git subrepo commit (merge) mailcow/src/mailcow-dockerized
subrepo:
subdir: "mailcow/src/mailcow-dockerized"
merged: "81fb18894"
upstream:
origin: "https://github.com/mailcow/mailcow-dockerized.git"
branch: "master"
commit: "4ca02ecee"
git-subrepo:
version: "0.4.6"
origin: "???"
commit: "???"
Update to upstream 2026-10. Local patches re-applied by hand
(no Unbound DNS for containers, IPv6 off by default, fake-MySQL
stubs in dockerapi, Postfix overrides, no .env symlink); dropped
the unused dovecot and clamd Dockerfile patches.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Change-Id: I2c2c194d1d436b841358685f5f94aef09eb19ae8
diff --git a/mailcow/src/mailcow-dockerized/data/web/_rspamderror.php b/mailcow/src/mailcow-dockerized/data/web/_rspamderror.php
index 6bdfb34..4976e0b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/_rspamderror.php
+++ b/mailcow/src/mailcow-dockerized/data/web/_rspamderror.php
@@ -7,6 +7,7 @@
else {
$redis->connect('redis-mailcow', 6379);
}
+ $redis->auth(getenv("REDISPASS"));
}
catch (Exception $e) {
exit;
diff --git a/mailcow/src/mailcow-dockerized/data/web/admin.php b/mailcow/src/mailcow-dockerized/data/web/admin.php
deleted file mode 100644
index d0fcbc9..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/admin.php
+++ /dev/null
@@ -1,124 +0,0 @@
-<?php
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
-
-if (!isset($_SESSION['mailcow_cc_role']) || $_SESSION['mailcow_cc_role'] != "admin") {
- header('Location: /');
- exit();
-}
-
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
-$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
-$tfa_data = get_tfa();
-$fido2_data = fido2(array("action" => "get_friendly_names"));
-
-$js_minifier->add('/web/js/site/admin.js');
-$js_minifier->add('/web/js/presets/rspamd.js');
-$js_minifier->add('/web/js/site/pwgen.js');
-
-// all domains
-$domains = mailbox('get', 'domains');
-$all_domains = array_merge($domains, mailbox('get', 'alias_domains'));
-
-// mailboxes
-$mailboxes = [];
-foreach ($all_domains as $domain) {
- foreach (mailbox('get', 'mailboxes', $domain) as $mailbox) {
- $mailboxes[] = $mailbox;
- }
-}
-$mailboxes = array_filter($mailboxes);
-
-// DKIM domains
-$dkim_domains = [];
-$dkim_domains_with_keys = [];
-foreach($domains as $domain) {
- $dkim_domains[$domain] = ['dkim' => null, 'alias_domains' => []];
- if (!empty($dkim = dkim('details', $domain))) {
- $dkim_domains_with_keys[] = $domain;
- if ($GLOBALS['SHOW_DKIM_PRIV_KEYS'] !== true) {
- $dkim['privkey'] = base64_encode('Please set $SHOW_DKIM_PRIV_KEYS to true to show DKIM private keys.');
- }
- $dkim_domains[$domain]['dkim'] = $dkim;
- }
-
- // get alias domains
- foreach (mailbox('get', 'alias_domains', $domain) as $alias_domain) {
- $dkim_domains[$domain]['alias_domains'][$alias_domain] = ['dkim' => null];
- if (!empty($dkim = dkim('details', $alias_domain))) {
- $dkim_domains_with_keys[] = $alias_domain;
- if ($GLOBALS['SHOW_DKIM_PRIV_KEYS'] !== true) {
- $dkim['privkey'] = base64_encode('Please set $SHOW_DKIM_PRIV_KEYS to true to show DKIM private keys.');
- }
- $dkim_domains[$domain]['alias_domains'][$alias_domain]['dkim'] = $dkim;
- }
- }
-}
-$dkim_blind_domains = [];
-foreach(dkim('blind') as $blind) {
- $dkim_blind_domains[$blind] = ['dkim' => null];
- if (!empty($dkim = dkim('details', $blind))) {
- $dkim_domains_with_keys[] = $blind;
- if ($GLOBALS['SHOW_DKIM_PRIV_KEYS'] !== true) {
- $dkim['privkey'] = base64_encode('Please set $SHOW_DKIM_PRIV_KEYS to true to show DKIM private keys.');
- }
- $dkim_blind_domains[$blind]['dkim'] = $dkim;
- }
-}
-
-// rsettings
-$rsettings = array_map(function ($rsetting){
- $rsetting['details'] = rsettings('details', $rsetting['id']);
- return $rsetting;
-}, rsettings('get'));
-
-// rspamd regex maps
-$rspamd_regex_maps = [];
-foreach ($RSPAMD_MAPS['regex'] as $rspamd_regex_desc => $rspamd_regex_map) {
- $rspamd_regex_maps[$rspamd_regex_desc] = [
- 'map' => $rspamd_regex_map,
- 'data' => file_get_contents('/rspamd_custom_maps/' . $rspamd_regex_map)
- ];
-}
-
-// cors settings
-$cors_settings = cors('get');
-$cors_settings['allowed_origins'] = str_replace(", ", "\n", $cors_settings['allowed_origins']);
-$cors_settings['allowed_methods'] = explode(", ", $cors_settings['allowed_methods']);
-
-$f2b_data = fail2ban('get');
-
-$template = 'admin.twig';
-$template_data = [
- 'tfa_data' => $tfa_data,
- 'tfa_id' => @$_SESSION['tfa_id'],
- 'fido2_cid' => @$_SESSION['fido2_cid'],
- 'fido2_data' => $fido2_data,
- 'api' => [
- 'ro' => admin_api('ro', 'get'),
- 'rw' => admin_api('rw', 'get'),
- ],
- 'dkim_domains' => $dkim_domains,
- 'dkim_domains_with_keys' => $dkim_domains_with_keys,
- 'dkim_blind_domains' => $dkim_blind_domains,
- 'domains' => $domains,
- 'all_domains' => $all_domains,
- 'mailboxes' => $mailboxes,
- 'f2b_data' => $f2b_data,
- 'f2b_banlist_url' => getBaseUrl() . "/api/v1/get/fail2ban/banlist/" . $f2b_data['banlist_id'],
- 'q_data' => quarantine('settings'),
- 'qn_data' => quota_notification('get'),
- 'rsettings_map' => file_get_contents('http://nginx:8081/settings.php'),
- 'rsettings' => $rsettings,
- 'rspamd_regex_maps' => $rspamd_regex_maps,
- 'logo_specs' => customize('get', 'main_logo_specs'),
- 'logo_dark_specs' => customize('get', 'main_logo_dark_specs'),
- 'ip_check' => customize('get', 'ip_check'),
- 'password_complexity' => password_complexity('get'),
- 'show_rspamd_global_filters' => @$_SESSION['show_rspamd_global_filters'],
- 'cors_settings' => $cors_settings,
- 'is_https' => isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on',
- 'lang_admin' => json_encode($lang['admin']),
- 'lang_datatables' => json_encode($lang['datatables'])
-];
-
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/admin/dashboard.php b/mailcow/src/mailcow-dockerized/data/web/admin/dashboard.php
new file mode 100644
index 0000000..2867770
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/admin/dashboard.php
@@ -0,0 +1,81 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.admin.inc.php';
+
+protect_route(['admin']);
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+$clamd_status = (preg_match("/^([yY][eE][sS]|[yY])+$/", $_ENV["SKIP_CLAMD"])) ? false : true;
+$olefy_status = (preg_match("/^([yY][eE][sS]|[yY])+$/", $_ENV["SKIP_OLEFY"])) ? false : true;
+
+
+if (!isset($_SESSION['gal']) && $license_cache = $redis->Get('LICENSE_STATUS_CACHE')) {
+ $_SESSION['gal'] = json_decode($license_cache, true);
+}
+
+$js_minifier->add('/web/js/site/dashboard.js');
+
+// vmail df
+$exec_fields = array('cmd' => 'system', 'task' => 'df', 'dir' => '/var/vmail');
+$vmail_df = explode(',', (string)json_decode(docker('post', 'dovecot-mailcow', 'exec', $exec_fields), true));
+
+// containers
+$containers_info = (array) docker('info');
+if ($clamd_status === false) unset($containers_info['clamd-mailcow']);
+if ($olefy_status === false) unset($containers_info['olefy-mailcow']);
+ksort($containers_info);
+$containers = array();
+foreach ($containers_info as $container => $container_info) {
+ if (!isset($container_info['State']) || !is_array($container_info['State']) || !isset($container_info['State']['StartedAt'])){
+ continue;
+ }
+ date_default_timezone_set('UTC');
+ $StartedAt = date_parse($container_info['State']['StartedAt']);
+ if ($StartedAt['hour'] !== false) {
+ $date = new \DateTime();
+ $date->setTimestamp(mktime(
+ $StartedAt['hour'],
+ $StartedAt['minute'],
+ $StartedAt['second'],
+ $StartedAt['month'],
+ $StartedAt['day'],
+ $StartedAt['year']));
+ try {
+ $user_tz = new DateTimeZone(getenv('TZ'));
+ $date->setTimezone($user_tz);
+ $container_info['State']['StartedAtHR'] = $date->format('r');
+ } catch(Exception $e) {
+ $container_info['State']['StartedAtHR'] = '?';
+ }
+ }
+ else {
+ $container_info['State']['StartedAtHR'] = '?';
+ }
+ $containers[$container] = $container_info;
+}
+
+// get mailcow data
+$hostname = getenv('MAILCOW_HOSTNAME');
+$timezone = getenv('TZ');
+
+$template = 'dashboard.twig';
+$template_data = [
+ 'log_lines' => getenv('LOG_LINES'),
+ 'vmail_df' => $vmail_df,
+ 'hostname' => $hostname,
+ 'timezone' => $timezone,
+ 'gal' => @$_SESSION['gal'],
+ 'license_guid' => license('guid'),
+ 'clamd_status' => $clamd_status,
+ 'olefy_status' => $olefy_status,
+ 'containers' => $containers,
+ 'ip_check' => customize('get', 'ip_check'),
+ 'lang_admin' => json_encode($lang['admin']),
+ 'lang_debug' => json_encode($lang['debug']),
+ 'lang_datatables' => json_encode($lang['datatables']),
+];
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
+
+
diff --git a/mailcow/src/mailcow-dockerized/data/web/admin/index.php b/mailcow/src/mailcow-dockerized/data/web/admin/index.php
new file mode 100644
index 0000000..9e0bf1b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/admin/index.php
@@ -0,0 +1,33 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.admin.inc.php';
+
+if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'admin') {
+ // Only redirect to dashboard if NO pending actions
+ if (empty($_SESSION['pending_tfa_setup']) && empty($_SESSION['pending_pw_update'])) {
+ header('Location: /admin/dashboard');
+ exit();
+ }
+}
+elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'domainadmin') {
+ header('Location: /domainadmin/mailbox');
+ exit();
+}
+elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'user') {
+ header('Location: /user');
+ exit();
+}
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+$_SESSION['index_query_string'] = $_SERVER['QUERY_STRING'];
+
+
+$template = 'admin_index.twig';
+$template_data = [
+ 'login_delay' => @$_SESSION['ldelay'],
+ 'custom_login' => customize('get', 'custom_login'),
+];
+
+$js_minifier->add('/web/js/site/index.js');
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/admin/mailbox.php b/mailcow/src/mailcow-dockerized/data/web/admin/mailbox.php
new file mode 100644
index 0000000..7b07d6f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/admin/mailbox.php
@@ -0,0 +1,47 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.admin.inc.php';
+
+protect_route(['admin']);
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+
+
+
+$js_minifier->add('/web/js/site/mailbox.js');
+$js_minifier->add('/web/js/presets/sieveMailbox.js');
+$js_minifier->add('/web/js/site/pwgen.js');
+
+$role = "admin";
+$is_dual = (!empty($_SESSION["dual-login"]["username"])) ? 'true' : 'false';
+$allow_admin_email_login = (preg_match("/^([yY][eE][sS]|[yY])+$/", $_ENV["ALLOW_ADMIN_EMAIL_LOGIN"])) ? 'true' : 'false';
+
+// domains
+$domains = mailbox('get', 'domains');
+
+// mailboxes
+$mailboxes = [];
+foreach ($domains as $domain) {
+ foreach (mailbox('get', 'mailboxes', $domain) as $mailbox) {
+ $mailboxes[] = $mailbox;
+ }
+}
+
+$template = 'mailbox.twig';
+$template_data = [
+ 'acl' => $_SESSION['acl'],
+ 'acl_json' => json_encode($_SESSION['acl']),
+ 'role' => $role,
+ 'is_dual' => $is_dual,
+ 'allow_admin_email_login' => $allow_admin_email_login,
+ 'global_filters' => mailbox('get', 'global_filter_details'),
+ 'domains' => $domains,
+ 'mailboxes' => $mailboxes,
+ 'lang_mailbox' => json_encode($lang['mailbox']),
+ 'lang_rl' => json_encode($lang['ratelimit']),
+ 'lang_edit' => json_encode($lang['edit']),
+ 'lang_datatables' => json_encode($lang['datatables']),
+];
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/admin/queue.php b/mailcow/src/mailcow-dockerized/data/web/admin/queue.php
new file mode 100644
index 0000000..66682c7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/admin/queue.php
@@ -0,0 +1,23 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.admin.inc.php';
+
+protect_route(['admin']);
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$js_minifier->add('/web/js/site/queue.js');
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+
+$role = "admin";
+
+$template = 'queue.twig';
+$template_data = [
+ 'acl' => $_SESSION['acl'],
+ 'acl_json' => json_encode($_SESSION['acl']),
+ 'role' => $role,
+ 'lang_admin' => json_encode($lang['admin']),
+ 'lang_queue' => json_encode($lang['queue']),
+ 'lang_datatables' => json_encode($lang['datatables'])
+];
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/admin/system.php b/mailcow/src/mailcow-dockerized/data/web/admin/system.php
new file mode 100644
index 0000000..b5e0080
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/admin/system.php
@@ -0,0 +1,130 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.admin.inc.php';
+
+protect_route(['admin']);
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+$tfa_data = get_tfa();
+$fido2_data = fido2(array("action" => "get_friendly_names"));
+
+$js_minifier->add('/web/js/site/admin.js');
+$js_minifier->add('/web/js/presets/rspamd.js');
+$js_minifier->add('/web/js/site/pwgen.js');
+
+// all domains
+$domains = mailbox('get', 'domains');
+$all_domains = array_merge($domains, mailbox('get', 'alias_domains'));
+
+// mailboxes
+$mailboxes = [];
+foreach ($all_domains as $domain) {
+ foreach (mailbox('get', 'mailboxes', $domain) as $mailbox) {
+ $mailboxes[] = $mailbox;
+ }
+}
+$mailboxes = array_filter($mailboxes);
+
+// DKIM domains
+$dkim_domains = [];
+$dkim_domains_with_keys = [];
+foreach($domains as $domain) {
+ $dkim_domains[$domain] = ['dkim' => null, 'alias_domains' => []];
+ if (!empty($dkim = dkim('details', $domain))) {
+ $dkim_domains_with_keys[] = $domain;
+ if ($GLOBALS['SHOW_DKIM_PRIV_KEYS'] !== true) {
+ $dkim['privkey'] = base64_encode('Please set $SHOW_DKIM_PRIV_KEYS to true to show DKIM private keys.');
+ }
+ $dkim_domains[$domain]['dkim'] = $dkim;
+ }
+
+ // get alias domains
+ foreach (mailbox('get', 'alias_domains', $domain) as $alias_domain) {
+ $dkim_domains[$domain]['alias_domains'][$alias_domain] = ['dkim' => null];
+ if (!empty($dkim = dkim('details', $alias_domain))) {
+ $dkim_domains_with_keys[] = $alias_domain;
+ if ($GLOBALS['SHOW_DKIM_PRIV_KEYS'] !== true) {
+ $dkim['privkey'] = base64_encode('Please set $SHOW_DKIM_PRIV_KEYS to true to show DKIM private keys.');
+ }
+ $dkim_domains[$domain]['alias_domains'][$alias_domain]['dkim'] = $dkim;
+ }
+ }
+}
+$dkim_blind_domains = [];
+foreach(dkim('blind') as $blind) {
+ $dkim_blind_domains[$blind] = ['dkim' => null];
+ if (!empty($dkim = dkim('details', $blind))) {
+ $dkim_domains_with_keys[] = $blind;
+ if ($GLOBALS['SHOW_DKIM_PRIV_KEYS'] !== true) {
+ $dkim['privkey'] = base64_encode('Please set $SHOW_DKIM_PRIV_KEYS to true to show DKIM private keys.');
+ }
+ $dkim_blind_domains[$blind]['dkim'] = $dkim;
+ }
+}
+
+// rsettings
+$rsettings = array_map(function ($rsetting){
+ $rsetting['details'] = rsettings('details', $rsetting['id']);
+ return $rsetting;
+}, rsettings('get'));
+
+// rspamd regex maps
+$rspamd_regex_maps = [];
+foreach ($RSPAMD_MAPS['regex'] as $rspamd_regex_desc => $rspamd_regex_map) {
+ $rspamd_regex_maps[$rspamd_regex_desc] = [
+ 'map' => $rspamd_regex_map,
+ 'data' => file_get_contents('/rspamd_custom_maps/' . $rspamd_regex_map)
+ ];
+}
+
+// cors settings
+$cors_settings = cors('get');
+$cors_settings['allowed_origins'] = str_replace(", ", "\n", $cors_settings['allowed_origins']);
+$cors_settings['allowed_methods'] = explode(", ", $cors_settings['allowed_methods']);
+
+$f2b_data = fail2ban('get');
+// mbox templates
+$mbox_templates = mailbox('get', 'mailbox_templates');
+
+$template = 'admin.twig';
+$template_data = [
+ 'tfa_data' => $tfa_data,
+ 'tfa_id' => @$_SESSION['tfa_id'],
+ 'fido2_cid' => @$_SESSION['fido2_cid'],
+ 'fido2_data' => $fido2_data,
+ 'api' => [
+ 'ro' => admin_api('ro', 'get'),
+ 'rw' => admin_api('rw', 'get'),
+ ],
+ 'dkim_domains' => $dkim_domains,
+ 'dkim_domains_with_keys' => $dkim_domains_with_keys,
+ 'dkim_blind_domains' => $dkim_blind_domains,
+ 'domains' => $domains,
+ 'all_domains' => $all_domains,
+ 'mailboxes' => $mailboxes,
+ 'f2b_data' => $f2b_data,
+ 'f2b_banlist_url' => getBaseUrl() . "/f2b-banlist?id=" . $f2b_data['banlist_id'],
+ 'q_data' => quarantine('settings'),
+ 'qn_data' => quota_notification('get'),
+ 'pw_reset_data' => reset_password('get_notification'),
+ 'rsettings_map' => file_get_contents('http://nginx:8081/settings.php'),
+ 'rsettings' => $rsettings,
+ 'rspamd_regex_maps' => $rspamd_regex_maps,
+ 'logo_specs' => customize('get', 'main_logo_specs'),
+ 'logo_dark_specs' => customize('get', 'main_logo_dark_specs'),
+ 'ip_check' => customize('get', 'ip_check'),
+ 'custom_login' => customize('get', 'custom_login'),
+ 'ui_themes' => customize('get', 'ui_themes'),
+ 'ui_theme' => customize('get', 'ui_theme'),
+ 'password_complexity' => password_complexity('get'),
+ 'show_rspamd_global_filters' => @$_SESSION['show_rspamd_global_filters'],
+ 'cors_settings' => $cors_settings,
+ 'is_https' => isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on',
+ 'iam_settings' => $iam_settings,
+ 'mbox_templates' => $mbox_templates,
+ 'lang_admin' => json_encode($lang['admin']),
+ 'lang_datatables' => json_encode($lang['datatables'])
+];
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/api/openapi.yaml b/mailcow/src/mailcow-dockerized/data/web/api/openapi.yaml
index 09d613a..c865619 100644
--- a/mailcow/src/mailcow-dockerized/data/web/api/openapi.yaml
+++ b/mailcow/src/mailcow-dockerized/data/web/api/openapi.yaml
@@ -185,6 +185,9 @@
example:
username: info@domain.tld
domain: domain.tld
+ description: my time limited alias
+ validity: 8760
+ permanent: false
properties:
username:
description: 'the mailbox an alias should be created for'
@@ -192,6 +195,15 @@
domain:
description: "the domain"
type: string
+ description:
+ description: "a description for the alias, defaults to an empty string"
+ type: string
+ validity:
+ description: "how many hours the alias stays valid, 1 to 87600, defaults to 8760 (one year)"
+ type: integer
+ permanent:
+ description: "keep the alias after it expired, defaults to false"
+ type: boolean
type: object
summary: Create time limited alias
/api/v1/add/app-passwd:
@@ -346,7 +358,8 @@
description: the domain which emails should be forwarded
type: string
type:
- description: the type of bcc map can be `sender` or `recipient`
+ description: the type of bcc map can be `sender` or `rcpt`
+ enum: [sender, rcpt]
type: string
type: object
summary: Create BCC Map
@@ -409,7 +422,7 @@
description: a list of domains for which a dkim key should be generated
type: string
key_size:
- description: the key size (1024 or 2048)
+ description: the key size (1024, 2048, 3072 or 4096)
type: number
type: object
summary: Generate DKIM Key
@@ -1071,6 +1084,7 @@
password2: "*"
quota: "3072"
force_pw_update: "1"
+ force_tfa: "1"
tls_enforce_in: "1"
tls_enforce_out: "1"
tags: ["tag1", "tag2"]
@@ -1112,10 +1126,12 @@
domain: domain.tld
local_part: info
name: Full name
+ authsource: mailcow
password: atedismonsin
password2: atedismonsin
quota: "3072"
force_pw_update: "1"
+ force_tfa: "1"
tls_enforce_in: "1"
tls_enforce_out: "1"
tags: ["tag1", "tag2"]
@@ -1132,11 +1148,16 @@
name:
description: Full name of the mailbox user
type: string
+ authsource:
+ description: Specifies the authentication source for the mailbox.
+ type: string
+ enum: [mailcow, ldap, keycloak, generic-oidc]
+ default: mailcow
password2:
description: mailbox password for confirmation
type: string
password:
- description: mailbox password
+ description: mailbox password when using `mailcow` as the authentication source.
type: string
quota:
description: mailbox quota
@@ -1144,6 +1165,9 @@
force_pw_update:
description: forces the user to update its password on first login
type: boolean
+ force_tfa:
+ description: force 2FA enrollment at login
+ type: boolean
tls_enforce_in:
description: force inbound email tls encryption
type: boolean
@@ -1531,6 +1555,9 @@
port1:
description: the smtp port of the target mail server
type: string
+ user1:
+ description: the username of the mailbox
+ type: string
password:
description: the password of the mailbox
type: string
@@ -2444,6 +2471,90 @@
type: object
type: object
summary: Delete mails in Quarantine
+ /api/v1/edit/qitem:
+ post:
+ responses:
+ "401":
+ $ref: "#/components/responses/Unauthorized"
+ "200":
+ content:
+ application/json:
+ examples:
+ release:
+ value:
+ - log:
+ - quarantine
+ - edit
+ - id:
+ - "33"
+ action: release
+ msg:
+ - item_released
+ - "33"
+ type: success
+ learnham:
+ value:
+ - log:
+ - quarantine
+ - edit
+ - id:
+ - "34"
+ action: learnham
+ msg:
+ - item_learned
+ - "34"
+ type: success
+ schema:
+ properties:
+ log:
+ description: contains request object
+ items: {}
+ type: array
+ msg:
+ items: {}
+ type: array
+ type:
+ enum:
+ - success
+ - danger
+ - error
+ type: string
+ type: object
+ description: OK
+ headers: {}
+ tags:
+ - Quarantine
+ description: >-
+ Using this endpoint you can perform actions on quarantine items. It is possible to release
+ emails from quarantine into to the inbox, or learn them as ham to improve Rspamd filtering.
+ You must provide the quarantine item IDs. You can get the IDs using the GET method.
+ operationId: Edit mails in Quarantine
+ requestBody:
+ content:
+ application/json:
+ schema:
+ example:
+ items:
+ - "33"
+ - "34"
+ attr:
+ action: release
+ properties:
+ items:
+ description: contains list of quarantine item IDs to release or learn as ham
+ type: object
+ attr:
+ description: attributes for the action
+ type: object
+ properties:
+ action:
+ type: string
+ enum:
+ - release
+ - learnham
+ description: "release - return email to inbox; learnham - learn as ham to improve filtering"
+ type: object
+ summary: Edit mails in Quarantine
/api/v1/delete/recipient_map:
post:
responses:
@@ -3320,6 +3431,7 @@
- mailbox
- active: "1"
force_pw_update: "0"
+ force_tfa: "0"
name: Full name
password: "*"
password2: "*"
@@ -3370,7 +3482,9 @@
attr:
active: "1"
force_pw_update: "0"
+ force_tfa: "0"
name: Full name
+ authsource: mailcow
password: ""
password2: ""
quota: "3072"
@@ -3392,14 +3506,21 @@
force_pw_update:
description: force user to change password on next login
type: boolean
+ force_tfa:
+ description: force 2FA enrollment at login
+ type: boolean
name:
description: Full name of the mailbox user
type: string
+ authsource:
+ description: Specifies the authentication source for the mailbox.
+ type: string
+ enum: [mailcow, ldap, keycloak, generic-oidc]
password2:
description: new mailbox password for confirmation
type: string
password:
- description: new mailbox password
+ description: new mailbox password when using `mailcow` as the authentication source.
type: string
quota:
description: mailbox quota
@@ -4782,6 +4903,7 @@
- active: "1"
attributes:
force_pw_update: "0"
+ force_tfa: "0"
mailbox_format: "maildir:"
quarantine_notification: never
sogo_access: "1"
@@ -4798,6 +4920,7 @@
quota: 3221225472
quota_used: 0
rl: false
+ sender_acl: ["otherbox@doman3.tld", "@aliasdomain.tld"]
spam_aliases: 0
username: info@doman3.tld
tags: ["tag1", "tag2"]
@@ -5415,12 +5538,6 @@
started_at: "2019-12-22T20:59:58.382274592Z"
state: running
type: info
- solr-mailcow:
- container: solr-mailcow
- image: "mailcow/solr:1.7"
- started_at: "2019-12-22T20:59:59.635413798Z"
- state: running
- type: info
unbound-mailcow:
container: unbound-mailcow
image: "mailcow/unbound:1.10"
@@ -5442,30 +5559,6 @@
hey where started and a few other details.
operationId: Get container status
summary: Get container status
- /api/v1/get/status/solr:
- get:
- responses:
- "401":
- $ref: "#/components/responses/Unauthorized"
- "200":
- content:
- application/json:
- examples:
- response:
- value:
- solr_documents: null
- solr_enabled: false
- solr_size: null
- type: info
- description: OK
- headers: {}
- tags:
- - Status
- description: >-
- Using this endpoint you can get the status of all containers and when
- hey where started and a few other details.
- operationId: Get solr status
- summary: Get solr status
/api/v1/get/status/vmail:
get:
responses:
@@ -5714,7 +5807,7 @@
- description: name of domain
in: path
name: domain
- required: false
+ required: true
schema:
type: string
- description: e.g. api-key-string
@@ -5736,6 +5829,7 @@
- active: "1"
attributes:
force_pw_update: "0"
+ force_tfa: "0"
mailbox_format: "maildir:"
quarantine_notification: never
sogo_access: "1"
@@ -5753,6 +5847,7 @@
quota: 3221225472
quota_used: 0
rl: false
+ sender_acl: ["otherbox@domain3.tld", "@aliasdomain.tld"]
spam_aliases: 0
username: info@domain3.tld
tags: ["tag1", "tag2"]
@@ -5775,15 +5870,15 @@
response:
value:
- type: "success"
- log: ["cors", "edit", {"allowed_origins": ["*", "mail.mailcow.tld"], "allowed_methods": ["POST", "GET", "DELETE", "PUT"]}]
+ log: ["cors", "edit", {"allowed_origins": ["*", "https://mail.mailcow.tld"], "allowed_methods": ["POST", "GET", "DELETE", "PUT"]}]
msg: "cors_headers_edited"
description: OK
headers: { }
tags:
- Cross-Origin Resource Sharing (CORS)
description: >-
- This endpoint allows you to manage Cross-Origin Resource Sharing (CORS) settings for the API.
- CORS is a security feature implemented by web browsers to prevent unauthorized cross-origin requests.
+ This endpoint allows you to manage Cross-Origin Resource Sharing (CORS) settings for the API.
+ CORS is a security feature implemented by web browsers to prevent unauthorized cross-origin requests.
By editing the CORS settings, you can specify which domains and which methods are permitted to access the API resources from outside the mailcow domain.
operationId: Edit Cross-Origin Resource Sharing (CORS) settings
requestBody:
@@ -5792,7 +5887,7 @@
schema:
example:
attr:
- allowed_origins: ["*", "mail.mailcow.tld"]
+ allowed_origins: ["*", "https://mail.mailcow.tld"]
allowed_methods: ["POST", "GET", "DELETE", "PUT"]
properties:
attr:
@@ -5841,6 +5936,226 @@
Using this endpoint you can get the global spam filter score or the spam filter score of a certain mailbox.
operationId: Get mailbox or global spam filter score
summary: Get mailbox or global spam filter score
+ /api/v1/edit/identity-provider:
+ post:
+ responses:
+ "401":
+ $ref: "#/components/responses/Unauthorized"
+ "200":
+ content:
+ application/json:
+ examples:
+ response:
+ value:
+ - type: "success"
+ log:
+ - "identity_provider"
+ - "edit"
+ - authsource: "keycloak"
+ server_url: "https://auth.mailcow.tld"
+ realm: "mailcow"
+ client_id: "mailcow_client"
+ client_secret: "*"
+ redirect_url: "https://mail.mailcow.tld"
+ redirect_url_extra: ["https://extramail.mailcow.tld"]
+ version: "26.1.3"
+ default_template: "Default"
+ mappers:
+ - "small_mbox"
+ - "medium_mbox"
+ templates:
+ - "small"
+ - "medium"
+ ignore_ssl_error: true
+ mailpassword_flow: true
+ periodic_sync: true
+ import_users: true
+ sync_interval: 30
+ msg:
+ - "object_modified"
+ - ""
+ description: OK
+ headers: { }
+ tags:
+ - Identity Provider
+ description: >-
+ Configure an external Identity Provider to use as user authentication
+ operationId: Edit external Identity Provider settings
+ requestBody:
+ content:
+ application/json:
+ schema:
+ properties:
+ items:
+ type: array
+ default: ["identity-provider"]
+ attr:
+ type: object
+ properties:
+ authsource:
+ description: Specifies the type of the Identity Provider
+ type: string
+ enum: [ldap, keycloak, generic-oidc]
+ server_url:
+ description: The base URL of your Keycloak server. Required if `authsource` is keycloak.
+ type: string
+ realm:
+ description: The Keycloak realm where the mailcow client is configured. Required if `authsource` is keycloak.
+ type: string
+ client_id:
+ description: The Client ID assigned to mailcow Client in OIDC Provider. Required if `authsource` is keycloak or generic-oidc.
+ type: string
+ client_secret:
+ description: The Client Secret assigned to mailcow Client in OIDC Provider. Required if `authsource` is keycloak or generic-oidc.
+ type: string
+ redirect_url:
+ description: The redirect URL that OIDC Provider will use after authentication. Required if `authsource` is keycloak or generic-oidc.
+ type: string
+ redirect_url_extra:
+ description: Additional redirect URLs that OIDC Provider can use after authentication if valid.
+ type: array
+ version:
+ description: Specifies the Keycloak version. Required if `authsource` is keycloak.
+ type: string
+ default_template:
+ description: (Optional) If no matching Attribute Mapping exists for a User, the default template will be used for creating the mailbox, but not for updating the mailbox.
+ type: string
+ mappers:
+ description: (Optional) Attribute values used to match a mailbox template. Each element corresponds to the respective index in the templates array (i.e., the first element matches the first element of templates, the second matches the second, and so on).
+ type: array
+ templates:
+ description: (Optional) Defines the mailbox templates to be assigned. Each element corresponds to the respective index in the `mappers` array.
+ type: array
+ ignore_ssl_error:
+ description: If enabled, SSL certificate validation is bypassed
+ type: boolean
+ default: false
+ mailpassword_flow:
+ description: If enabled, mailcow will attempt to validate user credentials using the Keycloak Admin REST API instead of relying solely on the Authorization Code Flow.
+ type: boolean
+ default: false
+ periodic_sync:
+ description: If enabled, mailcow periodically performs a full sync of all users from Keycloak or LDAP.
+ type: boolean
+ default: false
+ import_users:
+ description: If enabled, new users are automatically imported from Keycloak or LDAP into mailcow.
+ type: boolean
+ default: false
+ sync_interval:
+ description: Defines the time interval (in minutes) for periodic synchronization and user imports.
+ type: number
+ default: 15
+ host:
+ description: The address of your LDAP server. You can provide a single hostname or a comma-separated list of hosts for fallback in case the primary server is unreachable. Required if `authsource` is ldap.
+ type: string
+ port:
+ description: The port used to connect to the LDAP server. Required if `authsource` is ldap.
+ type: string
+ use_ssl:
+ description: enable LDAPS connection. If Port is set to 389 it will be overriden to 636.
+ type: boolean
+ default: false
+ use_tls:
+ description: enable TLS connection. TLS is recommended over SSL. SSL Ports cannot be used.
+ type: boolean
+ default: false
+ basedn:
+ description: The Distinguished Name (DN) from which searches will be performed. Required if `authsource` is ldap.
+ type: string
+ username_field:
+ description: The LDAP attribute used to identify users during authentication. Required if `authsource` is ldap.
+ type: string
+ default: mail
+ filter:
+ description: An optional LDAP search filter to refine which users can authenticate.
+ type: string
+ attribute_field:
+ description: Specifies an LDAP attribute that holds a specific value which can be mapped to a mailbox template using the Attribute Mapping section. Required if `authsource` is ldap.
+ type: string
+ binddn:
+ description: The Distinguished Name (DN) of the LDAP user that will be used to authenticate and perform LDAP searches. This account should have sufficient permissions to read the required attributes. Required if `authsource` is ldap.
+ type: string
+ bindpass:
+ description: The password for the Bind DN user. It is required for authentication when connecting to the LDAP server. Required if `authsource` is ldap.
+ type: string
+ authorize_url:
+ description: The OIDC provider's authorization server URL. Required if `authsource` is generic-oidc.
+ type: string
+ token_url:
+ description: The OIDC provider's token server URL. Required if `authsource` is generic-oidc.
+ type: string
+ userinfo_url:
+ description: The OIDC provider's user info server URL. Required if `authsource` is generic-oidc.
+ type: string
+ client_scopes:
+ description: Specifies the OIDC scopes requested during authentication.
+ type: string
+ default: "openid profile email mailcow_template"
+ examples:
+ keycloak:
+ value:
+ items:
+ - "identity-provider"
+ attr:
+ authsource: "keycloak"
+ server_url: "https://auth.mailcow.tld"
+ realm: "mailcow"
+ client_id: "mailcow_client"
+ client_secret: "Xy7GdPqvJ9m3R8sT2LkVZ5W1oNbCaYQf"
+ redirect_url: "https://mail.mailcow.tld"
+ redirect_url_extra: ["https://extramail.mailcow.tld"]
+ version: "26.1.3"
+ default_template: "Default"
+ mappers: ["small_mbox", "medium_mbox"]
+ templates: ["small", "medium"]
+ ignore_ssl_error: true
+ mailpassword_flow: true
+ periodic_sync: true
+ import_users: true
+ sync_interval: 30
+ ldap:
+ value:
+ items:
+ - "identity-provider"
+ attr:
+ authsource: "ldap"
+ host: "127.0.0.1"
+ port: "389"
+ use_ssl: false
+ use_tls: false
+ ignore_ssl_error: false
+ basedn: "DC=mailcow,DC=local"
+ username_field: "mail"
+ filter: "(memberOf:1.2.840.113556.1.4.1941:=DC=mailcow,DC=local)"
+ attribute_field: "othermailbox"
+ binddn: "CN=LDAP Read Only,CN=Users,DC=mailcow,DC=local"
+ bindpass: "moohoo"
+ default_template: "Default"
+ mappers: ["small_mbox", "medium_mbox"]
+ templates: ["small", "medium"]
+ periodic_sync: true
+ import_users: true
+ sync_interval: 30
+ generic-oidc:
+ value:
+ items:
+ - "identity-provider"
+ attr:
+ authsource: "generic-oidc"
+ authorize_url: "https://auth.mailcow.tld/application/o/authorize/"
+ token_url: "https://auth.mailcow.tld/application/o/token/"
+ userinfo_url: "https://auth.mailcow.tld/application/o/userinfo/"
+ client_id: "mailcow_client"
+ client_secret: "Xy7GdPqvJ9m3R8sT2LkVZ5W1oNbCaYQf"
+ redirect_url: "https://mail.mailcow.tld"
+ redirect_url_extra: ["https://extramail.mailcow.tld"]
+ client_scopes: "openid profile email mailcow_template"
+ default_template: "Default"
+ mappers: ["small_mbox", "medium_mbox"]
+ templates: ["small", "medium"]
+ ignore_ssl_error: true
+ summary: Edit external Identity Provider
tags:
- name: Domains
@@ -5887,3 +6202,5 @@
description: Edit domain ratelimits
- name: Cross-Origin Resource Sharing (CORS)
description: Manage Cross-Origin Resource Sharing (CORS) settings
+ - name: Identity Provider
+ description: Manage external Identity Provider settings
diff --git a/mailcow/src/mailcow-dockerized/data/web/autoconfig.php b/mailcow/src/mailcow-dockerized/data/web/autoconfig.php
index 95952df..bb4a55c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/autoconfig.php
+++ b/mailcow/src/mailcow-dockerized/data/web/autoconfig.php
@@ -29,8 +29,8 @@
<clientConfig version="1.1">
<emailProvider id="<?=$mailcow_hostname; ?>">
<domain>%EMAILDOMAIN%</domain>
- <displayName>A mailcow mail server</displayName>
- <displayShortName>mail server</displayShortName>
+ <displayName><?=$autodiscover_config['displayName']; ?></displayName>
+ <displayShortName><?=$autodiscover_config['displayShortName']; ?></displayShortName>
<incomingServer type="imap">
<hostname><?=$autodiscover_config['imap']['server']; ?></hostname>
@@ -85,7 +85,7 @@
<authentication>password-cleartext</authentication>
</outgoingServer>
- <enable visiturl="https://<?=$mailcow_hostname; ?><?php if ($port != 443) echo ':'.$port; ?>/admin.php">
+ <enable visiturl="https://<?=$mailcow_hostname; ?><?php if ($port != 443) echo ':'.$port; ?>/admin">
<instruction>If you didn't change the password given to you by the administrator or if you didn't change it in a long time, please consider doing that now.</instruction>
<instruction lang="de">Sollten Sie das Ihnen durch den Administrator vergebene Passwort noch nicht geändert haben, empfehlen wir dies nun zu tun. Auch ein altes Passwort sollte aus Sicherheitsgründen geändert werden.</instruction>
</enable>
diff --git a/mailcow/src/mailcow-dockerized/data/web/autodiscover.php b/mailcow/src/mailcow-dockerized/data/web/autodiscover.php
index 992524b..3e31dc3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/autodiscover.php
+++ b/mailcow/src/mailcow-dockerized/data/web/autodiscover.php
@@ -1,10 +1,15 @@
<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/lib/vendor/autoload.php';
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/vars.inc.php';
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.inc.php';
-$default_autodiscover_config = $autodiscover_config;
if(file_exists('inc/vars.local.inc.php')) {
include_once 'inc/vars.local.inc.php';
}
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.auth.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/sessions.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.mailbox.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.ratelimit.inc.php';
+$default_autodiscover_config = $autodiscover_config;
$autodiscover_config = array_merge($default_autodiscover_config, $autodiscover_config);
// Redis
@@ -16,6 +21,7 @@
else {
$redis->connect('redis-mailcow', 6379);
}
+ $redis->auth(getenv("REDISPASS"));
}
catch (Exception $e) {
exit;
@@ -49,101 +55,36 @@
PDO::ATTR_EMULATE_PREPARES => false,
];
$pdo = new PDO($dsn, $database_user, $database_pass, $opt);
-$login_user = strtolower(trim($_SERVER['PHP_AUTH_USER']));
-$login_pass = trim(htmlspecialchars_decode($_SERVER['PHP_AUTH_PW']));
-if (empty($_SERVER['PHP_AUTH_USER']) || empty($_SERVER['PHP_AUTH_PW'])) {
- $json = json_encode(
- array(
- "time" => time(),
- "ua" => $_SERVER['HTTP_USER_AGENT'],
- "user" => "none",
- "ip" => $_SERVER['REMOTE_ADDR'],
- "service" => "Error: must be authenticated"
- )
- );
- $redis->lPush('AUTODISCOVER_LOG', $json);
- header('WWW-Authenticate: Basic realm="' . $_SERVER['HTTP_HOST'] . '"');
- header('HTTP/1.0 401 Unauthorized');
- exit(0);
-}
+// Init Identity Provider
+$iam_provider = identity_provider('init');
+$iam_settings = identity_provider('get');
-$login_role = check_login($login_user, $login_pass, array('eas' => TRUE));
+// Passwordless autodiscover - no authentication required
+// Email will be extracted from the request body
+$login_user = null;
+$login_role = null;
-if ($login_role === "user") {
- header("Content-Type: application/xml");
- echo '<?xml version="1.0" encoding="utf-8" ?>' . PHP_EOL;
+header("Content-Type: application/xml");
+echo '<?xml version="1.0" encoding="utf-8" ?>' . PHP_EOL;
?>
<Autodiscover xmlns="http://schemas.microsoft.com/exchange/autodiscover/responseschema/2006">
<?php
- if(!$data) {
- try {
- $json = json_encode(
- array(
- "time" => time(),
- "ua" => $_SERVER['HTTP_USER_AGENT'],
- "user" => $_SERVER['PHP_AUTH_USER'],
- "ip" => $_SERVER['REMOTE_ADDR'],
- "service" => "Error: invalid or missing request data"
- )
- );
- $redis->lPush('AUTODISCOVER_LOG', $json);
- $redis->lTrim('AUTODISCOVER_LOG', 0, 100);
- }
- catch (RedisException $e) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'msg' => 'Redis: '.$e
- );
- return false;
- }
- list($usec, $sec) = explode(' ', microtime());
-?>
- <Response>
- <Error Time="<?=date('H:i:s', $sec) . substr($usec, 0, strlen($usec) - 2);?>" Id="2477272013">
- <ErrorCode>600</ErrorCode>
- <Message>Invalid Request</Message>
- <DebugData />
- </Error>
- </Response>
-</Autodiscover>
-<?php
- exit(0);
- }
- try {
- $discover = new SimpleXMLElement($data);
- $email = $discover->Request->EMailAddress;
- } catch (Exception $e) {
- $email = $_SERVER['PHP_AUTH_USER'];
- }
-
- $username = trim($email);
- try {
- $stmt = $pdo->prepare("SELECT `name` FROM `mailbox` WHERE `username`= :username");
- $stmt->execute(array(':username' => $username));
- $MailboxData = $stmt->fetch(PDO::FETCH_ASSOC);
- }
- catch(PDOException $e) {
- die("Failed to determine name from SQL");
- }
- if (!empty($MailboxData['name'])) {
- $displayname = $MailboxData['name'];
- }
- else {
- $displayname = $email;
- }
+if(!$data) {
try {
$json = json_encode(
array(
"time" => time(),
"ua" => $_SERVER['HTTP_USER_AGENT'],
- "user" => $_SERVER['PHP_AUTH_USER'],
+ "user" => "none",
"ip" => $_SERVER['REMOTE_ADDR'],
- "service" => $autodiscover_config['autodiscoverType']
+ "service" => "Error: invalid or missing request data"
)
);
$redis->lPush('AUTODISCOVER_LOG', $json);
$redis->lTrim('AUTODISCOVER_LOG', 0, 100);
+ $redis->publish("F2B_CHANNEL", "Autodiscover: Invalid request by " . $_SERVER['REMOTE_ADDR']);
+ error_log("Autodiscover: Invalid request by " . $_SERVER['REMOTE_ADDR']);
}
catch (RedisException $e) {
$_SESSION['return'][] = array(
@@ -152,7 +93,143 @@
);
return false;
}
- if ($autodiscover_config['autodiscoverType'] == 'imap') {
+ list($usec, $sec) = explode(' ', microtime());
+?>
+ <Response>
+ <Error Time="<?=date('H:i:s', $sec) . substr($usec, 0, strlen($usec) - 2);?>" Id="<?=rand(1000000000, 9999999999);?>">
+ <ErrorCode>600</ErrorCode>
+ <Message>Invalid Request</Message>
+ <DebugData />
+ </Error>
+ </Response>
+</Autodiscover>
+<?php
+ exit(0);
+}
+try {
+ $discover = new SimpleXMLElement($data);
+ $email = $discover->Request->EMailAddress;
+} catch (Exception $e) {
+ // If parsing fails, return error
+ try {
+ $json = json_encode(
+ array(
+ "time" => time(),
+ "ua" => $_SERVER['HTTP_USER_AGENT'],
+ "user" => "none",
+ "ip" => $_SERVER['REMOTE_ADDR'],
+ "service" => "Error: could not parse email from request"
+ )
+ );
+ $redis->lPush('AUTODISCOVER_LOG', $json);
+ $redis->lTrim('AUTODISCOVER_LOG', 0, 100);
+ $redis->publish("F2B_CHANNEL", "Autodiscover: Malformed XML by " . $_SERVER['REMOTE_ADDR']);
+ error_log("Autodiscover: Malformed XML by " . $_SERVER['REMOTE_ADDR']);
+ }
+ catch (RedisException $e) {
+ // Silently fail
+ }
+ list($usec, $sec) = explode(' ', microtime());
+?>
+ <Response>
+ <Error Time="<?=date('H:i:s', $sec) . substr($usec, 0, strlen($usec) - 2);?>" Id="<?=rand(1000000000, 9999999999);?>">
+ <ErrorCode>600</ErrorCode>
+ <Message>Invalid Request</Message>
+ <DebugData />
+ </Error>
+ </Response>
+</Autodiscover>
+<?php
+ exit(0);
+}
+
+$username = trim((string)$email);
+try {
+ $stmt = $pdo->prepare("SELECT `mailbox`.`name`, `mailbox`.`active` FROM `mailbox`
+ INNER JOIN `domain` ON `mailbox`.`domain` = `domain`.`domain`
+ WHERE `mailbox`.`username` = :username
+ AND `mailbox`.`active` = '1'
+ AND `domain`.`active` = '1'");
+ $stmt->execute(array(':username' => $username));
+ $MailboxData = $stmt->fetch(PDO::FETCH_ASSOC);
+}
+catch(PDOException $e) {
+ // Database error - return error response with complete XML
+ list($usec, $sec) = explode(' ', microtime());
+?>
+ <Response>
+ <Error Time="<?=date('H:i:s', $sec) . substr($usec, 0, strlen($usec) - 2);?>" Id="<?=rand(1000000000, 9999999999);?>">
+ <ErrorCode>500</ErrorCode>
+ <Message>Database Error</Message>
+ <DebugData />
+ </Error>
+ </Response>
+</Autodiscover>
+<?php
+ exit(0);
+}
+
+// Mailbox not found or not active - return generic error to prevent user enumeration
+if (empty($MailboxData)) {
+ try {
+ $json = json_encode(
+ array(
+ "time" => time(),
+ "ua" => $_SERVER['HTTP_USER_AGENT'],
+ "user" => $email,
+ "ip" => $_SERVER['REMOTE_ADDR'],
+ "service" => "Error: mailbox not found or inactive"
+ )
+ );
+ $redis->lPush('AUTODISCOVER_LOG', $json);
+ $redis->lTrim('AUTODISCOVER_LOG', 0, 100);
+ $redis->publish("F2B_CHANNEL", "Autodiscover: Invalid mailbox attempt by " . $_SERVER['REMOTE_ADDR']);
+ error_log("Autodiscover: Invalid mailbox attempt by " . $_SERVER['REMOTE_ADDR']);
+ }
+ catch (RedisException $e) {
+ // Silently fail
+ }
+ list($usec, $sec) = explode(' ', microtime());
+?>
+ <Response>
+ <Error Time="<?=date('H:i:s', $sec) . substr($usec, 0, strlen($usec) - 2);?>" Id="<?=rand(1000000000, 9999999999);?>">
+ <ErrorCode>600</ErrorCode>
+ <Message>Invalid Request</Message>
+ <DebugData />
+ </Error>
+ </Response>
+</Autodiscover>
+<?php
+ exit(0);
+}
+
+if (!empty($MailboxData['name'])) {
+ $displayname = $MailboxData['name'];
+}
+else {
+ $displayname = $email;
+}
+try {
+ $json = json_encode(
+ array(
+ "time" => time(),
+ "ua" => $_SERVER['HTTP_USER_AGENT'],
+ "user" => $email,
+ "ip" => $_SERVER['REMOTE_ADDR'],
+ "service" => $autodiscover_config['autodiscoverType']
+ )
+ );
+ $redis->lPush('AUTODISCOVER_LOG', $json);
+ $redis->lTrim('AUTODISCOVER_LOG', 0, 100);
+}
+catch (RedisException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'msg' => 'Redis: '.$e
+ );
+ return false;
+}
+if ($autodiscover_config['autodiscoverType'] == 'imap') {
?>
<Response xmlns="http://schemas.microsoft.com/exchange/autodiscover/outlook/responseschema/2006a">
<User>
@@ -227,6 +304,3 @@
}
?>
</Autodiscover>
-<?php
-}
-?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/build/003-bootstrap-select.css b/mailcow/src/mailcow-dockerized/data/web/css/build/003-bootstrap-select.css
index e248901..f9ce6d9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/build/003-bootstrap-select.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/build/003-bootstrap-select.css
@@ -1,10 +1,10 @@
-/*!
- * Bootstrap-select v1.14.0-beta2 (https://developer.snapappointments.com/bootstrap-select)
- *
- * Copyright 2012-2021 SnapAppointments, LLC
- * Licensed under MIT (https://github.com/snapappointments/bootstrap-select/blob/master/LICENSE)
- */
-
+/*!
+ * Bootstrap-select v1.14.0-beta3 (https://developer.snapappointments.com/bootstrap-select)
+ *
+ * Copyright 2012-2022 SnapAppointments, LLC
+ * Licensed under MIT (https://github.com/snapappointments/bootstrap-select/blob/master/LICENSE)
+ */
+
@-webkit-keyframes bs-notify-fadeOut {
0% {
opacity: 0.9;
@@ -35,8 +35,7 @@
display: none !important;
}
.bootstrap-select {
- width: 220px \0;
- /*IE9 and below*/
+ width: 220px;
vertical-align: middle;
}
.bootstrap-select > .dropdown-toggle {
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/build/007-languages.min.css b/mailcow/src/mailcow-dockerized/data/web/css/build/007-languages.min.css
index 864e338..9d8cb20 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/build/007-languages.min.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/build/007-languages.min.css
@@ -1 +1 @@
-.flag-icon-background{background-size:contain;background-position:50%;background-repeat:no-repeat}.flag-icon{background-size:contain;background-position:50%;background-repeat:no-repeat;position:relative;display:inline-block;width:1.33333333em;line-height:1em}.flag-icon:before{content:'\00a0'}.flag-icon.flag-icon-squared{width:1em}.flag-icon-ad{background-image:url(../flags/4x3/ad.svg)}.flag-icon-ad.flag-icon-squared{background-image:url(../flags/1x1/ad.svg)}.flag-icon-ae{background-image:url(../flags/4x3/ae.svg)}.flag-icon-ae.flag-icon-squared{background-image:url(../flags/1x1/ae.svg)}.flag-icon-af{background-image:url(../flags/4x3/af.svg)}.flag-icon-af.flag-icon-squared{background-image:url(../flags/1x1/af.svg)}.flag-icon-ag{background-image:url(../flags/4x3/ag.svg)}.flag-icon-ag.flag-icon-squared{background-image:url(../flags/1x1/ag.svg)}.flag-icon-ai{background-image:url(../flags/4x3/ai.svg)}.flag-icon-ai.flag-icon-squared{background-image:url(../flags/1x1/ai.svg)}.flag-icon-al{background-image:url(../flags/4x3/al.svg)}.flag-icon-al.flag-icon-squared{background-image:url(../flags/1x1/al.svg)}.flag-icon-am{background-image:url(../flags/4x3/am.svg)}.flag-icon-am.flag-icon-squared{background-image:url(../flags/1x1/am.svg)}.flag-icon-ao{background-image:url(../flags/4x3/ao.svg)}.flag-icon-ao.flag-icon-squared{background-image:url(../flags/1x1/ao.svg)}.flag-icon-aq{background-image:url(../flags/4x3/aq.svg)}.flag-icon-aq.flag-icon-squared{background-image:url(../flags/1x1/aq.svg)}.flag-icon-ar{background-image:url(../flags/4x3/ar.svg)}.flag-icon-ar.flag-icon-squared{background-image:url(../flags/1x1/ar.svg)}.flag-icon-as{background-image:url(../flags/4x3/as.svg)}.flag-icon-as.flag-icon-squared{background-image:url(../flags/1x1/as.svg)}.flag-icon-at{background-image:url(../flags/4x3/at.svg)}.flag-icon-at.flag-icon-squared{background-image:url(../flags/1x1/at.svg)}.flag-icon-au{background-image:url(../flags/4x3/au.svg)}.flag-icon-au.flag-icon-squared{background-image:url(../flags/1x1/au.svg)}.flag-icon-aw{background-image:url(../flags/4x3/aw.svg)}.flag-icon-aw.flag-icon-squared{background-image:url(../flags/1x1/aw.svg)}.flag-icon-ax{background-image:url(../flags/4x3/ax.svg)}.flag-icon-ax.flag-icon-squared{background-image:url(../flags/1x1/ax.svg)}.flag-icon-az{background-image:url(../flags/4x3/az.svg)}.flag-icon-az.flag-icon-squared{background-image:url(../flags/1x1/az.svg)}.flag-icon-ba{background-image:url(../flags/4x3/ba.svg)}.flag-icon-ba.flag-icon-squared{background-image:url(../flags/1x1/ba.svg)}.flag-icon-bb{background-image:url(../flags/4x3/bb.svg)}.flag-icon-bb.flag-icon-squared{background-image:url(../flags/1x1/bb.svg)}.flag-icon-bd{background-image:url(../flags/4x3/bd.svg)}.flag-icon-bd.flag-icon-squared{background-image:url(../flags/1x1/bd.svg)}.flag-icon-be{background-image:url(../flags/4x3/be.svg)}.flag-icon-be.flag-icon-squared{background-image:url(../flags/1x1/be.svg)}.flag-icon-bf{background-image:url(../flags/4x3/bf.svg)}.flag-icon-bf.flag-icon-squared{background-image:url(../flags/1x1/bf.svg)}.flag-icon-bg{background-image:url(../flags/4x3/bg.svg)}.flag-icon-bg.flag-icon-squared{background-image:url(../flags/1x1/bg.svg)}.flag-icon-bh{background-image:url(../flags/4x3/bh.svg)}.flag-icon-bh.flag-icon-squared{background-image:url(../flags/1x1/bh.svg)}.flag-icon-bi{background-image:url(../flags/4x3/bi.svg)}.flag-icon-bi.flag-icon-squared{background-image:url(../flags/1x1/bi.svg)}.flag-icon-bj{background-image:url(../flags/4x3/bj.svg)}.flag-icon-bj.flag-icon-squared{background-image:url(../flags/1x1/bj.svg)}.flag-icon-bl{background-image:url(../flags/4x3/bl.svg)}.flag-icon-bl.flag-icon-squared{background-image:url(../flags/1x1/bl.svg)}.flag-icon-bm{background-image:url(../flags/4x3/bm.svg)}.flag-icon-bm.flag-icon-squared{background-image:url(../flags/1x1/bm.svg)}.flag-icon-bn{background-image:url(../flags/4x3/bn.svg)}.flag-icon-bn.flag-icon-squared{background-image:url(../flags/1x1/bn.svg)}.flag-icon-bo{background-image:url(../flags/4x3/bo.svg)}.flag-icon-bo.flag-icon-squared{background-image:url(../flags/1x1/bo.svg)}.flag-icon-bq{background-image:url(../flags/4x3/bq.svg)}.flag-icon-bq.flag-icon-squared{background-image:url(../flags/1x1/bq.svg)}.flag-icon-br{background-image:url(../flags/4x3/br.svg)}.flag-icon-br.flag-icon-squared{background-image:url(../flags/1x1/br.svg)}.flag-icon-bs{background-image:url(../flags/4x3/bs.svg)}.flag-icon-bs.flag-icon-squared{background-image:url(../flags/1x1/bs.svg)}.flag-icon-bt{background-image:url(../flags/4x3/bt.svg)}.flag-icon-bt.flag-icon-squared{background-image:url(../flags/1x1/bt.svg)}.flag-icon-bv{background-image:url(../flags/4x3/bv.svg)}.flag-icon-bv.flag-icon-squared{background-image:url(../flags/1x1/bv.svg)}.flag-icon-bw{background-image:url(../flags/4x3/bw.svg)}.flag-icon-bw.flag-icon-squared{background-image:url(../flags/1x1/bw.svg)}.flag-icon-by{background-image:url(../flags/4x3/by.svg)}.flag-icon-by.flag-icon-squared{background-image:url(../flags/1x1/by.svg)}.flag-icon-bz{background-image:url(../flags/4x3/bz.svg)}.flag-icon-bz.flag-icon-squared{background-image:url(../flags/1x1/bz.svg)}.flag-icon-ca{background-image:url(../flags/4x3/ca.svg)}.flag-icon-ca.flag-icon-squared{background-image:url(../flags/1x1/ca.svg)}.flag-icon-cc{background-image:url(../flags/4x3/cc.svg)}.flag-icon-cc.flag-icon-squared{background-image:url(../flags/1x1/cc.svg)}.flag-icon-cd{background-image:url(../flags/4x3/cd.svg)}.flag-icon-cd.flag-icon-squared{background-image:url(../flags/1x1/cd.svg)}.flag-icon-cf{background-image:url(../flags/4x3/cf.svg)}.flag-icon-cf.flag-icon-squared{background-image:url(../flags/1x1/cf.svg)}.flag-icon-cg{background-image:url(../flags/4x3/cg.svg)}.flag-icon-cg.flag-icon-squared{background-image:url(../flags/1x1/cg.svg)}.flag-icon-ch{background-image:url(../flags/4x3/ch.svg)}.flag-icon-ch.flag-icon-squared{background-image:url(../flags/1x1/ch.svg)}.flag-icon-ci{background-image:url(../flags/4x3/ci.svg)}.flag-icon-ci.flag-icon-squared{background-image:url(../flags/1x1/ci.svg)}.flag-icon-ck{background-image:url(../flags/4x3/ck.svg)}.flag-icon-ck.flag-icon-squared{background-image:url(../flags/1x1/ck.svg)}.flag-icon-cl{background-image:url(../flags/4x3/cl.svg)}.flag-icon-cl.flag-icon-squared{background-image:url(../flags/1x1/cl.svg)}.flag-icon-cm{background-image:url(../flags/4x3/cm.svg)}.flag-icon-cm.flag-icon-squared{background-image:url(../flags/1x1/cm.svg)}.flag-icon-zh{background-image:url(../flags/4x3/zh.svg)}.flag-iconzh.flag-icon-squared{background-image:url(../flags/1x1/zh.svg)}.flag-icon-cn{background-image:url(../flags/4x3/cn.svg)}.flag-icon-cn.flag-icon-squared{background-image:url(../flags/1x1/cn.svg)}.flag-icon-co{background-image:url(../flags/4x3/co.svg)}.flag-icon-co.flag-icon-squared{background-image:url(../flags/1x1/co.svg)}.flag-icon-cr{background-image:url(../flags/4x3/cr.svg)}.flag-icon-cr.flag-icon-squared{background-image:url(../flags/1x1/cr.svg)}.flag-icon-cu{background-image:url(../flags/4x3/cu.svg)}.flag-icon-cu.flag-icon-squared{background-image:url(../flags/1x1/cu.svg)}.flag-icon-cv{background-image:url(../flags/4x3/cv.svg)}.flag-icon-cv.flag-icon-squared{background-image:url(../flags/1x1/cv.svg)}.flag-icon-cw{background-image:url(../flags/4x3/cw.svg)}.flag-icon-cw.flag-icon-squared{background-image:url(../flags/1x1/cw.svg)}.flag-icon-cx{background-image:url(../flags/4x3/cx.svg)}.flag-icon-cx.flag-icon-squared{background-image:url(../flags/1x1/cx.svg)}.flag-icon-cy{background-image:url(../flags/4x3/cy.svg)}.flag-icon-cy.flag-icon-squared{background-image:url(../flags/1x1/cy.svg)}.flag-icon-cz{background-image:url(../flags/4x3/cz.svg)}.flag-icon-cz.flag-icon-squared{background-image:url(../flags/1x1/cz.svg)}.flag-icon-cs{background-image:url(../flags/4x3/cs.svg)}.flag-icon-cs.flag-icon-squared{background-image:url(../flags/1x1/cs.svg)}.flag-icon-de{background-image:url(../flags/4x3/de.svg)}.flag-icon-de.flag-icon-squared{background-image:url(../flags/1x1/de.svg)}.flag-icon-dj{background-image:url(../flags/4x3/dj.svg)}.flag-icon-dj.flag-icon-squared{background-image:url(../flags/1x1/dj.svg)}.flag-icon-da{background-image:url(../flags/4x3/da.svg)}.flag-icon-da.flag-icon-squared{background-image:url(../flags/1x1/d.svg)}.flag-icon-dk{background-image:url(../flags/4x3/dk.svg)}.flag-icon-dk.flag-icon-squared{background-image:url(../flags/1x1/dk.svg)}.flag-icon-dm{background-image:url(../flags/4x3/dm.svg)}.flag-icon-dm.flag-icon-squared{background-image:url(../flags/1x1/dm.svg)}.flag-icon-do{background-image:url(../flags/4x3/do.svg)}.flag-icon-do.flag-icon-squared{background-image:url(../flags/1x1/do.svg)}.flag-icon-dz{background-image:url(../flags/4x3/dz.svg)}.flag-icon-dz.flag-icon-squared{background-image:url(../flags/1x1/dz.svg)}.flag-icon-ec{background-image:url(../flags/4x3/ec.svg)}.flag-icon-ec.flag-icon-squared{background-image:url(../flags/1x1/ec.svg)}.flag-icon-ee{background-image:url(../flags/4x3/ee.svg)}.flag-icon-ee.flag-icon-squared{background-image:url(../flags/1x1/ee.svg)}.flag-icon-eg{background-image:url(../flags/4x3/eg.svg)}.flag-icon-eg.flag-icon-squared{background-image:url(../flags/1x1/eg.svg)}.flag-icon-eh{background-image:url(../flags/4x3/eh.svg)}.flag-icon-eh.flag-icon-squared{background-image:url(../flags/1x1/eh.svg)}.flag-icon-er{background-image:url(../flags/4x3/er.svg)}.flag-icon-er.flag-icon-squared{background-image:url(../flags/1x1/er.svg)}.flag-icon-es{background-image:url(../flags/4x3/es.svg)}.flag-icon-es.flag-icon-squared{background-image:url(../flags/1x1/es.svg)}.flag-icon-et{background-image:url(../flags/4x3/et.svg)}.flag-icon-et.flag-icon-squared{background-image:url(../flags/1x1/et.svg)}.flag-icon-fi{background-image:url(../flags/4x3/fi.svg)}.flag-icon-fi.flag-icon-squared{background-image:url(../flags/1x1/fi.svg)}.flag-icon-fj{background-image:url(../flags/4x3/fj.svg)}.flag-icon-fj.flag-icon-squared{background-image:url(../flags/1x1/fj.svg)}.flag-icon-fk{background-image:url(../flags/4x3/fk.svg)}.flag-icon-fk.flag-icon-squared{background-image:url(../flags/1x1/fk.svg)}.flag-icon-fm{background-image:url(../flags/4x3/fm.svg)}.flag-icon-fm.flag-icon-squared{background-image:url(../flags/1x1/fm.svg)}.flag-icon-fo{background-image:url(../flags/4x3/fo.svg)}.flag-icon-fo.flag-icon-squared{background-image:url(../flags/1x1/fo.svg)}.flag-icon-fr{background-image:url(../flags/4x3/fr.svg)}.flag-icon-fr.flag-icon-squared{background-image:url(../flags/1x1/fr.svg)}.flag-icon-ga{background-image:url(../flags/4x3/ga.svg)}.flag-icon-ga.flag-icon-squared{background-image:url(../flags/1x1/ga.svg)}.flag-icon-gb{background-image:url(../flags/4x3/en.svg)}.flag-icon-gb.flag-icon-squared{background-image:url(../flags/1x1/en.svg)}.flag-icon-gd{background-image:url(../flags/4x3/gd.svg)}.flag-icon-gd.flag-icon-squared{background-image:url(../flags/1x1/gd.svg)}.flag-icon-ge{background-image:url(../flags/4x3/ge.svg)}.flag-icon-ge.flag-icon-squared{background-image:url(../flags/1x1/ge.svg)}.flag-icon-gf{background-image:url(../flags/4x3/gf.svg)}.flag-icon-gf.flag-icon-squared{background-image:url(../flags/1x1/gf.svg)}.flag-icon-gg{background-image:url(../flags/4x3/gg.svg)}.flag-icon-gg.flag-icon-squared{background-image:url(../flags/1x1/gg.svg)}.flag-icon-gh{background-image:url(../flags/4x3/gh.svg)}.flag-icon-gh.flag-icon-squared{background-image:url(../flags/1x1/gh.svg)}.flag-icon-gi{background-image:url(../flags/4x3/gi.svg)}.flag-icon-gi.flag-icon-squared{background-image:url(../flags/1x1/gi.svg)}.flag-icon-gl{background-image:url(../flags/4x3/gl.svg)}.flag-icon-gl.flag-icon-squared{background-image:url(../flags/1x1/gl.svg)}.flag-icon-gm{background-image:url(../flags/4x3/gm.svg)}.flag-icon-gm.flag-icon-squared{background-image:url(../flags/1x1/gm.svg)}.flag-icon-gn{background-image:url(../flags/4x3/gn.svg)}.flag-icon-gn.flag-icon-squared{background-image:url(../flags/1x1/gn.svg)}.flag-icon-gp{background-image:url(../flags/4x3/gp.svg)}.flag-icon-gp.flag-icon-squared{background-image:url(../flags/1x1/gp.svg)}.flag-icon-gq{background-image:url(../flags/4x3/gq.svg)}.flag-icon-gq.flag-icon-squared{background-image:url(../flags/1x1/gq.svg)}.flag-icon-gr{background-image:url(../flags/4x3/gr.svg)}.flag-icon-gr.flag-icon-squared{background-image:url(../flags/1x1/gr.svg)}.flag-icon-gs{background-image:url(../flags/4x3/gs.svg)}.flag-icon-gs.flag-icon-squared{background-image:url(../flags/1x1/gs.svg)}.flag-icon-gt{background-image:url(../flags/4x3/gt.svg)}.flag-icon-gt.flag-icon-squared{background-image:url(../flags/1x1/gt.svg)}.flag-icon-gu{background-image:url(../flags/4x3/gu.svg)}.flag-icon-gu.flag-icon-squared{background-image:url(../flags/1x1/gu.svg)}.flag-icon-gw{background-image:url(../flags/4x3/gw.svg)}.flag-icon-gw.flag-icon-squared{background-image:url(../flags/1x1/gw.svg)}.flag-icon-gy{background-image:url(../flags/4x3/gy.svg)}.flag-icon-gy.flag-icon-squared{background-image:url(../flags/1x1/gy.svg)}.flag-icon-hk{background-image:url(../flags/4x3/hk.svg)}.flag-icon-hk.flag-icon-squared{background-image:url(../flags/1x1/hk.svg)}.flag-icon-hm{background-image:url(../flags/4x3/hm.svg)}.flag-icon-hm.flag-icon-squared{background-image:url(../flags/1x1/hm.svg)}.flag-icon-hn{background-image:url(../flags/4x3/hn.svg)}.flag-icon-hn.flag-icon-squared{background-image:url(../flags/1x1/hn.svg)}.flag-icon-hr{background-image:url(../flags/4x3/hr.svg)}.flag-icon-hr.flag-icon-squared{background-image:url(../flags/1x1/hr.svg)}.flag-icon-ht{background-image:url(../flags/4x3/ht.svg)}.flag-icon-ht.flag-icon-squared{background-image:url(../flags/1x1/ht.svg)}.flag-icon-hu{background-image:url(../flags/4x3/hu.svg)}.flag-icon-hu.flag-icon-squared{background-image:url(../flags/1x1/hu.svg)}.flag-icon-id{background-image:url(../flags/4x3/id.svg)}.flag-icon-id.flag-icon-squared{background-image:url(../flags/1x1/id.svg)}.flag-icon-ie{background-image:url(../flags/4x3/ie.svg)}.flag-icon-ie.flag-icon-squared{background-image:url(../flags/1x1/ie.svg)}.flag-icon-il{background-image:url(../flags/4x3/il.svg)}.flag-icon-il.flag-icon-squared{background-image:url(../flags/1x1/il.svg)}.flag-icon-im{background-image:url(../flags/4x3/im.svg)}.flag-icon-im.flag-icon-squared{background-image:url(../flags/1x1/im.svg)}.flag-icon-in{background-image:url(../flags/4x3/in.svg)}.flag-icon-in.flag-icon-squared{background-image:url(../flags/1x1/in.svg)}.flag-icon-io{background-image:url(../flags/4x3/io.svg)}.flag-icon-io.flag-icon-squared{background-image:url(../flags/1x1/io.svg)}.flag-icon-iq{background-image:url(../flags/4x3/iq.svg)}.flag-icon-iq.flag-icon-squared{background-image:url(../flags/1x1/iq.svg)}.flag-icon-ir{background-image:url(../flags/4x3/ir.svg)}.flag-icon-ir.flag-icon-squared{background-image:url(../flags/1x1/ir.svg)}.flag-icon-is{background-image:url(../flags/4x3/is.svg)}.flag-icon-is.flag-icon-squared{background-image:url(../flags/1x1/is.svg)}.flag-icon-it{background-image:url(../flags/4x3/it.svg)}.flag-icon-it.flag-icon-squared{background-image:url(../flags/1x1/it.svg)}.flag-icon-je{background-image:url(../flags/4x3/je.svg)}.flag-icon-je.flag-icon-squared{background-image:url(../flags/1x1/je.svg)}.flag-icon-jm{background-image:url(../flags/4x3/jm.svg)}.flag-icon-jm.flag-icon-squared{background-image:url(../flags/1x1/jm.svg)}.flag-icon-jo{background-image:url(../flags/4x3/jo.svg)}.flag-icon-jo.flag-icon-squared{background-image:url(../flags/1x1/jo.svg)}.flag-icon-jp{background-image:url(../flags/4x3/jp.svg)}.flag-icon-jp.flag-icon-squared{background-image:url(../flags/1x1/jp.svg)}.flag-icon-ke{background-image:url(../flags/4x3/ke.svg)}.flag-icon-ke.flag-icon-squared{background-image:url(../flags/1x1/ke.svg)}.flag-icon-kg{background-image:url(../flags/4x3/kg.svg)}.flag-icon-kg.flag-icon-squared{background-image:url(../flags/1x1/kg.svg)}.flag-icon-kh{background-image:url(../flags/4x3/kh.svg)}.flag-icon-kh.flag-icon-squared{background-image:url(../flags/1x1/kh.svg)}.flag-icon-ki{background-image:url(../flags/4x3/ki.svg)}.flag-icon-ki.flag-icon-squared{background-image:url(../flags/1x1/ki.svg)}.flag-icon-km{background-image:url(../flags/4x3/km.svg)}.flag-icon-km.flag-icon-squared{background-image:url(../flags/1x1/km.svg)}.flag-icon-kn{background-image:url(../flags/4x3/kn.svg)}.flag-icon-kn.flag-icon-squared{background-image:url(../flags/1x1/kn.svg)}.flag-icon-kp{background-image:url(../flags/4x3/kp.svg)}.flag-icon-kp.flag-icon-squared{background-image:url(../flags/1x1/kp.svg)}.flag-icon-ko{background-image:url(../flags/4x3/ko.svg)}.flag-icon-ko.flag-icon-squared{background-image:url(../flags/1x1/ko.svg)}.flag-icon-kr{background-image:url(../flags/4x3/kr.svg)}.flag-icon-kr.flag-icon-squared{background-image:url(../flags/1x1/kr.svg)}.flag-icon-kw{background-image:url(../flags/4x3/kw.svg)}.flag-icon-kw.flag-icon-squared{background-image:url(../flags/1x1/kw.svg)}.flag-icon-ky{background-image:url(../flags/4x3/ky.svg)}.flag-icon-ky.flag-icon-squared{background-image:url(../flags/1x1/ky.svg)}.flag-icon-kz{background-image:url(../flags/4x3/kz.svg)}.flag-icon-kz.flag-icon-squared{background-image:url(../flags/1x1/kz.svg)}.flag-icon-la{background-image:url(../flags/4x3/la.svg)}.flag-icon-la.flag-icon-squared{background-image:url(../flags/1x1/la.svg)}.flag-icon-lb{background-image:url(../flags/4x3/lb.svg)}.flag-icon-lb.flag-icon-squared{background-image:url(../flags/1x1/lb.svg)}.flag-icon-lc{background-image:url(../flags/4x3/lc.svg)}.flag-icon-lc.flag-icon-squared{background-image:url(../flags/1x1/lc.svg)}.flag-icon-li{background-image:url(../flags/4x3/li.svg)}.flag-icon-li.flag-icon-squared{background-image:url(../flags/1x1/li.svg)}.flag-icon-lk{background-image:url(../flags/4x3/lk.svg)}.flag-icon-lk.flag-icon-squared{background-image:url(../flags/1x1/lk.svg)}.flag-icon-lr{background-image:url(../flags/4x3/lr.svg)}.flag-icon-lr.flag-icon-squared{background-image:url(../flags/1x1/lr.svg)}.flag-icon-ls{background-image:url(../flags/4x3/ls.svg)}.flag-icon-ls.flag-icon-squared{background-image:url(../flags/1x1/ls.svg)}.flag-icon-lt{background-image:url(../flags/4x3/lt.svg)}.flag-icon-lt.flag-icon-squared{background-image:url(../flags/1x1/lt.svg)}.flag-icon-lu{background-image:url(../flags/4x3/lu.svg)}.flag-icon-lu.flag-icon-squared{background-image:url(../flags/1x1/lu.svg)}.flag-icon-lv{background-image:url(../flags/4x3/lv.svg)}.flag-icon-lv.flag-icon-squared{background-image:url(../flags/1x1/lv.svg)}.flag-icon-ly{background-image:url(../flags/4x3/ly.svg)}.flag-icon-ly.flag-icon-squared{background-image:url(../flags/1x1/ly.svg)}.flag-icon-ma{background-image:url(../flags/4x3/ma.svg)}.flag-icon-ma.flag-icon-squared{background-image:url(../flags/1x1/ma.svg)}.flag-icon-mc{background-image:url(../flags/4x3/mc.svg)}.flag-icon-mc.flag-icon-squared{background-image:url(../flags/1x1/mc.svg)}.flag-icon-md{background-image:url(../flags/4x3/md.svg)}.flag-icon-md.flag-icon-squared{background-image:url(../flags/1x1/md.svg)}.flag-icon-me{background-image:url(../flags/4x3/me.svg)}.flag-icon-me.flag-icon-squared{background-image:url(../flags/1x1/me.svg)}.flag-icon-mf{background-image:url(../flags/4x3/mf.svg)}.flag-icon-mf.flag-icon-squared{background-image:url(../flags/1x1/mf.svg)}.flag-icon-mg{background-image:url(../flags/4x3/mg.svg)}.flag-icon-mg.flag-icon-squared{background-image:url(../flags/1x1/mg.svg)}.flag-icon-mh{background-image:url(../flags/4x3/mh.svg)}.flag-icon-mh.flag-icon-squared{background-image:url(../flags/1x1/mh.svg)}.flag-icon-mk{background-image:url(../flags/4x3/mk.svg)}.flag-icon-mk.flag-icon-squared{background-image:url(../flags/1x1/mk.svg)}.flag-icon-ml{background-image:url(../flags/4x3/ml.svg)}.flag-icon-ml.flag-icon-squared{background-image:url(../flags/1x1/ml.svg)}.flag-icon-mm{background-image:url(../flags/4x3/mm.svg)}.flag-icon-mm.flag-icon-squared{background-image:url(../flags/1x1/mm.svg)}.flag-icon-mn{background-image:url(../flags/4x3/mn.svg)}.flag-icon-mn.flag-icon-squared{background-image:url(../flags/1x1/mn.svg)}.flag-icon-mo{background-image:url(../flags/4x3/mo.svg)}.flag-icon-mo.flag-icon-squared{background-image:url(../flags/1x1/mo.svg)}.flag-icon-mp{background-image:url(../flags/4x3/mp.svg)}.flag-icon-mp.flag-icon-squared{background-image:url(../flags/1x1/mp.svg)}.flag-icon-mq{background-image:url(../flags/4x3/mq.svg)}.flag-icon-mq.flag-icon-squared{background-image:url(../flags/1x1/mq.svg)}.flag-icon-mr{background-image:url(../flags/4x3/mr.svg)}.flag-icon-mr.flag-icon-squared{background-image:url(../flags/1x1/mr.svg)}.flag-icon-ms{background-image:url(../flags/4x3/ms.svg)}.flag-icon-ms.flag-icon-squared{background-image:url(../flags/1x1/ms.svg)}.flag-icon-mt{background-image:url(../flags/4x3/mt.svg)}.flag-icon-mt.flag-icon-squared{background-image:url(../flags/1x1/mt.svg)}.flag-icon-mu{background-image:url(../flags/4x3/mu.svg)}.flag-icon-mu.flag-icon-squared{background-image:url(../flags/1x1/mu.svg)}.flag-icon-mv{background-image:url(../flags/4x3/mv.svg)}.flag-icon-mv.flag-icon-squared{background-image:url(../flags/1x1/mv.svg)}.flag-icon-mw{background-image:url(../flags/4x3/mw.svg)}.flag-icon-mw.flag-icon-squared{background-image:url(../flags/1x1/mw.svg)}.flag-icon-mx{background-image:url(../flags/4x3/mx.svg)}.flag-icon-mx.flag-icon-squared{background-image:url(../flags/1x1/mx.svg)}.flag-icon-my{background-image:url(../flags/4x3/my.svg)}.flag-icon-my.flag-icon-squared{background-image:url(../flags/1x1/my.svg)}.flag-icon-mz{background-image:url(../flags/4x3/mz.svg)}.flag-icon-mz.flag-icon-squared{background-image:url(../flags/1x1/mz.svg)}.flag-icon-na{background-image:url(../flags/4x3/na.svg)}.flag-icon-na.flag-icon-squared{background-image:url(../flags/1x1/na.svg)}.flag-icon-nc{background-image:url(../flags/4x3/nc.svg)}.flag-icon-nc.flag-icon-squared{background-image:url(../flags/1x1/nc.svg)}.flag-icon-ne{background-image:url(../flags/4x3/ne.svg)}.flag-icon-ne.flag-icon-squared{background-image:url(../flags/1x1/ne.svg)}.flag-icon-nf{background-image:url(../flags/4x3/nf.svg)}.flag-icon-nf.flag-icon-squared{background-image:url(../flags/1x1/nf.svg)}.flag-icon-ng{background-image:url(../flags/4x3/ng.svg)}.flag-icon-ng.flag-icon-squared{background-image:url(../flags/1x1/ng.svg)}.flag-icon-ni{background-image:url(../flags/4x3/ni.svg)}.flag-icon-ni.flag-icon-squared{background-image:url(../flags/1x1/ni.svg)}.flag-icon-nl{background-image:url(../flags/4x3/nl.svg)}.flag-icon-nl.flag-icon-squared{background-image:url(../flags/1x1/nl.svg)}.flag-icon-no{background-image:url(../flags/4x3/no.svg)}.flag-icon-no.flag-icon-squared{background-image:url(../flags/1x1/no.svg)}.flag-icon-np{background-image:url(../flags/4x3/np.svg)}.flag-icon-np.flag-icon-squared{background-image:url(../flags/1x1/np.svg)}.flag-icon-nr{background-image:url(../flags/4x3/nr.svg)}.flag-icon-nr.flag-icon-squared{background-image:url(../flags/1x1/nr.svg)}.flag-icon-nu{background-image:url(../flags/4x3/nu.svg)}.flag-icon-nu.flag-icon-squared{background-image:url(../flags/1x1/nu.svg)}.flag-icon-nz{background-image:url(../flags/4x3/nz.svg)}.flag-icon-nz.flag-icon-squared{background-image:url(../flags/1x1/nz.svg)}.flag-icon-om{background-image:url(../flags/4x3/om.svg)}.flag-icon-om.flag-icon-squared{background-image:url(../flags/1x1/om.svg)}.flag-icon-pa{background-image:url(../flags/4x3/pa.svg)}.flag-icon-pa.flag-icon-squared{background-image:url(../flags/1x1/pa.svg)}.flag-icon-pe{background-image:url(../flags/4x3/pe.svg)}.flag-icon-pe.flag-icon-squared{background-image:url(../flags/1x1/pe.svg)}.flag-icon-pf{background-image:url(../flags/4x3/pf.svg)}.flag-icon-pf.flag-icon-squared{background-image:url(../flags/1x1/pf.svg)}.flag-icon-pg{background-image:url(../flags/4x3/pg.svg)}.flag-icon-pg.flag-icon-squared{background-image:url(../flags/1x1/pg.svg)}.flag-icon-ph{background-image:url(../flags/4x3/ph.svg)}.flag-icon-ph.flag-icon-squared{background-image:url(../flags/1x1/ph.svg)}.flag-icon-pk{background-image:url(../flags/4x3/pk.svg)}.flag-icon-pk.flag-icon-squared{background-image:url(../flags/1x1/pk.svg)}.flag-icon-pl{background-image:url(../flags/4x3/pl.svg)}.flag-icon-pl.flag-icon-squared{background-image:url(../flags/1x1/pl.svg)}.flag-icon-pm{background-image:url(../flags/4x3/pm.svg)}.flag-icon-pm.flag-icon-squared{background-image:url(../flags/1x1/pm.svg)}.flag-icon-pn{background-image:url(../flags/4x3/pn.svg)}.flag-icon-pn.flag-icon-squared{background-image:url(../flags/1x1/pn.svg)}.flag-icon-pr{background-image:url(../flags/4x3/pr.svg)}.flag-icon-pr.flag-icon-squared{background-image:url(../flags/1x1/pr.svg)}.flag-icon-ps{background-image:url(../flags/4x3/ps.svg)}.flag-icon-ps.flag-icon-squared{background-image:url(../flags/1x1/ps.svg)}.flag-icon-pt{background-image:url(../flags/4x3/pt.svg)}.flag-icon-pt.flag-icon-squared{background-image:url(../flags/1x1/pt.svg)}.flag-icon-pw{background-image:url(../flags/4x3/pw.svg)}.flag-icon-pw.flag-icon-squared{background-image:url(../flags/1x1/pw.svg)}.flag-icon-py{background-image:url(../flags/4x3/py.svg)}.flag-icon-py.flag-icon-squared{background-image:url(../flags/1x1/py.svg)}.flag-icon-qa{background-image:url(../flags/4x3/qa.svg)}.flag-icon-qa.flag-icon-squared{background-image:url(../flags/1x1/qa.svg)}.flag-icon-re{background-image:url(../flags/4x3/re.svg)}.flag-icon-re.flag-icon-squared{background-image:url(../flags/1x1/re.svg)}.flag-icon-ro{background-image:url(../flags/4x3/ro.svg)}.flag-icon-ro.flag-icon-squared{background-image:url(../flags/1x1/ro.svg)}.flag-icon-rs{background-image:url(../flags/4x3/rs.svg)}.flag-icon-rs.flag-icon-squared{background-image:url(../flags/1x1/rs.svg)}.flag-icon-ru{background-image:url(../flags/4x3/ru.svg)}.flag-icon-ru.flag-icon-squared{background-image:url(../flags/1x1/ru.svg)}.flag-icon-rw{background-image:url(../flags/4x3/rw.svg)}.flag-icon-rw.flag-icon-squared{background-image:url(../flags/1x1/rw.svg)}.flag-icon-sa{background-image:url(../flags/4x3/sa.svg)}.flag-icon-sa.flag-icon-squared{background-image:url(../flags/1x1/sa.svg)}.flag-icon-sb{background-image:url(../flags/4x3/sb.svg)}.flag-icon-sb.flag-icon-squared{background-image:url(../flags/1x1/sb.svg)}.flag-icon-sc{background-image:url(../flags/4x3/sc.svg)}.flag-icon-sc.flag-icon-squared{background-image:url(../flags/1x1/sc.svg)}.flag-icon-sd{background-image:url(../flags/4x3/sd.svg)}.flag-icon-sd.flag-icon-squared{background-image:url(../flags/1x1/sd.svg)}.flag-icon-se{background-image:url(../flags/4x3/se.svg)}.flag-icon-se.flag-icon-squared{background-image:url(../flags/1x1/se.svg)}.flag-icon-sg{background-image:url(../flags/4x3/sg.svg)}.flag-icon-sg.flag-icon-squared{background-image:url(../flags/1x1/sg.svg)}.flag-icon-sh{background-image:url(../flags/4x3/sh.svg)}.flag-icon-sh.flag-icon-squared{background-image:url(../flags/1x1/sh.svg)}.flag-icon-si{background-image:url(../flags/4x3/si.svg)}.flag-icon-si.flag-icon-squared{background-image:url(../flags/1x1/si.svg)}.flag-icon-sj{background-image:url(../flags/4x3/sj.svg)}.flag-icon-sj.flag-icon-squared{background-image:url(../flags/1x1/sj.svg)}.flag-icon-sk{background-image:url(../flags/4x3/sk.svg)}.flag-icon-sk.flag-icon-squared{background-image:url(../flags/1x1/sk.svg)}.flag-icon-sl{background-image:url(../flags/4x3/sl.svg)}.flag-icon-sl.flag-icon-squared{background-image:url(../flags/1x1/sl.svg)}.flag-icon-sm{background-image:url(../flags/4x3/sm.svg)}.flag-icon-sm.flag-icon-squared{background-image:url(../flags/1x1/sm.svg)}.flag-icon-sn{background-image:url(../flags/4x3/sn.svg)}.flag-icon-sn.flag-icon-squared{background-image:url(../flags/1x1/sn.svg)}.flag-icon-so{background-image:url(../flags/4x3/so.svg)}.flag-icon-so.flag-icon-squared{background-image:url(../flags/1x1/so.svg)}.flag-icon-sr{background-image:url(../flags/4x3/sr.svg)}.flag-icon-sr.flag-icon-squared{background-image:url(../flags/1x1/sr.svg)}.flag-icon-ss{background-image:url(../flags/4x3/ss.svg)}.flag-icon-ss.flag-icon-squared{background-image:url(../flags/1x1/ss.svg)}.flag-icon-st{background-image:url(../flags/4x3/st.svg)}.flag-icon-st.flag-icon-squared{background-image:url(../flags/1x1/st.svg)}.flag-icon-sv{background-image:url(../flags/4x3/sv.svg)}.flag-icon-sv.flag-icon-squared{background-image:url(../flags/1x1/sv.svg)}.flag-icon-sx{background-image:url(../flags/4x3/sx.svg)}.flag-icon-sx.flag-icon-squared{background-image:url(../flags/1x1/sx.svg)}.flag-icon-sy{background-image:url(../flags/4x3/sy.svg)}.flag-icon-sy.flag-icon-squared{background-image:url(../flags/1x1/sy.svg)}.flag-icon-sz{background-image:url(../flags/4x3/sz.svg)}.flag-icon-sz.flag-icon-squared{background-image:url(../flags/1x1/sz.svg)}.flag-icon-tc{background-image:url(../flags/4x3/tc.svg)}.flag-icon-tc.flag-icon-squared{background-image:url(../flags/1x1/tc.svg)}.flag-icon-td{background-image:url(../flags/4x3/td.svg)}.flag-icon-td.flag-icon-squared{background-image:url(../flags/1x1/td.svg)}.flag-icon-tf{background-image:url(../flags/4x3/tf.svg)}.flag-icon-tf.flag-icon-squared{background-image:url(../flags/1x1/tf.svg)}.flag-icon-tg{background-image:url(../flags/4x3/tg.svg)}.flag-icon-tg.flag-icon-squared{background-image:url(../flags/1x1/tg.svg)}.flag-icon-th{background-image:url(../flags/4x3/th.svg)}.flag-icon-th.flag-icon-squared{background-image:url(../flags/1x1/th.svg)}.flag-icon-tj{background-image:url(../flags/4x3/tj.svg)}.flag-icon-tj.flag-icon-squared{background-image:url(../flags/1x1/tj.svg)}.flag-icon-tk{background-image:url(../flags/4x3/tk.svg)}.flag-icon-tk.flag-icon-squared{background-image:url(../flags/1x1/tk.svg)}.flag-icon-tl{background-image:url(../flags/4x3/tl.svg)}.flag-icon-tl.flag-icon-squared{background-image:url(../flags/1x1/tl.svg)}.flag-icon-tm{background-image:url(../flags/4x3/tm.svg)}.flag-icon-tm.flag-icon-squared{background-image:url(../flags/1x1/tm.svg)}.flag-icon-tn{background-image:url(../flags/4x3/tn.svg)}.flag-icon-tn.flag-icon-squared{background-image:url(../flags/1x1/tn.svg)}.flag-icon-to{background-image:url(../flags/4x3/to.svg)}.flag-icon-to.flag-icon-squared{background-image:url(../flags/1x1/to.svg)}.flag-icon-tr{background-image:url(../flags/4x3/tr.svg)}.flag-icon-tr.flag-icon-squared{background-image:url(../flags/1x1/tr.svg)}.flag-icon-tt{background-image:url(../flags/4x3/tt.svg)}.flag-icon-tt.flag-icon-squared{background-image:url(../flags/1x1/tt.svg)}.flag-icon-tv{background-image:url(../flags/4x3/tv.svg)}.flag-icon-tv.flag-icon-squared{background-image:url(../flags/1x1/tv.svg)}.flag-icon-tw{background-image:url(../flags/4x3/tw.svg)}.flag-icon-tw.flag-icon-squared{background-image:url(../flags/1x1/tw.svg)}.flag-icon-tz{background-image:url(../flags/4x3/tz.svg)}.flag-icon-tz.flag-icon-squared{background-image:url(../flags/1x1/tz.svg)}.flag-icon-ua{background-image:url(../flags/4x3/ua.svg)}.flag-icon-ua.flag-icon-squared{background-image:url(../flags/1x1/ua.svg)}.flag-icon-ug{background-image:url(../flags/4x3/ug.svg)}.flag-icon-ug.flag-icon-squared{background-image:url(../flags/1x1/ug.svg)}.flag-icon-um{background-image:url(../flags/4x3/um.svg)}.flag-icon-um.flag-icon-squared{background-image:url(../flags/1x1/um.svg)}.flag-icon-us{background-image:url(../flags/4x3/us.svg)}.flag-icon-us.flag-icon-squared{background-image:url(../flags/1x1/us.svg)}.flag-icon-uy{background-image:url(../flags/4x3/uy.svg)}.flag-icon-uy.flag-icon-squared{background-image:url(../flags/1x1/uy.svg)}.flag-icon-uz{background-image:url(../flags/4x3/uz.svg)}.flag-icon-uz.flag-icon-squared{background-image:url(../flags/1x1/uz.svg)}.flag-icon-va{background-image:url(../flags/4x3/va.svg)}.flag-icon-va.flag-icon-squared{background-image:url(../flags/1x1/va.svg)}.flag-icon-vc{background-image:url(../flags/4x3/vc.svg)}.flag-icon-vc.flag-icon-squared{background-image:url(../flags/1x1/vc.svg)}.flag-icon-ve{background-image:url(../flags/4x3/ve.svg)}.flag-icon-ve.flag-icon-squared{background-image:url(../flags/1x1/ve.svg)}.flag-icon-vg{background-image:url(../flags/4x3/vg.svg)}.flag-icon-vg.flag-icon-squared{background-image:url(../flags/1x1/vg.svg)}.flag-icon-vi{background-image:url(../flags/4x3/vi.svg)}.flag-icon-vi.flag-icon-squared{background-image:url(../flags/1x1/vi.svg)}.flag-icon-vn{background-image:url(../flags/4x3/vn.svg)}.flag-icon-vn.flag-icon-squared{background-image:url(../flags/1x1/vn.svg)}.flag-icon-vu{background-image:url(../flags/4x3/vu.svg)}.flag-icon-vu.flag-icon-squared{background-image:url(../flags/1x1/vu.svg)}.flag-icon-wf{background-image:url(../flags/4x3/wf.svg)}.flag-icon-wf.flag-icon-squared{background-image:url(../flags/1x1/wf.svg)}.flag-icon-ws{background-image:url(../flags/4x3/ws.svg)}.flag-icon-ws.flag-icon-squared{background-image:url(../flags/1x1/ws.svg)}.flag-icon-ye{background-image:url(../flags/4x3/ye.svg)}.flag-icon-ye.flag-icon-squared{background-image:url(../flags/1x1/ye.svg)}.flag-icon-yt{background-image:url(../flags/4x3/yt.svg)}.flag-icon-yt.flag-icon-squared{background-image:url(../flags/1x1/yt.svg)}.flag-icon-za{background-image:url(../flags/4x3/za.svg)}.flag-icon-za.flag-icon-squared{background-image:url(../flags/1x1/za.svg)}.flag-icon-zm{background-image:url(../flags/4x3/zm.svg)}.flag-icon-zm.flag-icon-squared{background-image:url(../flags/1x1/zm.svg)}.flag-icon-zw{background-image:url(../flags/4x3/zw.svg)}.flag-icon-zw.flag-icon-squared{background-image:url(../flags/1x1/zw.svg)}.flag-icon-es-ct{background-image:url(../flags/4x3/es-ct.svg)}.flag-icon-es-ct.flag-icon-squared{background-image:url(../flags/1x1/es-ct.svg)}.flag-icon-es-ga{background-image:url(../flags/4x3/es-ga.svg)}.flag-icon-es-ga.flag-icon-squared{background-image:url(../flags/1x1/es-ga.svg)}.flag-icon-eu{background-image:url(../flags/4x3/eu.svg)}.flag-icon-eu.flag-icon-squared{background-image:url(../flags/1x1/eu.svg)}.flag-icon-gb-eng{background-image:url(../flags/4x3/gb-eng.svg)}.flag-icon-gb-eng.flag-icon-squared{background-image:url(../flags/1x1/gb-eng.svg)}.flag-icon-gb-nir{background-image:url(../flags/4x3/gb-nir.svg)}.flag-icon-gb-nir.flag-icon-squared{background-image:url(../flags/1x1/gb-nir.svg)}.flag-icon-gb-sct{background-image:url(../flags/4x3/gb-sct.svg)}.flag-icon-gb-sct.flag-icon-squared{background-image:url(../flags/1x1/gb-sct.svg)}.flag-icon-gb-wls{background-image:url(../flags/4x3/gb-wls.svg)}.flag-icon-gb-wls.flag-icon-squared{background-image:url(../flags/1x1/gb-wls.svg)}.flag-icon-un{background-image:url(../flags/4x3/un.svg)}.flag-icon-un.flag-icon-squared{background-image:url(../flags/1x1/un.svg)}.flag-icon-xk{background-image:url(../flags/4x3/xk.svg)}.flag-icon-xk.flag-icon-squared{background-image:url(../flags/1x1/xk.svg)}
+.flag-icon-background{background-size:contain;background-position:50%;background-repeat:no-repeat}.flag-icon{background-size:contain;background-position:50%;background-repeat:no-repeat;position:relative;display:inline-block;width:1.33333333em;line-height:1em}.flag-icon:before{content:'\00a0'}.flag-icon.flag-icon-squared{width:1em}.flag-icon-ad{background-image:url(/css/flags/4x3/ad.svg)}.flag-icon-ad.flag-icon-squared{background-image:url(/css/flags/1x1/ad.svg)}.flag-icon-ae{background-image:url(/css/flags/4x3/ae.svg)}.flag-icon-ae.flag-icon-squared{background-image:url(/css/flags/1x1/ae.svg)}.flag-icon-af{background-image:url(/css/flags/4x3/af.svg)}.flag-icon-af.flag-icon-squared{background-image:url(/css/flags/1x1/af.svg)}.flag-icon-ag{background-image:url(/css/flags/4x3/ag.svg)}.flag-icon-ag.flag-icon-squared{background-image:url(/css/flags/1x1/ag.svg)}.flag-icon-ai{background-image:url(/css/flags/4x3/ai.svg)}.flag-icon-ai.flag-icon-squared{background-image:url(/css/flags/1x1/ai.svg)}.flag-icon-al{background-image:url(/css/flags/4x3/al.svg)}.flag-icon-al.flag-icon-squared{background-image:url(/css/flags/1x1/al.svg)}.flag-icon-am{background-image:url(/css/flags/4x3/am.svg)}.flag-icon-am.flag-icon-squared{background-image:url(/css/flags/1x1/am.svg)}.flag-icon-ao{background-image:url(/css/flags/4x3/ao.svg)}.flag-icon-ao.flag-icon-squared{background-image:url(/css/flags/1x1/ao.svg)}.flag-icon-aq{background-image:url(/css/flags/4x3/aq.svg)}.flag-icon-aq.flag-icon-squared{background-image:url(/css/flags/1x1/aq.svg)}.flag-icon-ar{background-image:url(/css/flags/4x3/ar.svg)}.flag-icon-ar.flag-icon-squared{background-image:url(/css/flags/1x1/ar.svg)}.flag-icon-as{background-image:url(/css/flags/4x3/as.svg)}.flag-icon-as.flag-icon-squared{background-image:url(/css/flags/1x1/as.svg)}.flag-icon-at{background-image:url(/css/flags/4x3/at.svg)}.flag-icon-at.flag-icon-squared{background-image:url(/css/flags/1x1/at.svg)}.flag-icon-au{background-image:url(/css/flags/4x3/au.svg)}.flag-icon-au.flag-icon-squared{background-image:url(/css/flags/1x1/au.svg)}.flag-icon-aw{background-image:url(/css/flags/4x3/aw.svg)}.flag-icon-aw.flag-icon-squared{background-image:url(/css/flags/1x1/aw.svg)}.flag-icon-ax{background-image:url(/css/flags/4x3/ax.svg)}.flag-icon-ax.flag-icon-squared{background-image:url(/css/flags/1x1/ax.svg)}.flag-icon-az{background-image:url(/css/flags/4x3/az.svg)}.flag-icon-az.flag-icon-squared{background-image:url(/css/flags/1x1/az.svg)}.flag-icon-ba{background-image:url(/css/flags/4x3/ba.svg)}.flag-icon-ba.flag-icon-squared{background-image:url(/css/flags/1x1/ba.svg)}.flag-icon-bb{background-image:url(/css/flags/4x3/bb.svg)}.flag-icon-bb.flag-icon-squared{background-image:url(/css/flags/1x1/bb.svg)}.flag-icon-bd{background-image:url(/css/flags/4x3/bd.svg)}.flag-icon-bd.flag-icon-squared{background-image:url(/css/flags/1x1/bd.svg)}.flag-icon-be{background-image:url(/css/flags/4x3/be.svg)}.flag-icon-be.flag-icon-squared{background-image:url(/css/flags/1x1/be.svg)}.flag-icon-bf{background-image:url(/css/flags/4x3/bf.svg)}.flag-icon-bf.flag-icon-squared{background-image:url(/css/flags/1x1/bf.svg)}.flag-icon-bg{background-image:url(/css/flags/4x3/bg.svg)}.flag-icon-bg.flag-icon-squared{background-image:url(/css/flags/1x1/bg.svg)}.flag-icon-bh{background-image:url(/css/flags/4x3/bh.svg)}.flag-icon-bh.flag-icon-squared{background-image:url(/css/flags/1x1/bh.svg)}.flag-icon-bi{background-image:url(/css/flags/4x3/bi.svg)}.flag-icon-bi.flag-icon-squared{background-image:url(/css/flags/1x1/bi.svg)}.flag-icon-bj{background-image:url(/css/flags/4x3/bj.svg)}.flag-icon-bj.flag-icon-squared{background-image:url(/css/flags/1x1/bj.svg)}.flag-icon-bl{background-image:url(/css/flags/4x3/bl.svg)}.flag-icon-bl.flag-icon-squared{background-image:url(/css/flags/1x1/bl.svg)}.flag-icon-bm{background-image:url(/css/flags/4x3/bm.svg)}.flag-icon-bm.flag-icon-squared{background-image:url(/css/flags/1x1/bm.svg)}.flag-icon-bn{background-image:url(/css/flags/4x3/bn.svg)}.flag-icon-bn.flag-icon-squared{background-image:url(/css/flags/1x1/bn.svg)}.flag-icon-bo{background-image:url(/css/flags/4x3/bo.svg)}.flag-icon-bo.flag-icon-squared{background-image:url(/css/flags/1x1/bo.svg)}.flag-icon-bq{background-image:url(/css/flags/4x3/bq.svg)}.flag-icon-bq.flag-icon-squared{background-image:url(/css/flags/1x1/bq.svg)}.flag-icon-br{background-image:url(/css/flags/4x3/br.svg)}.flag-icon-br.flag-icon-squared{background-image:url(/css/flags/1x1/br.svg)}.flag-icon-bs{background-image:url(/css/flags/4x3/bs.svg)}.flag-icon-bs.flag-icon-squared{background-image:url(/css/flags/1x1/bs.svg)}.flag-icon-bt{background-image:url(/css/flags/4x3/bt.svg)}.flag-icon-bt.flag-icon-squared{background-image:url(/css/flags/1x1/bt.svg)}.flag-icon-bv{background-image:url(/css/flags/4x3/bv.svg)}.flag-icon-bv.flag-icon-squared{background-image:url(/css/flags/1x1/bv.svg)}.flag-icon-bw{background-image:url(/css/flags/4x3/bw.svg)}.flag-icon-bw.flag-icon-squared{background-image:url(/css/flags/1x1/bw.svg)}.flag-icon-by{background-image:url(/css/flags/4x3/by.svg)}.flag-icon-by.flag-icon-squared{background-image:url(/css/flags/1x1/by.svg)}.flag-icon-bz{background-image:url(/css/flags/4x3/bz.svg)}.flag-icon-bz.flag-icon-squared{background-image:url(/css/flags/1x1/bz.svg)}.flag-icon-ca{background-image:url(/css/flags/4x3/ca.svg)}.flag-icon-ca.flag-icon-squared{background-image:url(/css/flags/1x1/ca.svg)}.flag-icon-cc{background-image:url(/css/flags/4x3/cc.svg)}.flag-icon-cc.flag-icon-squared{background-image:url(/css/flags/1x1/cc.svg)}.flag-icon-cd{background-image:url(/css/flags/4x3/cd.svg)}.flag-icon-cd.flag-icon-squared{background-image:url(/css/flags/1x1/cd.svg)}.flag-icon-cf{background-image:url(/css/flags/4x3/cf.svg)}.flag-icon-cf.flag-icon-squared{background-image:url(/css/flags/1x1/cf.svg)}.flag-icon-cg{background-image:url(/css/flags/4x3/cg.svg)}.flag-icon-cg.flag-icon-squared{background-image:url(/css/flags/1x1/cg.svg)}.flag-icon-ch{background-image:url(/css/flags/4x3/ch.svg)}.flag-icon-ch.flag-icon-squared{background-image:url(/css/flags/1x1/ch.svg)}.flag-icon-ci{background-image:url(/css/flags/4x3/ci.svg)}.flag-icon-ci.flag-icon-squared{background-image:url(/css/flags/1x1/ci.svg)}.flag-icon-ck{background-image:url(/css/flags/4x3/ck.svg)}.flag-icon-ck.flag-icon-squared{background-image:url(/css/flags/1x1/ck.svg)}.flag-icon-cl{background-image:url(/css/flags/4x3/cl.svg)}.flag-icon-cl.flag-icon-squared{background-image:url(/css/flags/1x1/cl.svg)}.flag-icon-cm{background-image:url(/css/flags/4x3/cm.svg)}.flag-icon-cm.flag-icon-squared{background-image:url(/css/flags/1x1/cm.svg)}.flag-icon-zh{background-image:url(/css/flags/4x3/zh.svg)}.flag-iconzh.flag-icon-squared{background-image:url(/css/flags/1x1/zh.svg)}.flag-icon-cn{background-image:url(/css/flags/4x3/cn.svg)}.flag-icon-cn.flag-icon-squared{background-image:url(/css/flags/1x1/cn.svg)}.flag-icon-co{background-image:url(/css/flags/4x3/co.svg)}.flag-icon-co.flag-icon-squared{background-image:url(/css/flags/1x1/co.svg)}.flag-icon-cr{background-image:url(/css/flags/4x3/cr.svg)}.flag-icon-cr.flag-icon-squared{background-image:url(/css/flags/1x1/cr.svg)}.flag-icon-cu{background-image:url(/css/flags/4x3/cu.svg)}.flag-icon-cu.flag-icon-squared{background-image:url(/css/flags/1x1/cu.svg)}.flag-icon-cv{background-image:url(/css/flags/4x3/cv.svg)}.flag-icon-cv.flag-icon-squared{background-image:url(/css/flags/1x1/cv.svg)}.flag-icon-cw{background-image:url(/css/flags/4x3/cw.svg)}.flag-icon-cw.flag-icon-squared{background-image:url(/css/flags/1x1/cw.svg)}.flag-icon-cx{background-image:url(/css/flags/4x3/cx.svg)}.flag-icon-cx.flag-icon-squared{background-image:url(/css/flags/1x1/cx.svg)}.flag-icon-cy{background-image:url(/css/flags/4x3/cy.svg)}.flag-icon-cy.flag-icon-squared{background-image:url(/css/flags/1x1/cy.svg)}.flag-icon-cz{background-image:url(/css/flags/4x3/cz.svg)}.flag-icon-cz.flag-icon-squared{background-image:url(/css/flags/1x1/cz.svg)}.flag-icon-cs{background-image:url(/css/flags/4x3/cs.svg)}.flag-icon-cs.flag-icon-squared{background-image:url(/css/flags/1x1/cs.svg)}.flag-icon-de{background-image:url(/css/flags/4x3/de.svg)}.flag-icon-de.flag-icon-squared{background-image:url(/css/flags/1x1/de.svg)}.flag-icon-dj{background-image:url(/css/flags/4x3/dj.svg)}.flag-icon-dj.flag-icon-squared{background-image:url(/css/flags/1x1/dj.svg)}.flag-icon-da{background-image:url(/css/flags/4x3/da.svg)}.flag-icon-da.flag-icon-squared{background-image:url(/css/flags/1x1/d.svg)}.flag-icon-dk{background-image:url(/css/flags/4x3/dk.svg)}.flag-icon-dk.flag-icon-squared{background-image:url(/css/flags/1x1/dk.svg)}.flag-icon-dm{background-image:url(/css/flags/4x3/dm.svg)}.flag-icon-dm.flag-icon-squared{background-image:url(/css/flags/1x1/dm.svg)}.flag-icon-do{background-image:url(/css/flags/4x3/do.svg)}.flag-icon-do.flag-icon-squared{background-image:url(/css/flags/1x1/do.svg)}.flag-icon-dz{background-image:url(/css/flags/4x3/dz.svg)}.flag-icon-dz.flag-icon-squared{background-image:url(/css/flags/1x1/dz.svg)}.flag-icon-ec{background-image:url(/css/flags/4x3/ec.svg)}.flag-icon-ec.flag-icon-squared{background-image:url(/css/flags/1x1/ec.svg)}.flag-icon-ee{background-image:url(/css/flags/4x3/ee.svg)}.flag-icon-ee.flag-icon-squared{background-image:url(/css/flags/1x1/ee.svg)}.flag-icon-eg{background-image:url(/css/flags/4x3/eg.svg)}.flag-icon-eg.flag-icon-squared{background-image:url(/css/flags/1x1/eg.svg)}.flag-icon-eh{background-image:url(/css/flags/4x3/eh.svg)}.flag-icon-eh.flag-icon-squared{background-image:url(/css/flags/1x1/eh.svg)}.flag-icon-er{background-image:url(/css/flags/4x3/er.svg)}.flag-icon-er.flag-icon-squared{background-image:url(/css/flags/1x1/er.svg)}.flag-icon-es{background-image:url(/css/flags/4x3/es.svg)}.flag-icon-es.flag-icon-squared{background-image:url(/css/flags/1x1/es.svg)}.flag-icon-et{background-image:url(/css/flags/4x3/et.svg)}.flag-icon-et.flag-icon-squared{background-image:url(/css/flags/1x1/et.svg)}.flag-icon-fi{background-image:url(/css/flags/4x3/fi.svg)}.flag-icon-fi.flag-icon-squared{background-image:url(/css/flags/1x1/fi.svg)}.flag-icon-fj{background-image:url(/css/flags/4x3/fj.svg)}.flag-icon-fj.flag-icon-squared{background-image:url(/css/flags/1x1/fj.svg)}.flag-icon-fk{background-image:url(/css/flags/4x3/fk.svg)}.flag-icon-fk.flag-icon-squared{background-image:url(/css/flags/1x1/fk.svg)}.flag-icon-fm{background-image:url(/css/flags/4x3/fm.svg)}.flag-icon-fm.flag-icon-squared{background-image:url(/css/flags/1x1/fm.svg)}.flag-icon-fo{background-image:url(/css/flags/4x3/fo.svg)}.flag-icon-fo.flag-icon-squared{background-image:url(/css/flags/1x1/fo.svg)}.flag-icon-fr{background-image:url(/css/flags/4x3/fr.svg)}.flag-icon-fr.flag-icon-squared{background-image:url(/css/flags/1x1/fr.svg)}.flag-icon-ga{background-image:url(/css/flags/4x3/ga.svg)}.flag-icon-ga.flag-icon-squared{background-image:url(/css/flags/1x1/ga.svg)}.flag-icon-gb{background-image:url(/css/flags/4x3/en.svg)}.flag-icon-gb.flag-icon-squared{background-image:url(/css/flags/1x1/en.svg)}.flag-icon-gd{background-image:url(/css/flags/4x3/gd.svg)}.flag-icon-gd.flag-icon-squared{background-image:url(/css/flags/1x1/gd.svg)}.flag-icon-ge{background-image:url(/css/flags/4x3/ge.svg)}.flag-icon-ge.flag-icon-squared{background-image:url(/css/flags/1x1/ge.svg)}.flag-icon-gf{background-image:url(/css/flags/4x3/gf.svg)}.flag-icon-gf.flag-icon-squared{background-image:url(/css/flags/1x1/gf.svg)}.flag-icon-gg{background-image:url(/css/flags/4x3/gg.svg)}.flag-icon-gg.flag-icon-squared{background-image:url(/css/flags/1x1/gg.svg)}.flag-icon-gh{background-image:url(/css/flags/4x3/gh.svg)}.flag-icon-gh.flag-icon-squared{background-image:url(/css/flags/1x1/gh.svg)}.flag-icon-gi{background-image:url(/css/flags/4x3/gi.svg)}.flag-icon-gi.flag-icon-squared{background-image:url(/css/flags/1x1/gi.svg)}.flag-icon-gl{background-image:url(/css/flags/4x3/gl.svg)}.flag-icon-gl.flag-icon-squared{background-image:url(/css/flags/1x1/gl.svg)}.flag-icon-gm{background-image:url(/css/flags/4x3/gm.svg)}.flag-icon-gm.flag-icon-squared{background-image:url(/css/flags/1x1/gm.svg)}.flag-icon-gn{background-image:url(/css/flags/4x3/gn.svg)}.flag-icon-gn.flag-icon-squared{background-image:url(/css/flags/1x1/gn.svg)}.flag-icon-gp{background-image:url(/css/flags/4x3/gp.svg)}.flag-icon-gp.flag-icon-squared{background-image:url(/css/flags/1x1/gp.svg)}.flag-icon-gq{background-image:url(/css/flags/4x3/gq.svg)}.flag-icon-gq.flag-icon-squared{background-image:url(/css/flags/1x1/gq.svg)}.flag-icon-gr{background-image:url(/css/flags/4x3/gr.svg)}.flag-icon-gr.flag-icon-squared{background-image:url(/css/flags/1x1/gr.svg)}.flag-icon-gs{background-image:url(/css/flags/4x3/gs.svg)}.flag-icon-gs.flag-icon-squared{background-image:url(/css/flags/1x1/gs.svg)}.flag-icon-gt{background-image:url(/css/flags/4x3/gt.svg)}.flag-icon-gt.flag-icon-squared{background-image:url(/css/flags/1x1/gt.svg)}.flag-icon-gu{background-image:url(/css/flags/4x3/gu.svg)}.flag-icon-gu.flag-icon-squared{background-image:url(/css/flags/1x1/gu.svg)}.flag-icon-gw{background-image:url(/css/flags/4x3/gw.svg)}.flag-icon-gw.flag-icon-squared{background-image:url(/css/flags/1x1/gw.svg)}.flag-icon-gy{background-image:url(/css/flags/4x3/gy.svg)}.flag-icon-gy.flag-icon-squared{background-image:url(/css/flags/1x1/gy.svg)}.flag-icon-hk{background-image:url(/css/flags/4x3/hk.svg)}.flag-icon-hk.flag-icon-squared{background-image:url(/css/flags/1x1/hk.svg)}.flag-icon-hm{background-image:url(/css/flags/4x3/hm.svg)}.flag-icon-hm.flag-icon-squared{background-image:url(/css/flags/1x1/hm.svg)}.flag-icon-hn{background-image:url(/css/flags/4x3/hn.svg)}.flag-icon-hn.flag-icon-squared{background-image:url(/css/flags/1x1/hn.svg)}.flag-icon-hr{background-image:url(/css/flags/4x3/hr.svg)}.flag-icon-hr.flag-icon-squared{background-image:url(/css/flags/1x1/hr.svg)}.flag-icon-ht{background-image:url(/css/flags/4x3/ht.svg)}.flag-icon-ht.flag-icon-squared{background-image:url(/css/flags/1x1/ht.svg)}.flag-icon-hu{background-image:url(/css/flags/4x3/hu.svg)}.flag-icon-hu.flag-icon-squared{background-image:url(/css/flags/1x1/hu.svg)}.flag-icon-id{background-image:url(/css/flags/4x3/id.svg)}.flag-icon-id.flag-icon-squared{background-image:url(/css/flags/1x1/id.svg)}.flag-icon-ie{background-image:url(/css/flags/4x3/ie.svg)}.flag-icon-ie.flag-icon-squared{background-image:url(/css/flags/1x1/ie.svg)}.flag-icon-il{background-image:url(/css/flags/4x3/il.svg)}.flag-icon-il.flag-icon-squared{background-image:url(/css/flags/1x1/il.svg)}.flag-icon-im{background-image:url(/css/flags/4x3/im.svg)}.flag-icon-im.flag-icon-squared{background-image:url(/css/flags/1x1/im.svg)}.flag-icon-in{background-image:url(/css/flags/4x3/in.svg)}.flag-icon-in.flag-icon-squared{background-image:url(/css/flags/1x1/in.svg)}.flag-icon-io{background-image:url(/css/flags/4x3/io.svg)}.flag-icon-io.flag-icon-squared{background-image:url(/css/flags/1x1/io.svg)}.flag-icon-iq{background-image:url(/css/flags/4x3/iq.svg)}.flag-icon-iq.flag-icon-squared{background-image:url(/css/flags/1x1/iq.svg)}.flag-icon-ir{background-image:url(/css/flags/4x3/ir.svg)}.flag-icon-ir.flag-icon-squared{background-image:url(/css/flags/1x1/ir.svg)}.flag-icon-is{background-image:url(/css/flags/4x3/is.svg)}.flag-icon-is.flag-icon-squared{background-image:url(/css/flags/1x1/is.svg)}.flag-icon-it{background-image:url(/css/flags/4x3/it.svg)}.flag-icon-it.flag-icon-squared{background-image:url(/css/flags/1x1/it.svg)}.flag-icon-je{background-image:url(/css/flags/4x3/je.svg)}.flag-icon-je.flag-icon-squared{background-image:url(/css/flags/1x1/je.svg)}.flag-icon-jm{background-image:url(/css/flags/4x3/jm.svg)}.flag-icon-jm.flag-icon-squared{background-image:url(/css/flags/1x1/jm.svg)}.flag-icon-jo{background-image:url(/css/flags/4x3/jo.svg)}.flag-icon-jo.flag-icon-squared{background-image:url(/css/flags/1x1/jo.svg)}.flag-icon-jp{background-image:url(/css/flags/4x3/jp.svg)}.flag-icon-jp.flag-icon-squared{background-image:url(/css/flags/1x1/jp.svg)}.flag-icon-ke{background-image:url(/css/flags/4x3/ke.svg)}.flag-icon-ke.flag-icon-squared{background-image:url(/css/flags/1x1/ke.svg)}.flag-icon-kg{background-image:url(/css/flags/4x3/kg.svg)}.flag-icon-kg.flag-icon-squared{background-image:url(/css/flags/1x1/kg.svg)}.flag-icon-kh{background-image:url(/css/flags/4x3/kh.svg)}.flag-icon-kh.flag-icon-squared{background-image:url(/css/flags/1x1/kh.svg)}.flag-icon-ki{background-image:url(/css/flags/4x3/ki.svg)}.flag-icon-ki.flag-icon-squared{background-image:url(/css/flags/1x1/ki.svg)}.flag-icon-km{background-image:url(/css/flags/4x3/km.svg)}.flag-icon-km.flag-icon-squared{background-image:url(/css/flags/1x1/km.svg)}.flag-icon-kn{background-image:url(/css/flags/4x3/kn.svg)}.flag-icon-kn.flag-icon-squared{background-image:url(/css/flags/1x1/kn.svg)}.flag-icon-kp{background-image:url(/css/flags/4x3/kp.svg)}.flag-icon-kp.flag-icon-squared{background-image:url(/css/flags/1x1/kp.svg)}.flag-icon-ko{background-image:url(/css/flags/4x3/ko.svg)}.flag-icon-ko.flag-icon-squared{background-image:url(/css/flags/1x1/ko.svg)}.flag-icon-kr{background-image:url(/css/flags/4x3/kr.svg)}.flag-icon-kr.flag-icon-squared{background-image:url(/css/flags/1x1/kr.svg)}.flag-icon-kw{background-image:url(/css/flags/4x3/kw.svg)}.flag-icon-kw.flag-icon-squared{background-image:url(/css/flags/1x1/kw.svg)}.flag-icon-ky{background-image:url(/css/flags/4x3/ky.svg)}.flag-icon-ky.flag-icon-squared{background-image:url(/css/flags/1x1/ky.svg)}.flag-icon-kz{background-image:url(/css/flags/4x3/kz.svg)}.flag-icon-kz.flag-icon-squared{background-image:url(/css/flags/1x1/kz.svg)}.flag-icon-la{background-image:url(/css/flags/4x3/la.svg)}.flag-icon-la.flag-icon-squared{background-image:url(/css/flags/1x1/la.svg)}.flag-icon-lb{background-image:url(/css/flags/4x3/lb.svg)}.flag-icon-lb.flag-icon-squared{background-image:url(/css/flags/1x1/lb.svg)}.flag-icon-lc{background-image:url(/css/flags/4x3/lc.svg)}.flag-icon-lc.flag-icon-squared{background-image:url(/css/flags/1x1/lc.svg)}.flag-icon-li{background-image:url(/css/flags/4x3/li.svg)}.flag-icon-li.flag-icon-squared{background-image:url(/css/flags/1x1/li.svg)}.flag-icon-lk{background-image:url(/css/flags/4x3/lk.svg)}.flag-icon-lk.flag-icon-squared{background-image:url(/css/flags/1x1/lk.svg)}.flag-icon-lr{background-image:url(/css/flags/4x3/lr.svg)}.flag-icon-lr.flag-icon-squared{background-image:url(/css/flags/1x1/lr.svg)}.flag-icon-ls{background-image:url(/css/flags/4x3/ls.svg)}.flag-icon-ls.flag-icon-squared{background-image:url(/css/flags/1x1/ls.svg)}.flag-icon-lt{background-image:url(/css/flags/4x3/lt.svg)}.flag-icon-lt.flag-icon-squared{background-image:url(/css/flags/1x1/lt.svg)}.flag-icon-lu{background-image:url(/css/flags/4x3/lu.svg)}.flag-icon-lu.flag-icon-squared{background-image:url(/css/flags/1x1/lu.svg)}.flag-icon-lv{background-image:url(/css/flags/4x3/lv.svg)}.flag-icon-lv.flag-icon-squared{background-image:url(/css/flags/1x1/lv.svg)}.flag-icon-ly{background-image:url(/css/flags/4x3/ly.svg)}.flag-icon-ly.flag-icon-squared{background-image:url(/css/flags/1x1/ly.svg)}.flag-icon-ma{background-image:url(/css/flags/4x3/ma.svg)}.flag-icon-ma.flag-icon-squared{background-image:url(/css/flags/1x1/ma.svg)}.flag-icon-mc{background-image:url(/css/flags/4x3/mc.svg)}.flag-icon-mc.flag-icon-squared{background-image:url(/css/flags/1x1/mc.svg)}.flag-icon-md{background-image:url(/css/flags/4x3/md.svg)}.flag-icon-md.flag-icon-squared{background-image:url(/css/flags/1x1/md.svg)}.flag-icon-me{background-image:url(/css/flags/4x3/me.svg)}.flag-icon-me.flag-icon-squared{background-image:url(/css/flags/1x1/me.svg)}.flag-icon-mf{background-image:url(/css/flags/4x3/mf.svg)}.flag-icon-mf.flag-icon-squared{background-image:url(/css/flags/1x1/mf.svg)}.flag-icon-mg{background-image:url(/css/flags/4x3/mg.svg)}.flag-icon-mg.flag-icon-squared{background-image:url(/css/flags/1x1/mg.svg)}.flag-icon-mh{background-image:url(/css/flags/4x3/mh.svg)}.flag-icon-mh.flag-icon-squared{background-image:url(/css/flags/1x1/mh.svg)}.flag-icon-mk{background-image:url(/css/flags/4x3/mk.svg)}.flag-icon-mk.flag-icon-squared{background-image:url(/css/flags/1x1/mk.svg)}.flag-icon-ml{background-image:url(/css/flags/4x3/ml.svg)}.flag-icon-ml.flag-icon-squared{background-image:url(/css/flags/1x1/ml.svg)}.flag-icon-mm{background-image:url(/css/flags/4x3/mm.svg)}.flag-icon-mm.flag-icon-squared{background-image:url(/css/flags/1x1/mm.svg)}.flag-icon-mn{background-image:url(/css/flags/4x3/mn.svg)}.flag-icon-mn.flag-icon-squared{background-image:url(/css/flags/1x1/mn.svg)}.flag-icon-mo{background-image:url(/css/flags/4x3/mo.svg)}.flag-icon-mo.flag-icon-squared{background-image:url(/css/flags/1x1/mo.svg)}.flag-icon-mp{background-image:url(/css/flags/4x3/mp.svg)}.flag-icon-mp.flag-icon-squared{background-image:url(/css/flags/1x1/mp.svg)}.flag-icon-mq{background-image:url(/css/flags/4x3/mq.svg)}.flag-icon-mq.flag-icon-squared{background-image:url(/css/flags/1x1/mq.svg)}.flag-icon-mr{background-image:url(/css/flags/4x3/mr.svg)}.flag-icon-mr.flag-icon-squared{background-image:url(/css/flags/1x1/mr.svg)}.flag-icon-ms{background-image:url(/css/flags/4x3/ms.svg)}.flag-icon-ms.flag-icon-squared{background-image:url(/css/flags/1x1/ms.svg)}.flag-icon-mt{background-image:url(/css/flags/4x3/mt.svg)}.flag-icon-mt.flag-icon-squared{background-image:url(/css/flags/1x1/mt.svg)}.flag-icon-mu{background-image:url(/css/flags/4x3/mu.svg)}.flag-icon-mu.flag-icon-squared{background-image:url(/css/flags/1x1/mu.svg)}.flag-icon-mv{background-image:url(/css/flags/4x3/mv.svg)}.flag-icon-mv.flag-icon-squared{background-image:url(/css/flags/1x1/mv.svg)}.flag-icon-mw{background-image:url(/css/flags/4x3/mw.svg)}.flag-icon-mw.flag-icon-squared{background-image:url(/css/flags/1x1/mw.svg)}.flag-icon-mx{background-image:url(/css/flags/4x3/mx.svg)}.flag-icon-mx.flag-icon-squared{background-image:url(/css/flags/1x1/mx.svg)}.flag-icon-my{background-image:url(/css/flags/4x3/my.svg)}.flag-icon-my.flag-icon-squared{background-image:url(/css/flags/1x1/my.svg)}.flag-icon-mz{background-image:url(/css/flags/4x3/mz.svg)}.flag-icon-mz.flag-icon-squared{background-image:url(/css/flags/1x1/mz.svg)}.flag-icon-na{background-image:url(/css/flags/4x3/na.svg)}.flag-icon-na.flag-icon-squared{background-image:url(/css/flags/1x1/na.svg)}.flag-icon-nc{background-image:url(/css/flags/4x3/nc.svg)}.flag-icon-nc.flag-icon-squared{background-image:url(/css/flags/1x1/nc.svg)}.flag-icon-ne{background-image:url(/css/flags/4x3/ne.svg)}.flag-icon-ne.flag-icon-squared{background-image:url(/css/flags/1x1/ne.svg)}.flag-icon-nf{background-image:url(/css/flags/4x3/nf.svg)}.flag-icon-nf.flag-icon-squared{background-image:url(/css/flags/1x1/nf.svg)}.flag-icon-ng{background-image:url(/css/flags/4x3/ng.svg)}.flag-icon-ng.flag-icon-squared{background-image:url(/css/flags/1x1/ng.svg)}.flag-icon-ni{background-image:url(/css/flags/4x3/ni.svg)}.flag-icon-ni.flag-icon-squared{background-image:url(/css/flags/1x1/ni.svg)}.flag-icon-nl{background-image:url(/css/flags/4x3/nl.svg)}.flag-icon-nl.flag-icon-squared{background-image:url(/css/flags/1x1/nl.svg)}.flag-icon-no{background-image:url(/css/flags/4x3/no.svg)}.flag-icon-no.flag-icon-squared{background-image:url(/css/flags/1x1/no.svg)}.flag-icon-np{background-image:url(/css/flags/4x3/np.svg)}.flag-icon-np.flag-icon-squared{background-image:url(/css/flags/1x1/np.svg)}.flag-icon-nr{background-image:url(/css/flags/4x3/nr.svg)}.flag-icon-nr.flag-icon-squared{background-image:url(/css/flags/1x1/nr.svg)}.flag-icon-nu{background-image:url(/css/flags/4x3/nu.svg)}.flag-icon-nu.flag-icon-squared{background-image:url(/css/flags/1x1/nu.svg)}.flag-icon-nz{background-image:url(/css/flags/4x3/nz.svg)}.flag-icon-nz.flag-icon-squared{background-image:url(/css/flags/1x1/nz.svg)}.flag-icon-om{background-image:url(/css/flags/4x3/om.svg)}.flag-icon-om.flag-icon-squared{background-image:url(/css/flags/1x1/om.svg)}.flag-icon-pa{background-image:url(/css/flags/4x3/pa.svg)}.flag-icon-pa.flag-icon-squared{background-image:url(/css/flags/1x1/pa.svg)}.flag-icon-pe{background-image:url(/css/flags/4x3/pe.svg)}.flag-icon-pe.flag-icon-squared{background-image:url(/css/flags/1x1/pe.svg)}.flag-icon-pf{background-image:url(/css/flags/4x3/pf.svg)}.flag-icon-pf.flag-icon-squared{background-image:url(/css/flags/1x1/pf.svg)}.flag-icon-pg{background-image:url(/css/flags/4x3/pg.svg)}.flag-icon-pg.flag-icon-squared{background-image:url(/css/flags/1x1/pg.svg)}.flag-icon-ph{background-image:url(/css/flags/4x3/ph.svg)}.flag-icon-ph.flag-icon-squared{background-image:url(/css/flags/1x1/ph.svg)}.flag-icon-pk{background-image:url(/css/flags/4x3/pk.svg)}.flag-icon-pk.flag-icon-squared{background-image:url(/css/flags/1x1/pk.svg)}.flag-icon-pl{background-image:url(/css/flags/4x3/pl.svg)}.flag-icon-pl.flag-icon-squared{background-image:url(/css/flags/1x1/pl.svg)}.flag-icon-pm{background-image:url(/css/flags/4x3/pm.svg)}.flag-icon-pm.flag-icon-squared{background-image:url(/css/flags/1x1/pm.svg)}.flag-icon-pn{background-image:url(/css/flags/4x3/pn.svg)}.flag-icon-pn.flag-icon-squared{background-image:url(/css/flags/1x1/pn.svg)}.flag-icon-pr{background-image:url(/css/flags/4x3/pr.svg)}.flag-icon-pr.flag-icon-squared{background-image:url(/css/flags/1x1/pr.svg)}.flag-icon-ps{background-image:url(/css/flags/4x3/ps.svg)}.flag-icon-ps.flag-icon-squared{background-image:url(/css/flags/1x1/ps.svg)}.flag-icon-pt{background-image:url(/css/flags/4x3/pt.svg)}.flag-icon-pt.flag-icon-squared{background-image:url(/css/flags/1x1/pt.svg)}.flag-icon-pw{background-image:url(/css/flags/4x3/pw.svg)}.flag-icon-pw.flag-icon-squared{background-image:url(/css/flags/1x1/pw.svg)}.flag-icon-py{background-image:url(/css/flags/4x3/py.svg)}.flag-icon-py.flag-icon-squared{background-image:url(/css/flags/1x1/py.svg)}.flag-icon-qa{background-image:url(/css/flags/4x3/qa.svg)}.flag-icon-qa.flag-icon-squared{background-image:url(/css/flags/1x1/qa.svg)}.flag-icon-re{background-image:url(/css/flags/4x3/re.svg)}.flag-icon-re.flag-icon-squared{background-image:url(/css/flags/1x1/re.svg)}.flag-icon-ro{background-image:url(/css/flags/4x3/ro.svg)}.flag-icon-ro.flag-icon-squared{background-image:url(/css/flags/1x1/ro.svg)}.flag-icon-rs{background-image:url(/css/flags/4x3/rs.svg)}.flag-icon-rs.flag-icon-squared{background-image:url(/css/flags/1x1/rs.svg)}.flag-icon-ru{background-image:url(/css/flags/4x3/ru.svg)}.flag-icon-ru.flag-icon-squared{background-image:url(/css/flags/1x1/ru.svg)}.flag-icon-rw{background-image:url(/css/flags/4x3/rw.svg)}.flag-icon-rw.flag-icon-squared{background-image:url(/css/flags/1x1/rw.svg)}.flag-icon-sa{background-image:url(/css/flags/4x3/sa.svg)}.flag-icon-sa.flag-icon-squared{background-image:url(/css/flags/1x1/sa.svg)}.flag-icon-sb{background-image:url(/css/flags/4x3/sb.svg)}.flag-icon-sb.flag-icon-squared{background-image:url(/css/flags/1x1/sb.svg)}.flag-icon-sc{background-image:url(/css/flags/4x3/sc.svg)}.flag-icon-sc.flag-icon-squared{background-image:url(/css/flags/1x1/sc.svg)}.flag-icon-sd{background-image:url(/css/flags/4x3/sd.svg)}.flag-icon-sd.flag-icon-squared{background-image:url(/css/flags/1x1/sd.svg)}.flag-icon-se{background-image:url(/css/flags/4x3/se.svg)}.flag-icon-se.flag-icon-squared{background-image:url(/css/flags/1x1/se.svg)}.flag-icon-sg{background-image:url(/css/flags/4x3/sg.svg)}.flag-icon-sg.flag-icon-squared{background-image:url(/css/flags/1x1/sg.svg)}.flag-icon-sh{background-image:url(/css/flags/4x3/sh.svg)}.flag-icon-sh.flag-icon-squared{background-image:url(/css/flags/1x1/sh.svg)}.flag-icon-si{background-image:url(/css/flags/4x3/si.svg)}.flag-icon-si.flag-icon-squared{background-image:url(/css/flags/1x1/si.svg)}.flag-icon-sj{background-image:url(/css/flags/4x3/sj.svg)}.flag-icon-sj.flag-icon-squared{background-image:url(/css/flags/1x1/sj.svg)}.flag-icon-sk{background-image:url(/css/flags/4x3/sk.svg)}.flag-icon-sk.flag-icon-squared{background-image:url(/css/flags/1x1/sk.svg)}.flag-icon-sl{background-image:url(/css/flags/4x3/sl.svg)}.flag-icon-sl.flag-icon-squared{background-image:url(/css/flags/1x1/sl.svg)}.flag-icon-sm{background-image:url(/css/flags/4x3/sm.svg)}.flag-icon-sm.flag-icon-squared{background-image:url(/css/flags/1x1/sm.svg)}.flag-icon-sn{background-image:url(/css/flags/4x3/sn.svg)}.flag-icon-sn.flag-icon-squared{background-image:url(/css/flags/1x1/sn.svg)}.flag-icon-so{background-image:url(/css/flags/4x3/so.svg)}.flag-icon-so.flag-icon-squared{background-image:url(/css/flags/1x1/so.svg)}.flag-icon-sr{background-image:url(/css/flags/4x3/sr.svg)}.flag-icon-sr.flag-icon-squared{background-image:url(/css/flags/1x1/sr.svg)}.flag-icon-ss{background-image:url(/css/flags/4x3/ss.svg)}.flag-icon-ss.flag-icon-squared{background-image:url(/css/flags/1x1/ss.svg)}.flag-icon-st{background-image:url(/css/flags/4x3/st.svg)}.flag-icon-st.flag-icon-squared{background-image:url(/css/flags/1x1/st.svg)}.flag-icon-sv{background-image:url(/css/flags/4x3/sv.svg)}.flag-icon-sv.flag-icon-squared{background-image:url(/css/flags/1x1/sv.svg)}.flag-icon-sx{background-image:url(/css/flags/4x3/sx.svg)}.flag-icon-sx.flag-icon-squared{background-image:url(/css/flags/1x1/sx.svg)}.flag-icon-sy{background-image:url(/css/flags/4x3/sy.svg)}.flag-icon-sy.flag-icon-squared{background-image:url(/css/flags/1x1/sy.svg)}.flag-icon-sz{background-image:url(/css/flags/4x3/sz.svg)}.flag-icon-sz.flag-icon-squared{background-image:url(/css/flags/1x1/sz.svg)}.flag-icon-tc{background-image:url(/css/flags/4x3/tc.svg)}.flag-icon-tc.flag-icon-squared{background-image:url(/css/flags/1x1/tc.svg)}.flag-icon-td{background-image:url(/css/flags/4x3/td.svg)}.flag-icon-td.flag-icon-squared{background-image:url(/css/flags/1x1/td.svg)}.flag-icon-tf{background-image:url(/css/flags/4x3/tf.svg)}.flag-icon-tf.flag-icon-squared{background-image:url(/css/flags/1x1/tf.svg)}.flag-icon-tg{background-image:url(/css/flags/4x3/tg.svg)}.flag-icon-tg.flag-icon-squared{background-image:url(/css/flags/1x1/tg.svg)}.flag-icon-th{background-image:url(/css/flags/4x3/th.svg)}.flag-icon-th.flag-icon-squared{background-image:url(/css/flags/1x1/th.svg)}.flag-icon-tj{background-image:url(/css/flags/4x3/tj.svg)}.flag-icon-tj.flag-icon-squared{background-image:url(/css/flags/1x1/tj.svg)}.flag-icon-tk{background-image:url(/css/flags/4x3/tk.svg)}.flag-icon-tk.flag-icon-squared{background-image:url(/css/flags/1x1/tk.svg)}.flag-icon-tl{background-image:url(/css/flags/4x3/tl.svg)}.flag-icon-tl.flag-icon-squared{background-image:url(/css/flags/1x1/tl.svg)}.flag-icon-tm{background-image:url(/css/flags/4x3/tm.svg)}.flag-icon-tm.flag-icon-squared{background-image:url(/css/flags/1x1/tm.svg)}.flag-icon-tn{background-image:url(/css/flags/4x3/tn.svg)}.flag-icon-tn.flag-icon-squared{background-image:url(/css/flags/1x1/tn.svg)}.flag-icon-to{background-image:url(/css/flags/4x3/to.svg)}.flag-icon-to.flag-icon-squared{background-image:url(/css/flags/1x1/to.svg)}.flag-icon-tr{background-image:url(/css/flags/4x3/tr.svg)}.flag-icon-tr.flag-icon-squared{background-image:url(/css/flags/1x1/tr.svg)}.flag-icon-tt{background-image:url(/css/flags/4x3/tt.svg)}.flag-icon-tt.flag-icon-squared{background-image:url(/css/flags/1x1/tt.svg)}.flag-icon-tv{background-image:url(/css/flags/4x3/tv.svg)}.flag-icon-tv.flag-icon-squared{background-image:url(/css/flags/1x1/tv.svg)}.flag-icon-tw{background-image:url(/css/flags/4x3/tw.svg)}.flag-icon-tw.flag-icon-squared{background-image:url(/css/flags/1x1/tw.svg)}.flag-icon-tz{background-image:url(/css/flags/4x3/tz.svg)}.flag-icon-tz.flag-icon-squared{background-image:url(/css/flags/1x1/tz.svg)}.flag-icon-ua{background-image:url(/css/flags/4x3/ua.svg)}.flag-icon-ua.flag-icon-squared{background-image:url(/css/flags/1x1/ua.svg)}.flag-icon-ug{background-image:url(/css/flags/4x3/ug.svg)}.flag-icon-ug.flag-icon-squared{background-image:url(/css/flags/1x1/ug.svg)}.flag-icon-um{background-image:url(/css/flags/4x3/um.svg)}.flag-icon-um.flag-icon-squared{background-image:url(/css/flags/1x1/um.svg)}.flag-icon-us{background-image:url(/css/flags/4x3/us.svg)}.flag-icon-us.flag-icon-squared{background-image:url(/css/flags/1x1/us.svg)}.flag-icon-uy{background-image:url(/css/flags/4x3/uy.svg)}.flag-icon-uy.flag-icon-squared{background-image:url(/css/flags/1x1/uy.svg)}.flag-icon-uz{background-image:url(/css/flags/4x3/uz.svg)}.flag-icon-uz.flag-icon-squared{background-image:url(/css/flags/1x1/uz.svg)}.flag-icon-va{background-image:url(/css/flags/4x3/va.svg)}.flag-icon-va.flag-icon-squared{background-image:url(/css/flags/1x1/va.svg)}.flag-icon-vc{background-image:url(/css/flags/4x3/vc.svg)}.flag-icon-vc.flag-icon-squared{background-image:url(/css/flags/1x1/vc.svg)}.flag-icon-ve{background-image:url(/css/flags/4x3/ve.svg)}.flag-icon-ve.flag-icon-squared{background-image:url(/css/flags/1x1/ve.svg)}.flag-icon-vg{background-image:url(/css/flags/4x3/vg.svg)}.flag-icon-vg.flag-icon-squared{background-image:url(/css/flags/1x1/vg.svg)}.flag-icon-vi{background-image:url(/css/flags/4x3/vi.svg)}.flag-icon-vi.flag-icon-squared{background-image:url(/css/flags/1x1/vi.svg)}.flag-icon-vn{background-image:url(/css/flags/4x3/vn.svg)}.flag-icon-vn.flag-icon-squared{background-image:url(/css/flags/1x1/vn.svg)}.flag-icon-vu{background-image:url(/css/flags/4x3/vu.svg)}.flag-icon-vu.flag-icon-squared{background-image:url(/css/flags/1x1/vu.svg)}.flag-icon-wf{background-image:url(/css/flags/4x3/wf.svg)}.flag-icon-wf.flag-icon-squared{background-image:url(/css/flags/1x1/wf.svg)}.flag-icon-ws{background-image:url(/css/flags/4x3/ws.svg)}.flag-icon-ws.flag-icon-squared{background-image:url(/css/flags/1x1/ws.svg)}.flag-icon-ye{background-image:url(/css/flags/4x3/ye.svg)}.flag-icon-ye.flag-icon-squared{background-image:url(/css/flags/1x1/ye.svg)}.flag-icon-yt{background-image:url(/css/flags/4x3/yt.svg)}.flag-icon-yt.flag-icon-squared{background-image:url(/css/flags/1x1/yt.svg)}.flag-icon-za{background-image:url(/css/flags/4x3/za.svg)}.flag-icon-za.flag-icon-squared{background-image:url(/css/flags/1x1/za.svg)}.flag-icon-zm{background-image:url(/css/flags/4x3/zm.svg)}.flag-icon-zm.flag-icon-squared{background-image:url(/css/flags/1x1/zm.svg)}.flag-icon-zw{background-image:url(/css/flags/4x3/zw.svg)}.flag-icon-zw.flag-icon-squared{background-image:url(/css/flags/1x1/zw.svg)}.flag-icon-es-ct{background-image:url(/css/flags/4x3/es-ct.svg)}.flag-icon-es-ct.flag-icon-squared{background-image:url(/css/flags/1x1/es-ct.svg)}.flag-icon-es-ga{background-image:url(/css/flags/4x3/es-ga.svg)}.flag-icon-es-ga.flag-icon-squared{background-image:url(/css/flags/1x1/es-ga.svg)}.flag-icon-eu{background-image:url(/css/flags/4x3/eu.svg)}.flag-icon-eu.flag-icon-squared{background-image:url(/css/flags/1x1/eu.svg)}.flag-icon-gb-eng{background-image:url(/css/flags/4x3/gb-eng.svg)}.flag-icon-gb-eng.flag-icon-squared{background-image:url(/css/flags/1x1/gb-eng.svg)}.flag-icon-gb-nir{background-image:url(/css/flags/4x3/gb-nir.svg)}.flag-icon-gb-nir.flag-icon-squared{background-image:url(/css/flags/1x1/gb-nir.svg)}.flag-icon-gb-sct{background-image:url(/css/flags/4x3/gb-sct.svg)}.flag-icon-gb-sct.flag-icon-squared{background-image:url(/css/flags/1x1/gb-sct.svg)}.flag-icon-gb-wls{background-image:url(/css/flags/4x3/gb-wls.svg)}.flag-icon-gb-wls.flag-icon-squared{background-image:url(/css/flags/1x1/gb-wls.svg)}.flag-icon-un{background-image:url(/css/flags/4x3/un.svg)}.flag-icon-un.flag-icon-squared{background-image:url(/css/flags/1x1/un.svg)}.flag-icon-xk{background-image:url(/css/flags/4x3/xk.svg)}.flag-icon-xk.flag-icon-squared{background-image:url(/css/flags/1x1/xk.svg)}
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/build/013-datatables.css b/mailcow/src/mailcow-dockerized/data/web/css/build/013-datatables.css
index 57e2b6d..1bc1811 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/build/013-datatables.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/build/013-datatables.css
@@ -8,9 +8,6 @@
.dtr-details {
width: 100%;
}
-.table-striped>tbody>tr:nth-of-type(odd) {
- background-color: #F2F2F2;
-}
td.child>ul>li {
display: flex;
}
@@ -20,15 +17,15 @@
}
table.dataTable.dtr-inline.collapsed>tbody>tr>td.dtr-control:before:hover,
table.dataTable.dtr-inline.collapsed>tbody>tr>th.dtr-control:before:hover {
- background-color: #5e5e5e;
+ background-color: var(--mc-dtr-hover-bg);
}
table.dataTable.dtr-inline.collapsed>tbody>tr>td.dtr-control:before,
table.dataTable.dtr-inline.collapsed>tbody>tr>th.dtr-control:before,
table.dataTable td.dt-control:before {
- background-color: #979797 !important;
- border: 1.5px solid #616161 !important;
+ background-color: var(--mc-dtr-bg) !important;
+ border: 1.5px solid var(--mc-dtr-border) !important;
border-radius: 2px !important;
- color: #fff;
+ color: var(--mc-dtr-color);
height: 1em;
width: 1em;
line-height: 1.25em;
@@ -40,7 +37,7 @@
table.dataTable.dtr-inline.collapsed>tbody>tr.parent>td.dtr-control:before,
table.dataTable.dtr-inline.collapsed>tbody>tr.parent>th.dtr-control:before,
table.dataTable td.dt-control:before {
- background-color: #979797 !important;
+ background-color: var(--mc-dtr-active-bg) !important;
}
table.dataTable.table-striped>tbody>tr>td {
vertical-align: middle;
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/build/014-mailcow.css b/mailcow/src/mailcow-dockerized/data/web/css/build/014-mailcow.css
index 6c70a2a..52a34f8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/build/014-mailcow.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/build/014-mailcow.css
@@ -33,6 +33,46 @@
url('/fonts/noto-sans-v12-latin_greek_cyrillic-700italic.woff2') format('woff2'),
url('/fonts/noto-sans-v12-latin_greek_cyrillic-700italic.woff') format('woff');
}
+
+/* theme tokens, override in css/themes/<name>/theme.css */
+:root {
+ --mc-font-family: "Noto Sans","Helvetica Neue",Helvetica,Arial,sans-serif;
+ --mc-font-size: 10.5pt;
+ --mc-body-bg: #fbfbfb;
+ --mc-primary: #0F688D;
+ --mc-primary-border: #0d526d;
+ --mc-info: #148DBC;
+ --mc-info-border: #127ea8;
+ --mc-border: #dfdfdf;
+ --mc-surface: #fff;
+ --mc-surface-alt: #f7f7f7;
+ --mc-muted: #959595;
+ --mc-hr: #ccc;
+ --mc-progress-bg: #d5d5d5;
+ --mc-placeholder: rgb(137 137 137);
+ --mc-btn-outline-color: #000000;
+ --mc-btn-outline-border: #cfcfcf;
+ --mc-btn-outline-hover-bg: #f0f0f0;
+ --mc-btn-outline-active-bg: #f0f0f0;
+ --mc-btn-light-active-color: #fff;
+ --mc-btn-light-active-bg: #555;
+ --mc-btn-light-active-border: #4d4d4d;
+ --mc-dtr-bg: #979797;
+ --mc-dtr-border: #616161;
+ --mc-dtr-color: #fff;
+ --mc-dtr-hover-bg: #5e5e5e;
+ --mc-dtr-active-bg: #979797;
+ --mc-login-user: #28b62c;
+ --mc-login-domainadmin: #ffc107;
+ --mc-login-admin: #ff4136;
+}
+
+body {
+ min-height: 100vh;
+ display: flex;
+ flex-direction: column;
+ background-color: var(--mc-body-bg);
+}
#maxmsgsize { min-width: 80px; }
#slider1 .slider-selection {
background: #FFD700;
@@ -74,10 +114,23 @@
align-items: center;
padding: 0 10px !important;
}
-.navbar-fixed-bottom .navbar-collapse,
+.navbar-fixed-bottom .navbar-collapse,
.navbar-fixed-top .navbar-collapse {
max-height: 1000px
}
+.nav-tabs .nav-link, .nav-tabs .nav-link.disabled, .nav-tabs .nav-link.disabled:hover, .nav-tabs .nav-link.disabled:focus {
+ border-color: var(--mc-border);
+}
+.nav-tabs .nav-link.active, .nav-tabs .nav-item.show .nav-link {
+ border-color: var(--mc-border);
+ border-bottom: 1px solid var(--mc-surface);
+}
+.nav-tabs .nav-link:hover, .nav-tabs .nav-link:focus {
+ border-color: var(--mc-border);
+}
+.nav-tabs {
+ border-bottom: 1px solid var(--mc-border);
+}
.bi {
display: inline-block;
font-size: 12pt;
@@ -123,18 +176,18 @@
}
}
@keyframes blink {
- 50% {
- color: transparent
+ 50% {
+ color: transparent
}
}
-.loader-dot {
- animation: 1s blink infinite
+.loader-dot {
+ animation: 1s blink infinite
}
-.loader-dot:nth-child(2) {
- animation-delay: 250ms
+.loader-dot:nth-child(2) {
+ animation-delay: 250ms
}
-.loader-dot:nth-child(3) {
- animation-delay: 500ms
+.loader-dot:nth-child(3) {
+ animation-delay: 500ms
}
pre{white-space:pre-wrap;white-space:-moz-pre-wrap;white-space:-o-pre-wrap;word-wrap:break-word;}
@@ -144,13 +197,13 @@
padding-right: inherit !important;
}
body {
- font-family: "Noto Sans","Helvetica Neue",Helvetica,Arial,sans-serif;
- font-size: 10.5pt;
+ font-family: var(--mc-font-family);
+ font-size: var(--mc-font-size);
line-height: 1.5;
}
html {
- font-family: "Noto Sans","Helvetica Neue",Helvetica,Arial,sans-serif;
- font-size: 10.5pt;
+ font-family: var(--mc-font-family);
+ font-size: var(--mc-font-size);
line-height: 1.5;
}
#mailcow-alert {
@@ -186,7 +239,7 @@
cursor: not-allowed;
}
.overlay {
- background: #fff;
+ background: var(--mc-surface);
position: absolute;
z-index: 10000;
top: 0; right: 0; bottom: 0; left: 0;
@@ -195,18 +248,15 @@
.bootstrap-select.btn-group .no-results {
display: none;
}
-.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-secondary {
- color: rgb(197, 197, 197) !important;
-}
.haveibeenpwned {
cursor: pointer;
- -webkit-user-select: none;
- -moz-user-select: none;
- -ms-user-select: none;
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
user-select: none;
}
.full-width-select {
- width: 100%!important;
+ width: 100%!important;
}
.tooltip {
font-family: inherit;
@@ -219,7 +269,7 @@
.footer {
margin-top: 27px;
margin-bottom: 20px;
- color: #959595;
+ color: var(--mc-muted);
display: flex;
flex-direction: column;
}
@@ -317,7 +367,7 @@
overflow-x: auto!important;
}
.well {
- border: 1px solid #dfdfdf;
+ border: 1px solid var(--mc-border);
background-color: #f9f9f9;
padding: 10px;
}
@@ -330,52 +380,53 @@
.caret {
transform: rotate(0deg);
}
-a[aria-expanded='true'] > .caret,
+a[aria-expanded='true'] > .caret,
button[aria-expanded='true'] > .caret {
transform: rotate(-180deg);
}
.list-group-details {
- background: #fff;
+ background: var(--mc-surface);
}
.list-group-header {
- background: #f7f7f7;
-}
+ background: var(--mc-surface-alt);
+}
.bg-primary, .alert-primary, .btn-primary {
- background-color: #0F688D !important;
- border-color: #0d526d !important;
+ background-color: var(--mc-primary) !important;
+ border-color: var(--mc-primary-border) !important;
}
.bg-info, .alert-info, .btn-info {
- background-color: #148DBC !important;
- border-color: #127ea8 !important;
+ background-color: var(--mc-info) !important;
+ border-color: var(--mc-info-border) !important;
}
.bootstrap-select>.dropdown-toggle.bs-placeholder.btn-secondary {
- color: rgb(137 137 137)!important;
+ color: var(--mc-placeholder) !important;
}
.progress {
height: 16px;
- background-color: #d5d5d5;
+ background-color: var(--mc-progress-bg);
}
.btn-outline-secondary:hover {
- background-color: #f0f0f0;
+ background-color: var(--mc-btn-outline-hover-bg);
}
.btn.btn-outline-secondary {
- border-color: #cfcfcf !important;
+ color: var(--mc-btn-outline-color) !important;
+ border-color: var(--mc-btn-outline-border) !important;
}
.btn-check:checked+.btn-outline-secondary, .btn-check:active+.btn-outline-secondary, .btn-outline-secondary:active, .btn-outline-secondary.active, .btn-outline-secondary.dropdown-toggle.show {
- background-color: #f0f0f0 !important;
+ background-color: var(--mc-btn-outline-active-bg) !important;
}
-.btn-check:checked+.btn-light, .btn-check:active+.btn-light, .btn-light:active, .btn-light.active, .show>.btn-light.dropdown-toggle {
- color: #fff;
- background-color: #555;
+.btn-check:checked+.btn-light, .btn-check:active+.btn-light, .btn-light:active, .btn-light.active, .show>.btn-light.dropdown-toggle {
+ color: var(--mc-btn-light-active-color);
+ background-color: var(--mc-btn-light-active-bg);
background-image: none;
- border-color: #4d4d4d;
+ border-color: var(--mc-btn-light-active-border);
}
.btn-check:checked+.btn-light:focus, .btn-check:active+.btn-light:focus, .btn-light:active:focus, .btn-light.active:focus, .show>.btn-light.dropdown-toggle:focus,
.btn-check:focus+.btn-light, .btn-light:focus {
@@ -389,4 +440,46 @@
.badge.bg-danger > a {
color: #fff !important;
text-decoration: none;
+}
+
+/* role marker on login pages, header icons differ too (color blindness) */
+.login-card::before {
+ content: "";
+ display: block;
+ height: 5px;
+ background: var(--mc-login-color);
+ border-radius: inherit;
+ border-bottom-left-radius: 0;
+ border-bottom-right-radius: 0;
+}
+.login-user {
+ --mc-login-color: var(--mc-login-user);
+}
+.login-domainadmin {
+ --mc-login-color: var(--mc-login-domainadmin);
+}
+.login-admin {
+ --mc-login-color: var(--mc-login-admin);
+}
+
+.hr-title {
+ display: flex;
+ align-items: center;
+ text-align: center;
+ margin: 20px 0;
+}
+
+.hr-title::before,
+.hr-title::after {
+ content: "";
+ flex: 1;
+ border-bottom: 1px solid var(--mc-hr);
+}
+
+.hr-title:not(:empty)::before {
+ margin-right: 10px;
+}
+
+.hr-title:not(:empty)::after {
+ margin-left: 10px;
}
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/build/015-responsive.css b/mailcow/src/mailcow-dockerized/data/web/css/build/015-responsive.css
index 57ce802..82be710 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/build/015-responsive.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/build/015-responsive.css
@@ -6,15 +6,9 @@
max-width: 350px;
}
-.card-login .apps .btn {
- width: auto;
- float: left;
- margin-right: 10px;
- margin-top: auto;
-}
-.card-login .apps .btn:hover {
- margin-top: 1px !important;
- border-bottom-width: 3px;
+.card .apps {
+ display: flex;
+ flex-wrap: wrap;
}
.responsive-tabs .nav-tabs {
@@ -43,16 +37,6 @@
opacity: 1;
}
- .card-login .apps .btn {
- width: 100%;
- float: none;
- margin-bottom: 10px;
- }
-
- .card-login .apps .btn {
- border-bottom-width: 4px;
- }
-
.xs-show {
display: block !important;
}
@@ -113,9 +97,6 @@
.btn-group.nowrap .dropdown-menu {
width: 100%;
}
- .card-login .btn-group {
- display: block;
- }
.mass-actions-user .btn-group {
float: none;
}
@@ -191,9 +172,6 @@
.btn-group .btn i {
margin-right: 5px;
}
- .card-login .btn-group .btn {
- display: block !important;
- }
.dt-sm-head-hidden .dtr-title {
display: none !important;
@@ -206,7 +184,7 @@
.senders-mw220 {
max-width: 100% !important;
}
-
+
table.dataTable.dtr-inline.collapsed>tbody>tr>td.dtr-control:before,
table.dataTable.dtr-inline.collapsed>tbody>tr>th.dtr-control:before,
table.dataTable td.dt-control:before {
@@ -215,7 +193,7 @@
line-height: 2rem;
margin-top: -15px;
}
-
+
li .dtr-data {
padding: 0;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/site/admin.css b/mailcow/src/mailcow-dockerized/data/web/css/site/admin.css
index e49046b..b541480 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/site/admin.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/site/admin.css
@@ -59,9 +59,6 @@
.table-condensed > thead > tr > th, .table-condensed > tbody > tr > th, .table-condensed > tfoot > tr > th, .table-condensed > thead > tr > td, .table-condensed > tbody > tr > td, .table-condensed > tfoot > tr > td {
padding: 3px;
}
-table tbody tr {
- cursor: pointer;
-}
table tbody tr td input[type="checkbox"] {
cursor: pointer;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/lumen-bootstrap.css b/mailcow/src/mailcow-dockerized/data/web/css/themes/lumen-bootstrap.css
index bcf6268..65ef3ca 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/themes/lumen-bootstrap.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/lumen-bootstrap.css
@@ -1,17 +1,16 @@
@charset "UTF-8";
/*!
- * Bootswatch v5.1.3 (https://bootswatch.com)
- * Copyright 2012-2022 Thomas Park
+ * Bootswatch v5.3.8 (https://bootswatch.com)
+ * Theme: lumen
+ * Copyright 2012-2025 Thomas Park
* Licensed under MIT
* Based on Bootstrap
*/
/*!
- * Bootstrap v5.1.3 (https://getbootstrap.com/)
- * Copyright 2011-2021 The Bootstrap Authors
- * Copyright 2011-2021 Twitter, Inc.
+ * Bootstrap v5.3.8 (https://getbootstrap.com/)
+ * Copyright 2011-2025 The Bootstrap Authors
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
-
/* source-sans-pro-300 - latin */
@font-face {
font-family: 'Source Sans Pro';
@@ -90,8 +89,8 @@
url('/fonts/source-sans-pro-v21-latin-700italic.ttf') format('truetype'), /* Safari, Android, iOS */
url('/fonts/source-sans-pro-v21-latin-700italic.svg#SourceSansPro') format('svg'); /* Legacy iOS */
}
-
-:root {
+:root,
+[data-bs-theme=light] {
--bs-blue: #158cba;
--bs-indigo: #6610f2;
--bs-purple: #6f42c1;
@@ -102,6 +101,7 @@
--bs-green: #28b62c;
--bs-teal: #20c997;
--bs-cyan: #75caeb;
+ --bs-black: #000;
--bs-white: #fff;
--bs-gray: #999;
--bs-gray-dark: #333;
@@ -130,10 +130,32 @@
--bs-danger-rgb: 255, 65, 54;
--bs-light-rgb: 246, 246, 246;
--bs-dark-rgb: 85, 85, 85;
+ --bs-primary-text-emphasis: #08384a;
+ --bs-secondary-text-emphasis: #606060;
+ --bs-success-text-emphasis: #104912;
+ --bs-info-text-emphasis: #2f515e;
+ --bs-warning-text-emphasis: #66350b;
+ --bs-danger-text-emphasis: #661a16;
+ --bs-light-text-emphasis: #555;
+ --bs-dark-text-emphasis: #555;
+ --bs-primary-bg-subtle: #d0e8f1;
+ --bs-secondary-bg-subtle: #fcfcfc;
+ --bs-success-bg-subtle: #d4f0d5;
+ --bs-info-bg-subtle: #e3f4fb;
+ --bs-warning-bg-subtle: #ffe7d1;
+ --bs-danger-bg-subtle: #ffd9d7;
+ --bs-light-bg-subtle: #fbfbfb;
+ --bs-dark-bg-subtle: #ced4da;
+ --bs-primary-border-subtle: #a1d1e3;
+ --bs-secondary-border-subtle: #f9f9f9;
+ --bs-success-border-subtle: #a9e2ab;
+ --bs-info-border-subtle: #c8eaf7;
+ --bs-warning-border-subtle: #ffcea4;
+ --bs-danger-border-subtle: #ffb3af;
+ --bs-light-border-subtle: #f0f0f0;
+ --bs-dark-border-subtle: #adb5bd;
--bs-white-rgb: 255, 255, 255;
--bs-black-rgb: 0, 0, 0;
- --bs-body-color-rgb: 34, 34, 34;
- --bs-body-bg-rgb: 255, 255, 255;
--bs-font-sans-serif: "Source Sans Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
--bs-font-monospace: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
--bs-gradient: linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0));
@@ -142,7 +164,106 @@
--bs-body-font-weight: 400;
--bs-body-line-height: 1.5;
--bs-body-color: #222;
+ --bs-body-color-rgb: 34, 34, 34;
--bs-body-bg: #fff;
+ --bs-body-bg-rgb: 255, 255, 255;
+ --bs-emphasis-color: #000;
+ --bs-emphasis-color-rgb: 0, 0, 0;
+ --bs-secondary-color: rgba(34, 34, 34, 0.75);
+ --bs-secondary-color-rgb: 34, 34, 34;
+ --bs-secondary-bg: #f0f0f0;
+ --bs-secondary-bg-rgb: 240, 240, 240;
+ --bs-tertiary-color: rgba(34, 34, 34, 0.5);
+ --bs-tertiary-color-rgb: 34, 34, 34;
+ --bs-tertiary-bg: #f6f6f6;
+ --bs-tertiary-bg-rgb: 246, 246, 246;
+ --bs-heading-color: inherit;
+ --bs-link-color: #158cba;
+ --bs-link-color-rgb: 21, 140, 186;
+ --bs-link-decoration: underline;
+ --bs-link-hover-color: #117095;
+ --bs-link-hover-color-rgb: 17, 112, 149;
+ --bs-code-color: #e83e8c;
+ --bs-highlight-color: #222;
+ --bs-highlight-bg: #ffe7d1;
+ --bs-border-width: 1px;
+ --bs-border-style: solid;
+ --bs-border-color: #dee2e6;
+ --bs-border-color-translucent: rgba(0, 0, 0, 0.175);
+ --bs-border-radius: 0.375rem;
+ --bs-border-radius-sm: 0.25rem;
+ --bs-border-radius-lg: 0.5rem;
+ --bs-border-radius-xl: 1rem;
+ --bs-border-radius-xxl: 2rem;
+ --bs-border-radius-2xl: var(--bs-border-radius-xxl);
+ --bs-border-radius-pill: 50rem;
+ --bs-box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
+ --bs-box-shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
+ --bs-box-shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);
+ --bs-box-shadow-inset: inset 0 1px 2px rgba(0, 0, 0, 0.075);
+ --bs-focus-ring-width: 0.25rem;
+ --bs-focus-ring-opacity: 0.25;
+ --bs-focus-ring-color: rgba(21, 140, 186, 0.25);
+ --bs-form-valid-color: #28b62c;
+ --bs-form-valid-border-color: #28b62c;
+ --bs-form-invalid-color: #ff4136;
+ --bs-form-invalid-border-color: #ff4136;
+}
+
+[data-bs-theme=dark] {
+ color-scheme: dark;
+ --bs-body-color: #dee2e6;
+ --bs-body-color-rgb: 222, 226, 230;
+ --bs-body-bg: #222;
+ --bs-body-bg-rgb: 34, 34, 34;
+ --bs-emphasis-color: #fff;
+ --bs-emphasis-color-rgb: 255, 255, 255;
+ --bs-secondary-color: rgba(222, 226, 230, 0.75);
+ --bs-secondary-color-rgb: 222, 226, 230;
+ --bs-secondary-bg: #333;
+ --bs-secondary-bg-rgb: 51, 51, 51;
+ --bs-tertiary-color: rgba(222, 226, 230, 0.5);
+ --bs-tertiary-color-rgb: 222, 226, 230;
+ --bs-tertiary-bg: #2b2b2b;
+ --bs-tertiary-bg-rgb: 43, 43, 43;
+ --bs-primary-text-emphasis: #73bad6;
+ --bs-secondary-text-emphasis: #f6f6f6;
+ --bs-success-text-emphasis: #7ed380;
+ --bs-info-text-emphasis: #acdff3;
+ --bs-warning-text-emphasis: #ffb676;
+ --bs-danger-text-emphasis: #ff8d86;
+ --bs-light-text-emphasis: #f6f6f6;
+ --bs-dark-text-emphasis: #dee2e6;
+ --bs-primary-bg-subtle: #041c25;
+ --bs-secondary-bg-subtle: #303030;
+ --bs-success-bg-subtle: #082409;
+ --bs-info-bg-subtle: #17282f;
+ --bs-warning-bg-subtle: #331b05;
+ --bs-danger-bg-subtle: #330d0b;
+ --bs-light-bg-subtle: #333;
+ --bs-dark-bg-subtle: #1a1a1a;
+ --bs-primary-border-subtle: #0d5470;
+ --bs-secondary-border-subtle: #909090;
+ --bs-success-border-subtle: #186d1a;
+ --bs-info-border-subtle: #46798d;
+ --bs-warning-border-subtle: #995010;
+ --bs-danger-border-subtle: #992720;
+ --bs-light-border-subtle: #555;
+ --bs-dark-border-subtle: #333;
+ --bs-heading-color: inherit;
+ --bs-link-color: #73bad6;
+ --bs-link-hover-color: #8fc8de;
+ --bs-link-color-rgb: 115, 186, 214;
+ --bs-link-hover-color-rgb: 143, 200, 222;
+ --bs-code-color: #f18bba;
+ --bs-highlight-color: #dee2e6;
+ --bs-highlight-bg: #66350b;
+ --bs-border-color: #555;
+ --bs-border-color-translucent: rgba(255, 255, 255, 0.15);
+ --bs-form-valid-color: #7ed380;
+ --bs-form-valid-border-color: #7ed380;
+ --bs-form-invalid-color: #ff8d86;
+ --bs-form-invalid-border-color: #ff8d86;
}
*,
@@ -173,20 +294,17 @@
hr {
margin: 1rem 0;
color: inherit;
- background-color: currentColor;
border: 0;
+ border-top: var(--bs-border-width) solid;
opacity: 0.25;
}
-hr:not([size]) {
- height: 1px;
-}
-
h6, .h6, h5, .h5, h4, .h4, h3, .h3, h2, .h2, h1, .h1 {
margin-top: 0;
margin-bottom: 0.5rem;
font-weight: 500;
line-height: 1.2;
+ color: var(--bs-heading-color);
}
h1, .h1 {
@@ -238,8 +356,7 @@
margin-bottom: 1rem;
}
-abbr[title],
-abbr[data-bs-original-title] {
+abbr[title] {
-webkit-text-decoration: underline dotted;
text-decoration: underline dotted;
cursor: help;
@@ -295,8 +412,9 @@
}
mark, .mark {
- padding: 0.2em;
- background-color: #fcf8e3;
+ padding: 0.1875em;
+ color: var(--bs-highlight-color);
+ background-color: var(--bs-highlight-bg);
}
sub,
@@ -316,11 +434,11 @@
}
a {
- color: #158cba;
+ color: rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 1));
text-decoration: underline;
}
a:hover {
- color: #117095;
+ --bs-link-color-rgb: var(--bs-link-hover-color-rgb);
}
a:not([href]):not([class]), a:not([href]):not([class]):hover {
@@ -334,8 +452,6 @@
samp {
font-family: var(--bs-font-monospace);
font-size: 1em;
- direction: ltr /* rtl:ignore */;
- unicode-bidi: bidi-override;
}
pre {
@@ -353,7 +469,7 @@
code {
font-size: 0.875em;
- color: #e83e8c;
+ color: var(--bs-code-color);
word-wrap: break-word;
}
a > code {
@@ -361,16 +477,15 @@
}
kbd {
- padding: 0.2rem 0.4rem;
+ padding: 0.1875rem 0.375rem;
font-size: 0.875em;
- color: #fff;
- background-color: #222;
- border-radius: 0.2rem;
+ color: var(--bs-body-bg);
+ background-color: var(--bs-body-color);
+ border-radius: 0.25rem;
}
kbd kbd {
padding: 0;
font-size: 1em;
- font-weight: 700;
}
figure {
@@ -390,7 +505,7 @@
caption {
padding-top: 0.5rem;
padding-bottom: 0.5rem;
- color: #999;
+ color: var(--bs-secondary-color);
text-align: left;
}
@@ -449,8 +564,8 @@
opacity: 1;
}
-[list]::-webkit-calendar-picker-indicator {
- display: none;
+[list]:not([type=date]):not([type=datetime-local]):not([type=month]):not([type=week]):not([type=time])::-webkit-calendar-picker-indicator {
+ display: none !important;
}
button,
@@ -487,8 +602,8 @@
width: 100%;
padding: 0;
margin-bottom: 0.5rem;
- font-size: calc(1.275rem + 0.3vw);
line-height: inherit;
+ font-size: calc(1.275rem + 0.3vw);
}
@media (min-width: 1200px) {
legend {
@@ -514,8 +629,12 @@
}
[type=search] {
- outline-offset: -2px;
-webkit-appearance: textfield;
+ outline-offset: -2px;
+}
+[type=search]::-webkit-search-cancel-button {
+ cursor: pointer;
+ filter: grayscale(1);
}
/* rtl:raw:
@@ -536,14 +655,11 @@
::-webkit-file-upload-button {
font: inherit;
+ -webkit-appearance: button;
}
::file-selector-button {
font: inherit;
-}
-
-::-webkit-file-upload-button {
- font: inherit;
-webkit-appearance: button;
}
@@ -574,9 +690,9 @@
}
.display-1 {
- font-size: calc(1.625rem + 4.5vw);
font-weight: 300;
line-height: 1.2;
+ font-size: calc(1.625rem + 4.5vw);
}
@media (min-width: 1200px) {
.display-1 {
@@ -585,9 +701,9 @@
}
.display-2 {
- font-size: calc(1.575rem + 3.9vw);
font-weight: 300;
line-height: 1.2;
+ font-size: calc(1.575rem + 3.9vw);
}
@media (min-width: 1200px) {
.display-2 {
@@ -596,9 +712,9 @@
}
.display-3 {
- font-size: calc(1.525rem + 3.3vw);
font-weight: 300;
line-height: 1.2;
+ font-size: calc(1.525rem + 3.3vw);
}
@media (min-width: 1200px) {
.display-3 {
@@ -607,9 +723,9 @@
}
.display-4 {
- font-size: calc(1.475rem + 2.7vw);
font-weight: 300;
line-height: 1.2;
+ font-size: calc(1.475rem + 2.7vw);
}
@media (min-width: 1200px) {
.display-4 {
@@ -618,9 +734,9 @@
}
.display-5 {
- font-size: calc(1.425rem + 2.1vw);
font-weight: 300;
line-height: 1.2;
+ font-size: calc(1.425rem + 2.1vw);
}
@media (min-width: 1200px) {
.display-5 {
@@ -629,9 +745,9 @@
}
.display-6 {
- font-size: calc(1.375rem + 1.5vw);
font-weight: 300;
line-height: 1.2;
+ font-size: calc(1.375rem + 1.5vw);
}
@media (min-width: 1200px) {
.display-6 {
@@ -676,7 +792,7 @@
color: #999;
}
.blockquote-footer::before {
- content: "— ";
+ content: "— ";
}
.img-fluid {
@@ -686,9 +802,9 @@
.img-thumbnail {
padding: 0.25rem;
- background-color: #fff;
- border: 1px solid #dee2e6;
- border-radius: 0.25rem;
+ background-color: var(--bs-body-bg);
+ border: var(--bs-border-width) solid var(--bs-border-color);
+ border-radius: var(--bs-border-radius);
max-width: 100%;
height: auto;
}
@@ -704,7 +820,7 @@
.figure-caption {
font-size: 0.875em;
- color: #999;
+ color: var(--bs-secondary-color);
}
.container,
@@ -714,9 +830,11 @@
.container-lg,
.container-md,
.container-sm {
+ --bs-gutter-x: 1.5rem;
+ --bs-gutter-y: 0;
width: 100%;
- padding-right: var(--bs-gutter-x, 0.75rem);
- padding-left: var(--bs-gutter-x, 0.75rem);
+ padding-right: calc(var(--bs-gutter-x) * 0.5);
+ padding-left: calc(var(--bs-gutter-x) * 0.5);
margin-right: auto;
margin-left: auto;
}
@@ -746,6 +864,15 @@
max-width: 1320px;
}
}
+:root {
+ --bs-breakpoint-xs: 0;
+ --bs-breakpoint-sm: 576px;
+ --bs-breakpoint-md: 768px;
+ --bs-breakpoint-lg: 992px;
+ --bs-breakpoint-xl: 1200px;
+ --bs-breakpoint-xxl: 1400px;
+}
+
.row {
--bs-gutter-x: 1.5rem;
--bs-gutter-y: 0;
@@ -765,7 +892,7 @@
}
.col {
- flex: 1 0 0%;
+ flex: 1 0 0;
}
.row-cols-auto > * {
@@ -785,7 +912,7 @@
.row-cols-3 > * {
flex: 0 0 auto;
- width: 33.3333333333%;
+ width: 33.33333333%;
}
.row-cols-4 > * {
@@ -800,7 +927,7 @@
.row-cols-6 > * {
flex: 0 0 auto;
- width: 16.6666666667%;
+ width: 16.66666667%;
}
.col-auto {
@@ -974,1089 +1101,875 @@
@media (min-width: 576px) {
.col-sm {
- flex: 1 0 0%;
+ flex: 1 0 0;
}
-
.row-cols-sm-auto > * {
flex: 0 0 auto;
width: auto;
}
-
.row-cols-sm-1 > * {
flex: 0 0 auto;
width: 100%;
}
-
.row-cols-sm-2 > * {
flex: 0 0 auto;
width: 50%;
}
-
.row-cols-sm-3 > * {
flex: 0 0 auto;
- width: 33.3333333333%;
+ width: 33.33333333%;
}
-
.row-cols-sm-4 > * {
flex: 0 0 auto;
width: 25%;
}
-
.row-cols-sm-5 > * {
flex: 0 0 auto;
width: 20%;
}
-
.row-cols-sm-6 > * {
flex: 0 0 auto;
- width: 16.6666666667%;
+ width: 16.66666667%;
}
-
.col-sm-auto {
flex: 0 0 auto;
width: auto;
}
-
.col-sm-1 {
flex: 0 0 auto;
width: 8.33333333%;
}
-
.col-sm-2 {
flex: 0 0 auto;
width: 16.66666667%;
}
-
.col-sm-3 {
flex: 0 0 auto;
width: 25%;
}
-
.col-sm-4 {
flex: 0 0 auto;
width: 33.33333333%;
}
-
.col-sm-5 {
flex: 0 0 auto;
width: 41.66666667%;
}
-
.col-sm-6 {
flex: 0 0 auto;
width: 50%;
}
-
.col-sm-7 {
flex: 0 0 auto;
width: 58.33333333%;
}
-
.col-sm-8 {
flex: 0 0 auto;
width: 66.66666667%;
}
-
.col-sm-9 {
flex: 0 0 auto;
width: 75%;
}
-
.col-sm-10 {
flex: 0 0 auto;
width: 83.33333333%;
}
-
.col-sm-11 {
flex: 0 0 auto;
width: 91.66666667%;
}
-
.col-sm-12 {
flex: 0 0 auto;
width: 100%;
}
-
.offset-sm-0 {
margin-left: 0;
}
-
.offset-sm-1 {
margin-left: 8.33333333%;
}
-
.offset-sm-2 {
margin-left: 16.66666667%;
}
-
.offset-sm-3 {
margin-left: 25%;
}
-
.offset-sm-4 {
margin-left: 33.33333333%;
}
-
.offset-sm-5 {
margin-left: 41.66666667%;
}
-
.offset-sm-6 {
margin-left: 50%;
}
-
.offset-sm-7 {
margin-left: 58.33333333%;
}
-
.offset-sm-8 {
margin-left: 66.66666667%;
}
-
.offset-sm-9 {
margin-left: 75%;
}
-
.offset-sm-10 {
margin-left: 83.33333333%;
}
-
.offset-sm-11 {
margin-left: 91.66666667%;
}
-
.g-sm-0,
-.gx-sm-0 {
+ .gx-sm-0 {
--bs-gutter-x: 0;
}
-
.g-sm-0,
-.gy-sm-0 {
+ .gy-sm-0 {
--bs-gutter-y: 0;
}
-
.g-sm-1,
-.gx-sm-1 {
+ .gx-sm-1 {
--bs-gutter-x: 0.25rem;
}
-
.g-sm-1,
-.gy-sm-1 {
+ .gy-sm-1 {
--bs-gutter-y: 0.25rem;
}
-
.g-sm-2,
-.gx-sm-2 {
+ .gx-sm-2 {
--bs-gutter-x: 0.5rem;
}
-
.g-sm-2,
-.gy-sm-2 {
+ .gy-sm-2 {
--bs-gutter-y: 0.5rem;
}
-
.g-sm-3,
-.gx-sm-3 {
+ .gx-sm-3 {
--bs-gutter-x: 1rem;
}
-
.g-sm-3,
-.gy-sm-3 {
+ .gy-sm-3 {
--bs-gutter-y: 1rem;
}
-
.g-sm-4,
-.gx-sm-4 {
+ .gx-sm-4 {
--bs-gutter-x: 1.5rem;
}
-
.g-sm-4,
-.gy-sm-4 {
+ .gy-sm-4 {
--bs-gutter-y: 1.5rem;
}
-
.g-sm-5,
-.gx-sm-5 {
+ .gx-sm-5 {
--bs-gutter-x: 3rem;
}
-
.g-sm-5,
-.gy-sm-5 {
+ .gy-sm-5 {
--bs-gutter-y: 3rem;
}
}
@media (min-width: 768px) {
.col-md {
- flex: 1 0 0%;
+ flex: 1 0 0;
}
-
.row-cols-md-auto > * {
flex: 0 0 auto;
width: auto;
}
-
.row-cols-md-1 > * {
flex: 0 0 auto;
width: 100%;
}
-
.row-cols-md-2 > * {
flex: 0 0 auto;
width: 50%;
}
-
.row-cols-md-3 > * {
flex: 0 0 auto;
- width: 33.3333333333%;
+ width: 33.33333333%;
}
-
.row-cols-md-4 > * {
flex: 0 0 auto;
width: 25%;
}
-
.row-cols-md-5 > * {
flex: 0 0 auto;
width: 20%;
}
-
.row-cols-md-6 > * {
flex: 0 0 auto;
- width: 16.6666666667%;
+ width: 16.66666667%;
}
-
.col-md-auto {
flex: 0 0 auto;
width: auto;
}
-
.col-md-1 {
flex: 0 0 auto;
width: 8.33333333%;
}
-
.col-md-2 {
flex: 0 0 auto;
width: 16.66666667%;
}
-
.col-md-3 {
flex: 0 0 auto;
width: 25%;
}
-
.col-md-4 {
flex: 0 0 auto;
width: 33.33333333%;
}
-
.col-md-5 {
flex: 0 0 auto;
width: 41.66666667%;
}
-
.col-md-6 {
flex: 0 0 auto;
width: 50%;
}
-
.col-md-7 {
flex: 0 0 auto;
width: 58.33333333%;
}
-
.col-md-8 {
flex: 0 0 auto;
width: 66.66666667%;
}
-
.col-md-9 {
flex: 0 0 auto;
width: 75%;
}
-
.col-md-10 {
flex: 0 0 auto;
width: 83.33333333%;
}
-
.col-md-11 {
flex: 0 0 auto;
width: 91.66666667%;
}
-
.col-md-12 {
flex: 0 0 auto;
width: 100%;
}
-
.offset-md-0 {
margin-left: 0;
}
-
.offset-md-1 {
margin-left: 8.33333333%;
}
-
.offset-md-2 {
margin-left: 16.66666667%;
}
-
.offset-md-3 {
margin-left: 25%;
}
-
.offset-md-4 {
margin-left: 33.33333333%;
}
-
.offset-md-5 {
margin-left: 41.66666667%;
}
-
.offset-md-6 {
margin-left: 50%;
}
-
.offset-md-7 {
margin-left: 58.33333333%;
}
-
.offset-md-8 {
margin-left: 66.66666667%;
}
-
.offset-md-9 {
margin-left: 75%;
}
-
.offset-md-10 {
margin-left: 83.33333333%;
}
-
.offset-md-11 {
margin-left: 91.66666667%;
}
-
.g-md-0,
-.gx-md-0 {
+ .gx-md-0 {
--bs-gutter-x: 0;
}
-
.g-md-0,
-.gy-md-0 {
+ .gy-md-0 {
--bs-gutter-y: 0;
}
-
.g-md-1,
-.gx-md-1 {
+ .gx-md-1 {
--bs-gutter-x: 0.25rem;
}
-
.g-md-1,
-.gy-md-1 {
+ .gy-md-1 {
--bs-gutter-y: 0.25rem;
}
-
.g-md-2,
-.gx-md-2 {
+ .gx-md-2 {
--bs-gutter-x: 0.5rem;
}
-
.g-md-2,
-.gy-md-2 {
+ .gy-md-2 {
--bs-gutter-y: 0.5rem;
}
-
.g-md-3,
-.gx-md-3 {
+ .gx-md-3 {
--bs-gutter-x: 1rem;
}
-
.g-md-3,
-.gy-md-3 {
+ .gy-md-3 {
--bs-gutter-y: 1rem;
}
-
.g-md-4,
-.gx-md-4 {
+ .gx-md-4 {
--bs-gutter-x: 1.5rem;
}
-
.g-md-4,
-.gy-md-4 {
+ .gy-md-4 {
--bs-gutter-y: 1.5rem;
}
-
.g-md-5,
-.gx-md-5 {
+ .gx-md-5 {
--bs-gutter-x: 3rem;
}
-
.g-md-5,
-.gy-md-5 {
+ .gy-md-5 {
--bs-gutter-y: 3rem;
}
}
@media (min-width: 992px) {
.col-lg {
- flex: 1 0 0%;
+ flex: 1 0 0;
}
-
.row-cols-lg-auto > * {
flex: 0 0 auto;
width: auto;
}
-
.row-cols-lg-1 > * {
flex: 0 0 auto;
width: 100%;
}
-
.row-cols-lg-2 > * {
flex: 0 0 auto;
width: 50%;
}
-
.row-cols-lg-3 > * {
flex: 0 0 auto;
- width: 33.3333333333%;
+ width: 33.33333333%;
}
-
.row-cols-lg-4 > * {
flex: 0 0 auto;
width: 25%;
}
-
.row-cols-lg-5 > * {
flex: 0 0 auto;
width: 20%;
}
-
.row-cols-lg-6 > * {
flex: 0 0 auto;
- width: 16.6666666667%;
+ width: 16.66666667%;
}
-
.col-lg-auto {
flex: 0 0 auto;
width: auto;
}
-
.col-lg-1 {
flex: 0 0 auto;
width: 8.33333333%;
}
-
.col-lg-2 {
flex: 0 0 auto;
width: 16.66666667%;
}
-
.col-lg-3 {
flex: 0 0 auto;
width: 25%;
}
-
.col-lg-4 {
flex: 0 0 auto;
width: 33.33333333%;
}
-
.col-lg-5 {
flex: 0 0 auto;
width: 41.66666667%;
}
-
.col-lg-6 {
flex: 0 0 auto;
width: 50%;
}
-
.col-lg-7 {
flex: 0 0 auto;
width: 58.33333333%;
}
-
.col-lg-8 {
flex: 0 0 auto;
width: 66.66666667%;
}
-
.col-lg-9 {
flex: 0 0 auto;
width: 75%;
}
-
.col-lg-10 {
flex: 0 0 auto;
width: 83.33333333%;
}
-
.col-lg-11 {
flex: 0 0 auto;
width: 91.66666667%;
}
-
.col-lg-12 {
flex: 0 0 auto;
width: 100%;
}
-
.offset-lg-0 {
margin-left: 0;
}
-
.offset-lg-1 {
margin-left: 8.33333333%;
}
-
.offset-lg-2 {
margin-left: 16.66666667%;
}
-
.offset-lg-3 {
margin-left: 25%;
}
-
.offset-lg-4 {
margin-left: 33.33333333%;
}
-
.offset-lg-5 {
margin-left: 41.66666667%;
}
-
.offset-lg-6 {
margin-left: 50%;
}
-
.offset-lg-7 {
margin-left: 58.33333333%;
}
-
.offset-lg-8 {
margin-left: 66.66666667%;
}
-
.offset-lg-9 {
margin-left: 75%;
}
-
.offset-lg-10 {
margin-left: 83.33333333%;
}
-
.offset-lg-11 {
margin-left: 91.66666667%;
}
-
.g-lg-0,
-.gx-lg-0 {
+ .gx-lg-0 {
--bs-gutter-x: 0;
}
-
.g-lg-0,
-.gy-lg-0 {
+ .gy-lg-0 {
--bs-gutter-y: 0;
}
-
.g-lg-1,
-.gx-lg-1 {
+ .gx-lg-1 {
--bs-gutter-x: 0.25rem;
}
-
.g-lg-1,
-.gy-lg-1 {
+ .gy-lg-1 {
--bs-gutter-y: 0.25rem;
}
-
.g-lg-2,
-.gx-lg-2 {
+ .gx-lg-2 {
--bs-gutter-x: 0.5rem;
}
-
.g-lg-2,
-.gy-lg-2 {
+ .gy-lg-2 {
--bs-gutter-y: 0.5rem;
}
-
.g-lg-3,
-.gx-lg-3 {
+ .gx-lg-3 {
--bs-gutter-x: 1rem;
}
-
.g-lg-3,
-.gy-lg-3 {
+ .gy-lg-3 {
--bs-gutter-y: 1rem;
}
-
.g-lg-4,
-.gx-lg-4 {
+ .gx-lg-4 {
--bs-gutter-x: 1.5rem;
}
-
.g-lg-4,
-.gy-lg-4 {
+ .gy-lg-4 {
--bs-gutter-y: 1.5rem;
}
-
.g-lg-5,
-.gx-lg-5 {
+ .gx-lg-5 {
--bs-gutter-x: 3rem;
}
-
.g-lg-5,
-.gy-lg-5 {
+ .gy-lg-5 {
--bs-gutter-y: 3rem;
}
}
@media (min-width: 1200px) {
.col-xl {
- flex: 1 0 0%;
+ flex: 1 0 0;
}
-
.row-cols-xl-auto > * {
flex: 0 0 auto;
width: auto;
}
-
.row-cols-xl-1 > * {
flex: 0 0 auto;
width: 100%;
}
-
.row-cols-xl-2 > * {
flex: 0 0 auto;
width: 50%;
}
-
.row-cols-xl-3 > * {
flex: 0 0 auto;
- width: 33.3333333333%;
+ width: 33.33333333%;
}
-
.row-cols-xl-4 > * {
flex: 0 0 auto;
width: 25%;
}
-
.row-cols-xl-5 > * {
flex: 0 0 auto;
width: 20%;
}
-
.row-cols-xl-6 > * {
flex: 0 0 auto;
- width: 16.6666666667%;
+ width: 16.66666667%;
}
-
.col-xl-auto {
flex: 0 0 auto;
width: auto;
}
-
.col-xl-1 {
flex: 0 0 auto;
width: 8.33333333%;
}
-
.col-xl-2 {
flex: 0 0 auto;
width: 16.66666667%;
}
-
.col-xl-3 {
flex: 0 0 auto;
width: 25%;
}
-
.col-xl-4 {
flex: 0 0 auto;
width: 33.33333333%;
}
-
.col-xl-5 {
flex: 0 0 auto;
width: 41.66666667%;
}
-
.col-xl-6 {
flex: 0 0 auto;
width: 50%;
}
-
.col-xl-7 {
flex: 0 0 auto;
width: 58.33333333%;
}
-
.col-xl-8 {
flex: 0 0 auto;
width: 66.66666667%;
}
-
.col-xl-9 {
flex: 0 0 auto;
width: 75%;
}
-
.col-xl-10 {
flex: 0 0 auto;
width: 83.33333333%;
}
-
.col-xl-11 {
flex: 0 0 auto;
width: 91.66666667%;
}
-
.col-xl-12 {
flex: 0 0 auto;
width: 100%;
}
-
.offset-xl-0 {
margin-left: 0;
}
-
.offset-xl-1 {
margin-left: 8.33333333%;
}
-
.offset-xl-2 {
margin-left: 16.66666667%;
}
-
.offset-xl-3 {
margin-left: 25%;
}
-
.offset-xl-4 {
margin-left: 33.33333333%;
}
-
.offset-xl-5 {
margin-left: 41.66666667%;
}
-
.offset-xl-6 {
margin-left: 50%;
}
-
.offset-xl-7 {
margin-left: 58.33333333%;
}
-
.offset-xl-8 {
margin-left: 66.66666667%;
}
-
.offset-xl-9 {
margin-left: 75%;
}
-
.offset-xl-10 {
margin-left: 83.33333333%;
}
-
.offset-xl-11 {
margin-left: 91.66666667%;
}
-
.g-xl-0,
-.gx-xl-0 {
+ .gx-xl-0 {
--bs-gutter-x: 0;
}
-
.g-xl-0,
-.gy-xl-0 {
+ .gy-xl-0 {
--bs-gutter-y: 0;
}
-
.g-xl-1,
-.gx-xl-1 {
+ .gx-xl-1 {
--bs-gutter-x: 0.25rem;
}
-
.g-xl-1,
-.gy-xl-1 {
+ .gy-xl-1 {
--bs-gutter-y: 0.25rem;
}
-
.g-xl-2,
-.gx-xl-2 {
+ .gx-xl-2 {
--bs-gutter-x: 0.5rem;
}
-
.g-xl-2,
-.gy-xl-2 {
+ .gy-xl-2 {
--bs-gutter-y: 0.5rem;
}
-
.g-xl-3,
-.gx-xl-3 {
+ .gx-xl-3 {
--bs-gutter-x: 1rem;
}
-
.g-xl-3,
-.gy-xl-3 {
+ .gy-xl-3 {
--bs-gutter-y: 1rem;
}
-
.g-xl-4,
-.gx-xl-4 {
+ .gx-xl-4 {
--bs-gutter-x: 1.5rem;
}
-
.g-xl-4,
-.gy-xl-4 {
+ .gy-xl-4 {
--bs-gutter-y: 1.5rem;
}
-
.g-xl-5,
-.gx-xl-5 {
+ .gx-xl-5 {
--bs-gutter-x: 3rem;
}
-
.g-xl-5,
-.gy-xl-5 {
+ .gy-xl-5 {
--bs-gutter-y: 3rem;
}
}
@media (min-width: 1400px) {
.col-xxl {
- flex: 1 0 0%;
+ flex: 1 0 0;
}
-
.row-cols-xxl-auto > * {
flex: 0 0 auto;
width: auto;
}
-
.row-cols-xxl-1 > * {
flex: 0 0 auto;
width: 100%;
}
-
.row-cols-xxl-2 > * {
flex: 0 0 auto;
width: 50%;
}
-
.row-cols-xxl-3 > * {
flex: 0 0 auto;
- width: 33.3333333333%;
+ width: 33.33333333%;
}
-
.row-cols-xxl-4 > * {
flex: 0 0 auto;
width: 25%;
}
-
.row-cols-xxl-5 > * {
flex: 0 0 auto;
width: 20%;
}
-
.row-cols-xxl-6 > * {
flex: 0 0 auto;
- width: 16.6666666667%;
+ width: 16.66666667%;
}
-
.col-xxl-auto {
flex: 0 0 auto;
width: auto;
}
-
.col-xxl-1 {
flex: 0 0 auto;
width: 8.33333333%;
}
-
.col-xxl-2 {
flex: 0 0 auto;
width: 16.66666667%;
}
-
.col-xxl-3 {
flex: 0 0 auto;
width: 25%;
}
-
.col-xxl-4 {
flex: 0 0 auto;
width: 33.33333333%;
}
-
.col-xxl-5 {
flex: 0 0 auto;
width: 41.66666667%;
}
-
.col-xxl-6 {
flex: 0 0 auto;
width: 50%;
}
-
.col-xxl-7 {
flex: 0 0 auto;
width: 58.33333333%;
}
-
.col-xxl-8 {
flex: 0 0 auto;
width: 66.66666667%;
}
-
.col-xxl-9 {
flex: 0 0 auto;
width: 75%;
}
-
.col-xxl-10 {
flex: 0 0 auto;
width: 83.33333333%;
}
-
.col-xxl-11 {
flex: 0 0 auto;
width: 91.66666667%;
}
-
.col-xxl-12 {
flex: 0 0 auto;
width: 100%;
}
-
.offset-xxl-0 {
margin-left: 0;
}
-
.offset-xxl-1 {
margin-left: 8.33333333%;
}
-
.offset-xxl-2 {
margin-left: 16.66666667%;
}
-
.offset-xxl-3 {
margin-left: 25%;
}
-
.offset-xxl-4 {
margin-left: 33.33333333%;
}
-
.offset-xxl-5 {
margin-left: 41.66666667%;
}
-
.offset-xxl-6 {
margin-left: 50%;
}
-
.offset-xxl-7 {
margin-left: 58.33333333%;
}
-
.offset-xxl-8 {
margin-left: 66.66666667%;
}
-
.offset-xxl-9 {
margin-left: 75%;
}
-
.offset-xxl-10 {
margin-left: 83.33333333%;
}
-
.offset-xxl-11 {
margin-left: 91.66666667%;
}
-
.g-xxl-0,
-.gx-xxl-0 {
+ .gx-xxl-0 {
--bs-gutter-x: 0;
}
-
.g-xxl-0,
-.gy-xxl-0 {
+ .gy-xxl-0 {
--bs-gutter-y: 0;
}
-
.g-xxl-1,
-.gx-xxl-1 {
+ .gx-xxl-1 {
--bs-gutter-x: 0.25rem;
}
-
.g-xxl-1,
-.gy-xxl-1 {
+ .gy-xxl-1 {
--bs-gutter-y: 0.25rem;
}
-
.g-xxl-2,
-.gx-xxl-2 {
+ .gx-xxl-2 {
--bs-gutter-x: 0.5rem;
}
-
.g-xxl-2,
-.gy-xxl-2 {
+ .gy-xxl-2 {
--bs-gutter-y: 0.5rem;
}
-
.g-xxl-3,
-.gx-xxl-3 {
+ .gx-xxl-3 {
--bs-gutter-x: 1rem;
}
-
.g-xxl-3,
-.gy-xxl-3 {
+ .gy-xxl-3 {
--bs-gutter-y: 1rem;
}
-
.g-xxl-4,
-.gx-xxl-4 {
+ .gx-xxl-4 {
--bs-gutter-x: 1.5rem;
}
-
.g-xxl-4,
-.gy-xxl-4 {
+ .gy-xxl-4 {
--bs-gutter-y: 1.5rem;
}
-
.g-xxl-5,
-.gx-xxl-5 {
+ .gx-xxl-5 {
--bs-gutter-x: 3rem;
}
-
.g-xxl-5,
-.gy-xxl-5 {
+ .gy-xxl-5 {
--bs-gutter-y: 3rem;
}
}
.table {
- --bs-table-bg: transparent;
+ --bs-table-color-type: initial;
+ --bs-table-bg-type: initial;
+ --bs-table-color-state: initial;
+ --bs-table-bg-state: initial;
+ --bs-table-color: initial;
+ --bs-table-bg: var(--bs-body-bg);
+ --bs-table-border-color: var(--bs-border-color);
--bs-table-accent-bg: transparent;
- --bs-table-striped-color: #222;
- --bs-table-striped-bg: rgba(0, 0, 0, 0.05);
- --bs-table-active-color: #222;
- --bs-table-active-bg: rgba(0, 0, 0, 0.1);
- --bs-table-hover-color: #222;
- --bs-table-hover-bg: rgba(0, 0, 0, 0.075);
+ --bs-table-striped-color: initial;
+ --bs-table-striped-bg: rgba(var(--bs-emphasis-color-rgb), 0.05);
+ --bs-table-active-color: initial;
+ --bs-table-active-bg: rgba(var(--bs-emphasis-color-rgb), 0.1);
+ --bs-table-hover-color: initial;
+ --bs-table-hover-bg: rgba(var(--bs-emphasis-color-rgb), 0.075);
width: 100%;
margin-bottom: 1rem;
- color: #222;
vertical-align: top;
- border-color: #dee2e6;
+ border-color: var(--bs-table-border-color);
}
.table > :not(caption) > * > * {
padding: 0.5rem 0.5rem;
+ color: var(--bs-table-color-state, var(--bs-table-color-type, var(--bs-table-color)));
background-color: var(--bs-table-bg);
- border-bottom-width: 1px;
- box-shadow: inset 0 0 0 9999px var(--bs-table-accent-bg);
+ border-bottom-width: var(--bs-border-width);
+ box-shadow: inset 0 0 0 9999px var(--bs-table-bg-state, var(--bs-table-bg-type, var(--bs-table-accent-bg)));
}
.table > tbody {
vertical-align: inherit;
@@ -2064,8 +1977,9 @@
.table > thead {
vertical-align: bottom;
}
-.table > :not(:first-child) {
- border-top: 2px solid currentColor;
+
+.table-group-divider {
+ border-top: calc(var(--bs-border-width) * 2) solid currentcolor;
}
.caption-top {
@@ -2077,10 +1991,10 @@
}
.table-bordered > :not(caption) > * {
- border-width: 1px 0;
+ border-width: var(--bs-border-width) 0;
}
.table-bordered > :not(caption) > * > * {
- border-width: 0 1px;
+ border-width: 0 var(--bs-border-width);
}
.table-borderless > :not(caption) > * > * {
@@ -2091,114 +2005,135 @@
}
.table-striped > tbody > tr:nth-of-type(odd) > * {
- --bs-table-accent-bg: var(--bs-table-striped-bg);
- color: var(--bs-table-striped-color);
+ --bs-table-color-type: var(--bs-table-striped-color);
+ --bs-table-bg-type: var(--bs-table-striped-bg);
+}
+
+.table-striped-columns > :not(caption) > tr > :nth-child(even) {
+ --bs-table-color-type: var(--bs-table-striped-color);
+ --bs-table-bg-type: var(--bs-table-striped-bg);
}
.table-active {
- --bs-table-accent-bg: var(--bs-table-active-bg);
- color: var(--bs-table-active-color);
+ --bs-table-color-state: var(--bs-table-active-color);
+ --bs-table-bg-state: var(--bs-table-active-bg);
}
.table-hover > tbody > tr:hover > * {
- --bs-table-accent-bg: var(--bs-table-hover-bg);
- color: var(--bs-table-hover-color);
+ --bs-table-color-state: var(--bs-table-hover-color);
+ --bs-table-bg-state: var(--bs-table-hover-bg);
}
.table-primary {
+ --bs-table-color: #fff;
--bs-table-bg: #158cba;
+ --bs-table-border-color: #44a3c8;
--bs-table-striped-bg: #2192bd;
--bs-table-striped-color: #fff;
--bs-table-active-bg: #2c98c1;
--bs-table-active-color: #fff;
--bs-table-hover-bg: #2795bf;
--bs-table-hover-color: #fff;
- color: #fff;
- border-color: #2c98c1;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-secondary {
+ --bs-table-color: #000;
--bs-table-bg: #f0f0f0;
+ --bs-table-border-color: silver;
--bs-table-striped-bg: #e4e4e4;
--bs-table-striped-color: #000;
--bs-table-active-bg: #d8d8d8;
--bs-table-active-color: #000;
--bs-table-hover-bg: #dedede;
--bs-table-hover-color: #000;
- color: #000;
- border-color: #d8d8d8;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-success {
+ --bs-table-color: #fff;
--bs-table-bg: #28b62c;
+ --bs-table-border-color: #53c556;
--bs-table-striped-bg: #33ba37;
--bs-table-striped-color: #fff;
--bs-table-active-bg: #3ebd41;
--bs-table-active-color: #fff;
--bs-table-hover-bg: #38bb3c;
--bs-table-hover-color: #fff;
- color: #fff;
- border-color: #3ebd41;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-info {
+ --bs-table-color: #fff;
--bs-table-bg: #75caeb;
+ --bs-table-border-color: #91d5ef;
--bs-table-striped-bg: #7ccdec;
--bs-table-striped-color: #fff;
--bs-table-active-bg: #83cfed;
--bs-table-active-color: #000;
--bs-table-hover-bg: #7fceed;
--bs-table-hover-color: #fff;
- color: #fff;
- border-color: #83cfed;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-warning {
+ --bs-table-color: #fff;
--bs-table-bg: #ff851b;
+ --bs-table-border-color: #ff9d49;
--bs-table-striped-bg: #ff8b26;
--bs-table-striped-color: #fff;
--bs-table-active-bg: #ff9132;
--bs-table-active-color: #fff;
--bs-table-hover-bg: #ff8e2c;
--bs-table-hover-color: #fff;
- color: #fff;
- border-color: #ff9132;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-danger {
+ --bs-table-color: #fff;
--bs-table-bg: #ff4136;
+ --bs-table-border-color: #ff675e;
--bs-table-striped-bg: #ff4b40;
--bs-table-striped-color: #fff;
--bs-table-active-bg: #ff544a;
--bs-table-active-color: #fff;
--bs-table-hover-bg: #ff4f45;
--bs-table-hover-color: #fff;
- color: #fff;
- border-color: #ff544a;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-light {
+ --bs-table-color: #000;
--bs-table-bg: #f6f6f6;
+ --bs-table-border-color: #c5c5c5;
--bs-table-striped-bg: #eaeaea;
--bs-table-striped-color: #000;
--bs-table-active-bg: #dddddd;
--bs-table-active-color: #000;
--bs-table-hover-bg: #e4e4e4;
--bs-table-hover-color: #000;
- color: #000;
- border-color: #dddddd;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-dark {
+ --bs-table-color: #fff;
--bs-table-bg: #555;
+ --bs-table-border-color: #777777;
--bs-table-striped-bg: #5e5e5e;
--bs-table-striped-color: #fff;
--bs-table-active-bg: #666666;
--bs-table-active-color: #fff;
--bs-table-hover-bg: #626262;
--bs-table-hover-color: #fff;
- color: #fff;
- border-color: #666666;
+ color: var(--bs-table-color);
+ border-color: var(--bs-table-border-color);
}
.table-responsive {
@@ -2241,29 +2176,29 @@
}
.col-form-label {
- padding-top: calc(0.375rem + 1px);
- padding-bottom: calc(0.375rem + 1px);
+ padding-top: calc(0.375rem + var(--bs-border-width));
+ padding-bottom: calc(0.375rem + var(--bs-border-width));
margin-bottom: 0;
font-size: inherit;
line-height: 1.5;
}
.col-form-label-lg {
- padding-top: calc(0.5rem + 1px);
- padding-bottom: calc(0.5rem + 1px);
+ padding-top: calc(0.5rem + var(--bs-border-width));
+ padding-bottom: calc(0.5rem + var(--bs-border-width));
font-size: 1.25rem;
}
.col-form-label-sm {
- padding-top: calc(0.25rem + 1px);
- padding-bottom: calc(0.25rem + 1px);
+ padding-top: calc(0.25rem + var(--bs-border-width));
+ padding-bottom: calc(0.25rem + var(--bs-border-width));
font-size: 0.875rem;
}
.form-text {
margin-top: 0.25rem;
font-size: 0.875em;
- color: #999;
+ color: var(--bs-secondary-color);
}
.form-control {
@@ -2273,14 +2208,14 @@
font-size: 1rem;
font-weight: 400;
line-height: 1.5;
- color: #222;
- background-color: #fff;
- background-clip: padding-box;
- border: 1px solid #ced4da;
+ color: var(--bs-body-color);
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
- border-radius: 0.25rem;
+ background-color: var(--bs-body-bg);
+ background-clip: padding-box;
+ border: var(--bs-border-width) solid var(--bs-border-color);
+ border-radius: var(--bs-border-radius);
transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
@media (prefers-reduced-motion: reduce) {
@@ -2295,25 +2230,31 @@
cursor: pointer;
}
.form-control:focus {
- color: #222;
- background-color: #fff;
+ color: var(--bs-body-color);
+ background-color: var(--bs-body-bg);
border-color: #8ac6dd;
outline: 0;
box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
}
.form-control::-webkit-date-and-time-value {
+ min-width: 85px;
height: 1.5em;
+ margin: 0;
+}
+.form-control::-webkit-datetime-edit {
+ display: block;
+ padding: 0;
}
.form-control::-moz-placeholder {
- color: #999;
+ color: var(--bs-secondary-color);
opacity: 1;
}
.form-control::placeholder {
- color: #999;
+ color: var(--bs-secondary-color);
opacity: 1;
}
-.form-control:disabled, .form-control[readonly] {
- background-color: #f0f0f0;
+.form-control:disabled {
+ background-color: var(--bs-secondary-bg);
opacity: 1;
}
.form-control::-webkit-file-upload-button {
@@ -2321,13 +2262,13 @@
margin: -0.375rem -0.75rem;
-webkit-margin-end: 0.75rem;
margin-inline-end: 0.75rem;
- color: #222;
- background-color: #f0f0f0;
+ color: var(--bs-body-color);
+ background-color: var(--bs-tertiary-bg);
pointer-events: none;
border-color: inherit;
border-style: solid;
border-width: 0;
- border-inline-end-width: 1px;
+ border-inline-end-width: var(--bs-border-width);
border-radius: 0;
-webkit-transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
@@ -2337,13 +2278,13 @@
margin: -0.375rem -0.75rem;
-webkit-margin-end: 0.75rem;
margin-inline-end: 0.75rem;
- color: #222;
- background-color: #f0f0f0;
+ color: var(--bs-body-color);
+ background-color: var(--bs-tertiary-bg);
pointer-events: none;
border-color: inherit;
border-style: solid;
border-width: 0;
- border-inline-end-width: 1px;
+ border-inline-end-width: var(--bs-border-width);
border-radius: 0;
transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
@@ -2357,35 +2298,10 @@
}
}
.form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button {
- background-color: #e4e4e4;
+ background-color: var(--bs-secondary-bg);
}
.form-control:hover:not(:disabled):not([readonly])::file-selector-button {
- background-color: #e4e4e4;
-}
-.form-control::-webkit-file-upload-button {
- padding: 0.375rem 0.75rem;
- margin: -0.375rem -0.75rem;
- -webkit-margin-end: 0.75rem;
- margin-inline-end: 0.75rem;
- color: #222;
- background-color: #f0f0f0;
- pointer-events: none;
- border-color: inherit;
- border-style: solid;
- border-width: 0;
- border-inline-end-width: 1px;
- border-radius: 0;
- -webkit-transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
- transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
-}
-@media (prefers-reduced-motion: reduce) {
- .form-control::-webkit-file-upload-button {
- -webkit-transition: none;
- transition: none;
- }
-}
-.form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button {
- background-color: #e4e4e4;
+ background-color: var(--bs-secondary-bg);
}
.form-control-plaintext {
@@ -2394,10 +2310,13 @@
padding: 0.375rem 0;
margin-bottom: 0;
line-height: 1.5;
- color: #222;
+ color: var(--bs-body-color);
background-color: transparent;
border: solid transparent;
- border-width: 1px 0;
+ border-width: var(--bs-border-width) 0;
+}
+.form-control-plaintext:focus {
+ outline: 0;
}
.form-control-plaintext.form-control-sm, .form-control-plaintext.form-control-lg {
padding-right: 0;
@@ -2405,10 +2324,10 @@
}
.form-control-sm {
- min-height: calc(1.5em + 0.5rem + 2px);
+ min-height: calc(1.5em + 0.5rem + calc(var(--bs-border-width) * 2));
padding: 0.25rem 0.5rem;
font-size: 0.875rem;
- border-radius: 0.2rem;
+ border-radius: var(--bs-border-radius-sm);
}
.form-control-sm::-webkit-file-upload-button {
padding: 0.25rem 0.5rem;
@@ -2422,18 +2341,12 @@
-webkit-margin-end: 0.5rem;
margin-inline-end: 0.5rem;
}
-.form-control-sm::-webkit-file-upload-button {
- padding: 0.25rem 0.5rem;
- margin: -0.25rem -0.5rem;
- -webkit-margin-end: 0.5rem;
- margin-inline-end: 0.5rem;
-}
.form-control-lg {
- min-height: calc(1.5em + 1rem + 2px);
+ min-height: calc(1.5em + 1rem + calc(var(--bs-border-width) * 2));
padding: 0.5rem 1rem;
font-size: 1.25rem;
- border-radius: 0.3rem;
+ border-radius: var(--bs-border-radius-lg);
}
.form-control-lg::-webkit-file-upload-button {
padding: 0.5rem 1rem;
@@ -2447,60 +2360,60 @@
-webkit-margin-end: 1rem;
margin-inline-end: 1rem;
}
-.form-control-lg::-webkit-file-upload-button {
- padding: 0.5rem 1rem;
- margin: -0.5rem -1rem;
- -webkit-margin-end: 1rem;
- margin-inline-end: 1rem;
-}
textarea.form-control {
- min-height: calc(1.5em + 0.75rem + 2px);
+ min-height: calc(1.5em + 0.75rem + calc(var(--bs-border-width) * 2));
}
textarea.form-control-sm {
- min-height: calc(1.5em + 0.5rem + 2px);
+ min-height: calc(1.5em + 0.5rem + calc(var(--bs-border-width) * 2));
}
textarea.form-control-lg {
- min-height: calc(1.5em + 1rem + 2px);
+ min-height: calc(1.5em + 1rem + calc(var(--bs-border-width) * 2));
}
.form-control-color {
width: 3rem;
- height: auto;
+ height: calc(1.5em + 0.75rem + calc(var(--bs-border-width) * 2));
padding: 0.375rem;
}
.form-control-color:not(:disabled):not([readonly]) {
cursor: pointer;
}
.form-control-color::-moz-color-swatch {
- height: 1.5em;
- border-radius: 0.25rem;
+ border: 0 !important;
+ border-radius: var(--bs-border-radius);
}
.form-control-color::-webkit-color-swatch {
- height: 1.5em;
- border-radius: 0.25rem;
+ border: 0 !important;
+ border-radius: var(--bs-border-radius);
+}
+.form-control-color.form-control-sm {
+ height: calc(1.5em + 0.5rem + calc(var(--bs-border-width) * 2));
+}
+.form-control-color.form-control-lg {
+ height: calc(1.5em + 1rem + calc(var(--bs-border-width) * 2));
}
.form-select {
+ --bs-form-select-bg-img: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23333' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
display: block;
width: 100%;
padding: 0.375rem 2.25rem 0.375rem 0.75rem;
- -moz-padding-start: calc(0.75rem - 3px);
font-size: 1rem;
font-weight: 400;
line-height: 1.5;
- color: #222;
- background-color: #fff;
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23333' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
- background-repeat: no-repeat;
- background-position: right 0.75rem center;
- background-size: 16px 12px;
- border: 1px solid #ced4da;
- border-radius: 0.25rem;
- transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
+ color: var(--bs-body-color);
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
+ background-color: var(--bs-body-bg);
+ background-image: var(--bs-form-select-bg-img), var(--bs-form-select-bg-icon, none);
+ background-repeat: no-repeat;
+ background-position: right 0.75rem center;
+ background-size: 16px 12px;
+ border: var(--bs-border-width) solid var(--bs-border-color);
+ border-radius: var(--bs-border-radius);
+ transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
@media (prefers-reduced-motion: reduce) {
.form-select {
@@ -2517,11 +2430,11 @@
background-image: none;
}
.form-select:disabled {
- background-color: #f0f0f0;
+ background-color: var(--bs-secondary-bg);
}
.form-select:-moz-focusring {
color: transparent;
- text-shadow: 0 0 0 #222;
+ text-shadow: 0 0 0 var(--bs-body-color);
}
.form-select-sm {
@@ -2529,7 +2442,7 @@
padding-bottom: 0.25rem;
padding-left: 0.5rem;
font-size: 0.875rem;
- border-radius: 0.2rem;
+ border-radius: var(--bs-border-radius-sm);
}
.form-select-lg {
@@ -2537,7 +2450,11 @@
padding-bottom: 0.5rem;
padding-left: 1rem;
font-size: 1.25rem;
- border-radius: 0.3rem;
+ border-radius: var(--bs-border-radius-lg);
+}
+
+[data-bs-theme=dark] .form-select {
+ --bs-form-select-bg-img: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23dee2e6' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}
.form-check {
@@ -2551,21 +2468,36 @@
margin-left: -1.5em;
}
+.form-check-reverse {
+ padding-right: 1.5em;
+ padding-left: 0;
+ text-align: right;
+}
+.form-check-reverse .form-check-input {
+ float: right;
+ margin-right: -1.5em;
+ margin-left: 0;
+}
+
.form-check-input {
+ --bs-form-check-bg: var(--bs-body-bg);
+ flex-shrink: 0;
width: 1em;
height: 1em;
margin-top: 0.25em;
vertical-align: top;
- background-color: #fff;
- background-repeat: no-repeat;
- background-position: center;
- background-size: contain;
- border: 1px solid rgba(0, 0, 0, 0.25);
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
+ background-color: var(--bs-form-check-bg);
+ background-image: var(--bs-form-check-bg-image);
+ background-repeat: no-repeat;
+ background-position: center;
+ background-size: contain;
+ border: var(--bs-border-width) solid var(--bs-border-color);
-webkit-print-color-adjust: exact;
color-adjust: exact;
+ print-color-adjust: exact;
}
.form-check-input[type=checkbox] {
border-radius: 0.25em;
@@ -2586,15 +2518,15 @@
border-color: #158cba;
}
.form-check-input:checked[type=checkbox] {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10l3 3l6-6'/%3e%3c/svg%3e");
+ --bs-form-check-bg-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
}
.form-check-input:checked[type=radio] {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='2' fill='%23fff'/%3e%3c/svg%3e");
+ --bs-form-check-bg-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='2' fill='%23fff'/%3e%3c/svg%3e");
}
.form-check-input[type=checkbox]:indeterminate {
background-color: #158cba;
border-color: #158cba;
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10h8'/%3e%3c/svg%3e");
+ --bs-form-check-bg-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='M6 10h8'/%3e%3c/svg%3e");
}
.form-check-input:disabled {
pointer-events: none;
@@ -2602,6 +2534,7 @@
opacity: 0.5;
}
.form-check-input[disabled] ~ .form-check-label, .form-check-input:disabled ~ .form-check-label {
+ cursor: default;
opacity: 0.5;
}
@@ -2609,9 +2542,10 @@
padding-left: 2.5em;
}
.form-switch .form-check-input {
+ --bs-form-switch-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%280, 0, 0, 0.25%29'/%3e%3c/svg%3e");
width: 2em;
margin-left: -2.5em;
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%280, 0, 0, 0.25%29'/%3e%3c/svg%3e");
+ background-image: var(--bs-form-switch-bg);
background-position: left center;
border-radius: 2em;
transition: background-position 0.15s ease-in-out;
@@ -2622,11 +2556,19 @@
}
}
.form-switch .form-check-input:focus {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%238ac6dd'/%3e%3c/svg%3e");
+ --bs-form-switch-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%238ac6dd'/%3e%3c/svg%3e");
}
.form-switch .form-check-input:checked {
background-position: right center;
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
+ --bs-form-switch-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
+}
+.form-switch.form-check-reverse {
+ padding-right: 2.5em;
+ padding-left: 0;
+}
+.form-switch.form-check-reverse .form-check-input {
+ margin-right: -2.5em;
+ margin-left: 0;
}
.form-check-inline {
@@ -2645,14 +2587,18 @@
opacity: 0.65;
}
+[data-bs-theme=dark] .form-switch .form-check-input:not(:checked):not(:focus) {
+ --bs-form-switch-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%28255, 255, 255, 0.25%29'/%3e%3c/svg%3e");
+}
+
.form-range {
width: 100%;
height: 1.5rem;
padding: 0;
- background-color: transparent;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
+ background-color: transparent;
}
.form-range:focus {
outline: 0;
@@ -2670,13 +2616,13 @@
width: 1rem;
height: 1rem;
margin-top: -0.25rem;
+ -webkit-appearance: none;
+ appearance: none;
background-color: #158cba;
border: 0;
border-radius: 1rem;
-webkit-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
- -webkit-appearance: none;
- appearance: none;
}
@media (prefers-reduced-motion: reduce) {
.form-range::-webkit-slider-thumb {
@@ -2692,20 +2638,20 @@
height: 0.5rem;
color: transparent;
cursor: pointer;
- background-color: #dee2e6;
+ background-color: var(--bs-secondary-bg);
border-color: transparent;
border-radius: 1rem;
}
.form-range::-moz-range-thumb {
width: 1rem;
height: 1rem;
+ -moz-appearance: none;
+ appearance: none;
background-color: #158cba;
border: 0;
border-radius: 1rem;
-moz-transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
transition: background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
- -moz-appearance: none;
- appearance: none;
}
@media (prefers-reduced-motion: reduce) {
.form-range::-moz-range-thumb {
@@ -2721,7 +2667,7 @@
height: 0.5rem;
color: transparent;
cursor: pointer;
- background-color: #dee2e6;
+ background-color: var(--bs-secondary-bg);
border-color: transparent;
border-radius: 1rem;
}
@@ -2729,28 +2675,37 @@
pointer-events: none;
}
.form-range:disabled::-webkit-slider-thumb {
- background-color: #adb5bd;
+ background-color: var(--bs-secondary-color);
}
.form-range:disabled::-moz-range-thumb {
- background-color: #adb5bd;
+ background-color: var(--bs-secondary-color);
}
.form-floating {
position: relative;
}
.form-floating > .form-control,
+.form-floating > .form-control-plaintext,
.form-floating > .form-select {
- height: calc(3.5rem + 2px);
+ height: calc(3.5rem + calc(var(--bs-border-width) * 2));
+ min-height: calc(3.5rem + calc(var(--bs-border-width) * 2));
line-height: 1.25;
}
.form-floating > label {
position: absolute;
top: 0;
left: 0;
+ z-index: 2;
+ max-width: 100%;
height: 100%;
padding: 1rem 0.75rem;
+ overflow: hidden;
+ color: rgba(var(--bs-body-color-rgb), 0.65);
+ text-align: start;
+ text-overflow: ellipsis;
+ white-space: nowrap;
pointer-events: none;
- border: 1px solid transparent;
+ border: var(--bs-border-width) solid transparent;
transform-origin: 0 0;
transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out;
}
@@ -2759,45 +2714,78 @@
transition: none;
}
}
-.form-floating > .form-control {
+.form-floating > .form-control,
+.form-floating > .form-control-plaintext {
padding: 1rem 0.75rem;
}
-.form-floating > .form-control::-moz-placeholder {
+.form-floating > .form-control::-moz-placeholder, .form-floating > .form-control-plaintext::-moz-placeholder {
color: transparent;
}
-.form-floating > .form-control::placeholder {
+.form-floating > .form-control::placeholder,
+.form-floating > .form-control-plaintext::placeholder {
color: transparent;
}
-.form-floating > .form-control:not(:-moz-placeholder-shown) {
+.form-floating > .form-control:not(:-moz-placeholder-shown), .form-floating > .form-control-plaintext:not(:-moz-placeholder-shown) {
padding-top: 1.625rem;
padding-bottom: 0.625rem;
}
-.form-floating > .form-control:focus, .form-floating > .form-control:not(:placeholder-shown) {
+.form-floating > .form-control:focus, .form-floating > .form-control:not(:placeholder-shown),
+.form-floating > .form-control-plaintext:focus,
+.form-floating > .form-control-plaintext:not(:placeholder-shown) {
padding-top: 1.625rem;
padding-bottom: 0.625rem;
}
-.form-floating > .form-control:-webkit-autofill {
+.form-floating > .form-control:-webkit-autofill,
+.form-floating > .form-control-plaintext:-webkit-autofill {
padding-top: 1.625rem;
padding-bottom: 0.625rem;
}
.form-floating > .form-select {
padding-top: 1.625rem;
padding-bottom: 0.625rem;
+ padding-left: 0.75rem;
}
.form-floating > .form-control:not(:-moz-placeholder-shown) ~ label {
- opacity: 0.65;
transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}
.form-floating > .form-control:focus ~ label,
.form-floating > .form-control:not(:placeholder-shown) ~ label,
+.form-floating > .form-control-plaintext ~ label,
.form-floating > .form-select ~ label {
- opacity: 0.65;
transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}
.form-floating > .form-control:-webkit-autofill ~ label {
- opacity: 0.65;
transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}
+.form-floating > textarea:not(:-moz-placeholder-shown) ~ label::after {
+ position: absolute;
+ inset: 1rem 0.375rem;
+ z-index: -1;
+ height: 1.5em;
+ content: "";
+ background-color: var(--bs-body-bg);
+ border-radius: var(--bs-border-radius);
+}
+.form-floating > textarea:focus ~ label::after,
+.form-floating > textarea:not(:placeholder-shown) ~ label::after {
+ position: absolute;
+ inset: 1rem 0.375rem;
+ z-index: -1;
+ height: 1.5em;
+ content: "";
+ background-color: var(--bs-body-bg);
+ border-radius: var(--bs-border-radius);
+}
+.form-floating > textarea:disabled ~ label::after {
+ background-color: var(--bs-secondary-bg);
+}
+.form-floating > .form-control-plaintext ~ label {
+ border-width: var(--bs-border-width) 0;
+}
+.form-floating > :disabled ~ label,
+.form-floating > .form-control:disabled ~ label {
+ color: #999;
+}
.input-group {
position: relative;
@@ -2807,22 +2795,24 @@
width: 100%;
}
.input-group > .form-control,
-.input-group > .form-select {
+.input-group > .form-select,
+.input-group > .form-floating {
position: relative;
flex: 1 1 auto;
width: 1%;
min-width: 0;
}
.input-group > .form-control:focus,
-.input-group > .form-select:focus {
- z-index: 3;
+.input-group > .form-select:focus,
+.input-group > .form-floating:focus-within {
+ z-index: 5;
}
.input-group .btn {
position: relative;
z-index: 2;
}
.input-group .btn:focus {
- z-index: 3;
+ z-index: 5;
}
.input-group-text {
@@ -2832,12 +2822,12 @@
font-size: 1rem;
font-weight: 400;
line-height: 1.5;
- color: #222;
+ color: var(--bs-body-color);
text-align: center;
white-space: nowrap;
- background-color: #f0f0f0;
- border: 1px solid #ced4da;
- border-radius: 0.25rem;
+ background-color: var(--bs-tertiary-bg);
+ border: var(--bs-border-width) solid var(--bs-border-color);
+ border-radius: var(--bs-border-radius);
}
.input-group-lg > .form-control,
@@ -2846,7 +2836,7 @@
.input-group-lg > .btn {
padding: 0.5rem 1rem;
font-size: 1.25rem;
- border-radius: 0.3rem;
+ border-radius: var(--bs-border-radius-lg);
}
.input-group-sm > .form-control,
@@ -2855,7 +2845,7 @@
.input-group-sm > .btn {
padding: 0.25rem 0.5rem;
font-size: 0.875rem;
- border-radius: 0.2rem;
+ border-radius: var(--bs-border-radius-sm);
}
.input-group-lg > .form-select,
@@ -2863,18 +2853,27 @@
padding-right: 3rem;
}
-.input-group:not(.has-validation) > :not(:last-child):not(.dropdown-toggle):not(.dropdown-menu),
-.input-group:not(.has-validation) > .dropdown-toggle:nth-last-child(n+3) {
+.input-group:not(.has-validation) > :not(:last-child):not(.dropdown-toggle):not(.dropdown-menu):not(.form-floating),
+.input-group:not(.has-validation) > .dropdown-toggle:nth-last-child(n+3),
+.input-group:not(.has-validation) > .form-floating:not(:last-child) > .form-control,
+.input-group:not(.has-validation) > .form-floating:not(:last-child) > .form-select {
border-top-right-radius: 0;
border-bottom-right-radius: 0;
}
-.input-group.has-validation > :nth-last-child(n+3):not(.dropdown-toggle):not(.dropdown-menu),
-.input-group.has-validation > .dropdown-toggle:nth-last-child(n+4) {
+.input-group.has-validation > :nth-last-child(n+3):not(.dropdown-toggle):not(.dropdown-menu):not(.form-floating),
+.input-group.has-validation > .dropdown-toggle:nth-last-child(n+4),
+.input-group.has-validation > .form-floating:nth-last-child(n+3) > .form-control,
+.input-group.has-validation > .form-floating:nth-last-child(n+3) > .form-select {
border-top-right-radius: 0;
border-bottom-right-radius: 0;
}
.input-group > :not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback) {
- margin-left: -1px;
+ margin-left: calc(-1 * var(--bs-border-width));
+ border-top-left-radius: 0;
+ border-bottom-left-radius: 0;
+}
+.input-group > .form-floating:not(:first-child) > .form-control,
+.input-group > .form-floating:not(:first-child) > .form-select {
border-top-left-radius: 0;
border-bottom-left-radius: 0;
}
@@ -2884,7 +2883,7 @@
width: 100%;
margin-top: 0.25rem;
font-size: 0.875em;
- color: #28b62c;
+ color: var(--bs-form-valid-color);
}
.valid-tooltip {
@@ -2897,8 +2896,8 @@
margin-top: 0.1rem;
font-size: 0.875rem;
color: #fff;
- background-color: rgba(40, 182, 44, 0.9);
- border-radius: 0.25rem;
+ background-color: var(--bs-success);
+ border-radius: var(--bs-border-radius);
}
.was-validated :valid ~ .valid-feedback,
@@ -2909,16 +2908,16 @@
}
.was-validated .form-control:valid, .form-control.is-valid {
- border-color: #28b62c;
+ border-color: var(--bs-form-valid-border-color);
padding-right: calc(1.5em + 0.75rem);
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2328b62c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2328b62c' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1'/%3e%3c/svg%3e");
background-repeat: no-repeat;
background-position: right calc(0.375em + 0.1875rem) center;
background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}
.was-validated .form-control:valid:focus, .form-control.is-valid:focus {
- border-color: #28b62c;
- box-shadow: 0 0 0 0.25rem rgba(40, 182, 44, 0.25);
+ border-color: var(--bs-form-valid-border-color);
+ box-shadow: 0 0 0 0.25rem rgba(var(--bs-success-rgb), 0.25);
}
.was-validated textarea.form-control:valid, textarea.form-control.is-valid {
@@ -2927,44 +2926,45 @@
}
.was-validated .form-select:valid, .form-select.is-valid {
- border-color: #28b62c;
+ border-color: var(--bs-form-valid-border-color);
}
.was-validated .form-select:valid:not([multiple]):not([size]), .was-validated .form-select:valid:not([multiple])[size="1"], .form-select.is-valid:not([multiple]):not([size]), .form-select.is-valid:not([multiple])[size="1"] {
+ --bs-form-select-bg-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2328b62c' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1'/%3e%3c/svg%3e");
padding-right: 4.125rem;
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23333' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e"), url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2328b62c' d='M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
background-position: right 0.75rem center, center right 2.25rem;
background-size: 16px 12px, calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}
.was-validated .form-select:valid:focus, .form-select.is-valid:focus {
- border-color: #28b62c;
- box-shadow: 0 0 0 0.25rem rgba(40, 182, 44, 0.25);
+ border-color: var(--bs-form-valid-border-color);
+ box-shadow: 0 0 0 0.25rem rgba(var(--bs-success-rgb), 0.25);
+}
+
+.was-validated .form-control-color:valid, .form-control-color.is-valid {
+ width: calc(3rem + calc(1.5em + 0.75rem));
}
.was-validated .form-check-input:valid, .form-check-input.is-valid {
- border-color: #28b62c;
+ border-color: var(--bs-form-valid-border-color);
}
.was-validated .form-check-input:valid:checked, .form-check-input.is-valid:checked {
- background-color: #28b62c;
+ background-color: var(--bs-form-valid-color);
}
.was-validated .form-check-input:valid:focus, .form-check-input.is-valid:focus {
- box-shadow: 0 0 0 0.25rem rgba(40, 182, 44, 0.25);
+ box-shadow: 0 0 0 0.25rem rgba(var(--bs-success-rgb), 0.25);
}
.was-validated .form-check-input:valid ~ .form-check-label, .form-check-input.is-valid ~ .form-check-label {
- color: #28b62c;
+ color: var(--bs-form-valid-color);
}
.form-check-inline .form-check-input ~ .valid-feedback {
margin-left: 0.5em;
}
-.was-validated .input-group .form-control:valid, .input-group .form-control.is-valid,
-.was-validated .input-group .form-select:valid,
-.input-group .form-select.is-valid {
- z-index: 1;
-}
-.was-validated .input-group .form-control:valid:focus, .input-group .form-control.is-valid:focus,
-.was-validated .input-group .form-select:valid:focus,
-.input-group .form-select.is-valid:focus {
+.was-validated .input-group > .form-control:not(:focus):valid, .input-group > .form-control:not(:focus).is-valid,
+.was-validated .input-group > .form-select:not(:focus):valid,
+.input-group > .form-select:not(:focus).is-valid,
+.was-validated .input-group > .form-floating:not(:focus-within):valid,
+.input-group > .form-floating:not(:focus-within).is-valid {
z-index: 3;
}
@@ -2973,7 +2973,7 @@
width: 100%;
margin-top: 0.25rem;
font-size: 0.875em;
- color: #ff4136;
+ color: var(--bs-form-invalid-color);
}
.invalid-tooltip {
@@ -2986,8 +2986,8 @@
margin-top: 0.1rem;
font-size: 0.875rem;
color: #fff;
- background-color: rgba(255, 65, 54, 0.9);
- border-radius: 0.25rem;
+ background-color: var(--bs-danger);
+ border-radius: var(--bs-border-radius);
}
.was-validated :invalid ~ .invalid-feedback,
@@ -2998,7 +2998,7 @@
}
.was-validated .form-control:invalid, .form-control.is-invalid {
- border-color: #ff4136;
+ border-color: var(--bs-form-invalid-border-color);
padding-right: calc(1.5em + 0.75rem);
background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23ff4136'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23ff4136' stroke='none'/%3e%3c/svg%3e");
background-repeat: no-repeat;
@@ -3006,8 +3006,8 @@
background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}
.was-validated .form-control:invalid:focus, .form-control.is-invalid:focus {
- border-color: #ff4136;
- box-shadow: 0 0 0 0.25rem rgba(255, 65, 54, 0.25);
+ border-color: var(--bs-form-invalid-border-color);
+ box-shadow: 0 0 0 0.25rem rgba(var(--bs-danger-rgb), 0.25);
}
.was-validated textarea.form-control:invalid, textarea.form-control.is-invalid {
@@ -3016,52 +3016,71 @@
}
.was-validated .form-select:invalid, .form-select.is-invalid {
- border-color: #ff4136;
+ border-color: var(--bs-form-invalid-border-color);
}
.was-validated .form-select:invalid:not([multiple]):not([size]), .was-validated .form-select:invalid:not([multiple])[size="1"], .form-select.is-invalid:not([multiple]):not([size]), .form-select.is-invalid:not([multiple])[size="1"] {
+ --bs-form-select-bg-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23ff4136'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23ff4136' stroke='none'/%3e%3c/svg%3e");
padding-right: 4.125rem;
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23333' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e"), url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23ff4136'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23ff4136' stroke='none'/%3e%3c/svg%3e");
background-position: right 0.75rem center, center right 2.25rem;
background-size: 16px 12px, calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}
.was-validated .form-select:invalid:focus, .form-select.is-invalid:focus {
- border-color: #ff4136;
- box-shadow: 0 0 0 0.25rem rgba(255, 65, 54, 0.25);
+ border-color: var(--bs-form-invalid-border-color);
+ box-shadow: 0 0 0 0.25rem rgba(var(--bs-danger-rgb), 0.25);
+}
+
+.was-validated .form-control-color:invalid, .form-control-color.is-invalid {
+ width: calc(3rem + calc(1.5em + 0.75rem));
}
.was-validated .form-check-input:invalid, .form-check-input.is-invalid {
- border-color: #ff4136;
+ border-color: var(--bs-form-invalid-border-color);
}
.was-validated .form-check-input:invalid:checked, .form-check-input.is-invalid:checked {
- background-color: #ff4136;
+ background-color: var(--bs-form-invalid-color);
}
.was-validated .form-check-input:invalid:focus, .form-check-input.is-invalid:focus {
- box-shadow: 0 0 0 0.25rem rgba(255, 65, 54, 0.25);
+ box-shadow: 0 0 0 0.25rem rgba(var(--bs-danger-rgb), 0.25);
}
.was-validated .form-check-input:invalid ~ .form-check-label, .form-check-input.is-invalid ~ .form-check-label {
- color: #ff4136;
+ color: var(--bs-form-invalid-color);
}
.form-check-inline .form-check-input ~ .invalid-feedback {
margin-left: 0.5em;
}
-.was-validated .input-group .form-control:invalid, .input-group .form-control.is-invalid,
-.was-validated .input-group .form-select:invalid,
-.input-group .form-select.is-invalid {
- z-index: 2;
-}
-.was-validated .input-group .form-control:invalid:focus, .input-group .form-control.is-invalid:focus,
-.was-validated .input-group .form-select:invalid:focus,
-.input-group .form-select.is-invalid:focus {
- z-index: 3;
+.was-validated .input-group > .form-control:not(:focus):invalid, .input-group > .form-control:not(:focus).is-invalid,
+.was-validated .input-group > .form-select:not(:focus):invalid,
+.input-group > .form-select:not(:focus).is-invalid,
+.was-validated .input-group > .form-floating:not(:focus-within):invalid,
+.input-group > .form-floating:not(:focus-within).is-invalid {
+ z-index: 4;
}
.btn {
+ --bs-btn-padding-x: 0.75rem;
+ --bs-btn-padding-y: 0.375rem;
+ --bs-btn-font-family: ;
+ --bs-btn-font-size: 1rem;
+ --bs-btn-font-weight: 700;
+ --bs-btn-line-height: 1.5;
+ --bs-btn-color: var(--bs-body-color);
+ --bs-btn-bg: transparent;
+ --bs-btn-border-width: var(--bs-border-width);
+ --bs-btn-border-color: transparent;
+ --bs-btn-border-radius: var(--bs-border-radius);
+ --bs-btn-hover-border-color: transparent;
+ --bs-btn-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 1px rgba(0, 0, 0, 0.075);
+ --bs-btn-disabled-opacity: 0.65;
+ --bs-btn-focus-box-shadow: 0 0 0 0.25rem rgba(var(--bs-btn-focus-shadow-rgb), .5);
display: inline-block;
- font-weight: 700;
- line-height: 1.5;
- color: #222;
+ padding: var(--bs-btn-padding-y) var(--bs-btn-padding-x);
+ font-family: var(--bs-btn-font-family);
+ font-size: var(--bs-btn-font-size);
+ font-weight: var(--bs-btn-font-weight);
+ line-height: var(--bs-btn-line-height);
+ color: var(--bs-btn-color);
text-align: center;
text-decoration: none;
vertical-align: middle;
@@ -3069,11 +3088,9 @@
-webkit-user-select: none;
-moz-user-select: none;
user-select: none;
- background-color: transparent;
- border: 1px solid transparent;
- padding: 0.375rem 0.75rem;
- font-size: 1rem;
- border-radius: 0.25rem;
+ border: var(--bs-btn-border-width) solid var(--bs-btn-border-color);
+ border-radius: var(--bs-btn-border-radius);
+ background-color: var(--bs-btn-bg);
transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
@media (prefers-reduced-motion: reduce) {
@@ -3082,479 +3099,352 @@
}
}
.btn:hover {
- color: #222;
+ color: var(--bs-btn-hover-color);
+ background-color: var(--bs-btn-hover-bg);
+ border-color: var(--bs-btn-hover-border-color);
}
-.btn-check:focus + .btn, .btn:focus {
+.btn-check + .btn:hover {
+ color: var(--bs-btn-color);
+ background-color: var(--bs-btn-bg);
+ border-color: var(--bs-btn-border-color);
+}
+.btn:focus-visible {
+ color: var(--bs-btn-hover-color);
+ background-color: var(--bs-btn-hover-bg);
+ border-color: var(--bs-btn-hover-border-color);
outline: 0;
- box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
+ box-shadow: var(--bs-btn-focus-box-shadow);
+}
+.btn-check:focus-visible + .btn {
+ border-color: var(--bs-btn-hover-border-color);
+ outline: 0;
+ box-shadow: var(--bs-btn-focus-box-shadow);
+}
+.btn-check:checked + .btn, :not(.btn-check) + .btn:active, .btn:first-child:active, .btn.active, .btn.show {
+ color: var(--bs-btn-active-color);
+ background-color: var(--bs-btn-active-bg);
+ border-color: var(--bs-btn-active-border-color);
+}
+.btn-check:checked + .btn:focus-visible, :not(.btn-check) + .btn:active:focus-visible, .btn:first-child:active:focus-visible, .btn.active:focus-visible, .btn.show:focus-visible {
+ box-shadow: var(--bs-btn-focus-box-shadow);
+}
+.btn-check:checked:focus-visible + .btn {
+ box-shadow: var(--bs-btn-focus-box-shadow);
}
.btn:disabled, .btn.disabled, fieldset:disabled .btn {
+ color: var(--bs-btn-disabled-color);
pointer-events: none;
- opacity: 0.65;
+ background-color: var(--bs-btn-disabled-bg);
+ border-color: var(--bs-btn-disabled-border-color);
+ opacity: var(--bs-btn-disabled-opacity);
}
.btn-primary {
- color: #fff;
- background-color: #158cba;
- border-color: #158cba;
-}
-.btn-primary:hover {
- color: #fff;
- background-color: #12779e;
- border-color: #117095;
-}
-.btn-check:focus + .btn-primary, .btn-primary:focus {
- color: #fff;
- background-color: #12779e;
- border-color: #117095;
- box-shadow: 0 0 0 0.25rem rgba(56, 157, 196, 0.5);
-}
-.btn-check:checked + .btn-primary, .btn-check:active + .btn-primary, .btn-primary:active, .btn-primary.active, .show > .btn-primary.dropdown-toggle {
- color: #fff;
- background-color: #117095;
- border-color: #10698c;
-}
-.btn-check:checked + .btn-primary:focus, .btn-check:active + .btn-primary:focus, .btn-primary:active:focus, .btn-primary.active:focus, .show > .btn-primary.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(56, 157, 196, 0.5);
-}
-.btn-primary:disabled, .btn-primary.disabled {
- color: #fff;
- background-color: #158cba;
- border-color: #158cba;
+ --bs-btn-color: #fff;
+ --bs-btn-bg: #158cba;
+ --bs-btn-border-color: #158cba;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #12779e;
+ --bs-btn-hover-border-color: #117095;
+ --bs-btn-focus-shadow-rgb: 56, 157, 196;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #117095;
+ --bs-btn-active-border-color: #10698c;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #fff;
+ --bs-btn-disabled-bg: #158cba;
+ --bs-btn-disabled-border-color: #158cba;
}
.btn-secondary {
- color: #000;
- background-color: #f0f0f0;
- border-color: #f0f0f0;
-}
-.btn-secondary:hover {
- color: #000;
- background-color: #f2f2f2;
- border-color: #f2f2f2;
-}
-.btn-check:focus + .btn-secondary, .btn-secondary:focus {
- color: #000;
- background-color: #f2f2f2;
- border-color: #f2f2f2;
- box-shadow: 0 0 0 0.25rem rgba(204, 204, 204, 0.5);
-}
-.btn-check:checked + .btn-secondary, .btn-check:active + .btn-secondary, .btn-secondary:active, .btn-secondary.active, .show > .btn-secondary.dropdown-toggle {
- color: #000;
- background-color: #f3f3f3;
- border-color: #f2f2f2;
-}
-.btn-check:checked + .btn-secondary:focus, .btn-check:active + .btn-secondary:focus, .btn-secondary:active:focus, .btn-secondary.active:focus, .show > .btn-secondary.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(204, 204, 204, 0.5);
-}
-.btn-secondary:disabled, .btn-secondary.disabled {
- color: #000;
- background-color: #f0f0f0;
- border-color: #f0f0f0;
+ --bs-btn-color: #000;
+ --bs-btn-bg: #f0f0f0;
+ --bs-btn-border-color: #f0f0f0;
+ --bs-btn-hover-color: #000;
+ --bs-btn-hover-bg: #f2f2f2;
+ --bs-btn-hover-border-color: #f2f2f2;
+ --bs-btn-focus-shadow-rgb: 204, 204, 204;
+ --bs-btn-active-color: #000;
+ --bs-btn-active-bg: #f3f3f3;
+ --bs-btn-active-border-color: #f2f2f2;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #000;
+ --bs-btn-disabled-bg: #f0f0f0;
+ --bs-btn-disabled-border-color: #f0f0f0;
}
.btn-success {
- color: #fff;
- background-color: #28b62c;
- border-color: #28b62c;
-}
-.btn-success:hover {
- color: #fff;
- background-color: #229b25;
- border-color: #209223;
-}
-.btn-check:focus + .btn-success, .btn-success:focus {
- color: #fff;
- background-color: #229b25;
- border-color: #209223;
- box-shadow: 0 0 0 0.25rem rgba(72, 193, 76, 0.5);
-}
-.btn-check:checked + .btn-success, .btn-check:active + .btn-success, .btn-success:active, .btn-success.active, .show > .btn-success.dropdown-toggle {
- color: #fff;
- background-color: #209223;
- border-color: #1e8921;
-}
-.btn-check:checked + .btn-success:focus, .btn-check:active + .btn-success:focus, .btn-success:active:focus, .btn-success.active:focus, .show > .btn-success.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(72, 193, 76, 0.5);
-}
-.btn-success:disabled, .btn-success.disabled {
- color: #fff;
- background-color: #28b62c;
- border-color: #28b62c;
+ --bs-btn-color: #fff;
+ --bs-btn-bg: #28b62c;
+ --bs-btn-border-color: #28b62c;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #229b25;
+ --bs-btn-hover-border-color: #209223;
+ --bs-btn-focus-shadow-rgb: 72, 193, 76;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #209223;
+ --bs-btn-active-border-color: #1e8921;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #fff;
+ --bs-btn-disabled-bg: #28b62c;
+ --bs-btn-disabled-border-color: #28b62c;
}
.btn-info {
- color: #fff;
- background-color: #75caeb;
- border-color: #75caeb;
-}
-.btn-info:hover {
- color: #fff;
- background-color: #63acc8;
- border-color: #5ea2bc;
-}
-.btn-check:focus + .btn-info, .btn-info:focus {
- color: #fff;
- background-color: #63acc8;
- border-color: #5ea2bc;
- box-shadow: 0 0 0 0.25rem rgba(138, 210, 238, 0.5);
-}
-.btn-check:checked + .btn-info, .btn-check:active + .btn-info, .btn-info:active, .btn-info.active, .show > .btn-info.dropdown-toggle {
- color: #fff;
- background-color: #5ea2bc;
- border-color: #5898b0;
-}
-.btn-check:checked + .btn-info:focus, .btn-check:active + .btn-info:focus, .btn-info:active:focus, .btn-info.active:focus, .show > .btn-info.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(138, 210, 238, 0.5);
-}
-.btn-info:disabled, .btn-info.disabled {
- color: #fff;
- background-color: #75caeb;
- border-color: #75caeb;
+ --bs-btn-color: #fff;
+ --bs-btn-bg: #75caeb;
+ --bs-btn-border-color: #75caeb;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #63acc8;
+ --bs-btn-hover-border-color: #5ea2bc;
+ --bs-btn-focus-shadow-rgb: 138, 210, 238;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #5ea2bc;
+ --bs-btn-active-border-color: #5898b0;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #fff;
+ --bs-btn-disabled-bg: #75caeb;
+ --bs-btn-disabled-border-color: #75caeb;
}
.btn-warning {
- color: #fff;
- background-color: #ff851b;
- border-color: #ff851b;
-}
-.btn-warning:hover {
- color: #fff;
- background-color: #d97117;
- border-color: #cc6a16;
-}
-.btn-check:focus + .btn-warning, .btn-warning:focus {
- color: #fff;
- background-color: #d97117;
- border-color: #cc6a16;
- box-shadow: 0 0 0 0.25rem rgba(255, 151, 61, 0.5);
-}
-.btn-check:checked + .btn-warning, .btn-check:active + .btn-warning, .btn-warning:active, .btn-warning.active, .show > .btn-warning.dropdown-toggle {
- color: #fff;
- background-color: #cc6a16;
- border-color: #bf6414;
-}
-.btn-check:checked + .btn-warning:focus, .btn-check:active + .btn-warning:focus, .btn-warning:active:focus, .btn-warning.active:focus, .show > .btn-warning.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(255, 151, 61, 0.5);
-}
-.btn-warning:disabled, .btn-warning.disabled {
- color: #fff;
- background-color: #ff851b;
- border-color: #ff851b;
+ --bs-btn-color: #fff;
+ --bs-btn-bg: #ff851b;
+ --bs-btn-border-color: #ff851b;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #d97117;
+ --bs-btn-hover-border-color: #cc6a16;
+ --bs-btn-focus-shadow-rgb: 255, 151, 61;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #cc6a16;
+ --bs-btn-active-border-color: #bf6414;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #fff;
+ --bs-btn-disabled-bg: #ff851b;
+ --bs-btn-disabled-border-color: #ff851b;
}
.btn-danger {
- color: #fff;
- background-color: #ff4136;
- border-color: #ff4136;
-}
-.btn-danger:hover {
- color: #fff;
- background-color: #d9372e;
- border-color: #cc342b;
-}
-.btn-check:focus + .btn-danger, .btn-danger:focus {
- color: #fff;
- background-color: #d9372e;
- border-color: #cc342b;
- box-shadow: 0 0 0 0.25rem rgba(255, 94, 84, 0.5);
-}
-.btn-check:checked + .btn-danger, .btn-check:active + .btn-danger, .btn-danger:active, .btn-danger.active, .show > .btn-danger.dropdown-toggle {
- color: #fff;
- background-color: #cc342b;
- border-color: #bf3129;
-}
-.btn-check:checked + .btn-danger:focus, .btn-check:active + .btn-danger:focus, .btn-danger:active:focus, .btn-danger.active:focus, .show > .btn-danger.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(255, 94, 84, 0.5);
-}
-.btn-danger:disabled, .btn-danger.disabled {
- color: #fff;
- background-color: #ff4136;
- border-color: #ff4136;
+ --bs-btn-color: #fff;
+ --bs-btn-bg: #ff4136;
+ --bs-btn-border-color: #ff4136;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #d9372e;
+ --bs-btn-hover-border-color: #cc342b;
+ --bs-btn-focus-shadow-rgb: 255, 94, 84;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #cc342b;
+ --bs-btn-active-border-color: #bf3129;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #fff;
+ --bs-btn-disabled-bg: #ff4136;
+ --bs-btn-disabled-border-color: #ff4136;
}
.btn-light {
- color: #000;
- background-color: #f6f6f6;
- border-color: #f6f6f6;
-}
-.btn-light:hover {
- color: #000;
- background-color: #f7f7f7;
- border-color: #f7f7f7;
-}
-.btn-check:focus + .btn-light, .btn-light:focus {
- color: #000;
- background-color: #f7f7f7;
- border-color: #f7f7f7;
- box-shadow: 0 0 0 0.25rem rgba(209, 209, 209, 0.5);
-}
-.btn-check:checked + .btn-light, .btn-check:active + .btn-light, .btn-light:active, .btn-light.active, .show > .btn-light.dropdown-toggle {
- color: #000;
- background-color: #f8f8f8;
- border-color: #f7f7f7;
-}
-.btn-check:checked + .btn-light:focus, .btn-check:active + .btn-light:focus, .btn-light:active:focus, .btn-light.active:focus, .show > .btn-light.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(209, 209, 209, 0.5);
-}
-.btn-light:disabled, .btn-light.disabled {
- color: #000;
- background-color: #f6f6f6;
- border-color: #f6f6f6;
+ --bs-btn-color: #000;
+ --bs-btn-bg: #f6f6f6;
+ --bs-btn-border-color: #f6f6f6;
+ --bs-btn-hover-color: #000;
+ --bs-btn-hover-bg: #d1d1d1;
+ --bs-btn-hover-border-color: #c5c5c5;
+ --bs-btn-focus-shadow-rgb: 209, 209, 209;
+ --bs-btn-active-color: #000;
+ --bs-btn-active-bg: #c5c5c5;
+ --bs-btn-active-border-color: #b9b9b9;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #000;
+ --bs-btn-disabled-bg: #f6f6f6;
+ --bs-btn-disabled-border-color: #f6f6f6;
}
.btn-dark {
- color: #fff;
- background-color: #555;
- border-color: #555;
-}
-.btn-dark:hover {
- color: #fff;
- background-color: #484848;
- border-color: #444444;
-}
-.btn-check:focus + .btn-dark, .btn-dark:focus {
- color: #fff;
- background-color: #484848;
- border-color: #444444;
- box-shadow: 0 0 0 0.25rem rgba(111, 111, 111, 0.5);
-}
-.btn-check:checked + .btn-dark, .btn-check:active + .btn-dark, .btn-dark:active, .btn-dark.active, .show > .btn-dark.dropdown-toggle {
- color: #fff;
- background-color: #444444;
- border-color: #404040;
-}
-.btn-check:checked + .btn-dark:focus, .btn-check:active + .btn-dark:focus, .btn-dark:active:focus, .btn-dark.active:focus, .show > .btn-dark.dropdown-toggle:focus {
- box-shadow: 0 0 0 0.25rem rgba(111, 111, 111, 0.5);
-}
-.btn-dark:disabled, .btn-dark.disabled {
- color: #fff;
- background-color: #555;
- border-color: #555;
+ --bs-btn-color: #fff;
+ --bs-btn-bg: #555;
+ --bs-btn-border-color: #555;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #6f6f6f;
+ --bs-btn-hover-border-color: #666666;
+ --bs-btn-focus-shadow-rgb: 111, 111, 111;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #777777;
+ --bs-btn-active-border-color: #666666;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #fff;
+ --bs-btn-disabled-bg: #555;
+ --bs-btn-disabled-border-color: #555;
}
.btn-outline-primary {
- color: #158cba;
- border-color: #158cba;
-}
-.btn-outline-primary:hover {
- color: #fff;
- background-color: #158cba;
- border-color: #158cba;
-}
-.btn-check:focus + .btn-outline-primary, .btn-outline-primary:focus {
- box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.5);
-}
-.btn-check:checked + .btn-outline-primary, .btn-check:active + .btn-outline-primary, .btn-outline-primary:active, .btn-outline-primary.active, .btn-outline-primary.dropdown-toggle.show {
- color: #fff;
- background-color: #158cba;
- border-color: #158cba;
-}
-.btn-check:checked + .btn-outline-primary:focus, .btn-check:active + .btn-outline-primary:focus, .btn-outline-primary:active:focus, .btn-outline-primary.active:focus, .btn-outline-primary.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.5);
-}
-.btn-outline-primary:disabled, .btn-outline-primary.disabled {
- color: #158cba;
- background-color: transparent;
+ --bs-btn-color: #158cba;
+ --bs-btn-border-color: #158cba;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #158cba;
+ --bs-btn-hover-border-color: #158cba;
+ --bs-btn-focus-shadow-rgb: 21, 140, 186;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #158cba;
+ --bs-btn-active-border-color: #158cba;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #158cba;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #158cba;
+ --bs-gradient: none;
}
.btn-outline-secondary {
- color: #f0f0f0;
- border-color: #f0f0f0;
-}
-.btn-outline-secondary:hover {
- color: #000;
- background-color: #f0f0f0;
- border-color: #f0f0f0;
-}
-.btn-check:focus + .btn-outline-secondary, .btn-outline-secondary:focus {
- box-shadow: 0 0 0 0.25rem rgba(240, 240, 240, 0.5);
-}
-.btn-check:checked + .btn-outline-secondary, .btn-check:active + .btn-outline-secondary, .btn-outline-secondary:active, .btn-outline-secondary.active, .btn-outline-secondary.dropdown-toggle.show {
- color: #000;
- background-color: #f0f0f0;
- border-color: #f0f0f0;
-}
-.btn-check:checked + .btn-outline-secondary:focus, .btn-check:active + .btn-outline-secondary:focus, .btn-outline-secondary:active:focus, .btn-outline-secondary.active:focus, .btn-outline-secondary.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(240, 240, 240, 0.5);
-}
-.btn-outline-secondary:disabled, .btn-outline-secondary.disabled {
- color: #f0f0f0;
- background-color: transparent;
+ --bs-btn-color: #f0f0f0;
+ --bs-btn-border-color: #f0f0f0;
+ --bs-btn-hover-color: #000;
+ --bs-btn-hover-bg: #f0f0f0;
+ --bs-btn-hover-border-color: #f0f0f0;
+ --bs-btn-focus-shadow-rgb: 240, 240, 240;
+ --bs-btn-active-color: #000;
+ --bs-btn-active-bg: #f0f0f0;
+ --bs-btn-active-border-color: #f0f0f0;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #f0f0f0;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #f0f0f0;
+ --bs-gradient: none;
}
.btn-outline-success {
- color: #28b62c;
- border-color: #28b62c;
-}
-.btn-outline-success:hover {
- color: #fff;
- background-color: #28b62c;
- border-color: #28b62c;
-}
-.btn-check:focus + .btn-outline-success, .btn-outline-success:focus {
- box-shadow: 0 0 0 0.25rem rgba(40, 182, 44, 0.5);
-}
-.btn-check:checked + .btn-outline-success, .btn-check:active + .btn-outline-success, .btn-outline-success:active, .btn-outline-success.active, .btn-outline-success.dropdown-toggle.show {
- color: #fff;
- background-color: #28b62c;
- border-color: #28b62c;
-}
-.btn-check:checked + .btn-outline-success:focus, .btn-check:active + .btn-outline-success:focus, .btn-outline-success:active:focus, .btn-outline-success.active:focus, .btn-outline-success.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(40, 182, 44, 0.5);
-}
-.btn-outline-success:disabled, .btn-outline-success.disabled {
- color: #28b62c;
- background-color: transparent;
+ --bs-btn-color: #28b62c;
+ --bs-btn-border-color: #28b62c;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #28b62c;
+ --bs-btn-hover-border-color: #28b62c;
+ --bs-btn-focus-shadow-rgb: 40, 182, 44;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #28b62c;
+ --bs-btn-active-border-color: #28b62c;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #28b62c;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #28b62c;
+ --bs-gradient: none;
}
.btn-outline-info {
- color: #75caeb;
- border-color: #75caeb;
-}
-.btn-outline-info:hover {
- color: #fff;
- background-color: #75caeb;
- border-color: #75caeb;
-}
-.btn-check:focus + .btn-outline-info, .btn-outline-info:focus {
- box-shadow: 0 0 0 0.25rem rgba(117, 202, 235, 0.5);
-}
-.btn-check:checked + .btn-outline-info, .btn-check:active + .btn-outline-info, .btn-outline-info:active, .btn-outline-info.active, .btn-outline-info.dropdown-toggle.show {
- color: #fff;
- background-color: #75caeb;
- border-color: #75caeb;
-}
-.btn-check:checked + .btn-outline-info:focus, .btn-check:active + .btn-outline-info:focus, .btn-outline-info:active:focus, .btn-outline-info.active:focus, .btn-outline-info.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(117, 202, 235, 0.5);
-}
-.btn-outline-info:disabled, .btn-outline-info.disabled {
- color: #75caeb;
- background-color: transparent;
+ --bs-btn-color: #75caeb;
+ --bs-btn-border-color: #75caeb;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #75caeb;
+ --bs-btn-hover-border-color: #75caeb;
+ --bs-btn-focus-shadow-rgb: 117, 202, 235;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #75caeb;
+ --bs-btn-active-border-color: #75caeb;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #75caeb;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #75caeb;
+ --bs-gradient: none;
}
.btn-outline-warning {
- color: #ff851b;
- border-color: #ff851b;
-}
-.btn-outline-warning:hover {
- color: #fff;
- background-color: #ff851b;
- border-color: #ff851b;
-}
-.btn-check:focus + .btn-outline-warning, .btn-outline-warning:focus {
- box-shadow: 0 0 0 0.25rem rgba(255, 133, 27, 0.5);
-}
-.btn-check:checked + .btn-outline-warning, .btn-check:active + .btn-outline-warning, .btn-outline-warning:active, .btn-outline-warning.active, .btn-outline-warning.dropdown-toggle.show {
- color: #fff;
- background-color: #ff851b;
- border-color: #ff851b;
-}
-.btn-check:checked + .btn-outline-warning:focus, .btn-check:active + .btn-outline-warning:focus, .btn-outline-warning:active:focus, .btn-outline-warning.active:focus, .btn-outline-warning.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(255, 133, 27, 0.5);
-}
-.btn-outline-warning:disabled, .btn-outline-warning.disabled {
- color: #ff851b;
- background-color: transparent;
+ --bs-btn-color: #ff851b;
+ --bs-btn-border-color: #ff851b;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #ff851b;
+ --bs-btn-hover-border-color: #ff851b;
+ --bs-btn-focus-shadow-rgb: 255, 133, 27;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #ff851b;
+ --bs-btn-active-border-color: #ff851b;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #ff851b;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #ff851b;
+ --bs-gradient: none;
}
.btn-outline-danger {
- color: #ff4136;
- border-color: #ff4136;
-}
-.btn-outline-danger:hover {
- color: #fff;
- background-color: #ff4136;
- border-color: #ff4136;
-}
-.btn-check:focus + .btn-outline-danger, .btn-outline-danger:focus {
- box-shadow: 0 0 0 0.25rem rgba(255, 65, 54, 0.5);
-}
-.btn-check:checked + .btn-outline-danger, .btn-check:active + .btn-outline-danger, .btn-outline-danger:active, .btn-outline-danger.active, .btn-outline-danger.dropdown-toggle.show {
- color: #fff;
- background-color: #ff4136;
- border-color: #ff4136;
-}
-.btn-check:checked + .btn-outline-danger:focus, .btn-check:active + .btn-outline-danger:focus, .btn-outline-danger:active:focus, .btn-outline-danger.active:focus, .btn-outline-danger.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(255, 65, 54, 0.5);
-}
-.btn-outline-danger:disabled, .btn-outline-danger.disabled {
- color: #ff4136;
- background-color: transparent;
+ --bs-btn-color: #ff4136;
+ --bs-btn-border-color: #ff4136;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #ff4136;
+ --bs-btn-hover-border-color: #ff4136;
+ --bs-btn-focus-shadow-rgb: 255, 65, 54;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #ff4136;
+ --bs-btn-active-border-color: #ff4136;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #ff4136;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #ff4136;
+ --bs-gradient: none;
}
.btn-outline-light {
- color: #f6f6f6;
- border-color: #f6f6f6;
-}
-.btn-outline-light:hover {
- color: #000;
- background-color: #f6f6f6;
- border-color: #f6f6f6;
-}
-.btn-check:focus + .btn-outline-light, .btn-outline-light:focus {
- box-shadow: 0 0 0 0.25rem rgba(246, 246, 246, 0.5);
-}
-.btn-check:checked + .btn-outline-light, .btn-check:active + .btn-outline-light, .btn-outline-light:active, .btn-outline-light.active, .btn-outline-light.dropdown-toggle.show {
- color: #000;
- background-color: #f6f6f6;
- border-color: #f6f6f6;
-}
-.btn-check:checked + .btn-outline-light:focus, .btn-check:active + .btn-outline-light:focus, .btn-outline-light:active:focus, .btn-outline-light.active:focus, .btn-outline-light.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(246, 246, 246, 0.5);
-}
-.btn-outline-light:disabled, .btn-outline-light.disabled {
- color: #f6f6f6;
- background-color: transparent;
+ --bs-btn-color: #f6f6f6;
+ --bs-btn-border-color: #f6f6f6;
+ --bs-btn-hover-color: #000;
+ --bs-btn-hover-bg: #f6f6f6;
+ --bs-btn-hover-border-color: #f6f6f6;
+ --bs-btn-focus-shadow-rgb: 246, 246, 246;
+ --bs-btn-active-color: #000;
+ --bs-btn-active-bg: #f6f6f6;
+ --bs-btn-active-border-color: #f6f6f6;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #f6f6f6;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #f6f6f6;
+ --bs-gradient: none;
}
.btn-outline-dark {
- color: #555;
- border-color: #555;
-}
-.btn-outline-dark:hover {
- color: #fff;
- background-color: #555;
- border-color: #555;
-}
-.btn-check:focus + .btn-outline-dark, .btn-outline-dark:focus {
- box-shadow: 0 0 0 0.25rem rgba(85, 85, 85, 0.5);
-}
-.btn-check:checked + .btn-outline-dark, .btn-check:active + .btn-outline-dark, .btn-outline-dark:active, .btn-outline-dark.active, .btn-outline-dark.dropdown-toggle.show {
- color: #fff;
- background-color: #555;
- border-color: #555;
-}
-.btn-check:checked + .btn-outline-dark:focus, .btn-check:active + .btn-outline-dark:focus, .btn-outline-dark:active:focus, .btn-outline-dark.active:focus, .btn-outline-dark.dropdown-toggle.show:focus {
- box-shadow: 0 0 0 0.25rem rgba(85, 85, 85, 0.5);
-}
-.btn-outline-dark:disabled, .btn-outline-dark.disabled {
- color: #555;
- background-color: transparent;
+ --bs-btn-color: #555;
+ --bs-btn-border-color: #555;
+ --bs-btn-hover-color: #fff;
+ --bs-btn-hover-bg: #555;
+ --bs-btn-hover-border-color: #555;
+ --bs-btn-focus-shadow-rgb: 85, 85, 85;
+ --bs-btn-active-color: #fff;
+ --bs-btn-active-bg: #555;
+ --bs-btn-active-border-color: #555;
+ --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
+ --bs-btn-disabled-color: #555;
+ --bs-btn-disabled-bg: transparent;
+ --bs-btn-disabled-border-color: #555;
+ --bs-gradient: none;
}
.btn-link {
- font-weight: 400;
- color: #158cba;
+ --bs-btn-font-weight: 400;
+ --bs-btn-color: var(--bs-link-color);
+ --bs-btn-bg: transparent;
+ --bs-btn-border-color: transparent;
+ --bs-btn-hover-color: var(--bs-link-hover-color);
+ --bs-btn-hover-border-color: transparent;
+ --bs-btn-active-color: var(--bs-link-hover-color);
+ --bs-btn-active-border-color: transparent;
+ --bs-btn-disabled-color: #999;
+ --bs-btn-disabled-border-color: transparent;
+ --bs-btn-box-shadow: 0 0 0 #000;
+ --bs-btn-focus-shadow-rgb: 56, 157, 196;
text-decoration: underline;
}
-.btn-link:hover {
- color: #117095;
+.btn-link:focus-visible {
+ color: var(--bs-btn-color);
}
-.btn-link:disabled, .btn-link.disabled {
- color: #999;
+.btn-link:hover {
+ color: var(--bs-btn-hover-color);
}
.btn-lg, .btn-group-lg > .btn {
- padding: 0.5rem 1rem;
- font-size: 1.25rem;
- border-radius: 0.3rem;
+ --bs-btn-padding-y: 0.5rem;
+ --bs-btn-padding-x: 1rem;
+ --bs-btn-font-size: 1.25rem;
+ --bs-btn-border-radius: var(--bs-border-radius-lg);
}
.btn-sm, .btn-group-sm > .btn {
- padding: 0.25rem 0.5rem;
- font-size: 0.875rem;
- border-radius: 0.2rem;
+ --bs-btn-padding-y: 0.25rem;
+ --bs-btn-padding-x: 0.5rem;
+ --bs-btn-font-size: 0.875rem;
+ --bs-btn-border-radius: var(--bs-border-radius-sm);
}
.fade {
@@ -3597,7 +3487,9 @@
.dropup,
.dropend,
.dropdown,
-.dropstart {
+.dropstart,
+.dropup-center,
+.dropdown-center {
position: relative;
}
@@ -3619,25 +3511,51 @@
}
.dropdown-menu {
+ --bs-dropdown-zindex: 1000;
+ --bs-dropdown-min-width: 10rem;
+ --bs-dropdown-padding-x: 0;
+ --bs-dropdown-padding-y: 0.5rem;
+ --bs-dropdown-spacer: 0.125rem;
+ --bs-dropdown-font-size: 1rem;
+ --bs-dropdown-color: var(--bs-body-color);
+ --bs-dropdown-bg: var(--bs-body-bg);
+ --bs-dropdown-border-color: var(--bs-border-color-translucent);
+ --bs-dropdown-border-radius: var(--bs-border-radius);
+ --bs-dropdown-border-width: var(--bs-border-width);
+ --bs-dropdown-inner-border-radius: calc(var(--bs-border-radius) - var(--bs-border-width));
+ --bs-dropdown-divider-bg: var(--bs-border-color-translucent);
+ --bs-dropdown-divider-margin-y: 0.5rem;
+ --bs-dropdown-box-shadow: var(--bs-box-shadow);
+ --bs-dropdown-link-color: var(--bs-tertiary-color);
+ --bs-dropdown-link-hover-color: var(--bs-tertiary-color);
+ --bs-dropdown-link-hover-bg: var(--bs-tertiary-bg);
+ --bs-dropdown-link-active-color: #fff;
+ --bs-dropdown-link-active-bg: #158cba;
+ --bs-dropdown-link-disabled-color: var(--bs-tertiary-color);
+ --bs-dropdown-item-padding-x: 1rem;
+ --bs-dropdown-item-padding-y: 0.25rem;
+ --bs-dropdown-header-color: #999;
+ --bs-dropdown-header-padding-x: 1rem;
+ --bs-dropdown-header-padding-y: 0.5rem;
position: absolute;
- z-index: 1000;
+ z-index: var(--bs-dropdown-zindex);
display: none;
- min-width: 10rem;
- padding: 0.5rem 0;
+ min-width: var(--bs-dropdown-min-width);
+ padding: var(--bs-dropdown-padding-y) var(--bs-dropdown-padding-x);
margin: 0;
- font-size: 1rem;
- color: #222;
+ font-size: var(--bs-dropdown-font-size);
+ color: var(--bs-dropdown-color);
text-align: left;
list-style: none;
- background-color: #fff;
+ background-color: var(--bs-dropdown-bg);
background-clip: padding-box;
- border: 1px solid rgba(0, 0, 0, 0.15);
- border-radius: 0.25rem;
+ border: var(--bs-dropdown-border-width) solid var(--bs-dropdown-border-color);
+ border-radius: var(--bs-dropdown-border-radius);
}
.dropdown-menu[data-bs-popper] {
top: 100%;
left: 0;
- margin-top: 0.125rem;
+ margin-top: var(--bs-dropdown-spacer);
}
.dropdown-menu-start {
@@ -3664,7 +3582,6 @@
right: auto;
left: 0;
}
-
.dropdown-menu-sm-end {
--bs-position: end;
}
@@ -3681,7 +3598,6 @@
right: auto;
left: 0;
}
-
.dropdown-menu-md-end {
--bs-position: end;
}
@@ -3698,7 +3614,6 @@
right: auto;
left: 0;
}
-
.dropdown-menu-lg-end {
--bs-position: end;
}
@@ -3715,7 +3630,6 @@
right: auto;
left: 0;
}
-
.dropdown-menu-xl-end {
--bs-position: end;
}
@@ -3732,7 +3646,6 @@
right: auto;
left: 0;
}
-
.dropdown-menu-xxl-end {
--bs-position: end;
}
@@ -3745,7 +3658,7 @@
top: auto;
bottom: 100%;
margin-top: 0;
- margin-bottom: 0.125rem;
+ margin-bottom: var(--bs-dropdown-spacer);
}
.dropup .dropdown-toggle::after {
display: inline-block;
@@ -3766,7 +3679,7 @@
right: auto;
left: 100%;
margin-top: 0;
- margin-left: 0.125rem;
+ margin-left: var(--bs-dropdown-spacer);
}
.dropend .dropdown-toggle::after {
display: inline-block;
@@ -3790,7 +3703,7 @@
right: 100%;
left: auto;
margin-top: 0;
- margin-right: 0.125rem;
+ margin-right: var(--bs-dropdown-spacer);
}
.dropstart .dropdown-toggle::after {
display: inline-block;
@@ -3819,35 +3732,37 @@
.dropdown-divider {
height: 0;
- margin: 0.5rem 0;
+ margin: var(--bs-dropdown-divider-margin-y) 0;
overflow: hidden;
- border-top: 1px solid rgba(0, 0, 0, 0.15);
+ border-top: 1px solid var(--bs-dropdown-divider-bg);
+ opacity: 1;
}
.dropdown-item {
display: block;
width: 100%;
- padding: 0.25rem 1rem;
+ padding: var(--bs-dropdown-item-padding-y) var(--bs-dropdown-item-padding-x);
clear: both;
font-weight: 400;
- color: rgba(0, 0, 0, 0.5);
+ color: var(--bs-dropdown-link-color);
text-align: inherit;
text-decoration: none;
white-space: nowrap;
background-color: transparent;
border: 0;
+ border-radius: var(--bs-dropdown-item-border-radius, 0);
}
.dropdown-item:hover, .dropdown-item:focus {
- color: rgba(0, 0, 0, 0.55);
- background-color: #f0f0f0;
+ color: var(--bs-dropdown-link-hover-color);
+ background-color: var(--bs-dropdown-link-hover-bg);
}
.dropdown-item.active, .dropdown-item:active {
- color: #fff;
+ color: var(--bs-dropdown-link-active-color);
text-decoration: none;
- background-color: #158cba;
+ background-color: var(--bs-dropdown-link-active-bg);
}
.dropdown-item.disabled, .dropdown-item:disabled {
- color: #adb5bd;
+ color: var(--bs-dropdown-link-disabled-color);
pointer-events: none;
background-color: transparent;
}
@@ -3858,46 +3773,32 @@
.dropdown-header {
display: block;
- padding: 0.5rem 1rem;
+ padding: var(--bs-dropdown-header-padding-y) var(--bs-dropdown-header-padding-x);
margin-bottom: 0;
font-size: 0.875rem;
- color: #999;
+ color: var(--bs-dropdown-header-color);
white-space: nowrap;
}
.dropdown-item-text {
display: block;
- padding: 0.25rem 1rem;
- color: rgba(0, 0, 0, 0.5);
+ padding: var(--bs-dropdown-item-padding-y) var(--bs-dropdown-item-padding-x);
+ color: var(--bs-dropdown-link-color);
}
.dropdown-menu-dark {
- color: #dee2e6;
- background-color: #333;
- border-color: rgba(0, 0, 0, 0.15);
-}
-.dropdown-menu-dark .dropdown-item {
- color: #dee2e6;
-}
-.dropdown-menu-dark .dropdown-item:hover, .dropdown-menu-dark .dropdown-item:focus {
- color: #fff;
- background-color: rgba(255, 255, 255, 0.15);
-}
-.dropdown-menu-dark .dropdown-item.active, .dropdown-menu-dark .dropdown-item:active {
- color: #fff;
- background-color: #158cba;
-}
-.dropdown-menu-dark .dropdown-item.disabled, .dropdown-menu-dark .dropdown-item:disabled {
- color: #adb5bd;
-}
-.dropdown-menu-dark .dropdown-divider {
- border-color: rgba(0, 0, 0, 0.15);
-}
-.dropdown-menu-dark .dropdown-item-text {
- color: #dee2e6;
-}
-.dropdown-menu-dark .dropdown-header {
- color: #adb5bd;
+ --bs-dropdown-color: #dee2e6;
+ --bs-dropdown-bg: #333;
+ --bs-dropdown-border-color: var(--bs-border-color-translucent);
+ --bs-dropdown-box-shadow: ;
+ --bs-dropdown-link-color: #dee2e6;
+ --bs-dropdown-link-hover-color: #fff;
+ --bs-dropdown-divider-bg: var(--bs-border-color-translucent);
+ --bs-dropdown-link-hover-bg: rgba(255, 255, 255, 0.15);
+ --bs-dropdown-link-active-color: #fff;
+ --bs-dropdown-link-active-bg: #158cba;
+ --bs-dropdown-link-disabled-color: #adb5bd;
+ --bs-dropdown-header-color: #adb5bd;
}
.btn-group,
@@ -3935,11 +3836,15 @@
width: auto;
}
-.btn-group > .btn:not(:first-child),
+.btn-group {
+ border-radius: var(--bs-border-radius);
+}
+.btn-group > :not(.btn-check:first-child) + .btn,
.btn-group > .btn-group:not(:first-child) {
- margin-left: -1px;
+ margin-left: calc(-1 * var(--bs-border-width));
}
.btn-group > .btn:not(:last-child):not(.dropdown-toggle),
+.btn-group > .btn.dropdown-toggle-split:first-child,
.btn-group > .btn-group:not(:last-child) > .btn {
border-top-right-radius: 0;
border-bottom-right-radius: 0;
@@ -3983,20 +3888,27 @@
}
.btn-group-vertical > .btn:not(:first-child),
.btn-group-vertical > .btn-group:not(:first-child) {
- margin-top: -1px;
+ margin-top: calc(-1 * var(--bs-border-width));
}
.btn-group-vertical > .btn:not(:last-child):not(.dropdown-toggle),
.btn-group-vertical > .btn-group:not(:last-child) > .btn {
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
}
-.btn-group-vertical > .btn ~ .btn,
+.btn-group-vertical > .btn:nth-child(n+3),
+.btn-group-vertical > :not(.btn-check) + .btn,
.btn-group-vertical > .btn-group:not(:first-child) > .btn {
border-top-left-radius: 0;
border-top-right-radius: 0;
}
.nav {
+ --bs-nav-link-padding-x: 1rem;
+ --bs-nav-link-padding-y: 0.5rem;
+ --bs-nav-link-font-weight: ;
+ --bs-nav-link-color: var(--bs-link-color);
+ --bs-nav-link-hover-color: var(--bs-link-hover-color);
+ --bs-nav-link-disabled-color: var(--bs-secondary-color);
display: flex;
flex-wrap: wrap;
padding-left: 0;
@@ -4006,9 +3918,13 @@
.nav-link {
display: block;
- padding: 0.5rem 1rem;
- color: #158cba;
+ padding: var(--bs-nav-link-padding-y) var(--bs-nav-link-padding-x);
+ font-size: var(--bs-nav-link-font-size);
+ font-weight: var(--bs-nav-link-font-weight);
+ color: var(--bs-nav-link-color);
text-decoration: none;
+ background: none;
+ border: 0;
transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out;
}
@media (prefers-reduced-motion: reduce) {
@@ -4017,54 +3933,83 @@
}
}
.nav-link:hover, .nav-link:focus {
- color: #117095;
+ color: var(--bs-nav-link-hover-color);
}
-.nav-link.disabled {
- color: #999;
+.nav-link:focus-visible {
+ outline: 0;
+ box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
+}
+.nav-link.disabled, .nav-link:disabled {
+ color: var(--bs-nav-link-disabled-color);
pointer-events: none;
cursor: default;
}
.nav-tabs {
- border-bottom: 1px solid #f0f0f0;
+ --bs-nav-tabs-border-width: var(--bs-border-width);
+ --bs-nav-tabs-border-color: var(--bs-border-color);
+ --bs-nav-tabs-border-radius: var(--bs-border-radius);
+ --bs-nav-tabs-link-hover-border-color: var(--bs-secondary-bg) var(--bs-secondary-bg) var(--bs-border-color);
+ --bs-nav-tabs-link-active-color: var(--bs-emphasis-color);
+ --bs-nav-tabs-link-active-bg: var(--bs-body-bg);
+ --bs-nav-tabs-link-active-border-color: var(--bs-border-color) var(--bs-border-color) var(--bs-body-bg);
+ border-bottom: var(--bs-nav-tabs-border-width) solid var(--bs-nav-tabs-border-color);
}
.nav-tabs .nav-link {
- margin-bottom: -1px;
- background: none;
- border: 1px solid transparent;
- border-top-left-radius: 0.25rem;
- border-top-right-radius: 0.25rem;
+ margin-bottom: calc(-1 * var(--bs-nav-tabs-border-width));
+ border: var(--bs-nav-tabs-border-width) solid transparent;
+ border-top-left-radius: var(--bs-nav-tabs-border-radius);
+ border-top-right-radius: var(--bs-nav-tabs-border-radius);
}
.nav-tabs .nav-link:hover, .nav-tabs .nav-link:focus {
- border-color: #f0f0f0;
isolation: isolate;
-}
-.nav-tabs .nav-link.disabled {
- color: #999;
- background-color: transparent;
- border-color: transparent;
+ border-color: var(--bs-nav-tabs-link-hover-border-color);
}
.nav-tabs .nav-link.active,
.nav-tabs .nav-item.show .nav-link {
- color: #222;
- background-color: #fff;
- border-color: #f0f0f0;
+ color: var(--bs-nav-tabs-link-active-color);
+ background-color: var(--bs-nav-tabs-link-active-bg);
+ border-color: var(--bs-nav-tabs-link-active-border-color);
}
.nav-tabs .dropdown-menu {
- margin-top: -1px;
+ margin-top: calc(-1 * var(--bs-nav-tabs-border-width));
border-top-left-radius: 0;
border-top-right-radius: 0;
}
+.nav-pills {
+ --bs-nav-pills-border-radius: var(--bs-border-radius);
+ --bs-nav-pills-link-active-color: #fff;
+ --bs-nav-pills-link-active-bg: #158cba;
+}
.nav-pills .nav-link {
- background: none;
- border: 0;
- border-radius: 0.25rem;
+ border-radius: var(--bs-nav-pills-border-radius);
}
.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
- color: #fff;
- background-color: #158cba;
+ color: var(--bs-nav-pills-link-active-color);
+ background-color: var(--bs-nav-pills-link-active-bg);
+}
+
+.nav-underline {
+ --bs-nav-underline-gap: 1rem;
+ --bs-nav-underline-border-width: 0.125rem;
+ --bs-nav-underline-link-active-color: var(--bs-emphasis-color);
+ gap: var(--bs-nav-underline-gap);
+}
+.nav-underline .nav-link {
+ padding-right: 0;
+ padding-left: 0;
+ border-bottom: var(--bs-nav-underline-border-width) solid transparent;
+}
+.nav-underline .nav-link:hover, .nav-underline .nav-link:focus {
+ border-bottom-color: currentcolor;
+}
+.nav-underline .nav-link.active,
+.nav-underline .show > .nav-link {
+ font-weight: 700;
+ color: var(--bs-nav-underline-link-active-color);
+ border-bottom-color: currentcolor;
}
.nav-fill > .nav-link,
@@ -4075,8 +4020,8 @@
.nav-justified > .nav-link,
.nav-justified .nav-item {
- flex-basis: 0;
flex-grow: 1;
+ flex-basis: 0;
text-align: center;
}
@@ -4093,13 +4038,32 @@
}
.navbar {
+ --bs-navbar-padding-x: 0;
+ --bs-navbar-padding-y: 0.5rem;
+ --bs-navbar-color: rgba(var(--bs-emphasis-color-rgb), 0.65);
+ --bs-navbar-hover-color: rgba(var(--bs-emphasis-color-rgb), 0.8);
+ --bs-navbar-disabled-color: rgba(var(--bs-emphasis-color-rgb), 0.3);
+ --bs-navbar-active-color: rgba(var(--bs-emphasis-color-rgb), 1);
+ --bs-navbar-brand-padding-y: 0.3125rem;
+ --bs-navbar-brand-margin-end: 1rem;
+ --bs-navbar-brand-font-size: 1.25rem;
+ --bs-navbar-brand-color: rgba(var(--bs-emphasis-color-rgb), 1);
+ --bs-navbar-brand-hover-color: rgba(var(--bs-emphasis-color-rgb), 1);
+ --bs-navbar-nav-link-padding-x: 0.5rem;
+ --bs-navbar-toggler-padding-y: 0.25rem;
+ --bs-navbar-toggler-padding-x: 0.75rem;
+ --bs-navbar-toggler-font-size: 1.25rem;
+ --bs-navbar-toggler-icon-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%2834, 34, 34, 0.75%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
+ --bs-navbar-toggler-border-color: rgba(var(--bs-emphasis-color-rgb), 0.15);
+ --bs-navbar-toggler-border-radius: var(--bs-border-radius);
+ --bs-navbar-toggler-focus-width: 0.25rem;
+ --bs-navbar-toggler-transition: box-shadow 0.15s ease-in-out;
position: relative;
display: flex;
flex-wrap: wrap;
align-items: center;
justify-content: space-between;
- padding-top: 0.5rem;
- padding-bottom: 0.5rem;
+ padding: var(--bs-navbar-padding-y) var(--bs-navbar-padding-x);
}
.navbar > .container,
.navbar > .container-fluid,
@@ -4114,23 +4078,33 @@
justify-content: space-between;
}
.navbar-brand {
- padding-top: 0.3125rem;
- padding-bottom: 0.3125rem;
- margin-right: 1rem;
- font-size: 1.25rem;
+ padding-top: var(--bs-navbar-brand-padding-y);
+ padding-bottom: var(--bs-navbar-brand-padding-y);
+ margin-right: var(--bs-navbar-brand-margin-end);
+ font-size: var(--bs-navbar-brand-font-size);
+ color: var(--bs-navbar-brand-color);
text-decoration: none;
white-space: nowrap;
}
+.navbar-brand:hover, .navbar-brand:focus {
+ color: var(--bs-navbar-brand-hover-color);
+}
+
.navbar-nav {
+ --bs-nav-link-padding-x: 0;
+ --bs-nav-link-padding-y: 0.5rem;
+ --bs-nav-link-font-weight: ;
+ --bs-nav-link-color: var(--bs-navbar-color);
+ --bs-nav-link-hover-color: var(--bs-navbar-hover-color);
+ --bs-nav-link-disabled-color: var(--bs-navbar-disabled-color);
display: flex;
flex-direction: column;
padding-left: 0;
margin-bottom: 0;
list-style: none;
}
-.navbar-nav .nav-link {
- padding-right: 0;
- padding-left: 0;
+.navbar-nav .nav-link.active, .navbar-nav .nav-link.show {
+ color: var(--bs-navbar-active-color);
}
.navbar-nav .dropdown-menu {
position: static;
@@ -4139,22 +4113,29 @@
.navbar-text {
padding-top: 0.5rem;
padding-bottom: 0.5rem;
+ color: var(--bs-navbar-color);
+}
+.navbar-text a,
+.navbar-text a:hover,
+.navbar-text a:focus {
+ color: var(--bs-navbar-active-color);
}
.navbar-collapse {
- flex-basis: 100%;
flex-grow: 1;
+ flex-basis: 100%;
align-items: center;
}
.navbar-toggler {
- padding: 0.25rem 0.75rem;
- font-size: 1.25rem;
+ padding: var(--bs-navbar-toggler-padding-y) var(--bs-navbar-toggler-padding-x);
+ font-size: var(--bs-navbar-toggler-font-size);
line-height: 1;
+ color: var(--bs-navbar-color);
background-color: transparent;
- border: 1px solid transparent;
- border-radius: 0.25rem;
- transition: box-shadow 0.15s ease-in-out;
+ border: var(--bs-border-width) solid var(--bs-navbar-toggler-border-color);
+ border-radius: var(--bs-navbar-toggler-border-radius);
+ transition: var(--bs-navbar-toggler-transition);
}
@media (prefers-reduced-motion: reduce) {
.navbar-toggler {
@@ -4167,7 +4148,7 @@
.navbar-toggler:focus {
text-decoration: none;
outline: 0;
- box-shadow: 0 0 0 0.25rem;
+ box-shadow: 0 0 0 var(--bs-navbar-toggler-focus-width);
}
.navbar-toggler-icon {
@@ -4175,6 +4156,7 @@
width: 1.5em;
height: 1.5em;
vertical-align: middle;
+ background-image: var(--bs-navbar-toggler-icon-bg);
background-repeat: no-repeat;
background-position: center;
background-size: 100%;
@@ -4197,8 +4179,8 @@
position: absolute;
}
.navbar-expand-sm .navbar-nav .nav-link {
- padding-right: 0.5rem;
- padding-left: 0.5rem;
+ padding-right: var(--bs-navbar-nav-link-padding-x);
+ padding-left: var(--bs-navbar-nav-link-padding-x);
}
.navbar-expand-sm .navbar-nav-scroll {
overflow: visible;
@@ -4210,28 +4192,22 @@
.navbar-expand-sm .navbar-toggler {
display: none;
}
- .navbar-expand-sm .offcanvas-header {
+ .navbar-expand-sm .offcanvas {
+ position: static;
+ z-index: auto;
+ flex-grow: 1;
+ width: auto !important;
+ height: auto !important;
+ visibility: visible !important;
+ background-color: transparent !important;
+ border: 0 !important;
+ transform: none !important;
+ transition: none;
+ }
+ .navbar-expand-sm .offcanvas .offcanvas-header {
display: none;
}
- .navbar-expand-sm .offcanvas {
- position: inherit;
- bottom: 0;
- z-index: 1000;
- flex-grow: 1;
- visibility: visible !important;
- background-color: transparent;
- border-right: 0;
- border-left: 0;
- transition: none;
- transform: none;
- }
- .navbar-expand-sm .offcanvas-top,
-.navbar-expand-sm .offcanvas-bottom {
- height: auto;
- border-top: 0;
- border-bottom: 0;
- }
- .navbar-expand-sm .offcanvas-body {
+ .navbar-expand-sm .offcanvas .offcanvas-body {
display: flex;
flex-grow: 0;
padding: 0;
@@ -4250,8 +4226,8 @@
position: absolute;
}
.navbar-expand-md .navbar-nav .nav-link {
- padding-right: 0.5rem;
- padding-left: 0.5rem;
+ padding-right: var(--bs-navbar-nav-link-padding-x);
+ padding-left: var(--bs-navbar-nav-link-padding-x);
}
.navbar-expand-md .navbar-nav-scroll {
overflow: visible;
@@ -4263,28 +4239,22 @@
.navbar-expand-md .navbar-toggler {
display: none;
}
- .navbar-expand-md .offcanvas-header {
+ .navbar-expand-md .offcanvas {
+ position: static;
+ z-index: auto;
+ flex-grow: 1;
+ width: auto !important;
+ height: auto !important;
+ visibility: visible !important;
+ background-color: transparent !important;
+ border: 0 !important;
+ transform: none !important;
+ transition: none;
+ }
+ .navbar-expand-md .offcanvas .offcanvas-header {
display: none;
}
- .navbar-expand-md .offcanvas {
- position: inherit;
- bottom: 0;
- z-index: 1000;
- flex-grow: 1;
- visibility: visible !important;
- background-color: transparent;
- border-right: 0;
- border-left: 0;
- transition: none;
- transform: none;
- }
- .navbar-expand-md .offcanvas-top,
-.navbar-expand-md .offcanvas-bottom {
- height: auto;
- border-top: 0;
- border-bottom: 0;
- }
- .navbar-expand-md .offcanvas-body {
+ .navbar-expand-md .offcanvas .offcanvas-body {
display: flex;
flex-grow: 0;
padding: 0;
@@ -4303,8 +4273,8 @@
position: absolute;
}
.navbar-expand-lg .navbar-nav .nav-link {
- padding-right: 0.5rem;
- padding-left: 0.5rem;
+ padding-right: var(--bs-navbar-nav-link-padding-x);
+ padding-left: var(--bs-navbar-nav-link-padding-x);
}
.navbar-expand-lg .navbar-nav-scroll {
overflow: visible;
@@ -4316,28 +4286,22 @@
.navbar-expand-lg .navbar-toggler {
display: none;
}
- .navbar-expand-lg .offcanvas-header {
+ .navbar-expand-lg .offcanvas {
+ position: static;
+ z-index: auto;
+ flex-grow: 1;
+ width: auto !important;
+ height: auto !important;
+ visibility: visible !important;
+ background-color: transparent !important;
+ border: 0 !important;
+ transform: none !important;
+ transition: none;
+ }
+ .navbar-expand-lg .offcanvas .offcanvas-header {
display: none;
}
- .navbar-expand-lg .offcanvas {
- position: inherit;
- bottom: 0;
- z-index: 1000;
- flex-grow: 1;
- visibility: visible !important;
- background-color: transparent;
- border-right: 0;
- border-left: 0;
- transition: none;
- transform: none;
- }
- .navbar-expand-lg .offcanvas-top,
-.navbar-expand-lg .offcanvas-bottom {
- height: auto;
- border-top: 0;
- border-bottom: 0;
- }
- .navbar-expand-lg .offcanvas-body {
+ .navbar-expand-lg .offcanvas .offcanvas-body {
display: flex;
flex-grow: 0;
padding: 0;
@@ -4356,8 +4320,8 @@
position: absolute;
}
.navbar-expand-xl .navbar-nav .nav-link {
- padding-right: 0.5rem;
- padding-left: 0.5rem;
+ padding-right: var(--bs-navbar-nav-link-padding-x);
+ padding-left: var(--bs-navbar-nav-link-padding-x);
}
.navbar-expand-xl .navbar-nav-scroll {
overflow: visible;
@@ -4369,28 +4333,22 @@
.navbar-expand-xl .navbar-toggler {
display: none;
}
- .navbar-expand-xl .offcanvas-header {
+ .navbar-expand-xl .offcanvas {
+ position: static;
+ z-index: auto;
+ flex-grow: 1;
+ width: auto !important;
+ height: auto !important;
+ visibility: visible !important;
+ background-color: transparent !important;
+ border: 0 !important;
+ transform: none !important;
+ transition: none;
+ }
+ .navbar-expand-xl .offcanvas .offcanvas-header {
display: none;
}
- .navbar-expand-xl .offcanvas {
- position: inherit;
- bottom: 0;
- z-index: 1000;
- flex-grow: 1;
- visibility: visible !important;
- background-color: transparent;
- border-right: 0;
- border-left: 0;
- transition: none;
- transform: none;
- }
- .navbar-expand-xl .offcanvas-top,
-.navbar-expand-xl .offcanvas-bottom {
- height: auto;
- border-top: 0;
- border-bottom: 0;
- }
- .navbar-expand-xl .offcanvas-body {
+ .navbar-expand-xl .offcanvas .offcanvas-body {
display: flex;
flex-grow: 0;
padding: 0;
@@ -4409,8 +4367,8 @@
position: absolute;
}
.navbar-expand-xxl .navbar-nav .nav-link {
- padding-right: 0.5rem;
- padding-left: 0.5rem;
+ padding-right: var(--bs-navbar-nav-link-padding-x);
+ padding-left: var(--bs-navbar-nav-link-padding-x);
}
.navbar-expand-xxl .navbar-nav-scroll {
overflow: visible;
@@ -4422,28 +4380,22 @@
.navbar-expand-xxl .navbar-toggler {
display: none;
}
- .navbar-expand-xxl .offcanvas-header {
+ .navbar-expand-xxl .offcanvas {
+ position: static;
+ z-index: auto;
+ flex-grow: 1;
+ width: auto !important;
+ height: auto !important;
+ visibility: visible !important;
+ background-color: transparent !important;
+ border: 0 !important;
+ transform: none !important;
+ transition: none;
+ }
+ .navbar-expand-xxl .offcanvas .offcanvas-header {
display: none;
}
- .navbar-expand-xxl .offcanvas {
- position: inherit;
- bottom: 0;
- z-index: 1000;
- flex-grow: 1;
- visibility: visible !important;
- background-color: transparent;
- border-right: 0;
- border-left: 0;
- transition: none;
- transform: none;
- }
- .navbar-expand-xxl .offcanvas-top,
-.navbar-expand-xxl .offcanvas-bottom {
- height: auto;
- border-top: 0;
- border-bottom: 0;
- }
- .navbar-expand-xxl .offcanvas-body {
+ .navbar-expand-xxl .offcanvas .offcanvas-body {
display: flex;
flex-grow: 0;
padding: 0;
@@ -4461,8 +4413,8 @@
position: absolute;
}
.navbar-expand .navbar-nav .nav-link {
- padding-right: 0.5rem;
- padding-left: 0.5rem;
+ padding-right: var(--bs-navbar-nav-link-padding-x);
+ padding-left: var(--bs-navbar-nav-link-padding-x);
}
.navbar-expand .navbar-nav-scroll {
overflow: visible;
@@ -4474,114 +4426,75 @@
.navbar-expand .navbar-toggler {
display: none;
}
-.navbar-expand .offcanvas-header {
+.navbar-expand .offcanvas {
+ position: static;
+ z-index: auto;
+ flex-grow: 1;
+ width: auto !important;
+ height: auto !important;
+ visibility: visible !important;
+ background-color: transparent !important;
+ border: 0 !important;
+ transform: none !important;
+ transition: none;
+}
+.navbar-expand .offcanvas .offcanvas-header {
display: none;
}
-.navbar-expand .offcanvas {
- position: inherit;
- bottom: 0;
- z-index: 1000;
- flex-grow: 1;
- visibility: visible !important;
- background-color: transparent;
- border-right: 0;
- border-left: 0;
- transition: none;
- transform: none;
-}
-.navbar-expand .offcanvas-top,
-.navbar-expand .offcanvas-bottom {
- height: auto;
- border-top: 0;
- border-bottom: 0;
-}
-.navbar-expand .offcanvas-body {
+.navbar-expand .offcanvas .offcanvas-body {
display: flex;
flex-grow: 0;
padding: 0;
overflow-y: visible;
}
-.navbar-light .navbar-brand {
- color: rgba(0, 0, 0, 0.9);
-}
-.navbar-light .navbar-brand:hover, .navbar-light .navbar-brand:focus {
- color: rgba(0, 0, 0, 0.9);
-}
-.navbar-light .navbar-nav .nav-link {
- color: rgba(0, 0, 0, 0.55);
-}
-.navbar-light .navbar-nav .nav-link:hover, .navbar-light .navbar-nav .nav-link:focus {
- color: rgba(0, 0, 0, 0.7);
-}
-.navbar-light .navbar-nav .nav-link.disabled {
- color: rgba(0, 0, 0, 0.3);
-}
-.navbar-light .navbar-nav .show > .nav-link,
-.navbar-light .navbar-nav .nav-link.active {
- color: rgba(0, 0, 0, 0.9);
-}
-.navbar-light .navbar-toggler {
- color: rgba(0, 0, 0, 0.55);
- border-color: rgba(0, 0, 0, 0.1);
-}
-.navbar-light .navbar-toggler-icon {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%280, 0, 0, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
-}
-.navbar-light .navbar-text {
- color: rgba(0, 0, 0, 0.55);
-}
-.navbar-light .navbar-text a,
-.navbar-light .navbar-text a:hover,
-.navbar-light .navbar-text a:focus {
- color: rgba(0, 0, 0, 0.9);
+.navbar-dark,
+.navbar[data-bs-theme=dark] {
+ --bs-navbar-color: rgba(255, 255, 255, 0.55);
+ --bs-navbar-hover-color: rgba(255, 255, 255, 0.75);
+ --bs-navbar-disabled-color: rgba(255, 255, 255, 0.25);
+ --bs-navbar-active-color: #fff;
+ --bs-navbar-brand-color: #fff;
+ --bs-navbar-brand-hover-color: #fff;
+ --bs-navbar-toggler-border-color: rgba(255, 255, 255, 0.1);
+ --bs-navbar-toggler-icon-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}
-.navbar-dark .navbar-brand {
- color: #fff;
-}
-.navbar-dark .navbar-brand:hover, .navbar-dark .navbar-brand:focus {
- color: #fff;
-}
-.navbar-dark .navbar-nav .nav-link {
- color: rgba(255, 255, 255, 0.55);
-}
-.navbar-dark .navbar-nav .nav-link:hover, .navbar-dark .navbar-nav .nav-link:focus {
- color: rgba(255, 255, 255, 0.75);
-}
-.navbar-dark .navbar-nav .nav-link.disabled {
- color: rgba(255, 255, 255, 0.25);
-}
-.navbar-dark .navbar-nav .show > .nav-link,
-.navbar-dark .navbar-nav .nav-link.active {
- color: #fff;
-}
-.navbar-dark .navbar-toggler {
- color: rgba(255, 255, 255, 0.55);
- border-color: rgba(255, 255, 255, 0.1);
-}
-.navbar-dark .navbar-toggler-icon {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
-}
-.navbar-dark .navbar-text {
- color: rgba(255, 255, 255, 0.55);
-}
-.navbar-dark .navbar-text a,
-.navbar-dark .navbar-text a:hover,
-.navbar-dark .navbar-text a:focus {
- color: #fff;
+[data-bs-theme=dark] .navbar-toggler-icon {
+ --bs-navbar-toggler-icon-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}
.card {
+ --bs-card-spacer-y: 1rem;
+ --bs-card-spacer-x: 1rem;
+ --bs-card-title-spacer-y: 0.5rem;
+ --bs-card-title-color: ;
+ --bs-card-subtitle-color: ;
+ --bs-card-border-width: var(--bs-border-width);
+ --bs-card-border-color: var(--bs-border-color-translucent);
+ --bs-card-border-radius: var(--bs-border-radius);
+ --bs-card-box-shadow: ;
+ --bs-card-inner-border-radius: calc(var(--bs-border-radius) - (var(--bs-border-width)));
+ --bs-card-cap-padding-y: 0.5rem;
+ --bs-card-cap-padding-x: 1rem;
+ --bs-card-cap-bg: rgba(var(--bs-body-color-rgb), 0.03);
+ --bs-card-cap-color: ;
+ --bs-card-height: ;
+ --bs-card-color: ;
+ --bs-card-bg: var(--bs-body-bg);
+ --bs-card-img-overlay-padding: 1rem;
+ --bs-card-group-margin: 0.75rem;
position: relative;
display: flex;
flex-direction: column;
min-width: 0;
+ height: var(--bs-card-height);
+ color: var(--bs-body-color);
word-wrap: break-word;
- background-color: #fff;
+ background-color: var(--bs-card-bg);
background-clip: border-box;
- border: 1px solid rgba(0, 0, 0, 0.125);
- border-radius: 0.25rem;
+ border: var(--bs-card-border-width) solid var(--bs-card-border-color);
+ border-radius: var(--bs-card-border-radius);
}
.card > hr {
margin-right: 0;
@@ -4593,13 +4506,13 @@
}
.card > .list-group:first-child {
border-top-width: 0;
- border-top-left-radius: calc(0.25rem - 1px);
- border-top-right-radius: calc(0.25rem - 1px);
+ border-top-left-radius: var(--bs-card-inner-border-radius);
+ border-top-right-radius: var(--bs-card-inner-border-radius);
}
.card > .list-group:last-child {
border-bottom-width: 0;
- border-bottom-right-radius: calc(0.25rem - 1px);
- border-bottom-left-radius: calc(0.25rem - 1px);
+ border-bottom-right-radius: var(--bs-card-inner-border-radius);
+ border-bottom-left-radius: var(--bs-card-inner-border-radius);
}
.card > .card-header + .list-group,
.card > .list-group + .card-footer {
@@ -4608,16 +4521,19 @@
.card-body {
flex: 1 1 auto;
- padding: 1rem 1rem;
+ padding: var(--bs-card-spacer-y) var(--bs-card-spacer-x);
+ color: var(--bs-card-color);
}
.card-title {
- margin-bottom: 0.5rem;
+ margin-bottom: var(--bs-card-title-spacer-y);
+ color: var(--bs-card-title-color);
}
.card-subtitle {
- margin-top: -0.25rem;
+ margin-top: calc(-0.5 * var(--bs-card-title-spacer-y));
margin-bottom: 0;
+ color: var(--bs-card-subtitle-color);
}
.card-text:last-child {
@@ -4625,38 +4541,44 @@
}
.card-link + .card-link {
- margin-left: 1rem;
+ margin-left: var(--bs-card-spacer-x);
}
.card-header {
- padding: 0.5rem 1rem;
+ padding: var(--bs-card-cap-padding-y) var(--bs-card-cap-padding-x);
margin-bottom: 0;
- background-color: rgba(0, 0, 0, 0.03);
- border-bottom: 1px solid rgba(0, 0, 0, 0.125);
+ color: var(--bs-card-cap-color);
+ background-color: var(--bs-card-cap-bg);
+ border-bottom: var(--bs-card-border-width) solid var(--bs-card-border-color);
}
.card-header:first-child {
- border-radius: calc(0.25rem - 1px) calc(0.25rem - 1px) 0 0;
+ border-radius: var(--bs-card-inner-border-radius) var(--bs-card-inner-border-radius) 0 0;
}
.card-footer {
- padding: 0.5rem 1rem;
- background-color: rgba(0, 0, 0, 0.03);
- border-top: 1px solid rgba(0, 0, 0, 0.125);
+ padding: var(--bs-card-cap-padding-y) var(--bs-card-cap-padding-x);
+ color: var(--bs-card-cap-color);
+ background-color: var(--bs-card-cap-bg);
+ border-top: var(--bs-card-border-width) solid var(--bs-card-border-color);
}
.card-footer:last-child {
- border-radius: 0 0 calc(0.25rem - 1px) calc(0.25rem - 1px);
+ border-radius: 0 0 var(--bs-card-inner-border-radius) var(--bs-card-inner-border-radius);
}
.card-header-tabs {
- margin-right: -0.5rem;
- margin-bottom: -0.5rem;
- margin-left: -0.5rem;
+ margin-right: calc(-0.5 * var(--bs-card-cap-padding-x));
+ margin-bottom: calc(-1 * var(--bs-card-cap-padding-y));
+ margin-left: calc(-0.5 * var(--bs-card-cap-padding-x));
border-bottom: 0;
}
+.card-header-tabs .nav-link.active {
+ background-color: var(--bs-card-bg);
+ border-bottom-color: var(--bs-card-bg);
+}
.card-header-pills {
- margin-right: -0.5rem;
- margin-left: -0.5rem;
+ margin-right: calc(-0.5 * var(--bs-card-cap-padding-x));
+ margin-left: calc(-0.5 * var(--bs-card-cap-padding-x));
}
.card-img-overlay {
@@ -4665,8 +4587,8 @@
right: 0;
bottom: 0;
left: 0;
- padding: 1rem;
- border-radius: calc(0.25rem - 1px);
+ padding: var(--bs-card-img-overlay-padding);
+ border-radius: var(--bs-card-inner-border-radius);
}
.card-img,
@@ -4677,18 +4599,18 @@
.card-img,
.card-img-top {
- border-top-left-radius: calc(0.25rem - 1px);
- border-top-right-radius: calc(0.25rem - 1px);
+ border-top-left-radius: var(--bs-card-inner-border-radius);
+ border-top-right-radius: var(--bs-card-inner-border-radius);
}
.card-img,
.card-img-bottom {
- border-bottom-right-radius: calc(0.25rem - 1px);
- border-bottom-left-radius: calc(0.25rem - 1px);
+ border-bottom-right-radius: var(--bs-card-inner-border-radius);
+ border-bottom-left-radius: var(--bs-card-inner-border-radius);
}
.card-group > .card {
- margin-bottom: 0.75rem;
+ margin-bottom: var(--bs-card-group-margin);
}
@media (min-width: 576px) {
.card-group {
@@ -4696,7 +4618,7 @@
flex-flow: row wrap;
}
.card-group > .card {
- flex: 1 0 0%;
+ flex: 1 0 0;
margin-bottom: 0;
}
.card-group > .card + .card {
@@ -4707,42 +4629,66 @@
border-top-right-radius: 0;
border-bottom-right-radius: 0;
}
- .card-group > .card:not(:last-child) .card-img-top,
-.card-group > .card:not(:last-child) .card-header {
+ .card-group > .card:not(:last-child) > .card-img-top,
+ .card-group > .card:not(:last-child) > .card-header {
border-top-right-radius: 0;
}
- .card-group > .card:not(:last-child) .card-img-bottom,
-.card-group > .card:not(:last-child) .card-footer {
+ .card-group > .card:not(:last-child) > .card-img-bottom,
+ .card-group > .card:not(:last-child) > .card-footer {
border-bottom-right-radius: 0;
}
.card-group > .card:not(:first-child) {
border-top-left-radius: 0;
border-bottom-left-radius: 0;
}
- .card-group > .card:not(:first-child) .card-img-top,
-.card-group > .card:not(:first-child) .card-header {
+ .card-group > .card:not(:first-child) > .card-img-top,
+ .card-group > .card:not(:first-child) > .card-header {
border-top-left-radius: 0;
}
- .card-group > .card:not(:first-child) .card-img-bottom,
-.card-group > .card:not(:first-child) .card-footer {
+ .card-group > .card:not(:first-child) > .card-img-bottom,
+ .card-group > .card:not(:first-child) > .card-footer {
border-bottom-left-radius: 0;
}
}
+.accordion {
+ --bs-accordion-color: var(--bs-body-color);
+ --bs-accordion-bg: var(--bs-body-bg);
+ --bs-accordion-transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out, border-radius 0.15s ease;
+ --bs-accordion-border-color: var(--bs-border-color);
+ --bs-accordion-border-width: var(--bs-border-width);
+ --bs-accordion-border-radius: var(--bs-border-radius);
+ --bs-accordion-inner-border-radius: calc(var(--bs-border-radius) - (var(--bs-border-width)));
+ --bs-accordion-btn-padding-x: 1.25rem;
+ --bs-accordion-btn-padding-y: 1rem;
+ --bs-accordion-btn-color: var(--bs-body-color);
+ --bs-accordion-btn-bg: var(--bs-accordion-bg);
+ --bs-accordion-btn-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23222' stroke-linecap='round' stroke-linejoin='round'%3e%3cpath d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
+ --bs-accordion-btn-icon-width: 1.25rem;
+ --bs-accordion-btn-icon-transform: rotate(-180deg);
+ --bs-accordion-btn-icon-transition: transform 0.2s ease-in-out;
+ --bs-accordion-btn-active-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%2308384a' stroke-linecap='round' stroke-linejoin='round'%3e%3cpath d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
+ --bs-accordion-btn-focus-box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
+ --bs-accordion-body-padding-x: 1.25rem;
+ --bs-accordion-body-padding-y: 1rem;
+ --bs-accordion-active-color: var(--bs-primary-text-emphasis);
+ --bs-accordion-active-bg: var(--bs-primary-bg-subtle);
+}
+
.accordion-button {
position: relative;
display: flex;
align-items: center;
width: 100%;
- padding: 1rem 1.25rem;
+ padding: var(--bs-accordion-btn-padding-y) var(--bs-accordion-btn-padding-x);
font-size: 1rem;
- color: #222;
+ color: var(--bs-accordion-btn-color);
text-align: left;
- background-color: #fff;
+ background-color: var(--bs-accordion-btn-bg);
border: 0;
border-radius: 0;
overflow-anchor: none;
- transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out, border-radius 0.15s ease;
+ transition: var(--bs-accordion-transition);
}
@media (prefers-reduced-motion: reduce) {
.accordion-button {
@@ -4750,24 +4696,24 @@
}
}
.accordion-button:not(.collapsed) {
- color: #137ea7;
- background-color: #e8f4f8;
- box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.125);
+ color: var(--bs-accordion-active-color);
+ background-color: var(--bs-accordion-active-bg);
+ box-shadow: inset 0 calc(-1 * var(--bs-accordion-border-width)) 0 var(--bs-accordion-border-color);
}
.accordion-button:not(.collapsed)::after {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23137ea7'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
- transform: rotate(-180deg);
+ background-image: var(--bs-accordion-btn-active-icon);
+ transform: var(--bs-accordion-btn-icon-transform);
}
.accordion-button::after {
flex-shrink: 0;
- width: 1.25rem;
- height: 1.25rem;
+ width: var(--bs-accordion-btn-icon-width);
+ height: var(--bs-accordion-btn-icon-width);
margin-left: auto;
content: "";
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23222'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
+ background-image: var(--bs-accordion-btn-icon);
background-repeat: no-repeat;
- background-size: 1.25rem;
- transition: transform 0.2s ease-in-out;
+ background-size: var(--bs-accordion-btn-icon-width);
+ transition: var(--bs-accordion-btn-icon-transition);
}
@media (prefers-reduced-motion: reduce) {
.accordion-button::after {
@@ -4779,9 +4725,8 @@
}
.accordion-button:focus {
z-index: 3;
- border-color: #8ac6dd;
outline: 0;
- box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
+ box-shadow: var(--bs-accordion-btn-focus-box-shadow);
}
.accordion-header {
@@ -4789,79 +4734,113 @@
}
.accordion-item {
- background-color: #fff;
- border: 1px solid rgba(0, 0, 0, 0.125);
+ color: var(--bs-accordion-color);
+ background-color: var(--bs-accordion-bg);
+ border: var(--bs-accordion-border-width) solid var(--bs-accordion-border-color);
}
.accordion-item:first-of-type {
- border-top-left-radius: 0.25rem;
- border-top-right-radius: 0.25rem;
+ border-top-left-radius: var(--bs-accordion-border-radius);
+ border-top-right-radius: var(--bs-accordion-border-radius);
}
-.accordion-item:first-of-type .accordion-button {
- border-top-left-radius: calc(0.25rem - 1px);
- border-top-right-radius: calc(0.25rem - 1px);
+.accordion-item:first-of-type > .accordion-header .accordion-button {
+ border-top-left-radius: var(--bs-accordion-inner-border-radius);
+ border-top-right-radius: var(--bs-accordion-inner-border-radius);
}
.accordion-item:not(:first-of-type) {
border-top: 0;
}
.accordion-item:last-of-type {
- border-bottom-right-radius: 0.25rem;
- border-bottom-left-radius: 0.25rem;
+ border-bottom-right-radius: var(--bs-accordion-border-radius);
+ border-bottom-left-radius: var(--bs-accordion-border-radius);
}
-.accordion-item:last-of-type .accordion-button.collapsed {
- border-bottom-right-radius: calc(0.25rem - 1px);
- border-bottom-left-radius: calc(0.25rem - 1px);
+.accordion-item:last-of-type > .accordion-header .accordion-button.collapsed {
+ border-bottom-right-radius: var(--bs-accordion-inner-border-radius);
+ border-bottom-left-radius: var(--bs-accordion-inner-border-radius);
}
-.accordion-item:last-of-type .accordion-collapse {
- border-bottom-right-radius: 0.25rem;
- border-bottom-left-radius: 0.25rem;
+.accordion-item:last-of-type > .accordion-collapse {
+ border-bottom-right-radius: var(--bs-accordion-border-radius);
+ border-bottom-left-radius: var(--bs-accordion-border-radius);
}
.accordion-body {
- padding: 1rem 1.25rem;
+ padding: var(--bs-accordion-body-padding-y) var(--bs-accordion-body-padding-x);
}
-.accordion-flush .accordion-collapse {
- border-width: 0;
-}
-.accordion-flush .accordion-item {
+.accordion-flush > .accordion-item {
border-right: 0;
border-left: 0;
border-radius: 0;
}
-.accordion-flush .accordion-item:first-child {
+.accordion-flush > .accordion-item:first-child {
border-top: 0;
}
-.accordion-flush .accordion-item:last-child {
+.accordion-flush > .accordion-item:last-child {
border-bottom: 0;
}
-.accordion-flush .accordion-item .accordion-button {
+.accordion-flush > .accordion-item > .accordion-collapse,
+.accordion-flush > .accordion-item > .accordion-header .accordion-button,
+.accordion-flush > .accordion-item > .accordion-header .accordion-button.collapsed {
border-radius: 0;
}
+[data-bs-theme=dark] .accordion-button::after {
+ --bs-accordion-btn-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%2373bad6'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708'/%3e%3c/svg%3e");
+ --bs-accordion-btn-active-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%2373bad6'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708'/%3e%3c/svg%3e");
+}
+
.breadcrumb {
+ --bs-breadcrumb-padding-x: 0.75rem;
+ --bs-breadcrumb-padding-y: 0.375rem;
+ --bs-breadcrumb-margin-bottom: 1rem;
+ --bs-breadcrumb-bg: var(--bs-tertiary-bg);
+ --bs-breadcrumb-border-radius: 0.25rem;
+ --bs-breadcrumb-divider-color: var(--bs-secondary-color);
+ --bs-breadcrumb-item-padding-x: 0.5rem;
+ --bs-breadcrumb-item-active-color: var(--bs-secondary-color);
display: flex;
flex-wrap: wrap;
- padding: 0.375rem 0.75rem;
- margin-bottom: 1rem;
+ padding: var(--bs-breadcrumb-padding-y) var(--bs-breadcrumb-padding-x);
+ margin-bottom: var(--bs-breadcrumb-margin-bottom);
+ font-size: var(--bs-breadcrumb-font-size);
list-style: none;
- background-color: #f0f0f0;
- border-radius: 0.25rem;
+ background-color: var(--bs-breadcrumb-bg);
+ border-radius: var(--bs-breadcrumb-border-radius);
}
.breadcrumb-item + .breadcrumb-item {
- padding-left: 0.5rem;
+ padding-left: var(--bs-breadcrumb-item-padding-x);
}
.breadcrumb-item + .breadcrumb-item::before {
float: left;
- padding-right: 0.5rem;
- color: #999;
+ padding-right: var(--bs-breadcrumb-item-padding-x);
+ color: var(--bs-breadcrumb-divider-color);
content: var(--bs-breadcrumb-divider, "/") /* rtl: var(--bs-breadcrumb-divider, "/") */;
}
.breadcrumb-item.active {
- color: #999;
+ color: var(--bs-breadcrumb-item-active-color);
}
.pagination {
+ --bs-pagination-padding-x: 0.75rem;
+ --bs-pagination-padding-y: 0.375rem;
+ --bs-pagination-font-size: 1rem;
+ --bs-pagination-color: #555;
+ --bs-pagination-bg: var(--bs-tertiary-bg);
+ --bs-pagination-border-width: var(--bs-border-width);
+ --bs-pagination-border-color: var(--bs-border-color);
+ --bs-pagination-border-radius: var(--bs-border-radius);
+ --bs-pagination-hover-color: #555;
+ --bs-pagination-hover-bg: var(--bs-tertiary-bg);
+ --bs-pagination-hover-border-color: var(--bs-border-color);
+ --bs-pagination-focus-color: var(--bs-link-hover-color);
+ --bs-pagination-focus-bg: var(--bs-secondary-bg);
+ --bs-pagination-focus-box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
+ --bs-pagination-active-color: #fff;
+ --bs-pagination-active-bg: #158cba;
+ --bs-pagination-active-border-color: #127ba3;
+ --bs-pagination-disabled-color: #999;
+ --bs-pagination-disabled-bg: var(--bs-tertiary-bg);
+ --bs-pagination-disabled-border-color: var(--bs-border-color);
display: flex;
padding-left: 0;
list-style: none;
@@ -4870,10 +4849,12 @@
.page-link {
position: relative;
display: block;
- color: #555;
+ padding: var(--bs-pagination-padding-y) var(--bs-pagination-padding-x);
+ font-size: var(--bs-pagination-font-size);
+ color: var(--bs-pagination-color);
text-decoration: none;
- background-color: #f0f0f0;
- border: 1px solid #dee2e6;
+ background-color: var(--bs-pagination-bg);
+ border: var(--bs-pagination-border-width) solid var(--bs-pagination-border-color);
transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}
@media (prefers-reduced-motion: reduce) {
@@ -4883,84 +4864,73 @@
}
.page-link:hover {
z-index: 2;
- color: #555;
- background-color: #f0f0f0;
- border-color: #dee2e6;
+ color: var(--bs-pagination-hover-color);
+ background-color: var(--bs-pagination-hover-bg);
+ border-color: var(--bs-pagination-hover-border-color);
}
.page-link:focus {
z-index: 3;
- color: #117095;
- background-color: #f0f0f0;
+ color: var(--bs-pagination-focus-color);
+ background-color: var(--bs-pagination-focus-bg);
outline: 0;
- box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
+ box-shadow: var(--bs-pagination-focus-box-shadow);
+}
+.page-link.active, .active > .page-link {
+ z-index: 3;
+ color: var(--bs-pagination-active-color);
+ background-color: var(--bs-pagination-active-bg);
+ border-color: var(--bs-pagination-active-border-color);
+}
+.page-link.disabled, .disabled > .page-link {
+ color: var(--bs-pagination-disabled-color);
+ pointer-events: none;
+ background-color: var(--bs-pagination-disabled-bg);
+ border-color: var(--bs-pagination-disabled-border-color);
}
.page-item:not(:first-child) .page-link {
- margin-left: -1px;
+ margin-left: calc(-1 * var(--bs-border-width));
}
-.page-item.active .page-link {
- z-index: 3;
- color: #fff;
- background-color: #158cba;
- border-color: #127ba3;
-}
-.page-item.disabled .page-link {
- color: #999;
- pointer-events: none;
- background-color: #f0f0f0;
- border-color: #dee2e6;
-}
-
-.page-link {
- padding: 0.375rem 0.75rem;
-}
-
.page-item:first-child .page-link {
- border-top-left-radius: 0.25rem;
- border-bottom-left-radius: 0.25rem;
+ border-top-left-radius: var(--bs-pagination-border-radius);
+ border-bottom-left-radius: var(--bs-pagination-border-radius);
}
.page-item:last-child .page-link {
- border-top-right-radius: 0.25rem;
- border-bottom-right-radius: 0.25rem;
+ border-top-right-radius: var(--bs-pagination-border-radius);
+ border-bottom-right-radius: var(--bs-pagination-border-radius);
}
-.pagination-lg .page-link {
- padding: 0.75rem 1.5rem;
- font-size: 1.25rem;
-}
-.pagination-lg .page-item:first-child .page-link {
- border-top-left-radius: 0.3rem;
- border-bottom-left-radius: 0.3rem;
-}
-.pagination-lg .page-item:last-child .page-link {
- border-top-right-radius: 0.3rem;
- border-bottom-right-radius: 0.3rem;
+.pagination-lg {
+ --bs-pagination-padding-x: 1.5rem;
+ --bs-pagination-padding-y: 0.75rem;
+ --bs-pagination-font-size: 1.25rem;
+ --bs-pagination-border-radius: var(--bs-border-radius-lg);
}
-.pagination-sm .page-link {
- padding: 0.25rem 0.5rem;
- font-size: 0.875rem;
-}
-.pagination-sm .page-item:first-child .page-link {
- border-top-left-radius: 0.2rem;
- border-bottom-left-radius: 0.2rem;
-}
-.pagination-sm .page-item:last-child .page-link {
- border-top-right-radius: 0.2rem;
- border-bottom-right-radius: 0.2rem;
+.pagination-sm {
+ --bs-pagination-padding-x: 0.5rem;
+ --bs-pagination-padding-y: 0.25rem;
+ --bs-pagination-font-size: 0.875rem;
+ --bs-pagination-border-radius: var(--bs-border-radius-sm);
}
.badge {
+ --bs-badge-padding-x: 0.65em;
+ --bs-badge-padding-y: 0.35em;
+ --bs-badge-font-size: 0.75em;
+ --bs-badge-font-weight: 700;
+ --bs-badge-color: #fff;
+ --bs-badge-border-radius: var(--bs-border-radius);
display: inline-block;
- padding: 0.35em 0.65em;
- font-size: 0.75em;
- font-weight: 700;
+ padding: var(--bs-badge-padding-y) var(--bs-badge-padding-x);
+ font-size: var(--bs-badge-font-size);
+ font-weight: var(--bs-badge-font-weight);
line-height: 1;
- color: #fff;
+ color: var(--bs-badge-color);
text-align: center;
white-space: nowrap;
vertical-align: baseline;
- border-radius: 0.25rem;
+ border-radius: var(--bs-badge-border-radius);
}
.badge:empty {
display: none;
@@ -4972,11 +4942,22 @@
}
.alert {
+ --bs-alert-bg: transparent;
+ --bs-alert-padding-x: 1rem;
+ --bs-alert-padding-y: 1rem;
+ --bs-alert-margin-bottom: 1rem;
+ --bs-alert-color: inherit;
+ --bs-alert-border-color: transparent;
+ --bs-alert-border: var(--bs-border-width) solid var(--bs-alert-border-color);
+ --bs-alert-border-radius: var(--bs-border-radius);
+ --bs-alert-link-color: inherit;
position: relative;
- padding: 1rem 1rem;
- margin-bottom: 1rem;
- border: 1px solid transparent;
- border-radius: 0.25rem;
+ padding: var(--bs-alert-padding-y) var(--bs-alert-padding-x);
+ margin-bottom: var(--bs-alert-margin-bottom);
+ color: var(--bs-alert-color);
+ background-color: var(--bs-alert-bg);
+ border: var(--bs-alert-border);
+ border-radius: var(--bs-alert-border-radius);
}
.alert-heading {
@@ -4985,6 +4966,7 @@
.alert-link {
font-weight: 700;
+ color: var(--bs-alert-link-color);
}
.alert-dismissible {
@@ -4999,95 +4981,82 @@
}
.alert-primary {
- color: #0d5470;
- background-color: #d0e8f1;
- border-color: #b9ddea;
-}
-.alert-primary .alert-link {
- color: #0a435a;
+ --bs-alert-color: var(--bs-primary-text-emphasis);
+ --bs-alert-bg: var(--bs-primary-bg-subtle);
+ --bs-alert-border-color: var(--bs-primary-border-subtle);
+ --bs-alert-link-color: var(--bs-primary-text-emphasis);
}
.alert-secondary {
- color: #909090;
- background-color: #fcfcfc;
- border-color: #fbfbfb;
-}
-.alert-secondary .alert-link {
- color: #737373;
+ --bs-alert-color: var(--bs-secondary-text-emphasis);
+ --bs-alert-bg: var(--bs-secondary-bg-subtle);
+ --bs-alert-border-color: var(--bs-secondary-border-subtle);
+ --bs-alert-link-color: var(--bs-secondary-text-emphasis);
}
.alert-success {
- color: #186d1a;
- background-color: #d4f0d5;
- border-color: #bfe9c0;
-}
-.alert-success .alert-link {
- color: #135715;
+ --bs-alert-color: var(--bs-success-text-emphasis);
+ --bs-alert-bg: var(--bs-success-bg-subtle);
+ --bs-alert-border-color: var(--bs-success-border-subtle);
+ --bs-alert-link-color: var(--bs-success-text-emphasis);
}
.alert-info {
- color: #46798d;
- background-color: #e3f4fb;
- border-color: #d6eff9;
-}
-.alert-info .alert-link {
- color: #386171;
+ --bs-alert-color: var(--bs-info-text-emphasis);
+ --bs-alert-bg: var(--bs-info-bg-subtle);
+ --bs-alert-border-color: var(--bs-info-border-subtle);
+ --bs-alert-link-color: var(--bs-info-text-emphasis);
}
.alert-warning {
- color: #995010;
- background-color: #ffe7d1;
- border-color: #ffdabb;
-}
-.alert-warning .alert-link {
- color: #7a400d;
+ --bs-alert-color: var(--bs-warning-text-emphasis);
+ --bs-alert-bg: var(--bs-warning-bg-subtle);
+ --bs-alert-border-color: var(--bs-warning-border-subtle);
+ --bs-alert-link-color: var(--bs-warning-text-emphasis);
}
.alert-danger {
- color: #992720;
- background-color: #ffd9d7;
- border-color: #ffc6c3;
-}
-.alert-danger .alert-link {
- color: #7a1f1a;
+ --bs-alert-color: var(--bs-danger-text-emphasis);
+ --bs-alert-bg: var(--bs-danger-bg-subtle);
+ --bs-alert-border-color: var(--bs-danger-border-subtle);
+ --bs-alert-link-color: var(--bs-danger-text-emphasis);
}
.alert-light {
- color: #949494;
- background-color: #fdfdfd;
- border-color: #fcfcfc;
-}
-.alert-light .alert-link {
- color: #767676;
+ --bs-alert-color: var(--bs-light-text-emphasis);
+ --bs-alert-bg: var(--bs-light-bg-subtle);
+ --bs-alert-border-color: var(--bs-light-border-subtle);
+ --bs-alert-link-color: var(--bs-light-text-emphasis);
}
.alert-dark {
- color: #333333;
- background-color: #dddddd;
- border-color: #cccccc;
-}
-.alert-dark .alert-link {
- color: #292929;
-}
-
-@-webkit-keyframes progress-bar-stripes {
- 0% {
- background-position-x: 1rem;
- }
+ --bs-alert-color: var(--bs-dark-text-emphasis);
+ --bs-alert-bg: var(--bs-dark-bg-subtle);
+ --bs-alert-border-color: var(--bs-dark-border-subtle);
+ --bs-alert-link-color: var(--bs-dark-text-emphasis);
}
@keyframes progress-bar-stripes {
0% {
- background-position-x: 1rem;
+ background-position-x: var(--bs-progress-height);
}
}
-.progress {
+.progress,
+.progress-stacked {
+ --bs-progress-height: 1rem;
+ --bs-progress-font-size: 0.75rem;
+ --bs-progress-bg: var(--bs-secondary-bg);
+ --bs-progress-border-radius: var(--bs-border-radius);
+ --bs-progress-box-shadow: var(--bs-box-shadow-inset);
+ --bs-progress-bar-color: #fff;
+ --bs-progress-bar-bg: #158cba;
+ --bs-progress-bar-transition: width 0.6s ease;
display: flex;
- height: 1rem;
+ height: var(--bs-progress-height);
overflow: hidden;
- font-size: 0.75rem;
- background-color: #f0f0f0;
- border-radius: 0.25rem;
+ font-size: var(--bs-progress-font-size);
+ background-color: var(--bs-progress-bg);
+ border-radius: var(--bs-progress-border-radius);
}
.progress-bar {
@@ -5095,11 +5064,11 @@
flex-direction: column;
justify-content: center;
overflow: hidden;
- color: #fff;
+ color: var(--bs-progress-bar-color);
text-align: center;
white-space: nowrap;
- background-color: #158cba;
- transition: width 0.6s ease;
+ background-color: var(--bs-progress-bar-bg);
+ transition: var(--bs-progress-bar-transition);
}
@media (prefers-reduced-motion: reduce) {
.progress-bar {
@@ -5109,61 +5078,68 @@
.progress-bar-striped {
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
- background-size: 1rem 1rem;
+ background-size: var(--bs-progress-height) var(--bs-progress-height);
+}
+
+.progress-stacked > .progress {
+ overflow: visible;
+}
+
+.progress-stacked > .progress > .progress-bar {
+ width: 100%;
}
.progress-bar-animated {
- -webkit-animation: 1s linear infinite progress-bar-stripes;
animation: 1s linear infinite progress-bar-stripes;
}
@media (prefers-reduced-motion: reduce) {
.progress-bar-animated {
- -webkit-animation: none;
animation: none;
}
}
.list-group {
+ --bs-list-group-color: var(--bs-body-color);
+ --bs-list-group-bg: var(--bs-body-bg);
+ --bs-list-group-border-color: var(--bs-border-color);
+ --bs-list-group-border-width: var(--bs-border-width);
+ --bs-list-group-border-radius: var(--bs-border-radius);
+ --bs-list-group-item-padding-x: 1rem;
+ --bs-list-group-item-padding-y: 0.5rem;
+ --bs-list-group-action-color: var(--bs-secondary-color);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-tertiary-bg);
+ --bs-list-group-action-active-color: var(--bs-body-color);
+ --bs-list-group-action-active-bg: var(--bs-secondary-bg);
+ --bs-list-group-disabled-color: var(--bs-secondary-color);
+ --bs-list-group-disabled-bg: var(--bs-body-bg);
+ --bs-list-group-active-color: #fff;
+ --bs-list-group-active-bg: #158cba;
+ --bs-list-group-active-border-color: #158cba;
display: flex;
flex-direction: column;
padding-left: 0;
margin-bottom: 0;
- border-radius: 0.25rem;
+ border-radius: var(--bs-list-group-border-radius);
}
.list-group-numbered {
list-style-type: none;
counter-reset: section;
}
-.list-group-numbered > li::before {
+.list-group-numbered > .list-group-item::before {
content: counters(section, ".") ". ";
counter-increment: section;
}
-.list-group-item-action {
- width: 100%;
- color: #555;
- text-align: inherit;
-}
-.list-group-item-action:hover, .list-group-item-action:focus {
- z-index: 1;
- color: #555;
- text-decoration: none;
- background-color: #f6f6f6;
-}
-.list-group-item-action:active {
- color: #222;
- background-color: #f0f0f0;
-}
-
.list-group-item {
position: relative;
display: block;
- padding: 0.5rem 1rem;
- color: #222;
+ padding: var(--bs-list-group-item-padding-y) var(--bs-list-group-item-padding-x);
+ color: var(--bs-list-group-color);
text-decoration: none;
- background-color: #fff;
- border: 1px solid rgba(0, 0, 0, 0.125);
+ background-color: var(--bs-list-group-bg);
+ border: var(--bs-list-group-border-width) solid var(--bs-list-group-border-color);
}
.list-group-item:first-child {
border-top-left-radius: inherit;
@@ -5174,332 +5150,373 @@
border-bottom-left-radius: inherit;
}
.list-group-item.disabled, .list-group-item:disabled {
- color: #999;
+ color: var(--bs-list-group-disabled-color);
pointer-events: none;
- background-color: #fff;
+ background-color: var(--bs-list-group-disabled-bg);
}
.list-group-item.active {
z-index: 2;
- color: #fff;
- background-color: #158cba;
- border-color: #158cba;
+ color: var(--bs-list-group-active-color);
+ background-color: var(--bs-list-group-active-bg);
+ border-color: var(--bs-list-group-active-border-color);
}
.list-group-item + .list-group-item {
border-top-width: 0;
}
.list-group-item + .list-group-item.active {
- margin-top: -1px;
- border-top-width: 1px;
+ margin-top: calc(-1 * var(--bs-list-group-border-width));
+ border-top-width: var(--bs-list-group-border-width);
+}
+
+.list-group-item-action {
+ width: 100%;
+ color: var(--bs-list-group-action-color);
+ text-align: inherit;
+}
+.list-group-item-action:not(.active):hover, .list-group-item-action:not(.active):focus {
+ z-index: 1;
+ color: var(--bs-list-group-action-hover-color);
+ text-decoration: none;
+ background-color: var(--bs-list-group-action-hover-bg);
+}
+.list-group-item-action:not(.active):active {
+ color: var(--bs-list-group-action-active-color);
+ background-color: var(--bs-list-group-action-active-bg);
}
.list-group-horizontal {
flex-direction: row;
}
-.list-group-horizontal > .list-group-item:first-child {
- border-bottom-left-radius: 0.25rem;
+.list-group-horizontal > .list-group-item:first-child:not(:last-child) {
+ border-bottom-left-radius: var(--bs-list-group-border-radius);
border-top-right-radius: 0;
}
-.list-group-horizontal > .list-group-item:last-child {
- border-top-right-radius: 0.25rem;
+.list-group-horizontal > .list-group-item:last-child:not(:first-child) {
+ border-top-right-radius: var(--bs-list-group-border-radius);
border-bottom-left-radius: 0;
}
.list-group-horizontal > .list-group-item.active {
margin-top: 0;
}
.list-group-horizontal > .list-group-item + .list-group-item {
- border-top-width: 1px;
+ border-top-width: var(--bs-list-group-border-width);
border-left-width: 0;
}
.list-group-horizontal > .list-group-item + .list-group-item.active {
- margin-left: -1px;
- border-left-width: 1px;
+ margin-left: calc(-1 * var(--bs-list-group-border-width));
+ border-left-width: var(--bs-list-group-border-width);
}
@media (min-width: 576px) {
.list-group-horizontal-sm {
flex-direction: row;
}
- .list-group-horizontal-sm > .list-group-item:first-child {
- border-bottom-left-radius: 0.25rem;
+ .list-group-horizontal-sm > .list-group-item:first-child:not(:last-child) {
+ border-bottom-left-radius: var(--bs-list-group-border-radius);
border-top-right-radius: 0;
}
- .list-group-horizontal-sm > .list-group-item:last-child {
- border-top-right-radius: 0.25rem;
+ .list-group-horizontal-sm > .list-group-item:last-child:not(:first-child) {
+ border-top-right-radius: var(--bs-list-group-border-radius);
border-bottom-left-radius: 0;
}
.list-group-horizontal-sm > .list-group-item.active {
margin-top: 0;
}
.list-group-horizontal-sm > .list-group-item + .list-group-item {
- border-top-width: 1px;
+ border-top-width: var(--bs-list-group-border-width);
border-left-width: 0;
}
.list-group-horizontal-sm > .list-group-item + .list-group-item.active {
- margin-left: -1px;
- border-left-width: 1px;
+ margin-left: calc(-1 * var(--bs-list-group-border-width));
+ border-left-width: var(--bs-list-group-border-width);
}
}
@media (min-width: 768px) {
.list-group-horizontal-md {
flex-direction: row;
}
- .list-group-horizontal-md > .list-group-item:first-child {
- border-bottom-left-radius: 0.25rem;
+ .list-group-horizontal-md > .list-group-item:first-child:not(:last-child) {
+ border-bottom-left-radius: var(--bs-list-group-border-radius);
border-top-right-radius: 0;
}
- .list-group-horizontal-md > .list-group-item:last-child {
- border-top-right-radius: 0.25rem;
+ .list-group-horizontal-md > .list-group-item:last-child:not(:first-child) {
+ border-top-right-radius: var(--bs-list-group-border-radius);
border-bottom-left-radius: 0;
}
.list-group-horizontal-md > .list-group-item.active {
margin-top: 0;
}
.list-group-horizontal-md > .list-group-item + .list-group-item {
- border-top-width: 1px;
+ border-top-width: var(--bs-list-group-border-width);
border-left-width: 0;
}
.list-group-horizontal-md > .list-group-item + .list-group-item.active {
- margin-left: -1px;
- border-left-width: 1px;
+ margin-left: calc(-1 * var(--bs-list-group-border-width));
+ border-left-width: var(--bs-list-group-border-width);
}
}
@media (min-width: 992px) {
.list-group-horizontal-lg {
flex-direction: row;
}
- .list-group-horizontal-lg > .list-group-item:first-child {
- border-bottom-left-radius: 0.25rem;
+ .list-group-horizontal-lg > .list-group-item:first-child:not(:last-child) {
+ border-bottom-left-radius: var(--bs-list-group-border-radius);
border-top-right-radius: 0;
}
- .list-group-horizontal-lg > .list-group-item:last-child {
- border-top-right-radius: 0.25rem;
+ .list-group-horizontal-lg > .list-group-item:last-child:not(:first-child) {
+ border-top-right-radius: var(--bs-list-group-border-radius);
border-bottom-left-radius: 0;
}
.list-group-horizontal-lg > .list-group-item.active {
margin-top: 0;
}
.list-group-horizontal-lg > .list-group-item + .list-group-item {
- border-top-width: 1px;
+ border-top-width: var(--bs-list-group-border-width);
border-left-width: 0;
}
.list-group-horizontal-lg > .list-group-item + .list-group-item.active {
- margin-left: -1px;
- border-left-width: 1px;
+ margin-left: calc(-1 * var(--bs-list-group-border-width));
+ border-left-width: var(--bs-list-group-border-width);
}
}
@media (min-width: 1200px) {
.list-group-horizontal-xl {
flex-direction: row;
}
- .list-group-horizontal-xl > .list-group-item:first-child {
- border-bottom-left-radius: 0.25rem;
+ .list-group-horizontal-xl > .list-group-item:first-child:not(:last-child) {
+ border-bottom-left-radius: var(--bs-list-group-border-radius);
border-top-right-radius: 0;
}
- .list-group-horizontal-xl > .list-group-item:last-child {
- border-top-right-radius: 0.25rem;
+ .list-group-horizontal-xl > .list-group-item:last-child:not(:first-child) {
+ border-top-right-radius: var(--bs-list-group-border-radius);
border-bottom-left-radius: 0;
}
.list-group-horizontal-xl > .list-group-item.active {
margin-top: 0;
}
.list-group-horizontal-xl > .list-group-item + .list-group-item {
- border-top-width: 1px;
+ border-top-width: var(--bs-list-group-border-width);
border-left-width: 0;
}
.list-group-horizontal-xl > .list-group-item + .list-group-item.active {
- margin-left: -1px;
- border-left-width: 1px;
+ margin-left: calc(-1 * var(--bs-list-group-border-width));
+ border-left-width: var(--bs-list-group-border-width);
}
}
@media (min-width: 1400px) {
.list-group-horizontal-xxl {
flex-direction: row;
}
- .list-group-horizontal-xxl > .list-group-item:first-child {
- border-bottom-left-radius: 0.25rem;
+ .list-group-horizontal-xxl > .list-group-item:first-child:not(:last-child) {
+ border-bottom-left-radius: var(--bs-list-group-border-radius);
border-top-right-radius: 0;
}
- .list-group-horizontal-xxl > .list-group-item:last-child {
- border-top-right-radius: 0.25rem;
+ .list-group-horizontal-xxl > .list-group-item:last-child:not(:first-child) {
+ border-top-right-radius: var(--bs-list-group-border-radius);
border-bottom-left-radius: 0;
}
.list-group-horizontal-xxl > .list-group-item.active {
margin-top: 0;
}
.list-group-horizontal-xxl > .list-group-item + .list-group-item {
- border-top-width: 1px;
+ border-top-width: var(--bs-list-group-border-width);
border-left-width: 0;
}
.list-group-horizontal-xxl > .list-group-item + .list-group-item.active {
- margin-left: -1px;
- border-left-width: 1px;
+ margin-left: calc(-1 * var(--bs-list-group-border-width));
+ border-left-width: var(--bs-list-group-border-width);
}
}
.list-group-flush {
border-radius: 0;
}
.list-group-flush > .list-group-item {
- border-width: 0 0 1px;
+ border-width: 0 0 var(--bs-list-group-border-width);
}
.list-group-flush > .list-group-item:last-child {
border-bottom-width: 0;
}
.list-group-item-primary {
- color: #0d5470;
- background-color: #d0e8f1;
-}
-.list-group-item-primary.list-group-item-action:hover, .list-group-item-primary.list-group-item-action:focus {
- color: #0d5470;
- background-color: #bbd1d9;
-}
-.list-group-item-primary.list-group-item-action.active {
- color: #fff;
- background-color: #0d5470;
- border-color: #0d5470;
+ --bs-list-group-color: var(--bs-primary-text-emphasis);
+ --bs-list-group-bg: var(--bs-primary-bg-subtle);
+ --bs-list-group-border-color: var(--bs-primary-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-primary-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-primary-border-subtle);
+ --bs-list-group-active-color: var(--bs-primary-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-primary-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-primary-text-emphasis);
}
.list-group-item-secondary {
- color: #909090;
- background-color: #fcfcfc;
-}
-.list-group-item-secondary.list-group-item-action:hover, .list-group-item-secondary.list-group-item-action:focus {
- color: #909090;
- background-color: #e3e3e3;
-}
-.list-group-item-secondary.list-group-item-action.active {
- color: #fff;
- background-color: #909090;
- border-color: #909090;
+ --bs-list-group-color: var(--bs-secondary-text-emphasis);
+ --bs-list-group-bg: var(--bs-secondary-bg-subtle);
+ --bs-list-group-border-color: var(--bs-secondary-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-secondary-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-secondary-border-subtle);
+ --bs-list-group-active-color: var(--bs-secondary-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-secondary-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-secondary-text-emphasis);
}
.list-group-item-success {
- color: #186d1a;
- background-color: #d4f0d5;
-}
-.list-group-item-success.list-group-item-action:hover, .list-group-item-success.list-group-item-action:focus {
- color: #186d1a;
- background-color: #bfd8c0;
-}
-.list-group-item-success.list-group-item-action.active {
- color: #fff;
- background-color: #186d1a;
- border-color: #186d1a;
+ --bs-list-group-color: var(--bs-success-text-emphasis);
+ --bs-list-group-bg: var(--bs-success-bg-subtle);
+ --bs-list-group-border-color: var(--bs-success-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-success-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-success-border-subtle);
+ --bs-list-group-active-color: var(--bs-success-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-success-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-success-text-emphasis);
}
.list-group-item-info {
- color: #46798d;
- background-color: #e3f4fb;
-}
-.list-group-item-info.list-group-item-action:hover, .list-group-item-info.list-group-item-action:focus {
- color: #46798d;
- background-color: #ccdce2;
-}
-.list-group-item-info.list-group-item-action.active {
- color: #fff;
- background-color: #46798d;
- border-color: #46798d;
+ --bs-list-group-color: var(--bs-info-text-emphasis);
+ --bs-list-group-bg: var(--bs-info-bg-subtle);
+ --bs-list-group-border-color: var(--bs-info-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-info-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-info-border-subtle);
+ --bs-list-group-active-color: var(--bs-info-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-info-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-info-text-emphasis);
}
.list-group-item-warning {
- color: #995010;
- background-color: #ffe7d1;
-}
-.list-group-item-warning.list-group-item-action:hover, .list-group-item-warning.list-group-item-action:focus {
- color: #995010;
- background-color: #e6d0bc;
-}
-.list-group-item-warning.list-group-item-action.active {
- color: #fff;
- background-color: #995010;
- border-color: #995010;
+ --bs-list-group-color: var(--bs-warning-text-emphasis);
+ --bs-list-group-bg: var(--bs-warning-bg-subtle);
+ --bs-list-group-border-color: var(--bs-warning-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-warning-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-warning-border-subtle);
+ --bs-list-group-active-color: var(--bs-warning-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-warning-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-warning-text-emphasis);
}
.list-group-item-danger {
- color: #992720;
- background-color: #ffd9d7;
-}
-.list-group-item-danger.list-group-item-action:hover, .list-group-item-danger.list-group-item-action:focus {
- color: #992720;
- background-color: #e6c3c2;
-}
-.list-group-item-danger.list-group-item-action.active {
- color: #fff;
- background-color: #992720;
- border-color: #992720;
+ --bs-list-group-color: var(--bs-danger-text-emphasis);
+ --bs-list-group-bg: var(--bs-danger-bg-subtle);
+ --bs-list-group-border-color: var(--bs-danger-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-danger-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-danger-border-subtle);
+ --bs-list-group-active-color: var(--bs-danger-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-danger-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-danger-text-emphasis);
}
.list-group-item-light {
- color: #949494;
- background-color: #fdfdfd;
-}
-.list-group-item-light.list-group-item-action:hover, .list-group-item-light.list-group-item-action:focus {
- color: #949494;
- background-color: #e4e4e4;
-}
-.list-group-item-light.list-group-item-action.active {
- color: #fff;
- background-color: #949494;
- border-color: #949494;
+ --bs-list-group-color: var(--bs-light-text-emphasis);
+ --bs-list-group-bg: var(--bs-light-bg-subtle);
+ --bs-list-group-border-color: var(--bs-light-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-light-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-light-border-subtle);
+ --bs-list-group-active-color: var(--bs-light-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-light-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-light-text-emphasis);
}
.list-group-item-dark {
- color: #333333;
- background-color: #dddddd;
-}
-.list-group-item-dark.list-group-item-action:hover, .list-group-item-dark.list-group-item-action:focus {
- color: #333333;
- background-color: #c7c7c7;
-}
-.list-group-item-dark.list-group-item-action.active {
- color: #fff;
- background-color: #333333;
- border-color: #333333;
+ --bs-list-group-color: var(--bs-dark-text-emphasis);
+ --bs-list-group-bg: var(--bs-dark-bg-subtle);
+ --bs-list-group-border-color: var(--bs-dark-border-subtle);
+ --bs-list-group-action-hover-color: var(--bs-emphasis-color);
+ --bs-list-group-action-hover-bg: var(--bs-dark-border-subtle);
+ --bs-list-group-action-active-color: var(--bs-emphasis-color);
+ --bs-list-group-action-active-bg: var(--bs-dark-border-subtle);
+ --bs-list-group-active-color: var(--bs-dark-bg-subtle);
+ --bs-list-group-active-bg: var(--bs-dark-text-emphasis);
+ --bs-list-group-active-border-color: var(--bs-dark-text-emphasis);
}
.btn-close {
+ --bs-btn-close-color: #fff;
+ --bs-btn-close-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M.293.293a1 1 0 0 1 1.414 0L8 6.586 14.293.293a1 1 0 1 1 1.414 1.414L9.414 8l6.293 6.293a1 1 0 0 1-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 0 1-1.414-1.414L6.586 8 .293 1.707a1 1 0 0 1 0-1.414'/%3e%3c/svg%3e");
+ --bs-btn-close-opacity: 0.4;
+ --bs-btn-close-hover-opacity: 1;
+ --bs-btn-close-focus-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
+ --bs-btn-close-focus-opacity: 1;
+ --bs-btn-close-disabled-opacity: 0.25;
box-sizing: content-box;
width: 1em;
height: 1em;
padding: 0.25em 0.25em;
- color: #fff;
- background: transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M.293.293a1 1 0 011.414 0L8 6.586 14.293.293a1 1 0 111.414 1.414L9.414 8l6.293 6.293a1 1 0 01-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 01-1.414-1.414L6.586 8 .293 1.707a1 1 0 010-1.414z'/%3e%3c/svg%3e") center/1em auto no-repeat;
+ color: var(--bs-btn-close-color);
+ background: transparent var(--bs-btn-close-bg) center/1em auto no-repeat;
+ filter: var(--bs-btn-close-filter);
border: 0;
- border-radius: 0.25rem;
- opacity: 0.4;
+ border-radius: 0.375rem;
+ opacity: var(--bs-btn-close-opacity);
}
.btn-close:hover {
- color: #fff;
+ color: var(--bs-btn-close-color);
text-decoration: none;
- opacity: 1;
+ opacity: var(--bs-btn-close-hover-opacity);
}
.btn-close:focus {
outline: 0;
- box-shadow: 0 0 0 0.25rem rgba(21, 140, 186, 0.25);
- opacity: 1;
+ box-shadow: var(--bs-btn-close-focus-shadow);
+ opacity: var(--bs-btn-close-focus-opacity);
}
.btn-close:disabled, .btn-close.disabled {
pointer-events: none;
-webkit-user-select: none;
-moz-user-select: none;
user-select: none;
- opacity: 0.25;
+ opacity: var(--bs-btn-close-disabled-opacity);
}
.btn-close-white {
- filter: invert(1) grayscale(100%) brightness(200%);
+ --bs-btn-close-filter: invert(1) grayscale(100%) brightness(200%);
+}
+
+:root,
+[data-bs-theme=light] {
+ --bs-btn-close-filter: ;
+}
+
+[data-bs-theme=dark] {
+ --bs-btn-close-filter: invert(1) grayscale(100%) brightness(200%);
}
.toast {
- width: 350px;
+ --bs-toast-zindex: 1090;
+ --bs-toast-padding-x: 0.75rem;
+ --bs-toast-padding-y: 0.5rem;
+ --bs-toast-spacing: 1.5rem;
+ --bs-toast-max-width: 350px;
+ --bs-toast-font-size: 0.875rem;
+ --bs-toast-color: ;
+ --bs-toast-bg: rgba(var(--bs-body-bg-rgb), 0.85);
+ --bs-toast-border-width: var(--bs-border-width);
+ --bs-toast-border-color: var(--bs-border-color-translucent);
+ --bs-toast-border-radius: var(--bs-border-radius);
+ --bs-toast-box-shadow: var(--bs-box-shadow);
+ --bs-toast-header-color: var(--bs-secondary-color);
+ --bs-toast-header-bg: rgba(var(--bs-body-bg-rgb), 0.85);
+ --bs-toast-header-border-color: var(--bs-border-color-translucent);
+ width: var(--bs-toast-max-width);
max-width: 100%;
- font-size: 0.875rem;
+ font-size: var(--bs-toast-font-size);
+ color: var(--bs-toast-color);
pointer-events: auto;
- background-color: rgba(255, 255, 255, 0.85);
+ background-color: var(--bs-toast-bg);
background-clip: padding-box;
- border: 1px solid rgba(0, 0, 0, 0.1);
- box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
- border-radius: 0.25rem;
+ border: var(--bs-toast-border-width) solid var(--bs-toast-border-color);
+ box-shadow: var(--bs-toast-box-shadow);
+ border-radius: var(--bs-toast-border-radius);
}
.toast.showing {
opacity: 0;
@@ -5509,6 +5526,9 @@
}
.toast-container {
+ --bs-toast-zindex: 1090;
+ position: absolute;
+ z-index: var(--bs-toast-zindex);
width: -webkit-max-content;
width: -moz-max-content;
width: max-content;
@@ -5516,35 +5536,56 @@
pointer-events: none;
}
.toast-container > :not(:last-child) {
- margin-bottom: 0.75rem;
+ margin-bottom: var(--bs-toast-spacing);
}
.toast-header {
display: flex;
align-items: center;
- padding: 0.5rem 0.75rem;
- color: #999;
- background-color: rgba(255, 255, 255, 0.85);
+ padding: var(--bs-toast-padding-y) var(--bs-toast-padding-x);
+ color: var(--bs-toast-header-color);
+ background-color: var(--bs-toast-header-bg);
background-clip: padding-box;
- border-bottom: 1px solid rgba(0, 0, 0, 0.05);
- border-top-left-radius: calc(0.25rem - 1px);
- border-top-right-radius: calc(0.25rem - 1px);
+ border-bottom: var(--bs-toast-border-width) solid var(--bs-toast-header-border-color);
+ border-top-left-radius: calc(var(--bs-toast-border-radius) - var(--bs-toast-border-width));
+ border-top-right-radius: calc(var(--bs-toast-border-radius) - var(--bs-toast-border-width));
}
.toast-header .btn-close {
- margin-right: -0.375rem;
- margin-left: 0.75rem;
+ margin-right: calc(-0.5 * var(--bs-toast-padding-x));
+ margin-left: var(--bs-toast-padding-x);
}
.toast-body {
- padding: 0.75rem;
+ padding: var(--bs-toast-padding-x);
word-wrap: break-word;
}
.modal {
+ --bs-modal-zindex: 1055;
+ --bs-modal-width: 500px;
+ --bs-modal-padding: 1rem;
+ --bs-modal-margin: 0.5rem;
+ --bs-modal-color: var(--bs-body-color);
+ --bs-modal-bg: var(--bs-body-bg);
+ --bs-modal-border-color: rgba(0, 0, 0, 0.1);
+ --bs-modal-border-width: var(--bs-border-width);
+ --bs-modal-border-radius: var(--bs-border-radius-lg);
+ --bs-modal-box-shadow: var(--bs-box-shadow-sm);
+ --bs-modal-inner-border-radius: calc(var(--bs-border-radius-lg) - (var(--bs-border-width)));
+ --bs-modal-header-padding-x: 1rem;
+ --bs-modal-header-padding-y: 1rem;
+ --bs-modal-header-padding: 1rem 1rem;
+ --bs-modal-header-border-color: var(--bs-border-color);
+ --bs-modal-header-border-width: var(--bs-border-width);
+ --bs-modal-title-line-height: 1.5;
+ --bs-modal-footer-gap: 0.5rem;
+ --bs-modal-footer-bg: ;
+ --bs-modal-footer-border-color: var(--bs-border-color);
+ --bs-modal-footer-border-width: var(--bs-border-width);
position: fixed;
top: 0;
left: 0;
- z-index: 1055;
+ z-index: var(--bs-modal-zindex);
display: none;
width: 100%;
height: 100%;
@@ -5556,12 +5597,12 @@
.modal-dialog {
position: relative;
width: auto;
- margin: 0.5rem;
+ margin: var(--bs-modal-margin);
pointer-events: none;
}
.modal.fade .modal-dialog {
- transition: transform 0.3s ease-out;
transform: translate(0, -50px);
+ transition: transform 0.3s ease-out;
}
@media (prefers-reduced-motion: reduce) {
.modal.fade .modal-dialog {
@@ -5576,7 +5617,7 @@
}
.modal-dialog-scrollable {
- height: calc(100% - 1rem);
+ height: calc(100% - var(--bs-modal-margin) * 2);
}
.modal-dialog-scrollable .modal-content {
max-height: 100%;
@@ -5589,7 +5630,7 @@
.modal-dialog-centered {
display: flex;
align-items: center;
- min-height: calc(100% - 1rem);
+ min-height: calc(100% - var(--bs-modal-margin) * 2);
}
.modal-content {
@@ -5597,98 +5638,101 @@
display: flex;
flex-direction: column;
width: 100%;
+ color: var(--bs-modal-color);
pointer-events: auto;
- background-color: #fff;
+ background-color: var(--bs-modal-bg);
background-clip: padding-box;
- border: 1px solid rgba(0, 0, 0, 0.1);
- border-radius: 0.3rem;
+ border: var(--bs-modal-border-width) solid var(--bs-modal-border-color);
+ border-radius: var(--bs-modal-border-radius);
outline: 0;
}
.modal-backdrop {
+ --bs-backdrop-zindex: 1050;
+ --bs-backdrop-bg: #000;
+ --bs-backdrop-opacity: 0.5;
position: fixed;
top: 0;
left: 0;
- z-index: 1050;
+ z-index: var(--bs-backdrop-zindex);
width: 100vw;
height: 100vh;
- background-color: #000;
+ background-color: var(--bs-backdrop-bg);
}
.modal-backdrop.fade {
opacity: 0;
}
.modal-backdrop.show {
- opacity: 0.5;
+ opacity: var(--bs-backdrop-opacity);
}
.modal-header {
display: flex;
flex-shrink: 0;
align-items: center;
- justify-content: space-between;
- padding: 1rem 1rem;
- border-bottom: 1px solid #dee2e6;
- border-top-left-radius: calc(0.3rem - 1px);
- border-top-right-radius: calc(0.3rem - 1px);
+ padding: var(--bs-modal-header-padding);
+ border-bottom: var(--bs-modal-header-border-width) solid var(--bs-modal-header-border-color);
+ border-top-left-radius: var(--bs-modal-inner-border-radius);
+ border-top-right-radius: var(--bs-modal-inner-border-radius);
}
.modal-header .btn-close {
- padding: 0.5rem 0.5rem;
- margin: -0.5rem -0.5rem -0.5rem auto;
+ padding: calc(var(--bs-modal-header-padding-y) * 0.5) calc(var(--bs-modal-header-padding-x) * 0.5);
+ margin-top: calc(-0.5 * var(--bs-modal-header-padding-y));
+ margin-right: calc(-0.5 * var(--bs-modal-header-padding-x));
+ margin-bottom: calc(-0.5 * var(--bs-modal-header-padding-y));
+ margin-left: auto;
}
.modal-title {
margin-bottom: 0;
- line-height: 1.5;
+ line-height: var(--bs-modal-title-line-height);
}
.modal-body {
position: relative;
flex: 1 1 auto;
- padding: 1rem;
+ padding: var(--bs-modal-padding);
}
.modal-footer {
display: flex;
- flex-wrap: wrap;
flex-shrink: 0;
+ flex-wrap: wrap;
align-items: center;
justify-content: flex-end;
- padding: 0.75rem;
- border-top: 1px solid #dee2e6;
- border-bottom-right-radius: calc(0.3rem - 1px);
- border-bottom-left-radius: calc(0.3rem - 1px);
+ padding: calc(var(--bs-modal-padding) - var(--bs-modal-footer-gap) * 0.5);
+ background-color: var(--bs-modal-footer-bg);
+ border-top: var(--bs-modal-footer-border-width) solid var(--bs-modal-footer-border-color);
+ border-bottom-right-radius: var(--bs-modal-inner-border-radius);
+ border-bottom-left-radius: var(--bs-modal-inner-border-radius);
}
.modal-footer > * {
- margin: 0.25rem;
+ margin: calc(var(--bs-modal-footer-gap) * 0.5);
}
@media (min-width: 576px) {
+ .modal {
+ --bs-modal-margin: 1.75rem;
+ --bs-modal-box-shadow: var(--bs-box-shadow);
+ }
.modal-dialog {
- max-width: 500px;
- margin: 1.75rem auto;
+ max-width: var(--bs-modal-width);
+ margin-right: auto;
+ margin-left: auto;
}
-
- .modal-dialog-scrollable {
- height: calc(100% - 3.5rem);
- }
-
- .modal-dialog-centered {
- min-height: calc(100% - 3.5rem);
- }
-
.modal-sm {
- max-width: 300px;
+ --bs-modal-width: 300px;
}
}
@media (min-width: 992px) {
.modal-lg,
-.modal-xl {
- max-width: 800px;
+ .modal-xl {
+ --bs-modal-width: 800px;
}
}
@media (min-width: 1200px) {
.modal-xl {
- max-width: 1140px;
+ --bs-modal-width: 1140px;
}
}
.modal-fullscreen {
@@ -5702,15 +5746,13 @@
border: 0;
border-radius: 0;
}
-.modal-fullscreen .modal-header {
+.modal-fullscreen .modal-header,
+.modal-fullscreen .modal-footer {
border-radius: 0;
}
.modal-fullscreen .modal-body {
overflow-y: auto;
}
-.modal-fullscreen .modal-footer {
- border-radius: 0;
-}
@media (max-width: 575.98px) {
.modal-fullscreen-sm-down {
@@ -5724,15 +5766,13 @@
border: 0;
border-radius: 0;
}
- .modal-fullscreen-sm-down .modal-header {
+ .modal-fullscreen-sm-down .modal-header,
+ .modal-fullscreen-sm-down .modal-footer {
border-radius: 0;
}
.modal-fullscreen-sm-down .modal-body {
overflow-y: auto;
}
- .modal-fullscreen-sm-down .modal-footer {
- border-radius: 0;
- }
}
@media (max-width: 767.98px) {
.modal-fullscreen-md-down {
@@ -5746,15 +5786,13 @@
border: 0;
border-radius: 0;
}
- .modal-fullscreen-md-down .modal-header {
+ .modal-fullscreen-md-down .modal-header,
+ .modal-fullscreen-md-down .modal-footer {
border-radius: 0;
}
.modal-fullscreen-md-down .modal-body {
overflow-y: auto;
}
- .modal-fullscreen-md-down .modal-footer {
- border-radius: 0;
- }
}
@media (max-width: 991.98px) {
.modal-fullscreen-lg-down {
@@ -5768,15 +5806,13 @@
border: 0;
border-radius: 0;
}
- .modal-fullscreen-lg-down .modal-header {
+ .modal-fullscreen-lg-down .modal-header,
+ .modal-fullscreen-lg-down .modal-footer {
border-radius: 0;
}
.modal-fullscreen-lg-down .modal-body {
overflow-y: auto;
}
- .modal-fullscreen-lg-down .modal-footer {
- border-radius: 0;
- }
}
@media (max-width: 1199.98px) {
.modal-fullscreen-xl-down {
@@ -5790,15 +5826,13 @@
border: 0;
border-radius: 0;
}
- .modal-fullscreen-xl-down .modal-header {
+ .modal-fullscreen-xl-down .modal-header,
+ .modal-fullscreen-xl-down .modal-footer {
border-radius: 0;
}
.modal-fullscreen-xl-down .modal-body {
overflow-y: auto;
}
- .modal-fullscreen-xl-down .modal-footer {
- border-radius: 0;
- }
}
@media (max-width: 1399.98px) {
.modal-fullscreen-xxl-down {
@@ -5812,21 +5846,30 @@
border: 0;
border-radius: 0;
}
- .modal-fullscreen-xxl-down .modal-header {
+ .modal-fullscreen-xxl-down .modal-header,
+ .modal-fullscreen-xxl-down .modal-footer {
border-radius: 0;
}
.modal-fullscreen-xxl-down .modal-body {
overflow-y: auto;
}
- .modal-fullscreen-xxl-down .modal-footer {
- border-radius: 0;
- }
}
.tooltip {
- position: absolute;
- z-index: 1080;
+ --bs-tooltip-zindex: 1080;
+ --bs-tooltip-max-width: 200px;
+ --bs-tooltip-padding-x: 0.5rem;
+ --bs-tooltip-padding-y: 0.25rem;
+ --bs-tooltip-margin: ;
+ --bs-tooltip-font-size: 0.875rem;
+ --bs-tooltip-color: var(--bs-body-bg);
+ --bs-tooltip-bg: var(--bs-emphasis-color);
+ --bs-tooltip-border-radius: var(--bs-border-radius);
+ --bs-tooltip-opacity: 0.9;
+ --bs-tooltip-arrow-width: 0.8rem;
+ --bs-tooltip-arrow-height: 0.4rem;
+ z-index: var(--bs-tooltip-zindex);
display: block;
- margin: 0;
+ margin: var(--bs-tooltip-margin);
font-family: var(--bs-font-sans-serif);
font-style: normal;
font-weight: 400;
@@ -5838,21 +5881,20 @@
text-transform: none;
letter-spacing: normal;
word-break: normal;
- word-spacing: normal;
white-space: normal;
+ word-spacing: normal;
line-break: auto;
- font-size: 0.875rem;
+ font-size: var(--bs-tooltip-font-size);
word-wrap: break-word;
opacity: 0;
}
.tooltip.show {
- opacity: 0.9;
+ opacity: var(--bs-tooltip-opacity);
}
.tooltip .tooltip-arrow {
- position: absolute;
display: block;
- width: 0.8rem;
- height: 0.4rem;
+ width: var(--bs-tooltip-arrow-width);
+ height: var(--bs-tooltip-arrow-height);
}
.tooltip .tooltip-arrow::before {
position: absolute;
@@ -5861,74 +5903,83 @@
border-style: solid;
}
-.bs-tooltip-top, .bs-tooltip-auto[data-popper-placement^=top] {
- padding: 0.4rem 0;
-}
.bs-tooltip-top .tooltip-arrow, .bs-tooltip-auto[data-popper-placement^=top] .tooltip-arrow {
- bottom: 0;
+ bottom: calc(-1 * var(--bs-tooltip-arrow-height));
}
.bs-tooltip-top .tooltip-arrow::before, .bs-tooltip-auto[data-popper-placement^=top] .tooltip-arrow::before {
top: -1px;
- border-width: 0.4rem 0.4rem 0;
- border-top-color: #000;
+ border-width: var(--bs-tooltip-arrow-height) calc(var(--bs-tooltip-arrow-width) * 0.5) 0;
+ border-top-color: var(--bs-tooltip-bg);
}
-.bs-tooltip-end, .bs-tooltip-auto[data-popper-placement^=right] {
- padding: 0 0.4rem;
-}
+/* rtl:begin:ignore */
.bs-tooltip-end .tooltip-arrow, .bs-tooltip-auto[data-popper-placement^=right] .tooltip-arrow {
- left: 0;
- width: 0.4rem;
- height: 0.8rem;
+ left: calc(-1 * var(--bs-tooltip-arrow-height));
+ width: var(--bs-tooltip-arrow-height);
+ height: var(--bs-tooltip-arrow-width);
}
.bs-tooltip-end .tooltip-arrow::before, .bs-tooltip-auto[data-popper-placement^=right] .tooltip-arrow::before {
right: -1px;
- border-width: 0.4rem 0.4rem 0.4rem 0;
- border-right-color: #000;
+ border-width: calc(var(--bs-tooltip-arrow-width) * 0.5) var(--bs-tooltip-arrow-height) calc(var(--bs-tooltip-arrow-width) * 0.5) 0;
+ border-right-color: var(--bs-tooltip-bg);
}
-.bs-tooltip-bottom, .bs-tooltip-auto[data-popper-placement^=bottom] {
- padding: 0.4rem 0;
-}
+/* rtl:end:ignore */
.bs-tooltip-bottom .tooltip-arrow, .bs-tooltip-auto[data-popper-placement^=bottom] .tooltip-arrow {
- top: 0;
+ top: calc(-1 * var(--bs-tooltip-arrow-height));
}
.bs-tooltip-bottom .tooltip-arrow::before, .bs-tooltip-auto[data-popper-placement^=bottom] .tooltip-arrow::before {
bottom: -1px;
- border-width: 0 0.4rem 0.4rem;
- border-bottom-color: #000;
+ border-width: 0 calc(var(--bs-tooltip-arrow-width) * 0.5) var(--bs-tooltip-arrow-height);
+ border-bottom-color: var(--bs-tooltip-bg);
}
-.bs-tooltip-start, .bs-tooltip-auto[data-popper-placement^=left] {
- padding: 0 0.4rem;
-}
+/* rtl:begin:ignore */
.bs-tooltip-start .tooltip-arrow, .bs-tooltip-auto[data-popper-placement^=left] .tooltip-arrow {
- right: 0;
- width: 0.4rem;
- height: 0.8rem;
+ right: calc(-1 * var(--bs-tooltip-arrow-height));
+ width: var(--bs-tooltip-arrow-height);
+ height: var(--bs-tooltip-arrow-width);
}
.bs-tooltip-start .tooltip-arrow::before, .bs-tooltip-auto[data-popper-placement^=left] .tooltip-arrow::before {
left: -1px;
- border-width: 0.4rem 0 0.4rem 0.4rem;
- border-left-color: #000;
+ border-width: calc(var(--bs-tooltip-arrow-width) * 0.5) 0 calc(var(--bs-tooltip-arrow-width) * 0.5) var(--bs-tooltip-arrow-height);
+ border-left-color: var(--bs-tooltip-bg);
}
+/* rtl:end:ignore */
.tooltip-inner {
- max-width: 200px;
- padding: 0.25rem 0.5rem;
- color: #fff;
+ max-width: var(--bs-tooltip-max-width);
+ padding: var(--bs-tooltip-padding-y) var(--bs-tooltip-padding-x);
+ color: var(--bs-tooltip-color);
text-align: center;
- background-color: #000;
- border-radius: 0.25rem;
+ background-color: var(--bs-tooltip-bg);
+ border-radius: var(--bs-tooltip-border-radius);
}
.popover {
- position: absolute;
- top: 0;
- left: 0 /* rtl:ignore */;
- z-index: 1070;
+ --bs-popover-zindex: 1070;
+ --bs-popover-max-width: 276px;
+ --bs-popover-font-size: 0.875rem;
+ --bs-popover-bg: var(--bs-body-bg);
+ --bs-popover-border-width: var(--bs-border-width);
+ --bs-popover-border-color: var(--bs-border-color-translucent);
+ --bs-popover-border-radius: var(--bs-border-radius-lg);
+ --bs-popover-inner-border-radius: calc(var(--bs-border-radius-lg) - var(--bs-border-width));
+ --bs-popover-box-shadow: var(--bs-box-shadow);
+ --bs-popover-header-padding-x: 1rem;
+ --bs-popover-header-padding-y: 0.5rem;
+ --bs-popover-header-font-size: 1rem;
+ --bs-popover-header-color: inherit;
+ --bs-popover-header-bg: var(--bs-secondary-bg);
+ --bs-popover-body-padding-x: 1rem;
+ --bs-popover-body-padding-y: 1rem;
+ --bs-popover-body-color: var(--bs-body-color);
+ --bs-popover-arrow-width: 1rem;
+ --bs-popover-arrow-height: 0.5rem;
+ --bs-popover-arrow-border: var(--bs-popover-border-color);
+ z-index: var(--bs-popover-zindex);
display: block;
- max-width: 276px;
+ max-width: var(--bs-popover-max-width);
font-family: var(--bs-font-sans-serif);
font-style: normal;
font-weight: 400;
@@ -5940,21 +5991,20 @@
text-transform: none;
letter-spacing: normal;
word-break: normal;
- word-spacing: normal;
white-space: normal;
+ word-spacing: normal;
line-break: auto;
- font-size: 0.875rem;
+ font-size: var(--bs-popover-font-size);
word-wrap: break-word;
- background-color: #fff;
+ background-color: var(--bs-popover-bg);
background-clip: padding-box;
- border: 1px solid rgba(0, 0, 0, 0.2);
- border-radius: 0.3rem;
+ border: var(--bs-popover-border-width) solid var(--bs-popover-border-color);
+ border-radius: var(--bs-popover-border-radius);
}
.popover .popover-arrow {
- position: absolute;
display: block;
- width: 1rem;
- height: 0.5rem;
+ width: var(--bs-popover-arrow-width);
+ height: var(--bs-popover-arrow-height);
}
.popover .popover-arrow::before, .popover .popover-arrow::after {
position: absolute;
@@ -5962,94 +6012,104 @@
content: "";
border-color: transparent;
border-style: solid;
+ border-width: 0;
}
.bs-popover-top > .popover-arrow, .bs-popover-auto[data-popper-placement^=top] > .popover-arrow {
- bottom: calc(-0.5rem - 1px);
+ bottom: calc(-1 * (var(--bs-popover-arrow-height)) - var(--bs-popover-border-width));
+}
+.bs-popover-top > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=top] > .popover-arrow::before, .bs-popover-top > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=top] > .popover-arrow::after {
+ border-width: var(--bs-popover-arrow-height) calc(var(--bs-popover-arrow-width) * 0.5) 0;
}
.bs-popover-top > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=top] > .popover-arrow::before {
bottom: 0;
- border-width: 0.5rem 0.5rem 0;
- border-top-color: rgba(0, 0, 0, 0.25);
+ border-top-color: var(--bs-popover-arrow-border);
}
.bs-popover-top > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=top] > .popover-arrow::after {
- bottom: 1px;
- border-width: 0.5rem 0.5rem 0;
- border-top-color: #fff;
+ bottom: var(--bs-popover-border-width);
+ border-top-color: var(--bs-popover-bg);
}
+/* rtl:begin:ignore */
.bs-popover-end > .popover-arrow, .bs-popover-auto[data-popper-placement^=right] > .popover-arrow {
- left: calc(-0.5rem - 1px);
- width: 0.5rem;
- height: 1rem;
+ left: calc(-1 * (var(--bs-popover-arrow-height)) - var(--bs-popover-border-width));
+ width: var(--bs-popover-arrow-height);
+ height: var(--bs-popover-arrow-width);
+}
+.bs-popover-end > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=right] > .popover-arrow::before, .bs-popover-end > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=right] > .popover-arrow::after {
+ border-width: calc(var(--bs-popover-arrow-width) * 0.5) var(--bs-popover-arrow-height) calc(var(--bs-popover-arrow-width) * 0.5) 0;
}
.bs-popover-end > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=right] > .popover-arrow::before {
left: 0;
- border-width: 0.5rem 0.5rem 0.5rem 0;
- border-right-color: rgba(0, 0, 0, 0.25);
+ border-right-color: var(--bs-popover-arrow-border);
}
.bs-popover-end > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=right] > .popover-arrow::after {
- left: 1px;
- border-width: 0.5rem 0.5rem 0.5rem 0;
- border-right-color: #fff;
+ left: var(--bs-popover-border-width);
+ border-right-color: var(--bs-popover-bg);
}
+/* rtl:end:ignore */
.bs-popover-bottom > .popover-arrow, .bs-popover-auto[data-popper-placement^=bottom] > .popover-arrow {
- top: calc(-0.5rem - 1px);
+ top: calc(-1 * (var(--bs-popover-arrow-height)) - var(--bs-popover-border-width));
+}
+.bs-popover-bottom > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=bottom] > .popover-arrow::before, .bs-popover-bottom > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=bottom] > .popover-arrow::after {
+ border-width: 0 calc(var(--bs-popover-arrow-width) * 0.5) var(--bs-popover-arrow-height);
}
.bs-popover-bottom > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=bottom] > .popover-arrow::before {
top: 0;
- border-width: 0 0.5rem 0.5rem 0.5rem;
- border-bottom-color: rgba(0, 0, 0, 0.25);
+ border-bottom-color: var(--bs-popover-arrow-border);
}
.bs-popover-bottom > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=bottom] > .popover-arrow::after {
- top: 1px;
- border-width: 0 0.5rem 0.5rem 0.5rem;
- border-bottom-color: #fff;
+ top: var(--bs-popover-border-width);
+ border-bottom-color: var(--bs-popover-bg);
}
.bs-popover-bottom .popover-header::before, .bs-popover-auto[data-popper-placement^=bottom] .popover-header::before {
position: absolute;
top: 0;
left: 50%;
display: block;
- width: 1rem;
- margin-left: -0.5rem;
+ width: var(--bs-popover-arrow-width);
+ margin-left: calc(-0.5 * var(--bs-popover-arrow-width));
content: "";
- border-bottom: 1px solid #f0f0f0;
+ border-bottom: var(--bs-popover-border-width) solid var(--bs-popover-header-bg);
}
+/* rtl:begin:ignore */
.bs-popover-start > .popover-arrow, .bs-popover-auto[data-popper-placement^=left] > .popover-arrow {
- right: calc(-0.5rem - 1px);
- width: 0.5rem;
- height: 1rem;
+ right: calc(-1 * (var(--bs-popover-arrow-height)) - var(--bs-popover-border-width));
+ width: var(--bs-popover-arrow-height);
+ height: var(--bs-popover-arrow-width);
+}
+.bs-popover-start > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=left] > .popover-arrow::before, .bs-popover-start > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=left] > .popover-arrow::after {
+ border-width: calc(var(--bs-popover-arrow-width) * 0.5) 0 calc(var(--bs-popover-arrow-width) * 0.5) var(--bs-popover-arrow-height);
}
.bs-popover-start > .popover-arrow::before, .bs-popover-auto[data-popper-placement^=left] > .popover-arrow::before {
right: 0;
- border-width: 0.5rem 0 0.5rem 0.5rem;
- border-left-color: rgba(0, 0, 0, 0.25);
+ border-left-color: var(--bs-popover-arrow-border);
}
.bs-popover-start > .popover-arrow::after, .bs-popover-auto[data-popper-placement^=left] > .popover-arrow::after {
- right: 1px;
- border-width: 0.5rem 0 0.5rem 0.5rem;
- border-left-color: #fff;
+ right: var(--bs-popover-border-width);
+ border-left-color: var(--bs-popover-bg);
}
+/* rtl:end:ignore */
.popover-header {
- padding: 0.5rem 1rem;
+ padding: var(--bs-popover-header-padding-y) var(--bs-popover-header-padding-x);
margin-bottom: 0;
- font-size: 1rem;
- background-color: #f0f0f0;
- border-bottom: 1px solid rgba(0, 0, 0, 0.2);
- border-top-left-radius: calc(0.3rem - 1px);
- border-top-right-radius: calc(0.3rem - 1px);
+ font-size: var(--bs-popover-header-font-size);
+ color: var(--bs-popover-header-color);
+ background-color: var(--bs-popover-header-bg);
+ border-bottom: var(--bs-popover-border-width) solid var(--bs-popover-border-color);
+ border-top-left-radius: var(--bs-popover-inner-border-radius);
+ border-top-right-radius: var(--bs-popover-inner-border-radius);
}
.popover-header:empty {
display: none;
}
.popover-body {
- padding: 1rem 1rem;
- color: #222;
+ padding: var(--bs-popover-body-padding-y) var(--bs-popover-body-padding-x);
+ color: var(--bs-popover-body-color);
}
.carousel {
@@ -6093,7 +6153,6 @@
display: block;
}
-/* rtl:begin:ignore */
.carousel-item-next:not(.carousel-item-start),
.active.carousel-item-end {
transform: translateX(100%);
@@ -6104,7 +6163,6 @@
transform: translateX(-100%);
}
-/* rtl:end:ignore */
.carousel-fade .carousel-item {
opacity: 0;
transition-property: opacity;
@@ -6124,7 +6182,7 @@
}
@media (prefers-reduced-motion: reduce) {
.carousel-fade .active.carousel-item-start,
-.carousel-fade .active.carousel-item-end {
+ .carousel-fade .active.carousel-item-end {
transition: none;
}
}
@@ -6143,13 +6201,14 @@
color: #fff;
text-align: center;
background: none;
+ filter: var(--bs-carousel-control-icon-filter);
border: 0;
opacity: 0.5;
transition: opacity 0.15s ease;
}
@media (prefers-reduced-motion: reduce) {
.carousel-control-prev,
-.carousel-control-next {
+ .carousel-control-next {
transition: none;
}
}
@@ -6180,20 +6239,12 @@
background-size: 100% 100%;
}
-/* rtl:options: {
- "autoRename": true,
- "stringMap":[ {
- "name" : "prev-next",
- "search" : "prev",
- "replace" : "next"
- } ]
-} */
.carousel-control-prev-icon {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0z'/%3e%3c/svg%3e");
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0'/%3e%3c/svg%3e") /*rtl:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708'/%3e%3c/svg%3e")*/;
}
.carousel-control-next-icon {
- background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708'/%3e%3c/svg%3e") /*rtl:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23fff'%3e%3cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0'/%3e%3c/svg%3e")*/;
}
.carousel-indicators {
@@ -6208,7 +6259,6 @@
margin-right: 15%;
margin-bottom: 1rem;
margin-left: 15%;
- list-style: none;
}
.carousel-indicators [data-bs-target] {
box-sizing: content-box;
@@ -6220,7 +6270,7 @@
margin-left: 3px;
text-indent: -999px;
cursor: pointer;
- background-color: #fff;
+ background-color: var(--bs-carousel-indicator-active-bg);
background-clip: padding-box;
border: 0;
border-top: 10px solid transparent;
@@ -6244,25 +6294,38 @@
left: 15%;
padding-top: 1.25rem;
padding-bottom: 1.25rem;
- color: #fff;
+ color: var(--bs-carousel-caption-color);
text-align: center;
}
-.carousel-dark .carousel-control-prev-icon,
-.carousel-dark .carousel-control-next-icon {
- filter: invert(1) grayscale(100);
-}
-.carousel-dark .carousel-indicators [data-bs-target] {
- background-color: #000;
-}
-.carousel-dark .carousel-caption {
- color: #000;
+.carousel-dark {
+ --bs-carousel-indicator-active-bg: #000;
+ --bs-carousel-caption-color: #000;
+ --bs-carousel-control-icon-filter: invert(1) grayscale(100);
}
-@-webkit-keyframes spinner-border {
- to {
- transform: rotate(360deg) /* rtl:ignore */;
- }
+:root,
+[data-bs-theme=light] {
+ --bs-carousel-indicator-active-bg: #fff;
+ --bs-carousel-caption-color: #fff;
+ --bs-carousel-control-icon-filter: ;
+}
+
+[data-bs-theme=dark] {
+ --bs-carousel-indicator-active-bg: #000;
+ --bs-carousel-caption-color: #000;
+ --bs-carousel-control-icon-filter: invert(1) grayscale(100);
+}
+
+.spinner-grow,
+.spinner-border {
+ display: inline-block;
+ flex-shrink: 0;
+ width: var(--bs-spinner-width);
+ height: var(--bs-spinner-height);
+ vertical-align: var(--bs-spinner-vertical-align);
+ border-radius: 50%;
+ animation: var(--bs-spinner-animation-speed) linear infinite var(--bs-spinner-animation-name);
}
@keyframes spinner-border {
@@ -6271,31 +6334,20 @@
}
}
.spinner-border {
- display: inline-block;
- width: 2rem;
- height: 2rem;
- vertical-align: -0.125em;
- border: 0.25em solid currentColor;
+ --bs-spinner-width: 2rem;
+ --bs-spinner-height: 2rem;
+ --bs-spinner-vertical-align: -0.125em;
+ --bs-spinner-border-width: 0.25em;
+ --bs-spinner-animation-speed: 0.75s;
+ --bs-spinner-animation-name: spinner-border;
+ border: var(--bs-spinner-border-width) solid currentcolor;
border-right-color: transparent;
- border-radius: 50%;
- -webkit-animation: 0.75s linear infinite spinner-border;
- animation: 0.75s linear infinite spinner-border;
}
.spinner-border-sm {
- width: 1rem;
- height: 1rem;
- border-width: 0.2em;
-}
-
-@-webkit-keyframes spinner-grow {
- 0% {
- transform: scale(0);
- }
- 50% {
- opacity: 1;
- transform: none;
- }
+ --bs-spinner-width: 1rem;
+ --bs-spinner-height: 1rem;
+ --bs-spinner-border-width: 0.2em;
}
@keyframes spinner-grow {
@@ -6308,47 +6360,487 @@
}
}
.spinner-grow {
- display: inline-block;
- width: 2rem;
- height: 2rem;
- vertical-align: -0.125em;
- background-color: currentColor;
- border-radius: 50%;
+ --bs-spinner-width: 2rem;
+ --bs-spinner-height: 2rem;
+ --bs-spinner-vertical-align: -0.125em;
+ --bs-spinner-animation-speed: 0.75s;
+ --bs-spinner-animation-name: spinner-grow;
+ background-color: currentcolor;
opacity: 0;
- -webkit-animation: 0.75s linear infinite spinner-grow;
- animation: 0.75s linear infinite spinner-grow;
}
.spinner-grow-sm {
- width: 1rem;
- height: 1rem;
+ --bs-spinner-width: 1rem;
+ --bs-spinner-height: 1rem;
}
@media (prefers-reduced-motion: reduce) {
.spinner-border,
-.spinner-grow {
- -webkit-animation-duration: 1.5s;
- animation-duration: 1.5s;
+ .spinner-grow {
+ --bs-spinner-animation-speed: 1.5s;
}
}
+.offcanvas, .offcanvas-xxl, .offcanvas-xl, .offcanvas-lg, .offcanvas-md, .offcanvas-sm {
+ --bs-offcanvas-zindex: 1045;
+ --bs-offcanvas-width: 400px;
+ --bs-offcanvas-height: 30vh;
+ --bs-offcanvas-padding-x: 1rem;
+ --bs-offcanvas-padding-y: 1rem;
+ --bs-offcanvas-color: var(--bs-body-color);
+ --bs-offcanvas-bg: var(--bs-body-bg);
+ --bs-offcanvas-border-width: var(--bs-border-width);
+ --bs-offcanvas-border-color: rgba(0, 0, 0, 0.1);
+ --bs-offcanvas-box-shadow: var(--bs-box-shadow-sm);
+ --bs-offcanvas-transition: transform 0.3s ease-in-out;
+ --bs-offcanvas-title-line-height: 1.5;
+}
+
+@media (max-width: 575.98px) {
+ .offcanvas-sm {
+ position: fixed;
+ bottom: 0;
+ z-index: var(--bs-offcanvas-zindex);
+ display: flex;
+ flex-direction: column;
+ max-width: 100%;
+ color: var(--bs-offcanvas-color);
+ visibility: hidden;
+ background-color: var(--bs-offcanvas-bg);
+ background-clip: padding-box;
+ outline: 0;
+ transition: var(--bs-offcanvas-transition);
+ }
+}
+@media (max-width: 575.98px) and (prefers-reduced-motion: reduce) {
+ .offcanvas-sm {
+ transition: none;
+ }
+}
+@media (max-width: 575.98px) {
+ .offcanvas-sm.offcanvas-start {
+ top: 0;
+ left: 0;
+ width: var(--bs-offcanvas-width);
+ border-right: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(-100%);
+ }
+ .offcanvas-sm.offcanvas-end {
+ top: 0;
+ right: 0;
+ width: var(--bs-offcanvas-width);
+ border-left: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(100%);
+ }
+ .offcanvas-sm.offcanvas-top {
+ top: 0;
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-bottom: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(-100%);
+ }
+ .offcanvas-sm.offcanvas-bottom {
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-top: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(100%);
+ }
+ .offcanvas-sm.showing, .offcanvas-sm.show:not(.hiding) {
+ transform: none;
+ }
+ .offcanvas-sm.showing, .offcanvas-sm.hiding, .offcanvas-sm.show {
+ visibility: visible;
+ }
+}
+@media (min-width: 576px) {
+ .offcanvas-sm {
+ --bs-offcanvas-height: auto;
+ --bs-offcanvas-border-width: 0;
+ background-color: transparent !important;
+ }
+ .offcanvas-sm .offcanvas-header {
+ display: none;
+ }
+ .offcanvas-sm .offcanvas-body {
+ display: flex;
+ flex-grow: 0;
+ padding: 0;
+ overflow-y: visible;
+ background-color: transparent !important;
+ }
+}
+
+@media (max-width: 767.98px) {
+ .offcanvas-md {
+ position: fixed;
+ bottom: 0;
+ z-index: var(--bs-offcanvas-zindex);
+ display: flex;
+ flex-direction: column;
+ max-width: 100%;
+ color: var(--bs-offcanvas-color);
+ visibility: hidden;
+ background-color: var(--bs-offcanvas-bg);
+ background-clip: padding-box;
+ outline: 0;
+ transition: var(--bs-offcanvas-transition);
+ }
+}
+@media (max-width: 767.98px) and (prefers-reduced-motion: reduce) {
+ .offcanvas-md {
+ transition: none;
+ }
+}
+@media (max-width: 767.98px) {
+ .offcanvas-md.offcanvas-start {
+ top: 0;
+ left: 0;
+ width: var(--bs-offcanvas-width);
+ border-right: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(-100%);
+ }
+ .offcanvas-md.offcanvas-end {
+ top: 0;
+ right: 0;
+ width: var(--bs-offcanvas-width);
+ border-left: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(100%);
+ }
+ .offcanvas-md.offcanvas-top {
+ top: 0;
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-bottom: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(-100%);
+ }
+ .offcanvas-md.offcanvas-bottom {
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-top: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(100%);
+ }
+ .offcanvas-md.showing, .offcanvas-md.show:not(.hiding) {
+ transform: none;
+ }
+ .offcanvas-md.showing, .offcanvas-md.hiding, .offcanvas-md.show {
+ visibility: visible;
+ }
+}
+@media (min-width: 768px) {
+ .offcanvas-md {
+ --bs-offcanvas-height: auto;
+ --bs-offcanvas-border-width: 0;
+ background-color: transparent !important;
+ }
+ .offcanvas-md .offcanvas-header {
+ display: none;
+ }
+ .offcanvas-md .offcanvas-body {
+ display: flex;
+ flex-grow: 0;
+ padding: 0;
+ overflow-y: visible;
+ background-color: transparent !important;
+ }
+}
+
+@media (max-width: 991.98px) {
+ .offcanvas-lg {
+ position: fixed;
+ bottom: 0;
+ z-index: var(--bs-offcanvas-zindex);
+ display: flex;
+ flex-direction: column;
+ max-width: 100%;
+ color: var(--bs-offcanvas-color);
+ visibility: hidden;
+ background-color: var(--bs-offcanvas-bg);
+ background-clip: padding-box;
+ outline: 0;
+ transition: var(--bs-offcanvas-transition);
+ }
+}
+@media (max-width: 991.98px) and (prefers-reduced-motion: reduce) {
+ .offcanvas-lg {
+ transition: none;
+ }
+}
+@media (max-width: 991.98px) {
+ .offcanvas-lg.offcanvas-start {
+ top: 0;
+ left: 0;
+ width: var(--bs-offcanvas-width);
+ border-right: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(-100%);
+ }
+ .offcanvas-lg.offcanvas-end {
+ top: 0;
+ right: 0;
+ width: var(--bs-offcanvas-width);
+ border-left: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(100%);
+ }
+ .offcanvas-lg.offcanvas-top {
+ top: 0;
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-bottom: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(-100%);
+ }
+ .offcanvas-lg.offcanvas-bottom {
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-top: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(100%);
+ }
+ .offcanvas-lg.showing, .offcanvas-lg.show:not(.hiding) {
+ transform: none;
+ }
+ .offcanvas-lg.showing, .offcanvas-lg.hiding, .offcanvas-lg.show {
+ visibility: visible;
+ }
+}
+@media (min-width: 992px) {
+ .offcanvas-lg {
+ --bs-offcanvas-height: auto;
+ --bs-offcanvas-border-width: 0;
+ background-color: transparent !important;
+ }
+ .offcanvas-lg .offcanvas-header {
+ display: none;
+ }
+ .offcanvas-lg .offcanvas-body {
+ display: flex;
+ flex-grow: 0;
+ padding: 0;
+ overflow-y: visible;
+ background-color: transparent !important;
+ }
+}
+
+@media (max-width: 1199.98px) {
+ .offcanvas-xl {
+ position: fixed;
+ bottom: 0;
+ z-index: var(--bs-offcanvas-zindex);
+ display: flex;
+ flex-direction: column;
+ max-width: 100%;
+ color: var(--bs-offcanvas-color);
+ visibility: hidden;
+ background-color: var(--bs-offcanvas-bg);
+ background-clip: padding-box;
+ outline: 0;
+ transition: var(--bs-offcanvas-transition);
+ }
+}
+@media (max-width: 1199.98px) and (prefers-reduced-motion: reduce) {
+ .offcanvas-xl {
+ transition: none;
+ }
+}
+@media (max-width: 1199.98px) {
+ .offcanvas-xl.offcanvas-start {
+ top: 0;
+ left: 0;
+ width: var(--bs-offcanvas-width);
+ border-right: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(-100%);
+ }
+ .offcanvas-xl.offcanvas-end {
+ top: 0;
+ right: 0;
+ width: var(--bs-offcanvas-width);
+ border-left: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(100%);
+ }
+ .offcanvas-xl.offcanvas-top {
+ top: 0;
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-bottom: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(-100%);
+ }
+ .offcanvas-xl.offcanvas-bottom {
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-top: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(100%);
+ }
+ .offcanvas-xl.showing, .offcanvas-xl.show:not(.hiding) {
+ transform: none;
+ }
+ .offcanvas-xl.showing, .offcanvas-xl.hiding, .offcanvas-xl.show {
+ visibility: visible;
+ }
+}
+@media (min-width: 1200px) {
+ .offcanvas-xl {
+ --bs-offcanvas-height: auto;
+ --bs-offcanvas-border-width: 0;
+ background-color: transparent !important;
+ }
+ .offcanvas-xl .offcanvas-header {
+ display: none;
+ }
+ .offcanvas-xl .offcanvas-body {
+ display: flex;
+ flex-grow: 0;
+ padding: 0;
+ overflow-y: visible;
+ background-color: transparent !important;
+ }
+}
+
+@media (max-width: 1399.98px) {
+ .offcanvas-xxl {
+ position: fixed;
+ bottom: 0;
+ z-index: var(--bs-offcanvas-zindex);
+ display: flex;
+ flex-direction: column;
+ max-width: 100%;
+ color: var(--bs-offcanvas-color);
+ visibility: hidden;
+ background-color: var(--bs-offcanvas-bg);
+ background-clip: padding-box;
+ outline: 0;
+ transition: var(--bs-offcanvas-transition);
+ }
+}
+@media (max-width: 1399.98px) and (prefers-reduced-motion: reduce) {
+ .offcanvas-xxl {
+ transition: none;
+ }
+}
+@media (max-width: 1399.98px) {
+ .offcanvas-xxl.offcanvas-start {
+ top: 0;
+ left: 0;
+ width: var(--bs-offcanvas-width);
+ border-right: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(-100%);
+ }
+ .offcanvas-xxl.offcanvas-end {
+ top: 0;
+ right: 0;
+ width: var(--bs-offcanvas-width);
+ border-left: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(100%);
+ }
+ .offcanvas-xxl.offcanvas-top {
+ top: 0;
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-bottom: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(-100%);
+ }
+ .offcanvas-xxl.offcanvas-bottom {
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-top: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(100%);
+ }
+ .offcanvas-xxl.showing, .offcanvas-xxl.show:not(.hiding) {
+ transform: none;
+ }
+ .offcanvas-xxl.showing, .offcanvas-xxl.hiding, .offcanvas-xxl.show {
+ visibility: visible;
+ }
+}
+@media (min-width: 1400px) {
+ .offcanvas-xxl {
+ --bs-offcanvas-height: auto;
+ --bs-offcanvas-border-width: 0;
+ background-color: transparent !important;
+ }
+ .offcanvas-xxl .offcanvas-header {
+ display: none;
+ }
+ .offcanvas-xxl .offcanvas-body {
+ display: flex;
+ flex-grow: 0;
+ padding: 0;
+ overflow-y: visible;
+ background-color: transparent !important;
+ }
+}
+
.offcanvas {
position: fixed;
bottom: 0;
- z-index: 1045;
+ z-index: var(--bs-offcanvas-zindex);
display: flex;
flex-direction: column;
max-width: 100%;
+ color: var(--bs-offcanvas-color);
visibility: hidden;
- background-color: #fff;
+ background-color: var(--bs-offcanvas-bg);
background-clip: padding-box;
outline: 0;
- transition: transform 0.3s ease-in-out;
+ transition: var(--bs-offcanvas-transition);
}
@media (prefers-reduced-motion: reduce) {
.offcanvas {
transition: none;
}
}
+.offcanvas.offcanvas-start {
+ top: 0;
+ left: 0;
+ width: var(--bs-offcanvas-width);
+ border-right: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(-100%);
+}
+.offcanvas.offcanvas-end {
+ top: 0;
+ right: 0;
+ width: var(--bs-offcanvas-width);
+ border-left: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateX(100%);
+}
+.offcanvas.offcanvas-top {
+ top: 0;
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-bottom: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(-100%);
+}
+.offcanvas.offcanvas-bottom {
+ right: 0;
+ left: 0;
+ height: var(--bs-offcanvas-height);
+ max-height: 100%;
+ border-top: var(--bs-offcanvas-border-width) solid var(--bs-offcanvas-border-color);
+ transform: translateY(100%);
+}
+.offcanvas.showing, .offcanvas.show:not(.hiding) {
+ transform: none;
+}
+.offcanvas.showing, .offcanvas.hiding, .offcanvas.show {
+ visibility: visible;
+}
.offcanvas-backdrop {
position: fixed;
@@ -6369,72 +6861,33 @@
.offcanvas-header {
display: flex;
align-items: center;
- justify-content: space-between;
- padding: 1rem 1rem;
+ padding: var(--bs-offcanvas-padding-y) var(--bs-offcanvas-padding-x);
}
.offcanvas-header .btn-close {
- padding: 0.5rem 0.5rem;
- margin-top: -0.5rem;
- margin-right: -0.5rem;
- margin-bottom: -0.5rem;
+ padding: calc(var(--bs-offcanvas-padding-y) * 0.5) calc(var(--bs-offcanvas-padding-x) * 0.5);
+ margin-top: calc(-0.5 * var(--bs-offcanvas-padding-y));
+ margin-right: calc(-0.5 * var(--bs-offcanvas-padding-x));
+ margin-bottom: calc(-0.5 * var(--bs-offcanvas-padding-y));
+ margin-left: auto;
}
.offcanvas-title {
margin-bottom: 0;
- line-height: 1.5;
+ line-height: var(--bs-offcanvas-title-line-height);
}
.offcanvas-body {
flex-grow: 1;
- padding: 1rem 1rem;
+ padding: var(--bs-offcanvas-padding-y) var(--bs-offcanvas-padding-x);
overflow-y: auto;
}
-.offcanvas-start {
- top: 0;
- left: 0;
- width: 400px;
- border-right: 1px solid rgba(0, 0, 0, 0.1);
- transform: translateX(-100%);
-}
-
-.offcanvas-end {
- top: 0;
- right: 0;
- width: 400px;
- border-left: 1px solid rgba(0, 0, 0, 0.1);
- transform: translateX(100%);
-}
-
-.offcanvas-top {
- top: 0;
- right: 0;
- left: 0;
- height: 30vh;
- max-height: 100%;
- border-bottom: 1px solid rgba(0, 0, 0, 0.1);
- transform: translateY(-100%);
-}
-
-.offcanvas-bottom {
- right: 0;
- left: 0;
- height: 30vh;
- max-height: 100%;
- border-top: 1px solid rgba(0, 0, 0, 0.1);
- transform: translateY(100%);
-}
-
-.offcanvas.show {
- transform: none;
-}
-
.placeholder {
display: inline-block;
min-height: 1em;
vertical-align: middle;
cursor: wait;
- background-color: currentColor;
+ background-color: currentcolor;
opacity: 0.5;
}
.placeholder.btn::before {
@@ -6455,16 +6908,9 @@
}
.placeholder-glow .placeholder {
- -webkit-animation: placeholder-glow 2s ease-in-out infinite;
animation: placeholder-glow 2s ease-in-out infinite;
}
-@-webkit-keyframes placeholder-glow {
- 50% {
- opacity: 0.2;
- }
-}
-
@keyframes placeholder-glow {
50% {
opacity: 0.2;
@@ -6475,17 +6921,9 @@
mask-image: linear-gradient(130deg, #000 55%, rgba(0, 0, 0, 0.8) 75%, #000 95%);
-webkit-mask-size: 200% 100%;
mask-size: 200% 100%;
- -webkit-animation: placeholder-wave 2s linear infinite;
animation: placeholder-wave 2s linear infinite;
}
-@-webkit-keyframes placeholder-wave {
- 100% {
- -webkit-mask-position: -200% 0%;
- mask-position: -200% 0%;
- }
-}
-
@keyframes placeholder-wave {
100% {
-webkit-mask-position: -200% 0%;
@@ -6498,60 +6936,175 @@
content: "";
}
+.text-bg-primary {
+ color: #fff !important;
+ background-color: RGBA(var(--bs-primary-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
+.text-bg-secondary {
+ color: #000 !important;
+ background-color: RGBA(var(--bs-secondary-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
+.text-bg-success {
+ color: #fff !important;
+ background-color: RGBA(var(--bs-success-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
+.text-bg-info {
+ color: #fff !important;
+ background-color: RGBA(var(--bs-info-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
+.text-bg-warning {
+ color: #fff !important;
+ background-color: RGBA(var(--bs-warning-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
+.text-bg-danger {
+ color: #fff !important;
+ background-color: RGBA(var(--bs-danger-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
+.text-bg-light {
+ color: #000 !important;
+ background-color: RGBA(var(--bs-light-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
+.text-bg-dark {
+ color: #fff !important;
+ background-color: RGBA(var(--bs-dark-rgb), var(--bs-bg-opacity, 1)) !important;
+}
+
.link-primary {
- color: #158cba;
+ color: RGBA(var(--bs-primary-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-primary-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-primary-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-primary:hover, .link-primary:focus {
- color: #117095;
+ color: RGBA(17, 112, 149, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(17, 112, 149, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(17, 112, 149, var(--bs-link-underline-opacity, 1)) !important;
}
.link-secondary {
- color: #f0f0f0;
+ color: RGBA(var(--bs-secondary-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-secondary-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-secondary-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-secondary:hover, .link-secondary:focus {
- color: #f3f3f3;
+ color: RGBA(243, 243, 243, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(243, 243, 243, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(243, 243, 243, var(--bs-link-underline-opacity, 1)) !important;
}
.link-success {
- color: #28b62c;
+ color: RGBA(var(--bs-success-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-success-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-success-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-success:hover, .link-success:focus {
- color: #209223;
+ color: RGBA(32, 146, 35, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(32, 146, 35, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(32, 146, 35, var(--bs-link-underline-opacity, 1)) !important;
}
.link-info {
- color: #75caeb;
+ color: RGBA(var(--bs-info-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-info-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-info-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-info:hover, .link-info:focus {
- color: #5ea2bc;
+ color: RGBA(94, 162, 188, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(94, 162, 188, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(94, 162, 188, var(--bs-link-underline-opacity, 1)) !important;
}
.link-warning {
- color: #ff851b;
+ color: RGBA(var(--bs-warning-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-warning-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-warning-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-warning:hover, .link-warning:focus {
- color: #cc6a16;
+ color: RGBA(204, 106, 22, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(204, 106, 22, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(204, 106, 22, var(--bs-link-underline-opacity, 1)) !important;
}
.link-danger {
- color: #ff4136;
+ color: RGBA(var(--bs-danger-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-danger-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-danger-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-danger:hover, .link-danger:focus {
- color: #cc342b;
+ color: RGBA(204, 52, 43, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(204, 52, 43, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(204, 52, 43, var(--bs-link-underline-opacity, 1)) !important;
}
.link-light {
- color: #f6f6f6;
+ color: RGBA(var(--bs-light-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-light-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-light-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-light:hover, .link-light:focus {
- color: #f8f8f8;
+ color: RGBA(248, 248, 248, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(248, 248, 248, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(248, 248, 248, var(--bs-link-underline-opacity, 1)) !important;
}
.link-dark {
- color: #555;
+ color: RGBA(var(--bs-dark-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-dark-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-dark-rgb), var(--bs-link-underline-opacity, 1)) !important;
}
.link-dark:hover, .link-dark:focus {
- color: #444444;
+ color: RGBA(68, 68, 68, var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(68, 68, 68, var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(68, 68, 68, var(--bs-link-underline-opacity, 1)) !important;
+}
+
+.link-body-emphasis {
+ color: RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-opacity, 1)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 1)) !important;
+}
+.link-body-emphasis:hover, .link-body-emphasis:focus {
+ color: RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-opacity, 0.75)) !important;
+ -webkit-text-decoration-color: RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 0.75)) !important;
+ text-decoration-color: RGBA(var(--bs-emphasis-color-rgb), var(--bs-link-underline-opacity, 0.75)) !important;
+}
+
+.focus-ring:focus {
+ outline: 0;
+ box-shadow: var(--bs-focus-ring-x, 0) var(--bs-focus-ring-y, 0) var(--bs-focus-ring-blur, 0) var(--bs-focus-ring-width) var(--bs-focus-ring-color);
+}
+
+.icon-link {
+ display: inline-flex;
+ gap: 0.375rem;
+ align-items: center;
+ -webkit-text-decoration-color: rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 0.5));
+ text-decoration-color: rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 0.5));
+ text-underline-offset: 0.25em;
+ -webkit-backface-visibility: hidden;
+ backface-visibility: hidden;
+}
+.icon-link > .bi {
+ flex-shrink: 0;
+ width: 1em;
+ height: 1em;
+ fill: currentcolor;
+ transition: 0.2s ease-in-out transform;
+}
+@media (prefers-reduced-motion: reduce) {
+ .icon-link > .bi {
+ transition: none;
+ }
+}
+
+.icon-link-hover:hover > .bi, .icon-link-hover:focus-visible > .bi {
+ transform: var(--bs-icon-link-transform, translate3d(0.25em, 0, 0));
}
.ratio {
@@ -6610,6 +7163,13 @@
z-index: 1020;
}
+.sticky-bottom {
+ position: -webkit-sticky;
+ position: sticky;
+ bottom: 0;
+ z-index: 1020;
+}
+
@media (min-width: 576px) {
.sticky-sm-top {
position: -webkit-sticky;
@@ -6617,6 +7177,12 @@
top: 0;
z-index: 1020;
}
+ .sticky-sm-bottom {
+ position: -webkit-sticky;
+ position: sticky;
+ bottom: 0;
+ z-index: 1020;
+ }
}
@media (min-width: 768px) {
.sticky-md-top {
@@ -6625,6 +7191,12 @@
top: 0;
z-index: 1020;
}
+ .sticky-md-bottom {
+ position: -webkit-sticky;
+ position: sticky;
+ bottom: 0;
+ z-index: 1020;
+ }
}
@media (min-width: 992px) {
.sticky-lg-top {
@@ -6633,6 +7205,12 @@
top: 0;
z-index: 1020;
}
+ .sticky-lg-bottom {
+ position: -webkit-sticky;
+ position: sticky;
+ bottom: 0;
+ z-index: 1020;
+ }
}
@media (min-width: 1200px) {
.sticky-xl-top {
@@ -6641,6 +7219,12 @@
top: 0;
z-index: 1020;
}
+ .sticky-xl-bottom {
+ position: -webkit-sticky;
+ position: sticky;
+ bottom: 0;
+ z-index: 1020;
+ }
}
@media (min-width: 1400px) {
.sticky-xxl-top {
@@ -6649,6 +7233,12 @@
top: 0;
z-index: 1020;
}
+ .sticky-xxl-bottom {
+ position: -webkit-sticky;
+ position: sticky;
+ bottom: 0;
+ z-index: 1020;
+ }
}
.hstack {
display: flex;
@@ -6666,7 +7256,6 @@
.visually-hidden,
.visually-hidden-focusable:not(:focus):not(:focus-within) {
- position: absolute !important;
width: 1px !important;
height: 1px !important;
padding: 0 !important;
@@ -6676,6 +7265,14 @@
white-space: nowrap !important;
border: 0 !important;
}
+.visually-hidden:not(caption),
+.visually-hidden-focusable:not(:focus):not(:focus-within):not(caption) {
+ position: absolute !important;
+}
+.visually-hidden *,
+.visually-hidden-focusable:not(:focus):not(:focus-within) * {
+ overflow: hidden !important;
+}
.stretched-link::after {
position: absolute;
@@ -6696,9 +7293,9 @@
.vr {
display: inline-block;
align-self: stretch;
- width: 1px;
+ width: var(--bs-border-width);
min-height: 1em;
- background-color: currentColor;
+ background-color: currentcolor;
opacity: 0.25;
}
@@ -6738,6 +7335,31 @@
float: none !important;
}
+.object-fit-contain {
+ -o-object-fit: contain !important;
+ object-fit: contain !important;
+}
+
+.object-fit-cover {
+ -o-object-fit: cover !important;
+ object-fit: cover !important;
+}
+
+.object-fit-fill {
+ -o-object-fit: fill !important;
+ object-fit: fill !important;
+}
+
+.object-fit-scale {
+ -o-object-fit: scale-down !important;
+ object-fit: scale-down !important;
+}
+
+.object-fit-none {
+ -o-object-fit: none !important;
+ object-fit: none !important;
+}
+
.opacity-0 {
opacity: 0 !important;
}
@@ -6774,6 +7396,38 @@
overflow: scroll !important;
}
+.overflow-x-auto {
+ overflow-x: auto !important;
+}
+
+.overflow-x-hidden {
+ overflow-x: hidden !important;
+}
+
+.overflow-x-visible {
+ overflow-x: visible !important;
+}
+
+.overflow-x-scroll {
+ overflow-x: scroll !important;
+}
+
+.overflow-y-auto {
+ overflow-y: auto !important;
+}
+
+.overflow-y-hidden {
+ overflow-y: hidden !important;
+}
+
+.overflow-y-visible {
+ overflow-y: visible !important;
+}
+
+.overflow-y-scroll {
+ overflow-y: scroll !important;
+}
+
.d-inline {
display: inline !important;
}
@@ -6790,6 +7444,10 @@
display: grid !important;
}
+.d-inline-grid {
+ display: inline-grid !important;
+}
+
.d-table {
display: table !important;
}
@@ -6815,21 +7473,53 @@
}
.shadow {
- box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
+ box-shadow: var(--bs-box-shadow) !important;
}
.shadow-sm {
- box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
+ box-shadow: var(--bs-box-shadow-sm) !important;
}
.shadow-lg {
- box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175) !important;
+ box-shadow: var(--bs-box-shadow-lg) !important;
}
.shadow-none {
box-shadow: none !important;
}
+.focus-ring-primary {
+ --bs-focus-ring-color: rgba(var(--bs-primary-rgb), var(--bs-focus-ring-opacity));
+}
+
+.focus-ring-secondary {
+ --bs-focus-ring-color: rgba(var(--bs-secondary-rgb), var(--bs-focus-ring-opacity));
+}
+
+.focus-ring-success {
+ --bs-focus-ring-color: rgba(var(--bs-success-rgb), var(--bs-focus-ring-opacity));
+}
+
+.focus-ring-info {
+ --bs-focus-ring-color: rgba(var(--bs-info-rgb), var(--bs-focus-ring-opacity));
+}
+
+.focus-ring-warning {
+ --bs-focus-ring-color: rgba(var(--bs-warning-rgb), var(--bs-focus-ring-opacity));
+}
+
+.focus-ring-danger {
+ --bs-focus-ring-color: rgba(var(--bs-danger-rgb), var(--bs-focus-ring-opacity));
+}
+
+.focus-ring-light {
+ --bs-focus-ring-color: rgba(var(--bs-light-rgb), var(--bs-focus-ring-opacity));
+}
+
+.focus-ring-dark {
+ --bs-focus-ring-color: rgba(var(--bs-dark-rgb), var(--bs-focus-ring-opacity));
+}
+
.position-static {
position: static !important;
}
@@ -6912,7 +7602,7 @@
}
.border {
- border: 1px solid #dee2e6 !important;
+ border: var(--bs-border-width) var(--bs-border-style) var(--bs-border-color) !important;
}
.border-0 {
@@ -6920,7 +7610,7 @@
}
.border-top {
- border-top: 1px solid #dee2e6 !important;
+ border-top: var(--bs-border-width) var(--bs-border-style) var(--bs-border-color) !important;
}
.border-top-0 {
@@ -6928,7 +7618,7 @@
}
.border-end {
- border-right: 1px solid #dee2e6 !important;
+ border-right: var(--bs-border-width) var(--bs-border-style) var(--bs-border-color) !important;
}
.border-end-0 {
@@ -6936,7 +7626,7 @@
}
.border-bottom {
- border-bottom: 1px solid #dee2e6 !important;
+ border-bottom: var(--bs-border-width) var(--bs-border-style) var(--bs-border-color) !important;
}
.border-bottom-0 {
@@ -6944,7 +7634,7 @@
}
.border-start {
- border-left: 1px solid #dee2e6 !important;
+ border-left: var(--bs-border-width) var(--bs-border-style) var(--bs-border-color) !important;
}
.border-start-0 {
@@ -6952,39 +7642,85 @@
}
.border-primary {
- border-color: #158cba !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-primary-rgb), var(--bs-border-opacity)) !important;
}
.border-secondary {
- border-color: #f0f0f0 !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-secondary-rgb), var(--bs-border-opacity)) !important;
}
.border-success {
- border-color: #28b62c !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-success-rgb), var(--bs-border-opacity)) !important;
}
.border-info {
- border-color: #75caeb !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-info-rgb), var(--bs-border-opacity)) !important;
}
.border-warning {
- border-color: #ff851b !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-warning-rgb), var(--bs-border-opacity)) !important;
}
.border-danger {
- border-color: #ff4136 !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-danger-rgb), var(--bs-border-opacity)) !important;
}
.border-light {
- border-color: #f6f6f6 !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-light-rgb), var(--bs-border-opacity)) !important;
}
.border-dark {
- border-color: #555 !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-dark-rgb), var(--bs-border-opacity)) !important;
+}
+
+.border-black {
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-black-rgb), var(--bs-border-opacity)) !important;
}
.border-white {
- border-color: #fff !important;
+ --bs-border-opacity: 1;
+ border-color: rgba(var(--bs-white-rgb), var(--bs-border-opacity)) !important;
+}
+
+.border-primary-subtle {
+ border-color: var(--bs-primary-border-subtle) !important;
+}
+
+.border-secondary-subtle {
+ border-color: var(--bs-secondary-border-subtle) !important;
+}
+
+.border-success-subtle {
+ border-color: var(--bs-success-border-subtle) !important;
+}
+
+.border-info-subtle {
+ border-color: var(--bs-info-border-subtle) !important;
+}
+
+.border-warning-subtle {
+ border-color: var(--bs-warning-border-subtle) !important;
+}
+
+.border-danger-subtle {
+ border-color: var(--bs-danger-border-subtle) !important;
+}
+
+.border-light-subtle {
+ border-color: var(--bs-light-border-subtle) !important;
+}
+
+.border-dark-subtle {
+ border-color: var(--bs-dark-border-subtle) !important;
}
.border-1 {
@@ -7007,6 +7743,26 @@
border-width: 5px !important;
}
+.border-opacity-10 {
+ --bs-border-opacity: 0.1;
+}
+
+.border-opacity-25 {
+ --bs-border-opacity: 0.25;
+}
+
+.border-opacity-50 {
+ --bs-border-opacity: 0.5;
+}
+
+.border-opacity-75 {
+ --bs-border-opacity: 0.75;
+}
+
+.border-opacity-100 {
+ --bs-border-opacity: 1;
+}
+
.w-25 {
width: 25% !important;
}
@@ -7119,30 +7875,6 @@
flex-wrap: wrap-reverse !important;
}
-.gap-0 {
- gap: 0 !important;
-}
-
-.gap-1 {
- gap: 0.25rem !important;
-}
-
-.gap-2 {
- gap: 0.5rem !important;
-}
-
-.gap-3 {
- gap: 1rem !important;
-}
-
-.gap-4 {
- gap: 1.5rem !important;
-}
-
-.gap-5 {
- gap: 3rem !important;
-}
-
.justify-content-start {
justify-content: flex-start !important;
}
@@ -7657,6 +8389,84 @@
padding-left: 3rem !important;
}
+.gap-0 {
+ gap: 0 !important;
+}
+
+.gap-1 {
+ gap: 0.25rem !important;
+}
+
+.gap-2 {
+ gap: 0.5rem !important;
+}
+
+.gap-3 {
+ gap: 1rem !important;
+}
+
+.gap-4 {
+ gap: 1.5rem !important;
+}
+
+.gap-5 {
+ gap: 3rem !important;
+}
+
+.row-gap-0 {
+ row-gap: 0 !important;
+}
+
+.row-gap-1 {
+ row-gap: 0.25rem !important;
+}
+
+.row-gap-2 {
+ row-gap: 0.5rem !important;
+}
+
+.row-gap-3 {
+ row-gap: 1rem !important;
+}
+
+.row-gap-4 {
+ row-gap: 1.5rem !important;
+}
+
+.row-gap-5 {
+ row-gap: 3rem !important;
+}
+
+.column-gap-0 {
+ -moz-column-gap: 0 !important;
+ column-gap: 0 !important;
+}
+
+.column-gap-1 {
+ -moz-column-gap: 0.25rem !important;
+ column-gap: 0.25rem !important;
+}
+
+.column-gap-2 {
+ -moz-column-gap: 0.5rem !important;
+ column-gap: 0.5rem !important;
+}
+
+.column-gap-3 {
+ -moz-column-gap: 1rem !important;
+ column-gap: 1rem !important;
+}
+
+.column-gap-4 {
+ -moz-column-gap: 1.5rem !important;
+ column-gap: 1.5rem !important;
+}
+
+.column-gap-5 {
+ -moz-column-gap: 3rem !important;
+ column-gap: 3rem !important;
+}
+
.font-monospace {
font-family: var(--bs-font-monospace) !important;
}
@@ -7693,18 +8503,26 @@
font-style: normal !important;
}
-.fw-light {
- font-weight: 300 !important;
-}
-
.fw-lighter {
font-weight: lighter !important;
}
+.fw-light {
+ font-weight: 300 !important;
+}
+
.fw-normal {
font-weight: 400 !important;
}
+.fw-medium {
+ font-weight: 500 !important;
+}
+
+.fw-semibold {
+ font-weight: 600 !important;
+}
+
.fw-bold {
font-weight: 700 !important;
}
@@ -7837,7 +8655,7 @@
.text-muted {
--bs-text-opacity: 1;
- color: #999 !important;
+ color: var(--bs-secondary-color) !important;
}
.text-black-50 {
@@ -7850,6 +8668,21 @@
color: rgba(255, 255, 255, 0.5) !important;
}
+.text-body-secondary {
+ --bs-text-opacity: 1;
+ color: var(--bs-secondary-color) !important;
+}
+
+.text-body-tertiary {
+ --bs-text-opacity: 1;
+ color: var(--bs-tertiary-color) !important;
+}
+
+.text-body-emphasis {
+ --bs-text-opacity: 1;
+ color: var(--bs-emphasis-color) !important;
+}
+
.text-reset {
--bs-text-opacity: 1;
color: inherit !important;
@@ -7871,6 +8704,204 @@
--bs-text-opacity: 1;
}
+.text-primary-emphasis {
+ color: var(--bs-primary-text-emphasis) !important;
+}
+
+.text-secondary-emphasis {
+ color: var(--bs-secondary-text-emphasis) !important;
+}
+
+.text-success-emphasis {
+ color: var(--bs-success-text-emphasis) !important;
+}
+
+.text-info-emphasis {
+ color: var(--bs-info-text-emphasis) !important;
+}
+
+.text-warning-emphasis {
+ color: var(--bs-warning-text-emphasis) !important;
+}
+
+.text-danger-emphasis {
+ color: var(--bs-danger-text-emphasis) !important;
+}
+
+.text-light-emphasis {
+ color: var(--bs-light-text-emphasis) !important;
+}
+
+.text-dark-emphasis {
+ color: var(--bs-dark-text-emphasis) !important;
+}
+
+.link-opacity-10 {
+ --bs-link-opacity: 0.1;
+}
+
+.link-opacity-10-hover:hover {
+ --bs-link-opacity: 0.1;
+}
+
+.link-opacity-25 {
+ --bs-link-opacity: 0.25;
+}
+
+.link-opacity-25-hover:hover {
+ --bs-link-opacity: 0.25;
+}
+
+.link-opacity-50 {
+ --bs-link-opacity: 0.5;
+}
+
+.link-opacity-50-hover:hover {
+ --bs-link-opacity: 0.5;
+}
+
+.link-opacity-75 {
+ --bs-link-opacity: 0.75;
+}
+
+.link-opacity-75-hover:hover {
+ --bs-link-opacity: 0.75;
+}
+
+.link-opacity-100 {
+ --bs-link-opacity: 1;
+}
+
+.link-opacity-100-hover:hover {
+ --bs-link-opacity: 1;
+}
+
+.link-offset-1 {
+ text-underline-offset: 0.125em !important;
+}
+
+.link-offset-1-hover:hover {
+ text-underline-offset: 0.125em !important;
+}
+
+.link-offset-2 {
+ text-underline-offset: 0.25em !important;
+}
+
+.link-offset-2-hover:hover {
+ text-underline-offset: 0.25em !important;
+}
+
+.link-offset-3 {
+ text-underline-offset: 0.375em !important;
+}
+
+.link-offset-3-hover:hover {
+ text-underline-offset: 0.375em !important;
+}
+
+.link-underline-primary {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-primary-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-primary-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline-secondary {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-secondary-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-secondary-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline-success {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-success-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-success-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline-info {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-info-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-info-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline-warning {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-warning-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-warning-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline-danger {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-danger-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-danger-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline-light {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-light-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-light-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline-dark {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-dark-rgb), var(--bs-link-underline-opacity)) !important;
+ text-decoration-color: rgba(var(--bs-dark-rgb), var(--bs-link-underline-opacity)) !important;
+}
+
+.link-underline {
+ --bs-link-underline-opacity: 1;
+ -webkit-text-decoration-color: rgba(var(--bs-link-color-rgb), var(--bs-link-underline-opacity, 1)) !important;
+ text-decoration-color: rgba(var(--bs-link-color-rgb), var(--bs-link-underline-opacity, 1)) !important;
+}
+
+.link-underline-opacity-0 {
+ --bs-link-underline-opacity: 0;
+}
+
+.link-underline-opacity-0-hover:hover {
+ --bs-link-underline-opacity: 0;
+}
+
+.link-underline-opacity-10 {
+ --bs-link-underline-opacity: 0.1;
+}
+
+.link-underline-opacity-10-hover:hover {
+ --bs-link-underline-opacity: 0.1;
+}
+
+.link-underline-opacity-25 {
+ --bs-link-underline-opacity: 0.25;
+}
+
+.link-underline-opacity-25-hover:hover {
+ --bs-link-underline-opacity: 0.25;
+}
+
+.link-underline-opacity-50 {
+ --bs-link-underline-opacity: 0.5;
+}
+
+.link-underline-opacity-50-hover:hover {
+ --bs-link-underline-opacity: 0.5;
+}
+
+.link-underline-opacity-75 {
+ --bs-link-underline-opacity: 0.75;
+}
+
+.link-underline-opacity-75-hover:hover {
+ --bs-link-underline-opacity: 0.75;
+}
+
+.link-underline-opacity-100 {
+ --bs-link-underline-opacity: 1;
+}
+
+.link-underline-opacity-100-hover:hover {
+ --bs-link-underline-opacity: 1;
+}
+
.bg-primary {
--bs-bg-opacity: 1;
background-color: rgba(var(--bs-primary-rgb), var(--bs-bg-opacity)) !important;
@@ -7931,6 +8962,16 @@
background-color: transparent !important;
}
+.bg-body-secondary {
+ --bs-bg-opacity: 1;
+ background-color: rgba(var(--bs-secondary-bg-rgb), var(--bs-bg-opacity)) !important;
+}
+
+.bg-body-tertiary {
+ --bs-bg-opacity: 1;
+ background-color: rgba(var(--bs-tertiary-bg-rgb), var(--bs-bg-opacity)) !important;
+}
+
.bg-opacity-10 {
--bs-bg-opacity: 0.1;
}
@@ -7951,6 +8992,38 @@
--bs-bg-opacity: 1;
}
+.bg-primary-subtle {
+ background-color: var(--bs-primary-bg-subtle) !important;
+}
+
+.bg-secondary-subtle {
+ background-color: var(--bs-secondary-bg-subtle) !important;
+}
+
+.bg-success-subtle {
+ background-color: var(--bs-success-bg-subtle) !important;
+}
+
+.bg-info-subtle {
+ background-color: var(--bs-info-bg-subtle) !important;
+}
+
+.bg-warning-subtle {
+ background-color: var(--bs-warning-bg-subtle) !important;
+}
+
+.bg-danger-subtle {
+ background-color: var(--bs-danger-bg-subtle) !important;
+}
+
+.bg-light-subtle {
+ background-color: var(--bs-light-bg-subtle) !important;
+}
+
+.bg-dark-subtle {
+ background-color: var(--bs-dark-bg-subtle) !important;
+}
+
.bg-gradient {
background-image: var(--bs-gradient) !important;
}
@@ -7982,7 +9055,7 @@
}
.rounded {
- border-radius: 0.25rem !important;
+ border-radius: var(--bs-border-radius) !important;
}
.rounded-0 {
@@ -7990,15 +9063,23 @@
}
.rounded-1 {
- border-radius: 0.2rem !important;
+ border-radius: var(--bs-border-radius-sm) !important;
}
.rounded-2 {
- border-radius: 0.25rem !important;
+ border-radius: var(--bs-border-radius) !important;
}
.rounded-3 {
- border-radius: 0.3rem !important;
+ border-radius: var(--bs-border-radius-lg) !important;
+}
+
+.rounded-4 {
+ border-radius: var(--bs-border-radius-xl) !important;
+}
+
+.rounded-5 {
+ border-radius: var(--bs-border-radius-xxl) !important;
}
.rounded-circle {
@@ -8006,27 +9087,187 @@
}
.rounded-pill {
- border-radius: 50rem !important;
+ border-radius: var(--bs-border-radius-pill) !important;
}
.rounded-top {
- border-top-left-radius: 0.25rem !important;
- border-top-right-radius: 0.25rem !important;
+ border-top-left-radius: var(--bs-border-radius) !important;
+ border-top-right-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-top-0 {
+ border-top-left-radius: 0 !important;
+ border-top-right-radius: 0 !important;
+}
+
+.rounded-top-1 {
+ border-top-left-radius: var(--bs-border-radius-sm) !important;
+ border-top-right-radius: var(--bs-border-radius-sm) !important;
+}
+
+.rounded-top-2 {
+ border-top-left-radius: var(--bs-border-radius) !important;
+ border-top-right-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-top-3 {
+ border-top-left-radius: var(--bs-border-radius-lg) !important;
+ border-top-right-radius: var(--bs-border-radius-lg) !important;
+}
+
+.rounded-top-4 {
+ border-top-left-radius: var(--bs-border-radius-xl) !important;
+ border-top-right-radius: var(--bs-border-radius-xl) !important;
+}
+
+.rounded-top-5 {
+ border-top-left-radius: var(--bs-border-radius-xxl) !important;
+ border-top-right-radius: var(--bs-border-radius-xxl) !important;
+}
+
+.rounded-top-circle {
+ border-top-left-radius: 50% !important;
+ border-top-right-radius: 50% !important;
+}
+
+.rounded-top-pill {
+ border-top-left-radius: var(--bs-border-radius-pill) !important;
+ border-top-right-radius: var(--bs-border-radius-pill) !important;
}
.rounded-end {
- border-top-right-radius: 0.25rem !important;
- border-bottom-right-radius: 0.25rem !important;
+ border-top-right-radius: var(--bs-border-radius) !important;
+ border-bottom-right-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-end-0 {
+ border-top-right-radius: 0 !important;
+ border-bottom-right-radius: 0 !important;
+}
+
+.rounded-end-1 {
+ border-top-right-radius: var(--bs-border-radius-sm) !important;
+ border-bottom-right-radius: var(--bs-border-radius-sm) !important;
+}
+
+.rounded-end-2 {
+ border-top-right-radius: var(--bs-border-radius) !important;
+ border-bottom-right-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-end-3 {
+ border-top-right-radius: var(--bs-border-radius-lg) !important;
+ border-bottom-right-radius: var(--bs-border-radius-lg) !important;
+}
+
+.rounded-end-4 {
+ border-top-right-radius: var(--bs-border-radius-xl) !important;
+ border-bottom-right-radius: var(--bs-border-radius-xl) !important;
+}
+
+.rounded-end-5 {
+ border-top-right-radius: var(--bs-border-radius-xxl) !important;
+ border-bottom-right-radius: var(--bs-border-radius-xxl) !important;
+}
+
+.rounded-end-circle {
+ border-top-right-radius: 50% !important;
+ border-bottom-right-radius: 50% !important;
+}
+
+.rounded-end-pill {
+ border-top-right-radius: var(--bs-border-radius-pill) !important;
+ border-bottom-right-radius: var(--bs-border-radius-pill) !important;
}
.rounded-bottom {
- border-bottom-right-radius: 0.25rem !important;
- border-bottom-left-radius: 0.25rem !important;
+ border-bottom-right-radius: var(--bs-border-radius) !important;
+ border-bottom-left-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-bottom-0 {
+ border-bottom-right-radius: 0 !important;
+ border-bottom-left-radius: 0 !important;
+}
+
+.rounded-bottom-1 {
+ border-bottom-right-radius: var(--bs-border-radius-sm) !important;
+ border-bottom-left-radius: var(--bs-border-radius-sm) !important;
+}
+
+.rounded-bottom-2 {
+ border-bottom-right-radius: var(--bs-border-radius) !important;
+ border-bottom-left-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-bottom-3 {
+ border-bottom-right-radius: var(--bs-border-radius-lg) !important;
+ border-bottom-left-radius: var(--bs-border-radius-lg) !important;
+}
+
+.rounded-bottom-4 {
+ border-bottom-right-radius: var(--bs-border-radius-xl) !important;
+ border-bottom-left-radius: var(--bs-border-radius-xl) !important;
+}
+
+.rounded-bottom-5 {
+ border-bottom-right-radius: var(--bs-border-radius-xxl) !important;
+ border-bottom-left-radius: var(--bs-border-radius-xxl) !important;
+}
+
+.rounded-bottom-circle {
+ border-bottom-right-radius: 50% !important;
+ border-bottom-left-radius: 50% !important;
+}
+
+.rounded-bottom-pill {
+ border-bottom-right-radius: var(--bs-border-radius-pill) !important;
+ border-bottom-left-radius: var(--bs-border-radius-pill) !important;
}
.rounded-start {
- border-bottom-left-radius: 0.25rem !important;
- border-top-left-radius: 0.25rem !important;
+ border-bottom-left-radius: var(--bs-border-radius) !important;
+ border-top-left-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-start-0 {
+ border-bottom-left-radius: 0 !important;
+ border-top-left-radius: 0 !important;
+}
+
+.rounded-start-1 {
+ border-bottom-left-radius: var(--bs-border-radius-sm) !important;
+ border-top-left-radius: var(--bs-border-radius-sm) !important;
+}
+
+.rounded-start-2 {
+ border-bottom-left-radius: var(--bs-border-radius) !important;
+ border-top-left-radius: var(--bs-border-radius) !important;
+}
+
+.rounded-start-3 {
+ border-bottom-left-radius: var(--bs-border-radius-lg) !important;
+ border-top-left-radius: var(--bs-border-radius-lg) !important;
+}
+
+.rounded-start-4 {
+ border-bottom-left-radius: var(--bs-border-radius-xl) !important;
+ border-top-left-radius: var(--bs-border-radius-xl) !important;
+}
+
+.rounded-start-5 {
+ border-bottom-left-radius: var(--bs-border-radius-xxl) !important;
+ border-top-left-radius: var(--bs-border-radius-xxl) !important;
+}
+
+.rounded-start-circle {
+ border-bottom-left-radius: 50% !important;
+ border-top-left-radius: 50% !important;
+}
+
+.rounded-start-pill {
+ border-bottom-left-radius: var(--bs-border-radius-pill) !important;
+ border-top-left-radius: var(--bs-border-radius-pill) !important;
}
.visible {
@@ -8037,653 +9278,583 @@
visibility: hidden !important;
}
+.z-n1 {
+ z-index: -1 !important;
+}
+
+.z-0 {
+ z-index: 0 !important;
+}
+
+.z-1 {
+ z-index: 1 !important;
+}
+
+.z-2 {
+ z-index: 2 !important;
+}
+
+.z-3 {
+ z-index: 3 !important;
+}
+
@media (min-width: 576px) {
.float-sm-start {
float: left !important;
}
-
.float-sm-end {
float: right !important;
}
-
.float-sm-none {
float: none !important;
}
-
+ .object-fit-sm-contain {
+ -o-object-fit: contain !important;
+ object-fit: contain !important;
+ }
+ .object-fit-sm-cover {
+ -o-object-fit: cover !important;
+ object-fit: cover !important;
+ }
+ .object-fit-sm-fill {
+ -o-object-fit: fill !important;
+ object-fit: fill !important;
+ }
+ .object-fit-sm-scale {
+ -o-object-fit: scale-down !important;
+ object-fit: scale-down !important;
+ }
+ .object-fit-sm-none {
+ -o-object-fit: none !important;
+ object-fit: none !important;
+ }
.d-sm-inline {
display: inline !important;
}
-
.d-sm-inline-block {
display: inline-block !important;
}
-
.d-sm-block {
display: block !important;
}
-
.d-sm-grid {
display: grid !important;
}
-
+ .d-sm-inline-grid {
+ display: inline-grid !important;
+ }
.d-sm-table {
display: table !important;
}
-
.d-sm-table-row {
display: table-row !important;
}
-
.d-sm-table-cell {
display: table-cell !important;
}
-
.d-sm-flex {
display: flex !important;
}
-
.d-sm-inline-flex {
display: inline-flex !important;
}
-
.d-sm-none {
display: none !important;
}
-
.flex-sm-fill {
flex: 1 1 auto !important;
}
-
.flex-sm-row {
flex-direction: row !important;
}
-
.flex-sm-column {
flex-direction: column !important;
}
-
.flex-sm-row-reverse {
flex-direction: row-reverse !important;
}
-
.flex-sm-column-reverse {
flex-direction: column-reverse !important;
}
-
.flex-sm-grow-0 {
flex-grow: 0 !important;
}
-
.flex-sm-grow-1 {
flex-grow: 1 !important;
}
-
.flex-sm-shrink-0 {
flex-shrink: 0 !important;
}
-
.flex-sm-shrink-1 {
flex-shrink: 1 !important;
}
-
.flex-sm-wrap {
flex-wrap: wrap !important;
}
-
.flex-sm-nowrap {
flex-wrap: nowrap !important;
}
-
.flex-sm-wrap-reverse {
flex-wrap: wrap-reverse !important;
}
-
- .gap-sm-0 {
- gap: 0 !important;
- }
-
- .gap-sm-1 {
- gap: 0.25rem !important;
- }
-
- .gap-sm-2 {
- gap: 0.5rem !important;
- }
-
- .gap-sm-3 {
- gap: 1rem !important;
- }
-
- .gap-sm-4 {
- gap: 1.5rem !important;
- }
-
- .gap-sm-5 {
- gap: 3rem !important;
- }
-
.justify-content-sm-start {
justify-content: flex-start !important;
}
-
.justify-content-sm-end {
justify-content: flex-end !important;
}
-
.justify-content-sm-center {
justify-content: center !important;
}
-
.justify-content-sm-between {
justify-content: space-between !important;
}
-
.justify-content-sm-around {
justify-content: space-around !important;
}
-
.justify-content-sm-evenly {
justify-content: space-evenly !important;
}
-
.align-items-sm-start {
align-items: flex-start !important;
}
-
.align-items-sm-end {
align-items: flex-end !important;
}
-
.align-items-sm-center {
align-items: center !important;
}
-
.align-items-sm-baseline {
align-items: baseline !important;
}
-
.align-items-sm-stretch {
align-items: stretch !important;
}
-
.align-content-sm-start {
align-content: flex-start !important;
}
-
.align-content-sm-end {
align-content: flex-end !important;
}
-
.align-content-sm-center {
align-content: center !important;
}
-
.align-content-sm-between {
align-content: space-between !important;
}
-
.align-content-sm-around {
align-content: space-around !important;
}
-
.align-content-sm-stretch {
align-content: stretch !important;
}
-
.align-self-sm-auto {
align-self: auto !important;
}
-
.align-self-sm-start {
align-self: flex-start !important;
}
-
.align-self-sm-end {
align-self: flex-end !important;
}
-
.align-self-sm-center {
align-self: center !important;
}
-
.align-self-sm-baseline {
align-self: baseline !important;
}
-
.align-self-sm-stretch {
align-self: stretch !important;
}
-
.order-sm-first {
order: -1 !important;
}
-
.order-sm-0 {
order: 0 !important;
}
-
.order-sm-1 {
order: 1 !important;
}
-
.order-sm-2 {
order: 2 !important;
}
-
.order-sm-3 {
order: 3 !important;
}
-
.order-sm-4 {
order: 4 !important;
}
-
.order-sm-5 {
order: 5 !important;
}
-
.order-sm-last {
order: 6 !important;
}
-
.m-sm-0 {
margin: 0 !important;
}
-
.m-sm-1 {
margin: 0.25rem !important;
}
-
.m-sm-2 {
margin: 0.5rem !important;
}
-
.m-sm-3 {
margin: 1rem !important;
}
-
.m-sm-4 {
margin: 1.5rem !important;
}
-
.m-sm-5 {
margin: 3rem !important;
}
-
.m-sm-auto {
margin: auto !important;
}
-
.mx-sm-0 {
margin-right: 0 !important;
margin-left: 0 !important;
}
-
.mx-sm-1 {
margin-right: 0.25rem !important;
margin-left: 0.25rem !important;
}
-
.mx-sm-2 {
margin-right: 0.5rem !important;
margin-left: 0.5rem !important;
}
-
.mx-sm-3 {
margin-right: 1rem !important;
margin-left: 1rem !important;
}
-
.mx-sm-4 {
margin-right: 1.5rem !important;
margin-left: 1.5rem !important;
}
-
.mx-sm-5 {
margin-right: 3rem !important;
margin-left: 3rem !important;
}
-
.mx-sm-auto {
margin-right: auto !important;
margin-left: auto !important;
}
-
.my-sm-0 {
margin-top: 0 !important;
margin-bottom: 0 !important;
}
-
.my-sm-1 {
margin-top: 0.25rem !important;
margin-bottom: 0.25rem !important;
}
-
.my-sm-2 {
margin-top: 0.5rem !important;
margin-bottom: 0.5rem !important;
}
-
.my-sm-3 {
margin-top: 1rem !important;
margin-bottom: 1rem !important;
}
-
.my-sm-4 {
margin-top: 1.5rem !important;
margin-bottom: 1.5rem !important;
}
-
.my-sm-5 {
margin-top: 3rem !important;
margin-bottom: 3rem !important;
}
-
.my-sm-auto {
margin-top: auto !important;
margin-bottom: auto !important;
}
-
.mt-sm-0 {
margin-top: 0 !important;
}
-
.mt-sm-1 {
margin-top: 0.25rem !important;
}
-
.mt-sm-2 {
margin-top: 0.5rem !important;
}
-
.mt-sm-3 {
margin-top: 1rem !important;
}
-
.mt-sm-4 {
margin-top: 1.5rem !important;
}
-
.mt-sm-5 {
margin-top: 3rem !important;
}
-
.mt-sm-auto {
margin-top: auto !important;
}
-
.me-sm-0 {
margin-right: 0 !important;
}
-
.me-sm-1 {
margin-right: 0.25rem !important;
}
-
.me-sm-2 {
margin-right: 0.5rem !important;
}
-
.me-sm-3 {
margin-right: 1rem !important;
}
-
.me-sm-4 {
margin-right: 1.5rem !important;
}
-
.me-sm-5 {
margin-right: 3rem !important;
}
-
.me-sm-auto {
margin-right: auto !important;
}
-
.mb-sm-0 {
margin-bottom: 0 !important;
}
-
.mb-sm-1 {
margin-bottom: 0.25rem !important;
}
-
.mb-sm-2 {
margin-bottom: 0.5rem !important;
}
-
.mb-sm-3 {
margin-bottom: 1rem !important;
}
-
.mb-sm-4 {
margin-bottom: 1.5rem !important;
}
-
.mb-sm-5 {
margin-bottom: 3rem !important;
}
-
.mb-sm-auto {
margin-bottom: auto !important;
}
-
.ms-sm-0 {
margin-left: 0 !important;
}
-
.ms-sm-1 {
margin-left: 0.25rem !important;
}
-
.ms-sm-2 {
margin-left: 0.5rem !important;
}
-
.ms-sm-3 {
margin-left: 1rem !important;
}
-
.ms-sm-4 {
margin-left: 1.5rem !important;
}
-
.ms-sm-5 {
margin-left: 3rem !important;
}
-
.ms-sm-auto {
margin-left: auto !important;
}
-
.p-sm-0 {
padding: 0 !important;
}
-
.p-sm-1 {
padding: 0.25rem !important;
}
-
.p-sm-2 {
padding: 0.5rem !important;
}
-
.p-sm-3 {
padding: 1rem !important;
}
-
.p-sm-4 {
padding: 1.5rem !important;
}
-
.p-sm-5 {
padding: 3rem !important;
}
-
.px-sm-0 {
padding-right: 0 !important;
padding-left: 0 !important;
}
-
.px-sm-1 {
padding-right: 0.25rem !important;
padding-left: 0.25rem !important;
}
-
.px-sm-2 {
padding-right: 0.5rem !important;
padding-left: 0.5rem !important;
}
-
.px-sm-3 {
padding-right: 1rem !important;
padding-left: 1rem !important;
}
-
.px-sm-4 {
padding-right: 1.5rem !important;
padding-left: 1.5rem !important;
}
-
.px-sm-5 {
padding-right: 3rem !important;
padding-left: 3rem !important;
}
-
.py-sm-0 {
padding-top: 0 !important;
padding-bottom: 0 !important;
}
-
.py-sm-1 {
padding-top: 0.25rem !important;
padding-bottom: 0.25rem !important;
}
-
.py-sm-2 {
padding-top: 0.5rem !important;
padding-bottom: 0.5rem !important;
}
-
.py-sm-3 {
padding-top: 1rem !important;
padding-bottom: 1rem !important;
}
-
.py-sm-4 {
padding-top: 1.5rem !important;
padding-bottom: 1.5rem !important;
}
-
.py-sm-5 {
padding-top: 3rem !important;
padding-bottom: 3rem !important;
}
-
.pt-sm-0 {
padding-top: 0 !important;
}
-
.pt-sm-1 {
padding-top: 0.25rem !important;
}
-
.pt-sm-2 {
padding-top: 0.5rem !important;
}
-
.pt-sm-3 {
padding-top: 1rem !important;
}
-
.pt-sm-4 {
padding-top: 1.5rem !important;
}
-
.pt-sm-5 {
padding-top: 3rem !important;
}
-
.pe-sm-0 {
padding-right: 0 !important;
}
-
.pe-sm-1 {
padding-right: 0.25rem !important;
}
-
.pe-sm-2 {
padding-right: 0.5rem !important;
}
-
.pe-sm-3 {
padding-right: 1rem !important;
}
-
.pe-sm-4 {
padding-right: 1.5rem !important;
}
-
.pe-sm-5 {
padding-right: 3rem !important;
}
-
.pb-sm-0 {
padding-bottom: 0 !important;
}
-
.pb-sm-1 {
padding-bottom: 0.25rem !important;
}
-
.pb-sm-2 {
padding-bottom: 0.5rem !important;
}
-
.pb-sm-3 {
padding-bottom: 1rem !important;
}
-
.pb-sm-4 {
padding-bottom: 1.5rem !important;
}
-
.pb-sm-5 {
padding-bottom: 3rem !important;
}
-
.ps-sm-0 {
padding-left: 0 !important;
}
-
.ps-sm-1 {
padding-left: 0.25rem !important;
}
-
.ps-sm-2 {
padding-left: 0.5rem !important;
}
-
.ps-sm-3 {
padding-left: 1rem !important;
}
-
.ps-sm-4 {
padding-left: 1.5rem !important;
}
-
.ps-sm-5 {
padding-left: 3rem !important;
}
-
+ .gap-sm-0 {
+ gap: 0 !important;
+ }
+ .gap-sm-1 {
+ gap: 0.25rem !important;
+ }
+ .gap-sm-2 {
+ gap: 0.5rem !important;
+ }
+ .gap-sm-3 {
+ gap: 1rem !important;
+ }
+ .gap-sm-4 {
+ gap: 1.5rem !important;
+ }
+ .gap-sm-5 {
+ gap: 3rem !important;
+ }
+ .row-gap-sm-0 {
+ row-gap: 0 !important;
+ }
+ .row-gap-sm-1 {
+ row-gap: 0.25rem !important;
+ }
+ .row-gap-sm-2 {
+ row-gap: 0.5rem !important;
+ }
+ .row-gap-sm-3 {
+ row-gap: 1rem !important;
+ }
+ .row-gap-sm-4 {
+ row-gap: 1.5rem !important;
+ }
+ .row-gap-sm-5 {
+ row-gap: 3rem !important;
+ }
+ .column-gap-sm-0 {
+ -moz-column-gap: 0 !important;
+ column-gap: 0 !important;
+ }
+ .column-gap-sm-1 {
+ -moz-column-gap: 0.25rem !important;
+ column-gap: 0.25rem !important;
+ }
+ .column-gap-sm-2 {
+ -moz-column-gap: 0.5rem !important;
+ column-gap: 0.5rem !important;
+ }
+ .column-gap-sm-3 {
+ -moz-column-gap: 1rem !important;
+ column-gap: 1rem !important;
+ }
+ .column-gap-sm-4 {
+ -moz-column-gap: 1.5rem !important;
+ column-gap: 1.5rem !important;
+ }
+ .column-gap-sm-5 {
+ -moz-column-gap: 3rem !important;
+ column-gap: 3rem !important;
+ }
.text-sm-start {
text-align: left !important;
}
-
.text-sm-end {
text-align: right !important;
}
-
.text-sm-center {
text-align: center !important;
}
@@ -8692,649 +9863,559 @@
.float-md-start {
float: left !important;
}
-
.float-md-end {
float: right !important;
}
-
.float-md-none {
float: none !important;
}
-
+ .object-fit-md-contain {
+ -o-object-fit: contain !important;
+ object-fit: contain !important;
+ }
+ .object-fit-md-cover {
+ -o-object-fit: cover !important;
+ object-fit: cover !important;
+ }
+ .object-fit-md-fill {
+ -o-object-fit: fill !important;
+ object-fit: fill !important;
+ }
+ .object-fit-md-scale {
+ -o-object-fit: scale-down !important;
+ object-fit: scale-down !important;
+ }
+ .object-fit-md-none {
+ -o-object-fit: none !important;
+ object-fit: none !important;
+ }
.d-md-inline {
display: inline !important;
}
-
.d-md-inline-block {
display: inline-block !important;
}
-
.d-md-block {
display: block !important;
}
-
.d-md-grid {
display: grid !important;
}
-
+ .d-md-inline-grid {
+ display: inline-grid !important;
+ }
.d-md-table {
display: table !important;
}
-
.d-md-table-row {
display: table-row !important;
}
-
.d-md-table-cell {
display: table-cell !important;
}
-
.d-md-flex {
display: flex !important;
}
-
.d-md-inline-flex {
display: inline-flex !important;
}
-
.d-md-none {
display: none !important;
}
-
.flex-md-fill {
flex: 1 1 auto !important;
}
-
.flex-md-row {
flex-direction: row !important;
}
-
.flex-md-column {
flex-direction: column !important;
}
-
.flex-md-row-reverse {
flex-direction: row-reverse !important;
}
-
.flex-md-column-reverse {
flex-direction: column-reverse !important;
}
-
.flex-md-grow-0 {
flex-grow: 0 !important;
}
-
.flex-md-grow-1 {
flex-grow: 1 !important;
}
-
.flex-md-shrink-0 {
flex-shrink: 0 !important;
}
-
.flex-md-shrink-1 {
flex-shrink: 1 !important;
}
-
.flex-md-wrap {
flex-wrap: wrap !important;
}
-
.flex-md-nowrap {
flex-wrap: nowrap !important;
}
-
.flex-md-wrap-reverse {
flex-wrap: wrap-reverse !important;
}
-
- .gap-md-0 {
- gap: 0 !important;
- }
-
- .gap-md-1 {
- gap: 0.25rem !important;
- }
-
- .gap-md-2 {
- gap: 0.5rem !important;
- }
-
- .gap-md-3 {
- gap: 1rem !important;
- }
-
- .gap-md-4 {
- gap: 1.5rem !important;
- }
-
- .gap-md-5 {
- gap: 3rem !important;
- }
-
.justify-content-md-start {
justify-content: flex-start !important;
}
-
.justify-content-md-end {
justify-content: flex-end !important;
}
-
.justify-content-md-center {
justify-content: center !important;
}
-
.justify-content-md-between {
justify-content: space-between !important;
}
-
.justify-content-md-around {
justify-content: space-around !important;
}
-
.justify-content-md-evenly {
justify-content: space-evenly !important;
}
-
.align-items-md-start {
align-items: flex-start !important;
}
-
.align-items-md-end {
align-items: flex-end !important;
}
-
.align-items-md-center {
align-items: center !important;
}
-
.align-items-md-baseline {
align-items: baseline !important;
}
-
.align-items-md-stretch {
align-items: stretch !important;
}
-
.align-content-md-start {
align-content: flex-start !important;
}
-
.align-content-md-end {
align-content: flex-end !important;
}
-
.align-content-md-center {
align-content: center !important;
}
-
.align-content-md-between {
align-content: space-between !important;
}
-
.align-content-md-around {
align-content: space-around !important;
}
-
.align-content-md-stretch {
align-content: stretch !important;
}
-
.align-self-md-auto {
align-self: auto !important;
}
-
.align-self-md-start {
align-self: flex-start !important;
}
-
.align-self-md-end {
align-self: flex-end !important;
}
-
.align-self-md-center {
align-self: center !important;
}
-
.align-self-md-baseline {
align-self: baseline !important;
}
-
.align-self-md-stretch {
align-self: stretch !important;
}
-
.order-md-first {
order: -1 !important;
}
-
.order-md-0 {
order: 0 !important;
}
-
.order-md-1 {
order: 1 !important;
}
-
.order-md-2 {
order: 2 !important;
}
-
.order-md-3 {
order: 3 !important;
}
-
.order-md-4 {
order: 4 !important;
}
-
.order-md-5 {
order: 5 !important;
}
-
.order-md-last {
order: 6 !important;
}
-
.m-md-0 {
margin: 0 !important;
}
-
.m-md-1 {
margin: 0.25rem !important;
}
-
.m-md-2 {
margin: 0.5rem !important;
}
-
.m-md-3 {
margin: 1rem !important;
}
-
.m-md-4 {
margin: 1.5rem !important;
}
-
.m-md-5 {
margin: 3rem !important;
}
-
.m-md-auto {
margin: auto !important;
}
-
.mx-md-0 {
margin-right: 0 !important;
margin-left: 0 !important;
}
-
.mx-md-1 {
margin-right: 0.25rem !important;
margin-left: 0.25rem !important;
}
-
.mx-md-2 {
margin-right: 0.5rem !important;
margin-left: 0.5rem !important;
}
-
.mx-md-3 {
margin-right: 1rem !important;
margin-left: 1rem !important;
}
-
.mx-md-4 {
margin-right: 1.5rem !important;
margin-left: 1.5rem !important;
}
-
.mx-md-5 {
margin-right: 3rem !important;
margin-left: 3rem !important;
}
-
.mx-md-auto {
margin-right: auto !important;
margin-left: auto !important;
}
-
.my-md-0 {
margin-top: 0 !important;
margin-bottom: 0 !important;
}
-
.my-md-1 {
margin-top: 0.25rem !important;
margin-bottom: 0.25rem !important;
}
-
.my-md-2 {
margin-top: 0.5rem !important;
margin-bottom: 0.5rem !important;
}
-
.my-md-3 {
margin-top: 1rem !important;
margin-bottom: 1rem !important;
}
-
.my-md-4 {
margin-top: 1.5rem !important;
margin-bottom: 1.5rem !important;
}
-
.my-md-5 {
margin-top: 3rem !important;
margin-bottom: 3rem !important;
}
-
.my-md-auto {
margin-top: auto !important;
margin-bottom: auto !important;
}
-
.mt-md-0 {
margin-top: 0 !important;
}
-
.mt-md-1 {
margin-top: 0.25rem !important;
}
-
.mt-md-2 {
margin-top: 0.5rem !important;
}
-
.mt-md-3 {
margin-top: 1rem !important;
}
-
.mt-md-4 {
margin-top: 1.5rem !important;
}
-
.mt-md-5 {
margin-top: 3rem !important;
}
-
.mt-md-auto {
margin-top: auto !important;
}
-
.me-md-0 {
margin-right: 0 !important;
}
-
.me-md-1 {
margin-right: 0.25rem !important;
}
-
.me-md-2 {
margin-right: 0.5rem !important;
}
-
.me-md-3 {
margin-right: 1rem !important;
}
-
.me-md-4 {
margin-right: 1.5rem !important;
}
-
.me-md-5 {
margin-right: 3rem !important;
}
-
.me-md-auto {
margin-right: auto !important;
}
-
.mb-md-0 {
margin-bottom: 0 !important;
}
-
.mb-md-1 {
margin-bottom: 0.25rem !important;
}
-
.mb-md-2 {
margin-bottom: 0.5rem !important;
}
-
.mb-md-3 {
margin-bottom: 1rem !important;
}
-
.mb-md-4 {
margin-bottom: 1.5rem !important;
}
-
.mb-md-5 {
margin-bottom: 3rem !important;
}
-
.mb-md-auto {
margin-bottom: auto !important;
}
-
.ms-md-0 {
margin-left: 0 !important;
}
-
.ms-md-1 {
margin-left: 0.25rem !important;
}
-
.ms-md-2 {
margin-left: 0.5rem !important;
}
-
.ms-md-3 {
margin-left: 1rem !important;
}
-
.ms-md-4 {
margin-left: 1.5rem !important;
}
-
.ms-md-5 {
margin-left: 3rem !important;
}
-
.ms-md-auto {
margin-left: auto !important;
}
-
.p-md-0 {
padding: 0 !important;
}
-
.p-md-1 {
padding: 0.25rem !important;
}
-
.p-md-2 {
padding: 0.5rem !important;
}
-
.p-md-3 {
padding: 1rem !important;
}
-
.p-md-4 {
padding: 1.5rem !important;
}
-
.p-md-5 {
padding: 3rem !important;
}
-
.px-md-0 {
padding-right: 0 !important;
padding-left: 0 !important;
}
-
.px-md-1 {
padding-right: 0.25rem !important;
padding-left: 0.25rem !important;
}
-
.px-md-2 {
padding-right: 0.5rem !important;
padding-left: 0.5rem !important;
}
-
.px-md-3 {
padding-right: 1rem !important;
padding-left: 1rem !important;
}
-
.px-md-4 {
padding-right: 1.5rem !important;
padding-left: 1.5rem !important;
}
-
.px-md-5 {
padding-right: 3rem !important;
padding-left: 3rem !important;
}
-
.py-md-0 {
padding-top: 0 !important;
padding-bottom: 0 !important;
}
-
.py-md-1 {
padding-top: 0.25rem !important;
padding-bottom: 0.25rem !important;
}
-
.py-md-2 {
padding-top: 0.5rem !important;
padding-bottom: 0.5rem !important;
}
-
.py-md-3 {
padding-top: 1rem !important;
padding-bottom: 1rem !important;
}
-
.py-md-4 {
padding-top: 1.5rem !important;
padding-bottom: 1.5rem !important;
}
-
.py-md-5 {
padding-top: 3rem !important;
padding-bottom: 3rem !important;
}
-
.pt-md-0 {
padding-top: 0 !important;
}
-
.pt-md-1 {
padding-top: 0.25rem !important;
}
-
.pt-md-2 {
padding-top: 0.5rem !important;
}
-
.pt-md-3 {
padding-top: 1rem !important;
}
-
.pt-md-4 {
padding-top: 1.5rem !important;
}
-
.pt-md-5 {
padding-top: 3rem !important;
}
-
.pe-md-0 {
padding-right: 0 !important;
}
-
.pe-md-1 {
padding-right: 0.25rem !important;
}
-
.pe-md-2 {
padding-right: 0.5rem !important;
}
-
.pe-md-3 {
padding-right: 1rem !important;
}
-
.pe-md-4 {
padding-right: 1.5rem !important;
}
-
.pe-md-5 {
padding-right: 3rem !important;
}
-
.pb-md-0 {
padding-bottom: 0 !important;
}
-
.pb-md-1 {
padding-bottom: 0.25rem !important;
}
-
.pb-md-2 {
padding-bottom: 0.5rem !important;
}
-
.pb-md-3 {
padding-bottom: 1rem !important;
}
-
.pb-md-4 {
padding-bottom: 1.5rem !important;
}
-
.pb-md-5 {
padding-bottom: 3rem !important;
}
-
.ps-md-0 {
padding-left: 0 !important;
}
-
.ps-md-1 {
padding-left: 0.25rem !important;
}
-
.ps-md-2 {
padding-left: 0.5rem !important;
}
-
.ps-md-3 {
padding-left: 1rem !important;
}
-
.ps-md-4 {
padding-left: 1.5rem !important;
}
-
.ps-md-5 {
padding-left: 3rem !important;
}
-
+ .gap-md-0 {
+ gap: 0 !important;
+ }
+ .gap-md-1 {
+ gap: 0.25rem !important;
+ }
+ .gap-md-2 {
+ gap: 0.5rem !important;
+ }
+ .gap-md-3 {
+ gap: 1rem !important;
+ }
+ .gap-md-4 {
+ gap: 1.5rem !important;
+ }
+ .gap-md-5 {
+ gap: 3rem !important;
+ }
+ .row-gap-md-0 {
+ row-gap: 0 !important;
+ }
+ .row-gap-md-1 {
+ row-gap: 0.25rem !important;
+ }
+ .row-gap-md-2 {
+ row-gap: 0.5rem !important;
+ }
+ .row-gap-md-3 {
+ row-gap: 1rem !important;
+ }
+ .row-gap-md-4 {
+ row-gap: 1.5rem !important;
+ }
+ .row-gap-md-5 {
+ row-gap: 3rem !important;
+ }
+ .column-gap-md-0 {
+ -moz-column-gap: 0 !important;
+ column-gap: 0 !important;
+ }
+ .column-gap-md-1 {
+ -moz-column-gap: 0.25rem !important;
+ column-gap: 0.25rem !important;
+ }
+ .column-gap-md-2 {
+ -moz-column-gap: 0.5rem !important;
+ column-gap: 0.5rem !important;
+ }
+ .column-gap-md-3 {
+ -moz-column-gap: 1rem !important;
+ column-gap: 1rem !important;
+ }
+ .column-gap-md-4 {
+ -moz-column-gap: 1.5rem !important;
+ column-gap: 1.5rem !important;
+ }
+ .column-gap-md-5 {
+ -moz-column-gap: 3rem !important;
+ column-gap: 3rem !important;
+ }
.text-md-start {
text-align: left !important;
}
-
.text-md-end {
text-align: right !important;
}
-
.text-md-center {
text-align: center !important;
}
@@ -9343,649 +10424,559 @@
.float-lg-start {
float: left !important;
}
-
.float-lg-end {
float: right !important;
}
-
.float-lg-none {
float: none !important;
}
-
+ .object-fit-lg-contain {
+ -o-object-fit: contain !important;
+ object-fit: contain !important;
+ }
+ .object-fit-lg-cover {
+ -o-object-fit: cover !important;
+ object-fit: cover !important;
+ }
+ .object-fit-lg-fill {
+ -o-object-fit: fill !important;
+ object-fit: fill !important;
+ }
+ .object-fit-lg-scale {
+ -o-object-fit: scale-down !important;
+ object-fit: scale-down !important;
+ }
+ .object-fit-lg-none {
+ -o-object-fit: none !important;
+ object-fit: none !important;
+ }
.d-lg-inline {
display: inline !important;
}
-
.d-lg-inline-block {
display: inline-block !important;
}
-
.d-lg-block {
display: block !important;
}
-
.d-lg-grid {
display: grid !important;
}
-
+ .d-lg-inline-grid {
+ display: inline-grid !important;
+ }
.d-lg-table {
display: table !important;
}
-
.d-lg-table-row {
display: table-row !important;
}
-
.d-lg-table-cell {
display: table-cell !important;
}
-
.d-lg-flex {
display: flex !important;
}
-
.d-lg-inline-flex {
display: inline-flex !important;
}
-
.d-lg-none {
display: none !important;
}
-
.flex-lg-fill {
flex: 1 1 auto !important;
}
-
.flex-lg-row {
flex-direction: row !important;
}
-
.flex-lg-column {
flex-direction: column !important;
}
-
.flex-lg-row-reverse {
flex-direction: row-reverse !important;
}
-
.flex-lg-column-reverse {
flex-direction: column-reverse !important;
}
-
.flex-lg-grow-0 {
flex-grow: 0 !important;
}
-
.flex-lg-grow-1 {
flex-grow: 1 !important;
}
-
.flex-lg-shrink-0 {
flex-shrink: 0 !important;
}
-
.flex-lg-shrink-1 {
flex-shrink: 1 !important;
}
-
.flex-lg-wrap {
flex-wrap: wrap !important;
}
-
.flex-lg-nowrap {
flex-wrap: nowrap !important;
}
-
.flex-lg-wrap-reverse {
flex-wrap: wrap-reverse !important;
}
-
- .gap-lg-0 {
- gap: 0 !important;
- }
-
- .gap-lg-1 {
- gap: 0.25rem !important;
- }
-
- .gap-lg-2 {
- gap: 0.5rem !important;
- }
-
- .gap-lg-3 {
- gap: 1rem !important;
- }
-
- .gap-lg-4 {
- gap: 1.5rem !important;
- }
-
- .gap-lg-5 {
- gap: 3rem !important;
- }
-
.justify-content-lg-start {
justify-content: flex-start !important;
}
-
.justify-content-lg-end {
justify-content: flex-end !important;
}
-
.justify-content-lg-center {
justify-content: center !important;
}
-
.justify-content-lg-between {
justify-content: space-between !important;
}
-
.justify-content-lg-around {
justify-content: space-around !important;
}
-
.justify-content-lg-evenly {
justify-content: space-evenly !important;
}
-
.align-items-lg-start {
align-items: flex-start !important;
}
-
.align-items-lg-end {
align-items: flex-end !important;
}
-
.align-items-lg-center {
align-items: center !important;
}
-
.align-items-lg-baseline {
align-items: baseline !important;
}
-
.align-items-lg-stretch {
align-items: stretch !important;
}
-
.align-content-lg-start {
align-content: flex-start !important;
}
-
.align-content-lg-end {
align-content: flex-end !important;
}
-
.align-content-lg-center {
align-content: center !important;
}
-
.align-content-lg-between {
align-content: space-between !important;
}
-
.align-content-lg-around {
align-content: space-around !important;
}
-
.align-content-lg-stretch {
align-content: stretch !important;
}
-
.align-self-lg-auto {
align-self: auto !important;
}
-
.align-self-lg-start {
align-self: flex-start !important;
}
-
.align-self-lg-end {
align-self: flex-end !important;
}
-
.align-self-lg-center {
align-self: center !important;
}
-
.align-self-lg-baseline {
align-self: baseline !important;
}
-
.align-self-lg-stretch {
align-self: stretch !important;
}
-
.order-lg-first {
order: -1 !important;
}
-
.order-lg-0 {
order: 0 !important;
}
-
.order-lg-1 {
order: 1 !important;
}
-
.order-lg-2 {
order: 2 !important;
}
-
.order-lg-3 {
order: 3 !important;
}
-
.order-lg-4 {
order: 4 !important;
}
-
.order-lg-5 {
order: 5 !important;
}
-
.order-lg-last {
order: 6 !important;
}
-
.m-lg-0 {
margin: 0 !important;
}
-
.m-lg-1 {
margin: 0.25rem !important;
}
-
.m-lg-2 {
margin: 0.5rem !important;
}
-
.m-lg-3 {
margin: 1rem !important;
}
-
.m-lg-4 {
margin: 1.5rem !important;
}
-
.m-lg-5 {
margin: 3rem !important;
}
-
.m-lg-auto {
margin: auto !important;
}
-
.mx-lg-0 {
margin-right: 0 !important;
margin-left: 0 !important;
}
-
.mx-lg-1 {
margin-right: 0.25rem !important;
margin-left: 0.25rem !important;
}
-
.mx-lg-2 {
margin-right: 0.5rem !important;
margin-left: 0.5rem !important;
}
-
.mx-lg-3 {
margin-right: 1rem !important;
margin-left: 1rem !important;
}
-
.mx-lg-4 {
margin-right: 1.5rem !important;
margin-left: 1.5rem !important;
}
-
.mx-lg-5 {
margin-right: 3rem !important;
margin-left: 3rem !important;
}
-
.mx-lg-auto {
margin-right: auto !important;
margin-left: auto !important;
}
-
.my-lg-0 {
margin-top: 0 !important;
margin-bottom: 0 !important;
}
-
.my-lg-1 {
margin-top: 0.25rem !important;
margin-bottom: 0.25rem !important;
}
-
.my-lg-2 {
margin-top: 0.5rem !important;
margin-bottom: 0.5rem !important;
}
-
.my-lg-3 {
margin-top: 1rem !important;
margin-bottom: 1rem !important;
}
-
.my-lg-4 {
margin-top: 1.5rem !important;
margin-bottom: 1.5rem !important;
}
-
.my-lg-5 {
margin-top: 3rem !important;
margin-bottom: 3rem !important;
}
-
.my-lg-auto {
margin-top: auto !important;
margin-bottom: auto !important;
}
-
.mt-lg-0 {
margin-top: 0 !important;
}
-
.mt-lg-1 {
margin-top: 0.25rem !important;
}
-
.mt-lg-2 {
margin-top: 0.5rem !important;
}
-
.mt-lg-3 {
margin-top: 1rem !important;
}
-
.mt-lg-4 {
margin-top: 1.5rem !important;
}
-
.mt-lg-5 {
margin-top: 3rem !important;
}
-
.mt-lg-auto {
margin-top: auto !important;
}
-
.me-lg-0 {
margin-right: 0 !important;
}
-
.me-lg-1 {
margin-right: 0.25rem !important;
}
-
.me-lg-2 {
margin-right: 0.5rem !important;
}
-
.me-lg-3 {
margin-right: 1rem !important;
}
-
.me-lg-4 {
margin-right: 1.5rem !important;
}
-
.me-lg-5 {
margin-right: 3rem !important;
}
-
.me-lg-auto {
margin-right: auto !important;
}
-
.mb-lg-0 {
margin-bottom: 0 !important;
}
-
.mb-lg-1 {
margin-bottom: 0.25rem !important;
}
-
.mb-lg-2 {
margin-bottom: 0.5rem !important;
}
-
.mb-lg-3 {
margin-bottom: 1rem !important;
}
-
.mb-lg-4 {
margin-bottom: 1.5rem !important;
}
-
.mb-lg-5 {
margin-bottom: 3rem !important;
}
-
.mb-lg-auto {
margin-bottom: auto !important;
}
-
.ms-lg-0 {
margin-left: 0 !important;
}
-
.ms-lg-1 {
margin-left: 0.25rem !important;
}
-
.ms-lg-2 {
margin-left: 0.5rem !important;
}
-
.ms-lg-3 {
margin-left: 1rem !important;
}
-
.ms-lg-4 {
margin-left: 1.5rem !important;
}
-
.ms-lg-5 {
margin-left: 3rem !important;
}
-
.ms-lg-auto {
margin-left: auto !important;
}
-
.p-lg-0 {
padding: 0 !important;
}
-
.p-lg-1 {
padding: 0.25rem !important;
}
-
.p-lg-2 {
padding: 0.5rem !important;
}
-
.p-lg-3 {
padding: 1rem !important;
}
-
.p-lg-4 {
padding: 1.5rem !important;
}
-
.p-lg-5 {
padding: 3rem !important;
}
-
.px-lg-0 {
padding-right: 0 !important;
padding-left: 0 !important;
}
-
.px-lg-1 {
padding-right: 0.25rem !important;
padding-left: 0.25rem !important;
}
-
.px-lg-2 {
padding-right: 0.5rem !important;
padding-left: 0.5rem !important;
}
-
.px-lg-3 {
padding-right: 1rem !important;
padding-left: 1rem !important;
}
-
.px-lg-4 {
padding-right: 1.5rem !important;
padding-left: 1.5rem !important;
}
-
.px-lg-5 {
padding-right: 3rem !important;
padding-left: 3rem !important;
}
-
.py-lg-0 {
padding-top: 0 !important;
padding-bottom: 0 !important;
}
-
.py-lg-1 {
padding-top: 0.25rem !important;
padding-bottom: 0.25rem !important;
}
-
.py-lg-2 {
padding-top: 0.5rem !important;
padding-bottom: 0.5rem !important;
}
-
.py-lg-3 {
padding-top: 1rem !important;
padding-bottom: 1rem !important;
}
-
.py-lg-4 {
padding-top: 1.5rem !important;
padding-bottom: 1.5rem !important;
}
-
.py-lg-5 {
padding-top: 3rem !important;
padding-bottom: 3rem !important;
}
-
.pt-lg-0 {
padding-top: 0 !important;
}
-
.pt-lg-1 {
padding-top: 0.25rem !important;
}
-
.pt-lg-2 {
padding-top: 0.5rem !important;
}
-
.pt-lg-3 {
padding-top: 1rem !important;
}
-
.pt-lg-4 {
padding-top: 1.5rem !important;
}
-
.pt-lg-5 {
padding-top: 3rem !important;
}
-
.pe-lg-0 {
padding-right: 0 !important;
}
-
.pe-lg-1 {
padding-right: 0.25rem !important;
}
-
.pe-lg-2 {
padding-right: 0.5rem !important;
}
-
.pe-lg-3 {
padding-right: 1rem !important;
}
-
.pe-lg-4 {
padding-right: 1.5rem !important;
}
-
.pe-lg-5 {
padding-right: 3rem !important;
}
-
.pb-lg-0 {
padding-bottom: 0 !important;
}
-
.pb-lg-1 {
padding-bottom: 0.25rem !important;
}
-
.pb-lg-2 {
padding-bottom: 0.5rem !important;
}
-
.pb-lg-3 {
padding-bottom: 1rem !important;
}
-
.pb-lg-4 {
padding-bottom: 1.5rem !important;
}
-
.pb-lg-5 {
padding-bottom: 3rem !important;
}
-
.ps-lg-0 {
padding-left: 0 !important;
}
-
.ps-lg-1 {
padding-left: 0.25rem !important;
}
-
.ps-lg-2 {
padding-left: 0.5rem !important;
}
-
.ps-lg-3 {
padding-left: 1rem !important;
}
-
.ps-lg-4 {
padding-left: 1.5rem !important;
}
-
.ps-lg-5 {
padding-left: 3rem !important;
}
-
+ .gap-lg-0 {
+ gap: 0 !important;
+ }
+ .gap-lg-1 {
+ gap: 0.25rem !important;
+ }
+ .gap-lg-2 {
+ gap: 0.5rem !important;
+ }
+ .gap-lg-3 {
+ gap: 1rem !important;
+ }
+ .gap-lg-4 {
+ gap: 1.5rem !important;
+ }
+ .gap-lg-5 {
+ gap: 3rem !important;
+ }
+ .row-gap-lg-0 {
+ row-gap: 0 !important;
+ }
+ .row-gap-lg-1 {
+ row-gap: 0.25rem !important;
+ }
+ .row-gap-lg-2 {
+ row-gap: 0.5rem !important;
+ }
+ .row-gap-lg-3 {
+ row-gap: 1rem !important;
+ }
+ .row-gap-lg-4 {
+ row-gap: 1.5rem !important;
+ }
+ .row-gap-lg-5 {
+ row-gap: 3rem !important;
+ }
+ .column-gap-lg-0 {
+ -moz-column-gap: 0 !important;
+ column-gap: 0 !important;
+ }
+ .column-gap-lg-1 {
+ -moz-column-gap: 0.25rem !important;
+ column-gap: 0.25rem !important;
+ }
+ .column-gap-lg-2 {
+ -moz-column-gap: 0.5rem !important;
+ column-gap: 0.5rem !important;
+ }
+ .column-gap-lg-3 {
+ -moz-column-gap: 1rem !important;
+ column-gap: 1rem !important;
+ }
+ .column-gap-lg-4 {
+ -moz-column-gap: 1.5rem !important;
+ column-gap: 1.5rem !important;
+ }
+ .column-gap-lg-5 {
+ -moz-column-gap: 3rem !important;
+ column-gap: 3rem !important;
+ }
.text-lg-start {
text-align: left !important;
}
-
.text-lg-end {
text-align: right !important;
}
-
.text-lg-center {
text-align: center !important;
}
@@ -9994,649 +10985,559 @@
.float-xl-start {
float: left !important;
}
-
.float-xl-end {
float: right !important;
}
-
.float-xl-none {
float: none !important;
}
-
+ .object-fit-xl-contain {
+ -o-object-fit: contain !important;
+ object-fit: contain !important;
+ }
+ .object-fit-xl-cover {
+ -o-object-fit: cover !important;
+ object-fit: cover !important;
+ }
+ .object-fit-xl-fill {
+ -o-object-fit: fill !important;
+ object-fit: fill !important;
+ }
+ .object-fit-xl-scale {
+ -o-object-fit: scale-down !important;
+ object-fit: scale-down !important;
+ }
+ .object-fit-xl-none {
+ -o-object-fit: none !important;
+ object-fit: none !important;
+ }
.d-xl-inline {
display: inline !important;
}
-
.d-xl-inline-block {
display: inline-block !important;
}
-
.d-xl-block {
display: block !important;
}
-
.d-xl-grid {
display: grid !important;
}
-
+ .d-xl-inline-grid {
+ display: inline-grid !important;
+ }
.d-xl-table {
display: table !important;
}
-
.d-xl-table-row {
display: table-row !important;
}
-
.d-xl-table-cell {
display: table-cell !important;
}
-
.d-xl-flex {
display: flex !important;
}
-
.d-xl-inline-flex {
display: inline-flex !important;
}
-
.d-xl-none {
display: none !important;
}
-
.flex-xl-fill {
flex: 1 1 auto !important;
}
-
.flex-xl-row {
flex-direction: row !important;
}
-
.flex-xl-column {
flex-direction: column !important;
}
-
.flex-xl-row-reverse {
flex-direction: row-reverse !important;
}
-
.flex-xl-column-reverse {
flex-direction: column-reverse !important;
}
-
.flex-xl-grow-0 {
flex-grow: 0 !important;
}
-
.flex-xl-grow-1 {
flex-grow: 1 !important;
}
-
.flex-xl-shrink-0 {
flex-shrink: 0 !important;
}
-
.flex-xl-shrink-1 {
flex-shrink: 1 !important;
}
-
.flex-xl-wrap {
flex-wrap: wrap !important;
}
-
.flex-xl-nowrap {
flex-wrap: nowrap !important;
}
-
.flex-xl-wrap-reverse {
flex-wrap: wrap-reverse !important;
}
-
- .gap-xl-0 {
- gap: 0 !important;
- }
-
- .gap-xl-1 {
- gap: 0.25rem !important;
- }
-
- .gap-xl-2 {
- gap: 0.5rem !important;
- }
-
- .gap-xl-3 {
- gap: 1rem !important;
- }
-
- .gap-xl-4 {
- gap: 1.5rem !important;
- }
-
- .gap-xl-5 {
- gap: 3rem !important;
- }
-
.justify-content-xl-start {
justify-content: flex-start !important;
}
-
.justify-content-xl-end {
justify-content: flex-end !important;
}
-
.justify-content-xl-center {
justify-content: center !important;
}
-
.justify-content-xl-between {
justify-content: space-between !important;
}
-
.justify-content-xl-around {
justify-content: space-around !important;
}
-
.justify-content-xl-evenly {
justify-content: space-evenly !important;
}
-
.align-items-xl-start {
align-items: flex-start !important;
}
-
.align-items-xl-end {
align-items: flex-end !important;
}
-
.align-items-xl-center {
align-items: center !important;
}
-
.align-items-xl-baseline {
align-items: baseline !important;
}
-
.align-items-xl-stretch {
align-items: stretch !important;
}
-
.align-content-xl-start {
align-content: flex-start !important;
}
-
.align-content-xl-end {
align-content: flex-end !important;
}
-
.align-content-xl-center {
align-content: center !important;
}
-
.align-content-xl-between {
align-content: space-between !important;
}
-
.align-content-xl-around {
align-content: space-around !important;
}
-
.align-content-xl-stretch {
align-content: stretch !important;
}
-
.align-self-xl-auto {
align-self: auto !important;
}
-
.align-self-xl-start {
align-self: flex-start !important;
}
-
.align-self-xl-end {
align-self: flex-end !important;
}
-
.align-self-xl-center {
align-self: center !important;
}
-
.align-self-xl-baseline {
align-self: baseline !important;
}
-
.align-self-xl-stretch {
align-self: stretch !important;
}
-
.order-xl-first {
order: -1 !important;
}
-
.order-xl-0 {
order: 0 !important;
}
-
.order-xl-1 {
order: 1 !important;
}
-
.order-xl-2 {
order: 2 !important;
}
-
.order-xl-3 {
order: 3 !important;
}
-
.order-xl-4 {
order: 4 !important;
}
-
.order-xl-5 {
order: 5 !important;
}
-
.order-xl-last {
order: 6 !important;
}
-
.m-xl-0 {
margin: 0 !important;
}
-
.m-xl-1 {
margin: 0.25rem !important;
}
-
.m-xl-2 {
margin: 0.5rem !important;
}
-
.m-xl-3 {
margin: 1rem !important;
}
-
.m-xl-4 {
margin: 1.5rem !important;
}
-
.m-xl-5 {
margin: 3rem !important;
}
-
.m-xl-auto {
margin: auto !important;
}
-
.mx-xl-0 {
margin-right: 0 !important;
margin-left: 0 !important;
}
-
.mx-xl-1 {
margin-right: 0.25rem !important;
margin-left: 0.25rem !important;
}
-
.mx-xl-2 {
margin-right: 0.5rem !important;
margin-left: 0.5rem !important;
}
-
.mx-xl-3 {
margin-right: 1rem !important;
margin-left: 1rem !important;
}
-
.mx-xl-4 {
margin-right: 1.5rem !important;
margin-left: 1.5rem !important;
}
-
.mx-xl-5 {
margin-right: 3rem !important;
margin-left: 3rem !important;
}
-
.mx-xl-auto {
margin-right: auto !important;
margin-left: auto !important;
}
-
.my-xl-0 {
margin-top: 0 !important;
margin-bottom: 0 !important;
}
-
.my-xl-1 {
margin-top: 0.25rem !important;
margin-bottom: 0.25rem !important;
}
-
.my-xl-2 {
margin-top: 0.5rem !important;
margin-bottom: 0.5rem !important;
}
-
.my-xl-3 {
margin-top: 1rem !important;
margin-bottom: 1rem !important;
}
-
.my-xl-4 {
margin-top: 1.5rem !important;
margin-bottom: 1.5rem !important;
}
-
.my-xl-5 {
margin-top: 3rem !important;
margin-bottom: 3rem !important;
}
-
.my-xl-auto {
margin-top: auto !important;
margin-bottom: auto !important;
}
-
.mt-xl-0 {
margin-top: 0 !important;
}
-
.mt-xl-1 {
margin-top: 0.25rem !important;
}
-
.mt-xl-2 {
margin-top: 0.5rem !important;
}
-
.mt-xl-3 {
margin-top: 1rem !important;
}
-
.mt-xl-4 {
margin-top: 1.5rem !important;
}
-
.mt-xl-5 {
margin-top: 3rem !important;
}
-
.mt-xl-auto {
margin-top: auto !important;
}
-
.me-xl-0 {
margin-right: 0 !important;
}
-
.me-xl-1 {
margin-right: 0.25rem !important;
}
-
.me-xl-2 {
margin-right: 0.5rem !important;
}
-
.me-xl-3 {
margin-right: 1rem !important;
}
-
.me-xl-4 {
margin-right: 1.5rem !important;
}
-
.me-xl-5 {
margin-right: 3rem !important;
}
-
.me-xl-auto {
margin-right: auto !important;
}
-
.mb-xl-0 {
margin-bottom: 0 !important;
}
-
.mb-xl-1 {
margin-bottom: 0.25rem !important;
}
-
.mb-xl-2 {
margin-bottom: 0.5rem !important;
}
-
.mb-xl-3 {
margin-bottom: 1rem !important;
}
-
.mb-xl-4 {
margin-bottom: 1.5rem !important;
}
-
.mb-xl-5 {
margin-bottom: 3rem !important;
}
-
.mb-xl-auto {
margin-bottom: auto !important;
}
-
.ms-xl-0 {
margin-left: 0 !important;
}
-
.ms-xl-1 {
margin-left: 0.25rem !important;
}
-
.ms-xl-2 {
margin-left: 0.5rem !important;
}
-
.ms-xl-3 {
margin-left: 1rem !important;
}
-
.ms-xl-4 {
margin-left: 1.5rem !important;
}
-
.ms-xl-5 {
margin-left: 3rem !important;
}
-
.ms-xl-auto {
margin-left: auto !important;
}
-
.p-xl-0 {
padding: 0 !important;
}
-
.p-xl-1 {
padding: 0.25rem !important;
}
-
.p-xl-2 {
padding: 0.5rem !important;
}
-
.p-xl-3 {
padding: 1rem !important;
}
-
.p-xl-4 {
padding: 1.5rem !important;
}
-
.p-xl-5 {
padding: 3rem !important;
}
-
.px-xl-0 {
padding-right: 0 !important;
padding-left: 0 !important;
}
-
.px-xl-1 {
padding-right: 0.25rem !important;
padding-left: 0.25rem !important;
}
-
.px-xl-2 {
padding-right: 0.5rem !important;
padding-left: 0.5rem !important;
}
-
.px-xl-3 {
padding-right: 1rem !important;
padding-left: 1rem !important;
}
-
.px-xl-4 {
padding-right: 1.5rem !important;
padding-left: 1.5rem !important;
}
-
.px-xl-5 {
padding-right: 3rem !important;
padding-left: 3rem !important;
}
-
.py-xl-0 {
padding-top: 0 !important;
padding-bottom: 0 !important;
}
-
.py-xl-1 {
padding-top: 0.25rem !important;
padding-bottom: 0.25rem !important;
}
-
.py-xl-2 {
padding-top: 0.5rem !important;
padding-bottom: 0.5rem !important;
}
-
.py-xl-3 {
padding-top: 1rem !important;
padding-bottom: 1rem !important;
}
-
.py-xl-4 {
padding-top: 1.5rem !important;
padding-bottom: 1.5rem !important;
}
-
.py-xl-5 {
padding-top: 3rem !important;
padding-bottom: 3rem !important;
}
-
.pt-xl-0 {
padding-top: 0 !important;
}
-
.pt-xl-1 {
padding-top: 0.25rem !important;
}
-
.pt-xl-2 {
padding-top: 0.5rem !important;
}
-
.pt-xl-3 {
padding-top: 1rem !important;
}
-
.pt-xl-4 {
padding-top: 1.5rem !important;
}
-
.pt-xl-5 {
padding-top: 3rem !important;
}
-
.pe-xl-0 {
padding-right: 0 !important;
}
-
.pe-xl-1 {
padding-right: 0.25rem !important;
}
-
.pe-xl-2 {
padding-right: 0.5rem !important;
}
-
.pe-xl-3 {
padding-right: 1rem !important;
}
-
.pe-xl-4 {
padding-right: 1.5rem !important;
}
-
.pe-xl-5 {
padding-right: 3rem !important;
}
-
.pb-xl-0 {
padding-bottom: 0 !important;
}
-
.pb-xl-1 {
padding-bottom: 0.25rem !important;
}
-
.pb-xl-2 {
padding-bottom: 0.5rem !important;
}
-
.pb-xl-3 {
padding-bottom: 1rem !important;
}
-
.pb-xl-4 {
padding-bottom: 1.5rem !important;
}
-
.pb-xl-5 {
padding-bottom: 3rem !important;
}
-
.ps-xl-0 {
padding-left: 0 !important;
}
-
.ps-xl-1 {
padding-left: 0.25rem !important;
}
-
.ps-xl-2 {
padding-left: 0.5rem !important;
}
-
.ps-xl-3 {
padding-left: 1rem !important;
}
-
.ps-xl-4 {
padding-left: 1.5rem !important;
}
-
.ps-xl-5 {
padding-left: 3rem !important;
}
-
+ .gap-xl-0 {
+ gap: 0 !important;
+ }
+ .gap-xl-1 {
+ gap: 0.25rem !important;
+ }
+ .gap-xl-2 {
+ gap: 0.5rem !important;
+ }
+ .gap-xl-3 {
+ gap: 1rem !important;
+ }
+ .gap-xl-4 {
+ gap: 1.5rem !important;
+ }
+ .gap-xl-5 {
+ gap: 3rem !important;
+ }
+ .row-gap-xl-0 {
+ row-gap: 0 !important;
+ }
+ .row-gap-xl-1 {
+ row-gap: 0.25rem !important;
+ }
+ .row-gap-xl-2 {
+ row-gap: 0.5rem !important;
+ }
+ .row-gap-xl-3 {
+ row-gap: 1rem !important;
+ }
+ .row-gap-xl-4 {
+ row-gap: 1.5rem !important;
+ }
+ .row-gap-xl-5 {
+ row-gap: 3rem !important;
+ }
+ .column-gap-xl-0 {
+ -moz-column-gap: 0 !important;
+ column-gap: 0 !important;
+ }
+ .column-gap-xl-1 {
+ -moz-column-gap: 0.25rem !important;
+ column-gap: 0.25rem !important;
+ }
+ .column-gap-xl-2 {
+ -moz-column-gap: 0.5rem !important;
+ column-gap: 0.5rem !important;
+ }
+ .column-gap-xl-3 {
+ -moz-column-gap: 1rem !important;
+ column-gap: 1rem !important;
+ }
+ .column-gap-xl-4 {
+ -moz-column-gap: 1.5rem !important;
+ column-gap: 1.5rem !important;
+ }
+ .column-gap-xl-5 {
+ -moz-column-gap: 3rem !important;
+ column-gap: 3rem !important;
+ }
.text-xl-start {
text-align: left !important;
}
-
.text-xl-end {
text-align: right !important;
}
-
.text-xl-center {
text-align: center !important;
}
@@ -10645,649 +11546,559 @@
.float-xxl-start {
float: left !important;
}
-
.float-xxl-end {
float: right !important;
}
-
.float-xxl-none {
float: none !important;
}
-
+ .object-fit-xxl-contain {
+ -o-object-fit: contain !important;
+ object-fit: contain !important;
+ }
+ .object-fit-xxl-cover {
+ -o-object-fit: cover !important;
+ object-fit: cover !important;
+ }
+ .object-fit-xxl-fill {
+ -o-object-fit: fill !important;
+ object-fit: fill !important;
+ }
+ .object-fit-xxl-scale {
+ -o-object-fit: scale-down !important;
+ object-fit: scale-down !important;
+ }
+ .object-fit-xxl-none {
+ -o-object-fit: none !important;
+ object-fit: none !important;
+ }
.d-xxl-inline {
display: inline !important;
}
-
.d-xxl-inline-block {
display: inline-block !important;
}
-
.d-xxl-block {
display: block !important;
}
-
.d-xxl-grid {
display: grid !important;
}
-
+ .d-xxl-inline-grid {
+ display: inline-grid !important;
+ }
.d-xxl-table {
display: table !important;
}
-
.d-xxl-table-row {
display: table-row !important;
}
-
.d-xxl-table-cell {
display: table-cell !important;
}
-
.d-xxl-flex {
display: flex !important;
}
-
.d-xxl-inline-flex {
display: inline-flex !important;
}
-
.d-xxl-none {
display: none !important;
}
-
.flex-xxl-fill {
flex: 1 1 auto !important;
}
-
.flex-xxl-row {
flex-direction: row !important;
}
-
.flex-xxl-column {
flex-direction: column !important;
}
-
.flex-xxl-row-reverse {
flex-direction: row-reverse !important;
}
-
.flex-xxl-column-reverse {
flex-direction: column-reverse !important;
}
-
.flex-xxl-grow-0 {
flex-grow: 0 !important;
}
-
.flex-xxl-grow-1 {
flex-grow: 1 !important;
}
-
.flex-xxl-shrink-0 {
flex-shrink: 0 !important;
}
-
.flex-xxl-shrink-1 {
flex-shrink: 1 !important;
}
-
.flex-xxl-wrap {
flex-wrap: wrap !important;
}
-
.flex-xxl-nowrap {
flex-wrap: nowrap !important;
}
-
.flex-xxl-wrap-reverse {
flex-wrap: wrap-reverse !important;
}
-
- .gap-xxl-0 {
- gap: 0 !important;
- }
-
- .gap-xxl-1 {
- gap: 0.25rem !important;
- }
-
- .gap-xxl-2 {
- gap: 0.5rem !important;
- }
-
- .gap-xxl-3 {
- gap: 1rem !important;
- }
-
- .gap-xxl-4 {
- gap: 1.5rem !important;
- }
-
- .gap-xxl-5 {
- gap: 3rem !important;
- }
-
.justify-content-xxl-start {
justify-content: flex-start !important;
}
-
.justify-content-xxl-end {
justify-content: flex-end !important;
}
-
.justify-content-xxl-center {
justify-content: center !important;
}
-
.justify-content-xxl-between {
justify-content: space-between !important;
}
-
.justify-content-xxl-around {
justify-content: space-around !important;
}
-
.justify-content-xxl-evenly {
justify-content: space-evenly !important;
}
-
.align-items-xxl-start {
align-items: flex-start !important;
}
-
.align-items-xxl-end {
align-items: flex-end !important;
}
-
.align-items-xxl-center {
align-items: center !important;
}
-
.align-items-xxl-baseline {
align-items: baseline !important;
}
-
.align-items-xxl-stretch {
align-items: stretch !important;
}
-
.align-content-xxl-start {
align-content: flex-start !important;
}
-
.align-content-xxl-end {
align-content: flex-end !important;
}
-
.align-content-xxl-center {
align-content: center !important;
}
-
.align-content-xxl-between {
align-content: space-between !important;
}
-
.align-content-xxl-around {
align-content: space-around !important;
}
-
.align-content-xxl-stretch {
align-content: stretch !important;
}
-
.align-self-xxl-auto {
align-self: auto !important;
}
-
.align-self-xxl-start {
align-self: flex-start !important;
}
-
.align-self-xxl-end {
align-self: flex-end !important;
}
-
.align-self-xxl-center {
align-self: center !important;
}
-
.align-self-xxl-baseline {
align-self: baseline !important;
}
-
.align-self-xxl-stretch {
align-self: stretch !important;
}
-
.order-xxl-first {
order: -1 !important;
}
-
.order-xxl-0 {
order: 0 !important;
}
-
.order-xxl-1 {
order: 1 !important;
}
-
.order-xxl-2 {
order: 2 !important;
}
-
.order-xxl-3 {
order: 3 !important;
}
-
.order-xxl-4 {
order: 4 !important;
}
-
.order-xxl-5 {
order: 5 !important;
}
-
.order-xxl-last {
order: 6 !important;
}
-
.m-xxl-0 {
margin: 0 !important;
}
-
.m-xxl-1 {
margin: 0.25rem !important;
}
-
.m-xxl-2 {
margin: 0.5rem !important;
}
-
.m-xxl-3 {
margin: 1rem !important;
}
-
.m-xxl-4 {
margin: 1.5rem !important;
}
-
.m-xxl-5 {
margin: 3rem !important;
}
-
.m-xxl-auto {
margin: auto !important;
}
-
.mx-xxl-0 {
margin-right: 0 !important;
margin-left: 0 !important;
}
-
.mx-xxl-1 {
margin-right: 0.25rem !important;
margin-left: 0.25rem !important;
}
-
.mx-xxl-2 {
margin-right: 0.5rem !important;
margin-left: 0.5rem !important;
}
-
.mx-xxl-3 {
margin-right: 1rem !important;
margin-left: 1rem !important;
}
-
.mx-xxl-4 {
margin-right: 1.5rem !important;
margin-left: 1.5rem !important;
}
-
.mx-xxl-5 {
margin-right: 3rem !important;
margin-left: 3rem !important;
}
-
.mx-xxl-auto {
margin-right: auto !important;
margin-left: auto !important;
}
-
.my-xxl-0 {
margin-top: 0 !important;
margin-bottom: 0 !important;
}
-
.my-xxl-1 {
margin-top: 0.25rem !important;
margin-bottom: 0.25rem !important;
}
-
.my-xxl-2 {
margin-top: 0.5rem !important;
margin-bottom: 0.5rem !important;
}
-
.my-xxl-3 {
margin-top: 1rem !important;
margin-bottom: 1rem !important;
}
-
.my-xxl-4 {
margin-top: 1.5rem !important;
margin-bottom: 1.5rem !important;
}
-
.my-xxl-5 {
margin-top: 3rem !important;
margin-bottom: 3rem !important;
}
-
.my-xxl-auto {
margin-top: auto !important;
margin-bottom: auto !important;
}
-
.mt-xxl-0 {
margin-top: 0 !important;
}
-
.mt-xxl-1 {
margin-top: 0.25rem !important;
}
-
.mt-xxl-2 {
margin-top: 0.5rem !important;
}
-
.mt-xxl-3 {
margin-top: 1rem !important;
}
-
.mt-xxl-4 {
margin-top: 1.5rem !important;
}
-
.mt-xxl-5 {
margin-top: 3rem !important;
}
-
.mt-xxl-auto {
margin-top: auto !important;
}
-
.me-xxl-0 {
margin-right: 0 !important;
}
-
.me-xxl-1 {
margin-right: 0.25rem !important;
}
-
.me-xxl-2 {
margin-right: 0.5rem !important;
}
-
.me-xxl-3 {
margin-right: 1rem !important;
}
-
.me-xxl-4 {
margin-right: 1.5rem !important;
}
-
.me-xxl-5 {
margin-right: 3rem !important;
}
-
.me-xxl-auto {
margin-right: auto !important;
}
-
.mb-xxl-0 {
margin-bottom: 0 !important;
}
-
.mb-xxl-1 {
margin-bottom: 0.25rem !important;
}
-
.mb-xxl-2 {
margin-bottom: 0.5rem !important;
}
-
.mb-xxl-3 {
margin-bottom: 1rem !important;
}
-
.mb-xxl-4 {
margin-bottom: 1.5rem !important;
}
-
.mb-xxl-5 {
margin-bottom: 3rem !important;
}
-
.mb-xxl-auto {
margin-bottom: auto !important;
}
-
.ms-xxl-0 {
margin-left: 0 !important;
}
-
.ms-xxl-1 {
margin-left: 0.25rem !important;
}
-
.ms-xxl-2 {
margin-left: 0.5rem !important;
}
-
.ms-xxl-3 {
margin-left: 1rem !important;
}
-
.ms-xxl-4 {
margin-left: 1.5rem !important;
}
-
.ms-xxl-5 {
margin-left: 3rem !important;
}
-
.ms-xxl-auto {
margin-left: auto !important;
}
-
.p-xxl-0 {
padding: 0 !important;
}
-
.p-xxl-1 {
padding: 0.25rem !important;
}
-
.p-xxl-2 {
padding: 0.5rem !important;
}
-
.p-xxl-3 {
padding: 1rem !important;
}
-
.p-xxl-4 {
padding: 1.5rem !important;
}
-
.p-xxl-5 {
padding: 3rem !important;
}
-
.px-xxl-0 {
padding-right: 0 !important;
padding-left: 0 !important;
}
-
.px-xxl-1 {
padding-right: 0.25rem !important;
padding-left: 0.25rem !important;
}
-
.px-xxl-2 {
padding-right: 0.5rem !important;
padding-left: 0.5rem !important;
}
-
.px-xxl-3 {
padding-right: 1rem !important;
padding-left: 1rem !important;
}
-
.px-xxl-4 {
padding-right: 1.5rem !important;
padding-left: 1.5rem !important;
}
-
.px-xxl-5 {
padding-right: 3rem !important;
padding-left: 3rem !important;
}
-
.py-xxl-0 {
padding-top: 0 !important;
padding-bottom: 0 !important;
}
-
.py-xxl-1 {
padding-top: 0.25rem !important;
padding-bottom: 0.25rem !important;
}
-
.py-xxl-2 {
padding-top: 0.5rem !important;
padding-bottom: 0.5rem !important;
}
-
.py-xxl-3 {
padding-top: 1rem !important;
padding-bottom: 1rem !important;
}
-
.py-xxl-4 {
padding-top: 1.5rem !important;
padding-bottom: 1.5rem !important;
}
-
.py-xxl-5 {
padding-top: 3rem !important;
padding-bottom: 3rem !important;
}
-
.pt-xxl-0 {
padding-top: 0 !important;
}
-
.pt-xxl-1 {
padding-top: 0.25rem !important;
}
-
.pt-xxl-2 {
padding-top: 0.5rem !important;
}
-
.pt-xxl-3 {
padding-top: 1rem !important;
}
-
.pt-xxl-4 {
padding-top: 1.5rem !important;
}
-
.pt-xxl-5 {
padding-top: 3rem !important;
}
-
.pe-xxl-0 {
padding-right: 0 !important;
}
-
.pe-xxl-1 {
padding-right: 0.25rem !important;
}
-
.pe-xxl-2 {
padding-right: 0.5rem !important;
}
-
.pe-xxl-3 {
padding-right: 1rem !important;
}
-
.pe-xxl-4 {
padding-right: 1.5rem !important;
}
-
.pe-xxl-5 {
padding-right: 3rem !important;
}
-
.pb-xxl-0 {
padding-bottom: 0 !important;
}
-
.pb-xxl-1 {
padding-bottom: 0.25rem !important;
}
-
.pb-xxl-2 {
padding-bottom: 0.5rem !important;
}
-
.pb-xxl-3 {
padding-bottom: 1rem !important;
}
-
.pb-xxl-4 {
padding-bottom: 1.5rem !important;
}
-
.pb-xxl-5 {
padding-bottom: 3rem !important;
}
-
.ps-xxl-0 {
padding-left: 0 !important;
}
-
.ps-xxl-1 {
padding-left: 0.25rem !important;
}
-
.ps-xxl-2 {
padding-left: 0.5rem !important;
}
-
.ps-xxl-3 {
padding-left: 1rem !important;
}
-
.ps-xxl-4 {
padding-left: 1.5rem !important;
}
-
.ps-xxl-5 {
padding-left: 3rem !important;
}
-
+ .gap-xxl-0 {
+ gap: 0 !important;
+ }
+ .gap-xxl-1 {
+ gap: 0.25rem !important;
+ }
+ .gap-xxl-2 {
+ gap: 0.5rem !important;
+ }
+ .gap-xxl-3 {
+ gap: 1rem !important;
+ }
+ .gap-xxl-4 {
+ gap: 1.5rem !important;
+ }
+ .gap-xxl-5 {
+ gap: 3rem !important;
+ }
+ .row-gap-xxl-0 {
+ row-gap: 0 !important;
+ }
+ .row-gap-xxl-1 {
+ row-gap: 0.25rem !important;
+ }
+ .row-gap-xxl-2 {
+ row-gap: 0.5rem !important;
+ }
+ .row-gap-xxl-3 {
+ row-gap: 1rem !important;
+ }
+ .row-gap-xxl-4 {
+ row-gap: 1.5rem !important;
+ }
+ .row-gap-xxl-5 {
+ row-gap: 3rem !important;
+ }
+ .column-gap-xxl-0 {
+ -moz-column-gap: 0 !important;
+ column-gap: 0 !important;
+ }
+ .column-gap-xxl-1 {
+ -moz-column-gap: 0.25rem !important;
+ column-gap: 0.25rem !important;
+ }
+ .column-gap-xxl-2 {
+ -moz-column-gap: 0.5rem !important;
+ column-gap: 0.5rem !important;
+ }
+ .column-gap-xxl-3 {
+ -moz-column-gap: 1rem !important;
+ column-gap: 1rem !important;
+ }
+ .column-gap-xxl-4 {
+ -moz-column-gap: 1.5rem !important;
+ column-gap: 1.5rem !important;
+ }
+ .column-gap-xxl-5 {
+ -moz-column-gap: 3rem !important;
+ column-gap: 3rem !important;
+ }
.text-xxl-start {
text-align: left !important;
}
-
.text-xxl-end {
text-align: right !important;
}
-
.text-xxl-center {
text-align: center !important;
}
@@ -11296,15 +12107,12 @@
.fs-1 {
font-size: 2.5rem !important;
}
-
.fs-2 {
font-size: 2rem !important;
}
-
.fs-3 {
font-size: 1.75rem !important;
}
-
.fs-4 {
font-size: 1.5rem !important;
}
@@ -11313,39 +12121,33 @@
.d-print-inline {
display: inline !important;
}
-
.d-print-inline-block {
display: inline-block !important;
}
-
.d-print-block {
display: block !important;
}
-
.d-print-grid {
display: grid !important;
}
-
+ .d-print-inline-grid {
+ display: inline-grid !important;
+ }
.d-print-table {
display: table !important;
}
-
.d-print-table-row {
display: table-row !important;
}
-
.d-print-table-cell {
display: table-cell !important;
}
-
.d-print-flex {
display: flex !important;
}
-
.d-print-inline-flex {
display: inline-flex !important;
}
-
.d-print-none {
display: none !important;
}
@@ -11378,6 +12180,9 @@
.navbar.bg-dark {
border-color: #4d4d4d;
}
+.navbar.bg-body-secondary, .navbar.bg-body-tertiary {
+ border-color: rgba(0, 0, 0, 0.1);
+}
.btn {
border-style: solid;
@@ -11441,6 +12246,10 @@
border-color: #4d4d4d;
}
+.btn-outline-secondary {
+ color: var(--bs-tertiary-color);
+}
+
[class*=btn-outline] {
border-top-width: 1px;
}
@@ -11462,6 +12271,11 @@
color: #999;
}
+.table-secondary,
+.table-light {
+ --bs-table-color: #222;
+}
+
.form-control {
box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.075);
}
@@ -11473,16 +12287,17 @@
}
.nav-tabs .nav-link {
- color: #222;
+ color: var(--bs-body-color);
}
.nav-tabs .nav-link, .nav-tabs .nav-link.disabled, .nav-tabs .nav-link.disabled:hover, .nav-tabs .nav-link.disabled:focus {
margin-top: 6px;
- border-color: #f0f0f0;
+ border-color: var(--bs-border-color);
transition: padding-bottom 0.2s ease-in-out, margin-top 0.2s ease-in-out, border-bottom 0.2s ease-in-out;
}
.nav-tabs .nav-link:not(.disabled):hover, .nav-tabs .nav-link:not(.disabled):focus, .nav-tabs .nav-link.active {
padding-bottom: calc(0.5rem + 6px);
margin-top: 0;
+ color: var(--bs-body-color);
border-bottom-color: transparent;
}
.nav-tabs.nav-justified > li {
@@ -11497,7 +12312,7 @@
}
.breadcrumb {
- border-color: #d8d8d8;
+ border-color: var(--bs-border-color);
border-style: solid;
border-width: 0 1px 4px 1px;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/mailcow-darkmode.css b/mailcow/src/mailcow-dockerized/data/web/css/themes/mailcow-darkmode.css
index 83befea..901a6bc 100644
--- a/mailcow/src/mailcow-dockerized/data/web/css/themes/mailcow-darkmode.css
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/mailcow-darkmode.css
@@ -1,62 +1,103 @@
+/* theme tokens, override in css/themes/<name>/dark.css */
+:root {
+ --mc-body-bg: #1c1c1e;
+ --mc-body-color: #f2f2f7;
+ --mc-surface: #2c2c2e;
+ --mc-surface-alt: #282828;
+ --mc-text: #ccc;
+ --mc-text-soft: #bbb;
+ --mc-muted: #8e8e93;
+ --mc-border: #555;
+ --mc-tab-border: #444444;
+ --mc-link: #6fc7e9;
+ --mc-link-hover: #3daedb;
+ --mc-btn-bg: #5e5e5e;
+ --mc-btn-border: #4c4c4e;
+ --mc-input-bg: #424242;
+ --mc-input-color: #e2e2e2;
+ --mc-input-border: #999;
+ --mc-dropdown-bg: #424242;
+ --mc-table-bg: #3a3a3a;
+ --mc-table-stripe: #282828;
+ --mc-table-stripe-row: #424242;
+ --mc-table-hover: #343434;
+ --mc-table-border: #5c5c5c;
+ --mc-progress-bg: #555;
+ --mc-placeholder: #d4d4d4;
+ --mc-btn-outline-color: #e0e0e0;
+ --mc-btn-outline-border: #7a7a7a;
+ --mc-btn-outline-hover-bg: #5c5c5c;
+ --mc-btn-outline-active-bg: #7a7a7a;
+ --mc-btn-light-active-color: #f2f2f7;
+ --mc-btn-light-active-bg: #242424;
+ --mc-btn-light-active-border: #1c1c1e;
+ --mc-btn-dark-bg: #242424;
+ --mc-input-disabled-bg: #6e6e6e;
+ --mc-input-disabled-color: #a8a8a8;
+ --mc-list-header-bg: #444;
+ --mc-list-details-bg: #555;
+ --mc-chip-bg: #444;
+ --mc-table-child-bg: #414141;
+ --mc-dtr-bg: #7a7a7a;
+ --mc-dtr-border: #5c5c5c;
+ --mc-dtr-color: #e0e0e0;
+ --mc-dtr-hover-bg: #7a7a7a;
+ --mc-dtr-active-bg: #949494;
+}
+
body {
- background-color: #1c1c1e;
- color: #f2f2f7;
+ background-color: var(--mc-body-bg);
+ color: var(--mc-body-color);
}
.card {
- border: 1px solid #2c2c2e;
- background-color: #2c2c2e;
+ border: 1px solid var(--mc-surface);
+ background-color: var(--mc-surface);
}
legend {
- color: #f2f2f7;
+ color: var(--mc-body-color);
}
.card-header {
- color: #8e8e93;
- background-color: #1c1c1e;
+ color: var(--mc-muted);
+ background-color: var(--mc-body-bg);
border-color: transparent;
}
.card-body {
- --bs-card-color: #bbb;
+ --bs-card-color: var(--mc-text-soft);
}
.btn-secondary, .paginate_button, .page-link, .btn-light {
- color: #f2f2f7 !important;
- background-color: #5e5e5e !important;
- border-color: #4c4c4e !important;
+ color: var(--mc-body-color) !important;
+ background-color: var(--mc-btn-bg) !important;
+ border-color: var(--mc-btn-border) !important;
}
.btn-dark {
- color: #f2f2f7 !important;
- background-color: #242424 !important;
- border-color: #1c1c1e !important;
-}
-
-.btn-secondary:focus, .btn-secondary:hover, .btn-group.open .dropdown-toggle.btn-secondary {
- background-color: #444444;
- border-color: #4c4c4e !important;
- color: #f2f2f7;
+ color: var(--mc-body-color) !important;
+ background-color: var(--mc-btn-dark-bg) !important;
+ border-color: var(--mc-body-bg) !important;
}
.btn-check:checked+.btn-secondary, .btn-check:active+.btn-secondary, .btn-secondary:active, .btn-secondary.active, .show>.btn-secondary.dropdown-toggle {
- border-color: #5e5e5e !important;
+ border-color: var(--mc-btn-bg) !important;
}
.alert-secondary {
- color: #f2f2f7 !important;
- background-color: #5e5e5e !important;
- border-color: #4c4c4e !important;
+ color: var(--mc-body-color) !important;
+ background-color: var(--mc-btn-bg) !important;
+ border-color: var(--mc-btn-border) !important;
}
.bg-secondary {
- color: #f2f2f7 !important;
- background-color: #5e5e5e !important;
+ color: var(--mc-body-color) !important;
+ background-color: var(--mc-btn-bg) !important;
}
.alert-secondary, .alert-secondary a, .alert-secondary .alert-link {
- color: #f2f2f7;
+ color: var(--mc-body-color);
}
.page-item.active .page-link {
@@ -65,18 +106,18 @@
}
.btn-secondary:focus, .btn-secondary:hover, .btn-group.open .dropdown-toggle.btn-secondary {
- background-color: #5e5e5e;
- border-color: #4c4c4e !important;
- color: #f2f2f7;
+ background-color: var(--mc-btn-bg);
+ border-color: var(--mc-btn-border) !important;
+ color: var(--mc-body-color);
}
.btn-secondary:disabled, .btn-secondary.disabled {
- border-color: #5e5e5e !important;
+ border-color: var(--mc-btn-bg) !important;
}
.modal-content {
- --bs-modal-color: #bbb;
- background-color: #2c2c2e;
+ --bs-modal-color: var(--mc-text-soft);
+ background-color: var(--mc-surface);
}
.modal-header {
@@ -84,7 +125,7 @@
}
.modal-title {
- color: #bbb;
+ color: var(--mc-text-soft);
}
.modal .btn-close {
@@ -92,12 +133,12 @@
}
.navbar.bg-light {
- background-color: #1c1c1e !important;
- border-color: #2c2c2e;
+ background-color: var(--mc-body-bg) !important;
+ border-color: var(--mc-surface);
}
.nav-link {
- color: #8e8e93 !important;
+ color: var(--mc-muted) !important;
}
.nav-tabs .nav-link.active, .nav-tabs .nav-item.show .nav-link {
@@ -105,23 +146,23 @@
}
.nav-tabs, .nav-tabs .nav-link {
- border-color: #444444 !important;
+ border-color: var(--mc-tab-border) !important;
}
.nav-tabs .nav-link:not(.disabled):hover, .nav-tabs .nav-link:not(.disabled):focus, .nav-tabs .nav-link.active {
- border-bottom-color: #1c1c1e !important;
+ border-bottom-color: var(--mc-body-bg) !important;
}
.card .nav-tabs .nav-link:not(.disabled):hover, .card .nav-tabs .nav-link:not(.disabled):focus, .card .nav-tabs .nav-link.active {
- border-bottom-color: #2c2c2e !important;
+ border-bottom-color: var(--mc-surface) !important;
}
.table, .table-striped>tbody>tr:nth-of-type(odd)>*, tbody tr {
- color: #f2f2f7 !important;
+ color: var(--mc-body-color) !important;
}
.dropdown-menu {
- background-color: #424242;
+ background-color: var(--mc-dropdown-bg);
border: 1px solid #282828;
}
.dropdown-menu>li>a:focus, .dropdown-menu>li>a:hover {
@@ -132,79 +173,79 @@
color: #fff;
}
.bootstrap-select>.dropdown-toggle.bs-placeholder, .bootstrap-select>.dropdown-toggle.bs-placeholder.btn-secondary {
- color: #d4d4d4 !important;
+ color: var(--mc-placeholder) !important;
}
tbody tr {
- color: #ccc;
+ color: var(--mc-text);
}
.navbar-default .navbar-nav>.open>a, .navbar-default .navbar-nav>.open>a:focus, .navbar-default .navbar-nav>.open>a:hover {
- color: #ccc;
+ color: var(--mc-text);
}
.navbar-default .navbar-nav>.active>a, .navbar-default .navbar-nav>.active>a:focus, .navbar-default .navbar-nav>.active>a:hover {
- color: #ccc;
+ color: var(--mc-text);
}
.list-group-item {
- background-color: #282828;
- border: 1px solid #555;
+ background-color: var(--mc-surface-alt);
+ border: 1px solid var(--mc-border);
}
.table-striped>tbody>tr:nth-of-type(odd) {
- background-color: #424242;
+ background-color: var(--mc-table-stripe-row);
}
table.dataTable>tbody>tr.child ul.dtr-details>li {
border-bottom: 1px solid rgba(255, 255, 255, 0.13);
}
.label.label-last-login {
- color: #ccc !important;
+ color: var(--mc-text) !important;
background-color: #555 !important;
}
.progress {
- background-color: #555;
+ background-color: var(--mc-progress-bg);
}
.h1, .h2, .h3, .h4, .h5, .h6, h1, h2, h3, h4, h5, h6 {
- color: #ccc;
+ color: var(--mc-text);
}
div.numberedtextarea-number {
color: #999;
}
.well {
- border: 1px solid #555;
- background-color: #282828;
+ border: 1px solid var(--mc-border);
+ background-color: var(--mc-surface-alt);
}
pre {
- color: #ccc;
- background-color: #282828;
- border: 1px solid #555;
+ color: var(--mc-text);
+ background-color: var(--mc-surface-alt);
+ border: 1px solid var(--mc-border);
}
.form-control {
background-color: transparent;
}
input.form-control, textarea.form-control {
- color: #e2e2e2 !important;
- background-color: #424242 !important;
- border: 1px solid #999;
+ color: var(--mc-input-color) !important;
+ background-color: var(--mc-input-bg) !important;
+ border: 1px solid var(--mc-input-border);
}
input.form-control:focus, textarea.form-control {
- background-color: #424242 !important;
+ background-color: var(--mc-input-bg) !important;
}
input.form-control:disabled, textarea.form-disabled {
- color: #a8a8a8 !important;
- background-color: #6e6e6e !important;
+ color: var(--mc-input-disabled-color) !important;
+ background-color: var(--mc-input-disabled-bg) !important;
}
.input-group-addon {
- color: #ccc;
- background-color: #424242 !important;
- border: 1px solid #999;
+ color: var(--mc-text);
+ background-color: var(--mc-input-bg) !important;
+ border: 1px solid var(--mc-input-border);
}
.input-group-text {
- color: #ccc;
+ color: var(--mc-text);
background-color: #1c1c1c;
}
.list-group-item {
- color: #ccc;
+ color: var(--mc-text);
}
.dropdown-item {
- color: #ccc;
+ color: var(--mc-text);
}
.dropdown-item:hover {
color: #616161 !important;
@@ -214,9 +255,9 @@
background-color: #007aff;
}
.form-select {
- color: #e2e2e2!important;
- background-color: #424242!important;
- border: 1px solid #999;
+ color: var(--mc-input-color)!important;
+ background-color: var(--mc-input-bg)!important;
+ border: 1px solid var(--mc-input-border);
}
.responsive-tabs .card-header button[data-bs-toggle="collapse"] {
@@ -240,15 +281,15 @@
a {
- color: #6fc7e9;
+ color: var(--mc-link);
text-decoration: underline;
}
a:hover {
- color: #3daedb;
+ color: var(--mc-link-hover);
}
.breadcrumb-item.active {
- color: #ccc;
+ color: var(--mc-text);
}
@@ -273,11 +314,11 @@
background-color: #3a3a3a;
}
.accordion-button {
- color: #bbb;
+ color: var(--mc-text-soft);
background-color: #2c2c2c;
}
.accordion-button:not(.collapsed) {
- color: #6fc7e9;
+ color: var(--mc-link);
background-color: #2c2c2c;
}
.accordion-button::after {
@@ -300,15 +341,15 @@
}
.tag-box {
- background-color: #282828;
- border: 1px solid #555;
+ background-color: var(--mc-surface-alt);
+ border: 1px solid var(--mc-border);
}
.tag-input {
color: #fff;
- background-color: #282828;
+ background-color: var(--mc-surface-alt);
}
.tag-add {
- color: #ccc;
+ color: var(--mc-text);
}
.tag-add:hover {
color: #d1d1d1;
@@ -318,19 +359,19 @@
color: #fff;
}
.btn-outline-secondary:hover {
- background-color: #5c5c5c;
+ background-color: var(--mc-btn-outline-hover-bg);
}
.btn.btn-outline-secondary {
- color: #e0e0e0 !important;
- border-color: #7a7a7a !important;
+ color: var(--mc-btn-outline-color) !important;
+ border-color: var(--mc-btn-outline-border) !important;
}
.btn-check:checked+.btn-outline-secondary, .btn-check:active+.btn-outline-secondary, .btn-outline-secondary:active, .btn-outline-secondary.active, .btn-outline-secondary.dropdown-toggle.show {
- background-color: #7a7a7a !important;
+ background-color: var(--mc-btn-outline-active-bg) !important;
}
.btn-check:checked+.btn-light, .btn-check:active+.btn-light, .btn-light:active, .btn-light.active, .show>.btn-light.dropdown-toggle {
- color: #f2f2f7 !important;
- background-color: #242424 !important;
- border-color: #1c1c1e !important;
+ color: var(--mc-btn-light-active-color) !important;
+ background-color: var(--mc-btn-light-active-bg) !important;
+ border-color: var(--mc-btn-light-active-border) !important;
}
.btn-input-missing,
.btn-input-missing:hover,
@@ -348,16 +389,16 @@
}
.list-group-details {
- background: #555;
+ background: var(--mc-list-details-bg);
}
.list-group-header {
- background: #444;
+ background: var(--mc-list-header-bg);
}
span.mail-address-item {
- background-color: #444;
+ background-color: var(--mc-chip-bg);
border-radius: 4px;
- border: 1px solid #555;
+ border: 1px solid var(--mc-border);
padding: 2px 7px;
display: inline-block;
margin: 2px 6px 2px 0;
@@ -365,52 +406,52 @@
table.dataTable.dtr-inline.collapsed>tbody>tr>td.dtr-control:before:hover,
table.dataTable.dtr-inline.collapsed>tbody>tr>th.dtr-control:before:hover {
- background-color: #7a7a7a !important;
+ background-color: var(--mc-dtr-hover-bg) !important;
}
table.dataTable.dtr-inline.collapsed>tbody>tr>td.dtr-control:before,
table.dataTable.dtr-inline.collapsed>tbody>tr>th.dtr-control:before {
- background-color: #7a7a7a !important;
- border: 1.5px solid #5c5c5c !important;
- color: #e0e0e0 !important;
+ background-color: var(--mc-dtr-bg) !important;
+ border: 1.5px solid var(--mc-dtr-border) !important;
+ color: var(--mc-dtr-color) !important;
}
table.dataTable.dtr-inline.collapsed>tbody>tr.parent>td.dtr-control:before,
table.dataTable.dtr-inline.collapsed>tbody>tr.parent>th.dtr-control:before {
- background-color: #949494;
+ background-color: var(--mc-dtr-active-bg);
}
table.dataTable.dtr-inline.collapsed>tbody>tr>td.child,
table.dataTable.dtr-inline.collapsed>tbody>tr>th.child,
table.dataTable.dtr-inline.collapsed>tbody>tr>td.dataTables_empty {
- background-color: #414141;
+ background-color: var(--mc-table-child-bg);
}
table.table, .table-striped>tbody>tr:nth-of-type(odd)>*, tbody tr {
- color: #ccc !important;
+ color: var(--mc-text) !important;
}
.table-secondary {
--bs-table-bg: #282828;
--bs-table-striped-bg: #343434;
- --bs-table-striped-color: #f2f2f7;
+ --bs-table-striped-color: var(--mc-body-color);
--bs-table-active-bg: #4c4c4c;
- --bs-table-active-color: #f2f2f7;
+ --bs-table-active-color: var(--mc-body-color);
--bs-table-hover-bg: #3a3a3a;
- --bs-table-hover-color: #f2f2f7;
- color: #ccc;
+ --bs-table-hover-color: var(--mc-body-color);
+ color: var(--mc-text);
border-color: #3a3a3a;
}
.table-light {
--bs-table-bg: #3a3a3a;
--bs-table-striped-bg: #444444;
- --bs-table-striped-color: #f2f2f7;
+ --bs-table-striped-color: var(--mc-body-color);
--bs-table-active-bg: #5c5c5c;
- --bs-table-active-color: #f2f2f7;
+ --bs-table-active-color: var(--mc-body-color);
--bs-table-hover-bg: #4c4c4c;
- --bs-table-hover-color: #f2f2f7;
- color: #ccc;
+ --bs-table-hover-color: var(--mc-body-color);
+ color: var(--mc-text);
border-color: #4c4c4c;
}
@@ -430,23 +471,23 @@
.table-striped>tbody>tr:nth-of-type(odd)>td,
.table-striped>tbody>tr:nth-of-type(odd)>th {
- background-color: #282828;
+ background-color: var(--mc-table-stripe);
}
.table-hover>tbody>tr:hover {
- background-color: #343434;
+ background-color: var(--mc-table-hover);
}
.table>:not(caption)>*>* {
- border-color: #5c5c5c;
- --bs-table-color-state:#bbb;
- --bs-table-bg: #3a3a3a;
+ border-color: var(--mc-table-border);
+ --bs-table-color-state:var(--mc-text-soft);
+ --bs-table-bg: var(--mc-table-bg);
}
.text-muted {
- --bs-secondary-color: #8e8e93;
+ --bs-secondary-color: var(--mc-muted);
}
input::placeholder {
- color: #8e8e93 !important;
+ color: var(--mc-muted) !important;
}
.form-select {
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/dark.css b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/dark.css
new file mode 100644
index 0000000..5694350
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/dark.css
@@ -0,0 +1,212 @@
+/* servercow theme, dark mode, bundled after mailcow core dark mode */
+
+:root {
+ --sc-brown-hover: #806b55;
+ --sc-brown-active: #8a745c;
+ --sc-brown-soft: rgba(201, 180, 154, .18);
+ --sc-brown-tint: rgba(201, 180, 154, .08);
+ --sc-link: #c9b49a;
+ --sc-danger-text: #ff8a8a;
+ --sc-ink: #ece7e1;
+ --sc-muted: #a89f94;
+ --sc-placeholder: #8a8177;
+ --sc-bg: #171513;
+ --sc-surface: #211e1b;
+ --sc-cap: #2a2622;
+ --sc-addon: #2a2622;
+ --sc-line: #463f38;
+ --sc-divider: #34302b;
+ --sc-cap-line: #3d3732;
+ --sc-stripe: rgba(255, 255, 255, .025);
+ --sc-hover: rgba(201, 180, 154, .08);
+ --sc-focus-border: #8a7864;
+ --sc-focus: rgba(201, 180, 154, .25);
+ --sc-shadow: 0 0 10px 0 rgba(0, 0, 0, .5);
+ --bs-body-color: #ece7e1;
+ --bs-body-bg: #171513;
+ /* core dark tokens, see css/themes/mailcow-darkmode.css */
+ --mc-body-bg: var(--sc-bg);
+ --mc-body-color: var(--sc-ink);
+ --mc-surface: var(--sc-surface);
+ --mc-surface-alt: var(--sc-cap);
+ --mc-text: var(--sc-ink);
+ --mc-text-soft: var(--sc-ink);
+ --mc-muted: var(--sc-muted);
+ --mc-border: var(--sc-divider);
+ --mc-tab-border: var(--sc-divider);
+ --mc-link: var(--sc-link);
+ --mc-link-hover: #e0cfba;
+ --mc-btn-bg: var(--sc-cap);
+ --mc-btn-border: var(--sc-line);
+ --mc-input-bg: var(--sc-bg);
+ --mc-input-color: var(--sc-ink);
+ --mc-input-border: var(--sc-line);
+ --mc-dropdown-bg: var(--sc-surface);
+ --mc-table-bg: transparent;
+ --mc-table-stripe: var(--sc-stripe);
+ --mc-table-stripe-row: transparent;
+ --mc-table-hover: var(--sc-hover);
+ --mc-table-border: var(--sc-divider);
+ --mc-progress-bg: var(--sc-cap);
+ --mc-placeholder: var(--sc-placeholder);
+ --mc-hr: var(--sc-divider);
+ --mc-btn-outline-color: var(--sc-ink);
+ --mc-btn-outline-border: var(--sc-line);
+ --mc-btn-outline-hover-bg: var(--sc-brown-tint);
+ --mc-btn-outline-active-bg: var(--sc-brown);
+ --mc-btn-light-active-color: #fff;
+ --mc-btn-light-active-bg: var(--sc-brown);
+ --mc-btn-light-active-border: var(--sc-brown);
+ --mc-btn-dark-bg: var(--sc-brown);
+ --mc-input-disabled-bg: var(--sc-cap);
+ --mc-input-disabled-color: var(--sc-muted);
+ --mc-list-header-bg: var(--sc-cap);
+ --mc-list-details-bg: var(--sc-surface);
+ --mc-chip-bg: var(--sc-cap);
+ --mc-table-child-bg: var(--sc-surface);
+ --mc-dtr-bg: var(--sc-cap);
+ --mc-dtr-border: var(--sc-line);
+ --mc-dtr-color: var(--sc-link);
+ --mc-dtr-hover-bg: var(--sc-hover);
+ --mc-dtr-active-bg: var(--sc-brown-soft);
+}
+
+/* navbar */
+.navbar.bg-light {
+ background-color: var(--sc-surface) !important;
+ border-bottom-color: var(--sc-green);
+}
+.navbar-light .navbar-nav .nav-link {
+ color: var(--sc-ink) !important;
+}
+.navbar-light .navbar-nav .nav-link:hover,
+.navbar-light .navbar-nav .nav-link:focus,
+.navbar-light .navbar-nav .nav-link.active,
+.navbar-light .navbar-nav .show > .nav-link {
+ color: var(--sc-link) !important;
+}
+.dropdown-menu {
+ border-color: var(--sc-cap-line);
+}
+.dropdown-item:hover, .dropdown-item:focus {
+ color: var(--sc-link) !important;
+}
+
+/* cards and modals */
+.card-header {
+ color: var(--sc-ink);
+ background-color: var(--sc-cap);
+ border-color: var(--sc-cap-line);
+}
+.modal-content {
+ background-color: var(--sc-surface);
+}
+.modal-header {
+ border-color: var(--sc-cap-line);
+}
+.input-group-text {
+ background-color: var(--sc-addon);
+}
+.form-control::file-selector-button {
+ color: var(--sc-ink);
+ background-color: var(--sc-cap);
+ border-color: var(--sc-line);
+}
+.form-control:hover:not(:disabled):not([readonly])::file-selector-button {
+ color: var(--sc-link);
+ background-color: var(--sc-line);
+}
+.form-check-input:not(:checked) {
+ background-color: var(--sc-bg);
+ border-color: var(--sc-line);
+}
+kbd {
+ color: var(--sc-ink);
+ background-color: var(--sc-cap);
+}
+
+/* buttons */
+.btn-secondary:hover, .btn-secondary:focus, .btn-light:hover, .btn-light:focus, .page-link:hover {
+ color: var(--sc-link) !important;
+ background-color: var(--sc-line) !important;
+}
+.btn-check:checked + .btn-secondary, .btn-secondary.active, .show > .btn-secondary.dropdown-toggle,
+.page-item.active .page-link {
+ color: #fff !important;
+ background-color: var(--sc-brown) !important;
+ border-color: var(--sc-brown) !important;
+}
+
+/* tabs */
+.nav-tabs .nav-link {
+ color: var(--sc-ink) !important;
+ border-bottom-color: transparent !important;
+}
+.nav-tabs .nav-link:not(.disabled):hover, .nav-tabs .nav-link:not(.disabled):focus,
+.card .nav-tabs .nav-link:not(.disabled):hover, .card .nav-tabs .nav-link:not(.disabled):focus {
+ color: var(--sc-link) !important;
+ border-bottom-color: transparent !important;
+}
+.nav-tabs .nav-link.active, .card .nav-tabs .nav-link.active {
+ color: var(--sc-link) !important;
+ border-bottom-color: var(--sc-link) !important;
+}
+
+/* semantic text */
+.text-success {
+ color: var(--sc-green) !important;
+}
+.text-warning {
+ color: var(--sc-warning) !important;
+}
+
+/* alerts, opaque dark tints (also used for floating notifications) */
+.alert-primary {
+ color: #e6d9c9 !important;
+ background-color: #3c342b !important;
+ border-color: #5e4f3e !important;
+}
+.alert-info {
+ color: #cfe9f6 !important;
+ background-color: #2f3334 !important;
+ border-color: #44535a !important;
+}
+.alert-success {
+ color: #cdeea0;
+ background-color: #2e3419;
+ border-color: #405515;
+}
+.alert-danger {
+ color: #f9c4c4;
+ background-color: #402a28;
+ border-color: #693a38;
+}
+.alert-warning {
+ color: #f5d496;
+ background-color: #3c2f19;
+ border-color: #654815;
+}
+.alert-secondary, .alert-light {
+ color: var(--sc-ink) !important;
+ background-color: var(--sc-cap) !important;
+ border-color: var(--sc-divider) !important;
+}
+
+.alert .btn-close {
+ filter: invert(1) grayscale(100%) brightness(200%);
+}
+
+/* slider */
+.noUi-target {
+ background: var(--sc-bg);
+ border-color: var(--sc-line);
+ box-shadow: none;
+}
+.noUi-handle {
+ background: var(--sc-cap);
+ border-color: var(--sc-line);
+ box-shadow: none;
+}
+.noUi-handle::before, .noUi-handle::after {
+ background: var(--sc-line);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/LICENSE-RobotoSlab.txt b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/LICENSE-RobotoSlab.txt
new file mode 100644
index 0000000..d645695
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/LICENSE-RobotoSlab.txt
@@ -0,0 +1,202 @@
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/OFL-Poppins.txt b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/OFL-Poppins.txt
new file mode 100644
index 0000000..76df3b5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/OFL-Poppins.txt
@@ -0,0 +1,93 @@
+Copyright 2020 The Poppins Project Authors (https://github.com/itfoundry/Poppins)
+
+This Font Software is licensed under the SIL Open Font License, Version 1.1.
+This license is copied below, and is also available with a FAQ at:
+http://scripts.sil.org/OFL
+
+
+-----------------------------------------------------------
+SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
+-----------------------------------------------------------
+
+PREAMBLE
+The goals of the Open Font License (OFL) are to stimulate worldwide
+development of collaborative font projects, to support the font creation
+efforts of academic and linguistic communities, and to provide a free and
+open framework in which fonts may be shared and improved in partnership
+with others.
+
+The OFL allows the licensed fonts to be used, studied, modified and
+redistributed freely as long as they are not sold by themselves. The
+fonts, including any derivative works, can be bundled, embedded,
+redistributed and/or sold with any software provided that any reserved
+names are not used by derivative works. The fonts and derivatives,
+however, cannot be released under any other type of license. The
+requirement for fonts to remain under this license does not apply
+to any document created using the fonts or their derivatives.
+
+DEFINITIONS
+"Font Software" refers to the set of files released by the Copyright
+Holder(s) under this license and clearly marked as such. This may
+include source files, build scripts and documentation.
+
+"Reserved Font Name" refers to any names specified as such after the
+copyright statement(s).
+
+"Original Version" refers to the collection of Font Software components as
+distributed by the Copyright Holder(s).
+
+"Modified Version" refers to any derivative made by adding to, deleting,
+or substituting -- in part or in whole -- any of the components of the
+Original Version, by changing formats or by porting the Font Software to a
+new environment.
+
+"Author" refers to any designer, engineer, programmer, technical
+writer or other person who contributed to the Font Software.
+
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of the Font Software, to use, study, copy, merge, embed, modify,
+redistribute, and sell modified and unmodified copies of the Font
+Software, subject to the following conditions:
+
+1) Neither the Font Software nor any of its individual components,
+in Original or Modified Versions, may be sold by itself.
+
+2) Original or Modified Versions of the Font Software may be bundled,
+redistributed and/or sold with any software, provided that each copy
+contains the above copyright notice and this license. These can be
+included either as stand-alone text files, human-readable headers or
+in the appropriate machine-readable metadata fields within text or
+binary files as long as those fields can be easily viewed by the user.
+
+3) No Modified Version of the Font Software may use the Reserved Font
+Name(s) unless explicit written permission is granted by the corresponding
+Copyright Holder. This restriction only applies to the primary font name as
+presented to the users.
+
+4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
+Software shall not be used to promote, endorse or advertise any
+Modified Version, except to acknowledge the contribution(s) of the
+Copyright Holder(s) and the Author(s) or with their explicit written
+permission.
+
+5) The Font Software, modified or unmodified, in part or in whole,
+must be distributed entirely under this license, and must not be
+distributed under any other license. The requirement for fonts to
+remain under this license does not apply to any document created
+using the Font Software.
+
+TERMINATION
+This license becomes null and void if any of the above conditions are
+not met.
+
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
+OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
+COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
+DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
+OTHER DEALINGS IN THE FONT SOFTWARE.
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff
new file mode 100644
index 0000000..fc6d5c7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff2 b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff2
new file mode 100644
index 0000000..abfe991
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff2
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff
new file mode 100644
index 0000000..08368fc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff2 b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff2
new file mode 100644
index 0000000..068762f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff2
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff
new file mode 100644
index 0000000..86fbadd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff2 b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff2
new file mode 100644
index 0000000..981bdb3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff2
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff
new file mode 100644
index 0000000..b925aa3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff2 b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff2
new file mode 100644
index 0000000..d83f92c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff2
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff
new file mode 100644
index 0000000..8621fd6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff2 b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff2
new file mode 100644
index 0000000..2e40973
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff2
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff
new file mode 100644
index 0000000..8c8b94f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff2 b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff2
new file mode 100644
index 0000000..f55bf37
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff2
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/theme.css b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/theme.css
new file mode 100644
index 0000000..14bcecd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/theme.css
@@ -0,0 +1,584 @@
+/* servercow theme for mailcow, based on the servercow customer portal */
+
+@font-face {
+ font-family: 'Poppins';
+ font-style: normal;
+ font-weight: 400;
+ font-display: swap;
+ src: local(''),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff2') format('woff2'),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-regular.woff') format('woff');
+}
+@font-face {
+ font-family: 'Poppins';
+ font-style: italic;
+ font-weight: 400;
+ font-display: swap;
+ src: local(''),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff2') format('woff2'),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-italic.woff') format('woff');
+}
+@font-face {
+ font-family: 'Poppins';
+ font-style: normal;
+ font-weight: 500;
+ font-display: swap;
+ src: local(''),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff2') format('woff2'),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-500.woff') format('woff');
+}
+@font-face {
+ font-family: 'Poppins';
+ font-style: normal;
+ font-weight: 600;
+ font-display: swap;
+ src: local(''),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff2') format('woff2'),
+ url('/css/themes/servercow/fonts/poppins-v24-latin_latin-ext-600.woff') format('woff');
+}
+@font-face {
+ font-family: 'Roboto Slab';
+ font-style: normal;
+ font-weight: 400;
+ font-display: swap;
+ src: local(''),
+ url('/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff2') format('woff2'),
+ url('/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-regular.woff') format('woff');
+}
+@font-face {
+ font-family: 'Roboto Slab';
+ font-style: normal;
+ font-weight: 500;
+ font-display: swap;
+ src: local(''),
+ url('/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff2') format('woff2'),
+ url('/css/themes/servercow/fonts/roboto-slab-v36-cyrillic_greek_latin-500.woff') format('woff');
+}
+
+/* tokens */
+:root {
+ --sc-brown: #6F5D49;
+ --sc-brown-hover: #5e4f3e;
+ --sc-brown-active: #594a3a;
+ --sc-brown-soft: rgba(111, 93, 73, .2);
+ --sc-brown-tint: rgba(111, 93, 73, .08);
+ --sc-link: #6F5D49;
+ --sc-green: #8AD608;
+ --sc-blue: #96D0EC;
+ --sc-warning: #e3950b;
+ --sc-danger: #ef6f6f;
+ --sc-danger-hover: #e85e5e;
+ --sc-danger-text: #c43c3c;
+ --sc-ink: #212529;
+ --sc-muted: #6c757d;
+ --sc-placeholder: #6c757d;
+ --sc-bg: #F6F8F8;
+ --sc-surface: #ffffff;
+ --sc-cap: #f7f7f7;
+ --sc-addon: #e9ecef;
+ --sc-line: #ced4da;
+ --sc-divider: #dee2e6;
+ --sc-cap-line: rgba(0, 0, 0, .175);
+ --sc-stripe: rgba(111, 93, 73, .04);
+ --sc-hover: rgba(111, 93, 73, .08);
+ --sc-focus-border: #b7aea4;
+ --sc-focus: rgba(111, 93, 73, .25);
+ --sc-shadow: 0 0 10px 0 rgba(134, 134, 134, .3);
+ --sc-font: 'Poppins', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
+ --sc-font-head: 'Roboto Slab', Georgia, serif;
+ --bs-body-color: #212529;
+ --bs-body-bg: #F6F8F8;
+ --bs-body-font-family: var(--sc-font);
+ /* core tokens, see css/build/014-mailcow.css */
+ --mc-font-family: var(--sc-font);
+ --mc-font-size: 10pt;
+ --mc-body-bg: var(--sc-bg);
+ --mc-primary: var(--sc-brown);
+ --mc-primary-border: var(--sc-brown);
+ --mc-info: var(--sc-blue);
+ --mc-info-border: var(--sc-blue);
+ --mc-border: var(--sc-divider);
+ --mc-surface: var(--sc-surface);
+ --mc-surface-alt: var(--sc-cap);
+ --mc-muted: var(--sc-muted);
+ --mc-hr: var(--sc-divider);
+ --mc-progress-bg: var(--sc-addon);
+ --mc-placeholder: var(--sc-placeholder);
+ --mc-btn-outline-color: var(--sc-ink);
+ --mc-btn-outline-border: var(--sc-line);
+ --mc-btn-outline-hover-bg: var(--sc-brown-tint);
+ --mc-btn-outline-active-bg: var(--sc-brown);
+ --mc-btn-light-active-color: #fff;
+ --mc-btn-light-active-bg: var(--sc-brown);
+ --mc-btn-light-active-border: var(--sc-brown);
+ --mc-dtr-bg: var(--sc-surface);
+ --mc-dtr-border: var(--sc-line);
+ --mc-dtr-color: var(--sc-brown);
+ --mc-dtr-hover-bg: var(--sc-brown-tint);
+ --mc-dtr-active-bg: var(--sc-brown-soft);
+ --mc-login-user: var(--sc-green);
+ --mc-login-domainadmin: #f5c400;
+ --mc-login-admin: var(--sc-danger);
+}
+
+/* base */
+body {
+ color: var(--sc-ink);
+ -webkit-font-smoothing: antialiased;
+}
+h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6, legend, .modal-title {
+ font-family: var(--sc-font-head);
+ font-weight: 500;
+ color: var(--sc-ink);
+}
+a {
+ color: var(--sc-link);
+}
+a:hover {
+ color: var(--sc-brown-hover);
+}
+.text-muted, .text-secondary {
+ color: var(--sc-muted) !important;
+}
+::selection {
+ background: var(--sc-brown-soft);
+}
+hr {
+ border-color: var(--sc-divider);
+ opacity: 1;
+}
+::placeholder {
+ color: var(--sc-placeholder) !important;
+}
+
+/* navbar, white with green line */
+.navbar.bg-light {
+ background-color: var(--sc-surface) !important;
+ border: 0;
+ border-bottom: 5px solid var(--sc-green);
+}
+.navbar-light .navbar-nav .nav-link {
+ color: var(--sc-ink);
+}
+.navbar-light .navbar-nav .nav-link:hover,
+.navbar-light .navbar-nav .nav-link:focus,
+.navbar-light .navbar-nav .nav-link.active,
+.navbar-light .navbar-nav .show > .nav-link {
+ color: var(--sc-brown);
+}
+@media (min-width: 992px) {
+ .navbar-nav .nav-link {
+ height: 60px;
+ }
+}
+.dropdown-menu {
+ border: 1px solid var(--sc-cap-line);
+ border-radius: 0;
+ box-shadow: var(--sc-shadow);
+}
+.dropdown-item {
+ color: var(--sc-ink);
+}
+.dropdown-item:hover, .dropdown-item:focus {
+ color: var(--sc-brown) !important;
+ background-color: var(--sc-brown-soft);
+}
+.dropdown-item.active, .dropdown-item:active {
+ color: #fff;
+ background-color: var(--sc-brown);
+}
+
+/* cards, white with soft shadow */
+.card {
+ border: 0 !important;
+ border-radius: 0;
+ background-color: var(--sc-surface);
+ box-shadow: var(--sc-shadow);
+}
+.card-header, .card-header:first-child {
+ font-family: var(--sc-font-head);
+ font-weight: 500;
+ font-size: 1.1rem;
+ color: var(--sc-ink);
+ background-color: var(--sc-cap);
+ border-bottom: 1px solid var(--sc-cap-line);
+ border-radius: 0;
+ padding: .5rem 1rem;
+}
+.card-header .btn, .card-header .form-control, .card-header .form-select {
+ font-family: var(--sc-font);
+ font-size: .875rem;
+}
+.card-footer {
+ background-color: var(--sc-cap);
+ border-top: 1px solid var(--sc-cap-line);
+ border-radius: 0;
+}
+.card .card {
+ box-shadow: none;
+ border: 1px solid var(--sc-divider) !important;
+}
+/* colored headers become a top line */
+.card:has(> .card-header.bg-danger) {
+ border-top: 4px solid var(--sc-danger) !important;
+}
+.card-header.bg-danger, .card-header.bg-success, .card-header.bg-primary, .card-header.bg-info {
+ color: var(--sc-ink) !important;
+ background-color: var(--sc-cap) !important;
+}
+.list-group-item {
+ border-color: var(--sc-divider);
+}
+
+/* modals */
+.modal-content {
+ border: 0;
+ border-radius: 0;
+ box-shadow: 0 8px 40px rgba(0, 0, 0, .2);
+}
+.modal-header {
+ background-color: var(--sc-cap);
+ border-bottom: 1px solid var(--sc-cap-line);
+ border-radius: 0;
+}
+.modal-footer {
+ border-top: 1px solid var(--sc-divider);
+}
+
+/* buttons, flat and square */
+.btn {
+ border-width: 1px;
+ border-radius: 0;
+ font-weight: 400;
+ transition: none;
+}
+.btn:not(.disabled):hover,
+.btn:not(.disabled):active {
+ margin-top: 0;
+ border-bottom-width: 1px;
+}
+.btn:focus, .btn-check:focus + .btn {
+ box-shadow: 0 0 0 .2rem var(--sc-focus);
+}
+.btn-primary, .btn-primary:hover, .btn-primary:focus, .btn-primary:active {
+ color: #fff;
+}
+.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
+ background-color: var(--sc-brown-hover) !important;
+ border-color: var(--sc-brown-active) !important;
+}
+/* main call to action, portal primary */
+.btn-success, .btn-success:not(.disabled):hover, .btn-success:not(.disabled):active, .btn-success:focus,
+.btn-success:disabled, .btn-success.disabled {
+ color: #fff;
+ background-color: var(--sc-brown);
+ border-color: var(--sc-brown);
+}
+.btn-success:hover, .btn-success:active, .btn-success:focus {
+ background-color: var(--sc-brown-hover);
+ border-color: var(--sc-brown-active);
+}
+.btn-danger, .btn-danger:not(.disabled):hover, .btn-danger:not(.disabled):active, .btn-danger:focus,
+.btn-danger:disabled, .btn-danger.disabled {
+ color: #000;
+ background-color: var(--sc-danger);
+ border-color: var(--sc-danger);
+}
+.btn-danger:hover, .btn-danger:active, .btn-danger:focus {
+ background-color: var(--sc-danger-hover);
+ border-color: var(--sc-danger-hover);
+}
+.btn-warning, .btn-warning:not(.disabled):hover, .btn-warning:not(.disabled):active, .btn-warning:focus {
+ color: #000;
+ background-color: var(--sc-warning);
+ border-color: var(--sc-warning);
+}
+.bg-info, .alert-info, .btn-info, .badge.bg-info > a {
+ color: #000 !important;
+}
+.btn-secondary, .btn-secondary:not(.disabled):hover, .btn-secondary:not(.disabled):active, .btn-secondary:focus,
+.btn-light, .btn-light:not(.disabled):hover, .btn-light:not(.disabled):active, .btn-light:focus {
+ color: var(--sc-ink);
+ background-color: var(--sc-surface);
+ border-color: var(--sc-line);
+}
+.btn-secondary:hover, .btn-secondary:active, .btn-secondary:focus,
+.btn-light:hover, .btn-light:focus {
+ color: var(--sc-brown);
+ background-color: var(--sc-brown-tint);
+ border-color: var(--sc-line);
+}
+.btn-check:checked + .btn-secondary, .btn-secondary.active, .show > .btn-secondary.dropdown-toggle {
+ color: #fff;
+ background-color: var(--sc-brown);
+ border-color: var(--sc-brown);
+}
+.btn-check:checked + .btn-outline-secondary, .btn-outline-secondary.active {
+ color: #fff !important;
+ border-color: var(--sc-brown) !important;
+}
+.btn-outline-primary {
+ color: var(--sc-brown);
+ border-color: var(--sc-brown);
+}
+.btn-outline-primary:hover {
+ color: #fff;
+ background-color: var(--sc-brown);
+ border-color: var(--sc-brown);
+}
+/* active toggle, e.g. tagging options */
+.btn-dark, .btn-dark:hover, .btn-dark:focus, .btn-dark:active {
+ color: #fff;
+ background-color: var(--sc-brown);
+ border-color: var(--sc-brown);
+}
+.btn-xs, .btn-group-xs > .btn {
+ border-radius: 0;
+}
+
+/* forms */
+.form-control, .form-select {
+ border-color: var(--sc-line);
+ border-radius: 0;
+ box-shadow: none;
+ color: var(--sc-ink);
+ background-color: var(--sc-surface);
+}
+.form-control:focus, .form-select:focus {
+ border-color: var(--sc-focus-border);
+ box-shadow: 0 0 0 .25rem var(--sc-focus);
+}
+.form-control::file-selector-button {
+ color: var(--sc-ink);
+ background-color: var(--sc-addon);
+ border-color: var(--sc-line);
+}
+.form-control:hover:not(:disabled):not([readonly])::file-selector-button {
+ color: var(--sc-brown);
+ background-color: var(--sc-brown-soft);
+}
+.input-group-text {
+ color: var(--sc-ink);
+ background-color: var(--sc-addon);
+ border-color: var(--sc-line);
+ border-radius: 0;
+}
+.input-group > :not(:first-child), .input-group > :not(:last-child) {
+ border-radius: 0;
+}
+.form-check-input {
+ border-color: var(--sc-line);
+}
+.form-check-input:checked {
+ background-color: var(--sc-brown);
+ border-color: var(--sc-brown);
+}
+.form-check-input:focus {
+ border-color: var(--sc-focus-border);
+ box-shadow: 0 0 0 .25rem var(--sc-focus);
+}
+.bootstrap-select > .dropdown-toggle {
+ border-radius: 0;
+}
+.bootstrap-select > .dropdown-toggle.bs-placeholder,
+.bootstrap-select > .dropdown-toggle.bs-placeholder:hover,
+.bootstrap-select > .dropdown-toggle.bs-placeholder:focus,
+.bootstrap-select > .dropdown-toggle.bs-placeholder:active {
+ color: var(--mc-placeholder);
+}
+.bootstrap-select .dropdown-menu li a.active, .bootstrap-select .dropdown-menu li a:active {
+ color: #fff;
+ background-color: var(--sc-brown);
+}
+div.numberedtextarea-number {
+ color: var(--sc-muted);
+}
+
+/* nav tabs */
+.nav-tabs {
+ border-bottom: 1px solid var(--sc-divider);
+}
+.nav-tabs .nav-link,
+.nav-tabs .nav-link.disabled, .nav-tabs .nav-link.disabled:hover, .nav-tabs .nav-link.disabled:focus {
+ margin-top: 0;
+ color: var(--sc-ink);
+ border: 0;
+ border-bottom: 3px solid transparent;
+ border-radius: 0;
+ background: none;
+}
+.nav-tabs .nav-link:not(.disabled):hover, .nav-tabs .nav-link:not(.disabled):focus {
+ padding-bottom: .5rem;
+ color: var(--sc-brown);
+}
+.nav-tabs .nav-link.active, .nav-tabs .nav-item.show .nav-link,
+.nav-tabs .nav-link:not(.disabled).active {
+ padding-bottom: .5rem;
+ color: var(--sc-brown);
+ background: none;
+ border-bottom: 3px solid var(--sc-brown);
+}
+.nav-pills .nav-link {
+ border-radius: 0;
+ color: var(--sc-ink);
+}
+.nav-pills .nav-link.active, .nav-pills .show > .nav-link {
+ background-color: var(--sc-brown);
+}
+
+/* tables */
+.table {
+ --bs-table-bg: transparent;
+ --bs-table-striped-bg: var(--sc-stripe);
+ --bs-table-striped-color: var(--sc-ink);
+ --bs-table-hover-color: var(--sc-ink);
+ --bs-table-hover-bg: var(--sc-hover);
+ color: var(--sc-ink);
+ border-color: var(--sc-divider);
+}
+.table > thead > tr > th, table.dataTable thead th {
+ color: var(--sc-ink);
+ font-weight: 600;
+ border-bottom: 1px solid var(--sc-line);
+}
+table.dataTable.table-striped > tbody > tr.odd > * {
+ box-shadow: inset 0 0 0 9999px var(--sc-stripe);
+}
+table.dataTable.table-hover > tbody > tr:hover > * {
+ box-shadow: inset 0 0 0 9999px var(--sc-hover);
+}
+.table > :not(:first-child) {
+ border-top: 0;
+}
+.dataTables_wrapper .dataTables_filter input,
+.dataTables_wrapper .dataTables_length select {
+ border: 1px solid var(--sc-line);
+ border-radius: 0;
+}
+.pagination > li > a, .pagination > li > span, .pagination .page-link,
+.pagination > li > a:hover, .pagination > li > a:focus, .pagination > li > a:active {
+ top: 0;
+ color: var(--sc-brown);
+ font-weight: 400;
+ text-transform: none;
+ background-color: var(--sc-surface);
+ border: 1px solid var(--sc-divider);
+ border-radius: 0 !important;
+}
+.pagination > li > a:hover, .pagination > li > a:focus {
+ background-color: var(--sc-brown-tint);
+}
+.pagination > .disabled > a, .pagination > .disabled > a:hover, .pagination > .disabled > a:active,
+.page-item.disabled .page-link {
+ color: var(--sc-muted);
+ background-color: var(--sc-surface);
+ border-width: 1px;
+ border-color: var(--sc-divider);
+}
+.page-item.active .page-link {
+ color: #fff;
+ background-color: var(--sc-brown);
+ border-color: var(--sc-brown);
+}
+.breadcrumb {
+ border: 1px solid var(--sc-divider);
+ border-radius: 0;
+}
+
+/* alerts like the portal */
+.alert {
+ border: 1px solid;
+ border-radius: 0;
+}
+.alert-primary {
+ color: #43382c !important;
+ background-color: #e2dfdb !important;
+ border-color: #d4cec8 !important;
+}
+.alert-info {
+ color: #3c535e !important;
+ background-color: #eaf6fb !important;
+ border-color: #e0f1f9 !important;
+}
+.alert-success {
+ color: #375603;
+ background-color: #e8f7ce;
+ border-color: #dcf3b5;
+}
+.alert-danger {
+ color: #8f4343;
+ background-color: #fce2e2;
+ border-color: #fad4d4;
+}
+.alert-warning {
+ color: #885907;
+ background-color: #f9eace;
+ border-color: #f7dfb6;
+}
+.alert-secondary, .alert-light {
+ color: var(--sc-ink);
+ background-color: var(--sc-cap);
+ border-color: var(--sc-divider);
+}
+.alert .alert-link {
+ color: inherit;
+}
+.alert .btn-close {
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3e%3cpath d='M.293.293a1 1 0 0 1 1.414 0L8 6.586 14.293.293a1 1 0 1 1 1.414 1.414L9.414 8l6.293 6.293a1 1 0 0 1-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 0 1-1.414-1.414L6.586 8 .293 1.707a1 1 0 0 1 0-1.414z'/%3e%3c/svg%3e");
+ opacity: .5;
+}
+
+/* badges and semantic colors, readable text on top */
+.badge {
+ font-weight: 500;
+ border-radius: 0;
+}
+.bg-success {
+ color: #000 !important;
+ background-color: var(--sc-green) !important;
+}
+.bg-warning {
+ color: #000 !important;
+ background-color: var(--sc-warning) !important;
+}
+.bg-danger {
+ color: #000 !important;
+ background-color: var(--sc-danger) !important;
+}
+.badge.bg-secondary, .badge.bg-light {
+ color: var(--sc-ink);
+ background-color: var(--sc-addon) !important;
+}
+.text-success {
+ color: #4f8a0b !important;
+}
+.text-danger {
+ color: var(--sc-danger-text) !important;
+}
+.text-warning {
+ color: #9a6100 !important;
+}
+.progress {
+ border-radius: 0;
+}
+.progress-bar {
+ color: #000;
+ background-color: var(--sc-green);
+}
+.progress-bar.bg-danger, .progress-bar-danger {
+ color: #000;
+ background-color: var(--sc-danger) !important;
+}
+.progress-bar-warning {
+ color: #000;
+ background-color: var(--sc-warning) !important;
+}
+
+
+/* footer */
+.footer, .footer a {
+ color: var(--sc-muted);
+}
+.footer hr {
+ border-color: var(--sc-divider);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/theme.json b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/theme.json
new file mode 100644
index 0000000..2c8f041
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/css/themes/servercow/theme.json
@@ -0,0 +1,4 @@
+{
+ "name": "servercow",
+ "description": "Based on the servercow theme"
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/debug.php b/mailcow/src/mailcow-dockerized/data/web/debug.php
deleted file mode 100644
index 9c33800..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/debug.php
+++ /dev/null
@@ -1,80 +0,0 @@
-<?php
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
-
-if (!isset($_SESSION['mailcow_cc_role']) || $_SESSION['mailcow_cc_role'] != "admin") {
- header('Location: /');
- exit();
-}
-
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
-$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
-$solr_status = (preg_match("/^([yY][eE][sS]|[yY])+$/", $_ENV["SKIP_SOLR"])) ? false : solr_status();
-$clamd_status = (preg_match("/^([yY][eE][sS]|[yY])+$/", $_ENV["SKIP_CLAMD"])) ? false : true;
-
-
-if (!isset($_SESSION['gal']) && $license_cache = $redis->Get('LICENSE_STATUS_CACHE')) {
- $_SESSION['gal'] = json_decode($license_cache, true);
-}
-
-$js_minifier->add('/web/js/site/debug.js');
-
-// vmail df
-$exec_fields = array('cmd' => 'system', 'task' => 'df', 'dir' => '/var/vmail');
-$vmail_df = explode(',', (string)json_decode(docker('post', 'dovecot-mailcow', 'exec', $exec_fields), true));
-
-// containers
-$containers = (array) docker('info');
-if ($clamd_status === false) unset($containers['clamd-mailcow']);
-if ($solr_status === false) unset($containers['solr-mailcow']);
-ksort($containers);
-foreach ($containers as $container => $container_info) {
- date_default_timezone_set('UTC');
- $StartedAt = date_parse($container_info['State']['StartedAt']);
- if ($StartedAt['hour'] !== false) {
- $date = new \DateTime();
- $date->setTimestamp(mktime(
- $StartedAt['hour'],
- $StartedAt['minute'],
- $StartedAt['second'],
- $StartedAt['month'],
- $StartedAt['day'],
- $StartedAt['year']));
- try {
- $user_tz = new DateTimeZone(getenv('TZ'));
- $date->setTimezone($user_tz);
- $started = $date->format('r');
- } catch(Exception $e) {
- $started = '?';
- }
- }
- else {
- $started = '?';
- }
- $containers[$container]['State']['StartedAtHR'] = $started;
-}
-
-// get mailcow data
-$hostname = getenv('MAILCOW_HOSTNAME');
-$timezone = getenv('TZ');
-
-$template = 'debug.twig';
-$template_data = [
- 'log_lines' => getenv('LOG_LINES'),
- 'vmail_df' => $vmail_df,
- 'hostname' => $hostname,
- 'timezone' => $timezone,
- 'gal' => @$_SESSION['gal'],
- 'license_guid' => license('guid'),
- 'solr_status' => $solr_status,
- 'solr_uptime' => round($solr_status['status']['dovecot-fts']['uptime'] / 1000 / 60 / 60),
- 'clamd_status' => $clamd_status,
- 'containers' => $containers,
- 'ip_check' => customize('get', 'ip_check'),
- 'lang_admin' => json_encode($lang['admin']),
- 'lang_debug' => json_encode($lang['debug']),
- 'lang_datatables' => json_encode($lang['datatables']),
-];
-
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
-
-
diff --git a/mailcow/src/mailcow-dockerized/data/web/domainadmin/index.php b/mailcow/src/mailcow-dockerized/data/web/domainadmin/index.php
new file mode 100644
index 0000000..07c62a7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/domainadmin/index.php
@@ -0,0 +1,32 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.domainadmin.inc.php';
+
+if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'domainadmin') {
+ // Only redirect to mailbox if NO pending actions
+ if (empty($_SESSION['pending_tfa_setup']) && empty($_SESSION['pending_pw_update'])) {
+ header('Location: /domainadmin/mailbox');
+ exit();
+ }
+}
+elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'admin') {
+ header('Location: /admin/dashboard');
+ exit();
+}
+elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'user') {
+ header('Location: /user');
+ exit();
+}
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+$_SESSION['index_query_string'] = $_SERVER['QUERY_STRING'];
+
+$template = 'domainadmin_index.twig';
+$template_data = [
+ 'login_delay' => @$_SESSION['ldelay'],
+ 'custom_login' => customize('get', 'custom_login'),
+];
+
+$js_minifier->add('/web/js/site/index.js');
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/domainadmin/mailbox.php b/mailcow/src/mailcow-dockerized/data/web/domainadmin/mailbox.php
new file mode 100644
index 0000000..8beb5ab
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/domainadmin/mailbox.php
@@ -0,0 +1,47 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.domainadmin.inc.php';
+
+protect_route(['domainadmin']);
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+
+
+
+$js_minifier->add('/web/js/site/mailbox.js');
+$js_minifier->add('/web/js/presets/sieveMailbox.js');
+$js_minifier->add('/web/js/site/pwgen.js');
+
+$role = "domainadmin";
+$is_dual = (!empty($_SESSION["dual-login"]["username"])) ? 'true' : 'false';
+$allow_admin_email_login = (preg_match("/^([yY][eE][sS]|[yY])+$/", $_ENV["ALLOW_ADMIN_EMAIL_LOGIN"])) ? 'true' : 'false';
+
+// domains
+$domains = mailbox('get', 'domains');
+
+// mailboxes
+$mailboxes = [];
+foreach ($domains as $domain) {
+ foreach (mailbox('get', 'mailboxes', $domain) as $mailbox) {
+ $mailboxes[] = $mailbox;
+ }
+}
+
+$template = 'mailbox.twig';
+$template_data = [
+ 'acl' => $_SESSION['acl'],
+ 'acl_json' => json_encode($_SESSION['acl']),
+ 'role' => $role,
+ 'is_dual' => $is_dual,
+ 'allow_admin_email_login' => $allow_admin_email_login,
+ 'global_filters' => mailbox('get', 'global_filter_details'),
+ 'domains' => $domains,
+ 'mailboxes' => $mailboxes,
+ 'lang_mailbox' => json_encode($lang['mailbox']),
+ 'lang_rl' => json_encode($lang['ratelimit']),
+ 'lang_edit' => json_encode($lang['edit']),
+ 'lang_datatables' => json_encode($lang['datatables']),
+];
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/domainadmin/user.php b/mailcow/src/mailcow-dockerized/data/web/domainadmin/user.php
new file mode 100644
index 0000000..a45e00d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/domainadmin/user.php
@@ -0,0 +1,31 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.domainadmin.inc.php';
+
+/*
+/ DOMAIN ADMIN
+*/
+
+protect_route(['domainadmin']);
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+$tfa_data = get_tfa();
+$fido2_data = fido2(array("action" => "get_friendly_names"));
+$username = $_SESSION['mailcow_cc_username'];
+
+$template = 'domainadmin.twig';
+$template_data = [
+ 'acl' => $_SESSION['acl'],
+ 'acl_json' => json_encode($_SESSION['acl']),
+ 'user_spam_score' => mailbox('get', 'spam_score', $username),
+ 'tfa_data' => $tfa_data,
+ 'fido2_data' => $fido2_data,
+ 'lang_user' => json_encode($lang['user']),
+ 'lang_datatables' => json_encode($lang['datatables']),
+];
+
+$js_minifier->add('/web/js/site/user.js');
+$js_minifier->add('/web/js/site/pwgen.js');
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/edit.php b/mailcow/src/mailcow-dockerized/data/web/edit.php
index 4c5cd89..48f2309 100644
--- a/mailcow/src/mailcow-dockerized/data/web/edit.php
+++ b/mailcow/src/mailcow-dockerized/data/web/edit.php
@@ -1,10 +1,8 @@
<?php
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
-$AuthUsers = array("admin", "domainadmin", "user");
-if (!isset($_SESSION['mailcow_cc_role']) OR !in_array($_SESSION['mailcow_cc_role'], $AuthUsers)) {
- header('Location: /');
- exit();
-}
+
+protect_route();
+
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
$template = 'edit.twig';
@@ -48,6 +46,12 @@
$rl = ratelimit('get', 'domain', $domain);
$rlyhosts = relayhost('get');
$domain_footer = mailbox('get', 'domain_wide_footer', $domain);
+ $mta_sts = mailbox('get', 'mta_sts', $domain);
+ if (count($mta_sts) == 0) {
+ $mta_sts = false;
+ } elseif (isset($mta_sts['mx'])) {
+ $mta_sts['mx'] = implode(',', $mta_sts['mx']);
+ }
$template = 'edit/domain.twig';
$template_data = [
'acl' => $_SESSION['acl'],
@@ -58,6 +62,7 @@
'dkim' => dkim('details', $domain),
'domain_details' => $result,
'domain_footer' => $domain_footer,
+ 'mta_sts' => $mta_sts,
'mailboxes' => mailbox('get', 'mailboxes', $_GET["domain"]),
'aliases' => mailbox('get', 'aliases', $_GET["domain"], 'address'),
'alias_domains' => mailbox('get', 'alias_domains', $_GET["domain"])
@@ -125,13 +130,15 @@
'mailbox' => $mailbox,
'rl' => $rl,
'pushover_data' => $pushover_data,
+ 'get_tagging_options' => mailbox('get', 'delimiter_action', $mailbox),
'quarantine_notification' => $quarantine_notification,
'quarantine_category' => $quarantine_category,
'get_tls_policy' => $get_tls_policy,
'rlyhosts' => $rlyhosts,
'sender_acl_handles' => mailbox('get', 'sender_acl_handles', $mailbox),
'user_acls' => acl('get', 'user', $mailbox),
- 'mailbox_details' => $result
+ 'mailbox_details' => $result,
+ 'iam_settings' => $iam_settings,
];
}
}
@@ -166,6 +173,9 @@
if (substr($result['recipient_map_old'], 0, 1) == '@') {
$result['recipient_map_old'] = substr($result['recipient_map_old'], 1);
}
+ if (substr($result['recipient_map_new'], 0, 1) == '@') {
+ $result['recipient_map_new'] = substr($result['recipient_map_new'], 1);
+ }
$template = 'edit/recipient_map.twig';
$template_data = ['map' => $map];
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/f2b-banlist.php b/mailcow/src/mailcow-dockerized/data/web/f2b-banlist.php
new file mode 100644
index 0000000..05c7699
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/f2b-banlist.php
@@ -0,0 +1,11 @@
+<?php
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+
+if (isset($_GET['id'])) {
+ header('Content-Type: text/plain');
+ echo fail2ban('banlist', 'get', $_GET['id']);
+} else {
+ header('HTTP/1.1 404 Not Found');
+ exit;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/favicon.png b/mailcow/src/mailcow-dockerized/data/web/favicon.png
index 69eb2fc..5413613 100644
--- a/mailcow/src/mailcow-dockerized/data/web/favicon.png
+++ b/mailcow/src/mailcow-dockerized/data/web/favicon.png
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/ajax/container_ctrl.php b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/container_ctrl.php
index f0e220f..48c21cb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/ajax/container_ctrl.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/container_ctrl.php
@@ -1,4 +1,11 @@
<?php
+
+// Block requests by checking the 'Sec-Fetch-Dest' header.
+if (isset($_SERVER['HTTP_SEC_FETCH_DEST']) && $_SERVER['HTTP_SEC_FETCH_DEST'] !== 'empty') {
+ header('HTTP/1.1 403 Forbidden');
+ exit;
+}
+
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
if (!isset($_SESSION['mailcow_cc_role']) || $_SESSION['mailcow_cc_role'] != 'admin') {
exit();
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 15cb3a3..5efbaa4 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
@@ -71,6 +71,7 @@
// Init records array
$spf_link = '<a href="http://www.open-spf.org/SPF_Record_Syntax/" target="_blank">SPF Record Syntax</a><br />';
$dmarc_link = '<a href="https://www.kitterman.com/dmarc/assistant.html" target="_blank">DMARC Assistant</a>';
+ $mtasts_report_link = '<a href="https://mxtoolbox.com/dmarc/smtp-tls/how-to-setup-smtp-tls-reports" target="_blank">TLS Report Record Syntax</a>';
$records = array();
@@ -128,6 +129,36 @@
);
}
+ // Check if domain is an alias domain and get target domain's MTA-STS
+ $alias_domain_details = mailbox('get', 'alias_domain_details', $domain);
+ $mta_sts_domain = $domain;
+
+ if ($alias_domain_details !== false && !empty($alias_domain_details['target_domain'])) {
+ // This is an alias domain, check target domain for MTA-STS
+ $mta_sts_domain = $alias_domain_details['target_domain'];
+ }
+
+ $mta_sts = mailbox('get', 'mta_sts', $mta_sts_domain);
+ if (count($mta_sts) > 0 && $mta_sts['active'] == 1) {
+ if (!in_array($domain, $alias_domains)) {
+ $records[] = array(
+ 'mta-sts.' . $domain,
+ 'CNAME',
+ $mailcow_hostname
+ );
+ }
+ $records[] = array(
+ '_mta-sts.' . $domain,
+ 'TXT',
+ "v={$mta_sts['version']};id={$mta_sts['id']};",
+ );
+ $records[] = array(
+ '_smtp._tls.' . $domain,
+ 'TXT',
+ $mtasts_report_link,
+ );
+ }
+
$records[] = array(
$domain,
'TXT',
@@ -341,25 +372,35 @@
}
foreach ($currents as &$current) {
+ if ($current['type'] == "TXT" &&
+ stripos(strtolower($current['txt']), 'v=sts') === 0) {
+ if (strtolower($current[$data_field[$current['type']]]) == strtolower($record[2])) {
+ $state = state_good;
+ }
+ else {
+ $state = state_nomatch;
+ }
+ $state .= '<br />' . htmlspecialchars($current[$data_field[$current['type']]]);
+ }
if ($current['type'] == 'TXT' &&
- stripos($current['txt'], 'v=dmarc') === 0 &&
- $record[2] == $dmarc_link) {
+ stripos($current['txt'], 'v=dmarc') === 0 &&
+ $record[2] == $dmarc_link) {
$current['txt'] = str_replace(' ', '', $current['txt']);
- $state = $current[$data_field[$current['type']]] . state_optional;
+ $state = htmlspecialchars($current[$data_field[$current['type']]]) . state_optional;
}
elseif ($current['type'] == 'TXT' &&
- stripos($current['txt'], 'v=spf') === 0 &&
- $record[2] == $spf_link) {
+ stripos($current['txt'], 'v=spf') === 0 &&
+ $record[2] == $spf_link) {
$state = state_nomatch;
$rslt = get_spf_allowed_hosts($record[0], true);
if (in_array($ip, $rslt) && in_array(expand_ipv6($ip6), $rslt)) {
$state = state_good;
}
- $state .= '<br />' . $current[$data_field[$current['type']]] . state_optional;
+ $state .= '<br />' . htmlspecialchars($current[$data_field[$current['type']]]) . state_optional;
}
elseif ($current['type'] == 'TXT' &&
- stripos($current['txt'], 'v=dkim') === 0 &&
- stripos($record[2], 'v=dkim') === 0) {
+ stripos($current['txt'], 'v=dkim') === 0 &&
+ stripos($record[2], 'v=dkim') === 0) {
preg_match('/v=DKIM1;.*k=rsa;.*p=([^;]*).*/i', $current[$data_field[$current['type']]], $dkim_matches_current);
preg_match('/v=DKIM1;.*k=rsa;.*p=([^;]*).*/i', $record[2], $dkim_matches_good);
if ($dkim_matches_current[1] == $dkim_matches_good[1]) {
@@ -367,7 +408,7 @@
}
}
elseif ($current['type'] != 'TXT' &&
- isset($data_field[$current['type']]) && $state != state_good) {
+ isset($data_field[$current['type']]) && $state != state_good) {
$state = state_nomatch;
if ($current[$data_field[$current['type']]] == $record[2]) {
$state = state_good;
@@ -385,7 +426,7 @@
if ($state == state_nomatch) {
$state = array();
foreach ($currents as $current) {
- $state[] = $current[$data_field[$current['type']]];
+ $state[] = htmlspecialchars($current[$data_field[$current['type']]]);
}
$state = implode('<br />', $state);
}
@@ -395,12 +436,22 @@
<td>%s</td>
<td class="dns-found">%s</td>
<td class="dns-recommended">%s</td>
- </tr>', $record[0], $record[1], $record[2], $state);
+ </tr>', htmlspecialchars($record[0]), htmlspecialchars($record[1]), $record[2], $state);
$record[3] = explode('<br />', $state);
}
unset($record);
+ // Make a hostname RHS absolute so it is not read relative to $ORIGIN.
+ // Already-absolute names, the SRV root target "." and IP addresses are left alone.
+ $absolutize = function($host) {
+ $host = trim($host);
+ if ($host === '' || $host === '.' || substr($host, -1) === '.' || filter_var($host, FILTER_VALIDATE_IP)) {
+ return $host;
+ }
+ return $host . '.';
+ };
+
$dns_data = sprintf("\$ORIGIN %s.\n", $domain);
foreach ($records as $record) {
if ($domain == substr($record[0], -strlen($domain))) {
@@ -421,22 +472,32 @@
$val = str_replace(state_optional, '', $val);
$val = str_replace(state_good, '', $val);
if (strlen($val) > 0) {
+ // these are all TXT values, their RHS is a character string, not a name
$vals[] = sprintf("%s\tIN\t%s\t%s\n", $label, $record[1], $val);
}
}
}
else {
+ if ($record[1] == 'MX' || $record[1] == 'CNAME') {
+ $val = $absolutize($val);
+ }
+ elseif ($record[1] == 'SRV') {
+ // format here is "target port"; only the target is a name
+ $parts = explode(' ', $val, 2);
+ $parts[0] = $absolutize($parts[0]);
+ $val = implode(' ', $parts);
+ }
$vals[] = sprintf("%s\tIN\t%s\t%s\n", $label, $record[1], $val);
}
foreach ($vals as $val) {
- $dns_data .= str_replace($domain, $domain . '.', $val);
+ $dns_data .= $val;
}
}
}
?>
</table>
- <a id='download-zonefile' class="btn btn-sm btn-secondary visible-xs-block visible-sm-inline visible-md-inline visible-lg-inline mb-4" style="margin-top:10px" data-zonefile="<?=base64_encode($dns_data);?>" download='<?=$_GET['domain'];?>.txt' type='text/csv'>Download</a>
+ <a id='download-zonefile' class="btn btn-sm btn-secondary visible-xs-block visible-sm-inline visible-md-inline visible-lg-inline mb-4" style="margin-top:10px" data-zonefile="<?=base64_encode($dns_data);?>" download='<?=htmlspecialchars($_GET['domain']);?>.txt' type='text/csv'>Download</a>
<script>
var zonefile_dl_link = document.getElementById('download-zonefile');
var zonefile = atob(zonefile_dl_link.getAttribute('data-zonefile'));
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/ajax/sieve_validation.php b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/sieve_validation.php
index eb421b4..99be1f0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/ajax/sieve_validation.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/sieve_validation.php
@@ -4,14 +4,14 @@
if (!isset($_SESSION['mailcow_cc_role'])) {
exit();
}
-if (isset($_GET['script'])) {
+if (isset($_REQUEST['script'])) {
$sieve = new Sieve\SieveParser();
try {
- if (empty($_GET['script'])) {
+ if (empty($_REQUEST['script'])) {
echo json_encode(array('type' => 'danger', 'msg' => $lang['danger']['script_empty']));
exit();
}
- $sieve->parse($_GET['script']);
+ $sieve->parse($_REQUEST['script']);
}
catch (Exception $e) {
echo json_encode(array('type' => 'danger', 'msg' => $e->getMessage()));
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/ajax/update_check.php b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/update_check.php
new file mode 100644
index 0000000..6bf0160
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/ajax/update_check.php
@@ -0,0 +1,67 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+
+header('Content-Type: application/json');
+
+// Admins only
+if (!isset($_SESSION['mailcow_cc_role']) || $_SESSION['mailcow_cc_role'] !== 'admin') {
+ http_response_code(403);
+ echo json_encode(array('status' => 'error', 'message' => 'access denied'));
+ exit;
+}
+
+$owner = $GLOBALS['MAILCOW_GIT_OWNER'];
+$repo = $GLOBALS['MAILCOW_GIT_REPO'];
+$current = $GLOBALS['MAILCOW_GIT_VERSION'];
+
+// Cache key is bound to the running version, so an update invalidates it naturally
+$cache_key = 'MAILCOW_UPDATE_CHECK/' . $current;
+
+// Serve cached result if present (one GitHub call per TTL, not one per page load)
+$cached = $redis->get($cache_key);
+if ($cached !== false) {
+ echo $cached;
+ exit;
+}
+
+// GitHub requires a User-Agent and rate-limits unauthenticated requests to 60/h per IP
+function github_get($url) {
+ $ch = curl_init($url);
+ curl_setopt_array($ch, array(
+ CURLOPT_RETURNTRANSFER => true,
+ CURLOPT_USERAGENT => 'mailcow-update-check',
+ CURLOPT_TIMEOUT => 10,
+ CURLOPT_HTTPHEADER => array('Accept: application/vnd.github+json'),
+ ));
+ $body = curl_exec($ch);
+ $code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
+ curl_close($ch);
+ if ($body === false || $code !== 200) return false;
+ $json = json_decode($body, true);
+ return is_array($json) ? $json : false;
+}
+
+$latest = github_get("https://api.github.com/repos/{$owner}/{$repo}/releases/latest");
+$release = github_get("https://api.github.com/repos/{$owner}/{$repo}/releases/tags/{$current}");
+
+// Any failure (rate limit, offline, unexpected payload) -> honest error, cached briefly
+if ($latest === false || $release === false ||
+ empty($latest['tag_name']) || empty($latest['created_at']) || empty($release['created_at'])) {
+ $result = json_encode(array('status' => 'error', 'message' => 'could not reach GitHub API'));
+ $redis->setex($cache_key, 300, $result);
+ echo $result;
+ exit;
+}
+
+$date_latest = strtotime($latest['created_at']);
+$date_current = strtotime($release['created_at']);
+
+if ($date_latest <= $date_current) {
+ $result = json_encode(array('status' => 'no_update'));
+} else {
+ $result = json_encode(array('status' => 'update_available', 'latest_tag' => $latest['tag_name']));
+}
+
+// Cache the positive result for an hour
+$redis->setex($cache_key, 3600, $result);
+echo $result;
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 61d81df..4ced152 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/footer.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/footer.inc.php
@@ -12,7 +12,8 @@
$alerts = [];
if (is_array($alertbox_log_parser)) {
foreach ($alertbox_log_parser as $log) {
- $message = strtr($log['msg'], ["\n" => '', "\r" => '', "\t" => '<br>']);
+ $message = htmlspecialchars($log['msg'], ENT_QUOTES);
+ $message = strtr($message, ["\n" => '', "\r" => '', "\t" => '<br>']);
$alerts[trim($log['type'], '"')][] = trim($message, '"');
}
$alert = array_filter(array_unique($alerts));
@@ -25,23 +26,25 @@
// map tfa details for twig
$pending_tfa_authmechs = [];
-foreach($_SESSION['pending_tfa_methods'] as $authdata){
- $pending_tfa_authmechs[$authdata['authmech']] = false;
-}
-if (isset($pending_tfa_authmechs['webauthn'])) {
- $pending_tfa_authmechs['webauthn'] = true;
-}
-if (!isset($pending_tfa_authmechs['webauthn'])
- && isset($pending_tfa_authmechs['yubi_otp'])) {
- $pending_tfa_authmechs['yubi_otp'] = true;
-}
-if (!isset($pending_tfa_authmechs['webauthn'])
- && !isset($pending_tfa_authmechs['yubi_otp'])
- && isset($pending_tfa_authmechs['totp'])) {
- $pending_tfa_authmechs['totp'] = true;
-}
-if (isset($pending_tfa_authmechs['u2f'])) {
- $pending_tfa_authmechs['u2f'] = true;
+if (array_key_exists('pending_tfa_methods', $_SESSION)) {
+ foreach($_SESSION['pending_tfa_methods'] as $authdata){
+ $pending_tfa_authmechs[$authdata['authmech']] = false;
+ }
+ if (isset($pending_tfa_authmechs['webauthn'])) {
+ $pending_tfa_authmechs['webauthn'] = true;
+ }
+ if (!isset($pending_tfa_authmechs['webauthn'])
+ && isset($pending_tfa_authmechs['yubi_otp'])) {
+ $pending_tfa_authmechs['yubi_otp'] = true;
+ }
+ if (!isset($pending_tfa_authmechs['webauthn'])
+ && !isset($pending_tfa_authmechs['yubi_otp'])
+ && isset($pending_tfa_authmechs['totp'])) {
+ $pending_tfa_authmechs['totp'] = true;
+ }
+ if (isset($pending_tfa_authmechs['u2f'])) {
+ $pending_tfa_authmechs['u2f'] = true;
+ }
}
// globals
@@ -61,10 +64,14 @@
'pending_tfa_methods' => @$_SESSION['pending_tfa_methods'],
'pending_tfa_authmechs' => $pending_tfa_authmechs,
'pending_mailcow_cc_username' => @$_SESSION['pending_mailcow_cc_username'],
+ 'pending_tfa_setup' => !empty($_SESSION['pending_tfa_setup']),
+ 'pending_pw_update_modal' => !empty($_SESSION['pending_pw_update']),
'lang_footer' => json_encode($lang['footer']),
'lang_acl' => json_encode($lang['acl']),
'lang_tfa' => json_encode($lang['tfa']),
'lang_fido2' => json_encode($lang['fido2']),
+ 'lang_success' => json_encode($lang['success']),
+ 'lang_danger' => json_encode($lang['danger']),
'docker_timeout' => $DOCKER_TIMEOUT,
'session_lifetime' => (int)$SESSION_LIFETIME,
'csrf_token' => $_SESSION['CSRF']['TOKEN'],
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.acl.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.acl.inc.php
index ffce9f4..dde9b12 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.acl.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.acl.inc.php
@@ -1,5 +1,5 @@
<?php
-function acl($_action, $_scope = null, $_data = null) {
+function acl($_action, $_scope = null, $_data = null, $_extra = null) {
global $pdo;
global $lang;
$_data_log = $_data;
@@ -24,7 +24,7 @@
}
// Users cannot change their own ACL
if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)
- || ($_SESSION['mailcow_cc_role'] != 'admin' && $_SESSION['mailcow_cc_role'] != 'domainadmin')) {
+ || ($_SESSION['mailcow_cc_role'] != 'admin' && $_SESSION['mailcow_cc_role'] != 'domainadmin' && $_SESSION['access_all_exception'] != '1')) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_scope, $_data_log),
@@ -34,7 +34,7 @@
}
// Read all available acl options by calling acl(get)
// Set all available acl options we cannot find in the post data to 0, else 1
- $is_now = acl('get', 'user', $username);
+ $is_now = acl('get', 'user', $username, $_extra);
if (!empty($is_now)) {
foreach ($is_now as $acl_now_name => $acl_now_val) {
$set_acls[$acl_now_name] = (isset($acl_post[$acl_now_name])) ? 1 : 0;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.address_rewriting.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.address_rewriting.inc.php
index 140ae47..0c89d00 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.address_rewriting.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.address_rewriting.inc.php
@@ -270,6 +270,9 @@
$old_dest = substr($old_dest, 1);
}
$new_dest = strtolower(trim($_data['recipient_map_new']));
+ if (substr($new_dest, 0, 1) == '@') {
+ $new_dest = substr($new_dest, 1);
+ }
$active = intval($_data['active']);
if (is_valid_domain_name($old_dest)) {
$old_dest_sane = '@' . idn_to_ascii($old_dest, 0, INTL_IDNA_VARIANT_UTS46);
@@ -285,7 +288,13 @@
);
return false;
}
- if (!filter_var($new_dest, FILTER_VALIDATE_EMAIL)) {
+ if (is_valid_domain_name($new_dest)) {
+ $new_dest_sane = '@' . idn_to_ascii($new_dest, 0, INTL_IDNA_VARIANT_UTS46);
+ }
+ elseif (filter_var($new_dest, FILTER_VALIDATE_EMAIL)) {
+ $new_dest_sane = $new_dest;
+ }
+ else {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_data, $_attr),
@@ -308,7 +317,7 @@
(:old_dest, :new_dest, :active)");
$stmt->execute(array(
':old_dest' => $old_dest_sane,
- ':new_dest' => $new_dest,
+ ':new_dest' => $new_dest_sane,
':active' => $active
));
$_SESSION['return'][] = array(
@@ -325,6 +334,9 @@
$active = (isset($_data['active'])) ? intval($_data['active']) : $is_now['active'];
$new_dest = (!empty($_data['recipient_map_new'])) ? $_data['recipient_map_new'] : $is_now['recipient_map_new'];
$old_dest = (!empty($_data['recipient_map_old'])) ? $_data['recipient_map_old'] : $is_now['recipient_map_old'];
+ if (substr($new_dest, 0, 1) == '@') {
+ $new_dest = substr($new_dest, 1);
+ }
if (substr($old_dest, 0, 1) == '@') {
$old_dest = substr($old_dest, 1);
}
@@ -351,7 +363,13 @@
);
continue;
}
- if (!filter_var($new_dest, FILTER_VALIDATE_EMAIL)) {
+ if (is_valid_domain_name($new_dest)) {
+ $new_dest_sane = '@' . idn_to_ascii($new_dest, 0, INTL_IDNA_VARIANT_UTS46);
+ }
+ elseif (filter_var($new_dest, FILTER_VALIDATE_EMAIL)) {
+ $new_dest_sane = $new_dest;
+ }
+ else {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_data, $_attr),
@@ -378,7 +396,7 @@
WHERE `id`= :id");
$stmt->execute(array(
':old_dest' => $old_dest_sane,
- ':new_dest' => $new_dest,
+ ':new_dest' => $new_dest_sane,
':active' => $active,
':id' => $id
));
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 9f42fd7..7bd0af4 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
@@ -121,34 +121,56 @@
continue;
}
}
- if (!empty($password)) {
- if (password_check($password, $password2) !== true) {
- return false;
+ // Check if this is a self password change via forced update
+ if ($username == $_SESSION['mailcow_cc_username'] && !empty($_SESSION['pending_pw_update'])) {
+ // Forced password update: only change password and clear force_pw_update flag
+ if (!empty($password)) {
+ if (password_check($password, $_data['password2']) !== true) {
+ return false;
+ }
+ $password_hashed = hash_password($password);
+ $stmt = $pdo->prepare("UPDATE `admin` SET `password` = :password_hashed,
+ `attributes` = JSON_SET(COALESCE(`attributes`, '{}'), '$.force_pw_update', '0')
+ WHERE `username` = :username");
+ $stmt->execute(array(
+ ':password_hashed' => $password_hashed,
+ ':username' => $username
+ ));
+ unset($_SESSION['pending_pw_update']);
}
- $password_hashed = hash_password($password);
- $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active, `password` = :password_hashed WHERE `username` = :username");
- $stmt->execute(array(
- ':password_hashed' => $password_hashed,
- ':username_new' => $username_new,
- ':username' => $username,
- ':active' => $active
- ));
- if (isset($_data['disable_tfa'])) {
- $stmt = $pdo->prepare("UPDATE `tfa` SET `active` = '0' WHERE `username` = :username");
- $stmt->execute(array(':username' => $username));
+ } else {
+ // Normal admin edit: update all attributes
+ $force_tfa = intval($_data['force_tfa'] ?? 0) ? 1 : 0;
+ $force_pw_update = intval($_data['force_pw_update'] ?? 0) ? 1 : 0;
+ if (!empty($password)) {
+ if (password_check($password, $password2) !== true) {
+ return false;
+ }
+ $password_hashed = hash_password($password);
+ $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active, `password` = :password_hashed,
+ `attributes` = JSON_SET(COALESCE(`attributes`, '{}'), '$.force_tfa', :force_tfa, '$.force_pw_update', :force_pw_update)
+ WHERE `username` = :username");
+ $stmt->execute(array(
+ ':password_hashed' => $password_hashed,
+ ':username_new' => $username_new,
+ ':username' => $username,
+ ':active' => $active,
+ ':force_tfa' => strval($force_tfa),
+ ':force_pw_update' => strval($force_pw_update)
+ ));
}
else {
- $stmt = $pdo->prepare("UPDATE `tfa` SET `username` = :username_new WHERE `username` = :username");
- $stmt->execute(array(':username_new' => $username_new, ':username' => $username));
+ $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active,
+ `attributes` = JSON_SET(COALESCE(`attributes`, '{}'), '$.force_tfa', :force_tfa, '$.force_pw_update', :force_pw_update)
+ WHERE `username` = :username");
+ $stmt->execute(array(
+ ':username_new' => $username_new,
+ ':username' => $username,
+ ':active' => $active,
+ ':force_tfa' => strval($force_tfa),
+ ':force_pw_update' => strval($force_pw_update)
+ ));
}
- }
- else {
- $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active WHERE `username` = :username");
- $stmt->execute(array(
- ':username_new' => $username_new,
- ':username' => $username,
- ':active' => $active
- ));
if (isset($_data['disable_tfa'])) {
$stmt = $pdo->prepare("UPDATE `tfa` SET `active` = '0' WHERE `username` = :username");
$stmt->execute(array(':username' => $username));
@@ -223,7 +245,8 @@
`tfa`.`active` AS `tfa_active`,
`admin`.`username`,
`admin`.`created`,
- `admin`.`active` AS `active`
+ `admin`.`active` AS `active`,
+ `admin`.`attributes` AS `attributes`
FROM `admin`
LEFT OUTER JOIN `tfa` ON `tfa`.`username`=`admin`.`username`
WHERE `admin`.`username`= :admin AND `superadmin` = '1'");
@@ -240,6 +263,7 @@
$admindata['active'] = $row['active'];
$admindata['active_int'] = $row['active'];
$admindata['created'] = $row['created'];
+ $admindata['attributes'] = json_decode($row['attributes'], true) ?? array('force_tfa' => '0', 'force_pw_update' => '0');
return $admindata;
break;
}
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 b493fc9..aacbb82 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
@@ -1,7 +1,7 @@
<?php
function app_passwd($_action, $_data = null) {
- global $pdo;
- global $lang;
+ global $pdo;
+ global $lang;
$_data_log = $_data;
!isset($_data_log['app_passwd']) ?: $_data_log['app_passwd'] = '*';
!isset($_data_log['app_passwd2']) ?: $_data_log['app_passwd2'] = '*';
@@ -43,20 +43,7 @@
);
return false;
}
- if (!preg_match('/' . $GLOBALS['PASSWD_REGEP'] . '/', $password)) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_action, $_data_log),
- 'msg' => 'password_complexity'
- );
- return false;
- }
- if ($password != $password2) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_action, $_data_log),
- 'msg' => 'password_mismatch'
- );
+ if (password_check($password, $password2) !== true) {
return false;
}
$password_hashed = hash_password($password);
@@ -88,15 +75,15 @@
'log' => array(__FUNCTION__, $_action, $_data_log),
'msg' => 'app_passwd_added'
);
- break;
+ break;
case 'edit':
$ids = (array)$_data['id'];
foreach ($ids as $id) {
$is_now = app_passwd('details', $id);
if (!empty($is_now)) {
$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;
+ $password = (!empty($_data['app_passwd'])) ? $_data['app_passwd'] : null;
+ $password2 = (!empty($_data['app_passwd2'])) ? $_data['app_passwd2'] : null;
if (isset($_data['protocols'])) {
$protocols = (array)$_data['protocols'];
$imap_access = (in_array('imap_access', $protocols)) ? 1 : 0;
@@ -126,20 +113,7 @@
}
$app_name = htmlspecialchars(trim($app_name));
if (!empty($password) && !empty($password2)) {
- if (!preg_match('/' . $GLOBALS['PASSWD_REGEP'] . '/', $password)) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
- 'msg' => 'password_complexity'
- );
- continue;
- }
- if ($password != $password2) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
- 'msg' => 'password_mismatch'
- );
+ if (password_check($password, $password2) !== true) {
continue;
}
$password_hashed = hash_password($password);
@@ -182,7 +156,7 @@
'msg' => array('object_modified', htmlspecialchars(implode(', ', $ids)))
);
}
- break;
+ break;
case 'delete':
$ids = (array)$_data['id'];
foreach ($ids as $id) {
@@ -213,19 +187,17 @@
'msg' => array('app_passwd_removed', htmlspecialchars($id))
);
}
- break;
+ break;
case 'get':
$app_passwds = array();
$stmt = $pdo->prepare("SELECT `id`, `name` FROM `app_passwd` WHERE `mailbox` = :username");
$stmt->execute(array(':username' => $username));
$app_passwds = $stmt->fetchAll(PDO::FETCH_ASSOC);
return $app_passwds;
- break;
+ break;
case 'details':
$app_passwd_data = array();
- $stmt = $pdo->prepare("SELECT *
- FROM `app_passwd`
- WHERE `id` = :id");
+ $stmt = $pdo->prepare("SELECT * FROM `app_passwd` WHERE `id` = :id");
$stmt->execute(array(':id' => $_data));
$app_passwd_data = $stmt->fetch(PDO::FETCH_ASSOC);
if (empty($app_passwd_data)) {
@@ -237,6 +209,6 @@
}
$app_passwd_data['name'] = htmlspecialchars(trim($app_passwd_data['name']));
return $app_passwd_data;
- break;
+ break;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.auth.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.auth.inc.php
new file mode 100644
index 0000000..e5a303f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.auth.inc.php
@@ -0,0 +1,753 @@
+<?php
+function check_login($user, $pass, $extra = null) {
+ global $pdo;
+ global $redis;
+
+ $is_internal = $extra['is_internal'];
+ $role = $extra['role'];
+ $extra['service'] = !isset($extra['service']) ? 'NONE' : $extra['service'];
+
+ // Try validate admin
+ if (!isset($role) || $role == "admin") {
+ $result = admin_login($user, $pass);
+ if ($result !== false){
+ return $result;
+ }
+ }
+
+ // Try validate domain admin
+ if (!isset($role) || $role == "domain_admin") {
+ $result = domainadmin_login($user, $pass);
+ if ($result !== false) {
+ return $result;
+ }
+ }
+
+
+ // Try validate app password
+ if (!isset($role) || $role == "app") {
+ $result = apppass_login($user, $pass, $extra);
+ if ($result !== false) {
+ $real_rip = ($_SERVER['HTTP_X_REAL_IP'] ?? $_SERVER['REMOTE_ADDR']);
+ set_sasl_log($user, $real_rip, $extra['service'], $pass);
+ return $result;
+ }
+ }
+
+ // Try validate user
+ if (!isset($role) || $role == "user") {
+ $result = user_login($user, $pass, $extra);
+ if ($result !== false) {
+ $real_rip = ($_SERVER['HTTP_X_REAL_IP'] ?? $_SERVER['REMOTE_ADDR']);
+ set_sasl_log($user, $real_rip, $extra['service']);
+ return $result;
+ }
+ }
+
+ // skip log and only return false if it's an internal request
+ if ($is_internal == true) return false;
+
+ if (!isset($_SESSION['ldelay'])) {
+ $_SESSION['ldelay'] = "0";
+ $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']);
+ }
+ elseif (!isset($_SESSION['mailcow_cc_username'])) {
+ $_SESSION['ldelay'] = $_SESSION['ldelay']+0.5;
+ $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;
+}
+
+function admin_login($user, $pass){
+ global $pdo;
+
+ if (!filter_var($user, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $user))) {
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'malformed_username'
+ );
+ }
+ return false;
+ }
+
+ $user = strtolower(trim($user));
+ $stmt = $pdo->prepare("SELECT `password`, `attributes` FROM `admin`
+ WHERE `superadmin` = '1'
+ AND `active` = '1'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ // verify password
+ if (verify_hash($row['password'], $pass)) {
+ $admin_attrs = json_decode($row['attributes'], true) ?? [];
+
+ // Check force_pw_update
+ if (intval($admin_attrs['force_pw_update'] ?? 0) == 1) {
+ $_SESSION['pending_pw_update'] = true;
+ }
+
+ // check for tfa authenticators
+ $authenticators = get_tfa($user);
+ if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0) {
+ // active tfa authenticators found, set pending user login
+ $_SESSION['pending_mailcow_cc_username'] = $user;
+ $_SESSION['pending_mailcow_cc_role'] = "admin";
+ $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
+ unset($_SESSION['ldelay']);
+ $_SESSION['return'][] = array(
+ 'type' => 'info',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'awaiting_tfa_confirmation'
+ );
+ return "pending";
+ } else {
+ unset($_SESSION['ldelay']);
+ // Reactivate TFA if it was set to "deactivate TFA for next login"
+ $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ // Check force_tfa: only force setup if NO TFA exists at all
+ if (intval($admin_attrs['force_tfa'] ?? 0) == 1 && !tfa_exists($user)) {
+ $_SESSION['pending_tfa_setup'] = true;
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ return "admin";
+ }
+ }
+
+ return false;
+}
+function domainadmin_login($user, $pass){
+ global $pdo;
+
+ if (!filter_var($user, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $user))) {
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'malformed_username'
+ );
+ }
+ return false;
+ }
+
+ $stmt = $pdo->prepare("SELECT `password`, `attributes` FROM `admin`
+ WHERE `superadmin` = '0'
+ AND `active`='1'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ // verify password
+ if (verify_hash($row['password'], $pass) !== false) {
+ $admin_attrs = json_decode($row['attributes'], true) ?? [];
+
+ // Check force_pw_update
+ if (intval($admin_attrs['force_pw_update'] ?? 0) == 1) {
+ $_SESSION['pending_pw_update'] = true;
+ }
+
+ // check for tfa authenticators
+ $authenticators = get_tfa($user);
+ if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0) {
+ $_SESSION['pending_mailcow_cc_username'] = $user;
+ $_SESSION['pending_mailcow_cc_role'] = "domainadmin";
+ $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
+ unset($_SESSION['ldelay']);
+ $_SESSION['return'][] = array(
+ 'type' => 'info',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'awaiting_tfa_confirmation'
+ );
+ return "pending";
+ }
+ else {
+ unset($_SESSION['ldelay']);
+ // Reactivate TFA if it was set to "deactivate TFA for next login"
+ $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ // Check force_tfa: only force setup if NO TFA exists at all
+ if (intval($admin_attrs['force_tfa'] ?? 0) == 1 && !tfa_exists($user)) {
+ $_SESSION['pending_tfa_setup'] = true;
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ return "domainadmin";
+ }
+ }
+
+ return false;
+}
+function user_login($user, $pass, $extra = null){
+ global $pdo;
+ global $iam_provider;
+ global $iam_settings;
+
+ $is_internal = $extra['is_internal'];
+ $extra['service'] = !isset($extra['service']) ? 'NONE' : $extra['service'];
+
+ if (!filter_var($user, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $user))) {
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'malformed_username'
+ );
+ }
+ return false;
+ }
+
+ $stmt = $pdo->prepare("SELECT
+ mailbox.*,
+ domain.active AS d_active
+ FROM `mailbox`
+ INNER JOIN domain on mailbox.domain = domain.domain
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ // user does not exist, try call idp login and create user if possible via rest flow
+ if (!$row){
+ $result = false;
+ if ($iam_settings['authsource'] == 'keycloak' && intval($iam_settings['mailpassword_flow']) == 1){
+ $result = keycloak_mbox_login_rest($user, $pass, array('is_internal' => $is_internal, 'create' => true));
+ } else if ($iam_settings['authsource'] == 'ldap') {
+ $result = ldap_mbox_login($user, $pass, array('is_internal' => $is_internal, 'create' => true));
+ }
+ if ($result !== false){
+ // double check if mailbox is active
+ $stmt = $pdo->prepare("SELECT * FROM `mailbox`
+ INNER JOIN domain on mailbox.domain = domain.domain
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `mailbox`.`active`='1'
+ AND `domain`.`active`='1'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ if (!empty($row)) {
+ // check if user has access to service (imap, smtp, pop3, sieve, dav, eas) if service is set
+ $row['attributes'] = json_decode($row['attributes'], true);
+ if ($extra['service'] != 'NONE') {
+ $key = strtolower($extra['service']) . "_access";
+ if (isset($row['attributes'][$key]) && $row['attributes'][$key] != '1') {
+ return false;
+ }
+ }
+ return true;
+ }
+ }
+ clear_session();
+ return false;
+ }
+
+ // check if user has access to service (imap, smtp, pop3, sieve) if service is set
+ $row['attributes'] = json_decode($row['attributes'], true);
+ if ($extra['service'] != 'NONE') {
+ $key = strtolower($extra['service']) . "_access";
+ if (isset($row['attributes'][$key]) && $row['attributes'][$key] != '1') {
+ return false;
+ }
+ }
+ switch ($row['authsource']) {
+ case 'keycloak':
+ // user authsource is keycloak, try using via rest flow
+ if (intval($iam_settings['mailpassword_flow']) == 1){
+ $result = keycloak_mbox_login_rest($user, $pass, array('is_internal' => $is_internal));
+ if ($result !== false) {
+ // double check if mailbox and domain is active
+ $stmt = $pdo->prepare("SELECT * FROM `mailbox`
+ INNER JOIN domain on mailbox.domain = domain.domain
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `mailbox`.`active`='1'
+ AND `domain`.`active`='1'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if (empty($row)) {
+ return false;
+ }
+
+ $row['attributes'] = json_decode($row['attributes'], true);
+
+ // check for tfa authenticators
+ $authenticators = get_tfa($user);
+ if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0 && !$is_internal) {
+ // authenticators found, init TFA flow
+ $_SESSION['pending_mailcow_cc_username'] = $user;
+ $_SESSION['pending_mailcow_cc_role'] = "user";
+ $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
+ unset($_SESSION['ldelay']);
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*', 'Provider: Keycloak'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ return "pending";
+ } else if (!isset($authenticators['additional']) || !is_array($authenticators['additional']) || count($authenticators['additional']) == 0) {
+ // no authenticators found, login successfull
+ if (!$is_internal){
+ unset($_SESSION['ldelay']);
+ // Reactivate TFA if it was set to "deactivate TFA for next login"
+ $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ // Check force_tfa: only force setup if NO TFA exists at all
+ if (intval($row['attributes']['force_tfa']) == 1 && !tfa_exists($user)) {
+ $_SESSION['pending_tfa_setup'] = true;
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*', 'Provider: Keycloak'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ }
+ return "user";
+ }
+ }
+ return $result;
+ } else {
+ return false;
+ }
+ break;
+ case 'ldap':
+ // user authsource is ldap
+ $result = ldap_mbox_login($user, $pass, array('is_internal' => $is_internal));
+ if ($result !== false) {
+ // double check if mailbox and domain is active
+ $stmt = $pdo->prepare("SELECT * FROM `mailbox`
+ INNER JOIN domain on mailbox.domain = domain.domain
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `mailbox`.`active`='1'
+ AND `domain`.`active`='1'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if (empty($row)) {
+ return false;
+ }
+
+ $row['attributes'] = json_decode($row['attributes'], true);
+
+ // check for tfa authenticators
+ $authenticators = get_tfa($user);
+ if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0 && !$is_internal) {
+ // authenticators found, init TFA flow
+ $_SESSION['pending_mailcow_cc_username'] = $user;
+ $_SESSION['pending_mailcow_cc_role'] = "user";
+ $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
+ unset($_SESSION['ldelay']);
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*', 'Provider: LDAP'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ return "pending";
+ } else if (!isset($authenticators['additional']) || !is_array($authenticators['additional']) || count($authenticators['additional']) == 0) {
+ // no authenticators found, login successfull
+ if (!$is_internal){
+ unset($_SESSION['ldelay']);
+ // Reactivate TFA if it was set to "deactivate TFA for next login"
+ $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ // Check force_tfa: only force setup if NO TFA exists at all
+ if (intval($row['attributes']['force_tfa']) == 1 && !tfa_exists($user)) {
+ $_SESSION['pending_tfa_setup'] = true;
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*', 'Provider: LDAP'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ }
+ return "user";
+ }
+ }
+ return $result;
+ break;
+ case 'mailcow':
+ if ($row['active'] != 1 || $row['d_active'] != 1) {
+ return false;
+ }
+ // verify password
+ if (verify_hash($row['password'], $pass) !== false) {
+
+ if (intval($row['attributes']['force_pw_update']) == 1) {
+ $_SESSION['pending_pw_update'] = true;
+ }
+
+ // check for tfa authenticators
+ $authenticators = get_tfa($user);
+ if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0 && !$is_internal) {
+ // authenticators found, init TFA flow
+ $_SESSION['pending_mailcow_cc_username'] = $user;
+ $_SESSION['pending_mailcow_cc_role'] = "user";
+ $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
+ unset($_SESSION['ldelay']);
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*', 'Provider: mailcow'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ return "pending";
+ } else if (!isset($authenticators['additional']) || !is_array($authenticators['additional']) || count($authenticators['additional']) == 0) {
+ // no authenticators found, login successfull
+ if (!$is_internal){
+ unset($_SESSION['ldelay']);
+ // Reactivate TFA if it was set to "deactivate TFA for next login"
+ $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
+ $stmt->execute(array(':user' => $user));
+ // Check force_tfa: only force setup if NO TFA exists at all
+ if (intval($row['attributes']['force_tfa']) == 1 && !tfa_exists($user)) {
+ $_SESSION['pending_tfa_setup'] = true;
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $user, '*', 'Provider: mailcow'),
+ 'msg' => array('logged_in_as', $user)
+ );
+ }
+ return "user";
+ }
+ }
+ break;
+ }
+
+ return false;
+}
+function apppass_login($user, $pass, $extra = null){
+ global $pdo;
+
+ $is_internal = $extra['is_internal'];
+
+ if (!filter_var($user, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $user))) {
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'malformed_username'
+ );
+ }
+ return false;
+ }
+
+ $extra['service'] = !isset($extra['service']) ? 'NONE' : $extra['service'];
+ if (!$is_internal && $extra['service'] == 'NONE') {
+ return false;
+ }
+
+ // fetch app password data
+ $stmt = $pdo->prepare("SELECT `app_passwd`.*, `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`.`mailbox` = :user"
+ );
+ // fetch password data
+ $stmt->execute(array(
+ ':user' => $user,
+ ));
+ $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
+
+ foreach ($rows as $row) {
+ if ($extra['service'] != 'NONE' && $row[strtolower($extra['service']) . '_access'] != '1'){
+ continue;
+ }
+
+ // verify password
+ if (verify_hash($row['password'], $pass) !== false) {
+ $_SESSION['app_passwd_id'] = $row['app_passwd_id'];
+ unset($_SESSION['ldelay']);
+ return "user";
+ }
+ }
+
+ return false;
+}
+// Keycloak REST Api Flow - auth user by mailcow_password attribute
+// This password will be used for direct UI, IMAP and SMTP Auth
+// To use direct user credentials, only Authorization Code Flow is valid
+function keycloak_mbox_login_rest($user, $pass, $extra = null){
+ global $pdo;
+ global $iam_provider;
+ global $iam_settings;
+
+ $is_internal = $extra['is_internal'];
+ $create = $extra['create'];
+
+ if (!filter_var($user, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $user))) {
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'malformed_username'
+ );
+ }
+ return false;
+ }
+ if (!$iam_provider) {
+ return false;
+ }
+
+ // get access_token for service account of mailcow client
+ $admin_token = identity_provider("get-keycloak-admin-token");
+
+ // get the mailcow_password attribute from keycloak user
+ $url = "{$iam_settings['server_url']}/admin/realms/{$iam_settings['realm']}/users";
+ $queryParams = array('email' => $user, 'exact' => true);
+ $queryString = http_build_query($queryParams);
+ $curl = curl_init();
+ curl_setopt($curl, CURLOPT_TIMEOUT, 7);
+ curl_setopt($curl, CURLOPT_URL, $url . '?' . $queryString);
+ curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
+ curl_setopt($curl, CURLOPT_HTTPHEADER, array(
+ 'Authorization: Bearer ' . $admin_token,
+ 'Content-Type: application/json'
+ ));
+ $user_res = json_decode(curl_exec($curl), true)[0];
+ $code = curl_getinfo($curl, CURLINFO_HTTP_CODE);
+ curl_close($curl);
+ if ($code != 200) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', 'Identity Provider returned HTTP ' . $code),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+ if (!isset($user_res['attributes']['mailcow_password']) || !is_array($user_res['attributes']['mailcow_password'])){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', 'User has no mailcow_password attribute'),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+ if (empty($user_res['attributes']['mailcow_password'][0])){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', "User's mailcow_password attribute is empty"),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+
+ // validate mailcow_password
+ $mailcow_password = $user_res['attributes']['mailcow_password'][0];
+ if (!verify_hash($mailcow_password, $pass)) {
+ return false;
+ }
+
+ // get mapped template
+ $user_template = $user_res['attributes']['mailcow_template'][0];
+ $mapper_key = array_search($user_template, $iam_settings['mappers']);
+
+ if (!$create) {
+ // login success
+ if ($mapper_key !== false) {
+ // update user
+ $_SESSION['access_all_exception'] = '1';
+ mailbox('edit', 'mailbox_from_template', array(
+ 'username' => $user,
+ 'name' => $user_res['name'],
+ 'template' => $iam_settings['templates'][$mapper_key]
+ ));
+ $_SESSION['access_all_exception'] = '0';
+ }
+ return 'user';
+ }
+
+ // check if login provisioning is enabled before creating user
+ if (!$iam_settings['login_provisioning']){
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, "Auto-create users on login is deactivated"),
+ 'msg' => 'login_failed'
+ );
+ }
+ return false;
+ }
+ // check if matching attribute exist
+ if (empty($iam_settings['mappers']) || !$user_template || $mapper_key === false) {
+ if (!empty($iam_settings['default_template'])) {
+ $mbox_template = $iam_settings['default_template'];
+ } else {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', 'No matching attribute mapping was found'),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+ } else {
+ $mbox_template = $iam_settings['templates'][$mapper_key];
+ }
+
+ // create mailbox
+ $_SESSION['access_all_exception'] = '1';
+ $create_res = mailbox('add', 'mailbox_from_template', array(
+ 'domain' => explode('@', $user)[1],
+ 'local_part' => explode('@', $user)[0],
+ 'name' => $user_res['name'],
+ 'authsource' => 'keycloak',
+ 'template' => $mbox_template
+ ));
+ $_SESSION['access_all_exception'] = '0';
+ if (!$create_res){
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', 'Could not create mailbox on login'),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+
+ return 'user';
+}
+function ldap_mbox_login($user, $pass, $extra = null){
+ global $pdo;
+ global $iam_provider;
+ global $iam_settings;
+
+ $is_internal = $extra['is_internal'];
+ $create = $extra['create'];
+
+ if (!filter_var($user, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $user))) {
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'malformed_username'
+ );
+ }
+ return false;
+ }
+ if (!$iam_provider) {
+ return false;
+ }
+
+ try {
+ $ldap_query = $iam_provider->query();
+ if (!empty($iam_settings['filter'])) {
+ $ldap_query = $ldap_query->rawFilter($iam_settings['filter']);
+ }
+ $ldap_query = $ldap_query->where($iam_settings['username_field'], '=', $user)
+ ->select([$iam_settings['username_field'], $iam_settings['attribute_field'], 'displayname', 'distinguishedname', 'dn']);
+
+ $user_res = $ldap_query->firstOrFail();
+ } catch (Exception $e) {
+ // clear $_SESSION['return'] to not leak data
+ $_SESSION['return'] = array();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', $e->getMessage()),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+ try {
+ if (!$iam_provider->auth()->attempt($user_res['dn'], $pass)) {
+ return false;
+ }
+ } catch (Exception $e) {
+ // clear $_SESSION['return'] to not leak data
+ $_SESSION['return'] = array();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', $e->getMessage()),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+
+ // get mapped template
+ $user_template = $user_res[$iam_settings['attribute_field']][0];
+ $mapper_key = array_search($user_template, $iam_settings['mappers']);
+
+ if (!$create) {
+ // login success
+ if ($mapper_key !== false) {
+ // update user
+ $_SESSION['access_all_exception'] = '1';
+ mailbox('edit', 'mailbox_from_template', array(
+ 'username' => $user,
+ 'name' => $user_res['displayname'][0],
+ 'template' => $iam_settings['templates'][$mapper_key]
+ ));
+ $_SESSION['access_all_exception'] = '0';
+ }
+ return 'user';
+ }
+
+ // check if login provisioning is enabled before creating user
+ if (!$iam_settings['login_provisioning']){
+ if (!$is_internal){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, "Auto-create users on login is deactivated"),
+ 'msg' => 'login_failed'
+ );
+ }
+ return false;
+ }
+ // check if matching attribute exist
+ if (empty($iam_settings['mappers']) || !$user_template || $mapper_key === false) {
+ if (!empty($iam_settings['default_template'])) {
+ $mbox_template = $iam_settings['default_template'];
+ } else {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', 'No matching attribute mapping was found'),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+ } else {
+ $mbox_template = $iam_settings['templates'][$mapper_key];
+ }
+
+ // create mailbox
+ $_SESSION['access_all_exception'] = '1';
+ $create_res = mailbox('add', 'mailbox_from_template', array(
+ 'domain' => explode('@', $user)[1],
+ 'local_part' => explode('@', $user)[0],
+ 'name' => $user_res['displayname'][0],
+ 'authsource' => 'ldap',
+ 'template' => $mbox_template
+ ));
+ $_SESSION['access_all_exception'] = '0';
+ if (!$create_res){
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $user, '*', 'Could not create mailbox on login'),
+ 'msg' => 'generic_server_error'
+ );
+ return false;
+ }
+
+ return 'user';
+}
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 b729235..49a098e 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
@@ -3,7 +3,7 @@
global $redis;
global $lang;
global $LOGO_LIMITS;
-
+
switch ($_action) {
case 'add':
// disable functionality when demo mode is enabled
@@ -122,10 +122,16 @@
case 'app_links':
$apps = (array)$_data['app'];
$links = (array)$_data['href'];
+ $user_links = (array)$_data['user_href'];
+ $hide = (array)$_data['hide'];
$out = array();
- if (count($apps) == count($links)) {
+ if (count($apps) == count($links) && count($apps) == count($user_links) && count($apps) == count($hide)) {
for ($i = 0; $i < count($apps); $i++) {
- $out[] = array($apps[$i] => $links[$i]);
+ $out[] = array($apps[$i] => array(
+ 'link' => $links[$i],
+ 'user_link' => $user_links[$i],
+ 'hide' => ($hide[$i] === '0' || $hide[$i] === 0) ? false : true
+ ));
}
try {
$redis->set('APP_LINKS', json_encode($out));
@@ -198,6 +204,67 @@
'msg' => 'ip_check_opt_in_modified'
);
break;
+ case 'custom_login':
+ $hide_user_quicklink = ($_data['hide_user_quicklink'] == "1") ? 1 : 0;
+ $hide_domainadmin_quicklink = ($_data['hide_domainadmin_quicklink'] == "1") ? 1 : 0;
+ $hide_admin_quicklink = ($_data['hide_admin_quicklink'] == "1") ? 1 : 0;
+ $force_sso = ($_data['force_sso'] == "1") ? 1 : 0;
+
+ $custom_login = array(
+ "hide_user_quicklink" => $hide_user_quicklink,
+ "hide_domainadmin_quicklink" => $hide_domainadmin_quicklink,
+ "hide_admin_quicklink" => $hide_admin_quicklink,
+ "force_sso" => $force_sso,
+ );
+ try {
+ $redis->set('CUSTOM_LOGIN', json_encode($custom_login));
+ }
+ catch (RedisException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_item, $_data),
+ 'msg' => array('redis_error', $e)
+ );
+ return false;
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_action, $_item, $_data),
+ 'msg' => 'custom_login_modified'
+ );
+ break;
+ case 'ui_theme':
+ $ui_theme = is_array($_data['ui_theme']) ? (string)reset($_data['ui_theme']) : (string)$_data['ui_theme'];
+ if ($ui_theme !== '' && !array_key_exists($ui_theme, customize('get', 'ui_themes'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_item, $_data),
+ 'msg' => 'ui_theme_invalid'
+ );
+ return false;
+ }
+ try {
+ if ($ui_theme === '') {
+ $redis->del('UI_THEME');
+ }
+ else {
+ $redis->set('UI_THEME', $ui_theme);
+ }
+ }
+ catch (RedisException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_item, $_data),
+ 'msg' => array('redis_error', $e)
+ );
+ return false;
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_action, $_item, $_data),
+ 'msg' => 'ui_theme_modified'
+ );
+ break;
}
break;
case 'delete':
@@ -256,7 +323,23 @@
);
return false;
}
- return ($app_links) ? $app_links : false;
+
+ if (empty($app_links)){
+ return [];
+ }
+
+ // convert from old style
+ foreach($app_links as $i => $entry){
+ foreach($entry as $app => $link){
+ if (empty($link['link']) && empty($link['user_link'])){
+ $app_links[$i][$app] = array();
+ $app_links[$i][$app]['link'] = $link;
+ $app_links[$i][$app]['user_link'] = $link;
+ }
+ }
+ }
+
+ return $app_links;
break;
case 'main_logo':
case 'main_logo_dark':
@@ -274,8 +357,10 @@
break;
case 'ui_texts':
try {
- $data['title_name'] = ($title_name = $redis->get('TITLE_NAME')) ? $title_name : 'mailcow UI';
- $data['main_name'] = ($main_name = $redis->get('MAIN_NAME')) ? $main_name : 'mailcow UI';
+ $mailcow_hostname = strtolower(getenv("MAILCOW_HOSTNAME"));
+
+ $data['title_name'] = ($title_name = $redis->get('TITLE_NAME')) ? $title_name : "$mailcow_hostname - mail UI";
+ $data['main_name'] = ($main_name = $redis->get('MAIN_NAME')) ? $main_name : "$mailcow_hostname - mail UI";
$data['apps_name'] = ($apps_name = $redis->get('APPS_NAME')) ? $apps_name : $lang['header']['apps'];
$data['help_text'] = ($help_text = $redis->get('HELP_TEXT')) ? $help_text : false;
if (!empty($redis->get('UI_IMPRESS'))) {
@@ -335,6 +420,56 @@
return false;
}
break;
+ case 'custom_login':
+ try {
+ $custom_login = $redis->get('CUSTOM_LOGIN');
+ return $custom_login ? json_decode($custom_login, true) : array();
+ }
+ catch (RedisException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_item, $_data),
+ 'msg' => array('redis_error', $e)
+ );
+ return false;
+ }
+ break;
+ case 'ui_themes':
+ // theme folders in css/themes/<name>/ with a theme.css
+ $themes = array();
+ foreach (glob('/web/css/themes/*/theme.css') as $theme_css) {
+ $theme_dir = dirname($theme_css);
+ $theme = basename($theme_dir);
+ if (!preg_match('/^[a-zA-Z0-9_-]+$/', $theme)) {
+ continue;
+ }
+ $meta = json_decode(@file_get_contents($theme_dir . '/theme.json'), true);
+ $themes[$theme] = array(
+ 'name' => (!empty($meta['name'])) ? $meta['name'] : $theme,
+ 'description' => (!empty($meta['description'])) ? $meta['description'] : '',
+ 'dark' => file_exists($theme_dir . '/dark.css')
+ );
+ }
+ ksort($themes);
+ return $themes;
+ break;
+ case 'ui_theme':
+ try {
+ $ui_theme = $redis->get('UI_THEME');
+ }
+ catch (RedisException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_item, $_data),
+ 'msg' => array('redis_error', $e)
+ );
+ return false;
+ }
+ if (empty($ui_theme) || !preg_match('/^[a-zA-Z0-9_-]+$/', $ui_theme) || !file_exists('/web/css/themes/' . $ui_theme . '/theme.css')) {
+ return '';
+ }
+ return $ui_theme;
+ break;
}
break;
}
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 29b32d5..e7e4117 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
@@ -26,7 +26,7 @@
);
continue;
}
- if (!ctype_alnum(str_replace(['-', '_'], '', $dkim_selector))) {
+ if (!ctype_alnum(str_replace(['-', '_', '.'], '', $dkim_selector))) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_data),
@@ -188,7 +188,7 @@
return false;
}
}
- if (!ctype_alnum($dkim_selector)) {
+ if (!ctype_alnum(str_replace(['-', '_', '.'], '', $dkim_selector))) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_data),
@@ -240,9 +240,12 @@
if (strlen($dkimdata['pubkey']) < 391) {
$dkimdata['length'] = "1024";
}
- elseif (strlen($dkimdata['pubkey']) < 736) {
+ elseif (strlen($dkimdata['pubkey']) < 564) {
$dkimdata['length'] = "2048";
}
+ elseif (strlen($dkimdata['pubkey']) < 736) {
+ $dkimdata['length'] = "3072";
+ }
elseif (strlen($dkimdata['pubkey']) < 1416) {
$dkimdata['length'] = "4096";
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.docker.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.docker.inc.php
index 5b5b7ac..daed17c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.docker.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.docker.inc.php
@@ -63,7 +63,7 @@
break;
case 'info':
if (empty($service_name)) {
- curl_setopt($curl, CURLOPT_URL, 'https://dockerapi:443/containers/json');
+ curl_setopt($curl, CURLOPT_URL, 'https://dockerapi:443/containers/json?all=true');
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_POST, 0);
curl_setopt($curl, CURLOPT_TIMEOUT, $DOCKER_TIMEOUT);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.domain_admin.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.domain_admin.inc.php
index bb88ea3..17aa4ad 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.domain_admin.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.domain_admin.inc.php
@@ -195,17 +195,23 @@
));
}
}
+ $force_tfa = intval($_data['force_tfa'] ?? 0) ? 1 : 0;
+ $force_pw_update = intval($_data['force_pw_update'] ?? 0) ? 1 : 0;
if (!empty($password)) {
if (password_check($password, $password2) !== true) {
return false;
}
$password_hashed = hash_password($password);
- $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active, `password` = :password_hashed WHERE `username` = :username");
+ $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active, `password` = :password_hashed,
+ `attributes` = JSON_SET(COALESCE(`attributes`, '{}'), '$.force_tfa', :force_tfa, '$.force_pw_update', :force_pw_update)
+ WHERE `username` = :username");
$stmt->execute(array(
':password_hashed' => $password_hashed,
':username_new' => $username_new,
':username' => $username,
- ':active' => $active
+ ':active' => $active,
+ ':force_tfa' => strval($force_tfa),
+ ':force_pw_update' => strval($force_pw_update)
));
if (isset($_data['disable_tfa'])) {
$stmt = $pdo->prepare("UPDATE `tfa` SET `active` = '0' WHERE `username` = :username");
@@ -217,11 +223,15 @@
}
}
else {
- $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active WHERE `username` = :username");
+ $stmt = $pdo->prepare("UPDATE `admin` SET `username` = :username_new, `active` = :active,
+ `attributes` = JSON_SET(COALESCE(`attributes`, '{}'), '$.force_tfa', :force_tfa, '$.force_pw_update', :force_pw_update)
+ WHERE `username` = :username");
$stmt->execute(array(
':username_new' => $username_new,
':username' => $username,
- ':active' => $active
+ ':active' => $active,
+ ':force_tfa' => strval($force_tfa),
+ ':force_pw_update' => strval($force_pw_update)
));
if (isset($_data['disable_tfa'])) {
$stmt = $pdo->prepare("UPDATE `tfa` SET `active` = '0' WHERE `username` = :username");
@@ -244,31 +254,37 @@
// Can only edit itself
elseif ($_SESSION['mailcow_cc_role'] == "domainadmin") {
$username = $_SESSION['mailcow_cc_username'];
- $password_old = $_data['user_old_pass'];
+ $password_old = $_data['user_old_pass'] ?? '';
$password_new = $_data['user_new_pass'];
$password_new2 = $_data['user_new_pass2'];
- $stmt = $pdo->prepare("SELECT `password` FROM `admin`
- WHERE `username` = :user");
- $stmt->execute(array(':user' => $username));
- $row = $stmt->fetch(PDO::FETCH_ASSOC);
- if (!verify_hash($row['password'], $password_old)) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_action, $_data_log),
- 'msg' => 'access_denied'
- );
- return false;
+ // Only verify old password if this is NOT a forced password update
+ if (empty($_SESSION['pending_pw_update'])) {
+ $stmt = $pdo->prepare("SELECT `password` FROM `admin`
+ WHERE `username` = :user");
+ $stmt->execute(array(':user' => $username));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if (!verify_hash($row['password'], $password_old)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_data_log),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
}
if (password_check($password_new, $password_new2) !== true) {
return false;
}
$password_hashed = hash_password($password_new);
- $stmt = $pdo->prepare("UPDATE `admin` SET `password` = :password_hashed WHERE `username` = :username");
+ $stmt = $pdo->prepare("UPDATE `admin` SET `password` = :password_hashed,
+ `attributes` = JSON_SET(COALESCE(`attributes`, '{}'), '$.force_pw_update', '0')
+ WHERE `username` = :username");
$stmt->execute(array(
':password_hashed' => $password_hashed,
':username' => $username
));
+ unset($_SESSION['pending_pw_update']);
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_action, $_data_log),
@@ -360,9 +376,11 @@
`tfa`.`active` AS `tfa_active`,
`domain_admins`.`username`,
`domain_admins`.`created`,
- `domain_admins`.`active` AS `active`
+ `domain_admins`.`active` AS `active`,
+ `admin`.`attributes` AS `attributes`
FROM `domain_admins`
LEFT OUTER JOIN `tfa` ON `tfa`.`username`=`domain_admins`.`username`
+ LEFT OUTER JOIN `admin` ON `admin`.`username`=`domain_admins`.`username`
WHERE `domain_admins`.`username`= :domain_admin");
$stmt->execute(array(
':domain_admin' => $_data
@@ -377,6 +395,7 @@
$domainadmindata['active'] = $row['active'];
$domainadmindata['active_int'] = $row['active'];
$domainadmindata['created'] = $row['created'];
+ $domainadmindata['attributes'] = json_decode($row['attributes'], true) ?? array('force_tfa' => '0', 'force_pw_update' => '0');
// GET SELECTED
$stmt = $pdo->prepare("SELECT `domain` FROM `domain`
WHERE `domain` IN (
@@ -410,14 +429,25 @@
switch ($_action) {
case 'check':
- $token = $_data;
+ $token = preg_replace('/[^a-zA-Z0-9-]/', '', $_data);
$stmt = $pdo->prepare("SELECT `t1`.`username` FROM `da_sso` AS `t1` JOIN `admin` AS `t2` ON `t1`.`username` = `t2`.`username` WHERE `t1`.`token` = :token AND `t1`.`created` > DATE_SUB(NOW(), INTERVAL '30' SECOND) AND `t2`.`active` = 1 AND `t2`.`superadmin` = 0;");
$stmt->execute(array(
- ':token' => preg_replace('/[^a-zA-Z0-9-]/', '', $token)
+ ':token' => $token
));
$return = $stmt->fetch(PDO::FETCH_ASSOC);
- return empty($return['username']) ? false : $return['username'];
+ if (empty($return['username'])) {
+ return false;
+ }
+ // single-use: consume the token; if a concurrent request already used it, deny
+ $del = $pdo->prepare("DELETE FROM `da_sso` WHERE `token` = :token");
+ $del->execute(array(
+ ':token' => $token
+ ));
+ if ($del->rowCount() < 1) {
+ return false;
+ }
+ return $return['username'];
case 'issue':
if ($_SESSION['mailcow_cc_role'] != "admin") {
$_SESSION['return'][] = array(
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.fwdhost.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.fwdhost.inc.php
index d7ac256..52c7515 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.fwdhost.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.fwdhost.inc.php
@@ -108,6 +108,14 @@
}
break;
case 'delete':
+ if ($_SESSION['mailcow_cc_role'] != "admin") {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_data_log),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
$hosts = (array)$_data['forwardinghost'];
foreach ($hosts as $host) {
try {
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 3cff09b..09e8ec1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.inc.php
@@ -53,6 +53,39 @@
function valid_hostname($hostname) {
return filter_var($hostname, FILTER_VALIDATE_DOMAIN, FILTER_FLAG_HOSTNAME);
}
+// Validates a browser-style Origin: scheme://host[:port], no path/query/fragment/credentials
+function valid_origin($origin) {
+ $parts = parse_url($origin);
+ if ($parts === false || !isset($parts['scheme']) || !isset($parts['host'])) {
+ return false;
+ }
+ if (!in_array(strtolower($parts['scheme']), array('http', 'https'), true)) {
+ return false;
+ }
+ if (isset($parts['user']) || isset($parts['pass']) || isset($parts['path']) || isset($parts['query']) || isset($parts['fragment'])) {
+ return false;
+ }
+ $host = $parts['host'];
+ $host_without_brackets = trim($host, '[]');
+ if (!valid_hostname($host_without_brackets) && !filter_var($host_without_brackets, FILTER_VALIDATE_IP)) {
+ return false;
+ }
+ // Reject anything that doesn't round-trip to the exact same origin (e.g. stray trailing slash)
+ $port = isset($parts['port']) ? ':' . $parts['port'] : '';
+ $rebuilt = strtolower($parts['scheme']) . '://' . strtolower($host) . $port;
+ return strtolower($origin) === $rebuilt;
+}
+// Bring an origin into the exact form a browser sends it (scheme://host[:port], lowercase).
+function normalize_cors_origin($origin) {
+ $origin = trim($origin);
+ if ($origin === '*') {
+ return '*';
+ }
+ if ($origin !== '' && !preg_match('~^[a-z][a-z0-9+.-]*://~i', $origin)) {
+ $origin = 'https://' . $origin;
+ }
+ return valid_origin($origin) ? strtolower($origin) : false;
+}
// Thanks to https://stackoverflow.com/a/49373789
// Validates exact ip matches and ip-in-cidr, ipv4 and ipv6
function ip_acl($ip, $networks) {
@@ -205,6 +238,42 @@
break;
}
}
+
+function password_generate(){
+ $password_complexity = password_complexity('get');
+ $min_length = max(16, intval($password_complexity['length']));
+
+ $lowercase = range('a', 'z');
+ $uppercase = range('A', 'Z');
+ $digits = range(0, 9);
+ $special_chars = str_split('!@#$%^&*()?=');
+
+ $password = [
+ $lowercase[random_int(0, count($lowercase) - 1)],
+ $uppercase[random_int(0, count($uppercase) - 1)],
+ $digits[random_int(0, count($digits) - 1)],
+ $special_chars[random_int(0, count($special_chars) - 1)],
+ ];
+
+ $all = array_merge($lowercase, $uppercase, $digits, $special_chars);
+
+ while (count($password) < $min_length) {
+ $password[] = $all[random_int(0, count($all) - 1)];
+ }
+
+ // Cryptographically secure shuffle using Fisher-Yates algorithm
+ $count = count($password);
+ for ($i = $count - 1; $i > 0; $i--) {
+ $j = random_int(0, $i);
+ $temp = $password[$i];
+ $password[$i] = $password[$j];
+ $password[$j] = $temp;
+ }
+
+ return implode('', $password);
+
+}
+
function password_check($password1, $password2) {
$password_complexity = password_complexity('get');
@@ -284,17 +353,17 @@
}
if (!$sasl[$k]['location']) {
$curl = curl_init();
- curl_setopt($curl, CURLOPT_URL,"https://dfdata.bella.network/lookup/" . $sasl[$k]['real_rip']);
+ curl_setopt($curl, CURLOPT_URL,"https://dfdata.bella.network/country/" . $sasl[$k]['real_rip']);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_USERAGENT, 'Moocow');
curl_setopt($curl, CURLOPT_TIMEOUT, 5);
$ip_data = curl_exec($curl);
if (!curl_errno($curl)) {
$ip_data_array = json_decode($ip_data, true);
- if ($ip_data_array !== false and !empty($ip_data_array['location']['shortcountry'])) {
- $sasl[$k]['location'] = $ip_data_array['location']['shortcountry'];
+ if ($ip_data_array !== false and !empty($ip_data_array['shortcountry'])) {
+ $sasl[$k]['location'] = $ip_data_array['shortcountry'];
try {
- $redis->hSet('IP_SHORTCOUNTRY', $sasl[$k]['real_rip'], $ip_data_array['location']['shortcountry']);
+ $redis->hSet('IP_SHORTCOUNTRY', $sasl[$k]['real_rip'], $ip_data_array['shortcountry']);
}
catch (RedisException $e) {
$_SESSION['return'][] = array(
@@ -350,6 +419,34 @@
}
}
+function set_sasl_log($username, $real_rip, $service){
+ global $pdo;
+
+ try {
+ if (!empty($_SESSION['app_passwd_id'])) {
+ $app_password = $_SESSION['app_passwd_id'];
+ } else {
+ $app_password = 0;
+ }
+
+ $stmt = $pdo->prepare('REPLACE INTO `sasl_log` (`username`, `real_rip`, `service`, `app_password`) VALUES (:username, :real_rip, :service, :app_password)');
+ $stmt->execute(array(
+ ':username' => $username,
+ ':real_rip' => $real_rip,
+ ':service' => $service,
+ ':app_password' => $app_password
+ ));
+ } catch (PDOException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_data_log),
+ 'msg' => array('mysql_error', $e)
+ );
+ return false;
+ }
+
+ return true;
+}
function flush_memcached() {
try {
$m = new Memcached();
@@ -494,7 +591,7 @@
$type = $return['type'];
$msg = null;
if (isset($return['msg'])) {
- $msg = json_encode($return['msg'], JSON_UNESCAPED_UNICODE);
+ $msg = json_encode($return['msg'], JSON_UNESCAPED_UNICODE | JSON_HEX_TAG | JSON_HEX_AMP | JSON_HEX_APOS | JSON_HEX_QUOT);
}
$call = null;
if (isset($return['log'])) {
@@ -536,14 +633,29 @@
return true;
}
}
-function hasDomainAccess($username, $role, $domain) {
+function is_local_mailcow_domain($domain) {
+ // True if domain is a locally managed, active primary or alias domain
global $pdo;
- if (!filter_var($username, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $username))) {
+ $domain = idn_to_ascii($domain, 0, INTL_IDNA_VARIANT_UTS46);
+ if (empty($domain)) {
return false;
}
+ $stmt = $pdo->prepare("SELECT 1 FROM `domain` WHERE `domain` = :d AND `active` = 1
+ UNION SELECT 1 FROM `alias_domain` WHERE `alias_domain` = :d2 AND `active` = 1 LIMIT 1");
+ $stmt->execute(array(':d' => $domain, ':d2' => $domain));
+ return (bool)$stmt->fetchColumn();
+}
+function hasDomainAccess($username, $role, $domain) {
+ global $pdo;
if (empty($domain) || !is_valid_domain_name($domain)) {
return false;
}
+ if (isset($_SESSION['access_all_exception']) && $_SESSION['access_all_exception'] == "1") {
+ return true;
+ }
+ if (!filter_var($username, FILTER_VALIDATE_EMAIL) && !ctype_alnum(str_replace(array('_', '.', '-'), '', $username))) {
+ return false;
+ }
if ($role != 'admin' && $role != 'domainadmin') {
return false;
}
@@ -577,6 +689,9 @@
}
function hasMailboxObjectAccess($username, $role, $object) {
global $pdo;
+ if (isset($_SESSION['access_all_exception']) && $_SESSION['access_all_exception'] == "1") {
+ return true;
+ }
if (empty($username) || empty($role) || empty($object)) {
return false;
}
@@ -600,6 +715,9 @@
// does also verify mailboxes as a mailbox is a alias == goto
function hasAliasObjectAccess($username, $role, $object) {
global $pdo;
+ if (isset($_SESSION['access_all_exception']) && $_SESSION['access_all_exception'] == "1") {
+ return true;
+ }
if (empty($username) || empty($role) || empty($object)) {
return false;
}
@@ -617,6 +735,16 @@
}
return false;
}
+function hasACLAccess($type) {
+ if (isset($_SESSION['access_all_exception']) && $_SESSION['access_all_exception'] == "1") {
+ return true;
+ }
+ if (isset($_SESSION['acl'][$type]) && $_SESSION['acl'][$type] == "1") {
+ return true;
+ }
+
+ return false;
+}
function pem_to_der($pem_key) {
// Need to remove BEGIN/END PUBLIC KEY
$lines = explode("\n", trim($pem_key));
@@ -767,6 +895,32 @@
$hash = $components[4];
return hash_equals(hash_pbkdf2('sha1', $password, $salt, $rounds), $hash);
+ case "PBKDF2-SHA512":
+ // Handle FreeIPA-style hash: {PBKDF2-SHA512}10000$<base64_salt>$<base64_hash>
+ $components = explode('$', $hash);
+ if (count($components) !== 3) return false;
+
+ // 1st part: iteration count (integer)
+ $iterations = intval($components[0]);
+ if ($iterations <= 0) return false;
+
+ // 2nd part: salt (base64-encoded)
+ $salt = $components[1];
+ // 3rd part: hash (base64-encoded)
+ $stored_hash_b64 = $components[2];
+
+ // Decode salt and hash from base64
+ $salt_bin = base64_decode($salt, true);
+ $hash_bin = base64_decode($stored_hash_b64, true);
+ if ($salt_bin === false || $hash_bin === false) return false;
+ // Get length of hash in bytes
+ $hash_len = strlen($hash_bin);
+ if ($hash_len === 0) return false;
+
+ // Calculate PBKDF2-SHA512 hash for provided password
+ $test_hash = hash_pbkdf2('sha512', $password, $salt_bin, $iterations, $hash_len, true);
+ return hash_equals($hash_bin, $test_hash);
+
case "PLAIN-MD4":
return hash_equals(hash('md4', $password), $hash);
@@ -811,200 +965,6 @@
}
return false;
}
-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',
- 'log' => array(__FUNCTION__, $user, '*'),
- 'msg' => 'malformed_username'
- );
- return false;
- }
-
- // Validate admin
- $user = strtolower(trim($user));
- $stmt = $pdo->prepare("SELECT `password` FROM `admin`
- WHERE `superadmin` = '1'
- AND `active` = '1'
- AND `username` = :user");
- $stmt->execute(array(':user' => $user));
- $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
- foreach ($rows as $row) {
- // verify password
- if (verify_hash($row['password'], $pass)) {
- // check for tfa authenticators
- $authenticators = get_tfa($user);
- if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0) {
- // active tfa authenticators found, set pending user login
- $_SESSION['pending_mailcow_cc_username'] = $user;
- $_SESSION['pending_mailcow_cc_role'] = "admin";
- $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
- unset($_SESSION['ldelay']);
- $_SESSION['return'][] = array(
- 'type' => 'info',
- 'log' => array(__FUNCTION__, $user, '*'),
- 'msg' => 'awaiting_tfa_confirmation'
- );
- return "pending";
- } else {
- unset($_SESSION['ldelay']);
- // Reactivate TFA if it was set to "deactivate TFA for next login"
- $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
- $stmt->execute(array(':user' => $user));
- $_SESSION['return'][] = array(
- 'type' => 'success',
- 'log' => array(__FUNCTION__, $user, '*'),
- 'msg' => array('logged_in_as', $user)
- );
- return "admin";
- }
- }
- }
-
- // Validate domain admin
- $stmt = $pdo->prepare("SELECT `password` FROM `admin`
- WHERE `superadmin` = '0'
- AND `active`='1'
- AND `username` = :user");
- $stmt->execute(array(':user' => $user));
- $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
- foreach ($rows as $row) {
- // verify password
- if (verify_hash($row['password'], $pass) !== false) {
- // check for tfa authenticators
- $authenticators = get_tfa($user);
- if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0) {
- $_SESSION['pending_mailcow_cc_username'] = $user;
- $_SESSION['pending_mailcow_cc_role'] = "domainadmin";
- $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
- unset($_SESSION['ldelay']);
- $_SESSION['return'][] = array(
- 'type' => 'info',
- 'log' => array(__FUNCTION__, $user, '*'),
- 'msg' => 'awaiting_tfa_confirmation'
- );
- return "pending";
- }
- else {
- unset($_SESSION['ldelay']);
- // Reactivate TFA if it was set to "deactivate TFA for next login"
- $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
- $stmt->execute(array(':user' => $user));
- $_SESSION['return'][] = array(
- 'type' => 'success',
- 'log' => array(__FUNCTION__, $user, '*'),
- 'msg' => array('logged_in_as', $user)
- );
- return "domainadmin";
- }
- }
- }
-
- // 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'
- AND `mailbox`.`active`='1'
- AND `domain`.`active`='1'
- 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) {
- // verify password
- if (verify_hash($row['password'], $pass) !== false) {
- if (!array_key_exists("app_passwd_id", $row)){
- // password is not a app password
- // check for tfa authenticators
- $authenticators = get_tfa($user);
- if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0 &&
- $app_passwd_data['eas'] !== true && $app_passwd_data['dav'] !== true) {
- // authenticators found, init TFA flow
- $_SESSION['pending_mailcow_cc_username'] = $user;
- $_SESSION['pending_mailcow_cc_role'] = "user";
- $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
- unset($_SESSION['ldelay']);
- $_SESSION['return'][] = array(
- 'type' => 'success',
- 'log' => array(__FUNCTION__, $user, '*'),
- 'msg' => array('logged_in_as', $user)
- );
- return "pending";
- } else if (!isset($authenticators['additional']) || !is_array($authenticators['additional']) || count($authenticators['additional']) == 0) {
- // no authenticators found, login successfull
- // Reactivate TFA if it was set to "deactivate TFA for next login"
- $stmt = $pdo->prepare("UPDATE `tfa` SET `active`='1' WHERE `username` = :user");
- $stmt->execute(array(':user' => $user));
-
- unset($_SESSION['ldelay']);
- return "user";
- }
- } elseif ($app_passwd_data['eas'] === true || $app_passwd_data['dav'] === true) {
- // password is a app password
- $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'])
- ));
-
- unset($_SESSION['ldelay']);
- return "user";
- }
- }
- }
-
- if (!isset($_SESSION['ldelay'])) {
- $_SESSION['ldelay'] = "0";
- $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']);
- }
- elseif (!isset($_SESSION['mailcow_cc_username'])) {
- $_SESSION['ldelay'] = $_SESSION['ldelay']+0.5;
- $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;
-}
function formatBytes($size, $precision = 2) {
if(!is_numeric($size)) {
return "0";
@@ -1028,58 +988,86 @@
// Check if the mailbox exists
$stmt = $pdo->prepare("SELECT username FROM mailbox WHERE username = :mailbox AND active = '1'");
$stmt->execute(array(':mailbox' => $mailbox));
- $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
if ($row){
$mailbox_exists = true;
}
}
- $query = "REPLACE INTO _sogo_static_view (`c_uid`, `domain`, `c_name`, `c_password`, `c_cn`, `mail`, `aliases`, `ad_aliases`, `ext_acl`, `kind`, `multiple_bookings`)
- SELECT
- mailbox.username,
- mailbox.domain,
- mailbox.username,
- IF(JSON_UNQUOTE(JSON_VALUE(attributes, '$.force_pw_update')) = '0',
- IF(JSON_UNQUOTE(JSON_VALUE(attributes, '$.sogo_access')) = 1, password, '{SSHA256}A123A123A321A321A321B321B321B123B123B321B432F123E321123123321321'),
- '{SSHA256}A123A123A321A321A321B321B321B123B123B321B432F123E321123123321321'),
- mailbox.name,
- mailbox.username,
- IFNULL(GROUP_CONCAT(ga.aliases ORDER BY ga.aliases SEPARATOR ' '), ''),
- IFNULL(gda.ad_alias, ''),
- IFNULL(external_acl.send_as_acl, ''),
- mailbox.kind,
- mailbox.multiple_bookings
- FROM
- mailbox
- LEFT OUTER JOIN grouped_mail_aliases ga ON ga.username REGEXP CONCAT('(^|,)', mailbox.username, '($|,)')
- LEFT OUTER JOIN grouped_domain_alias_address gda ON gda.username = mailbox.username
- LEFT OUTER JOIN grouped_sender_acl_external external_acl ON external_acl.username = mailbox.username
- WHERE
- mailbox.active = '1'";
-
+ // generate random password for sogo to deny direct login
+ $random_password = base64_encode(openssl_random_pseudo_bytes(24));
+ $random_salt = base64_encode(openssl_random_pseudo_bytes(16));
+ $random_hash = '{SSHA256}' . base64_encode(hash('sha256', base64_decode($password) . $salt, true) . $salt);
+
+ $subquery = "GROUP BY mailbox.username";
if ($mailbox_exists) {
- $query .= " AND mailbox.username = :mailbox";
- $stmt = $pdo->prepare($query);
- $stmt->execute(array(':mailbox' => $mailbox));
- } else {
- $query .= " GROUP BY mailbox.username";
- $stmt = $pdo->query($query);
+ $subquery = "AND mailbox.username = :mailbox";
}
-
+ $query = "INSERT INTO _sogo_static_view (`c_uid`, `domain`, `c_name`, `c_password`, `c_cn`, `mail`, `aliases`, `ad_aliases`, `ext_acl`, `kind`, `multiple_bookings`)
+ SELECT
+ mailbox.username,
+ mailbox.domain,
+ mailbox.username,
+ :random_hash,
+ mailbox.name,
+ mailbox.username,
+ IFNULL(GROUP_CONCAT(ga.aliases ORDER BY ga.aliases SEPARATOR ' '), ''),
+ IFNULL(gda.ad_alias, ''),
+ IFNULL(external_acl.send_as_acl, ''),
+ mailbox.kind,
+ mailbox.multiple_bookings
+ FROM
+ mailbox
+ LEFT OUTER JOIN grouped_mail_aliases ga ON ga.username REGEXP CONCAT('(^|,)', mailbox.username, '($|,)')
+ LEFT OUTER JOIN grouped_domain_alias_address gda ON gda.username = mailbox.username
+ LEFT OUTER JOIN grouped_sender_acl_external external_acl ON external_acl.username = mailbox.username
+ WHERE
+ mailbox.active = '1'
+ $subquery
+ ON DUPLICATE KEY UPDATE
+ `domain` = VALUES(`domain`),
+ `c_name` = VALUES(`c_name`),
+ `c_password` = VALUES(`c_password`),
+ `c_cn` = VALUES(`c_cn`),
+ `mail` = VALUES(`mail`),
+ `aliases` = VALUES(`aliases`),
+ `ad_aliases` = VALUES(`ad_aliases`),
+ `ext_acl` = VALUES(`ext_acl`),
+ `kind` = VALUES(`kind`),
+ `multiple_bookings` = VALUES(`multiple_bookings`)";
+
+
+ if ($mailbox_exists) {
+ $stmt = $pdo->prepare($query);
+ $stmt->execute(array(
+ ':random_hash' => $random_hash,
+ ':mailbox' => $mailbox
+ ));
+ } else {
+ $stmt = $pdo->prepare($query);
+ $stmt->execute(array(
+ ':random_hash' => $random_hash
+ ));
+ }
+
$stmt = $pdo->query("DELETE FROM _sogo_static_view WHERE `c_uid` NOT IN (SELECT `username` FROM `mailbox` WHERE `active` = '1');");
-
+
flush_memcached();
}
function edit_user_account($_data) {
global $lang;
global $pdo;
+
$_data_log = $_data;
!isset($_data_log['user_new_pass']) ?: $_data_log['user_new_pass'] = '*';
!isset($_data_log['user_new_pass2']) ?: $_data_log['user_new_pass2'] = '*';
!isset($_data_log['user_old_pass']) ?: $_data_log['user_old_pass'] = '*';
+
$username = $_SESSION['mailcow_cc_username'];
$role = $_SESSION['mailcow_cc_role'];
$password_old = $_data['user_old_pass'];
+ $pw_recovery_email = $_data['pw_recovery_email'];
+
if (filter_var($username, FILTER_VALIDATE_EMAIL === false) || $role != 'user') {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -1088,20 +1076,28 @@
);
return false;
}
- $stmt = $pdo->prepare("SELECT `password` FROM `mailbox`
- WHERE `kind` NOT REGEXP 'location|thing|group'
- AND `username` = :user");
- $stmt->execute(array(':user' => $username));
- $row = $stmt->fetch(PDO::FETCH_ASSOC);
- if (!verify_hash($row['password'], $password_old)) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_data_log),
- 'msg' => 'access_denied'
- );
- return false;
- }
- if (!empty($_data['user_new_pass']) && !empty($_data['user_new_pass2'])) {
+
+ // edit password
+ $is_forced_pw_update = !empty($_SESSION['pending_pw_update']);
+ if (((!empty($password_old) || $is_forced_pw_update) && !empty($_data['user_new_pass']) && !empty($_data['user_new_pass2']))) {
+ // Only verify old password if this is NOT a forced password update
+ if (!$is_forced_pw_update) {
+ $stmt = $pdo->prepare("SELECT `password` FROM `mailbox`
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `username` = :user AND authsource = 'mailcow'");
+ $stmt->execute(array(':user' => $username));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ if (!verify_hash($row['password'], $password_old)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_data_log),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+ }
+
$password_new = $_data['user_new_pass'];
$password_new2 = $_data['user_new_pass2'];
if (password_check($password_new, $password_new2) !== true) {
@@ -1111,13 +1107,50 @@
$stmt = $pdo->prepare("UPDATE `mailbox` SET `password` = :password_hashed,
`attributes` = JSON_SET(`attributes`, '$.force_pw_update', '0'),
`attributes` = JSON_SET(`attributes`, '$.passwd_update', NOW())
- WHERE `username` = :username");
+ WHERE `username` = :username AND authsource = 'mailcow'");
$stmt->execute(array(
':password_hashed' => $password_hashed,
':username' => $username
));
+ $_SESSION['pending_pw_update'] = false;
+
+ update_sogo_static_view();
}
- update_sogo_static_view();
+ // edit password recovery email
+ elseif (!empty($password_old) && isset($pw_recovery_email)) {
+ if (!isset($_SESSION['acl']['pw_reset']) || $_SESSION['acl']['pw_reset'] != "1" ) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ $stmt = $pdo->prepare("SELECT `password` FROM `mailbox`
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `username` = :user AND authsource = 'mailcow'");
+ $stmt->execute(array(':user' => $username));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ if (!verify_hash($row['password'], $password_old)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_data_log),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ $pw_recovery_email = (!filter_var($pw_recovery_email, FILTER_VALIDATE_EMAIL)) ? '' : $pw_recovery_email;
+ $stmt = $pdo->prepare("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.recovery_email', :recovery_email)
+ WHERE `username` = :username AND authsource = 'mailcow'");
+ $stmt->execute(array(
+ ':recovery_email' => $pw_recovery_email,
+ ':username' => $username
+ ));
+ }
+
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_data_log),
@@ -1145,7 +1178,7 @@
AND `goto` != :username_goto2
AND `address` != :username_address");
$stmt->execute(array(
- ':username_goto' => '(^|,)'.$username.'($|,)',
+ ':username_goto' => '(^|,)'.preg_quote($username, '/').'($|,)',
':username_goto2' => $username,
':username_address' => $username
));
@@ -1193,18 +1226,28 @@
$data['aliases_send_as_all'] = $row['send_as'];
}
$stmt = $pdo->prepare("SELECT IFNULL(GROUP_CONCAT(`address` SEPARATOR ', '), '') as `address` FROM `alias` WHERE `goto` REGEXP :username AND `address` LIKE '@%';");
- $stmt->execute(array(':username' => '(^|,)'.$username.'($|,)'));
+ $stmt->execute(array(':username' => '(^|,)'.preg_quote($username, '/').'($|,)'));
$run = $stmt->fetchAll(PDO::FETCH_ASSOC);
while ($row = array_shift($run)) {
$data['is_catch_all'] = $row['address'];
}
return $data;
}
-function is_valid_domain_name($domain_name) {
+function is_valid_domain_name($domain_name, $options = array()) {
if (empty($domain_name)) {
return false;
}
+
+ // Convert domain name to ASCII for validation
$domain_name = idn_to_ascii($domain_name, 0, INTL_IDNA_VARIANT_UTS46);
+
+ if (isset($options['allow_wildcard']) && $options['allow_wildcard'] == true) {
+ // Remove '*.' if wildcard subdomains are allowed
+ if (strpos($domain_name, '*.') === 0) {
+ $domain_name = substr($domain_name, 2);
+ }
+ }
+
return (preg_match("/^([a-z\d](-*[a-z\d])*)(\.([a-z\d](-*[a-z\d])*))*$/i", $domain_name)
&& preg_match("/^.{1,253}$/", $domain_name)
&& preg_match("/^[^\.]{1,63}(\.[^\.]{1,63})*$/", $domain_name));
@@ -1213,46 +1256,55 @@
global $pdo;
global $yubi;
global $tfa;
+ global $iam_settings;
+
$_data_log = $_data;
- $access_denied = null;
!isset($_data_log['confirm_password']) ?: $_data_log['confirm_password'] = '*';
- $username = $_SESSION['mailcow_cc_username'];
- // check for empty user and role
- if (!isset($_SESSION['mailcow_cc_role']) || empty($username)) $access_denied = true;
-
- // check admin confirm password
- if ($access_denied === null) {
- $stmt = $pdo->prepare("SELECT `password` FROM `admin`
- WHERE `username` = :username");
- $stmt->execute(array(':username' => $username));
- $row = $stmt->fetch(PDO::FETCH_ASSOC);
- if ($row) {
- if (!verify_hash($row['password'], $_data["confirm_password"])) $access_denied = true;
- else $access_denied = false;
+ // skip password check if this is a forced TFA enrollment after login
+ if (!empty($_SESSION['pending_tfa_setup'])) {
+ $username = $_SESSION['mailcow_cc_username'];
+ if (empty($username) || !isset($_SESSION['mailcow_cc_role'])) {
+ $_SESSION['return'][] = array('type' => 'danger', 'log' => array(__FUNCTION__, $_data_log), 'msg' => 'access_denied');
+ return false;
}
- }
+ } else {
+ $username = $_SESSION['mailcow_cc_username'];
+ $access_denied = null;
- // check mailbox confirm password
- if ($access_denied === null) {
- $stmt = $pdo->prepare("SELECT `password` FROM `mailbox`
- WHERE `username` = :username");
- $stmt->execute(array(':username' => $username));
- $row = $stmt->fetch(PDO::FETCH_ASSOC);
- if ($row) {
- if (!verify_hash($row['password'], $_data["confirm_password"])) $access_denied = true;
- else $access_denied = false;
+ if (!isset($_SESSION['mailcow_cc_role']) || empty($username)) $access_denied = true;
+
+ // check admin password
+ if ($access_denied === null) {
+ $stmt = $pdo->prepare("SELECT `password` FROM `admin` WHERE `username` = :username");
+ $stmt->execute(array(':username' => $username));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if ($row) {
+ if (!verify_hash($row['password'], $_data["confirm_password"])) $access_denied = true;
+ else $access_denied = false;
+ }
}
- }
- // set access_denied error
- if ($access_denied){
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_data_log),
- 'msg' => 'access_denied'
- );
- return false;
+ // check mailbox password
+ if ($access_denied === null) {
+ $stmt = $pdo->prepare("SELECT `password`, `authsource` FROM `mailbox` WHERE `username` = :username");
+ $stmt->execute(array(':username' => $username));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if ($row) {
+ if ($row['authsource'] == 'ldap'){
+ if (!ldap_mbox_login($username, $_data["confirm_password"], $iam_settings)) $access_denied = true;
+ else $access_denied = false;
+ } else {
+ if (!verify_hash($row['password'], $_data["confirm_password"])) $access_denied = true;
+ else $access_denied = false;
+ }
+ }
+ }
+
+ if ($access_denied) {
+ $_SESSION['return'][] = array('type' => 'danger', 'log' => array(__FUNCTION__, $_data_log), 'msg' => 'access_denied');
+ return false;
+ }
}
switch ($_data["tfa_method"]) {
@@ -1305,6 +1357,7 @@
);
return false;
}
+ unset($_SESSION['pending_tfa_setup']);
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_data_log),
@@ -1318,6 +1371,7 @@
//$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']));
+ unset($_SESSION['pending_tfa_setup']);
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_data_log),
@@ -1345,7 +1399,8 @@
$_data['registration']->certificate,
0
));
-
+
+ unset($_SESSION['pending_tfa_setup']);
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_data_log),
@@ -1353,6 +1408,25 @@
);
break;
case "none":
+ // Block TFA removal if force_tfa policy is active
+ $is_forced_tfa = false;
+ if ($_SESSION['mailcow_cc_role'] === 'user') {
+ $stmt_check = $pdo->prepare("SELECT JSON_EXTRACT(`attributes`, '$.force_tfa') FROM `mailbox` WHERE `username` = ?");
+ $stmt_check->execute(array($username));
+ $is_forced_tfa = ($stmt_check->fetchColumn() == '1');
+ } else {
+ $stmt_check = $pdo->prepare("SELECT JSON_EXTRACT(`attributes`, '$.force_tfa') FROM `admin` WHERE `username` = ?");
+ $stmt_check->execute(array($username));
+ $is_forced_tfa = ($stmt_check->fetchColumn() == '1');
+ }
+ if ($is_forced_tfa) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_data_log),
+ 'msg' => 'tfa_removal_blocked'
+ );
+ return false;
+ }
$stmt = $pdo->prepare("DELETE FROM `tfa` WHERE `username` = :username");
$stmt->execute(array(':username' => $username));
$_SESSION['return'][] = array(
@@ -1365,6 +1439,7 @@
}
function fido2($_data) {
global $pdo;
+ global $WebAuthn;
$_data_log = $_data;
// Not logging registration data, only actions
// Silent errors for "get" requests
@@ -1498,6 +1573,84 @@
'msg' => array('object_modified', htmlspecialchars($username))
);
break;
+ case "verify":
+ $role = "";
+ $tokenData = json_decode($_data['token']);
+ $clientDataJSON = base64_decode($tokenData->clientDataJSON);
+ $authenticatorData = base64_decode($tokenData->authenticatorData);
+ $signature = base64_decode($tokenData->signature);
+ $id = base64_decode($tokenData->id);
+ $challenge = $_SESSION['challenge'];
+ $process_fido2 = fido2(array("action" => "get_by_b64cid", "cid" => $tokenData->id));
+ if ($process_fido2['pub_key'] === false) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array("fido2_login", $_data['user'], $process_fido2['username']),
+ 'msg' => "login_failed"
+ );
+ return false;
+ }
+ try {
+ $WebAuthn->processGet($clientDataJSON, $authenticatorData, $signature, $process_fido2['pub_key'], $challenge, null, $GLOBALS['FIDO2_UV_FLAG_LOGIN'], $GLOBALS['FIDO2_USER_PRESENT_FLAG']);
+ }
+ catch (Throwable $ex) {
+ unset($process_fido2);
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array("fido2_login", $_data['user'], $process_fido2['username'], $ex->getMessage()),
+ 'msg' => "login_failed"
+ );
+ return false;
+ }
+ $return = new stdClass();
+ $return->success = true;
+ $stmt = $pdo->prepare("SELECT `superadmin` FROM `admin` WHERE `username` = :username");
+ $stmt->execute(array(':username' => $process_fido2['username']));
+ $obj_props = $stmt->fetch(PDO::FETCH_ASSOC);
+ if ($obj_props['superadmin'] === 1 && (!$_data['user'] || $_data['user'] == "admin")) {
+ $role = "admin";
+ }
+ elseif ($obj_props['superadmin'] === 0 && (!$_data['user'] || $_data['user'] == "domainadmin")) {
+ $role = "domainadmin";
+ }
+ elseif (!isset($obj_props['superadmin']) && (!$_data['user'] || $_data['user'] == "user")) {
+ $stmt = $pdo->prepare("SELECT `username` FROM `mailbox` WHERE `username` = :username");
+ $stmt->execute(array(':username' => $process_fido2['username']));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if ($row['username'] == $process_fido2['username']) {
+ $role = "user";
+ }
+ }
+ else {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array("fido2_login", $_data['user'], $process_fido2['username']),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+ if (empty($role)) {
+ session_unset();
+ session_destroy();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array("fido2_login", $_data['user'], $process_fido2['username']),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+ unset($_SESSION["challenge"]);
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array("fido2_login", $_data['user'], $process_fido2['username']),
+ 'msg' => array('logged_in_as', $process_fido2['username'])
+ );
+ return array(
+ "role" => $role,
+ "username" => $process_fido2['username'],
+ "cid" => $process_fido2['cid']
+ );
+ break;
}
}
function unset_tfa_key($_data) {
@@ -1515,7 +1668,7 @@
try {
if (!is_numeric($id)) $access_denied = true;
-
+
// set access_denied error
if ($access_denied){
$_SESSION['return'][] = array(
@@ -1524,7 +1677,27 @@
'msg' => 'access_denied'
);
return false;
- }
+ }
+
+ // Block key removal if force_tfa policy is active
+ $is_forced_tfa = false;
+ if ($_SESSION['mailcow_cc_role'] === 'user') {
+ $stmt_check = $pdo->prepare("SELECT JSON_EXTRACT(`attributes`, '$.force_tfa') FROM `mailbox` WHERE `username` = ?");
+ $stmt_check->execute(array($username));
+ $is_forced_tfa = ($stmt_check->fetchColumn() == '1');
+ } else {
+ $stmt_check = $pdo->prepare("SELECT JSON_EXTRACT(`attributes`, '$.force_tfa') FROM `admin` WHERE `username` = ?");
+ $stmt_check->execute(array($username));
+ $is_forced_tfa = ($stmt_check->fetchColumn() == '1');
+ }
+ if ($is_forced_tfa) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_data_log),
+ 'msg' => 'tfa_removal_blocked'
+ );
+ return false;
+ }
// check if it's last key
$stmt = $pdo->prepare("SELECT COUNT(*) AS `keys` FROM `tfa`
@@ -1558,9 +1731,18 @@
return false;
}
}
+function tfa_exists($username) {
+ global $pdo;
+ if (empty($username)) {
+ return false;
+ }
+ $stmt = $pdo->prepare("SELECT COUNT(*) as count FROM `tfa` WHERE `username` = :username");
+ $stmt->execute(array(':username' => $username));
+ return $stmt->fetch(PDO::FETCH_ASSOC)['count'] > 0;
+}
function get_tfa($username = null, $id = null) {
global $pdo;
- if (isset($_SESSION['mailcow_cc_username'])) {
+ if (empty($username) && isset($_SESSION['mailcow_cc_username'])) {
$username = $_SESSION['mailcow_cc_username'];
}
elseif (empty($username)) {
@@ -1573,7 +1755,7 @@
WHERE `username` = :username AND `active` = '1'");
$stmt->execute(array(':username' => $username));
$results = $stmt->fetchAll(PDO::FETCH_ASSOC);
-
+
// no tfa methods found
if (count($results) == 0) {
$data['name'] = 'none';
@@ -1781,8 +1963,8 @@
'msg' => array('webauthn_authenticator_failed')
);
return false;
- }
-
+ }
+
if (empty($process_webauthn['publicKey']) || $process_webauthn['publicKey'] === false) {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -2144,12 +2326,15 @@
'msg' => 'access_denied'
);
return false;
- }
+ }
- $allowed_origins = isset($data['allowed_origins']) ? $data['allowed_origins'] : array($_SERVER['SERVER_NAME']);
+ $allowed_origins = isset($data['allowed_origins']) ? $data['allowed_origins'] : array(getBaseURL());
$allowed_origins = !is_array($allowed_origins) ? array_filter(array_map('trim', explode("\n", $allowed_origins))) : $allowed_origins;
- foreach ($allowed_origins as $origin) {
- if (!filter_var($origin, FILTER_VALIDATE_DOMAIN, FILTER_FLAG_HOSTNAME) && $origin != '*') {
+ foreach ($allowed_origins as &$origin) {
+ if ($origin === '*') {
+ continue;
+ }
+ if (!valid_origin($origin)) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $action, $data),
@@ -2157,7 +2342,10 @@
);
return false;
}
+ // browsers always send a lowercase scheme/host in the Origin header, so normalize to match
+ $origin = strtolower($origin);
}
+ unset($origin);
$allowed_methods = isset($data['allowed_methods']) ? $data['allowed_methods'] : array('GET', 'POST', 'PUT', 'DELETE');
$allowed_methods = !is_array($allowed_methods) ? array_map('trim', preg_split( "/( |,|;|\n)/", $allowed_methods)) : $allowed_methods;
@@ -2177,7 +2365,7 @@
$redis->hMSet('CORS_SETTINGS', array(
'allowed_origins' => implode(', ', $allowed_origins),
'allowed_methods' => implode(', ', $allowed_methods)
- ));
+ ));
} catch (RedisException $e) {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -2205,34 +2393,43 @@
);
}
- $cors_settings = !$cors_settings ? array('allowed_origins' => $_SERVER['SERVER_NAME'], 'allowed_methods' => 'GET, POST, PUT, DELETE') : $cors_settings;
- $cors_settings['allowed_origins'] = empty($cors_settings['allowed_origins']) ? $_SERVER['SERVER_NAME'] : $cors_settings['allowed_origins'];
+ $cors_settings = !$cors_settings ? array('allowed_origins' => getBaseURL(), 'allowed_methods' => 'GET, POST, PUT, DELETE') : $cors_settings;
+ $cors_settings['allowed_origins'] = empty($cors_settings['allowed_origins']) ? getBaseURL() : $cors_settings['allowed_origins'];
$cors_settings['allowed_methods'] = empty($cors_settings['allowed_methods']) ? 'GET, POST, PUT, DELETE, OPTION' : $cors_settings['allowed_methods'];
return $cors_settings;
break;
case "set_headers":
$cors_settings = cors('get');
+ // normalize the stored list; it may still hold bare hostnames written before origins were validated as origins
+ $allowed_origins = array_filter(array_map('normalize_cors_origin', explode(',', $cors_settings['allowed_origins'])));
+ $origin = isset($_SERVER['HTTP_ORIGIN']) ? normalize_cors_origin($_SERVER['HTTP_ORIGIN']) : false;
// check if requested origin is in allowed origins
- $allowed_origins = explode(', ', $cors_settings['allowed_origins']);
- $cors_settings['allowed_origins'] = $allowed_origins[0];
- if (in_array('*', $allowed_origins)){
- $cors_settings['allowed_origins'] = '*';
- } else if (in_array($_SERVER['HTTP_ORIGIN'], $allowed_origins)) {
- $cors_settings['allowed_origins'] = $_SERVER['HTTP_ORIGIN'];
+ $allow_origin = null;
+ if (in_array('*', $allowed_origins, true)) {
+ $allow_origin = '*';
+ } else if ($origin !== false && in_array($origin, $allowed_origins, true)) {
+ $allow_origin = $origin;
}
// always allow OPTIONS for preflight request
$cors_settings["allowed_methods"] = empty($cors_settings["allowed_methods"]) ? 'OPTIONS' : $cors_settings["allowed_methods"] . ', ' . 'OPTIONS';
- header('Access-Control-Allow-Origin: ' . $cors_settings['allowed_origins']);
+ // a disallowed origin gets no Access-Control-Allow-Origin at all; echoing a different origin than the requesting one tells a browser nothing
+ if ($allow_origin !== null) {
+ header('Access-Control-Allow-Origin: ' . $allow_origin);
+ }
+ if ($allow_origin !== '*') {
+ // the response depends on the request origin, keep caches from mixing them up
+ header('Vary: Origin', false);
+ }
header('Access-Control-Allow-Methods: '. $cors_settings['allowed_methods']);
header('Access-Control-Allow-Headers: Accept, Content-Type, X-Api-Key, Origin');
// Access-Control settings requested, this is just a preflight request
- if ($_SERVER['REQUEST_METHOD'] == 'OPTIONS' &&
+ if ($_SERVER['REQUEST_METHOD'] == 'OPTIONS' &&
isset($_SERVER['HTTP_ACCESS_CONTROL_REQUEST_METHOD']) &&
isset($_SERVER['HTTP_ACCESS_CONTROL_REQUEST_HEADERS'])) {
-
+
$allowed_methods = explode(', ', $cors_settings["allowed_methods"]);
if (in_array($_SERVER['HTTP_ACCESS_CONTROL_REQUEST_METHOD'], $allowed_methods, true))
// method allowed send 200 OK
@@ -2246,9 +2443,25 @@
break;
}
}
-function getBaseURL() {
- $protocol = isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? 'https' : 'http';
- $host = $_SERVER['HTTP_HOST'];
+function getBaseURL($protocol = null) {
+ // Get current server name
+ $host = strtolower($_SERVER['SERVER_NAME']);
+
+ // craft allowed server name list
+ $mailcow_hostname = strtolower(getenv("MAILCOW_HOSTNAME"));
+ $additional_server_names = strtolower(getenv("ADDITIONAL_SERVER_NAMES")) ?: "";
+ $additional_server_names = preg_replace('/\s+/', '', $additional_server_names);
+ $allowed_server_names = $additional_server_names !== "" ? explode(',', $additional_server_names) : array();
+ array_push($allowed_server_names, $mailcow_hostname);
+
+ // Fallback to MAILCOW HOSTNAME if current server name is not in allowed list
+ if (!in_array($host, $allowed_server_names)) {
+ $host = $mailcow_hostname;
+ }
+
+ if (!isset($protocol)) {
+ $protocol = isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? 'https' : 'http';
+ }
$base_url = $protocol . '://' . $host;
return $base_url;
@@ -2261,7 +2474,1141 @@
return vsprintf('%s%s-%s-%s-%s-%s%s%s', str_split(bin2hex($data), 4));
}
+function identity_provider($_action = null, $_data = null, $_extra = null) {
+ global $pdo;
+ global $iam_provider;
+ global $iam_settings;
+ $data_log = $_data;
+ if (isset($data_log['client_secret'])) $data_log['client_secret'] = '*';
+ if (isset($data_log['access_token'])) $data_log['access_token'] = '*';
+
+ switch ($_action) {
+ case 'get':
+ $settings = array();
+ $stmt = $pdo->prepare("SELECT * FROM `identity_provider`;");
+ $stmt->execute();
+ $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
+ foreach($rows as $row){
+ switch ($row["key"]) {
+ case "redirect_url_extra":
+ case "mappers":
+ case "templates":
+ $settings[$row["key"]] = json_decode($row["value"]);
+ break;
+ case "use_ssl":
+ case "use_tls":
+ case "login_provisioning":
+ case "ignore_ssl_errors":
+ $settings[$row["key"]] = boolval($row["value"]);
+ break;
+ default:
+ $settings[$row["key"]] = $row["value"];
+ break;
+ }
+ }
+ // set login_provisioning if not exists
+ if (!array_key_exists('login_provisioning', $settings)) {
+ $settings['login_provisioning'] = 1;
+ }
+ // return default client_scopes for generic-oidc if none is set
+ if ($settings["authsource"] == "generic-oidc" && empty($settings["client_scopes"])){
+ $settings["client_scopes"] = "openid profile email mailcow_template";
+ }
+ if ($_extra['hide_sensitive']){
+ $settings['client_secret'] = '';
+ $settings['access_token'] = '';
+ }
+ // return default ldap options
+ if ($settings["authsource"] == "ldap"){
+ $settings['use_ssl'] = !isset($settings['use_ssl']) ? false : $settings['use_ssl'];
+ $settings['use_tls'] = !isset($settings['use_tls']) ? false : $settings['use_tls'];
+ $settings['ignore_ssl_errors'] = !isset($settings['ignore_ssl_errors']) ? false : $settings['ignore_ssl_errors'];
+ }
+ return $settings;
+ break;
+ case 'edit':
+ if ($_SESSION['mailcow_cc_role'] != "admin") {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_data),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+ if (!isset($_data['authsource'])){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $data_log),
+ 'msg' => array('required_data_missing', '')
+ );
+ return false;
+ }
+
+ $available_authsources = array(
+ "keycloak",
+ "generic-oidc",
+ "ldap"
+ );
+ $_data['authsource'] = strtolower($_data['authsource']);
+ if (!in_array($_data['authsource'], $available_authsources)){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $data_log),
+ 'msg' => array('invalid_authsource', $setting)
+ );
+ return false;
+ }
+
+ $stmt = $pdo->prepare("SELECT * FROM `mailbox`
+ WHERE `authsource` != 'mailcow'
+ AND `authsource` IS NOT NULL
+ AND `authsource` != :authsource");
+ $stmt->execute(array(':authsource' => $_data['authsource']));
+ $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
+ if ($rows) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $data_log),
+ 'msg' => array('authsource_in_use', $setting)
+ );
+ return false;
+ }
+
+ $_data['ignore_ssl_error'] = isset($_data['ignore_ssl_error']) ? boolval($_data['ignore_ssl_error']) : false;
+ $_data['login_provisioning'] = isset($_data['login_provisioning']) ? boolval($_data['login_provisioning']) : false;
+ switch ($_data['authsource']) {
+ case "keycloak":
+ $_data['server_url'] = (!empty($_data['server_url'])) ? rtrim($_data['server_url'], '/') : null;
+ $_data['mailpassword_flow'] = isset($_data['mailpassword_flow']) ? intval($_data['mailpassword_flow']) : 0;
+ $_data['periodic_sync'] = isset($_data['periodic_sync']) ? intval($_data['periodic_sync']) : 0;
+ $_data['import_users'] = isset($_data['import_users']) ? intval($_data['import_users']) : 0;
+ $_data['sync_interval'] = (!empty($_data['sync_interval'])) ? intval($_data['sync_interval']) : 15;
+ $_data['sync_interval'] = $_data['sync_interval'] < 1 ? 1 : $_data['sync_interval'];
+ $required_settings = array('authsource', 'server_url', 'realm', 'client_id', 'client_secret', 'redirect_url', 'version', 'mailpassword_flow', 'periodic_sync', 'import_users', 'sync_interval', 'ignore_ssl_error', 'login_provisioning');
+ break;
+ case "generic-oidc":
+ $_data['authorize_url'] = (!empty($_data['authorize_url'])) ? $_data['authorize_url'] : null;
+ $_data['token_url'] = (!empty($_data['token_url'])) ? $_data['token_url'] : null;
+ $_data['userinfo_url'] = (!empty($_data['userinfo_url'])) ? $_data['userinfo_url'] : null;
+ $_data['client_scopes'] = (!empty($_data['client_scopes'])) ? $_data['client_scopes'] : "openid profile email mailcow_template";
+ $required_settings = array('authsource', 'authorize_url', 'token_url', 'client_id', 'client_secret', 'redirect_url', 'userinfo_url', 'client_scopes', 'ignore_ssl_error', 'login_provisioning');
+ break;
+ case "ldap":
+ $_data['host'] = (!empty($_data['host'])) ? str_replace(" ", "", $_data['host']) : "";
+ $_data['port'] = (!empty($_data['port'])) ? intval($_data['port']) : 389;
+ $_data['username_field'] = (!empty($_data['username_field'])) ? strtolower($_data['username_field']) : "mail";
+ $_data['attribute_field'] = (!empty($_data['attribute_field'])) ? strtolower($_data['attribute_field']) : "";
+ $_data['filter'] = (!empty($_data['filter'])) ? $_data['filter'] : "";
+ $_data['periodic_sync'] = isset($_data['periodic_sync']) ? intval($_data['periodic_sync']) : 0;
+ $_data['import_users'] = isset($_data['import_users']) ? intval($_data['import_users']) : 0;
+ $_data['use_ssl'] = isset($_data['use_ssl']) ? boolval($_data['use_ssl']) : false;
+ $_data['use_tls'] = isset($_data['use_tls']) && !$_data['use_ssl'] ? boolval($_data['use_tls']) : false;
+ $_data['sync_interval'] = (!empty($_data['sync_interval'])) ? intval($_data['sync_interval']) : 15;
+ $_data['sync_interval'] = $_data['sync_interval'] < 1 ? 1 : $_data['sync_interval'];
+ $required_settings = array('authsource', 'host', 'port', 'basedn', 'username_field', 'filter', 'attribute_field', 'binddn', 'bindpass', 'periodic_sync', 'import_users', 'sync_interval', 'use_ssl', 'use_tls', 'ignore_ssl_error', 'login_provisioning');
+ break;
+ }
+
+ $pdo->beginTransaction();
+ $stmt = $pdo->prepare("INSERT INTO identity_provider (`key`, `value`) VALUES (:key, :value) ON DUPLICATE KEY UPDATE `value` = VALUES(`value`);");
+ // add connection settings
+ foreach($required_settings as $setting){
+ if (!isset($_data[$setting])){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $data_log),
+ 'msg' => array('required_data_missing', $setting)
+ );
+ $pdo->rollback();
+ return false;
+ }
+
+ $stmt->bindParam(':key', $setting);
+ $stmt->bindParam(':value', $_data[$setting]);
+ $stmt->execute();
+ }
+ $pdo->commit();
+
+ // add redirect_url_extra
+ if (isset($_data['redirect_url_extra'])){
+ $_data['redirect_url_extra'] = (!is_array($_data['redirect_url_extra'])) ? array($_data['redirect_url_extra']) : $_data['redirect_url_extra'];
+
+ $redirect_url_extra = array_filter($_data['redirect_url_extra']);
+ $redirect_url_extra = json_encode($redirect_url_extra);
+
+ $stmt = $pdo->prepare("INSERT INTO identity_provider (`key`, `value`) VALUES ('redirect_url_extra', :value) ON DUPLICATE KEY UPDATE `value` = VALUES(`value`);");
+ $stmt->bindParam(':value', $redirect_url_extra);
+ $stmt->execute();
+ }
+
+ // add default template
+ if (isset($_data['default_template'])) {
+ $_data['default_template'] = (empty($_data['default_template'])) ? "" : $_data['default_template'];
+ $stmt = $pdo->prepare("INSERT INTO identity_provider (`key`, `value`) VALUES ('default_template', :value) ON DUPLICATE KEY UPDATE `value` = VALUES(`value`);");
+ $stmt->bindParam(':value', $_data['default_template']);
+ $stmt->execute();
+ }
+
+ // add mappers
+ if (isset($_data['mappers']) && isset($_data['templates'])){
+ $_data['mappers'] = (!is_array($_data['mappers'])) ? array($_data['mappers']) : $_data['mappers'];
+ $_data['templates'] = (!is_array($_data['templates'])) ? array($_data['templates']) : $_data['templates'];
+
+ $mappers = array_filter($_data['mappers']);
+ $templates = array_filter($_data['templates']);
+ if (count($mappers) == count($templates)){
+ $mappers = json_encode($mappers);
+ $templates = json_encode($templates);
+
+ $stmt = $pdo->prepare("INSERT INTO identity_provider (`key`, `value`) VALUES ('mappers', :value) ON DUPLICATE KEY UPDATE `value` = VALUES(`value`);");
+ $stmt->bindParam(':value', $mappers);
+ $stmt->execute();
+ $stmt = $pdo->prepare("INSERT INTO identity_provider (`key`, `value`) VALUES ('templates', :value) ON DUPLICATE KEY UPDATE `value` = VALUES(`value`);");
+ $stmt->bindParam(':value', $templates);
+ $stmt->execute();
+ }
+ }
+
+ // delete old access_token
+ $stmt = $pdo->query("INSERT INTO identity_provider (`key`, `value`) VALUES ('access_token', '') ON DUPLICATE KEY UPDATE `value` = VALUES(`value`);");
+
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_action, $data_log),
+ 'msg' => array('object_modified', '')
+ );
+ return true;
+ break;
+ case 'test':
+ if ($_SESSION['mailcow_cc_role'] != "admin") {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_data),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ switch ($_data['authsource']) {
+ case 'keycloak':
+ $url = "{$_data['server_url']}/realms/{$_data['realm']}/protocol/openid-connect/token";
+ $req = http_build_query(array(
+ 'grant_type' => 'client_credentials',
+ 'client_id' => $_data['client_id'],
+ 'client_secret' => $_data['client_secret']
+ ));
+ $curl = curl_init();
+ curl_setopt($curl, CURLOPT_URL, $url);
+ curl_setopt($curl, CURLOPT_TIMEOUT, 7);
+ curl_setopt($curl, CURLOPT_POST, 1);
+ curl_setopt($curl, CURLOPT_POSTFIELDS, $req);
+ curl_setopt($curl, CURLOPT_HTTPHEADER, array('Content-Type: application/x-www-form-urlencoded'));
+ curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
+ if ($_data['ignore_ssl_error'] == "1"){
+ curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
+ curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
+ }
+ $res = curl_exec($curl);
+ $code = curl_getinfo($curl, CURLINFO_HTTP_CODE);
+ curl_close ($curl);
+
+ if ($code != 200) {
+ return false;
+ }
+ break;
+ case 'generic-oidc':
+ $url = $_data['token_url'];
+ $curl = curl_init();
+ curl_setopt($curl, CURLOPT_URL, $url);
+ curl_setopt($curl, CURLOPT_TIMEOUT, 7);
+ curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
+ curl_setopt($curl, CURLOPT_CUSTOMREQUEST, "OPTIONS");
+ if ($_data['ignore_ssl_error'] == "1"){
+ curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
+ curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
+ }
+ $res = curl_exec($curl);
+ $code = curl_getinfo($curl, CURLINFO_HTTP_CODE);
+ curl_close ($curl);
+
+ if ($code != 200) {
+ return false;
+ }
+ break;
+ case 'ldap':
+ if (!$_data['host'] || !$_data['port'] || !$_data['basedn'] ||
+ !$_data['binddn'] || !$_data['bindpass']){
+ return false;
+ }
+ $_data['use_ssl'] = isset($_data['use_ssl']) ? boolval($_data['use_ssl']) : false;
+ $_data['use_tls'] = isset($_data['use_tls']) && !$_data['use_ssl'] ? boolval($_data['use_tls']) : false;
+ $_data['ignore_ssl_error'] = isset($_data['ignore_ssl_error']) ? boolval($_data['ignore_ssl_error']) : false;
+ $options = array();
+ if ($_data['ignore_ssl_error']) {
+ $options[LDAP_OPT_X_TLS_REQUIRE_CERT] = LDAP_OPT_X_TLS_NEVER;
+ }
+ $provider = new \LdapRecord\Connection([
+ 'hosts' => explode(",", $_data['host']),
+ 'port' => $_data['port'],
+ 'base_dn' => $_data['basedn'],
+ 'username' => $_data['binddn'],
+ 'password' => $_data['bindpass'],
+ 'use_ssl' => $_data['use_ssl'],
+ 'use_tls' => $_data['use_tls'],
+ 'options' => $options
+ ]);
+ try {
+ $provider->connect();
+ } catch (Throwable $e) {
+ return false;
+ }
+ break;
+ }
+
+ return true;
+ break;
+ case "delete":
+ if ($_SESSION['mailcow_cc_role'] != "admin") {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_data),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ $stmt = $pdo->query("SELECT * FROM `mailbox`
+ WHERE `authsource` != 'mailcow'
+ AND `authsource` IS NOT NULL");
+ $rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
+ if ($rows) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $data_log),
+ 'msg' => array('authsource_in_use', $setting)
+ );
+ return false;
+ }
+
+ $stmt = $pdo->query("DELETE FROM identity_provider;");
+
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_action, $data_log),
+ 'msg' => array('item_deleted', '')
+ );
+ return true;
+ break;
+ case "init":
+ $settings = identity_provider('get');
+ $provider = null;
+
+ switch ($settings['authsource']) {
+ case "keycloak":
+ if ($settings['server_url'] && $settings['realm'] && $settings['client_id'] &&
+ $settings['client_secret'] && $settings['redirect_url'] && $settings['version']){
+ $guzzyClient = new GuzzleHttp\Client([
+ 'defaults' => [
+ \GuzzleHttp\RequestOptions::CONNECT_TIMEOUT => 5,
+ \GuzzleHttp\RequestOptions::ALLOW_REDIRECTS => true],
+ \GuzzleHttp\RequestOptions::VERIFY => !$settings['ignore_ssl_error'],
+ ]
+ );
+ $provider = new Stevenmaguire\OAuth2\Client\Provider\Keycloak([
+ 'authServerUrl' => $settings['server_url'],
+ 'realm' => $settings['realm'],
+ 'clientId' => $settings['client_id'],
+ 'clientSecret' => $settings['client_secret'],
+ 'redirectUri' => $settings['redirect_url'],
+ 'version' => $settings['version'],
+ // 'encryptionAlgorithm' => 'RS256', // optional
+ // 'encryptionKeyPath' => '../key.pem' // optional
+ // 'encryptionKey' => 'contents_of_key_or_certificate' // optional
+ ]);
+ $provider->setHttpClient($guzzyClient);
+ }
+ break;
+ case "generic-oidc":
+ if ($settings['client_id'] && $settings['client_secret'] && $settings['redirect_url'] &&
+ $settings['authorize_url'] && $settings['token_url'] && $settings['userinfo_url']){
+ $guzzyClient = new GuzzleHttp\Client([
+ 'defaults' => [
+ \GuzzleHttp\RequestOptions::CONNECT_TIMEOUT => 5,
+ \GuzzleHttp\RequestOptions::ALLOW_REDIRECTS => true],
+ \GuzzleHttp\RequestOptions::VERIFY => !$settings['ignore_ssl_error'],
+ ]
+ );
+ $provider = new \League\OAuth2\Client\Provider\GenericProvider([
+ 'clientId' => $settings['client_id'],
+ 'clientSecret' => $settings['client_secret'],
+ 'redirectUri' => $settings['redirect_url'],
+ 'urlAuthorize' => $settings['authorize_url'],
+ 'urlAccessToken' => $settings['token_url'],
+ 'urlResourceOwnerDetails' => $settings['userinfo_url'],
+ 'scopes' => $settings['client_scopes']
+ ]);
+ $provider->setHttpClient($guzzyClient);
+ }
+ break;
+ case "ldap":
+ if ($settings['host'] && $settings['port'] && $settings['basedn'] &&
+ $settings['binddn'] && $settings['bindpass']){
+ $options = array();
+ if ($settings['ignore_ssl_error']) {
+ $options[LDAP_OPT_X_TLS_REQUIRE_CERT] = LDAP_OPT_X_TLS_NEVER;
+ }
+ $provider = new \LdapRecord\Connection([
+ 'hosts' => explode(",", $settings['host']),
+ 'port' => $settings['port'],
+ 'base_dn' => $settings['basedn'],
+ 'username' => $settings['binddn'],
+ 'password' => $settings['bindpass'],
+ 'use_ssl' => $settings['use_ssl'],
+ 'use_tls' => $settings['use_tls'],
+ 'options' => $options
+ ]);
+ try {
+ $provider->connect();
+ } catch (Throwable $e) {
+ $provider = null;
+ }
+ }
+ break;
+ }
+ return $provider;
+ break;
+ case "verify-sso":
+ if ($iam_settings['authsource'] != 'keycloak' && $iam_settings['authsource'] != 'generic-oidc'){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, "no OIDC provider configured"),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+
+ try {
+ $token = $iam_provider->getAccessToken('authorization_code', ['code' => $_GET['code']]);
+ $plain_token = $token->getToken();
+ $plain_refreshtoken = $token->getRefreshToken();
+ $info = $iam_provider->getResourceOwner($token)->toArray();
+ } catch (Throwable $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $e->getMessage()),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+ // check if email address is given
+ if (empty($info['email'])) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, 'No email address found for user'),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+
+ // get mapped template
+ $user_template = $info['mailcow_template'];
+ $mapper_key = array_search($user_template, $iam_settings['mappers']);
+
+ // token valid, get mailbox
+ $stmt = $pdo->prepare("SELECT
+ mailbox.*,
+ domain.active AS d_active
+ FROM `mailbox`
+ INNER JOIN domain on mailbox.domain = domain.domain
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $info['email']));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if ($row){
+ if (!in_array($row['authsource'], array("keycloak", "generic-oidc"))) {
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $info['email'], "The user's authentication source is not of type OIDC"),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+ if ($mapper_key !== false) {
+ // update user
+ $_SESSION['access_all_exception'] = '1';
+ mailbox('edit', 'mailbox_from_template', array(
+ 'username' => $info['email'],
+ 'name' => $info['name'],
+ 'template' => $iam_settings['templates'][$mapper_key]
+ ));
+ $_SESSION['access_all_exception'] = '0';
+
+ // get updated row
+ $stmt = $pdo->prepare("SELECT
+ mailbox.*,
+ domain.active AS d_active
+ FROM `mailbox`
+ INNER JOIN domain on mailbox.domain = domain.domain
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $info['email']));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ }
+ if ($row['active'] != 1 || $row['d_active'] != 1) {
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $info['email'], 'Domain or mailbox is inactive'),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+ set_user_loggedin_session($info['email']);
+ $_SESSION['iam_token'] = $plain_token;
+ $_SESSION['iam_refresh_token'] = $plain_refreshtoken;
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role']),
+ 'msg' => array('logged_in_as', $_SESSION['mailcow_cc_username'])
+ );
+ return true;
+ }
+
+ // user doesn't exist, check if login provisioning is enabled
+ if (!$iam_settings['login_provisioning']){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, "Auto-create users on login is deactivated"),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+
+ if (empty($iam_settings['mappers']) || empty($user_template) || $mapper_key === false){
+ if (!empty($iam_settings['default_template'])) {
+ $mbox_template = $iam_settings['default_template'];
+ } else {
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $info['email'], 'No matching attribute mapping was found'),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+ } else {
+ $mbox_template = $iam_settings['templates'][$mapper_key];
+ }
+
+ // create mailbox
+ $_SESSION['access_all_exception'] = '1';
+ $create_res = mailbox('add', 'mailbox_from_template', array(
+ 'domain' => explode('@', $info['email'])[1],
+ 'local_part' => explode('@', $info['email'])[0],
+ 'name' => $info['name'],
+ 'authsource' => $iam_settings['authsource'],
+ 'template' => $mbox_template
+ ));
+ $_SESSION['access_all_exception'] = '0';
+ if (!$create_res){
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $info['email'], 'Could not create mailbox on login'),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+
+ // double check if mailbox and domain is active
+ $stmt = $pdo->prepare("SELECT * FROM `mailbox`
+ INNER JOIN domain on mailbox.domain = domain.domain
+ WHERE `kind` NOT REGEXP 'location|thing|group'
+ AND `mailbox`.`active`='1'
+ AND `domain`.`active`='1'
+ AND `username` = :user");
+ $stmt->execute(array(':user' => $info['email']));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if (empty($row)) {
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $info['email'], 'Domain or mailbox is inactive'),
+ 'msg' => 'login_failed'
+ );
+ return false;
+ }
+
+ set_user_loggedin_session($info['email']);
+ $_SESSION['iam_token'] = $plain_token;
+ $_SESSION['iam_refresh_token'] = $plain_refreshtoken;
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role']),
+ 'msg' => array('logged_in_as', $_SESSION['mailcow_cc_username'])
+ );
+ return true;
+ break;
+ case "refresh-token":
+ try {
+ $token = $iam_provider->getAccessToken('refresh_token', ['refresh_token' => $_SESSION['iam_refresh_token']]);
+ $plain_token = $token->getToken();
+ $plain_refreshtoken = $token->getRefreshToken();
+ $info = $iam_provider->getResourceOwner($token)->toArray();
+ } catch (Throwable $e) {
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__),
+ 'msg' => array('refresh_login_failed', $e->getMessage())
+ );
+ return false;
+ }
+
+ if (empty($info['email'])){
+ clear_session();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role']),
+ 'msg' => 'refresh_login_failed'
+ );
+ return false;
+ }
+
+ set_user_loggedin_session($info['email']);
+ $_SESSION['iam_token'] = $plain_token;
+ $_SESSION['iam_refresh_token'] = $plain_refreshtoken;
+ return true;
+ break;
+ case "get-redirect":
+ if ($iam_settings['authsource'] != 'keycloak' && $iam_settings['authsource'] != 'generic-oidc')
+ return false;
+ $options = [];
+ if (isset($iam_settings['redirect_url_extra'])) {
+ // check if the current domain is used in an extra redirect URL
+ $targetDomain = strtolower($_SERVER['HTTP_HOST']);
+ foreach ($iam_settings['redirect_url_extra'] as $testUrl) {
+ $testUrlParsed = parse_url($testUrl);
+ if (isset($testUrlParsed['host']) && strtolower($testUrlParsed['host']) == $targetDomain) {
+ $options['redirect_uri'] = $testUrl;
+ break;
+ }
+ }
+ }
+ $authUrl = $iam_provider->getAuthorizationUrl($options);
+ $_SESSION['oauth2state'] = $iam_provider->getState();
+ return $authUrl;
+ break;
+ case "get-keycloak-admin-token":
+ // get access_token for service account of mailcow client
+ if ($iam_settings['authsource'] !== 'keycloak') return false;
+ if (isset($iam_settings['access_token'])) {
+ // check if access_token is valid
+ $url = "{$iam_settings['server_url']}/realms/{$iam_settings['realm']}/protocol/openid-connect/token/introspect";
+ $req = http_build_query(array(
+ 'token' => $iam_settings['access_token'],
+ 'client_id' => $iam_settings['client_id'],
+ 'client_secret' => $iam_settings['client_secret']
+ ));
+ $curl = curl_init();
+ curl_setopt($curl, CURLOPT_URL, $url);
+ curl_setopt($curl, CURLOPT_TIMEOUT, 7);
+ curl_setopt($curl, CURLOPT_POST, 1);
+ curl_setopt($curl, CURLOPT_POSTFIELDS, $req);
+ curl_setopt($curl, CURLOPT_HTTPHEADER, array('Content-Type: application/x-www-form-urlencoded'));
+ curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
+ curl_setopt($curl, CURLOPT_TIMEOUT, 5);
+ $res = json_decode(curl_exec($curl), true);
+ $code = curl_getinfo($curl, CURLINFO_HTTP_CODE);
+ curl_close ($curl);
+ if ($code == 200 && $res['active'] == true) {
+ // token is valid
+ return $iam_settings['access_token'];
+ }
+ }
+
+ $url = "{$iam_settings['server_url']}/realms/{$iam_settings['realm']}/protocol/openid-connect/token";
+ $req = http_build_query(array(
+ 'grant_type' => 'client_credentials',
+ 'client_id' => $iam_settings['client_id'],
+ 'client_secret' => $iam_settings['client_secret']
+ ));
+ $curl = curl_init();
+ curl_setopt($curl, CURLOPT_URL, $url);
+ curl_setopt($curl, CURLOPT_TIMEOUT, 7);
+ curl_setopt($curl, CURLOPT_POST, 1);
+ curl_setopt($curl, CURLOPT_POSTFIELDS, $req);
+ curl_setopt($curl, CURLOPT_HTTPHEADER, array('Content-Type: application/x-www-form-urlencoded'));
+ curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
+ curl_setopt($curl, CURLOPT_TIMEOUT, 5);
+ $res = json_decode(curl_exec($curl), true);
+ $code = curl_getinfo($curl, CURLINFO_HTTP_CODE);
+ curl_close ($curl);
+ if ($code != 200) {
+ return false;
+ }
+
+ $stmt = $pdo->prepare("INSERT INTO identity_provider (`key`, `value`) VALUES (:key, :value) ON DUPLICATE KEY UPDATE `value` = VALUES(`value`);");
+ $stmt->execute(array(
+ ':key' => 'access_token',
+ ':value' => $res['access_token']
+ ));
+ return $res['access_token'];
+ break;
+ }
+}
+function reset_password($action, $data = null) {
+ global $pdo;
+ global $redis;
+ global $mailcow_hostname;
+ global $PW_RESET_TOKEN_LIMIT;
+ global $PW_RESET_TOKEN_LIFETIME;
+
+ $_data_log = $data;
+ if (isset($_data_log['new_password'])) $_data_log['new_password'] = '*';
+ if (isset($_data_log['new_password2'])) $_data_log['new_password2'] = '*';
+
+ switch ($action) {
+ case 'check':
+ $token = $data;
+
+ $stmt = $pdo->prepare("SELECT `t1`.`username` FROM `reset_password` AS `t1` JOIN `mailbox` AS `t2` ON `t1`.`username` = `t2`.`username` WHERE `t1`.`token` = :token AND `t1`.`created` > DATE_SUB(NOW(), INTERVAL :lifetime MINUTE) AND `t2`.`active` = 1 AND `t2`.`authsource` = 'mailcow';");
+ $stmt->execute(array(
+ ':token' => preg_replace('/[^a-zA-Z0-9-]/', '', $token),
+ ':lifetime' => $PW_RESET_TOKEN_LIFETIME
+ ));
+ $return = $stmt->fetch(PDO::FETCH_ASSOC);
+ return empty($return['username']) ? false : $return['username'];
+ break;
+ case 'issue':
+ $username = $data;
+
+ // perform cleanup
+ $stmt = $pdo->prepare("DELETE FROM `reset_password` WHERE created < DATE_SUB(NOW(), INTERVAL :lifetime MINUTE);");
+ $stmt->execute(array(':lifetime' => $PW_RESET_TOKEN_LIFETIME));
+
+ if (filter_var($username, FILTER_VALIDATE_EMAIL) === false) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ $pw_reset_notification = reset_password('get_notification', 'raw');
+ if (!$pw_reset_notification) return false;
+ if (empty($pw_reset_notification['from']) || empty($pw_reset_notification['subject'])) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'password_reset_na'
+ );
+ return false;
+ }
+
+ $stmt = $pdo->prepare("SELECT * FROM `mailbox`
+ WHERE `username` = :username AND authsource = 'mailcow'");
+ $stmt->execute(array(':username' => $username));
+ $mailbox_data = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ if (empty($mailbox_data)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'password_reset_invalid_user'
+ );
+ return false;
+ }
+
+ $mailbox_attr = json_decode($mailbox_data['attributes'], true);
+ if (empty($mailbox_attr['recovery_email']) || filter_var($mailbox_attr['recovery_email'], FILTER_VALIDATE_EMAIL) === false) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => "password_reset_invalid_user"
+ );
+ return false;
+ }
+
+ $stmt = $pdo->prepare("SELECT * FROM `reset_password`
+ WHERE `username` = :username");
+ $stmt->execute(array(':username' => $username));
+ $generated_token_count = count($stmt->fetchAll(PDO::FETCH_ASSOC));
+ if ($generated_token_count >= $PW_RESET_TOKEN_LIMIT) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => "reset_token_limit_exceeded"
+ );
+ return false;
+ }
+
+ $token = implode('-', array(
+ strtoupper(bin2hex(random_bytes(3))),
+ strtoupper(bin2hex(random_bytes(3))),
+ strtoupper(bin2hex(random_bytes(3))),
+ strtoupper(bin2hex(random_bytes(3))),
+ strtoupper(bin2hex(random_bytes(3)))
+ ));
+
+ $stmt = $pdo->prepare("INSERT INTO `reset_password` (`username`, `token`)
+ VALUES (:username, :token)");
+ $stmt->execute(array(
+ ':username' => $username,
+ ':token' => $token
+ ));
+
+ $reset_link = getBaseURL() . "/reset-password?token=" . $token;
+
+ $request_date = new DateTime();
+ $locale_date = locale_get_default();
+ $date_formatter = new IntlDateFormatter(
+ $locale_date,
+ IntlDateFormatter::FULL,
+ IntlDateFormatter::FULL
+ );
+ $formatted_request_date = $date_formatter->format($request_date);
+
+ // set template vars
+ // subject
+ $pw_reset_notification['subject'] = str_replace('{{hostname}}', $mailcow_hostname, $pw_reset_notification['subject']);
+ $pw_reset_notification['subject'] = str_replace('{{link}}', $reset_link, $pw_reset_notification['subject']);
+ $pw_reset_notification['subject'] = str_replace('{{username}}', $username, $pw_reset_notification['subject']);
+ $pw_reset_notification['subject'] = str_replace('{{username2}}', $mailbox_attr['recovery_email'], $pw_reset_notification['subject']);
+ $pw_reset_notification['subject'] = str_replace('{{date}}', $formatted_request_date, $pw_reset_notification['subject']);
+ $pw_reset_notification['subject'] = str_replace('{{token_lifetime}}', $PW_RESET_TOKEN_LIFETIME, $pw_reset_notification['subject']);
+ // text
+ $pw_reset_notification['text_tmpl'] = str_replace('{{hostname}}', $mailcow_hostname, $pw_reset_notification['text_tmpl']);
+ $pw_reset_notification['text_tmpl'] = str_replace('{{link}}', $reset_link, $pw_reset_notification['text_tmpl']);
+ $pw_reset_notification['text_tmpl'] = str_replace('{{username}}', $username, $pw_reset_notification['text_tmpl']);
+ $pw_reset_notification['text_tmpl'] = str_replace('{{username2}}', $mailbox_attr['recovery_email'], $pw_reset_notification['text_tmpl']);
+ $pw_reset_notification['text_tmpl'] = str_replace('{{date}}', $formatted_request_date, $pw_reset_notification['text_tmpl']);
+ $pw_reset_notification['text_tmpl'] = str_replace('{{token_lifetime}}', $PW_RESET_TOKEN_LIFETIME, $pw_reset_notification['text_tmpl']);
+ // html
+ $pw_reset_notification['html_tmpl'] = str_replace('{{hostname}}', $mailcow_hostname, $pw_reset_notification['html_tmpl']);
+ $pw_reset_notification['html_tmpl'] = str_replace('{{link}}', $reset_link, $pw_reset_notification['html_tmpl']);
+ $pw_reset_notification['html_tmpl'] = str_replace('{{username}}', $username, $pw_reset_notification['html_tmpl']);
+ $pw_reset_notification['html_tmpl'] = str_replace('{{username2}}', $mailbox_attr['recovery_email'], $pw_reset_notification['html_tmpl']);
+ $pw_reset_notification['html_tmpl'] = str_replace('{{date}}', $formatted_request_date, $pw_reset_notification['html_tmpl']);
+ $pw_reset_notification['html_tmpl'] = str_replace('{{token_lifetime}}', $PW_RESET_TOKEN_LIFETIME, $pw_reset_notification['html_tmpl']);
+
+
+ $email_sent = reset_password('send_mail', array(
+ "from" => $pw_reset_notification['from'],
+ "to" => $mailbox_attr['recovery_email'],
+ "subject" => $pw_reset_notification['subject'],
+ "text" => $pw_reset_notification['text_tmpl'],
+ "html" => $pw_reset_notification['html_tmpl']
+ ));
+
+ if (!$email_sent){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => "recovery_email_failed"
+ );
+ return false;
+ }
+
+ list($localPart, $domainPart) = explode('@', $mailbox_attr['recovery_email']);
+ if (strlen($localPart) > 1) {
+ $maskedLocalPart = $localPart[0] . str_repeat('*', strlen($localPart) - 1);
+ } else {
+ $maskedLocalPart = "*";
+ }
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => array("recovery_email_sent", $maskedLocalPart . '@' . $domainPart)
+ );
+ return array(
+ "username" => $username,
+ "issue" => "success"
+ );
+ break;
+ case 'reset':
+ $token = $data['token'];
+ $new_password = $data['new_password'];
+ $new_password2 = $data['new_password2'];
+ $username = $data['username'];
+ $check_tfa = $data['check_tfa'];
+
+ if (!$username || !$token) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'invalid_reset_token'
+ );
+ return false;
+ }
+
+ # check new password
+ if (!password_check($new_password, $new_password2)) {
+ return false;
+ }
+
+ if ($check_tfa){
+ // check for tfa authenticators
+ $authenticators = get_tfa($username);
+ if (isset($authenticators['additional']) && is_array($authenticators['additional']) && count($authenticators['additional']) > 0) {
+ $_SESSION['pending_mailcow_cc_username'] = $username;
+ $_SESSION['pending_pw_reset_token'] = $token;
+ $_SESSION['pending_pw_new_password'] = $new_password;
+ $_SESSION['pending_tfa_methods'] = $authenticators['additional'];
+ $_SESSION['return'][] = array(
+ 'type' => 'info',
+ 'log' => array(__FUNCTION__, $user, '*'),
+ 'msg' => 'awaiting_tfa_confirmation'
+ );
+ return false;
+ }
+ }
+
+ # set new password
+ $password_hashed = hash_password($new_password);
+ $stmt = $pdo->prepare("UPDATE `mailbox` SET
+ `password` = :password_hashed,
+ `attributes` = JSON_SET(`attributes`, '$.passwd_update', NOW())
+ WHERE `username` = :username AND authsource = 'mailcow'");
+ $stmt->execute(array(
+ ':password_hashed' => $password_hashed,
+ ':username' => $username
+ ));
+
+ // perform cleanup
+ $stmt = $pdo->prepare("DELETE FROM `reset_password` WHERE `username` = :username;");
+ $stmt->execute(array(
+ ':username' => $username
+ ));
+
+ update_sogo_static_view($username);
+
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'password_changed_success'
+ );
+ return true;
+ break;
+ case 'get_notification':
+ $type = $data;
+
+ try {
+ $settings['from'] = $redis->Get('PW_RESET_FROM');
+ $settings['subject'] = $redis->Get('PW_RESET_SUBJ');
+ $settings['html_tmpl'] = $redis->Get('PW_RESET_HTML');
+ $settings['text_tmpl'] = $redis->Get('PW_RESET_TEXT');
+ if (empty($settings['html_tmpl']) && empty($settings['text_tmpl'])) {
+ $settings['html_tmpl'] = file_get_contents("/tpls/pw_reset_html.tpl");
+ $settings['text_tmpl'] = file_get_contents("/tpls/pw_reset_text.tpl");
+ }
+
+ if ($type != "raw") {
+ $settings['html_tmpl'] = htmlspecialchars($settings['html_tmpl']);
+ $settings['text_tmpl'] = htmlspecialchars($settings['text_tmpl']);
+ }
+ }
+ catch (RedisException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => array('redis_error', $e)
+ );
+ return false;
+ }
+
+ return $settings;
+ break;
+ case 'send_mail':
+ $from = $data['from'];
+ $to = $data['to'];
+ $text = $data['text'];
+ $html = $data['html'];
+ $subject = $data['subject'];
+
+ if (!filter_var($from, FILTER_VALIDATE_EMAIL)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'from_invalid'
+ );
+ return false;
+ }
+ if (!filter_var($to, FILTER_VALIDATE_EMAIL)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'to_invalid'
+ );
+ return false;
+ }
+ if (empty($subject)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'subject_empty'
+ );
+ return false;
+ }
+ if (empty($text)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'text_empty'
+ );
+ return false;
+ }
+
+ ini_set('max_execution_time', 0);
+ ini_set('max_input_time', 0);
+ $mail = new PHPMailer;
+ $mail->Timeout = 10;
+ $mail->SMTPOptions = array(
+ 'ssl' => array(
+ 'verify_peer' => false,
+ 'verify_peer_name' => false,
+ 'allow_self_signed' => true
+ )
+ );
+ $mail->isSMTP();
+ $mail->Host = 'postfix-mailcow';
+ $mail->SMTPAuth = false;
+ $mail->Port = 25;
+ $mail->setFrom($from);
+ $mail->Subject = $subject;
+ $mail->CharSet ="UTF-8";
+ if (!empty($html)) {
+ $mail->Body = $html;
+ $mail->AltBody = $text;
+ }
+ else {
+ $mail->Body = $text;
+ }
+ $mail->XMailer = 'MooMail';
+ $mail->AddAddress($to);
+ if (!$mail->send()) {
+ return false;
+ }
+ $mail->ClearAllRecipients();
+
+ return true;
+ break;
+ }
+
+ if ($_SESSION['mailcow_cc_role'] != "admin") {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ switch ($action) {
+ case 'edit_notification':
+ $subject = $data['subject'];
+ $from = preg_replace('/[\x00-\x1F\x80-\xFF]/', '', $data['from']);
+
+ $from = (!filter_var($from, FILTER_VALIDATE_EMAIL)) ? "" : $from;
+ $subject = (empty($subject)) ? "" : $subject;
+ $text = (empty($data['text_tmpl'])) ? "" : $data['text_tmpl'];
+ $html = (empty($data['html_tmpl'])) ? "" : $data['html_tmpl'];
+
+ try {
+ $redis->Set('PW_RESET_FROM', $from);
+ $redis->Set('PW_RESET_SUBJ', $subject);
+ $redis->Set('PW_RESET_HTML', $html);
+ $redis->Set('PW_RESET_TEXT', $text);
+ }
+ catch (RedisException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => array('redis_error', $e)
+ );
+ return false;
+ }
+
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $action, $_data_log),
+ 'msg' => 'saved_settings'
+ );
+ break;
+ }
+}
+function clear_session(){
+ session_regenerate_id(true);
+ session_unset();
+ session_destroy();
+ session_write_close();
+}
+function set_user_loggedin_session($user) {
+ session_regenerate_id(true);
+ $_SESSION['mailcow_cc_username'] = $user;
+ $_SESSION['mailcow_cc_role'] = 'user';
+ $sogo_sso_pass = file_get_contents("/etc/sogo-sso/sogo-sso.pass");
+ $_SESSION['sogo-sso-user-allowed'][] = $user;
+ $_SESSION['sogo-sso-pass'] = $sogo_sso_pass;
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+}
+function protect_route($allowed_roles = ['admin', 'domainadmin', 'user'], $redirects = []) {
+ // Check if user is authenticated
+ if (!isset($_SESSION['mailcow_cc_role'])) {
+ if (isset($redirects['unauthenticated'])) {
+ header('Location: ' . $redirects['unauthenticated']);
+ } else {
+ // Send a deep link to the login page for its area instead of the user login at /,
+ // e.g. /admin/dashboard -> /admin rather than /
+ $request_uri = isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : '/';
+ if (strpos($request_uri, '/admin/') === 0) {
+ header('Location: /admin');
+ } elseif (strpos($request_uri, '/domainadmin/') === 0) {
+ header('Location: /domainadmin');
+ } else {
+ header('Location: /');
+ }
+ }
+ exit();
+ }
+
+ // Check for pending actions (2FA setup, password update)
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ $pending_redirect = '/';
+ if ($_SESSION['mailcow_cc_role'] === 'admin') {
+ $pending_redirect = '/admin';
+ } elseif ($_SESSION['mailcow_cc_role'] === 'domainadmin') {
+ $pending_redirect = '/domainadmin';
+ }
+ header('Location: ' . $pending_redirect);
+ exit();
+ }
+
+ // Check if user's role is in the allowed roles for the route
+ if (!in_array($_SESSION['mailcow_cc_role'], $allowed_roles)) {
+ if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'admin') {
+ header('Location: /admin/dashboard');
+ exit();
+ }
+ elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'domainadmin') {
+ header('Location: /domainadmin/mailbox');
+ exit();
+ }
+ elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'user') {
+ header('Location: /user');
+ exit();
+ }
+ else {
+ header('Location: /');
+ exit();
+ }
+ }
+}
function get_logs($application, $lines = false) {
if ($lines === false) {
$lines = $GLOBALS['LOG_LINES'] - 1;
@@ -2336,6 +3683,20 @@
return $data_array;
}
}
+ if ($application == "cron-mailcow") {
+ if (isset($from) && isset($to)) {
+ $data = $redis->lRange('CRON_LOG', $from - 1, $to - 1);
+ }
+ else {
+ $data = $redis->lRange('CRON_LOG', 0, $lines);
+ }
+ if ($data) {
+ foreach ($data as $json_line) {
+ $data_array[] = json_decode($json_line, true);
+ }
+ return $data_array;
+ }
+ }
if ($application == "postfix-mailcow") {
if (isset($from) && isset($to)) {
$data = $redis->lRange('POSTFIX_MAILLOG', $from - 1, $to - 1);
@@ -2497,50 +3858,6 @@
.substr($charid,16, 4).$hyphen
.substr($charid,20,12);
}
-function solr_status() {
- $curl = curl_init();
- $endpoint = 'http://solr:8983/solr/admin/cores';
- $params = array(
- 'action' => 'STATUS',
- 'core' => 'dovecot-fts',
- 'indexInfo' => 'true'
- );
- $url = $endpoint . '?' . http_build_query($params);
- curl_setopt($curl, CURLOPT_URL, $url);
- curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt($curl, CURLOPT_POST, 0);
- curl_setopt($curl, CURLOPT_TIMEOUT, 10);
- $response_core = curl_exec($curl);
- if ($response_core === false) {
- $err = curl_error($curl);
- curl_close($curl);
- return false;
- }
- else {
- curl_close($curl);
- $curl = curl_init();
- $status_core = json_decode($response_core, true);
- $url = 'http://solr:8983/solr/admin/info/system';
- curl_setopt($curl, CURLOPT_URL, $url);
- curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt($curl, CURLOPT_POST, 0);
- curl_setopt($curl, CURLOPT_TIMEOUT, 10);
- $response_sysinfo = curl_exec($curl);
- if ($response_sysinfo === false) {
- $err = curl_error($curl);
- curl_close($curl);
- return false;
- }
- else {
- curl_close($curl);
- $status_sysinfo = json_decode($response_sysinfo, true);
- $status = array_merge($status_core, $status_sysinfo);
- return (!empty($status['status']['dovecot-fts']) && !empty($status['jvm']['memory'])) ? $status : false;
- }
- return (!empty($status['status']['dovecot-fts'])) ? $status['status']['dovecot-fts'] : false;
- }
- return false;
-}
function cleanupJS($ignore = '', $folder = '/tmp/*.js') {
$now = time();
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 00c11de..37ccbd8 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
@@ -4,9 +4,15 @@
global $redis;
global $lang;
global $MAILBOX_DEFAULT_ATTRIBUTES;
+ global $iam_settings;
+
$_data_log = $_data;
!isset($_data_log['password']) ?: $_data_log['password'] = '*';
!isset($_data_log['password2']) ?: $_data_log['password2'] = '*';
+
+ // Track mailboxes affected by alias operations for incremental SOGo updates
+ $update_sogo_mailboxes = array();
+
switch ($_action) {
case 'add':
switch ($_type) {
@@ -35,19 +41,29 @@
else {
$username = $_SESSION['mailcow_cc_username'];
}
- if (isset($_data["validity"]) && !filter_var($_data["validity"], FILTER_VALIDATE_INT, array('options' => array('min_range' => 1, 'max_range' => 87600)))) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
- 'msg' => 'validity_missing'
- );
- return false;
+ if (isset($_data["validity"])) {
+ if (!filter_var($_data["validity"], FILTER_VALIDATE_INT, array('options' => array('min_range' => 1, 'max_range' => 87600)))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'validity_missing'
+ );
+ return false;
+ }
}
else {
// Default to 1 yr
$_data["validity"] = 8760;
}
+ if (isset($_data["permanent"]) && filter_var($_data["permanent"], FILTER_VALIDATE_BOOL)) {
+ $permanent = 1;
+ }
+ else {
+ $permanent = 0;
+ }
$domain = $_data['domain'];
+ // spamalias.description is NOT NULL, an absent description must not become a null insert
+ $description = $_data['description'] ?? '';
$valid_domains[] = mailbox('get', 'mailbox_details', $username)['domain'];
$valid_alias_domains = user_get_alias_details($username)['alias_domains'];
if (!empty($valid_alias_domains)) {
@@ -62,12 +78,14 @@
return false;
}
$validity = strtotime("+" . $_data["validity"] . " hour");
- $stmt = $pdo->prepare("INSERT INTO `spamalias` (`address`, `goto`, `validity`) VALUES
- (:address, :goto, :validity)");
+ $stmt = $pdo->prepare("INSERT INTO `spamalias` (`address`, `description`, `goto`, `validity`, `permanent`) VALUES
+ (:address, :description, :goto, :validity, :permanent)");
$stmt->execute(array(
':address' => readable_random_string(rand(rand(3, 9), rand(3, 9))) . '.' . readable_random_string(rand(rand(3, 9), rand(3, 9))) . '@' . $domain,
+ ':description' => $description,
':goto' => $username,
- ':validity' => $validity
+ ':validity' => $validity,
+ ':permanent' => $permanent
));
$_SESSION['return'][] = array(
'type' => 'success',
@@ -184,6 +202,7 @@
'msg' => 'global_filter_written'
);
return true;
+ break;
case 'filter':
$sieve = new Sieve\SieveParser();
if (!isset($_SESSION['acl']['filters']) || $_SESSION['acl']['filters'] != "1" ) {
@@ -679,15 +698,17 @@
return true;
break;
case 'alias':
- $addresses = array_map('trim', preg_split( "/( |,|;|\n)/", $_data['address']));
- $gotos = array_map('trim', preg_split( "/( |,|;|\n)/", $_data['goto']));
- $active = intval($_data['active']);
- $sogo_visible = intval($_data['sogo_visible']);
- $goto_null = intval($_data['goto_null']);
- $goto_spam = intval($_data['goto_spam']);
- $goto_ham = intval($_data['goto_ham']);
+ $addresses = array_map('trim', preg_split( "/( |,|;|\n)/", $_data['address']));
+ $gotos = array_map('trim', preg_split( "/( |,|;|\n)/", $_data['goto']));
+ $internal = intval($_data['internal']);
+ $active = intval($_data['active']);
+ $sender_allowed = intval($_data['sender_allowed']);
+ $sogo_visible = intval($_data['sogo_visible']);
+ $goto_null = intval($_data['goto_null']);
+ $goto_spam = intval($_data['goto_spam']);
+ $goto_ham = intval($_data['goto_ham']);
$private_comment = $_data['private_comment'];
- $public_comment = $_data['public_comment'];
+ $public_comment = $_data['public_comment'];
if (strlen($private_comment) > 160 | strlen($public_comment) > 160){
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -729,6 +750,18 @@
$goto_domain = idn_to_ascii(substr(strstr($goto, '@'), 1), 0, INTL_IDNA_VARIANT_UTS46);
$goto_local_part = strstr($goto, '@', true);
$goto = $goto_local_part.'@'.$goto_domain;
+ // Deny external goto domains: global switch (all roles) overrides the per-DA ACL
+ if (($GLOBALS['ALIAS_DISABLE_EXTERNAL_DOMAINS'] === true ||
+ (isset($_SESSION['acl']['alias_external_goto']) && $_SESSION['acl']['alias_external_goto'] != "1")) &&
+ !is_local_mailcow_domain($goto_domain)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => array('external_goto_denied', htmlspecialchars($goto))
+ );
+ unset($gotos[$i]);
+ continue;
+ }
$stmt = $pdo->prepare("SELECT `username` FROM `mailbox`
WHERE `kind` REGEXP 'location|thing|group'
AND `username`= :goto");
@@ -837,8 +870,8 @@
);
continue;
}
- $stmt = $pdo->prepare("INSERT INTO `alias` (`address`, `public_comment`, `private_comment`, `goto`, `domain`, `sogo_visible`, `active`)
- VALUES (:address, :public_comment, :private_comment, :goto, :domain, :sogo_visible, :active)");
+ $stmt = $pdo->prepare("INSERT INTO `alias` (`address`, `public_comment`, `private_comment`, `goto`, `domain`, `sogo_visible`, `internal`, `sender_allowed`, `active`)
+ VALUES (:address, :public_comment, :private_comment, :goto, :domain, :sogo_visible, :internal, :sender_allowed, :active)");
if (!filter_var($address, FILTER_VALIDATE_EMAIL) === true) {
$stmt->execute(array(
':address' => '@'.$domain,
@@ -848,6 +881,8 @@
':goto' => $goto,
':domain' => $domain,
':sogo_visible' => $sogo_visible,
+ ':internal' => $internal,
+ ':sender_allowed' => $sender_allowed,
':active' => $active
));
}
@@ -859,6 +894,8 @@
':goto' => $goto,
':domain' => $domain,
':sogo_visible' => $sogo_visible,
+ ':internal' => $internal,
+ ':sender_allowed' => $sender_allowed,
':active' => $active
));
}
@@ -868,6 +905,17 @@
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('alias_added', $address, $id)
);
+
+ // Track affected mailboxes for SOGo update
+ if (!empty($goto)) {
+ $gotos = array_map('trim', explode(',', $goto));
+ foreach ($gotos as $g) {
+ if (filter_var($g, FILTER_VALIDATE_EMAIL) &&
+ !in_array($g, array('null@localhost', 'spam@localhost', 'ham@localhost'))) {
+ $update_sogo_mailboxes[] = $g;
+ }
+ }
+ }
}
break;
case 'alias_domain':
@@ -1002,6 +1050,7 @@
$local_part = strtolower(trim($_data['local_part']));
$domain = idn_to_ascii(strtolower(trim($_data['domain'])), 0, INTL_IDNA_VARIANT_UTS46);
$username = $local_part . '@' . $domain;
+ $authsource = 'mailcow';
if (!filter_var($username, FILTER_VALIDATE_EMAIL)) {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -1018,15 +1067,19 @@
);
return false;
}
+ if ($_data['authsource'] == "mailcow" ||
+ in_array($_data['authsource'], array('keycloak', 'generic-oidc', 'ldap')) && $iam_settings['authsource'] == $_data['authsource']){
+ $authsource = $_data['authsource'];
+ }
if (empty($name)) {
$name = $local_part;
}
$template_attr = null;
if ($_data['template']){
- $template_attr = mailbox('get', 'mailbox_templates', $_data['template'])['attributes'];
+ $template_attr = mailbox('get', 'mailbox_templates', $_data['template'], $_extra)['attributes'];
}
if (empty($template_attr)) {
- $template_attr = mailbox('get', 'mailbox_templates')[0]['attributes'];
+ $template_attr = mailbox('get', 'mailbox_templates', null, $_extra)[0]['attributes'];
}
$MAILBOX_DEFAULT_ATTRIBUTES = array_merge($MAILBOX_DEFAULT_ATTRIBUTES, $template_attr);
@@ -1035,7 +1088,12 @@
$name = ltrim(rtrim($_data['name'], '>'), '<');
$tags = (isset($_data['tags'])) ? $_data['tags'] : $MAILBOX_DEFAULT_ATTRIBUTES['tags'];
$quota_m = (isset($_data['quota'])) ? intval($_data['quota']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['quota']) / 1024 ** 2;
- if ((!isset($_SESSION['acl']['unlimited_quota']) || $_SESSION['acl']['unlimited_quota'] != "1") && $quota_m === 0) {
+ if ($authsource != 'mailcow'){
+ $password = '';
+ $password2 = '';
+ $password_hashed = '';
+ }
+ if (!hasACLAccess("unlimited_quota") && $quota_m === 0) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -1050,9 +1108,12 @@
$_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;
+ $_data['eas_access'] = (in_array('eas', $_data['protocol_access'])) ? 1 : 0;
+ $_data['dav_access'] = (in_array('dav', $_data['protocol_access'])) ? 1 : 0;
}
$active = (isset($_data['active'])) ? intval($_data['active']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['active']);
$force_pw_update = (isset($_data['force_pw_update'])) ? intval($_data['force_pw_update']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['force_pw_update']);
+ $force_tfa = (isset($_data['force_tfa'])) ? intval($_data['force_tfa']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['force_tfa']);
$tls_enforce_in = (isset($_data['tls_enforce_in'])) ? intval($_data['tls_enforce_in']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['tls_enforce_in']);
$tls_enforce_out = (isset($_data['tls_enforce_out'])) ? intval($_data['tls_enforce_out']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['tls_enforce_out']);
$sogo_access = (isset($_data['sogo_access'])) ? intval($_data['sogo_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['sogo_access']);
@@ -1060,13 +1121,32 @@
$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']);
+ $eas_access = (isset($_data['eas_access'])) ? intval($_data['eas_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['eas_access']);
+ $dav_access = (isset($_data['dav_access'])) ? intval($_data['dav_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['dav_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']);
+ // Validate quarantine_category
+ if (!in_array($quarantine_category, array('add_header', 'reject', 'all'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'quarantine_category_invalid'
+ );
+ return false;
+ }
$quota_b = ($quota_m * 1048576);
+ $attribute_hash = (!empty($_data['attribute_hash'])) ? $_data['attribute_hash'] : '';
+ if (in_array($authsource, array('keycloak', 'generic-oidc', 'ldap'))){
+ $force_pw_update = 0;
+ }
+ if ($authsource == 'generic-oidc'){
+ $force_tfa = 0;
+ }
$mailbox_attrs = json_encode(
array(
'force_pw_update' => strval($force_pw_update),
+ 'force_tfa' => strval($force_tfa),
'tls_enforce_in' => strval($tls_enforce_in),
'tls_enforce_out' => strval($tls_enforce_out),
'sogo_access' => strval($sogo_access),
@@ -1074,11 +1154,14 @@
'pop3_access' => strval($pop3_access),
'smtp_access' => strval($smtp_access),
'sieve_access' => strval($sieve_access),
+ 'eas_access' => strval($eas_access),
+ 'dav_access' => strval($dav_access),
'relayhost' => strval($relayhost),
'passwd_update' => time(),
'mailbox_format' => strval($MAILBOX_DEFAULT_ATTRIBUTES['mailbox_format']),
'quarantine_notification' => strval($quarantine_notification),
- 'quarantine_category' => strval($quarantine_category)
+ 'quarantine_category' => strval($quarantine_category),
+ 'attribute_hash' => $attribute_hash
)
);
if (!is_valid_domain_name($domain)) {
@@ -1153,10 +1236,12 @@
);
return false;
}
- if (password_check($password, $password2) !== true) {
- return false;
+ if ($authsource == 'mailcow'){
+ if (password_check($password, $password2) !== true) {
+ return false;
+ }
+ $password_hashed = hash_password($password);
}
- $password_hashed = hash_password($password);
if ($MailboxData['count'] >= $DomainData['mailboxes']) {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -1182,8 +1267,8 @@
);
return false;
}
- $stmt = $pdo->prepare("INSERT INTO `mailbox` (`username`, `password`, `name`, `quota`, `local_part`, `domain`, `attributes`, `active`)
- VALUES (:username, :password_hashed, :name, :quota_b, :local_part, :domain, :mailbox_attrs, :active)");
+ $stmt = $pdo->prepare("INSERT INTO `mailbox` (`username`, `password`, `name`, `quota`, `local_part`, `domain`, `attributes`, `authsource`, `active`)
+ VALUES (:username, :password_hashed, :name, :quota_b, :local_part, :domain, :mailbox_attrs, :authsource, :active)");
$stmt->execute(array(
':username' => $username,
':password_hashed' => $password_hashed,
@@ -1192,6 +1277,7 @@
':local_part' => $local_part,
':domain' => $domain,
':mailbox_attrs' => $mailbox_attrs,
+ ':authsource' => $authsource,
':active' => $active
));
$stmt = $pdo->prepare("UPDATE `mailbox` SET
@@ -1200,6 +1286,14 @@
$stmt->execute(array(
':username' => $username
));
+ // save delimiter_action
+ if (isset($_data['tagged_mail_handler'])) {
+ mailbox('edit', 'delimiter_action', array(
+ 'username' => $username,
+ 'tagged_mail_handler' => $_data['tagged_mail_handler']
+ ));
+ }
+
// save tags
foreach($tags as $index => $tag){
if (empty($tag)) continue;
@@ -1211,11 +1305,14 @@
);
break;
}
- $stmt = $pdo->prepare("INSERT INTO `tags_mailbox` (`username`, `tag_name`) VALUES (:username, :tag_name)");
- $stmt->execute(array(
- ':username' => $username,
- ':tag_name' => $tag,
- ));
+ try {
+ $stmt = $pdo->prepare("INSERT INTO `tags_mailbox` (`username`, `tag_name`) VALUES (:username, :tag_name)");
+ $stmt->execute(array(
+ ':username' => $username,
+ ':tag_name' => $tag,
+ ));
+ } catch (Exception $e) {
+ }
}
$stmt = $pdo->prepare("INSERT INTO `quota2` (`username`, `bytes`, `messages`)
VALUES (:username, '0', '0') ON DUPLICATE KEY UPDATE `bytes` = '0', `messages` = '0';");
@@ -1232,7 +1329,7 @@
':active' => $active
));
-
+
if (isset($_data['acl'])) {
$_data['acl'] = (array)$_data['acl'];
$_data['spam_alias'] = (in_array('spam_alias', $_data['acl'])) ? 1 : 0;
@@ -1249,6 +1346,7 @@
$_data['quarantine_notification'] = (in_array('quarantine_notification', $_data['acl'])) ? 1 : 0;
$_data['quarantine_category'] = (in_array('quarantine_category', $_data['acl'])) ? 1 : 0;
$_data['app_passwds'] = (in_array('app_passwds', $_data['acl'])) ? 1 : 0;
+ $_data['pw_reset'] = (in_array('pw_reset', $_data['acl'])) ? 1 : 0;
} else {
$_data['spam_alias'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_spam_alias']);
$_data['tls_policy'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_tls_policy']);
@@ -1263,15 +1361,16 @@
$_data['quarantine_attachments'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_quarantine_attachments']);
$_data['quarantine_notification'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_quarantine_notification']);
$_data['quarantine_category'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_quarantine_category']);
- $_data['app_passwds'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_app_passwds']);
+ $_data['app_passwds'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_app_passwds']);
+ $_data['pw_reset'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['acl_pw_reset']);
}
try {
- $stmt = $pdo->prepare("INSERT INTO `user_acl`
+ $stmt = $pdo->prepare("INSERT INTO `user_acl`
(`username`, `spam_alias`, `tls_policy`, `spam_score`, `spam_policy`, `delimiter_action`, `syncjobs`, `eas_reset`, `sogo_profile_reset`,
- `pushover`, `quarantine`, `quarantine_attachments`, `quarantine_notification`, `quarantine_category`, `app_passwds`)
+ `pushover`, `quarantine`, `quarantine_attachments`, `quarantine_notification`, `quarantine_category`, `app_passwds`, `pw_reset`)
VALUES (:username, :spam_alias, :tls_policy, :spam_score, :spam_policy, :delimiter_action, :syncjobs, :eas_reset, :sogo_profile_reset,
- :pushover, :quarantine, :quarantine_attachments, :quarantine_notification, :quarantine_category, :app_passwds) ");
+ :pushover, :quarantine, :quarantine_attachments, :quarantine_notification, :quarantine_category, :app_passwds, :pw_reset) ");
$stmt->execute(array(
':username' => $username,
':spam_alias' => $_data['spam_alias'],
@@ -1287,7 +1386,8 @@
':quarantine_attachments' => $_data['quarantine_attachments'],
':quarantine_notification' => $_data['quarantine_notification'],
':quarantine_category' => $_data['quarantine_category'],
- ':app_passwds' => $_data['app_passwds']
+ ':app_passwds' => $_data['app_passwds'],
+ ':pw_reset' => $_data['pw_reset']
));
}
catch (PDOException $e) {
@@ -1306,16 +1406,129 @@
'object' => $username,
'rl_frame' => $_data['rl_frame'],
'rl_value' => $_data['rl_value']
- ));
+ ), $_extra);
}
- update_sogo_static_view($username);
+ // Track affected mailboxes for SOGo update
+ $update_sogo_mailboxes[] = $username;
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('mailbox_added', htmlspecialchars($username))
);
- return true;
+ break;
+ case 'mailbox_from_template':
+ $stmt = $pdo->prepare("SELECT * FROM `templates`
+ WHERE `template` = :template AND type = 'mailbox'");
+ $stmt->execute(array(
+ ":template" => $_data['template']
+ ));
+ $mbox_template_data = $stmt->fetch(PDO::FETCH_ASSOC);
+ if (empty($mbox_template_data)){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'template_missing'
+ );
+ return false;
+ }
+
+ $attribute_hash = sha1(json_encode($mbox_template_data["attributes"]));
+ $mbox_template_data = json_decode($mbox_template_data["attributes"], true);
+ $mbox_template_data['domain'] = $_data['domain'];
+ $mbox_template_data['name'] = $_data['name'];
+ $mbox_template_data['local_part'] = $_data['local_part'];
+ $mbox_template_data['authsource'] = $_data['authsource'];
+ $mbox_template_data['attribute_hash'] = $attribute_hash;
+ $mbox_template_data['quota'] = intval($mbox_template_data['quota'] / 1048576);
+
+ $mailbox_attributes = array('acl' => array());
+ foreach ($mbox_template_data as $key => $value){
+ switch (true) {
+ case (strpos($key, 'acl_') === 0 && $value != 0):
+ array_push($mailbox_attributes['acl'], str_replace('acl_' , '', $key));
+ break;
+ default:
+ $mailbox_attributes[$key] = $value;
+ break;
+ }
+ }
+
+ return mailbox('add', 'mailbox', $mailbox_attributes);
+ break;
+ case 'mta_sts':
+ $domain = idn_to_ascii(strtolower(trim($_data['domain'])), 0, INTL_IDNA_VARIANT_UTS46);
+ $version = strtolower($_data['version']);
+ $mode = strtolower($_data['mode']);
+ $mx = explode(",", preg_replace('/\s+/', '', $_data['mx']));
+ $max_age = intval($_data['max_age']);
+ $active = (intval($_data['active']) == 1) ? 1 : 0;
+ $id = date('YmdHis');
+
+ if (!hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $domain)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+ if (empty($version) || !in_array($version, array('stsv1'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('version_invalid', htmlspecialchars($domain))
+ );
+ return false;
+ }
+ if (empty($mode) || !in_array($mode, array('enforce', 'testing', 'none'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('mode_invalid', htmlspecialchars($domain))
+ );
+ return false;
+ }
+ if (empty($max_age) || $max_age < 0 || $max_age > 31536000) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('max_age_invalid', htmlspecialchars($domain))
+ );
+ return false;
+ }
+ foreach ($mx as $index => $mx_domain) {
+ $mx_domain = idn_to_ascii(strtolower(trim($mx_domain)), 0, INTL_IDNA_VARIANT_UTS46);
+ if (!is_valid_domain_name($mx_domain, array('allow_wildcard' => true))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('mx_invalid', htmlspecialchars($mx_domain))
+ );
+ return false;
+ }
+ }
+
+ try {
+ $stmt = $pdo->prepare("INSERT INTO `mta_sts` (`id`, `domain`, `version`, `mode`, `mx`, `max_age`, `active`)
+ VALUES (:id, :domain, :version, :mode, :mx, :max_age, :active)");
+ $stmt->execute(array(
+ ':id' => $id,
+ ':domain' => $domain,
+ ':version' => $version,
+ ':mode' => $mode,
+ ':mx' => implode(",", $mx),
+ ':max_age' => $max_age,
+ ':active' => $active
+ ));
+ } catch (PDOException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data),
+ 'msg' => $e->getMessage()
+ );
+ return false;
+ }
break;
case 'resource':
$domain = idn_to_ascii(strtolower(trim($_data['domain'])), 0, INTL_IDNA_VARIANT_UTS46);
@@ -1428,6 +1641,9 @@
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('resource_added', htmlspecialchars($name))
);
+
+ // Track affected mailboxes for SOGo update
+ $update_sogo_mailboxes[] = $name;
break;
case 'domain_templates':
if ($_SESSION['mailcow_cc_role'] != "admin") {
@@ -1463,7 +1679,7 @@
);
return false;
}
-
+
// check attributes
$attr = array();
$attr['tags'] = (isset($_data['tags'])) ? $_data['tags'] : array();
@@ -1538,11 +1754,22 @@
$attr = array();
$attr["quota"] = isset($_data['quota']) ? intval($_data['quota']) * 1048576 : 0;
$attr['tags'] = (isset($_data['tags'])) ? $_data['tags'] : array();
+ $attr["tagged_mail_handler"] = (!empty($_data['tagged_mail_handler'])) ? $_data['tagged_mail_handler'] : strval($MAILBOX_DEFAULT_ATTRIBUTES['tagged_mail_handler']);
$attr["quarantine_notification"] = (!empty($_data['quarantine_notification'])) ? $_data['quarantine_notification'] : strval($MAILBOX_DEFAULT_ATTRIBUTES['quarantine_notification']);
$attr["quarantine_category"] = (!empty($_data['quarantine_category'])) ? $_data['quarantine_category'] : strval($MAILBOX_DEFAULT_ATTRIBUTES['quarantine_category']);
+ // Validate quarantine_category
+ if (!in_array($attr["quarantine_category"], array('add_header', 'reject', 'all'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_extra),
+ 'msg' => 'quarantine_category_invalid'
+ );
+ return false;
+ }
$attr["rl_frame"] = (!empty($_data['rl_frame'])) ? $_data['rl_frame'] : "s";
$attr["rl_value"] = (!empty($_data['rl_value'])) ? $_data['rl_value'] : "";
$attr["force_pw_update"] = isset($_data['force_pw_update']) ? intval($_data['force_pw_update']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['force_pw_update']);
+ $attr["force_tfa"] = isset($_data['force_tfa']) ? intval($_data['force_tfa']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['force_tfa']);
$attr["sogo_access"] = isset($_data['sogo_access']) ? intval($_data['sogo_access']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['sogo_access']);
$attr["active"] = isset($_data['active']) ? intval($_data['active']) : 1;
$attr["tls_enforce_in"] = isset($_data['tls_enforce_in']) ? intval($_data['tls_enforce_in']) : intval($MAILBOX_DEFAULT_ATTRIBUTES['tls_enforce_in']);
@@ -1553,12 +1780,16 @@
$attr['pop3_access'] = (in_array('pop3', $_data['protocol_access'])) ? 1 : 0;
$attr['smtp_access'] = (in_array('smtp', $_data['protocol_access'])) ? 1 : 0;
$attr['sieve_access'] = (in_array('sieve', $_data['protocol_access'])) ? 1 : 0;
- }
+ $attr['eas_access'] = (in_array('eas', $_data['protocol_access'])) ? 1 : 0;
+ $attr['dav_access'] = (in_array('dav', $_data['protocol_access'])) ? 1 : 0;
+ }
else {
$attr['imap_access'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['imap_access']);
$attr['pop3_access'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['pop3_access']);
$attr['smtp_access'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['smtp_access']);
$attr['sieve_access'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['sieve_access']);
+ $attr['eas_access'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['eas_access']);
+ $attr['dav_access'] = intval($MAILBOX_DEFAULT_ATTRIBUTES['dav_access']);
}
if (isset($_data['acl'])) {
$_data['acl'] = (array)$_data['acl'];
@@ -1576,6 +1807,7 @@
$attr['acl_quarantine_notification'] = (in_array('quarantine_notification', $_data['acl'])) ? 1 : 0;
$attr['acl_quarantine_category'] = (in_array('quarantine_category', $_data['acl'])) ? 1 : 0;
$attr['acl_app_passwds'] = (in_array('app_passwds', $_data['acl'])) ? 1 : 0;
+ $attr['acl_pw_reset'] = (in_array('pw_reset', $_data['acl'])) ? 1 : 0;
} else {
$_data['acl'] = (array)$_data['acl'];
$attr['acl_spam_alias'] = 0;
@@ -1682,7 +1914,7 @@
else {
$usernames = $_data['username'];
}
- if (!isset($_SESSION['acl']['tls_policy']) || $_SESSION['acl']['tls_policy'] != "1" ) {
+ if (!hasACLAccess("tls_policy")) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -1691,7 +1923,7 @@
return false;
}
foreach ($usernames as $username) {
- if (!filter_var($username, FILTER_VALIDATE_EMAIL) || !hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
+ if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -1699,7 +1931,7 @@
);
continue;
}
- $is_now = mailbox('get', 'tls_policy', $username);
+ $is_now = mailbox('get', 'tls_policy', $username, $_extra);
if (!empty($is_now)) {
$tls_enforce_in = (isset($_data['tls_enforce_in'])) ? intval($_data['tls_enforce_in']) : $is_now['tls_enforce_in'];
$tls_enforce_out = (isset($_data['tls_enforce_out'])) ? intval($_data['tls_enforce_out']) : $is_now['tls_enforce_out'];
@@ -1736,7 +1968,7 @@
else {
$usernames = $_data['username'];
}
- if (!isset($_SESSION['acl']['quarantine_notification']) || $_SESSION['acl']['quarantine_notification'] != "1" ) {
+ if (!hasACLAccess("quarantine_notification")) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -1745,7 +1977,7 @@
return false;
}
foreach ($usernames as $username) {
- if (!filter_var($username, FILTER_VALIDATE_EMAIL) || !hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
+ if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -1753,7 +1985,7 @@
);
continue;
}
- $is_now = mailbox('get', 'quarantine_notification', $username);
+ $is_now = mailbox('get', 'quarantine_notification', $username, $_extra);
if (!empty($is_now)) {
$quarantine_notification = (isset($_data['quarantine_notification'])) ? $_data['quarantine_notification'] : $is_now['quarantine_notification'];
}
@@ -1795,7 +2027,7 @@
else {
$usernames = $_data['username'];
}
- if (!isset($_SESSION['acl']['quarantine_category']) || $_SESSION['acl']['quarantine_category'] != "1" ) {
+ if (!hasACLAccess("quarantine_category")) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -1804,7 +2036,7 @@
return false;
}
foreach ($usernames as $username) {
- if (!filter_var($username, FILTER_VALIDATE_EMAIL) || !hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
+ if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -1812,7 +2044,7 @@
);
continue;
}
- $is_now = mailbox('get', 'quarantine_category', $username);
+ $is_now = mailbox('get', 'quarantine_category', $username, $_extra);
if (!empty($is_now)) {
$quarantine_category = (isset($_data['quarantine_category'])) ? $_data['quarantine_category'] : $is_now['quarantine_category'];
}
@@ -1863,6 +2095,14 @@
return false;
}
foreach ($usernames as $username) {
+ if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $username)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'access_denied'
+ );
+ continue;
+ }
if ($_data['spam_score'] == "default") {
$stmt = $pdo->prepare("DELETE FROM `filterconf` WHERE `object` = :username
AND (`option` = 'lowspamlevel' OR `option` = 'highspamlevel')");
@@ -1941,15 +2181,23 @@
);
continue;
}
- if (empty($_data['validity'])) {
+ if (empty($_data['validity']) && empty($_data['permanent'])) {
continue;
}
- $validity = round((int)time() + ($_data['validity'] * 3600));
- $stmt = $pdo->prepare("UPDATE `spamalias` SET `validity` = :validity WHERE
+ if (isset($_data['permanent']) && filter_var($_data['permanent'], FILTER_VALIDATE_BOOL)) {
+ $permanent = 1;
+ $validity = 0;
+ }
+ else if (isset($_data['validity'])) {
+ $permanent = 0;
+ $validity = round((int)time() + ($_data['validity'] * 3600));
+ }
+ $stmt = $pdo->prepare("UPDATE `spamalias` SET `validity` = :validity, `permanent` = :permanent WHERE
`address` = :address");
$stmt->execute(array(
':address' => $address,
- ':validity' => $validity
+ ':validity' => $validity,
+ ':permanent' => $permanent
));
$_SESSION['return'][] = array(
'type' => 'success',
@@ -2104,7 +2352,7 @@
);
return false;
}
-
+
// check if param is whitelisted
if (!in_array(strtolower($param), $GLOBALS["IMAPSYNC_OPTIONS"]["whitelist"])){
// bad option
@@ -2322,7 +2570,9 @@
foreach ($ids as $id) {
$is_now = mailbox('get', 'alias_details', $id);
if (!empty($is_now)) {
+ $internal = (isset($_data['internal'])) ? intval($_data['internal']) : $is_now['internal'];
$active = (isset($_data['active'])) ? intval($_data['active']) : $is_now['active'];
+ $sender_allowed = (isset($_data['sender_allowed'])) ? intval($_data['sender_allowed']) : $is_now['sender_allowed'];
$sogo_visible = (isset($_data['sogo_visible'])) ? intval($_data['sogo_visible']) : $is_now['sogo_visible'];
$goto_null = (isset($_data['goto_null'])) ? intval($_data['goto_null']) : 0;
$goto_spam = (isset($_data['goto_spam'])) ? intval($_data['goto_spam']) : 0;
@@ -2477,6 +2727,19 @@
unset($gotos[$i]);
continue;
}
+ // Deny external goto domains: global switch (all roles) overrides the per-DA ACL
+ $goto_domain = idn_to_ascii(substr(strstr($goto, '@'), 1), 0, INTL_IDNA_VARIANT_UTS46);
+ if (($GLOBALS['ALIAS_DISABLE_EXTERNAL_DOMAINS'] === true ||
+ (isset($_SESSION['acl']['alias_external_goto']) && $_SESSION['acl']['alias_external_goto'] != "1")) &&
+ !is_local_mailcow_domain($goto_domain)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => array('external_goto_denied', htmlspecialchars($goto))
+ );
+ unset($gotos[$i]);
+ continue;
+ }
if ($goto == $address) {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -2507,6 +2770,8 @@
`domain` = :domain,
`goto` = :goto,
`sogo_visible`= :sogo_visible,
+ `internal`= :internal,
+ `sender_allowed`= :sender_allowed,
`active`= :active
WHERE `id` = :id");
$stmt->execute(array(
@@ -2516,6 +2781,8 @@
':domain' => $domain,
':goto' => $goto,
':sogo_visible' => $sogo_visible,
+ ':internal' => $internal,
+ ':sender_allowed' => $sender_allowed,
':active' => $active,
':id' => $is_now['id']
));
@@ -2525,6 +2792,28 @@
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('alias_modified', htmlspecialchars($address))
);
+
+ // Track affected mailboxes for SOGo update (both old and new goto addresses)
+ // Old goto: to remove alias from their view
+ if (!empty($is_now['goto'])) {
+ $old_gotos = array_map('trim', explode(',', $is_now['goto']));
+ foreach ($old_gotos as $g) {
+ if (filter_var($g, FILTER_VALIDATE_EMAIL) &&
+ !in_array($g, array('null@localhost', 'spam@localhost', 'ham@localhost'))) {
+ $update_sogo_mailboxes[] = $g;
+ }
+ }
+ }
+ // New goto: to add alias to their view
+ if (!empty($goto)) {
+ $new_gotos = array_map('trim', explode(',', $goto));
+ foreach ($new_gotos as $g) {
+ if (filter_var($g, FILTER_VALIDATE_EMAIL) &&
+ !in_array($g, array('null@localhost', 'spam@localhost', 'ham@localhost'))) {
+ $update_sogo_mailboxes[] = $g;
+ }
+ }
+ }
}
break;
case 'domain':
@@ -2797,11 +3086,11 @@
// check name
if ($is_now["template"] == "Default" && $is_now["template"] != $_data["template"]){
// keep template name of Default template
- $_data["template"] = $is_now["template"];
+ $_data["template"] = $is_now["template"];
}
else {
- $_data["template"] = (isset($_data["template"])) ? $_data["template"] : $is_now["template"];
- }
+ $_data["template"] = (isset($_data["template"])) ? $_data["template"] : $is_now["template"];
+ }
// check attributes
$attr = array();
$attr['tags'] = (isset($_data['tags'])) ? $_data['tags'] : array();
@@ -2828,10 +3117,10 @@
":id" => $id ,
":template" => $_data["template"] ,
":attributes" => json_encode($attr)
- ));
+ ));
}
-
+
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -2856,30 +3145,48 @@
);
continue;
}
- $is_now = mailbox('get', 'mailbox_details', $username);
+ $is_now = mailbox('get', 'mailbox_details', $username, $_extra);
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;
+ $_data['eas_access'] = (in_array('eas', $_data['protocol_access'])) ? 1 : 0;
+ $_data['dav_access'] = (in_array('dav', $_data['protocol_access'])) ? 1 : 0;
}
if (!empty($is_now)) {
- $active = (isset($_data['active'])) ? intval($_data['active']) : $is_now['active'];
+ $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']['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'];
- $domain = $is_now['domain'];
- $quota_b = $quota_m * 1048576;
- $password = (!empty($_data['password'])) ? $_data['password'] : null;
- $password2 = (!empty($_data['password2'])) ? $_data['password2'] : null;
- $tags = (is_array($_data['tags']) ? $_data['tags'] : array());
+ (int)$force_tfa = (isset($_data['force_tfa'])) ? intval($_data['force_tfa']) : intval($is_now['attributes']['force_tfa']);
+ (int)$sogo_access = (isset($_data['sogo_access']) && hasACLAccess("sogo_access")) ? intval($_data['sogo_access']) : intval($is_now['attributes']['sogo_access']);
+ (int)$imap_access = (isset($_data['imap_access']) && hasACLAccess("protocol_access")) ? intval($_data['imap_access']) : intval($is_now['attributes']['imap_access']);
+ (int)$pop3_access = (isset($_data['pop3_access']) && hasACLAccess("protocol_access")) ? intval($_data['pop3_access']) : intval($is_now['attributes']['pop3_access']);
+ (int)$smtp_access = (isset($_data['smtp_access']) && hasACLAccess("protocol_access")) ? intval($_data['smtp_access']) : intval($is_now['attributes']['smtp_access']);
+ (int)$sieve_access = (isset($_data['sieve_access']) && hasACLAccess("protocol_access")) ? intval($_data['sieve_access']) : intval($is_now['attributes']['sieve_access']);
+ (int)$eas_access = (isset($_data['eas_access']) && hasACLAccess("protocol_access")) ? intval($_data['eas_access']) : intval($is_now['attributes']['eas_access']);
+ (int)$dav_access = (isset($_data['dav_access']) && hasACLAccess("protocol_access")) ? intval($_data['dav_access']) : intval($is_now['attributes']['dav_access']);
+ (int)$relayhost = (isset($_data['relayhost']) && hasACLAccess("mailbox_relayhost")) ? 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'];
+ $domain = $is_now['domain'];
+ $quota_b = $quota_m * 1048576;
+ $password = (!empty($_data['password'])) ? $_data['password'] : null;
+ $password2 = (!empty($_data['password2'])) ? $_data['password2'] : null;
+ $tags = (is_array($_data['tags']) ? $_data['tags'] : array());
+ $attribute_hash = (!empty($_data['attribute_hash'])) ? $_data['attribute_hash'] : '';
+ $authsource = $is_now['authsource'];
+ if ($_data['authsource'] == "mailcow" ||
+ in_array($_data['authsource'], array('keycloak', 'generic-oidc', 'ldap')) && $iam_settings['authsource'] == $_data['authsource']){
+ $authsource = $_data['authsource'];
+ }
+ if (in_array($authsource, array('keycloak', 'generic-oidc', 'ldap'))){
+ $force_pw_update = 0;
+ }
+ if ($authsource == 'generic-oidc'){
+ $force_tfa = 0;
+ }
+ $pw_recovery_email = (isset($_data['pw_recovery_email']) && $authsource == 'mailcow') ? $_data['pw_recovery_email'] : $is_now['attributes']['recovery_email'];
}
else {
$_SESSION['return'][] = array(
@@ -2890,7 +3197,7 @@
continue;
}
// if already 0 == ok
- if ((!isset($_SESSION['acl']['unlimited_quota']) || $_SESSION['acl']['unlimited_quota'] != "1") && ($quota_m == 0 && $is_now['quota'] != 0)) {
+ if (!hasACLAccess("unlimited_quota") && ($quota_m == 0 && $is_now['quota'] != 0)) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -2906,7 +3213,7 @@
);
continue;
}
- $DomainData = mailbox('get', 'domain_details', $domain);
+ $DomainData = mailbox('get', 'domain_details', $domain, $_extra);
if ($quota_m > ($is_now['max_new_quota'] / 1048576)) {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -2925,7 +3232,7 @@
}
$extra_acls = array();
if (isset($_data['extended_sender_acl'])) {
- if (!isset($_SESSION['acl']['extend_sender_acl']) || $_SESSION['acl']['extend_sender_acl'] != "1" ) {
+ if (!hasACLAccess("extend_sender_acl")) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -2995,9 +3302,10 @@
}
if (isset($_data['sender_acl'])) {
// Get sender_acl items set by admin
+ $current_sender_acls = mailbox('get', 'sender_acl_handles', $username);
$sender_acl_admin = array_merge(
- mailbox('get', 'sender_acl_handles', $username)['sender_acl_domains']['ro'],
- mailbox('get', 'sender_acl_handles', $username)['sender_acl_addresses']['ro']
+ $current_sender_acls['sender_acl_domains']['ro'],
+ $current_sender_acls['sender_acl_addresses']['ro']
);
// Get sender_acl items from POST array
// Set sender_acl_domain_admin to empty array if sender_acl contains "default" to trigger a reset
@@ -3085,16 +3393,25 @@
$stmt->execute(array(
':username' => $username
));
- $fixed_sender_aliases = mailbox('get', 'sender_acl_handles', $username)['fixed_sender_aliases'];
+ $sender_acl_handles = mailbox('get', 'sender_acl_handles', $username);
+ $fixed_sender_aliases_allowed = $sender_acl_handles['fixed_sender_aliases_allowed'];
+ $fixed_sender_aliases_blocked = $sender_acl_handles['fixed_sender_aliases_blocked'];
+
foreach ($sender_acl_merged as $sender_acl) {
$domain = ltrim($sender_acl, '@');
if (is_valid_domain_name($domain)) {
$sender_acl = '@' . $domain;
}
- // Don't add if allowed by alias
- if (in_array($sender_acl, $fixed_sender_aliases)) {
+
+ // Always add to sender_acl table to create explicit permission
+ // Skip only if it's in allowed list (would be redundant)
+ // But DO add if it's in blocked list (creates override)
+ if (in_array($sender_acl, $fixed_sender_aliases_allowed)) {
+ // Skip: already allowed by sender_allowed=1, no need for sender_acl entry
continue;
}
+
+ // Add to sender_acl (either override for blocked aliases, or grant for selectable ones)
$stmt = $pdo->prepare("INSERT INTO `sender_acl` (`send_as`, `logged_in_as`)
VALUES (:sender_acl, :username)");
$stmt->execute(array(
@@ -3118,7 +3435,7 @@
$stmt = $pdo->prepare("UPDATE `mailbox` SET
`password` = :password_hashed,
`attributes` = JSON_SET(`attributes`, '$.passwd_update', NOW())
- WHERE `username` = :username");
+ WHERE `username` = :username AND authsource = 'mailcow'");
$stmt->execute(array(
':password_hashed' => $password_hashed,
':username' => $username
@@ -3132,31 +3449,60 @@
':address' => $username,
':active' => $active
));
- $stmt = $pdo->prepare("UPDATE `mailbox` SET
- `active` = :active,
- `name`= :name,
- `quota` = :quota_b,
- `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)
- WHERE `username` = :username");
- $stmt->execute(array(
- ':active' => $active,
- ':name' => $name,
- ':quota_b' => $quota_b,
- ':force_pw_update' => $force_pw_update,
- ':sogo_access' => $sogo_access,
- ':imap_access' => $imap_access,
- ':pop3_access' => $pop3_access,
- ':sieve_access' => $sieve_access,
- ':smtp_access' => $smtp_access,
- ':relayhost' => $relayhost,
- ':username' => $username
- ));
+ try {
+ $stmt = $pdo->prepare("UPDATE `mailbox` SET
+ `active` = :active,
+ `name`= :name,
+ `quota` = :quota_b,
+ `authsource` = :authsource,
+ `attributes` = JSON_SET(`attributes`, '$.force_pw_update', :force_pw_update),
+ `attributes` = JSON_SET(`attributes`, '$.force_tfa', :force_tfa),
+ `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),
+ `attributes` = JSON_SET(`attributes`, '$.eas_access', :eas_access),
+ `attributes` = JSON_SET(`attributes`, '$.dav_access', :dav_access),
+ `attributes` = JSON_SET(`attributes`, '$.recovery_email', :recovery_email),
+ `attributes` = JSON_SET(`attributes`, '$.attribute_hash', :attribute_hash)
+ WHERE `username` = :username");
+ $stmt->execute(array(
+ ':active' => $active,
+ ':name' => $name,
+ ':quota_b' => $quota_b,
+ ':attribute_hash' => $attribute_hash,
+ ':force_pw_update' => $force_pw_update,
+ ':force_tfa' => $force_tfa,
+ ':sogo_access' => $sogo_access,
+ ':imap_access' => $imap_access,
+ ':pop3_access' => $pop3_access,
+ ':sieve_access' => $sieve_access,
+ ':smtp_access' => $smtp_access,
+ ':eas_access' => $eas_access,
+ ':dav_access' => $dav_access,
+ ':recovery_email' => $pw_recovery_email,
+ ':relayhost' => $relayhost,
+ ':username' => $username,
+ ':authsource' => $authsource
+ ));
+ }
+ catch (PDOException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => $e->getMessage()
+ );
+ return false;
+ }
+ // save delimiter_action
+ if (isset($_data['tagged_mail_handler'])) {
+ mailbox('edit', 'delimiter_action', array(
+ 'username' => $username,
+ 'tagged_mail_handler' => $_data['tagged_mail_handler']
+ ));
+ }
// save tags
foreach($tags as $index => $tag){
if (empty($tag)) continue;
@@ -3168,21 +3514,289 @@
);
break;
}
- $stmt = $pdo->prepare("INSERT INTO `tags_mailbox` (`username`, `tag_name`) VALUES (:username, :tag_name)");
- $stmt->execute(array(
- ':username' => $username,
- ':tag_name' => $tag,
- ));
+ try {
+ $stmt = $pdo->prepare("INSERT INTO `tags_mailbox` (`username`, `tag_name`) VALUES (:username, :tag_name)");
+ $stmt->execute(array(
+ ':username' => $username,
+ ':tag_name' => $tag,
+ ));
+ } catch (Exception $e) {
+ }
}
-
+
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('mailbox_modified', $username)
);
- update_sogo_static_view($username);
+ // Track affected mailboxes for SOGo update
+ $update_sogo_mailboxes[] = $username;
}
+ break;
+ case 'mailbox_rename':
+ $domain = $_data['domain'];
+ $old_local_part = $_data['old_local_part'];
+ $old_username = $old_local_part . "@" . $domain;
+ $new_local_part = $_data['new_local_part'];
+ $new_username = $new_local_part . "@" . $domain;
+ $create_alias = intval($_data['create_alias']);
+
+ if (!filter_var($old_username, FILTER_VALIDATE_EMAIL)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => array('username_invalid', $old_username)
+ );
+ return false;
+ }
+ if (!filter_var($new_username, FILTER_VALIDATE_EMAIL)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => array('username_invalid', $new_username)
+ );
+ return false;
+ }
+
+ $is_now = mailbox('get', 'mailbox_details', $old_username);
+ if (empty($is_now) || ($is_now['active'] != '1' && $is_now['active'] != '2')) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ if (!hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $is_now['domain'])) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'access_denied'
+ );
+ return false;
+ }
+
+ // get imap acls
+ try {
+ $exec_fields = array(
+ 'cmd' => 'doveadm',
+ 'task' => 'get_acl',
+ 'id' => $old_username
+ );
+ $imap_acls = json_decode(docker('post', 'dovecot-mailcow', 'exec', $exec_fields), true);
+ // delete imap acls
+ foreach ($imap_acls as $imap_acl) {
+ $exec_fields = array(
+ 'cmd' => 'doveadm',
+ 'task' => 'delete_acl',
+ 'user' => $imap_acl['user'],
+ 'mailbox' => $imap_acl['mailbox'],
+ 'id' => $imap_acl['id']
+ );
+ docker('post', 'dovecot-mailcow', 'exec', $exec_fields);
+ }
+ } catch (Exception $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => $e->getMessage()
+ );
+ return false;
+ }
+
+ // rename username in sql
+ try {
+ $pdo->beginTransaction();
+ $pdo->exec('SET FOREIGN_KEY_CHECKS = 0');
+
+ // Update username in mailbox table
+ $pdo->prepare('UPDATE mailbox SET username = :new_username, local_part = :new_local_part WHERE username = :old_username')
+ ->execute([
+ ':new_username' => $new_username,
+ ':new_local_part' => $new_local_part,
+ ':old_username' => $old_username
+ ]);
+
+ $pdo->prepare("UPDATE alias SET address = :new_username, goto = :new_username2 WHERE address = :old_username")
+ ->execute([
+ ':new_username' => $new_username,
+ ':new_username2' => $new_username,
+ ':old_username' => $old_username
+ ]);
+
+ // Update the username in all related tables
+ $tables = [
+ 'tags_mailbox' => ['username'],
+ 'sieve_filters' => ['username'],
+ 'app_passwd' => ['mailbox'],
+ 'user_acl' => ['username'],
+ 'da_acl' => ['username'],
+ 'quota2' => ['username'],
+ 'quota2replica' => ['username'],
+ 'pushover' => ['username'],
+ 'alias' => ['goto'],
+ "imapsync" => ['user2'],
+ 'bcc_maps' => ['local_dest', 'bcc_dest'],
+ 'recipient_maps' => ['old_dest', 'new_dest'],
+ 'sender_acl' => ['logged_in_as', 'send_as']
+ ];
+ foreach ($tables as $table => $columns) {
+ foreach ($columns as $column) {
+ $stmt = $pdo->prepare("UPDATE $table SET $column = :new_username WHERE $column = :old_username")
+ ->execute([
+ ':new_username' => $new_username,
+ ':old_username' => $old_username
+ ]);
+ }
+ }
+
+ // Update c_uid, c_name and mail in _sogo_static_view table
+ $pdo->prepare("UPDATE _sogo_static_view SET c_uid = :new_username, c_name = :new_username2, mail = :new_username3 WHERE c_uid = :old_username")
+ ->execute([
+ ':new_username' => $new_username,
+ ':new_username2' => $new_username,
+ ':new_username3' => $new_username,
+ ':old_username' => $old_username
+ ]);
+
+ // Re-enable foreign key checks
+ $pdo->exec('SET FOREIGN_KEY_CHECKS = 1');
+ $pdo->commit();
+ } catch (PDOException $e) {
+ // Rollback the transaction if something goes wrong
+ $pdo->rollBack();
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => $e->getMessage()
+ );
+ return false;
+ }
+
+ // move maildir
+ $exec_fields = array(
+ 'cmd' => 'maildir',
+ 'task' => 'move',
+ 'old_maildir' => $domain . '/' . $old_local_part,
+ 'new_maildir' => $domain . '/' . $new_local_part
+ );
+ if (getenv("CLUSTERMODE") == "replication") {
+ // broadcast to each dovecot container
+ docker('broadcast', 'dovecot-mailcow', 'exec', $exec_fields);
+ } else {
+ docker('post', 'dovecot-mailcow', 'exec', $exec_fields);
+ }
+
+ // rename username in sogo
+ $exec_fields = array(
+ 'cmd' => 'sogo',
+ 'task' => 'rename_user',
+ 'old_username' => $old_username,
+ 'new_username' => $new_username
+ );
+ docker('post', 'sogo-mailcow', 'exec', $exec_fields);
+
+ // set imap acls
+ foreach ($imap_acls as $imap_acl) {
+ $user_id = ($imap_acl['id'] == $old_username) ? $new_username : $imap_acl['id'];
+ $user = ($imap_acl['user'] == $old_username) ? $new_username : $imap_acl['user'];
+ $exec_fields = array(
+ 'cmd' => 'doveadm',
+ 'task' => 'set_acl',
+ 'user' => $user,
+ 'mailbox' => $imap_acl['mailbox'],
+ 'id' => $user_id,
+ 'rights' => $imap_acl['rights']
+ );
+ docker('post', 'dovecot-mailcow', 'exec', $exec_fields);
+ }
+
+ // create alias
+ if ($create_alias == 1) {
+ mailbox("add", "alias", array(
+ "address" => $old_username,
+ "goto" => $new_username,
+ "active" => 1,
+ "sogo_visible" => 1,
+ "private_comment" => sprintf($lang['success']['mailbox_renamed'], $old_username, $new_username)
+ ));
+ }
+
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => array('mailbox_renamed', $old_username, $new_username)
+ );
+ break;
+ case 'mailbox_from_template':
+ $stmt = $pdo->prepare("SELECT * FROM `templates`
+ WHERE `template` = :template AND type = 'mailbox'");
+ $stmt->execute(array(
+ ":template" => $_data['template']
+ ));
+ $mbox_template_data = $stmt->fetch(PDO::FETCH_ASSOC);
+ if (empty($mbox_template_data)){
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'template_missing'
+ );
+ return false;
+ }
+
+ $attribute_hash = sha1(json_encode($mbox_template_data["attributes"]));
+ $is_now = mailbox('get', 'mailbox_details', $_data['username']);
+ $name = ltrim(rtrim($_data['name'], '>'), '<');
+ if ($is_now['attributes']['attribute_hash'] == $attribute_hash && $is_now['name'] == $name)
+ return true;
+
+ $mbox_template_data = json_decode($mbox_template_data["attributes"], true);
+ $mbox_template_data['attribute_hash'] = $attribute_hash;
+ $mbox_template_data['name'] = $name;
+ $quarantine_attributes = array('username' => $_data['username']);
+ $tls_attributes = array('username' => $_data['username']);
+ $ratelimit_attributes = array('object' => $_data['username']);
+ $acl_attributes = array('username' => $_data['username'], 'user_acl' => array());
+ $mailbox_attributes = array('username' => $_data['username']);
+ foreach ($mbox_template_data as $key => $value){
+ switch (true) {
+ case (strpos($key, 'quarantine_') === 0):
+ $quarantine_attributes[$key] = $value;
+ break;
+ case (strpos($key, 'tls_') === 0):
+ if ($value == null)
+ $value = 0;
+ $tls_attributes[$key] = $value;
+ break;
+ case (strpos($key, 'rl_') === 0):
+ $ratelimit_attributes[$key] = $value;
+ break;
+ case (strpos($key, 'acl_') === 0 && $value != 0):
+ array_push($acl_attributes['user_acl'], str_replace('acl_' , '', $key));
+ break;
+ default:
+ $mailbox_attributes[$key] = $value;
+ break;
+ }
+ }
+
+ $mailbox_attributes['quota'] = intval($mailbox_attributes['quota'] / 1048576);
+ $result = mailbox('edit', 'mailbox', $mailbox_attributes);
+ if ($result === false) return $result;
+ $result = mailbox('edit', 'tls_policy', $tls_attributes);
+ if ($result === false) return $result;
+ $result = mailbox('edit', 'quarantine_notification', $quarantine_attributes);
+ if ($result === false) return $result;
+ $result = mailbox('edit', 'quarantine_category', $quarantine_attributes);
+ if ($result === false) return $result;
+ $result = ratelimit('edit', 'mailbox', $ratelimit_attributes);
+ if ($result === false) return $result;
+ $result = acl('edit', 'user', $acl_attributes);
+ if ($result === false) return $result;
+
+ $_SESSION['return'] = array();
return true;
break;
case 'mailbox_templates':
@@ -3217,20 +3831,31 @@
// check name
if ($is_now["template"] == "Default" && $is_now["template"] != $_data["template"]){
// keep template name of Default template
- $_data["template"] = $is_now["template"];
+ $_data["template"] = $is_now["template"];
}
else {
- $_data["template"] = (isset($_data["template"])) ? $_data["template"] : $is_now["template"];
- }
+ $_data["template"] = (isset($_data["template"])) ? $_data["template"] : $is_now["template"];
+ }
// check attributes
$attr = array();
$attr["quota"] = isset($_data['quota']) ? intval($_data['quota']) * 1048576 : 0;
$attr['tags'] = (isset($_data['tags'])) ? $_data['tags'] : $is_now['tags'];
+ $attr["tagged_mail_handler"] = (!empty($_data['tagged_mail_handler'])) ? $_data['tagged_mail_handler'] : $is_now['tagged_mail_handler'];
$attr["quarantine_notification"] = (!empty($_data['quarantine_notification'])) ? $_data['quarantine_notification'] : $is_now['quarantine_notification'];
$attr["quarantine_category"] = (!empty($_data['quarantine_category'])) ? $_data['quarantine_category'] : $is_now['quarantine_category'];
+ // Validate quarantine_category
+ if (!in_array($attr["quarantine_category"], array('add_header', 'reject', 'all'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_extra),
+ 'msg' => 'quarantine_category_invalid'
+ );
+ continue;
+ }
$attr["rl_frame"] = (!empty($_data['rl_frame'])) ? $_data['rl_frame'] : $is_now['rl_frame'];
$attr["rl_value"] = (!empty($_data['rl_value'])) ? $_data['rl_value'] : $is_now['rl_value'];
$attr["force_pw_update"] = isset($_data['force_pw_update']) ? intval($_data['force_pw_update']) : $is_now['force_pw_update'];
+ $attr["force_tfa"] = isset($_data['force_tfa']) ? intval($_data['force_tfa']) : $is_now['force_tfa'];
$attr["sogo_access"] = isset($_data['sogo_access']) ? intval($_data['sogo_access']) : $is_now['sogo_access'];
$attr["active"] = isset($_data['active']) ? intval($_data['active']) : $is_now['active'];
$attr["tls_enforce_in"] = isset($_data['tls_enforce_in']) ? intval($_data['tls_enforce_in']) : $is_now['tls_enforce_in'];
@@ -3241,11 +3866,13 @@
$attr['pop3_access'] = (in_array('pop3', $_data['protocol_access'])) ? 1 : 0;
$attr['smtp_access'] = (in_array('smtp', $_data['protocol_access'])) ? 1 : 0;
$attr['sieve_access'] = (in_array('sieve', $_data['protocol_access'])) ? 1 : 0;
- }
- else {
+ $attr['eas_access'] = (in_array('eas', $_data['protocol_access'])) ? 1 : 0;
+ $attr['dav_access'] = (in_array('dav', $_data['protocol_access'])) ? 1 : 0;
+ }
+ else {
foreach ($is_now as $key => $value){
$attr[$key] = $is_now[$key];
- }
+ }
}
if (isset($_data['acl'])) {
$_data['acl'] = (array)$_data['acl'];
@@ -3263,10 +3890,11 @@
$attr['acl_quarantine_notification'] = (in_array('quarantine_notification', $_data['acl'])) ? 1 : 0;
$attr['acl_quarantine_category'] = (in_array('quarantine_category', $_data['acl'])) ? 1 : 0;
$attr['acl_app_passwds'] = (in_array('app_passwds', $_data['acl'])) ? 1 : 0;
- } else {
+ $attr['acl_pw_reset'] = (in_array('pw_reset', $_data['acl'])) ? 1 : 0;
+ } else {
foreach ($is_now as $key => $value){
$attr[$key] = $is_now[$key];
- }
+ }
}
@@ -3278,7 +3906,7 @@
":id" => $id ,
":template" => $_data["template"] ,
":attributes" => json_encode($attr)
- ));
+ ));
}
@@ -3307,7 +3935,7 @@
);
continue;
}
- $is_now = mailbox('get', 'mailbox_details', $mailbox);
+ $is_now = mailbox('get', 'mailbox_details', $mailbox);
if(!empty($is_now)){
if (!hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $is_now['domain'])) {
$_SESSION['return'][] = array(
@@ -3334,15 +3962,134 @@
$stmt->execute(array(
":username" => $mailbox,
":custom_attributes" => json_encode($attributes)
- ));
-
+ ));
+
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('mailbox_modified', $mailbox)
);
}
-
+
+ return true;
+ break;
+ case 'mta_sts':
+ if (!is_array($_data['domains'])) {
+ $domains = array();
+ $domains[] = $_data['domains'];
+ }
+ else {
+ $domains = $_data['domains'];
+ }
+
+ foreach ($domains as $domain) {
+ $domain = idn_to_ascii(strtolower(trim($domain)), 0, INTL_IDNA_VARIANT_UTS46);
+
+ if (!hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $domain)) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => 'access_denied'
+ );
+ continue;
+ }
+
+ $is_now = mailbox('get', 'mta_sts', $domain);
+ if (!empty($is_now)) {
+ $version = (isset($_data['version'])) ? strtolower($_data['version']) : $is_now['version'];
+ $active = (isset($_data['active'])) ? intval($_data['active']) : $is_now['active'];
+ $active = ($active == 1) ? 1 : 0;
+ $mode = (isset($_data['mode'])) ? strtolower($_data['mode']) : $is_now['mode'];
+ $mx = (isset($_data['mx'])) ? explode(",", preg_replace('/\s+/', '', $_data['mx'])) : $is_now['mx'];
+ $max_age = (isset($_data['max_age'])) ? intval($_data['max_age']) : $is_now['max_age'];
+
+ // Update ID if neccesary
+ if ($version != strtolower($is_now['version']) ||
+ $mode != strtolower($is_now['mode']) ||
+ $mx != $is_now['mx'] ||
+ $max_age != $is_now['max_age']) {
+ $id = date('YmdHis');
+ } else {
+ $id = $is_now['id'];
+ }
+
+ } else {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => 'access_denied'
+ );
+ continue;
+ }
+
+ if (empty($version) || !in_array($version, array('stsv1'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('version_invalid', htmlspecialchars($version))
+ );
+ continue;
+ }
+ if (empty($mode) || !in_array($mode, array('enforce', 'testing', 'none'))) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('mode_invalid', htmlspecialchars($domain))
+ );
+ continue;
+ }
+ if (empty($max_age) || $max_age < 0 || $max_age > 31557600) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('max_age_invalid', htmlspecialchars($domain))
+ );
+ continue;
+ }
+ foreach ($mx as $index => $mx_domain) {
+ $mx_domain = idn_to_ascii(strtolower(trim($mx_domain)), 0, INTL_IDNA_VARIANT_UTS46);
+ $invalid_mx = false;
+ if (!is_valid_domain_name($mx_domain, array('allow_wildcard' => true))) {
+ $invalid_mx = $mx_domain;
+ break;
+ }
+ }
+ if ($invalid_mx) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('mx_invalid', htmlspecialchars($invalid_mx))
+ );
+ continue;
+ }
+
+ try {
+ $stmt = $pdo->prepare("UPDATE `mta_sts` SET `id` = :id, `version` = :version, `mode` = :mode, `mx` = :mx, `max_age` = :max_age, `active` = :active WHERE `domain` = :domain");
+ $stmt->execute(array(
+ ':id' => $id,
+ ':domain' => $domain,
+ ':version' => $version,
+ ':mode' => $mode,
+ ':mx' => implode(",", $mx),
+ ':max_age' => $max_age,
+ ':active' => $active
+ ));
+ } catch (PDOException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data),
+ 'msg' => $e->getMessage()
+ );
+ continue;
+ }
+
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data, $_attr),
+ 'msg' => array('object_modified', $domain)
+ );
+ }
+
return true;
break;
case 'resource':
@@ -3422,9 +4169,12 @@
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('resource_modified', htmlspecialchars($name))
);
+
+ // Track affected mailboxes for SOGo update
+ $update_sogo_mailboxes[] = $name;
}
break;
- case 'domain_wide_footer':
+ case 'domain_wide_footer':
if (!is_array($_data['domains'])) {
$domains = array();
$domains[] = $_data['domains'];
@@ -3550,13 +4300,22 @@
$data['sender_acl_addresses']['rw'] = array();
$data['sender_acl_addresses']['selectable'] = array();
$data['fixed_sender_aliases'] = array();
+ $data['fixed_sender_aliases_allowed'] = array();
+ $data['fixed_sender_aliases_blocked'] = array();
$data['external_sender_aliases'] = array();
- // Fixed addresses
- $stmt = $pdo->prepare("SELECT `address` FROM `alias` WHERE `goto` REGEXP :goto AND `address` NOT LIKE '@%'");
- $stmt->execute(array(':goto' => '(^|,)'.$_data.'($|,)'));
+ // Fixed addresses - split by sender_allowed status
+ $stmt = $pdo->prepare("SELECT `address`, `sender_allowed` FROM `alias` WHERE `goto` REGEXP :goto AND `address` NOT LIKE '@%'");
+ $stmt->execute(array(':goto' => '(^|,)'.preg_quote($_data, '/').'($|,)'));
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
while ($row = array_shift($rows)) {
+ // Keep old array for backward compatibility
$data['fixed_sender_aliases'][] = $row['address'];
+ // Split into allowed/blocked for proper display
+ if ($row['sender_allowed'] == '1') {
+ $data['fixed_sender_aliases_allowed'][] = $row['address'];
+ } else {
+ $data['fixed_sender_aliases_blocked'][] = $row['address'];
+ }
}
$stmt = $pdo->prepare("SELECT CONCAT(`local_part`, '@', `alias_domain`.`alias_domain`) AS `alias_domain_alias` FROM `mailbox`, `alias_domain`
WHERE `alias_domain`.`target_domain` = `mailbox`.`domain`
@@ -3677,7 +4436,7 @@
// prepend domain to array
$params = array();
- foreach ($tags as $key => $val){
+ foreach ($tags as $key => $val){
array_push($params, '%'.$_data.'%');
array_push($params, '%'.$val.'%');
}
@@ -3686,7 +4445,7 @@
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
while($row = array_shift($rows)) {
- if (hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], explode('@', $row['username'])[1]))
+ if (hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], explode('@', $row['username'])[1]))
$mailboxes[] = $row['username'];
}
}
@@ -3986,12 +4745,15 @@
}
$stmt = $pdo->prepare("SELECT `address`,
`goto`,
+ `description`,
`validity`,
`created`,
- `modified`
+ `modified`,
+ `permanent`
FROM `spamalias`
WHERE `goto` = :username
- AND `validity` >= :unixnow");
+ AND (`validity` >= :unixnow
+ OR `permanent` != 0)");
$stmt->execute(array(':username' => $_data, ':unixnow' => time()));
$tladata = $stmt->fetchAll(PDO::FETCH_ASSOC);
return $tladata;
@@ -4110,8 +4872,10 @@
`address`,
`public_comment`,
`private_comment`,
+ `internal`,
`active`,
`sogo_visible`,
+ `sender_allowed`,
`created`,
`modified`
FROM `alias`
@@ -4140,10 +4904,12 @@
$aliasdata['goto'] = $row['goto'];
$aliasdata['address'] = $row['address'];
(!filter_var($aliasdata['address'], FILTER_VALIDATE_EMAIL)) ? $aliasdata['is_catch_all'] = 1 : $aliasdata['is_catch_all'] = 0;
+ $aliasdata['internal'] = $row['internal'];
$aliasdata['active'] = $row['active'];
$aliasdata['active_int'] = $row['active'];
$aliasdata['sogo_visible'] = $row['sogo_visible'];
$aliasdata['sogo_visible_int'] = $row['sogo_visible'];
+ $aliasdata['sender_allowed'] = $row['sender_allowed'];
$aliasdata['created'] = $row['created'];
$aliasdata['modified'] = $row['modified'];
if (!hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $aliasdata['domain'])) {
@@ -4241,7 +5007,7 @@
while($row = array_shift($rows)) {
if ($_SESSION['mailcow_cc_role'] == "admin")
$domains[] = $row['domain'];
- elseif (hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $row['domain']))
+ elseif (hasDomainAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $row['domain']))
$domains[] = $row['domain'];
}
} else {
@@ -4401,19 +5167,19 @@
}
$_data = (isset($_data)) ? intval($_data) : null;
- if (isset($_data)){
- $stmt = $pdo->prepare("SELECT * FROM `templates`
+ if (isset($_data)){
+ $stmt = $pdo->prepare("SELECT * FROM `templates`
WHERE `id` = :id AND type = :type");
$stmt->execute(array(
":id" => $_data,
":type" => "domain"
));
$row = $stmt->fetch(PDO::FETCH_ASSOC);
-
+
if (empty($row)){
return false;
}
-
+
$row["attributes"] = json_decode($row["attributes"], true);
return $row;
}
@@ -4421,11 +5187,11 @@
$stmt = $pdo->prepare("SELECT * FROM `templates` WHERE `type` = 'domain'");
$stmt->execute();
$rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
-
+
if (empty($rows)){
return false;
}
-
+
foreach($rows as $key => $row){
$rows[$key]["attributes"] = json_decode($row["attributes"], true);
}
@@ -4448,6 +5214,7 @@
`mailbox`.`quota`,
`mailbox`.`created`,
`mailbox`.`modified`,
+ `mailbox`.`authsource`,
`quota2`.`bytes`,
`attributes`,
`custom_attributes`,
@@ -4469,6 +5236,7 @@
`mailbox`.`quota`,
`mailbox`.`created`,
`mailbox`.`modified`,
+ `mailbox`.`authsource`,
`quota2replica`.`bytes`,
`attributes`,
`custom_attributes`,
@@ -4498,6 +5266,7 @@
$mailboxdata['percent_in_use'] = ($row['quota'] == 0) ? '- ' : round((intval($row['bytes']) / intval($row['quota'])) * 100);
$mailboxdata['created'] = $row['created'];
$mailboxdata['modified'] = $row['modified'];
+ $mailboxdata['authsource'] = ($row['authsource']) ? $row['authsource'] : 'mailcow';
if ($mailboxdata['percent_in_use'] === '- ') {
$mailboxdata['percent_class'] = "info";
@@ -4528,6 +5297,9 @@
else if ($SaslLogs['service'] == 'pop3') {
$last_pop3_login = strtotime($SaslLogs['datetime']);
}
+ else if ($SaslLogs['service'] == 'SSO') {
+ $last_sso_login = strtotime($SaslLogs['datetime']);
+ }
}
if (!isset($last_imap_login) || $GLOBALS['SHOW_LAST_LOGIN'] === false) {
$last_imap_login = 0;
@@ -4538,9 +5310,13 @@
if (!isset($last_pop3_login) || $GLOBALS['SHOW_LAST_LOGIN'] === false) {
$last_pop3_login = 0;
}
+ if (!isset($last_sso_login) || $GLOBALS['SHOW_LAST_LOGIN'] === false) {
+ $last_sso_login = 0;
+ }
$mailboxdata['last_imap_login'] = $last_imap_login;
$mailboxdata['last_smtp_login'] = $last_smtp_login;
$mailboxdata['last_pop3_login'] = $last_pop3_login;
+ $mailboxdata['last_sso_login'] = $last_sso_login;
if (!isset($_extra) || $_extra != 'reduced') {
$rl = ratelimit('get', 'mailbox', $_data);
@@ -4554,7 +5330,7 @@
$stmt = $pdo->prepare("SELECT COALESCE(SUM(`quota`), 0) as `in_use` FROM `mailbox` WHERE (`kind` = '' OR `kind` = NULL) AND `domain` = :domain AND `username` != :username");
$stmt->execute(array(':domain' => $row['domain'], ':username' => $_data));
$MailboxUsage = $stmt->fetch(PDO::FETCH_ASSOC);
- $stmt = $pdo->prepare("SELECT IFNULL(COUNT(`address`), 0) AS `sa_count` FROM `spamalias` WHERE `goto` = :address AND `validity` >= :unixnow");
+ $stmt = $pdo->prepare("SELECT IFNULL(COUNT(`address`), 0) AS `sa_count` FROM `spamalias` WHERE `goto` = :address AND (`validity` >= :unixnow OR `permanent` != 0)");
$stmt->execute(array(':address' => $_data, ':unixnow' => time()));
$SpamaliasUsage = $stmt->fetch(PDO::FETCH_ASSOC);
$mailboxdata['max_new_quota'] = ($DomainQuota['quota'] * 1048576) - $MailboxUsage['in_use'];
@@ -4572,6 +5348,14 @@
$mailboxdata['rl_scope'] = 'domain';
}
$mailboxdata['is_relayed'] = $row['backupmx'];
+ // Internal send-as ACL for this mailbox, mirrors the sender_acl field accepted by edit/mailbox
+ $mailboxdata['sender_acl'] = array();
+ $stmt = $pdo->prepare("SELECT `send_as` FROM `sender_acl` WHERE `logged_in_as` = :username AND `external` = '0'");
+ $stmt->execute(array(':username' => $_data));
+ $sender_acl_rows = $stmt->fetchAll(PDO::FETCH_ASSOC);
+ foreach ($sender_acl_rows as $sender_acl_row) {
+ $mailboxdata['sender_acl'][] = $sender_acl_row['send_as'];
+ }
}
$stmt = $pdo->prepare("SELECT `tag_name`
FROM `tags_mailbox` WHERE `username`= :username");
@@ -4586,24 +5370,24 @@
return $mailboxdata;
break;
case 'mailbox_templates':
- if ($_SESSION['mailcow_cc_role'] != "admin" && $_SESSION['mailcow_cc_role'] != "domainadmin") {
+ if ($_SESSION['mailcow_cc_role'] != "admin" && $_SESSION['mailcow_cc_role'] != "domainadmin" && $_SESSION['access_all_exception'] != "1") {
return false;
}
$_data = (isset($_data)) ? intval($_data) : null;
- if (isset($_data)){
- $stmt = $pdo->prepare("SELECT * FROM `templates`
+ if (isset($_data)){
+ $stmt = $pdo->prepare("SELECT * FROM `templates`
WHERE `id` = :id AND type = :type");
$stmt->execute(array(
":id" => $_data,
":type" => "mailbox"
));
$row = $stmt->fetch(PDO::FETCH_ASSOC);
-
+
if (empty($row)){
return false;
}
-
+
$row["attributes"] = json_decode($row["attributes"], true);
return $row;
}
@@ -4622,6 +5406,20 @@
return $rows;
}
break;
+ case 'mta_sts':
+ $stmt = $pdo->prepare("SELECT * FROM `mta_sts` WHERE `domain` = :domain");
+ $stmt->execute(array(
+ ':domain' => $_data,
+ ));
+ $row = $stmt->fetch(PDO::FETCH_ASSOC);
+ if (empty($row)){
+ return [];
+ }
+ $row['mx'] = explode(',', $row['mx']);
+ $row['version'] = strtoupper(substr($row['version'], 0, 3)) . substr($row['version'], 3);
+
+ return $row;
+ break;
case 'resource_details':
$resourcedata = array();
if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $_data)) {
@@ -4885,8 +5683,11 @@
$stmt->execute(array(
':username' => $username
));
- $stmt = $pdo->prepare("DELETE FROM `sogo_acl` WHERE `c_object` LIKE '%/" . $username . "/%' OR `c_uid` = :username");
+ // bind LIKE pattern + escape LIKE wildcards so the value matches literally (no SQLi, no over-match)
+ $c_object_like = '%/' . addcslashes($username, '\\%_') . '/%';
+ $stmt = $pdo->prepare("DELETE FROM `sogo_acl` WHERE `c_object` LIKE :c_object_like OR `c_uid` = :username");
$stmt->execute(array(
+ ':c_object_like' => $c_object_like,
':username' => $username
));
$stmt = $pdo->prepare("DELETE FROM `sogo_store` WHERE `c_folder_id` IN (SELECT `c_folder_id` FROM `sogo_folder_info` WHERE `c_path2` = :username)");
@@ -5007,6 +5808,10 @@
$stmt->execute(array(
':domain' => $domain,
));
+ $stmt = $pdo->prepare("DELETE FROM `mta_sts` WHERE `domain` = :domain");
+ $stmt->execute(array(
+ ':domain' => $domain,
+ ));
$stmt = $pdo->query("DELETE FROM `admin` WHERE `superadmin` = 0 AND `username` NOT IN (SELECT `username`FROM `domain_admins`);");
$stmt = $pdo->query("DELETE FROM `da_acl` WHERE `username` NOT IN (SELECT `username`FROM `domain_admins`);");
try {
@@ -5045,7 +5850,7 @@
$ids = $_data['ids'];
}
-
+
foreach ($ids as $id) {
// delete template
$stmt = $pdo->prepare("DELETE FROM `templates`
@@ -5082,6 +5887,18 @@
);
continue;
}
+
+ // Track affected mailboxes for SOGo update (capture before deletion)
+ if (!empty($alias_data['goto'])) {
+ $gotos = array_map('trim', explode(',', $alias_data['goto']));
+ foreach ($gotos as $g) {
+ if (filter_var($g, FILTER_VALIDATE_EMAIL) &&
+ !in_array($g, array('null@localhost', 'spam@localhost', 'ham@localhost'))) {
+ $update_sogo_mailboxes[] = $g;
+ }
+ }
+ }
+
$stmt = $pdo->prepare("DELETE FROM `alias` WHERE `id` = :id");
$stmt->execute(array(
':id' => $alias_data['id']
@@ -5212,25 +6029,6 @@
'msg' => 'Could not move maildir to garbage collector: variables local_part and/or domain empty'
);
}
- if (strtolower(getenv('SKIP_SOLR')) == 'n') {
- $curl = curl_init();
- curl_setopt($curl, CURLOPT_URL, 'http://solr:8983/solr/dovecot-fts/update?commit=true');
- curl_setopt($curl, CURLOPT_HTTPHEADER,array('Content-Type: text/xml'));
- curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt($curl, CURLOPT_POST, 1);
- curl_setopt($curl, CURLOPT_POSTFIELDS, '<delete><query>user:' . $username . '</query></delete>');
- curl_setopt($curl, CURLOPT_TIMEOUT, 30);
- $response = curl_exec($curl);
- if ($response === false) {
- $err = curl_error($curl);
- $_SESSION['return'][] = array(
- 'type' => 'warning',
- 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
- 'msg' => 'Could not remove Solr index: ' . print_r($err, true)
- );
- }
- curl_close($curl);
- }
$stmt = $pdo->prepare("DELETE FROM `alias` WHERE `goto` = :username");
$stmt->execute(array(
':username' => $username
@@ -5285,8 +6083,11 @@
$stmt->execute(array(
':username' => $username
));
- $stmt = $pdo->prepare("DELETE FROM `sogo_acl` WHERE `c_object` LIKE '%/" . str_replace('%', '\%', $username) . "/%' OR `c_uid` = :username");
+ // bind LIKE pattern + escape LIKE wildcards so the value matches literally (no SQLi, no over-match)
+ $c_object_like = '%/' . addcslashes($username, '\\%_') . '/%';
+ $stmt = $pdo->prepare("DELETE FROM `sogo_acl` WHERE `c_object` LIKE :c_object_like OR `c_uid` = :username");
$stmt->execute(array(
+ ':c_object_like' => $c_object_like,
':username' => $username
));
$stmt = $pdo->prepare("DELETE FROM `sogo_store` WHERE `c_folder_id` IN (SELECT `c_folder_id` FROM `sogo_folder_info` WHERE `c_path2` = :username)");
@@ -5331,7 +6132,7 @@
));
$stmt = $pdo->prepare("SELECT `address`, `goto` FROM `alias`
WHERE `goto` REGEXP :username");
- $stmt->execute(array(':username' => '(^|,)'.$username.'($|,)'));
+ $stmt->execute(array(':username' => '(^|,)'.preg_quote($username, '/').'($|,)'));
$GotoData = $stmt->fetchAll(PDO::FETCH_ASSOC);
foreach ($GotoData as $gotos) {
$goto_exploded = explode(',', $gotos['goto']);
@@ -5358,15 +6159,16 @@
);
continue;
}
-
- update_sogo_static_view($username);
+
$_SESSION['return'][] = array(
'type' => 'success',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('mailbox_removed', htmlspecialchars($username))
);
+
+ // Track affected mailboxes for SOGo update
+ $update_sogo_mailboxes[] = $username;
}
- return true;
break;
case 'mailbox_templates':
if ($_SESSION['mailcow_cc_role'] != "admin") {
@@ -5385,7 +6187,7 @@
$ids = $_data['ids'];
}
-
+
foreach ($ids as $id) {
// delete template
$stmt = $pdo->prepare("DELETE FROM `templates`
@@ -5394,7 +6196,7 @@
":id" => $id,
":type" => "mailbox",
":template" => "Default"
- ));
+ ));
}
$_SESSION['return'][] = array(
@@ -5441,8 +6243,11 @@
$stmt->execute(array(
':username' => $name
));
- $stmt = $pdo->prepare("DELETE FROM `sogo_acl` WHERE `c_object` LIKE '%/" . $name . "/%' OR `c_uid` = :username");
+ // bind LIKE pattern + escape LIKE wildcards so the value matches literally (no SQLi, no over-match)
+ $c_object_like = '%/' . addcslashes($name, '\\%_') . '/%';
+ $stmt = $pdo->prepare("DELETE FROM `sogo_acl` WHERE `c_object` LIKE :c_object_like OR `c_uid` = :username");
$stmt->execute(array(
+ ':c_object_like' => $c_object_like,
':username' => $name
));
$stmt = $pdo->prepare("DELETE FROM `sogo_store` WHERE `c_folder_id` IN (SELECT `c_folder_id` FROM `sogo_folder_info` WHERE `c_path2` = :username)");
@@ -5466,9 +6271,12 @@
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
'msg' => array('resource_removed', htmlspecialchars($name))
);
+
+ // Track affected mailboxes for SOGo update
+ $update_sogo_mailboxes[] = $name;
}
break;
- case 'tags_domain':
+ case 'tags_domain':
if (!is_array($_data['domain'])) {
$domains = array();
$domains[] = $_data['domain'];
@@ -5481,7 +6289,7 @@
$wasModified = false;
- foreach ($domains as $domain) {
+ foreach ($domains as $domain) {
if (!is_valid_domain_name($domain)) {
$_SESSION['return'][] = array(
'type' => 'danger',
@@ -5498,7 +6306,7 @@
);
return false;
}
-
+
foreach($tags as $tag){
// delete tag
$wasModified = true;
@@ -5553,7 +6361,7 @@
// delete tags
foreach($tags as $tag){
$wasModified = true;
-
+
$stmt = $pdo->prepare("DELETE FROM `tags_mailbox` WHERE `username` = :username AND `tag_name` = :tag_name");
$stmt->execute(array(
':username' => $username,
@@ -5572,7 +6380,29 @@
}
break;
}
- if ($_action != 'get' && in_array($_type, array('domain', 'alias', 'alias_domain', 'resource')) && getenv('SKIP_SOGO') != "y") {
- update_sogo_static_view();
+ if ($_action != 'get' && in_array($_type, array('domain', 'alias', 'alias_domain', 'resource', 'mailbox')) && getenv('SKIP_SOGO') != "y") {
+ try {
+ if (($_type == 'alias' || $_type == 'resource' || $_type == 'mailbox') && !empty($update_sogo_mailboxes)) {
+ // INCREMENTAL UPDATE: Update only affected mailboxes/resources
+ $update_sogo_mailboxes = array_unique($update_sogo_mailboxes);
+ foreach ($update_sogo_mailboxes as $mailbox) {
+ update_sogo_static_view($mailbox);
+ }
+ }
+ else {
+ // FULL REBUILD: For domain and alias_domain operations or if no tracked mailboxes
+ // Domain operations affect all mailboxes
+ // Alias_domain operations affect entire target domain
+ update_sogo_static_view();
+ }
+ }catch (PDOException $e) {
+ $_SESSION['return'][] = array(
+ 'type' => 'success',
+ 'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
+ 'msg' => $e->getMessage()
+ );
+ }
}
+
+ return true;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.quarantine.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.quarantine.inc.php
index f4f49de..c89b3e4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.quarantine.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.quarantine.inc.php
@@ -22,7 +22,7 @@
return false;
}
$stmt = $pdo->prepare('SELECT `id` FROM `quarantine` LEFT OUTER JOIN `user_acl` ON `user_acl`.`username` = `rcpt`
- WHERE SHA2(CONCAT(`id`, `qid`), 256) = :hash
+ WHERE `qhash` = :hash
AND user_acl.quarantine = 1
AND rcpt IN (SELECT username FROM mailbox)');
$stmt->execute(array(':hash' => $hash));
@@ -65,7 +65,7 @@
return false;
}
$stmt = $pdo->prepare('SELECT `id` FROM `quarantine` LEFT OUTER JOIN `user_acl` ON `user_acl`.`username` = `rcpt`
- WHERE SHA2(CONCAT(`id`, `qid`), 256) = :hash
+ WHERE `qhash` = :hash
AND `user_acl`.`quarantine` = 1
AND `username` IN (SELECT `username` FROM `mailbox`)');
$stmt->execute(array(':hash' => $hash));
@@ -169,7 +169,9 @@
}
}
elseif ($release_format == 'raw') {
- $detail_row['msg'] = preg_replace('/^X-Spam-Flag: (.*)/', 'X-Pre-Release-Spam-Flag $1', $detail_row['msg']);
+ $detail_row['msg'] = preg_replace('/^X-Spam-Flag: (.*)/m', 'X-Pre-Release-Spam-Flag: $1', $detail_row['msg']);
+ // dot-stuffing per RFC5321 4.5.2: escape leading dots
+ $detail_row['msg'] = preg_replace('~^\.~m', '..', $detail_row['msg']);
$postfix_talk = array(
array('220', 'HELO quarantine' . chr(10)),
array('250', 'MAIL FROM: ' . $sender . chr(10)),
@@ -180,7 +182,7 @@
array('221', '')
);
// Thanks to https://stackoverflow.com/questions/6632399/given-an-email-as-raw-text-how-can-i-send-it-using-php
- $smtp_connection = fsockopen($postfix, 590, $errno, $errstr, 1);
+ $smtp_connection = fsockopen($postfix, 590, $errno, $errstr, 1);
if (!$smtp_connection) {
logger(array('return' => array(
array(
@@ -192,7 +194,7 @@
return false;
}
for ($i=0; $i < count($postfix_talk); $i++) {
- $smtp_resource = fgets($smtp_connection, 256);
+ $smtp_resource = fgets($smtp_connection, 256);
if (substr($smtp_resource, 0, 3) !== $postfix_talk[$i][0]) {
$ret = substr($smtp_resource, 0, 3);
$ret = (empty($ret)) ? '-' : $ret;
@@ -464,18 +466,20 @@
}
}
elseif ($release_format == 'raw') {
- $row['msg'] = preg_replace('/^X-Spam-Flag: (.*)/', 'X-Pre-Release-Spam-Flag $1', $row['msg']);
+ $row['msg'] = preg_replace('/^X-Spam-Flag: (.*)/m', 'X-Pre-Release-Spam-Flag: $1', $row['msg']);
+ // dot-stuffing per RFC5321 4.5.2: escape leading dots
+ $row['msg'] = preg_replace('~^\.~m', '..', $row['msg']);
$postfix_talk = array(
array('220', 'HELO quarantine' . chr(10)),
array('250', 'MAIL FROM: ' . $sender . chr(10)),
array('250', 'RCPT TO: ' . $row['rcpt'] . chr(10)),
array('250', 'DATA' . chr(10)),
- array('354', str_replace("\n.", '', $row['msg']) . chr(10) . '.' . chr(10)),
+ array('354', $row['msg'] . chr(10) . '.' . chr(10)),
array('250', 'QUIT' . chr(10)),
array('221', '')
);
// Thanks to https://stackoverflow.com/questions/6632399/given-an-email-as-raw-text-how-can-i-send-it-using-php
- $smtp_connection = fsockopen($postfix, 590, $errno, $errstr, 1);
+ $smtp_connection = fsockopen($postfix, 590, $errno, $errstr, 1);
if (!$smtp_connection) {
$_SESSION['return'][] = array(
'type' => 'warning',
@@ -485,7 +489,7 @@
return false;
}
for ($i=0; $i < count($postfix_talk); $i++) {
- $smtp_resource = fgets($smtp_connection, 256);
+ $smtp_resource = fgets($smtp_connection, 256);
if (substr($smtp_resource, 0, 3) !== $postfix_talk[$i][0]) {
$ret = substr($smtp_resource, 0, 3);
$ret = (empty($ret)) ? '-' : $ret;
@@ -833,7 +837,7 @@
)));
return false;
}
- $stmt = $pdo->prepare('SELECT * FROM `quarantine` WHERE SHA2(CONCAT(`id`, `qid`), 256) = :hash');
+ $stmt = $pdo->prepare('SELECT * FROM `quarantine` WHERE `qhash` = :hash');
$stmt->execute(array(':hash' => $hash));
return $stmt->fetch(PDO::FETCH_ASSOC);
break;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/functions.ratelimit.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/functions.ratelimit.inc.php
index f9e7a71..91ac999 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/functions.ratelimit.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/functions.ratelimit.inc.php
@@ -1,10 +1,10 @@
<?php
-function ratelimit($_action, $_scope, $_data = null) {
+function ratelimit($_action, $_scope, $_data = null, $_extra = null) {
global $redis;
$_data_log = $_data;
switch ($_action) {
case 'edit':
- if (!isset($_SESSION['acl']['ratelimit']) || $_SESSION['acl']['ratelimit'] != "1" ) {
+ if (!hasACLAccess("ratelimit")) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_type, $_data_log, $_attr),
@@ -93,7 +93,7 @@
continue;
}
if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $object)
- || ($_SESSION['mailcow_cc_role'] != 'admin' && $_SESSION['mailcow_cc_role'] != 'domainadmin')) {
+ || ($_SESSION['mailcow_cc_role'] != 'admin' && $_SESSION['mailcow_cc_role'] != 'domainadmin' && $_SESSION['access_all_exception'] != '1')) {
$_SESSION['return'][] = array(
'type' => 'danger',
'log' => array(__FUNCTION__, $_action, $_scope, $_data_log),
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 fd1c5bd..c2444d9 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
@@ -143,17 +143,26 @@
return false;
}
$maps = (array)$_data['map'];
+ $valid_maps = array();
foreach ($maps as $map) {
+ $is_valid = false;
foreach ($RSPAMD_MAPS as $rspamd_map_type) {
- if (!in_array($map, $rspamd_map_type)) {
- $_SESSION['return'][] = array(
- 'type' => 'danger',
- 'log' => array(__FUNCTION__, $_action, '-'),
- 'msg' => array('global_map_invalid', $map)
- );
- continue;
+ if (in_array($map, $rspamd_map_type)) {
+ $is_valid = true;
+ break;
}
}
+ if ($is_valid) {
+ array_push($valid_maps, $map);
+ } else {
+ $_SESSION['return'][] = array(
+ 'type' => 'danger',
+ 'log' => array(__FUNCTION__, $_action, '-'),
+ 'msg' => array('global_map_invalid', $map)
+ );
+ }
+ }
+ foreach ($valid_maps as $map) {
try {
if (file_exists('/rspamd_custom_maps/' . $map)) {
$map_content = trim($_data['rspamd_map_data']);
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 9afc288..65c086d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/header.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/header.inc.php
@@ -22,6 +22,9 @@
if ($_SERVER['REQUEST_URI'] == '/') {
$css_minifier->add('/web/css/site/index.css');
}
+if (file_exists('/web/css/themes/'.$UI_THEME.'/theme.css')) {
+ $css_minifier->add('/web/css/themes/'.$UI_THEME.'/theme.css');
+}
$hash = $css_minifier->getDataHash();
$CSSPath = '/tmp/' . $hash . '.css';
@@ -30,6 +33,55 @@
cleanupCSS($hash);
}
+// dark mode bundle, core dark mode + theme dark.css
+$dark_minifier = new CSSminifierExtended('/web/css/themes/mailcow-darkmode.css');
+if (file_exists('/web/css/themes/'.$UI_THEME.'/dark.css')) {
+ $dark_minifier->add('/web/css/themes/'.$UI_THEME.'/dark.css');
+}
+$DarkCSSPath = '/tmp/' . $hash . '-' . $dark_minifier->getDataHash() . '.css';
+if(!file_exists($DarkCSSPath)) {
+ $dark_minifier->minify($DarkCSSPath);
+}
+$dark_css_path = '/cache/' . basename($DarkCSSPath);
+
+$mailcow_apps_processed = $MAILCOW_APPS;
+$app_links = customize('get', 'app_links');
+$app_links_processed = $app_links;
+$hide_mailcow_apps = true;
+for ($i = 0; $i < count($mailcow_apps_processed); $i++) {
+ if ($hide_mailcow_apps && !$mailcow_apps_processed[$i]['hide']){
+ $hide_mailcow_apps = false;
+ }
+ if (!empty($_SESSION['mailcow_cc_username'])){
+ if ($app_links_processed[$i]['user_link']) {
+ $mailcow_apps_processed[$i]['user_link'] = str_replace('%u', $_SESSION['mailcow_cc_username'], $mailcow_apps_processed[$i]['user_link']);
+ } else {
+ $mailcow_apps_processed[$i]['user_link'] = $mailcow_apps_processed[$i]['link'];
+ }
+ }
+}
+if ($app_links_processed){
+ for ($i = 0; $i < count($app_links_processed); $i++) {
+ $key = array_key_first($app_links_processed[$i]);
+ if ($hide_mailcow_apps && !$app_links_processed[$i][$key]['hide']){
+ $hide_mailcow_apps = false;
+ }
+ if (!empty($_SESSION['mailcow_cc_username'])){
+ if ($app_links_processed[$i][$key]['user_link']) {
+ $app_links_processed[$i][$key]['user_link'] = str_replace('%u', $_SESSION['mailcow_cc_username'], $app_links_processed[$i][$key]['user_link']);
+ } else {
+ $app_links_processed[$i][$key]['user_link'] = $app_links_processed[$i][$key]['link'];
+ }
+ }
+ }
+}
+
+// Workaround to get text with <br> straight to twig.
+// Using "nl2br" doesn't work with Twig as it would escape everything by default.
+if (isset($UI_TEXTS["ui_footer"])) {
+ $UI_TEXTS["ui_footer"] = nl2br($UI_TEXTS["ui_footer"]);
+}
+
$globalVariables = [
'mailcow_hostname' => getenv('MAILCOW_HOSTNAME'),
'mailcow_locale' => @$_SESSION['mailcow_locale'],
@@ -39,17 +91,20 @@
'dual_login' => @$_SESSION['dual-login'],
'ui_texts' => $UI_TEXTS,
'css_path' => '/cache/'.basename($CSSPath),
+ 'dark_css_path' => $dark_css_path,
'logo' => customize('get', 'main_logo'),
'logo_dark' => customize('get', 'main_logo_dark'),
'available_languages' => $AVAILABLE_LANGUAGES,
'lang' => $lang,
'skip_sogo' => (getenv('SKIP_SOGO') == 'y'),
'allow_admin_email_login' => (getenv('ALLOW_ADMIN_EMAIL_LOGIN') == 'n'),
+ 'hide_mailcow_apps' => $hide_mailcow_apps,
'mailcow_apps' => $MAILCOW_APPS,
- 'app_links' => customize('get', 'app_links'),
+ 'mailcow_apps_processed' => $mailcow_apps_processed,
+ 'app_links' => $app_links,
+ 'app_links_processed' => $app_links_processed,
'is_root_uri' => (parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) == '/'),
- 'uri' => $_SERVER['REQUEST_URI'],
- 'last_login' => last_login('get', $_SESSION['mailcow_cc_username'], 7, 0)['ui']['time']
+ 'uri' => parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) ?: '/',
];
foreach ($globalVariables as $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 445af8a..f6b0cd7 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
@@ -1,9 +1,10 @@
<?php
-function init_db_schema() {
+function init_db_schema()
+{
try {
global $pdo;
- $db_version = "09022024_1433";
+ $db_version = "18082026_1200";
$stmt = $pdo->query("SHOW TABLES LIKE 'versions'");
$num_results = count($stmt->fetchAll(PDO::FETCH_ASSOC));
@@ -75,7 +76,8 @@
"superadmin" => "TINYINT(1) NOT NULL DEFAULT '0'",
"created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
"modified" => "DATETIME ON UPDATE NOW(0)",
- "active" => "TINYINT(1) NOT NULL DEFAULT '1'"
+ "active" => "TINYINT(1) NOT NULL DEFAULT '1'",
+ "attributes" => "JSON"
),
"keys" => array(
"primary" => array(
@@ -111,6 +113,10 @@
"c_name" => "VARCHAR(255) NOT NULL",
"c_password" => "VARCHAR(255) NOT NULL DEFAULT ''",
"c_cn" => "VARCHAR(255)",
+ "c_l" => "VARCHAR(255)",
+ "c_o" => "VARCHAR(255)",
+ "c_ou" => "VARCHAR(255)",
+ "c_telephonenumber" => "VARCHAR(255)",
"mail" => "VARCHAR(255) NOT NULL",
// TODO -> use TEXT and check if SOGo login breaks on empty aliases
"aliases" => "TEXT NOT NULL",
@@ -179,6 +185,8 @@
"private_comment" => "TEXT",
"public_comment" => "TEXT",
"sogo_visible" => "TINYINT(1) NOT NULL DEFAULT '1'",
+ "internal" => "TINYINT(1) NOT NULL DEFAULT '0'",
+ "sender_allowed" => "TINYINT(1) NOT NULL DEFAULT '1'",
"active" => "TINYINT(1) NOT NULL DEFAULT '1'"
),
"keys" => array(
@@ -340,10 +348,14 @@
"notified" => "TINYINT(1) NOT NULL DEFAULT '0'",
"created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
"user" => "VARCHAR(255) NOT NULL DEFAULT 'unknown'",
+ "qhash" => "VARCHAR(64)",
),
"keys" => array(
"primary" => array(
"" => array("id")
+ ),
+ "key" => array(
+ "qhash" => array("qhash")
)
),
"attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
@@ -363,6 +375,7 @@
"custom_attributes" => "JSON NOT NULL DEFAULT ('{}')",
"kind" => "VARCHAR(100) NOT NULL DEFAULT ''",
"multiple_bookings" => "INT NOT NULL DEFAULT -1",
+ "authsource" => "ENUM('mailcow', 'keycloak', 'generic-oidc', 'ldap') DEFAULT 'mailcow'",
"created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
"modified" => "DATETIME ON UPDATE CURRENT_TIMESTAMP",
"active" => "TINYINT(1) NOT NULL DEFAULT '1'"
@@ -465,6 +478,23 @@
),
"attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
),
+ "mta_sts" => array(
+ "cols" => array(
+ "id" => "BIGINT NOT NULL",
+ "domain" => "VARCHAR(255) NOT NULL",
+ "version" => "VARCHAR(255) NOT NULL",
+ "mode" => "VARCHAR(255) NOT NULL",
+ "mx" => "VARCHAR(255) NOT NULL",
+ "max_age" => "VARCHAR(255) NOT NULL",
+ "active" => "TINYINT(1) NOT NULL DEFAULT '1'"
+ ),
+ "keys" => array(
+ "primary" => array(
+ "" => array("domain")
+ )
+ ),
+ "attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
+ ),
"user_acl" => array(
"cols" => array(
"username" => "VARCHAR(255) NOT NULL",
@@ -483,7 +513,8 @@
"quarantine_notification" => "TINYINT(1) NOT NULL DEFAULT '1'",
"quarantine_category" => "TINYINT(1) NOT NULL DEFAULT '1'",
"app_passwds" => "TINYINT(1) NOT NULL DEFAULT '1'",
- ),
+ "pw_reset" => "TINYINT(1) NOT NULL DEFAULT '1'",
+ ),
"keys" => array(
"primary" => array(
"" => array("username")
@@ -522,9 +553,11 @@
"cols" => array(
"address" => "VARCHAR(255) NOT NULL",
"goto" => "TEXT NOT NULL",
+ "description" => "TEXT NOT NULL",
"created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
"modified" => "DATETIME ON UPDATE CURRENT_TIMESTAMP",
- "validity" => "INT(11)"
+ "validity" => "INT(11)",
+ "permanent" => "TINYINT(1) NOT NULL DEFAULT '0'"
),
"keys" => array(
"primary" => array(
@@ -568,6 +601,20 @@
),
"attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
),
+ "identity_provider" => array(
+ "cols" => array(
+ "key" => "VARCHAR(255) NOT NULL",
+ "value" => "TEXT NOT NULL",
+ "created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
+ "modified" => "DATETIME ON UPDATE CURRENT_TIMESTAMP"
+ ),
+ "keys" => array(
+ "primary" => array(
+ "" => array("key")
+ )
+ ),
+ "attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
+ ),
"logs" => array(
"cols" => array(
"id" => "INT NOT NULL AUTO_INCREMENT",
@@ -672,8 +719,9 @@
"alias_domains" => "TINYINT(1) NOT NULL DEFAULT '0'",
"mailbox_relayhost" => "TINYINT(1) NOT NULL DEFAULT '1'",
"domain_relayhost" => "TINYINT(1) NOT NULL DEFAULT '1'",
- "domain_desc" => "TINYINT(1) NOT NULL DEFAULT '0'"
- ),
+ "domain_desc" => "TINYINT(1) NOT NULL DEFAULT '0'",
+ "alias_external_goto" => "TINYINT(1) NOT NULL DEFAULT '1'"
+ ),
"keys" => array(
"primary" => array(
"" => array("username")
@@ -694,6 +742,19 @@
),
"attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
),
+ "reset_password" => array(
+ "cols" => array(
+ "username" => "VARCHAR(255) NOT NULL",
+ "token" => "VARCHAR(255) NOT NULL",
+ "created" => "DATETIME(0) NOT NULL DEFAULT NOW(0)",
+ ),
+ "keys" => array(
+ "primary" => array(
+ "" => array("token", "created")
+ ),
+ ),
+ "attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
+ ),
"imapsync" => array(
"cols" => array(
"id" => "INT NOT NULL AUTO_INCREMENT",
@@ -979,6 +1040,18 @@
),
"attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
),
+ "sogo_admin" => array(
+ "cols" => array(
+ "c_key" => "VARCHAR(255) NOT NULL DEFAULT ''",
+ "c_content" => "mediumtext NOT NULL",
+ ),
+ "keys" => array(
+ "primary" => array(
+ "" => array("c_key")
+ )
+ ),
+ "attr" => "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC"
+ ),
"pushover" => array(
"cols" => array(
"username" => "VARCHAR(255) NOT NULL",
@@ -1121,7 +1194,7 @@
while ($row = array_shift($rows)) {
$pdo->query($row['FKEY_DROP']);
}
- foreach($properties['cols'] as $column => $type) {
+ foreach ($properties['cols'] as $column => $type) {
$stmt = $pdo->query("SHOW COLUMNS FROM `" . $table . "` LIKE '" . $column . "'");
$num_results = count($stmt->fetchAll(PDO::FETCH_ASSOC));
if ($num_results == 0) {
@@ -1135,12 +1208,11 @@
}
}
$pdo->query("ALTER TABLE `" . $table . "` ADD `" . $column . "` " . $type);
- }
- else {
+ } else {
$pdo->query("ALTER TABLE `" . $table . "` MODIFY COLUMN `" . $column . "` " . $type);
}
}
- foreach($properties['keys'] as $key_type => $key_content) {
+ foreach ($properties['keys'] as $key_type => $key_content) {
if (strtolower($key_type) == 'primary') {
foreach ($key_content as $key_values) {
$fields = "`" . implode("`, `", $key_values) . "`";
@@ -1197,18 +1269,18 @@
$keys_to_exist = array();
if (isset($properties['keys']['unique']) && is_array($properties['keys']['unique'])) {
foreach ($properties['keys']['unique'] as $key_name => $key_values) {
- $keys_to_exist[] = $key_name;
+ $keys_to_exist[] = $key_name;
}
}
if (isset($properties['keys']['key']) && is_array($properties['keys']['key'])) {
foreach ($properties['keys']['key'] as $key_name => $key_values) {
- $keys_to_exist[] = $key_name;
+ $keys_to_exist[] = $key_name;
}
}
// Index for foreign key must exist
if (isset($properties['keys']['fkey']) && is_array($properties['keys']['fkey'])) {
foreach ($properties['keys']['fkey'] as $key_name => $key_values) {
- $keys_to_exist[] = $key_name;
+ $keys_to_exist[] = $key_name;
}
}
// Step 2: Drop all vanished indexes
@@ -1225,33 +1297,29 @@
$pdo->query("ALTER TABLE `" . $table . "` DROP PRIMARY KEY");
}
}
- }
- else {
+ } else {
// Create table if it is missing
$sql = "CREATE TABLE IF NOT EXISTS `" . $table . "` (";
- foreach($properties['cols'] as $column => $type) {
+ foreach ($properties['cols'] as $column => $type) {
$sql .= "`" . $column . "` " . $type . ",";
}
- foreach($properties['keys'] as $key_type => $key_content) {
+ foreach ($properties['keys'] as $key_type => $key_content) {
if (strtolower($key_type) == 'primary') {
foreach ($key_content as $key_values) {
$fields = "`" . implode("`, `", $key_values) . "`";
$sql .= "PRIMARY KEY (" . $fields . ")" . ",";
}
- }
- elseif (strtolower($key_type) == 'key') {
+ } elseif (strtolower($key_type) == 'key') {
foreach ($key_content as $key_name => $key_values) {
$fields = "`" . implode("`, `", $key_values) . "`";
$sql .= "KEY `" . $key_name . "` (" . $fields . ")" . ",";
}
- }
- elseif (strtolower($key_type) == 'unique') {
+ } elseif (strtolower($key_type) == 'unique') {
foreach ($key_content as $key_name => $key_values) {
$fields = "`" . implode("`, `", $key_values) . "`";
$sql .= "UNIQUE KEY `" . $key_name . "` (" . $fields . ")" . ",";
}
- }
- elseif (strtolower($key_type) == 'fkey') {
+ } elseif (strtolower($key_type) == 'fkey') {
foreach ($key_content as $key_name => $key_values) {
@list($table_ref, $field_ref) = explode('.', $key_values['ref']);
$sql .= "FOREIGN KEY `" . $key_name . "` (" . $key_values['col'] . ") REFERENCES `" . $table_ref . "` (`" . $field_ref . "`)
@@ -1265,7 +1333,6 @@
}
// Reset table attributes
$pdo->query("ALTER TABLE `" . $table . "` " . $properties['attr'] . ";");
-
}
// Recreate SQL views
@@ -1274,6 +1341,14 @@
$pdo->query($create);
}
+ // Clear old app_passwd log entries
+ $pdo->exec("DELETE FROM logs
+ WHERE role != 'unauthenticated'
+ AND JSON_EXTRACT(`call`, '$[0]') = 'app_passwd'
+ AND JSON_EXTRACT(`call`, '$[1]') = 'edit'
+ AND (JSON_CONTAINS_PATH(`call`, 'one', '$[2].password')
+ OR JSON_CONTAINS_PATH(`call`, 'one', '$[2].password2'));");
+
// Mitigate imapsync argument injection issue
$pdo->query("UPDATE `imapsync` SET `custom_params` = ''
WHERE `custom_params` LIKE '%pipemess%'
@@ -1292,12 +1367,12 @@
$stmt = $pdo->query("SELECT NULL FROM `admin`");
$num_results = count($stmt->fetchAll(PDO::FETCH_ASSOC));
if ($num_results == 0) {
- $pdo->query("INSERT INTO `admin` (`username`, `password`, `superadmin`, `created`, `modified`, `active`)
+ $pdo->query("INSERT INTO `admin` (`username`, `password`, `superadmin`, `created`, `modified`, `active`)
VALUES ('admin', '{SSHA256}K8eVJ6YsZbQCfuJvSUbaQRLr0HPLz5rC9IAp0PAFl0tmNDBkMDc0NDAyOTAxN2Rk', 1, NOW(), NOW(), 1)");
- $pdo->query("INSERT INTO `domain_admins` (`username`, `domain`, `created`, `active`)
+ $pdo->query("INSERT INTO `domain_admins` (`username`, `domain`, `created`, `active`)
SELECT `username`, 'ALL', NOW(), 1 FROM `admin`
WHERE superadmin='1' AND `username` NOT IN (SELECT `username` FROM `domain_admins`);");
- $pdo->query("DELETE FROM `admin` WHERE `username` NOT IN (SELECT `username` FROM `domain_admins`);");
+ $pdo->query("DELETE FROM `admin` WHERE `username` NOT IN (SELECT `username` FROM `domain_admins`);");
}
// Insert new DB schema version
$pdo->query("REPLACE INTO `versions` (`application`, `version`) VALUES ('db_schema', '" . $db_version . "');");
@@ -1317,15 +1392,22 @@
$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`, '$.force_tfa', \"0\") WHERE JSON_VALUE(`attributes`, '$.force_tfa') IS NULL;");
+ // admin attributes
+ $pdo->query("UPDATE `admin` SET `attributes` = '{}' WHERE `attributes` = '' OR `attributes` IS NULL;");
+ $pdo->query("UPDATE `admin` SET `attributes` = JSON_SET(`attributes`, '$.force_tfa', \"0\") WHERE JSON_VALUE(`attributes`, '$.force_tfa') IS NULL;");
+ $pdo->query("UPDATE `admin` 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;");
$pdo->query("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.smtp_access', \"1\") WHERE JSON_VALUE(`attributes`, '$.smtp_access') IS NULL;");
+ $pdo->query("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.eas_access', \"1\") WHERE JSON_VALUE(`attributes`, '$.eas_access') IS NULL;");
+ $pdo->query("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.dav_access', \"1\") WHERE JSON_VALUE(`attributes`, '$.dav_access') IS NULL;");
$pdo->query("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.mailbox_format', \"maildir:\") WHERE JSON_VALUE(`attributes`, '$.mailbox_format') IS NULL;");
$pdo->query("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.quarantine_notification', \"never\") WHERE JSON_VALUE(`attributes`, '$.quarantine_notification') IS NULL;");
$pdo->query("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.quarantine_category', \"reject\") WHERE JSON_VALUE(`attributes`, '$.quarantine_category') IS NULL;");
- foreach($tls_options as $tls_user => $tls_options) {
+ foreach ($tls_options as $tls_user => $tls_options) {
$stmt = $pdo->prepare("UPDATE `mailbox` SET `attributes` = JSON_SET(`attributes`, '$.tls_enforce_in', :tls_enforce_in),
`attributes` = JSON_SET(`attributes`, '$.tls_enforce_out', :tls_enforce_out)
WHERE `username` = :username");
@@ -1362,7 +1444,7 @@
"key_size" => 2048,
"max_quota_for_domain" => 10240 * 1048576,
)
- );
+ );
$default_mailbox_template = array(
"template" => "Default",
"type" => "mailbox",
@@ -1374,6 +1456,7 @@
"rl_frame" => "s",
"rl_value" => "",
"force_pw_update" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['force_pw_update']),
+ "force_tfa" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['force_tfa']),
"sogo_access" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['sogo_access']),
"active" => 1,
"tls_enforce_in" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['tls_enforce_in']),
@@ -1382,6 +1465,8 @@
"pop3_access" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['pop3_access']),
"smtp_access" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['smtp_access']),
"sieve_access" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['sieve_access']),
+ "eas_access" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['eas_access']),
+ "dav_access" => intval($GLOBALS['MAILBOX_DEFAULT_ATTRIBUTES']['dav_access']),
"acl_spam_alias" => 1,
"acl_tls_policy" => 1,
"acl_spam_score" => 1,
@@ -1397,37 +1482,40 @@
"acl_quarantine_category" => 1,
"acl_app_passwds" => 1,
)
- );
+ );
$stmt = $pdo->prepare("SELECT id FROM `templates` WHERE `type` = :type AND `template` = :template");
$stmt->execute(array(
":type" => "domain",
":template" => $default_domain_template["template"]
));
$row = $stmt->fetch(PDO::FETCH_ASSOC);
- if (empty($row)){
+ if (empty($row)) {
$stmt = $pdo->prepare("INSERT INTO `templates` (`type`, `template`, `attributes`)
VALUES (:type, :template, :attributes)");
$stmt->execute(array(
":type" => "domain",
":template" => $default_domain_template["template"],
":attributes" => json_encode($default_domain_template["attributes"])
- ));
- }
+ ));
+ }
$stmt = $pdo->prepare("SELECT id FROM `templates` WHERE `type` = :type AND `template` = :template");
$stmt->execute(array(
":type" => "mailbox",
":template" => $default_mailbox_template["template"]
));
$row = $stmt->fetch(PDO::FETCH_ASSOC);
- if (empty($row)){
+ if (empty($row)) {
$stmt = $pdo->prepare("INSERT INTO `templates` (`type`, `template`, `attributes`)
VALUES (:type, :template, :attributes)");
$stmt->execute(array(
":type" => "mailbox",
":template" => $default_mailbox_template["template"],
":attributes" => json_encode($default_mailbox_template["attributes"])
- ));
- }
+ ));
+ }
+
+ // remove old sogo views and triggers
+ $pdo->query("DROP TRIGGER IF EXISTS sogo_update_password");
if (php_sapi_name() == "cli") {
echo "DB initialization completed" . PHP_EOL;
@@ -1438,8 +1526,11 @@
'msg' => 'db_init_complete'
);
}
- }
- catch (PDOException $e) {
+
+ // fill quarantine.qhash
+ $pdo->query("UPDATE `quarantine` SET `qhash` = SHA2(CONCAT(`id`, `qid`), 256) WHERE ISNULL(`qhash`)");
+
+ } catch (PDOException $e) {
if (php_sapi_name() == "cli") {
echo "DB initialization failed: " . print_r($e, true) . PHP_EOL;
} else {
@@ -1453,6 +1544,7 @@
}
if (php_sapi_name() == "cli") {
include '/web/inc/vars.inc.php';
+ include '/web/inc/functions.inc.php';
include '/web/inc/functions.docker.inc.php';
// $now = new DateTime();
// $mins = $now->getOffset() / 60;
@@ -1474,12 +1566,9 @@
if (intval($res['OK_C']) === 2) {
// Be more precise when replacing into _sogo_static_view, col orders may change
try {
- $stmt = $pdo->query("REPLACE INTO _sogo_static_view (`c_uid`, `domain`, `c_name`, `c_password`, `c_cn`, `mail`, `aliases`, `ad_aliases`, `ext_acl`, `kind`, `multiple_bookings`)
- SELECT `c_uid`, `domain`, `c_name`, `c_password`, `c_cn`, `mail`, `aliases`, `ad_aliases`, `ext_acl`, `kind`, `multiple_bookings` from sogo_view");
- $stmt = $pdo->query("DELETE FROM _sogo_static_view WHERE `c_uid` NOT IN (SELECT `username` FROM `mailbox` WHERE `active` = '1');");
+ update_sogo_static_view();
echo "Fixed _sogo_static_view" . PHP_EOL;
- }
- catch ( Exception $e ) {
+ } catch (Exception $e) {
// Dunno
}
}
@@ -1487,9 +1576,8 @@
$m = new Memcached();
$m->addServer('memcached', 11211);
$m->flush();
- echo "Cleaned up memcached". PHP_EOL;
- }
- catch ( Exception $e ) {
+ echo "Cleaned up memcached" . PHP_EOL;
+ } catch (Exception $e) {
// Dunno
}
init_db_schema();
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 78033ec..3998065 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.json
@@ -1,7 +1,6 @@
{
"require": {
"robthree/twofactorauth": "^1.6",
- "yubico/u2flib-server": "^1.0",
"phpmailer/phpmailer": "^6.1",
"php-mime-mail-parser/php-mime-mail-parser": "^7",
"soundasleep/html2text": "^0.5.0",
@@ -9,7 +8,10 @@
"matthiasmullie/minify": "^1.3",
"bshaffer/oauth2-server-php": "^1.11",
"mustangostang/spyc": "^0.6.3",
- "directorytree/ldaprecord": "^2.4",
- "twig/twig": "^3.0"
+ "directorytree/ldaprecord": "^3.3",
+ "twig/twig": "^3.0",
+ "stevenmaguire/oauth2-keycloak": "^4.0",
+ "league/oauth2-client": "^2.7",
+ "bacon/bacon-qr-code": "^2.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 7585353..4254def 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.lock
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/composer.lock
@@ -4,9 +4,63 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "139c1e5dec323144cd778ce80fd1847e",
+ "content-hash": "50fb4a320500820e36f30eabc45222a0",
"packages": [
{
+ "name": "bacon/bacon-qr-code",
+ "version": "2.0.8",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Bacon/BaconQrCode.git",
+ "reference": "8674e51bb65af933a5ffaf1c308a660387c35c22"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Bacon/BaconQrCode/zipball/8674e51bb65af933a5ffaf1c308a660387c35c22",
+ "reference": "8674e51bb65af933a5ffaf1c308a660387c35c22",
+ "shasum": ""
+ },
+ "require": {
+ "dasprid/enum": "^1.0.3",
+ "ext-iconv": "*",
+ "php": "^7.1 || ^8.0"
+ },
+ "require-dev": {
+ "phly/keep-a-changelog": "^2.1",
+ "phpunit/phpunit": "^7 | ^8 | ^9",
+ "spatie/phpunit-snapshot-assertions": "^4.2.9",
+ "squizlabs/php_codesniffer": "^3.4"
+ },
+ "suggest": {
+ "ext-imagick": "to generate QR code images"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "BaconQrCode\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-2-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Ben Scholzen 'DASPRiD'",
+ "email": "mail@dasprids.de",
+ "homepage": "https://dasprids.de/",
+ "role": "Developer"
+ }
+ ],
+ "description": "BaconQrCode is a QR code generator for PHP.",
+ "homepage": "https://github.com/Bacon/BaconQrCode",
+ "support": {
+ "issues": "https://github.com/Bacon/BaconQrCode/issues",
+ "source": "https://github.com/Bacon/BaconQrCode/tree/2.0.8"
+ },
+ "time": "2022-12-07T17:46:57+00:00"
+ },
+ {
"name": "bshaffer/oauth2-server-php",
"version": "v1.11.1",
"source": {
@@ -69,6 +123,125 @@
"time": "2018-12-04T00:29:32+00:00"
},
{
+ "name": "carbonphp/carbon-doctrine-types",
+ "version": "3.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/CarbonPHP/carbon-doctrine-types.git",
+ "reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/CarbonPHP/carbon-doctrine-types/zipball/18ba5ddfec8976260ead6e866180bd5d2f71aa1d",
+ "reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.1"
+ },
+ "conflict": {
+ "doctrine/dbal": "<4.0.0 || >=5.0.0"
+ },
+ "require-dev": {
+ "doctrine/dbal": "^4.0.0",
+ "nesbot/carbon": "^2.71.0 || ^3.0.0",
+ "phpunit/phpunit": "^10.3"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Carbon\\Doctrine\\": "src/Carbon/Doctrine/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "KyleKatarn",
+ "email": "kylekatarnls@gmail.com"
+ }
+ ],
+ "description": "Types to use Carbon in Doctrine",
+ "keywords": [
+ "carbon",
+ "date",
+ "datetime",
+ "doctrine",
+ "time"
+ ],
+ "support": {
+ "issues": "https://github.com/CarbonPHP/carbon-doctrine-types/issues",
+ "source": "https://github.com/CarbonPHP/carbon-doctrine-types/tree/3.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/kylekatarnls",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/Carbon",
+ "type": "open_collective"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/nesbot/carbon",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2024-02-09T16:56:22+00:00"
+ },
+ {
+ "name": "dasprid/enum",
+ "version": "1.0.7",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/DASPRiD/Enum.git",
+ "reference": "b5874fa9ed0043116c72162ec7f4fb50e02e7cce"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/DASPRiD/Enum/zipball/b5874fa9ed0043116c72162ec7f4fb50e02e7cce",
+ "reference": "b5874fa9ed0043116c72162ec7f4fb50e02e7cce",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.1 <9.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^7 || ^8 || ^9 || ^10 || ^11",
+ "squizlabs/php_codesniffer": "*"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "DASPRiD\\Enum\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-2-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Ben Scholzen 'DASPRiD'",
+ "email": "mail@dasprids.de",
+ "homepage": "https://dasprids.de/",
+ "role": "Developer"
+ }
+ ],
+ "description": "PHP 7.1 enum implementation",
+ "keywords": [
+ "enum",
+ "map"
+ ],
+ "support": {
+ "issues": "https://github.com/DASPRiD/Enum/issues",
+ "source": "https://github.com/DASPRiD/Enum/tree/1.0.7"
+ },
+ "time": "2025-09-16T12:23:56+00:00"
+ },
+ {
"name": "ddeboer/imap",
"version": "1.13.1",
"source": {
@@ -145,29 +318,32 @@
},
{
"name": "directorytree/ldaprecord",
- "version": "v2.10.1",
+ "version": "v3.8.5",
"source": {
"type": "git",
"url": "https://github.com/DirectoryTree/LdapRecord.git",
- "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88"
+ "reference": "00e5f088f8c4028d5f398783cccc2e8119a27a65"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/bf512d9af7a7b0e2ed7a666ab29cefdd027bee88",
- "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88",
+ "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/00e5f088f8c4028d5f398783cccc2e8119a27a65",
+ "reference": "00e5f088f8c4028d5f398783cccc2e8119a27a65",
"shasum": ""
},
"require": {
+ "ext-iconv": "*",
"ext-json": "*",
"ext-ldap": "*",
- "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0|^9.0",
- "nesbot/carbon": "^1.0|^2.0",
- "php": ">=7.3",
+ "illuminate/collections": "^8.0|^9.0|^10.0|^11.0|^12.0",
+ "illuminate/contracts": "^8.0|^9.0|^10.0|^11.0|^12.0",
+ "nesbot/carbon": "*",
+ "php": ">=8.1",
"psr/log": "*",
- "psr/simple-cache": "^1.0|^2.0",
- "tightenco/collect": "^5.6|^6.0|^7.0|^8.0"
+ "psr/simple-cache": "^1.0|^2.0|^3.0"
},
"require-dev": {
+ "fakerphp/faker": "^1.21",
+ "laravel/pint": "^1.6",
"mockery/mockery": "^1.0",
"phpunit/phpunit": "^9.0",
"spatie/ray": "^1.24"
@@ -214,31 +390,523 @@
"type": "github"
}
],
- "time": "2022-02-25T16:00:51+00:00"
+ "time": "2025-10-06T02:22:34+00:00"
},
{
- "name": "illuminate/contracts",
- "version": "v9.3.0",
+ "name": "firebase/php-jwt",
+ "version": "v6.5.0",
"source": {
"type": "git",
- "url": "https://github.com/illuminate/contracts.git",
- "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0"
+ "url": "https://github.com/firebase/php-jwt.git",
+ "reference": "e94e7353302b0c11ec3cfff7180cd0b1743975d2"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/illuminate/contracts/zipball/bf4b3c254c49d28157645d01e4883b5951b1e1d0",
- "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0",
+ "url": "https://api.github.com/repos/firebase/php-jwt/zipball/e94e7353302b0c11ec3cfff7180cd0b1743975d2",
+ "reference": "e94e7353302b0c11ec3cfff7180cd0b1743975d2",
"shasum": ""
},
"require": {
- "php": "^8.0.2",
+ "php": "^7.4||^8.0"
+ },
+ "require-dev": {
+ "guzzlehttp/guzzle": "^6.5||^7.4",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5",
+ "psr/cache": "^1.0||^2.0",
+ "psr/http-client": "^1.0",
+ "psr/http-factory": "^1.0"
+ },
+ "suggest": {
+ "ext-sodium": "Support EdDSA (Ed25519) signatures",
+ "paragonie/sodium_compat": "Support EdDSA (Ed25519) signatures when libsodium is not present"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Firebase\\JWT\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Neuman Vong",
+ "email": "neuman+pear@twilio.com",
+ "role": "Developer"
+ },
+ {
+ "name": "Anant Narayanan",
+ "email": "anant@php.net",
+ "role": "Developer"
+ }
+ ],
+ "description": "A simple library to encode and decode JSON Web Tokens (JWT) in PHP. Should conform to the current spec.",
+ "homepage": "https://github.com/firebase/php-jwt",
+ "keywords": [
+ "jwt",
+ "php"
+ ],
+ "support": {
+ "issues": "https://github.com/firebase/php-jwt/issues",
+ "source": "https://github.com/firebase/php-jwt/tree/v6.5.0"
+ },
+ "time": "2023-05-12T15:47:07+00:00"
+ },
+ {
+ "name": "guzzlehttp/guzzle",
+ "version": "7.5.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/guzzle.git",
+ "reference": "b50a2a1251152e43f6a37f0fa053e730a67d25ba"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/guzzle/zipball/b50a2a1251152e43f6a37f0fa053e730a67d25ba",
+ "reference": "b50a2a1251152e43f6a37f0fa053e730a67d25ba",
+ "shasum": ""
+ },
+ "require": {
+ "ext-json": "*",
+ "guzzlehttp/promises": "^1.5",
+ "guzzlehttp/psr7": "^1.9 || ^2.4",
+ "php": "^7.2.5 || ^8.0",
+ "psr/http-client": "^1.0",
+ "symfony/deprecation-contracts": "^2.2 || ^3.0"
+ },
+ "provide": {
+ "psr/http-client-implementation": "1.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.1",
+ "ext-curl": "*",
+ "php-http/client-integration-tests": "^3.0",
+ "phpunit/phpunit": "^8.5.29 || ^9.5.23",
+ "psr/log": "^1.1 || ^2.0 || ^3.0"
+ },
+ "suggest": {
+ "ext-curl": "Required for CURL handler support",
+ "ext-intl": "Required for Internationalized Domain Name (IDN) support",
+ "psr/log": "Required for using the Log middleware"
+ },
+ "type": "library",
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ },
+ "branch-alias": {
+ "dev-master": "7.5-dev"
+ }
+ },
+ "autoload": {
+ "files": [
+ "src/functions_include.php"
+ ],
+ "psr-4": {
+ "GuzzleHttp\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Jeremy Lindblom",
+ "email": "jeremeamia@gmail.com",
+ "homepage": "https://github.com/jeremeamia"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "description": "Guzzle is a PHP HTTP client library",
+ "keywords": [
+ "client",
+ "curl",
+ "framework",
+ "http",
+ "http client",
+ "psr-18",
+ "psr-7",
+ "rest",
+ "web service"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/guzzle/issues",
+ "source": "https://github.com/guzzle/guzzle/tree/7.5.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/guzzle",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2022-08-28T15:39:27+00:00"
+ },
+ {
+ "name": "guzzlehttp/promises",
+ "version": "1.5.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/promises.git",
+ "reference": "b94b2807d85443f9719887892882d0329d1e2598"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/promises/zipball/b94b2807d85443f9719887892882d0329d1e2598",
+ "reference": "b94b2807d85443f9719887892882d0329d1e2598",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.5"
+ },
+ "require-dev": {
+ "symfony/phpunit-bridge": "^4.4 || ^5.1"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.5-dev"
+ }
+ },
+ "autoload": {
+ "files": [
+ "src/functions_include.php"
+ ],
+ "psr-4": {
+ "GuzzleHttp\\Promise\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "description": "Guzzle promises library",
+ "keywords": [
+ "promise"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/promises/issues",
+ "source": "https://github.com/guzzle/promises/tree/1.5.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/promises",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2022-08-28T14:55:35+00:00"
+ },
+ {
+ "name": "guzzlehttp/psr7",
+ "version": "2.4.5",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/psr7.git",
+ "reference": "0454e12ef0cd597ccd2adb036f7bda4e7fface66"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/psr7/zipball/0454e12ef0cd597ccd2adb036f7bda4e7fface66",
+ "reference": "0454e12ef0cd597ccd2adb036f7bda4e7fface66",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.2.5 || ^8.0",
+ "psr/http-factory": "^1.0",
+ "psr/http-message": "^1.0",
+ "ralouphie/getallheaders": "^3.0"
+ },
+ "provide": {
+ "psr/http-factory-implementation": "1.0",
+ "psr/http-message-implementation": "1.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.1",
+ "http-interop/http-factory-tests": "^0.9",
+ "phpunit/phpunit": "^8.5.29 || ^9.5.23"
+ },
+ "suggest": {
+ "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses"
+ },
+ "type": "library",
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "GuzzleHttp\\Psr7\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://sagikazarmark.hu"
+ }
+ ],
+ "description": "PSR-7 message implementation that also provides common utility methods",
+ "keywords": [
+ "http",
+ "message",
+ "psr-7",
+ "request",
+ "response",
+ "stream",
+ "uri",
+ "url"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/psr7/issues",
+ "source": "https://github.com/guzzle/psr7/tree/2.4.5"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/psr7",
+ "type": "tidelift"
+ }
+ ],
+ "time": "2023-04-17T16:00:45+00:00"
+ },
+ {
+ "name": "illuminate/collections",
+ "version": "v10.49.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/collections.git",
+ "reference": "6ae9c74fa92d4e1824d1b346cd435e8eacdc3232"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/collections/zipball/6ae9c74fa92d4e1824d1b346cd435e8eacdc3232",
+ "reference": "6ae9c74fa92d4e1824d1b346cd435e8eacdc3232",
+ "shasum": ""
+ },
+ "require": {
+ "illuminate/conditionable": "^10.0",
+ "illuminate/contracts": "^10.0",
+ "illuminate/macroable": "^10.0",
+ "php": "^8.1"
+ },
+ "suggest": {
+ "symfony/var-dumper": "Required to use the dump method (^6.2)."
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "autoload": {
+ "files": [
+ "helpers.php"
+ ],
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "description": "The Illuminate Collections package.",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "time": "2025-09-08T19:05:53+00:00"
+ },
+ {
+ "name": "illuminate/conditionable",
+ "version": "v10.49.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/conditionable.git",
+ "reference": "47c700320b7a419f0d188d111f3bbed978fcbd3f"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/conditionable/zipball/47c700320b7a419f0d188d111f3bbed978fcbd3f",
+ "reference": "47c700320b7a419f0d188d111f3bbed978fcbd3f",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.0.2"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "description": "The Illuminate Conditionable package.",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "time": "2025-03-24T11:47:24+00:00"
+ },
+ {
+ "name": "illuminate/contracts",
+ "version": "v10.44.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/contracts.git",
+ "reference": "8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/contracts/zipball/8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac",
+ "reference": "8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.1",
"psr/container": "^1.1.1|^2.0.1",
"psr/simple-cache": "^1.0|^2.0|^3.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "9.x-dev"
+ "dev-master": "10.x-dev"
}
},
"autoload": {
@@ -262,7 +930,123 @@
"issues": "https://github.com/laravel/framework/issues",
"source": "https://github.com/laravel/framework"
},
- "time": "2022-02-22T14:45:39+00:00"
+ "time": "2024-01-15T18:52:32+00:00"
+ },
+ {
+ "name": "illuminate/macroable",
+ "version": "v10.49.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/macroable.git",
+ "reference": "dff667a46ac37b634dcf68909d9d41e94dc97c27"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/macroable/zipball/dff667a46ac37b634dcf68909d9d41e94dc97c27",
+ "reference": "dff667a46ac37b634dcf68909d9d41e94dc97c27",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.1"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "description": "The Illuminate Macroable package.",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "time": "2023-06-05T12:46:42+00:00"
+ },
+ {
+ "name": "league/oauth2-client",
+ "version": "2.7.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/thephpleague/oauth2-client.git",
+ "reference": "160d6274b03562ebeb55ed18399281d8118b76c8"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/thephpleague/oauth2-client/zipball/160d6274b03562ebeb55ed18399281d8118b76c8",
+ "reference": "160d6274b03562ebeb55ed18399281d8118b76c8",
+ "shasum": ""
+ },
+ "require": {
+ "guzzlehttp/guzzle": "^6.0 || ^7.0",
+ "paragonie/random_compat": "^1 || ^2 || ^9.99",
+ "php": "^5.6 || ^7.0 || ^8.0"
+ },
+ "require-dev": {
+ "mockery/mockery": "^1.3.5",
+ "php-parallel-lint/php-parallel-lint": "^1.3.1",
+ "phpunit/phpunit": "^5.7 || ^6.0 || ^9.5",
+ "squizlabs/php_codesniffer": "^2.3 || ^3.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-2.x": "2.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "League\\OAuth2\\Client\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Alex Bilbie",
+ "email": "hello@alexbilbie.com",
+ "homepage": "http://www.alexbilbie.com",
+ "role": "Developer"
+ },
+ {
+ "name": "Woody Gilk",
+ "homepage": "https://github.com/shadowhand",
+ "role": "Contributor"
+ }
+ ],
+ "description": "OAuth 2.0 Client Library",
+ "keywords": [
+ "Authentication",
+ "SSO",
+ "authorization",
+ "identity",
+ "idp",
+ "oauth",
+ "oauth2",
+ "single sign on"
+ ],
+ "support": {
+ "issues": "https://github.com/thephpleague/oauth2-client/issues",
+ "source": "https://github.com/thephpleague/oauth2-client/tree/2.7.0"
+ },
+ "time": "2023-04-16T18:19:15+00:00"
},
{
"name": "matthiasmullie/minify",
@@ -447,34 +1231,41 @@
},
{
"name": "nesbot/carbon",
- "version": "2.57.0",
+ "version": "2.72.3",
"source": {
"type": "git",
"url": "https://github.com/briannesbitt/Carbon.git",
- "reference": "4a54375c21eea4811dbd1149fe6b246517554e78"
+ "reference": "0c6fd108360c562f6e4fd1dedb8233b423e91c83"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/4a54375c21eea4811dbd1149fe6b246517554e78",
- "reference": "4a54375c21eea4811dbd1149fe6b246517554e78",
+ "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/0c6fd108360c562f6e4fd1dedb8233b423e91c83",
+ "reference": "0c6fd108360c562f6e4fd1dedb8233b423e91c83",
"shasum": ""
},
"require": {
+ "carbonphp/carbon-doctrine-types": "*",
"ext-json": "*",
"php": "^7.1.8 || ^8.0",
+ "psr/clock": "^1.0",
"symfony/polyfill-mbstring": "^1.0",
"symfony/polyfill-php80": "^1.16",
"symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0"
},
+ "provide": {
+ "psr/clock-implementation": "1.0"
+ },
"require-dev": {
- "doctrine/dbal": "^2.0 || ^3.0",
- "doctrine/orm": "^2.7",
+ "doctrine/dbal": "^2.0 || ^3.1.4 || ^4.0",
+ "doctrine/orm": "^2.7 || ^3.0",
"friendsofphp/php-cs-fixer": "^3.0",
"kylekatarnls/multi-tester": "^2.0",
+ "ondrejmirtes/better-reflection": "*",
"phpmd/phpmd": "^2.9",
"phpstan/extension-installer": "^1.0",
- "phpstan/phpstan": "^0.12.54 || ^1.0",
- "phpunit/phpunit": "^7.5.20 || ^8.5.14",
+ "phpstan/phpstan": "^0.12.99 || ^1.7.14",
+ "phpunit/php-file-iterator": "^2.0.5 || ^3.0.6",
+ "phpunit/phpunit": "^7.5.20 || ^8.5.26 || ^9.5.20",
"squizlabs/php_codesniffer": "^3.4"
},
"bin": [
@@ -531,15 +1322,19 @@
},
"funding": [
{
- "url": "https://opencollective.com/Carbon",
- "type": "open_collective"
+ "url": "https://github.com/sponsors/kylekatarnls",
+ "type": "github"
},
{
- "url": "https://tidelift.com/funding/github/packagist/nesbot/carbon",
+ "url": "https://opencollective.com/Carbon#sponsor",
+ "type": "opencollective"
+ },
+ {
+ "url": "https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme",
"type": "tidelift"
}
],
- "time": "2022-02-13T18:13:33+00:00"
+ "time": "2024-01-25T10:35:09+00:00"
},
{
"name": "paragonie/random_compat",
@@ -761,6 +1556,54 @@
"time": "2022-02-28T15:31:21+00:00"
},
{
+ "name": "psr/clock",
+ "version": "1.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/clock.git",
+ "reference": "e41a24703d4560fd0acb709162f73b8adfc3aa0d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/clock/zipball/e41a24703d4560fd0acb709162f73b8adfc3aa0d",
+ "reference": "e41a24703d4560fd0acb709162f73b8adfc3aa0d",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.0 || ^8.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Psr\\Clock\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for reading the clock.",
+ "homepage": "https://github.com/php-fig/clock",
+ "keywords": [
+ "clock",
+ "now",
+ "psr",
+ "psr-20",
+ "time"
+ ],
+ "support": {
+ "issues": "https://github.com/php-fig/clock/issues",
+ "source": "https://github.com/php-fig/clock/tree/1.0.0"
+ },
+ "time": "2022-11-25T14:36:26+00:00"
+ },
+ {
"name": "psr/container",
"version": "2.0.2",
"source": {
@@ -814,6 +1657,166 @@
"time": "2021-11-05T16:47:00+00:00"
},
{
+ "name": "psr/http-client",
+ "version": "1.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-client.git",
+ "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621",
+ "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.0 || ^8.0",
+ "psr/http-message": "^1.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Client\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for HTTP clients",
+ "homepage": "https://github.com/php-fig/http-client",
+ "keywords": [
+ "http",
+ "http-client",
+ "psr",
+ "psr-18"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-client/tree/master"
+ },
+ "time": "2020-06-29T06:28:15+00:00"
+ },
+ {
+ "name": "psr/http-factory",
+ "version": "1.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-factory.git",
+ "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-factory/zipball/12ac7fcd07e5b077433f5f2bee95b3a771bf61be",
+ "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.0.0",
+ "psr/http-message": "^1.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interfaces for PSR-7 HTTP message factories",
+ "keywords": [
+ "factory",
+ "http",
+ "message",
+ "psr",
+ "psr-17",
+ "psr-7",
+ "request",
+ "response"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-factory/tree/master"
+ },
+ "time": "2019-04-30T12:38:16+00:00"
+ },
+ {
+ "name": "psr/http-message",
+ "version": "1.0.1",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-message.git",
+ "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363",
+ "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.3.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for HTTP messages",
+ "homepage": "https://github.com/php-fig/http-message",
+ "keywords": [
+ "http",
+ "http-message",
+ "psr",
+ "psr-7",
+ "request",
+ "response"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-message/tree/master"
+ },
+ "time": "2016-08-06T14:39:51+00:00"
+ },
+ {
"name": "psr/log",
"version": "3.0.0",
"source": {
@@ -915,6 +1918,50 @@
"time": "2021-10-29T13:22:09+00:00"
},
{
+ "name": "ralouphie/getallheaders",
+ "version": "3.0.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/ralouphie/getallheaders.git",
+ "reference": "120b605dfeb996808c31b6477290a714d356e822"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822",
+ "reference": "120b605dfeb996808c31b6477290a714d356e822",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.6"
+ },
+ "require-dev": {
+ "php-coveralls/php-coveralls": "^2.1",
+ "phpunit/phpunit": "^5 || ^6.5"
+ },
+ "type": "library",
+ "autoload": {
+ "files": [
+ "src/getallheaders.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Ralph Khattar",
+ "email": "ralph.khattar@gmail.com"
+ }
+ ],
+ "description": "A polyfill for getallheaders.",
+ "support": {
+ "issues": "https://github.com/ralouphie/getallheaders/issues",
+ "source": "https://github.com/ralouphie/getallheaders/tree/develop"
+ },
+ "time": "2019-03-08T08:55:37+00:00"
+ },
+ {
"name": "robthree/twofactorauth",
"version": "1.8.1",
"source": {
@@ -1040,6 +2087,134 @@
"time": "2017-04-19T22:01:50+00:00"
},
{
+ "name": "stevenmaguire/oauth2-keycloak",
+ "version": "4.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/stevenmaguire/oauth2-keycloak.git",
+ "reference": "05ead6bb6bcd2b6f96dfae87c769dcd3e5f6129d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/stevenmaguire/oauth2-keycloak/zipball/05ead6bb6bcd2b6f96dfae87c769dcd3e5f6129d",
+ "reference": "05ead6bb6bcd2b6f96dfae87c769dcd3e5f6129d",
+ "shasum": ""
+ },
+ "require": {
+ "firebase/php-jwt": "^4.0 || ^5.0 || ^6.0",
+ "league/oauth2-client": "^2.0",
+ "php": "~7.2 || ~8.0"
+ },
+ "require-dev": {
+ "mockery/mockery": "~1.5.0",
+ "phpunit/phpunit": "~9.6.4",
+ "squizlabs/php_codesniffer": "~3.7.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Stevenmaguire\\OAuth2\\Client\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Steven Maguire",
+ "email": "stevenmaguire@gmail.com",
+ "homepage": "https://github.com/stevenmaguire"
+ }
+ ],
+ "description": "Keycloak OAuth 2.0 Client Provider for The PHP League OAuth2-Client",
+ "keywords": [
+ "authorisation",
+ "authorization",
+ "client",
+ "keycloak",
+ "oauth",
+ "oauth2"
+ ],
+ "support": {
+ "issues": "https://github.com/stevenmaguire/oauth2-keycloak/issues",
+ "source": "https://github.com/stevenmaguire/oauth2-keycloak/tree/4.0.0"
+ },
+ "time": "2023-03-14T09:43:47+00:00"
+ },
+ {
+ "name": "symfony/deprecation-contracts",
+ "version": "v3.5.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/deprecation-contracts.git",
+ "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
+ "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.1"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.5-dev"
+ },
+ "thanks": {
+ "name": "symfony/contracts",
+ "url": "https://github.com/symfony/contracts"
+ }
+ },
+ "autoload": {
+ "files": [
+ "function.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Nicolas Grekas",
+ "email": "p@tchwork.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "description": "A generic function and convention to trigger deprecation notices",
+ "homepage": "https://symfony.com",
+ "support": {
+ "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.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": "2024-04-18T09:32:20+00:00"
+ },
+ {
"name": "symfony/polyfill-ctype",
"version": "v1.24.0",
"source": {
@@ -1123,16 +2298,16 @@
},
{
"name": "symfony/polyfill-mbstring",
- "version": "v1.24.0",
+ "version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git",
- "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825"
+ "reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/0abb51d2f102e00a4eefcf46ba7fec406d245825",
- "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825",
+ "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
+ "reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
"shasum": ""
},
"require": {
@@ -1146,9 +2321,6 @@
},
"type": "library",
"extra": {
- "branch-alias": {
- "dev-main": "1.23-dev"
- },
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1186,7 +2358,7 @@
"shim"
],
"support": {
- "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.24.0"
+ "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.29.0"
},
"funding": [
{
@@ -1202,20 +2374,20 @@
"type": "tidelift"
}
],
- "time": "2021-11-30T18:21:41+00:00"
+ "time": "2024-01-29T20:11:03+00:00"
},
{
"name": "symfony/polyfill-php80",
- "version": "v1.24.0",
+ "version": "v1.29.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php80.git",
- "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9"
+ "reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/57b712b08eddb97c762a8caa32c84e037892d2e9",
- "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9",
+ "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/87b68208d5c1188808dd7839ee1e6c8ec3b02f1b",
+ "reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b",
"shasum": ""
},
"require": {
@@ -1223,9 +2395,6 @@
},
"type": "library",
"extra": {
- "branch-alias": {
- "dev-main": "1.23-dev"
- },
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1269,7 +2438,7 @@
"shim"
],
"support": {
- "source": "https://github.com/symfony/polyfill-php80/tree/v1.24.0"
+ "source": "https://github.com/symfony/polyfill-php80/tree/v1.29.0"
},
"funding": [
{
@@ -1285,32 +2454,111 @@
"type": "tidelift"
}
],
- "time": "2021-09-13T13:58:33+00:00"
+ "time": "2024-01-29T20:11:03+00:00"
},
{
- "name": "symfony/translation",
- "version": "v6.0.5",
+ "name": "symfony/polyfill-php81",
+ "version": "v1.31.0",
"source": {
"type": "git",
- "url": "https://github.com/symfony/translation.git",
- "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875"
+ "url": "https://github.com/symfony/polyfill-php81.git",
+ "reference": "4a4cfc2d253c21a5ad0e53071df248ed48c6ce5c"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/translation/zipball/e69501c71107cc3146b32aaa45f4edd0c3427875",
- "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875",
+ "url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/4a4cfc2d253c21a5ad0e53071df248ed48c6ce5c",
+ "reference": "4a4cfc2d253c21a5ad0e53071df248ed48c6ce5c",
"shasum": ""
},
"require": {
- "php": ">=8.0.2",
+ "php": ">=7.2"
+ },
+ "type": "library",
+ "extra": {
+ "thanks": {
+ "name": "symfony/polyfill",
+ "url": "https://github.com/symfony/polyfill"
+ }
+ },
+ "autoload": {
+ "files": [
+ "bootstrap.php"
+ ],
+ "psr-4": {
+ "Symfony\\Polyfill\\Php81\\": ""
+ },
+ "classmap": [
+ "Resources/stubs"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Nicolas Grekas",
+ "email": "p@tchwork.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions",
+ "homepage": "https://symfony.com",
+ "keywords": [
+ "compatibility",
+ "polyfill",
+ "portable",
+ "shim"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-php81/tree/v1.31.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": "2024-09-09T11:45:10+00:00"
+ },
+ {
+ "name": "symfony/translation",
+ "version": "v6.4.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/translation.git",
+ "reference": "637c51191b6b184184bbf98937702bcf554f7d04"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/translation/zipball/637c51191b6b184184bbf98937702bcf554f7d04",
+ "reference": "637c51191b6b184184bbf98937702bcf554f7d04",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.1",
+ "symfony/deprecation-contracts": "^2.5|^3",
"symfony/polyfill-mbstring": "~1.0",
- "symfony/translation-contracts": "^2.3|^3.0"
+ "symfony/translation-contracts": "^2.5|^3.0"
},
"conflict": {
"symfony/config": "<5.4",
"symfony/console": "<5.4",
"symfony/dependency-injection": "<5.4",
+ "symfony/http-client-contracts": "<2.5",
"symfony/http-kernel": "<5.4",
+ "symfony/service-contracts": "<2.5",
"symfony/twig-bundle": "<5.4",
"symfony/yaml": "<5.4"
},
@@ -1318,22 +2566,19 @@
"symfony/translation-implementation": "2.3|3.0"
},
"require-dev": {
+ "nikic/php-parser": "^4.18|^5.0",
"psr/log": "^1|^2|^3",
- "symfony/config": "^5.4|^6.0",
- "symfony/console": "^5.4|^6.0",
- "symfony/dependency-injection": "^5.4|^6.0",
- "symfony/finder": "^5.4|^6.0",
- "symfony/http-client-contracts": "^1.1|^2.0|^3.0",
- "symfony/http-kernel": "^5.4|^6.0",
- "symfony/intl": "^5.4|^6.0",
+ "symfony/config": "^5.4|^6.0|^7.0",
+ "symfony/console": "^5.4|^6.0|^7.0",
+ "symfony/dependency-injection": "^5.4|^6.0|^7.0",
+ "symfony/finder": "^5.4|^6.0|^7.0",
+ "symfony/http-client-contracts": "^2.5|^3.0",
+ "symfony/http-kernel": "^5.4|^6.0|^7.0",
+ "symfony/intl": "^5.4|^6.0|^7.0",
"symfony/polyfill-intl-icu": "^1.21",
- "symfony/service-contracts": "^1.1.2|^2|^3",
- "symfony/yaml": "^5.4|^6.0"
- },
- "suggest": {
- "psr/log-implementation": "To use logging capability in translator",
- "symfony/config": "",
- "symfony/yaml": ""
+ "symfony/routing": "^5.4|^6.0|^7.0",
+ "symfony/service-contracts": "^2.5|^3",
+ "symfony/yaml": "^5.4|^6.0|^7.0"
},
"type": "library",
"autoload": {
@@ -1364,7 +2609,7 @@
"description": "Provides tools to internationalize your application",
"homepage": "https://symfony.com",
"support": {
- "source": "https://github.com/symfony/translation/tree/v6.0.5"
+ "source": "https://github.com/symfony/translation/tree/v6.4.3"
},
"funding": [
{
@@ -1380,32 +2625,29 @@
"type": "tidelift"
}
],
- "time": "2022-02-09T15:52:48+00:00"
+ "time": "2024-01-29T13:11:52+00:00"
},
{
"name": "symfony/translation-contracts",
- "version": "v3.0.0",
+ "version": "v3.4.1",
"source": {
"type": "git",
"url": "https://github.com/symfony/translation-contracts.git",
- "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77"
+ "reference": "06450585bf65e978026bda220cdebca3f867fde7"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/1b6ea5a7442af5a12dba3dbd6d71034b5b234e77",
- "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77",
+ "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/06450585bf65e978026bda220cdebca3f867fde7",
+ "reference": "06450585bf65e978026bda220cdebca3f867fde7",
"shasum": ""
},
"require": {
- "php": ">=8.0.2"
- },
- "suggest": {
- "symfony/translation-implementation": ""
+ "php": ">=8.1"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "3.0-dev"
+ "dev-main": "3.4-dev"
},
"thanks": {
"name": "symfony/contracts",
@@ -1415,7 +2657,10 @@
"autoload": {
"psr-4": {
"Symfony\\Contracts\\Translation\\": ""
- }
+ },
+ "exclude-from-classmap": [
+ "/Test/"
+ ]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
@@ -1442,7 +2687,7 @@
"standards"
],
"support": {
- "source": "https://github.com/symfony/translation-contracts/tree/v3.0.0"
+ "source": "https://github.com/symfony/translation-contracts/tree/v3.4.1"
},
"funding": [
{
@@ -1458,180 +2703,41 @@
"type": "tidelift"
}
],
- "time": "2021-09-07T12:43:40+00:00"
+ "time": "2023-12-26T14:02:43+00:00"
},
{
- "name": "symfony/var-dumper",
- "version": "v6.0.5",
+ "name": "twig/twig",
+ "version": "v3.14.0",
"source": {
"type": "git",
- "url": "https://github.com/symfony/var-dumper.git",
- "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce"
+ "url": "https://github.com/twigphp/Twig.git",
+ "reference": "126b2c97818dbff0cdf3fbfc881aedb3d40aae72"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/var-dumper/zipball/60d6a756d5f485df5e6e40b337334848f79f61ce",
- "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce",
+ "url": "https://api.github.com/repos/twigphp/Twig/zipball/126b2c97818dbff0cdf3fbfc881aedb3d40aae72",
+ "reference": "126b2c97818dbff0cdf3fbfc881aedb3d40aae72",
"shasum": ""
},
"require": {
"php": ">=8.0.2",
- "symfony/polyfill-mbstring": "~1.0"
- },
- "conflict": {
- "phpunit/phpunit": "<5.4.3",
- "symfony/console": "<5.4"
- },
- "require-dev": {
- "ext-iconv": "*",
- "symfony/console": "^5.4|^6.0",
- "symfony/process": "^5.4|^6.0",
- "symfony/uid": "^5.4|^6.0",
- "twig/twig": "^2.13|^3.0.4"
- },
- "suggest": {
- "ext-iconv": "To convert non-UTF-8 strings to UTF-8 (or symfony/polyfill-iconv in case ext-iconv cannot be used).",
- "ext-intl": "To show region name in time zone dump",
- "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script"
- },
- "bin": [
- "Resources/bin/var-dump-server"
- ],
- "type": "library",
- "autoload": {
- "files": [
- "Resources/functions/dump.php"
- ],
- "psr-4": {
- "Symfony\\Component\\VarDumper\\": ""
- },
- "exclude-from-classmap": [
- "/Tests/"
- ]
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "MIT"
- ],
- "authors": [
- {
- "name": "Nicolas Grekas",
- "email": "p@tchwork.com"
- },
- {
- "name": "Symfony Community",
- "homepage": "https://symfony.com/contributors"
- }
- ],
- "description": "Provides mechanisms for walking through any arbitrary PHP variable",
- "homepage": "https://symfony.com",
- "keywords": [
- "debug",
- "dump"
- ],
- "support": {
- "source": "https://github.com/symfony/var-dumper/tree/v6.0.5"
- },
- "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": "2022-02-21T17:15:17+00:00"
- },
- {
- "name": "tightenco/collect",
- "version": "v8.83.2",
- "source": {
- "type": "git",
- "url": "https://github.com/tighten/collect.git",
- "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/tighten/collect/zipball/d9c66d586ec2d216d8a31283d73f8df1400cc722",
- "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722",
- "shasum": ""
- },
- "require": {
- "php": "^7.3|^8.0",
- "symfony/var-dumper": "^3.4 || ^4.0 || ^5.0 || ^6.0"
- },
- "require-dev": {
- "mockery/mockery": "^1.0",
- "nesbot/carbon": "^2.23.0",
- "phpunit/phpunit": "^8.3"
- },
- "type": "library",
- "autoload": {
- "files": [
- "src/Collect/Support/helpers.php",
- "src/Collect/Support/alias.php"
- ],
- "psr-4": {
- "Tightenco\\Collect\\": "src/Collect"
- }
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "MIT"
- ],
- "authors": [
- {
- "name": "Taylor Otwell",
- "email": "taylorotwell@gmail.com"
- }
- ],
- "description": "Collect - Illuminate Collections as a separate package.",
- "keywords": [
- "collection",
- "laravel"
- ],
- "support": {
- "issues": "https://github.com/tighten/collect/issues",
- "source": "https://github.com/tighten/collect/tree/v8.83.2"
- },
- "time": "2022-02-16T16:15:54+00:00"
- },
- {
- "name": "twig/twig",
- "version": "v3.4.3",
- "source": {
- "type": "git",
- "url": "https://github.com/twigphp/Twig.git",
- "reference": "c38fd6b0b7f370c198db91ffd02e23b517426b58"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/twigphp/Twig/zipball/c38fd6b0b7f370c198db91ffd02e23b517426b58",
- "reference": "c38fd6b0b7f370c198db91ffd02e23b517426b58",
- "shasum": ""
- },
- "require": {
- "php": ">=7.2.5",
+ "symfony/deprecation-contracts": "^2.5|^3",
"symfony/polyfill-ctype": "^1.8",
- "symfony/polyfill-mbstring": "^1.3"
+ "symfony/polyfill-mbstring": "^1.3",
+ "symfony/polyfill-php81": "^1.29"
},
"require-dev": {
- "psr/container": "^1.0",
- "symfony/phpunit-bridge": "^4.4.9|^5.0.9|^6.0"
+ "psr/container": "^1.0|^2.0",
+ "symfony/phpunit-bridge": "^5.4.9|^6.4|^7.0"
},
"type": "library",
- "extra": {
- "branch-alias": {
- "dev-master": "3.4-dev"
- }
- },
"autoload": {
+ "files": [
+ "src/Resources/core.php",
+ "src/Resources/debug.php",
+ "src/Resources/escaper.php",
+ "src/Resources/string_loader.php"
+ ],
"psr-4": {
"Twig\\": "src/"
}
@@ -1664,7 +2770,7 @@
],
"support": {
"issues": "https://github.com/twigphp/Twig/issues",
- "source": "https://github.com/twigphp/Twig/tree/v3.4.3"
+ "source": "https://github.com/twigphp/Twig/tree/v3.14.0"
},
"funding": [
{
@@ -1676,57 +2782,16 @@
"type": "tidelift"
}
],
- "time": "2022-09-28T08:42:51+00:00"
- },
- {
- "name": "yubico/u2flib-server",
- "version": "1.0.2",
- "source": {
- "type": "git",
- "url": "https://github.com/Yubico/php-u2flib-server.git",
- "reference": "55d813acf68212ad2cadecde07551600d6971939"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/Yubico/php-u2flib-server/zipball/55d813acf68212ad2cadecde07551600d6971939",
- "reference": "55d813acf68212ad2cadecde07551600d6971939",
- "shasum": ""
- },
- "require": {
- "ext-openssl": "*",
- "paragonie/random_compat": ">= 1",
- "php": ">=5.6"
- },
- "require-dev": {
- "phpunit/phpunit": "~5.7",
- "vimeo/psalm": "^0|^1|^2"
- },
- "type": "library",
- "autoload": {
- "classmap": [
- "src/"
- ]
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "BSD-2-Clause"
- ],
- "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"
+ "time": "2024-09-09T17:55:12+00:00"
}
],
"packages-dev": [],
"aliases": [],
"minimum-stability": "stable",
- "stability-flags": [],
+ "stability-flags": {},
"prefer-stable": false,
"prefer-lowest": false,
- "platform": [],
- "platform-dev": [],
- "plugin-api-version": "2.3.0"
+ "platform": {},
+ "platform-dev": {},
+ "plugin-api-version": "2.6.0"
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/sieve/extensions/enotify.xml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/sieve/extensions/enotify.xml
new file mode 100644
index 0000000..b4686a3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/sieve/extensions/enotify.xml
@@ -0,0 +1,33 @@
+<?xml version='1.0' standalone='yes'?>
+
+<extension name="enotify">
+ <command name="notify">
+ <parameter type="tag" name="from" occurrence="optional">
+ <parameter type="string" name="from-address" />
+ </parameter>
+
+ <parameter type="tag" name="importance" regex="(1|2|3)" occurrence="optional" />
+
+ <parameter type="tag" name="options" occurrence="optional">
+ <parameter type="stringlist" name="option-strings" />
+ </parameter>
+
+ <parameter type="tag" name="message" occurrence="optional">
+ <parameter type="string" name="message-text" />
+ </parameter>
+
+ <parameter type="string" name="method" />
+ </command>
+
+ <test name="valid_notify_method">
+ <parameter type="stringlist" name="notification-uris" />
+ </test>
+
+ <test name="notify_method_capability">
+ <parameter type="string" name="notification-uri" />
+ <parameter type="string" name="notification-capability" />
+ <parameter type="stringlist" name="key-list" />
+ </test>
+
+ <modifier name="encodeurl" />
+</extension>
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/sieve/extensions/mime.xml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/sieve/extensions/mime.xml
new file mode 100644
index 0000000..d7e200f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/sieve/extensions/mime.xml
@@ -0,0 +1,58 @@
+<?xml version='1.0' standalone='yes'?>
+
+<extension name="mime">
+ <command name="foreverypart">
+ <parameter type="string" name="name" occurrence="optional" />
+ <block />
+ </command>
+
+ <command name="break">
+ <parameter type="string" name="name" occurrence="optional" />
+ </command>
+
+ <tagged-argument extends="(header|address|exists)">
+ <parameter type="tag" name="mime" regex="mime" occurrence="optional" />
+ </tagged-argument>
+ <tagged-argument extends="(header|address|exists)">
+ <parameter type="tag" name="anychild" regex="anychild" occurrence="optional" />
+ </tagged-argument>
+ <tagged-argument extends="(header)">
+ <parameter type="tag" name="type" occurrence="optional" />
+ </tagged-argument>
+ <tagged-argument extends="(header)">
+ <parameter type="tag" name="subtype" occurrence="optional" />
+ </tagged-argument>
+ <tagged-argument extends="(header)">
+ <parameter type="tag" name="contenttype" occurrence="optional" />
+ </tagged-argument>
+ <tagged-argument extends="(header)">
+ <parameter type="tag" name="param" regex="param" occurrence="optional">
+ <parameter type="stringlist" name="param-list" />
+ </parameter>
+ </tagged-argument>
+ <tagged-argument extends="(header|address|exists)">
+ <parameter type="stringlist" name="header-names" />
+ </tagged-argument>
+ <tagged-argument extends="(header)">
+ <parameter type="stringlist" name="key-list" />
+ </tagged-argument>
+
+ <action name="replace">
+ <parameter type="tag" name="mime" regex="mime" occurrence="optional" />
+ <parameter type="string" name="subject" occurrence="optional" />
+ <parameter type="string" name="from" occurrence="optional" />
+ <parameter type="string" name="replacement" />
+ </action>
+
+ <action name="enclose">
+ <parameter type="string" name="subject" occurrence="optional" />
+ <parameter type="stringlist" name="headers" occurrence="optional" />
+ <parameter type="string" name="text" />
+ </action>
+
+ <action name="extracttext">
+ <parameter type="tag" name="first" regex="first" occurrence="optional" />
+ <parameter type="number" name="number" occurrence="optional" />
+ <parameter type="string" name="varname" />
+ </action>
+</extension>
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/autoload.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/autoload.php
index c21364e..a0fb8f4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/autoload.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/autoload.php
@@ -3,8 +3,21 @@
// autoload.php @generated by Composer
if (PHP_VERSION_ID < 50600) {
- echo 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
- exit(1);
+ if (!headers_sent()) {
+ header('HTTP/1.1 500 Internal Server Error');
+ }
+ $err = 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
+ if (!ini_get('display_errors')) {
+ if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
+ fwrite(STDERR, $err);
+ } elseif (!headers_sent()) {
+ echo $err;
+ }
+ }
+ trigger_error(
+ $err,
+ E_USER_ERROR
+ );
}
require_once __DIR__ . '/composer/autoload_real.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/LICENSE
new file mode 100644
index 0000000..d45a356
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/LICENSE
@@ -0,0 +1,22 @@
+Copyright (c) 2017, Ben Scholzen 'DASPRiD'
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+1. Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+2. 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.
+
+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/bacon/bacon-qr-code/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/README.md
new file mode 100644
index 0000000..9c099fe
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/README.md
@@ -0,0 +1,39 @@
+# QR Code generator
+
+[](https://github.com/Bacon/BaconQrCode/actions/workflows/ci.yml)
+[](https://codecov.io/gh/Bacon/BaconQrCode)
+[](https://packagist.org/packages/bacon/bacon-qr-code)
+[](https://packagist.org/packages/bacon/bacon-qr-code)
+[](https://packagist.org/packages/bacon/bacon-qr-code)
+
+
+## Introduction
+BaconQrCode is a port of QR code portion of the ZXing library. It currently
+only features the encoder part, but could later receive the decoder part as
+well.
+
+As the Reed Solomon codec implementation of the ZXing library performs quite
+slow in PHP, it was exchanged with the implementation by Phil Karn.
+
+
+## Example usage
+```php
+use BaconQrCode\Renderer\ImageRenderer;
+use BaconQrCode\Renderer\Image\ImagickImageBackEnd;
+use BaconQrCode\Renderer\RendererStyle\RendererStyle;
+use BaconQrCode\Writer;
+
+$renderer = new ImageRenderer(
+ new RendererStyle(400),
+ new ImagickImageBackEnd()
+);
+$writer = new Writer($renderer);
+$writer->writeFile('Hello World!', 'qrcode.png');
+```
+
+## Available image renderer back ends
+BaconQrCode comes with multiple back ends for rendering images. Currently included are the following:
+
+- `ImagickImageBackEnd`: renders raster images using the Imagick library
+- `SvgImageBackEnd`: renders SVG files using XMLWriter
+- `EpsImageBackEnd`: renders EPS files
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/composer.json
new file mode 100644
index 0000000..7f193da
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/composer.json
@@ -0,0 +1,44 @@
+{
+ "name": "bacon/bacon-qr-code",
+ "description": "BaconQrCode is a QR code generator for PHP.",
+ "license" : "BSD-2-Clause",
+ "homepage": "https://github.com/Bacon/BaconQrCode",
+ "require": {
+ "php": "^7.1 || ^8.0",
+ "ext-iconv": "*",
+ "dasprid/enum": "^1.0.3"
+ },
+ "suggest": {
+ "ext-imagick": "to generate QR code images"
+ },
+ "authors": [
+ {
+ "name": "Ben Scholzen 'DASPRiD'",
+ "email": "mail@dasprids.de",
+ "homepage": "https://dasprids.de/",
+ "role": "Developer"
+ }
+ ],
+ "autoload": {
+ "psr-4": {
+ "BaconQrCode\\": "src/"
+ }
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^7 | ^8 | ^9",
+ "spatie/phpunit-snapshot-assertions": "^4.2.9",
+ "squizlabs/php_codesniffer": "^3.4",
+ "phly/keep-a-changelog": "^2.1"
+ },
+ "config": {
+ "allow-plugins": {
+ "ocramius/package-versions": true
+ }
+ },
+ "archive": {
+ "exclude": [
+ "/test",
+ "/phpunit.xml.dist"
+ ]
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/phpunit.xml.dist b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/phpunit.xml.dist
new file mode 100644
index 0000000..d9e4d57
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/phpunit.xml.dist
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd" bootstrap="vendor/autoload.php" colors="true">
+ <coverage processUncoveredFiles="true">
+ <include>
+ <directory suffix=".php">src</directory>
+ </include>
+ </coverage>
+ <testsuites>
+ <testsuite name="BaconQrCode Tests">
+ <directory>./test</directory>
+ </testsuite>
+ </testsuites>
+</phpunit>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitArray.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitArray.php
new file mode 100644
index 0000000..158384f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitArray.php
@@ -0,0 +1,372 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+use BaconQrCode\Exception\InvalidArgumentException;
+use SplFixedArray;
+
+/**
+ * A simple, fast array of bits.
+ */
+final class BitArray
+{
+ /**
+ * Bits represented as an array of integers.
+ *
+ * @var SplFixedArray<int>
+ */
+ private $bits;
+
+ /**
+ * Size of the bit array in bits.
+ *
+ * @var int
+ */
+ private $size;
+
+ /**
+ * Creates a new bit array with a given size.
+ */
+ public function __construct(int $size = 0)
+ {
+ $this->size = $size;
+ $this->bits = SplFixedArray::fromArray(array_fill(0, ($this->size + 31) >> 3, 0));
+ }
+
+ /**
+ * Gets the size in bits.
+ */
+ public function getSize() : int
+ {
+ return $this->size;
+ }
+
+ /**
+ * Gets the size in bytes.
+ */
+ public function getSizeInBytes() : int
+ {
+ return ($this->size + 7) >> 3;
+ }
+
+ /**
+ * Ensures that the array has a minimum capacity.
+ */
+ public function ensureCapacity(int $size) : void
+ {
+ if ($size > count($this->bits) << 5) {
+ $this->bits->setSize(($size + 31) >> 5);
+ }
+ }
+
+ /**
+ * Gets a specific bit.
+ */
+ public function get(int $i) : bool
+ {
+ return 0 !== ($this->bits[$i >> 5] & (1 << ($i & 0x1f)));
+ }
+
+ /**
+ * Sets a specific bit.
+ */
+ public function set(int $i) : void
+ {
+ $this->bits[$i >> 5] = $this->bits[$i >> 5] | 1 << ($i & 0x1f);
+ }
+
+ /**
+ * Flips a specific bit.
+ */
+ public function flip(int $i) : void
+ {
+ $this->bits[$i >> 5] ^= 1 << ($i & 0x1f);
+ }
+
+ /**
+ * Gets the next set bit position from a given position.
+ */
+ public function getNextSet(int $from) : int
+ {
+ if ($from >= $this->size) {
+ return $this->size;
+ }
+
+ $bitsOffset = $from >> 5;
+ $currentBits = $this->bits[$bitsOffset];
+ $bitsLength = count($this->bits);
+ $currentBits &= ~((1 << ($from & 0x1f)) - 1);
+
+ while (0 === $currentBits) {
+ if (++$bitsOffset === $bitsLength) {
+ return $this->size;
+ }
+
+ $currentBits = $this->bits[$bitsOffset];
+ }
+
+ $result = ($bitsOffset << 5) + BitUtils::numberOfTrailingZeros($currentBits);
+ return $result > $this->size ? $this->size : $result;
+ }
+
+ /**
+ * Gets the next unset bit position from a given position.
+ */
+ public function getNextUnset(int $from) : int
+ {
+ if ($from >= $this->size) {
+ return $this->size;
+ }
+
+ $bitsOffset = $from >> 5;
+ $currentBits = ~$this->bits[$bitsOffset];
+ $bitsLength = count($this->bits);
+ $currentBits &= ~((1 << ($from & 0x1f)) - 1);
+
+ while (0 === $currentBits) {
+ if (++$bitsOffset === $bitsLength) {
+ return $this->size;
+ }
+
+ $currentBits = ~$this->bits[$bitsOffset];
+ }
+
+ $result = ($bitsOffset << 5) + BitUtils::numberOfTrailingZeros($currentBits);
+ return $result > $this->size ? $this->size : $result;
+ }
+
+ /**
+ * Sets a bulk of bits.
+ */
+ public function setBulk(int $i, int $newBits) : void
+ {
+ $this->bits[$i >> 5] = $newBits;
+ }
+
+ /**
+ * Sets a range of bits.
+ *
+ * @throws InvalidArgumentException if end is smaller than start
+ */
+ public function setRange(int $start, int $end) : void
+ {
+ if ($end < $start) {
+ throw new InvalidArgumentException('End must be greater or equal to start');
+ }
+
+ if ($end === $start) {
+ return;
+ }
+
+ --$end;
+
+ $firstInt = $start >> 5;
+ $lastInt = $end >> 5;
+
+ for ($i = $firstInt; $i <= $lastInt; ++$i) {
+ $firstBit = $i > $firstInt ? 0 : $start & 0x1f;
+ $lastBit = $i < $lastInt ? 31 : $end & 0x1f;
+
+ if (0 === $firstBit && 31 === $lastBit) {
+ $mask = 0x7fffffff;
+ } else {
+ $mask = 0;
+
+ for ($j = $firstBit; $j < $lastBit; ++$j) {
+ $mask |= 1 << $j;
+ }
+ }
+
+ $this->bits[$i] = $this->bits[$i] | $mask;
+ }
+ }
+
+ /**
+ * Clears the bit array, unsetting every bit.
+ */
+ public function clear() : void
+ {
+ $bitsLength = count($this->bits);
+
+ for ($i = 0; $i < $bitsLength; ++$i) {
+ $this->bits[$i] = 0;
+ }
+ }
+
+ /**
+ * Checks if a range of bits is set or not set.
+
+ * @throws InvalidArgumentException if end is smaller than start
+ */
+ public function isRange(int $start, int $end, bool $value) : bool
+ {
+ if ($end < $start) {
+ throw new InvalidArgumentException('End must be greater or equal to start');
+ }
+
+ if ($end === $start) {
+ return true;
+ }
+
+ --$end;
+
+ $firstInt = $start >> 5;
+ $lastInt = $end >> 5;
+
+ for ($i = $firstInt; $i <= $lastInt; ++$i) {
+ $firstBit = $i > $firstInt ? 0 : $start & 0x1f;
+ $lastBit = $i < $lastInt ? 31 : $end & 0x1f;
+
+ if (0 === $firstBit && 31 === $lastBit) {
+ $mask = 0x7fffffff;
+ } else {
+ $mask = 0;
+
+ for ($j = $firstBit; $j <= $lastBit; ++$j) {
+ $mask |= 1 << $j;
+ }
+ }
+
+ if (($this->bits[$i] & $mask) !== ($value ? $mask : 0)) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Appends a bit to the array.
+ */
+ public function appendBit(bool $bit) : void
+ {
+ $this->ensureCapacity($this->size + 1);
+
+ if ($bit) {
+ $this->bits[$this->size >> 5] = $this->bits[$this->size >> 5] | (1 << ($this->size & 0x1f));
+ }
+
+ ++$this->size;
+ }
+
+ /**
+ * Appends a number of bits (up to 32) to the array.
+
+ * @throws InvalidArgumentException if num bits is not between 0 and 32
+ */
+ public function appendBits(int $value, int $numBits) : void
+ {
+ if ($numBits < 0 || $numBits > 32) {
+ throw new InvalidArgumentException('Num bits must be between 0 and 32');
+ }
+
+ $this->ensureCapacity($this->size + $numBits);
+
+ for ($numBitsLeft = $numBits; $numBitsLeft > 0; $numBitsLeft--) {
+ $this->appendBit((($value >> ($numBitsLeft - 1)) & 0x01) === 1);
+ }
+ }
+
+ /**
+ * Appends another bit array to this array.
+ */
+ public function appendBitArray(self $other) : void
+ {
+ $otherSize = $other->getSize();
+ $this->ensureCapacity($this->size + $other->getSize());
+
+ for ($i = 0; $i < $otherSize; ++$i) {
+ $this->appendBit($other->get($i));
+ }
+ }
+
+ /**
+ * Makes an exclusive-or comparision on the current bit array.
+ *
+ * @throws InvalidArgumentException if sizes don't match
+ */
+ public function xorBits(self $other) : void
+ {
+ $bitsLength = count($this->bits);
+ $otherBits = $other->getBitArray();
+
+ if ($bitsLength !== count($otherBits)) {
+ throw new InvalidArgumentException('Sizes don\'t match');
+ }
+
+ for ($i = 0; $i < $bitsLength; ++$i) {
+ $this->bits[$i] = $this->bits[$i] ^ $otherBits[$i];
+ }
+ }
+
+ /**
+ * Converts the bit array to a byte array.
+ *
+ * @return SplFixedArray<int>
+ */
+ public function toBytes(int $bitOffset, int $numBytes) : SplFixedArray
+ {
+ $bytes = new SplFixedArray($numBytes);
+
+ for ($i = 0; $i < $numBytes; ++$i) {
+ $byte = 0;
+
+ for ($j = 0; $j < 8; ++$j) {
+ if ($this->get($bitOffset)) {
+ $byte |= 1 << (7 - $j);
+ }
+
+ ++$bitOffset;
+ }
+
+ $bytes[$i] = $byte;
+ }
+
+ return $bytes;
+ }
+
+ /**
+ * Gets the internal bit array.
+ *
+ * @return SplFixedArray<int>
+ */
+ public function getBitArray() : SplFixedArray
+ {
+ return $this->bits;
+ }
+
+ /**
+ * Reverses the array.
+ */
+ public function reverse() : void
+ {
+ $newBits = new SplFixedArray(count($this->bits));
+
+ for ($i = 0; $i < $this->size; ++$i) {
+ if ($this->get($this->size - $i - 1)) {
+ $newBits[$i >> 5] = $newBits[$i >> 5] | (1 << ($i & 0x1f));
+ }
+ }
+
+ $this->bits = $newBits;
+ }
+
+ /**
+ * Returns a string representation of the bit array.
+ */
+ public function __toString() : string
+ {
+ $result = '';
+
+ for ($i = 0; $i < $this->size; ++$i) {
+ if (0 === ($i & 0x07)) {
+ $result .= ' ';
+ }
+
+ $result .= $this->get($i) ? 'X' : '.';
+ }
+
+ return $result;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitMatrix.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitMatrix.php
new file mode 100644
index 0000000..10bf8fe
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitMatrix.php
@@ -0,0 +1,313 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+use BaconQrCode\Exception\InvalidArgumentException;
+use SplFixedArray;
+
+/**
+ * Bit matrix.
+ *
+ * Represents a 2D matrix of bits. In function arguments below, and throughout
+ * the common module, x is the column position, and y is the row position. The
+ * ordering is always x, y. The origin is at the top-left.
+ */
+class BitMatrix
+{
+ /**
+ * Width of the bit matrix.
+ *
+ * @var int
+ */
+ private $width;
+
+ /**
+ * Height of the bit matrix.
+ *
+ * @var int
+ */
+ private $height;
+
+ /**
+ * Size in bits of each individual row.
+ *
+ * @var int
+ */
+ private $rowSize;
+
+ /**
+ * Bits representation.
+ *
+ * @var SplFixedArray<int>
+ */
+ private $bits;
+
+ /**
+ * @throws InvalidArgumentException if a dimension is smaller than zero
+ */
+ public function __construct(int $width, int $height = null)
+ {
+ if (null === $height) {
+ $height = $width;
+ }
+
+ if ($width < 1 || $height < 1) {
+ throw new InvalidArgumentException('Both dimensions must be greater than zero');
+ }
+
+ $this->width = $width;
+ $this->height = $height;
+ $this->rowSize = ($width + 31) >> 5;
+ $this->bits = SplFixedArray::fromArray(array_fill(0, $this->rowSize * $height, 0));
+ }
+
+ /**
+ * Gets the requested bit, where true means black.
+ */
+ public function get(int $x, int $y) : bool
+ {
+ $offset = $y * $this->rowSize + ($x >> 5);
+ return 0 !== (BitUtils::unsignedRightShift($this->bits[$offset], ($x & 0x1f)) & 1);
+ }
+
+ /**
+ * Sets the given bit to true.
+ */
+ public function set(int $x, int $y) : void
+ {
+ $offset = $y * $this->rowSize + ($x >> 5);
+ $this->bits[$offset] = $this->bits[$offset] | (1 << ($x & 0x1f));
+ }
+
+ /**
+ * Flips the given bit.
+ */
+ public function flip(int $x, int $y) : void
+ {
+ $offset = $y * $this->rowSize + ($x >> 5);
+ $this->bits[$offset] = $this->bits[$offset] ^ (1 << ($x & 0x1f));
+ }
+
+ /**
+ * Clears all bits (set to false).
+ */
+ public function clear() : void
+ {
+ $max = count($this->bits);
+
+ for ($i = 0; $i < $max; ++$i) {
+ $this->bits[$i] = 0;
+ }
+ }
+
+ /**
+ * Sets a square region of the bit matrix to true.
+ *
+ * @throws InvalidArgumentException if left or top are negative
+ * @throws InvalidArgumentException if width or height are smaller than 1
+ * @throws InvalidArgumentException if region does not fit into the matix
+ */
+ public function setRegion(int $left, int $top, int $width, int $height) : void
+ {
+ if ($top < 0 || $left < 0) {
+ throw new InvalidArgumentException('Left and top must be non-negative');
+ }
+
+ if ($height < 1 || $width < 1) {
+ throw new InvalidArgumentException('Width and height must be at least 1');
+ }
+
+ $right = $left + $width;
+ $bottom = $top + $height;
+
+ if ($bottom > $this->height || $right > $this->width) {
+ throw new InvalidArgumentException('The region must fit inside the matrix');
+ }
+
+ for ($y = $top; $y < $bottom; ++$y) {
+ $offset = $y * $this->rowSize;
+
+ for ($x = $left; $x < $right; ++$x) {
+ $index = $offset + ($x >> 5);
+ $this->bits[$index] = $this->bits[$index] | (1 << ($x & 0x1f));
+ }
+ }
+ }
+
+ /**
+ * A fast method to retrieve one row of data from the matrix as a BitArray.
+ */
+ public function getRow(int $y, BitArray $row = null) : BitArray
+ {
+ if (null === $row || $row->getSize() < $this->width) {
+ $row = new BitArray($this->width);
+ }
+
+ $offset = $y * $this->rowSize;
+
+ for ($x = 0; $x < $this->rowSize; ++$x) {
+ $row->setBulk($x << 5, $this->bits[$offset + $x]);
+ }
+
+ return $row;
+ }
+
+ /**
+ * Sets a row of data from a BitArray.
+ */
+ public function setRow(int $y, BitArray $row) : void
+ {
+ $bits = $row->getBitArray();
+
+ for ($i = 0; $i < $this->rowSize; ++$i) {
+ $this->bits[$y * $this->rowSize + $i] = $bits[$i];
+ }
+ }
+
+ /**
+ * This is useful in detecting the enclosing rectangle of a 'pure' barcode.
+ *
+ * @return int[]|null
+ */
+ public function getEnclosingRectangle() : ?array
+ {
+ $left = $this->width;
+ $top = $this->height;
+ $right = -1;
+ $bottom = -1;
+
+ for ($y = 0; $y < $this->height; ++$y) {
+ for ($x32 = 0; $x32 < $this->rowSize; ++$x32) {
+ $bits = $this->bits[$y * $this->rowSize + $x32];
+
+ if (0 !== $bits) {
+ if ($y < $top) {
+ $top = $y;
+ }
+
+ if ($y > $bottom) {
+ $bottom = $y;
+ }
+
+ if ($x32 * 32 < $left) {
+ $bit = 0;
+
+ while (($bits << (31 - $bit)) === 0) {
+ $bit++;
+ }
+
+ if (($x32 * 32 + $bit) < $left) {
+ $left = $x32 * 32 + $bit;
+ }
+ }
+ }
+
+ if ($x32 * 32 + 31 > $right) {
+ $bit = 31;
+
+ while (0 === BitUtils::unsignedRightShift($bits, $bit)) {
+ --$bit;
+ }
+
+ if (($x32 * 32 + $bit) > $right) {
+ $right = $x32 * 32 + $bit;
+ }
+ }
+ }
+ }
+
+ $width = $right - $left;
+ $height = $bottom - $top;
+
+ if ($width < 0 || $height < 0) {
+ return null;
+ }
+
+ return [$left, $top, $width, $height];
+ }
+
+ /**
+ * Gets the most top left set bit.
+ *
+ * This is useful in detecting a corner of a 'pure' barcode.
+ *
+ * @return int[]|null
+ */
+ public function getTopLeftOnBit() : ?array
+ {
+ $bitsOffset = 0;
+
+ while ($bitsOffset < count($this->bits) && 0 === $this->bits[$bitsOffset]) {
+ ++$bitsOffset;
+ }
+
+ if (count($this->bits) === $bitsOffset) {
+ return null;
+ }
+
+ $x = intdiv($bitsOffset, $this->rowSize);
+ $y = ($bitsOffset % $this->rowSize) << 5;
+
+ $bits = $this->bits[$bitsOffset];
+ $bit = 0;
+
+ while (0 === ($bits << (31 - $bit))) {
+ ++$bit;
+ }
+
+ $x += $bit;
+
+ return [$x, $y];
+ }
+
+ /**
+ * Gets the most bottom right set bit.
+ *
+ * This is useful in detecting a corner of a 'pure' barcode.
+ *
+ * @return int[]|null
+ */
+ public function getBottomRightOnBit() : ?array
+ {
+ $bitsOffset = count($this->bits) - 1;
+
+ while ($bitsOffset >= 0 && 0 === $this->bits[$bitsOffset]) {
+ --$bitsOffset;
+ }
+
+ if ($bitsOffset < 0) {
+ return null;
+ }
+
+ $x = intdiv($bitsOffset, $this->rowSize);
+ $y = ($bitsOffset % $this->rowSize) << 5;
+
+ $bits = $this->bits[$bitsOffset];
+ $bit = 0;
+
+ while (0 === BitUtils::unsignedRightShift($bits, $bit)) {
+ --$bit;
+ }
+
+ $x += $bit;
+
+ return [$x, $y];
+ }
+
+ /**
+ * Gets the width of the matrix,
+ */
+ public function getWidth() : int
+ {
+ return $this->width;
+ }
+
+ /**
+ * Gets the height of the matrix.
+ */
+ public function getHeight() : int
+ {
+ return $this->height;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitUtils.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitUtils.php
new file mode 100644
index 0000000..0c575b4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/BitUtils.php
@@ -0,0 +1,41 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+/**
+ * General bit utilities.
+ *
+ * All utility methods are based on 32-bit integers and also work on 64-bit
+ * systems.
+ */
+final class BitUtils
+{
+ private function __construct()
+ {
+ }
+
+ /**
+ * Performs an unsigned right shift.
+ *
+ * This is the same as the unsigned right shift operator ">>>" in other
+ * languages.
+ */
+ public static function unsignedRightShift(int $a, int $b) : int
+ {
+ return (
+ $a >= 0
+ ? $a >> $b
+ : (($a & 0x7fffffff) >> $b) | (0x40000000 >> ($b - 1))
+ );
+ }
+
+ /**
+ * Gets the number of trailing zeros.
+ */
+ public static function numberOfTrailingZeros(int $i) : int
+ {
+ $lastPos = strrpos(str_pad(decbin($i), 32, '0', STR_PAD_LEFT), '1');
+ return $lastPos === false ? 32 : 31 - $lastPos;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/CharacterSetEci.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/CharacterSetEci.php
new file mode 100644
index 0000000..9049ccb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/CharacterSetEci.php
@@ -0,0 +1,183 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+use BaconQrCode\Exception\InvalidArgumentException;
+use DASPRiD\Enum\AbstractEnum;
+
+/**
+ * Encapsulates a Character Set ECI, according to "Extended Channel Interpretations" 5.3.1.1 of ISO 18004.
+ *
+ * @method static self CP437()
+ * @method static self ISO8859_1()
+ * @method static self ISO8859_2()
+ * @method static self ISO8859_3()
+ * @method static self ISO8859_4()
+ * @method static self ISO8859_5()
+ * @method static self ISO8859_6()
+ * @method static self ISO8859_7()
+ * @method static self ISO8859_8()
+ * @method static self ISO8859_9()
+ * @method static self ISO8859_10()
+ * @method static self ISO8859_11()
+ * @method static self ISO8859_12()
+ * @method static self ISO8859_13()
+ * @method static self ISO8859_14()
+ * @method static self ISO8859_15()
+ * @method static self ISO8859_16()
+ * @method static self SJIS()
+ * @method static self CP1250()
+ * @method static self CP1251()
+ * @method static self CP1252()
+ * @method static self CP1256()
+ * @method static self UNICODE_BIG_UNMARKED()
+ * @method static self UTF8()
+ * @method static self ASCII()
+ * @method static self BIG5()
+ * @method static self GB18030()
+ * @method static self EUC_KR()
+ */
+final class CharacterSetEci extends AbstractEnum
+{
+ protected const CP437 = [[0, 2]];
+ protected const ISO8859_1 = [[1, 3], 'ISO-8859-1'];
+ protected const ISO8859_2 = [[4], 'ISO-8859-2'];
+ protected const ISO8859_3 = [[5], 'ISO-8859-3'];
+ protected const ISO8859_4 = [[6], 'ISO-8859-4'];
+ protected const ISO8859_5 = [[7], 'ISO-8859-5'];
+ protected const ISO8859_6 = [[8], 'ISO-8859-6'];
+ protected const ISO8859_7 = [[9], 'ISO-8859-7'];
+ protected const ISO8859_8 = [[10], 'ISO-8859-8'];
+ protected const ISO8859_9 = [[11], 'ISO-8859-9'];
+ protected const ISO8859_10 = [[12], 'ISO-8859-10'];
+ protected const ISO8859_11 = [[13], 'ISO-8859-11'];
+ protected const ISO8859_12 = [[14], 'ISO-8859-12'];
+ protected const ISO8859_13 = [[15], 'ISO-8859-13'];
+ protected const ISO8859_14 = [[16], 'ISO-8859-14'];
+ protected const ISO8859_15 = [[17], 'ISO-8859-15'];
+ protected const ISO8859_16 = [[18], 'ISO-8859-16'];
+ protected const SJIS = [[20], 'Shift_JIS'];
+ protected const CP1250 = [[21], 'windows-1250'];
+ protected const CP1251 = [[22], 'windows-1251'];
+ protected const CP1252 = [[23], 'windows-1252'];
+ protected const CP1256 = [[24], 'windows-1256'];
+ protected const UNICODE_BIG_UNMARKED = [[25], 'UTF-16BE', 'UnicodeBig'];
+ protected const UTF8 = [[26], 'UTF-8'];
+ protected const ASCII = [[27, 170], 'US-ASCII'];
+ protected const BIG5 = [[28]];
+ protected const GB18030 = [[29], 'GB2312', 'EUC_CN', 'GBK'];
+ protected const EUC_KR = [[30], 'EUC-KR'];
+
+ /**
+ * @var int[]
+ */
+ private $values;
+
+ /**
+ * @var string[]
+ */
+ private $otherEncodingNames;
+
+ /**
+ * @var array<int, self>|null
+ */
+ private static $valueToEci;
+
+ /**
+ * @var array<string, self>|null
+ */
+ private static $nameToEci;
+
+ /**
+ * @param int[] $values
+ */
+ public function __construct(array $values, string ...$otherEncodingNames)
+ {
+ $this->values = $values;
+ $this->otherEncodingNames = $otherEncodingNames;
+ }
+
+ /**
+ * Returns the primary value.
+ */
+ public function getValue() : int
+ {
+ return $this->values[0];
+ }
+
+ /**
+ * Gets character set ECI by value.
+ *
+ * Returns the representing ECI of a given value, or null if it is legal but unsupported.
+ *
+ * @throws InvalidArgumentException if value is not between 0 and 900
+ */
+ public static function getCharacterSetEciByValue(int $value) : ?self
+ {
+ if ($value < 0 || $value >= 900) {
+ throw new InvalidArgumentException('Value must be between 0 and 900');
+ }
+
+ $valueToEci = self::valueToEci();
+
+ if (! array_key_exists($value, $valueToEci)) {
+ return null;
+ }
+
+ return $valueToEci[$value];
+ }
+
+ /**
+ * Returns character set ECI by name.
+ *
+ * Returns the representing ECI of a given name, or null if it is legal but unsupported
+ */
+ public static function getCharacterSetEciByName(string $name) : ?self
+ {
+ $nameToEci = self::nameToEci();
+ $name = strtolower($name);
+
+ if (! array_key_exists($name, $nameToEci)) {
+ return null;
+ }
+
+ return $nameToEci[$name];
+ }
+
+ private static function valueToEci() : array
+ {
+ if (null !== self::$valueToEci) {
+ return self::$valueToEci;
+ }
+
+ self::$valueToEci = [];
+
+ foreach (self::values() as $eci) {
+ foreach ($eci->values as $value) {
+ self::$valueToEci[$value] = $eci;
+ }
+ }
+
+ return self::$valueToEci;
+ }
+
+ private static function nameToEci() : array
+ {
+ if (null !== self::$nameToEci) {
+ return self::$nameToEci;
+ }
+
+ self::$nameToEci = [];
+
+ foreach (self::values() as $eci) {
+ self::$nameToEci[strtolower($eci->name())] = $eci;
+
+ foreach ($eci->otherEncodingNames as $name) {
+ self::$nameToEci[strtolower($name)] = $eci;
+ }
+ }
+
+ return self::$nameToEci;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/EcBlock.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/EcBlock.php
new file mode 100644
index 0000000..a9a1d07
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/EcBlock.php
@@ -0,0 +1,49 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+/**
+ * Encapsulates the parameters for one error-correction block in one symbol version.
+ *
+ * This includes the number of data codewords, and the number of times a block with these parameters is used
+ * consecutively in the QR code version's format.
+ */
+final class EcBlock
+{
+ /**
+ * How many times the block is used.
+ *
+ * @var int
+ */
+ private $count;
+
+ /**
+ * Number of data codewords.
+ *
+ * @var int
+ */
+ private $dataCodewords;
+
+ public function __construct(int $count, int $dataCodewords)
+ {
+ $this->count = $count;
+ $this->dataCodewords = $dataCodewords;
+ }
+
+ /**
+ * Returns how many times the block is used.
+ */
+ public function getCount() : int
+ {
+ return $this->count;
+ }
+
+ /**
+ * Returns the number of data codewords.
+ */
+ public function getDataCodewords() : int
+ {
+ return $this->dataCodewords;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/EcBlocks.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/EcBlocks.php
new file mode 100644
index 0000000..172b5f2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/EcBlocks.php
@@ -0,0 +1,74 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+/**
+ * Encapsulates a set of error-correction blocks in one symbol version.
+ *
+ * Most versions will use blocks of differing sizes within one version, so, this encapsulates the parameters for each
+ * set of blocks. It also holds the number of error-correction codewords per block since it will be the same across all
+ * blocks within one version.
+ */
+final class EcBlocks
+{
+ /**
+ * Number of EC codewords per block.
+ *
+ * @var int
+ */
+ private $ecCodewordsPerBlock;
+
+ /**
+ * List of EC blocks.
+ *
+ * @var EcBlock[]
+ */
+ private $ecBlocks;
+
+ public function __construct(int $ecCodewordsPerBlock, EcBlock ...$ecBlocks)
+ {
+ $this->ecCodewordsPerBlock = $ecCodewordsPerBlock;
+ $this->ecBlocks = $ecBlocks;
+ }
+
+ /**
+ * Returns the number of EC codewords per block.
+ */
+ public function getEcCodewordsPerBlock() : int
+ {
+ return $this->ecCodewordsPerBlock;
+ }
+
+ /**
+ * Returns the total number of EC block appearances.
+ */
+ public function getNumBlocks() : int
+ {
+ $total = 0;
+
+ foreach ($this->ecBlocks as $ecBlock) {
+ $total += $ecBlock->getCount();
+ }
+
+ return $total;
+ }
+
+ /**
+ * Returns the total count of EC codewords.
+ */
+ public function getTotalEcCodewords() : int
+ {
+ return $this->ecCodewordsPerBlock * $this->getNumBlocks();
+ }
+
+ /**
+ * Returns the EC blocks included in this collection.
+ *
+ * @return EcBlock[]
+ */
+ public function getEcBlocks() : array
+ {
+ return $this->ecBlocks;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/ErrorCorrectionLevel.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/ErrorCorrectionLevel.php
new file mode 100644
index 0000000..9bbf440
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/ErrorCorrectionLevel.php
@@ -0,0 +1,63 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+use BaconQrCode\Exception\OutOfBoundsException;
+use DASPRiD\Enum\AbstractEnum;
+
+/**
+ * Enum representing the four error correction levels.
+ *
+ * @method static self L() ~7% correction
+ * @method static self M() ~15% correction
+ * @method static self Q() ~25% correction
+ * @method static self H() ~30% correction
+ */
+final class ErrorCorrectionLevel extends AbstractEnum
+{
+ protected const L = [0x01];
+ protected const M = [0x00];
+ protected const Q = [0x03];
+ protected const H = [0x02];
+
+ /**
+ * @var int
+ */
+ private $bits;
+
+ protected function __construct(int $bits)
+ {
+ $this->bits = $bits;
+ }
+
+ /**
+ * @throws OutOfBoundsException if number of bits is invalid
+ */
+ public static function forBits(int $bits) : self
+ {
+ switch ($bits) {
+ case 0:
+ return self::M();
+
+ case 1:
+ return self::L();
+
+ case 2:
+ return self::H();
+
+ case 3:
+ return self::Q();
+ }
+
+ throw new OutOfBoundsException('Invalid number of bits');
+ }
+
+ /**
+ * Returns the two bits used to encode this error correction level.
+ */
+ public function getBits() : int
+ {
+ return $this->bits;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/FormatInformation.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/FormatInformation.php
new file mode 100644
index 0000000..38295fc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/FormatInformation.php
@@ -0,0 +1,203 @@
+<?php
+/**
+ * BaconQrCode
+ *
+ * @link http://github.com/Bacon/BaconQrCode For the canonical source repository
+ * @copyright 2013 Ben 'DASPRiD' Scholzen
+ * @license http://opensource.org/licenses/BSD-2-Clause Simplified BSD License
+ */
+
+namespace BaconQrCode\Common;
+
+/**
+ * Encapsulates a QR Code's format information, including the data mask used and error correction level.
+ */
+class FormatInformation
+{
+ /**
+ * Mask for format information.
+ */
+ private const FORMAT_INFO_MASK_QR = 0x5412;
+
+ /**
+ * Lookup table for decoding format information.
+ *
+ * See ISO 18004:2006, Annex C, Table C.1
+ */
+ private const FORMAT_INFO_DECODE_LOOKUP = [
+ [0x5412, 0x00],
+ [0x5125, 0x01],
+ [0x5e7c, 0x02],
+ [0x5b4b, 0x03],
+ [0x45f9, 0x04],
+ [0x40ce, 0x05],
+ [0x4f97, 0x06],
+ [0x4aa0, 0x07],
+ [0x77c4, 0x08],
+ [0x72f3, 0x09],
+ [0x7daa, 0x0a],
+ [0x789d, 0x0b],
+ [0x662f, 0x0c],
+ [0x6318, 0x0d],
+ [0x6c41, 0x0e],
+ [0x6976, 0x0f],
+ [0x1689, 0x10],
+ [0x13be, 0x11],
+ [0x1ce7, 0x12],
+ [0x19d0, 0x13],
+ [0x0762, 0x14],
+ [0x0255, 0x15],
+ [0x0d0c, 0x16],
+ [0x083b, 0x17],
+ [0x355f, 0x18],
+ [0x3068, 0x19],
+ [0x3f31, 0x1a],
+ [0x3a06, 0x1b],
+ [0x24b4, 0x1c],
+ [0x2183, 0x1d],
+ [0x2eda, 0x1e],
+ [0x2bed, 0x1f],
+ ];
+
+ /**
+ * Offset i holds the number of 1 bits in the binary representation of i.
+ *
+ * @var int[]
+ */
+ private const BITS_SET_IN_HALF_BYTE = [0, 1, 1, 2, 1, 2, 2, 3, 1, 2, 2, 3, 2, 3, 3, 4];
+
+ /**
+ * Error correction level.
+ *
+ * @var ErrorCorrectionLevel
+ */
+ private $ecLevel;
+
+ /**
+ * Data mask.
+ *
+ * @var int
+ */
+ private $dataMask;
+
+ protected function __construct(int $formatInfo)
+ {
+ $this->ecLevel = ErrorCorrectionLevel::forBits(($formatInfo >> 3) & 0x3);
+ $this->dataMask = $formatInfo & 0x7;
+ }
+
+ /**
+ * Checks how many bits are different between two integers.
+ */
+ public static function numBitsDiffering(int $a, int $b) : int
+ {
+ $a ^= $b;
+
+ return (
+ self::BITS_SET_IN_HALF_BYTE[$a & 0xf]
+ + self::BITS_SET_IN_HALF_BYTE[(BitUtils::unsignedRightShift($a, 4) & 0xf)]
+ + self::BITS_SET_IN_HALF_BYTE[(BitUtils::unsignedRightShift($a, 8) & 0xf)]
+ + self::BITS_SET_IN_HALF_BYTE[(BitUtils::unsignedRightShift($a, 12) & 0xf)]
+ + self::BITS_SET_IN_HALF_BYTE[(BitUtils::unsignedRightShift($a, 16) & 0xf)]
+ + self::BITS_SET_IN_HALF_BYTE[(BitUtils::unsignedRightShift($a, 20) & 0xf)]
+ + self::BITS_SET_IN_HALF_BYTE[(BitUtils::unsignedRightShift($a, 24) & 0xf)]
+ + self::BITS_SET_IN_HALF_BYTE[(BitUtils::unsignedRightShift($a, 28) & 0xf)]
+ );
+ }
+
+ /**
+ * Decodes format information.
+ */
+ public static function decodeFormatInformation(int $maskedFormatInfo1, int $maskedFormatInfo2) : ?self
+ {
+ $formatInfo = self::doDecodeFormatInformation($maskedFormatInfo1, $maskedFormatInfo2);
+
+ if (null !== $formatInfo) {
+ return $formatInfo;
+ }
+
+ // Should return null, but, some QR codes apparently do not mask this info. Try again by actually masking the
+ // pattern first.
+ return self::doDecodeFormatInformation(
+ $maskedFormatInfo1 ^ self::FORMAT_INFO_MASK_QR,
+ $maskedFormatInfo2 ^ self::FORMAT_INFO_MASK_QR
+ );
+ }
+
+ /**
+ * Internal method for decoding format information.
+ */
+ private static function doDecodeFormatInformation(int $maskedFormatInfo1, int $maskedFormatInfo2) : ?self
+ {
+ $bestDifference = PHP_INT_MAX;
+ $bestFormatInfo = 0;
+
+ foreach (self::FORMAT_INFO_DECODE_LOOKUP as $decodeInfo) {
+ $targetInfo = $decodeInfo[0];
+
+ if ($targetInfo === $maskedFormatInfo1 || $targetInfo === $maskedFormatInfo2) {
+ // Found an exact match
+ return new self($decodeInfo[1]);
+ }
+
+ $bitsDifference = self::numBitsDiffering($maskedFormatInfo1, $targetInfo);
+
+ if ($bitsDifference < $bestDifference) {
+ $bestFormatInfo = $decodeInfo[1];
+ $bestDifference = $bitsDifference;
+ }
+
+ if ($maskedFormatInfo1 !== $maskedFormatInfo2) {
+ // Also try the other option
+ $bitsDifference = self::numBitsDiffering($maskedFormatInfo2, $targetInfo);
+
+ if ($bitsDifference < $bestDifference) {
+ $bestFormatInfo = $decodeInfo[1];
+ $bestDifference = $bitsDifference;
+ }
+ }
+ }
+
+ // Hamming distance of the 32 masked codes is 7, by construction, so <= 3 bits differing means we found a match.
+ if ($bestDifference <= 3) {
+ return new self($bestFormatInfo);
+ }
+
+ return null;
+ }
+
+ /**
+ * Returns the error correction level.
+ */
+ public function getErrorCorrectionLevel() : ErrorCorrectionLevel
+ {
+ return $this->ecLevel;
+ }
+
+ /**
+ * Returns the data mask.
+ */
+ public function getDataMask() : int
+ {
+ return $this->dataMask;
+ }
+
+ /**
+ * Hashes the code of the EC level.
+ */
+ public function hashCode() : int
+ {
+ return ($this->ecLevel->getBits() << 3) | $this->dataMask;
+ }
+
+ /**
+ * Verifies if this instance equals another one.
+ */
+ public function equals(self $other) : bool
+ {
+ return (
+ $this->ecLevel === $other->ecLevel
+ && $this->dataMask === $other->dataMask
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/Mode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/Mode.php
new file mode 100644
index 0000000..af5a113
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/Mode.php
@@ -0,0 +1,79 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+use DASPRiD\Enum\AbstractEnum;
+
+/**
+ * Enum representing various modes in which data can be encoded to bits.
+ *
+ * @method static self TERMINATOR()
+ * @method static self NUMERIC()
+ * @method static self ALPHANUMERIC()
+ * @method static self STRUCTURED_APPEND()
+ * @method static self BYTE()
+ * @method static self ECI()
+ * @method static self KANJI()
+ * @method static self FNC1_FIRST_POSITION()
+ * @method static self FNC1_SECOND_POSITION()
+ * @method static self HANZI()
+ */
+final class Mode extends AbstractEnum
+{
+ protected const TERMINATOR = [[0, 0, 0], 0x00];
+ protected const NUMERIC = [[10, 12, 14], 0x01];
+ protected const ALPHANUMERIC = [[9, 11, 13], 0x02];
+ protected const STRUCTURED_APPEND = [[0, 0, 0], 0x03];
+ protected const BYTE = [[8, 16, 16], 0x04];
+ protected const ECI = [[0, 0, 0], 0x07];
+ protected const KANJI = [[8, 10, 12], 0x08];
+ protected const FNC1_FIRST_POSITION = [[0, 0, 0], 0x05];
+ protected const FNC1_SECOND_POSITION = [[0, 0, 0], 0x09];
+ protected const HANZI = [[8, 10, 12], 0x0d];
+
+ /**
+ * @var int[]
+ */
+ private $characterCountBitsForVersions;
+
+ /**
+ * @var int
+ */
+ private $bits;
+
+ /**
+ * @param int[] $characterCountBitsForVersions
+ */
+ protected function __construct(array $characterCountBitsForVersions, int $bits)
+ {
+ $this->characterCountBitsForVersions = $characterCountBitsForVersions;
+ $this->bits = $bits;
+ }
+
+ /**
+ * Returns the number of bits used in a specific QR code version.
+ */
+ public function getCharacterCountBits(Version $version) : int
+ {
+ $number = $version->getVersionNumber();
+
+ if ($number <= 9) {
+ $offset = 0;
+ } elseif ($number <= 26) {
+ $offset = 1;
+ } else {
+ $offset = 2;
+ }
+
+ return $this->characterCountBitsForVersions[$offset];
+ }
+
+ /**
+ * Returns the four bits used to encode this mode.
+ */
+ public function getBits() : int
+ {
+ return $this->bits;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/ReedSolomonCodec.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/ReedSolomonCodec.php
new file mode 100644
index 0000000..a5aad0b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/ReedSolomonCodec.php
@@ -0,0 +1,468 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+use BaconQrCode\Exception\InvalidArgumentException;
+use BaconQrCode\Exception\RuntimeException;
+use SplFixedArray;
+
+/**
+ * Reed-Solomon codec for 8-bit characters.
+ *
+ * Based on libfec by Phil Karn, KA9Q.
+ */
+final class ReedSolomonCodec
+{
+ /**
+ * Symbol size in bits.
+ *
+ * @var int
+ */
+ private $symbolSize;
+
+ /**
+ * Block size in symbols.
+ *
+ * @var int
+ */
+ private $blockSize;
+
+ /**
+ * First root of RS code generator polynomial, index form.
+ *
+ * @var int
+ */
+ private $firstRoot;
+
+ /**
+ * Primitive element to generate polynomial roots, index form.
+ *
+ * @var int
+ */
+ private $primitive;
+
+ /**
+ * Prim-th root of 1, index form.
+ *
+ * @var int
+ */
+ private $iPrimitive;
+
+ /**
+ * RS code generator polynomial degree (number of roots).
+ *
+ * @var int
+ */
+ private $numRoots;
+
+ /**
+ * Padding bytes at front of shortened block.
+ *
+ * @var int
+ */
+ private $padding;
+
+ /**
+ * Log lookup table.
+ *
+ * @var SplFixedArray
+ */
+ private $alphaTo;
+
+ /**
+ * Anti-Log lookup table.
+ *
+ * @var SplFixedArray
+ */
+ private $indexOf;
+
+ /**
+ * Generator polynomial.
+ *
+ * @var SplFixedArray
+ */
+ private $generatorPoly;
+
+ /**
+ * @throws InvalidArgumentException if symbol size ist not between 0 and 8
+ * @throws InvalidArgumentException if first root is invalid
+ * @throws InvalidArgumentException if num roots is invalid
+ * @throws InvalidArgumentException if padding is invalid
+ * @throws RuntimeException if field generator polynomial is not primitive
+ */
+ public function __construct(
+ int $symbolSize,
+ int $gfPoly,
+ int $firstRoot,
+ int $primitive,
+ int $numRoots,
+ int $padding
+ ) {
+ if ($symbolSize < 0 || $symbolSize > 8) {
+ throw new InvalidArgumentException('Symbol size must be between 0 and 8');
+ }
+
+ if ($firstRoot < 0 || $firstRoot >= (1 << $symbolSize)) {
+ throw new InvalidArgumentException('First root must be between 0 and ' . (1 << $symbolSize));
+ }
+
+ if ($numRoots < 0 || $numRoots >= (1 << $symbolSize)) {
+ throw new InvalidArgumentException('Num roots must be between 0 and ' . (1 << $symbolSize));
+ }
+
+ if ($padding < 0 || $padding >= ((1 << $symbolSize) - 1 - $numRoots)) {
+ throw new InvalidArgumentException(
+ 'Padding must be between 0 and ' . ((1 << $symbolSize) - 1 - $numRoots)
+ );
+ }
+
+ $this->symbolSize = $symbolSize;
+ $this->blockSize = (1 << $symbolSize) - 1;
+ $this->padding = $padding;
+ $this->alphaTo = SplFixedArray::fromArray(array_fill(0, $this->blockSize + 1, 0), false);
+ $this->indexOf = SplFixedArray::fromArray(array_fill(0, $this->blockSize + 1, 0), false);
+
+ // Generate galous field lookup table
+ $this->indexOf[0] = $this->blockSize;
+ $this->alphaTo[$this->blockSize] = 0;
+
+ $sr = 1;
+
+ for ($i = 0; $i < $this->blockSize; ++$i) {
+ $this->indexOf[$sr] = $i;
+ $this->alphaTo[$i] = $sr;
+
+ $sr <<= 1;
+
+ if ($sr & (1 << $symbolSize)) {
+ $sr ^= $gfPoly;
+ }
+
+ $sr &= $this->blockSize;
+ }
+
+ if (1 !== $sr) {
+ throw new RuntimeException('Field generator polynomial is not primitive');
+ }
+
+ // Form RS code generator polynomial from its roots
+ $this->generatorPoly = SplFixedArray::fromArray(array_fill(0, $numRoots + 1, 0), false);
+ $this->firstRoot = $firstRoot;
+ $this->primitive = $primitive;
+ $this->numRoots = $numRoots;
+
+ // Find prim-th root of 1, used in decoding
+ for ($iPrimitive = 1; ($iPrimitive % $primitive) !== 0; $iPrimitive += $this->blockSize) {
+ }
+
+ $this->iPrimitive = intdiv($iPrimitive, $primitive);
+
+ $this->generatorPoly[0] = 1;
+
+ for ($i = 0, $root = $firstRoot * $primitive; $i < $numRoots; ++$i, $root += $primitive) {
+ $this->generatorPoly[$i + 1] = 1;
+
+ for ($j = $i; $j > 0; $j--) {
+ if ($this->generatorPoly[$j] !== 0) {
+ $this->generatorPoly[$j] = $this->generatorPoly[$j - 1] ^ $this->alphaTo[
+ $this->modNn($this->indexOf[$this->generatorPoly[$j]] + $root)
+ ];
+ } else {
+ $this->generatorPoly[$j] = $this->generatorPoly[$j - 1];
+ }
+ }
+
+ $this->generatorPoly[$j] = $this->alphaTo[$this->modNn($this->indexOf[$this->generatorPoly[0]] + $root)];
+ }
+
+ // Convert generator poly to index form for quicker encoding
+ for ($i = 0; $i <= $numRoots; ++$i) {
+ $this->generatorPoly[$i] = $this->indexOf[$this->generatorPoly[$i]];
+ }
+ }
+
+ /**
+ * Encodes data and writes result back into parity array.
+ */
+ public function encode(SplFixedArray $data, SplFixedArray $parity) : void
+ {
+ for ($i = 0; $i < $this->numRoots; ++$i) {
+ $parity[$i] = 0;
+ }
+
+ $iterations = $this->blockSize - $this->numRoots - $this->padding;
+
+ for ($i = 0; $i < $iterations; ++$i) {
+ $feedback = $this->indexOf[$data[$i] ^ $parity[0]];
+
+ if ($feedback !== $this->blockSize) {
+ // Feedback term is non-zero
+ $feedback = $this->modNn($this->blockSize - $this->generatorPoly[$this->numRoots] + $feedback);
+
+ for ($j = 1; $j < $this->numRoots; ++$j) {
+ $parity[$j] = $parity[$j] ^ $this->alphaTo[
+ $this->modNn($feedback + $this->generatorPoly[$this->numRoots - $j])
+ ];
+ }
+ }
+
+ for ($j = 0; $j < $this->numRoots - 1; ++$j) {
+ $parity[$j] = $parity[$j + 1];
+ }
+
+ if ($feedback !== $this->blockSize) {
+ $parity[$this->numRoots - 1] = $this->alphaTo[$this->modNn($feedback + $this->generatorPoly[0])];
+ } else {
+ $parity[$this->numRoots - 1] = 0;
+ }
+ }
+ }
+
+ /**
+ * Decodes received data.
+ */
+ public function decode(SplFixedArray $data, SplFixedArray $erasures = null) : ?int
+ {
+ // This speeds up the initialization a bit.
+ $numRootsPlusOne = SplFixedArray::fromArray(array_fill(0, $this->numRoots + 1, 0), false);
+ $numRoots = SplFixedArray::fromArray(array_fill(0, $this->numRoots, 0), false);
+
+ $lambda = clone $numRootsPlusOne;
+ $b = clone $numRootsPlusOne;
+ $t = clone $numRootsPlusOne;
+ $omega = clone $numRootsPlusOne;
+ $root = clone $numRoots;
+ $loc = clone $numRoots;
+
+ $numErasures = (null !== $erasures ? count($erasures) : 0);
+
+ // Form the Syndromes; i.e., evaluate data(x) at roots of g(x)
+ $syndromes = SplFixedArray::fromArray(array_fill(0, $this->numRoots, $data[0]), false);
+
+ for ($i = 1; $i < $this->blockSize - $this->padding; ++$i) {
+ for ($j = 0; $j < $this->numRoots; ++$j) {
+ if ($syndromes[$j] === 0) {
+ $syndromes[$j] = $data[$i];
+ } else {
+ $syndromes[$j] = $data[$i] ^ $this->alphaTo[
+ $this->modNn($this->indexOf[$syndromes[$j]] + ($this->firstRoot + $j) * $this->primitive)
+ ];
+ }
+ }
+ }
+
+ // Convert syndromes to index form, checking for nonzero conditions
+ $syndromeError = 0;
+
+ for ($i = 0; $i < $this->numRoots; ++$i) {
+ $syndromeError |= $syndromes[$i];
+ $syndromes[$i] = $this->indexOf[$syndromes[$i]];
+ }
+
+ if (! $syndromeError) {
+ // If syndrome is zero, data[] is a codeword and there are no errors to correct, so return data[]
+ // unmodified.
+ return 0;
+ }
+
+ $lambda[0] = 1;
+
+ if ($numErasures > 0) {
+ // Init lambda to be the erasure locator polynomial
+ $lambda[1] = $this->alphaTo[$this->modNn($this->primitive * ($this->blockSize - 1 - $erasures[0]))];
+
+ for ($i = 1; $i < $numErasures; ++$i) {
+ $u = $this->modNn($this->primitive * ($this->blockSize - 1 - $erasures[$i]));
+
+ for ($j = $i + 1; $j > 0; --$j) {
+ $tmp = $this->indexOf[$lambda[$j - 1]];
+
+ if ($tmp !== $this->blockSize) {
+ $lambda[$j] = $lambda[$j] ^ $this->alphaTo[$this->modNn($u + $tmp)];
+ }
+ }
+ }
+ }
+
+ for ($i = 0; $i <= $this->numRoots; ++$i) {
+ $b[$i] = $this->indexOf[$lambda[$i]];
+ }
+
+ // Begin Berlekamp-Massey algorithm to determine error+erasure locator polynomial
+ $r = $numErasures;
+ $el = $numErasures;
+
+ while (++$r <= $this->numRoots) {
+ // Compute discrepancy at the r-th step in poly form
+ $discrepancyR = 0;
+
+ for ($i = 0; $i < $r; ++$i) {
+ if ($lambda[$i] !== 0 && $syndromes[$r - $i - 1] !== $this->blockSize) {
+ $discrepancyR ^= $this->alphaTo[
+ $this->modNn($this->indexOf[$lambda[$i]] + $syndromes[$r - $i - 1])
+ ];
+ }
+ }
+
+ $discrepancyR = $this->indexOf[$discrepancyR];
+
+ if ($discrepancyR === $this->blockSize) {
+ $tmp = $b->toArray();
+ array_unshift($tmp, $this->blockSize);
+ array_pop($tmp);
+ $b = SplFixedArray::fromArray($tmp, false);
+ continue;
+ }
+
+ $t[0] = $lambda[0];
+
+ for ($i = 0; $i < $this->numRoots; ++$i) {
+ if ($b[$i] !== $this->blockSize) {
+ $t[$i + 1] = $lambda[$i + 1] ^ $this->alphaTo[$this->modNn($discrepancyR + $b[$i])];
+ } else {
+ $t[$i + 1] = $lambda[$i + 1];
+ }
+ }
+
+ if (2 * $el <= $r + $numErasures - 1) {
+ $el = $r + $numErasures - $el;
+
+ for ($i = 0; $i <= $this->numRoots; ++$i) {
+ $b[$i] = (
+ $lambda[$i] === 0
+ ? $this->blockSize
+ : $this->modNn($this->indexOf[$lambda[$i]] - $discrepancyR + $this->blockSize)
+ );
+ }
+ } else {
+ $tmp = $b->toArray();
+ array_unshift($tmp, $this->blockSize);
+ array_pop($tmp);
+ $b = SplFixedArray::fromArray($tmp, false);
+ }
+
+ $lambda = clone $t;
+ }
+
+ // Convert lambda to index form and compute deg(lambda(x))
+ $degLambda = 0;
+
+ for ($i = 0; $i <= $this->numRoots; ++$i) {
+ $lambda[$i] = $this->indexOf[$lambda[$i]];
+
+ if ($lambda[$i] !== $this->blockSize) {
+ $degLambda = $i;
+ }
+ }
+
+ // Find roots of the error+erasure locator polynomial by Chien search.
+ $reg = clone $lambda;
+ $reg[0] = 0;
+ $count = 0;
+ $i = 1;
+
+ for ($k = $this->iPrimitive - 1; $i <= $this->blockSize; ++$i, $k = $this->modNn($k + $this->iPrimitive)) {
+ $q = 1;
+
+ for ($j = $degLambda; $j > 0; $j--) {
+ if ($reg[$j] !== $this->blockSize) {
+ $reg[$j] = $this->modNn($reg[$j] + $j);
+ $q ^= $this->alphaTo[$reg[$j]];
+ }
+ }
+
+ if ($q !== 0) {
+ // Not a root
+ continue;
+ }
+
+ // Store root (index-form) and error location number
+ $root[$count] = $i;
+ $loc[$count] = $k;
+
+ if (++$count === $degLambda) {
+ break;
+ }
+ }
+
+ if ($degLambda !== $count) {
+ // deg(lambda) unequal to number of roots: uncorrectable error detected
+ return null;
+ }
+
+ // Compute err+eras evaluate poly omega(x) = s(x)*lambda(x) (modulo x**numRoots). In index form. Also find
+ // deg(omega).
+ $degOmega = $degLambda - 1;
+
+ for ($i = 0; $i <= $degOmega; ++$i) {
+ $tmp = 0;
+
+ for ($j = $i; $j >= 0; --$j) {
+ if ($syndromes[$i - $j] !== $this->blockSize && $lambda[$j] !== $this->blockSize) {
+ $tmp ^= $this->alphaTo[$this->modNn($syndromes[$i - $j] + $lambda[$j])];
+ }
+ }
+
+ $omega[$i] = $this->indexOf[$tmp];
+ }
+
+ // Compute error values in poly-form. num1 = omega(inv(X(l))), num2 = inv(X(l))**(firstRoot-1) and
+ // den = lambda_pr(inv(X(l))) all in poly form.
+ for ($j = $count - 1; $j >= 0; --$j) {
+ $num1 = 0;
+
+ for ($i = $degOmega; $i >= 0; $i--) {
+ if ($omega[$i] !== $this->blockSize) {
+ $num1 ^= $this->alphaTo[$this->modNn($omega[$i] + $i * $root[$j])];
+ }
+ }
+
+ $num2 = $this->alphaTo[$this->modNn($root[$j] * ($this->firstRoot - 1) + $this->blockSize)];
+ $den = 0;
+
+ // lambda[i+1] for i even is the formal derivativelambda_pr of lambda[i]
+ for ($i = min($degLambda, $this->numRoots - 1) & ~1; $i >= 0; $i -= 2) {
+ if ($lambda[$i + 1] !== $this->blockSize) {
+ $den ^= $this->alphaTo[$this->modNn($lambda[$i + 1] + $i * $root[$j])];
+ }
+ }
+
+ // Apply error to data
+ if ($num1 !== 0 && $loc[$j] >= $this->padding) {
+ $data[$loc[$j] - $this->padding] = $data[$loc[$j] - $this->padding] ^ (
+ $this->alphaTo[
+ $this->modNn(
+ $this->indexOf[$num1] + $this->indexOf[$num2] + $this->blockSize - $this->indexOf[$den]
+ )
+ ]
+ );
+ }
+ }
+
+ if (null !== $erasures) {
+ if (count($erasures) < $count) {
+ $erasures->setSize($count);
+ }
+
+ for ($i = 0; $i < $count; $i++) {
+ $erasures[$i] = $loc[$i];
+ }
+ }
+
+ return $count;
+ }
+
+ /**
+ * Computes $x % GF_SIZE, where GF_SIZE is 2**GF_BITS - 1, without a slow divide.
+ */
+ private function modNn(int $x) : int
+ {
+ while ($x >= $this->blockSize) {
+ $x -= $this->blockSize;
+ $x = ($x >> $this->symbolSize) + ($x & $this->blockSize);
+ }
+
+ return $x;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/Version.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/Version.php
new file mode 100644
index 0000000..917d048
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Common/Version.php
@@ -0,0 +1,596 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Common;
+
+use BaconQrCode\Exception\InvalidArgumentException;
+use SplFixedArray;
+
+/**
+ * Version representation.
+ */
+final class Version
+{
+ private const VERSION_DECODE_INFO = [
+ 0x07c94,
+ 0x085bc,
+ 0x09a99,
+ 0x0a4d3,
+ 0x0bbf6,
+ 0x0c762,
+ 0x0d847,
+ 0x0e60d,
+ 0x0f928,
+ 0x10b78,
+ 0x1145d,
+ 0x12a17,
+ 0x13532,
+ 0x149a6,
+ 0x15683,
+ 0x168c9,
+ 0x177ec,
+ 0x18ec4,
+ 0x191e1,
+ 0x1afab,
+ 0x1b08e,
+ 0x1cc1a,
+ 0x1d33f,
+ 0x1ed75,
+ 0x1f250,
+ 0x209d5,
+ 0x216f0,
+ 0x228ba,
+ 0x2379f,
+ 0x24b0b,
+ 0x2542e,
+ 0x26a64,
+ 0x27541,
+ 0x28c69,
+ ];
+
+ /**
+ * Version number of this version.
+ *
+ * @var int
+ */
+ private $versionNumber;
+
+ /**
+ * Alignment pattern centers.
+ *
+ * @var SplFixedArray
+ */
+ private $alignmentPatternCenters;
+
+ /**
+ * Error correction blocks.
+ *
+ * @var EcBlocks[]
+ */
+ private $ecBlocks;
+
+ /**
+ * Total number of codewords.
+ *
+ * @var int
+ */
+ private $totalCodewords;
+
+ /**
+ * Cached version instances.
+ *
+ * @var array<int, self>|null
+ */
+ private static $versions;
+
+ /**
+ * @param int[] $alignmentPatternCenters
+ */
+ private function __construct(
+ int $versionNumber,
+ array $alignmentPatternCenters,
+ EcBlocks ...$ecBlocks
+ ) {
+ $this->versionNumber = $versionNumber;
+ $this->alignmentPatternCenters = $alignmentPatternCenters;
+ $this->ecBlocks = $ecBlocks;
+
+ $totalCodewords = 0;
+ $ecCodewords = $ecBlocks[0]->getEcCodewordsPerBlock();
+
+ foreach ($ecBlocks[0]->getEcBlocks() as $ecBlock) {
+ $totalCodewords += $ecBlock->getCount() * ($ecBlock->getDataCodewords() + $ecCodewords);
+ }
+
+ $this->totalCodewords = $totalCodewords;
+ }
+
+ /**
+ * Returns the version number.
+ */
+ public function getVersionNumber() : int
+ {
+ return $this->versionNumber;
+ }
+
+ /**
+ * Returns the alignment pattern centers.
+ *
+ * @return int[]
+ */
+ public function getAlignmentPatternCenters() : array
+ {
+ return $this->alignmentPatternCenters;
+ }
+
+ /**
+ * Returns the total number of codewords.
+ */
+ public function getTotalCodewords() : int
+ {
+ return $this->totalCodewords;
+ }
+
+ /**
+ * Calculates the dimension for the current version.
+ */
+ public function getDimensionForVersion() : int
+ {
+ return 17 + 4 * $this->versionNumber;
+ }
+
+ /**
+ * Returns the number of EC blocks for a specific EC level.
+ */
+ public function getEcBlocksForLevel(ErrorCorrectionLevel $ecLevel) : EcBlocks
+ {
+ return $this->ecBlocks[$ecLevel->ordinal()];
+ }
+
+ /**
+ * Gets a provisional version number for a specific dimension.
+ *
+ * @throws InvalidArgumentException if dimension is not 1 mod 4
+ */
+ public static function getProvisionalVersionForDimension(int $dimension) : self
+ {
+ if (1 !== $dimension % 4) {
+ throw new InvalidArgumentException('Dimension is not 1 mod 4');
+ }
+
+ return self::getVersionForNumber(intdiv($dimension - 17, 4));
+ }
+
+ /**
+ * Gets a version instance for a specific version number.
+ *
+ * @throws InvalidArgumentException if version number is out of range
+ */
+ public static function getVersionForNumber(int $versionNumber) : self
+ {
+ if ($versionNumber < 1 || $versionNumber > 40) {
+ throw new InvalidArgumentException('Version number must be between 1 and 40');
+ }
+
+ return self::versions()[$versionNumber - 1];
+ }
+
+ /**
+ * Decodes version information from an integer and returns the version.
+ */
+ public static function decodeVersionInformation(int $versionBits) : ?self
+ {
+ $bestDifference = PHP_INT_MAX;
+ $bestVersion = 0;
+
+ foreach (self::VERSION_DECODE_INFO as $i => $targetVersion) {
+ if ($targetVersion === $versionBits) {
+ return self::getVersionForNumber($i + 7);
+ }
+
+ $bitsDifference = FormatInformation::numBitsDiffering($versionBits, $targetVersion);
+
+ if ($bitsDifference < $bestDifference) {
+ $bestVersion = $i + 7;
+ $bestDifference = $bitsDifference;
+ }
+ }
+
+ if ($bestDifference <= 3) {
+ return self::getVersionForNumber($bestVersion);
+ }
+
+ return null;
+ }
+
+ /**
+ * Builds the function pattern for the current version.
+ */
+ public function buildFunctionPattern() : BitMatrix
+ {
+ $dimension = $this->getDimensionForVersion();
+ $bitMatrix = new BitMatrix($dimension);
+
+ // Top left finder pattern + separator + format
+ $bitMatrix->setRegion(0, 0, 9, 9);
+ // Top right finder pattern + separator + format
+ $bitMatrix->setRegion($dimension - 8, 0, 8, 9);
+ // Bottom left finder pattern + separator + format
+ $bitMatrix->setRegion(0, $dimension - 8, 9, 8);
+
+ // Alignment patterns
+ $max = count($this->alignmentPatternCenters);
+
+ for ($x = 0; $x < $max; ++$x) {
+ $i = $this->alignmentPatternCenters[$x] - 2;
+
+ for ($y = 0; $y < $max; ++$y) {
+ if (($x === 0 && ($y === 0 || $y === $max - 1)) || ($x === $max - 1 && $y === 0)) {
+ // No alignment patterns near the three finder paterns
+ continue;
+ }
+
+ $bitMatrix->setRegion($this->alignmentPatternCenters[$y] - 2, $i, 5, 5);
+ }
+ }
+
+ // Vertical timing pattern
+ $bitMatrix->setRegion(6, 9, 1, $dimension - 17);
+ // Horizontal timing pattern
+ $bitMatrix->setRegion(9, 6, $dimension - 17, 1);
+
+ if ($this->versionNumber > 6) {
+ // Version info, top right
+ $bitMatrix->setRegion($dimension - 11, 0, 3, 6);
+ // Version info, bottom left
+ $bitMatrix->setRegion(0, $dimension - 11, 6, 3);
+ }
+
+ return $bitMatrix;
+ }
+
+ /**
+ * Returns a string representation for the version.
+ */
+ public function __toString() : string
+ {
+ return (string) $this->versionNumber;
+ }
+
+ /**
+ * Build and cache a specific version.
+ *
+ * See ISO 18004:2006 6.5.1 Table 9.
+ *
+ * @return array<int, self>
+ */
+ private static function versions() : array
+ {
+ if (null !== self::$versions) {
+ return self::$versions;
+ }
+
+ return self::$versions = [
+ new self(
+ 1,
+ [],
+ new EcBlocks(7, new EcBlock(1, 19)),
+ new EcBlocks(10, new EcBlock(1, 16)),
+ new EcBlocks(13, new EcBlock(1, 13)),
+ new EcBlocks(17, new EcBlock(1, 9))
+ ),
+ new self(
+ 2,
+ [6, 18],
+ new EcBlocks(10, new EcBlock(1, 34)),
+ new EcBlocks(16, new EcBlock(1, 28)),
+ new EcBlocks(22, new EcBlock(1, 22)),
+ new EcBlocks(28, new EcBlock(1, 16))
+ ),
+ new self(
+ 3,
+ [6, 22],
+ new EcBlocks(15, new EcBlock(1, 55)),
+ new EcBlocks(26, new EcBlock(1, 44)),
+ new EcBlocks(18, new EcBlock(2, 17)),
+ new EcBlocks(22, new EcBlock(2, 13))
+ ),
+ new self(
+ 4,
+ [6, 26],
+ new EcBlocks(20, new EcBlock(1, 80)),
+ new EcBlocks(18, new EcBlock(2, 32)),
+ new EcBlocks(26, new EcBlock(3, 24)),
+ new EcBlocks(16, new EcBlock(4, 9))
+ ),
+ new self(
+ 5,
+ [6, 30],
+ new EcBlocks(26, new EcBlock(1, 108)),
+ new EcBlocks(24, new EcBlock(2, 43)),
+ new EcBlocks(18, new EcBlock(2, 15), new EcBlock(2, 16)),
+ new EcBlocks(22, new EcBlock(2, 11), new EcBlock(2, 12))
+ ),
+ new self(
+ 6,
+ [6, 34],
+ new EcBlocks(18, new EcBlock(2, 68)),
+ new EcBlocks(16, new EcBlock(4, 27)),
+ new EcBlocks(24, new EcBlock(4, 19)),
+ new EcBlocks(28, new EcBlock(4, 15))
+ ),
+ new self(
+ 7,
+ [6, 22, 38],
+ new EcBlocks(20, new EcBlock(2, 78)),
+ new EcBlocks(18, new EcBlock(4, 31)),
+ new EcBlocks(18, new EcBlock(2, 14), new EcBlock(4, 15)),
+ new EcBlocks(26, new EcBlock(4, 13), new EcBlock(1, 14))
+ ),
+ new self(
+ 8,
+ [6, 24, 42],
+ new EcBlocks(24, new EcBlock(2, 97)),
+ new EcBlocks(22, new EcBlock(2, 38), new EcBlock(2, 39)),
+ new EcBlocks(22, new EcBlock(4, 18), new EcBlock(2, 19)),
+ new EcBlocks(26, new EcBlock(4, 14), new EcBlock(2, 15))
+ ),
+ new self(
+ 9,
+ [6, 26, 46],
+ new EcBlocks(30, new EcBlock(2, 116)),
+ new EcBlocks(22, new EcBlock(3, 36), new EcBlock(2, 37)),
+ new EcBlocks(20, new EcBlock(4, 16), new EcBlock(4, 17)),
+ new EcBlocks(24, new EcBlock(4, 12), new EcBlock(4, 13))
+ ),
+ new self(
+ 10,
+ [6, 28, 50],
+ new EcBlocks(18, new EcBlock(2, 68), new EcBlock(2, 69)),
+ new EcBlocks(26, new EcBlock(4, 43), new EcBlock(1, 44)),
+ new EcBlocks(24, new EcBlock(6, 19), new EcBlock(2, 20)),
+ new EcBlocks(28, new EcBlock(6, 15), new EcBlock(2, 16))
+ ),
+ new self(
+ 11,
+ [6, 30, 54],
+ new EcBlocks(20, new EcBlock(4, 81)),
+ new EcBlocks(30, new EcBlock(1, 50), new EcBlock(4, 51)),
+ new EcBlocks(28, new EcBlock(4, 22), new EcBlock(4, 23)),
+ new EcBlocks(24, new EcBlock(3, 12), new EcBlock(8, 13))
+ ),
+ new self(
+ 12,
+ [6, 32, 58],
+ new EcBlocks(24, new EcBlock(2, 92), new EcBlock(2, 93)),
+ new EcBlocks(22, new EcBlock(6, 36), new EcBlock(2, 37)),
+ new EcBlocks(26, new EcBlock(4, 20), new EcBlock(6, 21)),
+ new EcBlocks(28, new EcBlock(7, 14), new EcBlock(4, 15))
+ ),
+ new self(
+ 13,
+ [6, 34, 62],
+ new EcBlocks(26, new EcBlock(4, 107)),
+ new EcBlocks(22, new EcBlock(8, 37), new EcBlock(1, 38)),
+ new EcBlocks(24, new EcBlock(8, 20), new EcBlock(4, 21)),
+ new EcBlocks(22, new EcBlock(12, 11), new EcBlock(4, 12))
+ ),
+ new self(
+ 14,
+ [6, 26, 46, 66],
+ new EcBlocks(30, new EcBlock(3, 115), new EcBlock(1, 116)),
+ new EcBlocks(24, new EcBlock(4, 40), new EcBlock(5, 41)),
+ new EcBlocks(20, new EcBlock(11, 16), new EcBlock(5, 17)),
+ new EcBlocks(24, new EcBlock(11, 12), new EcBlock(5, 13))
+ ),
+ new self(
+ 15,
+ [6, 26, 48, 70],
+ new EcBlocks(22, new EcBlock(5, 87), new EcBlock(1, 88)),
+ new EcBlocks(24, new EcBlock(5, 41), new EcBlock(5, 42)),
+ new EcBlocks(30, new EcBlock(5, 24), new EcBlock(7, 25)),
+ new EcBlocks(24, new EcBlock(11, 12), new EcBlock(7, 13))
+ ),
+ new self(
+ 16,
+ [6, 26, 50, 74],
+ new EcBlocks(24, new EcBlock(5, 98), new EcBlock(1, 99)),
+ new EcBlocks(28, new EcBlock(7, 45), new EcBlock(3, 46)),
+ new EcBlocks(24, new EcBlock(15, 19), new EcBlock(2, 20)),
+ new EcBlocks(30, new EcBlock(3, 15), new EcBlock(13, 16))
+ ),
+ new self(
+ 17,
+ [6, 30, 54, 78],
+ new EcBlocks(28, new EcBlock(1, 107), new EcBlock(5, 108)),
+ new EcBlocks(28, new EcBlock(10, 46), new EcBlock(1, 47)),
+ new EcBlocks(28, new EcBlock(1, 22), new EcBlock(15, 23)),
+ new EcBlocks(28, new EcBlock(2, 14), new EcBlock(17, 15))
+ ),
+ new self(
+ 18,
+ [6, 30, 56, 82],
+ new EcBlocks(30, new EcBlock(5, 120), new EcBlock(1, 121)),
+ new EcBlocks(26, new EcBlock(9, 43), new EcBlock(4, 44)),
+ new EcBlocks(28, new EcBlock(17, 22), new EcBlock(1, 23)),
+ new EcBlocks(28, new EcBlock(2, 14), new EcBlock(19, 15))
+ ),
+ new self(
+ 19,
+ [6, 30, 58, 86],
+ new EcBlocks(28, new EcBlock(3, 113), new EcBlock(4, 114)),
+ new EcBlocks(26, new EcBlock(3, 44), new EcBlock(11, 45)),
+ new EcBlocks(26, new EcBlock(17, 21), new EcBlock(4, 22)),
+ new EcBlocks(26, new EcBlock(9, 13), new EcBlock(16, 14))
+ ),
+ new self(
+ 20,
+ [6, 34, 62, 90],
+ new EcBlocks(28, new EcBlock(3, 107), new EcBlock(5, 108)),
+ new EcBlocks(26, new EcBlock(3, 41), new EcBlock(13, 42)),
+ new EcBlocks(30, new EcBlock(15, 24), new EcBlock(5, 25)),
+ new EcBlocks(28, new EcBlock(15, 15), new EcBlock(10, 16))
+ ),
+ new self(
+ 21,
+ [6, 28, 50, 72, 94],
+ new EcBlocks(28, new EcBlock(4, 116), new EcBlock(4, 117)),
+ new EcBlocks(26, new EcBlock(17, 42)),
+ new EcBlocks(28, new EcBlock(17, 22), new EcBlock(6, 23)),
+ new EcBlocks(30, new EcBlock(19, 16), new EcBlock(6, 17))
+ ),
+ new self(
+ 22,
+ [6, 26, 50, 74, 98],
+ new EcBlocks(28, new EcBlock(2, 111), new EcBlock(7, 112)),
+ new EcBlocks(28, new EcBlock(17, 46)),
+ new EcBlocks(30, new EcBlock(7, 24), new EcBlock(16, 25)),
+ new EcBlocks(24, new EcBlock(34, 13))
+ ),
+ new self(
+ 23,
+ [6, 30, 54, 78, 102],
+ new EcBlocks(30, new EcBlock(4, 121), new EcBlock(5, 122)),
+ new EcBlocks(28, new EcBlock(4, 47), new EcBlock(14, 48)),
+ new EcBlocks(30, new EcBlock(11, 24), new EcBlock(14, 25)),
+ new EcBlocks(30, new EcBlock(16, 15), new EcBlock(14, 16))
+ ),
+ new self(
+ 24,
+ [6, 28, 54, 80, 106],
+ new EcBlocks(30, new EcBlock(6, 117), new EcBlock(4, 118)),
+ new EcBlocks(28, new EcBlock(6, 45), new EcBlock(14, 46)),
+ new EcBlocks(30, new EcBlock(11, 24), new EcBlock(16, 25)),
+ new EcBlocks(30, new EcBlock(30, 16), new EcBlock(2, 17))
+ ),
+ new self(
+ 25,
+ [6, 32, 58, 84, 110],
+ new EcBlocks(26, new EcBlock(8, 106), new EcBlock(4, 107)),
+ new EcBlocks(28, new EcBlock(8, 47), new EcBlock(13, 48)),
+ new EcBlocks(30, new EcBlock(7, 24), new EcBlock(22, 25)),
+ new EcBlocks(30, new EcBlock(22, 15), new EcBlock(13, 16))
+ ),
+ new self(
+ 26,
+ [6, 30, 58, 86, 114],
+ new EcBlocks(28, new EcBlock(10, 114), new EcBlock(2, 115)),
+ new EcBlocks(28, new EcBlock(19, 46), new EcBlock(4, 47)),
+ new EcBlocks(28, new EcBlock(28, 22), new EcBlock(6, 23)),
+ new EcBlocks(30, new EcBlock(33, 16), new EcBlock(4, 17))
+ ),
+ new self(
+ 27,
+ [6, 34, 62, 90, 118],
+ new EcBlocks(30, new EcBlock(8, 122), new EcBlock(4, 123)),
+ new EcBlocks(28, new EcBlock(22, 45), new EcBlock(3, 46)),
+ new EcBlocks(30, new EcBlock(8, 23), new EcBlock(26, 24)),
+ new EcBlocks(30, new EcBlock(12, 15), new EcBlock(28, 16))
+ ),
+ new self(
+ 28,
+ [6, 26, 50, 74, 98, 122],
+ new EcBlocks(30, new EcBlock(3, 117), new EcBlock(10, 118)),
+ new EcBlocks(28, new EcBlock(3, 45), new EcBlock(23, 46)),
+ new EcBlocks(30, new EcBlock(4, 24), new EcBlock(31, 25)),
+ new EcBlocks(30, new EcBlock(11, 15), new EcBlock(31, 16))
+ ),
+ new self(
+ 29,
+ [6, 30, 54, 78, 102, 126],
+ new EcBlocks(30, new EcBlock(7, 116), new EcBlock(7, 117)),
+ new EcBlocks(28, new EcBlock(21, 45), new EcBlock(7, 46)),
+ new EcBlocks(30, new EcBlock(1, 23), new EcBlock(37, 24)),
+ new EcBlocks(30, new EcBlock(19, 15), new EcBlock(26, 16))
+ ),
+ new self(
+ 30,
+ [6, 26, 52, 78, 104, 130],
+ new EcBlocks(30, new EcBlock(5, 115), new EcBlock(10, 116)),
+ new EcBlocks(28, new EcBlock(19, 47), new EcBlock(10, 48)),
+ new EcBlocks(30, new EcBlock(15, 24), new EcBlock(25, 25)),
+ new EcBlocks(30, new EcBlock(23, 15), new EcBlock(25, 16))
+ ),
+ new self(
+ 31,
+ [6, 30, 56, 82, 108, 134],
+ new EcBlocks(30, new EcBlock(13, 115), new EcBlock(3, 116)),
+ new EcBlocks(28, new EcBlock(2, 46), new EcBlock(29, 47)),
+ new EcBlocks(30, new EcBlock(42, 24), new EcBlock(1, 25)),
+ new EcBlocks(30, new EcBlock(23, 15), new EcBlock(28, 16))
+ ),
+ new self(
+ 32,
+ [6, 34, 60, 86, 112, 138],
+ new EcBlocks(30, new EcBlock(17, 115)),
+ new EcBlocks(28, new EcBlock(10, 46), new EcBlock(23, 47)),
+ new EcBlocks(30, new EcBlock(10, 24), new EcBlock(35, 25)),
+ new EcBlocks(30, new EcBlock(19, 15), new EcBlock(35, 16))
+ ),
+ new self(
+ 33,
+ [6, 30, 58, 86, 114, 142],
+ new EcBlocks(30, new EcBlock(17, 115), new EcBlock(1, 116)),
+ new EcBlocks(28, new EcBlock(14, 46), new EcBlock(21, 47)),
+ new EcBlocks(30, new EcBlock(29, 24), new EcBlock(19, 25)),
+ new EcBlocks(30, new EcBlock(11, 15), new EcBlock(46, 16))
+ ),
+ new self(
+ 34,
+ [6, 34, 62, 90, 118, 146],
+ new EcBlocks(30, new EcBlock(13, 115), new EcBlock(6, 116)),
+ new EcBlocks(28, new EcBlock(14, 46), new EcBlock(23, 47)),
+ new EcBlocks(30, new EcBlock(44, 24), new EcBlock(7, 25)),
+ new EcBlocks(30, new EcBlock(59, 16), new EcBlock(1, 17))
+ ),
+ new self(
+ 35,
+ [6, 30, 54, 78, 102, 126, 150],
+ new EcBlocks(30, new EcBlock(12, 121), new EcBlock(7, 122)),
+ new EcBlocks(28, new EcBlock(12, 47), new EcBlock(26, 48)),
+ new EcBlocks(30, new EcBlock(39, 24), new EcBlock(14, 25)),
+ new EcBlocks(30, new EcBlock(22, 15), new EcBlock(41, 16))
+ ),
+ new self(
+ 36,
+ [6, 24, 50, 76, 102, 128, 154],
+ new EcBlocks(30, new EcBlock(6, 121), new EcBlock(14, 122)),
+ new EcBlocks(28, new EcBlock(6, 47), new EcBlock(34, 48)),
+ new EcBlocks(30, new EcBlock(46, 24), new EcBlock(10, 25)),
+ new EcBlocks(30, new EcBlock(2, 15), new EcBlock(64, 16))
+ ),
+ new self(
+ 37,
+ [6, 28, 54, 80, 106, 132, 158],
+ new EcBlocks(30, new EcBlock(17, 122), new EcBlock(4, 123)),
+ new EcBlocks(28, new EcBlock(29, 46), new EcBlock(14, 47)),
+ new EcBlocks(30, new EcBlock(49, 24), new EcBlock(10, 25)),
+ new EcBlocks(30, new EcBlock(24, 15), new EcBlock(46, 16))
+ ),
+ new self(
+ 38,
+ [6, 32, 58, 84, 110, 136, 162],
+ new EcBlocks(30, new EcBlock(4, 122), new EcBlock(18, 123)),
+ new EcBlocks(28, new EcBlock(13, 46), new EcBlock(32, 47)),
+ new EcBlocks(30, new EcBlock(48, 24), new EcBlock(14, 25)),
+ new EcBlocks(30, new EcBlock(42, 15), new EcBlock(32, 16))
+ ),
+ new self(
+ 39,
+ [6, 26, 54, 82, 110, 138, 166],
+ new EcBlocks(30, new EcBlock(20, 117), new EcBlock(4, 118)),
+ new EcBlocks(28, new EcBlock(40, 47), new EcBlock(7, 48)),
+ new EcBlocks(30, new EcBlock(43, 24), new EcBlock(22, 25)),
+ new EcBlocks(30, new EcBlock(10, 15), new EcBlock(67, 16))
+ ),
+ new self(
+ 40,
+ [6, 30, 58, 86, 114, 142, 170],
+ new EcBlocks(30, new EcBlock(19, 118), new EcBlock(6, 119)),
+ new EcBlocks(28, new EcBlock(18, 47), new EcBlock(31, 48)),
+ new EcBlocks(30, new EcBlock(34, 24), new EcBlock(34, 25)),
+ new EcBlocks(30, new EcBlock(20, 15), new EcBlock(61, 16))
+ ),
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/BlockPair.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/BlockPair.php
new file mode 100644
index 0000000..be54afa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/BlockPair.php
@@ -0,0 +1,58 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Encoder;
+
+use SplFixedArray;
+
+/**
+ * Block pair.
+ */
+final class BlockPair
+{
+ /**
+ * Data bytes in the block.
+ *
+ * @var SplFixedArray<int>
+ */
+ private $dataBytes;
+
+ /**
+ * Error correction bytes in the block.
+ *
+ * @var SplFixedArray<int>
+ */
+ private $errorCorrectionBytes;
+
+ /**
+ * Creates a new block pair.
+ *
+ * @param SplFixedArray<int> $data
+ * @param SplFixedArray<int> $errorCorrection
+ */
+ public function __construct(SplFixedArray $data, SplFixedArray $errorCorrection)
+ {
+ $this->dataBytes = $data;
+ $this->errorCorrectionBytes = $errorCorrection;
+ }
+
+ /**
+ * Gets the data bytes.
+ *
+ * @return SplFixedArray<int>
+ */
+ public function getDataBytes() : SplFixedArray
+ {
+ return $this->dataBytes;
+ }
+
+ /**
+ * Gets the error correction bytes.
+ *
+ * @return SplFixedArray<int>
+ */
+ public function getErrorCorrectionBytes() : SplFixedArray
+ {
+ return $this->errorCorrectionBytes;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/ByteMatrix.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/ByteMatrix.php
new file mode 100644
index 0000000..b58cc0a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/ByteMatrix.php
@@ -0,0 +1,150 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Encoder;
+
+use SplFixedArray;
+use Traversable;
+
+/**
+ * Byte matrix.
+ */
+final class ByteMatrix
+{
+ /**
+ * Bytes in the matrix, represented as array.
+ *
+ * @var SplFixedArray<SplFixedArray<int>>
+ */
+ private $bytes;
+
+ /**
+ * Width of the matrix.
+ *
+ * @var int
+ */
+ private $width;
+
+ /**
+ * Height of the matrix.
+ *
+ * @var int
+ */
+ private $height;
+
+ public function __construct(int $width, int $height)
+ {
+ $this->height = $height;
+ $this->width = $width;
+ $this->bytes = new SplFixedArray($height);
+
+ for ($y = 0; $y < $height; ++$y) {
+ $this->bytes[$y] = SplFixedArray::fromArray(array_fill(0, $width, 0));
+ }
+ }
+
+ /**
+ * Gets the width of the matrix.
+ */
+ public function getWidth() : int
+ {
+ return $this->width;
+ }
+
+ /**
+ * Gets the height of the matrix.
+ */
+ public function getHeight() : int
+ {
+ return $this->height;
+ }
+
+ /**
+ * Gets the internal representation of the matrix.
+ *
+ * @return SplFixedArray<SplFixedArray<int>>
+ */
+ public function getArray() : SplFixedArray
+ {
+ return $this->bytes;
+ }
+
+ /**
+ * @return Traversable<int>
+ */
+ public function getBytes() : Traversable
+ {
+ foreach ($this->bytes as $row) {
+ foreach ($row as $byte) {
+ yield $byte;
+ }
+ }
+ }
+
+ /**
+ * Gets the byte for a specific position.
+ */
+ public function get(int $x, int $y) : int
+ {
+ return $this->bytes[$y][$x];
+ }
+
+ /**
+ * Sets the byte for a specific position.
+ */
+ public function set(int $x, int $y, int $value) : void
+ {
+ $this->bytes[$y][$x] = $value;
+ }
+
+ /**
+ * Clears the matrix with a specific value.
+ */
+ public function clear(int $value) : void
+ {
+ for ($y = 0; $y < $this->height; ++$y) {
+ for ($x = 0; $x < $this->width; ++$x) {
+ $this->bytes[$y][$x] = $value;
+ }
+ }
+ }
+
+ public function __clone()
+ {
+ $this->bytes = clone $this->bytes;
+
+ foreach ($this->bytes as $index => $row) {
+ $this->bytes[$index] = clone $row;
+ }
+ }
+
+ /**
+ * Returns a string representation of the matrix.
+ */
+ public function __toString() : string
+ {
+ $result = '';
+
+ for ($y = 0; $y < $this->height; $y++) {
+ for ($x = 0; $x < $this->width; $x++) {
+ switch ($this->bytes[$y][$x]) {
+ case 0:
+ $result .= ' 0';
+ break;
+
+ case 1:
+ $result .= ' 1';
+ break;
+
+ default:
+ $result .= ' ';
+ break;
+ }
+ }
+
+ $result .= "\n";
+ }
+
+ return $result;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/Encoder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/Encoder.php
new file mode 100644
index 0000000..3208460
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/Encoder.php
@@ -0,0 +1,668 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Encoder;
+
+use BaconQrCode\Common\BitArray;
+use BaconQrCode\Common\CharacterSetEci;
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\Mode;
+use BaconQrCode\Common\ReedSolomonCodec;
+use BaconQrCode\Common\Version;
+use BaconQrCode\Exception\WriterException;
+use SplFixedArray;
+
+/**
+ * Encoder.
+ */
+final class Encoder
+{
+ /**
+ * Default byte encoding.
+ */
+ public const DEFAULT_BYTE_MODE_ECODING = 'ISO-8859-1';
+
+ /**
+ * The original table is defined in the table 5 of JISX0510:2004 (p.19).
+ */
+ private const ALPHANUMERIC_TABLE = [
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 0x00-0x0f
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 0x10-0x1f
+ 36, -1, -1, -1, 37, 38, -1, -1, -1, -1, 39, 40, -1, 41, 42, 43, // 0x20-0x2f
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 44, -1, -1, -1, -1, -1, // 0x30-0x3f
+ -1, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, // 0x40-0x4f
+ 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, -1, -1, -1, -1, -1, // 0x50-0x5f
+ ];
+
+ /**
+ * Codec cache.
+ *
+ * @var array<string,ReedSolomonCodec>
+ */
+ private static $codecs = [];
+
+ /**
+ * Encodes "content" with the error correction level "ecLevel".
+ */
+ public static function encode(
+ string $content,
+ ErrorCorrectionLevel $ecLevel,
+ string $encoding = self::DEFAULT_BYTE_MODE_ECODING,
+ ?Version $forcedVersion = null
+ ) : QrCode {
+ // Pick an encoding mode appropriate for the content. Note that this
+ // will not attempt to use multiple modes / segments even if that were
+ // more efficient. Would be nice.
+ $mode = self::chooseMode($content, $encoding);
+
+ // This will store the header information, like mode and length, as well
+ // as "header" segments like an ECI segment.
+ $headerBits = new BitArray();
+
+ // Append ECI segment if applicable
+ if (Mode::BYTE() === $mode && self::DEFAULT_BYTE_MODE_ECODING !== $encoding) {
+ $eci = CharacterSetEci::getCharacterSetEciByName($encoding);
+
+ if (null !== $eci) {
+ self::appendEci($eci, $headerBits);
+ }
+ }
+
+ // (With ECI in place,) Write the mode marker
+ self::appendModeInfo($mode, $headerBits);
+
+ // Collect data within the main segment, separately, to count its size
+ // if needed. Don't add it to main payload yet.
+ $dataBits = new BitArray();
+ self::appendBytes($content, $mode, $dataBits, $encoding);
+
+ // Hard part: need to know version to know how many bits length takes.
+ // But need to know how many bits it takes to know version. First we
+ // take a guess at version by assuming version will be the minimum, 1:
+ $provisionalBitsNeeded = $headerBits->getSize()
+ + $mode->getCharacterCountBits(Version::getVersionForNumber(1))
+ + $dataBits->getSize();
+ $provisionalVersion = self::chooseVersion($provisionalBitsNeeded, $ecLevel);
+
+ // Use that guess to calculate the right version. I am still not sure
+ // this works in 100% of cases.
+ $bitsNeeded = $headerBits->getSize()
+ + $mode->getCharacterCountBits($provisionalVersion)
+ + $dataBits->getSize();
+ $version = self::chooseVersion($bitsNeeded, $ecLevel);
+
+ if (null !== $forcedVersion) {
+ // Forced version check
+ if ($version->getVersionNumber() <= $forcedVersion->getVersionNumber()) {
+ // Calculated minimum version is same or equal as forced version
+ $version = $forcedVersion;
+ } else {
+ throw new WriterException(
+ 'Invalid version! Calculated version: '
+ . $version->getVersionNumber()
+ . ', requested version: '
+ . $forcedVersion->getVersionNumber()
+ );
+ }
+ }
+
+ $headerAndDataBits = new BitArray();
+ $headerAndDataBits->appendBitArray($headerBits);
+
+ // Find "length" of main segment and write it.
+ $numLetters = (Mode::BYTE() === $mode ? $dataBits->getSizeInBytes() : strlen($content));
+ self::appendLengthInfo($numLetters, $version, $mode, $headerAndDataBits);
+
+ // Put data together into the overall payload.
+ $headerAndDataBits->appendBitArray($dataBits);
+ $ecBlocks = $version->getEcBlocksForLevel($ecLevel);
+ $numDataBytes = $version->getTotalCodewords() - $ecBlocks->getTotalEcCodewords();
+
+ // Terminate the bits properly.
+ self::terminateBits($numDataBytes, $headerAndDataBits);
+
+ // Interleave data bits with error correction code.
+ $finalBits = self::interleaveWithEcBytes(
+ $headerAndDataBits,
+ $version->getTotalCodewords(),
+ $numDataBytes,
+ $ecBlocks->getNumBlocks()
+ );
+
+ // Choose the mask pattern.
+ $dimension = $version->getDimensionForVersion();
+ $matrix = new ByteMatrix($dimension, $dimension);
+ $maskPattern = self::chooseMaskPattern($finalBits, $ecLevel, $version, $matrix);
+
+ // Build the matrix.
+ MatrixUtil::buildMatrix($finalBits, $ecLevel, $version, $maskPattern, $matrix);
+
+ return new QrCode($mode, $ecLevel, $version, $maskPattern, $matrix);
+ }
+
+ /**
+ * Gets the alphanumeric code for a byte.
+ */
+ private static function getAlphanumericCode(int $code) : int
+ {
+ if (isset(self::ALPHANUMERIC_TABLE[$code])) {
+ return self::ALPHANUMERIC_TABLE[$code];
+ }
+
+ return -1;
+ }
+
+ /**
+ * Chooses the best mode for a given content.
+ */
+ private static function chooseMode(string $content, string $encoding = null) : Mode
+ {
+ if (null !== $encoding && 0 === strcasecmp($encoding, 'SHIFT-JIS')) {
+ return self::isOnlyDoubleByteKanji($content) ? Mode::KANJI() : Mode::BYTE();
+ }
+
+ $hasNumeric = false;
+ $hasAlphanumeric = false;
+ $contentLength = strlen($content);
+
+ for ($i = 0; $i < $contentLength; ++$i) {
+ $char = $content[$i];
+
+ if (ctype_digit($char)) {
+ $hasNumeric = true;
+ } elseif (-1 !== self::getAlphanumericCode(ord($char))) {
+ $hasAlphanumeric = true;
+ } else {
+ return Mode::BYTE();
+ }
+ }
+
+ if ($hasAlphanumeric) {
+ return Mode::ALPHANUMERIC();
+ } elseif ($hasNumeric) {
+ return Mode::NUMERIC();
+ }
+
+ return Mode::BYTE();
+ }
+
+ /**
+ * Calculates the mask penalty for a matrix.
+ */
+ private static function calculateMaskPenalty(ByteMatrix $matrix) : int
+ {
+ return (
+ MaskUtil::applyMaskPenaltyRule1($matrix)
+ + MaskUtil::applyMaskPenaltyRule2($matrix)
+ + MaskUtil::applyMaskPenaltyRule3($matrix)
+ + MaskUtil::applyMaskPenaltyRule4($matrix)
+ );
+ }
+
+ /**
+ * Checks if content only consists of double-byte kanji characters.
+ */
+ private static function isOnlyDoubleByteKanji(string $content) : bool
+ {
+ $bytes = @iconv('utf-8', 'SHIFT-JIS', $content);
+
+ if (false === $bytes) {
+ return false;
+ }
+
+ $length = strlen($bytes);
+
+ if (0 !== $length % 2) {
+ return false;
+ }
+
+ for ($i = 0; $i < $length; $i += 2) {
+ $byte = $bytes[$i] & 0xff;
+
+ if (($byte < 0x81 || $byte > 0x9f) && $byte < 0xe0 || $byte > 0xeb) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Chooses the best mask pattern for a matrix.
+ */
+ private static function chooseMaskPattern(
+ BitArray $bits,
+ ErrorCorrectionLevel $ecLevel,
+ Version $version,
+ ByteMatrix $matrix
+ ) : int {
+ $minPenalty = PHP_INT_MAX;
+ $bestMaskPattern = -1;
+
+ for ($maskPattern = 0; $maskPattern < QrCode::NUM_MASK_PATTERNS; ++$maskPattern) {
+ MatrixUtil::buildMatrix($bits, $ecLevel, $version, $maskPattern, $matrix);
+ $penalty = self::calculateMaskPenalty($matrix);
+
+ if ($penalty < $minPenalty) {
+ $minPenalty = $penalty;
+ $bestMaskPattern = $maskPattern;
+ }
+ }
+
+ return $bestMaskPattern;
+ }
+
+ /**
+ * Chooses the best version for the input.
+ *
+ * @throws WriterException if data is too big
+ */
+ private static function chooseVersion(int $numInputBits, ErrorCorrectionLevel $ecLevel) : Version
+ {
+ for ($versionNum = 1; $versionNum <= 40; ++$versionNum) {
+ $version = Version::getVersionForNumber($versionNum);
+ $numBytes = $version->getTotalCodewords();
+
+ $ecBlocks = $version->getEcBlocksForLevel($ecLevel);
+ $numEcBytes = $ecBlocks->getTotalEcCodewords();
+
+ $numDataBytes = $numBytes - $numEcBytes;
+ $totalInputBytes = intdiv($numInputBits + 8, 8);
+
+ if ($numDataBytes >= $totalInputBytes) {
+ return $version;
+ }
+ }
+
+ throw new WriterException('Data too big');
+ }
+
+ /**
+ * Terminates the bits in a bit array.
+ *
+ * @throws WriterException if data bits cannot fit in the QR code
+ * @throws WriterException if bits size does not equal the capacity
+ */
+ private static function terminateBits(int $numDataBytes, BitArray $bits) : void
+ {
+ $capacity = $numDataBytes << 3;
+
+ if ($bits->getSize() > $capacity) {
+ throw new WriterException('Data bits cannot fit in the QR code');
+ }
+
+ for ($i = 0; $i < 4 && $bits->getSize() < $capacity; ++$i) {
+ $bits->appendBit(false);
+ }
+
+ $numBitsInLastByte = $bits->getSize() & 0x7;
+
+ if ($numBitsInLastByte > 0) {
+ for ($i = $numBitsInLastByte; $i < 8; ++$i) {
+ $bits->appendBit(false);
+ }
+ }
+
+ $numPaddingBytes = $numDataBytes - $bits->getSizeInBytes();
+
+ for ($i = 0; $i < $numPaddingBytes; ++$i) {
+ $bits->appendBits(0 === ($i & 0x1) ? 0xec : 0x11, 8);
+ }
+
+ if ($bits->getSize() !== $capacity) {
+ throw new WriterException('Bits size does not equal capacity');
+ }
+ }
+
+ /**
+ * Gets number of data- and EC bytes for a block ID.
+ *
+ * @return int[]
+ * @throws WriterException if block ID is too large
+ * @throws WriterException if EC bytes mismatch
+ * @throws WriterException if RS blocks mismatch
+ * @throws WriterException if total bytes mismatch
+ */
+ private static function getNumDataBytesAndNumEcBytesForBlockId(
+ int $numTotalBytes,
+ int $numDataBytes,
+ int $numRsBlocks,
+ int $blockId
+ ) : array {
+ if ($blockId >= $numRsBlocks) {
+ throw new WriterException('Block ID too large');
+ }
+
+ $numRsBlocksInGroup2 = $numTotalBytes % $numRsBlocks;
+ $numRsBlocksInGroup1 = $numRsBlocks - $numRsBlocksInGroup2;
+ $numTotalBytesInGroup1 = intdiv($numTotalBytes, $numRsBlocks);
+ $numTotalBytesInGroup2 = $numTotalBytesInGroup1 + 1;
+ $numDataBytesInGroup1 = intdiv($numDataBytes, $numRsBlocks);
+ $numDataBytesInGroup2 = $numDataBytesInGroup1 + 1;
+ $numEcBytesInGroup1 = $numTotalBytesInGroup1 - $numDataBytesInGroup1;
+ $numEcBytesInGroup2 = $numTotalBytesInGroup2 - $numDataBytesInGroup2;
+
+ if ($numEcBytesInGroup1 !== $numEcBytesInGroup2) {
+ throw new WriterException('EC bytes mismatch');
+ }
+
+ if ($numRsBlocks !== $numRsBlocksInGroup1 + $numRsBlocksInGroup2) {
+ throw new WriterException('RS blocks mismatch');
+ }
+
+ if ($numTotalBytes !==
+ (($numDataBytesInGroup1 + $numEcBytesInGroup1) * $numRsBlocksInGroup1)
+ + (($numDataBytesInGroup2 + $numEcBytesInGroup2) * $numRsBlocksInGroup2)
+ ) {
+ throw new WriterException('Total bytes mismatch');
+ }
+
+ if ($blockId < $numRsBlocksInGroup1) {
+ return [$numDataBytesInGroup1, $numEcBytesInGroup1];
+ } else {
+ return [$numDataBytesInGroup2, $numEcBytesInGroup2];
+ }
+ }
+
+ /**
+ * Interleaves data with EC bytes.
+ *
+ * @throws WriterException if number of bits and data bytes does not match
+ * @throws WriterException if data bytes does not match offset
+ * @throws WriterException if an interleaving error occurs
+ */
+ private static function interleaveWithEcBytes(
+ BitArray $bits,
+ int $numTotalBytes,
+ int $numDataBytes,
+ int $numRsBlocks
+ ) : BitArray {
+ if ($bits->getSizeInBytes() !== $numDataBytes) {
+ throw new WriterException('Number of bits and data bytes does not match');
+ }
+
+ $dataBytesOffset = 0;
+ $maxNumDataBytes = 0;
+ $maxNumEcBytes = 0;
+
+ $blocks = new SplFixedArray($numRsBlocks);
+
+ for ($i = 0; $i < $numRsBlocks; ++$i) {
+ list($numDataBytesInBlock, $numEcBytesInBlock) = self::getNumDataBytesAndNumEcBytesForBlockId(
+ $numTotalBytes,
+ $numDataBytes,
+ $numRsBlocks,
+ $i
+ );
+
+ $size = $numDataBytesInBlock;
+ $dataBytes = $bits->toBytes(8 * $dataBytesOffset, $size);
+ $ecBytes = self::generateEcBytes($dataBytes, $numEcBytesInBlock);
+ $blocks[$i] = new BlockPair($dataBytes, $ecBytes);
+
+ $maxNumDataBytes = max($maxNumDataBytes, $size);
+ $maxNumEcBytes = max($maxNumEcBytes, count($ecBytes));
+ $dataBytesOffset += $numDataBytesInBlock;
+ }
+
+ if ($numDataBytes !== $dataBytesOffset) {
+ throw new WriterException('Data bytes does not match offset');
+ }
+
+ $result = new BitArray();
+
+ for ($i = 0; $i < $maxNumDataBytes; ++$i) {
+ foreach ($blocks as $block) {
+ $dataBytes = $block->getDataBytes();
+
+ if ($i < count($dataBytes)) {
+ $result->appendBits($dataBytes[$i], 8);
+ }
+ }
+ }
+
+ for ($i = 0; $i < $maxNumEcBytes; ++$i) {
+ foreach ($blocks as $block) {
+ $ecBytes = $block->getErrorCorrectionBytes();
+
+ if ($i < count($ecBytes)) {
+ $result->appendBits($ecBytes[$i], 8);
+ }
+ }
+ }
+
+ if ($numTotalBytes !== $result->getSizeInBytes()) {
+ throw new WriterException(
+ 'Interleaving error: ' . $numTotalBytes . ' and ' . $result->getSizeInBytes() . ' differ'
+ );
+ }
+
+ return $result;
+ }
+
+ /**
+ * Generates EC bytes for given data.
+ *
+ * @param SplFixedArray<int> $dataBytes
+ * @return SplFixedArray<int>
+ */
+ private static function generateEcBytes(SplFixedArray $dataBytes, int $numEcBytesInBlock) : SplFixedArray
+ {
+ $numDataBytes = count($dataBytes);
+ $toEncode = new SplFixedArray($numDataBytes + $numEcBytesInBlock);
+
+ for ($i = 0; $i < $numDataBytes; $i++) {
+ $toEncode[$i] = $dataBytes[$i] & 0xff;
+ }
+
+ $ecBytes = new SplFixedArray($numEcBytesInBlock);
+ $codec = self::getCodec($numDataBytes, $numEcBytesInBlock);
+ $codec->encode($toEncode, $ecBytes);
+
+ return $ecBytes;
+ }
+
+ /**
+ * Gets an RS codec and caches it.
+ */
+ private static function getCodec(int $numDataBytes, int $numEcBytesInBlock) : ReedSolomonCodec
+ {
+ $cacheId = $numDataBytes . '-' . $numEcBytesInBlock;
+
+ if (isset(self::$codecs[$cacheId])) {
+ return self::$codecs[$cacheId];
+ }
+
+ return self::$codecs[$cacheId] = new ReedSolomonCodec(
+ 8,
+ 0x11d,
+ 0,
+ 1,
+ $numEcBytesInBlock,
+ 255 - $numDataBytes - $numEcBytesInBlock
+ );
+ }
+
+ /**
+ * Appends mode information to a bit array.
+ */
+ private static function appendModeInfo(Mode $mode, BitArray $bits) : void
+ {
+ $bits->appendBits($mode->getBits(), 4);
+ }
+
+ /**
+ * Appends length information to a bit array.
+ *
+ * @throws WriterException if num letters is bigger than expected
+ */
+ private static function appendLengthInfo(int $numLetters, Version $version, Mode $mode, BitArray $bits) : void
+ {
+ $numBits = $mode->getCharacterCountBits($version);
+
+ if ($numLetters >= (1 << $numBits)) {
+ throw new WriterException($numLetters . ' is bigger than ' . ((1 << $numBits) - 1));
+ }
+
+ $bits->appendBits($numLetters, $numBits);
+ }
+
+ /**
+ * Appends bytes to a bit array in a specific mode.
+ *
+ * @throws WriterException if an invalid mode was supplied
+ */
+ private static function appendBytes(string $content, Mode $mode, BitArray $bits, string $encoding) : void
+ {
+ switch ($mode) {
+ case Mode::NUMERIC():
+ self::appendNumericBytes($content, $bits);
+ break;
+
+ case Mode::ALPHANUMERIC():
+ self::appendAlphanumericBytes($content, $bits);
+ break;
+
+ case Mode::BYTE():
+ self::append8BitBytes($content, $bits, $encoding);
+ break;
+
+ case Mode::KANJI():
+ self::appendKanjiBytes($content, $bits);
+ break;
+
+ default:
+ throw new WriterException('Invalid mode: ' . $mode);
+ }
+ }
+
+ /**
+ * Appends numeric bytes to a bit array.
+ */
+ private static function appendNumericBytes(string $content, BitArray $bits) : void
+ {
+ $length = strlen($content);
+ $i = 0;
+
+ while ($i < $length) {
+ $num1 = (int) $content[$i];
+
+ if ($i + 2 < $length) {
+ // Encode three numeric letters in ten bits.
+ $num2 = (int) $content[$i + 1];
+ $num3 = (int) $content[$i + 2];
+ $bits->appendBits($num1 * 100 + $num2 * 10 + $num3, 10);
+ $i += 3;
+ } elseif ($i + 1 < $length) {
+ // Encode two numeric letters in seven bits.
+ $num2 = (int) $content[$i + 1];
+ $bits->appendBits($num1 * 10 + $num2, 7);
+ $i += 2;
+ } else {
+ // Encode one numeric letter in four bits.
+ $bits->appendBits($num1, 4);
+ ++$i;
+ }
+ }
+ }
+
+ /**
+ * Appends alpha-numeric bytes to a bit array.
+ *
+ * @throws WriterException if an invalid alphanumeric code was found
+ */
+ private static function appendAlphanumericBytes(string $content, BitArray $bits) : void
+ {
+ $length = strlen($content);
+ $i = 0;
+
+ while ($i < $length) {
+ $code1 = self::getAlphanumericCode(ord($content[$i]));
+
+ if (-1 === $code1) {
+ throw new WriterException('Invalid alphanumeric code');
+ }
+
+ if ($i + 1 < $length) {
+ $code2 = self::getAlphanumericCode(ord($content[$i + 1]));
+
+ if (-1 === $code2) {
+ throw new WriterException('Invalid alphanumeric code');
+ }
+
+ // Encode two alphanumeric letters in 11 bits.
+ $bits->appendBits($code1 * 45 + $code2, 11);
+ $i += 2;
+ } else {
+ // Encode one alphanumeric letter in six bits.
+ $bits->appendBits($code1, 6);
+ ++$i;
+ }
+ }
+ }
+
+ /**
+ * Appends regular 8-bit bytes to a bit array.
+ *
+ * @throws WriterException if content cannot be encoded to target encoding
+ */
+ private static function append8BitBytes(string $content, BitArray $bits, string $encoding) : void
+ {
+ $bytes = @iconv('utf-8', $encoding, $content);
+
+ if (false === $bytes) {
+ throw new WriterException('Could not encode content to ' . $encoding);
+ }
+
+ $length = strlen($bytes);
+
+ for ($i = 0; $i < $length; $i++) {
+ $bits->appendBits(ord($bytes[$i]), 8);
+ }
+ }
+
+ /**
+ * Appends KANJI bytes to a bit array.
+ *
+ * @throws WriterException if content does not seem to be encoded in SHIFT-JIS
+ * @throws WriterException if an invalid byte sequence occurs
+ */
+ private static function appendKanjiBytes(string $content, BitArray $bits) : void
+ {
+ if (strlen($content) % 2 > 0) {
+ // We just do a simple length check here. The for loop will check
+ // individual characters.
+ throw new WriterException('Content does not seem to be encoded in SHIFT-JIS');
+ }
+
+ $length = strlen($content);
+
+ for ($i = 0; $i < $length; $i += 2) {
+ $byte1 = ord($content[$i]) & 0xff;
+ $byte2 = ord($content[$i + 1]) & 0xff;
+ $code = ($byte1 << 8) | $byte2;
+
+ if ($code >= 0x8140 && $code <= 0x9ffc) {
+ $subtracted = $code - 0x8140;
+ } elseif ($code >= 0xe040 && $code <= 0xebbf) {
+ $subtracted = $code - 0xc140;
+ } else {
+ throw new WriterException('Invalid byte sequence');
+ }
+
+ $encoded = (($subtracted >> 8) * 0xc0) + ($subtracted & 0xff);
+
+ $bits->appendBits($encoded, 13);
+ }
+ }
+
+ /**
+ * Appends ECI information to a bit array.
+ */
+ private static function appendEci(CharacterSetEci $eci, BitArray $bits) : void
+ {
+ $mode = Mode::ECI();
+ $bits->appendBits($mode->getBits(), 4);
+ $bits->appendBits($eci->getValue(), 8);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/MaskUtil.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/MaskUtil.php
new file mode 100644
index 0000000..ba97dfb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/MaskUtil.php
@@ -0,0 +1,271 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Encoder;
+
+use BaconQrCode\Common\BitUtils;
+use BaconQrCode\Exception\InvalidArgumentException;
+
+/**
+ * Mask utility.
+ */
+final class MaskUtil
+{
+ /**#@+
+ * Penalty weights from section 6.8.2.1
+ */
+ const N1 = 3;
+ const N2 = 3;
+ const N3 = 40;
+ const N4 = 10;
+ /**#@-*/
+
+ private function __construct()
+ {
+ }
+
+ /**
+ * Applies mask penalty rule 1 and returns the penalty.
+ *
+ * Finds repetitive cells with the same color and gives penalty to them.
+ * Example: 00000 or 11111.
+ */
+ public static function applyMaskPenaltyRule1(ByteMatrix $matrix) : int
+ {
+ return (
+ self::applyMaskPenaltyRule1Internal($matrix, true)
+ + self::applyMaskPenaltyRule1Internal($matrix, false)
+ );
+ }
+
+ /**
+ * Applies mask penalty rule 2 and returns the penalty.
+ *
+ * Finds 2x2 blocks with the same color and gives penalty to them. This is
+ * actually equivalent to the spec's rule, which is to find MxN blocks and
+ * give a penalty proportional to (M-1)x(N-1), because this is the number of
+ * 2x2 blocks inside such a block.
+ */
+ public static function applyMaskPenaltyRule2(ByteMatrix $matrix) : int
+ {
+ $penalty = 0;
+ $array = $matrix->getArray();
+ $width = $matrix->getWidth();
+ $height = $matrix->getHeight();
+
+ for ($y = 0; $y < $height - 1; ++$y) {
+ for ($x = 0; $x < $width - 1; ++$x) {
+ $value = $array[$y][$x];
+
+ if ($value === $array[$y][$x + 1]
+ && $value === $array[$y + 1][$x]
+ && $value === $array[$y + 1][$x + 1]
+ ) {
+ ++$penalty;
+ }
+ }
+ }
+
+ return self::N2 * $penalty;
+ }
+
+ /**
+ * Applies mask penalty rule 3 and returns the penalty.
+ *
+ * Finds consecutive cells of 00001011101 or 10111010000, and gives penalty
+ * to them. If we find patterns like 000010111010000, we give penalties
+ * twice (i.e. 40 * 2).
+ */
+ public static function applyMaskPenaltyRule3(ByteMatrix $matrix) : int
+ {
+ $penalty = 0;
+ $array = $matrix->getArray();
+ $width = $matrix->getWidth();
+ $height = $matrix->getHeight();
+
+ for ($y = 0; $y < $height; ++$y) {
+ for ($x = 0; $x < $width; ++$x) {
+ if ($x + 6 < $width
+ && 1 === $array[$y][$x]
+ && 0 === $array[$y][$x + 1]
+ && 1 === $array[$y][$x + 2]
+ && 1 === $array[$y][$x + 3]
+ && 1 === $array[$y][$x + 4]
+ && 0 === $array[$y][$x + 5]
+ && 1 === $array[$y][$x + 6]
+ && (
+ (
+ $x + 10 < $width
+ && 0 === $array[$y][$x + 7]
+ && 0 === $array[$y][$x + 8]
+ && 0 === $array[$y][$x + 9]
+ && 0 === $array[$y][$x + 10]
+ )
+ || (
+ $x - 4 >= 0
+ && 0 === $array[$y][$x - 1]
+ && 0 === $array[$y][$x - 2]
+ && 0 === $array[$y][$x - 3]
+ && 0 === $array[$y][$x - 4]
+ )
+ )
+ ) {
+ $penalty += self::N3;
+ }
+
+ if ($y + 6 < $height
+ && 1 === $array[$y][$x]
+ && 0 === $array[$y + 1][$x]
+ && 1 === $array[$y + 2][$x]
+ && 1 === $array[$y + 3][$x]
+ && 1 === $array[$y + 4][$x]
+ && 0 === $array[$y + 5][$x]
+ && 1 === $array[$y + 6][$x]
+ && (
+ (
+ $y + 10 < $height
+ && 0 === $array[$y + 7][$x]
+ && 0 === $array[$y + 8][$x]
+ && 0 === $array[$y + 9][$x]
+ && 0 === $array[$y + 10][$x]
+ )
+ || (
+ $y - 4 >= 0
+ && 0 === $array[$y - 1][$x]
+ && 0 === $array[$y - 2][$x]
+ && 0 === $array[$y - 3][$x]
+ && 0 === $array[$y - 4][$x]
+ )
+ )
+ ) {
+ $penalty += self::N3;
+ }
+ }
+ }
+
+ return $penalty;
+ }
+
+ /**
+ * Applies mask penalty rule 4 and returns the penalty.
+ *
+ * Calculates the ratio of dark cells and gives penalty if the ratio is far
+ * from 50%. It gives 10 penalty for 5% distance.
+ */
+ public static function applyMaskPenaltyRule4(ByteMatrix $matrix) : int
+ {
+ $numDarkCells = 0;
+
+ $array = $matrix->getArray();
+ $width = $matrix->getWidth();
+ $height = $matrix->getHeight();
+
+ for ($y = 0; $y < $height; ++$y) {
+ $arrayY = $array[$y];
+
+ for ($x = 0; $x < $width; ++$x) {
+ if (1 === $arrayY[$x]) {
+ ++$numDarkCells;
+ }
+ }
+ }
+
+ $numTotalCells = $height * $width;
+ $darkRatio = $numDarkCells / $numTotalCells;
+ $fixedPercentVariances = (int) (abs($darkRatio - 0.5) * 20);
+
+ return $fixedPercentVariances * self::N4;
+ }
+
+ /**
+ * Returns the mask bit for "getMaskPattern" at "x" and "y".
+ *
+ * See 8.8 of JISX0510:2004 for mask pattern conditions.
+ *
+ * @throws InvalidArgumentException if an invalid mask pattern was supplied
+ */
+ public static function getDataMaskBit(int $maskPattern, int $x, int $y) : bool
+ {
+ switch ($maskPattern) {
+ case 0:
+ $intermediate = ($y + $x) & 0x1;
+ break;
+
+ case 1:
+ $intermediate = $y & 0x1;
+ break;
+
+ case 2:
+ $intermediate = $x % 3;
+ break;
+
+ case 3:
+ $intermediate = ($y + $x) % 3;
+ break;
+
+ case 4:
+ $intermediate = (BitUtils::unsignedRightShift($y, 1) + (int) ($x / 3)) & 0x1;
+ break;
+
+ case 5:
+ $temp = $y * $x;
+ $intermediate = ($temp & 0x1) + ($temp % 3);
+ break;
+
+ case 6:
+ $temp = $y * $x;
+ $intermediate = (($temp & 0x1) + ($temp % 3)) & 0x1;
+ break;
+
+ case 7:
+ $temp = $y * $x;
+ $intermediate = (($temp % 3) + (($y + $x) & 0x1)) & 0x1;
+ break;
+
+ default:
+ throw new InvalidArgumentException('Invalid mask pattern: ' . $maskPattern);
+ }
+
+ return 0 == $intermediate;
+ }
+
+ /**
+ * Helper function for applyMaskPenaltyRule1.
+ *
+ * We need this for doing this calculation in both vertical and horizontal
+ * orders respectively.
+ */
+ private static function applyMaskPenaltyRule1Internal(ByteMatrix $matrix, bool $isHorizontal) : int
+ {
+ $penalty = 0;
+ $iLimit = $isHorizontal ? $matrix->getHeight() : $matrix->getWidth();
+ $jLimit = $isHorizontal ? $matrix->getWidth() : $matrix->getHeight();
+ $array = $matrix->getArray();
+
+ for ($i = 0; $i < $iLimit; ++$i) {
+ $numSameBitCells = 0;
+ $prevBit = -1;
+
+ for ($j = 0; $j < $jLimit; $j++) {
+ $bit = $isHorizontal ? $array[$i][$j] : $array[$j][$i];
+
+ if ($bit === $prevBit) {
+ ++$numSameBitCells;
+ } else {
+ if ($numSameBitCells >= 5) {
+ $penalty += self::N1 + ($numSameBitCells - 5);
+ }
+
+ $numSameBitCells = 1;
+ $prevBit = $bit;
+ }
+ }
+
+ if ($numSameBitCells >= 5) {
+ $penalty += self::N1 + ($numSameBitCells - 5);
+ }
+ }
+
+ return $penalty;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/MatrixUtil.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/MatrixUtil.php
new file mode 100644
index 0000000..0967e29
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/MatrixUtil.php
@@ -0,0 +1,513 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Encoder;
+
+use BaconQrCode\Common\BitArray;
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\Version;
+use BaconQrCode\Exception\RuntimeException;
+use BaconQrCode\Exception\WriterException;
+
+/**
+ * Matrix utility.
+ */
+final class MatrixUtil
+{
+ /**
+ * Position detection pattern.
+ */
+ private const POSITION_DETECTION_PATTERN = [
+ [1, 1, 1, 1, 1, 1, 1],
+ [1, 0, 0, 0, 0, 0, 1],
+ [1, 0, 1, 1, 1, 0, 1],
+ [1, 0, 1, 1, 1, 0, 1],
+ [1, 0, 1, 1, 1, 0, 1],
+ [1, 0, 0, 0, 0, 0, 1],
+ [1, 1, 1, 1, 1, 1, 1],
+ ];
+
+ /**
+ * Position adjustment pattern.
+ */
+ private const POSITION_ADJUSTMENT_PATTERN = [
+ [1, 1, 1, 1, 1],
+ [1, 0, 0, 0, 1],
+ [1, 0, 1, 0, 1],
+ [1, 0, 0, 0, 1],
+ [1, 1, 1, 1, 1],
+ ];
+
+ /**
+ * Coordinates for position adjustment patterns for each version.
+ */
+ private const POSITION_ADJUSTMENT_PATTERN_COORDINATE_TABLE = [
+ [null, null, null, null, null, null, null], // Version 1
+ [ 6, 18, null, null, null, null, null], // Version 2
+ [ 6, 22, null, null, null, null, null], // Version 3
+ [ 6, 26, null, null, null, null, null], // Version 4
+ [ 6, 30, null, null, null, null, null], // Version 5
+ [ 6, 34, null, null, null, null, null], // Version 6
+ [ 6, 22, 38, null, null, null, null], // Version 7
+ [ 6, 24, 42, null, null, null, null], // Version 8
+ [ 6, 26, 46, null, null, null, null], // Version 9
+ [ 6, 28, 50, null, null, null, null], // Version 10
+ [ 6, 30, 54, null, null, null, null], // Version 11
+ [ 6, 32, 58, null, null, null, null], // Version 12
+ [ 6, 34, 62, null, null, null, null], // Version 13
+ [ 6, 26, 46, 66, null, null, null], // Version 14
+ [ 6, 26, 48, 70, null, null, null], // Version 15
+ [ 6, 26, 50, 74, null, null, null], // Version 16
+ [ 6, 30, 54, 78, null, null, null], // Version 17
+ [ 6, 30, 56, 82, null, null, null], // Version 18
+ [ 6, 30, 58, 86, null, null, null], // Version 19
+ [ 6, 34, 62, 90, null, null, null], // Version 20
+ [ 6, 28, 50, 72, 94, null, null], // Version 21
+ [ 6, 26, 50, 74, 98, null, null], // Version 22
+ [ 6, 30, 54, 78, 102, null, null], // Version 23
+ [ 6, 28, 54, 80, 106, null, null], // Version 24
+ [ 6, 32, 58, 84, 110, null, null], // Version 25
+ [ 6, 30, 58, 86, 114, null, null], // Version 26
+ [ 6, 34, 62, 90, 118, null, null], // Version 27
+ [ 6, 26, 50, 74, 98, 122, null], // Version 28
+ [ 6, 30, 54, 78, 102, 126, null], // Version 29
+ [ 6, 26, 52, 78, 104, 130, null], // Version 30
+ [ 6, 30, 56, 82, 108, 134, null], // Version 31
+ [ 6, 34, 60, 86, 112, 138, null], // Version 32
+ [ 6, 30, 58, 86, 114, 142, null], // Version 33
+ [ 6, 34, 62, 90, 118, 146, null], // Version 34
+ [ 6, 30, 54, 78, 102, 126, 150], // Version 35
+ [ 6, 24, 50, 76, 102, 128, 154], // Version 36
+ [ 6, 28, 54, 80, 106, 132, 158], // Version 37
+ [ 6, 32, 58, 84, 110, 136, 162], // Version 38
+ [ 6, 26, 54, 82, 110, 138, 166], // Version 39
+ [ 6, 30, 58, 86, 114, 142, 170], // Version 40
+ ];
+
+ /**
+ * Type information coordinates.
+ */
+ private const TYPE_INFO_COORDINATES = [
+ [8, 0],
+ [8, 1],
+ [8, 2],
+ [8, 3],
+ [8, 4],
+ [8, 5],
+ [8, 7],
+ [8, 8],
+ [7, 8],
+ [5, 8],
+ [4, 8],
+ [3, 8],
+ [2, 8],
+ [1, 8],
+ [0, 8],
+ ];
+
+ /**
+ * Version information polynomial.
+ */
+ private const VERSION_INFO_POLY = 0x1f25;
+
+ /**
+ * Type information polynomial.
+ */
+ private const TYPE_INFO_POLY = 0x537;
+
+ /**
+ * Type information mask pattern.
+ */
+ private const TYPE_INFO_MASK_PATTERN = 0x5412;
+
+ /**
+ * Clears a given matrix.
+ */
+ public static function clearMatrix(ByteMatrix $matrix) : void
+ {
+ $matrix->clear(-1);
+ }
+
+ /**
+ * Builds a complete matrix.
+ */
+ public static function buildMatrix(
+ BitArray $dataBits,
+ ErrorCorrectionLevel $level,
+ Version $version,
+ int $maskPattern,
+ ByteMatrix $matrix
+ ) : void {
+ self::clearMatrix($matrix);
+ self::embedBasicPatterns($version, $matrix);
+ self::embedTypeInfo($level, $maskPattern, $matrix);
+ self::maybeEmbedVersionInfo($version, $matrix);
+ self::embedDataBits($dataBits, $maskPattern, $matrix);
+ }
+
+ /**
+ * Removes the position detection patterns from a matrix.
+ *
+ * This can be useful if you need to render those patterns separately.
+ */
+ public static function removePositionDetectionPatterns(ByteMatrix $matrix) : void
+ {
+ $pdpWidth = count(self::POSITION_DETECTION_PATTERN[0]);
+
+ self::removePositionDetectionPattern(0, 0, $matrix);
+ self::removePositionDetectionPattern($matrix->getWidth() - $pdpWidth, 0, $matrix);
+ self::removePositionDetectionPattern(0, $matrix->getWidth() - $pdpWidth, $matrix);
+ }
+
+ /**
+ * Embeds type information into a matrix.
+ */
+ private static function embedTypeInfo(ErrorCorrectionLevel $level, int $maskPattern, ByteMatrix $matrix) : void
+ {
+ $typeInfoBits = new BitArray();
+ self::makeTypeInfoBits($level, $maskPattern, $typeInfoBits);
+
+ $typeInfoBitsSize = $typeInfoBits->getSize();
+
+ for ($i = 0; $i < $typeInfoBitsSize; ++$i) {
+ $bit = $typeInfoBits->get($typeInfoBitsSize - 1 - $i);
+
+ $x1 = self::TYPE_INFO_COORDINATES[$i][0];
+ $y1 = self::TYPE_INFO_COORDINATES[$i][1];
+
+ $matrix->set($x1, $y1, (int) $bit);
+
+ if ($i < 8) {
+ $x2 = $matrix->getWidth() - $i - 1;
+ $y2 = 8;
+ } else {
+ $x2 = 8;
+ $y2 = $matrix->getHeight() - 7 + ($i - 8);
+ }
+
+ $matrix->set($x2, $y2, (int) $bit);
+ }
+ }
+
+ /**
+ * Generates type information bits and appends them to a bit array.
+ *
+ * @throws RuntimeException if bit array resulted in invalid size
+ */
+ private static function makeTypeInfoBits(ErrorCorrectionLevel $level, int $maskPattern, BitArray $bits) : void
+ {
+ $typeInfo = ($level->getBits() << 3) | $maskPattern;
+ $bits->appendBits($typeInfo, 5);
+
+ $bchCode = self::calculateBchCode($typeInfo, self::TYPE_INFO_POLY);
+ $bits->appendBits($bchCode, 10);
+
+ $maskBits = new BitArray();
+ $maskBits->appendBits(self::TYPE_INFO_MASK_PATTERN, 15);
+ $bits->xorBits($maskBits);
+
+ if (15 !== $bits->getSize()) {
+ throw new RuntimeException('Bit array resulted in invalid size: ' . $bits->getSize());
+ }
+ }
+
+ /**
+ * Embeds version information if required.
+ */
+ private static function maybeEmbedVersionInfo(Version $version, ByteMatrix $matrix) : void
+ {
+ if ($version->getVersionNumber() < 7) {
+ return;
+ }
+
+ $versionInfoBits = new BitArray();
+ self::makeVersionInfoBits($version, $versionInfoBits);
+
+ $bitIndex = 6 * 3 - 1;
+
+ for ($i = 0; $i < 6; ++$i) {
+ for ($j = 0; $j < 3; ++$j) {
+ $bit = $versionInfoBits->get($bitIndex);
+ --$bitIndex;
+
+ $matrix->set($i, $matrix->getHeight() - 11 + $j, (int) $bit);
+ $matrix->set($matrix->getHeight() - 11 + $j, $i, (int) $bit);
+ }
+ }
+ }
+
+ /**
+ * Generates version information bits and appends them to a bit array.
+ *
+ * @throws RuntimeException if bit array resulted in invalid size
+ */
+ private static function makeVersionInfoBits(Version $version, BitArray $bits) : void
+ {
+ $bits->appendBits($version->getVersionNumber(), 6);
+
+ $bchCode = self::calculateBchCode($version->getVersionNumber(), self::VERSION_INFO_POLY);
+ $bits->appendBits($bchCode, 12);
+
+ if (18 !== $bits->getSize()) {
+ throw new RuntimeException('Bit array resulted in invalid size: ' . $bits->getSize());
+ }
+ }
+
+ /**
+ * Calculates the BCH code for a value and a polynomial.
+ */
+ private static function calculateBchCode(int $value, int $poly) : int
+ {
+ $msbSetInPoly = self::findMsbSet($poly);
+ $value <<= $msbSetInPoly - 1;
+
+ while (self::findMsbSet($value) >= $msbSetInPoly) {
+ $value ^= $poly << (self::findMsbSet($value) - $msbSetInPoly);
+ }
+
+ return $value;
+ }
+
+ /**
+ * Finds and MSB set.
+ */
+ private static function findMsbSet(int $value) : int
+ {
+ $numDigits = 0;
+
+ while (0 !== $value) {
+ $value >>= 1;
+ ++$numDigits;
+ }
+
+ return $numDigits;
+ }
+
+ /**
+ * Embeds basic patterns into a matrix.
+ */
+ private static function embedBasicPatterns(Version $version, ByteMatrix $matrix) : void
+ {
+ self::embedPositionDetectionPatternsAndSeparators($matrix);
+ self::embedDarkDotAtLeftBottomCorner($matrix);
+ self::maybeEmbedPositionAdjustmentPatterns($version, $matrix);
+ self::embedTimingPatterns($matrix);
+ }
+
+ /**
+ * Embeds position detection patterns and separators into a byte matrix.
+ */
+ private static function embedPositionDetectionPatternsAndSeparators(ByteMatrix $matrix) : void
+ {
+ $pdpWidth = count(self::POSITION_DETECTION_PATTERN[0]);
+
+ self::embedPositionDetectionPattern(0, 0, $matrix);
+ self::embedPositionDetectionPattern($matrix->getWidth() - $pdpWidth, 0, $matrix);
+ self::embedPositionDetectionPattern(0, $matrix->getWidth() - $pdpWidth, $matrix);
+
+ $hspWidth = 8;
+
+ self::embedHorizontalSeparationPattern(0, $hspWidth - 1, $matrix);
+ self::embedHorizontalSeparationPattern($matrix->getWidth() - $hspWidth, $hspWidth - 1, $matrix);
+ self::embedHorizontalSeparationPattern(0, $matrix->getWidth() - $hspWidth, $matrix);
+
+ $vspSize = 7;
+
+ self::embedVerticalSeparationPattern($vspSize, 0, $matrix);
+ self::embedVerticalSeparationPattern($matrix->getHeight() - $vspSize - 1, 0, $matrix);
+ self::embedVerticalSeparationPattern($vspSize, $matrix->getHeight() - $vspSize, $matrix);
+ }
+
+ /**
+ * Embeds a single position detection pattern into a byte matrix.
+ */
+ private static function embedPositionDetectionPattern(int $xStart, int $yStart, ByteMatrix $matrix) : void
+ {
+ for ($y = 0; $y < 7; ++$y) {
+ for ($x = 0; $x < 7; ++$x) {
+ $matrix->set($xStart + $x, $yStart + $y, self::POSITION_DETECTION_PATTERN[$y][$x]);
+ }
+ }
+ }
+
+ private static function removePositionDetectionPattern(int $xStart, int $yStart, ByteMatrix $matrix) : void
+ {
+ for ($y = 0; $y < 7; ++$y) {
+ for ($x = 0; $x < 7; ++$x) {
+ $matrix->set($xStart + $x, $yStart + $y, 0);
+ }
+ }
+ }
+
+ /**
+ * Embeds a single horizontal separation pattern.
+ *
+ * @throws RuntimeException if a byte was already set
+ */
+ private static function embedHorizontalSeparationPattern(int $xStart, int $yStart, ByteMatrix $matrix) : void
+ {
+ for ($x = 0; $x < 8; $x++) {
+ if (-1 !== $matrix->get($xStart + $x, $yStart)) {
+ throw new RuntimeException('Byte already set');
+ }
+
+ $matrix->set($xStart + $x, $yStart, 0);
+ }
+ }
+
+ /**
+ * Embeds a single vertical separation pattern.
+ *
+ * @throws RuntimeException if a byte was already set
+ */
+ private static function embedVerticalSeparationPattern(int $xStart, int $yStart, ByteMatrix $matrix) : void
+ {
+ for ($y = 0; $y < 7; $y++) {
+ if (-1 !== $matrix->get($xStart, $yStart + $y)) {
+ throw new RuntimeException('Byte already set');
+ }
+
+ $matrix->set($xStart, $yStart + $y, 0);
+ }
+ }
+
+ /**
+ * Embeds a dot at the left bottom corner.
+ *
+ * @throws RuntimeException if a byte was already set to 0
+ */
+ private static function embedDarkDotAtLeftBottomCorner(ByteMatrix $matrix) : void
+ {
+ if (0 === $matrix->get(8, $matrix->getHeight() - 8)) {
+ throw new RuntimeException('Byte already set to 0');
+ }
+
+ $matrix->set(8, $matrix->getHeight() - 8, 1);
+ }
+
+ /**
+ * Embeds position adjustment patterns if required.
+ */
+ private static function maybeEmbedPositionAdjustmentPatterns(Version $version, ByteMatrix $matrix) : void
+ {
+ if ($version->getVersionNumber() < 2) {
+ return;
+ }
+
+ $index = $version->getVersionNumber() - 1;
+
+ $coordinates = self::POSITION_ADJUSTMENT_PATTERN_COORDINATE_TABLE[$index];
+ $numCoordinates = count($coordinates);
+
+ for ($i = 0; $i < $numCoordinates; ++$i) {
+ for ($j = 0; $j < $numCoordinates; ++$j) {
+ $y = $coordinates[$i];
+ $x = $coordinates[$j];
+
+ if (null === $x || null === $y) {
+ continue;
+ }
+
+ if (-1 === $matrix->get($x, $y)) {
+ self::embedPositionAdjustmentPattern($x - 2, $y - 2, $matrix);
+ }
+ }
+ }
+ }
+
+ /**
+ * Embeds a single position adjustment pattern.
+ */
+ private static function embedPositionAdjustmentPattern(int $xStart, int $yStart, ByteMatrix $matrix) : void
+ {
+ for ($y = 0; $y < 5; $y++) {
+ for ($x = 0; $x < 5; $x++) {
+ $matrix->set($xStart + $x, $yStart + $y, self::POSITION_ADJUSTMENT_PATTERN[$y][$x]);
+ }
+ }
+ }
+
+ /**
+ * Embeds timing patterns into a matrix.
+ */
+ private static function embedTimingPatterns(ByteMatrix $matrix) : void
+ {
+ $matrixWidth = $matrix->getWidth();
+
+ for ($i = 8; $i < $matrixWidth - 8; ++$i) {
+ $bit = ($i + 1) % 2;
+
+ if (-1 === $matrix->get($i, 6)) {
+ $matrix->set($i, 6, $bit);
+ }
+
+ if (-1 === $matrix->get(6, $i)) {
+ $matrix->set(6, $i, $bit);
+ }
+ }
+ }
+
+ /**
+ * Embeds "dataBits" using "getMaskPattern".
+ *
+ * For debugging purposes, it skips masking process if "getMaskPattern" is -1. See 8.7 of JISX0510:2004 (p.38) for
+ * how to embed data bits.
+ *
+ * @throws WriterException if not all bits could be consumed
+ */
+ private static function embedDataBits(BitArray $dataBits, int $maskPattern, ByteMatrix $matrix) : void
+ {
+ $bitIndex = 0;
+ $direction = -1;
+
+ // Start from the right bottom cell.
+ $x = $matrix->getWidth() - 1;
+ $y = $matrix->getHeight() - 1;
+
+ while ($x > 0) {
+ // Skip vertical timing pattern.
+ if (6 === $x) {
+ --$x;
+ }
+
+ while ($y >= 0 && $y < $matrix->getHeight()) {
+ for ($i = 0; $i < 2; $i++) {
+ $xx = $x - $i;
+
+ // Skip the cell if it's not empty.
+ if (-1 !== $matrix->get($xx, $y)) {
+ continue;
+ }
+
+ if ($bitIndex < $dataBits->getSize()) {
+ $bit = $dataBits->get($bitIndex);
+ ++$bitIndex;
+ } else {
+ // Padding bit. If there is no bit left, we'll fill the
+ // left cells with 0, as described in 8.4.9 of
+ // JISX0510:2004 (p. 24).
+ $bit = false;
+ }
+
+ // Skip masking if maskPattern is -1.
+ if (-1 !== $maskPattern && MaskUtil::getDataMaskBit($maskPattern, $xx, $y)) {
+ $bit = ! $bit;
+ }
+
+ $matrix->set($xx, $y, (int) $bit);
+ }
+
+ $y += $direction;
+ }
+
+ $direction = -$direction;
+ $y += $direction;
+ $x -= 2;
+ }
+
+ // All bits should be consumed
+ if ($dataBits->getSize() !== $bitIndex) {
+ throw new WriterException('Not all bits consumed (' . $bitIndex . ' out of ' . $dataBits->getSize() .')');
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/QrCode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/QrCode.php
new file mode 100644
index 0000000..f568e88
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Encoder/QrCode.php
@@ -0,0 +1,141 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Encoder;
+
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\Mode;
+use BaconQrCode\Common\Version;
+
+/**
+ * QR code.
+ */
+final class QrCode
+{
+ /**
+ * Number of possible mask patterns.
+ */
+ public const NUM_MASK_PATTERNS = 8;
+
+ /**
+ * Mode of the QR code.
+ *
+ * @var Mode
+ */
+ private $mode;
+
+ /**
+ * EC level of the QR code.
+ *
+ * @var ErrorCorrectionLevel
+ */
+ private $errorCorrectionLevel;
+
+ /**
+ * Version of the QR code.
+ *
+ * @var Version
+ */
+ private $version;
+
+ /**
+ * Mask pattern of the QR code.
+ *
+ * @var int
+ */
+ private $maskPattern = -1;
+
+ /**
+ * Matrix of the QR code.
+ *
+ * @var ByteMatrix
+ */
+ private $matrix;
+
+ public function __construct(
+ Mode $mode,
+ ErrorCorrectionLevel $errorCorrectionLevel,
+ Version $version,
+ int $maskPattern,
+ ByteMatrix $matrix
+ ) {
+ $this->mode = $mode;
+ $this->errorCorrectionLevel = $errorCorrectionLevel;
+ $this->version = $version;
+ $this->maskPattern = $maskPattern;
+ $this->matrix = $matrix;
+ }
+
+ /**
+ * Gets the mode.
+ */
+ public function getMode() : Mode
+ {
+ return $this->mode;
+ }
+
+ /**
+ * Gets the EC level.
+ */
+ public function getErrorCorrectionLevel() : ErrorCorrectionLevel
+ {
+ return $this->errorCorrectionLevel;
+ }
+
+ /**
+ * Gets the version.
+ */
+ public function getVersion() : Version
+ {
+ return $this->version;
+ }
+
+ /**
+ * Gets the mask pattern.
+ */
+ public function getMaskPattern() : int
+ {
+ return $this->maskPattern;
+ }
+
+ /**
+ * Gets the matrix.
+ *
+ * @return ByteMatrix
+ */
+ public function getMatrix()
+ {
+ return $this->matrix;
+ }
+
+ /**
+ * Validates whether a mask pattern is valid.
+ */
+ public static function isValidMaskPattern(int $maskPattern) : bool
+ {
+ return $maskPattern > 0 && $maskPattern < self::NUM_MASK_PATTERNS;
+ }
+
+ /**
+ * Returns a string representation of the QR code.
+ */
+ public function __toString() : string
+ {
+ $result = "<<\n"
+ . ' mode: ' . $this->mode . "\n"
+ . ' ecLevel: ' . $this->errorCorrectionLevel . "\n"
+ . ' version: ' . $this->version . "\n"
+ . ' maskPattern: ' . $this->maskPattern . "\n";
+
+ if ($this->matrix === null) {
+ $result .= " matrix: null\n";
+ } else {
+ $result .= " matrix:\n";
+ $result .= $this->matrix;
+ }
+
+ $result .= ">>\n";
+
+ return $result;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/ExceptionInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/ExceptionInterface.php
new file mode 100644
index 0000000..6f70c20
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/ExceptionInterface.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Exception;
+
+use Throwable;
+
+interface ExceptionInterface extends Throwable
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/InvalidArgumentException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/InvalidArgumentException.php
new file mode 100644
index 0000000..0ec4249
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/InvalidArgumentException.php
@@ -0,0 +1,8 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Exception;
+
+final class InvalidArgumentException extends \InvalidArgumentException implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/OutOfBoundsException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/OutOfBoundsException.php
new file mode 100644
index 0000000..79e53af
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/OutOfBoundsException.php
@@ -0,0 +1,8 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Exception;
+
+final class OutOfBoundsException extends \OutOfBoundsException implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/RuntimeException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/RuntimeException.php
new file mode 100644
index 0000000..1e7fcc8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/RuntimeException.php
@@ -0,0 +1,8 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Exception;
+
+final class RuntimeException extends \RuntimeException implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/UnexpectedValueException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/UnexpectedValueException.php
new file mode 100644
index 0000000..24edcb8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/UnexpectedValueException.php
@@ -0,0 +1,8 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Exception;
+
+final class UnexpectedValueException extends \UnexpectedValueException implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/WriterException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/WriterException.php
new file mode 100644
index 0000000..4cb2f2e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Exception/WriterException.php
@@ -0,0 +1,8 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Exception;
+
+final class WriterException extends \RuntimeException implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Alpha.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Alpha.php
new file mode 100644
index 0000000..3490252
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Alpha.php
@@ -0,0 +1,57 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Color;
+
+use BaconQrCode\Exception;
+
+final class Alpha implements ColorInterface
+{
+ /**
+ * @var int
+ */
+ private $alpha;
+
+ /**
+ * @var ColorInterface
+ */
+ private $baseColor;
+
+ /**
+ * @param int $alpha the alpha value, 0 to 100
+ */
+ public function __construct(int $alpha, ColorInterface $baseColor)
+ {
+ if ($alpha < 0 || $alpha > 100) {
+ throw new Exception\InvalidArgumentException('Alpha must be between 0 and 100');
+ }
+
+ $this->alpha = $alpha;
+ $this->baseColor = $baseColor;
+ }
+
+ public function getAlpha() : int
+ {
+ return $this->alpha;
+ }
+
+ public function getBaseColor() : ColorInterface
+ {
+ return $this->baseColor;
+ }
+
+ public function toRgb() : Rgb
+ {
+ return $this->baseColor->toRgb();
+ }
+
+ public function toCmyk() : Cmyk
+ {
+ return $this->baseColor->toCmyk();
+ }
+
+ public function toGray() : Gray
+ {
+ return $this->baseColor->toGray();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Cmyk.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Cmyk.php
new file mode 100644
index 0000000..d6de390
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Cmyk.php
@@ -0,0 +1,103 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Color;
+
+use BaconQrCode\Exception;
+
+final class Cmyk implements ColorInterface
+{
+ /**
+ * @var int
+ */
+ private $cyan;
+
+ /**
+ * @var int
+ */
+ private $magenta;
+
+ /**
+ * @var int
+ */
+ private $yellow;
+
+ /**
+ * @var int
+ */
+ private $black;
+
+ /**
+ * @param int $cyan the cyan amount, 0 to 100
+ * @param int $magenta the magenta amount, 0 to 100
+ * @param int $yellow the yellow amount, 0 to 100
+ * @param int $black the black amount, 0 to 100
+ */
+ public function __construct(int $cyan, int $magenta, int $yellow, int $black)
+ {
+ if ($cyan < 0 || $cyan > 100) {
+ throw new Exception\InvalidArgumentException('Cyan must be between 0 and 100');
+ }
+
+ if ($magenta < 0 || $magenta > 100) {
+ throw new Exception\InvalidArgumentException('Magenta must be between 0 and 100');
+ }
+
+ if ($yellow < 0 || $yellow > 100) {
+ throw new Exception\InvalidArgumentException('Yellow must be between 0 and 100');
+ }
+
+ if ($black < 0 || $black > 100) {
+ throw new Exception\InvalidArgumentException('Black must be between 0 and 100');
+ }
+
+ $this->cyan = $cyan;
+ $this->magenta = $magenta;
+ $this->yellow = $yellow;
+ $this->black = $black;
+ }
+
+ public function getCyan() : int
+ {
+ return $this->cyan;
+ }
+
+ public function getMagenta() : int
+ {
+ return $this->magenta;
+ }
+
+ public function getYellow() : int
+ {
+ return $this->yellow;
+ }
+
+ public function getBlack() : int
+ {
+ return $this->black;
+ }
+
+ public function toRgb() : Rgb
+ {
+ $k = $this->black / 100;
+ $c = (-$k * $this->cyan + $k * 100 + $this->cyan) / 100;
+ $m = (-$k * $this->magenta + $k * 100 + $this->magenta) / 100;
+ $y = (-$k * $this->yellow + $k * 100 + $this->yellow) / 100;
+
+ return new Rgb(
+ (int) (-$c * 255 + 255),
+ (int) (-$m * 255 + 255),
+ (int) (-$y * 255 + 255)
+ );
+ }
+
+ public function toCmyk() : Cmyk
+ {
+ return $this;
+ }
+
+ public function toGray() : Gray
+ {
+ return $this->toRgb()->toGray();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/ColorInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/ColorInterface.php
new file mode 100644
index 0000000..b50d1ca
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/ColorInterface.php
@@ -0,0 +1,22 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Color;
+
+interface ColorInterface
+{
+ /**
+ * Converts the color to RGB.
+ */
+ public function toRgb() : Rgb;
+
+ /**
+ * Converts the color to CMYK.
+ */
+ public function toCmyk() : Cmyk;
+
+ /**
+ * Converts the color to gray.
+ */
+ public function toGray() : Gray;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Gray.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Gray.php
new file mode 100644
index 0000000..acb986d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Gray.php
@@ -0,0 +1,46 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Color;
+
+use BaconQrCode\Exception;
+
+final class Gray implements ColorInterface
+{
+ /**
+ * @var int
+ */
+ private $gray;
+
+ /**
+ * @param int $gray the gray value between 0 (black) and 100 (white)
+ */
+ public function __construct(int $gray)
+ {
+ if ($gray < 0 || $gray > 100) {
+ throw new Exception\InvalidArgumentException('Gray must be between 0 and 100');
+ }
+
+ $this->gray = (int) $gray;
+ }
+
+ public function getGray() : int
+ {
+ return $this->gray;
+ }
+
+ public function toRgb() : Rgb
+ {
+ return new Rgb((int) ($this->gray * 2.55), (int) ($this->gray * 2.55), (int) ($this->gray * 2.55));
+ }
+
+ public function toCmyk() : Cmyk
+ {
+ return new Cmyk(0, 0, 0, 100 - $this->gray);
+ }
+
+ public function toGray() : Gray
+ {
+ return $this;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Rgb.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Rgb.php
new file mode 100644
index 0000000..7935406
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Color/Rgb.php
@@ -0,0 +1,88 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Color;
+
+use BaconQrCode\Exception;
+
+final class Rgb implements ColorInterface
+{
+ /**
+ * @var int
+ */
+ private $red;
+
+ /**
+ * @var int
+ */
+ private $green;
+
+ /**
+ * @var int
+ */
+ private $blue;
+
+ /**
+ * @param int $red the red amount of the color, 0 to 255
+ * @param int $green the green amount of the color, 0 to 255
+ * @param int $blue the blue amount of the color, 0 to 255
+ */
+ public function __construct(int $red, int $green, int $blue)
+ {
+ if ($red < 0 || $red > 255) {
+ throw new Exception\InvalidArgumentException('Red must be between 0 and 255');
+ }
+
+ if ($green < 0 || $green > 255) {
+ throw new Exception\InvalidArgumentException('Green must be between 0 and 255');
+ }
+
+ if ($blue < 0 || $blue > 255) {
+ throw new Exception\InvalidArgumentException('Blue must be between 0 and 255');
+ }
+
+ $this->red = $red;
+ $this->green = $green;
+ $this->blue = $blue;
+ }
+
+ public function getRed() : int
+ {
+ return $this->red;
+ }
+
+ public function getGreen() : int
+ {
+ return $this->green;
+ }
+
+ public function getBlue() : int
+ {
+ return $this->blue;
+ }
+
+ public function toRgb() : Rgb
+ {
+ return $this;
+ }
+
+ public function toCmyk() : Cmyk
+ {
+ $c = 1 - ($this->red / 255);
+ $m = 1 - ($this->green / 255);
+ $y = 1 - ($this->blue / 255);
+ $k = min($c, $m, $y);
+
+ return new Cmyk(
+ (int) (100 * ($c - $k) / (1 - $k)),
+ (int) (100 * ($m - $k) / (1 - $k)),
+ (int) (100 * ($y - $k) / (1 - $k)),
+ (int) (100 * $k)
+ );
+ }
+
+ public function toGray() : Gray
+ {
+ return new Gray((int) (($this->red * 0.21 + $this->green * 0.71 + $this->blue * 0.07) / 2.55));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/CompositeEye.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/CompositeEye.php
new file mode 100644
index 0000000..0d03125
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/CompositeEye.php
@@ -0,0 +1,38 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Eye;
+
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Combines the style of two different eyes.
+ */
+final class CompositeEye implements EyeInterface
+{
+ /**
+ * @var EyeInterface
+ */
+ private $externalEye;
+
+ /**
+ * @var EyeInterface
+ */
+ private $internalEye;
+
+ public function __construct(EyeInterface $externalEye, EyeInterface $internalEye)
+ {
+ $this->externalEye = $externalEye;
+ $this->internalEye = $internalEye;
+ }
+
+ public function getExternalPath() : Path
+ {
+ return $this->externalEye->getExternalPath();
+ }
+
+ public function getInternalPath() : Path
+ {
+ return $this->internalEye->getInternalPath();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/EyeInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/EyeInterface.php
new file mode 100644
index 0000000..ab68f3c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/EyeInterface.php
@@ -0,0 +1,26 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Eye;
+
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Interface for describing the look of an eye.
+ */
+interface EyeInterface
+{
+ /**
+ * Returns the path of the external eye element.
+ *
+ * The path origin point (0, 0) must be anchored at the middle of the path.
+ */
+ public function getExternalPath() : Path;
+
+ /**
+ * Returns the path of the internal eye element.
+ *
+ * The path origin point (0, 0) must be anchored at the middle of the path.
+ */
+ public function getInternalPath() : Path;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/ModuleEye.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/ModuleEye.php
new file mode 100644
index 0000000..84f7d12
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/ModuleEye.php
@@ -0,0 +1,54 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Eye;
+
+use BaconQrCode\Encoder\ByteMatrix;
+use BaconQrCode\Renderer\Module\ModuleInterface;
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Renders an eye based on a module renderer.
+ */
+final class ModuleEye implements EyeInterface
+{
+ /**
+ * @var ModuleInterface
+ */
+ private $module;
+
+ public function __construct(ModuleInterface $module)
+ {
+ $this->module = $module;
+ }
+
+ public function getExternalPath() : Path
+ {
+ $matrix = new ByteMatrix(7, 7);
+
+ for ($x = 0; $x < 7; ++$x) {
+ $matrix->set($x, 0, 1);
+ $matrix->set($x, 6, 1);
+ }
+
+ for ($y = 1; $y < 6; ++$y) {
+ $matrix->set(0, $y, 1);
+ $matrix->set(6, $y, 1);
+ }
+
+ return $this->module->createPath($matrix)->translate(-3.5, -3.5);
+ }
+
+ public function getInternalPath() : Path
+ {
+ $matrix = new ByteMatrix(3, 3);
+
+ for ($x = 0; $x < 3; ++$x) {
+ for ($y = 0; $y < 3; ++$y) {
+ $matrix->set($x, $y, 1);
+ }
+ }
+
+ return $this->module->createPath($matrix)->translate(-1.5, -1.5);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/SimpleCircleEye.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/SimpleCircleEye.php
new file mode 100644
index 0000000..64d54ee
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/SimpleCircleEye.php
@@ -0,0 +1,54 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Eye;
+
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Renders the inner eye as a circle.
+ */
+final class SimpleCircleEye implements EyeInterface
+{
+ /**
+ * @var self|null
+ */
+ private static $instance;
+
+ private function __construct()
+ {
+ }
+
+ public static function instance() : self
+ {
+ return self::$instance ?: self::$instance = new self();
+ }
+
+ public function getExternalPath() : Path
+ {
+ return (new Path())
+ ->move(-3.5, -3.5)
+ ->line(3.5, -3.5)
+ ->line(3.5, 3.5)
+ ->line(-3.5, 3.5)
+ ->close()
+ ->move(-2.5, -2.5)
+ ->line(-2.5, 2.5)
+ ->line(2.5, 2.5)
+ ->line(2.5, -2.5)
+ ->close()
+ ;
+ }
+
+ public function getInternalPath() : Path
+ {
+ return (new Path())
+ ->move(1.5, 0)
+ ->ellipticArc(1.5, 1.5, 0., false, true, 0., 1.5)
+ ->ellipticArc(1.5, 1.5, 0., false, true, -1.5, 0.)
+ ->ellipticArc(1.5, 1.5, 0., false, true, 0., -1.5)
+ ->ellipticArc(1.5, 1.5, 0., false, true, 1.5, 0.)
+ ->close()
+ ;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/SquareEye.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/SquareEye.php
new file mode 100644
index 0000000..a3892b4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Eye/SquareEye.php
@@ -0,0 +1,53 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Eye;
+
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Renders the eyes in their default square shape.
+ */
+final class SquareEye implements EyeInterface
+{
+ /**
+ * @var self|null
+ */
+ private static $instance;
+
+ private function __construct()
+ {
+ }
+
+ public static function instance() : self
+ {
+ return self::$instance ?: self::$instance = new self();
+ }
+
+ public function getExternalPath() : Path
+ {
+ return (new Path())
+ ->move(-3.5, -3.5)
+ ->line(3.5, -3.5)
+ ->line(3.5, 3.5)
+ ->line(-3.5, 3.5)
+ ->close()
+ ->move(-2.5, -2.5)
+ ->line(-2.5, 2.5)
+ ->line(2.5, 2.5)
+ ->line(2.5, -2.5)
+ ->close()
+ ;
+ }
+
+ public function getInternalPath() : Path
+ {
+ return (new Path())
+ ->move(-1.5, -1.5)
+ ->line(1.5, -1.5)
+ ->line(1.5, 1.5)
+ ->line(-1.5, 1.5)
+ ->close()
+ ;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/EpsImageBackEnd.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/EpsImageBackEnd.php
new file mode 100644
index 0000000..b581b54
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/EpsImageBackEnd.php
@@ -0,0 +1,376 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Image;
+
+use BaconQrCode\Exception\RuntimeException;
+use BaconQrCode\Renderer\Color\Alpha;
+use BaconQrCode\Renderer\Color\Cmyk;
+use BaconQrCode\Renderer\Color\ColorInterface;
+use BaconQrCode\Renderer\Color\Gray;
+use BaconQrCode\Renderer\Color\Rgb;
+use BaconQrCode\Renderer\Path\Close;
+use BaconQrCode\Renderer\Path\Curve;
+use BaconQrCode\Renderer\Path\EllipticArc;
+use BaconQrCode\Renderer\Path\Line;
+use BaconQrCode\Renderer\Path\Move;
+use BaconQrCode\Renderer\Path\Path;
+use BaconQrCode\Renderer\RendererStyle\Gradient;
+use BaconQrCode\Renderer\RendererStyle\GradientType;
+
+final class EpsImageBackEnd implements ImageBackEndInterface
+{
+ private const PRECISION = 3;
+
+ /**
+ * @var string|null
+ */
+ private $eps;
+
+ public function new(int $size, ColorInterface $backgroundColor) : void
+ {
+ $this->eps = "%!PS-Adobe-3.0 EPSF-3.0\n"
+ . "%%Creator: BaconQrCode\n"
+ . sprintf("%%%%BoundingBox: 0 0 %d %d \n", $size, $size)
+ . "%%BeginProlog\n"
+ . "save\n"
+ . "50 dict begin\n"
+ . "/q { gsave } bind def\n"
+ . "/Q { grestore } bind def\n"
+ . "/s { scale } bind def\n"
+ . "/t { translate } bind def\n"
+ . "/r { rotate } bind def\n"
+ . "/n { newpath } bind def\n"
+ . "/m { moveto } bind def\n"
+ . "/l { lineto } bind def\n"
+ . "/c { curveto } bind def\n"
+ . "/z { closepath } bind def\n"
+ . "/f { eofill } bind def\n"
+ . "/rgb { setrgbcolor } bind def\n"
+ . "/cmyk { setcmykcolor } bind def\n"
+ . "/gray { setgray } bind def\n"
+ . "%%EndProlog\n"
+ . "1 -1 s\n"
+ . sprintf("0 -%d t\n", $size);
+
+ if ($backgroundColor instanceof Alpha && 0 === $backgroundColor->getAlpha()) {
+ return;
+ }
+
+ $this->eps .= wordwrap(
+ '0 0 m'
+ . sprintf(' %s 0 l', (string) $size)
+ . sprintf(' %s %s l', (string) $size, (string) $size)
+ . sprintf(' 0 %s l', (string) $size)
+ . ' z'
+ . ' ' .$this->getColorSetString($backgroundColor) . " f\n",
+ 75,
+ "\n "
+ );
+ }
+
+ public function scale(float $size) : void
+ {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->eps .= sprintf("%1\$s %1\$s s\n", round($size, self::PRECISION));
+ }
+
+ public function translate(float $x, float $y) : void
+ {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->eps .= sprintf("%s %s t\n", round($x, self::PRECISION), round($y, self::PRECISION));
+ }
+
+ public function rotate(int $degrees) : void
+ {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->eps .= sprintf("%d r\n", $degrees);
+ }
+
+ public function push() : void
+ {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->eps .= "q\n";
+ }
+
+ public function pop() : void
+ {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->eps .= "Q\n";
+ }
+
+ public function drawPathWithColor(Path $path, ColorInterface $color) : void
+ {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $fromX = 0;
+ $fromY = 0;
+ $this->eps .= wordwrap(
+ 'n '
+ . $this->drawPathOperations($path, $fromX, $fromY)
+ . ' ' . $this->getColorSetString($color) . " f\n",
+ 75,
+ "\n "
+ );
+ }
+
+ public function drawPathWithGradient(
+ Path $path,
+ Gradient $gradient,
+ float $x,
+ float $y,
+ float $width,
+ float $height
+ ) : void {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $fromX = 0;
+ $fromY = 0;
+ $this->eps .= wordwrap(
+ 'q n ' . $this->drawPathOperations($path, $fromX, $fromY) . "\n",
+ 75,
+ "\n "
+ );
+
+ $this->createGradientFill($gradient, $x, $y, $width, $height);
+ }
+
+ public function done() : string
+ {
+ if (null === $this->eps) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->eps .= "%%TRAILER\nend restore\n%%EOF";
+ $blob = $this->eps;
+ $this->eps = null;
+
+ return $blob;
+ }
+
+ private function drawPathOperations(Iterable $ops, &$fromX, &$fromY) : string
+ {
+ $pathData = [];
+
+ foreach ($ops as $op) {
+ switch (true) {
+ case $op instanceof Move:
+ $fromX = $toX = round($op->getX(), self::PRECISION);
+ $fromY = $toY = round($op->getY(), self::PRECISION);
+ $pathData[] = sprintf('%s %s m', $toX, $toY);
+ break;
+
+ case $op instanceof Line:
+ $fromX = $toX = round($op->getX(), self::PRECISION);
+ $fromY = $toY = round($op->getY(), self::PRECISION);
+ $pathData[] = sprintf('%s %s l', $toX, $toY);
+ break;
+
+ case $op instanceof EllipticArc:
+ $pathData[] = $this->drawPathOperations($op->toCurves($fromX, $fromY), $fromX, $fromY);
+ break;
+
+ case $op instanceof Curve:
+ $x1 = round($op->getX1(), self::PRECISION);
+ $y1 = round($op->getY1(), self::PRECISION);
+ $x2 = round($op->getX2(), self::PRECISION);
+ $y2 = round($op->getY2(), self::PRECISION);
+ $fromX = $x3 = round($op->getX3(), self::PRECISION);
+ $fromY = $y3 = round($op->getY3(), self::PRECISION);
+ $pathData[] = sprintf('%s %s %s %s %s %s c', $x1, $y1, $x2, $y2, $x3, $y3);
+ break;
+
+ case $op instanceof Close:
+ $pathData[] = 'z';
+ break;
+
+ default:
+ throw new RuntimeException('Unexpected draw operation: ' . get_class($op));
+ }
+ }
+
+ return implode(' ', $pathData);
+ }
+
+ private function createGradientFill(Gradient $gradient, float $x, float $y, float $width, float $height) : void
+ {
+ $startColor = $gradient->getStartColor();
+ $endColor = $gradient->getEndColor();
+
+ if ($startColor instanceof Alpha) {
+ $startColor = $startColor->getBaseColor();
+ }
+
+ $startColorType = get_class($startColor);
+
+ if (! in_array($startColorType, [Rgb::class, Cmyk::class, Gray::class])) {
+ $startColorType = Cmyk::class;
+ $startColor = $startColor->toCmyk();
+ }
+
+ if (get_class($endColor) !== $startColorType) {
+ switch ($startColorType) {
+ case Cmyk::class:
+ $endColor = $endColor->toCmyk();
+ break;
+
+ case Rgb::class:
+ $endColor = $endColor->toRgb();
+ break;
+
+ case Gray::class:
+ $endColor = $endColor->toGray();
+ break;
+ }
+ }
+
+ $this->eps .= "eoclip\n<<\n";
+
+ if ($gradient->getType() === GradientType::RADIAL()) {
+ $this->eps .= " /ShadingType 3\n";
+ } else {
+ $this->eps .= " /ShadingType 2\n";
+ }
+
+ $this->eps .= " /Extend [ true true ]\n"
+ . " /AntiAlias true\n";
+
+ switch ($startColorType) {
+ case Cmyk::class:
+ $this->eps .= " /ColorSpace /DeviceCMYK\n";
+ break;
+
+ case Rgb::class:
+ $this->eps .= " /ColorSpace /DeviceRGB\n";
+ break;
+
+ case Gray::class:
+ $this->eps .= " /ColorSpace /DeviceGray\n";
+ break;
+ }
+
+ switch ($gradient->getType()) {
+ case GradientType::HORIZONTAL():
+ $this->eps .= sprintf(
+ " /Coords [ %s %s %s %s ]\n",
+ round($x, self::PRECISION),
+ round($y, self::PRECISION),
+ round($x + $width, self::PRECISION),
+ round($y, self::PRECISION)
+ );
+ break;
+
+ case GradientType::VERTICAL():
+ $this->eps .= sprintf(
+ " /Coords [ %s %s %s %s ]\n",
+ round($x, self::PRECISION),
+ round($y, self::PRECISION),
+ round($x, self::PRECISION),
+ round($y + $height, self::PRECISION)
+ );
+ break;
+
+ case GradientType::DIAGONAL():
+ $this->eps .= sprintf(
+ " /Coords [ %s %s %s %s ]\n",
+ round($x, self::PRECISION),
+ round($y, self::PRECISION),
+ round($x + $width, self::PRECISION),
+ round($y + $height, self::PRECISION)
+ );
+ break;
+
+ case GradientType::INVERSE_DIAGONAL():
+ $this->eps .= sprintf(
+ " /Coords [ %s %s %s %s ]\n",
+ round($x, self::PRECISION),
+ round($y + $height, self::PRECISION),
+ round($x + $width, self::PRECISION),
+ round($y, self::PRECISION)
+ );
+ break;
+
+ case GradientType::RADIAL():
+ $centerX = ($x + $width) / 2;
+ $centerY = ($y + $height) / 2;
+
+ $this->eps .= sprintf(
+ " /Coords [ %s %s 0 %s %s %s ]\n",
+ round($centerX, self::PRECISION),
+ round($centerY, self::PRECISION),
+ round($centerX, self::PRECISION),
+ round($centerY, self::PRECISION),
+ round(max($width, $height) / 2, self::PRECISION)
+ );
+ break;
+ }
+
+ $this->eps .= " /Function\n"
+ . " <<\n"
+ . " /FunctionType 2\n"
+ . " /Domain [ 0 1 ]\n"
+ . sprintf(" /C0 [ %s ]\n", $this->getColorString($startColor))
+ . sprintf(" /C1 [ %s ]\n", $this->getColorString($endColor))
+ . " /N 1\n"
+ . " >>\n>>\nshfill\nQ\n";
+ }
+
+ private function getColorSetString(ColorInterface $color) : string
+ {
+ if ($color instanceof Rgb) {
+ return $this->getColorString($color) . ' rgb';
+ }
+
+ if ($color instanceof Cmyk) {
+ return $this->getColorString($color) . ' cmyk';
+ }
+
+ if ($color instanceof Gray) {
+ return $this->getColorString($color) . ' gray';
+ }
+
+ return $this->getColorSetString($color->toCmyk());
+ }
+
+ private function getColorString(ColorInterface $color) : string
+ {
+ if ($color instanceof Rgb) {
+ return sprintf('%s %s %s', $color->getRed() / 255, $color->getGreen() / 255, $color->getBlue() / 255);
+ }
+
+ if ($color instanceof Cmyk) {
+ return sprintf(
+ '%s %s %s %s',
+ $color->getCyan() / 100,
+ $color->getMagenta() / 100,
+ $color->getYellow() / 100,
+ $color->getBlack() / 100
+ );
+ }
+
+ if ($color instanceof Gray) {
+ return sprintf('%s', $color->getGray() / 100);
+ }
+
+ return $this->getColorString($color->toCmyk());
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/ImageBackEndInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/ImageBackEndInterface.php
new file mode 100644
index 0000000..0935819
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/ImageBackEndInterface.php
@@ -0,0 +1,87 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Image;
+
+use BaconQrCode\Exception\RuntimeException;
+use BaconQrCode\Renderer\Color\ColorInterface;
+use BaconQrCode\Renderer\Path\Path;
+use BaconQrCode\Renderer\RendererStyle\Gradient;
+
+/**
+ * Interface for back ends able to to produce path based images.
+ */
+interface ImageBackEndInterface
+{
+ /**
+ * Starts a new image.
+ *
+ * If a previous image was already started, previous data get erased.
+ */
+ public function new(int $size, ColorInterface $backgroundColor) : void;
+
+ /**
+ * Transforms all following drawing operation coordinates by scaling them by a given factor.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function scale(float $size) : void;
+
+ /**
+ * Transforms all following drawing operation coordinates by translating them by a given amount.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function translate(float $x, float $y) : void;
+
+ /**
+ * Transforms all following drawing operation coordinates by rotating them by a given amount.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function rotate(int $degrees) : void;
+
+ /**
+ * Pushes the current coordinate transformation onto a stack.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function push() : void;
+
+ /**
+ * Pops the last coordinate transformation from a stack.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function pop() : void;
+
+ /**
+ * Draws a path with a given color.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function drawPathWithColor(Path $path, ColorInterface $color) : void;
+
+ /**
+ * Draws a path with a given gradient which spans the box described by the position and size.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function drawPathWithGradient(
+ Path $path,
+ Gradient $gradient,
+ float $x,
+ float $y,
+ float $width,
+ float $height
+ ) : void;
+
+ /**
+ * Ends the image drawing operation and returns the resulting blob.
+ *
+ * This should reset the state of the back end and thus this method should only be callable once per image.
+ *
+ * @throws RuntimeException if no image was started yet.
+ */
+ public function done() : string;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/ImagickImageBackEnd.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/ImagickImageBackEnd.php
new file mode 100644
index 0000000..adec85e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/ImagickImageBackEnd.php
@@ -0,0 +1,336 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Image;
+
+use BaconQrCode\Exception\RuntimeException;
+use BaconQrCode\Renderer\Color\Alpha;
+use BaconQrCode\Renderer\Color\Cmyk;
+use BaconQrCode\Renderer\Color\ColorInterface;
+use BaconQrCode\Renderer\Color\Gray;
+use BaconQrCode\Renderer\Color\Rgb;
+use BaconQrCode\Renderer\Path\Close;
+use BaconQrCode\Renderer\Path\Curve;
+use BaconQrCode\Renderer\Path\EllipticArc;
+use BaconQrCode\Renderer\Path\Line;
+use BaconQrCode\Renderer\Path\Move;
+use BaconQrCode\Renderer\Path\Path;
+use BaconQrCode\Renderer\RendererStyle\Gradient;
+use BaconQrCode\Renderer\RendererStyle\GradientType;
+use Imagick;
+use ImagickDraw;
+use ImagickPixel;
+
+final class ImagickImageBackEnd implements ImageBackEndInterface
+{
+ /**
+ * @var string
+ */
+ private $imageFormat;
+
+ /**
+ * @var int
+ */
+ private $compressionQuality;
+
+ /**
+ * @var Imagick|null
+ */
+ private $image;
+
+ /**
+ * @var ImagickDraw|null
+ */
+ private $draw;
+
+ /**
+ * @var int|null
+ */
+ private $gradientCount;
+
+ /**
+ * @var TransformationMatrix[]|null
+ */
+ private $matrices;
+
+ /**
+ * @var int|null
+ */
+ private $matrixIndex;
+
+ public function __construct(string $imageFormat = 'png', int $compressionQuality = 100)
+ {
+ if (! class_exists(Imagick::class)) {
+ throw new RuntimeException('You need to install the imagick extension to use this back end');
+ }
+
+ $this->imageFormat = $imageFormat;
+ $this->compressionQuality = $compressionQuality;
+ }
+
+ public function new(int $size, ColorInterface $backgroundColor) : void
+ {
+ $this->image = new Imagick();
+ $this->image->newImage($size, $size, $this->getColorPixel($backgroundColor));
+ $this->image->setImageFormat($this->imageFormat);
+ $this->image->setCompressionQuality($this->compressionQuality);
+ $this->draw = new ImagickDraw();
+ $this->gradientCount = 0;
+ $this->matrices = [new TransformationMatrix()];
+ $this->matrixIndex = 0;
+ }
+
+ public function scale(float $size) : void
+ {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->draw->scale($size, $size);
+ $this->matrices[$this->matrixIndex] = $this->matrices[$this->matrixIndex]
+ ->multiply(TransformationMatrix::scale($size));
+ }
+
+ public function translate(float $x, float $y) : void
+ {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->draw->translate($x, $y);
+ $this->matrices[$this->matrixIndex] = $this->matrices[$this->matrixIndex]
+ ->multiply(TransformationMatrix::translate($x, $y));
+ }
+
+ public function rotate(int $degrees) : void
+ {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->draw->rotate($degrees);
+ $this->matrices[$this->matrixIndex] = $this->matrices[$this->matrixIndex]
+ ->multiply(TransformationMatrix::rotate($degrees));
+ }
+
+ public function push() : void
+ {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->draw->push();
+ $this->matrices[++$this->matrixIndex] = $this->matrices[$this->matrixIndex - 1];
+ }
+
+ public function pop() : void
+ {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->draw->pop();
+ unset($this->matrices[$this->matrixIndex--]);
+ }
+
+ public function drawPathWithColor(Path $path, ColorInterface $color) : void
+ {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->draw->setFillColor($this->getColorPixel($color));
+ $this->drawPath($path);
+ }
+
+ public function drawPathWithGradient(
+ Path $path,
+ Gradient $gradient,
+ float $x,
+ float $y,
+ float $width,
+ float $height
+ ) : void {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->draw->setFillPatternURL('#' . $this->createGradientFill($gradient, $x, $y, $width, $height));
+ $this->drawPath($path);
+ }
+
+ public function done() : string
+ {
+ if (null === $this->draw) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->image->drawImage($this->draw);
+ $blob = $this->image->getImageBlob();
+ $this->draw->clear();
+ $this->image->clear();
+ $this->draw = null;
+ $this->image = null;
+ $this->gradientCount = null;
+
+ return $blob;
+ }
+
+ private function drawPath(Path $path) : void
+ {
+ $this->draw->pathStart();
+
+ foreach ($path as $op) {
+ switch (true) {
+ case $op instanceof Move:
+ $this->draw->pathMoveToAbsolute($op->getX(), $op->getY());
+ break;
+
+ case $op instanceof Line:
+ $this->draw->pathLineToAbsolute($op->getX(), $op->getY());
+ break;
+
+ case $op instanceof EllipticArc:
+ $this->draw->pathEllipticArcAbsolute(
+ $op->getXRadius(),
+ $op->getYRadius(),
+ $op->getXAxisAngle(),
+ $op->isLargeArc(),
+ $op->isSweep(),
+ $op->getX(),
+ $op->getY()
+ );
+ break;
+
+ case $op instanceof Curve:
+ $this->draw->pathCurveToAbsolute(
+ $op->getX1(),
+ $op->getY1(),
+ $op->getX2(),
+ $op->getY2(),
+ $op->getX3(),
+ $op->getY3()
+ );
+ break;
+
+ case $op instanceof Close:
+ $this->draw->pathClose();
+ break;
+
+ default:
+ throw new RuntimeException('Unexpected draw operation: ' . get_class($op));
+ }
+ }
+
+ $this->draw->pathFinish();
+ }
+
+ private function createGradientFill(Gradient $gradient, float $x, float $y, float $width, float $height) : string
+ {
+ list($width, $height) = $this->matrices[$this->matrixIndex]->apply($width, $height);
+
+ $startColor = $this->getColorPixel($gradient->getStartColor())->getColorAsString();
+ $endColor = $this->getColorPixel($gradient->getEndColor())->getColorAsString();
+ $gradientImage = new Imagick();
+
+ switch ($gradient->getType()) {
+ case GradientType::HORIZONTAL():
+ $gradientImage->newPseudoImage((int) $height, (int) $width, sprintf(
+ 'gradient:%s-%s',
+ $startColor,
+ $endColor
+ ));
+ $gradientImage->rotateImage('transparent', -90);
+ break;
+
+ case GradientType::VERTICAL():
+ $gradientImage->newPseudoImage((int) $width, (int) $height, sprintf(
+ 'gradient:%s-%s',
+ $startColor,
+ $endColor
+ ));
+ break;
+
+ case GradientType::DIAGONAL():
+ case GradientType::INVERSE_DIAGONAL():
+ $gradientImage->newPseudoImage((int) ($width * sqrt(2)), (int) ($height * sqrt(2)), sprintf(
+ 'gradient:%s-%s',
+ $startColor,
+ $endColor
+ ));
+
+ if (GradientType::DIAGONAL() === $gradient->getType()) {
+ $gradientImage->rotateImage('transparent', -45);
+ } else {
+ $gradientImage->rotateImage('transparent', -135);
+ }
+
+ $rotatedWidth = $gradientImage->getImageWidth();
+ $rotatedHeight = $gradientImage->getImageHeight();
+
+ $gradientImage->setImagePage($rotatedWidth, $rotatedHeight, 0, 0);
+ $gradientImage->cropImage(
+ intdiv($rotatedWidth, 2) - 2,
+ intdiv($rotatedHeight, 2) - 2,
+ intdiv($rotatedWidth, 4) + 1,
+ intdiv($rotatedWidth, 4) + 1
+ );
+ break;
+
+ case GradientType::RADIAL():
+ $gradientImage->newPseudoImage((int) $width, (int) $height, sprintf(
+ 'radial-gradient:%s-%s',
+ $startColor,
+ $endColor
+ ));
+ break;
+ }
+
+ $id = sprintf('g%d', ++$this->gradientCount);
+ $this->draw->pushPattern($id, 0, 0, $width, $height);
+ $this->draw->composite(Imagick::COMPOSITE_COPY, 0, 0, $width, $height, $gradientImage);
+ $this->draw->popPattern();
+ return $id;
+ }
+
+ private function getColorPixel(ColorInterface $color) : ImagickPixel
+ {
+ $alpha = 100;
+
+ if ($color instanceof Alpha) {
+ $alpha = $color->getAlpha();
+ $color = $color->getBaseColor();
+ }
+
+ if ($color instanceof Rgb) {
+ return new ImagickPixel(sprintf(
+ 'rgba(%d, %d, %d, %F)',
+ $color->getRed(),
+ $color->getGreen(),
+ $color->getBlue(),
+ $alpha / 100
+ ));
+ }
+
+ if ($color instanceof Cmyk) {
+ return new ImagickPixel(sprintf(
+ 'cmyka(%d, %d, %d, %d, %F)',
+ $color->getCyan(),
+ $color->getMagenta(),
+ $color->getYellow(),
+ $color->getBlack(),
+ $alpha / 100
+ ));
+ }
+
+ if ($color instanceof Gray) {
+ return new ImagickPixel(sprintf(
+ 'graya(%d%%, %F)',
+ $color->getGray(),
+ $alpha / 100
+ ));
+ }
+
+ return $this->getColorPixel(new Alpha($alpha, $color->toRgb()));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/SvgImageBackEnd.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/SvgImageBackEnd.php
new file mode 100644
index 0000000..cb37a9f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/SvgImageBackEnd.php
@@ -0,0 +1,369 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Image;
+
+use BaconQrCode\Exception\RuntimeException;
+use BaconQrCode\Renderer\Color\Alpha;
+use BaconQrCode\Renderer\Color\ColorInterface;
+use BaconQrCode\Renderer\Path\Close;
+use BaconQrCode\Renderer\Path\Curve;
+use BaconQrCode\Renderer\Path\EllipticArc;
+use BaconQrCode\Renderer\Path\Line;
+use BaconQrCode\Renderer\Path\Move;
+use BaconQrCode\Renderer\Path\Path;
+use BaconQrCode\Renderer\RendererStyle\Gradient;
+use BaconQrCode\Renderer\RendererStyle\GradientType;
+use XMLWriter;
+
+final class SvgImageBackEnd implements ImageBackEndInterface
+{
+ private const PRECISION = 3;
+
+ /**
+ * @var XMLWriter|null
+ */
+ private $xmlWriter;
+
+ /**
+ * @var int[]|null
+ */
+ private $stack;
+
+ /**
+ * @var int|null
+ */
+ private $currentStack;
+
+ /**
+ * @var int|null
+ */
+ private $gradientCount;
+
+ public function __construct()
+ {
+ if (! class_exists(XMLWriter::class)) {
+ throw new RuntimeException('You need to install the libxml extension to use this back end');
+ }
+ }
+
+ public function new(int $size, ColorInterface $backgroundColor) : void
+ {
+ $this->xmlWriter = new XMLWriter();
+ $this->xmlWriter->openMemory();
+
+ $this->xmlWriter->startDocument('1.0', 'UTF-8');
+ $this->xmlWriter->startElement('svg');
+ $this->xmlWriter->writeAttribute('xmlns', 'http://www.w3.org/2000/svg');
+ $this->xmlWriter->writeAttribute('version', '1.1');
+ $this->xmlWriter->writeAttribute('width', (string) $size);
+ $this->xmlWriter->writeAttribute('height', (string) $size);
+ $this->xmlWriter->writeAttribute('viewBox', '0 0 '. $size . ' ' . $size);
+
+ $this->gradientCount = 0;
+ $this->currentStack = 0;
+ $this->stack[0] = 0;
+
+ $alpha = 1;
+
+ if ($backgroundColor instanceof Alpha) {
+ $alpha = $backgroundColor->getAlpha() / 100;
+ }
+
+ if (0 === $alpha) {
+ return;
+ }
+
+ $this->xmlWriter->startElement('rect');
+ $this->xmlWriter->writeAttribute('x', '0');
+ $this->xmlWriter->writeAttribute('y', '0');
+ $this->xmlWriter->writeAttribute('width', (string) $size);
+ $this->xmlWriter->writeAttribute('height', (string) $size);
+ $this->xmlWriter->writeAttribute('fill', $this->getColorString($backgroundColor));
+
+ if ($alpha < 1) {
+ $this->xmlWriter->writeAttribute('fill-opacity', (string) $alpha);
+ }
+
+ $this->xmlWriter->endElement();
+ }
+
+ public function scale(float $size) : void
+ {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->xmlWriter->startElement('g');
+ $this->xmlWriter->writeAttribute(
+ 'transform',
+ sprintf('scale(%s)', round($size, self::PRECISION))
+ );
+ ++$this->stack[$this->currentStack];
+ }
+
+ public function translate(float $x, float $y) : void
+ {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->xmlWriter->startElement('g');
+ $this->xmlWriter->writeAttribute(
+ 'transform',
+ sprintf('translate(%s,%s)', round($x, self::PRECISION), round($y, self::PRECISION))
+ );
+ ++$this->stack[$this->currentStack];
+ }
+
+ public function rotate(int $degrees) : void
+ {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->xmlWriter->startElement('g');
+ $this->xmlWriter->writeAttribute('transform', sprintf('rotate(%d)', $degrees));
+ ++$this->stack[$this->currentStack];
+ }
+
+ public function push() : void
+ {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $this->xmlWriter->startElement('g');
+ $this->stack[] = 1;
+ ++$this->currentStack;
+ }
+
+ public function pop() : void
+ {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ for ($i = 0; $i < $this->stack[$this->currentStack]; ++$i) {
+ $this->xmlWriter->endElement();
+ }
+
+ array_pop($this->stack);
+ --$this->currentStack;
+ }
+
+ public function drawPathWithColor(Path $path, ColorInterface $color) : void
+ {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $alpha = 1;
+
+ if ($color instanceof Alpha) {
+ $alpha = $color->getAlpha() / 100;
+ }
+
+ $this->startPathElement($path);
+ $this->xmlWriter->writeAttribute('fill', $this->getColorString($color));
+
+ if ($alpha < 1) {
+ $this->xmlWriter->writeAttribute('fill-opacity', (string) $alpha);
+ }
+
+ $this->xmlWriter->endElement();
+ }
+
+ public function drawPathWithGradient(
+ Path $path,
+ Gradient $gradient,
+ float $x,
+ float $y,
+ float $width,
+ float $height
+ ) : void {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ $gradientId = $this->createGradientFill($gradient, $x, $y, $width, $height);
+ $this->startPathElement($path);
+ $this->xmlWriter->writeAttribute('fill', 'url(#' . $gradientId . ')');
+ $this->xmlWriter->endElement();
+ }
+
+ public function done() : string
+ {
+ if (null === $this->xmlWriter) {
+ throw new RuntimeException('No image has been started');
+ }
+
+ foreach ($this->stack as $openElements) {
+ for ($i = $openElements; $i > 0; --$i) {
+ $this->xmlWriter->endElement();
+ }
+ }
+
+ $this->xmlWriter->endDocument();
+ $blob = $this->xmlWriter->outputMemory(true);
+ $this->xmlWriter = null;
+ $this->stack = null;
+ $this->currentStack = null;
+ $this->gradientCount = null;
+
+ return $blob;
+ }
+
+ private function startPathElement(Path $path) : void
+ {
+ $pathData = [];
+
+ foreach ($path as $op) {
+ switch (true) {
+ case $op instanceof Move:
+ $pathData[] = sprintf(
+ 'M%s %s',
+ round($op->getX(), self::PRECISION),
+ round($op->getY(), self::PRECISION)
+ );
+ break;
+
+ case $op instanceof Line:
+ $pathData[] = sprintf(
+ 'L%s %s',
+ round($op->getX(), self::PRECISION),
+ round($op->getY(), self::PRECISION)
+ );
+ break;
+
+ case $op instanceof EllipticArc:
+ $pathData[] = sprintf(
+ 'A%s %s %s %u %u %s %s',
+ round($op->getXRadius(), self::PRECISION),
+ round($op->getYRadius(), self::PRECISION),
+ round($op->getXAxisAngle(), self::PRECISION),
+ $op->isLargeArc(),
+ $op->isSweep(),
+ round($op->getX(), self::PRECISION),
+ round($op->getY(), self::PRECISION)
+ );
+ break;
+
+ case $op instanceof Curve:
+ $pathData[] = sprintf(
+ 'C%s %s %s %s %s %s',
+ round($op->getX1(), self::PRECISION),
+ round($op->getY1(), self::PRECISION),
+ round($op->getX2(), self::PRECISION),
+ round($op->getY2(), self::PRECISION),
+ round($op->getX3(), self::PRECISION),
+ round($op->getY3(), self::PRECISION)
+ );
+ break;
+
+ case $op instanceof Close:
+ $pathData[] = 'Z';
+ break;
+
+ default:
+ throw new RuntimeException('Unexpected draw operation: ' . get_class($op));
+ }
+ }
+
+ $this->xmlWriter->startElement('path');
+ $this->xmlWriter->writeAttribute('fill-rule', 'evenodd');
+ $this->xmlWriter->writeAttribute('d', implode('', $pathData));
+ }
+
+ private function createGradientFill(Gradient $gradient, float $x, float $y, float $width, float $height) : string
+ {
+ $this->xmlWriter->startElement('defs');
+
+ $startColor = $gradient->getStartColor();
+ $endColor = $gradient->getEndColor();
+
+ if ($gradient->getType() === GradientType::RADIAL()) {
+ $this->xmlWriter->startElement('radialGradient');
+ } else {
+ $this->xmlWriter->startElement('linearGradient');
+ }
+
+ $this->xmlWriter->writeAttribute('gradientUnits', 'userSpaceOnUse');
+
+ switch ($gradient->getType()) {
+ case GradientType::HORIZONTAL():
+ $this->xmlWriter->writeAttribute('x1', (string) round($x, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y1', (string) round($y, self::PRECISION));
+ $this->xmlWriter->writeAttribute('x2', (string) round($x + $width, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y2', (string) round($y, self::PRECISION));
+ break;
+
+ case GradientType::VERTICAL():
+ $this->xmlWriter->writeAttribute('x1', (string) round($x, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y1', (string) round($y, self::PRECISION));
+ $this->xmlWriter->writeAttribute('x2', (string) round($x, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y2', (string) round($y + $height, self::PRECISION));
+ break;
+
+ case GradientType::DIAGONAL():
+ $this->xmlWriter->writeAttribute('x1', (string) round($x, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y1', (string) round($y, self::PRECISION));
+ $this->xmlWriter->writeAttribute('x2', (string) round($x + $width, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y2', (string) round($y + $height, self::PRECISION));
+ break;
+
+ case GradientType::INVERSE_DIAGONAL():
+ $this->xmlWriter->writeAttribute('x1', (string) round($x, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y1', (string) round($y + $height, self::PRECISION));
+ $this->xmlWriter->writeAttribute('x2', (string) round($x + $width, self::PRECISION));
+ $this->xmlWriter->writeAttribute('y2', (string) round($y, self::PRECISION));
+ break;
+
+ case GradientType::RADIAL():
+ $this->xmlWriter->writeAttribute('cx', (string) round(($x + $width) / 2, self::PRECISION));
+ $this->xmlWriter->writeAttribute('cy', (string) round(($y + $height) / 2, self::PRECISION));
+ $this->xmlWriter->writeAttribute('r', (string) round(max($width, $height) / 2, self::PRECISION));
+ break;
+ }
+
+ $id = sprintf('g%d', ++$this->gradientCount);
+ $this->xmlWriter->writeAttribute('id', $id);
+
+ $this->xmlWriter->startElement('stop');
+ $this->xmlWriter->writeAttribute('offset', '0%');
+ $this->xmlWriter->writeAttribute('stop-color', $this->getColorString($startColor));
+
+ if ($startColor instanceof Alpha) {
+ $this->xmlWriter->writeAttribute('stop-opacity', (string) $startColor->getAlpha());
+ }
+
+ $this->xmlWriter->endElement();
+
+ $this->xmlWriter->startElement('stop');
+ $this->xmlWriter->writeAttribute('offset', '100%');
+ $this->xmlWriter->writeAttribute('stop-color', $this->getColorString($endColor));
+
+ if ($endColor instanceof Alpha) {
+ $this->xmlWriter->writeAttribute('stop-opacity', (string) $endColor->getAlpha());
+ }
+
+ $this->xmlWriter->endElement();
+
+ $this->xmlWriter->endElement();
+ $this->xmlWriter->endElement();
+
+ return $id;
+ }
+
+ private function getColorString(ColorInterface $color) : string
+ {
+ $color = $color->toRgb();
+
+ return sprintf(
+ '#%02x%02x%02x',
+ $color->getRed(),
+ $color->getGreen(),
+ $color->getBlue()
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/TransformationMatrix.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/TransformationMatrix.php
new file mode 100644
index 0000000..7e88da6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Image/TransformationMatrix.php
@@ -0,0 +1,68 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Image;
+
+final class TransformationMatrix
+{
+ /**
+ * @var float[]
+ */
+ private $values;
+
+ public function __construct()
+ {
+ $this->values = [1, 0, 0, 1, 0, 0];
+ }
+
+ public function multiply(self $other) : self
+ {
+ $matrix = new self();
+ $matrix->values[0] = $this->values[0] * $other->values[0] + $this->values[2] * $other->values[1];
+ $matrix->values[1] = $this->values[1] * $other->values[0] + $this->values[3] * $other->values[1];
+ $matrix->values[2] = $this->values[0] * $other->values[2] + $this->values[2] * $other->values[3];
+ $matrix->values[3] = $this->values[1] * $other->values[2] + $this->values[3] * $other->values[3];
+ $matrix->values[4] = $this->values[0] * $other->values[4] + $this->values[2] * $other->values[5]
+ + $this->values[4];
+ $matrix->values[5] = $this->values[1] * $other->values[4] + $this->values[3] * $other->values[5]
+ + $this->values[5];
+
+ return $matrix;
+ }
+
+ public static function scale(float $size) : self
+ {
+ $matrix = new self();
+ $matrix->values = [$size, 0, 0, $size, 0, 0];
+ return $matrix;
+ }
+
+ public static function translate(float $x, float $y) : self
+ {
+ $matrix = new self();
+ $matrix->values = [1, 0, 0, 1, $x, $y];
+ return $matrix;
+ }
+
+ public static function rotate(int $degrees) : self
+ {
+ $matrix = new self();
+ $rad = deg2rad($degrees);
+ $matrix->values = [cos($rad), sin($rad), -sin($rad), cos($rad), 0, 0];
+ return $matrix;
+ }
+
+
+ /**
+ * Applies this matrix onto a point and returns the resulting viewport point.
+ *
+ * @return float[]
+ */
+ public function apply(float $x, float $y) : array
+ {
+ return [
+ $x * $this->values[0] + $y * $this->values[2] + $this->values[4],
+ $x * $this->values[1] + $y * $this->values[3] + $this->values[5],
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/ImageRenderer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/ImageRenderer.php
new file mode 100644
index 0000000..ab16276
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/ImageRenderer.php
@@ -0,0 +1,152 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer;
+
+use BaconQrCode\Encoder\MatrixUtil;
+use BaconQrCode\Encoder\QrCode;
+use BaconQrCode\Exception\InvalidArgumentException;
+use BaconQrCode\Renderer\Image\ImageBackEndInterface;
+use BaconQrCode\Renderer\Path\Path;
+use BaconQrCode\Renderer\RendererStyle\EyeFill;
+use BaconQrCode\Renderer\RendererStyle\RendererStyle;
+
+final class ImageRenderer implements RendererInterface
+{
+ /**
+ * @var RendererStyle
+ */
+ private $rendererStyle;
+
+ /**
+ * @var ImageBackEndInterface
+ */
+ private $imageBackEnd;
+
+ public function __construct(RendererStyle $rendererStyle, ImageBackEndInterface $imageBackEnd)
+ {
+ $this->rendererStyle = $rendererStyle;
+ $this->imageBackEnd = $imageBackEnd;
+ }
+
+ /**
+ * @throws InvalidArgumentException if matrix width doesn't match height
+ */
+ public function render(QrCode $qrCode) : string
+ {
+ $size = $this->rendererStyle->getSize();
+ $margin = $this->rendererStyle->getMargin();
+ $matrix = $qrCode->getMatrix();
+ $matrixSize = $matrix->getWidth();
+
+ if ($matrixSize !== $matrix->getHeight()) {
+ throw new InvalidArgumentException('Matrix must have the same width and height');
+ }
+
+ $totalSize = $matrixSize + ($margin * 2);
+ $moduleSize = $size / $totalSize;
+ $fill = $this->rendererStyle->getFill();
+
+ $this->imageBackEnd->new($size, $fill->getBackgroundColor());
+ $this->imageBackEnd->scale((float) $moduleSize);
+ $this->imageBackEnd->translate((float) $margin, (float) $margin);
+
+ $module = $this->rendererStyle->getModule();
+ $moduleMatrix = clone $matrix;
+ MatrixUtil::removePositionDetectionPatterns($moduleMatrix);
+ $modulePath = $this->drawEyes($matrixSize, $module->createPath($moduleMatrix));
+
+ if ($fill->hasGradientFill()) {
+ $this->imageBackEnd->drawPathWithGradient(
+ $modulePath,
+ $fill->getForegroundGradient(),
+ 0,
+ 0,
+ $matrixSize,
+ $matrixSize
+ );
+ } else {
+ $this->imageBackEnd->drawPathWithColor($modulePath, $fill->getForegroundColor());
+ }
+
+ return $this->imageBackEnd->done();
+ }
+
+ private function drawEyes(int $matrixSize, Path $modulePath) : Path
+ {
+ $fill = $this->rendererStyle->getFill();
+
+ $eye = $this->rendererStyle->getEye();
+ $externalPath = $eye->getExternalPath();
+ $internalPath = $eye->getInternalPath();
+
+ $modulePath = $this->drawEye(
+ $externalPath,
+ $internalPath,
+ $fill->getTopLeftEyeFill(),
+ 3.5,
+ 3.5,
+ 0,
+ $modulePath
+ );
+ $modulePath = $this->drawEye(
+ $externalPath,
+ $internalPath,
+ $fill->getTopRightEyeFill(),
+ $matrixSize - 3.5,
+ 3.5,
+ 90,
+ $modulePath
+ );
+ $modulePath = $this->drawEye(
+ $externalPath,
+ $internalPath,
+ $fill->getBottomLeftEyeFill(),
+ 3.5,
+ $matrixSize - 3.5,
+ -90,
+ $modulePath
+ );
+
+ return $modulePath;
+ }
+
+ private function drawEye(
+ Path $externalPath,
+ Path $internalPath,
+ EyeFill $fill,
+ float $xTranslation,
+ float $yTranslation,
+ int $rotation,
+ Path $modulePath
+ ) : Path {
+ if ($fill->inheritsBothColors()) {
+ return $modulePath
+ ->append($externalPath->translate($xTranslation, $yTranslation))
+ ->append($internalPath->translate($xTranslation, $yTranslation));
+ }
+
+ $this->imageBackEnd->push();
+ $this->imageBackEnd->translate($xTranslation, $yTranslation);
+
+ if (0 !== $rotation) {
+ $this->imageBackEnd->rotate($rotation);
+ }
+
+ if ($fill->inheritsExternalColor()) {
+ $modulePath = $modulePath->append($externalPath->translate($xTranslation, $yTranslation));
+ } else {
+ $this->imageBackEnd->drawPathWithColor($externalPath, $fill->getExternalColor());
+ }
+
+ if ($fill->inheritsInternalColor()) {
+ $modulePath = $modulePath->append($internalPath->translate($xTranslation, $yTranslation));
+ } else {
+ $this->imageBackEnd->drawPathWithColor($internalPath, $fill->getInternalColor());
+ }
+
+ $this->imageBackEnd->pop();
+
+ return $modulePath;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/DotsModule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/DotsModule.php
new file mode 100644
index 0000000..f536e5a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/DotsModule.php
@@ -0,0 +1,63 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Module;
+
+use BaconQrCode\Encoder\ByteMatrix;
+use BaconQrCode\Exception\InvalidArgumentException;
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Renders individual modules as dots.
+ */
+final class DotsModule implements ModuleInterface
+{
+ public const LARGE = 1;
+ public const MEDIUM = .8;
+ public const SMALL = .6;
+
+ /**
+ * @var float
+ */
+ private $size;
+
+ public function __construct(float $size)
+ {
+ if ($size <= 0 || $size > 1) {
+ throw new InvalidArgumentException('Size must between 0 (exclusive) and 1 (inclusive)');
+ }
+
+ $this->size = $size;
+ }
+
+ public function createPath(ByteMatrix $matrix) : Path
+ {
+ $width = $matrix->getWidth();
+ $height = $matrix->getHeight();
+ $path = new Path();
+ $halfSize = $this->size / 2;
+ $margin = (1 - $this->size) / 2;
+
+ for ($y = 0; $y < $height; ++$y) {
+ for ($x = 0; $x < $width; ++$x) {
+ if (! $matrix->get($x, $y)) {
+ continue;
+ }
+
+ $pathX = $x + $margin;
+ $pathY = $y + $margin;
+
+ $path = $path
+ ->move($pathX + $this->size, $pathY + $halfSize)
+ ->ellipticArc($halfSize, $halfSize, 0, false, true, $pathX + $halfSize, $pathY + $this->size)
+ ->ellipticArc($halfSize, $halfSize, 0, false, true, $pathX, $pathY + $halfSize)
+ ->ellipticArc($halfSize, $halfSize, 0, false, true, $pathX + $halfSize, $pathY)
+ ->ellipticArc($halfSize, $halfSize, 0, false, true, $pathX + $this->size, $pathY + $halfSize)
+ ->close()
+ ;
+ }
+ }
+
+ return $path;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/EdgeIterator/Edge.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/EdgeIterator/Edge.php
new file mode 100644
index 0000000..90482f2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/EdgeIterator/Edge.php
@@ -0,0 +1,100 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Module\EdgeIterator;
+
+final class Edge
+{
+ /**
+ * @var bool
+ */
+ private $positive;
+
+ /**
+ * @var array<int[]>
+ */
+ private $points = [];
+
+ /**
+ * @var array<int[]>|null
+ */
+ private $simplifiedPoints;
+
+ /**
+ * @var int
+ */
+ private $minX = PHP_INT_MAX;
+
+ /**
+ * @var int
+ */
+ private $minY = PHP_INT_MAX;
+
+ /**
+ * @var int
+ */
+ private $maxX = -1;
+
+ /**
+ * @var int
+ */
+ private $maxY = -1;
+
+ public function __construct(bool $positive)
+ {
+ $this->positive = $positive;
+ }
+
+ public function addPoint(int $x, int $y) : void
+ {
+ $this->points[] = [$x, $y];
+ $this->minX = min($this->minX, $x);
+ $this->minY = min($this->minY, $y);
+ $this->maxX = max($this->maxX, $x);
+ $this->maxY = max($this->maxY, $y);
+ }
+
+ public function isPositive() : bool
+ {
+ return $this->positive;
+ }
+
+ /**
+ * @return array<int[]>
+ */
+ public function getPoints() : array
+ {
+ return $this->points;
+ }
+
+ public function getMaxX() : int
+ {
+ return $this->maxX;
+ }
+
+ public function getSimplifiedPoints() : array
+ {
+ if (null !== $this->simplifiedPoints) {
+ return $this->simplifiedPoints;
+ }
+
+ $points = [];
+ $length = count($this->points);
+
+ for ($i = 0; $i < $length; ++$i) {
+ $previousPoint = $this->points[(0 === $i ? $length : $i) - 1];
+ $nextPoint = $this->points[($length - 1 === $i ? -1 : $i) + 1];
+ $currentPoint = $this->points[$i];
+
+ if (($previousPoint[0] === $currentPoint[0] && $currentPoint[0] === $nextPoint[0])
+ || ($previousPoint[1] === $currentPoint[1] && $currentPoint[1] === $nextPoint[1])
+ ) {
+ continue;
+ }
+
+ $points[] = $currentPoint;
+ }
+
+ return $this->simplifiedPoints = $points;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/EdgeIterator/EdgeIterator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/EdgeIterator/EdgeIterator.php
new file mode 100644
index 0000000..eb29dc6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/EdgeIterator/EdgeIterator.php
@@ -0,0 +1,169 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Module\EdgeIterator;
+
+use BaconQrCode\Encoder\ByteMatrix;
+use IteratorAggregate;
+use Traversable;
+
+/**
+ * Edge iterator based on potrace.
+ */
+final class EdgeIterator implements IteratorAggregate
+{
+ /**
+ * @var int[]
+ */
+ private $bytes = [];
+
+ /**
+ * @var int
+ */
+ private $size;
+
+ /**
+ * @var int
+ */
+ private $width;
+
+ /**
+ * @var int
+ */
+ private $height;
+
+ public function __construct(ByteMatrix $matrix)
+ {
+ $this->bytes = iterator_to_array($matrix->getBytes());
+ $this->size = count($this->bytes);
+ $this->width = $matrix->getWidth();
+ $this->height = $matrix->getHeight();
+ }
+
+ /**
+ * @return Traversable<Edge>
+ */
+ public function getIterator() : Traversable
+ {
+ $originalBytes = $this->bytes;
+ $point = $this->findNext(0, 0);
+
+ while (null !== $point) {
+ $edge = $this->findEdge($point[0], $point[1]);
+ $this->xorEdge($edge);
+
+ yield $edge;
+
+ $point = $this->findNext($point[0], $point[1]);
+ }
+
+ $this->bytes = $originalBytes;
+ }
+
+ /**
+ * @return int[]|null
+ */
+ private function findNext(int $x, int $y) : ?array
+ {
+ $i = $this->width * $y + $x;
+
+ while ($i < $this->size && 1 !== $this->bytes[$i]) {
+ ++$i;
+ }
+
+ if ($i < $this->size) {
+ return $this->pointOf($i);
+ }
+
+ return null;
+ }
+
+ private function findEdge(int $x, int $y) : Edge
+ {
+ $edge = new Edge($this->isSet($x, $y));
+ $startX = $x;
+ $startY = $y;
+ $dirX = 0;
+ $dirY = 1;
+
+ while (true) {
+ $edge->addPoint($x, $y);
+ $x += $dirX;
+ $y += $dirY;
+
+ if ($x === $startX && $y === $startY) {
+ break;
+ }
+
+ $left = $this->isSet($x + ($dirX + $dirY - 1 ) / 2, $y + ($dirY - $dirX - 1) / 2);
+ $right = $this->isSet($x + ($dirX - $dirY - 1) / 2, $y + ($dirY + $dirX - 1) / 2);
+
+ if ($right && ! $left) {
+ $tmp = $dirX;
+ $dirX = -$dirY;
+ $dirY = $tmp;
+ } elseif ($right) {
+ $tmp = $dirX;
+ $dirX = -$dirY;
+ $dirY = $tmp;
+ } elseif (! $left) {
+ $tmp = $dirX;
+ $dirX = $dirY;
+ $dirY = -$tmp;
+ }
+ }
+
+ return $edge;
+ }
+
+ private function xorEdge(Edge $path) : void
+ {
+ $points = $path->getPoints();
+ $y1 = $points[0][1];
+ $length = count($points);
+ $maxX = $path->getMaxX();
+
+ for ($i = 1; $i < $length; ++$i) {
+ $y = $points[$i][1];
+
+ if ($y === $y1) {
+ continue;
+ }
+
+ $x = $points[$i][0];
+ $minY = min($y1, $y);
+
+ for ($j = $x; $j < $maxX; ++$j) {
+ $this->flip($j, $minY);
+ }
+
+ $y1 = $y;
+ }
+ }
+
+ private function isSet(int $x, int $y) : bool
+ {
+ return (
+ $x >= 0
+ && $x < $this->width
+ && $y >= 0
+ && $y < $this->height
+ ) && 1 === $this->bytes[$this->width * $y + $x];
+ }
+
+ /**
+ * @return int[]
+ */
+ private function pointOf(int $i) : array
+ {
+ $y = intdiv($i, $this->width);
+ return [$i - $y * $this->width, $y];
+ }
+
+ private function flip(int $x, int $y) : void
+ {
+ $this->bytes[$this->width * $y + $x] = (
+ $this->isSet($x, $y) ? 0 : 1
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/ModuleInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/ModuleInterface.php
new file mode 100644
index 0000000..0ccb0e0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/ModuleInterface.php
@@ -0,0 +1,18 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Module;
+
+use BaconQrCode\Encoder\ByteMatrix;
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Interface describing how modules should be rendered.
+ *
+ * A module always receives a byte matrix (with values either being 1 or 0). It returns a path, where the origin
+ * coordinate (0, 0) equals the top left corner of the first matrix value.
+ */
+interface ModuleInterface
+{
+ public function createPath(ByteMatrix $matrix) : Path;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/RoundnessModule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/RoundnessModule.php
new file mode 100644
index 0000000..01b83c6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/RoundnessModule.php
@@ -0,0 +1,129 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Module;
+
+use BaconQrCode\Encoder\ByteMatrix;
+use BaconQrCode\Exception\InvalidArgumentException;
+use BaconQrCode\Renderer\Module\EdgeIterator\EdgeIterator;
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Rounds the corners of module groups.
+ */
+final class RoundnessModule implements ModuleInterface
+{
+ public const STRONG = 1;
+ public const MEDIUM = .5;
+ public const SOFT = .25;
+
+ /**
+ * @var float
+ */
+ private $intensity;
+
+ public function __construct(float $intensity)
+ {
+ if ($intensity <= 0 || $intensity > 1) {
+ throw new InvalidArgumentException('Intensity must between 0 (exclusive) and 1 (inclusive)');
+ }
+
+ $this->intensity = $intensity / 2;
+ }
+
+ public function createPath(ByteMatrix $matrix) : Path
+ {
+ $path = new Path();
+
+ foreach (new EdgeIterator($matrix) as $edge) {
+ $points = $edge->getSimplifiedPoints();
+ $length = count($points);
+
+ $currentPoint = $points[0];
+ $nextPoint = $points[1];
+ $horizontal = ($currentPoint[1] === $nextPoint[1]);
+
+ if ($horizontal) {
+ $right = $nextPoint[0] > $currentPoint[0];
+ $path = $path->move(
+ $currentPoint[0] + ($right ? $this->intensity : -$this->intensity),
+ $currentPoint[1]
+ );
+ } else {
+ $up = $nextPoint[0] < $currentPoint[0];
+ $path = $path->move(
+ $currentPoint[0],
+ $currentPoint[1] + ($up ? -$this->intensity : $this->intensity)
+ );
+ }
+
+ for ($i = 1; $i <= $length; ++$i) {
+ if ($i === $length) {
+ $previousPoint = $points[$length - 1];
+ $currentPoint = $points[0];
+ $nextPoint = $points[1];
+ } else {
+ $previousPoint = $points[(0 === $i ? $length : $i) - 1];
+ $currentPoint = $points[$i];
+ $nextPoint = $points[($length - 1 === $i ? -1 : $i) + 1];
+ }
+
+ $horizontal = ($previousPoint[1] === $currentPoint[1]);
+
+ if ($horizontal) {
+ $right = $previousPoint[0] < $currentPoint[0];
+ $up = $nextPoint[1] < $currentPoint[1];
+ $sweep = ($up xor $right);
+
+ if ($this->intensity < 0.5
+ || ($right && $previousPoint[0] !== $currentPoint[0] - 1)
+ || (! $right && $previousPoint[0] - 1 !== $currentPoint[0])
+ ) {
+ $path = $path->line(
+ $currentPoint[0] + ($right ? -$this->intensity : $this->intensity),
+ $currentPoint[1]
+ );
+ }
+
+ $path = $path->ellipticArc(
+ $this->intensity,
+ $this->intensity,
+ 0,
+ false,
+ $sweep,
+ $currentPoint[0],
+ $currentPoint[1] + ($up ? -$this->intensity : $this->intensity)
+ );
+ } else {
+ $up = $previousPoint[1] > $currentPoint[1];
+ $right = $nextPoint[0] > $currentPoint[0];
+ $sweep = ! ($up xor $right);
+
+ if ($this->intensity < 0.5
+ || ($up && $previousPoint[1] !== $currentPoint[1] + 1)
+ || (! $up && $previousPoint[0] + 1 !== $currentPoint[0])
+ ) {
+ $path = $path->line(
+ $currentPoint[0],
+ $currentPoint[1] + ($up ? $this->intensity : -$this->intensity)
+ );
+ }
+
+ $path = $path->ellipticArc(
+ $this->intensity,
+ $this->intensity,
+ 0,
+ false,
+ $sweep,
+ $currentPoint[0] + ($right ? $this->intensity : -$this->intensity),
+ $currentPoint[1]
+ );
+ }
+ }
+
+ $path = $path->close();
+ }
+
+ return $path;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/SquareModule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/SquareModule.php
new file mode 100644
index 0000000..9ab4607
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Module/SquareModule.php
@@ -0,0 +1,47 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Module;
+
+use BaconQrCode\Encoder\ByteMatrix;
+use BaconQrCode\Renderer\Module\EdgeIterator\EdgeIterator;
+use BaconQrCode\Renderer\Path\Path;
+
+/**
+ * Groups modules together to a single path.
+ */
+final class SquareModule implements ModuleInterface
+{
+ /**
+ * @var self|null
+ */
+ private static $instance;
+
+ private function __construct()
+ {
+ }
+
+ public static function instance() : self
+ {
+ return self::$instance ?: self::$instance = new self();
+ }
+
+ public function createPath(ByteMatrix $matrix) : Path
+ {
+ $path = new Path();
+
+ foreach (new EdgeIterator($matrix) as $edge) {
+ $points = $edge->getSimplifiedPoints();
+ $length = count($points);
+ $path = $path->move($points[0][0], $points[0][1]);
+
+ for ($i = 1; $i < $length; ++$i) {
+ $path = $path->line($points[$i][0], $points[$i][1]);
+ }
+
+ $path = $path->close();
+ }
+
+ return $path;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Close.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Close.php
new file mode 100644
index 0000000..b07feb0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Close.php
@@ -0,0 +1,29 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Path;
+
+final class Close implements OperationInterface
+{
+ /**
+ * @var self|null
+ */
+ private static $instance;
+
+ private function __construct()
+ {
+ }
+
+ public static function instance() : self
+ {
+ return self::$instance ?: self::$instance = new self();
+ }
+
+ /**
+ * @return self
+ */
+ public function translate(float $x, float $y) : OperationInterface
+ {
+ return $this;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Curve.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Curve.php
new file mode 100644
index 0000000..c067c74
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Curve.php
@@ -0,0 +1,92 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Path;
+
+final class Curve implements OperationInterface
+{
+ /**
+ * @var float
+ */
+ private $x1;
+
+ /**
+ * @var float
+ */
+ private $y1;
+
+ /**
+ * @var float
+ */
+ private $x2;
+
+ /**
+ * @var float
+ */
+ private $y2;
+
+ /**
+ * @var float
+ */
+ private $x3;
+
+ /**
+ * @var float
+ */
+ private $y3;
+
+ public function __construct(float $x1, float $y1, float $x2, float $y2, float $x3, float $y3)
+ {
+ $this->x1 = $x1;
+ $this->y1 = $y1;
+ $this->x2 = $x2;
+ $this->y2 = $y2;
+ $this->x3 = $x3;
+ $this->y3 = $y3;
+ }
+
+ public function getX1() : float
+ {
+ return $this->x1;
+ }
+
+ public function getY1() : float
+ {
+ return $this->y1;
+ }
+
+ public function getX2() : float
+ {
+ return $this->x2;
+ }
+
+ public function getY2() : float
+ {
+ return $this->y2;
+ }
+
+ public function getX3() : float
+ {
+ return $this->x3;
+ }
+
+ public function getY3() : float
+ {
+ return $this->y3;
+ }
+
+ /**
+ * @return self
+ */
+ public function translate(float $x, float $y) : OperationInterface
+ {
+ return new self(
+ $this->x1 + $x,
+ $this->y1 + $y,
+ $this->x2 + $x,
+ $this->y2 + $y,
+ $this->x3 + $x,
+ $this->y3 + $y
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/EllipticArc.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/EllipticArc.php
new file mode 100644
index 0000000..9f2385a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/EllipticArc.php
@@ -0,0 +1,278 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Path;
+
+final class EllipticArc implements OperationInterface
+{
+ private const ZERO_TOLERANCE = 1e-05;
+
+ /**
+ * @var float
+ */
+ private $xRadius;
+
+ /**
+ * @var float
+ */
+ private $yRadius;
+
+ /**
+ * @var float
+ */
+ private $xAxisAngle;
+
+ /**
+ * @var bool
+ */
+ private $largeArc;
+
+ /**
+ * @var bool
+ */
+ private $sweep;
+
+ /**
+ * @var float
+ */
+ private $x;
+
+ /**
+ * @var float
+ */
+ private $y;
+
+ public function __construct(
+ float $xRadius,
+ float $yRadius,
+ float $xAxisAngle,
+ bool $largeArc,
+ bool $sweep,
+ float $x,
+ float $y
+ ) {
+ $this->xRadius = abs($xRadius);
+ $this->yRadius = abs($yRadius);
+ $this->xAxisAngle = $xAxisAngle % 360;
+ $this->largeArc = $largeArc;
+ $this->sweep = $sweep;
+ $this->x = $x;
+ $this->y = $y;
+ }
+
+ public function getXRadius() : float
+ {
+ return $this->xRadius;
+ }
+
+ public function getYRadius() : float
+ {
+ return $this->yRadius;
+ }
+
+ public function getXAxisAngle() : float
+ {
+ return $this->xAxisAngle;
+ }
+
+ public function isLargeArc() : bool
+ {
+ return $this->largeArc;
+ }
+
+ public function isSweep() : bool
+ {
+ return $this->sweep;
+ }
+
+ public function getX() : float
+ {
+ return $this->x;
+ }
+
+ public function getY() : float
+ {
+ return $this->y;
+ }
+
+ /**
+ * @return self
+ */
+ public function translate(float $x, float $y) : OperationInterface
+ {
+ return new self(
+ $this->xRadius,
+ $this->yRadius,
+ $this->xAxisAngle,
+ $this->largeArc,
+ $this->sweep,
+ $this->x + $x,
+ $this->y + $y
+ );
+ }
+
+ /**
+ * Converts the elliptic arc to multiple curves.
+ *
+ * Since not all image back ends support elliptic arcs, this method allows to convert the arc into multiple curves
+ * resembling the same result.
+ *
+ * @see https://mortoray.com/2017/02/16/rendering-an-svg-elliptical-arc-as-bezier-curves/
+ * @return array<Curve|Line>
+ */
+ public function toCurves(float $fromX, float $fromY) : array
+ {
+ if (sqrt(($fromX - $this->x) ** 2 + ($fromY - $this->y) ** 2) < self::ZERO_TOLERANCE) {
+ return [];
+ }
+
+ if ($this->xRadius < self::ZERO_TOLERANCE || $this->yRadius < self::ZERO_TOLERANCE) {
+ return [new Line($this->x, $this->y)];
+ }
+
+ return $this->createCurves($fromX, $fromY);
+ }
+
+ /**
+ * @return Curve[]
+ */
+ private function createCurves(float $fromX, float $fromY) : array
+ {
+ $xAngle = deg2rad($this->xAxisAngle);
+ list($centerX, $centerY, $radiusX, $radiusY, $startAngle, $deltaAngle) =
+ $this->calculateCenterPointParameters($fromX, $fromY, $xAngle);
+
+ $s = $startAngle;
+ $e = $s + $deltaAngle;
+ $sign = ($e < $s) ? -1 : 1;
+ $remain = abs($e - $s);
+ $p1 = self::point($centerX, $centerY, $radiusX, $radiusY, $xAngle, $s);
+ $curves = [];
+
+ while ($remain > self::ZERO_TOLERANCE) {
+ $step = min($remain, pi() / 2);
+ $signStep = $step * $sign;
+ $p2 = self::point($centerX, $centerY, $radiusX, $radiusY, $xAngle, $s + $signStep);
+
+ $alphaT = tan($signStep / 2);
+ $alpha = sin($signStep) * (sqrt(4 + 3 * $alphaT ** 2) - 1) / 3;
+ $d1 = self::derivative($radiusX, $radiusY, $xAngle, $s);
+ $d2 = self::derivative($radiusX, $radiusY, $xAngle, $s + $signStep);
+
+ $curves[] = new Curve(
+ $p1[0] + $alpha * $d1[0],
+ $p1[1] + $alpha * $d1[1],
+ $p2[0] - $alpha * $d2[0],
+ $p2[1] - $alpha * $d2[1],
+ $p2[0],
+ $p2[1]
+ );
+
+ $s += $signStep;
+ $remain -= $step;
+ $p1 = $p2;
+ }
+
+ return $curves;
+ }
+
+ /**
+ * @return float[]
+ */
+ private function calculateCenterPointParameters(float $fromX, float $fromY, float $xAngle)
+ {
+ $rX = $this->xRadius;
+ $rY = $this->yRadius;
+
+ // F.6.5.1
+ $dx2 = ($fromX - $this->x) / 2;
+ $dy2 = ($fromY - $this->y) / 2;
+ $x1p = cos($xAngle) * $dx2 + sin($xAngle) * $dy2;
+ $y1p = -sin($xAngle) * $dx2 + cos($xAngle) * $dy2;
+
+ // F.6.5.2
+ $rxs = $rX ** 2;
+ $rys = $rY ** 2;
+ $x1ps = $x1p ** 2;
+ $y1ps = $y1p ** 2;
+ $cr = $x1ps / $rxs + $y1ps / $rys;
+
+ if ($cr > 1) {
+ $s = sqrt($cr);
+ $rX *= $s;
+ $rY *= $s;
+ $rxs = $rX ** 2;
+ $rys = $rY ** 2;
+ }
+
+ $dq = ($rxs * $y1ps + $rys * $x1ps);
+ $pq = ($rxs * $rys - $dq) / $dq;
+ $q = sqrt(max(0, $pq));
+
+ if ($this->largeArc === $this->sweep) {
+ $q = -$q;
+ }
+
+ $cxp = $q * $rX * $y1p / $rY;
+ $cyp = -$q * $rY * $x1p / $rX;
+
+ // F.6.5.3
+ $cx = cos($xAngle) * $cxp - sin($xAngle) * $cyp + ($fromX + $this->x) / 2;
+ $cy = sin($xAngle) * $cxp + cos($xAngle) * $cyp + ($fromY + $this->y) / 2;
+
+ // F.6.5.5
+ $theta = self::angle(1, 0, ($x1p - $cxp) / $rX, ($y1p - $cyp) / $rY);
+
+ // F.6.5.6
+ $delta = self::angle(($x1p - $cxp) / $rX, ($y1p - $cyp) / $rY, (-$x1p - $cxp) / $rX, (-$y1p - $cyp) / $rY);
+ $delta = fmod($delta, pi() * 2);
+
+ if (! $this->sweep) {
+ $delta -= 2 * pi();
+ }
+
+ return [$cx, $cy, $rX, $rY, $theta, $delta];
+ }
+
+ private static function angle(float $ux, float $uy, float $vx, float $vy) : float
+ {
+ // F.6.5.4
+ $dot = $ux * $vx + $uy * $vy;
+ $length = sqrt($ux ** 2 + $uy ** 2) * sqrt($vx ** 2 + $vy ** 2);
+ $angle = acos(min(1, max(-1, $dot / $length)));
+
+ if (($ux * $vy - $uy * $vx) < 0) {
+ return -$angle;
+ }
+
+ return $angle;
+ }
+
+ /**
+ * @return float[]
+ */
+ private static function point(
+ float $centerX,
+ float $centerY,
+ float $radiusX,
+ float $radiusY,
+ float $xAngle,
+ float $angle
+ ) : array {
+ return [
+ $centerX + $radiusX * cos($xAngle) * cos($angle) - $radiusY * sin($xAngle) * sin($angle),
+ $centerY + $radiusX * sin($xAngle) * cos($angle) + $radiusY * cos($xAngle) * sin($angle),
+ ];
+ }
+
+ /**
+ * @return float[]
+ */
+ private static function derivative(float $radiusX, float $radiusY, float $xAngle, float $angle) : array
+ {
+ return [
+ -$radiusX * cos($xAngle) * sin($angle) - $radiusY * sin($xAngle) * cos($angle),
+ -$radiusX * sin($xAngle) * sin($angle) + $radiusY * cos($xAngle) * cos($angle),
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Line.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Line.php
new file mode 100644
index 0000000..3149a39
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Line.php
@@ -0,0 +1,41 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Path;
+
+final class Line implements OperationInterface
+{
+ /**
+ * @var float
+ */
+ private $x;
+
+ /**
+ * @var float
+ */
+ private $y;
+
+ public function __construct(float $x, float $y)
+ {
+ $this->x = $x;
+ $this->y = $y;
+ }
+
+ public function getX() : float
+ {
+ return $this->x;
+ }
+
+ public function getY() : float
+ {
+ return $this->y;
+ }
+
+ /**
+ * @return self
+ */
+ public function translate(float $x, float $y) : OperationInterface
+ {
+ return new self($this->x + $x, $this->y + $y);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Move.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Move.php
new file mode 100644
index 0000000..481d0dd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Move.php
@@ -0,0 +1,41 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Path;
+
+final class Move implements OperationInterface
+{
+ /**
+ * @var float
+ */
+ private $x;
+
+ /**
+ * @var float
+ */
+ private $y;
+
+ public function __construct(float $x, float $y)
+ {
+ $this->x = $x;
+ $this->y = $y;
+ }
+
+ public function getX() : float
+ {
+ return $this->x;
+ }
+
+ public function getY() : float
+ {
+ return $this->y;
+ }
+
+ /**
+ * @return self
+ */
+ public function translate(float $x, float $y) : OperationInterface
+ {
+ return new self($this->x + $x, $this->y + $y);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/OperationInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/OperationInterface.php
new file mode 100644
index 0000000..a5fa0ed
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/OperationInterface.php
@@ -0,0 +1,12 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Path;
+
+interface OperationInterface
+{
+ /**
+ * Translates the operation's coordinates.
+ */
+ public function translate(float $x, float $y) : self;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Path.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Path.php
new file mode 100644
index 0000000..8e5e298
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/Path/Path.php
@@ -0,0 +1,106 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\Path;
+
+use IteratorAggregate;
+use Traversable;
+
+/**
+ * Internal Representation of a vector path.
+ */
+final class Path implements IteratorAggregate
+{
+ /**
+ * @var OperationInterface[]
+ */
+ private $operations = [];
+
+ /**
+ * Moves the drawing operation to a certain position.
+ */
+ public function move(float $x, float $y) : self
+ {
+ $path = clone $this;
+ $path->operations[] = new Move($x, $y);
+ return $path;
+ }
+
+ /**
+ * Draws a line from the current position to another position.
+ */
+ public function line(float $x, float $y) : self
+ {
+ $path = clone $this;
+ $path->operations[] = new Line($x, $y);
+ return $path;
+ }
+
+ /**
+ * Draws an elliptic arc from the current position to another position.
+ */
+ public function ellipticArc(
+ float $xRadius,
+ float $yRadius,
+ float $xAxisRotation,
+ bool $largeArc,
+ bool $sweep,
+ float $x,
+ float $y
+ ) : self {
+ $path = clone $this;
+ $path->operations[] = new EllipticArc($xRadius, $yRadius, $xAxisRotation, $largeArc, $sweep, $x, $y);
+ return $path;
+ }
+
+ /**
+ * Draws a curve from the current position to another position.
+ */
+ public function curve(float $x1, float $y1, float $x2, float $y2, float $x3, float $y3) : self
+ {
+ $path = clone $this;
+ $path->operations[] = new Curve($x1, $y1, $x2, $y2, $x3, $y3);
+ return $path;
+ }
+
+ /**
+ * Closes a sub-path.
+ */
+ public function close() : self
+ {
+ $path = clone $this;
+ $path->operations[] = Close::instance();
+ return $path;
+ }
+
+ /**
+ * Appends another path to this one.
+ */
+ public function append(self $other) : self
+ {
+ $path = clone $this;
+ $path->operations = array_merge($this->operations, $other->operations);
+ return $path;
+ }
+
+ public function translate(float $x, float $y) : self
+ {
+ $path = new self();
+
+ foreach ($this->operations as $operation) {
+ $path->operations[] = $operation->translate($x, $y);
+ }
+
+ return $path;
+ }
+
+ /**
+ * @return OperationInterface[]|Traversable
+ */
+ public function getIterator() : Traversable
+ {
+ foreach ($this->operations as $operation) {
+ yield $operation;
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/PlainTextRenderer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/PlainTextRenderer.php
new file mode 100644
index 0000000..8aa7652
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/PlainTextRenderer.php
@@ -0,0 +1,86 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer;
+
+use BaconQrCode\Encoder\QrCode;
+use BaconQrCode\Exception\InvalidArgumentException;
+
+final class PlainTextRenderer implements RendererInterface
+{
+ /**
+ * UTF-8 full block (U+2588)
+ */
+ private const FULL_BLOCK = "\xe2\x96\x88";
+
+ /**
+ * UTF-8 upper half block (U+2580)
+ */
+ private const UPPER_HALF_BLOCK = "\xe2\x96\x80";
+
+ /**
+ * UTF-8 lower half block (U+2584)
+ */
+ private const LOWER_HALF_BLOCK = "\xe2\x96\x84";
+
+ /**
+ * UTF-8 no-break space (U+00A0)
+ */
+ private const EMPTY_BLOCK = "\xc2\xa0";
+
+ /**
+ * @var int
+ */
+ private $margin;
+
+ public function __construct(int $margin = 2)
+ {
+ $this->margin = $margin;
+ }
+
+ /**
+ * @throws InvalidArgumentException if matrix width doesn't match height
+ */
+ public function render(QrCode $qrCode) : string
+ {
+ $matrix = $qrCode->getMatrix();
+ $matrixSize = $matrix->getWidth();
+
+ if ($matrixSize !== $matrix->getHeight()) {
+ throw new InvalidArgumentException('Matrix must have the same width and height');
+ }
+
+ $rows = $matrix->getArray()->toArray();
+
+ if (0 !== $matrixSize % 2) {
+ $rows[] = array_fill(0, $matrixSize, 0);
+ }
+
+ $horizontalMargin = str_repeat(self::EMPTY_BLOCK, $this->margin);
+ $result = str_repeat("\n", (int) ceil($this->margin / 2));
+
+ for ($i = 0; $i < $matrixSize; $i += 2) {
+ $result .= $horizontalMargin;
+
+ $upperRow = $rows[$i];
+ $lowerRow = $rows[$i + 1];
+
+ for ($j = 0; $j < $matrixSize; ++$j) {
+ $upperBit = $upperRow[$j];
+ $lowerBit = $lowerRow[$j];
+
+ if ($upperBit) {
+ $result .= $lowerBit ? self::FULL_BLOCK : self::UPPER_HALF_BLOCK;
+ } else {
+ $result .= $lowerBit ? self::LOWER_HALF_BLOCK : self::EMPTY_BLOCK;
+ }
+ }
+
+ $result .= $horizontalMargin . "\n";
+ }
+
+ $result .= str_repeat("\n", (int) ceil($this->margin / 2));
+
+ return $result;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererInterface.php
new file mode 100644
index 0000000..b0aae39
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererInterface.php
@@ -0,0 +1,11 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer;
+
+use BaconQrCode\Encoder\QrCode;
+
+interface RendererInterface
+{
+ public function render(QrCode $qrCode) : string;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/EyeFill.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/EyeFill.php
new file mode 100644
index 0000000..46abc22
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/EyeFill.php
@@ -0,0 +1,74 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\RendererStyle;
+
+use BaconQrCode\Exception\RuntimeException;
+use BaconQrCode\Renderer\Color\ColorInterface;
+
+final class EyeFill
+{
+ /**
+ * @var ColorInterface|null
+ */
+ private $externalColor;
+
+ /**
+ * @var ColorInterface|null
+ */
+ private $internalColor;
+
+ /**
+ * @var self|null
+ */
+ private static $inherit;
+
+ public function __construct(?ColorInterface $externalColor, ?ColorInterface $internalColor)
+ {
+ $this->externalColor = $externalColor;
+ $this->internalColor = $internalColor;
+ }
+
+ public static function uniform(ColorInterface $color) : self
+ {
+ return new self($color, $color);
+ }
+
+ public static function inherit() : self
+ {
+ return self::$inherit ?: self::$inherit = new self(null, null);
+ }
+
+ public function inheritsBothColors() : bool
+ {
+ return null === $this->externalColor && null === $this->internalColor;
+ }
+
+ public function inheritsExternalColor() : bool
+ {
+ return null === $this->externalColor;
+ }
+
+ public function inheritsInternalColor() : bool
+ {
+ return null === $this->internalColor;
+ }
+
+ public function getExternalColor() : ColorInterface
+ {
+ if (null === $this->externalColor) {
+ throw new RuntimeException('External eye color inherits foreground color');
+ }
+
+ return $this->externalColor;
+ }
+
+ public function getInternalColor() : ColorInterface
+ {
+ if (null === $this->internalColor) {
+ throw new RuntimeException('Internal eye color inherits foreground color');
+ }
+
+ return $this->internalColor;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/Fill.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/Fill.php
new file mode 100644
index 0000000..d54268e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/Fill.php
@@ -0,0 +1,168 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\RendererStyle;
+
+use BaconQrCode\Exception\RuntimeException;
+use BaconQrCode\Renderer\Color\ColorInterface;
+use BaconQrCode\Renderer\Color\Gray;
+
+final class Fill
+{
+ /**
+ * @var ColorInterface
+ */
+ private $backgroundColor;
+
+ /**
+ * @var ColorInterface|null
+ */
+ private $foregroundColor;
+
+ /**
+ * @var Gradient|null
+ */
+ private $foregroundGradient;
+
+ /**
+ * @var EyeFill
+ */
+ private $topLeftEyeFill;
+
+ /**
+ * @var EyeFill
+ */
+ private $topRightEyeFill;
+
+ /**
+ * @var EyeFill
+ */
+ private $bottomLeftEyeFill;
+
+ /**
+ * @var self|null
+ */
+ private static $default;
+
+ private function __construct(
+ ColorInterface $backgroundColor,
+ ?ColorInterface $foregroundColor,
+ ?Gradient $foregroundGradient,
+ EyeFill $topLeftEyeFill,
+ EyeFill $topRightEyeFill,
+ EyeFill $bottomLeftEyeFill
+ ) {
+ $this->backgroundColor = $backgroundColor;
+ $this->foregroundColor = $foregroundColor;
+ $this->foregroundGradient = $foregroundGradient;
+ $this->topLeftEyeFill = $topLeftEyeFill;
+ $this->topRightEyeFill = $topRightEyeFill;
+ $this->bottomLeftEyeFill = $bottomLeftEyeFill;
+ }
+
+ public static function default() : self
+ {
+ return self::$default ?: self::$default = self::uniformColor(new Gray(100), new Gray(0));
+ }
+
+ public static function withForegroundColor(
+ ColorInterface $backgroundColor,
+ ColorInterface $foregroundColor,
+ EyeFill $topLeftEyeFill,
+ EyeFill $topRightEyeFill,
+ EyeFill $bottomLeftEyeFill
+ ) : self {
+ return new self(
+ $backgroundColor,
+ $foregroundColor,
+ null,
+ $topLeftEyeFill,
+ $topRightEyeFill,
+ $bottomLeftEyeFill
+ );
+ }
+
+ public static function withForegroundGradient(
+ ColorInterface $backgroundColor,
+ Gradient $foregroundGradient,
+ EyeFill $topLeftEyeFill,
+ EyeFill $topRightEyeFill,
+ EyeFill $bottomLeftEyeFill
+ ) : self {
+ return new self(
+ $backgroundColor,
+ null,
+ $foregroundGradient,
+ $topLeftEyeFill,
+ $topRightEyeFill,
+ $bottomLeftEyeFill
+ );
+ }
+
+ public static function uniformColor(ColorInterface $backgroundColor, ColorInterface $foregroundColor) : self
+ {
+ return new self(
+ $backgroundColor,
+ $foregroundColor,
+ null,
+ EyeFill::inherit(),
+ EyeFill::inherit(),
+ EyeFill::inherit()
+ );
+ }
+
+ public static function uniformGradient(ColorInterface $backgroundColor, Gradient $foregroundGradient) : self
+ {
+ return new self(
+ $backgroundColor,
+ null,
+ $foregroundGradient,
+ EyeFill::inherit(),
+ EyeFill::inherit(),
+ EyeFill::inherit()
+ );
+ }
+
+ public function hasGradientFill() : bool
+ {
+ return null !== $this->foregroundGradient;
+ }
+
+ public function getBackgroundColor() : ColorInterface
+ {
+ return $this->backgroundColor;
+ }
+
+ public function getForegroundColor() : ColorInterface
+ {
+ if (null === $this->foregroundColor) {
+ throw new RuntimeException('Fill uses a gradient, thus no foreground color is available');
+ }
+
+ return $this->foregroundColor;
+ }
+
+ public function getForegroundGradient() : Gradient
+ {
+ if (null === $this->foregroundGradient) {
+ throw new RuntimeException('Fill uses a single color, thus no foreground gradient is available');
+ }
+
+ return $this->foregroundGradient;
+ }
+
+ public function getTopLeftEyeFill() : EyeFill
+ {
+ return $this->topLeftEyeFill;
+ }
+
+ public function getTopRightEyeFill() : EyeFill
+ {
+ return $this->topRightEyeFill;
+ }
+
+ public function getBottomLeftEyeFill() : EyeFill
+ {
+ return $this->bottomLeftEyeFill;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/Gradient.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/Gradient.php
new file mode 100644
index 0000000..3813dfd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/Gradient.php
@@ -0,0 +1,46 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\RendererStyle;
+
+use BaconQrCode\Renderer\Color\ColorInterface;
+
+final class Gradient
+{
+ /**
+ * @var ColorInterface
+ */
+ private $startColor;
+
+ /**
+ * @var ColorInterface
+ */
+ private $endColor;
+
+ /**
+ * @var GradientType
+ */
+ private $type;
+
+ public function __construct(ColorInterface $startColor, ColorInterface $endColor, GradientType $type)
+ {
+ $this->startColor = $startColor;
+ $this->endColor = $endColor;
+ $this->type = $type;
+ }
+
+ public function getStartColor() : ColorInterface
+ {
+ return $this->startColor;
+ }
+
+ public function getEndColor() : ColorInterface
+ {
+ return $this->endColor;
+ }
+
+ public function getType() : GradientType
+ {
+ return $this->type;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/GradientType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/GradientType.php
new file mode 100644
index 0000000..c1ca754
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/GradientType.php
@@ -0,0 +1,22 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\RendererStyle;
+
+use DASPRiD\Enum\AbstractEnum;
+
+/**
+ * @method static self VERTICAL()
+ * @method static self HORIZONTAL()
+ * @method static self DIAGONAL()
+ * @method static self INVERSE_DIAGONAL()
+ * @method static self RADIAL()
+ */
+final class GradientType extends AbstractEnum
+{
+ protected const VERTICAL = null;
+ protected const HORIZONTAL = null;
+ protected const DIAGONAL = null;
+ protected const INVERSE_DIAGONAL = null;
+ protected const RADIAL = null;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/RendererStyle.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/RendererStyle.php
new file mode 100644
index 0000000..e03e099
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Renderer/RendererStyle/RendererStyle.php
@@ -0,0 +1,90 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode\Renderer\RendererStyle;
+
+use BaconQrCode\Renderer\Eye\EyeInterface;
+use BaconQrCode\Renderer\Eye\ModuleEye;
+use BaconQrCode\Renderer\Module\ModuleInterface;
+use BaconQrCode\Renderer\Module\SquareModule;
+
+final class RendererStyle
+{
+ /**
+ * @var int
+ */
+ private $size;
+
+ /**
+ * @var int
+ */
+ private $margin;
+
+ /**
+ * @var ModuleInterface
+ */
+ private $module;
+
+ /**
+ * @var EyeInterface|null
+ */
+ private $eye;
+
+ /**
+ * @var Fill
+ */
+ private $fill;
+
+ public function __construct(
+ int $size,
+ int $margin = 4,
+ ?ModuleInterface $module = null,
+ ?EyeInterface $eye = null,
+ ?Fill $fill = null
+ ) {
+ $this->margin = $margin;
+ $this->size = $size;
+ $this->module = $module ?: SquareModule::instance();
+ $this->eye = $eye ?: new ModuleEye($this->module);
+ $this->fill = $fill ?: Fill::default();
+ }
+
+ public function withSize(int $size) : self
+ {
+ $style = clone $this;
+ $style->size = $size;
+ return $style;
+ }
+
+ public function withMargin(int $margin) : self
+ {
+ $style = clone $this;
+ $style->margin = $margin;
+ return $style;
+ }
+
+ public function getSize() : int
+ {
+ return $this->size;
+ }
+
+ public function getMargin() : int
+ {
+ return $this->margin;
+ }
+
+ public function getModule() : ModuleInterface
+ {
+ return $this->module;
+ }
+
+ public function getEye() : EyeInterface
+ {
+ return $this->eye;
+ }
+
+ public function getFill() : Fill
+ {
+ return $this->fill;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Writer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Writer.php
new file mode 100644
index 0000000..d5bdc5c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/src/Writer.php
@@ -0,0 +1,71 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCode;
+
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\Version;
+use BaconQrCode\Encoder\Encoder;
+use BaconQrCode\Exception\InvalidArgumentException;
+use BaconQrCode\Renderer\RendererInterface;
+
+/**
+ * QR code writer.
+ */
+final class Writer
+{
+ /**
+ * Renderer instance.
+ *
+ * @var RendererInterface
+ */
+ private $renderer;
+
+ /**
+ * Creates a new writer with a specific renderer.
+ */
+ public function __construct(RendererInterface $renderer)
+ {
+ $this->renderer = $renderer;
+ }
+
+ /**
+ * Writes QR code and returns it as string.
+ *
+ * Content is a string which *should* be encoded in UTF-8, in case there are
+ * non ASCII-characters present.
+ *
+ * @throws InvalidArgumentException if the content is empty
+ */
+ public function writeString(
+ string $content,
+ string $encoding = Encoder::DEFAULT_BYTE_MODE_ECODING,
+ ?ErrorCorrectionLevel $ecLevel = null,
+ ?Version $forcedVersion = null
+ ) : string {
+ if (strlen($content) === 0) {
+ throw new InvalidArgumentException('Found empty contents');
+ }
+
+ if (null === $ecLevel) {
+ $ecLevel = ErrorCorrectionLevel::L();
+ }
+
+ return $this->renderer->render(Encoder::encode($content, $ecLevel, $encoding, $forcedVersion));
+ }
+
+ /**
+ * Writes QR code to a file.
+ *
+ * @see Writer::writeString()
+ */
+ public function writeFile(
+ string $content,
+ string $filename,
+ string $encoding = Encoder::DEFAULT_BYTE_MODE_ECODING,
+ ?ErrorCorrectionLevel $ecLevel = null,
+ ?Version $forcedVersion = null
+ ) : void {
+ file_put_contents($filename, $this->writeString($content, $encoding, $ecLevel, $forcedVersion));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitArrayTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitArrayTest.php
new file mode 100644
index 0000000..add798b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitArrayTest.php
@@ -0,0 +1,222 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\BitArray;
+use PHPUnit\Framework\TestCase;
+use PHPUnit\Runner\Version as PHPUnitVersion;
+
+final class BitArrayTest extends TestCase
+{
+ private function getPhpUnitMajorVersion(): int
+ {
+ return (int) explode('.', PHPUnitVersion::id())[0];
+ }
+
+ public function testGetSet() : void
+ {
+ $array = new BitArray(33);
+
+ for ($i = 0; $i < 33; ++$i) {
+ $this->assertFalse($array->get($i));
+ $array->set($i);
+ $this->assertTrue($array->get($i));
+ }
+ }
+
+ public function testGetNextSet1() : void
+ {
+ $array = new BitArray(32);
+
+ for ($i = 0; $i < $array->getSize(); ++$i) {
+ if ($this->getPhpUnitMajorVersion() === 7) {
+ $this->assertEquals($i, 32, '', $array->getNextSet($i));
+ } else {
+ $this->assertEqualsWithDelta($i, 32, $array->getNextSet($i));
+ }
+ }
+
+ $array = new BitArray(33);
+
+ for ($i = 0; $i < $array->getSize(); ++$i) {
+ if ($this->getPhpUnitMajorVersion() === 7) {
+ $this->assertEquals($i, 33, '', $array->getNextSet($i));
+ } else {
+ $this->assertEqualsWithDelta($i, 33, $array->getNextSet($i));
+ }
+ }
+ }
+
+ public function testGetNextSet2() : void
+ {
+ $array = new BitArray(33);
+
+ for ($i = 0; $i < $array->getSize(); ++$i) {
+ if ($this->getPhpUnitMajorVersion() === 7) {
+ $this->assertEquals($i, $i <= 31 ? 31 : 33, '', $array->getNextSet($i));
+ } else {
+ $this->assertEqualsWithDelta($i, $i <= 31 ? 31 : 33, $array->getNextSet($i));
+ }
+ }
+
+ $array = new BitArray(33);
+
+ for ($i = 0; $i < $array->getSize(); ++$i) {
+ if ($this->getPhpUnitMajorVersion() === 7) {
+ $this->assertEquals($i, 32, '', $array->getNextSet($i));
+ } else {
+ $this->assertEqualsWithDelta($i, 32, $array->getNextSet($i));
+ }
+ }
+ }
+
+ public function testGetNextSet3() : void
+ {
+ $array = new BitArray(63);
+ $array->set(31);
+ $array->set(32);
+
+ for ($i = 0; $i < $array->getSize(); ++$i) {
+ if ($i <= 31) {
+ $expected = 31;
+ } elseif ($i <= 32) {
+ $expected = 32;
+ } else {
+ $expected = 63;
+ }
+
+ if ($this->getPhpUnitMajorVersion() === 7) {
+ $this->assertEquals($i, $expected, '', $array->getNextSet($i));
+ } else {
+ $this->assertEqualsWithDelta($i, $expected, $array->getNextSet($i));
+ }
+ }
+ }
+
+ public function testGetNextSet4() : void
+ {
+ $array = new BitArray(63);
+ $array->set(33);
+ $array->set(40);
+
+ for ($i = 0; $i < $array->getSize(); ++$i) {
+ if ($i <= 33) {
+ $expected = 33;
+ } elseif ($i <= 40) {
+ $expected = 40;
+ } else {
+ $expected = 63;
+ }
+
+ if ($this->getPhpUnitMajorVersion() === 7) {
+ $this->assertEquals($i, $expected, '', $array->getNextSet($i));
+ } else {
+ $this->assertEqualsWithDelta($i, $expected, $array->getNextSet($i));
+ }
+ }
+ }
+
+ public function testGetNextSet5() : void
+ {
+ mt_srand(0xdeadbeef, MT_RAND_PHP);
+
+ for ($i = 0; $i < 10; ++$i) {
+ $array = new BitArray(mt_rand(1, 100));
+ $numSet = mt_rand(0, 19);
+
+ for ($j = 0; $j < $numSet; ++$j) {
+ $array->set(mt_rand(0, $array->getSize() - 1));
+ }
+
+ $numQueries = mt_rand(0, 19);
+
+ for ($j = 0; $j < $numQueries; ++$j) {
+ $query = mt_rand(0, $array->getSize() - 1);
+ $expected = $query;
+
+ while ($expected < $array->getSize() && ! $array->get($expected)) {
+ ++$expected;
+ }
+
+ $actual = $array->getNextSet($query);
+
+ if ($actual !== $expected) {
+ $array->getNextSet($query);
+ }
+
+ $this->assertEquals($expected, $actual);
+ }
+ }
+ }
+
+ public function testSetBulk() : void
+ {
+ $array = new BitArray(64);
+ $array->setBulk(32, 0xFFFF0000);
+
+ for ($i = 0; $i < 48; ++$i) {
+ $this->assertFalse($array->get($i));
+ }
+
+ for ($i = 48; $i < 64; ++$i) {
+ $this->assertTrue($array->get($i));
+ }
+ }
+
+ public function testClear() : void
+ {
+ $array = new BitArray(32);
+
+ for ($i = 0; $i < 32; ++$i) {
+ $array->set($i);
+ }
+
+ $array->clear();
+
+ for ($i = 0; $i < 32; ++$i) {
+ $this->assertFalse($array->get($i));
+ }
+ }
+
+ public function testGetArray() : void
+ {
+ $array = new BitArray(64);
+ $array->set(0);
+ $array->set(63);
+
+ $ints = $array->getBitArray();
+
+ $this->assertSame(1, $ints[0]);
+ $this->assertSame(0x80000000, $ints[1]);
+ }
+
+ public function testIsRange() : void
+ {
+ $array = new BitArray(64);
+ $this->assertTrue($array->isRange(0, 64, false));
+ $this->assertFalse($array->isRange(0, 64, true));
+
+ $array->set(32);
+ $this->assertTrue($array->isRange(32, 33, true));
+
+ $array->set(31);
+ $this->assertTrue($array->isRange(31, 33, true));
+
+ $array->set(34);
+ $this->assertFalse($array->isRange(31, 35, true));
+
+ for ($i = 0; $i < 31; ++$i) {
+ $array->set($i);
+ }
+
+ $this->assertTrue($array->isRange(0, 33, true));
+
+ for ($i = 33; $i < 64; ++$i) {
+ $array->set($i);
+ }
+
+ $this->assertTrue($array->isRange(0, 64, true));
+ $this->assertFalse($array->isRange(0, 64, false));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitMatrixTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitMatrixTest.php
new file mode 100644
index 0000000..8ad86d4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitMatrixTest.php
@@ -0,0 +1,115 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\BitArray;
+use BaconQrCode\Common\BitMatrix;
+use PHPUnit\Framework\TestCase;
+
+class BitMatrixTest extends TestCase
+{
+ public function testGetSet() : void
+ {
+ $matrix = new BitMatrix(33);
+ $this->assertEquals(33, $matrix->getHeight());
+
+ for ($y = 0; $y < 33; ++$y) {
+ for ($x = 0; $x < 33; ++$x) {
+ if ($y * $x % 3 === 0) {
+ $matrix->set($x, $y);
+ }
+ }
+ }
+
+ for ($y = 0; $y < 33; $y++) {
+ for ($x = 0; $x < 33; ++$x) {
+ $this->assertSame(0 === $x * $y % 3, $matrix->get($x, $y));
+ }
+ }
+ }
+
+ public function testSetRegion() : void
+ {
+ $matrix = new BitMatrix(5);
+ $matrix->setRegion(1, 1, 3, 3);
+
+ for ($y = 0; $y < 5; ++$y) {
+ for ($x = 0; $x < 5; ++$x) {
+ $this->assertSame($y >= 1 && $y <= 3 && $x >= 1 && $x <= 3, $matrix->get($x, $y));
+ }
+ }
+ }
+
+ public function testRectangularMatrix() : void
+ {
+ $matrix = new BitMatrix(75, 20);
+ $this->assertSame(75, $matrix->getWidth());
+ $this->assertSame(20, $matrix->getHeight());
+
+ $matrix->set(10, 0);
+ $matrix->set(11, 1);
+ $matrix->set(50, 2);
+ $matrix->set(51, 3);
+ $matrix->flip(74, 4);
+ $matrix->flip(0, 5);
+
+ $this->assertTrue($matrix->get(10, 0));
+ $this->assertTrue($matrix->get(11, 1));
+ $this->assertTrue($matrix->get(50, 2));
+ $this->assertTrue($matrix->get(51, 3));
+ $this->assertTrue($matrix->get(74, 4));
+ $this->assertTrue($matrix->get(0, 5));
+
+ $matrix->flip(50, 2);
+ $matrix->flip(51, 3);
+
+ $this->assertFalse($matrix->get(50, 2));
+ $this->assertFalse($matrix->get(51, 3));
+ }
+
+ public function testRectangularSetRegion() : void
+ {
+ $matrix = new BitMatrix(320, 240);
+ $this->assertSame(320, $matrix->getWidth());
+ $this->assertSame(240, $matrix->getHeight());
+
+ $matrix->setRegion(105, 22, 80, 12);
+
+ for ($y = 0; $y < 240; ++$y) {
+ for ($x = 0; $x < 320; ++$x) {
+ $this->assertEquals($y >= 22 && $y < 34 && $x >= 105 && $x < 185, $matrix->get($x, $y));
+ }
+ }
+ }
+
+ public function testGetRow() : void
+ {
+ $matrix = new BitMatrix(102, 5);
+
+ for ($x = 0; $x < 102; ++$x) {
+ if (0 === ($x & 3)) {
+ $matrix->set($x, 2);
+ }
+ }
+
+ $array1 = $matrix->getRow(2, null);
+ $this->assertSame(102, $array1->getSize());
+
+ $array2 = new BitArray(60);
+ $array2 = $matrix->getRow(2, $array2);
+ $this->assertSame(102, $array2->getSize());
+
+ $array3 = new BitArray(200);
+ $array3 = $matrix->getRow(2, $array3);
+ $this->assertSame(200, $array3->getSize());
+
+ for ($x = 0; $x < 102; ++$x) {
+ $on = (0 === ($x & 3));
+
+ $this->assertSame($on, $array1->get($x));
+ $this->assertSame($on, $array2->get($x));
+ $this->assertSame($on, $array3->get($x));
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitUtilsTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitUtilsTest.php
new file mode 100644
index 0000000..2904d31
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/BitUtilsTest.php
@@ -0,0 +1,25 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\BitUtils;
+use PHPUnit\Framework\TestCase;
+
+class BitUtilsTest extends TestCase
+{
+ public function testUnsignedRightShift() : void
+ {
+ $this->assertSame(1, BitUtils::unsignedRightShift(1, 0));
+ $this->assertSame(1, BitUtils::unsignedRightShift(10, 3));
+ $this->assertSame(536870910, BitUtils::unsignedRightShift(-10, 3));
+ }
+
+ public function testNumberOfTrailingZeros() : void
+ {
+ $this->assertSame(32, BitUtils::numberOfTrailingZeros(0));
+ $this->assertSame(1, BitUtils::numberOfTrailingZeros(10));
+ $this->assertSame(0, BitUtils::numberOfTrailingZeros(15));
+ $this->assertSame(2, BitUtils::numberOfTrailingZeros(20));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ErrorCorrectionLevelTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ErrorCorrectionLevelTest.php
new file mode 100644
index 0000000..369b5d9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ErrorCorrectionLevelTest.php
@@ -0,0 +1,25 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Exception\OutOfBoundsException;
+use PHPUnit\Framework\TestCase;
+
+class ErrorCorrectionLevelTest extends TestCase
+{
+ public function testBitsMatchConstants() : void
+ {
+ $this->assertSame(0x0, ErrorCorrectionLevel::M()->getBits());
+ $this->assertSame(0x1, ErrorCorrectionLevel::L()->getBits());
+ $this->assertSame(0x2, ErrorCorrectionLevel::H()->getBits());
+ $this->assertSame(0x3, ErrorCorrectionLevel::Q()->getBits());
+ }
+
+ public function testInvalidErrorCorrectionLevelThrowsException() : void
+ {
+ $this->expectException(OutOfBoundsException::class);
+ ErrorCorrectionLevel::forBits(4);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/FormatInformationTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/FormatInformationTest.php
new file mode 100644
index 0000000..39534a2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/FormatInformationTest.php
@@ -0,0 +1,94 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\FormatInformation;
+use PHPUnit\Framework\TestCase;
+
+class FormatInformationTest extends TestCase
+{
+ private const MASKED_TEST_FORMAT_INFO = 0x2bed;
+ private const UNMAKSED_TEST_FORMAT_INFO = self::MASKED_TEST_FORMAT_INFO ^ 0x5412;
+
+ public function testBitsDiffering() : void
+ {
+ $this->assertSame(0, FormatInformation::numBitsDiffering(1, 1));
+ $this->assertSame(1, FormatInformation::numBitsDiffering(0, 2));
+ $this->assertSame(2, FormatInformation::numBitsDiffering(1, 2));
+ $this->assertEquals(32, FormatInformation::numBitsDiffering(-1, 0));
+ }
+
+ public function testDecode() : void
+ {
+ $expected = FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO,
+ self::MASKED_TEST_FORMAT_INFO
+ );
+
+ $this->assertNotNull($expected);
+ $this->assertSame(7, $expected->getDataMask());
+ $this->assertSame(ErrorCorrectionLevel::Q(), $expected->getErrorCorrectionLevel());
+
+ $this->assertEquals(
+ $expected,
+ FormatInformation::decodeFormatInformation(
+ self::UNMAKSED_TEST_FORMAT_INFO,
+ self::MASKED_TEST_FORMAT_INFO
+ )
+ );
+ }
+
+ public function testDecodeWithBitDifference() : void
+ {
+ $expected = FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO,
+ self::MASKED_TEST_FORMAT_INFO
+ );
+
+ $this->assertEquals(
+ $expected,
+ FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO ^ 0x1,
+ self::MASKED_TEST_FORMAT_INFO ^ 0x1
+ )
+ );
+ $this->assertEquals(
+ $expected,
+ FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO ^ 0x3,
+ self::MASKED_TEST_FORMAT_INFO ^ 0x3
+ )
+ );
+ $this->assertEquals(
+ $expected,
+ FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO ^ 0x7,
+ self::MASKED_TEST_FORMAT_INFO ^ 0x7
+ )
+ );
+ $this->assertNull(
+ FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO ^ 0xf,
+ self::MASKED_TEST_FORMAT_INFO ^ 0xf
+ )
+ );
+ }
+
+ public function testDecodeWithMisRead() : void
+ {
+ $expected = FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO,
+ self::MASKED_TEST_FORMAT_INFO
+ );
+
+ $this->assertEquals(
+ $expected,
+ FormatInformation::decodeFormatInformation(
+ self::MASKED_TEST_FORMAT_INFO ^ 0x3,
+ self::MASKED_TEST_FORMAT_INFO ^ 0xf
+ )
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ModeTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ModeTest.php
new file mode 100644
index 0000000..51fcb3e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ModeTest.php
@@ -0,0 +1,19 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\Mode;
+use PHPUnit\Framework\TestCase;
+
+class ModeTest extends TestCase
+{
+ public function testBitsMatchConstants() : void
+ {
+ $this->assertSame(0x0, Mode::TERMINATOR()->getBits());
+ $this->assertSame(0x1, Mode::NUMERIC()->getBits());
+ $this->assertSame(0x2, Mode::ALPHANUMERIC()->getBits());
+ $this->assertSame(0x4, Mode::BYTE()->getBits());
+ $this->assertSame(0x8, Mode::KANJI()->getBits());
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ReedSolomonCodecTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ReedSolomonCodecTest.php
new file mode 100644
index 0000000..47975b5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/ReedSolomonCodecTest.php
@@ -0,0 +1,96 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\ReedSolomonCodec;
+use PHPUnit\Framework\TestCase;
+use SplFixedArray;
+
+class ReedSolomonTest extends TestCase
+{
+ public function tabs() : array
+ {
+ return [
+ [2, 0x7, 1, 1, 1],
+ [3, 0xb, 1, 1, 2],
+ [4, 0x13, 1, 1, 4],
+ [5, 0x25, 1, 1, 6],
+ [6, 0x43, 1, 1, 8],
+ [7, 0x89, 1, 1, 10],
+ [8, 0x11d, 1, 1, 32],
+ ];
+ }
+
+ /**
+ * @dataProvider tabs
+ */
+ public function testCodec(int $symbolSize, int $generatorPoly, int $firstRoot, int $primitive, int $numRoots) : void
+ {
+ mt_srand(0xdeadbeef, MT_RAND_PHP);
+
+ $blockSize = (1 << $symbolSize) - 1;
+ $dataSize = $blockSize - $numRoots;
+ $codec = new ReedSolomonCodec($symbolSize, $generatorPoly, $firstRoot, $primitive, $numRoots, 0);
+
+ for ($errors = 0; $errors <= $numRoots / 2; ++$errors) {
+ // Load block with random data and encode
+ $block = SplFixedArray::fromArray(array_fill(0, $blockSize, 0), false);
+
+ for ($i = 0; $i < $dataSize; ++$i) {
+ $block[$i] = mt_rand(0, $blockSize);
+ }
+
+ // Make temporary copy
+ $tBlock = clone $block;
+ $parity = SplFixedArray::fromArray(array_fill(0, $numRoots, 0), false);
+ $errorLocations = SplFixedArray::fromArray(array_fill(0, $blockSize, 0), false);
+ $erasures = [];
+
+ // Create parity
+ $codec->encode($block, $parity);
+
+ // Copy parity into test blocks
+ for ($i = 0; $i < $numRoots; ++$i) {
+ $block[$i + $dataSize] = $parity[$i];
+ $tBlock[$i + $dataSize] = $parity[$i];
+ }
+
+ // Seed with errors
+ for ($i = 0; $i < $errors; ++$i) {
+ $errorValue = mt_rand(1, $blockSize);
+
+ do {
+ $errorLocation = mt_rand(0, $blockSize);
+ } while (0 !== $errorLocations[$errorLocation]);
+
+ $errorLocations[$errorLocation] = 1;
+
+ if (mt_rand(0, 1)) {
+ $erasures[] = $errorLocation;
+ }
+
+ $tBlock[$errorLocation] ^= $errorValue;
+ }
+
+ $erasures = SplFixedArray::fromArray($erasures, false);
+
+ // Decode the errored block
+ $foundErrors = $codec->decode($tBlock, $erasures);
+
+ if ($errors > 0 && null === $foundErrors) {
+ $this->assertSame($block, $tBlock, 'Decoder failed to correct errors');
+ }
+
+ $this->assertSame($errors, $foundErrors, 'Found errors do not equal expected errors');
+
+ for ($i = 0; $i < $foundErrors; ++$i) {
+ if (0 === $errorLocations[$erasures[$i]]) {
+ $this->fail(sprintf('Decoder indicates error in location %d without error', $erasures[$i]));
+ }
+ }
+
+ $this->assertEquals($block, $tBlock, 'Decoder did not correct errors');
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/VersionTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/VersionTest.php
new file mode 100644
index 0000000..f6f038b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Common/VersionTest.php
@@ -0,0 +1,78 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Common;
+
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\Version;
+use PHPUnit\Framework\TestCase;
+
+class VersionTest extends TestCase
+{
+ public function versions() : array
+ {
+ $array = [];
+
+ for ($i = 1; $i <= 40; ++$i) {
+ $array[] = [$i, 4 * $i + 17];
+ }
+
+ return $array;
+ }
+
+ public function decodeInformation() : array
+ {
+ return [
+ [7, 0x07c94],
+ [12, 0x0c762],
+ [17, 0x1145d],
+ [22, 0x168c9],
+ [27, 0x1b08e],
+ [32, 0x209d5],
+ ];
+ }
+
+ /**
+ * @dataProvider versions
+ */
+ public function testVersionForNumber(int $versionNumber, int $dimension) : void
+ {
+ $version = Version::getVersionForNumber($versionNumber);
+
+ $this->assertNotNull($version);
+ $this->assertEquals($versionNumber, $version->getVersionNumber());
+ $this->assertNotNull($version->getAlignmentPatternCenters());
+
+ if ($versionNumber > 1) {
+ $this->assertTrue(count($version->getAlignmentPatternCenters()) > 0);
+ }
+
+ $this->assertEquals($dimension, $version->getDimensionForVersion());
+ $this->assertNotNull($version->getEcBlocksForLevel(ErrorCorrectionLevel::H()));
+ $this->assertNotNull($version->getEcBlocksForLevel(ErrorCorrectionLevel::L()));
+ $this->assertNotNull($version->getEcBlocksForLevel(ErrorCorrectionLevel::M()));
+ $this->assertNotNull($version->getEcBlocksForLevel(ErrorCorrectionLevel::Q()));
+ $this->assertNotNull($version->buildFunctionPattern());
+ }
+
+ /**
+ * @dataProvider versions
+ */
+ public function testGetProvisionalVersionForDimension(int $versionNumber, int $dimension) : void
+ {
+ $this->assertSame(
+ $versionNumber,
+ Version::getProvisionalVersionForDimension($dimension)->getVersionNumber()
+ );
+ }
+
+ /**
+ * @dataProvider decodeInformation
+ */
+ public function testDecodeVersionInformation(int $expectedVersion, int $mask) : void
+ {
+ $version = Version::decodeVersionInformation($mask);
+ $this->assertNotNull($version);
+ $this->assertSame($expectedVersion, $version->getVersionNumber());
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/EncoderTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/EncoderTest.php
new file mode 100644
index 0000000..9baa66b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/EncoderTest.php
@@ -0,0 +1,487 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Encoder;
+
+use BaconQrCode\Common\BitArray;
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\Mode;
+use BaconQrCode\Common\Version;
+use BaconQrCode\Encoder\Encoder;
+use BaconQrCode\Exception\WriterException;
+use PHPUnit\Framework\TestCase;
+use ReflectionClass;
+use ReflectionMethod;
+use SplFixedArray;
+
+final class EncoderTest extends TestCase
+{
+ /**
+ * @var ReflectionMethod[]
+ */
+ protected $methods = [];
+
+ public function setUp() : void
+ {
+ // Hack to be able to test protected methods
+ $reflection = new ReflectionClass(Encoder::class);
+
+ foreach ($reflection->getMethods(ReflectionMethod::IS_STATIC) as $method) {
+ $method->setAccessible(true);
+ $this->methods[$method->getName()] = $method;
+ }
+ }
+
+ public function testGetAlphanumericCode() : void
+ {
+ // The first ten code points are numbers.
+ for ($i = 0; $i < 10; ++$i) {
+ $this->assertSame($i, $this->methods['getAlphanumericCode']->invoke(null, ord('0') + $i));
+ }
+
+ // The next 26 code points are capital alphabet letters.
+ for ($i = 10; $i < 36; ++$i) {
+ // The first ten code points are numbers
+ $this->assertSame($i, $this->methods['getAlphanumericCode']->invoke(null, ord('A') + $i - 10));
+ }
+
+ // Others are symbol letters.
+ $this->assertSame(36, $this->methods['getAlphanumericCode']->invoke(null, ord(' ')));
+ $this->assertSame(37, $this->methods['getAlphanumericCode']->invoke(null, ord('$')));
+ $this->assertSame(38, $this->methods['getAlphanumericCode']->invoke(null, ord('%')));
+ $this->assertSame(39, $this->methods['getAlphanumericCode']->invoke(null, ord('*')));
+ $this->assertSame(40, $this->methods['getAlphanumericCode']->invoke(null, ord('+')));
+ $this->assertSame(41, $this->methods['getAlphanumericCode']->invoke(null, ord('-')));
+ $this->assertSame(42, $this->methods['getAlphanumericCode']->invoke(null, ord('.')));
+ $this->assertSame(43, $this->methods['getAlphanumericCode']->invoke(null, ord('/')));
+ $this->assertSame(44, $this->methods['getAlphanumericCode']->invoke(null, ord(':')));
+
+ // Should return -1 for other letters.
+ $this->assertSame(-1, $this->methods['getAlphanumericCode']->invoke(null, ord('a')));
+ $this->assertSame(-1, $this->methods['getAlphanumericCode']->invoke(null, ord('#')));
+ $this->assertSame(-1, $this->methods['getAlphanumericCode']->invoke(null, ord("\0")));
+ }
+
+ public function testChooseMode() : void
+ {
+ // Numeric mode
+ $this->assertSame(Mode::NUMERIC(), $this->methods['chooseMode']->invoke(null, '0'));
+ $this->assertSame(Mode::NUMERIC(), $this->methods['chooseMode']->invoke(null, '0123456789'));
+
+ // Alphanumeric mode
+ $this->assertSame(Mode::ALPHANUMERIC(), $this->methods['chooseMode']->invoke(null, 'A'));
+ $this->assertSame(
+ Mode::ALPHANUMERIC(),
+ $this->methods['chooseMode']->invoke(null, '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:')
+ );
+
+ // 8-bit byte mode
+ $this->assertSame(Mode::BYTE(), $this->methods['chooseMode']->invoke(null, 'a'));
+ $this->assertSame(Mode::BYTE(), $this->methods['chooseMode']->invoke(null, '#'));
+ $this->assertSame(Mode::BYTE(), $this->methods['chooseMode']->invoke(null, ''));
+
+ // AIUE in Hiragana in SHIFT-JIS
+ $this->assertSame(Mode::BYTE(), $this->methods['chooseMode']->invoke(null, "\x8\xa\x8\xa\x8\xa\x8\xa6"));
+
+ // Nihon in Kanji in SHIFT-JIS
+ $this->assertSame(Mode::BYTE(), $this->methods['chooseMode']->invoke(null, "\x9\xf\x9\x7b"));
+
+ // Sou-Utso-Byou in Kanji in SHIFT-JIS
+ $this->assertSame(Mode::BYTE(), $this->methods['chooseMode']->invoke(null, "\xe\x4\x9\x5\x9\x61"));
+ }
+
+ public function testEncode() : void
+ {
+ $qrCode = Encoder::encode('ABCDEF', ErrorCorrectionLevel::H());
+ $expected = "<<\n"
+ . " mode: ALPHANUMERIC\n"
+ . " ecLevel: H\n"
+ . " version: 1\n"
+ . " maskPattern: 0\n"
+ . " matrix:\n"
+ . " 1 1 1 1 1 1 1 0 1 1 1 1 0 0 1 1 1 1 1 1 1\n"
+ . " 1 0 0 0 0 0 1 0 0 1 1 1 0 0 1 0 0 0 0 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 1 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 1 1 1 0 1 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 0 0 0 0 1 0 0 1 0 0 0 0 1 0 0 0 0 0 1\n"
+ . " 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1\n"
+ . " 0 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0\n"
+ . " 0 0 1 0 1 1 1 0 1 1 0 0 1 1 0 0 0 1 0 0 1\n"
+ . " 1 0 1 1 1 0 0 1 0 0 0 1 0 1 0 0 0 0 0 0 0\n"
+ . " 0 0 1 1 0 0 1 0 1 0 0 0 1 0 1 0 1 0 1 1 0\n"
+ . " 1 1 0 1 0 1 0 1 1 1 0 1 0 1 0 0 0 0 0 1 0\n"
+ . " 0 0 1 1 0 1 1 1 1 0 0 0 1 0 1 0 1 1 1 1 0\n"
+ . " 0 0 0 0 0 0 0 0 1 0 0 1 1 1 0 1 0 1 0 0 0\n"
+ . " 1 1 1 1 1 1 1 0 0 0 1 0 1 0 1 1 0 0 0 0 1\n"
+ . " 1 0 0 0 0 0 1 0 1 1 1 1 0 1 0 1 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 1 0 1 1 0 1 0 1 0 0 0 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 1 0 1 1 1 1 0 1 0 1 0\n"
+ . " 1 0 1 1 1 0 1 0 1 0 0 0 1 0 1 0 1 1 1 0 1\n"
+ . " 1 0 0 0 0 0 1 0 0 1 1 0 1 1 0 1 0 0 0 1 1\n"
+ . " 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 1 0 1 0 1\n"
+ . ">>\n";
+
+ $this->assertSame($expected, (string) $qrCode);
+ }
+
+ public function testSimpleUtf8Eci() : void
+ {
+ $qrCode = Encoder::encode('hello', ErrorCorrectionLevel::H(), 'utf-8');
+ $expected = "<<\n"
+ . " mode: BYTE\n"
+ . " ecLevel: H\n"
+ . " version: 1\n"
+ . " maskPattern: 3\n"
+ . " matrix:\n"
+ . " 1 1 1 1 1 1 1 0 0 0 0 0 0 0 1 1 1 1 1 1 1\n"
+ . " 1 0 0 0 0 0 1 0 0 0 1 0 1 0 1 0 0 0 0 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 1 0 1 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 1 1 0 1\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 0 1 0 1 0 0 0 0 0 1\n"
+ . " 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1\n"
+ . " 0 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0\n"
+ . " 0 0 1 1 0 0 1 1 1 1 0 0 0 1 1 0 1 0 0 0 0\n"
+ . " 0 0 1 1 1 0 0 0 0 0 1 1 0 0 0 1 0 1 1 1 0\n"
+ . " 0 1 0 1 0 1 1 1 0 1 0 1 0 0 0 0 0 1 1 1 1\n"
+ . " 1 1 0 0 1 0 0 1 1 0 0 1 1 1 1 0 1 0 1 1 0\n"
+ . " 0 0 0 0 1 0 1 1 1 1 0 0 0 0 0 1 0 0 1 0 0\n"
+ . " 0 0 0 0 0 0 0 0 1 1 1 1 0 0 1 1 1 0 0 0 1\n"
+ . " 1 1 1 1 1 1 1 0 1 1 1 0 1 0 1 1 0 0 1 0 0\n"
+ . " 1 0 0 0 0 0 1 0 0 0 1 0 0 1 1 1 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 0 0 0 1 1 0 0 0 0 0\n"
+ . " 1 0 1 1 1 0 1 0 1 1 1 0 1 0 0 0 1 1 0 0 0\n"
+ . " 1 0 1 1 1 0 1 0 1 1 0 0 0 1 0 0 1 0 0 0 0\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 1 1 0 1 0 1 0 1 1 0\n"
+ . " 1 1 1 1 1 1 1 0 0 1 0 1 1 1 0 1 1 0 0 0 0\n"
+ . ">>\n";
+
+ $this->assertSame($expected, (string) $qrCode);
+ }
+
+ public function testAppendModeInfo() : void
+ {
+ $bits = new BitArray();
+ $this->methods['appendModeInfo']->invoke(null, Mode::NUMERIC(), $bits);
+ $this->assertSame(' ...X', (string) $bits);
+ }
+
+ public function testAppendLengthInfo() : void
+ {
+ // 1 letter (1/1), 10 bits.
+ $bits = new BitArray();
+ $this->methods['appendLengthInfo']->invoke(
+ null,
+ 1,
+ Version::getVersionForNumber(1),
+ Mode::NUMERIC(),
+ $bits
+ );
+ $this->assertSame(' ........ .X', (string) $bits);
+
+ // 2 letters (2/1), 11 bits.
+ $bits = new BitArray();
+ $this->methods['appendLengthInfo']->invoke(
+ null,
+ 2,
+ Version::getVersionForNumber(10),
+ Mode::ALPHANUMERIC(),
+ $bits
+ );
+ $this->assertSame(' ........ .X.', (string) $bits);
+
+ // 255 letters (255/1), 16 bits.
+ $bits = new BitArray();
+ $this->methods['appendLengthInfo']->invoke(
+ null,
+ 255,
+ Version::getVersionForNumber(27),
+ Mode::BYTE(),
+ $bits
+ );
+ $this->assertSame(' ........ XXXXXXXX', (string) $bits);
+
+ // 512 letters (1024/2), 12 bits.
+ $bits = new BitArray();
+ $this->methods['appendLengthInfo']->invoke(
+ null,
+ 512,
+ Version::getVersionForNumber(40),
+ Mode::KANJI(),
+ $bits
+ );
+ $this->assertSame(' ..X..... ....', (string) $bits);
+ }
+
+ public function testAppendBytes() : void
+ {
+ // Should use appendNumericBytes.
+ // 1 = 01 = 0001 in 4 bits.
+ $bits = new BitArray();
+ $this->methods['appendBytes']->invoke(
+ null,
+ '1',
+ Mode::NUMERIC(),
+ $bits,
+ Encoder::DEFAULT_BYTE_MODE_ECODING
+ );
+ $this->assertSame(' ...X', (string) $bits);
+
+ // Should use appendAlphaNumericBytes.
+ // A = 10 = 0xa = 001010 in 6 bits.
+ $bits = new BitArray();
+ $this->methods['appendBytes']->invoke(
+ null,
+ 'A',
+ Mode::ALPHANUMERIC(),
+ $bits,
+ Encoder::DEFAULT_BYTE_MODE_ECODING
+ );
+ $this->assertSame(' ..X.X.', (string) $bits);
+
+ // Should use append8BitBytes.
+ // 0x61, 0x62, 0x63
+ $bits = new BitArray();
+ $this->methods['appendBytes']->invoke(
+ null,
+ 'abc',
+ Mode::BYTE(),
+ $bits,
+ Encoder::DEFAULT_BYTE_MODE_ECODING
+ );
+ $this->assertSame(' .XX....X .XX...X. .XX...XX', (string) $bits);
+
+ // Should use appendKanjiBytes.
+ // 0x93, 0x5f
+ $bits = new BitArray();
+ $this->methods['appendBytes']->invoke(
+ null,
+ "\x93\x5f",
+ Mode::KANJI(),
+ $bits,
+ Encoder::DEFAULT_BYTE_MODE_ECODING
+ );
+ $this->assertSame(' .XX.XX.. XXXXX', (string) $bits);
+
+ // Lower letters such as 'a' cannot be encoded in alphanumeric mode.
+ $this->expectException(WriterException::class);
+ $this->methods['appendBytes']->invoke(
+ null,
+ 'a',
+ Mode::ALPHANUMERIC(),
+ $bits,
+ Encoder::DEFAULT_BYTE_MODE_ECODING
+ );
+ }
+
+ public function testTerminateBits() : void
+ {
+ $bits = new BitArray();
+ $this->methods['terminateBits']->invoke(null, 0, $bits);
+ $this->assertSame('', (string) $bits);
+
+ $bits = new BitArray();
+ $this->methods['terminateBits']->invoke(null, 1, $bits);
+ $this->assertSame(' ........', (string) $bits);
+
+ $bits = new BitArray();
+ $bits->appendBits(0, 3);
+ $this->methods['terminateBits']->invoke(null, 1, $bits);
+ $this->assertSame(' ........', (string) $bits);
+
+ $bits = new BitArray();
+ $bits->appendBits(0, 5);
+ $this->methods['terminateBits']->invoke(null, 1, $bits);
+ $this->assertSame(' ........', (string) $bits);
+
+ $bits = new BitArray();
+ $bits->appendBits(0, 8);
+ $this->methods['terminateBits']->invoke(null, 1, $bits);
+ $this->assertSame(' ........', (string) $bits);
+
+ $bits = new BitArray();
+ $this->methods['terminateBits']->invoke(null, 2, $bits);
+ $this->assertSame(' ........ XXX.XX..', (string) $bits);
+
+ $bits = new BitArray();
+ $bits->appendBits(0, 1);
+ $this->methods['terminateBits']->invoke(null, 3, $bits);
+ $this->assertSame(' ........ XXX.XX.. ...X...X', (string) $bits);
+ }
+
+ public function testGetNumDataBytesAndNumEcBytesForBlockId() : void
+ {
+ // Version 1-H.
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 26, 9, 1, 0);
+ $this->assertSame(9, $numDataBytes);
+ $this->assertSame(17, $numEcBytes);
+
+ // Version 3-H. 2 blocks.
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 70, 26, 2, 0);
+ $this->assertSame(13, $numDataBytes);
+ $this->assertSame(22, $numEcBytes);
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 70, 26, 2, 1);
+ $this->assertSame(13, $numDataBytes);
+ $this->assertSame(22, $numEcBytes);
+
+ // Version 7-H. (4 + 1) blocks.
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 196, 66, 5, 0);
+ $this->assertSame(13, $numDataBytes);
+ $this->assertSame(26, $numEcBytes);
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 196, 66, 5, 4);
+ $this->assertSame(14, $numDataBytes);
+ $this->assertSame(26, $numEcBytes);
+
+ // Version 40-H. (20 + 61) blocks.
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 3706, 1276, 81, 0);
+ $this->assertSame(15, $numDataBytes);
+ $this->assertSame(30, $numEcBytes);
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 3706, 1276, 81, 20);
+ $this->assertSame(16, $numDataBytes);
+ $this->assertSame(30, $numEcBytes);
+ list($numDataBytes, $numEcBytes) = $this->methods['getNumDataBytesAndNumEcBytesForBlockId']
+ ->invoke(null, 3706, 1276, 81, 80);
+ $this->assertSame(16, $numDataBytes);
+ $this->assertSame(30, $numEcBytes);
+ }
+
+ public function testInterleaveWithEcBytes() : void
+ {
+ $dataBytes = SplFixedArray::fromArray([32, 65, 205, 69, 41, 220, 46, 128, 236], false);
+ $in = new BitArray();
+
+ foreach ($dataBytes as $dataByte) {
+ $in->appendBits($dataByte, 8);
+ }
+
+ $outBits = $this->methods['interleaveWithEcBytes']->invoke(null, $in, 26, 9, 1);
+ $expected = SplFixedArray::fromArray([
+ // Data bytes.
+ 32, 65, 205, 69, 41, 220, 46, 128, 236,
+ // Error correction bytes.
+ 42, 159, 74, 221, 244, 169, 239, 150, 138, 70, 237, 85, 224, 96, 74, 219, 61,
+ ], false);
+
+ $out = $outBits->toBytes(0, count($expected));
+
+ $this->assertEquals($expected, $out);
+ }
+
+ public function testAppendNumericBytes() : void
+ {
+ // 1 = 01 = 0001 in 4 bits.
+ $bits = new BitArray();
+ $this->methods['appendNumericBytes']->invoke(null, '1', $bits);
+ $this->assertSame(' ...X', (string) $bits);
+
+ // 12 = 0xc = 0001100 in 7 bits.
+ $bits = new BitArray();
+ $this->methods['appendNumericBytes']->invoke(null, '12', $bits);
+ $this->assertSame(' ...XX..', (string) $bits);
+
+ // 123 = 0x7b = 0001111011 in 10 bits.
+ $bits = new BitArray();
+ $this->methods['appendNumericBytes']->invoke(null, '123', $bits);
+ $this->assertSame(' ...XXXX. XX', (string) $bits);
+
+ // 1234 = "123" + "4" = 0001111011 + 0100 in 14 bits.
+ $bits = new BitArray();
+ $this->methods['appendNumericBytes']->invoke(null, '1234', $bits);
+ $this->assertSame(' ...XXXX. XX.X..', (string) $bits);
+
+ // Empty
+ $bits = new BitArray();
+ $this->methods['appendNumericBytes']->invoke(null, '', $bits);
+ $this->assertSame('', (string) $bits);
+ }
+
+ public function testAppendAlphanumericBytes() : void
+ {
+ $bits = new BitArray();
+ $this->methods['appendAlphanumericBytes']->invoke(null, 'A', $bits);
+ $this->assertSame(' ..X.X.', (string) $bits);
+
+ $bits = new BitArray();
+ $this->methods['appendAlphanumericBytes']->invoke(null, 'AB', $bits);
+ $this->assertSame(' ..XXX..X X.X', (string) $bits);
+
+ $bits = new BitArray();
+ $this->methods['appendAlphanumericBytes']->invoke(null, 'ABC', $bits);
+ $this->assertSame(' ..XXX..X X.X..XX. .', (string) $bits);
+
+ // Empty
+ $bits = new BitArray();
+ $this->methods['appendAlphanumericBytes']->invoke(null, '', $bits);
+ $this->assertSame('', (string) $bits);
+
+ // Invalid data
+ $this->expectException(WriterException::class);
+ $bits = new BitArray();
+ $this->methods['appendAlphanumericBytes']->invoke(null, 'abc', $bits);
+ }
+
+ public function testAppend8BitBytes() : void
+ {
+ // 0x61, 0x62, 0x63
+ $bits = new BitArray();
+ $this->methods['append8BitBytes']->invoke(null, 'abc', $bits, Encoder::DEFAULT_BYTE_MODE_ECODING);
+ $this->assertSame(' .XX....X .XX...X. .XX...XX', (string) $bits);
+
+ // Empty
+ $bits = new BitArray();
+ $this->methods['append8BitBytes']->invoke(null, '', $bits, Encoder::DEFAULT_BYTE_MODE_ECODING);
+ $this->assertSame('', (string) $bits);
+ }
+
+ public function testAppendKanjiBytes() : void
+ {
+ // Numbers are from page 21 of JISX0510:2004
+ $bits = new BitArray();
+ $this->methods['appendKanjiBytes']->invoke(null, "\x93\x5f", $bits);
+ $this->assertSame(' .XX.XX.. XXXXX', (string) $bits);
+
+ $this->methods['appendKanjiBytes']->invoke(null, "\xe4\xaa", $bits);
+ $this->assertSame(' .XX.XX.. XXXXXXX. X.X.X.X. X.', (string) $bits);
+ }
+
+ public function testGenerateEcBytes() : void
+ {
+ // Numbers are from http://www.swetake.com/qr/qr3.html and
+ // http://www.swetake.com/qr/qr9.html
+ $dataBytes = SplFixedArray::fromArray([32, 65, 205, 69, 41, 220, 46, 128, 236], false);
+ $ecBytes = $this->methods['generateEcBytes']->invoke(null, $dataBytes, 17);
+ $expected = SplFixedArray::fromArray(
+ [42, 159, 74, 221, 244, 169, 239, 150, 138, 70, 237, 85, 224, 96, 74, 219, 61],
+ false
+ );
+ $this->assertEquals($expected, $ecBytes);
+
+ $dataBytes = SplFixedArray::fromArray(
+ [67, 70, 22, 38, 54, 70, 86, 102, 118, 134, 150, 166, 182, 198, 214],
+ false
+ );
+ $ecBytes = $this->methods['generateEcBytes']->invoke(null, $dataBytes, 18);
+ $expected = SplFixedArray::fromArray(
+ [175, 80, 155, 64, 178, 45, 214, 233, 65, 209, 12, 155, 117, 31, 140, 214, 27, 187],
+ false
+ );
+ $this->assertEquals($expected, $ecBytes);
+
+ // High-order zero coefficient case.
+ $dataBytes = SplFixedArray::fromArray([32, 49, 205, 69, 42, 20, 0, 236, 17], false);
+ $ecBytes = $this->methods['generateEcBytes']->invoke(null, $dataBytes, 17);
+ $expected = SplFixedArray::fromArray(
+ [0, 3, 130, 179, 194, 0, 55, 211, 110, 79, 98, 72, 170, 96, 211, 137, 213],
+ false
+ );
+ $this->assertEquals($expected, $ecBytes);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/MaskUtilTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/MaskUtilTest.php
new file mode 100644
index 0000000..46670fc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/MaskUtilTest.php
@@ -0,0 +1,251 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Encoder;
+
+use BaconQrCode\Encoder\ByteMatrix;
+use BaconQrCode\Encoder\MaskUtil;
+use PHPUnit\Framework\TestCase;
+
+class MaskUtilTest extends TestCase
+{
+ public function dataMaskBits() : array
+ {
+ return [
+ [0, [
+ [1, 0, 1, 0, 1, 0],
+ [0, 1, 0, 1, 0, 1],
+ [1, 0, 1, 0, 1, 0],
+ [0, 1, 0, 1, 0, 1],
+ [1, 0, 1, 0, 1, 0],
+ [0, 1, 0, 1, 0, 1],
+ ]],
+ [1, [
+ [1, 1, 1, 1, 1, 1],
+ [0, 0, 0, 0, 0, 0],
+ [1, 1, 1, 1, 1, 1],
+ [0, 0, 0, 0, 0, 0],
+ [1, 1, 1, 1, 1, 1],
+ [0, 0, 0, 0, 0, 0],
+ ]],
+ [2, [
+ [1, 0, 0, 1, 0, 0],
+ [1, 0, 0, 1, 0, 0],
+ [1, 0, 0, 1, 0, 0],
+ [1, 0, 0, 1, 0, 0],
+ [1, 0, 0, 1, 0, 0],
+ [1, 0, 0, 1, 0, 0],
+ ]],
+ [3, [
+ [1, 0, 0, 1, 0, 0],
+ [0, 0, 1, 0, 0, 1],
+ [0, 1, 0, 0, 1, 0],
+ [1, 0, 0, 1, 0, 0],
+ [0, 0, 1, 0, 0, 1],
+ [0, 1, 0, 0, 1, 0],
+ ]],
+ [4, [
+ [1, 1, 1, 0, 0, 0],
+ [1, 1, 1, 0, 0, 0],
+ [0, 0, 0, 1, 1, 1],
+ [0, 0, 0, 1, 1, 1],
+ [1, 1, 1, 0, 0, 0],
+ [1, 1, 1, 0, 0, 0],
+ ]],
+ [5, [
+ [1, 1, 1, 1, 1, 1],
+ [1, 0, 0, 0, 0, 0],
+ [1, 0, 0, 1, 0, 0],
+ [1, 0, 1, 0, 1, 0],
+ [1, 0, 0, 1, 0, 0],
+ [1, 0, 0, 0, 0, 0],
+ ]],
+ [6, [
+ [1, 1, 1, 1, 1, 1],
+ [1, 1, 1, 0, 0, 0],
+ [1, 1, 0, 1, 1, 0],
+ [1, 0, 1, 0, 1, 0],
+ [1, 0, 1, 1, 0, 1],
+ [1, 0, 0, 0, 1, 1],
+ ]],
+ [7, [
+ [1, 0, 1, 0, 1, 0],
+ [0, 0, 0, 1, 1, 1],
+ [1, 0, 0, 0, 1, 1],
+ [0, 1, 0, 1, 0, 1],
+ [1, 1, 1, 0, 0, 0],
+ [0, 1, 1, 1, 0, 0],
+ ]],
+ ];
+ }
+
+ /**
+ * @dataProvider dataMaskBits
+ */
+ public function testGetDatMaskBit(int $maskPattern, array $expected) : void
+ {
+ for ($x = 0; $x < 6; ++$x) {
+ for ($y = 0; $y < 6; ++$y) {
+ $this->assertSame(
+ 1 === $expected[$y][$x],
+ MaskUtil::getDataMaskBit($maskPattern, $x, $y)
+ );
+ }
+ }
+ }
+
+ public function testApplyMaskPenaltyRule1() : void
+ {
+ $matrix = new ByteMatrix(4, 1);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 0);
+ $matrix->set(2, 0, 0);
+ $matrix->set(3, 0, 0);
+
+ $this->assertSame(0, MaskUtil::applyMaskPenaltyRule1($matrix));
+
+ // Horizontal
+ $matrix = new ByteMatrix(6, 1);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 0);
+ $matrix->set(2, 0, 0);
+ $matrix->set(3, 0, 0);
+ $matrix->set(4, 0, 0);
+ $matrix->set(5, 0, 1);
+ $this->assertSame(3, MaskUtil::applyMaskPenaltyRule1($matrix));
+ $matrix->set(5, 0, 0);
+ $this->assertSame(4, MaskUtil::applyMaskPenaltyRule1($matrix));
+
+ // Vertical
+ $matrix = new ByteMatrix(1, 6);
+ $matrix->set(0, 0, 0);
+ $matrix->set(0, 1, 0);
+ $matrix->set(0, 2, 0);
+ $matrix->set(0, 3, 0);
+ $matrix->set(0, 4, 0);
+ $matrix->set(0, 5, 1);
+ $this->assertSame(3, MaskUtil::applyMaskPenaltyRule1($matrix));
+ $matrix->set(0, 5, 0);
+ $this->assertSame(4, MaskUtil::applyMaskPenaltyRule1($matrix));
+ }
+
+ public function testApplyMaskPenaltyRule2() : void
+ {
+ $matrix = new ByteMatrix(1, 1);
+ $matrix->set(0, 0, 0);
+ $this->assertSame(0, MaskUtil::applyMaskPenaltyRule2($matrix));
+
+ $matrix = new ByteMatrix(2, 2);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 0);
+ $matrix->set(0, 1, 0);
+ $matrix->set(1, 1, 1);
+ $this->assertSame(0, MaskUtil::applyMaskPenaltyRule2($matrix));
+
+ $matrix = new ByteMatrix(2, 2);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 0);
+ $matrix->set(0, 1, 0);
+ $matrix->set(1, 1, 0);
+ $this->assertSame(3, MaskUtil::applyMaskPenaltyRule2($matrix));
+
+ $matrix = new ByteMatrix(3, 3);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 0);
+ $matrix->set(2, 0, 0);
+ $matrix->set(0, 1, 0);
+ $matrix->set(1, 1, 0);
+ $matrix->set(2, 1, 0);
+ $matrix->set(0, 2, 0);
+ $matrix->set(1, 2, 0);
+ $matrix->set(2, 2, 0);
+ $this->assertSame(3 * 4, MaskUtil::applyMaskPenaltyRule2($matrix));
+ }
+
+ public function testApplyMaskPenalty3() : void
+ {
+ // Horizontal 00001011101
+ $matrix = new ByteMatrix(11, 1);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 0);
+ $matrix->set(2, 0, 0);
+ $matrix->set(3, 0, 0);
+ $matrix->set(4, 0, 1);
+ $matrix->set(5, 0, 0);
+ $matrix->set(6, 0, 1);
+ $matrix->set(7, 0, 1);
+ $matrix->set(8, 0, 1);
+ $matrix->set(9, 0, 0);
+ $matrix->set(10, 0, 1);
+ $this->assertSame(40, MaskUtil::applyMaskPenaltyRule3($matrix));
+
+ // Horizontal 10111010000
+ $matrix = new ByteMatrix(11, 1);
+ $matrix->set(0, 0, 1);
+ $matrix->set(1, 0, 0);
+ $matrix->set(2, 0, 1);
+ $matrix->set(3, 0, 1);
+ $matrix->set(4, 0, 1);
+ $matrix->set(5, 0, 0);
+ $matrix->set(6, 0, 1);
+ $matrix->set(7, 0, 0);
+ $matrix->set(8, 0, 0);
+ $matrix->set(9, 0, 0);
+ $matrix->set(10, 0, 0);
+ $this->assertSame(40, MaskUtil::applyMaskPenaltyRule3($matrix));
+
+ // Vertical 00001011101
+ $matrix = new ByteMatrix(1, 11);
+ $matrix->set(0, 0, 0);
+ $matrix->set(0, 1, 0);
+ $matrix->set(0, 2, 0);
+ $matrix->set(0, 3, 0);
+ $matrix->set(0, 4, 1);
+ $matrix->set(0, 5, 0);
+ $matrix->set(0, 6, 1);
+ $matrix->set(0, 7, 1);
+ $matrix->set(0, 8, 1);
+ $matrix->set(0, 9, 0);
+ $matrix->set(0, 10, 1);
+ $this->assertSame(40, MaskUtil::applyMaskPenaltyRule3($matrix));
+
+ // Vertical 10111010000
+ $matrix = new ByteMatrix(1, 11);
+ $matrix->set(0, 0, 1);
+ $matrix->set(0, 1, 0);
+ $matrix->set(0, 2, 1);
+ $matrix->set(0, 3, 1);
+ $matrix->set(0, 4, 1);
+ $matrix->set(0, 5, 0);
+ $matrix->set(0, 6, 1);
+ $matrix->set(0, 7, 0);
+ $matrix->set(0, 8, 0);
+ $matrix->set(0, 9, 0);
+ $matrix->set(0, 10, 0);
+ $this->assertSame(40, MaskUtil::applyMaskPenaltyRule3($matrix));
+ }
+
+ public function testApplyMaskPenaltyRule4() : void
+ {
+ // Dark cell ratio = 0%
+ $matrix = new ByteMatrix(1, 1);
+ $matrix->set(0, 0, 0);
+ $this->assertSame(100, MaskUtil::applyMaskPenaltyRule4($matrix));
+
+ // Dark cell ratio = 5%
+ $matrix = new ByteMatrix(2, 1);
+ $matrix->set(0, 0, 0);
+ $matrix->set(0, 0, 1);
+ $this->assertSame(0, MaskUtil::applyMaskPenaltyRule4($matrix));
+
+ // Dark cell ratio = 66.67%
+ $matrix = new ByteMatrix(6, 1);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 1);
+ $matrix->set(2, 0, 1);
+ $matrix->set(3, 0, 1);
+ $matrix->set(4, 0, 1);
+ $matrix->set(5, 0, 0);
+ $this->assertSame(30, MaskUtil::applyMaskPenaltyRule4($matrix));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/MatrixUtilTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/MatrixUtilTest.php
new file mode 100644
index 0000000..106ceaa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Encoder/MatrixUtilTest.php
@@ -0,0 +1,335 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Encoder;
+
+use BaconQrCode\Common\BitArray;
+use BaconQrCode\Common\ErrorCorrectionLevel;
+use BaconQrCode\Common\Version;
+use BaconQrCode\Encoder\ByteMatrix;
+use BaconQrCode\Encoder\MatrixUtil;
+use PHPUnit\Framework\TestCase;
+use ReflectionClass;
+use ReflectionMethod;
+
+class MatrixUtilTest extends TestCase
+{
+ /**
+ * @var ReflectionMethod[]
+ */
+ protected $methods = [];
+
+ public function setUp() : void
+ {
+ // Hack to be able to test protected methods
+ $reflection = new ReflectionClass(MatrixUtil::class);
+
+ foreach ($reflection->getMethods(ReflectionMethod::IS_STATIC) as $method) {
+ $method->setAccessible(true);
+ $this->methods[$method->getName()] = $method;
+ }
+ }
+
+ public function testToString() : void
+ {
+ $matrix = new ByteMatrix(3, 3);
+ $matrix->set(0, 0, 0);
+ $matrix->set(1, 0, 1);
+ $matrix->set(2, 0, 0);
+ $matrix->set(0, 1, 1);
+ $matrix->set(1, 1, 0);
+ $matrix->set(2, 1, 1);
+ $matrix->set(0, 2, -1);
+ $matrix->set(1, 2, -1);
+ $matrix->set(2, 2, -1);
+
+ $expected = " 0 1 0\n 1 0 1\n \n";
+ $this->assertSame($expected, (string) $matrix);
+ }
+
+ public function testClearMatrix() : void
+ {
+ $matrix = new ByteMatrix(2, 2);
+ MatrixUtil::clearMatrix($matrix);
+
+ $this->assertSame(-1, $matrix->get(0, 0));
+ $this->assertSame(-1, $matrix->get(1, 0));
+ $this->assertSame(-1, $matrix->get(0, 1));
+ $this->assertSame(-1, $matrix->get(1, 1));
+ }
+
+ public function testEmbedBasicPatterns1() : void
+ {
+ $matrix = new ByteMatrix(21, 21);
+ MatrixUtil::clearMatrix($matrix);
+ $this->methods['embedBasicPatterns']->invoke(
+ null,
+ Version::getVersionForNumber(1),
+ $matrix
+ );
+ $expected = " 1 1 1 1 1 1 1 0 0 1 1 1 1 1 1 1\n"
+ . " 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1\n"
+ . " 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1\n"
+ . " 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 \n"
+ . " 0 \n"
+ . " 1 \n"
+ . " 0 \n"
+ . " 1 \n"
+ . " 0 0 0 0 0 0 0 0 1 \n"
+ . " 1 1 1 1 1 1 1 0 \n"
+ . " 1 0 0 0 0 0 1 0 \n"
+ . " 1 0 1 1 1 0 1 0 \n"
+ . " 1 0 1 1 1 0 1 0 \n"
+ . " 1 0 1 1 1 0 1 0 \n"
+ . " 1 0 0 0 0 0 1 0 \n"
+ . " 1 1 1 1 1 1 1 0 \n";
+
+ $this->assertSame($expected, (string) $matrix);
+ }
+
+ public function testEmbedBasicPatterns2() : void
+ {
+ $matrix = new ByteMatrix(25, 25);
+ MatrixUtil::clearMatrix($matrix);
+ $this->methods['embedBasicPatterns']->invoke(
+ null,
+ Version::getVersionForNumber(2),
+ $matrix
+ );
+ $expected = " 1 1 1 1 1 1 1 0 0 1 1 1 1 1 1 1\n"
+ . " 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1\n"
+ . " 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1\n"
+ . " 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 \n"
+ . " 0 \n"
+ . " 1 \n"
+ . " 0 \n"
+ . " 1 \n"
+ . " 0 \n"
+ . " 1 \n"
+ . " 0 \n"
+ . " 1 1 1 1 1 1 \n"
+ . " 0 0 0 0 0 0 0 0 1 1 0 0 0 1 \n"
+ . " 1 1 1 1 1 1 1 0 1 0 1 0 1 \n"
+ . " 1 0 0 0 0 0 1 0 1 0 0 0 1 \n"
+ . " 1 0 1 1 1 0 1 0 1 1 1 1 1 \n"
+ . " 1 0 1 1 1 0 1 0 \n"
+ . " 1 0 1 1 1 0 1 0 \n"
+ . " 1 0 0 0 0 0 1 0 \n"
+ . " 1 1 1 1 1 1 1 0 \n";
+
+ $this->assertSame($expected, (string) $matrix);
+ }
+
+ public function testEmbedTypeInfo() : void
+ {
+ $matrix = new ByteMatrix(21, 21);
+ MatrixUtil::clearMatrix($matrix);
+ $this->methods['embedTypeInfo']->invoke(
+ null,
+ ErrorCorrectionLevel::M(),
+ 5,
+ $matrix
+ );
+ $expected = " 0 \n"
+ . " 1 \n"
+ . " 1 \n"
+ . " 1 \n"
+ . " 0 \n"
+ . " 0 \n"
+ . " \n"
+ . " 1 \n"
+ . " 1 0 0 0 0 0 0 1 1 1 0 0 1 1 1 0\n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " 0 \n"
+ . " 0 \n"
+ . " 0 \n"
+ . " 0 \n"
+ . " 0 \n"
+ . " 0 \n"
+ . " 1 \n";
+
+ $this->assertSame($expected, (string) $matrix);
+ }
+
+ public function testEmbedVersionInfo() : void
+ {
+ $matrix = new ByteMatrix(21, 21);
+ MatrixUtil::clearMatrix($matrix);
+ $this->methods['maybeEmbedVersionInfo']->invoke(
+ null,
+ Version::getVersionForNumber(7),
+ $matrix
+ );
+ $expected = " 0 0 1 \n"
+ . " 0 1 0 \n"
+ . " 0 1 0 \n"
+ . " 0 1 1 \n"
+ . " 1 1 1 \n"
+ . " 0 0 0 \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " 0 0 0 0 1 0 \n"
+ . " 0 1 1 1 1 0 \n"
+ . " 1 0 0 1 1 0 \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n"
+ . " \n";
+
+ $this->assertSame($expected, (string) $matrix);
+ }
+
+ public function testEmbedDataBits() : void
+ {
+ $matrix = new ByteMatrix(21, 21);
+ MatrixUtil::clearMatrix($matrix);
+ $this->methods['embedBasicPatterns']->invoke(
+ null,
+ Version::getVersionForNumber(1),
+ $matrix
+ );
+
+ $bits = new BitArray();
+ $this->methods['embedDataBits']->invoke(
+ null,
+ $bits,
+ -1,
+ $matrix
+ );
+
+ $expected = " 1 1 1 1 1 1 1 0 0 0 0 0 0 0 1 1 1 1 1 1 1\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 0 0 0 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 0 0 0 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 0 0 0 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 1\n"
+ . " 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1\n"
+ . " 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 0 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 0 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 0 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n"
+ . " 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0\n";
+
+ $this->assertSame($expected, (string) $matrix);
+ }
+
+ public function testBuildMatrix() : void
+ {
+ $bytes = [
+ 32, 65, 205, 69, 41, 220, 46, 128, 236, 42, 159, 74, 221, 244, 169,
+ 239, 150, 138, 70, 237, 85, 224, 96, 74, 219 , 61
+ ];
+ $bits = new BitArray();
+
+ foreach ($bytes as $byte) {
+ $bits->appendBits($byte, 8);
+ }
+
+ $matrix = new ByteMatrix(21, 21);
+ MatrixUtil::buildMatrix(
+ $bits,
+ ErrorCorrectionLevel::H(),
+ Version::getVersionForNumber(1),
+ 3,
+ $matrix
+ );
+
+ $expected = " 1 1 1 1 1 1 1 0 0 1 1 0 0 0 1 1 1 1 1 1 1\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 0 0 1 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 0 1 1 0 0 0 1 0 1 1 1 0 1\n"
+ . " 1 0 1 1 1 0 1 0 1 1 0 0 1 0 1 0 1 1 1 0 1\n"
+ . " 1 0 0 0 0 0 1 0 0 0 1 1 1 0 1 0 0 0 0 0 1\n"
+ . " 1 1 1 1 1 1 1 0 1 0 1 0 1 0 1 1 1 1 1 1 1\n"
+ . " 0 0 0 0 0 0 0 0 1 1 0 1 1 0 0 0 0 0 0 0 0\n"
+ . " 0 0 1 1 0 0 1 1 1 0 0 1 1 1 1 0 1 0 0 0 0\n"
+ . " 1 0 1 0 1 0 0 0 0 0 1 1 1 0 0 1 0 1 1 1 0\n"
+ . " 1 1 1 1 0 1 1 0 1 0 1 1 1 0 0 1 1 1 0 1 0\n"
+ . " 1 0 1 0 1 1 0 1 1 1 0 0 1 1 1 0 0 1 0 1 0\n"
+ . " 0 0 1 0 0 1 1 1 0 0 0 0 0 0 1 0 1 1 1 1 1\n"
+ . " 0 0 0 0 0 0 0 0 1 1 0 1 0 0 0 0 0 1 0 1 1\n"
+ . " 1 1 1 1 1 1 1 0 1 1 1 1 0 0 0 0 1 0 1 1 0\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 1 0 1 1 1 0 0 0 0 0\n"
+ . " 1 0 1 1 1 0 1 0 0 1 0 0 1 1 0 0 1 0 0 1 1\n"
+ . " 1 0 1 1 1 0 1 0 1 1 0 1 0 0 0 0 0 1 1 1 0\n"
+ . " 1 0 1 1 1 0 1 0 1 1 1 1 0 0 0 0 1 1 1 0 0\n"
+ . " 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1 0 1 0 0\n"
+ . " 1 1 1 1 1 1 1 0 0 0 1 1 1 1 1 0 1 0 0 1 0\n";
+
+ $this->assertSame($expected, (string) $matrix);
+ }
+
+ public function testFindMsbSet() : void
+ {
+ $this->assertSame(0, $this->methods['findMsbSet']->invoke(null, 0));
+ $this->assertSame(1, $this->methods['findMsbSet']->invoke(null, 1));
+ $this->assertSame(8, $this->methods['findMsbSet']->invoke(null, 0x80));
+ $this->assertSame(32, $this->methods['findMsbSet']->invoke(null, 0x80000000));
+ }
+
+ public function testCalculateBchCode() : void
+ {
+ // Encoding of type information.
+ // From Appendix C in JISX0510:2004 (p 65)
+ $this->assertSame(0xdc, $this->methods['calculateBchCode']->invoke(null, 5, 0x537));
+ // From http://www.swetake.com/qr/qr6.html
+ $this->assertSame(0x1c2, $this->methods['calculateBchCode']->invoke(null, 0x13, 0x537));
+ // From http://www.swetake.com/qr/qr11.html
+ $this->assertSame(0x214, $this->methods['calculateBchCode']->invoke(null, 0x1b, 0x537));
+
+ // Encoding of version information.
+ // From Appendix D in JISX0510:2004 (p 68)
+ $this->assertSame(0xc94, $this->methods['calculateBchCode']->invoke(null, 7, 0x1f25));
+ $this->assertSame(0x5bc, $this->methods['calculateBchCode']->invoke(null, 8, 0x1f25));
+ $this->assertSame(0xa99, $this->methods['calculateBchCode']->invoke(null, 9, 0x1f25));
+ $this->assertSame(0x4d3, $this->methods['calculateBchCode']->invoke(null, 10, 0x1f25));
+ $this->assertSame(0x9a6, $this->methods['calculateBchCode']->invoke(null, 20, 0x1f25));
+ $this->assertSame(0xd75, $this->methods['calculateBchCode']->invoke(null, 30, 0x1f25));
+ $this->assertSame(0xc69, $this->methods['calculateBchCode']->invoke(null, 40, 0x1f25));
+ }
+
+ public function testMakeVersionInfoBits() : void
+ {
+ // From Appendix D in JISX0510:2004 (p 68)
+ $bits = new BitArray();
+ $this->methods['makeVersionInfoBits']->invoke(null, Version::getVersionForNumber(7), $bits);
+ $this->assertSame(' ...XXXXX ..X..X.X ..', (string) $bits);
+ }
+
+ public function testMakeTypeInfoBits() : void
+ {
+ // From Appendix D in JISX0510:2004 (p 68)
+ $bits = new BitArray();
+ $this->methods['makeTypeInfoBits']->invoke(null, ErrorCorrectionLevel::M(), 5, $bits);
+ $this->assertSame(' X......X X..XXX.', (string) $bits);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/ImagickRenderingTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/ImagickRenderingTest.php
new file mode 100644
index 0000000..3df8687
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/ImagickRenderingTest.php
@@ -0,0 +1,72 @@
+<?php
+declare(strict_types = 1);
+
+namespace BaconQrCodeTest\Integration;
+
+use BaconQrCode\Renderer\Color\Rgb;
+use BaconQrCode\Renderer\Eye\SquareEye;
+use BaconQrCode\Renderer\Image\ImagickImageBackEnd;
+use BaconQrCode\Renderer\ImageRenderer;
+use BaconQrCode\Renderer\Module\SquareModule;
+use BaconQrCode\Renderer\RendererStyle\EyeFill;
+use BaconQrCode\Renderer\RendererStyle\Fill;
+use BaconQrCode\Renderer\RendererStyle\Gradient;
+use BaconQrCode\Renderer\RendererStyle\GradientType;
+use BaconQrCode\Renderer\RendererStyle\RendererStyle;
+use BaconQrCode\Writer;
+use PHPUnit\Framework\TestCase;
+use Spatie\Snapshots\MatchesSnapshots;
+
+/**
+ * @group integration
+ */
+final class ImagickRenderingTest extends TestCase
+{
+ use MatchesSnapshots;
+
+ /**
+ * @requires extension imagick
+ */
+ public function testGenericQrCode() : void
+ {
+ $renderer = new ImageRenderer(
+ new RendererStyle(400),
+ new ImagickImageBackEnd()
+ );
+ $writer = new Writer($renderer);
+ $tempName = tempnam(sys_get_temp_dir(), 'test') . '.png';
+ $writer->writeFile('Hello World!', $tempName);
+
+ $this->assertMatchesFileSnapshot($tempName);
+ unlink($tempName);
+ }
+
+ /**
+ * @requires extension imagick
+ */
+ public function testIssue79() : void
+ {
+ $eye = SquareEye::instance();
+ $squareModule = SquareModule::instance();
+
+ $eyeFill = new EyeFill(new Rgb(100, 100, 55), new Rgb(100, 100, 255));
+ $gradient = new Gradient(new Rgb(100, 100, 55), new Rgb(100, 100, 255), GradientType::HORIZONTAL());
+
+ $renderer = new ImageRenderer(
+ new RendererStyle(
+ 400,
+ 2,
+ $squareModule,
+ $eye,
+ Fill::withForegroundGradient(new Rgb(255, 255, 255), $gradient, $eyeFill, $eyeFill, $eyeFill)
+ ),
+ new ImagickImageBackEnd()
+ );
+ $writer = new Writer($renderer);
+ $tempName = tempnam(sys_get_temp_dir(), 'test') . '.png';
+ $writer->writeFile('https://apiroad.net/very-long-url', $tempName);
+
+ $this->assertMatchesFileSnapshot($tempName);
+ unlink($tempName);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/__snapshots__/files/ImagickRenderingTest__testGenericQrCode__1.png b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/__snapshots__/files/ImagickRenderingTest__testGenericQrCode__1.png
new file mode 100644
index 0000000..9a429ed
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/__snapshots__/files/ImagickRenderingTest__testGenericQrCode__1.png
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/__snapshots__/files/ImagickRenderingTest__testIssue79__1.png b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/__snapshots__/files/ImagickRenderingTest__testIssue79__1.png
new file mode 100644
index 0000000..47e3b1a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bacon/bacon-qr-code/test/Integration/__snapshots__/files/ImagickRenderingTest__testIssue79__1.png
Binary files differ
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bin/carbon b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bin/carbon
index 7b63379..86fbfdf 100755
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bin/carbon
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bin/carbon
@@ -12,6 +12,7 @@
namespace Composer;
+$GLOBALS['_composer_bin_dir'] = __DIR__;
$GLOBALS['_composer_autoload_path'] = __DIR__ . '/..'.'/autoload.php';
if (PHP_VERSION_ID < 80000) {
@@ -23,18 +24,17 @@
{
private $handle;
private $position;
+ private $realpath;
public function stream_open($path, $mode, $options, &$opened_path)
{
- // get rid of composer-bin-proxy:// prefix for __FILE__ & __DIR__ resolution
- $opened_path = substr($path, 21);
- $opened_path = realpath($opened_path) ?: $opened_path;
- $this->handle = fopen($opened_path, $mode);
+ // get rid of phpvfscomposer:// prefix for __FILE__ & __DIR__ resolution
+ $opened_path = substr($path, 17);
+ $this->realpath = realpath($opened_path) ?: $opened_path;
+ $opened_path = $this->realpath;
+ $this->handle = fopen($this->realpath, $mode);
$this->position = 0;
- // remove all traces of this stream wrapper once it has been used
- stream_wrapper_unregister('composer-bin-proxy');
-
return (bool) $this->handle;
}
@@ -66,6 +66,16 @@
return $operation ? flock($this->handle, $operation) : true;
}
+ public function stream_seek($offset, $whence)
+ {
+ if (0 === fseek($this->handle, $offset, $whence)) {
+ $this->position = ftell($this->handle);
+ return true;
+ }
+
+ return false;
+ }
+
public function stream_tell()
{
return $this->position;
@@ -78,20 +88,32 @@
public function stream_stat()
{
- return fstat($this->handle);
+ return array();
}
public function stream_set_option($option, $arg1, $arg2)
{
return true;
}
+
+ public function url_stat($path, $flags)
+ {
+ $path = substr($path, 17);
+ if (file_exists($path)) {
+ return stat($path);
+ }
+
+ return false;
+ }
}
}
- if (function_exists('stream_wrapper_register') && stream_wrapper_register('composer-bin-proxy', 'Composer\BinProxyWrapper')) {
- include("composer-bin-proxy://" . __DIR__ . '/..'.'/nesbot/carbon/bin/carbon');
- exit(0);
+ if (
+ (function_exists('stream_get_wrappers') && in_array('phpvfscomposer', stream_get_wrappers(), true))
+ || (function_exists('stream_wrapper_register') && stream_wrapper_register('phpvfscomposer', 'Composer\BinProxyWrapper'))
+ ) {
+ return include("phpvfscomposer://" . __DIR__ . '/..'.'/nesbot/carbon/bin/carbon');
}
}
-include __DIR__ . '/..'.'/nesbot/carbon/bin/carbon';
+return include __DIR__ . '/..'.'/nesbot/carbon/bin/carbon';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bin/var-dump-server b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bin/var-dump-server
deleted file mode 100755
index 1eafd5d..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/bin/var-dump-server
+++ /dev/null
@@ -1,97 +0,0 @@
-#!/usr/bin/env php
-<?php
-
-/**
- * Proxy PHP file generated by Composer
- *
- * This file includes the referenced bin path (../symfony/var-dumper/Resources/bin/var-dump-server)
- * using a stream wrapper to prevent the shebang from being output on PHP<8
- *
- * @generated
- */
-
-namespace Composer;
-
-$GLOBALS['_composer_autoload_path'] = __DIR__ . '/..'.'/autoload.php';
-
-if (PHP_VERSION_ID < 80000) {
- if (!class_exists('Composer\BinProxyWrapper')) {
- /**
- * @internal
- */
- final class BinProxyWrapper
- {
- private $handle;
- private $position;
-
- public function stream_open($path, $mode, $options, &$opened_path)
- {
- // get rid of composer-bin-proxy:// prefix for __FILE__ & __DIR__ resolution
- $opened_path = substr($path, 21);
- $opened_path = realpath($opened_path) ?: $opened_path;
- $this->handle = fopen($opened_path, $mode);
- $this->position = 0;
-
- // remove all traces of this stream wrapper once it has been used
- stream_wrapper_unregister('composer-bin-proxy');
-
- return (bool) $this->handle;
- }
-
- public function stream_read($count)
- {
- $data = fread($this->handle, $count);
-
- if ($this->position === 0) {
- $data = preg_replace('{^#!.*\r?\n}', '', $data);
- }
-
- $this->position += strlen($data);
-
- return $data;
- }
-
- public function stream_cast($castAs)
- {
- return $this->handle;
- }
-
- public function stream_close()
- {
- fclose($this->handle);
- }
-
- public function stream_lock($operation)
- {
- return $operation ? flock($this->handle, $operation) : true;
- }
-
- public function stream_tell()
- {
- return $this->position;
- }
-
- public function stream_eof()
- {
- return feof($this->handle);
- }
-
- public function stream_stat()
- {
- return fstat($this->handle);
- }
-
- public function stream_set_option($option, $arg1, $arg2)
- {
- return true;
- }
- }
- }
-
- if (function_exists('stream_wrapper_register') && stream_wrapper_register('composer-bin-proxy', 'Composer\BinProxyWrapper')) {
- include("composer-bin-proxy://" . __DIR__ . '/..'.'/symfony/var-dumper/Resources/bin/var-dump-server');
- exit(0);
- }
-}
-
-include __DIR__ . '/..'.'/symfony/var-dumper/Resources/bin/var-dump-server';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/LICENSE
new file mode 100644
index 0000000..2ee1671
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/LICENSE
@@ -0,0 +1,21 @@
+MIT License
+
+Copyright (c) 2023 Carbon
+
+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/carbonphp/carbon-doctrine-types/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/README.md
new file mode 100644
index 0000000..5a18121
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/README.md
@@ -0,0 +1,14 @@
+# carbonphp/carbon-doctrine-types
+
+Types to use Carbon in Doctrine
+
+## Documentation
+
+[Check how to use in the official Carbon documentation](https://carbon.nesbot.com/symfony/)
+
+This package is an externalization of [src/Carbon/Doctrine](https://github.com/briannesbitt/Carbon/tree/2.71.0/src/Carbon/Doctrine)
+from `nestbot/carbon` package.
+
+Externalization allows to better deal with different versions of dbal. With
+version 4.0 of dbal, it no longer sustainable to be compatible with all version
+using a single code.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/composer.json
new file mode 100644
index 0000000..abf45c5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/composer.json
@@ -0,0 +1,36 @@
+{
+ "name": "carbonphp/carbon-doctrine-types",
+ "description": "Types to use Carbon in Doctrine",
+ "type": "library",
+ "keywords": [
+ "date",
+ "time",
+ "DateTime",
+ "Carbon",
+ "Doctrine"
+ ],
+ "require": {
+ "php": "^8.1"
+ },
+ "require-dev": {
+ "doctrine/dbal": "^4.0.0",
+ "nesbot/carbon": "^2.71.0 || ^3.0.0",
+ "phpunit/phpunit": "^10.3"
+ },
+ "conflict": {
+ "doctrine/dbal": "<4.0.0 || >=5.0.0"
+ },
+ "license": "MIT",
+ "autoload": {
+ "psr-4": {
+ "Carbon\\Doctrine\\": "src/Carbon/Doctrine/"
+ }
+ },
+ "authors": [
+ {
+ "name": "KyleKatarn",
+ "email": "kylekatarnls@gmail.com"
+ }
+ ],
+ "minimum-stability": "dev"
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonDoctrineType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonDoctrineType.php
new file mode 100644
index 0000000..a63a9b8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonDoctrineType.php
@@ -0,0 +1,16 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Carbon\Doctrine;
+
+use Doctrine\DBAL\Platforms\AbstractPlatform;
+
+interface CarbonDoctrineType
+{
+ public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform);
+
+ public function convertToPHPValue(mixed $value, AbstractPlatform $platform);
+
+ public function convertToDatabaseValue($value, AbstractPlatform $platform);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonImmutableType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonImmutableType.php
new file mode 100644
index 0000000..8fc6bef
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonImmutableType.php
@@ -0,0 +1,9 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Carbon\Doctrine;
+
+class CarbonImmutableType extends DateTimeImmutableType implements CarbonDoctrineType
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonType.php
new file mode 100644
index 0000000..206b0e3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonType.php
@@ -0,0 +1,9 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Carbon\Doctrine;
+
+class CarbonType extends DateTimeType implements CarbonDoctrineType
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonTypeConverter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonTypeConverter.php
new file mode 100644
index 0000000..a813311
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/CarbonTypeConverter.php
@@ -0,0 +1,131 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Carbon\Doctrine;
+
+use Carbon\Carbon;
+use Carbon\CarbonInterface;
+use DateTimeInterface;
+use Doctrine\DBAL\Platforms\AbstractPlatform;
+use Doctrine\DBAL\Platforms\DB2Platform;
+use Doctrine\DBAL\Platforms\OraclePlatform;
+use Doctrine\DBAL\Platforms\SQLitePlatform;
+use Doctrine\DBAL\Platforms\SQLServerPlatform;
+use Doctrine\DBAL\Types\Exception\InvalidType;
+use Doctrine\DBAL\Types\Exception\ValueNotConvertible;
+use Exception;
+
+/**
+ * @template T of CarbonInterface
+ */
+trait CarbonTypeConverter
+{
+ /**
+ * This property differentiates types installed by carbonphp/carbon-doctrine-types
+ * from the ones embedded previously in nesbot/carbon source directly.
+ *
+ * @readonly
+ */
+ public bool $external = true;
+
+ /**
+ * @return class-string<T>
+ */
+ protected function getCarbonClassName(): string
+ {
+ return Carbon::class;
+ }
+
+ public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform): string
+ {
+ $precision = min(
+ $fieldDeclaration['precision'] ?? DateTimeDefaultPrecision::get(),
+ $this->getMaximumPrecision($platform),
+ );
+
+ $type = parent::getSQLDeclaration($fieldDeclaration, $platform);
+
+ if (!$precision) {
+ return $type;
+ }
+
+ if (str_contains($type, '(')) {
+ return preg_replace('/\(\d+\)/', "($precision)", $type);
+ }
+
+ [$before, $after] = explode(' ', "$type ");
+
+ return trim("$before($precision) $after");
+ }
+
+ /**
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
+ */
+ public function convertToDatabaseValue($value, AbstractPlatform $platform): ?string
+ {
+ if ($value === null) {
+ return $value;
+ }
+
+ if ($value instanceof DateTimeInterface) {
+ return $value->format('Y-m-d H:i:s.u');
+ }
+
+ throw InvalidType::new(
+ $value,
+ static::class,
+ ['null', 'DateTime', 'Carbon']
+ );
+ }
+
+ private function doConvertToPHPValue(mixed $value)
+ {
+ $class = $this->getCarbonClassName();
+
+ if ($value === null || is_a($value, $class)) {
+ return $value;
+ }
+
+ if ($value instanceof DateTimeInterface) {
+ return $class::instance($value);
+ }
+
+ $date = null;
+ $error = null;
+
+ try {
+ $date = $class::parse($value);
+ } catch (Exception $exception) {
+ $error = $exception;
+ }
+
+ if (!$date) {
+ throw ValueNotConvertible::new(
+ $value,
+ static::class,
+ 'Y-m-d H:i:s.u or any format supported by '.$class.'::parse()',
+ $error
+ );
+ }
+
+ return $date;
+ }
+
+ private function getMaximumPrecision(AbstractPlatform $platform): int
+ {
+ if ($platform instanceof DB2Platform) {
+ return 12;
+ }
+
+ if ($platform instanceof OraclePlatform) {
+ return 9;
+ }
+
+ if ($platform instanceof SQLServerPlatform || $platform instanceof SQLitePlatform) {
+ return 3;
+ }
+
+ return 6;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeDefaultPrecision.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeDefaultPrecision.php
new file mode 100644
index 0000000..cd9896f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeDefaultPrecision.php
@@ -0,0 +1,30 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Carbon\Doctrine;
+
+class DateTimeDefaultPrecision
+{
+ private static $precision = 6;
+
+ /**
+ * Change the default Doctrine datetime and datetime_immutable precision.
+ *
+ * @param int $precision
+ */
+ public static function set(int $precision): void
+ {
+ self::$precision = $precision;
+ }
+
+ /**
+ * Get the default Doctrine datetime and datetime_immutable precision.
+ *
+ * @return int
+ */
+ public static function get(): int
+ {
+ return self::$precision;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeImmutableType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeImmutableType.php
new file mode 100644
index 0000000..fd6467e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeImmutableType.php
@@ -0,0 +1,32 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Carbon\Doctrine;
+
+use Carbon\CarbonImmutable;
+use DateTimeImmutable;
+use Doctrine\DBAL\Platforms\AbstractPlatform;
+use Doctrine\DBAL\Types\VarDateTimeImmutableType;
+
+class DateTimeImmutableType extends VarDateTimeImmutableType implements CarbonDoctrineType
+{
+ /** @use CarbonTypeConverter<CarbonImmutable> */
+ use CarbonTypeConverter;
+
+ /**
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
+ */
+ public function convertToPHPValue(mixed $value, AbstractPlatform $platform): ?CarbonImmutable
+ {
+ return $this->doConvertToPHPValue($value);
+ }
+
+ /**
+ * @return class-string<CarbonImmutable>
+ */
+ protected function getCarbonClassName(): string
+ {
+ return CarbonImmutable::class;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeType.php
new file mode 100644
index 0000000..89e4b79
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine/DateTimeType.php
@@ -0,0 +1,24 @@
+<?php
+
+declare(strict_types=1);
+
+namespace Carbon\Doctrine;
+
+use Carbon\Carbon;
+use DateTime;
+use Doctrine\DBAL\Platforms\AbstractPlatform;
+use Doctrine\DBAL\Types\VarDateTimeType;
+
+class DateTimeType extends VarDateTimeType implements CarbonDoctrineType
+{
+ /** @use CarbonTypeConverter<Carbon> */
+ use CarbonTypeConverter;
+
+ /**
+ * @SuppressWarnings(PHPMD.UnusedFormalParameter)
+ */
+ public function convertToPHPValue(mixed $value, AbstractPlatform $platform): ?Carbon
+ {
+ return $this->doConvertToPHPValue($value);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/ClassLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/ClassLoader.php
index afef3fa..7824d8f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/ClassLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/ClassLoader.php
@@ -42,35 +42,37 @@
*/
class ClassLoader
{
- /** @var ?string */
+ /** @var \Closure(string):void */
+ private static $includeFile;
+
+ /** @var string|null */
private $vendorDir;
// PSR-4
/**
- * @var array[]
- * @psalm-var array<string, array<string, int>>
+ * @var array<string, array<string, int>>
*/
private $prefixLengthsPsr4 = array();
/**
- * @var array[]
- * @psalm-var array<string, array<int, string>>
+ * @var array<string, list<string>>
*/
private $prefixDirsPsr4 = array();
/**
- * @var array[]
- * @psalm-var array<string, string>
+ * @var list<string>
*/
private $fallbackDirsPsr4 = array();
// PSR-0
/**
- * @var array[]
- * @psalm-var array<string, array<string, string[]>>
+ * List of PSR-0 prefixes
+ *
+ * Structured as array('F (first letter)' => array('Foo\Bar (full prefix)' => array('path', 'path2')))
+ *
+ * @var array<string, array<string, list<string>>>
*/
private $prefixesPsr0 = array();
/**
- * @var array[]
- * @psalm-var array<string, string>
+ * @var list<string>
*/
private $fallbackDirsPsr0 = array();
@@ -78,8 +80,7 @@
private $useIncludePath = false;
/**
- * @var string[]
- * @psalm-var array<string, string>
+ * @var array<string, string>
*/
private $classMap = array();
@@ -87,29 +88,29 @@
private $classMapAuthoritative = false;
/**
- * @var bool[]
- * @psalm-var array<string, bool>
+ * @var array<string, bool>
*/
private $missingClasses = array();
- /** @var ?string */
+ /** @var string|null */
private $apcuPrefix;
/**
- * @var self[]
+ * @var array<string, self>
*/
private static $registeredLoaders = array();
/**
- * @param ?string $vendorDir
+ * @param string|null $vendorDir
*/
public function __construct($vendorDir = null)
{
$this->vendorDir = $vendorDir;
+ self::initializeIncludeClosure();
}
/**
- * @return string[]
+ * @return array<string, list<string>>
*/
public function getPrefixes()
{
@@ -121,8 +122,7 @@
}
/**
- * @return array[]
- * @psalm-return array<string, array<int, string>>
+ * @return array<string, list<string>>
*/
public function getPrefixesPsr4()
{
@@ -130,8 +130,7 @@
}
/**
- * @return array[]
- * @psalm-return array<string, string>
+ * @return list<string>
*/
public function getFallbackDirs()
{
@@ -139,8 +138,7 @@
}
/**
- * @return array[]
- * @psalm-return array<string, string>
+ * @return list<string>
*/
public function getFallbackDirsPsr4()
{
@@ -148,8 +146,7 @@
}
/**
- * @return string[] Array of classname => path
- * @psalm-return array<string, string>
+ * @return array<string, string> Array of classname => path
*/
public function getClassMap()
{
@@ -157,8 +154,7 @@
}
/**
- * @param string[] $classMap Class to filename map
- * @psalm-param array<string, string> $classMap
+ * @param array<string, string> $classMap Class to filename map
*
* @return void
*/
@@ -175,24 +171,25 @@
* Registers a set of PSR-0 directories for a given prefix, either
* appending or prepending to the ones previously set for this prefix.
*
- * @param string $prefix The prefix
- * @param string[]|string $paths The PSR-0 root directories
- * @param bool $prepend Whether to prepend the directories
+ * @param string $prefix The prefix
+ * @param list<string>|string $paths The PSR-0 root directories
+ * @param bool $prepend Whether to prepend the directories
*
* @return void
*/
public function add($prefix, $paths, $prepend = false)
{
+ $paths = (array) $paths;
if (!$prefix) {
if ($prepend) {
$this->fallbackDirsPsr0 = array_merge(
- (array) $paths,
+ $paths,
$this->fallbackDirsPsr0
);
} else {
$this->fallbackDirsPsr0 = array_merge(
$this->fallbackDirsPsr0,
- (array) $paths
+ $paths
);
}
@@ -201,19 +198,19 @@
$first = $prefix[0];
if (!isset($this->prefixesPsr0[$first][$prefix])) {
- $this->prefixesPsr0[$first][$prefix] = (array) $paths;
+ $this->prefixesPsr0[$first][$prefix] = $paths;
return;
}
if ($prepend) {
$this->prefixesPsr0[$first][$prefix] = array_merge(
- (array) $paths,
+ $paths,
$this->prefixesPsr0[$first][$prefix]
);
} else {
$this->prefixesPsr0[$first][$prefix] = array_merge(
$this->prefixesPsr0[$first][$prefix],
- (array) $paths
+ $paths
);
}
}
@@ -222,9 +219,9 @@
* Registers a set of PSR-4 directories for a given namespace, either
* appending or prepending to the ones previously set for this namespace.
*
- * @param string $prefix The prefix/namespace, with trailing '\\'
- * @param string[]|string $paths The PSR-4 base directories
- * @param bool $prepend Whether to prepend the directories
+ * @param string $prefix The prefix/namespace, with trailing '\\'
+ * @param list<string>|string $paths The PSR-4 base directories
+ * @param bool $prepend Whether to prepend the directories
*
* @throws \InvalidArgumentException
*
@@ -232,17 +229,18 @@
*/
public function addPsr4($prefix, $paths, $prepend = false)
{
+ $paths = (array) $paths;
if (!$prefix) {
// Register directories for the root namespace.
if ($prepend) {
$this->fallbackDirsPsr4 = array_merge(
- (array) $paths,
+ $paths,
$this->fallbackDirsPsr4
);
} else {
$this->fallbackDirsPsr4 = array_merge(
$this->fallbackDirsPsr4,
- (array) $paths
+ $paths
);
}
} elseif (!isset($this->prefixDirsPsr4[$prefix])) {
@@ -252,18 +250,18 @@
throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator.");
}
$this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length;
- $this->prefixDirsPsr4[$prefix] = (array) $paths;
+ $this->prefixDirsPsr4[$prefix] = $paths;
} elseif ($prepend) {
// Prepend directories for an already registered namespace.
$this->prefixDirsPsr4[$prefix] = array_merge(
- (array) $paths,
+ $paths,
$this->prefixDirsPsr4[$prefix]
);
} else {
// Append directories for an already registered namespace.
$this->prefixDirsPsr4[$prefix] = array_merge(
$this->prefixDirsPsr4[$prefix],
- (array) $paths
+ $paths
);
}
}
@@ -272,8 +270,8 @@
* Registers a set of PSR-0 directories for a given prefix,
* replacing any others previously set for this prefix.
*
- * @param string $prefix The prefix
- * @param string[]|string $paths The PSR-0 base directories
+ * @param string $prefix The prefix
+ * @param list<string>|string $paths The PSR-0 base directories
*
* @return void
*/
@@ -290,8 +288,8 @@
* Registers a set of PSR-4 directories for a given namespace,
* replacing any others previously set for this namespace.
*
- * @param string $prefix The prefix/namespace, with trailing '\\'
- * @param string[]|string $paths The PSR-4 base directories
+ * @param string $prefix The prefix/namespace, with trailing '\\'
+ * @param list<string>|string $paths The PSR-4 base directories
*
* @throws \InvalidArgumentException
*
@@ -425,7 +423,8 @@
public function loadClass($class)
{
if ($file = $this->findFile($class)) {
- includeFile($file);
+ $includeFile = self::$includeFile;
+ $includeFile($file);
return true;
}
@@ -476,9 +475,9 @@
}
/**
- * Returns the currently registered loaders indexed by their corresponding vendor directories.
+ * Returns the currently registered loaders keyed by their corresponding vendor directories.
*
- * @return self[]
+ * @return array<string, self>
*/
public static function getRegisteredLoaders()
{
@@ -555,18 +554,26 @@
return false;
}
-}
-/**
- * Scope isolated include.
- *
- * Prevents access to $this/self from included files.
- *
- * @param string $file
- * @return void
- * @private
- */
-function includeFile($file)
-{
- include $file;
+ /**
+ * @return void
+ */
+ private static function initializeIncludeClosure()
+ {
+ if (self::$includeFile !== null) {
+ return;
+ }
+
+ /**
+ * Scope isolated include.
+ *
+ * Prevents access to $this/self from included files.
+ *
+ * @param string $file
+ * @return void
+ */
+ self::$includeFile = \Closure::bind(static function($file) {
+ include $file;
+ }, null, null);
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/InstalledVersions.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/InstalledVersions.php
index c6b54af..6d29bff 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/InstalledVersions.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/InstalledVersions.php
@@ -33,6 +33,11 @@
private static $installed;
/**
+ * @var bool
+ */
+ private static $installedIsLocalDir;
+
+ /**
* @var bool|null
*/
private static $canGetVendors;
@@ -98,7 +103,7 @@
{
foreach (self::getInstalled() as $installed) {
if (isset($installed['versions'][$packageName])) {
- return $includeDevRequirements || empty($installed['versions'][$packageName]['dev_requirement']);
+ return $includeDevRequirements || !isset($installed['versions'][$packageName]['dev_requirement']) || $installed['versions'][$packageName]['dev_requirement'] === false;
}
}
@@ -119,7 +124,7 @@
*/
public static function satisfies(VersionParser $parser, $packageName, $constraint)
{
- $constraint = $parser->parseConstraints($constraint);
+ $constraint = $parser->parseConstraints((string) $constraint);
$provided = $parser->parseConstraints(self::getVersionRanges($packageName));
return $provided->matches($constraint);
@@ -309,6 +314,12 @@
{
self::$installed = $data;
self::$installedByVendor = array();
+
+ // when using reload, we disable the duplicate protection to ensure that self::$installed data is
+ // always returned, but we cannot know whether it comes from the installed.php in __DIR__ or not,
+ // so we have to assume it does not, and that may result in duplicate data being returned when listing
+ // all installed packages for example
+ self::$installedIsLocalDir = false;
}
/**
@@ -322,17 +333,27 @@
}
$installed = array();
+ $copiedLocalDir = false;
if (self::$canGetVendors) {
+ $selfDir = strtr(__DIR__, '\\', '/');
foreach (ClassLoader::getRegisteredLoaders() as $vendorDir => $loader) {
+ $vendorDir = strtr($vendorDir, '\\', '/');
if (isset(self::$installedByVendor[$vendorDir])) {
$installed[] = self::$installedByVendor[$vendorDir];
} elseif (is_file($vendorDir.'/composer/installed.php')) {
- $installed[] = self::$installedByVendor[$vendorDir] = require $vendorDir.'/composer/installed.php';
- if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) {
- self::$installed = $installed[count($installed) - 1];
+ /** @var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $required */
+ $required = require $vendorDir.'/composer/installed.php';
+ self::$installedByVendor[$vendorDir] = $required;
+ $installed[] = $required;
+ if (self::$installed === null && $vendorDir.'/composer' === $selfDir) {
+ self::$installed = $required;
+ self::$installedIsLocalDir = true;
}
}
+ if (self::$installedIsLocalDir && $vendorDir.'/composer' === $selfDir) {
+ $copiedLocalDir = true;
+ }
}
}
@@ -340,12 +361,17 @@
// only require the installed.php file if this file is loaded from its dumped location,
// and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937
if (substr(__DIR__, -8, 1) !== 'C') {
- self::$installed = require __DIR__ . '/installed.php';
+ /** @var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $required */
+ $required = require __DIR__ . '/installed.php';
+ self::$installed = $required;
} else {
self::$installed = array();
}
}
- $installed[] = self::$installed;
+
+ if (self::$installed !== array() && !$copiedLocalDir) {
+ $installed[] = self::$installed;
+ }
return $installed;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_classmap.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_classmap.php
index f3327f1..3885b22 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_classmap.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_classmap.php
@@ -7,13 +7,11 @@
return array(
'Attribute' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/Attribute.php',
+ 'CURLStringFile' => $vendorDir . '/symfony/polyfill-php81/Resources/stubs/CURLStringFile.php',
'Composer\\InstalledVersions' => $vendorDir . '/composer/InstalledVersions.php',
+ 'PhpToken' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/PhpToken.php',
+ 'ReturnTypeWillChange' => $vendorDir . '/symfony/polyfill-php81/Resources/stubs/ReturnTypeWillChange.php',
'Stringable' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/Stringable.php',
'UnhandledMatchError' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php',
'ValueError' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/ValueError.php',
- 'u2flib_server\\Error' => $vendorDir . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\RegisterRequest' => $vendorDir . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\Registration' => $vendorDir . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\SignRequest' => $vendorDir . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\U2F' => $vendorDir . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
);
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 502893f..e2cabb9 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,12 +6,19 @@
$baseDir = dirname($vendorDir);
return array(
+ '6e3fae29631ef280660b3cdad06f25a8' => $vendorDir . '/symfony/deprecation-contracts/function.php',
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php',
+ '7b11c4dc42b3b3023073cb14e519683c' => $vendorDir . '/ralouphie/getallheaders/src/getallheaders.php',
+ 'c964ee0ededf28c96ebd9db5099ef910' => $vendorDir . '/guzzlehttp/promises/src/functions_include.php',
+ '37a3dc5111fe8f707ab4c132ef1dbc62' => $vendorDir . '/guzzlehttp/guzzle/src/functions_include.php',
'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php',
'a1105708a18b76903365ca1c4aa61b02' => $vendorDir . '/symfony/translation/Resources/functions.php',
- '667aeda72477189d0494fecd327c3641' => $vendorDir . '/symfony/var-dumper/Resources/functions/dump.php',
+ '60799491728b879e74601d83e38b2cad' => $vendorDir . '/illuminate/collections/helpers.php',
'320cde22f66dd4f5d3fd621d3e88b98f' => $vendorDir . '/symfony/polyfill-ctype/bootstrap.php',
- 'fe62ba7e10580d903cc46d808b5961a4' => $vendorDir . '/tightenco/collect/src/Collect/Support/helpers.php',
- 'caf31cc6ec7cf2241cb6f12c226c3846' => $vendorDir . '/tightenco/collect/src/Collect/Support/alias.php',
+ '23c18046f52bef3eea034657bafda50f' => $vendorDir . '/symfony/polyfill-php81/bootstrap.php',
'04c6c5c2f7095ccf6c481d3e53e1776f' => $vendorDir . '/mustangostang/spyc/Spyc.php',
+ '89efb1254ef2d1c5d80096acd12c4098' => $vendorDir . '/twig/twig/src/Resources/core.php',
+ 'ffecb95d45175fd40f75be8a23b34f90' => $vendorDir . '/twig/twig/src/Resources/debug.php',
+ 'c7baa00073ee9c61edf148c51917cfb4' => $vendorDir . '/twig/twig/src/Resources/escaper.php',
+ 'f844ccf1d25df8663951193c3fc307c8' => $vendorDir . '/twig/twig/src/Resources/string_loader.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 83d1f56..236034c 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
@@ -7,24 +7,36 @@
return array(
'Twig\\' => array($vendorDir . '/twig/twig/src'),
- 'Tightenco\\Collect\\' => array($vendorDir . '/tightenco/collect/src/Collect'),
+ 'Symfony\\Polyfill\\Php81\\' => array($vendorDir . '/symfony/polyfill-php81'),
'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'),
+ 'Stevenmaguire\\OAuth2\\Client\\' => array($vendorDir . '/stevenmaguire/oauth2-keycloak/src'),
'RobThree\\Auth\\' => array($vendorDir . '/robthree/twofactorauth/lib'),
'Psr\\SimpleCache\\' => array($vendorDir . '/psr/simple-cache/src'),
'Psr\\Log\\' => array($vendorDir . '/psr/log/src'),
+ 'Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-factory/src', $vendorDir . '/psr/http-message/src'),
+ 'Psr\\Http\\Client\\' => array($vendorDir . '/psr/http-client/src'),
'Psr\\Container\\' => array($vendorDir . '/psr/container/src'),
+ 'Psr\\Clock\\' => array($vendorDir . '/psr/clock/src'),
'PhpMimeMailParser\\' => array($vendorDir . '/php-mime-mail-parser/php-mime-mail-parser/src'),
'PHPMailer\\PHPMailer\\' => array($vendorDir . '/phpmailer/phpmailer/src'),
'MatthiasMullie\\PathConverter\\' => array($vendorDir . '/matthiasmullie/path-converter/src'),
'MatthiasMullie\\Minify\\' => array($vendorDir . '/matthiasmullie/minify/src'),
+ 'League\\OAuth2\\Client\\' => array($vendorDir . '/league/oauth2-client/src'),
'LdapRecord\\' => array($vendorDir . '/directorytree/ldaprecord/src'),
+ 'Illuminate\\Support\\' => array($vendorDir . '/illuminate/collections', $vendorDir . '/illuminate/macroable', $vendorDir . '/illuminate/conditionable'),
'Illuminate\\Contracts\\' => array($vendorDir . '/illuminate/contracts'),
'Html2Text\\' => array($vendorDir . '/soundasleep/html2text/src'),
+ 'GuzzleHttp\\Psr7\\' => array($vendorDir . '/guzzlehttp/psr7/src'),
+ 'GuzzleHttp\\Promise\\' => array($vendorDir . '/guzzlehttp/promises/src'),
+ 'GuzzleHttp\\' => array($vendorDir . '/guzzlehttp/guzzle/src'),
+ 'Firebase\\JWT\\' => array($vendorDir . '/firebase/php-jwt/src'),
'Ddeboer\\Imap\\' => array($vendorDir . '/ddeboer/imap/src'),
+ 'DASPRiD\\Enum\\' => array($vendorDir . '/dasprid/enum/src'),
+ 'Carbon\\Doctrine\\' => array($vendorDir . '/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine'),
'Carbon\\' => array($vendorDir . '/nesbot/carbon/src/Carbon'),
+ 'BaconQrCode\\' => array($vendorDir . '/bacon/bacon-qr-code/src'),
);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_real.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_real.php
index 6891b0c..5e20825 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_real.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/autoload_real.php
@@ -33,25 +33,18 @@
$loader->register(true);
- $includeFiles = \Composer\Autoload\ComposerStaticInit873464e4bd965a3168f133248b1b218b::$files;
- foreach ($includeFiles as $fileIdentifier => $file) {
- composerRequire873464e4bd965a3168f133248b1b218b($fileIdentifier, $file);
+ $filesToLoad = \Composer\Autoload\ComposerStaticInit873464e4bd965a3168f133248b1b218b::$files;
+ $requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
+ if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
+ $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
+
+ require $file;
+ }
+ }, null, null);
+ foreach ($filesToLoad as $fileIdentifier => $file) {
+ $requireFile($fileIdentifier, $file);
}
return $loader;
}
}
-
-/**
- * @param string $fileIdentifier
- * @param string $file
- * @return void
- */
-function composerRequire873464e4bd965a3168f133248b1b218b($fileIdentifier, $file)
-{
- if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
- $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
-
- require $file;
- }
-}
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 94606e8..f66ad0c 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,30 +7,37 @@
class ComposerStaticInit873464e4bd965a3168f133248b1b218b
{
public static $files = array (
+ '6e3fae29631ef280660b3cdad06f25a8' => __DIR__ . '/..' . '/symfony/deprecation-contracts/function.php',
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
+ '7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php',
+ 'c964ee0ededf28c96ebd9db5099ef910' => __DIR__ . '/..' . '/guzzlehttp/promises/src/functions_include.php',
+ '37a3dc5111fe8f707ab4c132ef1dbc62' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/functions_include.php',
'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php',
'a1105708a18b76903365ca1c4aa61b02' => __DIR__ . '/..' . '/symfony/translation/Resources/functions.php',
- '667aeda72477189d0494fecd327c3641' => __DIR__ . '/..' . '/symfony/var-dumper/Resources/functions/dump.php',
+ '60799491728b879e74601d83e38b2cad' => __DIR__ . '/..' . '/illuminate/collections/helpers.php',
'320cde22f66dd4f5d3fd621d3e88b98f' => __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php',
- 'fe62ba7e10580d903cc46d808b5961a4' => __DIR__ . '/..' . '/tightenco/collect/src/Collect/Support/helpers.php',
- 'caf31cc6ec7cf2241cb6f12c226c3846' => __DIR__ . '/..' . '/tightenco/collect/src/Collect/Support/alias.php',
+ '23c18046f52bef3eea034657bafda50f' => __DIR__ . '/..' . '/symfony/polyfill-php81/bootstrap.php',
'04c6c5c2f7095ccf6c481d3e53e1776f' => __DIR__ . '/..' . '/mustangostang/spyc/Spyc.php',
+ '89efb1254ef2d1c5d80096acd12c4098' => __DIR__ . '/..' . '/twig/twig/src/Resources/core.php',
+ 'ffecb95d45175fd40f75be8a23b34f90' => __DIR__ . '/..' . '/twig/twig/src/Resources/debug.php',
+ 'c7baa00073ee9c61edf148c51917cfb4' => __DIR__ . '/..' . '/twig/twig/src/Resources/escaper.php',
+ 'f844ccf1d25df8663951193c3fc307c8' => __DIR__ . '/..' . '/twig/twig/src/Resources/string_loader.php',
);
public static $prefixLengthsPsr4 = array (
'T' =>
array (
'Twig\\' => 5,
- 'Tightenco\\Collect\\' => 18,
),
'S' =>
array (
+ 'Symfony\\Polyfill\\Php81\\' => 23,
'Symfony\\Polyfill\\Php80\\' => 23,
'Symfony\\Polyfill\\Mbstring\\' => 26,
'Symfony\\Polyfill\\Ctype\\' => 23,
'Symfony\\Contracts\\Translation\\' => 30,
- 'Symfony\\Component\\VarDumper\\' => 28,
'Symfony\\Component\\Translation\\' => 30,
+ 'Stevenmaguire\\OAuth2\\Client\\' => 28,
),
'R' =>
array (
@@ -40,7 +47,10 @@
array (
'Psr\\SimpleCache\\' => 16,
'Psr\\Log\\' => 8,
+ 'Psr\\Http\\Message\\' => 17,
+ 'Psr\\Http\\Client\\' => 16,
'Psr\\Container\\' => 14,
+ 'Psr\\Clock\\' => 10,
'PhpMimeMailParser\\' => 18,
'PHPMailer\\PHPMailer\\' => 20,
),
@@ -51,24 +61,42 @@
),
'L' =>
array (
+ 'League\\OAuth2\\Client\\' => 21,
'LdapRecord\\' => 11,
),
'I' =>
array (
+ 'Illuminate\\Support\\' => 19,
'Illuminate\\Contracts\\' => 21,
),
'H' =>
array (
'Html2Text\\' => 10,
),
+ 'G' =>
+ array (
+ 'GuzzleHttp\\Psr7\\' => 16,
+ 'GuzzleHttp\\Promise\\' => 19,
+ 'GuzzleHttp\\' => 11,
+ ),
+ 'F' =>
+ array (
+ 'Firebase\\JWT\\' => 13,
+ ),
'D' =>
array (
'Ddeboer\\Imap\\' => 13,
+ 'DASPRiD\\Enum\\' => 13,
),
'C' =>
array (
+ 'Carbon\\Doctrine\\' => 16,
'Carbon\\' => 7,
),
+ 'B' =>
+ array (
+ 'BaconQrCode\\' => 12,
+ ),
);
public static $prefixDirsPsr4 = array (
@@ -76,9 +104,9 @@
array (
0 => __DIR__ . '/..' . '/twig/twig/src',
),
- 'Tightenco\\Collect\\' =>
+ 'Symfony\\Polyfill\\Php81\\' =>
array (
- 0 => __DIR__ . '/..' . '/tightenco/collect/src/Collect',
+ 0 => __DIR__ . '/..' . '/symfony/polyfill-php81',
),
'Symfony\\Polyfill\\Php80\\' =>
array (
@@ -96,14 +124,14 @@
array (
0 => __DIR__ . '/..' . '/symfony/translation-contracts',
),
- 'Symfony\\Component\\VarDumper\\' =>
- array (
- 0 => __DIR__ . '/..' . '/symfony/var-dumper',
- ),
'Symfony\\Component\\Translation\\' =>
array (
0 => __DIR__ . '/..' . '/symfony/translation',
),
+ 'Stevenmaguire\\OAuth2\\Client\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/stevenmaguire/oauth2-keycloak/src',
+ ),
'RobThree\\Auth\\' =>
array (
0 => __DIR__ . '/..' . '/robthree/twofactorauth/lib',
@@ -116,10 +144,23 @@
array (
0 => __DIR__ . '/..' . '/psr/log/src',
),
+ 'Psr\\Http\\Message\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/psr/http-factory/src',
+ 1 => __DIR__ . '/..' . '/psr/http-message/src',
+ ),
+ 'Psr\\Http\\Client\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/psr/http-client/src',
+ ),
'Psr\\Container\\' =>
array (
0 => __DIR__ . '/..' . '/psr/container/src',
),
+ 'Psr\\Clock\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/psr/clock/src',
+ ),
'PhpMimeMailParser\\' =>
array (
0 => __DIR__ . '/..' . '/php-mime-mail-parser/php-mime-mail-parser/src',
@@ -136,10 +177,20 @@
array (
0 => __DIR__ . '/..' . '/matthiasmullie/minify/src',
),
+ 'League\\OAuth2\\Client\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/league/oauth2-client/src',
+ ),
'LdapRecord\\' =>
array (
0 => __DIR__ . '/..' . '/directorytree/ldaprecord/src',
),
+ 'Illuminate\\Support\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/illuminate/collections',
+ 1 => __DIR__ . '/..' . '/illuminate/macroable',
+ 2 => __DIR__ . '/..' . '/illuminate/conditionable',
+ ),
'Illuminate\\Contracts\\' =>
array (
0 => __DIR__ . '/..' . '/illuminate/contracts',
@@ -148,14 +199,42 @@
array (
0 => __DIR__ . '/..' . '/soundasleep/html2text/src',
),
+ 'GuzzleHttp\\Psr7\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/guzzlehttp/psr7/src',
+ ),
+ 'GuzzleHttp\\Promise\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/guzzlehttp/promises/src',
+ ),
+ 'GuzzleHttp\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/guzzlehttp/guzzle/src',
+ ),
+ 'Firebase\\JWT\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/firebase/php-jwt/src',
+ ),
'Ddeboer\\Imap\\' =>
array (
0 => __DIR__ . '/..' . '/ddeboer/imap/src',
),
+ 'DASPRiD\\Enum\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/dasprid/enum/src',
+ ),
+ 'Carbon\\Doctrine\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/carbonphp/carbon-doctrine-types/src/Carbon/Doctrine',
+ ),
'Carbon\\' =>
array (
0 => __DIR__ . '/..' . '/nesbot/carbon/src/Carbon',
),
+ 'BaconQrCode\\' =>
+ array (
+ 0 => __DIR__ . '/..' . '/bacon/bacon-qr-code/src',
+ ),
);
public static $prefixesPsr0 = array (
@@ -170,15 +249,13 @@
public static $classMap = array (
'Attribute' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/Attribute.php',
+ 'CURLStringFile' => __DIR__ . '/..' . '/symfony/polyfill-php81/Resources/stubs/CURLStringFile.php',
'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
+ 'PhpToken' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/PhpToken.php',
+ 'ReturnTypeWillChange' => __DIR__ . '/..' . '/symfony/polyfill-php81/Resources/stubs/ReturnTypeWillChange.php',
'Stringable' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/Stringable.php',
'UnhandledMatchError' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php',
'ValueError' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/ValueError.php',
- 'u2flib_server\\Error' => __DIR__ . '/..' . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\RegisterRequest' => __DIR__ . '/..' . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\Registration' => __DIR__ . '/..' . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\SignRequest' => __DIR__ . '/..' . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
- 'u2flib_server\\U2F' => __DIR__ . '/..' . '/yubico/u2flib-server/src/u2flib_server/U2F.php',
);
public static function getInitializer(ClassLoader $loader)
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 e21edcc..e2d7113 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
@@ -1,6 +1,63 @@
{
"packages": [
{
+ "name": "bacon/bacon-qr-code",
+ "version": "2.0.8",
+ "version_normalized": "2.0.8.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Bacon/BaconQrCode.git",
+ "reference": "8674e51bb65af933a5ffaf1c308a660387c35c22"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Bacon/BaconQrCode/zipball/8674e51bb65af933a5ffaf1c308a660387c35c22",
+ "reference": "8674e51bb65af933a5ffaf1c308a660387c35c22",
+ "shasum": ""
+ },
+ "require": {
+ "dasprid/enum": "^1.0.3",
+ "ext-iconv": "*",
+ "php": "^7.1 || ^8.0"
+ },
+ "require-dev": {
+ "phly/keep-a-changelog": "^2.1",
+ "phpunit/phpunit": "^7 | ^8 | ^9",
+ "spatie/phpunit-snapshot-assertions": "^4.2.9",
+ "squizlabs/php_codesniffer": "^3.4"
+ },
+ "suggest": {
+ "ext-imagick": "to generate QR code images"
+ },
+ "time": "2022-12-07T17:46:57+00:00",
+ "type": "library",
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "BaconQrCode\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-2-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Ben Scholzen 'DASPRiD'",
+ "email": "mail@dasprids.de",
+ "homepage": "https://dasprids.de/",
+ "role": "Developer"
+ }
+ ],
+ "description": "BaconQrCode is a QR code generator for PHP.",
+ "homepage": "https://github.com/Bacon/BaconQrCode",
+ "support": {
+ "issues": "https://github.com/Bacon/BaconQrCode/issues",
+ "source": "https://github.com/Bacon/BaconQrCode/tree/2.0.8"
+ },
+ "install-path": "../bacon/bacon-qr-code"
+ },
+ {
"name": "bshaffer/oauth2-server-php",
"version": "v1.11.1",
"version_normalized": "1.11.1.0",
@@ -62,6 +119,131 @@
"install-path": "../bshaffer/oauth2-server-php"
},
{
+ "name": "carbonphp/carbon-doctrine-types",
+ "version": "3.2.0",
+ "version_normalized": "3.2.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/CarbonPHP/carbon-doctrine-types.git",
+ "reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/CarbonPHP/carbon-doctrine-types/zipball/18ba5ddfec8976260ead6e866180bd5d2f71aa1d",
+ "reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.1"
+ },
+ "conflict": {
+ "doctrine/dbal": "<4.0.0 || >=5.0.0"
+ },
+ "require-dev": {
+ "doctrine/dbal": "^4.0.0",
+ "nesbot/carbon": "^2.71.0 || ^3.0.0",
+ "phpunit/phpunit": "^10.3"
+ },
+ "time": "2024-02-09T16:56:22+00:00",
+ "type": "library",
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Carbon\\Doctrine\\": "src/Carbon/Doctrine/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "KyleKatarn",
+ "email": "kylekatarnls@gmail.com"
+ }
+ ],
+ "description": "Types to use Carbon in Doctrine",
+ "keywords": [
+ "carbon",
+ "date",
+ "datetime",
+ "doctrine",
+ "time"
+ ],
+ "support": {
+ "issues": "https://github.com/CarbonPHP/carbon-doctrine-types/issues",
+ "source": "https://github.com/CarbonPHP/carbon-doctrine-types/tree/3.2.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/kylekatarnls",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/Carbon",
+ "type": "open_collective"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/nesbot/carbon",
+ "type": "tidelift"
+ }
+ ],
+ "install-path": "../carbonphp/carbon-doctrine-types"
+ },
+ {
+ "name": "dasprid/enum",
+ "version": "1.0.7",
+ "version_normalized": "1.0.7.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/DASPRiD/Enum.git",
+ "reference": "b5874fa9ed0043116c72162ec7f4fb50e02e7cce"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/DASPRiD/Enum/zipball/b5874fa9ed0043116c72162ec7f4fb50e02e7cce",
+ "reference": "b5874fa9ed0043116c72162ec7f4fb50e02e7cce",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.1 <9.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^7 || ^8 || ^9 || ^10 || ^11",
+ "squizlabs/php_codesniffer": "*"
+ },
+ "time": "2025-09-16T12:23:56+00:00",
+ "type": "library",
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "DASPRiD\\Enum\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-2-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Ben Scholzen 'DASPRiD'",
+ "email": "mail@dasprids.de",
+ "homepage": "https://dasprids.de/",
+ "role": "Developer"
+ }
+ ],
+ "description": "PHP 7.1 enum implementation",
+ "keywords": [
+ "enum",
+ "map"
+ ],
+ "support": {
+ "issues": "https://github.com/DASPRiD/Enum/issues",
+ "source": "https://github.com/DASPRiD/Enum/tree/1.0.7"
+ },
+ "install-path": "../dasprid/enum"
+ },
+ {
"name": "ddeboer/imap",
"version": "1.13.1",
"version_normalized": "1.13.1.0",
@@ -141,35 +323,38 @@
},
{
"name": "directorytree/ldaprecord",
- "version": "v2.10.1",
- "version_normalized": "2.10.1.0",
+ "version": "v3.8.5",
+ "version_normalized": "3.8.5.0",
"source": {
"type": "git",
"url": "https://github.com/DirectoryTree/LdapRecord.git",
- "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88"
+ "reference": "00e5f088f8c4028d5f398783cccc2e8119a27a65"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/bf512d9af7a7b0e2ed7a666ab29cefdd027bee88",
- "reference": "bf512d9af7a7b0e2ed7a666ab29cefdd027bee88",
+ "url": "https://api.github.com/repos/DirectoryTree/LdapRecord/zipball/00e5f088f8c4028d5f398783cccc2e8119a27a65",
+ "reference": "00e5f088f8c4028d5f398783cccc2e8119a27a65",
"shasum": ""
},
"require": {
+ "ext-iconv": "*",
"ext-json": "*",
"ext-ldap": "*",
- "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0|^9.0",
- "nesbot/carbon": "^1.0|^2.0",
- "php": ">=7.3",
+ "illuminate/collections": "^8.0|^9.0|^10.0|^11.0|^12.0",
+ "illuminate/contracts": "^8.0|^9.0|^10.0|^11.0|^12.0",
+ "nesbot/carbon": "*",
+ "php": ">=8.1",
"psr/log": "*",
- "psr/simple-cache": "^1.0|^2.0",
- "tightenco/collect": "^5.6|^6.0|^7.0|^8.0"
+ "psr/simple-cache": "^1.0|^2.0|^3.0"
},
"require-dev": {
+ "fakerphp/faker": "^1.21",
+ "laravel/pint": "^1.6",
"mockery/mockery": "^1.0",
"phpunit/phpunit": "^9.0",
"spatie/ray": "^1.24"
},
- "time": "2022-02-25T16:00:51+00:00",
+ "time": "2025-10-06T02:22:34+00:00",
"type": "library",
"installation-source": "dist",
"autoload": {
@@ -216,30 +401,540 @@
"install-path": "../directorytree/ldaprecord"
},
{
- "name": "illuminate/contracts",
- "version": "v9.3.0",
- "version_normalized": "9.3.0.0",
+ "name": "firebase/php-jwt",
+ "version": "v6.5.0",
+ "version_normalized": "6.5.0.0",
"source": {
"type": "git",
- "url": "https://github.com/illuminate/contracts.git",
- "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0"
+ "url": "https://github.com/firebase/php-jwt.git",
+ "reference": "e94e7353302b0c11ec3cfff7180cd0b1743975d2"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/illuminate/contracts/zipball/bf4b3c254c49d28157645d01e4883b5951b1e1d0",
- "reference": "bf4b3c254c49d28157645d01e4883b5951b1e1d0",
+ "url": "https://api.github.com/repos/firebase/php-jwt/zipball/e94e7353302b0c11ec3cfff7180cd0b1743975d2",
+ "reference": "e94e7353302b0c11ec3cfff7180cd0b1743975d2",
"shasum": ""
},
"require": {
- "php": "^8.0.2",
- "psr/container": "^1.1.1|^2.0.1",
- "psr/simple-cache": "^1.0|^2.0|^3.0"
+ "php": "^7.4||^8.0"
},
- "time": "2022-02-22T14:45:39+00:00",
+ "require-dev": {
+ "guzzlehttp/guzzle": "^6.5||^7.4",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5",
+ "psr/cache": "^1.0||^2.0",
+ "psr/http-client": "^1.0",
+ "psr/http-factory": "^1.0"
+ },
+ "suggest": {
+ "ext-sodium": "Support EdDSA (Ed25519) signatures",
+ "paragonie/sodium_compat": "Support EdDSA (Ed25519) signatures when libsodium is not present"
+ },
+ "time": "2023-05-12T15:47:07+00:00",
+ "type": "library",
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Firebase\\JWT\\": "src"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "BSD-3-Clause"
+ ],
+ "authors": [
+ {
+ "name": "Neuman Vong",
+ "email": "neuman+pear@twilio.com",
+ "role": "Developer"
+ },
+ {
+ "name": "Anant Narayanan",
+ "email": "anant@php.net",
+ "role": "Developer"
+ }
+ ],
+ "description": "A simple library to encode and decode JSON Web Tokens (JWT) in PHP. Should conform to the current spec.",
+ "homepage": "https://github.com/firebase/php-jwt",
+ "keywords": [
+ "jwt",
+ "php"
+ ],
+ "support": {
+ "issues": "https://github.com/firebase/php-jwt/issues",
+ "source": "https://github.com/firebase/php-jwt/tree/v6.5.0"
+ },
+ "install-path": "../firebase/php-jwt"
+ },
+ {
+ "name": "guzzlehttp/guzzle",
+ "version": "7.5.0",
+ "version_normalized": "7.5.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/guzzle.git",
+ "reference": "b50a2a1251152e43f6a37f0fa053e730a67d25ba"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/guzzle/zipball/b50a2a1251152e43f6a37f0fa053e730a67d25ba",
+ "reference": "b50a2a1251152e43f6a37f0fa053e730a67d25ba",
+ "shasum": ""
+ },
+ "require": {
+ "ext-json": "*",
+ "guzzlehttp/promises": "^1.5",
+ "guzzlehttp/psr7": "^1.9 || ^2.4",
+ "php": "^7.2.5 || ^8.0",
+ "psr/http-client": "^1.0",
+ "symfony/deprecation-contracts": "^2.2 || ^3.0"
+ },
+ "provide": {
+ "psr/http-client-implementation": "1.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.1",
+ "ext-curl": "*",
+ "php-http/client-integration-tests": "^3.0",
+ "phpunit/phpunit": "^8.5.29 || ^9.5.23",
+ "psr/log": "^1.1 || ^2.0 || ^3.0"
+ },
+ "suggest": {
+ "ext-curl": "Required for CURL handler support",
+ "ext-intl": "Required for Internationalized Domain Name (IDN) support",
+ "psr/log": "Required for using the Log middleware"
+ },
+ "time": "2022-08-28T15:39:27+00:00",
+ "type": "library",
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ },
+ "branch-alias": {
+ "dev-master": "7.5-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "files": [
+ "src/functions_include.php"
+ ],
+ "psr-4": {
+ "GuzzleHttp\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Jeremy Lindblom",
+ "email": "jeremeamia@gmail.com",
+ "homepage": "https://github.com/jeremeamia"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "description": "Guzzle is a PHP HTTP client library",
+ "keywords": [
+ "client",
+ "curl",
+ "framework",
+ "http",
+ "http client",
+ "psr-18",
+ "psr-7",
+ "rest",
+ "web service"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/guzzle/issues",
+ "source": "https://github.com/guzzle/guzzle/tree/7.5.0"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/guzzle",
+ "type": "tidelift"
+ }
+ ],
+ "install-path": "../guzzlehttp/guzzle"
+ },
+ {
+ "name": "guzzlehttp/promises",
+ "version": "1.5.2",
+ "version_normalized": "1.5.2.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/promises.git",
+ "reference": "b94b2807d85443f9719887892882d0329d1e2598"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/promises/zipball/b94b2807d85443f9719887892882d0329d1e2598",
+ "reference": "b94b2807d85443f9719887892882d0329d1e2598",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.5"
+ },
+ "require-dev": {
+ "symfony/phpunit-bridge": "^4.4 || ^5.1"
+ },
+ "time": "2022-08-28T14:55:35+00:00",
"type": "library",
"extra": {
"branch-alias": {
- "dev-master": "9.x-dev"
+ "dev-master": "1.5-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "files": [
+ "src/functions_include.php"
+ ],
+ "psr-4": {
+ "GuzzleHttp\\Promise\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "description": "Guzzle promises library",
+ "keywords": [
+ "promise"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/promises/issues",
+ "source": "https://github.com/guzzle/promises/tree/1.5.2"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/promises",
+ "type": "tidelift"
+ }
+ ],
+ "install-path": "../guzzlehttp/promises"
+ },
+ {
+ "name": "guzzlehttp/psr7",
+ "version": "2.4.5",
+ "version_normalized": "2.4.5.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/guzzle/psr7.git",
+ "reference": "0454e12ef0cd597ccd2adb036f7bda4e7fface66"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/guzzle/psr7/zipball/0454e12ef0cd597ccd2adb036f7bda4e7fface66",
+ "reference": "0454e12ef0cd597ccd2adb036f7bda4e7fface66",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.2.5 || ^8.0",
+ "psr/http-factory": "^1.0",
+ "psr/http-message": "^1.0",
+ "ralouphie/getallheaders": "^3.0"
+ },
+ "provide": {
+ "psr/http-factory-implementation": "1.0",
+ "psr/http-message-implementation": "1.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.1",
+ "http-interop/http-factory-tests": "^0.9",
+ "phpunit/phpunit": "^8.5.29 || ^9.5.23"
+ },
+ "suggest": {
+ "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses"
+ },
+ "time": "2023-04-17T16:00:45+00:00",
+ "type": "library",
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "GuzzleHttp\\Psr7\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://sagikazarmark.hu"
+ }
+ ],
+ "description": "PSR-7 message implementation that also provides common utility methods",
+ "keywords": [
+ "http",
+ "message",
+ "psr-7",
+ "request",
+ "response",
+ "stream",
+ "uri",
+ "url"
+ ],
+ "support": {
+ "issues": "https://github.com/guzzle/psr7/issues",
+ "source": "https://github.com/guzzle/psr7/tree/2.4.5"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/GrahamCampbell",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/Nyholm",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/psr7",
+ "type": "tidelift"
+ }
+ ],
+ "install-path": "../guzzlehttp/psr7"
+ },
+ {
+ "name": "illuminate/collections",
+ "version": "v10.49.0",
+ "version_normalized": "10.49.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/collections.git",
+ "reference": "6ae9c74fa92d4e1824d1b346cd435e8eacdc3232"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/collections/zipball/6ae9c74fa92d4e1824d1b346cd435e8eacdc3232",
+ "reference": "6ae9c74fa92d4e1824d1b346cd435e8eacdc3232",
+ "shasum": ""
+ },
+ "require": {
+ "illuminate/conditionable": "^10.0",
+ "illuminate/contracts": "^10.0",
+ "illuminate/macroable": "^10.0",
+ "php": "^8.1"
+ },
+ "suggest": {
+ "symfony/var-dumper": "Required to use the dump method (^6.2)."
+ },
+ "time": "2025-09-08T19:05:53+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "files": [
+ "helpers.php"
+ ],
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "description": "The Illuminate Collections package.",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "install-path": "../illuminate/collections"
+ },
+ {
+ "name": "illuminate/conditionable",
+ "version": "v10.49.0",
+ "version_normalized": "10.49.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/conditionable.git",
+ "reference": "47c700320b7a419f0d188d111f3bbed978fcbd3f"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/conditionable/zipball/47c700320b7a419f0d188d111f3bbed978fcbd3f",
+ "reference": "47c700320b7a419f0d188d111f3bbed978fcbd3f",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.0.2"
+ },
+ "time": "2025-03-24T11:47:24+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "description": "The Illuminate Conditionable package.",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "install-path": "../illuminate/conditionable"
+ },
+ {
+ "name": "illuminate/contracts",
+ "version": "v10.44.0",
+ "version_normalized": "10.44.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/contracts.git",
+ "reference": "8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/contracts/zipball/8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac",
+ "reference": "8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.1",
+ "psr/container": "^1.1.1|^2.0.1",
+ "psr/simple-cache": "^1.0|^2.0|^3.0"
+ },
+ "time": "2024-01-15T18:52:32+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
}
},
"installation-source": "dist",
@@ -267,6 +962,128 @@
"install-path": "../illuminate/contracts"
},
{
+ "name": "illuminate/macroable",
+ "version": "v10.49.0",
+ "version_normalized": "10.49.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/illuminate/macroable.git",
+ "reference": "dff667a46ac37b634dcf68909d9d41e94dc97c27"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/illuminate/macroable/zipball/dff667a46ac37b634dcf68909d9d41e94dc97c27",
+ "reference": "dff667a46ac37b634dcf68909d9d41e94dc97c27",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^8.1"
+ },
+ "time": "2023-06-05T12:46:42+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "description": "The Illuminate Macroable package.",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "install-path": "../illuminate/macroable"
+ },
+ {
+ "name": "league/oauth2-client",
+ "version": "2.7.0",
+ "version_normalized": "2.7.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/thephpleague/oauth2-client.git",
+ "reference": "160d6274b03562ebeb55ed18399281d8118b76c8"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/thephpleague/oauth2-client/zipball/160d6274b03562ebeb55ed18399281d8118b76c8",
+ "reference": "160d6274b03562ebeb55ed18399281d8118b76c8",
+ "shasum": ""
+ },
+ "require": {
+ "guzzlehttp/guzzle": "^6.0 || ^7.0",
+ "paragonie/random_compat": "^1 || ^2 || ^9.99",
+ "php": "^5.6 || ^7.0 || ^8.0"
+ },
+ "require-dev": {
+ "mockery/mockery": "^1.3.5",
+ "php-parallel-lint/php-parallel-lint": "^1.3.1",
+ "phpunit/phpunit": "^5.7 || ^6.0 || ^9.5",
+ "squizlabs/php_codesniffer": "^2.3 || ^3.0"
+ },
+ "time": "2023-04-16T18:19:15+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-2.x": "2.0.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "League\\OAuth2\\Client\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Alex Bilbie",
+ "email": "hello@alexbilbie.com",
+ "homepage": "http://www.alexbilbie.com",
+ "role": "Developer"
+ },
+ {
+ "name": "Woody Gilk",
+ "homepage": "https://github.com/shadowhand",
+ "role": "Contributor"
+ }
+ ],
+ "description": "OAuth 2.0 Client Library",
+ "keywords": [
+ "Authentication",
+ "SSO",
+ "authorization",
+ "identity",
+ "idp",
+ "oauth",
+ "oauth2",
+ "single sign on"
+ ],
+ "support": {
+ "issues": "https://github.com/thephpleague/oauth2-client/issues",
+ "source": "https://github.com/thephpleague/oauth2-client/tree/2.7.0"
+ },
+ "install-path": "../league/oauth2-client"
+ },
+ {
"name": "matthiasmullie/minify",
"version": "1.3.66",
"version_normalized": "1.3.66.0",
@@ -454,38 +1271,45 @@
},
{
"name": "nesbot/carbon",
- "version": "2.57.0",
- "version_normalized": "2.57.0.0",
+ "version": "2.72.3",
+ "version_normalized": "2.72.3.0",
"source": {
"type": "git",
"url": "https://github.com/briannesbitt/Carbon.git",
- "reference": "4a54375c21eea4811dbd1149fe6b246517554e78"
+ "reference": "0c6fd108360c562f6e4fd1dedb8233b423e91c83"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/4a54375c21eea4811dbd1149fe6b246517554e78",
- "reference": "4a54375c21eea4811dbd1149fe6b246517554e78",
+ "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/0c6fd108360c562f6e4fd1dedb8233b423e91c83",
+ "reference": "0c6fd108360c562f6e4fd1dedb8233b423e91c83",
"shasum": ""
},
"require": {
+ "carbonphp/carbon-doctrine-types": "*",
"ext-json": "*",
"php": "^7.1.8 || ^8.0",
+ "psr/clock": "^1.0",
"symfony/polyfill-mbstring": "^1.0",
"symfony/polyfill-php80": "^1.16",
"symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0"
},
+ "provide": {
+ "psr/clock-implementation": "1.0"
+ },
"require-dev": {
- "doctrine/dbal": "^2.0 || ^3.0",
- "doctrine/orm": "^2.7",
+ "doctrine/dbal": "^2.0 || ^3.1.4 || ^4.0",
+ "doctrine/orm": "^2.7 || ^3.0",
"friendsofphp/php-cs-fixer": "^3.0",
"kylekatarnls/multi-tester": "^2.0",
+ "ondrejmirtes/better-reflection": "*",
"phpmd/phpmd": "^2.9",
"phpstan/extension-installer": "^1.0",
- "phpstan/phpstan": "^0.12.54 || ^1.0",
- "phpunit/phpunit": "^7.5.20 || ^8.5.14",
+ "phpstan/phpstan": "^0.12.99 || ^1.7.14",
+ "phpunit/php-file-iterator": "^2.0.5 || ^3.0.6",
+ "phpunit/phpunit": "^7.5.20 || ^8.5.26 || ^9.5.20",
"squizlabs/php_codesniffer": "^3.4"
},
- "time": "2022-02-13T18:13:33+00:00",
+ "time": "2024-01-25T10:35:09+00:00",
"bin": [
"bin/carbon"
],
@@ -541,11 +1365,15 @@
},
"funding": [
{
- "url": "https://opencollective.com/Carbon",
- "type": "open_collective"
+ "url": "https://github.com/sponsors/kylekatarnls",
+ "type": "github"
},
{
- "url": "https://tidelift.com/funding/github/packagist/nesbot/carbon",
+ "url": "https://opencollective.com/Carbon#sponsor",
+ "type": "opencollective"
+ },
+ {
+ "url": "https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme",
"type": "tidelift"
}
],
@@ -780,6 +1608,57 @@
"install-path": "../phpmailer/phpmailer"
},
{
+ "name": "psr/clock",
+ "version": "1.0.0",
+ "version_normalized": "1.0.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/clock.git",
+ "reference": "e41a24703d4560fd0acb709162f73b8adfc3aa0d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/clock/zipball/e41a24703d4560fd0acb709162f73b8adfc3aa0d",
+ "reference": "e41a24703d4560fd0acb709162f73b8adfc3aa0d",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.0 || ^8.0"
+ },
+ "time": "2022-11-25T14:36:26+00:00",
+ "type": "library",
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Psr\\Clock\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for reading the clock.",
+ "homepage": "https://github.com/php-fig/clock",
+ "keywords": [
+ "clock",
+ "now",
+ "psr",
+ "psr-20",
+ "time"
+ ],
+ "support": {
+ "issues": "https://github.com/php-fig/clock/issues",
+ "source": "https://github.com/php-fig/clock/tree/1.0.0"
+ },
+ "install-path": "../psr/clock"
+ },
+ {
"name": "psr/container",
"version": "2.0.2",
"version_normalized": "2.0.2.0",
@@ -836,6 +1715,175 @@
"install-path": "../psr/container"
},
{
+ "name": "psr/http-client",
+ "version": "1.0.1",
+ "version_normalized": "1.0.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-client.git",
+ "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621",
+ "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^7.0 || ^8.0",
+ "psr/http-message": "^1.0"
+ },
+ "time": "2020-06-29T06:28:15+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Client\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for HTTP clients",
+ "homepage": "https://github.com/php-fig/http-client",
+ "keywords": [
+ "http",
+ "http-client",
+ "psr",
+ "psr-18"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-client/tree/master"
+ },
+ "install-path": "../psr/http-client"
+ },
+ {
+ "name": "psr/http-factory",
+ "version": "1.0.1",
+ "version_normalized": "1.0.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-factory.git",
+ "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-factory/zipball/12ac7fcd07e5b077433f5f2bee95b3a771bf61be",
+ "reference": "12ac7fcd07e5b077433f5f2bee95b3a771bf61be",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=7.0.0",
+ "psr/http-message": "^1.0"
+ },
+ "time": "2019-04-30T12:38:16+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interfaces for PSR-7 HTTP message factories",
+ "keywords": [
+ "factory",
+ "http",
+ "message",
+ "psr",
+ "psr-17",
+ "psr-7",
+ "request",
+ "response"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-factory/tree/master"
+ },
+ "install-path": "../psr/http-factory"
+ },
+ {
+ "name": "psr/http-message",
+ "version": "1.0.1",
+ "version_normalized": "1.0.1.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/php-fig/http-message.git",
+ "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363",
+ "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.3.0"
+ },
+ "time": "2016-08-06T14:39:51+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "description": "Common interface for HTTP messages",
+ "homepage": "https://github.com/php-fig/http-message",
+ "keywords": [
+ "http",
+ "http-message",
+ "psr",
+ "psr-7",
+ "request",
+ "response"
+ ],
+ "support": {
+ "source": "https://github.com/php-fig/http-message/tree/master"
+ },
+ "install-path": "../psr/http-message"
+ },
+ {
"name": "psr/log",
"version": "3.0.0",
"version_normalized": "3.0.0.0",
@@ -943,6 +1991,53 @@
"install-path": "../psr/simple-cache"
},
{
+ "name": "ralouphie/getallheaders",
+ "version": "3.0.3",
+ "version_normalized": "3.0.3.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/ralouphie/getallheaders.git",
+ "reference": "120b605dfeb996808c31b6477290a714d356e822"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822",
+ "reference": "120b605dfeb996808c31b6477290a714d356e822",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.6"
+ },
+ "require-dev": {
+ "php-coveralls/php-coveralls": "^2.1",
+ "phpunit/phpunit": "^5 || ^6.5"
+ },
+ "time": "2019-03-08T08:55:37+00:00",
+ "type": "library",
+ "installation-source": "dist",
+ "autoload": {
+ "files": [
+ "src/getallheaders.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Ralph Khattar",
+ "email": "ralph.khattar@gmail.com"
+ }
+ ],
+ "description": "A polyfill for getallheaders.",
+ "support": {
+ "issues": "https://github.com/ralouphie/getallheaders/issues",
+ "source": "https://github.com/ralouphie/getallheaders/tree/develop"
+ },
+ "install-path": "../ralouphie/getallheaders"
+ },
+ {
"name": "robthree/twofactorauth",
"version": "1.8.1",
"version_normalized": "1.8.1.0",
@@ -1069,6 +2164,140 @@
"install-path": "../soundasleep/html2text"
},
{
+ "name": "stevenmaguire/oauth2-keycloak",
+ "version": "4.0.0",
+ "version_normalized": "4.0.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/stevenmaguire/oauth2-keycloak.git",
+ "reference": "05ead6bb6bcd2b6f96dfae87c769dcd3e5f6129d"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/stevenmaguire/oauth2-keycloak/zipball/05ead6bb6bcd2b6f96dfae87c769dcd3e5f6129d",
+ "reference": "05ead6bb6bcd2b6f96dfae87c769dcd3e5f6129d",
+ "shasum": ""
+ },
+ "require": {
+ "firebase/php-jwt": "^4.0 || ^5.0 || ^6.0",
+ "league/oauth2-client": "^2.0",
+ "php": "~7.2 || ~8.0"
+ },
+ "require-dev": {
+ "mockery/mockery": "~1.5.0",
+ "phpunit/phpunit": "~9.6.4",
+ "squizlabs/php_codesniffer": "~3.7.0"
+ },
+ "time": "2023-03-14T09:43:47+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "psr-4": {
+ "Stevenmaguire\\OAuth2\\Client\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Steven Maguire",
+ "email": "stevenmaguire@gmail.com",
+ "homepage": "https://github.com/stevenmaguire"
+ }
+ ],
+ "description": "Keycloak OAuth 2.0 Client Provider for The PHP League OAuth2-Client",
+ "keywords": [
+ "authorisation",
+ "authorization",
+ "client",
+ "keycloak",
+ "oauth",
+ "oauth2"
+ ],
+ "support": {
+ "issues": "https://github.com/stevenmaguire/oauth2-keycloak/issues",
+ "source": "https://github.com/stevenmaguire/oauth2-keycloak/tree/4.0.0"
+ },
+ "install-path": "../stevenmaguire/oauth2-keycloak"
+ },
+ {
+ "name": "symfony/deprecation-contracts",
+ "version": "v3.5.0",
+ "version_normalized": "3.5.0.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/deprecation-contracts.git",
+ "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
+ "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.1"
+ },
+ "time": "2024-04-18T09:32:20+00:00",
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.5-dev"
+ },
+ "thanks": {
+ "name": "symfony/contracts",
+ "url": "https://github.com/symfony/contracts"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "files": [
+ "function.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Nicolas Grekas",
+ "email": "p@tchwork.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "description": "A generic function and convention to trigger deprecation notices",
+ "homepage": "https://symfony.com",
+ "support": {
+ "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.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/deprecation-contracts"
+ },
+ {
"name": "symfony/polyfill-ctype",
"version": "v1.24.0",
"version_normalized": "1.24.0.0",
@@ -1155,17 +2384,17 @@
},
{
"name": "symfony/polyfill-mbstring",
- "version": "v1.24.0",
- "version_normalized": "1.24.0.0",
+ "version": "v1.29.0",
+ "version_normalized": "1.29.0.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git",
- "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825"
+ "reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/0abb51d2f102e00a4eefcf46ba7fec406d245825",
- "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825",
+ "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
+ "reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec",
"shasum": ""
},
"require": {
@@ -1177,12 +2406,9 @@
"suggest": {
"ext-mbstring": "For best performance"
},
- "time": "2021-11-30T18:21:41+00:00",
+ "time": "2024-01-29T20:11:03+00:00",
"type": "library",
"extra": {
- "branch-alias": {
- "dev-main": "1.23-dev"
- },
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1221,7 +2447,7 @@
"shim"
],
"support": {
- "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.24.0"
+ "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.29.0"
},
"funding": [
{
@@ -1241,28 +2467,25 @@
},
{
"name": "symfony/polyfill-php80",
- "version": "v1.24.0",
- "version_normalized": "1.24.0.0",
+ "version": "v1.29.0",
+ "version_normalized": "1.29.0.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php80.git",
- "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9"
+ "reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/57b712b08eddb97c762a8caa32c84e037892d2e9",
- "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9",
+ "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/87b68208d5c1188808dd7839ee1e6c8ec3b02f1b",
+ "reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b",
"shasum": ""
},
"require": {
"php": ">=7.1"
},
- "time": "2021-09-13T13:58:33+00:00",
+ "time": "2024-01-29T20:11:03+00:00",
"type": "library",
"extra": {
- "branch-alias": {
- "dev-main": "1.23-dev"
- },
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
@@ -1307,7 +2530,7 @@
"shim"
],
"support": {
- "source": "https://github.com/symfony/polyfill-php80/tree/v1.24.0"
+ "source": "https://github.com/symfony/polyfill-php80/tree/v1.29.0"
},
"funding": [
{
@@ -1326,30 +2549,112 @@
"install-path": "../symfony/polyfill-php80"
},
{
- "name": "symfony/translation",
- "version": "v6.0.5",
- "version_normalized": "6.0.5.0",
+ "name": "symfony/polyfill-php81",
+ "version": "v1.31.0",
+ "version_normalized": "1.31.0.0",
"source": {
"type": "git",
- "url": "https://github.com/symfony/translation.git",
- "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875"
+ "url": "https://github.com/symfony/polyfill-php81.git",
+ "reference": "4a4cfc2d253c21a5ad0e53071df248ed48c6ce5c"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/translation/zipball/e69501c71107cc3146b32aaa45f4edd0c3427875",
- "reference": "e69501c71107cc3146b32aaa45f4edd0c3427875",
+ "url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/4a4cfc2d253c21a5ad0e53071df248ed48c6ce5c",
+ "reference": "4a4cfc2d253c21a5ad0e53071df248ed48c6ce5c",
"shasum": ""
},
"require": {
- "php": ">=8.0.2",
+ "php": ">=7.2"
+ },
+ "time": "2024-09-09T11:45:10+00:00",
+ "type": "library",
+ "extra": {
+ "thanks": {
+ "name": "symfony/polyfill",
+ "url": "https://github.com/symfony/polyfill"
+ }
+ },
+ "installation-source": "dist",
+ "autoload": {
+ "files": [
+ "bootstrap.php"
+ ],
+ "psr-4": {
+ "Symfony\\Polyfill\\Php81\\": ""
+ },
+ "classmap": [
+ "Resources/stubs"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Nicolas Grekas",
+ "email": "p@tchwork.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions",
+ "homepage": "https://symfony.com",
+ "keywords": [
+ "compatibility",
+ "polyfill",
+ "portable",
+ "shim"
+ ],
+ "support": {
+ "source": "https://github.com/symfony/polyfill-php81/tree/v1.31.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-php81"
+ },
+ {
+ "name": "symfony/translation",
+ "version": "v6.4.3",
+ "version_normalized": "6.4.3.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/symfony/translation.git",
+ "reference": "637c51191b6b184184bbf98937702bcf554f7d04"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/symfony/translation/zipball/637c51191b6b184184bbf98937702bcf554f7d04",
+ "reference": "637c51191b6b184184bbf98937702bcf554f7d04",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=8.1",
+ "symfony/deprecation-contracts": "^2.5|^3",
"symfony/polyfill-mbstring": "~1.0",
- "symfony/translation-contracts": "^2.3|^3.0"
+ "symfony/translation-contracts": "^2.5|^3.0"
},
"conflict": {
"symfony/config": "<5.4",
"symfony/console": "<5.4",
"symfony/dependency-injection": "<5.4",
+ "symfony/http-client-contracts": "<2.5",
"symfony/http-kernel": "<5.4",
+ "symfony/service-contracts": "<2.5",
"symfony/twig-bundle": "<5.4",
"symfony/yaml": "<5.4"
},
@@ -1357,24 +2662,21 @@
"symfony/translation-implementation": "2.3|3.0"
},
"require-dev": {
+ "nikic/php-parser": "^4.18|^5.0",
"psr/log": "^1|^2|^3",
- "symfony/config": "^5.4|^6.0",
- "symfony/console": "^5.4|^6.0",
- "symfony/dependency-injection": "^5.4|^6.0",
- "symfony/finder": "^5.4|^6.0",
- "symfony/http-client-contracts": "^1.1|^2.0|^3.0",
- "symfony/http-kernel": "^5.4|^6.0",
- "symfony/intl": "^5.4|^6.0",
+ "symfony/config": "^5.4|^6.0|^7.0",
+ "symfony/console": "^5.4|^6.0|^7.0",
+ "symfony/dependency-injection": "^5.4|^6.0|^7.0",
+ "symfony/finder": "^5.4|^6.0|^7.0",
+ "symfony/http-client-contracts": "^2.5|^3.0",
+ "symfony/http-kernel": "^5.4|^6.0|^7.0",
+ "symfony/intl": "^5.4|^6.0|^7.0",
"symfony/polyfill-intl-icu": "^1.21",
- "symfony/service-contracts": "^1.1.2|^2|^3",
- "symfony/yaml": "^5.4|^6.0"
+ "symfony/routing": "^5.4|^6.0|^7.0",
+ "symfony/service-contracts": "^2.5|^3",
+ "symfony/yaml": "^5.4|^6.0|^7.0"
},
- "suggest": {
- "psr/log-implementation": "To use logging capability in translator",
- "symfony/config": "",
- "symfony/yaml": ""
- },
- "time": "2022-02-09T15:52:48+00:00",
+ "time": "2024-01-29T13:11:52+00:00",
"type": "library",
"installation-source": "dist",
"autoload": {
@@ -1405,7 +2707,7 @@
"description": "Provides tools to internationalize your application",
"homepage": "https://symfony.com",
"support": {
- "source": "https://github.com/symfony/translation/tree/v6.0.5"
+ "source": "https://github.com/symfony/translation/tree/v6.4.3"
},
"funding": [
{
@@ -1425,30 +2727,27 @@
},
{
"name": "symfony/translation-contracts",
- "version": "v3.0.0",
- "version_normalized": "3.0.0.0",
+ "version": "v3.4.1",
+ "version_normalized": "3.4.1.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/translation-contracts.git",
- "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77"
+ "reference": "06450585bf65e978026bda220cdebca3f867fde7"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/1b6ea5a7442af5a12dba3dbd6d71034b5b234e77",
- "reference": "1b6ea5a7442af5a12dba3dbd6d71034b5b234e77",
+ "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/06450585bf65e978026bda220cdebca3f867fde7",
+ "reference": "06450585bf65e978026bda220cdebca3f867fde7",
"shasum": ""
},
"require": {
- "php": ">=8.0.2"
+ "php": ">=8.1"
},
- "suggest": {
- "symfony/translation-implementation": ""
- },
- "time": "2021-09-07T12:43:40+00:00",
+ "time": "2023-12-26T14:02:43+00:00",
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "3.0-dev"
+ "dev-main": "3.4-dev"
},
"thanks": {
"name": "symfony/contracts",
@@ -1459,7 +2758,10 @@
"autoload": {
"psr-4": {
"Symfony\\Contracts\\Translation\\": ""
- }
+ },
+ "exclude-from-classmap": [
+ "/Test/"
+ ]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
@@ -1486,7 +2788,7 @@
"standards"
],
"support": {
- "source": "https://github.com/symfony/translation-contracts/tree/v3.0.0"
+ "source": "https://github.com/symfony/translation-contracts/tree/v3.4.1"
},
"funding": [
{
@@ -1505,186 +2807,41 @@
"install-path": "../symfony/translation-contracts"
},
{
- "name": "symfony/var-dumper",
- "version": "v6.0.5",
- "version_normalized": "6.0.5.0",
+ "name": "twig/twig",
+ "version": "v3.14.0",
+ "version_normalized": "3.14.0.0",
"source": {
"type": "git",
- "url": "https://github.com/symfony/var-dumper.git",
- "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce"
+ "url": "https://github.com/twigphp/Twig.git",
+ "reference": "126b2c97818dbff0cdf3fbfc881aedb3d40aae72"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/symfony/var-dumper/zipball/60d6a756d5f485df5e6e40b337334848f79f61ce",
- "reference": "60d6a756d5f485df5e6e40b337334848f79f61ce",
+ "url": "https://api.github.com/repos/twigphp/Twig/zipball/126b2c97818dbff0cdf3fbfc881aedb3d40aae72",
+ "reference": "126b2c97818dbff0cdf3fbfc881aedb3d40aae72",
"shasum": ""
},
"require": {
"php": ">=8.0.2",
- "symfony/polyfill-mbstring": "~1.0"
- },
- "conflict": {
- "phpunit/phpunit": "<5.4.3",
- "symfony/console": "<5.4"
- },
- "require-dev": {
- "ext-iconv": "*",
- "symfony/console": "^5.4|^6.0",
- "symfony/process": "^5.4|^6.0",
- "symfony/uid": "^5.4|^6.0",
- "twig/twig": "^2.13|^3.0.4"
- },
- "suggest": {
- "ext-iconv": "To convert non-UTF-8 strings to UTF-8 (or symfony/polyfill-iconv in case ext-iconv cannot be used).",
- "ext-intl": "To show region name in time zone dump",
- "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script"
- },
- "time": "2022-02-21T17:15:17+00:00",
- "bin": [
- "Resources/bin/var-dump-server"
- ],
- "type": "library",
- "installation-source": "dist",
- "autoload": {
- "files": [
- "Resources/functions/dump.php"
- ],
- "psr-4": {
- "Symfony\\Component\\VarDumper\\": ""
- },
- "exclude-from-classmap": [
- "/Tests/"
- ]
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "MIT"
- ],
- "authors": [
- {
- "name": "Nicolas Grekas",
- "email": "p@tchwork.com"
- },
- {
- "name": "Symfony Community",
- "homepage": "https://symfony.com/contributors"
- }
- ],
- "description": "Provides mechanisms for walking through any arbitrary PHP variable",
- "homepage": "https://symfony.com",
- "keywords": [
- "debug",
- "dump"
- ],
- "support": {
- "source": "https://github.com/symfony/var-dumper/tree/v6.0.5"
- },
- "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/var-dumper"
- },
- {
- "name": "tightenco/collect",
- "version": "v8.83.2",
- "version_normalized": "8.83.2.0",
- "source": {
- "type": "git",
- "url": "https://github.com/tighten/collect.git",
- "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/tighten/collect/zipball/d9c66d586ec2d216d8a31283d73f8df1400cc722",
- "reference": "d9c66d586ec2d216d8a31283d73f8df1400cc722",
- "shasum": ""
- },
- "require": {
- "php": "^7.3|^8.0",
- "symfony/var-dumper": "^3.4 || ^4.0 || ^5.0 || ^6.0"
- },
- "require-dev": {
- "mockery/mockery": "^1.0",
- "nesbot/carbon": "^2.23.0",
- "phpunit/phpunit": "^8.3"
- },
- "time": "2022-02-16T16:15:54+00:00",
- "type": "library",
- "installation-source": "dist",
- "autoload": {
- "files": [
- "src/Collect/Support/helpers.php",
- "src/Collect/Support/alias.php"
- ],
- "psr-4": {
- "Tightenco\\Collect\\": "src/Collect"
- }
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "MIT"
- ],
- "authors": [
- {
- "name": "Taylor Otwell",
- "email": "taylorotwell@gmail.com"
- }
- ],
- "description": "Collect - Illuminate Collections as a separate package.",
- "keywords": [
- "collection",
- "laravel"
- ],
- "support": {
- "issues": "https://github.com/tighten/collect/issues",
- "source": "https://github.com/tighten/collect/tree/v8.83.2"
- },
- "install-path": "../tightenco/collect"
- },
- {
- "name": "twig/twig",
- "version": "v3.4.3",
- "version_normalized": "3.4.3.0",
- "source": {
- "type": "git",
- "url": "https://github.com/twigphp/Twig.git",
- "reference": "c38fd6b0b7f370c198db91ffd02e23b517426b58"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/twigphp/Twig/zipball/c38fd6b0b7f370c198db91ffd02e23b517426b58",
- "reference": "c38fd6b0b7f370c198db91ffd02e23b517426b58",
- "shasum": ""
- },
- "require": {
- "php": ">=7.2.5",
+ "symfony/deprecation-contracts": "^2.5|^3",
"symfony/polyfill-ctype": "^1.8",
- "symfony/polyfill-mbstring": "^1.3"
+ "symfony/polyfill-mbstring": "^1.3",
+ "symfony/polyfill-php81": "^1.29"
},
"require-dev": {
- "psr/container": "^1.0",
- "symfony/phpunit-bridge": "^4.4.9|^5.0.9|^6.0"
+ "psr/container": "^1.0|^2.0",
+ "symfony/phpunit-bridge": "^5.4.9|^6.4|^7.0"
},
- "time": "2022-09-28T08:42:51+00:00",
+ "time": "2024-09-09T17:55:12+00:00",
"type": "library",
- "extra": {
- "branch-alias": {
- "dev-master": "3.4-dev"
- }
- },
"installation-source": "dist",
"autoload": {
+ "files": [
+ "src/Resources/core.php",
+ "src/Resources/debug.php",
+ "src/Resources/escaper.php",
+ "src/Resources/string_loader.php"
+ ],
"psr-4": {
"Twig\\": "src/"
}
@@ -1717,7 +2874,7 @@
],
"support": {
"issues": "https://github.com/twigphp/Twig/issues",
- "source": "https://github.com/twigphp/Twig/tree/v3.4.3"
+ "source": "https://github.com/twigphp/Twig/tree/v3.14.0"
},
"funding": [
{
@@ -1730,46 +2887,6 @@
}
],
"install-path": "../twig/twig"
- },
- {
- "name": "yubico/u2flib-server",
- "version": "1.0.2",
- "version_normalized": "1.0.2.0",
- "source": {
- "type": "git",
- "url": "https://github.com/Yubico/php-u2flib-server.git",
- "reference": "55d813acf68212ad2cadecde07551600d6971939"
- },
- "dist": {
- "type": "zip",
- "url": "https://api.github.com/repos/Yubico/php-u2flib-server/zipball/55d813acf68212ad2cadecde07551600d6971939",
- "reference": "55d813acf68212ad2cadecde07551600d6971939",
- "shasum": ""
- },
- "require": {
- "ext-openssl": "*",
- "paragonie/random_compat": ">= 1",
- "php": ">=5.6"
- },
- "require-dev": {
- "phpunit/phpunit": "~5.7",
- "vimeo/psalm": "^0|^1|^2"
- },
- "time": "2018-09-07T08:16:44+00:00",
- "type": "library",
- "installation-source": "dist",
- "autoload": {
- "classmap": [
- "src/"
- ]
- },
- "notification-url": "https://packagist.org/downloads/",
- "license": [
- "BSD-2-Clause"
- ],
- "description": "Library for U2F implementation",
- "homepage": "https://developers.yubico.com/php-u2flib-server",
- "install-path": "../yubico/u2flib-server"
}
],
"dev": true,
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 c45f177..15a1aa8 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,9 +1,9 @@
<?php return array(
'root' => array(
'name' => '__root__',
- 'pretty_version' => 'dev-master',
- 'version' => 'dev-master',
- 'reference' => '8e0b1d8aee4af02311692cb031695cc2ac3850fd',
+ 'pretty_version' => '1.0.0+no-version-set',
+ 'version' => '1.0.0.0',
+ 'reference' => null,
'type' => 'library',
'install_path' => __DIR__ . '/../../',
'aliases' => array(),
@@ -11,14 +11,23 @@
),
'versions' => array(
'__root__' => array(
- 'pretty_version' => 'dev-master',
- 'version' => 'dev-master',
- 'reference' => '8e0b1d8aee4af02311692cb031695cc2ac3850fd',
+ 'pretty_version' => '1.0.0+no-version-set',
+ 'version' => '1.0.0.0',
+ 'reference' => null,
'type' => 'library',
'install_path' => __DIR__ . '/../../',
'aliases' => array(),
'dev_requirement' => false,
),
+ 'bacon/bacon-qr-code' => array(
+ 'pretty_version' => '2.0.8',
+ 'version' => '2.0.8.0',
+ 'reference' => '8674e51bb65af933a5ffaf1c308a660387c35c22',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../bacon/bacon-qr-code',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
'bshaffer/oauth2-server-php' => array(
'pretty_version' => 'v1.11.1',
'version' => '1.11.1.0',
@@ -28,6 +37,24 @@
'aliases' => array(),
'dev_requirement' => false,
),
+ 'carbonphp/carbon-doctrine-types' => array(
+ 'pretty_version' => '3.2.0',
+ 'version' => '3.2.0.0',
+ 'reference' => '18ba5ddfec8976260ead6e866180bd5d2f71aa1d',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../carbonphp/carbon-doctrine-types',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'dasprid/enum' => array(
+ 'pretty_version' => '1.0.7',
+ 'version' => '1.0.7.0',
+ 'reference' => 'b5874fa9ed0043116c72162ec7f4fb50e02e7cce',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../dasprid/enum',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
'ddeboer/imap' => array(
'pretty_version' => '1.13.1',
'version' => '1.13.1.0',
@@ -38,9 +65,9 @@
'dev_requirement' => false,
),
'directorytree/ldaprecord' => array(
- 'pretty_version' => 'v2.10.1',
- 'version' => '2.10.1.0',
- 'reference' => 'bf512d9af7a7b0e2ed7a666ab29cefdd027bee88',
+ 'pretty_version' => 'v3.8.5',
+ 'version' => '3.8.5.0',
+ 'reference' => '00e5f088f8c4028d5f398783cccc2e8119a27a65',
'type' => 'library',
'install_path' => __DIR__ . '/../directorytree/ldaprecord',
'aliases' => array(),
@@ -52,15 +79,87 @@
0 => '*',
),
),
+ 'firebase/php-jwt' => array(
+ 'pretty_version' => 'v6.5.0',
+ 'version' => '6.5.0.0',
+ 'reference' => 'e94e7353302b0c11ec3cfff7180cd0b1743975d2',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../firebase/php-jwt',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'guzzlehttp/guzzle' => array(
+ 'pretty_version' => '7.5.0',
+ 'version' => '7.5.0.0',
+ 'reference' => 'b50a2a1251152e43f6a37f0fa053e730a67d25ba',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../guzzlehttp/guzzle',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'guzzlehttp/promises' => array(
+ 'pretty_version' => '1.5.2',
+ 'version' => '1.5.2.0',
+ 'reference' => 'b94b2807d85443f9719887892882d0329d1e2598',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../guzzlehttp/promises',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'guzzlehttp/psr7' => array(
+ 'pretty_version' => '2.4.5',
+ 'version' => '2.4.5.0',
+ 'reference' => '0454e12ef0cd597ccd2adb036f7bda4e7fface66',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../guzzlehttp/psr7',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'illuminate/collections' => array(
+ 'pretty_version' => 'v10.49.0',
+ 'version' => '10.49.0.0',
+ 'reference' => '6ae9c74fa92d4e1824d1b346cd435e8eacdc3232',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../illuminate/collections',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'illuminate/conditionable' => array(
+ 'pretty_version' => 'v10.49.0',
+ 'version' => '10.49.0.0',
+ 'reference' => '47c700320b7a419f0d188d111f3bbed978fcbd3f',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../illuminate/conditionable',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
'illuminate/contracts' => array(
- 'pretty_version' => 'v9.3.0',
- 'version' => '9.3.0.0',
- 'reference' => 'bf4b3c254c49d28157645d01e4883b5951b1e1d0',
+ 'pretty_version' => 'v10.44.0',
+ 'version' => '10.44.0.0',
+ 'reference' => '8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac',
'type' => 'library',
'install_path' => __DIR__ . '/../illuminate/contracts',
'aliases' => array(),
'dev_requirement' => false,
),
+ 'illuminate/macroable' => array(
+ 'pretty_version' => 'v10.49.0',
+ 'version' => '10.49.0.0',
+ 'reference' => 'dff667a46ac37b634dcf68909d9d41e94dc97c27',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../illuminate/macroable',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'league/oauth2-client' => array(
+ 'pretty_version' => '2.7.0',
+ 'version' => '2.7.0.0',
+ 'reference' => '160d6274b03562ebeb55ed18399281d8118b76c8',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../league/oauth2-client',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
'matthiasmullie/minify' => array(
'pretty_version' => '1.3.66',
'version' => '1.3.66.0',
@@ -95,9 +194,9 @@
'dev_requirement' => false,
),
'nesbot/carbon' => array(
- 'pretty_version' => '2.57.0',
- 'version' => '2.57.0.0',
- 'reference' => '4a54375c21eea4811dbd1149fe6b246517554e78',
+ 'pretty_version' => '2.72.3',
+ 'version' => '2.72.3.0',
+ 'reference' => '0c6fd108360c562f6e4fd1dedb8233b423e91c83',
'type' => 'library',
'install_path' => __DIR__ . '/../nesbot/carbon',
'aliases' => array(),
@@ -130,6 +229,21 @@
'aliases' => array(),
'dev_requirement' => false,
),
+ 'psr/clock' => array(
+ 'pretty_version' => '1.0.0',
+ 'version' => '1.0.0.0',
+ 'reference' => 'e41a24703d4560fd0acb709162f73b8adfc3aa0d',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../psr/clock',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'psr/clock-implementation' => array(
+ 'dev_requirement' => false,
+ 'provided' => array(
+ 0 => '1.0',
+ ),
+ ),
'psr/container' => array(
'pretty_version' => '2.0.2',
'version' => '2.0.2.0',
@@ -139,6 +253,51 @@
'aliases' => array(),
'dev_requirement' => false,
),
+ 'psr/http-client' => array(
+ 'pretty_version' => '1.0.1',
+ 'version' => '1.0.1.0',
+ 'reference' => '2dfb5f6c5eff0e91e20e913f8c5452ed95b86621',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../psr/http-client',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'psr/http-client-implementation' => array(
+ 'dev_requirement' => false,
+ 'provided' => array(
+ 0 => '1.0',
+ ),
+ ),
+ 'psr/http-factory' => array(
+ 'pretty_version' => '1.0.1',
+ 'version' => '1.0.1.0',
+ 'reference' => '12ac7fcd07e5b077433f5f2bee95b3a771bf61be',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../psr/http-factory',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'psr/http-factory-implementation' => array(
+ 'dev_requirement' => false,
+ 'provided' => array(
+ 0 => '1.0',
+ ),
+ ),
+ 'psr/http-message' => array(
+ 'pretty_version' => '1.0.1',
+ 'version' => '1.0.1.0',
+ 'reference' => 'f6561bf28d520154e4b0ec72be95418abe6d9363',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../psr/http-message',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'psr/http-message-implementation' => array(
+ 'dev_requirement' => false,
+ 'provided' => array(
+ 0 => '1.0',
+ ),
+ ),
'psr/log' => array(
'pretty_version' => '3.0.0',
'version' => '3.0.0.0',
@@ -157,6 +316,15 @@
'aliases' => array(),
'dev_requirement' => false,
),
+ 'ralouphie/getallheaders' => array(
+ 'pretty_version' => '3.0.3',
+ 'version' => '3.0.3.0',
+ 'reference' => '120b605dfeb996808c31b6477290a714d356e822',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../ralouphie/getallheaders',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
'robthree/twofactorauth' => array(
'pretty_version' => '1.8.1',
'version' => '1.8.1.0',
@@ -175,6 +343,24 @@
'aliases' => array(),
'dev_requirement' => false,
),
+ 'stevenmaguire/oauth2-keycloak' => array(
+ 'pretty_version' => '4.0.0',
+ 'version' => '4.0.0.0',
+ 'reference' => '05ead6bb6bcd2b6f96dfae87c769dcd3e5f6129d',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../stevenmaguire/oauth2-keycloak',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
+ 'symfony/deprecation-contracts' => array(
+ 'pretty_version' => 'v3.5.0',
+ 'version' => '3.5.0.0',
+ 'reference' => '0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../symfony/deprecation-contracts',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
'symfony/polyfill-ctype' => array(
'pretty_version' => 'v1.24.0',
'version' => '1.24.0.0',
@@ -185,36 +371,45 @@
'dev_requirement' => false,
),
'symfony/polyfill-mbstring' => array(
- 'pretty_version' => 'v1.24.0',
- 'version' => '1.24.0.0',
- 'reference' => '0abb51d2f102e00a4eefcf46ba7fec406d245825',
+ 'pretty_version' => 'v1.29.0',
+ 'version' => '1.29.0.0',
+ 'reference' => '9773676c8a1bb1f8d4340a62efe641cf76eda7ec',
'type' => 'library',
'install_path' => __DIR__ . '/../symfony/polyfill-mbstring',
'aliases' => array(),
'dev_requirement' => false,
),
'symfony/polyfill-php80' => array(
- 'pretty_version' => 'v1.24.0',
- 'version' => '1.24.0.0',
- 'reference' => '57b712b08eddb97c762a8caa32c84e037892d2e9',
+ 'pretty_version' => 'v1.29.0',
+ 'version' => '1.29.0.0',
+ 'reference' => '87b68208d5c1188808dd7839ee1e6c8ec3b02f1b',
'type' => 'library',
'install_path' => __DIR__ . '/../symfony/polyfill-php80',
'aliases' => array(),
'dev_requirement' => false,
),
+ 'symfony/polyfill-php81' => array(
+ 'pretty_version' => 'v1.31.0',
+ 'version' => '1.31.0.0',
+ 'reference' => '4a4cfc2d253c21a5ad0e53071df248ed48c6ce5c',
+ 'type' => 'library',
+ 'install_path' => __DIR__ . '/../symfony/polyfill-php81',
+ 'aliases' => array(),
+ 'dev_requirement' => false,
+ ),
'symfony/translation' => array(
- 'pretty_version' => 'v6.0.5',
- 'version' => '6.0.5.0',
- 'reference' => 'e69501c71107cc3146b32aaa45f4edd0c3427875',
+ 'pretty_version' => 'v6.4.3',
+ 'version' => '6.4.3.0',
+ 'reference' => '637c51191b6b184184bbf98937702bcf554f7d04',
'type' => 'library',
'install_path' => __DIR__ . '/../symfony/translation',
'aliases' => array(),
'dev_requirement' => false,
),
'symfony/translation-contracts' => array(
- 'pretty_version' => 'v3.0.0',
- 'version' => '3.0.0.0',
- 'reference' => '1b6ea5a7442af5a12dba3dbd6d71034b5b234e77',
+ 'pretty_version' => 'v3.4.1',
+ 'version' => '3.4.1.0',
+ 'reference' => '06450585bf65e978026bda220cdebca3f867fde7',
'type' => 'library',
'install_path' => __DIR__ . '/../symfony/translation-contracts',
'aliases' => array(),
@@ -226,41 +421,14 @@
0 => '2.3|3.0',
),
),
- 'symfony/var-dumper' => array(
- 'pretty_version' => 'v6.0.5',
- 'version' => '6.0.5.0',
- 'reference' => '60d6a756d5f485df5e6e40b337334848f79f61ce',
- 'type' => 'library',
- 'install_path' => __DIR__ . '/../symfony/var-dumper',
- 'aliases' => array(),
- 'dev_requirement' => false,
- ),
- 'tightenco/collect' => array(
- 'pretty_version' => 'v8.83.2',
- 'version' => '8.83.2.0',
- 'reference' => 'd9c66d586ec2d216d8a31283d73f8df1400cc722',
- 'type' => 'library',
- 'install_path' => __DIR__ . '/../tightenco/collect',
- 'aliases' => array(),
- 'dev_requirement' => false,
- ),
'twig/twig' => array(
- 'pretty_version' => 'v3.4.3',
- 'version' => '3.4.3.0',
- 'reference' => 'c38fd6b0b7f370c198db91ffd02e23b517426b58',
+ 'pretty_version' => 'v3.14.0',
+ 'version' => '3.14.0.0',
+ 'reference' => '126b2c97818dbff0cdf3fbfc881aedb3d40aae72',
'type' => 'library',
'install_path' => __DIR__ . '/../twig/twig',
'aliases' => array(),
'dev_requirement' => false,
),
- 'yubico/u2flib-server' => array(
- 'pretty_version' => '1.0.2',
- 'version' => '1.0.2.0',
- 'reference' => '55d813acf68212ad2cadecde07551600d6971939',
- 'type' => 'library',
- 'install_path' => __DIR__ . '/../yubico/u2flib-server',
- 'aliases' => array(),
- 'dev_requirement' => false,
- ),
),
);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/platform_check.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/platform_check.php
index b168ddd..4c3a5d6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/platform_check.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/composer/platform_check.php
@@ -4,8 +4,8 @@
$issues = array();
-if (!(PHP_VERSION_ID >= 80002)) {
- $issues[] = 'Your Composer dependencies require a PHP version ">= 8.0.2". You are running ' . PHP_VERSION . '.';
+if (!(PHP_VERSION_ID >= 80100)) {
+ $issues[] = 'Your Composer dependencies require a PHP version ">= 8.1.0". You are running ' . PHP_VERSION . '.';
}
if ($issues) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/LICENSE
new file mode 100644
index 0000000..d45a356
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/LICENSE
@@ -0,0 +1,22 @@
+Copyright (c) 2017, Ben Scholzen 'DASPRiD'
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+1. Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+2. 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.
+
+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/dasprid/enum/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/README.md
new file mode 100644
index 0000000..da37045
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/README.md
@@ -0,0 +1,164 @@
+# PHP 7.1 enums
+
+[](https://github.com/DASPRiD/Enum/actions?query=workflow%3Atests)
+[](https://coveralls.io/github/DASPRiD/Enum?branch=master)
+[](https://packagist.org/packages/dasprid/enum)
+[](https://packagist.org/packages/dasprid/enum)
+[](https://packagist.org/packages/dasprid/enum)
+
+It is a well known fact that PHP is missing a basic enum type, ignoring the rather incomplete `SplEnum` implementation
+which is only available as a PECL extension. There are also quite a few other userland enum implementations around,
+but all of them have one or another compromise. This library tries to close that gap as far as PHP allows it to.
+
+## Usage
+
+### Basics
+
+At its core, there is the `DASPRiD\Enum\AbstractEnum` class, which by default will work with constants like any other
+enum implementation you might know. The first clear difference is that you should define all the constants as protected
+(so nobody outside your class can read them but the `AbstractEnum` can still do so). The other even mightier difference
+is that, for simple enums, the value of the constant doesn't matter at all. Let's have a look at a simple example:
+
+```php
+use DASPRiD\Enum\AbstractEnum;
+
+/**
+ * @method static self MONDAY()
+ * @method static self TUESDAY()
+ * @method static self WEDNESDAY()
+ * @method static self THURSDAY()
+ * @method static self FRIDAY()
+ * @method static self SATURDAY()
+ * @method static self SUNDAY()
+ */
+final class WeekDay extends AbstractEnum
+{
+ protected const MONDAY = null;
+ protected const TUESDAY = null;
+ protected const WEDNESDAY = null;
+ protected const THURSDAY = null;
+ protected const FRIDAY = null;
+ protected const SATURDAY = null;
+ protected const SUNDAY = null;
+}
+```
+
+If you need to provide constants for either internal use or public use, you can mark them as either private or public,
+in which case they will be ignored by the enum, which only considers protected constants as valid values. As you can
+see, we specifically defined the generated magic methods in a class level doc block, so anyone using this class will
+automatically have proper auto-completion in their IDE. Now since you have defined the enum, you can simply use it like
+that:
+
+```php
+function tellItLikeItIs(WeekDay $weekDay)
+{
+ switch ($weekDay) {
+ case WeekDay::MONDAY():
+ echo 'Mondays are bad.';
+ break;
+
+ case WeekDay::FRIDAY():
+ echo 'Fridays are better.';
+ break;
+
+ case WeekDay::SATURDAY():
+ case WeekDay::SUNDAY():
+ echo 'Weekends are best.';
+ break;
+
+ default:
+ echo 'Midweek days are so-so.';
+ }
+}
+
+tellItLikeItIs(WeekDay::MONDAY());
+tellItLikeItIs(WeekDay::WEDNESDAY());
+tellItLikeItIs(WeekDay::FRIDAY());
+tellItLikeItIs(WeekDay::SATURDAY());
+tellItLikeItIs(WeekDay::SUNDAY());
+```
+
+### More complex example
+
+Of course, all enums are singletons, which are not cloneable or serializable. Thus you can be sure that there is always
+just one instance of the same type. Of course, the values of constants are not completely useless, let's have a look at
+a more complex example:
+
+```php
+use DASPRiD\Enum\AbstractEnum;
+
+/**
+ * @method static self MERCURY()
+ * @method static self VENUS()
+ * @method static self EARTH()
+ * @method static self MARS()
+ * @method static self JUPITER()
+ * @method static self SATURN()
+ * @method static self URANUS()
+ * @method static self NEPTUNE()
+ */
+final class Planet extends AbstractEnum
+{
+ protected const MERCURY = [3.303e+23, 2.4397e6];
+ protected const VENUS = [4.869e+24, 6.0518e6];
+ protected const EARTH = [5.976e+24, 6.37814e6];
+ protected const MARS = [6.421e+23, 3.3972e6];
+ protected const JUPITER = [1.9e+27, 7.1492e7];
+ protected const SATURN = [5.688e+26, 6.0268e7];
+ protected const URANUS = [8.686e+25, 2.5559e7];
+ protected const NEPTUNE = [1.024e+26, 2.4746e7];
+
+ /**
+ * Universal gravitational constant.
+ *
+ * @var float
+ */
+ private const G = 6.67300E-11;
+
+ /**
+ * Mass in kilograms.
+ *
+ * @var float
+ */
+ private $mass;
+
+ /**
+ * Radius in meters.
+ *
+ * @var float
+ */
+ private $radius;
+
+ protected function __construct(float $mass, float $radius)
+ {
+ $this->mass = $mass;
+ $this->radius = $radius;
+ }
+
+ public function mass() : float
+ {
+ return $this->mass;
+ }
+
+ public function radius() : float
+ {
+ return $this->radius;
+ }
+
+ public function surfaceGravity() : float
+ {
+ return self::G * $this->mass / ($this->radius * $this->radius);
+ }
+
+ public function surfaceWeight(float $otherMass) : float
+ {
+ return $otherMass * $this->surfaceGravity();
+ }
+}
+
+$myMass = 80;
+
+foreach (Planet::values() as $planet) {
+ printf("Your weight on %s is %f\n", $planet, $planet->surfaceWeight($myMass));
+}
+```
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/composer.json
new file mode 100644
index 0000000..a099aba
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/composer.json
@@ -0,0 +1,34 @@
+{
+ "name": "dasprid/enum",
+ "description": "PHP 7.1 enum implementation",
+ "license": "BSD-2-Clause",
+ "authors": [
+ {
+ "name": "Ben Scholzen 'DASPRiD'",
+ "email": "mail@dasprids.de",
+ "homepage": "https://dasprids.de/",
+ "role": "Developer"
+ }
+ ],
+ "keywords": [
+ "enum",
+ "map"
+ ],
+ "require": {
+ "php": ">=7.1 <9.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^7 || ^8 || ^9 || ^10 || ^11",
+ "squizlabs/php_codesniffer": "*"
+ },
+ "autoload": {
+ "psr-4": {
+ "DASPRiD\\Enum\\": "src/"
+ }
+ },
+ "autoload-dev": {
+ "psr-4": {
+ "DASPRiD\\EnumTest\\": "test/"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/AbstractEnum.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/AbstractEnum.php
new file mode 100644
index 0000000..43006dc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/AbstractEnum.php
@@ -0,0 +1,261 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum;
+
+use DASPRiD\Enum\Exception\CloneNotSupportedException;
+use DASPRiD\Enum\Exception\IllegalArgumentException;
+use DASPRiD\Enum\Exception\MismatchException;
+use DASPRiD\Enum\Exception\SerializeNotSupportedException;
+use DASPRiD\Enum\Exception\UnserializeNotSupportedException;
+use ReflectionClass;
+
+abstract class AbstractEnum
+{
+ /**
+ * @var string
+ */
+ private $name;
+
+ /**
+ * @var int
+ */
+ private $ordinal;
+
+ /**
+ * @var array<string, array<string, static>>
+ */
+ private static $values = [];
+
+ /**
+ * @var array<string, bool>
+ */
+ private static $allValuesLoaded = [];
+
+ /**
+ * @var array<string, array>
+ */
+ private static $constants = [];
+
+ /**
+ * The constructor is private by default to avoid arbitrary enum creation.
+ *
+ * When creating your own constructor for a parameterized enum, make sure to declare it as protected, so that
+ * the static methods are able to construct it. Avoid making it public, as that would allow creation of
+ * non-singleton enum instances.
+ */
+ private function __construct()
+ {
+ }
+
+ /**
+ * Magic getter which forwards all calls to {@see self::valueOf()}.
+ *
+ * @return static
+ */
+ final public static function __callStatic(string $name, array $arguments) : self
+ {
+ return static::valueOf($name);
+ }
+
+ /**
+ * Returns an enum with the specified name.
+ *
+ * The name must match exactly an identifier used to declare an enum in this type (extraneous whitespace characters
+ * are not permitted).
+ *
+ * @return static
+ * @throws IllegalArgumentException if the enum has no constant with the specified name
+ */
+ final public static function valueOf(string $name) : self
+ {
+ if (isset(self::$values[static::class][$name])) {
+ return self::$values[static::class][$name];
+ }
+
+ $constants = self::constants();
+
+ if (array_key_exists($name, $constants)) {
+ return self::createValue($name, $constants[$name][0], $constants[$name][1]);
+ }
+
+ throw new IllegalArgumentException(sprintf('No enum constant %s::%s', static::class, $name));
+ }
+
+ /**
+ * @return static
+ */
+ private static function createValue(string $name, int $ordinal, array $arguments) : self
+ {
+ $instance = new static(...$arguments);
+ $instance->name = $name;
+ $instance->ordinal = $ordinal;
+ self::$values[static::class][$name] = $instance;
+ return $instance;
+ }
+
+ /**
+ * Obtains all possible types defined by this enum.
+ *
+ * @return static[]
+ */
+ final public static function values() : array
+ {
+ if (isset(self::$allValuesLoaded[static::class])) {
+ return self::$values[static::class];
+ }
+
+ if (! isset(self::$values[static::class])) {
+ self::$values[static::class] = [];
+ }
+
+ foreach (self::constants() as $name => $constant) {
+ if (array_key_exists($name, self::$values[static::class])) {
+ continue;
+ }
+
+ static::createValue($name, $constant[0], $constant[1]);
+ }
+
+ uasort(self::$values[static::class], function (self $a, self $b) {
+ return $a->ordinal() <=> $b->ordinal();
+ });
+
+ self::$allValuesLoaded[static::class] = true;
+ return self::$values[static::class];
+ }
+
+ private static function constants() : array
+ {
+ if (isset(self::$constants[static::class])) {
+ return self::$constants[static::class];
+ }
+
+ self::$constants[static::class] = [];
+ $reflectionClass = new ReflectionClass(static::class);
+ $ordinal = -1;
+
+ foreach ($reflectionClass->getReflectionConstants() as $reflectionConstant) {
+ if (! $reflectionConstant->isProtected()) {
+ continue;
+ }
+
+ $value = $reflectionConstant->getValue();
+
+ self::$constants[static::class][$reflectionConstant->name] = [
+ ++$ordinal,
+ is_array($value) ? $value : []
+ ];
+ }
+
+ return self::$constants[static::class];
+ }
+
+ /**
+ * Returns the name of this enum constant, exactly as declared in its enum declaration.
+ *
+ * Most programmers should use the {@see self::__toString()} method in preference to this one, as the toString
+ * method may return a more user-friendly name. This method is designed primarily for use in specialized situations
+ * where correctness depends on getting the exact name, which will not vary from release to release.
+ */
+ final public function name() : string
+ {
+ return $this->name;
+ }
+
+ /**
+ * Returns the ordinal of this enumeration constant (its position in its enum declaration, where the initial
+ * constant is assigned an ordinal of zero).
+ *
+ * Most programmers will have no use for this method. It is designed for use by sophisticated enum-based data
+ * structures.
+ */
+ final public function ordinal() : int
+ {
+ return $this->ordinal;
+ }
+
+ /**
+ * Compares this enum with the specified object for order.
+ *
+ * Returns negative integer, zero or positive integer as this object is less than, equal to or greater than the
+ * specified object.
+ *
+ * Enums are only comparable to other enums of the same type. The natural order implemented by this method is the
+ * order in which the constants are declared.
+ *
+ * @throws MismatchException if the passed enum is not of the same type
+ */
+ final public function compareTo(self $other) : int
+ {
+ if (! $other instanceof static) {
+ throw new MismatchException(sprintf(
+ 'The passed enum %s is not of the same type as %s',
+ get_class($other),
+ static::class
+ ));
+ }
+
+ return $this->ordinal - $other->ordinal;
+ }
+
+ /**
+ * Forbid cloning enums.
+ *
+ * @throws CloneNotSupportedException
+ */
+ final public function __clone()
+ {
+ throw new CloneNotSupportedException();
+ }
+
+ /**
+ * Forbid serializing enums.
+ *
+ * @throws SerializeNotSupportedException
+ */
+ final public function __sleep() : array
+ {
+ throw new SerializeNotSupportedException();
+ }
+
+ /**
+ * Forbid serializing enums.
+ *
+ * @throws SerializeNotSupportedException
+ */
+ final public function __serialize() : array
+ {
+ throw new SerializeNotSupportedException();
+ }
+
+ /**
+ * Forbid unserializing enums.
+ *
+ * @throws UnserializeNotSupportedException
+ */
+ final public function __wakeup() : void
+ {
+ throw new UnserializeNotSupportedException();
+ }
+
+ /**
+ * Forbid unserializing enums.
+ *
+ * @throws UnserializeNotSupportedException
+ */
+ final public function __unserialize($arg) : void
+ {
+ throw new UnserializeNotSupportedException();
+ }
+
+ /**
+ * Turns the enum into a string representation.
+ *
+ * You may override this method to give a more user-friendly version.
+ */
+ public function __toString() : string
+ {
+ return $this->name;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/EnumMap.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/EnumMap.php
new file mode 100644
index 0000000..95b8856
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/EnumMap.php
@@ -0,0 +1,385 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum;
+
+use DASPRiD\Enum\Exception\ExpectationException;
+use DASPRiD\Enum\Exception\IllegalArgumentException;
+use IteratorAggregate;
+use Serializable;
+use Traversable;
+
+/**
+ * A specialized map implementation for use with enum type keys.
+ *
+ * All of the keys in an enum map must come from a single enum type that is specified, when the map is created. Enum
+ * maps are represented internally as arrays. This representation is extremely compact and efficient.
+ *
+ * Enum maps are maintained in the natural order of their keys (the order in which the enum constants are declared).
+ * This is reflected in the iterators returned by the collection views {@see self::getIterator()} and
+ * {@see self::values()}.
+ *
+ * Iterators returned by the collection views are not consistent: They may or may not show the effects of modifications
+ * to the map that occur while the iteration is in progress.
+ */
+final class EnumMap implements Serializable, IteratorAggregate
+{
+ /**
+ * The class name of the key.
+ *
+ * @var string
+ */
+ private $keyType;
+
+ /**
+ * The type of the value.
+ *
+ * @var string
+ */
+ private $valueType;
+
+ /**
+ * @var bool
+ */
+ private $allowNullValues;
+
+ /**
+ * All of the constants comprising the enum, cached for performance.
+ *
+ * @var array<int, AbstractEnum>
+ */
+ private $keyUniverse;
+
+ /**
+ * Array representation of this map. The ith element is the value to which universe[i] is currently mapped, or null
+ * if it isn't mapped to anything, or NullValue if it's mapped to null.
+ *
+ * @var array<int, mixed>
+ */
+ private $values;
+
+ /**
+ * @var int
+ */
+ private $size = 0;
+
+ /**
+ * Creates a new enum map.
+ *
+ * @param string $keyType the type of the keys, must extend AbstractEnum
+ * @param string $valueType the type of the values
+ * @param bool $allowNullValues whether to allow null values
+ * @throws IllegalArgumentException when key type does not extend AbstractEnum
+ */
+ public function __construct(string $keyType, string $valueType, bool $allowNullValues)
+ {
+ if (! is_subclass_of($keyType, AbstractEnum::class)) {
+ throw new IllegalArgumentException(sprintf(
+ 'Class %s does not extend %s',
+ $keyType,
+ AbstractEnum::class
+ ));
+ }
+
+ $this->keyType = $keyType;
+ $this->valueType = $valueType;
+ $this->allowNullValues = $allowNullValues;
+ $this->keyUniverse = $keyType::values();
+ $this->values = array_fill(0, count($this->keyUniverse), null);
+ }
+
+ public function __serialize(): array
+ {
+ $values = [];
+
+ foreach ($this->values as $ordinal => $value) {
+ if (null === $value) {
+ continue;
+ }
+
+ $values[$ordinal] = $this->unmaskNull($value);
+ }
+
+ return [
+ 'keyType' => $this->keyType,
+ 'valueType' => $this->valueType,
+ 'allowNullValues' => $this->allowNullValues,
+ 'values' => $values,
+ ];
+ }
+
+ public function __unserialize(array $data): void
+ {
+ $this->unserialize(serialize($data));
+ }
+
+ /**
+ * Checks whether the map types match the supplied ones.
+ *
+ * You should call this method when an EnumMap is passed to you and you want to ensure that it's made up of the
+ * correct types.
+ *
+ * @throws ExpectationException when supplied key type mismatches local key type
+ * @throws ExpectationException when supplied value type mismatches local value type
+ * @throws ExpectationException when the supplied map allows null values, abut should not
+ */
+ public function expect(string $keyType, string $valueType, bool $allowNullValues) : void
+ {
+ if ($keyType !== $this->keyType) {
+ throw new ExpectationException(sprintf(
+ 'Callee expected an EnumMap with key type %s, but got %s',
+ $keyType,
+ $this->keyType
+ ));
+ }
+
+ if ($valueType !== $this->valueType) {
+ throw new ExpectationException(sprintf(
+ 'Callee expected an EnumMap with value type %s, but got %s',
+ $keyType,
+ $this->keyType
+ ));
+ }
+
+ if ($allowNullValues !== $this->allowNullValues) {
+ throw new ExpectationException(sprintf(
+ 'Callee expected an EnumMap with nullable flag %s, but got %s',
+ ($allowNullValues ? 'true' : 'false'),
+ ($this->allowNullValues ? 'true' : 'false')
+ ));
+ }
+ }
+
+ /**
+ * Returns the number of key-value mappings in this map.
+ */
+ public function size() : int
+ {
+ return $this->size;
+ }
+
+ /**
+ * Returns true if this map maps one or more keys to the specified value.
+ */
+ public function containsValue($value) : bool
+ {
+ return in_array($this->maskNull($value), $this->values, true);
+ }
+
+ /**
+ * Returns true if this map contains a mapping for the specified key.
+ */
+ public function containsKey(AbstractEnum $key) : bool
+ {
+ $this->checkKeyType($key);
+ return null !== $this->values[$key->ordinal()];
+ }
+
+ /**
+ * Returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.
+ *
+ * More formally, if this map contains a mapping from a key to a value, then this method returns the value;
+ * otherwise it returns null (there can be at most one such mapping).
+ *
+ * A return value of null does not necessarily indicate that the map contains no mapping for the key; it's also
+ * possible that hte map explicitly maps the key to null. The {@see self::containsKey()} operation may be used to
+ * distinguish these two cases.
+ *
+ * @return mixed
+ */
+ public function get(AbstractEnum $key)
+ {
+ $this->checkKeyType($key);
+ return $this->unmaskNull($this->values[$key->ordinal()]);
+ }
+
+ /**
+ * Associates the specified value with the specified key in this map.
+ *
+ * If the map previously contained a mapping for this key, the old value is replaced.
+ *
+ * @return mixed the previous value associated with the specified key, or null if there was no mapping for the key.
+ * (a null return can also indicate that the map previously associated null with the specified key.)
+ * @throws IllegalArgumentException when the passed values does not match the internal value type
+ */
+ public function put(AbstractEnum $key, $value)
+ {
+ $this->checkKeyType($key);
+
+ if (! $this->isValidValue($value)) {
+ throw new IllegalArgumentException(sprintf('Value is not of type %s', $this->valueType));
+ }
+
+ $index = $key->ordinal();
+ $oldValue = $this->values[$index];
+ $this->values[$index] = $this->maskNull($value);
+
+ if (null === $oldValue) {
+ ++$this->size;
+ }
+
+ return $this->unmaskNull($oldValue);
+ }
+
+ /**
+ * Removes the mapping for this key frm this map if present.
+ *
+ * @return mixed the previous value associated with the specified key, or null if there was no mapping for the key.
+ * (a null return can also indicate that the map previously associated null with the specified key.)
+ */
+ public function remove(AbstractEnum $key)
+ {
+ $this->checkKeyType($key);
+
+ $index = $key->ordinal();
+ $oldValue = $this->values[$index];
+ $this->values[$index] = null;
+
+ if (null !== $oldValue) {
+ --$this->size;
+ }
+
+ return $this->unmaskNull($oldValue);
+ }
+
+ /**
+ * Removes all mappings from this map.
+ */
+ public function clear() : void
+ {
+ $this->values = array_fill(0, count($this->keyUniverse), null);
+ $this->size = 0;
+ }
+
+ /**
+ * Compares the specified map with this map for quality.
+ *
+ * Returns true if the two maps represent the same mappings.
+ */
+ public function equals(self $other) : bool
+ {
+ if ($this === $other) {
+ return true;
+ }
+
+ if ($this->size !== $other->size) {
+ return false;
+ }
+
+ return $this->values === $other->values;
+ }
+
+ /**
+ * Returns the values contained in this map.
+ *
+ * The array will contain the values in the order their corresponding keys appear in the map, which is their natural
+ * order (the order in which the num constants are declared).
+ */
+ public function values() : array
+ {
+ return array_values(array_map(function ($value) {
+ return $this->unmaskNull($value);
+ }, array_filter($this->values, function ($value) : bool {
+ return null !== $value;
+ })));
+ }
+
+ public function serialize() : string
+ {
+ return serialize($this->__serialize());
+ }
+
+ public function unserialize($serialized) : void
+ {
+ $data = unserialize($serialized);
+ $this->__construct($data['keyType'], $data['valueType'], $data['allowNullValues']);
+
+ foreach ($this->keyUniverse as $key) {
+ if (array_key_exists($key->ordinal(), $data['values'])) {
+ $this->put($key, $data['values'][$key->ordinal()]);
+ }
+ }
+ }
+
+ public function getIterator() : Traversable
+ {
+ foreach ($this->keyUniverse as $key) {
+ if (null === $this->values[$key->ordinal()]) {
+ continue;
+ }
+
+ yield $key => $this->unmaskNull($this->values[$key->ordinal()]);
+ }
+ }
+
+ private function maskNull($value)
+ {
+ if (null === $value) {
+ return NullValue::instance();
+ }
+
+ return $value;
+ }
+
+ private function unmaskNull($value)
+ {
+ if ($value instanceof NullValue) {
+ return null;
+ }
+
+ return $value;
+ }
+
+ /**
+ * @throws IllegalArgumentException when the passed key does not match the internal key type
+ */
+ private function checkKeyType(AbstractEnum $key) : void
+ {
+ if (get_class($key) !== $this->keyType) {
+ throw new IllegalArgumentException(sprintf(
+ 'Object of type %s is not the same type as %s',
+ get_class($key),
+ $this->keyType
+ ));
+ }
+ }
+
+ private function isValidValue($value) : bool
+ {
+ if (null === $value) {
+ if ($this->allowNullValues) {
+ return true;
+ }
+
+ return false;
+ }
+
+ switch ($this->valueType) {
+ case 'mixed':
+ return true;
+
+ case 'bool':
+ case 'boolean':
+ return is_bool($value);
+
+ case 'int':
+ case 'integer':
+ return is_int($value);
+
+ case 'float':
+ case 'double':
+ return is_float($value);
+
+ case 'string':
+ return is_string($value);
+
+ case 'object':
+ return is_object($value);
+
+ case 'array':
+ return is_array($value);
+ }
+
+ return $value instanceof $this->valueType;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/CloneNotSupportedException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/CloneNotSupportedException.php
new file mode 100644
index 0000000..4b37dbe
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/CloneNotSupportedException.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum\Exception;
+
+use Exception;
+
+final class CloneNotSupportedException extends Exception implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/ExceptionInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/ExceptionInterface.php
new file mode 100644
index 0000000..16a6005
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/ExceptionInterface.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum\Exception;
+
+use Throwable;
+
+interface ExceptionInterface extends Throwable
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/ExpectationException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/ExpectationException.php
new file mode 100644
index 0000000..bddfc90
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/ExpectationException.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum\Exception;
+
+use Exception;
+
+final class ExpectationException extends Exception implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/IllegalArgumentException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/IllegalArgumentException.php
new file mode 100644
index 0000000..72b8f73
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/IllegalArgumentException.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum\Exception;
+
+use Exception;
+
+final class IllegalArgumentException extends Exception implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/MismatchException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/MismatchException.php
new file mode 100644
index 0000000..1ca87d5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/MismatchException.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum\Exception;
+
+use Exception;
+
+final class MismatchException extends Exception implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/SerializeNotSupportedException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/SerializeNotSupportedException.php
new file mode 100644
index 0000000..8997a7e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/SerializeNotSupportedException.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum\Exception;
+
+use Exception;
+
+final class SerializeNotSupportedException extends Exception implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/UnserializeNotSupportedException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/UnserializeNotSupportedException.php
new file mode 100644
index 0000000..13b0b49
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/Exception/UnserializeNotSupportedException.php
@@ -0,0 +1,10 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum\Exception;
+
+use Exception;
+
+final class UnserializeNotSupportedException extends Exception implements ExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/NullValue.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/NullValue.php
new file mode 100644
index 0000000..848e9f0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/dasprid/enum/src/NullValue.php
@@ -0,0 +1,75 @@
+<?php
+declare(strict_types = 1);
+
+namespace DASPRiD\Enum;
+
+use DASPRiD\Enum\Exception\CloneNotSupportedException;
+use DASPRiD\Enum\Exception\SerializeNotSupportedException;
+use DASPRiD\Enum\Exception\UnserializeNotSupportedException;
+
+final class NullValue
+{
+ /**
+ * @var self
+ */
+ private static $instance;
+
+ private function __construct()
+ {
+ }
+
+ public static function instance() : self
+ {
+ return self::$instance ?: self::$instance = new self();
+ }
+
+ /**
+ * Forbid cloning enums.
+ *
+ * @throws CloneNotSupportedException
+ */
+ final public function __clone()
+ {
+ throw new CloneNotSupportedException();
+ }
+
+ /**
+ * Forbid serializing enums.
+ *
+ * @throws SerializeNotSupportedException
+ */
+ final public function __sleep() : array
+ {
+ throw new SerializeNotSupportedException();
+ }
+
+ /**
+ * Forbid serializing enums.
+ *
+ * @throws SerializeNotSupportedException
+ */
+ final public function __serialize() : array
+ {
+ throw new SerializeNotSupportedException();
+ }
+
+ /**
+ * Forbid unserializing enums.
+ *
+ * @throws UnserializeNotSupportedException
+ */
+ final public function __wakeup() : void
+ {
+ throw new UnserializeNotSupportedException();
+ }
+
+ /**
+ * Forbid unserializing enums.
+ *
+ * @throws UnserializeNotSupportedException
+ */
+ final public function __unserialize($arg) : void
+ {
+ throw new UnserializeNotSupportedException();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/bug_report.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/bug_report.md
index a56a2af..aad61b9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/bug_report.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/bug_report.md
@@ -1,15 +1,16 @@
---
name: Bug report
about: Create a report to help improve LdapRecord
-title: "[Bug]"
-labels: bug
assignees: ''
---
-<!-- Please update the below information with your environment. -->
+<!--
+ Please update the below information with your environment.
+ Issues filed without the below information will be closed.
+-->
**Environment:**
- LDAP Server Type: [e.g. ActiveDirectory / OpenLDAP / FreeIPA]
- - PHP Version: [e.g. 7.3 / 7.4 / 8.0]
+ - PHP Version: [e.g. 8.1 / 8.2]
**Describe the bug:**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/support---help-request.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/support---help-request.md
index 230916c..b97a977 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/support---help-request.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/ISSUE_TEMPLATE/support---help-request.md
@@ -11,7 +11,10 @@
<!-- https://github.com/sponsors/stevebauman -->
<!-- Thank you for your understanding. -->
-<!-- Please update the below information with your environment. -->
+<!--
+ Please update the below information with your environment.
+ Issues filed without the below information will be closed.
+-->
**Environment:**
- LDAP Server Type: [e.g. ActiveDirectory / OpenLDAP / FreeIPA]
- - PHP Version: [e.g. 7.3 / 7.4 / 8.0]
+ - PHP Version: [e.g. 8.1 / 8.2]
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-cs-fix.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-cs-fix.yml
new file mode 100644
index 0000000..80cd34d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-cs-fix.yml
@@ -0,0 +1,34 @@
+name: run-cs-fix
+
+on:
+ push:
+
+jobs:
+ lint:
+ runs-on: ubuntu-latest
+ strategy:
+ fail-fast: true
+ matrix:
+ php: [8.3]
+
+ steps:
+ - name: Checkout code
+ uses: actions/checkout@v4
+
+ - name: Setup PHP
+ uses: shivammathur/setup-php@v2
+ with:
+ php-version: ${{ matrix.php }}
+ extensions: json, dom, curl, libxml, mbstring
+ coverage: none
+
+ - name: Install Pint
+ run: composer global require laravel/pint
+
+ - name: Run Pint
+ run: pint
+
+ - name: Commit linted files
+ uses: stefanzweifel/git-auto-commit-action@v5
+ with:
+ commit_message: "Fix code style"
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-integration-tests.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-integration-tests.yml
new file mode 100644
index 0000000..de67e91
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-integration-tests.yml
@@ -0,0 +1,62 @@
+name: run-integration-tests
+
+on:
+ push:
+ pull_request:
+ schedule:
+ - cron: "0 0 * * *"
+
+jobs:
+ run-tests:
+ runs-on: ${{ matrix.os }}
+
+ services:
+ ldap:
+ image: osixia/openldap:1.4.0
+ env:
+ LDAP_TLS_VERIFY_CLIENT: try
+ LDAP_OPENLDAP_UID: 1000
+ LDAP_OPENLDAP_GID: 1000
+ LDAP_ORGANISATION: Local
+ LDAP_DOMAIN: local.com
+ LDAP_ADMIN_PASSWORD: secret
+ ports:
+ - 389:389
+ - 636:636
+
+ strategy:
+ fail-fast: false
+ matrix:
+ os: [ubuntu-latest]
+ php: [8.1, 8.2, 8.3]
+
+ name: ${{ matrix.os }} - P${{ matrix.php }}
+
+ steps:
+ - name: Checkout code
+ uses: actions/checkout@v2
+
+ - name: Cache dependencies
+ uses: actions/cache@v3
+ with:
+ path: ~/.composer/cache/files
+ key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
+
+ - name: Set ldap.conf file permissions
+ run: sudo chown -R $USER:$USER /etc/ldap/ldap.conf
+
+ - name: Create ldap.conf file disabling TLS verification
+ run: sudo echo "TLS_REQCERT never" > "/etc/ldap/ldap.conf"
+
+ - name: Setup PHP
+ uses: shivammathur/setup-php@v2
+ with:
+ php-version: ${{ matrix.php }}
+ extensions: ldap, json
+ coverage: none
+
+ - name: Install dependencies
+ run: composer update --prefer-dist --no-interaction
+
+ - name: Execute tests
+ run: vendor/bin/phpunit --testsuite Integration
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml
index 44825dc..8781e91 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.github/workflows/run-tests.yml
@@ -1,78 +1,41 @@
name: run-tests
on:
- push:
- pull_request:
- schedule:
- - cron: "0 0 * * *"
+ push:
+ pull_request:
+ schedule:
+ - cron: "0 0 * * *"
jobs:
- run-tests:
- runs-on: ${{ matrix.os }}
- strategy:
- fail-fast: false
- matrix:
- os: [ubuntu-latest, windows-latest]
- php: [8.1, 8.0, 7.4, 7.3]
+ run-tests:
+ runs-on: ${{ matrix.os }}
+ name: ${{ matrix.os }} - P${{ matrix.php }}
- name: ${{ matrix.os }} - P${{ matrix.php }}
+ strategy:
+ fail-fast: false
+ matrix:
+ os: [ubuntu-latest, windows-latest]
+ php: [8.1, 8.2, 8.3, 8.4]
- steps:
- - name: Checkout code
- uses: actions/checkout@v4
+ steps:
+ - name: Checkout code
+ uses: actions/checkout@v2
- - name: Cache dependencies
- uses: actions/cache@v3
- with:
- path: ~/.composer/cache/files
- key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
+ - name: Cache dependencies
+ uses: actions/cache@v3
+ with:
+ path: ~/.composer/cache/files
+ key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
- - name: Setup PHP
- uses: shivammathur/setup-php@v2
- with:
- php-version: ${{ matrix.php }}
- extensions: ldap, json
- coverage: none
+ - name: Setup PHP
+ uses: shivammathur/setup-php@v2
+ with:
+ php-version: ${{ matrix.php }}
+ extensions: ldap, json
+ coverage: none
- - name: Install dependencies
- run: composer update --prefer-dist --no-interaction
+ - name: Install dependencies
+ run: composer update --prefer-dist --no-interaction
- - name: Execute tests
- run: vendor/bin/phpunit
-
- run-analysis:
- runs-on: ${{ matrix.os }}
- name: Static code analysis (PHP ${{ matrix.php }})
-
- strategy:
- fail-fast: false
- matrix:
- os: [ubuntu-latest]
- php: [8.0]
-
- steps:
- - name: Checkout code
- uses: actions/checkout@v4
-
- - name: Cache dependencies
- uses: actions/cache@v3
- with:
- path: ~/.composer/cache/files
- key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
-
- - name: Setup PHP
- uses: shivammathur/setup-php@v2
- with:
- php-version: ${{ matrix.php }}
- extensions: ldap, json
- coverage: none
- tools: psalm
-
- - name: Validate composer.json
- run: composer validate
-
- - name: Install dependencies
- run: composer update --prefer-dist --no-interaction
-
- - name: Run Psalm
- run: psalm
+ - name: Execute tests
+ run: vendor/bin/phpunit --testsuite Unit
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.scrutinizer.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.scrutinizer.yml
deleted file mode 100644
index b3f8f88..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.scrutinizer.yml
+++ /dev/null
@@ -1,9 +0,0 @@
-filter:
- excluded_paths:
- - tests/*
-build:
- nodes:
- analysis:
- tests:
- override:
- - command: php-scrutinizer-run
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.styleci.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.styleci.yml
deleted file mode 100644
index 9f5e38c..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/.styleci.yml
+++ /dev/null
@@ -1,8 +0,0 @@
-preset: laravel
-enabled:
- - phpdoc_align
- - phpdoc_separation
- - unalign_double_arrow
-disabled:
- - laravel_phpdoc_alignment
- - laravel_phpdoc_separation
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json
index 35c6057..97e84cd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/composer.json
@@ -29,19 +29,22 @@
}
],
"require": {
- "php": ">=7.3",
+ "php": ">=8.1",
"ext-ldap": "*",
"ext-json": "*",
+ "ext-iconv": "*",
"psr/log": "*",
- "psr/simple-cache": "^1.0|^2.0",
- "nesbot/carbon": "^1.0|^2.0",
- "tightenco/collect": "^5.6|^6.0|^7.0|^8.0",
- "illuminate/contracts": "^5.0|^6.0|^7.0|^8.0|^9.0"
+ "nesbot/carbon": "*",
+ "psr/simple-cache": "^1.0|^2.0|^3.0",
+ "illuminate/contracts": "^8.0|^9.0|^10.0|^11.0|^12.0",
+ "illuminate/collections": "^8.0|^9.0|^10.0|^11.0|^12.0"
},
"require-dev": {
"phpunit/phpunit": "^9.0",
"mockery/mockery": "^1.0",
- "spatie/ray": "^1.24"
+ "spatie/ray": "^1.24",
+ "laravel/pint": "^1.6",
+ "fakerphp/faker": "^1.21"
},
"archive": {
"exclude": [
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/docker-compose.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/docker-compose.yml
new file mode 100644
index 0000000..1abf097
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/docker-compose.yml
@@ -0,0 +1,33 @@
+services:
+ ldap:
+ image: osixia/openldap:1.4.0
+ container_name: ldap
+ restart: always
+ hostname: local.com
+ environment:
+ LDAP_TLS_VERIFY_CLIENT: try
+ LDAP_OPENLDAP_UID: 1000
+ LDAP_OPENLDAP_GID: 1000
+ LDAP_ORGANISATION: Local
+ LDAP_DOMAIN : local.com
+ LDAP_ADMIN_PASSWORD: secret
+ ports:
+ - "389:389"
+ - "636:636"
+ networks:
+ - local
+
+ ldapadmin:
+ image: osixia/phpldapadmin:0.9.0
+ container_name: ldapadmin
+ environment:
+ PHPLDAPADMIN_LDAP_HOSTS: ldap
+ restart: always
+ ports:
+ - "6443:443"
+ networks:
+ - local
+
+networks:
+ local:
+ driver: bridge
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/phpunit.xml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/phpunit.xml
index d03fdc2..aed09e4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/phpunit.xml
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/phpunit.xml
@@ -10,8 +10,11 @@
stopOnFailure="false"
>
<testsuites>
- <testsuite name="LdapRecord Test Suite">
- <directory suffix="Test.php">./tests/</directory>
+ <testsuite name="Unit">
+ <directory suffix="Test.php">./tests/Unit</directory>
+ </testsuite>
+ <testsuite name="Integration">
+ <directory suffix="Test.php">./tests/Integration</directory>
</testsuite>
</testsuites>
</phpunit>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/psalm.xml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/psalm.xml
deleted file mode 100644
index 7c0333d..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/psalm.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-<?xml version="1.0"?>
-<psalm
- errorLevel="7"
- resolveFromConfigFile="true"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns="https://getpsalm.org/schema/config"
- xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
->
- <projectFiles>
- <directory name="src" />
- <ignoreFiles>
- <directory name="vendor" />
- </ignoreFiles>
- </projectFiles>
-</psalm>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md
index 505d699..4e34bd7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/readme.md
@@ -1,25 +1,12 @@
-<!-- readme.md -->
-
<p align="center">
- <img src="https://ldaprecord.com/logo.svg" width="400">
+<img src="https://ldaprecord.com/logo.svg" width="400">
</p>
<p align="center">
- <a href="https://github.com/DirectoryTree/LdapRecord/actions">
- <img src="https://img.shields.io/github/workflow/status/directorytree/ldaprecord/run-tests.svg?style=flat-square">
- </a>
- <a href="https://scrutinizer-ci.com/g/DirectoryTree/LdapRecord/?branch=master">
- <img src="https://img.shields.io/scrutinizer/g/DirectoryTree/LdapRecord/master.svg?style=flat-square"/>
- </a>
- <a href="https://packagist.org/packages/DirectoryTree/LdapRecord">
- <img src="https://img.shields.io/packagist/dt/DirectoryTree/LdapRecord.svg?style=flat-square"/>
- </a>
- <a href="https://packagist.org/packages/DirectoryTree/LdapRecord">
- <img src="https://img.shields.io/packagist/v/DirectoryTree/LdapRecord.svg?style=flat-square"/>
- </a>
- <a href="https://packagist.org/packages/DirectoryTree/LdapRecord">
- <img src="https://img.shields.io/github/license/DirectoryTree/LdapRecord.svg?style=flat-square"/>
- </a>
+<a href="https://github.com/DirectoryTree/LdapRecord/actions"><img src="https://img.shields.io/github/actions/workflow/status/directorytree/ldaprecord/run-tests.yml?branch=master&style=flat-square"></a>
+<a href="https://packagist.org/packages/DirectoryTree/LdapRecord"><img src="https://img.shields.io/packagist/dt/DirectoryTree/LdapRecord.svg?style=flat-square"/></a>
+<a href="https://packagist.org/packages/DirectoryTree/LdapRecord"><img src="https://img.shields.io/packagist/v/DirectoryTree/LdapRecord.svg?style=flat-square"/></a>
+<a href="https://packagist.org/packages/DirectoryTree/LdapRecord"><img src="https://img.shields.io/github/license/DirectoryTree/LdapRecord.svg?style=flat-square"/></a>
</p>
<p align="center">
@@ -32,9 +19,9 @@
</p>
<h4 align="center">
- <a href="https://ldaprecord.com/docs/core/v2/quickstart/">Quickstart</a>
+ <a href="https://ldaprecord.com/docs/core/v3/quickstart/">Quickstart</a>
<span> · </span>
- <a href="https://ldaprecord.com/docs/core/v2/">Documentation</a>
+ <a href="https://ldaprecord.com/docs/core/v3/">Documentation</a>
<span> · </span>
<a href="https://github.com/DirectoryTree/LdapRecord-Laravel">Laravel Integration</a>
<span> · </span>
@@ -45,7 +32,7 @@
⏲ **Up and Running Fast**
-Connect to your LDAP servers and start running queries at lightning speed.
+Connect to your LDAP servers and start running queries in a matter of minutes.
💡 **Fluent Filter Builder**
@@ -67,15 +54,15 @@
🚪 **Enable / Disable Accounts**
-Detect and assign User Account Control values on accounts with the fluent [Account Control builder](https://ldaprecord.com/docs/core/v2/active-directory/users/#uac).
+Detect and assign User Account Control values on accounts with the fluent [Account Control builder](https://ldaprecord.com/docs/core/v3/active-directory/users/#uac).
🔑 **Reset / Change Passwords**
-Built-in support for [changing](https://ldaprecord.com/docs/core/v2/active-directory/users/#changing-passwords) and [resetting](https://ldaprecord.com/docs/core/v2/active-directory/users/#resetting-passwords) passwords on Active Directory accounts.
+Built-in support for [changing](https://ldaprecord.com/docs/core/v3/active-directory/users/#changing-passwords) and [resetting](https://ldaprecord.com/docs/core/v3/active-directory/users/#resetting-passwords) passwords on Active Directory accounts.
🗑 **Restore Deleted Objects**
-We've all been there -- accidentally deleting a user or group in Active Directory. [Restore them](https://ldaprecord.com/docs/core/v2/models/#restoring-deleted-models) by seamlessly accessing your directory's recycle bin.
+Seamlessly access your Active Directory recycle bin and [restore deleted objects](https://ldaprecord.com/docs/core/v3/models/#restoring-deleted-models).
---
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Event.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Event.php
index 83716b4..29687db 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Event.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Event.php
@@ -8,33 +8,23 @@
{
/**
* The connection that the username and password is being bound on.
- *
- * @var LdapInterface
*/
- protected $connection;
+ protected LdapInterface $connection;
/**
* The username that is being used for binding.
- *
- * @var string
*/
- protected $username;
+ protected ?string $username;
/**
* The password that is being used for binding.
- *
- * @var string
*/
- protected $password;
+ protected ?string $password;
/**
* Constructor.
- *
- * @param LdapInterface $connection
- * @param string $username
- * @param string $password
*/
- public function __construct(LdapInterface $connection, $username, $password)
+ public function __construct(LdapInterface $connection, ?string $username = null, ?string $password = null)
{
$this->connection = $connection;
$this->username = $username;
@@ -42,31 +32,25 @@
}
/**
- * Returns the events connection.
- *
- * @return LdapInterface
+ * Get the event's connection.
*/
- public function getConnection()
+ public function getConnection(): LdapInterface
{
return $this->connection;
}
/**
- * Returns the authentication events username.
- *
- * @return string
+ * Get the authentication event's username.
*/
- public function getUsername()
+ public function getUsername(): ?string
{
return $this->username;
}
/**
- * Returns the authentication events password.
- *
- * @return string
+ * Get the authentication event's password.
*/
- public function getPassword()
+ public function getPassword(): ?string
{
return $this->password;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Failed.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Failed.php
index 7133e43..b260491 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Failed.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Events/Failed.php
@@ -2,7 +2,32 @@
namespace LdapRecord\Auth\Events;
+use Exception;
+use LdapRecord\Auth\BindException;
+use LdapRecord\LdapInterface;
+
class Failed extends Event
{
- //
+ /**
+ * The exception that was thrown during the bind attempt.
+ */
+ protected BindException $exception;
+
+ /**
+ * Constructor.
+ */
+ public function __construct(LdapInterface $connection, ?string $username, ?string $password, BindException $exception)
+ {
+ parent::__construct($connection, $username, $password);
+
+ $this->exception = $exception;
+ }
+
+ /**
+ * Get the exception that was thrown during the bind attempt.
+ */
+ public function getException(): BindException
+ {
+ return $this->exception;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php
index d41af15..d560098 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Auth/Guard.php
@@ -3,11 +3,6 @@
namespace LdapRecord\Auth;
use Exception;
-use LdapRecord\Auth\Events\Attempting;
-use LdapRecord\Auth\Events\Binding;
-use LdapRecord\Auth\Events\Bound;
-use LdapRecord\Auth\Events\Failed;
-use LdapRecord\Auth\Events\Passed;
use LdapRecord\Configuration\DomainConfiguration;
use LdapRecord\Events\DispatcherInterface;
use LdapRecord\LdapInterface;
@@ -16,30 +11,21 @@
{
/**
* The connection to bind to.
- *
- * @var LdapInterface
*/
- protected $connection;
+ protected LdapInterface $connection;
/**
* The domain configuration to utilize.
- *
- * @var DomainConfiguration
*/
- protected $configuration;
+ protected DomainConfiguration $configuration;
/**
* The event dispatcher.
- *
- * @var DispatcherInterface
*/
- protected $events;
+ protected ?DispatcherInterface $events = null;
/**
* Constructor.
- *
- * @param LdapInterface $connection
- * @param DomainConfiguration $configuration
*/
public function __construct(LdapInterface $connection, DomainConfiguration $configuration)
{
@@ -50,16 +36,10 @@
/**
* Attempt binding a user to the LDAP server.
*
- * @param string $username
- * @param string $password
- * @param bool $stayBound
- *
- * @return bool
- *
* @throws UsernameRequiredException
* @throws PasswordRequiredException
*/
- public function attempt($username, $password, $stayBound = false)
+ public function attempt(string $username, string $password, bool $stayBound = false): bool
{
switch (true) {
case empty($username):
@@ -68,66 +48,81 @@
throw new PasswordRequiredException('A password must be specified.');
}
- $this->fireAttemptingEvent($username, $password);
+ $this->fireAuthEvent('attempting', $username, $password);
try {
$this->bind($username, $password);
- $authenticated = true;
+ $bound = true;
- $this->firePassedEvent($username, $password);
- } catch (BindException $e) {
- $authenticated = false;
+ $this->fireAuthEvent('passed', $username, $password);
+ } catch (BindException) {
+ $bound = false;
}
if (! $stayBound) {
$this->bindAsConfiguredUser();
}
- return $authenticated;
+ return $bound;
}
/**
- * Attempt binding a user to the LDAP server. Supports anonymous binding.
- *
- * @param string|null $username
- * @param string|null $password
+ * Attempt binding a user to the LDAP server. Supports sasl and anonymous binding.
*
* @throws BindException
* @throws \LdapRecord\ConnectionException
*/
- public function bind($username = null, $password = null)
+ public function bind(?string $username = null, ?string $password = null): void
{
- $this->fireBindingEvent($username, $password);
+ $this->fireAuthEvent('binding', $username, $password);
// Prior to binding, we will upgrade our connectivity to TLS on our current
// connection and ensure we are not already bound before upgrading.
// This is to prevent subsequent upgrading on several binds.
- if ($this->connection->isUsingTLS() && ! $this->connection->isBound()) {
+ if ($this->connection->isUsingTLS() && ! $this->connection->isSecure()) {
$this->connection->startTLS();
}
try {
- if (! $this->connection->bind($username, $password)) {
+ if (! $this->authenticate($username, $password)) {
throw new Exception($this->connection->getLastError(), $this->connection->errNo());
}
- $this->fireBoundEvent($username, $password);
+ $this->fireAuthEvent('bound', $username, $password);
} catch (Exception $e) {
- $this->fireFailedEvent($username, $password);
+ $exception = BindException::withDetailedError($e, $this->connection->getDetailedError());
- throw BindException::withDetailedError($e, $this->connection->getDetailedError());
+ $this->fireAuthEvent('failed', $username, $password, $exception);
+
+ throw $exception;
}
}
/**
+ * Authenticate by binding to the LDAP server.
+ *
+ * @throws \LdapRecord\ConnectionException
+ */
+ protected function authenticate(?string $username = null, ?string $password = null): bool
+ {
+ if ($this->configuration->get('use_sasl') ?? false) {
+ return $this->connection->saslBind(
+ $username, $password, $this->configuration->get('sasl_options')
+ );
+ }
+
+ return $this->connection->bind($username, $password)->successful();
+ }
+
+ /**
* Bind to the LDAP server using the configured username and password.
*
* @throws BindException
* @throws \LdapRecord\ConnectionException
* @throws \LdapRecord\Configuration\ConfigurationException
*/
- public function bindAsConfiguredUser()
+ public function bindAsConfiguredUser(): void
{
$this->bind(
$this->configuration->get('username'),
@@ -137,98 +132,29 @@
/**
* Get the event dispatcher instance.
- *
- * @return DispatcherInterface
*/
- public function getDispatcher()
+ public function getDispatcher(): ?DispatcherInterface
{
return $this->events;
}
/**
* Set the event dispatcher instance.
- *
- * @param DispatcherInterface $dispatcher
- *
- * @return void
*/
- public function setDispatcher(DispatcherInterface $dispatcher)
+ public function setDispatcher(?DispatcherInterface $dispatcher = null): void
{
$this->events = $dispatcher;
}
/**
- * Fire the attempting event.
- *
- * @param string $username
- * @param string $password
- *
- * @return void
+ * Fire an authentication event.
*/
- protected function fireAttemptingEvent($username, $password)
+ protected function fireAuthEvent(string $name, ?string $username = null, ?string $password = null, ...$args): void
{
if (isset($this->events)) {
- $this->events->fire(new Attempting($this->connection, $username, $password));
- }
- }
+ $event = implode('\\', [Events::class, ucfirst($name)]);
- /**
- * Fire the passed event.
- *
- * @param string $username
- * @param string $password
- *
- * @return void
- */
- protected function firePassedEvent($username, $password)
- {
- if (isset($this->events)) {
- $this->events->fire(new Passed($this->connection, $username, $password));
- }
- }
-
- /**
- * Fire the failed event.
- *
- * @param string $username
- * @param string $password
- *
- * @return void
- */
- protected function fireFailedEvent($username, $password)
- {
- if (isset($this->events)) {
- $this->events->fire(new Failed($this->connection, $username, $password));
- }
- }
-
- /**
- * Fire the binding event.
- *
- * @param string $username
- * @param string $password
- *
- * @return void
- */
- protected function fireBindingEvent($username, $password)
- {
- if (isset($this->events)) {
- $this->events->fire(new Binding($this->connection, $username, $password));
- }
- }
-
- /**
- * Fire the bound event.
- *
- * @param string $username
- * @param string $password
- *
- * @return void
- */
- protected function fireBoundEvent($username, $password)
- {
- if (isset($this->events)) {
- $this->events->fire(new Bound($this->connection, $username, $password));
+ $this->events->fire(new $event($this->connection, $username, $password, ...$args));
}
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php
index d1124bf..425fbd9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/DomainConfiguration.php
@@ -8,19 +8,15 @@
{
/**
* The extended configuration options.
- *
- * @var array
*/
- protected static $extended = [];
+ protected static array $extended = [];
/**
* The configuration options array.
*
* The default values for each key indicate the type of value it requires.
- *
- * @var array
*/
- protected $options = [
+ protected array $options = [
// An array of LDAP hosts.
'hosts' => [],
@@ -33,6 +29,9 @@
// The port to use for connecting to your hosts.
'port' => LdapInterface::PORT,
+ // The protocol to use for connecting to your hosts (ldap:// or ldaps://).
+ 'protocol' => null,
+
// The base distinguished name of your domain.
'base_dn' => '',
@@ -42,13 +41,28 @@
// The password to use for binding.
'password' => '',
- // Whether or not to use SSL when connecting.
+ // Whether to use SSL when connecting.
'use_ssl' => false,
- // Whether or not to use TLS when connecting.
+ // Whether to use TLS when connecting.
'use_tls' => false,
- // Whether or not follow referrals is enabled when performing LDAP operations.
+ // Whether to use SASL when connecting.
+ 'use_sasl' => false,
+
+ // Whether to allow password changes over plaintext.
+ 'allow_insecure_password_changes' => false,
+
+ // SASL options
+ 'sasl_options' => [
+ 'mech' => null,
+ 'realm' => null,
+ 'authc_id' => null,
+ 'authz_id' => null,
+ 'props' => null,
+ ],
+
+ // Whether follow referrals is enabled when performing LDAP operations.
'follow_referrals' => false,
// Custom LDAP options.
@@ -58,8 +72,6 @@
/**
* Constructor.
*
- * @param array $options
- *
* @throws ConfigurationException When an option value given is an invalid type.
*/
public function __construct(array $options = [])
@@ -73,33 +85,24 @@
/**
* Extend the configuration with a custom option, or override an existing.
- *
- * @param string $option
- * @param mixed $default
- *
- * @return void
*/
- public static function extend($option, $default = null)
+ public static function extend(string $option, mixed $default = null): void
{
static::$extended[$option] = $default;
}
/**
* Flush the extended configuration options.
- *
- * @return void
*/
- public static function flushExtended()
+ public static function flushExtended(): void
{
static::$extended = [];
}
/**
* Get all configuration options.
- *
- * @return array
*/
- public function all()
+ public function all(): array
{
return $this->options;
}
@@ -107,12 +110,9 @@
/**
* Set a configuration option.
*
- * @param string $key
- * @param mixed $value
- *
* @throws ConfigurationException When an option value given is an invalid type.
*/
- public function set($key, $value)
+ public function set(string $key, mixed $value): void
{
if ($this->validate($key, $value)) {
$this->options[$key] = $value;
@@ -120,18 +120,14 @@
}
/**
- * Returns the value for the specified configuration options.
- *
- * @param string $key
- *
- * @return mixed
+ * Get the value for the specified configuration options.
*
* @throws ConfigurationException When the option specified does not exist.
*/
- public function get($key)
+ public function get(string $key): mixed
{
if (! $this->has($key)) {
- throw new ConfigurationException("Option {$key} does not exist.");
+ throw new ConfigurationException("Option $key does not exist.");
}
return $this->options[$key];
@@ -139,12 +135,8 @@
/**
* Checks if a configuration option exists.
- *
- * @param string $key
- *
- * @return bool
*/
- public function has($key)
+ public function has(string $key): bool
{
return array_key_exists($key, $this->options);
}
@@ -152,14 +144,9 @@
/**
* Validate the configuration option.
*
- * @param string $key
- * @param mixed $value
- *
- * @return bool
- *
* @throws ConfigurationException When an option value given is an invalid type.
*/
- protected function validate($key, $value)
+ protected function validate(string $key, mixed $value): bool
{
$default = $this->get($key);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/ArrayValidator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/ArrayValidator.php
index 4aa43ed..1324d16 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/ArrayValidator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/ArrayValidator.php
@@ -6,15 +6,13 @@
{
/**
* The validation exception message.
- *
- * @var string
*/
- protected $message = 'Option [:option] must be an array.';
+ protected string $message = 'Option [:option] must be an array.';
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function passes()
+ public function passes(): bool
{
return is_array($this->value);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/BooleanValidator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/BooleanValidator.php
index 1d25a4b..1156859 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/BooleanValidator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/BooleanValidator.php
@@ -6,15 +6,13 @@
{
/**
* The validation exception message.
- *
- * @var string
*/
- protected $message = 'Option [:option] must be a boolean.';
+ protected string $message = 'Option [:option] must be a boolean.';
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function passes()
+ public function passes(): bool
{
return is_bool($this->value);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/IntegerValidator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/IntegerValidator.php
index 5c4f0f9..d701588 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/IntegerValidator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/IntegerValidator.php
@@ -6,15 +6,13 @@
{
/**
* The validation exception message.
- *
- * @var string
*/
- protected $message = 'Option [:option] must be an integer.';
+ protected string $message = 'Option [:option] must be an integer.';
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function passes()
+ public function passes(): bool
{
return is_numeric($this->value);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/StringOrNullValidator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/StringOrNullValidator.php
index bc23372..5ca453c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/StringOrNullValidator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/StringOrNullValidator.php
@@ -6,15 +6,13 @@
{
/**
* The validation exception message.
- *
- * @var string
*/
- protected $message = 'Option [:option] must be a string or null.';
+ protected string $message = 'Option [:option] must be a string or null.';
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function passes()
+ public function passes(): bool
{
return is_string($this->value) || is_null($this->value);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php
index de2f13f..25aedcb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Configuration/Validators/Validator.php
@@ -8,32 +8,23 @@
{
/**
* The configuration key under validation.
- *
- * @var string
*/
- protected $key;
+ protected string $key;
/**
* The configuration value under validation.
- *
- * @var mixed
*/
- protected $value;
+ protected mixed $value;
/**
* The validation exception message.
- *
- * @var string
*/
- protected $message;
+ protected string $message;
/**
* Constructor.
- *
- * @param string $key
- * @param mixed $value
*/
- public function __construct($key, $value)
+ public function __construct(string $key, mixed $value)
{
$this->key = $key;
$this->value = $value;
@@ -41,19 +32,15 @@
/**
* Determine if the validation rule passes.
- *
- * @return bool
*/
- abstract public function passes();
+ abstract public function passes(): bool;
/**
* Validate the configuration value.
*
- * @return bool
- *
* @throws ConfigurationException
*/
- public function validate()
+ public function validate(): bool
{
if (! $this->passes()) {
$this->fail();
@@ -65,11 +52,9 @@
/**
* Throw a configuration exception.
*
- * @return void
- *
* @throws ConfigurationException
*/
- protected function fail()
+ protected function fail(): void
{
throw new ConfigurationException(
str_replace(':option', $this->key, $this->message)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php
index d429aa4..e04393a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Connection.php
@@ -5,6 +5,7 @@
use Carbon\Carbon;
use Closure;
use LdapRecord\Auth\Guard;
+use LdapRecord\Configuration\ConfigurationException;
use LdapRecord\Configuration\DomainConfiguration;
use LdapRecord\Events\DispatcherInterface;
use LdapRecord\Query\Builder;
@@ -17,85 +18,64 @@
/**
* The underlying LDAP connection.
- *
- * @var Ldap
*/
- protected $ldap;
+ protected LdapInterface $ldap;
/**
* The cache driver.
- *
- * @var Cache|null
*/
- protected $cache;
+ protected ?Cache $cache = null;
/**
* The domain configuration.
- *
- * @var DomainConfiguration
*/
- protected $configuration;
+ protected DomainConfiguration $configuration;
/**
- * The event dispatcher;.
- *
- * @var DispatcherInterface|null
+ * The event dispatcher.
*/
- protected $dispatcher;
+ protected ?DispatcherInterface $dispatcher = null;
/**
- * The current host connected to.
- *
- * @var string
+ * The currently connected host.
*/
- protected $host;
+ protected string $host;
/**
* The configured domain hosts.
- *
- * @var array
*/
- protected $hosts = [];
+ protected array $hosts = [];
/**
* The attempted hosts that failed connecting to.
- *
- * @var array
*/
- protected $attempted = [];
+ protected array $attempted = [];
/**
* The callback to execute upon total connection failure.
- *
- * @var Closure
*/
- protected $failed;
+ protected Closure $failed;
/**
* The authentication guard resolver.
- *
- * @var Closure
*/
- protected $authGuardResolver;
+ protected Closure $authGuardResolver;
/**
* Whether the connection is retrying the initial connection attempt.
- *
- * @var bool
*/
- protected $retryingInitialConnection = false;
+ protected bool $retryingInitialConnection = false;
/**
* Constructor.
*
- * @param array $config
- * @param LdapInterface|null $ldap
+ * @throws ConfigurationException
*/
- public function __construct($config = [], LdapInterface $ldap = null)
+ public function __construct(DomainConfiguration|array $config = [], ?LdapInterface $ldap = null)
{
$this->setConfiguration($config);
- $this->setLdapConnection($ldap ?? new Ldap());
+ $this->setLdapConnection($ldap ?? new Ldap);
$this->failed = function () {
$this->dispatch(new Events\ConnectionFailed($this));
@@ -109,69 +89,63 @@
/**
* Set the connection configuration.
*
- * @param array $config
- *
- * @return $this
- *
* @throws Configuration\ConfigurationException
*/
- public function setConfiguration($config = [])
+ public function setConfiguration(DomainConfiguration|array $config = []): void
{
- $this->configuration = new DomainConfiguration($config);
+ if (! $config instanceof DomainConfiguration) {
+ $config = new DomainConfiguration($config);
+ }
+
+ $this->configuration = $config;
$this->hosts = $this->configuration->get('hosts');
$this->host = reset($this->hosts);
-
- return $this;
}
/**
* Set the LDAP connection.
- *
- * @param LdapInterface $ldap
- *
- * @return $this
*/
- public function setLdapConnection(LdapInterface $ldap)
+ public function setLdapConnection(LdapInterface $ldap): void
{
$this->ldap = $ldap;
-
- return $this;
}
/**
* Set the event dispatcher.
- *
- * @param DispatcherInterface $dispatcher
- *
- * @return $this
*/
- public function setDispatcher(DispatcherInterface $dispatcher)
+ public function setDispatcher(DispatcherInterface $dispatcher): void
{
$this->dispatcher = $dispatcher;
-
- return $this;
}
/**
- * Initializes the LDAP connection.
- *
- * @return void
+ * Get the event dispatcher.
*/
- public function initialize()
+ public function getDispatcher(): ?DispatcherInterface
+ {
+ return $this->dispatcher;
+ }
+
+ /**
+ * Initialize the LDAP connection.
+ */
+ public function initialize(): void
{
$this->configure();
- $this->ldap->connect($this->host, $this->configuration->get('port'));
+ $this->ldap->connect(
+ $this->host,
+ $this->configuration->get('port'),
+ $this->configuration->get('protocol')
+ );
}
/**
* Configure the LDAP connection.
- *
- * @return void
*/
- protected function configure()
+ protected function configure(): void
{
if ($this->configuration->get('use_ssl')) {
$this->ldap->ssl();
@@ -191,62 +165,53 @@
/**
* Set the cache store.
- *
- * @param CacheInterface $store
- *
- * @return $this
*/
- public function setCache(CacheInterface $store)
+ public function setCache(CacheInterface $store): void
{
$this->cache = new Cache($store);
-
- return $this;
}
/**
* Get the cache store.
- *
- * @return Cache|null
*/
- public function getCache()
+ public function getCache(): ?Cache
{
return $this->cache;
}
/**
* Get the LDAP configuration instance.
- *
- * @return DomainConfiguration
*/
- public function getConfiguration()
+ public function getConfiguration(): DomainConfiguration
{
return $this->configuration;
}
/**
* Get the LDAP connection instance.
- *
- * @return Ldap
*/
- public function getLdapConnection()
+ public function getLdapConnection(): LdapInterface
{
return $this->ldap;
}
/**
+ * Set the auth guard resolver callback.
+ */
+ public function setGuardResolver(Closure $callback): void
+ {
+ $this->authGuardResolver = $callback;
+ }
+
+ /**
* Bind to the LDAP server.
*
* If no username or password is specified, then the configured credentials are used.
*
- * @param string|null $username
- * @param string|null $password
- *
- * @return Connection
- *
* @throws Auth\BindException
* @throws LdapRecordException
*/
- public function connect($username = null, $password = null)
+ public function connect(?string $username = null, ?string $password = null): void
{
$attempt = function () use ($username, $password) {
$this->dispatch(new Events\Connecting($this));
@@ -267,19 +232,16 @@
$this->retryOnNextHost($e, $attempt);
}
-
- return $this;
}
/**
* Reconnect to the LDAP server.
*
- * @return void
- *
* @throws Auth\BindException
* @throws ConnectionException
+ * @throws LdapRecordException
*/
- public function reconnect()
+ public function reconnect(): void
{
$this->reinitialize();
@@ -288,10 +250,8 @@
/**
* Reinitialize the connection.
- *
- * @return void
*/
- protected function reinitialize()
+ protected function reinitialize(): void
{
$this->disconnect();
@@ -299,23 +259,25 @@
}
/**
- * Disconnect from the LDAP server.
- *
- * @return void
+ * Clone the connection.
*/
- public function disconnect()
+ public function replicate(): static
+ {
+ return new static($this->configuration, new $this->ldap);
+ }
+
+ /**
+ * Disconnect from the LDAP server.
+ */
+ public function disconnect(): void
{
$this->ldap->close();
}
/**
* Dispatch an event.
- *
- * @param object $event
- *
- * @return void
*/
- public function dispatch($event)
+ public function dispatch(object $event): void
{
if (isset($this->dispatcher)) {
$this->dispatcher->dispatch($event);
@@ -324,26 +286,20 @@
/**
* Get the attempted hosts that failed connecting to.
- *
- * @return array
*/
- public function attempted()
+ public function attempted(): array
{
return $this->attempted;
}
/**
* Perform the operation on the LDAP connection.
- *
- * @param Closure $operation
- *
- * @return mixed
*/
- public function run(Closure $operation)
+ public function run(Closure $operation): mixed
{
try {
// Before running the operation, we will check if the current
- // connection is bound and connect if necessary. Otherwise
+ // connection is bound and connect if necessary. Otherwise,
// some LDAP operations will not be executed properly.
if (! $this->isConnected()) {
$this->connect();
@@ -360,13 +316,23 @@
}
/**
- * Attempt to get an exception for the cause of failure.
- *
- * @param LdapRecordException $e
- *
- * @return mixed
+ * Perform the operation on an isolated LDAP connection.
*/
- protected function getExceptionForCauseOfFailure(LdapRecordException $e)
+ public function isolate(Closure $operation): mixed
+ {
+ $connection = $this->replicate();
+
+ try {
+ return $operation($connection);
+ } finally {
+ $connection->disconnect();
+ }
+ }
+
+ /**
+ * Attempt to get an exception for the cause of failure.
+ */
+ protected function getExceptionForCauseOfFailure(LdapRecordException $e): ?LdapRecordException
{
switch (true) {
case $this->errorContainsMessage($e->getMessage(), 'Already exists'):
@@ -376,30 +342,22 @@
case $this->errorContainsMessage($e->getMessage(), 'Constraint violation'):
return Exceptions\ConstraintViolationException::withDetailedError($e, $e->getDetailedError());
default:
- return;
+ return null;
}
}
/**
* Run the operation callback on the current LDAP connection.
- *
- * @param Closure $operation
- *
- * @return mixed
- *
- * @throws LdapRecordException
*/
- protected function runOperationCallback(Closure $operation)
+ protected function runOperationCallback(Closure $operation): mixed
{
return $operation($this->ldap);
}
/**
* Get a new auth guard instance.
- *
- * @return Auth\Guard
*/
- public function auth()
+ public function auth(): Guard
{
if (! $this->ldap->isConnected()) {
$this->initialize();
@@ -408,7 +366,7 @@
$guard = call_user_func($this->authGuardResolver);
$guard->setDispatcher(
- Container::getInstance()->getEventDispatcher()
+ Container::getInstance()->getDispatcher()
);
return $guard;
@@ -416,10 +374,8 @@
/**
* Get a new query builder for the connection.
- *
- * @return Query\Builder
*/
- public function query()
+ public function query(): Builder
{
return (new Builder($this))
->setCache($this->cache)
@@ -428,10 +384,8 @@
/**
* Determine if the LDAP connection is bound.
- *
- * @return bool
*/
- public function isConnected()
+ public function isConnected(): bool
{
return $this->ldap->isBound();
}
@@ -439,14 +393,9 @@
/**
* Attempt to retry an LDAP operation if due to a lost connection.
*
- * @param LdapRecordException $e
- * @param Closure $operation
- *
- * @return mixed
- *
* @throws LdapRecordException
*/
- protected function tryAgainIfCausedByLostConnection(LdapRecordException $e, Closure $operation)
+ protected function tryAgainIfCausedByLostConnection(LdapRecordException $e, Closure $operation): mixed
{
// If the operation failed due to a lost or failed connection,
// we'll attempt reconnecting and running the operation again
@@ -461,13 +410,9 @@
/**
* Retry the operation on the current host.
*
- * @param Closure $operation
- *
- * @return mixed
- *
* @throws LdapRecordException
*/
- protected function retry(Closure $operation)
+ protected function retry(Closure $operation): mixed
{
try {
$this->retryingInitialConnection
@@ -483,14 +428,9 @@
/**
* Attempt the operation again on the next host.
*
- * @param LdapRecordException $e
- * @param Closure $operation
- *
- * @return mixed
- *
* @throws LdapRecordException
*/
- protected function retryOnNextHost(LdapRecordException $e, Closure $operation)
+ protected function retryOnNextHost(LdapRecordException $e, Closure $operation): mixed
{
$this->attempted[$this->host] = Carbon::now();
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php
index 01b072b..8bef8d1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/ConnectionManager.php
@@ -2,7 +2,6 @@
namespace LdapRecord;
-use BadMethodCallException;
use LdapRecord\Events\Dispatcher;
use LdapRecord\Events\DispatcherInterface;
use LdapRecord\Events\Logger;
@@ -11,151 +10,82 @@
class ConnectionManager
{
/**
- * The logger instance.
- *
- * @var LoggerInterface|null
- */
- protected $logger;
-
- /**
- * The event dispatcher instance.
- *
- * @var DispatcherInterface|null
- */
- protected $dispatcher;
-
- /**
* The added LDAP connections.
*
* @var Connection[]
*/
- protected $connections = [];
+ protected array $connections = [];
/**
* The name of the default connection.
- *
- * @var string
*/
- protected $default = 'default';
+ protected string $default = 'default';
/**
* The events to register listeners for during initialization.
- *
- * @var array
*/
- protected $listen = [
+ protected array $listen = [
'LdapRecord\Auth\Events\*',
'LdapRecord\Query\Events\*',
'LdapRecord\Models\Events\*',
];
/**
- * The method calls to proxy for compatibility.
- *
- * To be removed in the next major version.
- *
- * @var array
+ * The logger instance.
*/
- protected $proxy = [
- 'reset' => 'flush',
- 'addConnection' => 'add',
- 'getConnection' => 'get',
- 'allConnections' => 'all',
- 'removeConnection' => 'remove',
- 'getDefaultConnection' => 'getDefault',
- 'setDefaultConnection' => 'setDefault',
- 'getEventDispatcher' => 'dispatcher',
- 'setEventDispatcher' => 'setDispatcher',
- ];
+ protected ?LoggerInterface $logger = null;
+
+ /**
+ * The event dispatcher instance.
+ */
+ protected ?DispatcherInterface $dispatcher = null;
/**
* Constructor.
- *
- * @return void
*/
- public function __construct()
+ public function __construct($dispatcher = new Dispatcher)
{
- $this->dispatcher = new Dispatcher();
- }
-
- /**
- * Forward missing method calls onto the instance.
- *
- * @param string $method
- * @param mixed $args
- *
- * @return mixed
- */
- public function __call($method, $args)
- {
- $method = $this->proxy[$method] ?? $method;
-
- if (! method_exists($this, $method)) {
- throw new BadMethodCallException(sprintf(
- 'Call to undefined method %s::%s()',
- static::class,
- $method
- ));
- }
-
- return $this->{$method}(...$args);
+ $this->dispatcher = $dispatcher;
}
/**
* Add a new connection.
- *
- * @param Connection $connection
- * @param string|null $name
- *
- * @return $this
*/
- public function add(Connection $connection, $name = null)
+ public function addConnection(Connection $connection, ?string $name = null): void
{
$this->connections[$name ?? $this->default] = $connection;
if ($this->dispatcher) {
$connection->setDispatcher($this->dispatcher);
}
-
- return $this;
}
/**
- * Remove a connection.
- *
- * @param $name
- *
- * @return $this
+ * Remove a connection by its name.
*/
- public function remove($name)
+ public function removeConnection(string $name): void
{
unset($this->connections[$name]);
-
- return $this;
}
/**
- * Get all of the connections.
+ * Get all the registered connections.
*
* @return Connection[]
*/
- public function all()
+ public function getConnections(): array
{
return $this->connections;
}
/**
- * Get a connection by name or return the default.
- *
- * @param string|null $name
- *
- * @return Connection
+ * Get a connection by its name or return the default.
*
* @throws ContainerException If the given connection does not exist.
*/
- public function get($name = null)
+ public function getConnection(?string $name = null): Connection
{
- if ($this->exists($name = $name ?? $this->default)) {
+ if ($this->hasConnection($name = $name ?? $this->default)) {
return $this->connections[$name];
}
@@ -163,85 +93,61 @@
}
/**
- * Return the default connection.
- *
- * @return Connection
+ * Get the default connection.
*/
- public function getDefault()
+ public function getDefaultConnection(): Connection
{
- return $this->get($this->default);
+ return $this->getConnection($this->default);
+ }
+
+ /**
+ * Set the default connection by its name.
+ */
+ public function setDefaultConnection(string $name): void
+ {
+ $this->default = $name;
}
/**
* Get the default connection name.
- *
- * @return string
*/
- public function getDefaultConnectionName()
+ public function getDefaultConnectionName(): string
{
return $this->default;
}
/**
- * Checks if the connection exists.
- *
- * @param string $name
- *
- * @return bool
+ * Determine if a connection exists.
*/
- public function exists($name)
+ public function hasConnection(string $name): bool
{
return array_key_exists($name, $this->connections);
}
/**
- * Set the default connection name.
- *
- * @param string $name
- *
- * @return $this
- */
- public function setDefault($name = null)
- {
- $this->default = $name;
-
- return $this;
- }
-
- /**
* Flush the manager of all instances and connections.
- *
- * @return $this
*/
- public function flush()
+ public function flush(): void
{
$this->logger = null;
$this->connections = [];
- $this->dispatcher = new Dispatcher();
-
- return $this;
+ $this->dispatcher->forgetAll();
}
/**
* Get the logger instance.
- *
- * @return LoggerInterface|null
*/
- public function getLogger()
+ public function getLogger(): ?LoggerInterface
{
return $this->logger;
}
/**
* Set the event logger to use.
- *
- * @param LoggerInterface $logger
- *
- * @return void
*/
- public function setLogger(LoggerInterface $logger)
+ public function setLogger(LoggerInterface $logger): void
{
$this->logger = $logger;
@@ -250,10 +156,8 @@
/**
* Initialize the event logger.
- *
- * @return void
*/
- public function initEventLogger()
+ protected function initEventLogger(): void
{
$logger = $this->newEventLogger();
@@ -268,52 +172,40 @@
/**
* Make a new event logger instance.
- *
- * @return Logger
*/
- protected function newEventLogger()
+ protected function newEventLogger(): Logger
{
return new Logger($this->logger);
}
/**
* Unset the logger instance.
- *
- * @return void
*/
- public function unsetLogger()
+ public function unsetLogger(): void
{
$this->logger = null;
}
/**
* Get the event dispatcher.
- *
- * @return DispatcherInterface|null
*/
- public function dispatcher()
+ public function getDispatcher(): ?DispatcherInterface
{
return $this->dispatcher;
}
/**
* Set the event dispatcher.
- *
- * @param DispatcherInterface $dispatcher
- *
- * @return void
*/
- public function setDispatcher(DispatcherInterface $dispatcher)
+ public function setDispatcher(DispatcherInterface $dispatcher): void
{
$this->dispatcher = $dispatcher;
}
/**
* Unset the event dispatcher.
- *
- * @return void
*/
- public function unsetEventDispatcher()
+ public function unsetDispatcher(): void
{
$this->dispatcher = null;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Container.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Container.php
index f458951..5a3bd7f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Container.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Container.php
@@ -2,125 +2,79 @@
namespace LdapRecord;
-/**
- * @method static $this reset()
- * @method static Connection[] all()
- * @method static Connection[] allConnections()
- * @method static Connection getDefaultConnection()
- * @method static Connection get(string|null $name = null)
- * @method static Connection getConnection(string|null $name = null)
- * @method static bool exists(string $name)
- * @method static $this remove(string|null $name = null)
- * @method static $this removeConnection(string|null $name = null)
- * @method static $this setDefault(string|null $name = null)
- * @method static $this setDefaultConnection(string|null $name = null)
- * @method static $this add(Connection $connection, string|null $name = null)
- * @method static $this addConnection(Connection $connection, string|null $name = null)
- */
+/** @mixin ConnectionManager */
class Container
{
/**
* The current container instance.
- *
- * @var Container
*/
- protected static $instance;
+ protected static Container $instance;
/**
* The connection manager instance.
- *
- * @var ConnectionManager
*/
- protected $manager;
-
- /**
- * The methods to passthru, for compatibility.
- *
- * @var array
- */
- protected $passthru = [
- 'reset', 'flush',
- 'add', 'addConnection',
- 'remove', 'removeConnection',
- 'setDefault', 'setDefaultConnection',
- ];
-
- /**
- * Forward missing static calls onto the current instance.
- *
- * @param string $method
- * @param mixed $args
- *
- * @return mixed
- */
- public static function __callStatic($method, $args)
- {
- return static::getInstance()->{$method}(...$args);
- }
+ protected ConnectionManager $manager;
/**
* Get or set the current instance of the container.
- *
- * @return Container
*/
- public static function getInstance()
+ public static function getInstance(): static
{
return static::$instance ?? static::getNewInstance();
}
/**
* Set the container instance.
- *
- * @param Container|null $container
- *
- * @return Container|null
*/
- public static function setInstance(self $container = null)
+ public static function setInstance(?self $container = null): ?static
{
return static::$instance = $container;
}
/**
* Set and get a new instance of the container.
- *
- * @return Container
*/
- public static function getNewInstance()
+ public static function getNewInstance(): static
{
- return static::setInstance(new static());
+ return static::setInstance(new static);
+ }
+
+ /**
+ * Forward missing static calls onto the current instance.
+ */
+ public static function __callStatic(string $method, array $parameters): mixed
+ {
+ return static::getInstance()->{$method}(...$parameters);
}
/**
* Constructor.
- *
- * @return void
*/
- public function __construct()
+ public function __construct(ConnectionManager $manager = new ConnectionManager)
{
- $this->manager = new ConnectionManager();
+ $this->manager = $manager;
}
/**
* Forward missing method calls onto the connection manager.
- *
- * @param string $method
- * @param mixed $args
- *
- * @return mixed
*/
- public function __call($method, $args)
+ public function __call(string $method, array $parameters): mixed
{
- $value = $this->manager->{$method}(...$args);
+ return $this->manager->{$method}(...$parameters);
+ }
- return in_array($method, $this->passthru) ? $this : $value;
+ /**
+ * Set the current container instance available globally.
+ */
+ public function setAsGlobal(): void
+ {
+ static::setInstance($this);
}
/**
* Get the connection manager.
- *
- * @return ConnectionManager
*/
- public function manager()
+ public function getConnectionManager(): ConnectionManager
{
return $this->manager;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetailedError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetailedError.php
index d61159e..e9d9609 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetailedError.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetailedError.php
@@ -5,66 +5,34 @@
class DetailedError
{
/**
- * The error code from ldap_errno.
- *
- * @var int|null
- */
- protected $errorCode;
-
- /**
- * The error message from ldap_error.
- *
- * @var string|null
- */
- protected $errorMessage;
-
- /**
- * The diagnostic message when retrieved after an ldap_error.
- *
- * @var string|null
- */
- protected $diagnosticMessage;
-
- /**
* Constructor.
- *
- * @param int $errorCode
- * @param string $errorMessage
- * @param string $diagnosticMessage
*/
- public function __construct($errorCode, $errorMessage, $diagnosticMessage)
- {
- $this->errorCode = $errorCode;
- $this->errorMessage = $errorMessage;
- $this->diagnosticMessage = $diagnosticMessage;
- }
+ public function __construct(
+ protected int $errorCode,
+ protected string $errorMessage,
+ protected ?string $diagnosticMessage
+ ) {}
/**
- * Returns the LDAP error code.
- *
- * @return int
+ * Get the LDAP error code.
*/
- public function getErrorCode()
+ public function getErrorCode(): int
{
return $this->errorCode;
}
/**
- * Returns the LDAP error message.
- *
- * @return string
+ * Get the LDAP error message.
*/
- public function getErrorMessage()
+ public function getErrorMessage(): string
{
return $this->errorMessage;
}
/**
- * Returns the LDAP diagnostic message.
- *
- * @return string
+ * Get the LDAP diagnostic message.
*/
- public function getDiagnosticMessage()
+ public function getDiagnosticMessage(): ?string
{
return $this->diagnosticMessage;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetectsErrors.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetectsErrors.php
index e8997a9..bb6f675 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetectsErrors.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/DetectsErrors.php
@@ -6,64 +6,43 @@
{
/**
* Determine if the error was caused by a lost connection.
- *
- * @param string $error
- *
- * @return bool
*/
- protected function causedByLostConnection($error)
+ protected function causedByLostConnection(string $error): bool
{
return $this->errorContainsMessage($error, ["Can't contact LDAP server", 'Operations error']);
}
/**
* Determine if the error was caused by lack of pagination support.
- *
- * @param string $error
- *
- * @return bool
*/
- protected function causedByPaginationSupport($error)
+ protected function causedByPaginationSupport(string $error): bool
{
return $this->errorContainsMessage($error, 'No server controls in result');
}
/**
* Determine if the error was caused by a size limit warning.
- *
- * @param $error
- *
- * @return bool
*/
- protected function causedBySizeLimit($error)
+ protected function causedBySizeLimit(string $error): bool
{
return $this->errorContainsMessage($error, ['Partial search results returned', 'Size limit exceeded']);
}
/**
* Determine if the error was caused by a "No such object" warning.
- *
- * @param string $error
- *
- * @return bool
*/
- protected function causedByNoSuchObject($error)
+ protected function causedByNoSuchObject(string $error): bool
{
return $this->errorContainsMessage($error, ['No such object']);
}
/**
- * Determine if the error contains the any of the messages.
- *
- * @param string $error
- * @param string|array $messages
- *
- * @return bool
+ * Determine if the error contains any of the messages.
*/
- protected function errorContainsMessage($error, $messages = [])
+ protected function errorContainsMessage(string $error, string|array $messages = []): bool
{
foreach ((array) $messages as $message) {
- if (strpos($error, $message) !== false) {
+ if (str_contains($error, $message)) {
return true;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/EscapesValues.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/EscapesValues.php
index acfc020..088b500 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/EscapesValues.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/EscapesValues.php
@@ -8,14 +8,8 @@
{
/**
* Prepare a value to be escaped.
- *
- * @param string $value
- * @param string $ignore
- * @param int $flags
- *
- * @return EscapedValue
*/
- public function escape($value, $ignore = '', $flags = 0)
+ public function escape(mixed $value = null, string $ignore = '', int $flags = 0): EscapedValue
{
return new EscapedValue($value, $ignore, $flags);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/ConnectionEvent.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/ConnectionEvent.php
index e9c2c35..99a6e6f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/ConnectionEvent.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/ConnectionEvent.php
@@ -8,15 +8,11 @@
{
/**
* The LDAP connection.
- *
- * @var Connection
*/
- protected $connection;
+ protected Connection $connection;
/**
* Constructor.
- *
- * @param Connection $connection
*/
public function __construct(Connection $connection)
{
@@ -25,10 +21,8 @@
/**
* Get the connection pertaining to the event.
- *
- * @return Connection
*/
- public function getConnection()
+ public function getConnection(): Connection
{
return $this->connection;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Dispatcher.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Dispatcher.php
index a4ae3de..304e15c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Dispatcher.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Dispatcher.php
@@ -2,7 +2,9 @@
namespace LdapRecord\Events;
+use Closure;
use LdapRecord\Support\Arr;
+use LdapRecord\Support\Str;
/**
* Class Dispatcher.
@@ -21,32 +23,26 @@
{
/**
* The registered event listeners.
- *
- * @var array
*/
- protected $listeners = [];
+ protected array $listeners = [];
/**
* The wildcard listeners.
- *
- * @var array
*/
- protected $wildcards = [];
+ protected array $wildcards = [];
/**
* The cached wildcard listeners.
- *
- * @var array
*/
- protected $wildcardsCache = [];
+ protected array $wildcardsCache = [];
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function listen($events, $listener)
+ public function listen(string|array $events, mixed $listener): void
{
foreach ((array) $events as $event) {
- if (strpos($event, '*') !== false) {
+ if (str_contains((string) $event, '*')) {
$this->setupWildcardListen($event, $listener);
} else {
$this->listeners[$event][] = $this->makeListener($listener);
@@ -56,13 +52,8 @@
/**
* Setup a wildcard listener callback.
- *
- * @param string $event
- * @param mixed $listener
- *
- * @return void
*/
- protected function setupWildcardListen($event, $listener)
+ protected function setupWildcardListen(string $event, mixed $listener): void
{
$this->wildcards[$event][] = $this->makeListener($listener, true);
@@ -70,33 +61,33 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function hasListeners($eventName)
+ public function hasListeners(string $event): bool
{
- return isset($this->listeners[$eventName]) || isset($this->wildcards[$eventName]);
+ return isset($this->listeners[$event]) || isset($this->wildcards[$event]);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function until($event, $payload = [])
+ public function until(string|object $event, mixed $payload = []): mixed
{
return $this->dispatch($event, $payload, true);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function fire($event, $payload = [], $halt = false)
+ public function fire(string|object $event, mixed $payload = [], bool $halt = false): void
{
- return $this->dispatch($event, $payload, $halt);
+ $this->dispatch($event, $payload, $halt);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function dispatch($event, $payload = [], $halt = false)
+ public function dispatch(string|object $event, mixed $payload = [], $halt = false): mixed
{
// When the given "event" is actually an object we will assume it is an event
// object and use the class as the event name and this event itself as the
@@ -133,13 +124,8 @@
/**
* Parse the given event and payload and prepare them for dispatching.
- *
- * @param mixed $event
- * @param mixed $payload
- *
- * @return array
*/
- protected function parseEventAndPayload($event, $payload)
+ protected function parseEventAndPayload(string|object $event, mixed $payload): array
{
if (is_object($event)) {
[$payload, $event] = [[$event], get_class($event)];
@@ -149,92 +135,42 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getListeners($eventName)
+ public function getListeners(string $event): array
{
- $listeners = $this->listeners[$eventName] ?? [];
+ $listeners = $this->listeners[$event] ?? [];
$listeners = array_merge(
$listeners,
- $this->wildcardsCache[$eventName] ?? $this->getWildcardListeners($eventName)
+ $this->wildcardsCache[$event] ?? $this->getWildcardListeners($event)
);
- return class_exists($eventName, false)
- ? $this->addInterfaceListeners($eventName, $listeners)
+ return class_exists($event, false)
+ ? $this->addInterfaceListeners($event, $listeners)
: $listeners;
}
/**
* Get the wildcard listeners for the event.
- *
- * @param string $eventName
- *
- * @return array
*/
- protected function getWildcardListeners($eventName)
+ protected function getWildcardListeners(string $event): array
{
$wildcards = [];
foreach ($this->wildcards as $key => $listeners) {
- if ($this->wildcardContainsEvent($key, $eventName)) {
+ if (Str::is($key, $event)) {
$wildcards = array_merge($wildcards, $listeners);
}
}
- return $this->wildcardsCache[$eventName] = $wildcards;
- }
-
- /**
- * Determine if the wildcard matches or contains the given event.
- *
- * This function is a direct excerpt from Laravel's Str::is().
- *
- * @param string $wildcard
- * @param string $eventName
- *
- * @return bool
- */
- protected function wildcardContainsEvent($wildcard, $eventName)
- {
- $patterns = Arr::wrap($wildcard);
-
- if (empty($patterns)) {
- return false;
- }
-
- foreach ($patterns as $pattern) {
- // If the given event is an exact match we can of course return true right
- // from the beginning. Otherwise, we will translate asterisks and do an
- // actual pattern match against the two strings to see if they match.
- if ($pattern == $eventName) {
- return true;
- }
-
- $pattern = preg_quote($pattern, '#');
-
- // Asterisks are translated into zero-or-more regular expression wildcards
- // to make it convenient to check if the strings starts with the given
- // pattern such as "library/*", making any string check convenient.
- $pattern = str_replace('\*', '.*', $pattern);
-
- if (preg_match('#^'.$pattern.'\z#u', $eventName) === 1) {
- return true;
- }
- }
-
- return false;
+ return $this->wildcardsCache[$event] = $wildcards;
}
/**
* Add the listeners for the event's interfaces to the given array.
- *
- * @param string $eventName
- * @param array $listeners
- *
- * @return array
*/
- protected function addInterfaceListeners($eventName, array $listeners = [])
+ protected function addInterfaceListeners(string $eventName, array $listeners = []): array
{
foreach (class_implements($eventName) as $interface) {
if (isset($this->listeners[$interface])) {
@@ -249,13 +185,8 @@
/**
* Register an event listener with the dispatcher.
- *
- * @param \Closure|string $listener
- * @param bool $wildcard
- *
- * @return \Closure
*/
- public function makeListener($listener, $wildcard = false)
+ public function makeListener(Closure|string $listener, bool $wildcard = false): Closure
{
if (is_string($listener)) {
return $this->createClassListener($listener, $wildcard);
@@ -272,13 +203,8 @@
/**
* Create a class based listener.
- *
- * @param string $listener
- * @param bool $wildcard
- *
- * @return \Closure
*/
- protected function createClassListener($listener, $wildcard = false)
+ protected function createClassListener(string $listener, bool $wildcard = false): Closure
{
return function ($event, $payload) use ($listener, $wildcard) {
if ($wildcard) {
@@ -294,41 +220,53 @@
/**
* Create the class based event callable.
- *
- * @param string $listener
- *
- * @return callable
*/
- protected function createClassCallable($listener)
+ protected function createClassCallable(string $listener): callable
{
[$class, $method] = $this->parseListenerCallback($listener);
- return [new $class(), $method];
+ return [new $class, $method];
}
/**
* Parse the class listener into class and method.
- *
- * @param string $listener
- *
- * @return array
*/
- protected function parseListenerCallback($listener)
+ protected function parseListenerCallback(string $listener): array
{
- return strpos($listener, '@') !== false
+ return str_contains($listener, '@')
? explode('@', $listener, 2)
: [$listener, 'handle'];
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function forget($event)
+ public function forget(string $event): void
{
- if (strpos($event, '*') !== false) {
+ if (str_contains($event, '*')) {
unset($this->wildcards[$event]);
} else {
unset($this->listeners[$event]);
}
+
+ foreach ($this->wildcardsCache as $key => $listeners) {
+ if (Str::is($event, $key)) {
+ unset($this->wildcardsCache[$key]);
+ }
+ }
+ }
+
+ /**
+ * Remove all the listeners from the dispatcher.
+ */
+ public function forgetAll(): void
+ {
+ $listeners = array_merge(
+ $this->listeners, $this->wildcards
+ );
+
+ foreach (array_keys($listeners) as $listener) {
+ $this->forget($listener);
+ }
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/DispatcherInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/DispatcherInterface.php
index 6b7cb10..71de892 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/DispatcherInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/DispatcherInterface.php
@@ -6,70 +6,41 @@
{
/**
* Register an event listener with the dispatcher.
- *
- * @param string|array $events
- * @param mixed $listener
- *
- * @return void
*/
- public function listen($events, $listener);
+ public function listen(string|array $events, mixed $listener): void;
/**
* Determine if a given event has listeners.
- *
- * @param string $eventName
- *
- * @return bool
*/
- public function hasListeners($eventName);
+ public function hasListeners(string $event): bool;
/**
* Fire an event until the first non-null response is returned.
- *
- * @param string|object $event
- * @param mixed $payload
- *
- * @return array|null
*/
- public function until($event, $payload = []);
+ public function until(string|object $event, mixed $payload = []): mixed;
/**
* Fire an event and call the listeners.
- *
- * @param string|object $event
- * @param mixed $payload
- * @param bool $halt
- *
- * @return mixed
*/
- public function fire($event, $payload = [], $halt = false);
+ public function fire(string|object $event, mixed $payload = [], bool $halt = false): void;
/**
* Fire an event and call the listeners.
- *
- * @param string|object $event
- * @param mixed $payload
- * @param bool $halt
- *
- * @return array|null
*/
- public function dispatch($event, $payload = [], $halt = false);
+ public function dispatch(string|object $event, mixed $payload = [], $halt = false): mixed;
/**
- * Get all of the listeners for a given event name.
- *
- * @param string $eventName
- *
- * @return array
+ * Get all the listeners for a given event name.
*/
- public function getListeners($eventName);
+ public function getListeners(string $event): array;
/**
* Remove a set of listeners from the dispatcher.
- *
- * @param string $event
- *
- * @return void
*/
- public function forget($event);
+ public function forget(string $event): void;
+
+ /**
+ * Remove all the listeners from the dispatcher.
+ */
+ public function forgetAll(): void;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php
index b2082e5..5ac66f2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/Logger.php
@@ -13,29 +13,21 @@
{
/**
* The logger instance.
- *
- * @var LoggerInterface|null
*/
- protected $logger;
+ protected ?LoggerInterface $logger;
/**
* Constructor.
- *
- * @param LoggerInterface|null $logger
*/
- public function __construct(LoggerInterface $logger = null)
+ public function __construct(?LoggerInterface $logger = null)
{
$this->logger = $logger;
}
/**
* Logs the given event.
- *
- * @param mixed $event
- *
- * @return void
*/
- public function log($event)
+ public function log($event): void
{
switch (true) {
case $event instanceof AuthEvent:
@@ -52,12 +44,8 @@
/**
* Logs an authentication event.
- *
- * @param AuthEvent $event
- *
- * @return void
*/
- public function auth(AuthEvent $event)
+ public function auth(AuthEvent $event): void
{
if (isset($this->logger)) {
$connection = $event->getConnection();
@@ -80,12 +68,8 @@
/**
* Logs a model event.
- *
- * @param ModelEvent $event
- *
- * @return void
*/
- public function model(ModelEvent $event)
+ public function model(ModelEvent $event): void
{
if (isset($this->logger)) {
$model = $event->getModel();
@@ -105,12 +89,8 @@
/**
* Logs a query event.
- *
- * @param QueryEvent $event
- *
- * @return void
*/
- public function query(QueryEvent $event)
+ public function query(QueryEvent $event): void
{
if (isset($this->logger)) {
$query = $event->getQuery();
@@ -131,13 +111,9 @@
}
/**
- * Returns the operational name of the given event.
- *
- * @param mixed $event
- *
- * @return string
+ * Get the operational name of the given event.
*/
- protected function getOperationName($event)
+ protected function getOperationName($event): string
{
return (new ReflectionClass($event))->getShortName();
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/NullDispatcher.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/NullDispatcher.php
index 73b1f5a..31f95cb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/NullDispatcher.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Events/NullDispatcher.php
@@ -6,15 +6,11 @@
{
/**
* The underlying dispatcher instance.
- *
- * @var DispatcherInterface
*/
- protected $dispatcher;
+ protected DispatcherInterface $dispatcher;
/**
* Constructor.
- *
- * @param DispatcherInterface $dispatcher
*/
public function __construct(DispatcherInterface $dispatcher)
{
@@ -23,91 +19,62 @@
/**
* Register an event listener with the dispatcher.
- *
- * @param string|array $events
- * @param mixed $listener
- *
- * @return void
*/
- public function listen($events, $listener)
+ public function listen(string|array $events, mixed $listener): void
{
$this->dispatcher->listen($events, $listener);
}
/**
* Determine if a given event has listeners.
- *
- * @param string $eventName
- *
- * @return bool
*/
- public function hasListeners($eventName)
+ public function hasListeners(string $event): bool
{
- return $this->dispatcher->hasListeners($eventName);
+ return $this->dispatcher->hasListeners($event);
}
/**
* Fire an event until the first non-null response is returned.
- *
- * @param string|object $event
- * @param mixed $payload
- *
- * @return null
*/
- public function until($event, $payload = [])
+ public function until(string|object $event, mixed $payload = []): ?array
{
return null;
}
/**
* Fire an event and call the listeners.
- *
- * @param string|object $event
- * @param mixed $payload
- * @param bool $halt
- *
- * @return null
*/
- public function fire($event, $payload = [], $halt = false)
- {
- return null;
- }
+ public function fire(string|object $event, mixed $payload = [], bool $halt = false): void {}
/**
* Fire an event and call the listeners.
- *
- * @param string|object $event
- * @param mixed $payload
- * @param bool $halt
- *
- * @return null
*/
- public function dispatch($event, $payload = [], $halt = false)
+ public function dispatch(string|object $event, mixed $payload = [], $halt = false): mixed
{
return null;
}
/**
- * Get all of the listeners for a given event name.
- *
- * @param string $eventName
- *
- * @return array
+ * Get all the listeners for a given event name.
*/
- public function getListeners($eventName)
+ public function getListeners(string $event): array
{
- return $this->dispatcher->getListeners($eventName);
+ return $this->dispatcher->getListeners($event);
}
/**
* Remove a set of listeners from the dispatcher.
- *
- * @param string $event
- *
- * @return void
*/
- public function forget($event)
+ public function forget(string $event): void
{
$this->dispatcher->forget($event);
}
+
+ /**
+ * Remove all the listeners from the dispatcher.
+ */
+ public function forgetAll(): void
+ {
+ $this->dispatcher->forgetAll();
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Exceptions/ConstraintViolationException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Exceptions/ConstraintViolationException.php
index 641843a..b5d30a7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Exceptions/ConstraintViolationException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Exceptions/ConstraintViolationException.php
@@ -11,25 +11,17 @@
/**
* Determine if the exception was generated due to the password policy.
- *
- * @return bool
*/
- public function causedByPasswordPolicy()
+ public function causedByPasswordPolicy(): bool
{
- return isset($this->detailedError)
- ? $this->errorContainsMessage($this->detailedError->getDiagnosticMessage(), '0000052D')
- : false;
+ return isset($this->detailedError) && $this->errorContainsMessage($this->detailedError->getDiagnosticMessage(), '0000052D');
}
/**
* Determine if the exception was generated due to an incorrect password.
- *
- * @return bool
*/
- public function causedByIncorrectPassword()
+ public function causedByIncorrectPassword(): bool
{
- return isset($this->detailedError)
- ? $this->errorContainsMessage($this->detailedError->getDiagnosticMessage(), '00000056')
- : false;
+ return isset($this->detailedError) && $this->errorContainsMessage($this->detailedError->getDiagnosticMessage(), '00000056');
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php
index 9af7ad7..e47904d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/HandlesConnection.php
@@ -5,88 +5,100 @@
use Closure;
use ErrorException;
use Exception;
+use LDAP\Connection;
+/** @mixin Ldap */
trait HandlesConnection
{
/**
* The LDAP host that is currently connected.
- *
- * @var string|null
*/
- protected $host;
+ protected ?string $host = null;
+
+ /**
+ * The LDAP protocol to use (ldap:// or ldaps://).
+ */
+ protected ?string $protocol = null;
/**
* The LDAP connection resource.
*
- * @var resource|null
+ * @var Connection
*/
- protected $connection;
+ protected mixed $connection = null;
/**
- * The bound status of the connection.
- *
- * @var bool
+ * Whether the connection is bound.
*/
- protected $bound = false;
+ protected bool $bound = false;
+
+ /**
+ * Whether the connection is secured over TLS or SSL.
+ */
+ protected bool $secure = false;
/**
* Whether the connection must be bound over SSL.
- *
- * @var bool
*/
- protected $useSSL = false;
+ protected bool $useSSL = false;
/**
* Whether the connection must be bound over TLS.
- *
- * @var bool
*/
- protected $useTLS = false;
+ protected bool $useTLS = false;
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function isUsingSSL()
+ public function isUsingSSL(): bool
{
return $this->useSSL;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function isUsingTLS()
+ public function isUsingTLS(): bool
{
return $this->useTLS;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function isBound()
+ public function isBound(): bool
{
return $this->bound;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function isConnected()
+ public function isSecure(): bool
+ {
+ return $this->secure;
+ }
+
+ /**
+ * {@inheritdoc}
+ */
+ public function isConnected(): bool
{
return ! is_null($this->connection);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function canChangePasswords()
+ public function canChangePasswords(): bool
{
return $this->isUsingSSL() || $this->isUsingTLS();
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function ssl($enabled = true)
+ public function ssl(bool $enabled = true): static
{
$this->useSSL = $enabled;
@@ -94,9 +106,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function tls($enabled = true)
+ public function tls(bool $enabled = true): static
{
$this->useTLS = $enabled;
@@ -104,9 +116,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function setOptions(array $options = [])
+ public function setOptions(array $options = []): void
{
foreach ($options as $option => $value) {
$this->setOption($option, $value);
@@ -114,47 +126,57 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getHost()
+ public function getHost(): ?string
{
return $this->host;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getConnection()
+ public function getConnection(): ?Connection
{
return $this->connection;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getProtocol()
+ public function getProtocol(): string
{
- return $this->isUsingSSL() ? LdapInterface::PROTOCOL_SSL : LdapInterface::PROTOCOL;
+ return $this->protocol ?: (
+ $this->isUsingSSL()
+ ? LdapInterface::PROTOCOL_SSL
+ : LdapInterface::PROTOCOL
+ );
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getExtendedError()
+ public function getExtendedError(): ?string
{
return $this->getDiagnosticMessage();
}
/**
+ * Handle the bind response.
+ */
+ protected function handleBindResponse(LdapResultResponse $response): void
+ {
+ $this->bound = $response->successful();
+
+ $this->secure = $this->secure ?: $this->bound && $this->isUsingSSL();
+ }
+
+ /**
* Convert warnings to exceptions for the given operation.
*
- * @param Closure $operation
- *
- * @return mixed
- *
* @throws LdapRecordException
*/
- protected function executeFailableOperation(Closure $operation)
+ protected function executeFailableOperation(Closure $operation): mixed
{
// If some older versions of PHP, errors are reported instead of throwing
// exceptions, which could be a significant detriment to our application.
@@ -173,8 +195,8 @@
}
// If the failed query operation was a based on a query being executed
- // -- such as a search, read, or listing, then we can safely return
- // the failed response here and prevent throwning an exception.
+ // -- such as a search, read, or list, then we can safely return
+ // the failed response here and prevent throwing an exception.
if ($this->shouldBypassFailure($method = debug_backtrace()[1]['function'])) {
return $result;
}
@@ -189,49 +211,24 @@
/**
* Determine if the failed operation should be bypassed.
- *
- * @param string $method
- *
- * @return bool
*/
- protected function shouldBypassFailure($method)
+ protected function shouldBypassFailure(string $method): bool
{
- return in_array($method, ['search', 'read', 'listing']);
+ return in_array($method, ['search', 'read', 'list']);
}
/**
* Determine if the error should be bypassed.
- *
- * @param string $error
- *
- * @return bool
*/
- protected function shouldBypassError($error)
+ protected function shouldBypassError(string $error): bool
{
return $this->causedByPaginationSupport($error) || $this->causedBySizeLimit($error) || $this->causedByNoSuchObject($error);
}
/**
- * Determine if the current PHP version supports server controls.
- *
- * @deprecated since v2.5.0
- *
- * @return bool
- */
- public function supportsServerControlsInMethods()
- {
- return version_compare(PHP_VERSION, '7.3.0') >= 0;
- }
-
- /**
* Generates an LDAP connection string for each host given.
- *
- * @param string|array $hosts
- * @param string $port
- *
- * @return string
*/
- protected function makeConnectionUris($hosts, $port)
+ protected function makeConnectionUris(array|string $hosts, string|int $port): string
{
// If an attempt to connect via SSL protocol is being performed,
// and we are still using the default port, we will swap it
@@ -248,16 +245,9 @@
/**
* Assemble the host URI strings.
- *
- * @param array|string $hosts
- * @param string $port
- *
- * @return array
*/
- protected function assembleHostUris($hosts, $port)
+ protected function assembleHostUris(array|string $hosts, string|int $port): array
{
- return array_map(function ($host) use ($port) {
- return "{$this->getProtocol()}{$host}:{$port}";
- }, (array) $hosts);
+ return array_map(fn ($host) => "{$this->getProtocol()}{$host}:{$port}", (array) $hosts);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php
index 0c3574f..7f2be60 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Ldap.php
@@ -4,18 +4,18 @@
use LDAP\Connection as RawLdapConnection;
-/** @psalm-suppress UndefinedClass */
class Ldap implements LdapInterface
{
- use HandlesConnection, DetectsErrors;
+ use DetectsErrors;
+ use HandlesConnection;
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getEntries($searchResults)
+ public function getEntries(mixed $result): array
{
- return $this->executeFailableOperation(function () use ($searchResults) {
- return ldap_get_entries($this->connection, $searchResults);
+ return $this->executeFailableOperation(function () use ($result) {
+ return ldap_get_entries($this->connection, $result);
});
}
@@ -24,14 +24,12 @@
*
* @see http://php.net/manual/en/function.ldap-first-entry.php
*
- * @param resource $searchResults
- *
- * @return resource
+ * @param \Ldap\Result $result
*/
- public function getFirstEntry($searchResults)
+ public function getFirstEntry(mixed $result): mixed
{
- return $this->executeFailableOperation(function () use ($searchResults) {
- return ldap_first_entry($this->connection, $searchResults);
+ return $this->executeFailableOperation(function () use ($result) {
+ return ldap_first_entry($this->connection, $result);
});
}
@@ -40,11 +38,9 @@
*
* @see http://php.net/manual/en/function.ldap-next-entry.php
*
- * @param resource $entry
- *
- * @return resource
+ * @param \Ldap\ResultEntry $entry
*/
- public function getNextEntry($entry)
+ public function getNextEntry(mixed $entry): mixed
{
return $this->executeFailableOperation(function () use ($entry) {
return ldap_next_entry($this->connection, $entry);
@@ -56,11 +52,9 @@
*
* @see http://php.net/manual/en/function.ldap-get-attributes.php
*
- * @param resource $entry
- *
- * @return array|false
+ * @param \Ldap\ResultEntry $entry
*/
- public function getAttributes($entry)
+ public function getAttributes(mixed $entry): array|false
{
return $this->executeFailableOperation(function () use ($entry) {
return ldap_get_attributes($this->connection, $entry);
@@ -68,43 +62,29 @@
}
/**
- * Returns the number of entries from a search result.
- *
- * @see http://php.net/manual/en/function.ldap-count-entries.php
- *
- * @param resource $searchResults
- *
- * @return int
+ * {@inheritDoc}
*/
- public function countEntries($searchResults)
+ public function countEntries(mixed $result): int
{
- return $this->executeFailableOperation(function () use ($searchResults) {
- return ldap_count_entries($this->connection, $searchResults);
+ return $this->executeFailableOperation(function () use ($result) {
+ return ldap_count_entries($this->connection, $result);
});
}
/**
- * Compare value of attribute found in entry specified with DN.
- *
- * @see http://php.net/manual/en/function.ldap-compare.php
- *
- * @param string $dn
- * @param string $attribute
- * @param string $value
- *
- * @return mixed
+ * {@inheritDoc}
*/
- public function compare($dn, $attribute, $value)
+ public function compare(string $dn, string $attribute, string $value, ?array $controls = null): bool|int
{
- return $this->executeFailableOperation(function () use ($dn, $attribute, $value) {
- return ldap_compare($this->connection, $dn, $attribute, $value);
+ return $this->executeFailableOperation(function () use ($dn, $attribute, $value, $controls) {
+ return ldap_compare($this->connection, $dn, $attribute, $value, $controls);
});
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getLastError()
+ public function getLastError(): ?string
{
if (! $this->connection) {
return null;
@@ -114,9 +94,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getDetailedError()
+ public function getDetailedError(): ?DetailedError
{
if (! $number = $this->errNo()) {
return null;
@@ -128,16 +108,9 @@
}
/**
- * Get all binary values from the specified result entry.
- *
- * @see http://php.net/manual/en/function.ldap-get-values-len.php
- *
- * @param $entry
- * @param $attribute
- *
- * @return array
+ * {@inheritDoc}
*/
- public function getValuesLen($entry, $attribute)
+ public function getValuesLen(mixed $entry, string $attribute): array|false
{
return $this->executeFailableOperation(function () use ($entry, $attribute) {
return ldap_get_values_len($this->connection, $entry, $attribute);
@@ -145,17 +118,17 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function setOption($option, $value)
+ public function setOption(int $option, mixed $value): bool
{
return ldap_set_option($this->connection, $option, $value);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getOption($option, &$value = null)
+ public function getOption(int $option, mixed &$value = null): mixed
{
ldap_get_option($this->connection, $option, $value);
@@ -166,60 +139,63 @@
* Set a callback function to do re-binds on referral chasing.
*
* @see http://php.net/manual/en/function.ldap-set-rebind-proc.php
- *
- * @param callable $callback
- *
- * @return bool
*/
- public function setRebindCallback(callable $callback)
+ public function setRebindCallback(callable $callback): bool
{
return ldap_set_rebind_proc($this->connection, $callback);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function startTLS()
+ public function startTLS(): bool
{
- return $this->executeFailableOperation(function () {
+ return $this->secure = $this->executeFailableOperation(function () {
return ldap_start_tls($this->connection);
});
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function connect($hosts = [], $port = 389)
+ public function connect(string|array $hosts = [], int $port = 389, ?string $protocol = null): bool
{
$this->bound = false;
-
+ $this->protocol = $protocol;
$this->host = $this->makeConnectionUris($hosts, $port);
- return $this->connection = $this->executeFailableOperation(function () {
+ $this->connection = $this->executeFailableOperation(function () {
return ldap_connect($this->host);
});
+
+ return $this->connection instanceof RawLdapConnection;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function close()
+ public function close(): bool
{
- $result = (is_resource($this->connection) || $this->connection instanceof RawLdapConnection)
- ? @ldap_close($this->connection)
- : false;
+ $result = false;
- $this->connection = null;
+ if ($this->connection instanceof RawLdapConnection) {
+ $result = @ldap_close($this->connection);
+ }
+
$this->bound = false;
+ $this->secure = false;
+
$this->host = null;
+ $this->protocol = null;
+ $this->connection = null;
return $result;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = [])
+ public function search(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed
{
return $this->executeFailableOperation(function () use (
$dn,
@@ -229,18 +205,16 @@
$size,
$time,
$deref,
- $serverControls
+ $controls
) {
- return empty($serverControls)
- ? ldap_search($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref)
- : ldap_search($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref, $serverControls);
+ return ldap_search($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref, $controls);
});
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = [])
+ public function list(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed
{
return $this->executeFailableOperation(function () use (
$dn,
@@ -250,18 +224,16 @@
$size,
$time,
$deref,
- $serverControls
+ $controls
) {
- return empty($serverControls)
- ? ldap_list($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref)
- : ldap_list($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref, $serverControls);
+ return ldap_list($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref, $controls);
});
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = [])
+ public function read(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed
{
return $this->executeFailableOperation(function () use (
$dn,
@@ -271,47 +243,78 @@
$size,
$time,
$deref,
- $serverControls
+ $controls
) {
- return empty($serverControls)
- ? ldap_read($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref)
- : ldap_read($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref, $serverControls);
+ return ldap_read($this->connection, $dn, $filter, $fields, $onlyAttributes, $size, $time, $deref, $controls);
});
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function parseResult($result, &$errorCode, &$dn, &$errorMessage, &$referrals, &$serverControls = [])
+ public function parseResult(mixed $result, int &$errorCode = 0, ?string &$dn = null, ?string &$errorMessage = null, ?array &$referrals = null, ?array &$controls = null): LdapResultResponse|false
{
- return $this->executeFailableOperation(function () use (
- $result,
- &$errorCode,
- &$dn,
- &$errorMessage,
- &$referrals,
- &$serverControls
- ) {
- return empty($serverControls)
- ? ldap_parse_result($this->connection, $result, $errorCode, $dn, $errorMessage, $referrals)
- : ldap_parse_result($this->connection, $result, $errorCode, $dn, $errorMessage, $referrals, $serverControls);
- });
+ if (ldap_parse_result($this->connection, $result, $errorCode, $dn, $errorMessage, $referrals, $controls)) {
+ return new LdapResultResponse(
+ $errorCode,
+ $dn,
+ $errorMessage,
+ $referrals,
+ $controls
+ );
+ }
+
+ return false;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function bind($username, $password)
+ public function bind(?string $dn = null, ?string $password = null, ?array $controls = null): LdapResultResponse
{
- return $this->bound = $this->executeFailableOperation(function () use ($username, $password) {
- return ldap_bind($this->connection, $username, html_entity_decode($password));
+ /** @var \LDAP\Result $result */
+ $result = $this->executeFailableOperation(function () use ($dn, $password, $controls) {
+ return ldap_bind_ext($this->connection, $dn, $password ? html_entity_decode($password) : null, $controls);
+ });
+
+ $response = $this->parseResult($result);
+
+ $this->handleBindResponse($response);
+
+ return $response;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function saslBind(?string $dn = null, ?string $password = null, array $options = []): bool
+ {
+ return $this->executeFailableOperation(function () use ($dn, $password, $options) {
+ $options = array_merge([
+ 'mech' => null,
+ 'realm' => null,
+ 'authc_id' => null,
+ 'authz_id' => null,
+ 'props' => null,
+ ], $options);
+
+ return $this->bound = ldap_sasl_bind(
+ $this->connection,
+ $dn,
+ $password ? html_entity_decode($password) : null,
+ $options['mech'],
+ $options['realm'],
+ $options['authc_id'],
+ $options['authz_id'],
+ $options['props'],
+ );
});
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function add($dn, array $entry)
+ public function add(string $dn, array $entry): bool
{
return $this->executeFailableOperation(function () use ($dn, $entry) {
return ldap_add($this->connection, $dn, $entry);
@@ -319,9 +322,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function delete($dn)
+ public function delete(string $dn): bool
{
return $this->executeFailableOperation(function () use ($dn) {
return ldap_delete($this->connection, $dn);
@@ -329,9 +332,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function rename($dn, $newRdn, $newParent, $deleteOldRdn = false)
+ public function rename(string $dn, string $newRdn, string $newParent, bool $deleteOldRdn = false): bool
{
return $this->executeFailableOperation(function () use (
$dn,
@@ -344,9 +347,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modify($dn, array $entry)
+ public function modify(string $dn, array $entry): bool
{
return $this->executeFailableOperation(function () use ($dn, $entry) {
return ldap_modify($this->connection, $dn, $entry);
@@ -354,9 +357,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modifyBatch($dn, array $values)
+ public function modifyBatch(string $dn, array $values): bool
{
return $this->executeFailableOperation(function () use ($dn, $values) {
return ldap_modify_batch($this->connection, $dn, $values);
@@ -364,9 +367,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modAdd($dn, array $entry)
+ public function modAdd(string $dn, array $entry): bool
{
return $this->executeFailableOperation(function () use ($dn, $entry) {
return ldap_mod_add($this->connection, $dn, $entry);
@@ -374,9 +377,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modReplace($dn, array $entry)
+ public function modReplace(string $dn, array $entry): bool
{
return $this->executeFailableOperation(function () use ($dn, $entry) {
return ldap_mod_replace($this->connection, $dn, $entry);
@@ -384,9 +387,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modDelete($dn, array $entry)
+ public function modDelete(string $dn, array $entry): bool
{
return $this->executeFailableOperation(function () use ($dn, $entry) {
return ldap_mod_del($this->connection, $dn, $entry);
@@ -394,89 +397,63 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function controlPagedResult($pageSize = 1000, $isCritical = false, $cookie = '')
- {
- return $this->executeFailableOperation(function () use ($pageSize, $isCritical, $cookie) {
- return ldap_control_paged_result($this->connection, $pageSize, $isCritical, $cookie);
- });
- }
-
- /**
- * @inheritdoc
- */
- public function controlPagedResultResponse($result, &$cookie, &$estimated = null)
- {
- return $this->executeFailableOperation(function () use ($result, &$cookie, &$estimated) {
- return ldap_control_paged_result_response($this->connection, $result, $cookie, $estimated);
- });
- }
-
- /**
- * @inheritdoc
- */
- public function freeResult($result)
+ public function freeResult(mixed $result): bool
{
return ldap_free_result($result);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function errNo()
+ public function errNo(): ?int
{
return $this->connection ? ldap_errno($this->connection) : null;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function err2Str($number)
+ public function err2Str(int $number): string
{
return ldap_err2str($number);
}
/**
- * Returns the extended error hex code of the last command.
- *
- * @return string|null
+ * Get the extended error hex code of the last command.
*/
- public function getExtendedErrorHex()
+ public function getExtendedErrorHex(): ?string
{
if (preg_match("/(?<=data\s).*?(?=,)/", $this->getExtendedError(), $code)) {
return $code[0];
}
+
+ return null;
}
/**
- * Returns the extended error code of the last command.
- *
- * @return bool|string
+ * Get the extended error code of the last command.
*/
- public function getExtendedErrorCode()
+ public function getExtendedErrorCode(): string|false
{
return $this->extractDiagnosticCode($this->getExtendedError());
}
/**
* Extract the diagnostic code from the message.
- *
- * @param string $message
- *
- * @return string|bool
*/
- public function extractDiagnosticCode($message)
+ public function extractDiagnosticCode(string $message): string|false
{
preg_match('/^([\da-fA-F]+):/', $message, $matches);
- return isset($matches[1]) ? $matches[1] : false;
+ return $matches[1] ?? false;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getDiagnosticMessage()
+ public function getDiagnosticMessage(): ?string
{
$this->getOption(LDAP_OPT_ERROR_STRING, $message);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php
index c74fe4e..735f858 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapInterface.php
@@ -2,156 +2,387 @@
namespace LdapRecord;
+use LDAP\Connection;
+
+/**
+ * @see https://ldap.com/ldap-oid-reference-guide
+ * @see http://msdn.microsoft.com/en-us/library/cc223359.aspx
+ * @see https://help.univention.com/t/openldap-debug-level/19301
+ */
interface LdapInterface
{
/**
- * The SSL LDAP protocol string.
- *
- * @var string
- */
- const PROTOCOL_SSL = 'ldaps://';
-
- /**
* The standard LDAP protocol string.
*
* @var string
*/
- const PROTOCOL = 'ldap://';
+ public const PROTOCOL = 'ldap://';
/**
- * The LDAP SSL port number.
+ * The SSL LDAP protocol string.
*
* @var string
*/
- const PORT_SSL = 636;
+ public const PROTOCOL_SSL = 'ldaps://';
/**
* The standard LDAP port number.
*
+ * @var int
+ */
+ public const PORT = 389;
+
+ /**
+ * The LDAP SSL port number.
+ *
+ * @var int
+ */
+ public const PORT_SSL = 636;
+
+ /**
+ * Print entry and exit from routines.
+ *
+ * @var int
+ */
+ public const DEBUG_TRACE = 1;
+
+ /**
+ * Print packet activity.
+ *
+ * @var int
+ */
+ public const DEBUG_PACKETS = 2;
+
+ /**
+ * Print data arguments from requests.
+ *
+ * @var int
+ */
+ public const DEBUG_ARGS = 4;
+
+ /**
+ * Print connection activity.
+ *
+ * @var int
+ */
+ public const DEBUG_CONNS = 8;
+
+ /**
+ * Print encoding and decoding of data.
+ *
+ * @var int
+ */
+ public const DEBUG_BER = 16;
+
+ /**
+ * Print search filters.
+ *
+ * @var int
+ */
+ public const DEBUG_FILTER = 32;
+
+ /**
+ * Print configuration file processing.
+ *
+ * @var int
+ */
+ public const DEBUG_CONFIG = 64;
+
+ /**
+ * Print Access Control List activities.
+ *
+ * @var int
+ */
+ public const DEBUG_ACL = 128;
+
+ /**
+ * Print operational statistics.
+ *
+ * @var int
+ */
+ public const DEBUG_STATS = 256;
+
+ /**
+ * Print more detailed statistics.
+ *
+ * @var int
+ */
+ public const DEBUG_STATS2 = 512;
+
+ /**
+ * Print communication with shell backends.
+ *
+ * @var int
+ */
+ public const DEBUG_SHELL = 1024;
+
+ /**
+ * Print entry parsing.
+ *
+ * @var int
+ */
+ public const DEBUG_PARSE = 2048;
+
+ /**
+ * Print LDAPSync replication.
+ *
+ * @var int
+ */
+ public const DEBUG_SYNC = 16384;
+
+ /**
+ * Print referral activities.
+ *
+ * @var int
+ */
+ public const DEBUG_REFERRAL = 32768;
+
+ /**
+ * Print error conditions.
+ *
+ * @var int
+ */
+ public const DEBUG_ERROR = 32768;
+
+ /**
+ * Print all levels of debug.
+ *
+ * @var int
+ */
+ public const DEBUG_ANY = 65535;
+
+ /**
+ * OID for StartTLS extended operation. Signals the server to initiate a TLS connection.
+ *
* @var string
*/
- const PORT = 389;
+ public const OID_SERVER_START_TLS = '1.3.6.1.4.1.1466.20037';
/**
- * Various useful server control OID's.
+ * OID for Paged Results Control. Used to retrieve search results in pages.
*
- * @see https://ldap.com/ldap-oid-reference-guide/
- * @see http://msdn.microsoft.com/en-us/library/cc223359.aspx
+ * @var string
*/
- const OID_SERVER_START_TLS = '1.3.6.1.4.1.1466.20037';
- const OID_SERVER_PAGED_RESULTS = '1.2.840.113556.1.4.319';
- const OID_SERVER_SHOW_DELETED = '1.2.840.113556.1.4.417';
- const OID_SERVER_SORT = '1.2.840.113556.1.4.473';
- const OID_SERVER_CROSSDOM_MOVE_TARGET = '1.2.840.113556.1.4.521';
- const OID_SERVER_NOTIFICATION = '1.2.840.113556.1.4.528';
- const OID_SERVER_EXTENDED_DN = '1.2.840.113556.1.4.529';
- const OID_SERVER_LAZY_COMMIT = '1.2.840.113556.1.4.619';
- const OID_SERVER_SD_FLAGS = '1.2.840.113556.1.4.801';
- const OID_SERVER_TREE_DELETE = '1.2.840.113556.1.4.805';
- const OID_SERVER_DIRSYNC = '1.2.840.113556.1.4.841';
- const OID_SERVER_VERIFY_NAME = '1.2.840.113556.1.4.1338';
- const OID_SERVER_DOMAIN_SCOPE = '1.2.840.113556.1.4.1339';
- const OID_SERVER_SEARCH_OPTIONS = '1.2.840.113556.1.4.1340';
- const OID_SERVER_PERMISSIVE_MODIFY = '1.2.840.113556.1.4.1413';
- const OID_SERVER_ASQ = '1.2.840.113556.1.4.1504';
- const OID_SERVER_FAST_BIND = '1.2.840.113556.1.4.1781';
- const OID_SERVER_CONTROL_VLVREQUEST = '2.16.840.1.113730.3.4.9';
+ public const OID_SERVER_PAGED_RESULTS = '1.2.840.113556.1.4.319';
/**
- * Query OID's.
+ * OID for Show Deleted Control. Includes deleted entries in the search results.
*
- * @see https://ldapwiki.com/wiki/LDAP_MATCHING_RULE_IN_CHAIN
+ * @var string
*/
- const OID_MATCHING_RULE_IN_CHAIN = '1.2.840.113556.1.4.1941';
+ public const OID_SERVER_SHOW_DELETED = '1.2.840.113556.1.4.417';
+
+ /**
+ * OID for Server Side Sort Control. Requests the server to sort the search results.
+ *
+ * @var string
+ */
+ public const OID_SERVER_SORT = '1.2.840.113556.1.4.473';
+
+ /**
+ * OID for Cross-Domain Move Target Control. Used in cross-domain move operations.
+ *
+ * @var string
+ */
+ public const OID_SERVER_CROSSDOM_MOVE_TARGET = '1.2.840.113556.1.4.521';
+
+ /**
+ * OID for LDAP Notification Control. Used to register for change notifications.
+ *
+ * @var string
+ */
+ public const OID_SERVER_NOTIFICATION = '1.2.840.113556.1.4.528';
+
+ /**
+ * OID for Extended DN Control. Requests extended DN information in search results.
+ *
+ * @var string
+ */
+ public const OID_SERVER_EXTENDED_DN = '1.2.840.113556.1.4.529';
+
+ /**
+ * OID for Lazy Commit Control. Delays the actual commit of changes until requested.
+ *
+ * @var string
+ */
+ public const OID_SERVER_LAZY_COMMIT = '1.2.840.113556.1.4.619';
+
+ /**
+ * OID for Security Descriptor Flags Control. Used to manipulate security descriptor flags.
+ *
+ * @var string
+ */
+ public const OID_SERVER_SD_FLAGS = '1.2.840.113556.1.4.801';
+
+ /**
+ * OID for Tree Delete Control. Enables the deletion of an entire subtree.
+ *
+ * @var string
+ */
+ public const OID_SERVER_TREE_DELETE = '1.2.840.113556.1.4.805';
+
+ /**
+ * OID for DirSync Control. Used for directory synchronization operations.
+ *
+ * @var string
+ */
+ public const OID_SERVER_DIRSYNC = '1.2.840.113556.1.4.841';
+
+ /**
+ * OID for Verify Name Control. Allows verification of an entry without retrieving attributes.
+ *
+ * @var string
+ */
+ public const OID_SERVER_VERIFY_NAME = '1.2.840.113556.1.4.1338';
+
+ /**
+ * OID for Domain Scope Control. Limits a search to the current domain.
+ *
+ * @var string
+ */
+ public const OID_SERVER_DOMAIN_SCOPE = '1.2.840.113556.1.4.1339';
+
+ /**
+ * OID for Search Options Control. Used to set various search options.
+ *
+ * @var string
+ */
+ public const OID_SERVER_SEARCH_OPTIONS = '1.2.840.113556.1.4.1340';
+
+ /**
+ * OID for Permissive Modify Control. Allows modifications even if some attributes are missing.
+ *
+ * @var string
+ */
+ public const OID_SERVER_PERMISSIVE_MODIFY = '1.2.840.113556.1.4.1413';
+
+ /**
+ * OID for Authentication Service Queries (ASQ) Control. Used to perform ASQ operations.
+ *
+ * @var string
+ */
+ public const OID_SERVER_ASQ = '1.2.840.113556.1.4.1504';
+
+ /**
+ * OID for Fast Bind Control. Optimizes the bind process for faster authentication.
+ *
+ * @var string
+ */
+ public const OID_SERVER_FAST_BIND = '1.2.840.113556.1.4.1781';
+
+ /**
+ * OID for Virtual List View (VLV) Request Control. Used to request a specific range of entries.
+ *
+ * @var string
+ */
+ public const OID_SERVER_CONTROL_VLVREQUEST = '2.16.840.1.113730.3.4.9';
+
+ /**
+ * OID for the 'matchingRuleInChain' matching rule. Used for substring searches in multi-valued attributes.
+ */
+ public const OID_MATCHING_RULE_IN_CHAIN = '1.2.840.113556.1.4.1941';
/**
* Set the current connection to use SSL.
- *
- * @param bool $enabled
- *
- * @return $this
*/
- public function ssl();
+ public function ssl(): static;
/**
* Determine if the current connection instance is using SSL.
- *
- * @return bool
*/
- public function isUsingSSL();
+ public function isUsingSSL(): bool;
/**
* Set the current connection to use TLS.
- *
- * @param bool $enabled
- *
- * @return $this
*/
- public function tls();
+ public function tls(): static;
/**
* Determine if the current connection instance is using TLS.
- *
- * @return bool
*/
- public function isUsingTLS();
+ public function isUsingTLS(): bool;
/**
* Determine if the connection is bound.
- *
- * @return bool
*/
- public function isBound();
+ public function isBound(): bool;
+
+ /**
+ * Determine if the connection is secure over TLS or SSL.
+ */
+ public function isSecure(): bool;
/**
* Determine if the connection has been created.
- *
- * @return bool
*/
- public function isConnected();
+ public function isConnected(): bool;
/**
* Determine the connection is able to modify passwords.
- *
- * @return bool
*/
- public function canChangePasswords();
+ public function canChangePasswords(): bool;
/**
- * Returns the full LDAP host URL.
+ * Get the full LDAP host URL.
*
* Ex: ldap://192.168.1.1:386
- *
- * @return string|null
*/
- public function getHost();
+ public function getHost(): ?string;
/**
- * Get the underlying connection resource.
- *
- * @return resource|null
+ * Get the underlying raw LDAP connection.
*/
- public function getConnection();
+ public function getConnection(): ?Connection;
/**
* Retrieve the entries from a search result.
*
* @see http://php.net/manual/en/function.ldap-get-entries.php
*
- * @param resource $searchResults
- *
- * @return array
+ * @param \LDAP\Result $result
*/
- public function getEntries($searchResults);
+ public function getEntries(mixed $result): array;
+
+ /**
+ * Get the entry identifier for first entry in the result.
+ *
+ * @see https://www.php.net/manual/en/function.ldap-first-entry.php
+ *
+ * @param \LDAP\Result $result
+ */
+ public function getFirstEntry(mixed $result): mixed;
+
+ /**
+ * Retrieve the next result entry.
+ *
+ * @see https://www.php.net/manual/en/function.ldap-next-entry.php
+ *
+ * @param \LDAP\Result $entry
+ */
+ public function getNextEntry(mixed $entry): mixed;
+
+ /**
+ * Reads attributes and values from an entry in the search result.
+ *
+ * @see https://www.php.net/manual/en/function.ldap-get-attributes.php
+ *
+ * @param \LDAP\Result $entry
+ */
+ public function getAttributes(mixed $entry): array|false;
+
+ /**
+ * Reads all the values of the attribute in the entry in the result.
+ *
+ * @param \LDAP\Result $entry
+ */
+ public function getValuesLen(mixed $entry, string $attribute): array|false;
/**
* Retrieve the last error on the current connection.
*
* @see http://php.net/manual/en/function.ldap-error.php
- *
- * @return string|null
*/
- public function getLastError();
+ public function getLastError(): ?string;
/**
* Return detailed information about an error.
@@ -159,66 +390,64 @@
* Returns null when there was a successful last request.
*
* Returns DetailedError when there was an error.
- *
- * @return DetailedError|null
*/
- public function getDetailedError();
+ public function getDetailedError(): ?DetailedError;
+
+ /**
+ * Count the number of entries in a search.
+ *
+ * @see https://www.php.net/manual/en/function.ldap-count-entries.php
+ *
+ * @param \LDAP\Result $result
+ */
+ public function countEntries(mixed $result): int;
+
+ /**
+ * Compare value of attribute found in entry specified with DN.
+ */
+ public function compare(string $dn, string $attribute, string $value, ?array $controls = null): bool|int;
/**
* Set an option on the current connection.
*
* @see http://php.net/manual/en/function.ldap-set-option.php
- *
- * @param int $option
- * @param mixed $value
- *
- * @return bool
*/
- public function setOption($option, $value);
+ public function setOption(int $option, mixed $value): bool;
/**
- * Set options on the current connection.
- *
- * @param array $options
- *
- * @return void
+ * Set multiple options on the current connection.
*/
- public function setOptions(array $options = []);
+ public function setOptions(array $options = []): void;
+
+ /**
+ * Set a callback function to do re-binds on referral chasing.
+ *
+ * @see https://www.php.net/manual/en/function.ldap-set-rebind-proc.php
+ */
+ public function setRebindCallback(callable $callback): bool;
/**
* Get the value for the LDAP option.
*
* @see https://www.php.net/manual/en/function.ldap-get-option.php
- *
- * @param int $option
- * @param mixed $value
- *
- * @return mixed
*/
- public function getOption($option, &$value = null);
+ public function getOption(int $option, mixed &$value = null): mixed;
/**
* Starts a connection using TLS.
*
* @see http://php.net/manual/en/function.ldap-start-tls.php
*
- * @return bool
- *
* @throws LdapRecordException
*/
- public function startTLS();
+ public function startTLS(): bool;
/**
* Connects to the specified hostname using the specified port.
*
* @see http://php.net/manual/en/function.ldap-start-tls.php
- *
- * @param string|array $hosts
- * @param int $port
- *
- * @return resource|false
*/
- public function connect($hosts = [], $port = 389);
+ public function connect(string|array $hosts = [], int $port = 389, ?string $protocol = null): bool;
/**
* Closes the current connection.
@@ -226,292 +455,176 @@
* Returns false if no connection is present.
*
* @see http://php.net/manual/en/function.ldap-close.php
- *
- * @return bool
*/
- public function close();
+ public function close(): bool;
/**
* Performs a search on the current connection.
*
* @see http://php.net/manual/en/function.ldap-search.php
*
- * @param string $dn
- * @param string $filter
- * @param array $fields
- * @param bool $onlyAttributes
- * @param int $size
- * @param int $time
- * @param int $deref
- * @param array $serverControls
- *
- * @return resource
+ * @return \LDAP\Result
*/
- public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []);
+ public function search(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed;
/**
* Performs a single level search on the current connection.
*
* @see http://php.net/manual/en/function.ldap-list.php
*
- * @param string $dn
- * @param string $filter
- * @param array $fields
- * @param bool $onlyAttributes
- * @param int $size
- * @param int $time
- * @param int $deref
- * @param array $serverControls
- *
- * @return resource
+ * @return \LDAP\Result
*/
- public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []);
+ public function list(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed;
/**
* Reads an entry on the current connection.
*
* @see http://php.net/manual/en/function.ldap-read.php
*
- * @param string $dn
- * @param string $filter
- * @param array $fields
- * @param bool $onlyAttributes
- * @param int $size
- * @param int $time
- * @param int $deref
- * @param array $serverControls
- *
- * @return resource
+ * @return \LDAP\Result
*/
- public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = []);
+ public function read(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed;
/**
* Extract information from an LDAP result.
*
* @see https://www.php.net/manual/en/function.ldap-parse-result.php
*
- * @param resource $result
- * @param int $errorCode
- * @param ?string $dn
- * @param ?string $errorMessage
- * @param ?array $referrals
- * @param ?array $serverControls
- *
- * @return bool
+ * @param \LDAP\Result $result
*/
- public function parseResult($result, &$errorCode, &$dn, &$errorMessage, &$referrals, &$serverControls = []);
+ public function parseResult(mixed $result, int &$errorCode = 0, ?string &$dn = null, ?string &$errorMessage = null, ?array &$referrals = null, ?array &$controls = null): LdapResultResponse|false;
/**
- * Binds to the current connection using the specified username and password.
- * If sasl is true, the current connection is bound using SASL.
+ * Bind to the LDAP directory.
*
* @see http://php.net/manual/en/function.ldap-bind.php
*
- * @param string $username
- * @param string $password
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function bind($username, $password);
+ public function bind(?string $dn = null, ?string $password = null, ?array $controls = null): LdapResultResponse;
+
+ /**
+ * Bind to the LDAP directory using SASL.
+ *
+ * SASL options:
+ * - mech: Mechanism (Defaults: null)
+ * - realm: Realm (Defaults: null)
+ * - authc_id: Verification Identity (Defaults: null)
+ * - authz_id: Authorization Identity (Defaults: null)
+ * - props: Options for Authorization Identity (Defaults: null)
+ *
+ * @see https://php.net/manual/en/function.ldap-sasl-bind.php
+ * @see https://www.iana.org/assignments/sasl-mechanisms/sasl-mechanisms.xhtml
+ */
+ public function saslBind(?string $dn = null, ?string $password = null, array $options = []): bool;
/**
* Adds an entry to the current connection.
*
* @see http://php.net/manual/en/function.ldap-add.php
*
- * @param string $dn
- * @param array $entry
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function add($dn, array $entry);
+ public function add(string $dn, array $entry): bool;
/**
* Deletes an entry on the current connection.
*
* @see http://php.net/manual/en/function.ldap-delete.php
*
- * @param string $dn
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function delete($dn);
+ public function delete(string $dn): bool;
/**
* Modify the name of an entry on the current connection.
*
* @see http://php.net/manual/en/function.ldap-rename.php
*
- * @param string $dn
- * @param string $newRdn
- * @param string $newParent
- * @param bool $deleteOldRdn
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function rename($dn, $newRdn, $newParent, $deleteOldRdn = false);
+ public function rename(string $dn, string $newRdn, string $newParent, bool $deleteOldRdn = false): bool;
/**
* Modifies an existing entry on the current connection.
*
* @see http://php.net/manual/en/function.ldap-modify.php
*
- * @param string $dn
- * @param array $entry
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function modify($dn, array $entry);
+ public function modify(string $dn, array $entry): bool;
/**
* Batch modifies an existing entry on the current connection.
*
* @see http://php.net/manual/en/function.ldap-modify-batch.php
*
- * @param string $dn
- * @param array $values
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function modifyBatch($dn, array $values);
+ public function modifyBatch(string $dn, array $values): bool;
/**
* Add attribute values to current attributes.
*
* @see http://php.net/manual/en/function.ldap-mod-add.php
*
- * @param string $dn
- * @param array $entry
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function modAdd($dn, array $entry);
+ public function modAdd(string $dn, array $entry): bool;
/**
* Replaces attribute values with new ones.
*
* @see http://php.net/manual/en/function.ldap-mod-replace.php
*
- * @param string $dn
- * @param array $entry
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function modReplace($dn, array $entry);
+ public function modReplace(string $dn, array $entry): bool;
/**
* Delete attribute values from current attributes.
*
* @see http://php.net/manual/en/function.ldap-mod-del.php
*
- * @param string $dn
- * @param array $entry
- *
- * @return bool
- *
* @throws LdapRecordException
*/
- public function modDelete($dn, array $entry);
-
- /**
- * Send LDAP pagination control.
- *
- * @see http://php.net/manual/en/function.ldap-control-paged-result.php
- *
- * @param int $pageSize
- * @param bool $isCritical
- * @param string $cookie
- *
- * @return bool
- */
- public function controlPagedResult($pageSize = 1000, $isCritical = false, $cookie = '');
-
- /**
- * Retrieve the LDAP pagination cookie.
- *
- * @see http://php.net/manual/en/function.ldap-control-paged-result-response.php
- *
- * @param resource $result
- * @param string $cookie
- *
- * @return bool
- */
- public function controlPagedResultResponse($result, &$cookie);
+ public function modDelete(string $dn, array $entry): bool;
/**
* Frees up the memory allocated internally to store the result.
*
* @see https://www.php.net/manual/en/function.ldap-free-result.php
*
- * @param resource $result
- *
- * @return bool
+ * @param \LDAP\Result $result
*/
- public function freeResult($result);
+ public function freeResult(mixed $result): bool;
/**
- * Returns the error number of the last command executed.
+ * Get the error number of the last command executed.
*
* @see http://php.net/manual/en/function.ldap-errno.php
- *
- * @return int|null
*/
- public function errNo();
+ public function errNo(): ?int;
/**
- * Returns the error string of the specified error number.
+ * Get the error string of the specified error number.
*
* @see http://php.net/manual/en/function.ldap-err2str.php
- *
- * @param int $number
- *
- * @return string
*/
- public function err2Str($number);
+ public function err2Str(int $number): string;
/**
- * Returns the LDAP protocol to utilize for the current connection.
- *
- * @return string
+ * Get the LDAP protocol to utilize for the current connection.
*/
- public function getProtocol();
+ public function getProtocol(): string;
/**
- * Returns the extended error code of the last command.
- *
- * @return string
+ * Get the extended error code of the last command.
*/
- public function getExtendedError();
+ public function getExtendedError(): ?string;
/**
- * Return the diagnostic Message.
- *
- * @return string
+ * Get the diagnostic message.
*/
- public function getDiagnosticMessage();
-
- /**
- * Determine if the current PHP version supports server controls.
- *
- * @deprecated since v2.5.0
- *
- * @return bool
- */
- public function supportsServerControlsInMethods();
+ public function getDiagnosticMessage(): ?string;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapRecordException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapRecordException.php
index b2439bf..f574b9b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapRecordException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapRecordException.php
@@ -8,32 +8,21 @@
{
/**
* The detailed LDAP error (if available).
- *
- * @var DetailedError|null
*/
- protected $detailedError;
+ protected ?DetailedError $detailedError = null;
/**
* Create a new Bind Exception with a detailed connection error.
- *
- * @param Exception $e
- * @param DetailedError|null $error
- *
- * @return $this
*/
- public static function withDetailedError(Exception $e, DetailedError $error = null)
+ public static function withDetailedError(Exception $e, ?DetailedError $error = null): static
{
return (new static($e->getMessage(), $e->getCode(), $e))->setDetailedError($error);
}
/**
* Set the detailed error.
- *
- * @param DetailedError|null $error
- *
- * @return $this
*/
- public function setDetailedError(DetailedError $error = null)
+ public function setDetailedError(?DetailedError $error = null): static
{
$this->detailedError = $error;
@@ -41,11 +30,9 @@
}
/**
- * Returns the detailed error.
- *
- * @return DetailedError|null
+ * Get the detailed error.
*/
- public function getDetailedError()
+ public function getDetailedError(): ?DetailedError
{
return $this->detailedError;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapResultResponse.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapResultResponse.php
new file mode 100644
index 0000000..c0c1e83
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/LdapResultResponse.php
@@ -0,0 +1,33 @@
+<?php
+
+namespace LdapRecord;
+
+class LdapResultResponse
+{
+ /**
+ * Constructor.
+ */
+ public function __construct(
+ public readonly int $errorCode = 0,
+ public readonly ?string $matchedDn = null,
+ public readonly ?string $errorMessage = null,
+ public readonly ?array $referrals = null,
+ public readonly ?array $controls = null,
+ ) {}
+
+ /**
+ * Determine if the LDAP response indicates a successful status.
+ */
+ public function successful(): bool
+ {
+ return $this->errorCode === 0;
+ }
+
+ /**
+ * Determine if the LDAP response indicates a failed status.
+ */
+ public function failed(): bool
+ {
+ return ! $this->successful();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Computer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Computer.php
index 72db0a0..3900c61 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Computer.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Computer.php
@@ -2,18 +2,21 @@
namespace LdapRecord\Models\ActiveDirectory;
+use LdapRecord\Models\ActiveDirectory\Concerns\HasAccountControl;
use LdapRecord\Models\ActiveDirectory\Concerns\HasPrimaryGroup;
+use LdapRecord\Models\ActiveDirectory\Relations\HasOnePrimaryGroup;
+use LdapRecord\Models\Relations\HasMany;
+use LdapRecord\Models\Relations\HasOne;
class Computer extends Entry
{
+ use HasAccountControl;
use HasPrimaryGroup;
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'person',
'organizationalperson',
@@ -23,32 +26,24 @@
/**
* The groups relationship.
- *
- * Retrieves groups that the current computer is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
*/
- public function groups()
+ public function groups(): HasMany
{
return $this->hasMany(Group::class, 'member')->with($this->primaryGroup());
}
/**
* The primary group relationship.
- *
- * @return Relations\HasOnePrimaryGroup
*/
- public function primaryGroup()
+ public function primaryGroup(): HasOnePrimaryGroup
{
return $this->hasOnePrimaryGroup(Group::class, 'primarygroupid');
}
/**
* The managed by relationship.
- *
- * @return \LdapRecord\Models\Relations\HasOne
*/
- public function managedBy()
+ public function managedBy(): HasOne
{
return $this->hasOne([Contact::class, Group::class, User::class], 'managedby');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Concerns/HasAccountControl.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Concerns/HasAccountControl.php
new file mode 100644
index 0000000..425cc54
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Concerns/HasAccountControl.php
@@ -0,0 +1,46 @@
+<?php
+
+namespace LdapRecord\Models\ActiveDirectory\Concerns;
+
+use LdapRecord\Models\Attributes\AccountControl;
+
+trait HasAccountControl
+{
+ /**
+ * Determine if the user's account is enabled.
+ */
+ public function isEnabled(): bool
+ {
+ return ! $this->isDisabled();
+ }
+
+ /**
+ * Determine if the user's account is disabled.
+ */
+ public function isDisabled(): bool
+ {
+ return $this->accountControl()->hasFlag(AccountControl::ACCOUNTDISABLE);
+ }
+
+ /**
+ * Get the user's account control.
+ */
+ public function accountControl(): AccountControl
+ {
+ return new AccountControl(
+ $this->getFirstAttribute('userAccountControl')
+ );
+ }
+
+ /**
+ * Set the user's account control attribute.
+ */
+ public function setUserAccountControlAttribute(mixed $value): void
+ {
+ if ($value instanceof AccountControl) {
+ $value = $value->getValue();
+ }
+
+ $this->attributes['useraccountcontrol'] = [(int) $value];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Concerns/HasPrimaryGroup.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Concerns/HasPrimaryGroup.php
index 97fd3a1..c8e6991 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Concerns/HasPrimaryGroup.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Concerns/HasPrimaryGroup.php
@@ -8,14 +8,8 @@
{
/**
* Returns a new has one primary group relationship.
- *
- * @param mixed $related
- * @param string $relationKey
- * @param string $foreignKey
- *
- * @return HasOnePrimaryGroup
*/
- public function hasOnePrimaryGroup($related, $relationKey, $foreignKey = 'primarygroupid')
+ public function hasOnePrimaryGroup(string $related, string $relationKey, string $foreignKey = 'primarygroupid'): HasOnePrimaryGroup
{
return new HasOnePrimaryGroup($this->newQuery(), $this, $related, $relationKey, $foreignKey);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Contact.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Contact.php
index 52c451f..9087f05 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Contact.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Contact.php
@@ -2,14 +2,14 @@
namespace LdapRecord\Models\ActiveDirectory;
+use LdapRecord\Models\Relations\HasMany;
+
class Contact extends Entry
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'person',
'organizationalperson',
@@ -18,12 +18,8 @@
/**
* The groups relationship.
- *
- * Retrieves groups that the current contact is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
*/
- public function groups()
+ public function groups(): HasMany
{
return $this->hasMany(Group::class, 'member');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Container.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Container.php
index 1636cf3..e17fb1f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Container.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Container.php
@@ -6,10 +6,8 @@
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'container',
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php
index 652ad56..e9924f4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Entry.php
@@ -9,16 +9,15 @@
use LdapRecord\Models\Events\Updated;
use LdapRecord\Models\Types\ActiveDirectory;
use LdapRecord\Query\Model\ActiveDirectoryBuilder;
+use LdapRecord\Support\Arr;
/** @mixin ActiveDirectoryBuilder */
class Entry extends BaseEntry implements ActiveDirectory
{
/**
* The default attributes that should be mutated to dates.
- *
- * @var array
*/
- protected $defaultDates = [
+ protected array $defaultDates = [
'whenchanged' => 'windows',
'whencreated' => 'windows',
'dscorepropagationdata' => 'windows',
@@ -26,57 +25,73 @@
/**
* The attribute key that contains the Object SID.
- *
- * @var string
*/
- protected $sidKey = 'objectsid';
+ protected string $sidKey = 'objectsid';
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getObjectSidKey()
+ public function getObjectSidKey(): string
{
return $this->sidKey;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getObjectSid()
+ public function getObjectSid(): ?string
{
return $this->getFirstAttribute($this->sidKey);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getConvertedSid()
+ public function getConvertedSid($sid = null): ?string
{
try {
- return (string) new Sid($this->getObjectSid());
- } catch (InvalidArgumentException $e) {
- return;
+ return $this->newObjectSid(
+ (string) ($sid ?? $this->getObjectSid())
+ );
+ } catch (InvalidArgumentException) {
+ return null;
}
}
/**
- * Create a new query builder.
- *
- * @param Connection $connection
- *
- * @return ActiveDirectoryBuilder
+ * {@inheritdoc}
*/
- public function newQueryBuilder(Connection $connection)
+ public function getBinarySid($sid = null): ?string
+ {
+ try {
+ return $this->newObjectSid(
+ $sid ?? $this->getObjectSid()
+ )->getBinary();
+ } catch (InvalidArgumentException) {
+ return null;
+ }
+ }
+
+ /**
+ * Make a new object Sid instance.
+ */
+ protected function newObjectSid(string $value): Sid
+ {
+ return new Sid($value);
+ }
+
+ /**
+ * Create a new query builder.
+ */
+ public function newQueryBuilder(Connection $connection): ActiveDirectoryBuilder
{
return new ActiveDirectoryBuilder($connection);
}
/**
* Determine if the object is deleted.
- *
- * @return bool
*/
- public function isDeleted()
+ public function isDeleted(): bool
{
return strtoupper((string) $this->getFirstAttribute('isDeleted')) === 'TRUE';
}
@@ -84,13 +99,9 @@
/**
* Restore a deleted object.
*
- * @param string|null $newParentDn
- *
- * @return bool
- *
* @throws \LdapRecord\LdapRecordException
*/
- public function restore($newParentDn = null)
+ public function restore(?string $newParentDn = null): bool
{
if (! $this->isDeleted()) {
return false;
@@ -112,53 +123,48 @@
$this->setRawAttribute('distinguishedname', $newDn);
$this->save(['isDeleted' => null]);
- }
- /**
- * Get the RootDSE (AD schema) record from the directory.
- *
- * @param string|null $connection
- *
- * @return static
- *
- * @throws \LdapRecord\Models\ModelNotFoundException
- */
- public static function getRootDse($connection = null)
- {
- return static::on($connection ?? (new static())->getConnectionName())
- ->in(null)
- ->read()
- ->whereHas('objectclass')
- ->firstOrFail();
+ return true;
}
/**
* Get the objects restore location.
- *
- * @return string
*/
- protected function getDefaultRestoreLocation()
+ protected function getDefaultRestoreLocation(): ?string
{
return $this->getFirstAttribute('lastKnownParent') ?? $this->getParentDn($this->getParentDn($this->getDn()));
}
/**
- * Converts attributes for JSON serialization.
- *
- * @param array $attributes
- *
- * @return array
+ * Convert the attributes for JSON serialization.
*/
- protected function convertAttributesForJson(array $attributes = [])
+ protected function convertAttributesForJson(array $attributes = []): array
{
$attributes = parent::convertAttributesForJson($attributes);
- if ($this->hasAttribute($this->sidKey)) {
- // If the model has a SID set, we need to convert it due to it being in
- // binary. Otherwise we will receive a JSON serialization exception.
- return array_replace($attributes, [
- $this->sidKey => [$this->getConvertedSid()],
- ]);
+ // If the model has a SID set, we need to convert it to its
+ // string format, due to it being in binary. Otherwise,
+ // we will receive a JSON serialization exception.
+ if (isset($attributes[$this->sidKey])) {
+ $attributes[$this->sidKey] = [$this->getConvertedSid(
+ Arr::first($attributes[$this->sidKey])
+ )];
+ }
+
+ return $attributes;
+ }
+
+ /**
+ * Convert the attributes from JSON serialization.
+ */
+ protected function convertAttributesFromJson(array $attributes = []): array
+ {
+ $attributes = parent::convertAttributesFromJson($attributes);
+
+ if (isset($attributes[$this->sidKey])) {
+ $attributes[$this->sidKey] = [$this->getBinarySid(
+ Arr::first($attributes[$this->sidKey])
+ )];
}
return $attributes;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeDatabase.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeDatabase.php
index 77abbbc..e32f820 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeDatabase.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeDatabase.php
@@ -5,17 +5,17 @@
class ExchangeDatabase extends Entry
{
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public static $objectClasses = ['msExchMDB'];
+ public static array $objectClasses = ['msExchMDB'];
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public static function boot()
+ public static function boot(): void
{
parent::boot();
- static::addGlobalScope(new Scopes\InConfigurationContext());
+ static::addGlobalScope(new Scopes\InConfigurationContext);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeServer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeServer.php
index d304876..5e13d40 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeServer.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ExchangeServer.php
@@ -5,18 +5,18 @@
class ExchangeServer extends Entry
{
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public static $objectClasses = ['msExchExchangeServer'];
+ public static array $objectClasses = ['msExchExchangeServer'];
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public static function boot()
+ public static function boot(): void
{
parent::boot();
- static::addGlobalScope(new Scopes\HasServerRoleAttribute());
- static::addGlobalScope(new Scopes\InConfigurationContext());
+ static::addGlobalScope(new Scopes\HasServerRoleAttribute);
+ static::addGlobalScope(new Scopes\InConfigurationContext);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ForeignSecurityPrincipal.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ForeignSecurityPrincipal.php
index 25287ae..34e6c33 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ForeignSecurityPrincipal.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/ForeignSecurityPrincipal.php
@@ -2,23 +2,23 @@
namespace LdapRecord\Models\ActiveDirectory;
+use LdapRecord\Models\Relations\HasMany;
+
class ForeignSecurityPrincipal extends Entry
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = ['foreignsecurityprincipal'];
+ public static array $objectClasses = [
+ 'foreignsecurityprincipal',
+ ];
/**
* The groups relationship.
*
- * Retrieves groups that the current security principal is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
+ * Retrieves groups that the current security principal is a part of.
*/
- public function groups()
+ public function groups(): HasMany
{
return $this->hasMany(Group::class, 'member');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php
index 7845887..165bd90 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Group.php
@@ -2,14 +2,14 @@
namespace LdapRecord\Models\ActiveDirectory;
+use LdapRecord\Models\Relations\HasMany;
+
class Group extends Entry
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'group',
];
@@ -17,23 +17,17 @@
/**
* The groups relationship.
*
- * Retrieves groups that the current group is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
+ * Retrieves groups that the current group is a part of.
*/
- public function groups()
+ public function groups(): HasMany
{
return $this->hasMany(static::class, 'member');
}
/**
* The members relationship.
- *
- * Retrieves members that are apart of the group.
- *
- * @return \LdapRecord\Models\Relations\HasMany
*/
- public function members()
+ public function members(): HasMany
{
return $this->hasMany([
static::class, User::class, Contact::class, Computer::class,
@@ -44,12 +38,8 @@
/**
* The primary group members relationship.
- *
- * Retrieves members that are apart the primary group.
- *
- * @return \LdapRecord\Models\Relations\HasMany
*/
- public function primaryGroupMembers()
+ public function primaryGroupMembers(): HasMany
{
return $this->hasMany([
static::class, User::class, Contact::class, Computer::class,
@@ -58,13 +48,11 @@
/**
* Get the RID of the group.
- *
- * @return array
*/
- public function getRidAttribute()
+ public function getRidAttribute(): array
{
- $objectSidComponents = explode('-', (string) $this->getConvertedSid());
-
- return [end($objectSidComponents)];
+ return array_filter([
+ last(explode('-', (string) $this->getConvertedSid())),
+ ]);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/OrganizationalUnit.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/OrganizationalUnit.php
index 80aae9f..0801d10 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/OrganizationalUnit.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/OrganizationalUnit.php
@@ -6,20 +6,16 @@
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'organizationalunit',
];
/**
* Get the creatable RDN attribute name.
- *
- * @return string
*/
- public function getCreatableRdnAttribute()
+ public function getCreatableRdnAttribute(): string
{
return 'ou';
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Printer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Printer.php
index df74216..7153498 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Printer.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Printer.php
@@ -6,8 +6,6 @@
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = ['printqueue'];
+ public static array $objectClasses = ['printqueue'];
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Relations/HasOnePrimaryGroup.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Relations/HasOnePrimaryGroup.php
index 540ec77..971f790 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Relations/HasOnePrimaryGroup.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Relations/HasOnePrimaryGroup.php
@@ -9,12 +9,8 @@
{
/**
* Get the foreign model by the given value.
- *
- * @param string $value
- *
- * @return Model|null
*/
- protected function getForeignModelByValue($value)
+ protected function getForeignModelByValue(string $value): ?Model
{
return $this->query->findBySid(
$this->getParentModelObjectSid()
@@ -25,12 +21,8 @@
* Get the foreign value from the given model.
*
* Retrieves the last RID from the models Object SID.
- *
- * @param Model $model
- *
- * @return string
*/
- protected function getForeignValueFromModel(Model $model)
+ protected function getForeignValueFromModel(Model $model): ?string
{
$objectSidComponents = explode('-', $model->getConvertedSid());
@@ -39,10 +31,8 @@
/**
* Get the parent relationship models converted object sid.
- *
- * @return string
*/
- protected function getParentModelObjectSid()
+ protected function getParentModelObjectSid(): string
{
return preg_replace(
'/\d+$/',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/HasServerRoleAttribute.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/HasServerRoleAttribute.php
index cd08648..24a2387 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/HasServerRoleAttribute.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/HasServerRoleAttribute.php
@@ -10,13 +10,8 @@
{
/**
* Includes condition of having a serverRole attribute.
- *
- * @param Builder $query
- * @param Model $model
- *
- * @return void
*/
- public function apply(Builder $query, Model $model)
+ public function apply(Builder $query, Model $model): void
{
$query->whereHas('serverRole');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php
index 9f2fbe4..b7942cf 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/InConfigurationContext.php
@@ -12,14 +12,9 @@
/**
* Refines the base dn to be inside the configuration context.
*
- * @param Builder $query
- * @param Model $model
- *
- * @return void
- *
* @throws \LdapRecord\Models\ModelNotFoundException
*/
- public function apply(Builder $query, Model $model)
+ public function apply(Builder $query, Model $model): void
{
$query->in($this->getConfigurationNamingContext($model));
}
@@ -27,10 +22,6 @@
/**
* Get the LDAP server configuration naming context distinguished name.
*
- * @param Model $model
- *
- * @return mixed
- *
* @throws \LdapRecord\Models\ModelNotFoundException
*/
protected function getConfigurationNamingContext(Model $model)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/RejectComputerObjectClass.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/RejectComputerObjectClass.php
index a616db1..30545b8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/RejectComputerObjectClass.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/Scopes/RejectComputerObjectClass.php
@@ -10,13 +10,8 @@
{
/**
* Prevent computer objects from being included in results.
- *
- * @param Builder $query
- * @param Model $model
- *
- * @return void
*/
- public function apply(Builder $query, Model $model)
+ public function apply(Builder $query, Model $model): void
{
$query->where('objectclass', '!=', 'computer');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php
index b735b03..3faec38 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ActiveDirectory/User.php
@@ -4,38 +4,36 @@
use Carbon\Carbon;
use Illuminate\Contracts\Auth\Authenticatable;
+use LdapRecord\Models\ActiveDirectory\Concerns\HasAccountControl;
use LdapRecord\Models\ActiveDirectory\Concerns\HasPrimaryGroup;
use LdapRecord\Models\ActiveDirectory\Scopes\RejectComputerObjectClass;
use LdapRecord\Models\Concerns\CanAuthenticate;
use LdapRecord\Models\Concerns\HasPassword;
+use LdapRecord\Models\Relations\HasMany;
+use LdapRecord\Models\Relations\HasOne;
use LdapRecord\Query\Model\Builder;
class User extends Entry implements Authenticatable
{
+ use CanAuthenticate;
+ use HasAccountControl;
use HasPassword;
use HasPrimaryGroup;
- use CanAuthenticate;
/**
* The password's attribute name.
- *
- * @var string
*/
- protected $passwordAttribute = 'unicodepwd';
+ protected string $passwordAttribute = 'unicodepwd';
/**
* The password's hash method.
- *
- * @var string
*/
- protected $passwordHashMethod = 'encode';
+ protected string $passwordHashMethod = 'encode';
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'person',
'organizationalperson',
@@ -44,10 +42,8 @@
/**
* The attributes that should be mutated to dates.
- *
- * @var array
*/
- protected $dates = [
+ protected array $dates = [
'lastlogon' => 'windows-int',
'lastlogoff' => 'windows-int',
'pwdlastset' => 'windows-int',
@@ -58,9 +54,9 @@
];
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected static function boot()
+ protected static function boot(): void
{
parent::boot();
@@ -68,17 +64,23 @@
// class. This is needed due to computer objects containing all
// of the ActiveDirectory 'user' object classes. Without
// this scope, they would be included in results.
- static::addGlobalScope(new RejectComputerObjectClass());
+ static::addGlobalScope(new RejectComputerObjectClass);
+ }
+
+ /**
+ * Get the unique identifier for the user.
+ */
+ public function getAuthIdentifier(): ?string
+ {
+ return $this->getConvertedGuid();
}
/**
* The groups relationship.
*
- * Retrieves groups that the user is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
+ * Retrieves groups that the user is a part of.
*/
- public function groups()
+ public function groups(): HasMany
{
return $this->hasMany(Group::class, 'member')->with($this->primaryGroup());
}
@@ -87,10 +89,8 @@
* The manager relationship.
*
* Retrieves the manager of the user.
- *
- * @return \LdapRecord\Models\Relations\HasOne
*/
- public function manager()
+ public function manager(): HasOne
{
return $this->hasOne(static::class, 'manager');
}
@@ -98,35 +98,25 @@
/**
* The primary group relationship of the current user.
*
- * Retrieves the primary group the user is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasOne
+ * Retrieves the primary group the user is a part of.
*/
- public function primaryGroup()
+ public function primaryGroup(): HasOne
{
return $this->hasOnePrimaryGroup(Group::class, 'primarygroupid');
}
/**
* Scopes the query to exchange mailbox users.
- *
- * @param Builder $query
- *
- * @return Builder
*/
- public function scopeWhereHasMailbox(Builder $query)
+ public function scopeWhereHasMailbox(Builder $query): Builder
{
return $query->whereHas('msExchMailboxGuid');
}
/**
* Scopes the query to users having a lockout value set.
- *
- * @param Builder $query
- *
- * @return Builder
*/
- public function scopeWhereHasLockout(Builder $query)
+ public function scopeWhereHasLockout(Builder $query): Builder
{
return $query->where('lockoutTime', '>=', 1);
}
@@ -136,13 +126,8 @@
*
* @see https://ldapwiki.com/wiki/Active%20Directory%20Account%20Lockout
* @see https://docs.microsoft.com/en-us/windows/security/threat-protection/security-policy-settings/account-lockout-duration
- *
- * @param string|int $localTimezone
- * @param int|null $durationInMinutes
- *
- * @return bool
*/
- public function isLockedOut($localTimezone, $durationInMinutes = null)
+ public function isLockedOut(string|int $localTimezone, ?int $durationInMinutes = null): bool
{
$time = $this->getFirstAttribute('lockouttime');
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php
index 7e24146..9024b93 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/AccountControl.php
@@ -3,204 +3,171 @@
namespace LdapRecord\Models\Attributes;
use ReflectionClass;
+use Stringable;
-class AccountControl
+class AccountControl implements Stringable
{
- const SCRIPT = 1;
+ public const SCRIPT = 1;
- const ACCOUNTDISABLE = 2;
+ public const ACCOUNTDISABLE = 2;
- const HOMEDIR_REQUIRED = 8;
+ public const HOMEDIR_REQUIRED = 8;
- const LOCKOUT = 16;
+ public const LOCKOUT = 16;
- const PASSWD_NOTREQD = 32;
+ public const PASSWD_NOTREQD = 32;
- const PASSWD_CANT_CHANGE = 64;
+ public const PASSWD_CANT_CHANGE = 64;
- const ENCRYPTED_TEXT_PWD_ALLOWED = 128;
+ public const ENCRYPTED_TEXT_PWD_ALLOWED = 128;
- const TEMP_DUPLICATE_ACCOUNT = 256;
+ public const TEMP_DUPLICATE_ACCOUNT = 256;
- const NORMAL_ACCOUNT = 512;
+ public const NORMAL_ACCOUNT = 512;
- const INTERDOMAIN_TRUST_ACCOUNT = 2048;
+ public const INTERDOMAIN_TRUST_ACCOUNT = 2048;
- const WORKSTATION_TRUST_ACCOUNT = 4096;
+ public const WORKSTATION_TRUST_ACCOUNT = 4096;
- const SERVER_TRUST_ACCOUNT = 8192;
+ public const SERVER_TRUST_ACCOUNT = 8192;
- const DONT_EXPIRE_PASSWORD = 65536;
+ public const DONT_EXPIRE_PASSWORD = 65536;
- const MNS_LOGON_ACCOUNT = 131072;
+ public const MNS_LOGON_ACCOUNT = 131072;
- const SMARTCARD_REQUIRED = 262144;
+ public const SMARTCARD_REQUIRED = 262144;
- const TRUSTED_FOR_DELEGATION = 524288;
+ public const TRUSTED_FOR_DELEGATION = 524288;
- const NOT_DELEGATED = 1048576;
+ public const NOT_DELEGATED = 1048576;
- const USE_DES_KEY_ONLY = 2097152;
+ public const USE_DES_KEY_ONLY = 2097152;
- const DONT_REQ_PREAUTH = 4194304;
+ public const DONT_REQ_PREAUTH = 4194304;
- const PASSWORD_EXPIRED = 8388608;
+ public const PASSWORD_EXPIRED = 8388608;
- const TRUSTED_TO_AUTH_FOR_DELEGATION = 16777216;
+ public const TRUSTED_TO_AUTH_FOR_DELEGATION = 16777216;
- const PARTIAL_SECRETS_ACCOUNT = 67108864;
+ public const PARTIAL_SECRETS_ACCOUNT = 67108864;
/**
- * The account control flag values.
+ * The account control flags.
*
* @var array<int, int>
*/
- protected $values = [];
+ protected array $flags = [];
/**
* Constructor.
- *
- * @param ?int $flag
*/
- public function __construct($flag = null)
+ public function __construct(?int $flag = null)
{
if (! is_null($flag)) {
- $this->apply($flag);
+ $this->applyFlags($flag);
}
}
/**
- * Get the value when casted to string.
- *
- * @return string
+ * Get the value when cast to string.
*/
- public function __toString()
+ public function __toString(): string
{
return (string) $this->getValue();
}
/**
- * Get the value when casted to int.
- *
- * @return int
+ * Get the value when cast to int.
*/
- public function __toInt()
+ public function __toInt(): int
{
return $this->getValue();
}
/**
- * Add the flag to the account control values.
- *
- * @param int $flag
- *
- * @return $this
+ * Set a flag on the account control.
*/
- public function add($flag)
+ public function setFlag(int $flag): static
{
// Use the value as a key so if the same value
// is used, it will always be overwritten
- $this->values[$flag] = $flag;
+ $this->flags[$flag] = $flag;
return $this;
}
/**
- * Remove the flag from the account control.
- *
- * @param int $flag
- *
- * @return $this
+ * Unset a flag from the account control.
*/
- public function remove($flag)
+ public function unsetFlag(int $flag): static
{
- unset($this->values[$flag]);
+ unset($this->flags[$flag]);
return $this;
}
/**
- * Extract and apply the flag.
- *
- * @param int $flag
- *
- * @return void
+ * Extract and apply several flags.
*/
- public function apply($flag)
+ public function applyFlags(int $flags): void
{
- $this->setValues($this->extractFlags($flag));
+ $this->setFlags($this->extractFlags($flags));
}
/**
- * Determine if the account control contains the given UAC flag(s).
- *
- * @param int $flag
- *
- * @return bool
+ * Determine if the account control contains the given flag(s).
*/
- public function has($flag)
+ public function hasFlag(int $flag): bool
{
// Here we will extract the given flag into an array
// of possible flags. This will allow us to see if
// our AccountControl object contains any of them.
$flagsUsed = array_intersect(
$this->extractFlags($flag),
- $this->values
+ $this->flags
);
return in_array($flag, $flagsUsed);
}
/**
- * Determine if the account control does not contain the given UAC flag(s).
- *
- * @param int $flag
- *
- * @return bool
+ * Determine if the account control does not contain the given flag(s).
*/
- public function doesntHave($flag)
+ public function doesntHaveFlag(int $flag): bool
{
- return ! $this->has($flag);
+ return ! $this->hasFlag($flag);
}
/**
* Generate an LDAP filter based on the current value.
- *
- * @return string
*/
- public function filter()
+ public function filter(): string
{
- return sprintf('(UserAccountControl:1.2.840.113556.1.4.803:=%s)', $this->getValue());
+ return sprintf('(UserAccountControl:1.2.840.113556.1.4.803:=%s)', $this);
}
/**
* The logon script will be run.
- *
- * @return $this
*/
- public function runLoginScript()
+ public function setRunLoginScript(): static
{
- return $this->add(static::SCRIPT);
+ return $this->setFlag(static::SCRIPT);
}
/**
* The user account is locked.
- *
- * @return $this
*/
- public function accountIsLocked()
+ public function setAccountIsLocked(): static
{
- return $this->add(static::LOCKOUT);
+ return $this->setFlag(static::LOCKOUT);
}
/**
* The user account is disabled.
- *
- * @return $this
*/
- public function accountIsDisabled()
+ public function setAccountIsDisabled(): static
{
- return $this->add(static::ACCOUNTDISABLE);
+ return $this->setFlag(static::ACCOUNTDISABLE);
}
/**
@@ -208,117 +175,95 @@
*
* This account provides user access to this domain, but not to any domain that
* trusts this domain. This is sometimes referred to as a local user account.
- *
- * @return $this
*/
- public function accountIsTemporary()
+ public function setAccountIsTemporary(): static
{
- return $this->add(static::TEMP_DUPLICATE_ACCOUNT);
+ return $this->setFlag(static::TEMP_DUPLICATE_ACCOUNT);
}
/**
* This is a default account type that represents a typical user.
- *
- * @return $this
*/
- public function accountIsNormal()
+ public function setAccountIsNormal(): static
{
- return $this->add(static::NORMAL_ACCOUNT);
+ return $this->setFlag(static::NORMAL_ACCOUNT);
}
/**
* This is a permit to trust an account for a system domain that trusts other domains.
- *
- * @return $this
*/
- public function accountIsForInterdomain()
+ public function setAccountIsForInterdomain(): static
{
- return $this->add(static::INTERDOMAIN_TRUST_ACCOUNT);
+ return $this->setFlag(static::INTERDOMAIN_TRUST_ACCOUNT);
}
/**
* This is a computer account for a computer that is running Microsoft
* Windows NT 4.0 Workstation, Microsoft Windows NT 4.0 Server, Microsoft
* Windows 2000 Professional, or Windows 2000 Server and is a member of this domain.
- *
- * @return $this
*/
- public function accountIsForWorkstation()
+ public function setAccountIsForWorkstation(): static
{
- return $this->add(static::WORKSTATION_TRUST_ACCOUNT);
+ return $this->setFlag(static::WORKSTATION_TRUST_ACCOUNT);
}
/**
* This is a computer account for a domain controller that is a member of this domain.
- *
- * @return $this
*/
- public function accountIsForServer()
+ public function setAccountIsForServer(): static
{
- return $this->add(static::SERVER_TRUST_ACCOUNT);
+ return $this->setFlag(static::SERVER_TRUST_ACCOUNT);
}
/**
* This is an MNS logon account.
- *
- * @return $this
*/
- public function accountIsMnsLogon()
+ public function setAccountIsMnsLogon(): static
{
- return $this->add(static::MNS_LOGON_ACCOUNT);
+ return $this->setFlag(static::MNS_LOGON_ACCOUNT);
}
/**
* (Windows 2000/Windows Server 2003) This account does
* not require Kerberos pre-authentication for logging on.
- *
- * @return $this
*/
- public function accountDoesNotRequirePreAuth()
+ public function setAccountDoesNotRequirePreAuth(): static
{
- return $this->add(static::DONT_REQ_PREAUTH);
+ return $this->setFlag(static::DONT_REQ_PREAUTH);
}
/**
* When this flag is set, it forces the user to log on by using a smart card.
- *
- * @return $this
*/
- public function accountRequiresSmartCard()
+ public function setAccountRequiresSmartCard(): static
{
- return $this->add(static::SMARTCARD_REQUIRED);
+ return $this->setFlag(static::SMARTCARD_REQUIRED);
}
/**
* (Windows Server 2008/Windows Server 2008 R2) The account is a read-only domain controller (RODC).
*
* This is a security-sensitive setting. Removing this setting from an RODC compromises security on that server.
- *
- * @return $this
*/
- public function accountIsReadOnly()
+ public function setAccountIsReadOnly(): static
{
- return $this->add(static::PARTIAL_SECRETS_ACCOUNT);
+ return $this->setFlag(static::PARTIAL_SECRETS_ACCOUNT);
}
/**
* The home folder is required.
- *
- * @return $this
*/
- public function homeFolderIsRequired()
+ public function setHomeFolderIsRequired(): static
{
- return $this->add(static::HOMEDIR_REQUIRED);
+ return $this->setFlag(static::HOMEDIR_REQUIRED);
}
/**
* No password is required.
- *
- * @return $this
*/
- public function passwordIsNotRequired()
+ public function setPasswordIsNotRequired(): static
{
- return $this->add(static::PASSWD_NOTREQD);
+ return $this->setFlag(static::PASSWD_NOTREQD);
}
/**
@@ -327,42 +272,34 @@
* For information about how to programmatically set this permission, visit the following link:
*
* @see http://msdn2.microsoft.com/en-us/library/aa746398.aspx
- *
- * @return $this
*/
- public function passwordCannotBeChanged()
+ public function setPasswordCannotBeChanged(): static
{
- return $this->add(static::PASSWD_CANT_CHANGE);
+ return $this->setFlag(static::PASSWD_CANT_CHANGE);
}
/**
* Represents the password, which should never expire on the account.
- *
- * @return $this
*/
- public function passwordDoesNotExpire()
+ public function setPasswordDoesNotExpire(): static
{
- return $this->add(static::DONT_EXPIRE_PASSWORD);
+ return $this->setFlag(static::DONT_EXPIRE_PASSWORD);
}
/**
* (Windows 2000/Windows Server 2003) The user's password has expired.
- *
- * @return $this
*/
- public function passwordIsExpired()
+ public function setPasswordIsExpired(): static
{
- return $this->add(static::PASSWORD_EXPIRED);
+ return $this->setFlag(static::PASSWORD_EXPIRED);
}
/**
* The user can send an encrypted password.
- *
- * @return $this
*/
- public function allowEncryptedTextPassword()
+ public function setAllowEncryptedTextPassword(): static
{
- return $this->add(static::ENCRYPTED_TEXT_PWD_ALLOWED);
+ return $this->setFlag(static::ENCRYPTED_TEXT_PWD_ALLOWED);
}
/**
@@ -373,12 +310,10 @@
*
* To enable a service for Kerberos delegation, you must set this
* flag on the userAccountControl property of the service account.
- *
- * @return $this
*/
- public function trustForDelegation()
+ public function setTrustForDelegation(): static
{
- return $this->add(static::TRUSTED_FOR_DELEGATION);
+ return $this->setFlag(static::TRUSTED_FOR_DELEGATION);
}
/**
@@ -388,44 +323,36 @@
* should be tightly controlled. This setting lets a service that runs under the
* account assume a client's identity and authenticate as that user to other remote
* servers on the network.
- *
- * @return $this
*/
- public function trustToAuthForDelegation()
+ public function setTrustToAuthForDelegation(): static
{
- return $this->add(static::TRUSTED_TO_AUTH_FOR_DELEGATION);
+ return $this->setFlag(static::TRUSTED_TO_AUTH_FOR_DELEGATION);
}
/**
* When this flag is set, the security context of the user is not delegated to a
* service even if the service account is set as trusted for Kerberos delegation.
- *
- * @return $this
*/
- public function doNotTrustForDelegation()
+ public function setDoNotTrustForDelegation(): static
{
- return $this->add(static::NOT_DELEGATED);
+ return $this->setFlag(static::NOT_DELEGATED);
}
/**
* (Windows 2000/Windows Server 2003) Restrict this principal to
* use only Data Encryption Standard (DES) encryption types for keys.
- *
- * @return $this
*/
- public function useDesKeyOnly()
+ public function setUseDesKeyOnly(): static
{
- return $this->add(static::USE_DES_KEY_ONLY);
+ return $this->setFlag(static::USE_DES_KEY_ONLY);
}
/**
* Get the account control value.
- *
- * @return int
*/
- public function getValue()
+ public function getValue(): int
{
- return array_sum($this->values);
+ return array_sum($this->flags);
}
/**
@@ -433,66 +360,56 @@
*
* @return array<int, int>
*/
- public function getValues()
+ public function getFlags(): array
{
- return $this->values;
+ return $this->flags;
}
/**
* Set the account control values.
*
- * @param array<int, int> $flags
- *
- * @return void
+ * @param array<int, int> $flags
*/
- public function setValues(array $flags)
+ public function setFlags(array $flags): void
{
- $this->values = $flags;
+ $this->flags = $flags;
}
/**
* Get all flags that are currently applied to the value.
- *
- * @return array
*/
- public function getAppliedFlags()
+ public function getAppliedFlags(): array
{
$flags = $this->getAllFlags();
- $exists = [];
+ $applied = [];
foreach ($flags as $name => $flag) {
- if ($this->has($flag)) {
- $exists[$name] = $flag;
+ if ($this->hasFlag($flag)) {
+ $applied[$name] = $flag;
}
}
- return $exists;
+ return $applied;
}
/**
* Get all possible account control flags.
- *
- * @return array
*/
- public function getAllFlags()
+ public function getAllFlags(): array
{
return (new ReflectionClass(__CLASS__))->getConstants();
}
/**
* Extracts the given flag into an array of flags used.
- *
- * @param int $flag
- *
- * @return array
*/
- public function extractFlags($flag)
+ protected function extractFlags(int $flag): array
{
$flags = [];
for ($i = 0; $i <= 26; $i++) {
- if ((int) $flag & (1 << $i)) {
+ if ($flag & (1 << $i)) {
$flags[1 << $i] = 1 << $i;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php
index c6977a8..0939109 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedName.php
@@ -4,94 +4,69 @@
use LdapRecord\EscapesValues;
use LdapRecord\Support\Arr;
+use Stringable;
-class DistinguishedName
+class DistinguishedName implements Stringable
{
use EscapesValues;
/**
- * The underlying raw value.
- *
- * @var string
+ * The underlying raw distinguished name value.
*/
- protected $value;
+ protected string $value;
/**
* Constructor.
- *
- * @param string|null $value
*/
- public function __construct($value = null)
+ public function __construct(?string $value = null)
{
$this->value = trim((string) $value);
}
/**
* Get the distinguished name value.
- *
- * @return string
*/
- public function __toString()
+ public function __toString(): string
{
- return (string) $this->value;
+ return $this->value;
}
/**
* Alias of the "build" method.
- *
- * @param string|null $value
- *
- * @return DistinguishedNameBuilder
*/
- public static function of($value = null)
+ public static function of(?string $value = null): DistinguishedNameBuilder
{
return static::build($value);
}
/**
* Get a new DN builder object from the given DN.
- *
- * @param string|null $value
- *
- * @return DistinguishedNameBuilder
*/
- public static function build($value = null)
+ public static function build(?string $value = null): DistinguishedNameBuilder
{
return new DistinguishedNameBuilder($value);
}
/**
* Make a new distinguished name instance.
- *
- * @param string|null $value
- *
- * @return static
*/
- public static function make($value = null)
+ public static function make(?string $value = null): static
{
return new static($value);
}
/**
* Determine if the given value is a valid distinguished name.
- *
- * @param string $value
- *
- * @return bool
*/
- public static function isValid($value)
+ public static function isValid(?string $value = null): bool
{
return ! static::make($value)->isEmpty();
}
/**
* Explode a distinguished name into relative distinguished names.
- *
- * @param string $dn
- *
- * @return array
*/
- public static function explode($dn)
+ public static function explode(string $dn): array
{
$components = ldap_explode_dn($dn, (int) $withoutAttributes = false);
@@ -109,61 +84,33 @@
}
/**
- * Un-escapes a hexadecimal string into its original string representation.
- *
- * @param string $value
- *
- * @return string
- */
- public static function unescape($value)
- {
- return preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', function ($matches) {
- return chr(hexdec($matches[1]));
- }, $value);
- }
-
- /**
* Explode the RDN into an attribute and value.
- *
- * @param string $rdn
- *
- * @return array
*/
- public static function explodeRdn($rdn)
+ public static function explodeRdn(string $rdn): array
{
return explode('=', $rdn, $limit = 2);
}
/**
* Implode the component attribute and value into an RDN.
- *
- * @param string $rdn
- *
- * @return string
*/
- public static function makeRdn(array $component)
+ public static function makeRdn(array $component): string
{
return implode('=', $component);
}
/**
* Get the underlying value.
- *
- * @return string|null
*/
- public function get()
+ public function get(): ?string
{
return $this->value;
}
/**
* Set the underlying value.
- *
- * @param string|null $value
- *
- * @return $this
*/
- public function set($value)
+ public function set(?string $value = null): static
{
$this->value = $value;
@@ -172,15 +119,13 @@
/**
* Get the distinguished name values without attributes.
- *
- * @return array
*/
- public function values()
+ public function values(): array
{
$values = [];
foreach ($this->multi() as [, $value]) {
- $values[] = static::unescape($value);
+ $values[] = EscapedValue::unescape($value);
}
return $values;
@@ -188,10 +133,8 @@
/**
* Get the distinguished name attributes without values.
- *
- * @return array
*/
- public function attributes()
+ public function attributes(): array
{
$attributes = [];
@@ -204,10 +147,8 @@
/**
* Get the distinguished name components with attributes.
- *
- * @return array
*/
- public function components()
+ public function components(): array
{
$components = [];
@@ -216,7 +157,7 @@
// escaped. This cannot be opted out of. Here we will unescape
// the attribute value, then re-escape it to its original
// representation from the server using the "dn" flag.
- $value = $this->escape(static::unescape($value))->dn();
+ $value = $this->escape(EscapedValue::unescape($value))->forDn();
$components[] = static::makeRdn([$attribute, $value]);
}
@@ -226,10 +167,8 @@
/**
* Convert the distinguished name into an associative array.
- *
- * @return array
*/
- public function assoc()
+ public function assoc(): array
{
$map = [];
@@ -246,52 +185,40 @@
/**
* Split the RDNs into a multi-dimensional array.
- *
- * @return array
*/
- public function multi()
+ public function multi(): array
{
- return array_map(function ($rdn) {
- return static::explodeRdn($rdn);
- }, $this->rdns());
+ return array_map(fn ($rdn) => static::explodeRdn($rdn), $this->rdns());
}
/**
* Split the distinguished name into an array of unescaped RDN's.
- *
- * @return array
*/
- public function rdns()
+ public function rdns(): array
{
return static::explode($this->value);
}
/**
* Get the first RDNs value.
- *
- * @return string|null
*/
- public function name()
+ public function name(): ?string
{
return Arr::first($this->values());
}
/**
* Get the first RDNs attribute.
- *
- * @return string|null
*/
- public function head()
+ public function head(): ?string
{
return Arr::first($this->attributes());
}
/**
* Get the relative distinguished name.
- *
- * @return string|null
*/
- public function relative()
+ public function relative(): ?string
{
return Arr::first($this->components());
}
@@ -300,20 +227,16 @@
* Alias of relative().
*
* Get the first RDN from the distinguished name.
- *
- * @return string|null
*/
- public function first()
+ public function first(): ?string
{
return $this->relative();
}
/**
* Get the parent distinguished name.
- *
- * @return string|null
*/
- public function parent()
+ public function parent(): ?string
{
$components = $this->components();
@@ -324,119 +247,91 @@
/**
* Determine if the distinguished name is empty.
- *
- * @return bool
*/
- public function isEmpty()
+ public function isEmpty(): bool
{
return empty(
- array_filter($this->values())
+ array_filter(
+ array_map('trim', $this->values())
+ )
);
}
/**
- * Determine if the current distinguished name is a parent of the given child.
- *
- * @param DistinguishedName $child
- *
- * @return bool
+ * Determine if the distinguished name is not empty.
*/
- public function isParentOf(self $child)
+ public function isNotEmpty(): bool
+ {
+ return ! $this->isEmpty();
+ }
+
+ /**
+ * Determine if the current distinguished name is a parent of the given child.
+ */
+ public function isParentOf(self $child): bool
{
return $child->isChildOf($this);
}
/**
* Determine if the current distinguished name is a child of the given parent.
- *
- * @param DistinguishedName $parent
- *
- * @return bool
*/
- public function isChildOf(self $parent)
+ public function isChildOf(self $parent): bool
{
- if (
- empty($components = $this->components()) ||
- empty($parentComponents = $parent->components())
- ) {
+ if (! $this->isComparable($this->parent(), $parent->get())) {
return false;
}
- array_shift($components);
-
- return $this->compare($components, $parentComponents);
+ return $this->normalize($this->parent()) === $this->normalize($parent->get());
}
/**
* Determine if the current distinguished name is an ancestor of the descendant.
- *
- * @param DistinguishedName $descendant
- *
- * @return bool
*/
- public function isAncestorOf(self $descendant)
+ public function isAncestorOf(self $descendant): bool
{
return $descendant->isDescendantOf($this);
}
/**
* Determine if the current distinguished name is a descendant of the ancestor.
- *
- * @param DistinguishedName $ancestor
- *
- * @return bool
*/
- public function isDescendantOf(self $ancestor)
+ public function isDescendantOf(self $ancestor): bool
{
- if (
- empty($components = $this->components()) ||
- empty($ancestorComponents = $ancestor->components())
- ) {
+ if (! $this->isComparable($this->parent(), $ancestor->get())) {
return false;
}
- if (! $length = count($components) - count($ancestorComponents)) {
+ return str_ends_with(
+ $this->normalize($this->parent()),
+ $this->normalize($ancestor->get())
+ );
+ }
+
+ /**
+ * Determine if the current distinguished name is a sibling of the given distinguished name.
+ */
+ public function isSiblingOf(self $sibling): bool
+ {
+ if (! $this->isComparable($this->parent(), $sibling->parent())) {
return false;
}
- array_splice($components, $offset = 0, $length);
-
- return $this->compare($components, $ancestorComponents);
+ return $this->normalize($this->parent()) === $this->normalize($sibling->parent());
}
/**
- * Compare whether the two distinguished name values are equal.
- *
- * @param array $values
- * @param array $other
- *
- * @return bool
+ * Determine if the distinguished names are comparable.
*/
- protected function compare(array $values, array $other)
+ protected function isComparable(?string $first, ?string $second): bool
{
- return $this->recase($values) == $this->recase($other);
- }
-
- /**
- * Recase the array values.
- *
- * @param array $values
- *
- * @return array
- */
- protected function recase(array $values)
- {
- return array_map([$this, 'normalize'], $values);
+ return static::make($first)->isNotEmpty() && static::make($second)->isNotEmpty();
}
/**
* Normalize the string value.
- *
- * @param string $value
- *
- * @return string
*/
- protected function normalize($value)
+ protected function normalize(string $value): string
{
return strtolower($value);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php
index 601902b..7345cb9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/DistinguishedNameBuilder.php
@@ -4,69 +4,53 @@
use LdapRecord\EscapesValues;
use LdapRecord\Support\Arr;
+use Stringable;
-class DistinguishedNameBuilder
+class DistinguishedNameBuilder implements Stringable
{
use EscapesValues;
/**
* The components of the DN.
- *
- * @var array
*/
- protected $components = [];
+ protected array $components = [];
/**
* Whether to output the DN in reverse.
- *
- * @var bool
*/
- protected $reverse = false;
+ protected bool $reverse = false;
/**
* Constructor.
- *
- * @param string|null $value
*/
public function __construct($dn = null)
{
- $this->components = array_map(function ($rdn) {
- return DistinguishedName::explodeRdn($rdn);
- }, DistinguishedName::make($dn)->components());
+ $this->components = array_map(
+ fn ($rdn) => DistinguishedName::explodeRdn($rdn),
+ DistinguishedName::make($dn)->components()
+ );
}
/**
* Forward missing method calls onto the Distinguished Name object.
- *
- * @param string $method
- * @param array $args
- *
- * @return mixed
*/
- public function __call($method, $args)
+ public function __call(string $method, array $args): mixed
{
return $this->get()->{$method}(...$args);
}
/**
* Get the distinguished name value.
- *
- * @return string
*/
- public function __toString()
+ public function __toString(): string
{
return (string) $this->get();
}
/**
* Prepend an RDN onto the DN.
- *
- * @param string|array $attribute
- * @param string|null $value
- *
- * @return $this
*/
- public function prepend($attribute, $value = null)
+ public function prepend(array|string $attribute, ?string $value = null): static
{
array_unshift(
$this->components,
@@ -78,13 +62,8 @@
/**
* Append an RDN onto the DN.
- *
- * @param string|array $attribute
- * @param string|null $value
- *
- * @return $this
*/
- public function append($attribute, $value = null)
+ public function append(array|string $attribute, ?string $value = null): static
{
array_push(
$this->components,
@@ -96,13 +75,8 @@
/**
* Componentize the attribute and value.
- *
- * @param string|array $attribute
- * @param string|null $value
- *
- * @return array
*/
- protected function componentize($attribute, $value = null)
+ protected function componentize(array|string $attribute, ?string $value = null): array
{
// Here we will make the assumption that an array of
// RDN's have been given if the value is null, and
@@ -124,69 +98,50 @@
/**
* Make a componentized array by exploding the value if it's a string.
- *
- * @param string $value
- *
- * @return array
*/
- protected function makeComponentizedArray($value)
+ protected function makeComponentizedArray(array|string $value): array
{
return is_array($value) ? $value : DistinguishedName::explodeRdn($value);
}
/**
* Make an appendable component array from the attribute and value.
- *
- * @param string|array $attribute
- * @param string|null $value
- *
- * @return array
*/
- protected function makeAppendableComponent($attribute, $value = null)
+ protected function makeAppendableComponent(string|array $attribute, ?string $value = null): array
{
- return [trim($attribute), $this->escape(trim($value))->dn()];
+ return [trim($attribute), $this->escape(trim($value))->forDn()];
}
/**
* Pop an RDN off of the end of the DN.
- *
- * @param int $amount
- * @param array $removed
- *
- * @return $this
*/
- public function pop($amount = 1, &$removed = [])
+ public function pop(int $amount = 1, ?array &$removed = null): static
{
- $removed = array_map(function ($component) {
- return DistinguishedName::makeRdn($component);
- }, array_splice($this->components, -$amount, $amount));
+ $removed = array_map(
+ fn ($component) => DistinguishedName::makeRdn($component),
+ array_splice($this->components, -$amount, $amount)
+ );
return $this;
}
/**
* Shift an RDN off of the beginning of the DN.
- *
- * @param int $amount
- * @param array $removed
- *
- * @return $this
*/
- public function shift($amount = 1, &$removed = [])
+ public function shift(int $amount = 1, ?array &$removed = null): static
{
- $removed = array_map(function ($component) {
- return DistinguishedName::makeRdn($component);
- }, array_splice($this->components, 0, $amount));
+ $removed = array_map(
+ fn ($component) => DistinguishedName::makeRdn($component),
+ array_splice($this->components, 0, $amount)
+ );
return $this;
}
/**
* Whether to output the DN in reverse.
- *
- * @return $this
*/
- public function reverse()
+ public function reverse(): static
{
$this->reverse = true;
@@ -195,12 +150,8 @@
/**
* Get the components of the DN.
- *
- * @param null|string $type
- *
- * @return array
*/
- public function components($type = null)
+ public function components(?string $type = null): array
{
return is_null($type)
? $this->components
@@ -209,43 +160,36 @@
/**
* Get the components of a particular type.
- *
- * @param string $type
- *
- * @return array
*/
- protected function componentsOfType($type)
+ protected function componentsOfType(string $type): array
{
- $components = array_filter($this->components, function ($component) use ($type) {
- return ([$name] = $component) && strtolower($name) === strtolower($type);
- });
+ $components = array_filter($this->components, fn ($component) => (
+ ([$name] = $component) && strtolower($name) === strtolower($type)
+ ));
return array_values($components);
}
/**
* Get the fully qualified DN.
- *
- * @return DistinguishedName
*/
- public function get()
+ public function get(): DistinguishedName
{
return new DistinguishedName($this->build());
}
/**
* Build the distinguished name from the components.
- *
- * @return string
*/
- protected function build()
+ protected function build(): string
{
$components = $this->reverse
? array_reverse($this->components)
: $this->components;
- return implode(',', array_map(function ($component) {
- return DistinguishedName::makeRdn($component);
- }, $components));
+ return implode(',', array_map(
+ fn ($component) => DistinguishedName::makeRdn($component),
+ $components
+ ));
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php
index 2f61112..c28d95c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/EscapedValue.php
@@ -2,81 +2,75 @@
namespace LdapRecord\Models\Attributes;
-class EscapedValue
+use Stringable;
+
+class EscapedValue implements Stringable
{
/**
* The value to be escaped.
- *
- * @var string
*/
- protected $value;
+ protected mixed $value;
/**
* The characters to ignore when escaping.
- *
- * @var string
*/
- protected $ignore;
+ protected string $ignore;
/**
* The escape flags.
- *
- * @var int
*/
- protected $flags;
+ protected int $flags;
/**
* Constructor.
- *
- * @param string $value
- * @param string $ignore
- * @param int $flags
*/
- public function __construct($value, $ignore = '', $flags = 0)
+ public function __construct(mixed $value, string $ignore = '', int $flags = 0)
{
- $this->value = (string) $value;
+ $this->value = $value;
$this->ignore = $ignore;
$this->flags = $flags;
}
/**
- * Get the escaped value.
- *
- * @return string
+ * Un-escapes a hexadecimal string into its original string representation.
*/
- public function __toString()
+ public static function unescape(string $value): string
{
- return (string) $this->get();
+ return preg_replace_callback(
+ '/\\\([0-9A-Fa-f]{2})/',
+ fn ($matches) => chr(hexdec($matches[1])),
+ $value
+ );
}
/**
* Get the escaped value.
- *
- * @return mixed
*/
- public function get()
+ public function __toString(): string
{
- return ldap_escape($this->value, $this->ignore, $this->flags);
+ return $this->get();
+ }
+
+ /**
+ * Get the escaped value.
+ */
+ public function get(): string
+ {
+ return ldap_escape((string) $this->value, $this->ignore, $this->flags);
}
/**
* Get the raw (unescaped) value.
- *
- * @return mixed
*/
- public function raw()
+ public function getRaw(): mixed
{
return $this->value;
}
/**
* Set the characters to exclude from being escaped.
- *
- * @param string $characters
- *
- * @return $this
*/
- public function ignore($characters)
+ public function ignore(string $characters): static
{
$this->ignore = $characters;
@@ -85,10 +79,8 @@
/**
* Prepare the value to be escaped for use in a distinguished name.
- *
- * @return $this
*/
- public function dn()
+ public function forDn(): static
{
$this->flags = LDAP_ESCAPE_DN;
@@ -97,10 +89,8 @@
/**
* Prepare the value to be escaped for use in a filter.
- *
- * @return $this
*/
- public function filter()
+ public function forFilter(): static
{
$this->flags = LDAP_ESCAPE_FILTER;
@@ -109,10 +99,8 @@
/**
* Prepare the value to be escaped for use in a distinguished name and filter.
- *
- * @return $this
*/
- public function both()
+ public function forDnAndFilter(): static
{
$this->flags = LDAP_ESCAPE_FILTER + LDAP_ESCAPE_DN;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Guid.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Guid.php
index d139f5f..dfde164 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Guid.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Guid.php
@@ -3,33 +3,14 @@
namespace LdapRecord\Models\Attributes;
use InvalidArgumentException;
-use LdapRecord\Utilities;
+use Stringable;
-class Guid
+class Guid implements Stringable
{
/**
* The string GUID value.
- *
- * @var string
*/
- protected $value;
-
- /**
- * The guid structure in order by section to parse using substr().
- *
- * @author Chad Sikorra <Chad.Sikorra@gmail.com>
- *
- * @see https://github.com/ldaptools/ldaptools
- *
- * @var array
- */
- protected $guidSections = [
- [[-26, 2], [-28, 2], [-30, 2], [-32, 2]],
- [[-22, 2], [-24, 2]],
- [[-18, 2], [-20, 2]],
- [[-16, 4]],
- [[-12, 12]],
- ];
+ protected ?string $value = null;
/**
* The hexadecimal octet order based on string position.
@@ -37,10 +18,8 @@
* @author Chad Sikorra <Chad.Sikorra@gmail.com>
*
* @see https://github.com/ldaptools/ldaptools
- *
- * @var array
*/
- protected $octetSections = [
+ protected array $octetSections = [
[6, 4, 2, 0],
[10, 8],
[14, 12],
@@ -48,25 +27,19 @@
];
/**
- * Determines if the specified GUID is valid.
- *
- * @param string $guid
- *
- * @return bool
+ * Determine if the specified GUID is valid.
*/
- public static function isValid($guid)
+ public static function isValid(string $guid): bool
{
- return Utilities::isValidGuid($guid);
+ return (bool) preg_match('/^([0-9a-fA-F]){8}(-([0-9a-fA-F]){4}){3}-([0-9a-fA-F]){12}$/', $guid);
}
/**
* Constructor.
*
- * @param mixed $value
- *
* @throws InvalidArgumentException
*/
- public function __construct($value)
+ public function __construct(string $value)
{
if (static::isValid($value)) {
$this->value = $value;
@@ -78,79 +51,94 @@
}
/**
- * Returns the string value of the GUID.
- *
- * @return string
+ * Get the string value of the GUID.
*/
- public function __toString()
+ public function __toString(): string
{
return $this->getValue();
}
/**
- * Returns the string value of the SID.
- *
- * @return string
+ * Get the string value of the GUID.
*/
- public function getValue()
+ public function getValue(): string
{
return $this->value;
}
/**
* Get the binary representation of the GUID string.
- *
- * @return string
*/
- public function getBinary()
+ public function getBinary(): string
{
return hex2bin($this->getHex());
}
/**
- * Get the hexadecimal representation of the GUID string.
- *
- * @return string
+ * Get the encoded hexadecimal representation of the GUID string.
*/
- public function getHex()
+ public function getEncodedHex(): string
{
- $data = '';
+ return '\\'.implode('\\', str_split($this->getHex(), 2));
+ }
+
+ /**
+ * Get the hexadecimal representation of the GUID string.
+ */
+ public function getHex(): string
+ {
+ return implode($this->getOctetSections());
+ }
+
+ /**
+ * Get the octect sections of the GUID.
+ */
+ protected function getOctetSections(): array
+ {
+ $sections = [];
$guid = str_replace('-', '', $this->value);
foreach ($this->octetSections as $section) {
- $data .= $this->parseSection($guid, $section, $octet = true);
+ $sections[] = $this->parseSection($guid, $section, true);
}
- return $data;
+ return $sections;
}
/**
- * Returns the string variant of a binary GUID.
- *
- * @param string $binary
- *
- * @return string|null
+ * Get the string variant of a binary GUID.
*/
- protected function binaryGuidToString($binary)
+ protected function binaryGuidToString(string $binary): ?string
{
- return Utilities::binaryGuidToString($binary);
+ if (trim($binary) === '') {
+ return null;
+ }
+
+ $hex = unpack('H*hex', $binary)['hex'];
+
+ $hex1 = substr($hex, -26, 2).substr($hex, -28, 2).substr($hex, -30, 2).substr($hex, -32, 2);
+ $hex2 = substr($hex, -22, 2).substr($hex, -24, 2);
+ $hex3 = substr($hex, -18, 2).substr($hex, -20, 2);
+ $hex4 = substr($hex, -16, 4);
+ $hex5 = substr($hex, -12, 12);
+
+ return sprintf('%s-%s-%s-%s-%s', $hex1, $hex2, $hex3, $hex4, $hex5);
}
/**
- * Return the specified section of the hexadecimal string.
+ * Get the specified section of the hexadecimal string.
*
* @author Chad Sikorra <Chad.Sikorra@gmail.com>
*
* @see https://github.com/ldaptools/ldaptools
*
- * @param string $hex The full hex string.
- * @param array $sections An array of start and length (unless octet is true, then length is always 2).
- * @param bool $octet Whether this is for octet string form.
- *
+ * @param string $hex The full hex string.
+ * @param array $sections An array of start and length (unless octet is true, then length is always 2).
+ * @param bool $octet Whether this is for octet string form.
* @return string The concatenated sections in upper-case.
*/
- protected function parseSection($hex, array $sections, $octet = false)
+ protected function parseSection(string $hex, array $sections, bool $octet = false): string
{
$parsedString = '';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/MbString.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/MbString.php
index 672e60d..c6eb498 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/MbString.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/MbString.php
@@ -6,12 +6,8 @@
{
/**
* Get the integer value of a specific character.
- *
- * @param $string
- *
- * @return int
*/
- public static function ord($string)
+ public static function ord(string $string): int
{
if (static::isLoaded()) {
$result = unpack('N', mb_convert_encoding($string, 'UCS-4BE', 'UTF-8'));
@@ -26,12 +22,8 @@
/**
* Get the character for a specific integer value.
- *
- * @param $int
- *
- * @return string
*/
- public static function chr($int)
+ public static function chr(int $int): string
{
if (static::isLoaded()) {
return mb_convert_encoding(pack('n', $int), 'UTF-8', 'UTF-16BE');
@@ -42,38 +34,28 @@
/**
* Split a string into its individual characters and return it as an array.
- *
- * @param string $value
- *
- * @return string[]
*/
- public static function split($value)
+ public static function split(string $value): array
{
return preg_split('/(?<!^)(?!$)/u', $value);
}
/**
* Detects if the given string is UTF 8.
- *
- * @param $string
- *
- * @return string|false
*/
- public static function isUtf8($string)
+ public static function isUtf8(string $string): bool
{
if (static::isLoaded()) {
- return mb_detect_encoding($string, 'UTF-8', $strict = true);
+ return mb_detect_encoding($string, 'UTF-8', true) === 'UTF-8';
}
- return $string;
+ return false;
}
/**
* Checks if the mbstring extension is enabled in PHP.
- *
- * @return bool
*/
- public static function isLoaded()
+ public static function isLoaded(): bool
{
return extension_loaded('mbstring');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php
index 644f0a8..71f4d06 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Password.php
@@ -8,197 +8,136 @@
class Password
{
- const CRYPT_SALT_TYPE_MD5 = 1;
- const CRYPT_SALT_TYPE_SHA256 = 5;
- const CRYPT_SALT_TYPE_SHA512 = 6;
+ public const CRYPT_SALT_TYPE_MD5 = 1;
+
+ public const CRYPT_SALT_TYPE_SHA256 = 5;
+
+ public const CRYPT_SALT_TYPE_SHA512 = 6;
/**
* Make an encoded password for transmission over LDAP.
- *
- * @param string $password
- *
- * @return string
*/
- public static function encode($password)
+ public static function encode(string $password): string
{
return iconv('UTF-8', 'UTF-16LE', '"'.$password.'"');
}
/**
* Make a salted md5 password.
- *
- * @param string $password
- * @param null|string $salt
- *
- * @return string
*/
- public static function smd5($password, $salt = null)
+ public static function smd5(string $password, ?string $salt = null): string
{
return '{SMD5}'.static::makeHash($password, 'md5', null, $salt ?? random_bytes(4));
}
/**
* Make a salted SHA password.
- *
- * @param string $password
- * @param null|string $salt
- *
- * @return string
*/
- public static function ssha($password, $salt = null)
+ public static function ssha(string $password, ?string $salt = null): string
{
return '{SSHA}'.static::makeHash($password, 'sha1', null, $salt ?? random_bytes(4));
}
/**
* Make a salted SSHA256 password.
- *
- * @param string $password
- * @param null|string $salt
- *
- * @return string
*/
- public static function ssha256($password, $salt = null)
+ public static function ssha256(string $password, ?string $salt = null): string
{
return '{SSHA256}'.static::makeHash($password, 'hash', 'sha256', $salt ?? random_bytes(4));
}
/**
* Make a salted SSHA384 password.
- *
- * @param string $password
- * @param null|string $salt
- *
- * @return string
*/
- public static function ssha384($password, $salt = null)
+ public static function ssha384(string $password, ?string $salt = null): string
{
return '{SSHA384}'.static::makeHash($password, 'hash', 'sha384', $salt ?? random_bytes(4));
}
/**
* Make a salted SSHA512 password.
- *
- * @param string $password
- * @param null|string $salt
- *
- * @return string
*/
- public static function ssha512($password, $salt = null)
+ public static function ssha512(string $password, ?string $salt = null): string
{
return '{SSHA512}'.static::makeHash($password, 'hash', 'sha512', $salt ?? random_bytes(4));
}
/**
* Make a non-salted SHA password.
- *
- * @param string $password
- *
- * @return string
*/
- public static function sha($password)
+ public static function sha(string $password): string
{
return '{SHA}'.static::makeHash($password, 'sha1');
}
/**
* Make a non-salted SHA256 password.
- *
- * @param string $password
- *
- * @return string
*/
- public static function sha256($password)
+ public static function sha256(string $password): string
{
return '{SHA256}'.static::makeHash($password, 'hash', 'sha256');
}
/**
* Make a non-salted SHA384 password.
- *
- * @param string $password
- *
- * @return string
*/
- public static function sha384($password)
+ public static function sha384(string $password): string
{
return '{SHA384}'.static::makeHash($password, 'hash', 'sha384');
}
/**
* Make a non-salted SHA512 password.
- *
- * @param string $password
- *
- * @return string
*/
- public static function sha512($password)
+ public static function sha512(string $password): string
{
return '{SHA512}'.static::makeHash($password, 'hash', 'sha512');
}
/**
* Make a non-salted md5 password.
- *
- * @param string $password
- *
- * @return string
*/
- public static function md5($password)
+ public static function md5(string $password): string
{
return '{MD5}'.static::makeHash($password, 'md5');
}
/**
- * Crypt password with an MD5 salt.
- *
- * @param string $password
- * @param string $salt
- *
- * @return string
+ * Make a non-salted NThash password.
*/
- public static function md5Crypt($password, $salt = null)
+ public static function nthash(string $password): string
+ {
+ return '{NTHASH}'.strtoupper(hash('md4', iconv('UTF-8', 'UTF-16LE', $password)));
+ }
+
+ /**
+ * Crypt password with an MD5 salt.
+ */
+ public static function md5Crypt(string $password, ?string $salt = null): string
{
return '{CRYPT}'.static::makeCrypt($password, static::CRYPT_SALT_TYPE_MD5, $salt);
}
/**
* Crypt password with a SHA256 salt.
- *
- * @param string $password
- * @param string $salt
- *
- * @return string
*/
- public static function sha256Crypt($password, $salt = null)
+ public static function sha256Crypt(string $password, ?string $salt = null): string
{
return '{CRYPT}'.static::makeCrypt($password, static::CRYPT_SALT_TYPE_SHA256, $salt);
}
/**
* Crypt a password with a SHA512 salt.
- *
- * @param string $password
- * @param string $salt
- *
- * @return string
*/
- public static function sha512Crypt($password, $salt = null)
+ public static function sha512Crypt(string $password, ?string $salt = null): string
{
return '{CRYPT}'.static::makeCrypt($password, static::CRYPT_SALT_TYPE_SHA512, $salt);
}
/**
* Make a new password hash.
- *
- * @param string $password The password to make a hash of.
- * @param string $method The hash function to use.
- * @param string|null $algo The algorithm to use for hashing.
- * @param string|null $salt The salt to append onto the hash.
- *
- * @return string
*/
- protected static function makeHash($password, $method, $algo = null, $salt = null)
+ protected static function makeHash(string $password, string $method, ?string $algo = null, ?string $salt = null): string
{
$params = $algo ? [$algo, $password.$salt] : [$password.$salt];
@@ -207,26 +146,16 @@
/**
* Make a hashed password.
- *
- * @param string $password
- * @param int $type
- * @param null|string $salt
- *
- * @return string
*/
- protected static function makeCrypt($password, $type, $salt = null)
+ protected static function makeCrypt(string $password, int $type, ?string $salt = null): string
{
return crypt($password, $salt ?? static::makeCryptSalt($type));
}
/**
* Make a salt for the crypt() method using the given type.
- *
- * @param int $type
- *
- * @return string
*/
- protected static function makeCryptSalt($type)
+ protected static function makeCryptSalt(int $type): string
{
[$prefix, $length] = static::makeCryptPrefixAndLength($type);
@@ -242,37 +171,26 @@
/**
* Determine the crypt prefix and length.
*
- * @param int $type
- *
- * @return array
*
* @throws InvalidArgumentException
*/
- protected static function makeCryptPrefixAndLength($type)
+ protected static function makeCryptPrefixAndLength(int $type): array
{
- switch ($type) {
- case static::CRYPT_SALT_TYPE_MD5:
- return ['$1$', 12];
- case static::CRYPT_SALT_TYPE_SHA256:
- return ['$5$', 16];
- case static::CRYPT_SALT_TYPE_SHA512:
- return ['$6$', 16];
- default:
- throw new InvalidArgumentException("Invalid crypt type [$type].");
- }
+ return match ((int) $type) {
+ static::CRYPT_SALT_TYPE_MD5 => ['$1$', 12],
+ static::CRYPT_SALT_TYPE_SHA256 => ['$5$', 16],
+ static::CRYPT_SALT_TYPE_SHA512 => ['$6$', 16],
+ default => throw new InvalidArgumentException("Invalid crypt type [$type]."),
+ };
}
/**
* Attempt to retrieve the hash method used for the password.
- *
- * @param string $password
- *
- * @return string|void
*/
- public static function getHashMethod($password)
+ public static function getHashMethod(string $password): ?string
{
if (! preg_match('/^\{(\w+)\}/', $password, $matches)) {
- return;
+ return null;
}
return $matches[1];
@@ -280,15 +198,11 @@
/**
* Attempt to retrieve the hash method and algorithm used for the password.
- *
- * @param string $password
- *
- * @return array|void
*/
- public static function getHashMethodAndAlgo($password)
+ public static function getHashMethodAndAlgo(string $password): ?array
{
if (! preg_match('/^\{(\w+)\}\$([0-9a-z]{1})\$/', $password, $matches)) {
- return;
+ return null;
}
return [$matches[1], $matches[2]];
@@ -297,11 +211,9 @@
/**
* Attempt to retrieve a salt from the encrypted password.
*
- * @return string
- *
* @throws LdapRecordException
*/
- public static function getSalt($encryptedPassword)
+ public static function getSalt(string $encryptedPassword): string
{
// crypt() methods.
if (preg_match('/^\{(\w+)\}(\$.*\$).*$/', $encryptedPassword, $matches)) {
@@ -319,13 +231,9 @@
/**
* Determine if the hash method requires a salt to be given.
*
- * @param string $method
- *
- * @return bool
- *
* @throws \ReflectionException
*/
- public static function hashMethodRequiresSalt($method): bool
+ public static function hashMethodRequiresSalt(string $method): bool
{
$parameters = (new ReflectionMethod(static::class, $method))->getParameters();
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Sid.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Sid.php
index 4ec46ea..08c3626 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Sid.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Sid.php
@@ -3,37 +3,29 @@
namespace LdapRecord\Models\Attributes;
use InvalidArgumentException;
-use LdapRecord\Utilities;
+use Stringable;
-class Sid
+class Sid implements Stringable
{
/**
* The string SID value.
- *
- * @var string
*/
- protected $value;
+ protected string $value;
/**
- * Determines if the specified SID is valid.
- *
- * @param string $sid
- *
- * @return bool
+ * Determine if the specified SID is valid.
*/
- public static function isValid($sid)
+ public static function isValid(string $sid): bool
{
- return Utilities::isValidSid($sid);
+ return (bool) preg_match("/^S-\d(-\d{1,10}){1,16}$/i", $sid);
}
/**
* Constructor.
*
- * @param mixed $value
- *
* @throws InvalidArgumentException
*/
- public function __construct($value)
+ public function __construct(string $value)
{
if (static::isValid($value)) {
$this->value = $value;
@@ -45,31 +37,25 @@
}
/**
- * Returns the string value of the SID.
- *
- * @return string
+ * Get the string value of the SID.
*/
- public function __toString()
+ public function __toString(): string
{
return $this->getValue();
}
/**
- * Returns the string value of the SID.
- *
- * @return string
+ * Get the string value of the SID.
*/
- public function getValue()
+ public function getValue(): string
{
return $this->value;
}
/**
- * Returns the binary variant of the SID.
- *
- * @return string
+ * Get the binary variant of the SID.
*/
- public function getBinary()
+ public function getBinary(): string
{
$sid = explode('-', ltrim($this->value, 'S-'));
@@ -88,14 +74,50 @@
}
/**
- * Returns the string variant of a binary SID.
- *
- * @param string $binary
- *
- * @return string|null
+ * Get the string variant of a binary SID.
*/
- protected function binarySidToString($binary)
+ protected function binarySidToString(string $binary): ?string
{
- return Utilities::binarySidToString($binary);
+ if (trim($binary) === '') {
+ return null;
+ }
+
+ // Revision - 8bit unsigned int (C1)
+ // Count - 8bit unsigned int (C1)
+ // 2 null bytes
+ // ID - 32bit unsigned long, big-endian order
+ $sid = @unpack('C1rev/C1count/x2/N1id', $binary);
+
+ if (! isset($sid['id']) || ! isset($sid['rev'])) {
+ return null;
+ }
+
+ $revisionLevel = $sid['rev'];
+
+ $identifierAuthority = $sid['id'];
+
+ $subs = $sid['count'] ?? 0;
+
+ $sidHex = $subs ? bin2hex($binary) : '';
+
+ $subAuthorities = [];
+
+ // The sub-authorities depend on the count, so only get as
+ // many as the count, regardless of data beyond it.
+ for ($i = 0; $i < $subs; $i++) {
+ $data = implode(array_reverse(
+ str_split(
+ substr($sidHex, 16 + ($i * 8), 8),
+ 2
+ )
+ ));
+
+ $subAuthorities[] = hexdec($data);
+ }
+
+ // Tack on the 'S-' and glue it all together...
+ return 'S-'.$revisionLevel.'-'.$identifierAuthority.implode(
+ preg_filter('/^/', '-', $subAuthorities)
+ );
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSProperty.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSProperty.php
index ad56aa1..dd2d0eb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSProperty.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSProperty.php
@@ -7,7 +7,7 @@
/**
* Nibble control values. The first value for each is if the nibble is <= 9, otherwise the second value is used.
*/
- const NIBBLE_CONTROL = [
+ public const NIBBLE_CONTROL = [
'X' => ['001011', '011010'],
'Y' => ['001110', '011010'],
];
@@ -15,12 +15,12 @@
/**
* The nibble header.
*/
- const NIBBLE_HEADER = '1110';
+ public const NIBBLE_HEADER = '1110';
/**
* Conversion factor needed for time values in the TSPropertyArray (stored in microseconds).
*/
- const TIME_CONVERSION = 60 * 1000;
+ public const TIME_CONVERSION = 60 * 1000;
/**
* A simple map to help determine how the property needs to be decoded/encoded from/to its binary value.
@@ -29,10 +29,8 @@
* cannot find any information on them in Microsoft documentation. However, their values appear to stay in sync with
* their non 'W' counterparts. But not doing so when manipulating the data manually does not seem to affect anything.
* This probably needs more investigation.
- *
- * @var array
*/
- protected $propTypes = [
+ protected array $propTypes = [
'string' => [
'CtxWFHomeDir',
'CtxWFHomeDirW',
@@ -63,31 +61,23 @@
/**
* The property name.
- *
- * @var string
*/
- protected $name;
+ protected ?string $name = null;
/**
* The property value.
- *
- * @var string|int
*/
- protected $value;
+ protected string|int|null $value = null;
/**
* The property value type.
- *
- * @var int
*/
- protected $valueType = 1;
+ protected int $valueType = 1;
/**
* Pass binary TSProperty data to construct its object representation.
- *
- * @param string|null $value
*/
- public function __construct($value = null)
+ public function __construct(string|int|null $value = null)
{
if ($value) {
$this->decode(bin2hex($value));
@@ -96,12 +86,8 @@
/**
* Set the name for the TSProperty.
- *
- * @param string $name
- *
- * @return TSProperty
*/
- public function setName($name)
+ public function setName(string $name): static
{
$this->name = $name;
@@ -110,22 +96,16 @@
/**
* Get the name for the TSProperty.
- *
- * @return string
*/
- public function getName()
+ public function getName(): ?string
{
return $this->name;
}
/**
* Set the value for the TSProperty.
- *
- * @param string|int $value
- *
- * @return TSProperty
*/
- public function setValue($value)
+ public function setValue(string|int $value): static
{
$this->value = $value;
@@ -134,10 +114,8 @@
/**
* Get the value for the TSProperty.
- *
- * @return string|int
*/
- public function getValue()
+ public function getValue(): string|int|null
{
return $this->value;
}
@@ -145,10 +123,8 @@
/**
* Convert the TSProperty name/value back to its binary
* representation for the userParameters blob.
- *
- * @return string
*/
- public function toBinary()
+ public function toBinary(): string
{
$name = bin2hex($this->name);
@@ -168,10 +144,8 @@
/**
* Given a TSProperty blob, decode the name/value/type/etc.
- *
- * @param string $tsProperty
*/
- protected function decode($tsProperty)
+ protected function decode(string $tsProperty): void
{
$nameLength = hexdec(substr($tsProperty, 0, 2));
@@ -185,13 +159,8 @@
/**
* Based on the property name/value in question, get its encoded form.
- *
- * @param string $propName
- * @param string|int $propValue
- *
- * @return string
*/
- protected function getEncodedValueForProp($propName, $propValue)
+ protected function getEncodedValueForProp(string $propName, string|int $propValue): string
{
if (in_array($propName, $this->propTypes['string'])) {
// Simple strings are null terminated. Unsure if this is
@@ -209,13 +178,8 @@
/**
* Based on the property name in question, get its actual value from the binary blob value.
- *
- * @param string $propName
- * @param string $propValue
- *
- * @return string|int
*/
- protected function getDecodedValueForProp($propName, $propValue)
+ protected function getDecodedValueForProp(string $propName, string $propValue): string|int
{
if (in_array($propName, $this->propTypes['string'])) {
// Strip away null terminators. I think this should
@@ -238,12 +202,9 @@
* Decode the property by inspecting the nibbles of each blob, checking
* the control, and adding up the results into a final value.
*
- * @param string $hex
- * @param bool $string Whether or not this is simple string data.
- *
- * @return string
+ * @param bool $string Whether this is simple string data.
*/
- protected function decodePropValue($hex, $string = false)
+ protected function decodePropValue(string $hex, bool $string = false): string
{
$decodePropValue = '';
@@ -271,13 +232,8 @@
/**
* Get the encoded property value as a binary blob.
- *
- * @param string $value
- * @param bool $string
- *
- * @return string
*/
- protected function encodePropValue($value, $string = false)
+ protected function encodePropValue(string $value, bool $string = false): string
{
// An int must be properly padded. (then split and reversed).
// For a string, we just split the chars. This seems
@@ -313,13 +269,8 @@
* PHP's pack() function has no 'b' or 'B' template. This is
* a workaround that turns a literal bit-string into a
* packed byte-string with 8 bits per byte.
- *
- * @param string $bits
- * @param bool $len
- *
- * @return string
*/
- protected function packBitString($bits, $len)
+ protected function packBitString(string $bits, int $len): string
{
$bits = substr($bits, 0, $len);
// Pad input with zeros to next multiple of 4 above $len
@@ -336,13 +287,8 @@
/**
* Based on the control, adjust the nibble accordingly.
- *
- * @param string $nibble
- * @param string $control
- *
- * @return string
*/
- protected function nibbleControl($nibble, $control)
+ protected function nibbleControl(string $nibble, string $control): string
{
// This control stays constant for the low/high nibbles,
// so it doesn't matter which we compare to
@@ -362,12 +308,9 @@
* the control for X or Y equals 011010. Additionally, if the dec value of the nibble is > 9, then the nibble value
* must be subtracted by 9 before the final value is constructed.
*
- * @param string $nibbleType Either X or Y
- * @param string $nibble
- *
- * @return string
+ * @param string $nibbleType Either X or Y
*/
- protected function getNibbleWithControl($nibbleType, $nibble)
+ protected function getNibbleWithControl(string $nibbleType, string $nibble): string
{
$dec = bindec($nibble);
@@ -384,12 +327,9 @@
/**
* Need to make sure hex values are always an even length, so pad as needed.
*
- * @param int $int
- * @param int $padLength The hex string must be padded to this length (with zeros).
- *
- * @return string
+ * @param int $padLength The hex string must be padded to this length (with zeros).
*/
- protected function dec2hex($int, $padLength = 2)
+ protected function dec2hex(int $int, int $padLength = 2): string
{
return str_pad(dechex($int), $padLength, 0, STR_PAD_LEFT);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSPropertyArray.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSPropertyArray.php
index 1831688..a810181 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSPropertyArray.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/TSPropertyArray.php
@@ -9,14 +9,14 @@
/**
* Represents that the TSPropertyArray data is valid.
*/
- const VALID_SIGNATURE = 'P';
+ public const VALID_SIGNATURE = 'P';
/**
* The default values for the TSPropertyArray structure.
*
* @var array
*/
- const DEFAULTS = [
+ public const DEFAULTS = [
'CtxCfgPresent' => 2953518677,
'CtxWFProfilePath' => '',
'CtxWFProfilePathW' => '',
@@ -36,33 +36,31 @@
];
/**
- * @var string The default data that occurs before the TSPropertyArray (CtxCfgPresent with a bunch of spaces...?)
+ * The default data that occurs before the TSPropertyArray (CtxCfgPresent with a bunch of spaces...?).
*/
- protected $defaultPreBinary = '43747843666750726573656e742020202020202020202020202020202020202020202020202020202020202020202020';
+ protected string $defaultPreBinary = '43747843666750726573656e742020202020202020202020202020202020202020202020202020202020202020202020';
/**
+ * The TSProperty array.
+ *
* @var TSProperty[]
*/
- protected $tsProperty = [];
+ protected array $tsProperty = [];
/**
- * @var string
+ * The TSProperty signature.
*/
- protected $signature = self::VALID_SIGNATURE;
+ protected string $signature = self::VALID_SIGNATURE;
/**
* Binary data that occurs before the TSPropertyArray data in userParameters.
- *
- * @var string
*/
- protected $preBinary = '';
+ protected string $preBinary = '';
/**
* Binary data that occurs after the TSPropertyArray data in userParameters.
- *
- * @var string
*/
- protected $postBinary = '';
+ protected string $postBinary = '';
/**
* Construct in one of the following ways:.
@@ -70,10 +68,8 @@
* - Pass an array of TSProperty key => value pairs (See DEFAULTS constant).
* - Pass the userParameters binary value. The object representation of that will be decoded and constructed.
* - Pass nothing and a default set of TSProperty key => value pairs will be used (See DEFAULTS constant).
- *
- * @param mixed $tsPropertyArray
*/
- public function __construct($tsPropertyArray = null)
+ public function __construct(mixed $tsPropertyArray = null)
{
$this->preBinary = hex2bin($this->defaultPreBinary);
@@ -81,7 +77,7 @@
$tsPropertyArray = $tsPropertyArray ?: self::DEFAULTS;
foreach ($tsPropertyArray as $key => $value) {
- $tsProperty = new TSProperty();
+ $tsProperty = new TSProperty;
$this->tsProperty[$key] = $tsProperty->setName($key)->setValue($value);
}
@@ -92,24 +88,16 @@
/**
* Check if a specific TSProperty exists by its property name.
- *
- * @param string $propName
- *
- * @return bool
*/
- public function has($propName)
+ public function has(string $propName): bool
{
return array_key_exists(strtolower($propName), array_change_key_case($this->tsProperty));
}
/**
* Get a TSProperty object by its property name (ie. CtxWFProfilePath).
- *
- * @param string $propName
- *
- * @return TSProperty
*/
- public function get($propName)
+ public function get(string $propName): TSProperty
{
$this->validateProp($propName);
@@ -118,12 +106,8 @@
/**
* Add a TSProperty object. If it already exists, it will be overwritten.
- *
- * @param TSProperty $tsProperty
- *
- * @return $this
*/
- public function add(TSProperty $tsProperty)
+ public function add(TSProperty $tsProperty): static
{
$this->tsProperty[$tsProperty->getName()] = $tsProperty;
@@ -131,13 +115,9 @@
}
/**
- * Remove a TSProperty by its property name (ie. CtxMinEncryptionLevel).
- *
- * @param string $propName
- *
- * @return $this
+ * Remove a TSProperty by its property name (i.e. CtxMinEncryptionLevel).
*/
- public function remove($propName)
+ public function remove(string $propName): static
{
foreach (array_keys($this->tsProperty) as $property) {
if (strtolower($propName) == strtolower($property)) {
@@ -150,13 +130,8 @@
/**
* Set the value for a specific TSProperty by its name.
- *
- * @param string $propName
- * @param mixed $propValue
- *
- * @return $this
*/
- public function set($propName, $propValue)
+ public function set(string $propName, string|int $propValue): static
{
$this->validateProp($propName);
@@ -167,10 +142,8 @@
/**
* Get the full binary representation of the userParameters containing the TSPropertyArray data.
- *
- * @return string
*/
- public function toBinary()
+ public function toBinary(): string
{
$binary = $this->preBinary;
@@ -187,10 +160,8 @@
/**
* Get a simple associative array containing of all TSProperty names and values.
- *
- * @return array
*/
- public function toArray()
+ public function toArray(): array
{
$userParameters = [];
@@ -206,17 +177,15 @@
*
* @return TSProperty[]
*/
- public function getTSProperties()
+ public function getTSProperties(): array
{
return $this->tsProperty;
}
/**
* Validates that the given property name exists.
- *
- * @param string $propName
*/
- protected function validateProp($propName)
+ protected function validateProp(string $propName): void
{
if (! $this->has($propName)) {
throw new InvalidArgumentException(sprintf('TSProperty for "%s" does not exist.', $propName));
@@ -224,23 +193,17 @@
}
/**
- * @param string $propName
- *
- * @return TSProperty
+ * Get the TS property object for the given property.
*/
- protected function getTsPropObj($propName)
+ protected function getTsPropObj(string $propName): TSProperty
{
return array_change_key_case($this->tsProperty)[strtolower($propName)];
}
/**
- * Get an associative array with all of the userParameters property names and values.
- *
- * @param string $userParameters
- *
- * @return void
+ * Get an associative array with all the userParameters property names and values.
*/
- protected function decodeUserParameters($userParameters)
+ protected function decodeUserParameters(string $userParameters): void
{
$userParameters = bin2hex($userParameters);
@@ -260,7 +223,7 @@
// Reserved data length + (count and sig length == 4) + the added lengths of the TSPropertyArray
// This saves anything after that variable TSPropertyArray data, so as to not squash anything stored there
if (strlen($userParameters) > (96 + 4 + $length)) {
- $this->postBinary = hex2bin(substr($userParameters, (96 + 4 + $length)));
+ $this->postBinary = hex2bin(substr($userParameters, 96 + 4 + $length));
}
}
@@ -270,12 +233,9 @@
* individual TSProperty structures. Return the full length
* of the TSPropertyArray data.
*
- * @param string $tsPropertyArray
- * @param int $tsPropCount
- *
* @return int The length of the data in the TSPropertyArray
*/
- protected function addTSPropData($tsPropertyArray, $tsPropCount)
+ protected function addTSPropData(string $tsPropertyArray, int $tsPropCount): int
{
$length = 0;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php
index e5d9dc3..4046eb7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Attributes/Timestamp.php
@@ -5,37 +5,39 @@
use Carbon\Carbon;
use Carbon\CarbonInterface;
use DateTime;
+use DateTimeZone;
use LdapRecord\LdapRecordException;
-use LdapRecord\Utilities;
class Timestamp
{
+ public const TYPE_LDAP = 'ldap';
+
+ public const TYPE_WINDOWS = 'windows';
+
+ public const TYPE_WINDOWS_INT = 'windows-int';
+
+ public const WINDOWS_INT_MAX = 9223372036854775807;
+
/**
* The current timestamp type.
- *
- * @var string
*/
- protected $type;
+ protected string $type;
/**
* The available timestamp types.
- *
- * @var array
*/
- protected $types = [
- 'ldap',
- 'windows',
- 'windows-int',
+ protected array $types = [
+ Timestamp::TYPE_LDAP,
+ Timestamp::TYPE_WINDOWS,
+ Timestamp::TYPE_WINDOWS_INT,
];
/**
* Constructor.
*
- * @param string $type
- *
* @throws LdapRecordException
*/
- public function __construct($type)
+ public function __construct(string $type)
{
$this->setType($type);
}
@@ -43,11 +45,9 @@
/**
* Set the type of timestamp to convert from / to.
*
- * @param string $type
- *
* @throws LdapRecordException
*/
- public function setType($type)
+ public function setType(string $type): void
{
if (! in_array($type, $this->types)) {
throw new LdapRecordException("Unrecognized LDAP date type [$type]");
@@ -59,19 +59,15 @@
/**
* Converts the value to an LDAP date string.
*
- * @param mixed $value
- *
- * @return float|string
- *
* @throws LdapRecordException
*/
- public function fromDateTime($value)
+ public function fromDateTime(mixed $value): int|string
{
$value = is_array($value) ? reset($value) : $value;
- // If the value is being converted to a windows integer format but it
+ // If the value is being converted to a windows integer format, but it
// is already in that format, we will simply return the value back.
- if ($this->type == 'windows-int' && $this->valueIsWindowsIntegerType($value)) {
+ if ($this->type === Timestamp::TYPE_WINDOWS_INT && $this->valueIsWindowsIntegerType($value)) {
return $value;
}
// If the value is numeric, we will assume it's a UNIX timestamp.
@@ -87,45 +83,28 @@
$value = Carbon::instance($value);
}
- switch ($this->type) {
- case 'ldap':
- $value = $this->convertDateTimeToLdapTime($value);
- break;
- case 'windows':
- $value = $this->convertDateTimeToWindows($value);
- break;
- case 'windows-int':
- $value = $this->convertDateTimeToWindowsInteger($value);
- break;
- default:
- throw new LdapRecordException("Unrecognized date type [{$this->type}]");
- }
-
- return $value;
+ return match ($this->type) {
+ Timestamp::TYPE_LDAP => $this->convertDateTimeToLdapTime($value),
+ Timestamp::TYPE_WINDOWS => $this->convertDateTimeToWindows($value),
+ Timestamp::TYPE_WINDOWS_INT => $this->convertDateTimeToWindowsInteger($value),
+ default => throw new LdapRecordException("Unrecognized date type [{$this->type}]"),
+ };
}
/**
* Determine if the value given is in Windows Integer (NTFS Filetime) format.
- *
- * @param int|string $value
- *
- * @return bool
*/
- protected function valueIsWindowsIntegerType($value)
+ protected function valueIsWindowsIntegerType(mixed $value): bool
{
- return is_numeric($value) && strlen((string) $value) === 18;
+ return is_numeric($value) && in_array(strlen((string) $value), [18, 19]);
}
/**
* Converts the LDAP timestamp value to a Carbon instance.
*
- * @param mixed $value
- *
- * @return Carbon|false
- *
* @throws LdapRecordException
*/
- public function toDateTime($value)
+ public function toDateTime(mixed $value): Carbon|int|false
{
$value = is_array($value) ? reset($value) : $value;
@@ -133,112 +112,93 @@
return Carbon::instance($value);
}
- switch ($this->type) {
- case 'ldap':
- $value = $this->convertLdapTimeToDateTime($value);
- break;
- case 'windows':
- $value = $this->convertWindowsTimeToDateTime($value);
- break;
- case 'windows-int':
- $value = $this->convertWindowsIntegerTimeToDateTime($value);
- break;
- default:
- throw new LdapRecordException("Unrecognized date type [{$this->type}]");
- }
+ $value = match ($this->type) {
+ Timestamp::TYPE_LDAP => $this->convertLdapTimeToDateTime($value),
+ Timestamp::TYPE_WINDOWS => $this->convertWindowsTimeToDateTime($value),
+ Timestamp::TYPE_WINDOWS_INT => $this->convertWindowsIntegerTimeToDateTime($value),
+ default => throw new LdapRecordException("Unrecognized date type [{$this->type}]"),
+ };
return $value instanceof DateTime ? Carbon::instance($value) : $value;
}
/**
* Converts standard LDAP timestamps to a date time object.
- *
- * @param string $value
- *
- * @return DateTime|false
*/
- protected function convertLdapTimeToDateTime($value)
+ protected function convertLdapTimeToDateTime(string $value): DateTime|false
{
- return DateTime::createFromFormat(
- strpos($value, 'Z') !== false ? 'YmdHis\Z' : 'YmdHisT',
- $value
- );
+ return DateTime::createFromFormat(match (true) {
+ str_ends_with($value, '.000Z') => 'YmdHis.000\Z',
+ str_ends_with($value, '.0Z') => 'YmdHis.0\Z',
+ str_ends_with($value, 'Z') => 'YmdHis\Z',
+ default => 'YmdHisT',
+ }, $value);
}
/**
* Converts date objects to a standard LDAP timestamp.
- *
- * @param DateTime $date
- *
- * @return string
*/
- protected function convertDateTimeToLdapTime(DateTime $date)
+ protected function convertDateTimeToLdapTime(DateTime $date): string
{
return $date->format(
- $date->getOffset() == 0 ? 'YmdHis\Z' : 'YmdHisO'
+ $date->getOffset() == 0
+ ? 'YmdHis\Z'
+ : 'YmdHisO'
);
}
/**
* Converts standard windows timestamps to a date time object.
- *
- * @param string $value
- *
- * @return DateTime|false
*/
- protected function convertWindowsTimeToDateTime($value)
+ protected function convertWindowsTimeToDateTime(string $value): DateTime|false
{
- return DateTime::createFromFormat(
- strpos($value, '0Z') !== false ? 'YmdHis.0\Z' : 'YmdHis.0T',
- $value
- );
+ return DateTime::createFromFormat(match (true) {
+ str_ends_with($value, '.0Z') => 'YmdHis.0\Z',
+ default => 'YmdHis.0T'
+ }, $value, new DateTimeZone('UTC'));
}
/**
* Converts date objects to a windows timestamp.
- *
- * @param DateTime $date
- *
- * @return string
*/
- protected function convertDateTimeToWindows(DateTime $date)
+ protected function convertDateTimeToWindows(DateTime $date): string
{
return $date->format(
- $date->getOffset() == 0 ? 'YmdHis.0\Z' : 'YmdHis.0O'
+ $date->getOffset() == 0
+ ? 'YmdHis.0\Z'
+ : 'YmdHis.0O'
);
}
/**
* Converts standard windows integer dates to a date time object.
*
- * @param int $value
- *
- * @return DateTime|false
- *
* @throws \Exception
*/
- protected function convertWindowsIntegerTimeToDateTime($value)
+ protected function convertWindowsIntegerTimeToDateTime(string|int|null $value = null): DateTime|int|false
{
- // ActiveDirectory dates that contain integers may return
- // "0" when they are not set. We will validate that here.
- if (! $value) {
+ if (is_null($value) || $value === '') {
return false;
}
- return (new DateTime())->setTimestamp(
- Utilities::convertWindowsTimeToUnixTime($value)
+ if ($value == 0) {
+ return (int) $value;
+ }
+
+ if ($value == static::WINDOWS_INT_MAX) {
+ return (int) $value;
+ }
+
+ return (new DateTime)->setTimestamp(
+ (int) ($value / 10000000) - 11644473600
);
}
/**
* Converts date objects to a windows integer timestamp.
- *
- * @param DateTime $date
- *
- * @return float
*/
- protected function convertDateTimeToWindowsInteger(DateTime $date)
+ protected function convertDateTimeToWindowsInteger(DateTime $date): int
{
- return Utilities::convertUnixTimeToWindowsTime($date->getTimestamp());
+ return ($date->getTimestamp() + 11644473600) * 10000000;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/BatchModification.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/BatchModification.php
index 37f0e87..3b15309 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/BatchModification.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/BatchModification.php
@@ -9,48 +9,38 @@
use DetectsResetIntegers;
/**
- * The array keys to be used in batch modifications.
+ * The array key identifiers.
*/
- const KEY_ATTRIB = 'attrib';
- const KEY_MODTYPE = 'modtype';
- const KEY_VALUES = 'values';
+ public const KEY_ATTRIB = 'attrib';
+
+ public const KEY_MODTYPE = 'modtype';
+
+ public const KEY_VALUES = 'values';
/**
* The attribute of the modification.
- *
- * @var string|null
*/
- protected $attribute;
+ protected ?string $attribute = null;
/**
* The original value of the attribute before modification.
- *
- * @var array
*/
- protected $original = [];
+ protected array $original = [];
/**
* The values of the modification.
- *
- * @var array
*/
- protected $values = [];
+ protected array $values = [];
/**
* The modtype integer of the batch modification.
- *
- * @var int|null
*/
- protected $type;
+ protected ?int $type = null;
/**
* Constructor.
- *
- * @param string|null $attribute
- * @param string|int|null $type
- * @param array $values
*/
- public function __construct($attribute = null, $type = null, array $values = [])
+ public function __construct(?string $attribute = null, ?int $type = null, array $values = [])
{
$this->setAttribute($attribute)
->setType($type)
@@ -58,13 +48,17 @@
}
/**
- * Set the original value of the attribute before modification.
- *
- * @param array|string $original
- *
- * @return $this
+ * Make a new batch modification instance.
*/
- public function setOriginal($original = [])
+ public static function make(?string $attribute = null, ?int $type = null, array $values = []): self
+ {
+ return new static($attribute, $type, $values);
+ }
+
+ /**
+ * Set the original value of the attribute before modification.
+ */
+ public function setOriginal(array|string $original = []): static
{
$this->original = $this->normalizeAttributeValues($original);
@@ -72,23 +66,17 @@
}
/**
- * Returns the original value of the attribute before modification.
- *
- * @return array
+ * Get the original value of the attribute before modification.
*/
- public function getOriginal()
+ public function getOriginal(): array
{
return $this->original;
}
/**
* Set the attribute of the modification.
- *
- * @param string $attribute
- *
- * @return $this
*/
- public function setAttribute($attribute)
+ public function setAttribute(?string $attribute = null): static
{
$this->attribute = $attribute;
@@ -96,67 +84,51 @@
}
/**
- * Returns the attribute of the modification.
- *
- * @return string
+ * Get the attribute of the modification.
*/
- public function getAttribute()
+ public function getAttribute(): string
{
return $this->attribute;
}
/**
* Set the values of the modification.
- *
- * @param array $values
- *
- * @return $this
*/
- public function setValues(array $values = [])
+ public function setValues(array $values = []): static
{
// Null and empty values must also not be added to a batch
// modification. Passing null or empty values will result
// in an exception when trying to save the modification.
$this->values = array_filter($this->normalizeAttributeValues($values), function ($value) {
- return is_numeric($value) && $this->valueIsResetInteger((int) $value) ?: ! empty($value);
+ return is_numeric($value) && $this->valueIsResetInteger((int) $value) || ! empty($value);
});
return $this;
}
/**
- * Normalize all of the attribute values.
- *
- * @param array|string $values
- *
- * @return array
+ * Normalize all the attribute values.
*/
- protected function normalizeAttributeValues($values = [])
+ protected function normalizeAttributeValues(array|string $values = []): array
{
- // We must convert all of the values to strings. Only strings can
+ // We must convert all the values to strings. Only strings can
// be used in batch modifications, otherwise we will we will
// receive an LDAP exception while attempting to save.
return array_map('strval', (array) $values);
}
/**
- * Returns the values of the modification.
- *
- * @return array
+ * Get the values of the modification.
*/
- public function getValues()
+ public function getValues(): array
{
return $this->values;
}
/**
* Set the type of the modification.
- *
- * @param int|null $type
- *
- * @return $this
*/
- public function setType($type = null)
+ public function setType(?int $type = null): static
{
if (is_null($type)) {
return $this;
@@ -172,21 +144,17 @@
}
/**
- * Returns the type of the modification.
- *
- * @return int
+ * Get the type of the modification.
*/
- public function getType()
+ public function getType(): ?int
{
return $this->type;
}
/**
- * Determines if the batch modification is valid in its current state.
- *
- * @return bool
+ * Determine if the batch modification is valid in its current state.
*/
- public function isValid()
+ public function isValid(): bool
{
return ! is_null($this->get());
}
@@ -194,51 +162,43 @@
/**
* Builds the type of modification automatically
* based on the current and original values.
- *
- * @return $this
*/
- public function build()
+ public function build(): static
{
- switch (true) {
- case empty($this->original) && empty($this->values):
- return $this;
- case ! empty($this->original) && empty($this->values):
- return $this->setType(LDAP_MODIFY_BATCH_REMOVE_ALL);
- case empty($this->original) && ! empty($this->values):
- return $this->setType(LDAP_MODIFY_BATCH_ADD);
- default:
- return $this->determineBatchTypeFromOriginal();
- }
+ return match (true) {
+ empty($this->original) && empty($this->values) => $this,
+
+ ! empty($this->original) && empty($this->values) => $this->setType(LDAP_MODIFY_BATCH_REMOVE_ALL),
+
+ empty($this->original) && ! empty($this->values) => $this->setType(LDAP_MODIFY_BATCH_ADD),
+
+ default => $this->determineBatchTypeFromOriginal(),
+ };
}
/**
* Determine the batch modification type from the original values.
- *
- * @return $this
*/
- protected function determineBatchTypeFromOriginal()
+ protected function determineBatchTypeFromOriginal(): static
{
$added = $this->getAddedValues();
$removed = $this->getRemovedValues();
- switch (true) {
- case ! empty($added) && ! empty($removed):
- return $this->setType(LDAP_MODIFY_BATCH_REPLACE);
- case ! empty($added):
- return $this->setValues($added)->setType(LDAP_MODIFY_BATCH_ADD);
- case ! empty($removed):
- return $this->setValues($removed)->setType(LDAP_MODIFY_BATCH_REMOVE);
- default:
- return $this;
- }
+ return match (true) {
+ ! empty($added) && ! empty($removed) => $this->setType(LDAP_MODIFY_BATCH_REPLACE),
+
+ ! empty($added) => $this->setValues($added)->setType(LDAP_MODIFY_BATCH_ADD),
+
+ ! empty($removed) => $this->setValues($removed)->setType(LDAP_MODIFY_BATCH_REMOVE),
+
+ default => $this,
+ };
}
/**
* Get the values that were added to the attribute.
- *
- * @return array
*/
- protected function getAddedValues()
+ protected function getAddedValues(): array
{
return array_values(
array_diff($this->values, $this->original)
@@ -247,10 +207,8 @@
/**
* Get the values that were removed from the attribute.
- *
- * @return array
*/
- protected function getRemovedValues()
+ protected function getRemovedValues(): array
{
return array_values(
array_diff($this->original, $this->values)
@@ -258,44 +216,30 @@
}
/**
- * Returns the built batch modification array.
- *
- * @return array|null
+ * Get the batch modification array.
*/
- public function get()
+ public function get(): ?array
{
- switch ($this->type) {
- case LDAP_MODIFY_BATCH_REMOVE_ALL:
- // A values key cannot be provided when
- // a remove all type is selected.
- return [
- static::KEY_ATTRIB => $this->attribute,
- static::KEY_MODTYPE => $this->type,
- ];
- case LDAP_MODIFY_BATCH_REMOVE:
- // Fallthrough.
- case LDAP_MODIFY_BATCH_ADD:
- // Fallthrough.
- case LDAP_MODIFY_BATCH_REPLACE:
- return [
- static::KEY_ATTRIB => $this->attribute,
- static::KEY_MODTYPE => $this->type,
- static::KEY_VALUES => $this->values,
- ];
- default:
- // If the modtype isn't recognized, we'll return null.
- return;
- }
+ return match ($this->type) {
+ LDAP_MODIFY_BATCH_REMOVE_ALL => [
+ static::KEY_ATTRIB => $this->attribute,
+ static::KEY_MODTYPE => $this->type,
+ ],
+
+ LDAP_MODIFY_BATCH_REMOVE, LDAP_MODIFY_BATCH_ADD, LDAP_MODIFY_BATCH_REPLACE => [
+ static::KEY_ATTRIB => $this->attribute,
+ static::KEY_MODTYPE => $this->type,
+ static::KEY_VALUES => $this->values,
+ ],
+
+ default => null,
+ };
}
/**
- * Determines if the given modtype is valid.
- *
- * @param int $type
- *
- * @return bool
+ * Determine if the given modtype is valid.
*/
- protected function isValidType($type)
+ protected function isValidType(int $type): bool
{
return in_array($type, [
LDAP_MODIFY_BATCH_REMOVE_ALL,
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Collection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Collection.php
index 850167b..a0d8126 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Collection.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Collection.php
@@ -10,13 +10,21 @@
class Collection extends QueryCollection
{
/**
- * Determine if the collection contains all of the given models, or any models.
- *
- * @param mixed $models
- *
- * @return bool
+ * Get a collection of the model's distinguished names.
*/
- public function exists($models = null)
+ public function modelDns(): static
+ {
+ return $this->map(function (Model $model) {
+ return $model->getDn();
+ });
+ }
+
+ /**
+ * Determine if the collection contains all the given models, or any models.
+ *
+ * @param QueryCollection|Model|array|string|null $models
+ */
+ public function exists(mixed $models = null): bool
{
$models = $this->getArrayableModels($models);
@@ -46,20 +54,11 @@
/**
* Determine if any of the given models are contained in the collection.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- *
- * @return bool
*/
- public function contains($key, $operator = null, $value = null)
+ public function contains($key, $operator = null, $value = null): bool
{
if (func_num_args() > 1 || $key instanceof Closure) {
- // If we are supplied with more than one argument, or
- // we were passed a closure, we will utilize the
- // parents contains method, for compatibility.
- return parent::contains($key, $operator, $value);
+ return parent::contains(...func_get_args());
}
foreach ($this->getArrayableModels($key) as $model) {
@@ -77,32 +76,25 @@
/**
* Get the provided models as an array.
- *
- * @param mixed $models
- *
- * @return array
*/
- protected function getArrayableModels($models = null)
+ protected function getArrayableModels(mixed $models = null): array
{
- return $models instanceof QueryCollection
- ? $models->toArray()
- : Arr::wrap($models);
+ if ($models instanceof QueryCollection) {
+ return $models->all();
+ }
+
+ return Arr::wrap($models);
}
/**
* Compare the related model with the given.
- *
- * @param Model|string $model
- * @param Model $related
- *
- * @return bool
*/
- protected function compareModelWithRelated($model, $related)
+ protected function compareModelWithRelated(Model|string $model, Model $related): bool
{
if (is_string($model)) {
return $this->isValidDn($model)
- ? $related->getDn() == $model
- : $related->getName() == $model;
+ ? strcasecmp($related->getDn(), $model) === 0
+ : strcasecmp($related->getName(), $model) === 0;
}
return $related->is($model);
@@ -110,12 +102,8 @@
/**
* Determine if the given string is a valid distinguished name.
- *
- * @param string $dn
- *
- * @return bool
*/
- protected function isValidDn($dn)
+ protected function isValidDn(string $dn): bool
{
return ! empty((new DistinguishedName($dn))->components());
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php
index 451738a..e52657a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/CanAuthenticate.php
@@ -2,65 +2,63 @@
namespace LdapRecord\Models\Concerns;
+/** @mixin \LdapRecord\Models\Model */
trait CanAuthenticate
{
/**
* Get the name of the unique identifier for the user.
- *
- * @return string
*/
- public function getAuthIdentifierName()
+ public function getAuthIdentifierName(): string
{
return $this->guidKey;
}
/**
* Get the unique identifier for the user.
- *
- * @return mixed
*/
- public function getAuthIdentifier()
+ public function getAuthIdentifier(): string
{
- return $this->getConvertedGuid();
+ return $this->getConvertedGuid(
+ $this->getFirstAttribute($this->getAuthIdentifierName())
+ );
}
/**
* Get the password for the user.
- *
- * @return string
*/
- public function getAuthPassword()
+ public function getAuthPassword(): string
{
return '';
}
/**
- * Get the token value for the "remember me" session.
- *
- * @return string
+ * Get the name of the password attribute for the user.
*/
- public function getRememberToken()
+ public function getAuthPasswordName(): string
+ {
+ return 'password';
+ }
+
+ /**
+ * Get the token value for the "remember me" session.
+ */
+ public function getRememberToken(): string
{
return '';
}
/**
* Set the token value for the "remember me" session.
- *
- * @param string $value
- *
- * @return void
*/
- public function setRememberToken($value)
+ public function setRememberToken($value): void
{
+ // Do nothing.
}
/**
* Get the column name for the "remember me" token.
- *
- * @return string
*/
- public function getRememberTokenName()
+ public function getRememberTokenName(): string
{
return '';
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php
index b5f33357..67b4cf7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasAttributes.php
@@ -10,6 +10,7 @@
use LdapRecord\Models\Attributes\Timestamp;
use LdapRecord\Models\DetectsResetIntegers;
use LdapRecord\Support\Arr;
+use RuntimeException;
trait HasAttributes
{
@@ -17,75 +18,72 @@
/**
* The models original attributes.
- *
- * @var array
*/
- protected $original = [];
+ protected array $original = [];
+
+ /**
+ * The models changed attributes.
+ */
+ protected array $changes = [];
/**
* The models attributes.
- *
- * @var array
*/
- protected $attributes = [];
+ protected array $attributes = [];
/**
* The attributes that should be mutated to dates.
- *
- * @var array
*/
- protected $dates = [];
+ protected array $dates = [];
/**
* The attributes that should be cast to their native types.
- *
- * @var array
*/
- protected $casts = [];
+ protected array $casts = [];
/**
* The accessors to append to the model's array form.
- *
- * @var array
*/
- protected $appends = [];
+ protected array $appends = [];
/**
* The format that dates must be output to for serialization.
- *
- * @var string
*/
- protected $dateFormat;
+ protected ?string $dateFormat = null;
/**
* The default attributes that should be mutated to dates.
- *
- * @var array
*/
- protected $defaultDates = [
+ protected array $defaultDates = [
'createtimestamp' => 'ldap',
'modifytimestamp' => 'ldap',
];
/**
* The cache of the mutated attributes for each class.
- *
- * @var array
*/
- protected static $mutatorCache = [];
+ protected static array $mutatorCache = [];
+
+ /**
+ * Convert the model's original attributes to an array.
+ */
+ public function originalToArray(): array
+ {
+ return $this->encodeAttributes(
+ $this->convertAttributesForJson($this->original)
+ );
+ }
/**
* Convert the model's attributes to an array.
- *
- * @return array
*/
- public function attributesToArray()
+ public function attributesToArray(): array
{
// Here we will replace our LDAP formatted dates with
// properly formatted ones, so dates do not need to
// be converted manually after being returned.
$attributes = $this->addDateAttributesToArray(
- $attributes = $this->getArrayableAttributes()
+ $this->getArrayableAttributes()
);
$attributes = $this->addMutatedAttributesToArray(
@@ -112,13 +110,31 @@
}
/**
- * Add the date attributes to the attributes array.
- *
- * @param array $attributes
- *
- * @return array
+ * Convert the model's serialized original attributes to their original form.
*/
- protected function addDateAttributesToArray(array $attributes)
+ public function arrayToOriginal(array $attributes): array
+ {
+ $attributes = $this->decodeAttributes($attributes);
+
+ return $this->convertAttributesFromJson($attributes);
+ }
+
+ /**
+ * Convert the model's serialized attributes to their original form.
+ */
+ public function arrayToAttributes(array $attributes): array
+ {
+ $attributes = $this->restoreDateAttributesFromArray($attributes);
+
+ $attributes = $this->decodeAttributes($attributes);
+
+ return $this->convertAttributesFromJson($attributes);
+ }
+
+ /**
+ * Add the date attributes to the attributes array.
+ */
+ protected function addDateAttributesToArray(array $attributes): array
{
foreach ($this->getDates() as $attribute => $type) {
if (! isset($attributes[$attribute])) {
@@ -136,23 +152,35 @@
}
/**
- * Prepare a date for array / JSON serialization.
- *
- * @param DateTimeInterface $date
- *
- * @return string
+ * Restore the date attributes to their true value from serialized attributes.
*/
- protected function serializeDate(DateTimeInterface $date)
+ protected function restoreDateAttributesFromArray(array $attributes): array
+ {
+ foreach ($this->getDates() as $attribute => $type) {
+ if (! isset($attributes[$attribute])) {
+ continue;
+ }
+
+ $date = $this->fromDateTime($attributes[$attribute], $type);
+
+ $attributes[$attribute] = Arr::wrap($date);
+ }
+
+ return $attributes;
+ }
+
+ /**
+ * Prepare a date for array / JSON serialization.
+ */
+ protected function serializeDate(DateTimeInterface $date): string
{
return $date->format($this->getDateFormat());
}
/**
* Recursively UTF-8 encode the given attributes.
- *
- * @return array
*/
- public function encodeAttributes($attributes)
+ protected function encodeAttributes($attributes): array
{
array_walk_recursive($attributes, function (&$value) {
$value = $this->encodeValue($value);
@@ -162,29 +190,48 @@
}
/**
- * Encode the given value for proper serialization.
- *
- * @param string $value
- *
- * @return string
+ * Recursively UTF-8 decode the given attributes.
*/
- protected function encodeValue($value)
+ public function decodeAttributes(array $attributes): array
+ {
+ array_walk_recursive($attributes, function (&$value) {
+ $value = $this->decodeValue($value);
+ });
+
+ return $attributes;
+ }
+
+ /**
+ * Encode the value for serialization.
+ */
+ protected function encodeValue(string $value): string
{
// If we are able to detect the encoding, we will
// encode only the attributes that need to be,
// so that we do not double encode values.
- return MbString::isLoaded() && MbString::isUtf8($value) ? $value : utf8_encode($value);
+ if (MbString::isLoaded() && MbString::isUtf8($value)) {
+ return $value;
+ }
+
+ return mb_convert_encoding($value, 'UTF-8', 'ISO-8859-1');
+ }
+
+ /**
+ * Decode the value from serialization.
+ */
+ protected function decodeValue(string $value): string
+ {
+ if (MbString::isLoaded() && ! MbString::isUtf8($value)) {
+ return mb_convert_encoding($value, 'UTF-8', 'ISO-8859-1');
+ }
+
+ return $value;
}
/**
* Add the mutated attributes to the attributes array.
- *
- * @param array $attributes
- * @param array $mutatedAttributes
- *
- * @return array
*/
- protected function addMutatedAttributesToArray(array $attributes, array $mutatedAttributes)
+ protected function addMutatedAttributesToArray(array $attributes, array $mutatedAttributes): array
{
foreach ($mutatedAttributes as $key) {
// We want to spin through all the mutated attributes for this model and call
@@ -208,10 +255,8 @@
/**
* Set the model's original attributes with the model's current attributes.
- *
- * @return $this
*/
- public function syncOriginal()
+ public function syncOriginal(): static
{
$this->original = $this->attributes;
@@ -219,13 +264,19 @@
}
/**
- * Fills the entry with the supplied attributes.
- *
- * @param array $attributes
- *
- * @return $this
+ * Sync the changed attributes.
*/
- public function fill(array $attributes = [])
+ public function syncChanges(): static
+ {
+ $this->changes = $this->getDirty();
+
+ return $this;
+ }
+
+ /**
+ * Fills the entry with the supplied attributes.
+ */
+ public function fill(array $attributes = []): static
{
foreach ($attributes as $key => $value) {
$this->setAttribute($key, $value);
@@ -235,31 +286,21 @@
}
/**
- * Returns the models attribute by its key.
- *
- * @param int|string $key
- * @param mixed $default
- *
- * @return mixed
+ * Get the models attribute by its key.
*/
- public function getAttribute($key, $default = null)
+ public function getAttribute(?string $key = null, mixed $default = null): mixed
{
if (! $key) {
- return;
+ return null;
}
return $this->getAttributeValue($key, $default);
}
/**
- * Get an attributes value.
- *
- * @param string $key
- * @param mixed $default
- *
- * @return mixed
+ * Get an attribute's value.
*/
- public function getAttributeValue($key, $default = null)
+ public function getAttributeValue(string $key, mixed $default = null): mixed
{
$key = $this->normalizeAttributeKey($key);
$value = $this->getAttributeFromArray($key);
@@ -280,44 +321,56 @@
}
/**
- * Determine if the given attribute is a date.
- *
- * @param string $key
- *
- * @return bool
+ * Get the model's raw attribute value.
*/
- public function isDateAttribute($key)
+ public function getRawAttribute(string $key, mixed $default = null): mixed
+ {
+ return Arr::get($this->attributes, $this->normalizeAttributeKey($key), $default);
+ }
+
+ /**
+ * Determine if the given attribute is a date.
+ */
+ public function isDateAttribute(string $key): bool
{
return array_key_exists($key, $this->getDates());
}
/**
* Get the attributes that should be mutated to dates.
- *
- * @return array
*/
- public function getDates()
+ public function getDates(): array
{
// Since array string keys can be unique depending
// on casing differences, we need to normalize the
// array key case so they are merged properly.
return array_merge(
- array_change_key_case($this->defaultDates, CASE_LOWER),
- array_change_key_case($this->dates, CASE_LOWER)
+ array_change_key_case($this->defaultDates),
+ array_change_key_case($this->dates),
+ array_change_key_case($this->getDateCasts()),
);
}
/**
+ * Get the attributes casts that should be mutated to dates.
+ */
+ protected function getDateCasts(): array
+ {
+ return array_map(function (string $cast) {
+ return explode(':', $cast, 2)[1] ?? throw new RuntimeException(
+ "Invalid date cast [$cast]. A date cast must be in the format 'datetime:format'."
+ );
+ }, array_filter($this->getCasts(), function ($cast) {
+ return $this->isDateTimeCast($cast);
+ }));
+ }
+
+ /**
* Convert the given date value to an LDAP compatible value.
*
- * @param string $type
- * @param mixed $value
- *
- * @return float|string
- *
* @throws LdapRecordException
*/
- public function fromDateTime($type, $value)
+ public function fromDateTime(mixed $value, string $type): float|int|string
{
return (new Timestamp($type))->fromDateTime($value);
}
@@ -325,30 +378,20 @@
/**
* Convert the given LDAP date value to a Carbon instance.
*
- * @param mixed $value
- * @param string $type
- *
- * @return Carbon|false
- *
* @throws LdapRecordException
*/
- public function asDateTime($value, $type)
+ public function asDateTime(mixed $value, string $type): Carbon|int|false
{
return (new Timestamp($type))->toDateTime($value);
}
/**
* Determine whether an attribute should be cast to a native type.
- *
- * @param string $key
- * @param array|string|null $types
- *
- * @return bool
*/
- public function hasCast($key, $types = null)
+ public function hasCast(string $key, array|string|null $types = null): bool
{
if (array_key_exists($key, $this->getCasts())) {
- return $types ? in_array($this->getCastType($key), (array) $types, true) : true;
+ return ! $types || in_array($this->getCastType($key), (array) $types, true);
}
return false;
@@ -356,34 +399,24 @@
/**
* Get the attributes that should be cast to their native types.
- *
- * @return array
*/
- protected function getCasts()
+ protected function getCasts(): array
{
- return array_change_key_case($this->casts, CASE_LOWER);
+ return array_change_key_case($this->casts);
}
/**
* Determine whether a value is JSON castable for inbound manipulation.
- *
- * @param string $key
- *
- * @return bool
*/
- protected function isJsonCastable($key)
+ protected function isJsonCastable(string $key): bool
{
return $this->hasCast($key, ['array', 'json', 'object', 'collection']);
}
/**
* Get the type of cast for a model attribute.
- *
- * @param string $key
- *
- * @return string
*/
- protected function getCastType($key)
+ protected function getCastType(string $key): string
{
if ($this->isDecimalCast($this->getCasts()[$key])) {
return 'decimal';
@@ -398,49 +431,32 @@
/**
* Determine if the cast is a decimal.
- *
- * @param string $cast
- *
- * @return bool
*/
- protected function isDecimalCast($cast)
+ protected function isDecimalCast(string $cast): bool
{
return strncmp($cast, 'decimal:', 8) === 0;
}
/**
* Determine if the cast is a datetime.
- *
- * @param string $cast
- *
- * @return bool
*/
- protected function isDateTimeCast($cast)
+ protected function isDateTimeCast(string $cast): bool
{
return strncmp($cast, 'datetime:', 8) === 0;
}
/**
* Determine if the given attribute must be casted.
- *
- * @param string $key
- *
- * @return bool
*/
- protected function isCastedAttribute($key)
+ protected function isCastedAttribute(string $key): bool
{
- return array_key_exists($key, array_change_key_case($this->casts, CASE_LOWER));
+ return array_key_exists($key, array_change_key_case($this->casts));
}
/**
* Cast an attribute to a native PHP type.
- *
- * @param string $key
- * @param array|null $value
- *
- * @return mixed
*/
- protected function castAttribute($key, $value)
+ protected function castAttribute(string $key, ?array $value): mixed
{
$value = $this->castRequiresArrayValue($key) ? $value : Arr::first($value);
@@ -464,7 +480,7 @@
case 'boolean':
return $this->asBoolean($value);
case 'object':
- return $this->fromJson($value, $asObject = true);
+ return $this->fromJson($value, true);
case 'array':
case 'json':
return $this->fromJson($value);
@@ -479,23 +495,16 @@
/**
* Determine if the cast type requires the first attribute value.
- *
- * @return bool
*/
- protected function castRequiresArrayValue($key)
+ protected function castRequiresArrayValue(string $key): bool
{
- return in_array($this->getCastType($key), ['collection']);
+ return $this->getCastType($key) === 'collection';
}
/**
* Cast the given attribute to JSON.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return string
*/
- protected function castAttributeAsJson($key, $value)
+ protected function castAttributeAsJson(string $key, mixed $value): string
{
$value = $this->asJson($value);
@@ -503,113 +512,104 @@
$class = get_class($this);
$message = json_last_error_msg();
- throw new Exception("Unable to encode attribute [{$key}] for model [{$class}] to JSON: {$message}.");
+ throw new Exception("Unable to encode attribute [$key] for model [$class] to JSON: $message.");
}
return $value;
}
/**
- * Convert the model to its JSON representation.
- *
- * @return string
+ * Cast the given attribute to an LDAP primitive type.
*/
- public function toJson()
+ protected function castAttributeAsPrimitive(string $key, mixed $value): string
+ {
+ return match ($this->getCastType($key)) {
+ 'bool', 'boolean' => $this->fromBoolean($value),
+ default => (string) $value,
+ };
+ }
+
+ /**
+ * Convert the model to its JSON representation.
+ */
+ public function toJson(): string
{
return json_encode($this);
}
/**
* Encode the given value as JSON.
- *
- * @param mixed $value
- *
- * @return string
*/
- protected function asJson($value)
+ protected function asJson(mixed $value): string|false
{
return json_encode($value);
}
/**
* Decode the given JSON back into an array or object.
- *
- * @param string $value
- * @param bool $asObject
- *
- * @return mixed
*/
- public function fromJson($value, $asObject = false)
+ public function fromJson(string $value, bool $asObject = false): mixed
{
return json_decode($value, ! $asObject);
}
/**
* Decode the given float.
- *
- * @param mixed $value
- *
- * @return mixed
*/
- public function fromFloat($value)
+ public function fromFloat(float $value): float
{
- switch ((string) $value) {
- case 'Infinity':
- return INF;
- case '-Infinity':
- return -INF;
- case 'NaN':
- return NAN;
- default:
- return (float) $value;
- }
+ return match ((string) $value) {
+ 'NaN' => NAN,
+ 'Infinity' => INF,
+ '-Infinity' => -INF,
+ default => $value,
+ };
}
/**
- * Cast the value to a boolean.
- *
- * @param mixed $value
- *
- * @return bool
+ * Cast the value from an LDAP boolean string to a primitive boolean.
*/
- protected function asBoolean($value)
+ protected function asBoolean(mixed $value): bool
{
- $map = ['true' => true, 'false' => false];
+ return match (strtolower($value)) {
+ 'true' => true,
+ 'false' => false,
+ default => (bool) $value,
+ };
+ }
- return $map[strtolower($value)] ?? (bool) $value;
+ /**
+ * Cast the value from a primitive boolean to an LDAP boolean string.
+ */
+ protected function fromBoolean(mixed $value): string
+ {
+ if (is_string($value)) {
+ $value = $this->asBoolean($value);
+ }
+
+ return $value ? 'TRUE' : 'FALSE';
}
/**
* Cast a decimal value as a string.
- *
- * @param float $value
- * @param int $decimals
- *
- * @return string
*/
- protected function asDecimal($value, $decimals)
+ protected function asDecimal(float $value, int $decimals): string
{
return number_format($value, $decimals, '.', '');
}
/**
* Get an attribute array of all arrayable attributes.
- *
- * @return array
*/
- protected function getArrayableAttributes()
+ protected function getArrayableAttributes(): array
{
return $this->getArrayableItems($this->attributes);
}
/**
* Get an attribute array of all arrayable values.
- *
- * @param array $values
- *
- * @return array
*/
- protected function getArrayableItems(array $values)
+ protected function getArrayableItems(array $values): array
{
if (count($visible = $this->getVisible()) > 0) {
$values = array_intersect_key($values, array_flip($visible));
@@ -623,11 +623,9 @@
}
/**
- * Get all of the appendable values that are arrayable.
- *
- * @return array
+ * Get all the appendable values that are arrayable.
*/
- protected function getArrayableAppends()
+ protected function getArrayableAppends(): array
{
if (empty($this->appends)) {
return [];
@@ -640,22 +638,16 @@
/**
* Get the format for date serialization.
- *
- * @return string
*/
- public function getDateFormat()
+ public function getDateFormat(): string
{
return $this->dateFormat ?: DateTimeInterface::ISO8601;
}
/**
* Set the date format used by the model for serialization.
- *
- * @param string $format
- *
- * @return $this
*/
- public function setDateFormat($format)
+ public function setDateFormat(string $format): static
{
$this->dateFormat = $format;
@@ -664,35 +656,24 @@
/**
* Get an attribute from the $attributes array.
- *
- * @param string $key
- *
- * @return mixed
*/
- protected function getAttributeFromArray($key)
+ protected function getAttributeFromArray(string $key): mixed
{
return $this->getNormalizedAttributes()[$key] ?? null;
}
/**
* Get the attributes with their keys normalized.
- *
- * @return array
*/
- protected function getNormalizedAttributes()
+ protected function getNormalizedAttributes(): array
{
- return array_change_key_case($this->attributes, CASE_LOWER);
+ return array_change_key_case($this->attributes);
}
/**
- * Returns the first attribute by the specified key.
- *
- * @param string $key
- * @param mixed $default
- *
- * @return mixed
+ * Get the first attribute by the specified key.
*/
- public function getFirstAttribute($key, $default = null)
+ public function getFirstAttribute(string $key, mixed $default = null): mixed
{
return Arr::first(
Arr::wrap($this->getAttribute($key, $default)),
@@ -700,39 +681,36 @@
}
/**
- * Returns all of the models attributes.
- *
- * @return array
+ * Returns all the model's attributes.
*/
- public function getAttributes()
+ public function getAttributes(): array
{
return $this->attributes;
}
/**
* Set an attribute value by the specified key.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return $this
*/
- public function setAttribute($key, $value)
+ public function setAttribute(string $key, mixed $value): static
{
$key = $this->normalizeAttributeKey($key);
if ($this->hasSetMutator($key)) {
return $this->setMutatedAttributeValue($key, $value);
- } elseif (
+ }
+
+ if (
$value &&
$this->isDateAttribute($key) &&
! $this->valueIsResetInteger($value)
) {
- $value = $this->fromDateTime($this->getDates()[$key], $value);
+ $value = (string) $this->fromDateTime($value, $this->getDates()[$key]);
}
if ($this->isJsonCastable($key) && ! is_null($value)) {
$value = $this->castAttributeAsJson($key, $value);
+ } elseif ($this->hasCast($key) && ! is_null($value)) {
+ $value = $this->castAttributeAsPrimitive($key, $value);
}
$this->attributes[$key] = Arr::wrap($value);
@@ -742,13 +720,8 @@
/**
* Set an attribute on the model. No checking is done.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return $this
*/
- public function setRawAttribute($key, $value)
+ public function setRawAttribute(string $key, mixed $value): static
{
$key = $this->normalizeAttributeKey($key);
@@ -759,81 +732,71 @@
/**
* Set the models first attribute value.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return $this
*/
- public function setFirstAttribute($key, $value)
+ public function setFirstAttribute(string $key, mixed $value): static
{
return $this->setAttribute($key, Arr::wrap($value));
}
/**
* Add a unique value to the given attribute.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return $this
*/
- public function addAttributeValue($key, $value)
+ public function addAttributeValue(string $key, mixed $value): static
{
- return $this->setAttribute($key, array_unique(
- array_merge(
- Arr::wrap($this->getAttribute($key)),
- Arr::wrap($value)
- )
- ));
+ return $this->setRawAttribute($key, array_unique(array_merge(
+ $this->getRawAttribute($key, []),
+ Arr::wrap($value)
+ )));
+ }
+
+ /**
+ * Remove a unique value from the given attribute.
+ */
+ public function removeAttributeValue(string $key, mixed $value): static
+ {
+ $values = $this->getRawAttribute($key, []);
+
+ foreach (Arr::wrap($value) as $value) {
+ $index = array_search($value, $values);
+
+ if ($index !== false) {
+ unset($values[$index]);
+ }
+ }
+
+ return $this->setRawAttribute($key, array_values($values));
}
/**
* Determine if a get mutator exists for an attribute.
- *
- * @param string $key
- *
- * @return bool
*/
- public function hasGetMutator($key)
+ public function hasGetMutator(string $key): bool
{
return method_exists($this, 'get'.$this->getMutatorMethodName($key).'Attribute');
}
/**
* Determine if a set mutator exists for an attribute.
- *
- * @param string $key
- *
- * @return bool
*/
- public function hasSetMutator($key)
+ public function hasSetMutator(string $key): bool
{
return method_exists($this, 'set'.$this->getMutatorMethodName($key).'Attribute');
}
/**
* Set the value of an attribute using its mutator.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return mixed
*/
- protected function setMutatedAttributeValue($key, $value)
+ protected function setMutatedAttributeValue(string $key, mixed $value): static
{
- return $this->{'set'.$this->getMutatorMethodName($key).'Attribute'}($value);
+ $this->{'set'.$this->getMutatorMethodName($key).'Attribute'}($value);
+
+ return $this;
}
/**
* Get the value of an attribute using its mutator.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return mixed
*/
- protected function getMutatedAttributeValue($key, $value)
+ protected function getMutatedAttributeValue(string $key, mixed $value): mixed
{
return $this->{'get'.$this->getMutatorMethodName($key).'Attribute'}($value);
}
@@ -842,12 +805,8 @@
* Get the mutator attribute method name.
*
* Hyphenated attributes will use pascal cased methods.
- *
- * @param string $key
- *
- * @return mixed
*/
- protected function getMutatorMethodName($key)
+ protected function getMutatorMethodName(string $key): string
{
$key = ucwords(str_replace('-', ' ', $key));
@@ -856,13 +815,8 @@
/**
* Get the value of an attribute using its mutator for array conversion.
- *
- * @param string $key
- * @param mixed $value
- *
- * @return array
*/
- protected function mutateAttributeForArray($key, $value)
+ protected function mutateAttributeForArray(string $key, mixed $value): array
{
return Arr::wrap(
$this->getMutatedAttributeValue($key, $value)
@@ -870,28 +824,22 @@
}
/**
- * Set the attributes property.
+ * Set the raw model attributes.
*
* Used when constructing an existing LDAP record.
- *
- * @param array $attributes
- *
- * @return $this
*/
- public function setRawAttributes(array $attributes = [])
+ public function setRawAttributes(array $attributes = []): static
{
// We will filter out those annoying 'count' keys
// returned with LDAP results and lowercase all
// root array keys to prevent any casing issues.
- $raw = array_change_key_case($this->filterRawAttributes($attributes), CASE_LOWER);
+ $raw = array_change_key_case($this->filterRawAttributes($attributes));
// Before setting the models attributes, we will filter
// out the attributes that contain an integer key. LDAP
// search results will contain integer keys that have
// attribute names as values. We don't need these.
- $this->attributes = array_filter($raw, function ($key) {
- return ! is_int($key);
- }, ARRAY_FILTER_USE_KEY);
+ $this->attributes = array_filter($raw, fn ($key) => ! is_int($key), ARRAY_FILTER_USE_KEY);
// LDAP search results will contain the distinguished
// name inside of the `dn` key. We will retrieve this,
@@ -914,13 +862,8 @@
/**
* Filters the count key recursively from raw LDAP attributes.
- *
- * @param array $attributes
- * @param array $keys
- *
- * @return array
*/
- public function filterRawAttributes(array $attributes = [], array $keys = ['count', 'dn'])
+ public function filterRawAttributes(array $attributes = [], array $keys = ['count', 'dn']): array
{
foreach ($keys as $key) {
unset($attributes[$key]);
@@ -937,42 +880,40 @@
/**
* Determine if the model has the given attribute.
- *
- * @param int|string $key
- *
- * @return bool
*/
- public function hasAttribute($key)
+ public function hasAttribute(int|string $key): bool
{
- return [] !== ($this->attributes[$this->normalizeAttributeKey($key)] ?? []);
+ return ($this->attributes[$this->normalizeAttributeKey($key)] ?? []) !== [];
}
/**
- * Returns the number of attributes.
- *
- * @return int
+ * Get the number of attributes.
*/
- public function countAttributes()
+ public function countAttributes(): int
{
return count($this->getAttributes());
}
/**
- * Returns the models original attributes.
- *
- * @return array
+ * Get the model's original attributes.
*/
- public function getOriginal()
+ public function getOriginal(): array
{
return $this->original;
}
/**
- * Get the attributes that have been changed since last sync.
- *
- * @return array
+ * Get the model's raw original attribute values.
*/
- public function getDirty()
+ public function getRawOriginal(string $key, mixed $default = null): mixed
+ {
+ return Arr::get($this->original, $key, $default);
+ }
+
+ /**
+ * Get the attributes that have been changed since last sync.
+ */
+ public function getDirty(): array
{
$dirty = [];
@@ -989,35 +930,69 @@
}
/**
- * Determine if the given attribute is dirty.
- *
- * @param string $key
- *
- * @return bool
+ * Get the attributes that have been changed since the model was last saved.
*/
- public function isDirty($key)
+ public function getChanges(): array
+ {
+ return $this->changes;
+ }
+
+ /**
+ * Determine if the given attribute is dirty.
+ */
+ public function isDirty(string $key): bool
{
return ! $this->originalIsEquivalent($key);
}
/**
- * Get the accessors being appended to the models array form.
- *
- * @return array
+ * Determine if given attribute has remained the same.
*/
- public function getAppends()
+ public function isClean(string $key): bool
+ {
+ return ! $this->isDirty($key);
+ }
+
+ /**
+ * Discard attribute changes and reset the attributes to their original state.
+ */
+ public function discardChanges(): static
+ {
+ [$this->attributes, $this->changes] = [$this->original, []];
+
+ return $this;
+ }
+
+ /**
+ * Determine if the model or any of the given attribute(s) were changed when the model was last saved.
+ */
+ public function wasChanged(array|string|null $attributes = null): bool
+ {
+ if (func_num_args() === 0) {
+ return count($this->changes) > 0;
+ }
+
+ foreach ((array) $attributes as $attribute) {
+ if (array_key_exists($attribute, $this->changes)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Get the accessors being appended to the models array form.
+ */
+ public function getAppends(): array
{
return $this->appends;
}
/**
* Set the accessors to append to model arrays.
- *
- * @param array $appends
- *
- * @return $this
*/
- public function setAppends(array $appends)
+ public function setAppends(array $appends): static
{
$this->appends = $appends;
@@ -1026,24 +1001,16 @@
/**
* Return whether the accessor attribute has been appended.
- *
- * @param string $attribute
- *
- * @return bool
*/
- public function hasAppended($attribute)
+ public function hasAppended(string $attribute): bool
{
return in_array($attribute, $this->appends);
}
/**
* Returns a normalized attribute key.
- *
- * @param string $key
- *
- * @return string
*/
- public function normalizeAttributeKey($key)
+ public function normalizeAttributeKey(string $key): string
{
// Since LDAP supports hyphens in attribute names,
// we'll convert attributes being retrieved by
@@ -1055,12 +1022,8 @@
/**
* Determine if the new and old values for a given key are equivalent.
- *
- * @param string $key
- *
- * @return bool
*/
- protected function originalIsEquivalent($key)
+ protected function originalIsEquivalent(string $key): bool
{
if (! array_key_exists($key, $this->original)) {
return false;
@@ -1073,17 +1036,15 @@
return true;
}
- return is_numeric($current) &&
+ return is_numeric($current) &&
is_numeric($original) &&
strcmp((string) $current, (string) $original) === 0;
}
/**
* Get the mutated attributes for a given instance.
- *
- * @return array
*/
- public function getMutatedAttributes()
+ public function getMutatedAttributes(): array
{
$class = static::class;
@@ -1096,28 +1057,19 @@
/**
* Extract and cache all the mutated attributes of a class.
- *
- * @param string $class
- *
- * @return void
*/
- public static function cacheMutatedAttributes($class)
+ public static function cacheMutatedAttributes(string $class): void
{
- static::$mutatorCache[$class] = collect(static::getMutatorMethods($class))->reject(function ($match) {
- return $match === 'First';
- })->map(function ($match) {
- return lcfirst($match);
- })->all();
+ static::$mutatorCache[$class] = collect(static::getMutatorMethods($class))
+ ->reject(fn ($match) => $match === 'First')
+ ->map(fn ($match) => lcfirst($match))
+ ->all();
}
/**
* Get all of the attribute mutator methods.
- *
- * @param mixed $class
- *
- * @return array
*/
- protected static function getMutatorMethods($class)
+ protected static function getMutatorMethods(string $class): array
{
preg_match_all('/(?<=^|;)get([^;]+?)Attribute(;|$)/', implode(';', get_class_methods($class)), $matches);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php
index 5adec96..7537f62 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasEvents.php
@@ -4,25 +4,24 @@
use Closure;
use LdapRecord\Events\NullDispatcher;
+use LdapRecord\Models\Events;
use LdapRecord\Models\Events\Event;
+use LdapRecord\Support\Arr;
+/** @mixin \LdapRecord\Models\Model */
trait HasEvents
{
/**
* Execute the callback without raising any events.
- *
- * @param Closure $callback
- *
- * @return mixed
*/
- protected static function withoutEvents(Closure $callback)
+ protected static function withoutEvents(Closure $callback): mixed
{
$container = static::getConnectionContainer();
- $dispatcher = $container->getEventDispatcher();
+ $dispatcher = $container->getDispatcher();
if ($dispatcher) {
- $container->setEventDispatcher(
+ $container->setDispatcher(
new NullDispatcher($dispatcher)
);
}
@@ -31,33 +30,44 @@
return $callback();
} finally {
if ($dispatcher) {
- $container->setEventDispatcher($dispatcher);
+ $container->setDispatcher($dispatcher);
}
}
}
/**
- * Fires the specified model event.
- *
- * @param Event $event
- *
- * @return mixed
+ * Dispatch the given model events.
*/
- protected function fireModelEvent(Event $event)
+ protected function dispatch(array|string $events, array $args = []): void
{
- return static::getConnectionContainer()->getEventDispatcher()->fire($event);
+ foreach (Arr::wrap($events) as $name) {
+ $this->fireCustomModelEvent($name, $args);
+ }
}
/**
- * Listens to a model event.
- *
- * @param string $event
- * @param Closure $listener
- *
- * @return mixed
+ * Fire a custom model event.
*/
- protected function listenForModelEvent($event, Closure $listener)
+ protected function fireCustomModelEvent(string $name, array $args = []): void
{
- return static::getConnectionContainer()->getEventDispatcher()->listen($event, $listener);
+ $event = implode('\\', [Events::class, ucfirst($name)]);
+
+ $this->fireModelEvent(new $event($this, ...$args));
+ }
+
+ /**
+ * Fire a model event.
+ */
+ protected function fireModelEvent(Event $event): void
+ {
+ static::getConnectionContainer()->getDispatcher()->fire($event);
+ }
+
+ /**
+ * Listen to a model event.
+ */
+ protected function listenForModelEvent(string $event, Closure $listener): void
+ {
+ static::getConnectionContainer()->getDispatcher()->listen($event, $listener);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php
index f7552c1..855ba37 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasGlobalScopes.php
@@ -6,51 +6,39 @@
use InvalidArgumentException;
use LdapRecord\Models\Scope;
+/** @mixin \LdapRecord\Models\Model */
trait HasGlobalScopes
{
/**
* Register a new global scope on the model.
*
- * @param Scope|Closure|string $scope
- * @param Closure|null $implementation
- *
- * @return mixed
- *
* @throws InvalidArgumentException
*/
- public static function addGlobalScope($scope, Closure $implementation = null)
+ public static function addGlobalScope(Scope|Closure|string $scope, ?Closure $implementation = null): void
{
if (is_string($scope) && ! is_null($implementation)) {
- return static::$globalScopes[static::class][$scope] = $implementation;
+ static::$globalScopes[static::class][$scope] = $implementation;
} elseif ($scope instanceof Closure) {
- return static::$globalScopes[static::class][spl_object_hash($scope)] = $scope;
+ static::$globalScopes[static::class][spl_object_hash($scope)] = $scope;
} elseif ($scope instanceof Scope) {
- return static::$globalScopes[static::class][get_class($scope)] = $scope;
+ static::$globalScopes[static::class][get_class($scope)] = $scope;
+ } else {
+ throw new InvalidArgumentException('Global scope must be an instance of Closure or Scope.');
}
-
- throw new InvalidArgumentException('Global scope must be an instance of Closure or Scope.');
}
/**
* Determine if a model has a global scope.
- *
- * @param Scope|string $scope
- *
- * @return bool
*/
- public static function hasGlobalScope($scope)
+ public static function hasGlobalScope(Scope|string $scope): bool
{
return ! is_null(static::getGlobalScope($scope));
}
/**
* Get a global scope registered with the model.
- *
- * @param Scope|string $scope
- *
- * @return Scope|Closure|null
*/
- public static function getGlobalScope($scope)
+ public static function getGlobalScope(Scope|string $scope): Scope|Closure|null
{
if (array_key_exists(static::class, static::$globalScopes)) {
$scopeName = is_string($scope) ? $scope : get_class($scope);
@@ -59,14 +47,14 @@
? static::$globalScopes[static::class][$scopeName]
: null;
}
+
+ return null;
}
/**
* Get the global scopes for this class instance.
- *
- * @return array
*/
- public function getGlobalScopes()
+ public function getGlobalScopes(): array
{
return array_key_exists(static::class, static::$globalScopes)
? static::$globalScopes[static::class]
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php
index 1a938c1..c84bd97 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasPassword.php
@@ -6,18 +6,17 @@
use LdapRecord\LdapRecordException;
use LdapRecord\Models\Attributes\Password;
+/** @mixin \LdapRecord\Models\Model */
trait HasPassword
{
/**
* Set the password on the user.
*
- * @param string|array $password
- *
* @throws ConnectionException
*/
- public function setPasswordAttribute($password)
+ public function setPasswordAttribute(array|string $password): void
{
- $this->validateSecureConnection();
+ $this->assertSecureConnection();
// Here we will attempt to determine the password hash method in use
// by parsing the users hashed password (if it as available). If a
@@ -48,31 +47,25 @@
/**
* Alias for setting the password on the user.
*
- * @param string|array $password
- *
* @throws ConnectionException
*/
- public function setUnicodepwdAttribute($password)
+ public function setUnicodepwdAttribute(array|string $password): void
{
$this->setPasswordAttribute($password);
}
/**
* An accessor for retrieving the user's hashed password value.
- *
- * @return string|null
*/
- public function getPasswordAttribute()
+ public function getPasswordAttribute(): ?string
{
return $this->getAttribute($this->getPasswordAttributeName())[0] ?? null;
}
/**
* Get the name of the attribute that contains the user's password.
- *
- * @return string
*/
- public function getPasswordAttributeName()
+ public function getPasswordAttributeName(): string
{
if (property_exists($this, 'passwordAttribute')) {
return $this->passwordAttribute;
@@ -87,10 +80,8 @@
/**
* Get the name of the method to use for hashing the user's password.
- *
- * @return string
*/
- public function getPasswordHashMethod()
+ public function getPasswordHashMethod(): string
{
if (property_exists($this, 'passwordHashMethod')) {
return $this->passwordHashMethod;
@@ -105,14 +96,8 @@
/**
* Set the changed password.
- *
- * @param string $oldPassword
- * @param string $newPassword
- * @param string $attribute
- *
- * @return void
*/
- protected function setChangedPassword($oldPassword, $newPassword, $attribute)
+ protected function setChangedPassword(string $oldPassword, string $newPassword, string $attribute): void
{
// Create batch modification for removing the old password.
$this->addModification(
@@ -135,14 +120,15 @@
/**
* Set the password on the model.
- *
- * @param string $password
- * @param string $attribute
- *
- * @return void
*/
- protected function setPassword($password, $attribute)
+ protected function setPassword(string $password, string $attribute): void
{
+ if (! $this->exists) {
+ $this->setRawAttribute($attribute, $password);
+
+ return;
+ }
+
$this->addModification(
$this->newBatchModification(
$attribute,
@@ -155,15 +141,9 @@
/**
* Encode / hash the given password.
*
- * @param string $method
- * @param string $password
- * @param string $salt
- *
- * @return string
- *
* @throws LdapRecordException
*/
- protected function getHashedPassword($method, $password, $salt = null)
+ protected function getHashedPassword(string $method, string $password, ?string $salt = null): string
{
if (! method_exists(Password::class, $method)) {
throw new LdapRecordException("Password hashing method [{$method}] does not exist.");
@@ -179,18 +159,22 @@
/**
* Validates that the current LDAP connection is secure.
*
- * @return void
- *
* @throws ConnectionException
*/
- protected function validateSecureConnection()
+ protected function assertSecureConnection(): void
{
$connection = $this->getConnection();
+ $config = $connection->getConfiguration();
+
+ if ($config->get('allow_insecure_password_changes') === true) {
+ return;
+ }
+
if ($connection->isConnected()) {
$secure = $connection->getLdapConnection()->canChangePasswords();
} else {
- $secure = $connection->getConfiguration()->get('use_ssl') || $connection->getConfiguration()->get('use_tls');
+ $secure = $config->get('use_ssl') || $config->get('use_tls');
}
if (! $secure) {
@@ -202,15 +186,11 @@
/**
* Attempt to retrieve the password's salt.
- *
- * @param string $method
- *
- * @return string|null
*/
- public function getPasswordSalt($method)
+ public function getPasswordSalt(string $method): ?string
{
if (! Password::hashMethodRequiresSalt($method)) {
- return;
+ return null;
}
return Password::getSalt($this->password);
@@ -237,15 +217,11 @@
$value = null
);
- switch ($algo) {
- case Password::CRYPT_SALT_TYPE_MD5:
- return 'md5'.$method;
- case Password::CRYPT_SALT_TYPE_SHA256:
- return 'sha256'.$method;
- case Password::CRYPT_SALT_TYPE_SHA512:
- return 'sha512'.$method;
- default:
- return $method;
- }
+ return match ((int) $algo) {
+ Password::CRYPT_SALT_TYPE_MD5 => 'md5'.$method,
+ Password::CRYPT_SALT_TYPE_SHA256 => 'sha256'.$method,
+ Password::CRYPT_SALT_TYPE_SHA512 => 'sha512'.$method,
+ default => $method,
+ };
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasRelationships.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasRelationships.php
index a8a5cac..e81c3a1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasRelationships.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasRelationships.php
@@ -5,58 +5,63 @@
use LdapRecord\Models\Relations\HasMany;
use LdapRecord\Models\Relations\HasManyIn;
use LdapRecord\Models\Relations\HasOne;
+use LdapRecord\Models\Relations\Relation;
use LdapRecord\Support\Arr;
trait HasRelationships
{
/**
* Returns a new has one relationship.
- *
- * @param mixed $related
- * @param string $relationKey
- * @param string $foreignKey
- *
- * @return HasOne
*/
- public function hasOne($related, $relationKey, $foreignKey = 'dn')
+ public function hasOne(array|string $related, string $relationKey, string $foreignKey = 'dn'): HasOne
{
return new HasOne($this->newQuery(), $this, $related, $relationKey, $foreignKey);
}
/**
* Returns a new has many relationship.
- *
- * @param mixed $related
- * @param string $relationKey
- * @param string $foreignKey
- *
- * @return HasMany
*/
- public function hasMany($related, $relationKey, $foreignKey = 'dn')
+ public function hasMany(array|string $related, string $relationKey, string $foreignKey = 'dn'): HasMany
{
return new HasMany($this->newQuery(), $this, $related, $relationKey, $foreignKey, $this->guessRelationshipName());
}
/**
* Returns a new has many in relationship.
- *
- * @param mixed $related
- * @param string $relationKey
- * @param string $foreignKey
- *
- * @return HasManyIn
*/
- public function hasManyIn($related, $relationKey, $foreignKey = 'dn')
+ public function hasManyIn(array|string $related, string $relationKey, string $foreignKey = 'dn'): HasManyIn
{
return new HasManyIn($this->newQuery(), $this, $related, $relationKey, $foreignKey, $this->guessRelationshipName());
}
/**
- * Get the relationships name.
- *
- * @return string|null
+ * Get a relationship by its name.
*/
- protected function guessRelationshipName()
+ public function getRelation(?string $relationName = null): ?Relation
+ {
+ if (is_null($relationName)) {
+ return null;
+ }
+
+ if (! method_exists($this, $relationName)) {
+ return null;
+ }
+
+ if (! $relation = $this->{$relationName}()) {
+ return null;
+ }
+
+ if (! $relation instanceof Relation) {
+ return null;
+ }
+
+ return $relation;
+ }
+
+ /**
+ * Get the relationships name.
+ */
+ protected function guessRelationshipName(): ?string
{
return Arr::last(debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 3))['function'];
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasScopes.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasScopes.php
index 6c97cf9..7420620 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasScopes.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HasScopes.php
@@ -2,37 +2,34 @@
namespace LdapRecord\Models\Concerns;
+use LdapRecord\Query\Model\Builder;
+
+/** @mixin \LdapRecord\Models\Model */
trait HasScopes
{
/**
* Begin querying the direct descendants of the model.
- *
- * @return \LdapRecord\Query\Model\Builder
*/
- public function descendants()
+ public function descendants(): Builder
{
- return $this->in($this->getDn())->listing();
+ return $this->in($this->getDn())->list();
}
/**
* Begin querying the direct ancestors of the model.
- *
- * @return \LdapRecord\Query\Model\Builder
*/
- public function ancestors()
+ public function ancestors(): Builder
{
$parent = $this->getParentDn($this->getDn());
- return $this->in($this->getParentDn($parent))->listing();
+ return $this->in($this->getParentDn($parent))->list();
}
/**
* Begin querying the direct siblings of the model.
- *
- * @return \LdapRecord\Query\Model\Builder
*/
- public function siblings()
+ public function siblings(): Builder
{
- return $this->in($this->getParentDn($this->getDn()))->listing();
+ return $this->in($this->getParentDn($this->getDn()))->list();
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HidesAttributes.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HidesAttributes.php
index 9cc2100..533e8fc 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HidesAttributes.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/HidesAttributes.php
@@ -6,43 +6,36 @@
* @author Taylor Otwell
*
* @see https://laravel.com
+ *
+ * @mixin \LdapRecord\Models\Model
*/
trait HidesAttributes
{
/**
* The attributes that should be hidden for serialization.
- *
- * @var array
*/
- protected $hidden = [];
+ protected array $hidden = [];
/**
* The attributes that should be visible in serialization.
- *
- * @var array
*/
- protected $visible = [];
+ protected array $visible = [];
/**
* Get the hidden attributes for the model.
- *
- * @return array
*/
- public function getHidden()
+ public function getHidden(): array
{
- return array_map(function ($key) {
- return $this->normalizeAttributeKey($key);
- }, $this->hidden);
+ return array_map(
+ $this->normalizeAttributeKey(...),
+ $this->hidden
+ );
}
/**
* Set the hidden attributes for the model.
- *
- * @param array $hidden
- *
- * @return $this
*/
- public function setHidden(array $hidden)
+ public function setHidden(array $hidden): static
{
$this->hidden = $hidden;
@@ -51,12 +44,8 @@
/**
* Add hidden attributes for the model.
- *
- * @param array|string|null $attributes
- *
- * @return void
*/
- public function addHidden($attributes = null)
+ public function addHidden(array|string|null $attributes = null): void
{
$this->hidden = array_merge(
$this->hidden,
@@ -66,24 +55,19 @@
/**
* Get the visible attributes for the model.
- *
- * @return array
*/
- public function getVisible()
+ public function getVisible(): array
{
- return array_map(function ($key) {
- return $this->normalizeAttributeKey($key);
- }, $this->visible);
+ return array_map(
+ $this->normalizeAttributeKey(...),
+ $this->visible
+ );
}
/**
* Set the visible attributes for the model.
- *
- * @param array $visible
- *
- * @return $this
*/
- public function setVisible(array $visible)
+ public function setVisible(array $visible): static
{
$this->visible = $visible;
@@ -92,12 +76,8 @@
/**
* Add visible attributes for the model.
- *
- * @param array|string|null $attributes
- *
- * @return void
*/
- public function addVisible($attributes = null)
+ public function addVisible(array|string|null $attributes = null): void
{
$this->visible = array_merge(
$this->visible,
@@ -107,12 +87,8 @@
/**
* Make the given, typically hidden, attributes visible.
- *
- * @param array|string $attributes
- *
- * @return $this
*/
- public function makeVisible($attributes)
+ public function makeVisible(array|string $attributes): static
{
$this->hidden = array_diff($this->hidden, (array) $attributes);
@@ -125,12 +101,8 @@
/**
* Make the given, typically visible, attributes hidden.
- *
- * @param array|string $attributes
- *
- * @return $this
*/
- public function makeHidden($attributes)
+ public function makeHidden(array|string $attributes): static
{
$attributes = (array) $attributes;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/SerializesAndRestoresPropertyValues.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/SerializesAndRestoresPropertyValues.php
new file mode 100644
index 0000000..bc4fa28
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/SerializesAndRestoresPropertyValues.php
@@ -0,0 +1,39 @@
+<?php
+
+namespace LdapRecord\Models\Concerns;
+
+/** @mixin HasAttributes */
+trait SerializesAndRestoresPropertyValues
+{
+ /**
+ * Get the property value prepared for serialization.
+ */
+ protected function getSerializedPropertyValue(string $property, mixed $value): mixed
+ {
+ if ($property === 'original') {
+ return $this->originalToArray();
+ }
+
+ if ($property === 'attributes') {
+ return $this->attributesToArray();
+ }
+
+ return $value;
+ }
+
+ /**
+ * Get the unserialized property value after deserialization.
+ */
+ protected function getUnserializedPropertyValue(string $property, mixed $value): mixed
+ {
+ if ($property === 'original') {
+ return $this->arrayToOriginal($value);
+ }
+
+ if ($property === 'attributes') {
+ return $this->arrayToAttributes($value);
+ }
+
+ return $value;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/SerializesProperties.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/SerializesProperties.php
new file mode 100644
index 0000000..65428fa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Concerns/SerializesProperties.php
@@ -0,0 +1,131 @@
+<?php
+
+namespace LdapRecord\Models\Concerns;
+
+use ReflectionClass;
+use ReflectionProperty;
+
+trait SerializesProperties
+{
+ use SerializesAndRestoresPropertyValues;
+
+ /**
+ * Prepare the attributes for serialization.
+ */
+ public function __sleep(): array
+ {
+ $properties = (new ReflectionClass($this))->getProperties();
+
+ foreach ($properties as $property) {
+ $property->setValue($this, $this->getSerializedPropertyValue(
+ $property->getName(),
+ $this->getPropertyValue($property)
+ ));
+ }
+
+ return array_values(array_filter(
+ array_map(fn ($p) => $p->isStatic() ? null : $p->getName(), $properties)
+ ));
+ }
+
+ /**
+ * Restore the attributes after serialization.
+ */
+ public function __wakeup(): void
+ {
+ foreach ((new ReflectionClass($this))->getProperties() as $property) {
+ if ($property->isStatic()) {
+ continue;
+ }
+
+ $property->setValue($this, $this->getUnserializedPropertyValue(
+ $property->getName(),
+ $this->getPropertyValue($property)
+ ));
+ }
+ }
+
+ /**
+ * Prepare the model for serialization.
+ */
+ public function __serialize(): array
+ {
+ $values = [];
+
+ $properties = (new ReflectionClass($this))->getProperties();
+
+ $class = get_class($this);
+
+ foreach ($properties as $property) {
+ if ($property->isStatic()) {
+ continue;
+ }
+
+ $property->setAccessible(true);
+
+ if (! $property->isInitialized($this)) {
+ continue;
+ }
+
+ $name = $property->getName();
+
+ if ($property->isPrivate()) {
+ $name = "\0{$class}\0{$name}";
+ } elseif ($property->isProtected()) {
+ $name = "\0*\0{$name}";
+ }
+
+ $values[$name] = $this->getSerializedPropertyValue(
+ $property->getName(),
+ $this->getPropertyValue($property)
+ );
+ }
+
+ return $values;
+ }
+
+ /**
+ * Restore the model after serialization.
+ */
+ public function __unserialize(array $values): void
+ {
+ $properties = (new ReflectionClass($this))->getProperties();
+
+ $class = get_class($this);
+
+ foreach ($properties as $property) {
+ if ($property->isStatic()) {
+ continue;
+ }
+
+ $name = $property->getName();
+
+ if ($property->isPrivate()) {
+ $name = "\0{$class}\0{$name}";
+ } elseif ($property->isProtected()) {
+ $name = "\0*\0{$name}";
+ }
+
+ if (! array_key_exists($name, $values)) {
+ continue;
+ }
+
+ $property->setAccessible(true);
+
+ $property->setValue(
+ $this,
+ $this->getUnserializedPropertyValue($property->getName(), $values[$name])
+ );
+ }
+ }
+
+ /**
+ * Get the property value for the given property.
+ */
+ protected function getPropertyValue(ReflectionProperty $property): mixed
+ {
+ $property->setAccessible(true);
+
+ return $property->getValue($this);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DetectsResetIntegers.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DetectsResetIntegers.php
index 8712ef7..1f2e826 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DetectsResetIntegers.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DetectsResetIntegers.php
@@ -10,13 +10,9 @@
* The integer values '0' and '-1' can be used on certain
* LDAP attributes to instruct the server to reset the
* value to an 'unset' or 'cleared' state.
- *
- * @param mixed $value
- *
- * @return bool
*/
- protected function valueIsResetInteger($value)
+ protected function valueIsResetInteger(mixed $value): bool
{
- return in_array($value, [0, -1], $strict = true);
+ return in_array($value, [0, -1], true);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Entry.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Entry.php
index 1bf8325..947daca 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Entry.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Entry.php
@@ -3,13 +3,12 @@
namespace LdapRecord\Models\DirectoryServer;
use LdapRecord\Models\Model;
+use LdapRecord\Models\Types\DirectoryServer;
-class Entry extends Model
+class Entry extends Model implements DirectoryServer
{
/**
* The attribute key that contains the models object GUID.
- *
- * @var string
*/
- protected $guidKey = 'gidNumber';
+ protected string $guidKey = 'gidNumber';
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Group.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Group.php
index 49a6e0a..c5b0c17 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Group.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/Group.php
@@ -6,10 +6,8 @@
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'groupOfUniqueNames',
'posixGroup',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/User.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/User.php
index 430588b..4a3bc14 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/User.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/DirectoryServer/User.php
@@ -6,10 +6,8 @@
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'nsPerson',
'nsAccount',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Event.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Event.php
index 20de0b7..340bc2e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Event.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Event.php
@@ -8,15 +8,11 @@
{
/**
* The model that the event is being triggered on.
- *
- * @var Model
*/
- protected $model;
+ protected Model $model;
/**
* Constructor.
- *
- * @param Model $model
*/
public function __construct(Model $model)
{
@@ -24,11 +20,9 @@
}
/**
- * Returns the model that generated the event.
- *
- * @return Model
+ * Get the model that generated the event.
*/
- public function getModel()
+ public function getModel(): Model
{
return $this->model;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Renaming.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Renaming.php
index 83427ca..4890e2b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Renaming.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Events/Renaming.php
@@ -8,26 +8,18 @@
{
/**
* The models RDN.
- *
- * @var string
*/
- protected $rdn;
+ protected string $rdn;
/**
* The models new parent DN.
- *
- * @var string
*/
- protected $newParentDn;
+ protected string $newParentDn;
/**
* Constructor.
- *
- * @param Model $model
- * @param string $rdn
- * @param string $newParentDn
*/
- public function __construct(Model $model, $rdn, $newParentDn)
+ public function __construct(Model $model, string $rdn, string $newParentDn)
{
parent::__construct($model);
@@ -37,20 +29,16 @@
/**
* Get the models RDN.
- *
- * @return string
*/
- public function getRdn()
+ public function getRdn(): string
{
return $this->rdn;
}
/**
* Get the models parent DN.
- *
- * @return string
*/
- public function getNewParentDn()
+ public function getNewParentDn(): string
{
return $this->newParentDn;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Entry.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Entry.php
index 7fdda9c..4f29ef0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Entry.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Entry.php
@@ -13,42 +13,34 @@
{
/**
* The attribute key that contains the models object GUID.
- *
- * @var string
*/
- protected $guidKey = 'ipauniqueid';
+ protected string $guidKey = 'ipauniqueid';
/**
* The default attributes that should be mutated to dates.
- *
- * @var array
*/
- protected $defaultDates = [
+ protected array $defaultDates = [
'krblastpwdchange' => 'ldap',
'krbpasswordexpiration' => 'ldap',
];
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected static function boot()
+ protected static function boot(): void
{
parent::boot();
// Here we'll add a global scope to all FreeIPA models to ensure the
// Entry UUID is always selected on each query. This attribute is
// virtual, so it must be manually selected to be included.
- static::addGlobalScope(new AddEntryUuidToSelects());
+ static::addGlobalScope(new AddEntryUuidToSelects);
}
/**
* Create a new query builder.
- *
- * @param Connection $connection
- *
- * @return FreeIpaBuilder
*/
- public function newQueryBuilder(Connection $connection)
+ public function newQueryBuilder(Connection $connection): FreeIpaBuilder
{
return new FreeIpaBuilder($connection);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Group.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Group.php
index 10fd934..9419775 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Group.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Group.php
@@ -2,14 +2,14 @@
namespace LdapRecord\Models\FreeIPA;
+use LdapRecord\Models\Relations\HasMany;
+
class Group extends Entry
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'groupofnames',
'nestedgroup',
@@ -20,21 +20,17 @@
/**
* The groups relationship.
*
- * Retrieves groups that the current group is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
+ * Retrieves groups that the current group is a part of.
*/
- public function groups()
+ public function groups(): HasMany
{
return $this->hasMany(self::class, 'member');
}
/**
* Retrieve the members of the group.
- *
- * @return \LdapRecord\Models\Relations\HasMany
*/
- public function members()
+ public function members(): HasMany
{
return $this->hasMany(User::class, 'memberof')->using($this, 'member');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Scopes/AddEntryUuidToSelects.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Scopes/AddEntryUuidToSelects.php
index 039c05e..d35ed91 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Scopes/AddEntryUuidToSelects.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/Scopes/AddEntryUuidToSelects.php
@@ -10,13 +10,8 @@
{
/**
* Add the entry UUID to the selected attributes.
- *
- * @param Builder $query
- * @param Model $model
- *
- * @return void
*/
- public function apply(Builder $query, Model $model)
+ public function apply(Builder $query, Model $model): void
{
empty($query->columns)
? $query->addSelect(['*', $model->getGuidKey()])
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/User.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/User.php
index 24c7f3b..47964f0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/User.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/FreeIPA/User.php
@@ -2,14 +2,14 @@
namespace LdapRecord\Models\FreeIPA;
+use LdapRecord\Models\Relations\HasMany;
+
class User extends Entry
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'person',
'inetorgperson',
@@ -17,11 +17,9 @@
];
/**
- * Retrieve groups that the current user is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
+ * Retrieve groups that the current user is a part of.
*/
- public function groups()
+ public function groups(): HasMany
{
return $this->hasMany(Group::class, 'member');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php
index 2e11696..b17d079 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Model.php
@@ -11,111 +11,92 @@
use LdapRecord\EscapesValues;
use LdapRecord\Models\Attributes\DistinguishedName;
use LdapRecord\Models\Attributes\Guid;
-use LdapRecord\Models\Events\Renamed;
-use LdapRecord\Models\Events\Renaming;
+use LdapRecord\Query\Builder as BaseBuilder;
use LdapRecord\Query\Model\Builder;
use LdapRecord\Support\Arr;
+use RuntimeException;
+use Stringable;
use UnexpectedValueException;
/** @mixin Builder */
-abstract class Model implements ArrayAccess, Arrayable, JsonSerializable
+abstract class Model implements Arrayable, ArrayAccess, JsonSerializable, Stringable
{
- use EscapesValues;
- use Concerns\HasEvents;
- use Concerns\HasScopes;
use Concerns\HasAttributes;
+ use Concerns\HasEvents;
use Concerns\HasGlobalScopes;
- use Concerns\HidesAttributes;
use Concerns\HasRelationships;
+ use Concerns\HasScopes;
+ use Concerns\HidesAttributes;
+ use Concerns\SerializesProperties;
+ use EscapesValues;
/**
* Indicates if the model exists in the directory.
- *
- * @var bool
*/
- public $exists = false;
+ public bool $exists = false;
/**
* Indicates whether the model was created during the current request lifecycle.
- *
- * @var bool
*/
- public $wasRecentlyCreated = false;
+ public bool $wasRecentlyCreated = false;
/**
* Indicates whether the model was renamed during the current request lifecycle.
- *
- * @var bool
*/
- public $wasRecentlyRenamed = false;
+ public bool $wasRecentlyRenamed = false;
/**
* The models distinguished name.
- *
- * @var string|null
*/
- protected $dn;
+ protected ?string $dn = null;
/**
* The base DN of where the model should be created in.
- *
- * @var string|null
*/
- protected $in;
+ protected ?string $in = null;
/**
* The object classes of the model.
- *
- * @var array
*/
- public static $objectClasses = [];
+ public static array $objectClasses = [];
/**
* The connection container instance.
- *
- * @var Container
*/
- protected static $container;
+ protected static ?Container $container = null;
/**
* The connection name for the model.
- *
- * @var string|null
*/
- protected $connection;
+ protected ?string $connection = null;
/**
- * The attribute key that contains the models object GUID.
- *
- * @var string
+ * The attribute key containing the models object GUID.
*/
- protected $guidKey = 'objectguid';
+ protected string $guidKey = 'objectguid';
/**
- * Contains the models modifications.
- *
- * @var array
+ * The array of the model's modifications.
*/
- protected $modifications = [];
-
- /**
- * The array of global scopes on the model.
- *
- * @var array
- */
- protected static $globalScopes = [];
+ protected array $modifications = [];
/**
* The array of booted models.
- *
- * @var array
*/
- protected static $booted = [];
+ protected static array $booted = [];
+
+ /**
+ * The array of global scopes on the model.
+ */
+ protected static array $globalScopes = [];
+
+ /**
+ * The morph model cache containing object classes and their corresponding models.
+ */
+ protected static array $morphCache = [];
/**
* Constructor.
- *
- * @param array $attributes
*/
public function __construct(array $attributes = [])
{
@@ -126,10 +107,8 @@
/**
* Check if the model needs to be booted and if so, do it.
- *
- * @return void
*/
- protected function bootIfNotBooted()
+ protected function bootIfNotBooted(): void
{
if (! isset(static::$booted[static::class])) {
static::$booted[static::class] = true;
@@ -140,20 +119,16 @@
/**
* The "boot" method of the model.
- *
- * @return void
*/
- protected static function boot()
+ protected static function boot(): void
{
//
}
/**
- * Clear the list of booted models so they will be re-booted.
- *
- * @return void
+ * Clear the list of booted models, so they will be re-booted.
*/
- public static function clearBootedModels()
+ public static function clearBootedModels(): void
{
static::$booted = [];
@@ -162,13 +137,8 @@
/**
* Handle dynamic method calls into the model.
- *
- * @param string $method
- * @param array $parameters
- *
- * @return mixed
*/
- public function __call($method, $parameters)
+ public function __call(string $method, array $parameters): mixed
{
if (method_exists($this, $method)) {
return $this->$method(...$parameters);
@@ -179,93 +149,66 @@
/**
* Handle dynamic static method calls into the method.
- *
- * @param string $method
- * @param array $parameters
- *
- * @return mixed
*/
- public static function __callStatic($method, $parameters)
+ public static function __callStatic(string $method, array $parameters): mixed
{
- return (new static())->$method(...$parameters);
+ return (new static)->$method(...$parameters);
}
/**
- * Returns the models distinguished name.
- *
- * @return string|null
+ * Get the models distinguished name.
*/
- public function getDn()
+ public function getDn(): ?string
{
return $this->dn;
}
/**
- * Set the models distinguished name.
- *
- * @param string $dn
- *
- * @return $this
+ * Set the model's distinguished name.
*/
- public function setDn($dn)
+ public function setDn(?string $dn = null): static
{
- $this->dn = (string) $dn;
+ $this->dn = $dn;
return $this;
}
/**
- * A mutator for setting the models distinguished name.
- *
- * @param string $dn
- *
- * @return $this
+ * A mutator for setting the model's distinguished name.
*/
- public function setDnAttribute($dn)
+ public function setDnAttribute(string $dn): static
{
return $this->setRawAttribute('dn', $dn)->setDn($dn);
}
/**
- * A mutator for setting the models distinguished name.
- *
- * @param string $dn
- *
- * @return $this
+ * A mutator for setting the model's distinguished name.
*/
- public function setDistinguishedNameAttribute($dn)
+ public function setDistinguishedNameAttribute(string $dn): static
{
return $this->setRawAttribute('distinguishedname', $dn)->setDn($dn);
}
/**
* Get the connection for the model.
- *
- * @return Connection
*/
- public function getConnection()
+ public function getConnection(): Connection
{
return static::resolveConnection($this->getConnectionName());
}
/**
* Get the current connection name for the model.
- *
- * @return string
*/
- public function getConnectionName()
+ public function getConnectionName(): ?string
{
return $this->connection;
}
/**
* Set the connection associated with the model.
- *
- * @param string $name
- *
- * @return $this
*/
- public function setConnection($name)
+ public function setConnection(?string $name = null): static
{
$this->connection = $name;
@@ -273,15 +216,19 @@
}
/**
- * Begin querying the model on a given connection.
- *
- * @param string|null $connection
- *
- * @return Builder
+ * Make a new model instance.
*/
- public static function on($connection = null)
+ public static function make(array $attributes = []): static
{
- $instance = new static();
+ return new static($attributes);
+ }
+
+ /**
+ * Begin querying the model on a given connection.
+ */
+ public static function on(?string $connection = null): Builder
+ {
+ $instance = new static;
$instance->setConnection($connection);
@@ -290,44 +237,59 @@
/**
* Get all the models from the directory.
- *
- * @param array|mixed $attributes
- *
- * @return Collection|static[]
*/
- public static function all($attributes = ['*'])
+ public static function all(array|string $attributes = ['*']): array|Collection
{
return static::query()->select($attributes)->paginate();
}
/**
- * Make a new model instance.
+ * Get the RootDSE (AD schema) record from the directory.
*
- * @param array $attributes
- *
- * @return static
+ * @throws \LdapRecord\Models\ModelNotFoundException
*/
- public static function make($attributes = [])
+ public static function getRootDse(?string $connection = null): Model
{
- return new static($attributes);
+ /** @var Model $model */
+ $model = static::getRootDseModel();
+
+ return $model::on($connection ?? (new $model)->getConnectionName())
+ ->in()
+ ->read()
+ ->whereHas('objectclass')
+ ->firstOrFail();
+ }
+
+ /**
+ * Get the root DSE model.
+ *
+ * @return class-string<Model>
+ */
+ protected static function getRootDseModel(): string
+ {
+ $instance = new static;
+
+ return match (true) {
+ $instance instanceof Types\ActiveDirectory => ActiveDirectory\Entry::class,
+ $instance instanceof Types\DirectoryServer => DirectoryServer\Entry::class,
+ $instance instanceof Types\OpenLDAP => OpenLDAP\Entry::class,
+ $instance instanceof Types\FreeIPA => FreeIPA\Entry::class,
+ default => Entry::class,
+ };
}
/**
* Begin querying the model.
- *
- * @return Builder
*/
- public static function query()
+ public static function query(): Builder
{
- return (new static())->newQuery();
+ return (new static)->newQuery();
}
/**
* Get a new query for builder filtered by the current models object classes.
- *
- * @return Builder
*/
- public function newQuery()
+ public function newQuery(): Builder
{
return $this->registerModelScopes(
$this->newQueryWithoutScopes()
@@ -336,10 +298,8 @@
/**
* Get a new query builder that doesn't have any global scopes.
- *
- * @return Builder
*/
- public function newQueryWithoutScopes()
+ public function newQueryWithoutScopes(): Builder
{
return static::resolveConnection(
$this->getConnectionName()
@@ -348,90 +308,64 @@
/**
* Create a new query builder.
- *
- * @param Connection $connection
- *
- * @return Builder
*/
- public function newQueryBuilder(Connection $connection)
+ public function newQueryBuilder(Connection $connection): Builder
{
return new Builder($connection);
}
/**
* Create a new model instance.
- *
- * @param array $attributes
- *
- * @return static
*/
- public function newInstance(array $attributes = [])
+ public function newInstance(array $attributes = []): static
{
return (new static($attributes))->setConnection($this->getConnectionName());
}
/**
* Resolve a connection instance.
- *
- * @param string|null $connection
- *
- * @return Connection
*/
- public static function resolveConnection($connection = null)
+ public static function resolveConnection(?string $connection = null): Connection
{
- return static::getConnectionContainer()->get($connection);
+ return static::getConnectionContainer()->getConnection($connection);
}
/**
* Get the connection container.
- *
- * @return Container
*/
- public static function getConnectionContainer()
+ public static function getConnectionContainer(): Container
{
return static::$container ?? static::getDefaultConnectionContainer();
}
/**
* Get the default singleton container instance.
- *
- * @return Container
*/
- public static function getDefaultConnectionContainer()
+ public static function getDefaultConnectionContainer(): Container
{
return Container::getInstance();
}
/**
* Set the connection container.
- *
- * @param Container $container
- *
- * @return void
*/
- public static function setConnectionContainer(Container $container)
+ public static function setConnectionContainer(Container $container): void
{
static::$container = $container;
}
/**
* Unset the connection container.
- *
- * @return void
*/
- public static function unsetConnectionContainer()
+ public static function unsetConnectionContainer(): void
{
static::$container = null;
}
/**
* Register the query scopes for this builder instance.
- *
- * @param Builder $builder
- *
- * @return Builder
*/
- public function registerModelScopes($builder)
+ public function registerModelScopes(Builder $builder): Builder
{
$this->applyObjectClassScopes($builder);
@@ -442,12 +376,8 @@
/**
* Register the global model scopes.
- *
- * @param Builder $builder
- *
- * @return Builder
*/
- public function registerGlobalScopes($builder)
+ public function registerGlobalScopes(Builder $builder): Builder
{
foreach ($this->getGlobalScopes() as $identifier => $scope) {
$builder->withGlobalScope($identifier, $scope);
@@ -458,12 +388,8 @@
/**
* Apply the model object class scopes to the given builder instance.
- *
- * @param Builder $query
- *
- * @return void
*/
- public function applyObjectClassScopes(Builder $query)
+ public function applyObjectClassScopes(Builder $query): void
{
foreach (static::$objectClasses as $objectClass) {
$query->where('objectclass', '=', $objectClass);
@@ -471,180 +397,143 @@
}
/**
- * Returns the models distinguished name when the model is converted to a string.
- *
- * @return null|string
+ * Get the models distinguished name when the model is converted to a string.
*/
- public function __toString()
+ public function __toString(): string
{
- return $this->getDn();
+ return (string) $this->getDn();
}
/**
* Returns a new batch modification.
- *
- * @param string|null $attribute
- * @param string|int|null $type
- * @param array $values
- *
- * @return BatchModification
*/
- public function newBatchModification($attribute = null, $type = null, $values = [])
+ public function newBatchModification(?string $attribute = null, ?int $type = null, array $values = []): BatchModification
{
return new BatchModification($attribute, $type, $values);
}
/**
* Returns a new collection with the specified items.
- *
- * @param mixed $items
- *
- * @return Collection
*/
- public function newCollection($items = [])
+ public function newCollection(mixed $items = []): Collection
{
return new Collection($items);
}
/**
* Dynamically retrieve attributes on the object.
- *
- * @param mixed $key
- *
- * @return bool
*/
- public function __get($key)
+ public function __get(string $key): mixed
{
return $this->getAttribute($key);
}
/**
* Dynamically set attributes on the object.
- *
- * @param mixed $key
- * @param mixed $value
- *
- * @return $this
*/
- public function __set($key, $value)
+ public function __set(string $key, mixed $value): void
{
- return $this->setAttribute($key, $value);
+ $this->setAttribute($key, $value);
}
/**
* Determine if the given offset exists.
- *
- * @param string $offset
- *
- * @return bool
*/
#[\ReturnTypeWillChange]
- public function offsetExists($offset)
+ public function offsetExists(mixed $offset): bool
{
return ! is_null($this->getAttribute($offset));
}
/**
* Get the value for a given offset.
- *
- * @param string $offset
- *
- * @return mixed
*/
#[\ReturnTypeWillChange]
- public function offsetGet($offset)
+ public function offsetGet(mixed $offset): mixed
{
return $this->getAttribute($offset);
}
/**
* Set the value at the given offset.
- *
- * @param string $offset
- * @param mixed $value
- *
- * @return void
*/
#[\ReturnTypeWillChange]
- public function offsetSet($offset, $value)
+ public function offsetSet(mixed $offset, mixed $value): void
{
$this->setAttribute($offset, $value);
}
/**
* Unset the value at the given offset.
- *
- * @param string $offset
- *
- * @return void
*/
#[\ReturnTypeWillChange]
- public function offsetUnset($offset)
+ public function offsetUnset(mixed $offset): void
{
unset($this->attributes[$offset]);
}
/**
* Determine if an attribute exists on the model.
- *
- * @param string $key
- *
- * @return bool
*/
- public function __isset($key)
+ public function __isset(string $key): bool
{
return $this->offsetExists($key);
}
/**
* Unset an attribute on the model.
- *
- * @param string $key
- *
- * @return void
*/
- public function __unset($key)
+ public function __unset(string $key): void
{
$this->offsetUnset($key);
}
/**
* Convert the model to its JSON encodeable array form.
- *
- * @return array
*/
- public function toArray()
+ public function toArray(): array
{
return $this->attributesToArray();
}
/**
* Convert the model's attributes into JSON encodeable values.
- *
- * @return array
*/
#[\ReturnTypeWillChange]
- public function jsonSerialize()
+ public function jsonSerialize(): array
{
return $this->toArray();
}
/**
- * Converts extra attributes for JSON serialization.
- *
- * @param array $attributes
- *
- * @return array
+ * Convert the attributes for JSON serialization.
*/
- protected function convertAttributesForJson(array $attributes = [])
+ protected function convertAttributesForJson(array $attributes = []): array
{
- // If the model has a GUID set, we need to convert
- // it due to it being in binary. Otherwise we'll
- // receive a JSON serialization exception.
- if ($this->hasAttribute($this->guidKey)) {
- return array_replace($attributes, [
- $this->guidKey => [$this->getConvertedGuid()],
- ]);
+ // If the model has a GUID set, we need to convert it to its
+ // string format, due to it being in binary. Otherwise,
+ // we will receive a JSON serialization exception.
+ if (isset($attributes[$this->guidKey])) {
+ $attributes[$this->guidKey] = [$this->getConvertedGuid(
+ Arr::first($attributes[$this->guidKey])
+ )];
+ }
+
+ return $attributes;
+ }
+
+ /**
+ * Convert the attributes from JSON serialization.
+ */
+ protected function convertAttributesFromJson(array $attributes = []): array
+ {
+ // Here we are converting the model's GUID and SID attributes
+ // back to their original values from serialization, so that
+ // their original value may be used and compared against.
+ if (isset($attributes[$this->guidKey])) {
+ $attributes[$this->guidKey] = [$this->getBinaryGuid(
+ Arr::first($attributes[$this->guidKey])
+ )];
}
return $attributes;
@@ -652,10 +541,8 @@
/**
* Reload a fresh model instance from the directory.
- *
- * @return static|false
*/
- public function fresh()
+ public function fresh(): static|false
{
if (! $this->exists) {
return false;
@@ -666,54 +553,106 @@
/**
* Determine if two models have the same distinguished name and belong to the same connection.
- *
- * @param Model|null $model
- *
- * @return bool
*/
- public function is($model)
+ public function is(?Model $model = null): bool
{
return ! is_null($model)
- && $this->dn == $model->getDn()
- && $this->getConnectionName() == $model->getConnectionName();
+ && ! empty($this->dn)
+ && ! empty($model->getDn())
+ && $this->dn == $model->getDn()
+ && $this->getConnectionName() == $model->getConnectionName();
}
/**
* Determine if two models are not the same.
- *
- * @param Model|null $model
- *
- * @return bool
*/
- public function isNot($model)
+ public function isNot(?Model $model = null): bool
{
return ! $this->is($model);
}
/**
* Hydrate a new collection of models from search results.
- *
- * @param array $records
- *
- * @return Collection
*/
- public function hydrate($records)
+ public function hydrate(array $records): Collection
{
return $this->newCollection($records)->transform(function ($attributes) {
- return $attributes instanceof static
- ? $attributes
- : static::newInstance()->setRawAttributes($attributes);
+ if ($attributes instanceof static) {
+ return $attributes;
+ }
+
+ return static::newInstance()->setRawAttributes($attributes);
});
}
/**
- * Converts the current model into the given model.
- *
- * @param Model $into
- *
- * @return Model
+ * Morph the model into a one of matching models using their object classes.
*/
- public function convert(self $into)
+ public function morphInto(array $models, ?callable $resolver = null): Model
+ {
+ if (class_exists($model = $this->determineMorphModel($this, $models, $resolver))) {
+ return $this->convert(new $model);
+ }
+
+ return $this;
+ }
+
+ /**
+ * Morph the model into a one of matching models or throw an exception.
+ */
+ public function morphIntoOrFail(array $models, ?callable $resolver = null): Model
+ {
+ $model = $this->morphInto($models, $resolver);
+
+ if ($model instanceof $this) {
+ throw new RuntimeException(
+ 'The model could not be morphed into any of the given models.'
+ );
+ }
+
+ return $model;
+ }
+
+ /**
+ * Determine the model to morph into from the given models.
+ *
+ * @return class-string|bool
+ */
+ protected function determineMorphModel(Model $model, array $models, ?callable $resolver = null): string|bool
+ {
+ $morphModelMap = [];
+
+ foreach ($models as $modelClass) {
+ $morphModelMap[$modelClass] = static::$morphCache[$modelClass] ??= $this->normalizeObjectClasses(
+ $modelClass::$objectClasses
+ );
+ }
+
+ $objectClasses = $this->normalizeObjectClasses(
+ $model->getObjectClasses()
+ );
+
+ $resolver ??= function (array $objectClasses, array $morphModelMap) {
+ return array_search($objectClasses, $morphModelMap);
+ };
+
+ return $resolver($objectClasses, $morphModelMap);
+ }
+
+ /**
+ * Sort and normalize the object classes.
+ */
+ protected function normalizeObjectClasses(array $classes): array
+ {
+ sort($classes);
+
+ return array_map('strtolower', $classes);
+ }
+
+ /**
+ * Converts the current model into the given model.
+ */
+ public function convert(self $into): Model
{
$into->setDn($this->getDn());
$into->setConnection($this->getConnectionName());
@@ -727,10 +666,8 @@
/**
* Refreshes the current models attributes with the directory values.
- *
- * @return bool
*/
- public function refresh()
+ public function refresh(): bool
{
if ($model = $this->fresh()) {
$this->setRawAttributes($model->getAttributes());
@@ -743,10 +680,8 @@
/**
* Get the model's batch modifications to be processed.
- *
- * @return array
*/
- public function getModifications()
+ public function getModifications(): array
{
$builtModifications = [];
@@ -759,12 +694,8 @@
/**
* Set the models batch modifications.
- *
- * @param array $modifications
- *
- * @return $this
*/
- public function setModifications(array $modifications = [])
+ public function setModifications(array $modifications = []): static
{
$this->modifications = [];
@@ -778,13 +709,9 @@
/**
* Adds a batch modification to the model.
*
- * @param array|BatchModification $mod
- *
- * @return $this
- *
* @throws InvalidArgumentException
*/
- public function addModification($mod = [])
+ public function addModification(BatchModification|array $mod = []): static
{
if ($mod instanceof BatchModification) {
$mod = $mod->get();
@@ -803,90 +730,68 @@
/**
* Get the model's guid attribute key name.
- *
- * @return string
*/
- public function getGuidKey()
+ public function getGuidKey(): string
{
return $this->guidKey;
}
/**
* Get the model's ANR attributes for querying when incompatible with ANR.
- *
- * @return array
*/
- public function getAnrAttributes()
+ public function getAnrAttributes(): array
{
return ['cn', 'sn', 'uid', 'name', 'mail', 'givenname', 'displayname'];
}
/**
* Get the name of the model, or the given DN.
- *
- * @param string|null $dn
- *
- * @return string|null
*/
- public function getName($dn = null)
+ public function getName(?string $dn = null): ?string
{
return $this->newDn($dn ?? $this->dn)->name();
}
/**
* Get the head attribute of the model, or the given DN.
- *
- * @param string|null $dn
- *
- * @return string|null
*/
- public function getHead($dn = null)
+ public function getHead(?string $dn = null): ?string
{
return $this->newDn($dn ?? $this->dn)->head();
}
/**
* Get the RDN of the model, of the given DN.
- *
- * @param string|null
- *
- * @return string|null
*/
- public function getRdn($dn = null)
+ public function getRdn(?string $dn = null): ?string
{
return $this->newDn($dn ?? $this->dn)->relative();
}
/**
* Get the parent distinguished name of the model, or the given DN.
- *
- * @param string|null
- *
- * @return string|null
*/
- public function getParentDn($dn = null)
+ public function getParentDn(?string $dn = null): ?string
{
return $this->newDn($dn ?? $this->dn)->parent();
}
/**
- * Create a new Distinguished Name object.
- *
- * @param string|null $dn
- *
- * @return DistinguishedName
+ * Create a new distinguished name.
*/
- public function newDn($dn = null)
+ public function newDn(?string $dn = null): DistinguishedName
{
+ if (! is_null($dn) && str_contains($dn, BaseBuilder::BASE_DN_PLACEHOLDER)) {
+ $dn = $this->newQuery()->substituteBaseDn($dn);
+ }
+
return new DistinguishedName($dn);
}
/**
* Get the model's object GUID key.
- *
- * @return string
*/
- public function getObjectGuidKey()
+ public function getObjectGuidKey(): string
{
return $this->guidKey;
}
@@ -895,46 +800,60 @@
* Get the model's binary object GUID.
*
* @see https://msdn.microsoft.com/en-us/library/ms679021(v=vs.85).aspx
- *
- * @return string|null
*/
- public function getObjectGuid()
+ public function getObjectGuid(): ?string
{
return $this->getFirstAttribute($this->guidKey);
}
/**
* Get the model's object classes.
- *
- * @return array
*/
- public function getObjectClasses()
+ public function getObjectClasses(): array
{
- return $this->getAttribute('objectclass') ?: [];
+ return $this->getAttribute('objectclass', static::$objectClasses);
}
/**
* Get the model's string GUID.
- *
- * @return string|null
*/
- public function getConvertedGuid()
+ public function getConvertedGuid(?string $guid = null): ?string
{
try {
- return (string) new Guid($this->getObjectGuid());
- } catch (InvalidArgumentException $e) {
- return;
+ return $this->newObjectGuid(
+ (string) ($guid ?? $this->getObjectGuid())
+ );
+ } catch (InvalidArgumentException) {
+ return null;
}
}
/**
- * Determine if the current model is a direct descendant of the given.
- *
- * @param static|string $parent
- *
- * @return bool
+ * Get the model's binary GUID.
*/
- public function isChildOf($parent)
+ public function getBinaryGuid(?string $guid = null): ?string
+ {
+ try {
+ return $this->newObjectGuid(
+ $guid ?? $this->getObjectGuid()
+ )->getBinary();
+ } catch (InvalidArgumentException) {
+ return null;
+ }
+ }
+
+ /**
+ * Make a new object Guid instance.
+ */
+ protected function newObjectGuid(string $value): Guid
+ {
+ return new Guid($value);
+ }
+
+ /**
+ * Determine if the current model is a direct descendant of the given.
+ */
+ public function isChildOf(Model|string|null $parent = null): bool
{
return $this->newDn($this->getDn())->isChildOf(
$this->newDn((string) $parent)
@@ -942,13 +861,19 @@
}
/**
- * Determine if the current model is a direct ascendant of the given.
- *
- * @param static|string $child
- *
- * @return bool
+ * Determine if the current model is a sibling of the given.
*/
- public function isParentOf($child)
+ public function isSiblingOf(Model|string|null $model = null): bool
+ {
+ return $this->newDn($this->getDn())->isSiblingOf(
+ $this->newDn((string) $model)
+ );
+ }
+
+ /**
+ * Determine if the current model is a direct ascendant of the given.
+ */
+ public function isParentOf(Model|string|null $child = null): bool
{
return $this->newDn($this->getDn())->isParentOf(
$this->newDn((string) $child)
@@ -957,37 +882,24 @@
/**
* Determine if the current model is a descendant of the given.
- *
- * @param static|string $model
- *
- * @return bool
*/
- public function isDescendantOf($model)
+ public function isDescendantOf(Model|string|null $model = null): bool
{
return $this->dnIsInside($this->getDn(), $model);
}
/**
* Determine if the current model is a ancestor of the given.
- *
- * @param static|string $model
- *
- * @return bool
*/
- public function isAncestorOf($model)
+ public function isAncestorOf(Model|string|null $model = null): bool
{
return $this->dnIsInside($model, $this->getDn());
}
/**
- * Determines if the DN is inside of the parent DN.
- *
- * @param static|string $dn
- * @param static|string $parentDn
- *
- * @return bool
+ * Determine if the DN is inside the parent DN.
*/
- protected function dnIsInside($dn, $parentDn)
+ protected function dnIsInside(Model|string|null $dn = null, Model|string|null $parentDn = null): bool
{
return $this->newDn((string) $dn)->isDescendantOf(
$this->newDn($parentDn)
@@ -996,12 +908,8 @@
/**
* Set the base DN of where the model should be created in.
- *
- * @param static|string $dn
- *
- * @return $this
*/
- public function inside($dn)
+ public function inside(Model|string $dn): static
{
$this->in = $dn instanceof self ? $dn->getDn() : $dn;
@@ -1011,13 +919,9 @@
/**
* Save the model to the directory without raising any events.
*
- * @param array $attributes
- *
- * @return void
- *
* @throws \LdapRecord\LdapRecordException
*/
- public function saveQuietly(array $attributes = [])
+ public function saveQuietly(array $attributes = []): void
{
static::withoutEvents(function () use ($attributes) {
$this->save($attributes);
@@ -1027,21 +931,19 @@
/**
* Save the model to the directory.
*
- * @param array $attributes The attributes to update or create for the current entry.
- *
- * @return void
- *
* @throws \LdapRecord\LdapRecordException
*/
- public function save(array $attributes = [])
+ public function save(array $attributes = []): void
{
$this->fill($attributes);
- $this->fireModelEvent(new Events\Saving($this));
+ $this->dispatch('saving');
$this->exists ? $this->performUpdate() : $this->performInsert();
- $this->fireModelEvent(new Events\Saved($this));
+ $this->dispatch('saved');
+
+ $this->modifications = [];
$this->in = null;
}
@@ -1049,11 +951,9 @@
/**
* Inserts the model into the directory.
*
- * @return void
- *
* @throws \LdapRecord\LdapRecordException
*/
- protected function performInsert()
+ protected function performInsert(): void
{
// Here we will populate the models object classes if it
// does not already have any set. An LDAP object cannot
@@ -1071,15 +971,22 @@
$this->setDn($this->getCreatableDn());
}
- $this->fireModelEvent(new Events\Creating($this));
+ $this->dispatch('creating');
+
+ // Some PHP versions prevent non-numerically indexed arrays
+ // from being sent to the server. To resolve this, we will
+ // convert the attributes to numerically indexed arrays.
+ $attributes = array_map('array_values', array_filter($this->getAttributes()));
// Here we perform the insert of new object in the directory,
// but filter out any empty attributes before sending them
// to the server. LDAP servers will throw an exception if
// attributes have been given empty or null values.
- $query->insert($this->getDn(), array_filter($this->getAttributes()));
+ $this->dn = $query->insertAndGetDn($this->getDn(), $attributes);
- $this->fireModelEvent(new Events\Created($this));
+ $this->attributes = $attributes;
+
+ $this->dispatch('created');
$this->syncOriginal();
@@ -1091,37 +998,31 @@
/**
* Updates the model in the directory.
*
- * @return void
- *
* @throws \LdapRecord\LdapRecordException
*/
- protected function performUpdate()
+ protected function performUpdate(): void
{
if (! count($modifications = $this->getModifications())) {
return;
}
- $this->fireModelEvent(new Events\Updating($this));
+ $this->dispatch('updating');
$this->newQuery()->update($this->dn, $modifications);
- $this->fireModelEvent(new Events\Updated($this));
+ $this->dispatch('updated');
+
+ $this->syncChanges();
$this->syncOriginal();
-
- $this->modifications = [];
}
/**
* Create the model in the directory.
*
- * @param array $attributes The attributes for the new entry.
- *
- * @return Model
- *
* @throws \LdapRecord\LdapRecordException
*/
- public static function create(array $attributes = [])
+ public static function create(array $attributes = []): static
{
$instance = new static($attributes);
@@ -1131,38 +1032,33 @@
}
/**
- * Create an attribute on the model.
- *
- * @param string $attribute The attribute to create
- * @param mixed $value The value of the new attribute
- *
- * @return void
+ * Add an attribute on the model with the given value.
*
* @throws ModelDoesNotExistException
* @throws \LdapRecord\LdapRecordException
*/
- public function createAttribute($attribute, $value)
+ public function addAttribute(string $attribute, mixed $value): void
{
- $this->requireExistence();
+ $this->assertExists();
- $this->newQuery()->insertAttributes($this->dn, [$attribute => (array) $value]);
+ $this->dispatch(['saving', 'updating']);
+
+ $this->newQuery()->add($this->dn, [$attribute => (array) $value]);
$this->addAttributeValue($attribute, $value);
+
+ $this->dispatch(['updated', 'saved']);
}
/**
* Update the model.
*
- * @param array $attributes The attributes to update for the current entry.
- *
- * @return void
- *
* @throws ModelDoesNotExistException
* @throws \LdapRecord\LdapRecordException
*/
- public function update(array $attributes = [])
+ public function update(array $attributes = []): void
{
- $this->requireExistence();
+ $this->assertExists();
$this->save($attributes);
}
@@ -1170,42 +1066,42 @@
/**
* Update the model attribute with the specified value.
*
- * @param string $attribute The attribute to modify
- * @param mixed $value The new value for the attribute
- *
- * @return void
- *
* @throws ModelDoesNotExistException
* @throws \LdapRecord\LdapRecordException
*/
- public function updateAttribute($attribute, $value)
+ public function replaceAttribute(string $attribute, mixed $value): void
{
- $this->requireExistence();
+ $this->assertExists();
- $this->newQuery()->updateAttributes($this->dn, [$attribute => (array) $value]);
+ $this->dispatch(['saving', 'updating']);
+
+ $this->newQuery()->replace($this->dn, [$attribute => (array) $value]);
$this->addAttributeValue($attribute, $value);
+
+ $this->dispatch(['updated', 'saved']);
}
/**
* Destroy the models for the given distinguished names.
*
- * @param Collection|array|string $dns
- * @param bool $recursive
- *
- * @return int
- *
* @throws \LdapRecord\LdapRecordException
*/
- public static function destroy($dns, $recursive = false)
+ public static function destroy(mixed $dns, bool $recursive = false): int
{
$count = 0;
- $dns = is_string($dns) ? (array) $dns : $dns;
+ $instance = new static;
- $instance = new static();
+ if ($dns instanceof Collection) {
+ $dns = $dns->modelDns()->toArray();
+ }
- foreach ($dns as $dn) {
+ // Here we are iterating through each distinguished name and locating
+ // the associated model. While it's more resource intensive, we must
+ // do this in case of leaf nodes being given alongside any parent
+ // node, ensuring they can be deleted inside of the directory.
+ foreach ((array) $dns as $dn) {
if (! $model = $instance->find($dn)) {
continue;
}
@@ -1224,18 +1120,14 @@
* Throws a ModelNotFoundException if the current model does
* not exist or does not contain a distinguished name.
*
- * @param bool $recursive Whether to recursively delete leaf nodes (models that are children).
- *
- * @return void
- *
* @throws ModelDoesNotExistException
* @throws \LdapRecord\LdapRecordException
*/
- public function delete($recursive = false)
+ public function delete(bool $recursive = false): void
{
- $this->requireExistence();
+ $this->assertExists();
- $this->fireModelEvent(new Events\Deleting($this));
+ $this->dispatch('deleting');
if ($recursive) {
$this->deleteLeafNodes();
@@ -1248,51 +1140,58 @@
// developers can hook in and run further operations.
$this->exists = false;
- $this->fireModelEvent(new Events\Deleted($this));
+ $this->dispatch('deleted');
}
/**
* Deletes leaf nodes that are attached to the model.
*
- * @return void
- *
* @throws \LdapRecord\LdapRecordException
*/
- protected function deleteLeafNodes()
+ protected function deleteLeafNodes(): void
{
$this->newQueryWithoutScopes()
->in($this->dn)
- ->listing()
- ->chunk(250, function ($models) {
- $models->each->delete($recursive = true);
+ ->list()
+ ->each(function (Model $model) {
+ $model->delete(recursive: true);
});
}
/**
- * Delete an attribute on the model.
- *
- * @param string|array $attributes The attribute(s) to delete
- *
- * Delete specific values in attributes:
- *
- * ["memberuid" => "jdoe"]
- *
- * Delete an entire attribute:
- *
- * ["memberuid" => []]
- *
- * @return void
+ * Remove an attribute on the model.
*
* @throws ModelDoesNotExistException
* @throws \LdapRecord\LdapRecordException
*/
- public function deleteAttribute($attributes)
+ public function removeAttribute(string $attribute, mixed $value = null): void
{
- $this->requireExistence();
+ $this->removeAttributes([$attribute => $value]);
+ }
+
+ /**
+ * Remove an attribute on the model.
+ *
+ * Remove specific values in attributes:
+ *
+ * ["memberuid" => "jdoe"]
+ *
+ * Remove an entire attribute:
+ *
+ * ["memberuid" => []]
+ *
+ * @throws ModelDoesNotExistException
+ * @throws \LdapRecord\LdapRecordException
+ */
+ public function removeAttributes(array|string $attributes): void
+ {
+ $this->assertExists();
$attributes = $this->makeDeletableAttributes($attributes);
- $this->newQuery()->deleteAttributes($this->dn, $attributes);
+ $this->dispatch(['saving', 'updating']);
+
+ $this->newQuery()->remove($this->dn, $attributes);
foreach ($attributes as $attribute => $value) {
// If the attribute value is empty, we can assume the
@@ -1311,17 +1210,15 @@
}
}
+ $this->dispatch(['updated', 'saved']);
+
$this->syncOriginal();
}
/**
* Make a deletable attribute array.
- *
- * @param string|array $attributes
- *
- * @return array
*/
- protected function makeDeletableAttributes($attributes)
+ protected function makeDeletableAttributes(string|array $attributes): array
{
$delete = [];
@@ -1339,18 +1236,13 @@
*
* For example: $user->move($ou);
*
- * @param static|string $newParentDn The new parent of the current model.
- * @param bool $deleteOldRdn Whether to delete the old models relative distinguished name once renamed / moved.
- *
- * @return void
- *
* @throws UnexpectedValueException
* @throws ModelDoesNotExistException
* @throws \LdapRecord\LdapRecordException
*/
- public function move($newParentDn, $deleteOldRdn = true)
+ public function move(Model|string $newParentDn, bool $deleteOldRdn = true): void
{
- $this->requireExistence();
+ $this->assertExists();
if (! $rdn = $this->getRdn()) {
throw new UnexpectedValueException('Current model does not contain an RDN to move.');
@@ -1362,18 +1254,12 @@
/**
* Rename the model to a new RDN and new parent.
*
- * @param string $rdn The models new relative distinguished name. Example: "cn=JohnDoe"
- * @param static|string|null $newParentDn The models new parent distinguished name (if moving). Leave this null if you are only renaming. Example: "ou=MovedUsers,dc=acme,dc=org"
- * @param bool|true $deleteOldRdn Whether to delete the old models relative distinguished name once renamed / moved.
- *
- * @return void
- *
* @throws ModelDoesNotExistException
* @throws \LdapRecord\LdapRecordException
*/
- public function rename($rdn, $newParentDn = null, $deleteOldRdn = true)
+ public function rename(string $rdn, Model|string|null $newParentDn = null, bool $deleteOldRdn = true): void
{
- $this->requireExistence();
+ $this->assertExists();
if ($newParentDn instanceof self) {
$newParentDn = $newParentDn->getDn();
@@ -1383,6 +1269,13 @@
$newParentDn = $this->getParentDn($this->dn);
}
+ // If the RDN we have been given is empty when parsed, we must
+ // have been given a string, with no attribute. In this case,
+ // we will create a new RDN using the current DN's head.
+ if ($this->newDn($rdn)->isEmpty()) {
+ $rdn = $this->getUpdateableRdn($rdn);
+ }
+
// If the RDN and the new parent DN are the same as the current,
// we will simply return here to prevent a rename operation
// being sent, which would fail anyway in such case.
@@ -1393,21 +1286,12 @@
return;
}
- // If the RDN we have been given is empty when parsed, we must
- // have been given a string, with no attribute. In this case,
- // we will create a new RDN using the current DN's head.
- if ($this->newDn($rdn)->isEmpty()) {
- $rdn = $this->getUpdateableRdn($rdn);
- }
-
- $this->fireModelEvent(new Renaming($this, $rdn, $newParentDn));
-
- $this->newQuery()->rename($this->dn, $rdn, $newParentDn, $deleteOldRdn);
+ $this->dispatch('renaming', [$rdn, $newParentDn]);
// If the model was successfully renamed, we will set
// its new DN so any further updates to the model
// can be performed without any issues.
- $this->dn = implode(',', [$rdn, $newParentDn]);
+ $this->dn = $this->newQuery()->renameAndGetDn($this->dn, $rdn, $newParentDn, $deleteOldRdn);
$map = $this->newDn($this->dn)->assoc();
@@ -1420,32 +1304,23 @@
= $this->original[$modelNameAttribute]
= [reset($map[$modelNameAttribute])];
- $this->fireModelEvent(new Renamed($this));
+ $this->dispatch('renamed');
$this->wasRecentlyRenamed = true;
}
/**
- * Get an updateable RDN for the model.
- *
- * @param string $name
- *
- * @return string
+ * Get an updatable RDN for the model.
*/
- public function getUpdateableRdn($name)
+ public function getUpdateableRdn(string $name): string
{
return $this->getCreatableRdn($name, $this->newDn($this->dn)->head());
}
/**
* Get a distinguished name that is creatable for the model.
- *
- * @param string|null $name
- * @param string|null $attribute
- *
- * @return string
*/
- public function getCreatableDn($name = null, $attribute = null)
+ public function getCreatableDn(?string $name = null, ?string $attribute = null): string
{
return implode(',', [
$this->getCreatableRdn($name, $attribute),
@@ -1455,41 +1330,30 @@
/**
* Get a creatable (escaped) RDN for the model.
- *
- * @param string|null $name
- * @param string|null $attribute
- *
- * @return string
*/
- public function getCreatableRdn($name = null, $attribute = null)
+ public function getCreatableRdn(?string $name = null, ?string $attribute = null): string
{
$attribute = $attribute ?? $this->getCreatableRdnAttribute();
$name = $this->escape(
$name ?? $this->getFirstAttribute($attribute)
- )->dn();
+ )->forDn();
return "$attribute=$name";
}
/**
* Get the creatable RDN attribute name.
- *
- * @return string
*/
- protected function getCreatableRdnAttribute()
+ protected function getCreatableRdnAttribute(): string
{
return 'cn';
}
/**
- * Determines if the given modification is valid.
- *
- * @param mixed $mod
- *
- * @return bool
+ * Determine if the given modification is valid.
*/
- protected function isValidModification($mod)
+ protected function isValidModification(mixed $mod): bool
{
return Arr::accessible($mod)
&& Arr::exists($mod, BatchModification::KEY_MODTYPE)
@@ -1501,7 +1365,7 @@
*
* @return BatchModification[]
*/
- protected function buildModificationsFromDirty()
+ protected function buildModificationsFromDirty(): array
{
$modifications = [];
@@ -1528,11 +1392,9 @@
/**
* Throw an exception if the model does not exist.
*
- * @return void
- *
* @throws ModelDoesNotExistException
*/
- protected function requireExistence()
+ protected function assertExists(): void
{
if (! $this->exists || is_null($this->dn)) {
throw ModelDoesNotExistException::forModel($this);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ModelDoesNotExistException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ModelDoesNotExistException.php
index 2dd2ba9..98efa98 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ModelDoesNotExistException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/ModelDoesNotExistException.php
@@ -7,32 +7,22 @@
class ModelDoesNotExistException extends LdapRecordException
{
/**
- * The class name of the model that does not exist.
- *
- * @var Model
+ * The instance of the model that does not exist.
*/
- protected $model;
+ protected Model $model;
/**
* Create a new exception for the given model.
- *
- * @param Model $model
- *
- * @return ModelDoesNotExistException
*/
- public static function forModel(Model $model)
+ public static function forModel(Model $model): static
{
- return (new static())->setModel($model);
+ return (new static)->setModel($model);
}
/**
- * Set the model that does not exist.
- *
- * @param Model $model
- *
- * @return ModelDoesNotExistException
+ * Set the model instance that does not exist.
*/
- public function setModel(Model $model)
+ public function setModel(Model $model): static
{
$this->model = $model;
@@ -42,4 +32,12 @@
return $this;
}
+
+ /**
+ * Get the instance of the model that does not exist.
+ */
+ public function getModel(): Model
+ {
+ return $this->model;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Entry.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Entry.php
index b7ad37a..e20016a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Entry.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Entry.php
@@ -13,32 +13,26 @@
{
/**
* The attribute key that contains the models object GUID.
- *
- * @var string
*/
- protected $guidKey = 'entryuuid';
+ protected string $guidKey = 'entryuuid';
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected static function boot()
+ protected static function boot(): void
{
parent::boot();
// Here we'll add a global scope to all OpenLDAP models to ensure the
// Entry UUID is always selected on each query. This attribute is
// virtual, so it must be manually selected to be included.
- static::addGlobalScope(new AddEntryUuidToSelects());
+ static::addGlobalScope(new AddEntryUuidToSelects);
}
/**
* Create a new query builder.
- *
- * @param Connection $connection
- *
- * @return OpenLdapBuilder
*/
- public function newQueryBuilder(Connection $connection)
+ public function newQueryBuilder(Connection $connection): OpenLdapBuilder
{
return new OpenLdapBuilder($connection);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Group.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Group.php
index 2d8d94e..e7d81ef 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Group.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Group.php
@@ -2,15 +2,23 @@
namespace LdapRecord\Models\OpenLDAP;
+use LdapRecord\Models\Relations\HasManyIn;
+
class Group extends Entry
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'groupofuniquenames',
];
+
+ /**
+ * The members relationship.
+ */
+ public function members(): HasManyIn
+ {
+ return $this->hasManyIn([static::class, User::class], 'uniquemember')->using($this, 'uniquemember');
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/OrganizationalUnit.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/OrganizationalUnit.php
index 7ae0a37..e304237 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/OrganizationalUnit.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/OrganizationalUnit.php
@@ -6,20 +6,16 @@
{
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'organizationalunit',
];
/**
* Get the creatable RDN attribute name.
- *
- * @return string
*/
- public function getCreatableRdnAttribute()
+ public function getCreatableRdnAttribute(): string
{
return 'ou';
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Scopes/AddEntryUuidToSelects.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Scopes/AddEntryUuidToSelects.php
index 54376c2..78efa95 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Scopes/AddEntryUuidToSelects.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/Scopes/AddEntryUuidToSelects.php
@@ -10,13 +10,8 @@
{
/**
* Add the entry UUID to the selected attributes.
- *
- * @param Builder $query
- * @param Model $model
- *
- * @return void
*/
- public function apply(Builder $query, Model $model)
+ public function apply(Builder $query, Model $model): void
{
empty($query->columns)
? $query->addSelect(['*', $model->getGuidKey()])
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/User.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/User.php
index b37f390..beaba9e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/User.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/OpenLDAP/User.php
@@ -5,32 +5,27 @@
use Illuminate\Contracts\Auth\Authenticatable;
use LdapRecord\Models\Concerns\CanAuthenticate;
use LdapRecord\Models\Concerns\HasPassword;
+use LdapRecord\Models\Relations\HasMany;
class User extends Entry implements Authenticatable
{
- use HasPassword;
use CanAuthenticate;
+ use HasPassword;
/**
* The password's attribute name.
- *
- * @var string
*/
- protected $passwordAttribute = 'userpassword';
+ protected string $passwordAttribute = 'userpassword';
/**
* The password's hash method.
- *
- * @var string
*/
- protected $passwordHashMethod = 'ssha';
+ protected string $passwordHashMethod = 'ssha';
/**
* The object classes of the LDAP model.
- *
- * @var array
*/
- public static $objectClasses = [
+ public static array $objectClasses = [
'top',
'person',
'organizationalperson',
@@ -38,14 +33,18 @@
];
/**
- * The groups relationship.
- *
- * Retrieves groups that the user is apart of.
- *
- * @return \LdapRecord\Models\Relations\HasMany
+ * Get the unique identifier for the user.
*/
- public function groups()
+ public function getAuthIdentifier(): string
{
- return $this->hasMany(Group::class, 'memberuid', 'uid');
+ return $this->getFirstAttribute($this->guidKey);
+ }
+
+ /**
+ * The groups relationship.
+ */
+ public function groups(): HasMany
+ {
+ return $this->hasMany(Group::class, 'uniquemember');
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php
index ae36720..16e65b1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasMany.php
@@ -3,75 +3,21 @@
namespace LdapRecord\Models\Relations;
use Closure;
-use LdapRecord\DetectsErrors;
-use LdapRecord\LdapRecordException;
+use LdapRecord\Models\Collection;
use LdapRecord\Models\Model;
-use LdapRecord\Models\ModelNotFoundException;
-use LdapRecord\Query\Collection;
+use LdapRecord\Query\Model\Builder;
class HasMany extends OneToMany
{
- use DetectsErrors;
-
- /**
- * The model to use for attaching / detaching.
- *
- * @var Model
- */
- protected $using;
-
- /**
- * The attribute key to use for attaching / detaching.
- *
- * @var string
- */
- protected $usingKey;
-
/**
* The pagination page size.
- *
- * @var int
*/
- protected $pageSize = 1000;
-
- /**
- * The exceptions to bypass for each relation operation.
- *
- * @var array
- */
- protected $bypass = [
- 'attach' => [
- 'Already exists', 'Type or value exists',
- ],
- 'detach' => [
- 'No such attribute', 'Server is unwilling to perform',
- ],
- ];
-
- /**
- * Set the model and attribute to use for attaching / detaching.
- *
- * @param Model $using
- * @param string $usingKey
- *
- * @return $this
- */
- public function using(Model $using, $usingKey)
- {
- $this->using = $using;
- $this->usingKey = $usingKey;
-
- return $this;
- }
+ protected int $pageSize = 1000;
/**
* Set the pagination page size of the relation query.
- *
- * @param int $pageSize
- *
- * @return $this
*/
- public function setPageSize($pageSize)
+ public function setPageSize(int $pageSize): static
{
$this->pageSize = $pageSize;
@@ -80,24 +26,16 @@
/**
* Paginate the relation using the given page size.
- *
- * @param int $pageSize
- *
- * @return Collection
*/
- public function paginate($pageSize = 1000)
+ public function paginate(int $pageSize = 1000): Collection
{
return $this->paginateOnceUsing($pageSize);
}
/**
* Paginate the relation using the page size once.
- *
- * @param int $pageSize
- *
- * @return Collection
*/
- protected function paginateOnceUsing($pageSize)
+ protected function paginateOnceUsing(int $pageSize): Collection
{
$size = $this->pageSize;
@@ -109,26 +47,63 @@
}
/**
- * Chunk the relation results using the given callback.
- *
- * @param int $pageSize
- * @param Closure $callback
- *
- * @return void
+ * Execute a callback over each result while chunking.
*/
- public function chunk($pageSize, Closure $callback)
+ public function each(Closure $callback, int $pageSize = 1000): bool
{
- $this->getRelationQuery()->chunk($pageSize, function ($entries) use ($callback) {
- $callback($this->transformResults($entries));
+ return $this->chunk($pageSize, function ($results) use ($callback) {
+ foreach ($results as $key => $value) {
+ if ($callback($value, $key) === false) {
+ return false;
+ }
+ }
+
+ return true;
+ });
+ }
+
+ /**
+ * Chunk the relation results using the given callback.
+ */
+ public function chunk(int $pageSize, Closure $callback): bool
+ {
+ return $this->chunkRelation($pageSize, $callback);
+ }
+
+ /**
+ * Execute the callback over chunks of relation results.
+ */
+ protected function chunkRelation(int $pageSize, Closure $callback, array $loaded = []): bool
+ {
+ return $this->getRelationQuery()->chunk($pageSize, function (Collection $results) use ($pageSize, $callback, $loaded) {
+ $models = $this->transformResults($results)->when($this->recursive, function (Collection $models) use ($loaded) {
+ return $models->reject(function (Model $model) use ($loaded) {
+ return in_array($model->getDn(), $loaded);
+ });
+ });
+
+ if ($callback($models) === false) {
+ return false;
+ }
+
+ $models->when($this->recursive, function (Collection $models) use ($pageSize, $callback, $loaded) {
+ $models->each(function (Model $model) use ($pageSize, $callback, $loaded) {
+ if ($relation = $model->getRelation($this->relationName)) {
+ $loaded[] = $model->getDn();
+
+ return $relation->recursive()->chunkRelation($pageSize, $callback, $loaded);
+ }
+ });
+ });
+
+ return true;
});
}
/**
* Get the relationships results.
- *
- * @return Collection
*/
- public function getRelationResults()
+ public function getRelationResults(): Collection
{
return $this->transformResults(
$this->getRelationQuery()->paginate($this->pageSize)
@@ -137,10 +112,8 @@
/**
* Get the prepared relationship query.
- *
- * @return \LdapRecord\Query\Model\Builder
*/
- public function getRelationQuery()
+ public function getRelationQuery(): Builder
{
$columns = $this->query->getSelects();
@@ -164,181 +137,4 @@
$this->getEscapedForeignValueFromModel($this->parent)
);
}
-
- /**
- * Attach a model to the relation.
- *
- * @param Model|string $model
- *
- * @return Model|string|false
- */
- public function attach($model)
- {
- return $this->attemptFailableOperation(
- $this->buildAttachCallback($model),
- $this->bypass['attach'],
- $model
- );
- }
-
- /**
- * Build the attach callback.
- *
- * @param Model|string $model
- *
- * @return \Closure
- */
- protected function buildAttachCallback($model)
- {
- return function () use ($model) {
- $foreign = $this->getAttachableForeignValue($model);
-
- if ($this->using) {
- return $this->using->createAttribute($this->usingKey, $foreign);
- }
-
- if (! $model instanceof Model) {
- $model = $this->getForeignModelByValueOrFail($model);
- }
-
- return $model->createAttribute($this->relationKey, $foreign);
- };
- }
-
- /**
- * Attach a collection of models to the parent instance.
- *
- * @param iterable $models
- *
- * @return iterable
- */
- public function attachMany($models)
- {
- foreach ($models as $model) {
- $this->attach($model);
- }
-
- return $models;
- }
-
- /**
- * Detach the model from the relation.
- *
- * @param Model|string $model
- *
- * @return Model|string|false
- */
- public function detach($model)
- {
- return $this->attemptFailableOperation(
- $this->buildDetachCallback($model),
- $this->bypass['detach'],
- $model
- );
- }
-
- /**
- * Build the detach callback.
- *
- * @param Model|string $model
- *
- * @return \Closure
- */
- protected function buildDetachCallback($model)
- {
- return function () use ($model) {
- $foreign = $this->getAttachableForeignValue($model);
-
- if ($this->using) {
- return $this->using->deleteAttribute([$this->usingKey => $foreign]);
- }
-
- if (! $model instanceof Model) {
- $model = $this->getForeignModelByValueOrFail($model);
- }
-
- return $model->deleteAttribute([$this->relationKey => $foreign]);
- };
- }
-
- /**
- * Get the attachable foreign value from the model.
- *
- * @param Model|string $model
- *
- * @return string
- */
- protected function getAttachableForeignValue($model)
- {
- if ($model instanceof Model) {
- return $this->using
- ? $this->getForeignValueFromModel($model)
- : $this->getParentForeignValue();
- }
-
- return $this->using ? $model : $this->getParentForeignValue();
- }
-
- /**
- * Get the foreign model by the given value, or fail.
- *
- * @param string $model
- *
- * @return Model
- *
- * @throws ModelNotFoundException
- */
- protected function getForeignModelByValueOrFail($model)
- {
- if (! is_null($model = $this->getForeignModelByValue($model))) {
- return $model;
- }
-
- throw ModelNotFoundException::forQuery(
- $this->query->getUnescapedQuery(),
- $this->query->getDn()
- );
- }
-
- /**
- * Attempt a failable operation and return the value if successful.
- *
- * If a bypassable exception is encountered, the value will be returned.
- *
- * @param callable $operation
- * @param string|array $bypass
- * @param mixed $value
- *
- * @return mixed
- *
- * @throws LdapRecordException
- */
- protected function attemptFailableOperation($operation, $bypass, $value)
- {
- try {
- $operation();
-
- return $value;
- } catch (LdapRecordException $e) {
- if ($this->errorContainsMessage($e->getMessage(), $bypass)) {
- return $value;
- }
-
- throw $e;
- }
- }
-
- /**
- * Detach all relation models.
- *
- * @return Collection
- */
- public function detachAll()
- {
- return $this->onceWithoutMerging(function () {
- return $this->get()->each(function (Model $model) {
- $this->detach($model);
- });
- });
- }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasManyIn.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasManyIn.php
index 303a144..8b5d561 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasManyIn.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasManyIn.php
@@ -2,21 +2,19 @@
namespace LdapRecord\Models\Relations;
-use LdapRecord\Query\Collection;
+use LdapRecord\Models\Collection;
class HasManyIn extends OneToMany
{
/**
* Get the relationships results.
- *
- * @return Collection
*/
- public function getRelationResults()
+ public function getRelationResults(): Collection
{
$results = $this->parent->newCollection();
foreach ((array) $this->parent->getAttribute($this->relationKey) as $value) {
- if ($foreign = $this->getForeignModelByValue($value)) {
+ if ($value && $foreign = $this->getForeignModelByValue($value)) {
$results->push($foreign);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php
index 7bad4ab..0199f21 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/HasOne.php
@@ -2,20 +2,19 @@
namespace LdapRecord\Models\Relations;
+use LdapRecord\Models\Collection;
use LdapRecord\Models\Model;
class HasOne extends Relation
{
/**
* Get the results of the relationship.
- *
- * @return \LdapRecord\Query\Collection
*/
- public function getResults()
+ public function getResults(): Collection
{
- $model = $this->getForeignModelByValue(
- $this->getFirstAttributeValue($this->parent, $this->relationKey)
- );
+ $relationValue = $this->getFirstAttributeValue($this->parent, $this->relationKey);
+
+ $model = $relationValue ? $this->getForeignModelByValue($relationValue) : null;
return $this->transformResults(
$this->parent->newCollection($model ? [$model] : null)
@@ -24,32 +23,20 @@
/**
* Attach a model instance to the parent model.
- *
- * @param Model|string $model
- *
- * @return Model|string
- *
- * @throws \LdapRecord\LdapRecordException
*/
- public function attach($model)
+ public function attach(Model|string $model): void
{
$foreign = $model instanceof Model
? $this->getForeignValueFromModel($model)
: $model;
$this->parent->setAttribute($this->relationKey, $foreign)->save();
-
- return $model;
}
/**
* Detach the related model from the parent.
- *
- * @return void
- *
- * @throws \LdapRecord\LdapRecordException
*/
- public function detach()
+ public function detach(): void
{
$this->parent->setAttribute($this->relationKey, null)->save();
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php
index 6d14c85..8eb88cb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/OneToMany.php
@@ -2,44 +2,59 @@
namespace LdapRecord\Models\Relations;
+use Closure;
+use LdapRecord\DetectsErrors;
+use LdapRecord\LdapRecordException;
+use LdapRecord\Models\Collection;
use LdapRecord\Models\Model;
-use LdapRecord\Query\Collection;
+use LdapRecord\Models\ModelNotFoundException;
use LdapRecord\Query\Model\Builder;
abstract class OneToMany extends Relation
{
+ use DetectsErrors;
+
+ /**
+ * The model to use for attaching / detaching.
+ */
+ protected ?Model $using = null;
+
/**
* The relation to merge results with.
- *
- * @var OneToMany|null
*/
- protected $with;
+ protected ?Relation $with = null;
+
+ /**
+ * The attribute key to use for attaching / detaching.
+ */
+ protected ?string $usingKey = null;
/**
* The name of the relationship.
- *
- * @var string
*/
- protected $relationName;
+ protected ?string $relationName = null;
/**
* Whether to include recursive results.
- *
- * @var bool
*/
- protected $recursive = false;
+ protected bool $recursive = false;
+
+ /**
+ * The exceptions to bypass for each relation operation.
+ */
+ protected array $bypass = [
+ 'attach' => [
+ 'Already exists', 'Type or value exists',
+ ],
+ 'detach' => [
+ 'No such attribute', 'Server is unwilling to perform',
+ ],
+ ];
/**
* Constructor.
- *
- * @param Builder $query
- * @param Model $parent
- * @param string $related
- * @param string $relationKey
- * @param string $foreignKey
- * @param string $relationName
*/
- public function __construct(Builder $query, Model $parent, $related, $relationKey, $foreignKey, $relationName)
+ public function __construct(Builder $query, Model $parent, array|string $related, string $relationKey, string $foreignKey, string $relationName)
{
$this->relationName = $relationName;
@@ -47,13 +62,20 @@
}
/**
- * Set the relation to load with its parent.
- *
- * @param Relation $relation
- *
- * @return $this
+ * Set the model and attribute to use for attaching / detaching.
*/
- public function with(Relation $relation)
+ public function using(Model $using, string $usingKey): static
+ {
+ $this->using = $using;
+ $this->usingKey = $usingKey;
+
+ return $this;
+ }
+
+ /**
+ * Set the relation to load with its parent.
+ */
+ public function with(Relation $relation): static
{
$this->with = $relation;
@@ -62,31 +84,23 @@
/**
* Whether to include recursive results.
- *
- * @param bool $enable
- *
- * @return $this
*/
- public function recursive($enable = true)
+ public function recursive(bool $recursive = true): static
{
- $this->recursive = $enable;
+ $this->recursive = $recursive;
return $this;
}
/**
* Get the immediate relationships results.
- *
- * @return Collection
*/
- abstract public function getRelationResults();
+ abstract public function getRelationResults(): Collection;
/**
* Get the results of the relationship.
- *
- * @return Collection
*/
- public function getResults()
+ public function getResults(): Collection
{
$results = $this->recursive
? $this->getRecursiveResults()
@@ -99,12 +113,8 @@
/**
* Execute the callback excluding the merged query result.
- *
- * @param callable $callback
- *
- * @return mixed
*/
- protected function onceWithoutMerging($callback)
+ protected function onceWithoutMerging(Closure $callback): mixed
{
$merging = $this->with;
@@ -119,20 +129,262 @@
/**
* Get the relation name.
- *
- * @return string
*/
- public function getRelationName()
+ public function getRelationName(): string
{
return $this->relationName;
}
/**
- * Get the results of the merging 'with' relation.
- *
- * @return Collection
+ * Attach the model in the relation.
*/
- protected function getMergingRelationResults()
+ public function attach(mixed $model): void
+ {
+ if (is_iterable($model)) {
+ array_map($this->attach(...), [...$model]);
+
+ return;
+ }
+
+ $this->attemptFailableOperation(
+ $this->buildAttachCallback($model),
+ $this->bypass['attach'],
+ $model
+ );
+ }
+
+ /**
+ * Build the attach callback.
+ */
+ protected function buildAttachCallback(Model|string $model): Closure
+ {
+ return function () use ($model) {
+ $foreign = $this->getAttachableForeignValue($model);
+
+ if ($this->using) {
+ $this->using->addAttribute($this->usingKey, $foreign);
+
+ return;
+ }
+
+ if (! $model instanceof Model) {
+ $model = $this->getForeignModelByValueOrFail($model);
+ }
+
+ $model->addAttribute($this->relationKey, $foreign);
+ };
+ }
+
+ /**
+ * Get the foreign model by the given value, or fail.
+ *
+ * @throws ModelNotFoundException
+ */
+ protected function getForeignModelByValueOrFail(string $model): Model
+ {
+ if (! is_null($model = $this->getForeignModelByValue($model))) {
+ return $model;
+ }
+
+ throw ModelNotFoundException::forQuery(
+ $this->query->getUnescapedQuery(),
+ $this->query->getDn()
+ );
+ }
+
+ /**
+ * Detach the model from the relation.
+ */
+ public function detach(mixed $model): void
+ {
+ if (is_iterable($model)) {
+ array_map($this->detach(...), [...$model]);
+
+ return;
+ }
+
+ $this->attemptFailableOperation(
+ $this->buildDetachCallback($model),
+ $this->bypass['detach'],
+ $model
+ );
+ }
+
+ /**
+ * Detach the model or delete the parent if the relation is empty.
+ */
+ public function detachOrDeleteParent(Model|string $model): void
+ {
+ /** @var Collection $related */
+ $related = $this->onceWithoutMerging(function () {
+ return $this->get('dn');
+ });
+
+ if (! $related->exists($model)) {
+ return;
+ }
+
+ if ($related->count() <= 1) {
+ $this->getParent()->delete();
+
+ return;
+ }
+
+ $this->detach($model);
+ }
+
+ /**
+ * Build the detach callback.
+ */
+ protected function buildDetachCallback(Model|string $model): Closure
+ {
+ return function () use ($model) {
+ $foreign = $this->getAttachableForeignValue($model);
+
+ if ($this->using) {
+ $this->using->removeAttribute($this->usingKey, $foreign);
+
+ return;
+ }
+
+ if (! $model instanceof Model) {
+ $model = $this->getForeignModelByValueOrFail($model);
+ }
+
+ $model->removeAttribute($this->relationKey, $foreign);
+ };
+ }
+
+ /**
+ * Associate the model in the relation.
+ */
+ public function associate(mixed $model): void
+ {
+ if (is_iterable($model)) {
+ array_map($this->associate(...), [...$model]);
+
+ return;
+ }
+
+ $foreign = $this->getAttachableForeignValue($model);
+
+ if ($this->using) {
+ $this->using->addAttributeValue($this->usingKey, $foreign);
+
+ return;
+ }
+
+ if (! $model instanceof Model) {
+ $model = $this->getForeignModelByValueOrFail($model);
+ }
+
+ $model->addAttributeValue($this->relationKey, $foreign);
+ }
+
+ /**
+ * Dissociate the model in the relation.
+ */
+ public function dissociate(mixed $model): void
+ {
+ if (is_iterable($model)) {
+ array_map($this->dissociate(...), [...$model]);
+
+ return;
+ }
+
+ $foreign = $this->getAttachableForeignValue($model);
+
+ if ($this->using) {
+ $this->using->removeAttributeValue($this->usingKey, $foreign);
+
+ return;
+ }
+
+ if (! $model instanceof Model) {
+ $model = $this->getForeignModelByValueOrFail($model);
+ }
+
+ $model->removeAttributeValue($this->relationKey, $foreign);
+ }
+
+ /**
+ * Alias of "dissociate" method.
+ */
+ public function disassociate(Model|string $model): void
+ {
+ $this->dissociate($model);
+ }
+
+ /**
+ * Get the attachable foreign value from the model.
+ */
+ protected function getAttachableForeignValue(Model|string $model): string
+ {
+ if ($model instanceof Model) {
+ return $this->using
+ ? $this->getForeignValueFromModel($model)
+ : $this->getParentForeignValue();
+ }
+
+ return $this->using ? $model : $this->getParentForeignValue();
+ }
+
+ /**
+ * Attempt a failable operation and return the value if successful.
+ *
+ * If a bypassable exception is encountered, the value will be returned.
+ *
+ * @throws LdapRecordException
+ */
+ protected function attemptFailableOperation(Closure $operation, string|array $bypass, mixed $value): mixed
+ {
+ try {
+ $operation();
+
+ return $value;
+ } catch (LdapRecordException $e) {
+ if ($this->errorContainsMessage($e->getMessage(), $bypass)) {
+ return $value;
+ }
+
+ throw $e;
+ }
+ }
+
+ /**
+ * Detach all relation models.
+ */
+ public function detachAll(): Collection
+ {
+ return $this->onceWithoutMerging(
+ fn () => $this->get()->each(function (Model $model) {
+ $this->detach($model);
+ })
+ );
+ }
+
+ /**
+ * Detach all relation models or delete the model if its relation is empty.
+ */
+ public function detachAllOrDelete(): Collection
+ {
+ return $this->onceWithoutMerging(
+ fn () => $this->get()->each(function (Model $model) {
+ $relation = $model->getRelation($this->relationName);
+
+ if ($relation && $relation->count() >= 1) {
+ $model->delete();
+ } else {
+ $this->detach($model);
+ }
+ })
+ );
+ }
+
+ /**
+ * Get the results of the merging 'with' relation.
+ */
+ protected function getMergingRelationResults(): Collection
{
return $this->with
? $this->with->recursive($this->recursive)->get()
@@ -140,25 +392,23 @@
}
/**
- * Get the results for the models relation recursively.
+ * Get the results for the model's relation recursively.
*
- * @param string[] $loaded The distinguished names of models already loaded
- *
- * @return Collection
+ * @param string[] $loaded The distinguished names of models already loaded
*/
- protected function getRecursiveResults(array $loaded = [])
+ protected function getRecursiveResults(array $loaded = []): Collection
{
- $results = $this->getRelationResults()->reject(function (Model $model) use ($loaded) {
+ $results = $this->getRelationResults()->reject(fn (Model $model) =>
// Here we will exclude the models that we have already
// loaded the recursive results for so we don't run
// into issues with circular relations in LDAP.
- return in_array($model->getDn(), $loaded);
- });
+ in_array($model->getDn(), $loaded)
+ );
foreach ($results as $model) {
$loaded[] = $model->getDn();
- // Finally, we will fetch the related models relations,
+ // Finally, we will fetch the related model's relations,
// passing along our loaded models, to ensure we do
// not attempt fetching already loaded relations.
$results = $results->merge(
@@ -171,16 +421,11 @@
/**
* Get the recursive relation results for given model.
- *
- * @param Model $model
- * @param array $loaded
- *
- * @return Collection
*/
- protected function getRecursiveRelationResults(Model $model, array $loaded)
+ protected function getRecursiveRelationResults(Model $model, array $loaded): Collection
{
- return method_exists($model, $this->relationName)
- ? $model->{$this->relationName}()->getRecursiveResults($loaded)
+ return ($relation = $model->getRelation($this->relationName))
+ ? $relation->getRecursiveResults($loaded)
: $model->newCollection();
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/Relation.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/Relation.php
index 1b108fd..b2d2610 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/Relation.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Relations/Relation.php
@@ -2,69 +2,63 @@
namespace LdapRecord\Models\Relations;
+use Closure;
+use LdapRecord\Models\Collection;
use LdapRecord\Models\Entry;
use LdapRecord\Models\Model;
-use LdapRecord\Query\Collection;
use LdapRecord\Query\Model\Builder;
/**
- * @method bool exists($models = null) Determine if the relation contains all of the given models, or any models
- * @method bool contains($models) Determine if any of the given models are contained in the relation
+ * @method bool exists($models = null) Determine if the relation contains all the given models, or any models
+ * @method bool contains($models) Determine if any of the given models are contained in the relation
+ * @method bool count() Retrieve the "count" result of the query.
*/
abstract class Relation
{
/**
* The underlying LDAP query.
- *
- * @var Builder
*/
- protected $query;
+ protected Builder $query;
/**
* The parent model instance.
- *
- * @var Model
*/
- protected $parent;
+ protected Model $parent;
/**
- * The related models.
- *
- * @var array
+ * The related model class names.
*/
- protected $related;
+ protected array $related;
/**
* The relation key.
- *
- * @var string
*/
- protected $relationKey;
+ protected string $relationKey;
/**
* The foreign key.
- *
- * @var string
*/
- protected $foreignKey;
+ protected string $foreignKey;
/**
* The default relation model.
- *
- * @var string
*/
- protected $default = Entry::class;
+ protected string $default = Entry::class;
+
+ /**
+ * The callback to use for resolving relation models.
+ */
+ protected static ?Closure $modelResolver = null;
+
+ /**
+ * The methods that should be passed along to a relation collection.
+ */
+ protected array $passthru = ['count', 'exists', 'contains'];
/**
* Constructor.
- *
- * @param Builder $query
- * @param Model $parent
- * @param mixed $related
- * @param string $relationKey
- * @param string $foreignKey
*/
- public function __construct(Builder $query, Model $parent, $related, $relationKey, $foreignKey)
+ public function __construct(Builder $query, Model $parent, array|string $related, string $relationKey, string $foreignKey)
{
$this->query = $query;
$this->parent = $parent;
@@ -77,15 +71,10 @@
/**
* Handle dynamic method calls to the relationship.
- *
- * @param string $method
- * @param array $parameters
- *
- * @return mixed
*/
- public function __call($method, $parameters)
+ public function __call(string $method, array $parameters): mixed
{
- if (in_array($method, ['exists', 'contains'])) {
+ if (in_array($method, $this->passthru)) {
return $this->get('objectclass')->$method(...$parameters);
}
@@ -99,20 +88,48 @@
}
/**
- * Get the results of the relationship.
- *
- * @return Collection
+ * Set the callback to use for resolving models from relation results.
*/
- abstract public function getResults();
+ public static function resolveModelsUsing(?Closure $callback = null): void
+ {
+ static::$modelResolver = $callback;
+ }
+
+ /**
+ * Only return objects matching the related model's object classes.
+ */
+ public function onlyRelated(): static
+ {
+ $relations = [];
+
+ foreach ($this->related as $related) {
+ $relations[$related] = $related::$objectClasses;
+ }
+
+ $relations = array_filter($relations);
+
+ if (empty($relations)) {
+ return $this;
+ }
+
+ $this->query->andFilter(function (Builder $query) use ($relations) {
+ foreach ($relations as $relation => $objectClasses) {
+ $query->whereIn('objectclass', $objectClasses);
+ }
+ });
+
+ return $this;
+ }
+
+ /**
+ * Get the results of the relationship.
+ */
+ abstract public function getResults(): Collection;
/**
* Execute the relationship query.
- *
- * @param array|string $columns
- *
- * @return Collection
*/
- public function get($columns = ['*'])
+ public function get(array|string $columns = ['*']): Collection
{
return $this->getResultsWithColumns($columns);
}
@@ -121,12 +138,8 @@
* Get the results of the relationship while selecting the given columns.
*
* If the query columns are empty, the given columns are applied.
- *
- * @param array $columns
- *
- * @return Collection
*/
- protected function getResultsWithColumns($columns)
+ protected function getResultsWithColumns(array|string $columns): Collection
{
if (is_null($this->query->columns)) {
$this->query->select($columns);
@@ -137,22 +150,16 @@
/**
* Get the first result of the relationship.
- *
- * @param array|string $columns
- *
- * @return Model|null
*/
- public function first($columns = ['*'])
+ public function first(array|string $columns = ['*']): ?Model
{
return $this->get($columns)->first();
}
/**
* Prepare the relation query.
- *
- * @return static
*/
- public function initRelation()
+ public function initRelation(): static
{
$this->query
->clearFilters()
@@ -163,73 +170,71 @@
}
/**
- * Get the underlying query for the relation.
- *
- * @return Builder
+ * Set the underlying query for the relation.
*/
- public function getQuery()
+ public function setQuery(Builder $query): static
+ {
+ $this->query = $query;
+
+ $this->initRelation();
+
+ return $this;
+ }
+
+ /**
+ * Get the underlying query for the relation.
+ */
+ public function getQuery(): Builder
{
return $this->query;
}
/**
* Get the parent model of the relation.
- *
- * @return Model
*/
- public function getParent()
+ public function getParent(): Model
{
return $this->parent;
}
/**
* Get the relation attribute key.
- *
- * @return string
*/
- public function getRelationKey()
+ public function getRelationKey(): string
{
return $this->relationKey;
}
/**
* Get the related model classes for the relation.
- *
- * @return array
*/
- public function getRelated()
+ public function getRelated(): array
{
return $this->related;
}
/**
* Get the relation foreign attribute key.
- *
- * @return string
*/
- public function getForeignKey()
+ public function getForeignKey(): string
{
return $this->foreignKey;
}
/**
* Get the class name of the default model.
- *
- * @return string
*/
- public function getDefaultModel()
+ public function getDefaultModel(): string
{
return $this->default;
}
/**
* Get a new instance of the default model on the relation.
- *
- * @return Model
*/
- public function getNewDefaultModel()
+ public function getNewDefaultModel(): Model
{
- $model = new $this->default();
+ $model = new $this->default;
$model->setConnection($this->parent->getConnectionName());
@@ -238,131 +243,65 @@
/**
* Get the foreign model by the given value.
- *
- * @param string $value
- *
- * @return Model|null
*/
- protected function getForeignModelByValue($value)
+ protected function getForeignModelByValue(string $value): ?Model
{
return $this->foreignKeyIsDistinguishedName()
- ? $this->query->find($value)
- : $this->query->findBy($this->foreignKey, $value);
+ ? $this->query->clearFilters()->find($value)
+ : $this->query->clearFilters()->findBy($this->foreignKey, $value);
}
/**
- * Returns the escaped foreign key value for use in an LDAP filter from the model.
- *
- * @param Model $model
- *
- * @return string
+ * Get the escaped foreign key value for use in an LDAP filter from the model.
*/
- protected function getEscapedForeignValueFromModel(Model $model)
+ protected function getEscapedForeignValueFromModel(Model $model): string
{
return $this->query->escape(
$this->getForeignValueFromModel($model)
- )->both();
+ )->forDnAndFilter();
}
/**
* Get the relation parents foreign value.
- *
- * @return string
*/
- protected function getParentForeignValue()
+ protected function getParentForeignValue(): ?string
{
return $this->getForeignValueFromModel($this->parent);
}
/**
* Get the foreign key value from the model.
- *
- * @param Model $model
- *
- * @return string
*/
- protected function getForeignValueFromModel(Model $model)
+ protected function getForeignValueFromModel(Model $model): ?string
{
return $this->foreignKeyIsDistinguishedName()
- ? $model->getDn()
- : $this->getFirstAttributeValue($model, $this->foreignKey);
+ ? $model->getDn()
+ : $this->getFirstAttributeValue($model, $this->foreignKey);
}
/**
* Get the first attribute value from the model.
- *
- * @param Model $model
- * @param string $attribute
- *
- * @return string|null
*/
- protected function getFirstAttributeValue(Model $model, $attribute)
+ protected function getFirstAttributeValue(Model $model, string $attribute): mixed
{
return $model->getFirstAttribute($attribute);
}
/**
* Transforms the results by converting the models into their related.
- *
- * @param Collection $results
- *
- * @return Collection
*/
- protected function transformResults(Collection $results)
+ protected function transformResults(Collection $results): Collection
{
- $related = [];
-
- foreach ($this->related as $relation) {
- $related[$relation] = $relation::$objectClasses;
- }
-
- return $results->transform(function (Model $entry) use ($related) {
- $model = $this->determineModelFromRelated($entry, $related);
-
- return class_exists($model) ? $entry->convert(new $model()) : $entry;
- });
- }
-
- /**
- * Determines if the foreign key is a distinguished name.
- *
- * @return bool
- */
- protected function foreignKeyIsDistinguishedName()
- {
- return in_array($this->foreignKey, ['dn', 'distinguishedname']);
- }
-
- /**
- * Determines the model from the given relations.
- *
- * @param Model $model
- * @param array $related
- *
- * @return string|bool
- */
- protected function determineModelFromRelated(Model $model, array $related)
- {
- // We must normalize all the related models object class
- // names to the same case so we are able to properly
- // determine the owning model from search results.
- return array_search(
- $this->normalizeObjectClasses($model->getObjectClasses()),
- array_map([$this, 'normalizeObjectClasses'], $related)
+ return $results->transform(
+ fn (Model $entry) => $entry->morphInto($this->related, static::$modelResolver)
);
}
/**
- * Sort and normalize the object classes.
- *
- * @param array $classes
- *
- * @return array
+ * Determine if the foreign key is a distinguished name.
*/
- protected function normalizeObjectClasses($classes)
+ protected function foreignKeyIsDistinguishedName(): bool
{
- sort($classes);
-
- return array_map('strtolower', $classes);
+ return in_array($this->foreignKey, ['dn', 'distinguishedname']);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Scope.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Scope.php
index 321cae3..09c0c0c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Scope.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Scope.php
@@ -8,11 +8,6 @@
{
/**
* Apply the scope to the given query.
- *
- * @param Builder $query
- * @param Model $model
- *
- * @return void
*/
- public function apply(Builder $query, Model $model);
+ public function apply(Builder $query, Model $model): void;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Types/ActiveDirectory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Types/ActiveDirectory.php
index 61d21ef..2fc54e4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Types/ActiveDirectory.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Types/ActiveDirectory.php
@@ -5,25 +5,24 @@
interface ActiveDirectory extends TypeInterface
{
/**
- * Returns the models object SID key.
- *
- * @return string
+ * Get the models object SID key.
*/
- public function getObjectSidKey();
+ public function getObjectSidKey(): string;
/**
- * Returns the model's hex object SID.
+ * Get the model's hex object SID.
*
* @see https://msdn.microsoft.com/en-us/library/ms679024(v=vs.85).aspx
- *
- * @return string
*/
- public function getObjectSid();
+ public function getObjectSid(): ?string;
/**
- * Returns the model's SID.
- *
- * @return string|null
+ * Get the model's SID.
*/
- public function getConvertedSid();
+ public function getConvertedSid(?string $sid = null): ?string;
+
+ /**
+ * Get the model's binary SID.
+ */
+ public function getBinarySid(?string $sid = null): ?string;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Types/DirectoryServer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Types/DirectoryServer.php
new file mode 100644
index 0000000..f06216c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Models/Types/DirectoryServer.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace LdapRecord\Models\Types;
+
+interface DirectoryServer extends TypeInterface
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ArrayCacheStore.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ArrayCacheStore.php
index d7480a7..d4a9137 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ArrayCacheStore.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ArrayCacheStore.php
@@ -10,15 +10,13 @@
/**
* An array of stored values.
- *
- * @var array
*/
- protected $storage = [];
+ protected array $storage = [];
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function get($key, $default = null)
+ public function get($key, $default = null): mixed
{
if (! isset($this->storage[$key])) {
return $default;
@@ -38,9 +36,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function set($key, $value, $ttl = null)
+ public function set($key, $value, $ttl = null): bool
{
$this->storage[$key] = [
'value' => $value,
@@ -52,32 +50,24 @@
/**
* Get the expiration time of the key.
- *
- * @param int $seconds
- *
- * @return int
*/
- protected function calculateExpiration($seconds)
+ protected function calculateExpiration($seconds = null): int
{
return $this->toTimestamp($seconds);
}
/**
* Get the UNIX timestamp for the given number of seconds.
- *
- * @param int $seconds
- *
- * @return int
*/
- protected function toTimestamp($seconds)
+ protected function toTimestamp($seconds = null): int
{
return $seconds > 0 ? $this->availableAt($seconds) : 0;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function delete($key)
+ public function delete($key): bool
{
unset($this->storage[$key]);
@@ -85,9 +75,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function clear()
+ public function clear(): bool
{
$this->storage = [];
@@ -95,9 +85,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getMultiple($keys, $default = null)
+ public function getMultiple($keys, $default = null): iterable
{
$values = [];
@@ -109,9 +99,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function setMultiple($values, $ttl = null)
+ public function setMultiple($values, $ttl = null): bool
{
foreach ($values as $key => $value) {
$this->set($key, $value, $ttl);
@@ -121,9 +111,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function deleteMultiple($keys)
+ public function deleteMultiple($keys): bool
{
foreach ($keys as $key) {
$this->delete($key);
@@ -133,9 +123,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function has($key)
+ public function has($key): bool
{
return isset($this->storage[$key]);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php
index b9e3196..642cf32 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Builder.php
@@ -5,6 +5,7 @@
use BadMethodCallException;
use Closure;
use DateTimeInterface;
+use Generator;
use InvalidArgumentException;
use LDAP\Result;
use LdapRecord\Connection;
@@ -12,32 +13,42 @@
use LdapRecord\EscapesValues;
use LdapRecord\LdapInterface;
use LdapRecord\LdapRecordException;
+use LdapRecord\Models\Attributes\EscapedValue;
use LdapRecord\Models\Model;
use LdapRecord\Query\Events\QueryExecuted;
use LdapRecord\Query\Model\Builder as ModelBuilder;
use LdapRecord\Query\Pagination\LazyPaginator;
use LdapRecord\Query\Pagination\Paginator;
use LdapRecord\Support\Arr;
-use LdapRecord\Utilities;
-/** @psalm-suppress UndefinedClass */
class Builder
{
use EscapesValues;
+ public const TYPE_SEARCH = 'search';
+
+ public const TYPE_READ = 'read';
+
+ public const TYPE_CHUNK = 'chunk';
+
+ public const TYPE_LIST = 'list';
+
+ public const TYPE_PAGINATE = 'paginate';
+
+ /**
+ * The base distinguished name placeholder.
+ */
+ public const BASE_DN_PLACEHOLDER = '{base}';
+
/**
* The selected columns to retrieve on the query.
- *
- * @var array
*/
- public $columns;
+ public ?array $columns = null;
/**
* The query filters.
- *
- * @var array
*/
- public $filters = [
+ public array $filters = [
'and' => [],
'or' => [],
'raw' => [],
@@ -45,121 +56,92 @@
/**
* The LDAP server controls to be sent.
- *
- * @var array
*/
- public $controls = [];
+ public array $controls = [];
/**
* The LDAP server controls that were processed.
- *
- * @var array
*/
- public $controlsResponse = [];
+ public array $controlsResponse = [];
/**
* The size limit of the query.
- *
- * @var int
*/
- public $limit = 0;
+ public int $limit = 0;
/**
- * Determines whether the current query is paginated.
- *
- * @var bool
+ * Determine whether the current query is paginated.
*/
- public $paginated = false;
+ public bool $paginated = false;
/**
* The distinguished name to perform searches upon.
- *
- * @var string|null
*/
- protected $dn;
+ protected ?string $dn = null;
/**
* The base distinguished name to perform searches inside.
- *
- * @var string|null
*/
- protected $baseDn;
+ protected ?string $baseDn = null;
/**
* The default query type.
- *
- * @var string
*/
- protected $type = 'search';
+ protected string $type = self::TYPE_SEARCH;
/**
- * Determines whether the query is nested.
- *
- * @var bool
+ * Determine whether the query is nested.
*/
- protected $nested = false;
+ protected bool $nested = false;
/**
- * Determines whether the query should be cached.
- *
- * @var bool
+ * Determine whether the query should be cached.
*/
- protected $caching = false;
+ protected bool $caching = false;
+
+ /**
+ * The custom cache key to use when caching results.
+ */
+ protected ?string $cacheKey = null;
/**
* How long the query should be cached until.
- *
- * @var DateTimeInterface|null
*/
- protected $cacheUntil = null;
+ protected ?DateTimeInterface $cacheUntil = null;
/**
- * Determines whether the query cache must be flushed.
- *
- * @var bool
+ * Determine whether the query cache must be flushed.
*/
- protected $flushCache = false;
+ protected bool $flushCache = false;
/**
* The current connection instance.
- *
- * @var Connection
*/
- protected $connection;
+ protected Connection $connection;
/**
* The current grammar instance.
- *
- * @var Grammar
*/
- protected $grammar;
+ protected Grammar $grammar;
/**
* The current cache instance.
- *
- * @var Cache|null
*/
- protected $cache;
+ protected ?Cache $cache = null;
/**
* Constructor.
- *
- * @param Connection $connection
*/
public function __construct(Connection $connection)
{
$this->connection = $connection;
- $this->grammar = new Grammar();
+ $this->grammar = new Grammar;
}
/**
* Set the current connection.
- *
- * @param Connection $connection
- *
- * @return $this
*/
- public function setConnection(Connection $connection)
+ public function setConnection(Connection $connection): static
{
$this->connection = $connection;
@@ -168,12 +150,8 @@
/**
* Set the current filter grammar.
- *
- * @param Grammar $grammar
- *
- * @return $this
*/
- public function setGrammar(Grammar $grammar)
+ public function setGrammar(Grammar $grammar): static
{
$this->grammar = $grammar;
@@ -182,12 +160,8 @@
/**
* Set the cache to store query results.
- *
- * @param Cache|null $cache
- *
- * @return $this
*/
- public function setCache(Cache $cache = null)
+ public function setCache(?Cache $cache = null): static
{
$this->cache = $cache;
@@ -196,28 +170,18 @@
/**
* Returns a new Query Builder instance.
- *
- * @param string $baseDn
- *
- * @return $this
*/
- public function newInstance($baseDn = null)
+ public function newInstance(?string $baseDn = null): Builder
{
- // We'll set the base DN of the new Builder so
- // developers don't need to do this manually.
- $dn = is_null($baseDn) ? $this->getDn() : $baseDn;
-
- return (new static($this->connection))->setDn($dn);
+ return (new static($this->connection))->setDn(
+ is_null($baseDn) ? $this->getDn() : $baseDn
+ );
}
/**
* Returns a new nested Query Builder instance.
- *
- * @param Closure|null $closure
- *
- * @return $this
*/
- public function newNestedInstance(Closure $closure = null)
+ public function newNestedInstance(?Closure $closure = null): Builder
{
$query = $this->newInstance()->nested();
@@ -230,29 +194,20 @@
/**
* Executes the LDAP query.
- *
- * @param string|array $columns
- *
- * @return Collection|array
*/
- public function get($columns = ['*'])
+ public function get(array|string $columns = ['*']): Collection|array
{
- return $this->onceWithColumns(Arr::wrap($columns), function () {
- return $this->query($this->getQuery());
- });
+ return $this->onceWithColumns(
+ Arr::wrap($columns), fn () => $this->query($this->getQuery())
+ );
}
/**
* Execute the given callback while selecting the given columns.
*
* After running the callback, the columns are reset to the original value.
- *
- * @param array $columns
- * @param Closure $callback
- *
- * @return mixed
*/
- protected function onceWithColumns($columns, Closure $callback)
+ protected function onceWithColumns(array $columns, Closure $callback): mixed
{
$original = $this->columns;
@@ -268,11 +223,9 @@
}
/**
- * Compiles and returns the current query string.
- *
- * @return string
+ * Compile the query into an LDAP filter string.
*/
- public function getQuery()
+ public function getQuery(): string
{
// We need to ensure we have at least one filter, as
// no query results will be returned otherwise.
@@ -284,139 +237,101 @@
}
/**
- * Returns the unescaped query.
- *
- * @return string
+ * Get the unescaped query.
*/
- public function getUnescapedQuery()
+ public function getUnescapedQuery(): string
{
- return Utilities::unescape($this->getQuery());
+ return EscapedValue::unescape($this->getQuery());
}
/**
- * Returns the current Grammar instance.
- *
- * @return Grammar
+ * Get the current Grammar instance.
*/
- public function getGrammar()
+ public function getGrammar(): Grammar
{
return $this->grammar;
}
/**
- * Returns the current Cache instance.
- *
- * @return Cache|null
+ * Get the current Cache instance.
*/
- public function getCache()
+ public function getCache(): ?Cache
{
return $this->cache;
}
/**
- * Returns the current Connection instance.
- *
- * @return Connection
+ * Get the current Connection instance.
*/
- public function getConnection()
+ public function getConnection(): Connection
{
return $this->connection;
}
/**
- * Returns the query type.
- *
- * @return string
+ * Get the query type.
*/
- public function getType()
+ public function getType(): string
{
return $this->type;
}
/**
* Set the base distinguished name of the query.
- *
- * @param Model|string $dn
- *
- * @return $this
*/
- public function setBaseDn($dn)
+ public function setBaseDn(Model|string|null $dn = null): static
{
- $this->baseDn = $this->substituteBaseInDn($dn);
+ $this->baseDn = $this->substituteBaseDn($dn);
return $this;
}
/**
* Get the base distinguished name of the query.
- *
- * @return string|null
*/
- public function getBaseDn()
+ public function getBaseDn(): ?string
{
return $this->baseDn;
}
/**
* Get the distinguished name of the query.
- *
- * @return string
*/
- public function getDn()
+ public function getDn(): ?string
{
return $this->dn;
}
/**
* Set the distinguished name for the query.
- *
- * @param string|Model|null $dn
- *
- * @return $this
*/
- public function setDn($dn = null)
+ public function setDn(Model|string|null $dn = null): static
{
- $this->dn = $this->substituteBaseInDn($dn);
+ $this->dn = $this->substituteBaseDn($dn);
return $this;
}
/**
* Substitute the base DN string template for the current base.
- *
- * @param Model|string $dn
- *
- * @return string
*/
- protected function substituteBaseInDn($dn)
+ public function substituteBaseDn(Model|string|null $dn = null): string
{
- return str_replace(
- '{base}',
- $this->baseDn ?: '',
- (string) ($dn instanceof Model ? $dn->getDn() : $dn)
- );
+ return str_replace(static::BASE_DN_PLACEHOLDER, $this->baseDn ?? '', (string) $dn);
}
/**
* Alias for setting the distinguished name for the query.
- *
- * @param string|Model|null $dn
- *
- * @return $this
*/
- public function in($dn = null)
+ public function in(Model|string|null $dn = null): static
{
return $this->setDn($dn);
}
/**
* Set the size limit of the current query.
- *
- * @param int $limit
- *
- * @return $this
*/
- public function limit($limit = 0)
+ public function limit(int $limit = 0): static
{
$this->limit = $limit;
@@ -425,12 +340,8 @@
/**
* Returns a new query for the given model.
- *
- * @param Model $model
- *
- * @return ModelBuilder
*/
- public function model(Model $model)
+ public function model(Model $model): ModelBuilder
{
return $model->newQueryBuilder($this->connection)
->setCache($this->connection->getCache())
@@ -440,21 +351,15 @@
/**
* Performs the specified query on the current LDAP connection.
- *
- * @param string $query
- *
- * @return Collection|array
*/
- public function query($query)
+ public function query(string $query): Collection|array
{
$start = microtime(true);
// Here we will create the execution callback. This allows us
// to only execute an LDAP request if caching is disabled
// or if no cache of the given query exists yet.
- $callback = function () use ($query) {
- return $this->parse($this->run($query));
- };
+ $callback = fn () => $this->parse($this->run($query));
$results = $this->getCachedResponse($query, $callback);
@@ -465,13 +370,8 @@
/**
* Paginates the current LDAP query.
- *
- * @param int $pageSize
- * @param bool $isCritical
- *
- * @return Collection|array
*/
- public function paginate($pageSize = 1000, $isCritical = false)
+ public function paginate(int $pageSize = 1000, bool $isCritical = false): Collection|array
{
$this->paginated = true;
@@ -482,106 +382,141 @@
// Here we will create the pagination callback. This allows us
// to only execute an LDAP request if caching is disabled
// or if no cache of the given query exists yet.
- $callback = function () use ($query, $pageSize, $isCritical) {
- return $this->runPaginate($query, $pageSize, $isCritical);
- };
+ $callback = fn () => $this->runPaginate($query, $pageSize, $isCritical);
$pages = $this->getCachedResponse($query, $callback);
- $this->logQuery($this, 'paginate', $this->getElapsedTime($start));
+ $this->logQuery($this, self::TYPE_PAGINATE, $this->getElapsedTime($start));
return $this->process($pages);
}
/**
* Runs the paginate operation with the given filter.
- *
- * @param string $filter
- * @param int $perPage
- * @param bool $isCritical
- *
- * @return array
*/
- protected function runPaginate($filter, $perPage, $isCritical)
+ protected function runPaginate(string $filter, int $perPage, bool $isCritical): array
{
- return $this->connection->run(function (LdapInterface $ldap) use ($filter, $perPage, $isCritical) {
- return (new Paginator($this, $filter, $perPage, $isCritical))->execute($ldap);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $this->newPaginator($filter, $perPage, $isCritical)->execute($ldap)
+ );
+ }
+
+ /**
+ * Make a new paginator instance.
+ */
+ protected function newPaginator(string $filter, int $perPage, bool $isCritical): Paginator
+ {
+ return new Paginator($this, $filter, $perPage, $isCritical);
}
/**
* Execute a callback over each item while chunking.
- *
- * @param Closure $callback
- * @param int $count
- *
- * @return bool
*/
- public function each(Closure $callback, $count = 1000)
+ public function each(Closure $callback, int $pageSize = 1000, bool $isCritical = false, bool $isolate = false): bool
{
- return $this->chunk($count, function ($results) use ($callback) {
+ return $this->chunk($pageSize, function ($results) use ($callback) {
foreach ($results as $key => $value) {
if ($callback($value, $key) === false) {
return false;
}
}
- });
+ }, $isCritical, $isolate);
}
/**
* Chunk the results of a paginated LDAP query.
- *
- * @param int $pageSize
- * @param Closure $callback
- * @param bool $isCritical
- *
- * @return bool
*/
- public function chunk($pageSize, Closure $callback, $isCritical = false)
+ public function chunk(int $pageSize, Closure $callback, bool $isCritical = false, bool $isolate = false): bool
{
+ $this->limit(0);
+
$start = microtime(true);
- $query = $this->getQuery();
+ $chunk = function (Builder $query) use ($pageSize, $callback, $isCritical) {
+ $page = 1;
- $page = 1;
+ foreach ($query->runChunk($this->getQuery(), $pageSize, $isCritical) as $chunk) {
+ if ($callback($this->process($chunk), $page) === false) {
+ return false;
+ }
- foreach ($this->runChunk($query, $pageSize, $isCritical) as $chunk) {
- if ($callback($this->process($chunk), $page) === false) {
- return false;
+ $page++;
}
+ };
- $page++;
- }
+ // Connection isolation creates a new, temporary connection for the pagination
+ // request to occur on. This allows connections that do not support executing
+ // other queries during a pagination request, to do so without interruption.
+ $isolate ? $this->connection->isolate(
+ fn (Connection $replicate) => $chunk($this->clone()->setConnection($replicate))
+ ) : $chunk($this);
- $this->logQuery($this, 'chunk', $this->getElapsedTime($start));
+ $this->logQuery($this, self::TYPE_CHUNK, $this->getElapsedTime($start));
return true;
}
/**
* Runs the chunk operation with the given filter.
- *
- * @param string $filter
- * @param int $perPage
- * @param bool $isCritical
- *
- * @return array
*/
- protected function runChunk($filter, $perPage, $isCritical)
+ protected function runChunk(string $filter, int $perPage, bool $isCritical): Generator
{
- return $this->connection->run(function (LdapInterface $ldap) use ($filter, $perPage, $isCritical) {
- return (new LazyPaginator($this, $filter, $perPage, $isCritical))->execute($ldap);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $this->newLazyPaginator($filter, $perPage, $isCritical)->execute($ldap)
+ );
+ }
+
+ /**
+ * Make a new lazy paginator instance.
+ */
+ protected function newLazyPaginator(string $filter, int $perPage, bool $isCritical): LazyPaginator
+ {
+ return new LazyPaginator($this, $filter, $perPage, $isCritical);
+ }
+
+ /**
+ * Create a slice of the LDAP query into a page.
+ */
+ public function slice(int $page = 1, int $perPage = 100, string $orderBy = 'cn', string $orderByDir = 'asc'): Slice
+ {
+ $results = $this->forPage($page, $perPage, $orderBy, $orderByDir);
+
+ $total = $this->controlsResponse[LDAP_CONTROL_VLVRESPONSE]['value']['count'] ?? 0;
+
+ // Some LDAP servers seem to have an issue where the last result in a virtual
+ // list view will always be returned, regardless of the offset being larger
+ // than the result itself. In this case, we will manually return an empty
+ // response so that no objects are deceivingly included in the slice.
+ $objects = $page > max((int) ceil($total / $perPage), 1)
+ ? ($this instanceof ModelBuilder ? $this->model->newCollection() : [])
+ : $results;
+
+ return new Slice($objects, $total, $perPage, $page);
+ }
+
+ /**
+ * Get the results of a query for a given page.
+ */
+ public function forPage(int $page = 1, int $perPage = 100, string $orderBy = 'cn', string $orderByDir = 'asc'): Collection|array
+ {
+ if (! $this->hasOrderBy()) {
+ $this->orderBy($orderBy, $orderByDir);
+ }
+
+ $this->addControl(LDAP_CONTROL_VLVREQUEST, true, [
+ 'before' => 0,
+ 'after' => $perPage - 1,
+ 'offset' => ($page * $perPage) - $perPage + 1,
+ 'count' => 0,
+ ]);
+
+ return $this->get();
}
/**
* Processes and converts the given LDAP results into models.
- *
- * @param array $results
- *
- * @return array
*/
- protected function process(array $results)
+ protected function process(array $results): mixed
{
unset($results['count']);
@@ -594,12 +529,8 @@
/**
* Flattens LDAP paged results into a single array.
- *
- * @param array $pages
- *
- * @return array
*/
- protected function flattenPages(array $pages)
+ protected function flattenPages(array $pages): array
{
$records = [];
@@ -614,16 +545,11 @@
/**
* Get the cached response or execute and cache the callback value.
- *
- * @param string $query
- * @param Closure $callback
- *
- * @return mixed
*/
- protected function getCachedResponse($query, Closure $callback)
+ protected function getCachedResponse(string $query, Closure $callback): mixed
{
if ($this->cache && $this->caching) {
- $key = $this->getCacheKey($query);
+ $key = $this->cacheKey ?? $this->getCacheKey($query);
if ($this->flushCache) {
$this->cache->delete($key);
@@ -632,17 +558,20 @@
return $this->cache->remember($key, $this->cacheUntil, $callback);
}
- return $callback();
+ try {
+ return $callback();
+ } finally {
+ $this->caching = false;
+ $this->cacheKey = null;
+ $this->cacheUntil = null;
+ $this->flushCache = false;
+ }
}
/**
* Runs the query operation with the given filter.
- *
- * @param string $filter
- *
- * @return resource
*/
- public function run($filter)
+ public function run(string $filter): mixed
{
return $this->connection->run(function (LdapInterface $ldap) use ($filter) {
// We will avoid setting the controls during any pagination
@@ -656,7 +585,7 @@
}
return $ldap->{$this->type}(
- $this->dn ?? $this->baseDn,
+ (string) ($this->dn ?? $this->baseDn),
$filter,
$this->getSelects(),
$onlyAttributes = false,
@@ -667,12 +596,8 @@
/**
* Parses the given LDAP resource by retrieving its entries.
- *
- * @param resource $resource
- *
- * @return array
*/
- public function parse($resource)
+ public function parse(mixed $resource): array
{
if (! $resource) {
return [];
@@ -681,17 +606,10 @@
return $this->connection->run(function (LdapInterface $ldap) use ($resource) {
$this->controlsResponse = $this->controls;
- $errorCode = 0;
- $dn = $errorMessage = $refs = null;
-
// Process the server controls response.
$ldap->parseResult(
- $resource,
- $errorCode,
- $dn,
- $errorMessage,
- $refs,
- $this->controlsResponse
+ result: $resource,
+ controls: $this->controlsResponse
);
$entries = $ldap->getEntries($resource);
@@ -706,15 +624,13 @@
}
/**
- * Returns the cache key.
- *
- * @param string $query
- *
- * @return string
+ * Get the cache key.
*/
- protected function getCacheKey($query)
+ protected function getCacheKey(string $query): string
{
- $host = $this->connection->getLdapConnection()->getHost();
+ $host = $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->getHost()
+ );
$key = $host
.$this->type
@@ -728,13 +644,9 @@
}
/**
- * Returns the first entry in a search result.
- *
- * @param array|string $columns
- *
- * @return Model|null
+ * Get the first entry in a search result.
*/
- public function first($columns = ['*'])
+ public function first(array|string $columns = ['*']): Model|array|null
{
return Arr::first(
$this->limit(1)->get($columns)
@@ -742,17 +654,13 @@
}
/**
- * Returns the first entry in a search result.
+ * Get the first entry in a search result.
*
* If no entry is found, an exception is thrown.
*
- * @param array|string $columns
- *
- * @return Model|array
- *
* @throws ObjectNotFoundException
*/
- public function firstOrFail($columns = ['*'])
+ public function firstOrFail(array|string $columns = ['*']): Model|array
{
if (! $record = $this->first($columns)) {
$this->throwNotFoundException($this->getUnescapedQuery(), $this->dn);
@@ -762,13 +670,9 @@
}
/**
- * Return the first entry in a result, or execute the callback.
- *
- * @param Closure $callback
- *
- * @return Model|mixed
+ * Get the first entry in a result, or execute the callback.
*/
- public function firstOr(Closure $callback)
+ public function firstOr(Closure $callback): mixed
{
return $this->first() ?: $callback();
}
@@ -776,14 +680,10 @@
/**
* Execute the query and get the first result if it's the sole matching record.
*
- * @param array|string $columns
- *
- * @return Model|array
- *
* @throws ObjectsNotFoundException
* @throws MultipleObjectsFoundException
*/
- public function sole($columns = ['*'])
+ public function sole(array|string $columns = ['*']): Model|array
{
$result = $this->limit(2)->get($columns);
@@ -800,32 +700,24 @@
/**
* Determine if any results exist for the current query.
- *
- * @return bool
*/
- public function exists()
+ public function exists(): bool
{
return ! is_null($this->first());
}
/**
* Determine if no results exist for the current query.
- *
- * @return bool
*/
- public function doesntExist()
+ public function doesntExist(): bool
{
return ! $this->exists();
}
/**
* Execute the given callback if no rows exist for the current query.
- *
- * @param Closure $callback
- *
- * @return bool|mixed
*/
- public function existsOr(Closure $callback)
+ public function existsOr(Closure $callback): mixed
{
return $this->exists() ? true : $callback();
}
@@ -833,12 +725,9 @@
/**
* Throws a not found exception.
*
- * @param string $query
- * @param string $dn
- *
* @throws ObjectNotFoundException
*/
- protected function throwNotFoundException($query, $dn)
+ protected function throwNotFoundException(string $query, ?string $dn = null): void
{
throw ObjectNotFoundException::forQuery($query, $dn);
}
@@ -846,18 +735,14 @@
/**
* Finds a record by the specified attribute and value.
*
- * @param string $attribute
- * @param string $value
- * @param array|string $columns
- *
* @return Model|static|null
*/
- public function findBy($attribute, $value, $columns = ['*'])
+ public function findBy(string $attribute, string $value, array|string $columns = ['*']): Model|array|null
{
try {
return $this->findByOrFail($attribute, $value, $columns);
} catch (ObjectNotFoundException $e) {
- return;
+ return null;
}
}
@@ -866,28 +751,17 @@
*
* If no record is found an exception is thrown.
*
- * @param string $attribute
- * @param string $value
- * @param array|string $columns
- *
- * @return Model
- *
* @throws ObjectNotFoundException
*/
- public function findByOrFail($attribute, $value, $columns = ['*'])
+ public function findByOrFail(string $attribute, string $value, array|string $columns = ['*']): Model|array
{
return $this->whereEquals($attribute, $value)->firstOrFail($columns);
}
/**
* Find many records by distinguished name.
- *
- * @param array $dns
- * @param array $columns
- *
- * @return array|Collection
*/
- public function findMany($dns, $columns = ['*'])
+ public function findMany(array|string $dns, array|string $columns = ['*']): Collection|array
{
if (empty($dns)) {
return $this->process([]);
@@ -895,7 +769,7 @@
$objects = [];
- foreach ($dns as $dn) {
+ foreach ((array) $dns as $dn) {
if (! is_null($object = $this->find($dn, $columns))) {
$objects[] = $object;
}
@@ -906,14 +780,8 @@
/**
* Finds many records by the specified attribute.
- *
- * @param string $attribute
- * @param array $values
- * @param array $columns
- *
- * @return Collection
*/
- public function findManyBy($attribute, array $values = [], $columns = ['*'])
+ public function findManyBy(string $attribute, array $values = [], array|string $columns = ['*']): Collection|array
{
$query = $this->select($columns);
@@ -926,13 +794,8 @@
/**
* Finds a record by its distinguished name.
- *
- * @param string|array $dn
- * @param array|string $columns
- *
- * @return Model|static|array|Collection|null
*/
- public function find($dn, $columns = ['*'])
+ public function find(array|string $dn, array|string $columns = ['*']): Collection|Model|array|null
{
if (is_array($dn)) {
return $this->findMany($dn, $columns);
@@ -941,7 +804,7 @@
try {
return $this->findOrFail($dn, $columns);
} catch (ObjectNotFoundException $e) {
- return;
+ return null;
}
}
@@ -950,14 +813,9 @@
*
* Fails upon no records returned.
*
- * @param string $dn
- * @param array|string $columns
- *
- * @return Model|static
- *
* @throws ObjectNotFoundException
*/
- public function findOrFail($dn, $columns = ['*'])
+ public function findOrFail(string $dn, array|string $columns = ['*']): Model|array
{
return $this->setDn($dn)
->read()
@@ -967,12 +825,8 @@
/**
* Adds the inserted fields to query on the current LDAP connection.
- *
- * @param array|string $columns
- *
- * @return $this
*/
- public function select($columns = ['*'])
+ public function select(array|string $columns = ['*']): static
{
$columns = is_array($columns) ? $columns : func_get_args();
@@ -985,12 +839,8 @@
/**
* Add a new select column to the query.
- *
- * @param array|mixed $column
- *
- * @return $this
*/
- public function addSelect($column)
+ public function addSelect(array|string $column): static
{
$column = is_array($column) ? $column : func_get_args();
@@ -1001,39 +851,38 @@
/**
* Add an order by control to the query.
- *
- * @param string $attribute
- * @param string $direction
- *
- * @return $this
*/
- public function orderBy($attribute, $direction = 'asc')
+ public function orderBy(string $attribute, string $direction = 'asc', array $options = []): static
{
return $this->addControl(LDAP_CONTROL_SORTREQUEST, true, [
- ['attr' => $attribute, 'reverse' => $direction === 'desc'],
+ [
+ ...$options,
+ 'attr' => $attribute,
+ 'reverse' => $direction === 'desc',
+ ],
]);
}
/**
* Add an order by descending control to the query.
- *
- * @param string $attribute
- *
- * @return $this
*/
- public function orderByDesc($attribute)
+ public function orderByDesc(string $attribute, array $options = []): static
{
- return $this->orderBy($attribute, 'desc');
+ return $this->orderBy($attribute, 'desc', $options);
+ }
+
+ /**
+ * Determine if the query has a sotr request control header.
+ */
+ public function hasOrderBy(): bool
+ {
+ return $this->hasControl(LDAP_CONTROL_SORTREQUEST);
}
/**
* Adds a raw filter to the current query.
- *
- * @param array|string $filters
- *
- * @return $this
*/
- public function rawFilter($filters = [])
+ public function rawFilter(array|string $filters = []): static
{
$filters = is_array($filters) ? $filters : func_get_args();
@@ -1046,12 +895,8 @@
/**
* Adds a nested 'and' filter to the current query.
- *
- * @param Closure $closure
- *
- * @return $this
*/
- public function andFilter(Closure $closure)
+ public function andFilter(Closure $closure): static
{
$query = $this->newNestedInstance($closure);
@@ -1062,12 +907,8 @@
/**
* Adds a nested 'or' filter to the current query.
- *
- * @param Closure $closure
- *
- * @return $this
*/
- public function orFilter(Closure $closure)
+ public function orFilter(Closure $closure): static
{
$query = $this->newNestedInstance($closure);
@@ -1078,12 +919,8 @@
/**
* Adds a nested 'not' filter to the current query.
- *
- * @param Closure $closure
- *
- * @return $this
*/
- public function notFilter(Closure $closure)
+ public function notFilter(Closure $closure): static
{
$query = $this->newNestedInstance($closure);
@@ -1095,31 +932,23 @@
/**
* Adds a where clause to the current query.
*
- * @param string|array $field
- * @param string $operator
- * @param string $value
- * @param string $boolean
- * @param bool $raw
- *
- * @return $this
- *
* @throws InvalidArgumentException
*/
- public function where($field, $operator = null, $value = null, $boolean = 'and', $raw = false)
+ public function where(array|string $field, mixed $operator = null, mixed $value = null, string $boolean = 'and', bool $raw = false): static
{
if (is_array($field)) {
// If the field is an array, we will assume we have been
// provided with an array of key-value pairs and can
- // add them each as their own seperate where clause.
+ // add them each as their own separate where clause.
return $this->addArrayOfWheres($field, $boolean, $raw);
}
// If we have been provided with two arguments not a "has" or
// "not has" operator, we'll assume the developer is creating
// an "equals" clause and set the proper operator in place.
- if (func_num_args() === 2 && ! in_array($operator, ['*', '!*'])) {
- [$value, $operator] = [$operator, '='];
- }
+ [$value, $operator] = $this->prepareValueAndOperator(
+ $value, $operator, func_num_args() === 2 && ! $this->operatorRequiresValue($operator)
+ );
if (! in_array($operator, $this->grammar->getOperators())) {
throw new InvalidArgumentException("Invalid LDAP filter operator [$operator]");
@@ -1128,7 +957,7 @@
// We'll escape the value if raw isn't requested.
$value = $this->prepareWhereValue($field, $value, $raw);
- $field = $this->escape($field)->both()->get();
+ $field = $this->escape($field)->forDnAndFilter()->get();
$this->addFilter($boolean, compact('field', 'operator', 'value'));
@@ -1136,135 +965,114 @@
}
/**
- * Prepare the value for being queried.
- *
- * @param string $field
- * @param string $value
- * @param bool $raw
- *
- * @return string
+ * Prepare the value and operator for a where clause.
*/
- protected function prepareWhereValue($field, $value, $raw = false)
+ public function prepareValueAndOperator(mixed $value, mixed $operator, bool $useDefault = false): array
{
- return $raw ? $value : $this->escape($value);
+ if ($useDefault) {
+ return [$operator, '='];
+ }
+
+ return [$value, $operator];
+ }
+
+ /**
+ * Determine if the operator requires a value to be present.
+ */
+ protected function operatorRequiresValue(mixed $operator): bool
+ {
+ return in_array($operator, ['*', '!*']);
+ }
+
+ /**
+ * Prepare the value for being queried.
+ */
+ protected function prepareWhereValue(string $field, mixed $value = null, bool $raw = false): string
+ {
+ return $raw ? $value : $this->escape($value)->get();
}
/**
* Adds a raw where clause to the current query.
*
* Values given to this method are not escaped.
- *
- * @param string|array $field
- * @param string $operator
- * @param string $value
- *
- * @return $this
*/
- public function whereRaw($field, $operator = null, $value = null)
+ public function whereRaw(array|string $field, ?string $operator = null, mixed $value = null): static
{
return $this->where($field, $operator, $value, 'and', true);
}
/**
* Adds a 'where equals' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereEquals($field, $value)
+ public function whereEquals(string $field, string $value): static
{
return $this->where($field, '=', $value);
}
/**
* Adds a 'where not equals' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereNotEquals($field, $value)
+ public function whereNotEquals(string $field, string $value): static
{
return $this->where($field, '!', $value);
}
/**
* Adds a 'where approximately equals' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereApproximatelyEquals($field, $value)
+ public function whereApproximatelyEquals(string $field, string $value): static
{
return $this->where($field, '~=', $value);
}
/**
* Adds a 'where has' clause to the current query.
- *
- * @param string $field
- *
- * @return $this
*/
- public function whereHas($field)
+ public function whereHas(string $field): static
{
return $this->where($field, '*');
}
/**
* Adds a 'where not has' clause to the current query.
- *
- * @param string $field
- *
- * @return $this
*/
- public function whereNotHas($field)
+ public function whereNotHas(string $field): static
{
return $this->where($field, '!*');
}
/**
* Adds a 'where contains' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereContains($field, $value)
+ public function whereContains(string $field, string $value): static
{
return $this->where($field, 'contains', $value);
}
/**
* Adds a 'where contains' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereNotContains($field, $value)
+ public function whereNotContains(string $field, string $value): static
{
return $this->where($field, 'not_contains', $value);
}
/**
* Query for entries that match any of the values provided for the given field.
- *
- * @param string $field
- * @param array $values
- *
- * @return $this
*/
- public function whereIn($field, array $values)
+ public function whereIn(string $field, array $values): static
{
- return $this->orFilter(function (self $query) use ($field, $values) {
+ if (empty($values)) {
+ // If the array of values is empty, we will
+ // add an empty OR filter to the query to
+ // ensure that no results are returned.
+ $this->rawFilter('(|)');
+
+ return $this;
+ }
+
+ return $this->orFilter(function (Builder $query) use ($field, $values) {
foreach ($values as $value) {
$query->whereEquals($field, $value);
}
@@ -1273,13 +1081,8 @@
/**
* Adds a 'between' clause to the current query.
- *
- * @param string $field
- * @param array $values
- *
- * @return $this
*/
- public function whereBetween($field, array $values)
+ public function whereBetween(string $field, array $values): static
{
return $this->where([
[$field, '>=', $values[0]],
@@ -1289,86 +1092,56 @@
/**
* Adds a 'where starts with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereStartsWith($field, $value)
+ public function whereStartsWith(string $field, string $value): static
{
return $this->where($field, 'starts_with', $value);
}
/**
* Adds a 'where *not* starts with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereNotStartsWith($field, $value)
+ public function whereNotStartsWith(string $field, string $value): static
{
return $this->where($field, 'not_starts_with', $value);
}
/**
* Adds a 'where ends with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereEndsWith($field, $value)
+ public function whereEndsWith(string $field, string $value): static
{
return $this->where($field, 'ends_with', $value);
}
/**
* Adds a 'where *not* ends with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function whereNotEndsWith($field, $value)
+ public function whereNotEndsWith(string $field, string $value): static
{
return $this->where($field, 'not_ends_with', $value);
}
/**
* Only include deleted models in the results.
- *
- * @return $this
*/
- public function whereDeleted()
+ public function whereDeleted(): static
{
return $this->withDeleted()->whereEquals('isDeleted', 'TRUE');
}
/**
* Set the LDAP control option to include deleted LDAP models.
- *
- * @return $this
*/
- public function withDeleted()
+ public function withDeleted(): static
{
return $this->addControl(LdapInterface::OID_SERVER_SHOW_DELETED, $isCritical = true);
}
/**
* Add a server control to the query.
- *
- * @param string $oid
- * @param bool $isCritical
- * @param mixed $value
- *
- * @return $this
*/
- public function addControl($oid, $isCritical = false, $value = null)
+ public function addControl(string $oid, bool $isCritical = false, mixed $value = null): static
{
$this->controls[$oid] = compact('oid', 'isCritical', 'value');
@@ -1377,27 +1150,21 @@
/**
* Determine if the server control exists on the query.
- *
- * @param string $oid
- *
- * @return bool
*/
- public function hasControl($oid)
+ public function hasControl(string $oid): bool
{
return array_key_exists($oid, $this->controls);
}
/**
* Adds an 'or where' clause to the current query.
- *
- * @param array|string $field
- * @param string|null $operator
- * @param string|null $value
- *
- * @return $this
*/
- public function orWhere($field, $operator = null, $value = null)
+ public function orWhere(array|string $field, ?string $operator = null, ?string $value = null): static
{
+ [$value, $operator] = $this->prepareValueAndOperator(
+ $value, $operator, func_num_args() === 2 && ! $this->operatorRequiresValue($operator)
+ );
+
return $this->where($field, $operator, $value, 'or');
}
@@ -1405,155 +1172,96 @@
* Adds a raw or where clause to the current query.
*
* Values given to this method are not escaped.
- *
- * @param string $field
- * @param string $operator
- * @param string $value
- *
- * @return $this
*/
- public function orWhereRaw($field, $operator = null, $value = null)
+ public function orWhereRaw(array|string $field, ?string $operator = null, ?string $value = null): static
{
return $this->where($field, $operator, $value, 'or', true);
}
/**
* Adds an 'or where has' clause to the current query.
- *
- * @param string $field
- *
- * @return $this
*/
- public function orWhereHas($field)
+ public function orWhereHas(string $field): static
{
return $this->orWhere($field, '*');
}
/**
* Adds a 'where not has' clause to the current query.
- *
- * @param string $field
- *
- * @return $this
*/
- public function orWhereNotHas($field)
+ public function orWhereNotHas(string $field): static
{
return $this->orWhere($field, '!*');
}
/**
* Adds an 'or where equals' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereEquals($field, $value)
+ public function orWhereEquals(string $field, string $value): static
{
return $this->orWhere($field, '=', $value);
}
/**
* Adds an 'or where not equals' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereNotEquals($field, $value)
+ public function orWhereNotEquals(string $field, string $value): static
{
return $this->orWhere($field, '!', $value);
}
/**
* Adds a 'or where approximately equals' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereApproximatelyEquals($field, $value)
+ public function orWhereApproximatelyEquals(string $field, string $value): static
{
return $this->orWhere($field, '~=', $value);
}
/**
* Adds an 'or where contains' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereContains($field, $value)
+ public function orWhereContains(string $field, string $value): static
{
return $this->orWhere($field, 'contains', $value);
}
/**
* Adds an 'or where *not* contains' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereNotContains($field, $value)
+ public function orWhereNotContains(string $field, string $value): static
{
return $this->orWhere($field, 'not_contains', $value);
}
/**
* Adds an 'or where starts with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereStartsWith($field, $value)
+ public function orWhereStartsWith(string $field, string $value): static
{
return $this->orWhere($field, 'starts_with', $value);
}
/**
* Adds an 'or where *not* starts with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereNotStartsWith($field, $value)
+ public function orWhereNotStartsWith(string $field, string $value): static
{
return $this->orWhere($field, 'not_starts_with', $value);
}
/**
* Adds an 'or where ends with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereEndsWith($field, $value)
+ public function orWhereEndsWith(string $field, string $value): static
{
return $this->orWhere($field, 'ends_with', $value);
}
/**
* Adds an 'or where *not* ends with' clause to the current query.
- *
- * @param string $field
- * @param string $value
- *
- * @return $this
*/
- public function orWhereNotEndsWith($field, $value)
+ public function orWhereNotEndsWith(string $field, string $value): static
{
return $this->orWhere($field, 'not_ends_with', $value);
}
@@ -1561,14 +1269,9 @@
/**
* Adds a filter binding onto the current query.
*
- * @param string $type The type of filter to add.
- * @param array $bindings The bindings of the filter.
- *
- * @return $this
- *
* @throws InvalidArgumentException
*/
- public function addFilter($type, array $bindings)
+ public function addFilter(string $type, array $bindings): static
{
if (! array_key_exists($type, $this->filters)) {
throw new InvalidArgumentException("Filter type: [$type] is invalid.");
@@ -1590,12 +1293,8 @@
/**
* Extract any missing required binding keys.
- *
- * @param array $bindings
- *
- * @return array
*/
- protected function missingBindingKeys($bindings)
+ protected function missingBindingKeys(array $bindings): array
{
$required = array_flip(['field', 'operator', 'value']);
@@ -1606,20 +1305,16 @@
/**
* Get all the filters on the query.
- *
- * @return array
*/
- public function getFilters()
+ public function getFilters(): array
{
return $this->filters;
}
/**
* Clear the query filters.
- *
- * @return $this
*/
- public function clearFilters()
+ public function clearFilters(): static
{
foreach (array_keys($this->filters) as $type) {
$this->filters[$type] = [];
@@ -1630,20 +1325,16 @@
/**
* Determine if the query has attributes selected.
- *
- * @return bool
*/
- public function hasSelects()
+ public function hasSelects(): bool
{
- return count($this->columns) > 0;
+ return count($this->columns ?? []) > 0;
}
/**
* Get the attributes to select on the search.
- *
- * @return array
*/
- public function getSelects()
+ public function getSelects(): array
{
$selects = $this->columns ?? ['*'];
@@ -1667,50 +1358,48 @@
* Set the query to search on the base distinguished name.
*
* This will result in one record being returned.
- *
- * @return $this
*/
- public function read()
+ public function read(): static
{
- $this->type = 'read';
+ $this->type = self::TYPE_READ;
return $this;
}
/**
* Set the query to search one level on the base distinguished name.
- *
- * @return $this
*/
- public function listing()
+ public function list(): static
{
- $this->type = 'listing';
+ $this->type = self::TYPE_LIST;
return $this;
}
/**
- * Set the query to search the entire directory on the base distinguished name.
- *
- * @return $this
+ * Alias for the "search" method.
*/
- public function recursive()
+ public function recursive(): static
{
- $this->type = 'search';
+ return $this->search();
+ }
+
+ /**
+ * Set the query to search the entire directory on the base distinguished name.
+ */
+ public function search(): static
+ {
+ $this->type = self::TYPE_SEARCH;
return $this;
}
/**
* Whether to mark the current query as nested.
- *
- * @param bool $nested
- *
- * @return $this
*/
- public function nested($nested = true)
+ public function nested(bool $nested = true): static
{
- $this->nested = (bool) $nested;
+ $this->nested = $nested;
return $this;
}
@@ -1719,15 +1408,11 @@
* Enables caching on the current query until the given date.
*
* If flushing is enabled, the query cache will be flushed and then re-cached.
- *
- * @param DateTimeInterface $until When to expire the query cache.
- * @param bool $flush Whether to force-flush the query cache.
- *
- * @return $this
*/
- public function cache(DateTimeInterface $until = null, $flush = false)
+ public function cache(?DateTimeInterface $until = null, bool $flush = false, ?string $key = null): static
{
$this->caching = true;
+ $this->cacheKey = $key;
$this->cacheUntil = $until;
$this->flushCache = $flush;
@@ -1736,20 +1421,16 @@
/**
* Determine if the query is nested.
- *
- * @return bool
*/
- public function isNested()
+ public function isNested(): bool
{
return $this->nested === true;
}
/**
* Determine whether the query is paginated.
- *
- * @return bool
*/
- public function isPaginated()
+ public function isPaginated(): bool
{
return $this->paginated;
}
@@ -1757,15 +1438,22 @@
/**
* Insert an entry into the directory.
*
- * @param string $dn
- * @param array $attributes
- *
- * @return bool
+ * @throws LdapRecordException
+ */
+ public function insert(string $dn, array $attributes): bool
+ {
+ return (bool) $this->insertAndGetDn($dn, $attributes);
+ }
+
+ /**
+ * Insert an entry into the directory and get the inserted distinguished name.
*
* @throws LdapRecordException
*/
- public function insert($dn, array $attributes)
+ public function insertAndGetDn(string $dn, array $attributes): string|false
{
+ $dn = $this->substituteBaseDn($dn);
+
if (empty($dn)) {
throw new LdapRecordException('A new LDAP object must have a distinguished name (dn).');
}
@@ -1776,118 +1464,100 @@
);
}
- return $this->connection->run(function (LdapInterface $ldap) use ($dn, $attributes) {
- return $ldap->add($dn, $attributes);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->add($dn, $attributes)
+ ) ? $dn : false;
}
/**
- * Create attributes on the entry in the directory.
- *
- * @param string $dn
- * @param array $attributes
- *
- * @return bool
+ * Add attributes to an entry in the directory.
*/
- public function insertAttributes($dn, array $attributes)
+ public function add(string $dn, array $attributes): bool
{
- return $this->connection->run(function (LdapInterface $ldap) use ($dn, $attributes) {
- return $ldap->modAdd($dn, $attributes);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->modAdd($dn, $attributes)
+ );
}
/**
* Update the entry with the given modifications.
- *
- * @param string $dn
- * @param array $modifications
- *
- * @return bool
*/
- public function update($dn, array $modifications)
+ public function update(string $dn, array $modifications): bool
{
- return $this->connection->run(function (LdapInterface $ldap) use ($dn, $modifications) {
- return $ldap->modifyBatch($dn, $modifications);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->modifyBatch($dn, $modifications)
+ );
}
/**
- * Update an entries attribute in the directory.
- *
- * @param string $dn
- * @param array $attributes
- *
- * @return bool
+ * Replace an entry's attributes in the directory.
*/
- public function updateAttributes($dn, array $attributes)
+ public function replace(string $dn, array $attributes): bool
{
- return $this->connection->run(function (LdapInterface $ldap) use ($dn, $attributes) {
- return $ldap->modReplace($dn, $attributes);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->modReplace($dn, $attributes)
+ );
}
/**
* Delete an entry from the directory.
- *
- * @param string $dn
- *
- * @return bool
*/
- public function delete($dn)
+ public function delete(string $dn): bool
{
- return $this->connection->run(function (LdapInterface $ldap) use ($dn) {
- return $ldap->delete($dn);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->delete($dn)
+ );
}
/**
- * Delete attributes on the entry in the directory.
- *
- * @param string $dn
- * @param array $attributes
- *
- * @return bool
+ * Remove attributes on the entry in the directory.
*/
- public function deleteAttributes($dn, array $attributes)
+ public function remove(string $dn, array $attributes): bool
{
- return $this->connection->run(function (LdapInterface $ldap) use ($dn, $attributes) {
- return $ldap->modDelete($dn, $attributes);
- });
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->modDelete($dn, $attributes)
+ );
}
/**
* Rename an entry in the directory.
- *
- * @param string $dn
- * @param string $rdn
- * @param string $newParentDn
- * @param bool $deleteOldRdn
- *
- * @return bool
*/
- public function rename($dn, $rdn, $newParentDn, $deleteOldRdn = true)
+ public function rename(string $dn, string $rdn, string $newParentDn, bool $deleteOldRdn = true): bool
{
- return $this->connection->run(function (LdapInterface $ldap) use ($dn, $rdn, $newParentDn, $deleteOldRdn) {
- return $ldap->rename($dn, $rdn, $newParentDn, $deleteOldRdn);
- });
+ return (bool) $this->renameAndGetDn($dn, $rdn, $newParentDn, $deleteOldRdn);
+ }
+
+ /**
+ * Rename an entry in the directory and get the new distinguished name.
+ */
+ public function renameAndGetDn(string $dn, string $rdn, string $newParentDn, bool $deleteOldRdn = true): string|false
+ {
+ $newParentDn = $this->substituteBaseDn($newParentDn);
+
+ return $this->connection->run(
+ fn (LdapInterface $ldap) => $ldap->rename($dn, $rdn, $newParentDn, $deleteOldRdn)
+ ) ? implode(',', [$rdn, $newParentDn]) : false;
+ }
+
+ /**
+ * Clone the query.
+ */
+ public function clone(): static
+ {
+ return clone $this;
}
/**
* Handle dynamic method calls on the query builder.
*
- * @param string $method
- * @param array $parameters
- *
- * @return mixed
- *
* @throws BadMethodCallException
*/
- public function __call($method, $parameters)
+ public function __call(string $method, array $parameters): static
{
// If the beginning of the method being called contains
// 'where', we will assume a dynamic 'where' clause is
// being performed and pass the parameters to it.
- if (substr($method, 0, 5) === 'where') {
+ if (str_starts_with($method, 'where')) {
return $this->dynamicWhere($method, $parameters);
}
@@ -1901,12 +1571,9 @@
/**
* Handles dynamic "where" clauses to the query.
*
- * @param string $method
- * @param array $parameters
- *
* @return $this
*/
- public function dynamicWhere($method, $parameters)
+ public function dynamicWhere(string $method, array $parameters): static
{
$finder = substr($method, 5);
@@ -1942,14 +1609,8 @@
/**
* Adds an array of wheres to the current query.
- *
- * @param array $wheres
- * @param string $boolean
- * @param bool $raw
- *
- * @return $this
*/
- protected function addArrayOfWheres($wheres, $boolean, $raw)
+ protected function addArrayOfWheres(array $wheres, string $boolean, bool $raw): static
{
foreach ($wheres as $key => $value) {
if (is_numeric($key) && is_array($value)) {
@@ -1974,15 +1635,8 @@
/**
* Add a single dynamic where clause statement to the query.
- *
- * @param string $segment
- * @param string $connector
- * @param array $parameters
- * @param int $index
- *
- * @return void
*/
- protected function addDynamic($segment, $connector, $parameters, $index)
+ protected function addDynamic(string $segment, string $connector, array $parameters, int $index): void
{
// If no parameters were given to the dynamic where clause,
// we can assume a "has" attribute filter is being added.
@@ -1995,58 +1649,34 @@
/**
* Logs the given executed query information by firing its query event.
- *
- * @param Builder $query
- * @param string $type
- * @param null|float $time
- *
- * @return void
*/
- protected function logQuery($query, $type, $time = null)
+ protected function logQuery(Builder $query, string $type, ?float $time = null): void
{
$args = [$query, $time];
- switch ($type) {
- case 'listing':
- $event = new Events\Listing(...$args);
- break;
- case 'read':
- $event = new Events\Read(...$args);
- break;
- case 'chunk':
- $event = new Events\Chunk(...$args);
- break;
- case 'paginate':
- $event = new Events\Paginate(...$args);
- break;
- default:
- $event = new Events\Search(...$args);
- break;
- }
-
- $this->fireQueryEvent($event);
+ $this->fireQueryEvent(
+ match ($type) {
+ self::TYPE_READ => new Events\Read(...$args),
+ self::TYPE_CHUNK => new Events\Chunk(...$args),
+ self::TYPE_LIST => new Events\Listing(...$args),
+ self::TYPE_PAGINATE => new Events\Paginate(...$args),
+ default => new Events\Search(...$args),
+ }
+ );
}
/**
* Fires the given query event.
- *
- * @param QueryExecuted $event
- *
- * @return void
*/
- protected function fireQueryEvent(QueryExecuted $event)
+ protected function fireQueryEvent(QueryExecuted $event): void
{
- Container::getInstance()->getEventDispatcher()->fire($event);
+ Container::getInstance()->getDispatcher()->fire($event);
}
/**
* Get the elapsed time since a given starting point.
- *
- * @param int $start
- *
- * @return float
*/
- protected function getElapsedTime($start)
+ protected function getElapsedTime(float $start): float
{
return round((microtime(true) - $start) * 1000, 2);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Cache.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Cache.php
index dfbf8cd..184455c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Cache.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Cache.php
@@ -13,15 +13,11 @@
/**
* The cache driver.
- *
- * @var CacheInterface
*/
- protected $store;
+ protected CacheInterface $store;
/**
* Constructor.
- *
- * @param CacheInterface $store
*/
public function __construct(CacheInterface $store)
{
@@ -30,50 +26,26 @@
/**
* Get an item from the cache.
- *
- * @param string $key
- *
- * @return mixed
*/
- public function get($key)
+ public function get(string $key): mixed
{
return $this->store->get($key);
}
/**
* Store an item in the cache.
- *
- * @param string $key
- * @param mixed $value
- * @param DateTimeInterface|DateInterval|int|null $ttl
- *
- * @return bool
*/
- public function put($key, $value, $ttl = null)
+ public function put(string $key, mixed $value, DateTimeInterface|DateInterval|int|null $ttl = null): bool
{
- $seconds = $this->secondsUntil($ttl);
-
- if ($seconds <= 0) {
- return $this->delete($key);
- }
-
- return $this->store->set($key, $value, $seconds);
+ return $this->store->set($key, $value, $this->secondsUntil($ttl));
}
/**
* Get an item from the cache, or execute the given Closure and store the result.
- *
- * @param string $key
- * @param DateTimeInterface|DateInterval|int|null $ttl
- * @param Closure $callback
- *
- * @return mixed
*/
- public function remember($key, $ttl, Closure $callback)
+ public function remember(string $key, DateTimeInterface|DateInterval|int|null $ttl, Closure $callback): mixed
{
- $value = $this->get($key);
-
- if (! is_null($value)) {
+ if (! is_null($value = $this->get($key))) {
return $value;
}
@@ -84,22 +56,16 @@
/**
* Delete an item from the cache.
- *
- * @param string $key
- *
- * @return bool
*/
- public function delete($key)
+ public function delete(string $key): bool
{
return $this->store->delete($key);
}
/**
* Get the underlying cache store.
- *
- * @return CacheInterface
*/
- public function store()
+ public function store(): CacheInterface
{
return $this->store;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php
index 036affa..9cda10c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Collection.php
@@ -2,25 +2,23 @@
namespace LdapRecord\Query;
+use Illuminate\Support\Collection as BaseCollection;
use LdapRecord\Models\Model;
-use Tightenco\Collect\Support\Collection as BaseCollection;
class Collection extends BaseCollection
{
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected function valueRetriever($value)
+ protected function valueRetriever(mixed $value): callable
{
if ($this->useAsCallable($value)) {
/** @var callable $value */
return $value;
}
- return function ($item) use ($value) {
- return $item instanceof Model
+ return fn ($item) => $item instanceof Model
? $item->getFirstAttribute($value)
: data_get($item, $value);
- };
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php
index 4f17ea2..95cadd6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Events/QueryExecuted.php
@@ -8,46 +8,35 @@
{
/**
* The LDAP filter that was used for the query.
- *
- * @var Builder
*/
- protected $query;
+ protected Builder $query;
/**
* The number of milliseconds it took to execute the query.
- *
- * @var ?float
*/
- protected $time;
+ protected ?float $time;
/**
* Constructor.
- *
- * @param Builder $query
- * @param null|float $time
*/
- public function __construct(Builder $query, $time = null)
+ public function __construct(Builder $query, ?float $time = null)
{
$this->query = $query;
$this->time = $time;
}
/**
- * Returns the LDAP filter that was used for the query.
- *
- * @return Builder
+ * Get the LDAP filter that was used for the query.
*/
- public function getQuery()
+ public function getQuery(): Builder
{
return $this->query;
}
/**
- * Returns the number of milliseconds it took to execute the query.
- *
- * @return float|null
+ * Get the number of milliseconds it took to execute the query.
*/
- public function getTime()
+ public function getTime(): ?float
{
return $this->time;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/ConditionNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/ConditionNode.php
new file mode 100644
index 0000000..4dfed72
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/ConditionNode.php
@@ -0,0 +1,77 @@
+<?php
+
+namespace LdapRecord\Query\Filter;
+
+use LdapRecord\Support\Str;
+
+class ConditionNode extends Node
+{
+ /**
+ * The condition's attribute.
+ */
+ protected string $attribute;
+
+ /**
+ * The condition's operator.
+ */
+ protected string $operator;
+
+ /**
+ * The condition's value.
+ */
+ protected string $value;
+
+ /**
+ * The available condition operators.
+ */
+ protected array $operators = ['>=', '<=', '~=', '='];
+
+ /**
+ * Constructor.
+ */
+ public function __construct(string $filter)
+ {
+ $this->raw = $filter;
+
+ [$this->attribute, $this->value] = $this->extractComponents($filter);
+ }
+
+ /**
+ * Get the condition's attribute.
+ */
+ public function getAttribute(): string
+ {
+ return $this->attribute;
+ }
+
+ /**
+ * Get the condition's operator.
+ */
+ public function getOperator(): string
+ {
+ return $this->operator;
+ }
+
+ /**
+ * Get the condition's value.
+ */
+ public function getValue(): string
+ {
+ return $this->value;
+ }
+
+ /**
+ * Extract the condition components from the filter.
+ */
+ protected function extractComponents(string $filter): array
+ {
+ $components = Str::whenContains(
+ $filter,
+ $this->operators,
+ fn ($operator, $filter) => explode($this->operator = $operator, $filter, 2),
+ fn ($filter) => throw new ParserException("Invalid query condition. No operator found in [$filter]"),
+ );
+
+ return $components;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/GroupNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/GroupNode.php
new file mode 100644
index 0000000..1af7136
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/GroupNode.php
@@ -0,0 +1,48 @@
+<?php
+
+namespace LdapRecord\Query\Filter;
+
+class GroupNode extends Node
+{
+ /**
+ * The group's operator.
+ */
+ protected string $operator;
+
+ /**
+ * The group's sub-nodes.
+ *
+ * @var Node[]
+ */
+ protected array $nodes = [];
+
+ /**
+ * Constructor.
+ */
+ public function __construct(string $filter)
+ {
+ $this->raw = $filter;
+
+ $this->operator = substr($filter, 0, 1);
+
+ $this->nodes = Parser::parse($filter);
+ }
+
+ /**
+ * Get the group's operator.
+ */
+ public function getOperator(): string
+ {
+ return $this->operator;
+ }
+
+ /**
+ * Get the group's sub-nodes.
+ *
+ * @return Node[]
+ */
+ public function getNodes(): array
+ {
+ return $this->nodes;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/Node.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/Node.php
new file mode 100644
index 0000000..3e9c039
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/Node.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace LdapRecord\Query\Filter;
+
+abstract class Node
+{
+ /**
+ * The raw value of the node.
+ */
+ protected string $raw;
+
+ /**
+ * Create a new filter node.
+ */
+ abstract public function __construct(string $filter);
+
+ /**
+ * Get the raw value of the node.
+ */
+ public function getRaw(): string
+ {
+ return $this->raw;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/Parser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/Parser.php
new file mode 100644
index 0000000..1fea181
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/Parser.php
@@ -0,0 +1,139 @@
+<?php
+
+namespace LdapRecord\Query\Filter;
+
+use LdapRecord\Support\Arr;
+use LdapRecord\Support\Str;
+
+class Parser
+{
+ /**
+ * Parse an LDAP filter into nodes.
+ *
+ * @return (ConditionNode|GroupNode)[]
+ *
+ * @throws ParserException
+ */
+ public static function parse(string $string): array
+ {
+ [$open, $close] = static::countParenthesis($string);
+
+ if ($open !== $close) {
+ $errors = [-1 => '"("', 1 => '")"'];
+
+ throw new ParserException(
+ sprintf('Unclosed filter group. Missing %s parenthesis', $errors[$open <=> $close])
+ );
+ }
+
+ return static::buildNodes(
+ array_map('trim', static::match($string))
+ );
+ }
+
+ /**
+ * Perform a match for all filters in the string.
+ */
+ protected static function match(string $string): array
+ {
+ preg_match_all("/\((((?>[^()]+)|(?R))*)\)/", trim($string), $matches);
+
+ return $matches[1] ?? [];
+ }
+
+ /**
+ * Assemble the parsed nodes into a single filter.
+ *
+ * @param Node|Node[] $nodes
+ */
+ public static function assemble(Node|array $nodes = []): string
+ {
+ return array_reduce(Arr::wrap($nodes), fn ($carry, Node $node) => (
+ $carry .= static::compileNode($node)
+ ));
+ }
+
+ /**
+ * Assemble the node into its string based format.
+ */
+ protected static function compileNode(Node $node): string
+ {
+ switch (true) {
+ case $node instanceof GroupNode:
+ return static::wrap($node->getOperator().static::assemble($node->getNodes()));
+ case $node instanceof ConditionNode:
+ return static::wrap($node->getAttribute().$node->getOperator().$node->getValue());
+ default:
+ return $node->getRaw();
+ }
+ }
+
+ /**
+ * Build an array of nodes from the given filters.
+ *
+ * @param string[] $filters
+ * @return (ConditionNode|GroupNode)[]
+ *
+ * @throws ParserException
+ */
+ protected static function buildNodes(array $filters = []): array
+ {
+ return array_map(function ($filter) {
+ if (static::isWrapped($filter)) {
+ $filter = static::unwrap($filter);
+ }
+
+ if (static::isGroup($filter) && ! Str::endsWith($filter, ')')) {
+ throw new ParserException(sprintf('Unclosed filter group [%s]', Str::afterLast($filter, ')')));
+ }
+
+ return static::isGroup($filter)
+ ? new GroupNode($filter)
+ : new ConditionNode($filter);
+ }, $filters);
+ }
+
+ /**
+ * Count the open and close parenthesis of the sting.
+ */
+ protected static function countParenthesis(string $string): array
+ {
+ return [Str::substrCount($string, '('), Str::substrCount($string, ')')];
+ }
+
+ /**
+ * Wrap the value in parentheses.
+ */
+ protected static function wrap(string $value): string
+ {
+ return "($value)";
+ }
+
+ /**
+ * Recursively unwrwap the value from its parentheses.
+ */
+ protected static function unwrap(string $value): string
+ {
+ $nodes = static::parse($value);
+
+ $unwrapped = Arr::first($nodes);
+
+ return $unwrapped instanceof Node ? $unwrapped->getRaw() : $value;
+ }
+
+ /**
+ * Determine if the filter is wrapped.
+ */
+ protected static function isWrapped(string $filter): bool
+ {
+ return Str::startsWith($filter, '(') && Str::endsWith($filter, ')');
+ }
+
+ /**
+ * Determine if the filter is a group.
+ */
+ protected static function isGroup(string $filter): bool
+ {
+ return Str::startsWith($filter, ['&', '|', '!']);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/ParserException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/ParserException.php
new file mode 100644
index 0000000..3c3d68e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Filter/ParserException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace LdapRecord\Query\Filter;
+
+use LdapRecord\LdapRecordException;
+
+class ParserException extends LdapRecordException {}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php
index 35a6c48..0506c98 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Grammar.php
@@ -8,10 +8,8 @@
{
/**
* The query operators and their method names.
- *
- * @var array
*/
- public $operators = [
+ public array $operators = [
'*' => 'has',
'!*' => 'notHas',
'=' => 'equals',
@@ -30,17 +28,13 @@
/**
* The query wrapper.
- *
- * @var string|null
*/
- protected $wrapper;
+ protected ?string $wrapper = null;
/**
* Get all the available operators.
- *
- * @return array
*/
- public function getOperators()
+ public function getOperators(): array
{
return array_keys($this->operators);
}
@@ -49,26 +43,16 @@
* Wraps a query string in brackets.
*
* Produces: (query)
- *
- * @param string $query
- * @param string $prefix
- * @param string $suffix
- *
- * @return string
*/
- public function wrap($query, $prefix = '(', $suffix = ')')
+ public function wrap(string $query, ?string $prefix = '(', ?string $suffix = ')'): string
{
return $prefix.$query.$suffix;
}
/**
* Compiles the Builder instance into an LDAP query string.
- *
- * @param Builder $query
- *
- * @return string
*/
- public function compile(Builder $query)
+ public function compile(Builder $query): string
{
if ($this->queryMustBeWrapped($query)) {
$this->wrapper = 'and';
@@ -78,53 +62,37 @@
.$this->compileWheres($query)
.$this->compileOrWheres($query);
- switch ($this->wrapper) {
- case 'and':
- return $this->compileAnd($filter);
- case 'or':
- return $this->compileOr($filter);
- default:
- return $filter;
- }
+ return match ($this->wrapper) {
+ 'and' => $this->compileAnd($filter),
+ 'or' => $this->compileOr($filter),
+ default => $filter,
+ };
}
/**
* Determine if the query must be wrapped in an encapsulating statement.
- *
- * @param Builder $query
- *
- * @return bool
*/
- protected function queryMustBeWrapped(Builder $query)
+ protected function queryMustBeWrapped(Builder $query): bool
{
return ! $query->isNested() && $this->hasMultipleFilters($query);
}
/**
- * Assembles all of the "raw" filters on the query.
- *
- * @param Builder $builder
- *
- * @return string
+ * Assembles all the "raw" filters on the query.
*/
- protected function compileRaws(Builder $builder)
+ protected function compileRaws(Builder $builder): string
{
return $this->concatenate($builder->filters['raw']);
}
/**
* Assembles all where clauses in the current wheres property.
- *
- * @param Builder $builder
- * @param string $type
- *
- * @return string
*/
- protected function compileWheres(Builder $builder, $type = 'and')
+ protected function compileWheres(Builder $builder, string $type = 'and'): string
{
$filter = '';
- foreach ($builder->filters[$type] as $where) {
+ foreach ($builder->filters[$type] ?? [] as $where) {
$filter .= $this->compileWhere($where);
}
@@ -133,12 +101,8 @@
/**
* Assembles all or where clauses in the current orWheres property.
- *
- * @param Builder $query
- *
- * @return string
*/
- protected function compileOrWheres(Builder $query)
+ protected function compileOrWheres(Builder $query): string
{
$filter = $this->compileWheres($query, 'or');
@@ -160,26 +124,18 @@
/**
* Determine if the query can be wrapped in a single or statement.
- *
- * @param Builder $query
- *
- * @return bool
*/
- protected function queryCanBeWrappedInSingleOrStatement(Builder $query)
+ protected function queryCanBeWrappedInSingleOrStatement(Builder $query): bool
{
- return $this->has($query, 'or', '>=', 1) &&
- $this->has($query, 'and', '<=', 1) &&
- $this->has($query, 'raw', '=', 0);
+ return $this->has($query, 'or', '>=', 1)
+ && $this->has($query, 'and', '<=', 1)
+ && $this->has($query, 'raw', '=', 0);
}
/**
* Concatenates filters into a single string.
- *
- * @param array $bindings
- *
- * @return string
*/
- public function concatenate(array $bindings = [])
+ public function concatenate(array $bindings = []): string
{
// Filter out empty query segments.
return implode(
@@ -189,73 +145,48 @@
/**
* Determine if the binding value is not empty.
- *
- * @param string $value
- *
- * @return bool
*/
- protected function bindingValueIsNotEmpty($value)
+ protected function bindingValueIsNotEmpty(string $value): bool
{
return ! empty($value);
}
/**
* Determine if the query is using multiple filters.
- *
- * @param Builder $query
- *
- * @return bool
*/
- protected function hasMultipleFilters(Builder $query)
+ protected function hasMultipleFilters(Builder $query): bool
{
return $this->has($query, ['and', 'or', 'raw'], '>', 1);
}
/**
* Determine if the query contains the given filter statement type.
- *
- * @param Builder $query
- * @param string|array $type
- * @param string $operator
- * @param int $count
- *
- * @return bool
*/
- protected function has(Builder $query, $type, $operator = '>=', $count = 1)
+ protected function has(Builder $query, array|string $type, string $operator = '>=', int $count = 1): bool
{
$types = (array) $type;
$filters = 0;
foreach ($types as $type) {
- $filters += count($query->filters[$type]);
+ $filters += count($query->filters[$type] ?? []);
}
- switch ($operator) {
- case '>':
- return $filters > $count;
- case '>=':
- return $filters >= $count;
- case '<':
- return $filters < $count;
- case '<=':
- return $filters <= $count;
- default:
- return $filters == $count;
- }
+ return match ($operator) {
+ '>' => $filters > $count,
+ '>=' => $filters >= $count,
+ '<' => $filters < $count,
+ '<=' => $filters <= $count,
+ default => $filters == $count,
+ };
}
/**
* Returns a query string for equals.
*
* Produces: (field=value)
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileEquals($field, $value)
+ public function compileEquals(string $field, string $value): string
{
return $this->wrap($field.'='.$value);
}
@@ -264,13 +195,8 @@
* Returns a query string for does not equal.
*
* Produces: (!(field=value))
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileDoesNotEqual($field, $value)
+ public function compileDoesNotEqual(string $field, string $value): string
{
return $this->compileNot(
$this->compileEquals($field, $value)
@@ -281,13 +207,8 @@
* Alias for does not equal operator (!=) operator.
*
* Produces: (!(field=value))
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileDoesNotEqualAlias($field, $value)
+ public function compileDoesNotEqualAlias(string $field, string $value): string
{
return $this->compileDoesNotEqual($field, $value);
}
@@ -296,13 +217,8 @@
* Returns a query string for greater than or equals.
*
* Produces: (field>=value)
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileGreaterThanOrEquals($field, $value)
+ public function compileGreaterThanOrEquals(string $field, string $value): string
{
return $this->wrap("$field>=$value");
}
@@ -311,13 +227,8 @@
* Returns a query string for less than or equals.
*
* Produces: (field<=value)
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileLessThanOrEquals($field, $value)
+ public function compileLessThanOrEquals(string $field, string $value): string
{
return $this->wrap("$field<=$value");
}
@@ -326,13 +237,8 @@
* Returns a query string for approximately equals.
*
* Produces: (field~=value)
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileApproximatelyEquals($field, $value)
+ public function compileApproximatelyEquals(string $field, string $value): string
{
return $this->wrap("$field~=$value");
}
@@ -341,13 +247,8 @@
* Returns a query string for starts with.
*
* Produces: (field=value*)
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileStartsWith($field, $value)
+ public function compileStartsWith(string $field, string $value): string
{
return $this->wrap("$field=$value*");
}
@@ -356,13 +257,8 @@
* Returns a query string for does not start with.
*
* Produces: (!(field=*value))
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileNotStartsWith($field, $value)
+ public function compileNotStartsWith(string $field, string $value): string
{
return $this->compileNot(
$this->compileStartsWith($field, $value)
@@ -373,13 +269,8 @@
* Returns a query string for ends with.
*
* Produces: (field=*value)
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileEndsWith($field, $value)
+ public function compileEndsWith(string $field, string $value): string
{
return $this->wrap("$field=*$value");
}
@@ -388,13 +279,8 @@
* Returns a query string for does not end with.
*
* Produces: (!(field=value*))
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileNotEndsWith($field, $value)
+ public function compileNotEndsWith(string $field, string $value): string
{
return $this->compileNot($this->compileEndsWith($field, $value));
}
@@ -403,13 +289,8 @@
* Returns a query string for contains.
*
* Produces: (field=*value*)
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileContains($field, $value)
+ public function compileContains(string $field, string $value): string
{
return $this->wrap("$field=*$value*");
}
@@ -418,13 +299,8 @@
* Returns a query string for does not contain.
*
* Produces: (!(field=*value*))
- *
- * @param string $field
- * @param string $value
- *
- * @return string
*/
- public function compileNotContains($field, $value)
+ public function compileNotContains(string $field, string $value): string
{
return $this->compileNot(
$this->compileContains($field, $value)
@@ -435,12 +311,8 @@
* Returns a query string for a where has.
*
* Produces: (field=*)
- *
- * @param string $field
- *
- * @return string
*/
- public function compileHas($field)
+ public function compileHas(string $field): string
{
return $this->wrap("$field=*");
}
@@ -449,12 +321,8 @@
* Returns a query string for a where does not have.
*
* Produces: (!(field=*))
- *
- * @param string $field
- *
- * @return string
*/
- public function compileNotHas($field)
+ public function compileNotHas(string $field): string
{
return $this->compileNot(
$this->compileHas($field)
@@ -465,12 +333,8 @@
* Wraps the inserted query inside an AND operator.
*
* Produces: (&query)
- *
- * @param string $query
- *
- * @return string
*/
- public function compileAnd($query)
+ public function compileAnd(string $query): string
{
return $query ? $this->wrap($query, '(&') : '';
}
@@ -479,24 +343,16 @@
* Wraps the inserted query inside an OR operator.
*
* Produces: (|query)
- *
- * @param string $query
- *
- * @return string
*/
- public function compileOr($query)
+ public function compileOr(string $query): string
{
return $query ? $this->wrap($query, '(|') : '';
}
/**
* Wraps the inserted query inside an NOT operator.
- *
- * @param string $query
- *
- * @return string
*/
- public function compileNot($query)
+ public function compileNot(string $query): string
{
return $query ? $this->wrap($query, '(!') : '';
}
@@ -504,13 +360,9 @@
/**
* Assembles a single where query.
*
- * @param array $where
- *
- * @return string
- *
* @throws UnexpectedValueException
*/
- protected function compileWhere(array $where)
+ protected function compileWhere(array $where): string
{
$method = $this->makeCompileMethod($where['operator']);
@@ -520,13 +372,9 @@
/**
* Make the compile method name for the operator.
*
- * @param string $operator
- *
- * @return string
- *
* @throws UnexpectedValueException
*/
- protected function makeCompileMethod($operator)
+ protected function makeCompileMethod(string $operator): string
{
if (! $this->operatorExists($operator)) {
throw new UnexpectedValueException("Invalid LDAP filter operator ['$operator']");
@@ -537,12 +385,8 @@
/**
* Determine if the operator exists.
- *
- * @param string $operator
- *
- * @return bool
*/
- protected function operatorExists($operator)
+ protected function operatorExists(string $operator): bool
{
return array_key_exists($operator, $this->operators);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/InteractsWithTime.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/InteractsWithTime.php
index 1562ec0..111c2c2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/InteractsWithTime.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/InteractsWithTime.php
@@ -15,12 +15,8 @@
{
/**
* Get the number of seconds until the given DateTime.
- *
- * @param DateTimeInterface|DateInterval|int $delay
- *
- * @return int
*/
- protected function secondsUntil($delay)
+ protected function secondsUntil(DateTimeInterface|DateInterval|int|null $delay = null): int
{
$delay = $this->parseDateInterval($delay);
@@ -31,12 +27,8 @@
/**
* Get the "available at" UNIX timestamp.
- *
- * @param DateTimeInterface|DateInterval|int $delay
- *
- * @return int
*/
- protected function availableAt($delay = 0)
+ protected function availableAt(DateTimeInterface|DateInterval|int $delay = 0): int
{
$delay = $this->parseDateInterval($delay);
@@ -47,12 +39,8 @@
/**
* If the given value is an interval, convert it to a DateTime instance.
- *
- * @param DateTimeInterface|DateInterval|int $delay
- *
- * @return DateTimeInterface|int
*/
- protected function parseDateInterval($delay)
+ protected function parseDateInterval(DateTimeInterface|DateInterval|int|null $delay = null): DateTimeInterface|int|null
{
if ($delay instanceof DateInterval) {
$delay = Carbon::now()->add($delay);
@@ -63,10 +51,8 @@
/**
* Get the current system time as a UNIX timestamp.
- *
- * @return int
*/
- protected function currentTime()
+ protected function currentTime(): int
{
return Carbon::now()->getTimestamp();
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php
index c3911d8..7fb8ab6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/ActiveDirectoryBuilder.php
@@ -5,24 +5,20 @@
use Closure;
use LdapRecord\LdapInterface;
use LdapRecord\Models\Attributes\AccountControl;
+use LdapRecord\Models\Model;
use LdapRecord\Models\ModelNotFoundException;
class ActiveDirectoryBuilder extends Builder
{
/**
* Finds a record by its Object SID.
- *
- * @param string $sid
- * @param array|string $columns
- *
- * @return \LdapRecord\Models\ActiveDirectory\Entry|static|null
*/
- public function findBySid($sid, $columns = [])
+ public function findBySid(string $sid, array|string $columns = ['*']): ?Model
{
try {
return $this->findBySidOrFail($sid, $columns);
- } catch (ModelNotFoundException $e) {
- return;
+ } catch (ModelNotFoundException) {
+ return null;
}
}
@@ -31,202 +27,157 @@
*
* Fails upon no records returned.
*
- * @param string $sid
- * @param array|string $columns
- *
- * @return \LdapRecord\Models\ActiveDirectory\Entry|static
- *
* @throws ModelNotFoundException
*/
- public function findBySidOrFail($sid, $columns = [])
+ public function findBySidOrFail(string $sid, array $columns = ['*']): Model
{
return $this->findByOrFail('objectsid', $sid, $columns);
}
/**
* Adds a enabled filter to the current query.
- *
- * @return $this
*/
- public function whereEnabled()
+ public function whereEnabled(): static
{
- return $this->notFilter(function ($query) {
- return $query->whereDisabled();
- });
+ return $this->notFilter(
+ fn (self $query) => $query->whereDisabled()
+ );
}
/**
* Adds a disabled filter to the current query.
- *
- * @return $this
*/
- public function whereDisabled()
+ public function whereDisabled(): static
{
return $this->rawFilter(
- (new AccountControl())->accountIsDisabled()->filter()
+ (new AccountControl)->setAccountIsDisabled()->filter()
);
}
/**
* Adds a 'where member' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function whereMember($dn, $nested = false)
+ public function whereMember(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->whereEquals($attribute, $dn);
- }, 'member', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->whereEquals($attribute, $this->substituteBaseDn($dn)),
+ 'member',
+ $nested
+ );
}
/**
* Adds an 'or where member' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function orWhereMember($dn, $nested = false)
+ public function orWhereMember(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->orWhereEquals($attribute, $dn);
- }, 'member', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->orWhereEquals($attribute, $this->substituteBaseDn($dn)),
+ 'member',
+ $nested
+ );
}
/**
* Adds a 'where member of' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function whereMemberOf($dn, $nested = false)
+ public function whereMemberOf(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->whereEquals($attribute, $dn);
- }, 'memberof', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->whereEquals($attribute, $this->substituteBaseDn($dn)),
+ 'memberof',
+ $nested
+ );
}
/**
* Adds a 'where not member of' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function whereNotMemberof($dn, $nested = false)
+ public function whereNotMemberof(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->whereNotEquals($attribute, $dn);
- }, 'memberof', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->whereNotEquals($attribute, $this->substituteBaseDn($dn)),
+ 'memberof',
+ $nested
+ );
}
/**
* Adds an 'or where member of' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function orWhereMemberOf($dn, $nested = false)
+ public function orWhereMemberOf(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->orWhereEquals($attribute, $dn);
- }, 'memberof', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->orWhereEquals($attribute, $this->substituteBaseDn($dn)),
+ 'memberof',
+ $nested
+ );
}
/**
* Adds a 'or where not member of' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function orWhereNotMemberof($dn, $nested = false)
+ public function orWhereNotMemberof(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->orWhereNotEquals($attribute, $dn);
- }, 'memberof', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->orWhereNotEquals($attribute, $this->substituteBaseDn($dn)),
+ 'memberof',
+ $nested
+ );
}
/**
* Adds a 'where manager' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function whereManager($dn, $nested = false)
+ public function whereManager(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->whereEquals($attribute, $dn);
- }, 'manager', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->whereEquals($attribute, $this->substituteBaseDn($dn)),
+ 'manager',
+ $nested
+ );
}
/**
* Adds a 'where not manager' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function whereNotManager($dn, $nested = false)
+ public function whereNotManager(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->whereNotEquals($attribute, $dn);
- }, 'manager', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->whereNotEquals($attribute, $this->substituteBaseDn($dn)),
+ 'manager',
+ $nested
+ );
}
/**
* Adds an 'or where manager' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function orWhereManager($dn, $nested = false)
+ public function orWhereManager(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->orWhereEquals($attribute, $dn);
- }, 'manager', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->orWhereEquals($attribute, $this->substituteBaseDn($dn)),
+ 'manager',
+ $nested
+ );
}
/**
* Adds an 'or where not manager' filter to the current query.
- *
- * @param string $dn
- * @param bool $nested
- *
- * @return $this
*/
- public function orWhereNotManager($dn, $nested = false)
+ public function orWhereNotManager(string $dn, bool $nested = false): static
{
- return $this->nestedMatchQuery(function ($attribute) use ($dn) {
- return $this->orWhereNotEquals($attribute, $dn);
- }, 'manager', $nested);
+ return $this->nestedMatchQuery(
+ fn (string $attribute) => $this->orWhereNotEquals($attribute, $this->substituteBaseDn($dn)),
+ 'manager',
+ $nested
+ );
}
/**
* Execute the callback with a nested match attribute.
- *
- * @param Closure $callback
- * @param string $attribute
- * @param bool $nested
- *
- * @return $this
*/
- protected function nestedMatchQuery(Closure $callback, $attribute, $nested = false)
+ protected function nestedMatchQuery(Closure $callback, string $attribute, bool $nested = false): static
{
return $callback(
$nested ? $this->makeNestedMatchAttribute($attribute) : $attribute
@@ -235,12 +186,8 @@
/**
* Make a "nested match" filter attribute for querying descendants.
- *
- * @param string $attribute
- *
- * @return string
*/
- protected function makeNestedMatchAttribute($attribute)
+ protected function makeNestedMatchAttribute(string $attribute): string
{
return sprintf('%s:%s:', $attribute, LdapInterface::OID_MATCHING_RULE_IN_CHAIN);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php
index 234dd0a..741646e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/Builder.php
@@ -4,52 +4,41 @@
use Closure;
use DateTime;
+use LdapRecord\Models\Attributes\Guid;
+use LdapRecord\Models\Collection;
use LdapRecord\Models\Model;
use LdapRecord\Models\ModelNotFoundException;
use LdapRecord\Models\Scope;
use LdapRecord\Models\Types\ActiveDirectory;
use LdapRecord\Query\Builder as BaseBuilder;
-use LdapRecord\Utilities;
+use UnexpectedValueException;
class Builder extends BaseBuilder
{
/**
* The model being queried.
- *
- * @var Model
*/
- protected $model;
+ protected Model $model;
/**
* The global scopes to be applied.
- *
- * @var array
*/
- protected $scopes = [];
+ protected array $scopes = [];
/**
* The removed global scopes.
- *
- * @var array
*/
- protected $removedScopes = [];
+ protected array $removedScopes = [];
/**
* The applied global scopes.
- *
- * @var array
*/
- protected $appliedScopes = [];
+ protected array $appliedScopes = [];
/**
* Dynamically handle calls into the query instance.
- *
- * @param string $method
- * @param array $parameters
- *
- * @return mixed
*/
- public function __call($method, $parameters)
+ public function __call(string $method, array $parameters): static
{
if (method_exists($this->model, $scope = 'scope'.ucfirst($method))) {
return $this->callScope([$this->model, $scope], $parameters);
@@ -60,13 +49,8 @@
/**
* Apply the given scope on the current builder instance.
- *
- * @param callable $scope
- * @param array $parameters
- *
- * @return mixed
*/
- protected function callScope(callable $scope, $parameters = [])
+ protected function callScope(callable $scope, array $parameters = []): static
{
array_unshift($parameters, $this);
@@ -75,10 +59,8 @@
/**
* Get the attributes to select on the search.
- *
- * @return array
*/
- public function getSelects()
+ public function getSelects(): array
{
// Here we will ensure the models GUID attribute is always
// selected. In some LDAP directories, the attribute is
@@ -90,12 +72,8 @@
/**
* Set the model instance for the model being queried.
- *
- * @param Model $model
- *
- * @return $this
*/
- public function setModel(Model $model)
+ public function setModel(Model $model): static
{
$this->model = $model;
@@ -103,51 +81,97 @@
}
/**
- * Returns the model being queried for.
- *
- * @return Model
+ * Get the model being queried for.
*/
- public function getModel()
+ public function getModel(): Model
{
return $this->model;
}
/**
* Get a new model query builder instance.
- *
- * @param string|null $baseDn
- *
- * @return static
*/
- public function newInstance($baseDn = null)
+ public function newInstance(?string $baseDn = null): BaseBuilder
{
return parent::newInstance($baseDn)->model($this->model);
}
/**
- * Finds a model by its distinguished name.
- *
- * @param array|string $dn
- * @param array|string|string[] $columns
- *
- * @return Model|\LdapRecord\Query\Collection|static|null
+ * {@inheritDoc}
*/
- public function find($dn, $columns = ['*'])
+ public function first(array|string $columns = ['*']): ?Model
{
- return $this->afterScopes(function () use ($dn, $columns) {
- return parent::find($dn, $columns);
- });
+ return parent::first($columns);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function firstOrFail(array|string $columns = ['*']): Model
+ {
+ return parent::firstOrFail($columns);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function sole(array|string $columns = ['*']): Model
+ {
+ return parent::sole($columns);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function find(array|string $dn, array|string $columns = ['*']): Model|Collection|null
+ {
+ return $this->afterScopes(fn () => parent::find($dn, $columns));
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function findOrFail(string $dn, array|string $columns = ['*']): Model
+ {
+ return parent::findOrFail($dn, $columns);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function findByOrFail(string $attribute, string $value, array|string $columns = ['*']): Model
+ {
+ return parent::findByOrFail($attribute, $value, $columns);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function findBy(string $attribute, string $value, array|string $columns = ['*']): ?Model
+ {
+ return parent::findBy($attribute, $value, $columns);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function findMany(array|string $dns, array|string $columns = ['*']): Collection
+ {
+ return parent::findMany($dns, $columns);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function findManyBy(string $attribute, array $values = [], array|string $columns = ['*']): Collection
+ {
+ return parent::findManyBy($attribute, $values, $columns);
}
/**
* Finds a record using ambiguous name resolution.
- *
- * @param string|array $value
- * @param array|string $columns
- *
- * @return Model|\LdapRecord\Query\Collection|static|null
*/
- public function findByAnr($value, $columns = ['*'])
+ public function findByAnr(array|string $value, array|string $columns = ['*']): Model|Collection|null
{
if (is_array($value)) {
return $this->findManyByAnr($value, $columns);
@@ -165,10 +189,8 @@
/**
* Determine if the current model is compatible with ANR filters.
- *
- * @return bool
*/
- protected function modelIsCompatibleWithAnr()
+ protected function modelIsCompatibleWithAnr(): bool
{
return $this->model instanceof ActiveDirectory;
}
@@ -178,14 +200,9 @@
*
* If a record is not found, an exception is thrown.
*
- * @param string $value
- * @param array|string $columns
- *
- * @return Model
- *
* @throws ModelNotFoundException
*/
- public function findByAnrOrFail($value, $columns = ['*'])
+ public function findByAnrOrFail(string $value, array|string $columns = ['*']): Model
{
if (! $entry = $this->findByAnr($value, $columns)) {
$this->throwNotFoundException($this->getUnescapedQuery(), $this->dn);
@@ -197,25 +214,17 @@
/**
* Throws a not found exception.
*
- * @param string $query
- * @param string $dn
- *
* @throws ModelNotFoundException
*/
- protected function throwNotFoundException($query, $dn)
+ protected function throwNotFoundException(string $query, ?string $dn = null): void
{
throw ModelNotFoundException::forQuery($query, $dn);
}
/**
* Finds multiple records using ambiguous name resolution.
- *
- * @param array $values
- * @param array $columns
- *
- * @return \LdapRecord\Query\Collection
*/
- public function findManyByAnr(array $values = [], $columns = ['*'])
+ public function findManyByAnr(array $values = [], array|string $columns = ['*']): Collection
{
$this->select($columns);
@@ -232,14 +241,10 @@
/**
* Creates an ANR equivalent query for LDAP distributions that do not support ANR.
- *
- * @param string $value
- *
- * @return $this
*/
- protected function prepareAnrEquivalentQuery($value)
+ protected function prepareAnrEquivalentQuery(string $value): static
{
- return $this->orFilter(function (self $query) use ($value) {
+ return $this->orFilter(function (BaseBuilder $query) use ($value) {
foreach ($this->model->getAnrAttributes() as $attribute) {
$query->whereEquals($attribute, $value);
}
@@ -248,37 +253,25 @@
/**
* Finds a record by its string GUID.
- *
- * @param string $guid
- * @param array|string $columns
- *
- * @return Model|static|null
*/
- public function findByGuid($guid, $columns = ['*'])
+ public function findByGuid(string $guid, array|string $columns = ['*']): ?Model
{
try {
return $this->findByGuidOrFail($guid, $columns);
} catch (ModelNotFoundException $e) {
- return;
+ return null;
}
}
/**
- * Finds a record by its string GUID.
- *
- * Fails upon no records returned.
- *
- * @param string $guid
- * @param array|string $columns
- *
- * @return Model|static
+ * Finds a record by its string GUID or throw an exception.
*
* @throws ModelNotFoundException
*/
- public function findByGuidOrFail($guid, $columns = ['*'])
+ public function findByGuidOrFail(string $guid, array|string $columns = ['*']): Model
{
if ($this->model instanceof ActiveDirectory) {
- $guid = Utilities::stringGuidToHex($guid);
+ $guid = (new Guid($guid))->getEncodedHex();
}
return $this->whereRaw([
@@ -287,23 +280,17 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getQuery()
+ public function getQuery(): string
{
- return $this->afterScopes(function () {
- return parent::getQuery();
- });
+ return $this->afterScopes(fn () => parent::getQuery());
}
/**
* Apply the query scopes and execute the callback.
- *
- * @param Closure $callback
- *
- * @return mixed
*/
- protected function afterScopes(Closure $callback)
+ protected function afterScopes(Closure $callback): mixed
{
$this->applyScopes();
@@ -312,10 +299,8 @@
/**
* Apply the global query scopes.
- *
- * @return $this
*/
- public function applyScopes()
+ public function applyScopes(): static
{
if (! $this->scopes) {
return $this;
@@ -338,13 +323,8 @@
/**
* Register a new global scope.
- *
- * @param string $identifier
- * @param Scope|\Closure $scope
- *
- * @return $this
*/
- public function withGlobalScope($identifier, $scope)
+ public function withGlobalScope(string $identifier, Scope|Closure $scope): static
{
$this->scopes[$identifier] = $scope;
@@ -353,12 +333,8 @@
/**
* Remove a registered global scope.
- *
- * @param Scope|string $scope
- *
- * @return $this
*/
- public function withoutGlobalScope($scope)
+ public function withoutGlobalScope(Scope|string $scope): static
{
if (! is_string($scope)) {
$scope = get_class($scope);
@@ -373,12 +349,8 @@
/**
* Remove all or passed registered global scopes.
- *
- * @param array|null $scopes
- *
- * @return $this
*/
- public function withoutGlobalScopes(array $scopes = null)
+ public function withoutGlobalScopes(?array $scopes = null): static
{
if (! is_array($scopes)) {
$scopes = array_keys($this->scopes);
@@ -393,52 +365,44 @@
/**
* Get an array of global scopes that were removed from the query.
- *
- * @return array
*/
- public function removedScopes()
+ public function removedScopes(): array
{
return $this->removedScopes;
}
/**
* Get an array of the global scopes that were applied to the query.
- *
- * @return array
*/
- public function appliedScopes()
+ public function appliedScopes(): array
{
return $this->appliedScopes;
}
/**
* Processes and converts the given LDAP results into models.
- *
- * @param array $results
- *
- * @return \LdapRecord\Query\Collection
*/
- protected function process(array $results)
+ protected function process(array $results): Collection
{
return $this->model->hydrate(parent::process($results));
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected function prepareWhereValue($field, $value, $raw = false)
+ protected function prepareWhereValue(string $field, mixed $value = null, $raw = false): string
{
if ($value instanceof DateTime) {
$field = $this->model->normalizeAttributeKey($field);
if (! $this->model->isDateAttribute($field)) {
- throw new \UnexpectedValueException(
+ throw new UnexpectedValueException(
"Cannot convert field [$field] to an LDAP timestamp. You must add this field as a model date."
- .' Refer to https://ldaprecord.com/docs/core/v2/model-mutators/#date-mutators'
+ .' Refer to https://ldaprecord.com/docs/core/v3/model-mutators/#date-mutators'
);
}
- $value = $this->model->fromDateTime($this->model->getDates()[$field], $value);
+ $value = $this->model->fromDateTime($value, $this->model->getDates()[$field]);
}
return parent::prepareWhereValue($field, $value, $raw);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/FreeIpaBuilder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/FreeIpaBuilder.php
index 5e3d43f..cac5ac3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/FreeIpaBuilder.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/FreeIpaBuilder.php
@@ -6,20 +6,16 @@
{
/**
* Adds a enabled filter to the current query.
- *
- * @return $this
*/
- public function whereEnabled()
+ public function whereEnabled(): static
{
return $this->rawFilter('(!(pwdAccountLockedTime=*))');
}
/**
* Adds a disabled filter to the current query.
- *
- * @return $this
*/
- public function whereDisabled()
+ public function whereDisabled(): static
{
return $this->rawFilter('(pwdAccountLockedTime=*)');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/OpenLdapBuilder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/OpenLdapBuilder.php
index dd41344..e0a8d5e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/OpenLdapBuilder.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Model/OpenLdapBuilder.php
@@ -6,20 +6,16 @@
{
/**
* Adds a enabled filter to the current query.
- *
- * @return $this
*/
- public function whereEnabled()
+ public function whereEnabled(): static
{
return $this->rawFilter('(!(pwdAccountLockedTime=*))');
}
/**
* Adds a disabled filter to the current query.
- *
- * @return $this
*/
- public function whereDisabled()
+ public function whereDisabled(): static
{
return $this->rawFilter('(pwdAccountLockedTime=*)');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/MultipleObjectsFoundException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/MultipleObjectsFoundException.php
index 0ece752..79ed1e3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/MultipleObjectsFoundException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/MultipleObjectsFoundException.php
@@ -4,6 +4,4 @@
use LdapRecord\LdapRecordException;
-class MultipleObjectsFoundException extends LdapRecordException
-{
-}
+class MultipleObjectsFoundException extends LdapRecordException {}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectNotFoundException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectNotFoundException.php
index c22563c..8fb22a2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectNotFoundException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectNotFoundException.php
@@ -8,40 +8,26 @@
{
/**
* The query filter that was used.
- *
- * @var string
*/
- protected $query;
+ protected string $query;
/**
* The base DN of the query that was used.
- *
- * @var string
*/
- protected $baseDn;
+ protected ?string $baseDn;
/**
* Create a new exception for the executed filter.
- *
- * @param string $query
- * @param ?string $baseDn
- *
- * @return static
*/
- public static function forQuery($query, $baseDn = null)
+ public static function forQuery(string $query, ?string $baseDn = null): static
{
- return (new static())->setQuery($query, $baseDn);
+ return (new static)->setQuery($query, $baseDn);
}
/**
* Set the query that was used.
- *
- * @param string $query
- * @param string|null $baseDn
- *
- * @return $this
*/
- public function setQuery($query, $baseDn = null)
+ public function setQuery(string $query, ?string $baseDn = null): static
{
$this->query = $query;
$this->baseDn = $baseDn;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectsNotFoundException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectsNotFoundException.php
index a984600..85edb7f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectsNotFoundException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/ObjectsNotFoundException.php
@@ -4,6 +4,4 @@
use LdapRecord\LdapRecordException;
-class ObjectsNotFoundException extends LdapRecordException
-{
-}
+class ObjectsNotFoundException extends LdapRecordException {}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/AbstractPaginator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/AbstractPaginator.php
index e2b0482..c556773 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/AbstractPaginator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/AbstractPaginator.php
@@ -9,38 +9,28 @@
{
/**
* The query builder instance.
- *
- * @var Builder
*/
- protected $query;
+ protected Builder $query;
/**
* The filter to execute.
- *
- * @var string
*/
- protected $filter;
+ protected string $filter;
/**
* The amount of objects to fetch per page.
- *
- * @var int
*/
- protected $perPage;
+ protected int $perPage;
/**
* Whether the operation is critical.
- *
- * @var bool
*/
- protected $isCritical;
+ protected bool $isCritical;
/**
* Constructor.
- *
- * @param Builder $query
*/
- public function __construct(Builder $query, $filter, $perPage, $isCritical)
+ public function __construct(Builder $query, string $filter, int $perPage, bool $isCritical = false)
{
$this->query = $query;
$this->filter = $filter;
@@ -50,12 +40,8 @@
/**
* Execute the pagination request.
- *
- * @param LdapInterface $ldap
- *
- * @return array
*/
- public function execute(LdapInterface $ldap)
+ public function execute(LdapInterface $ldap): mixed
{
$pages = [];
@@ -79,56 +65,37 @@
}
/**
- * Whether the paginater should continue iterating.
- *
- * @return bool
+ * Whether the paginator should continue iterating.
*/
- protected function shouldContinue()
+ protected function shouldContinue(): bool
{
- $cookie = (string) $this->fetchCookie();
+ $cookie = $this->fetchCookie();
return $cookie !== '';
}
/**
* Fetch the pagination cookie.
- *
- * @return string
*/
- abstract protected function fetchCookie();
+ abstract protected function fetchCookie(): ?string;
/**
* Prepare the server controls before executing the pagination request.
- *
- * @return void
*/
- abstract protected function prepareServerControls();
+ abstract protected function prepareServerControls(): void;
/**
* Apply the server controls.
- *
- * @param LdapInterface $ldap
- *
- * @return void
*/
- abstract protected function applyServerControls(LdapInterface $ldap);
+ abstract protected function applyServerControls(LdapInterface $ldap): void;
/**
* Reset the server controls.
- *
- * @param LdapInterface $ldap
- *
- * @return void
*/
- abstract protected function resetServerControls(LdapInterface $ldap);
+ abstract protected function resetServerControls(LdapInterface $ldap): void;
/**
* Update the server controls.
- *
- * @param LdapInterface $ldap
- * @param resource $resource
- *
- * @return void
*/
- abstract protected function updateServerControls(LdapInterface $ldap, $resource);
+ abstract protected function updateServerControls(LdapInterface $ldap, mixed $resource): void;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/DeprecatedPaginator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/DeprecatedPaginator.php
deleted file mode 100644
index b4a7f8d..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/DeprecatedPaginator.php
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-
-namespace LdapRecord\Query\Pagination;
-
-use LdapRecord\LdapInterface;
-
-/**
- * @deprecated since v2.5.0
- */
-class DeprecatedPaginator extends AbstractPaginator
-{
- /**
- * The pagination cookie.
- *
- * @var string
- */
- protected $cookie = '';
-
- /**
- * @inheritdoc
- */
- protected function fetchCookie()
- {
- return $this->cookie;
- }
-
- /**
- * @inheritdoc
- */
- protected function prepareServerControls()
- {
- $this->cookie = '';
- }
-
- /**
- * @inheritdoc
- */
- protected function applyServerControls(LdapInterface $ldap)
- {
- $ldap->controlPagedResult($this->perPage, $this->isCritical, $this->cookie);
- }
-
- /**
- * @inheritdoc
- */
- protected function updateServerControls(LdapInterface $ldap, $resource)
- {
- $ldap->controlPagedResultResponse($resource, $this->cookie);
- }
-
- /**
- * @inheritdoc
- */
- protected function resetServerControls(LdapInterface $ldap)
- {
- $ldap->controlPagedResult();
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php
index b9df77e..d770259 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/LazyPaginator.php
@@ -2,18 +2,15 @@
namespace LdapRecord\Query\Pagination;
+use Generator;
use LdapRecord\LdapInterface;
class LazyPaginator extends Paginator
{
/**
* Execute the pagination request.
- *
- * @param LdapInterface $ldap
- *
- * @return \Generator
*/
- public function execute(LdapInterface $ldap)
+ public function execute(LdapInterface $ldap): Generator
{
$this->prepareServerControls();
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php
index c0a31af..50671a7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Pagination/Paginator.php
@@ -7,17 +7,17 @@
class Paginator extends AbstractPaginator
{
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected function fetchCookie()
+ protected function fetchCookie(): ?string
{
return $this->query->controls[LDAP_CONTROL_PAGEDRESULTS]['value']['cookie'] ?? null;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected function prepareServerControls()
+ protected function prepareServerControls(): void
{
$this->query->addControl(LDAP_CONTROL_PAGEDRESULTS, $this->isCritical, [
'size' => $this->perPage, 'cookie' => '',
@@ -25,31 +25,27 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected function applyServerControls(LdapInterface $ldap)
+ protected function applyServerControls(LdapInterface $ldap): void
{
$ldap->setOption(LDAP_OPT_SERVER_CONTROLS, $this->query->controls);
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected function updateServerControls(LdapInterface $ldap, $resource)
+ protected function updateServerControls(LdapInterface $ldap, mixed $resource): void
{
- $errorCode = 0;
- $dn = $errorMessage = $refs = null;
$controls = $this->query->controls;
- $ldap->parseResult(
- $resource,
- $errorCode,
- $dn,
- $errorMessage,
- $refs,
- $controls
+ $response = $ldap->parseResult(
+ result: $resource,
+ controls: $controls
);
+ $controls = array_merge($controls, $response->controls ?? []);
+
$cookie = $controls[LDAP_CONTROL_PAGEDRESULTS]['value']['cookie'] ?? '';
$this->query->controls[LDAP_CONTROL_PAGEDRESULTS]['value'] = [
@@ -59,9 +55,9 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- protected function resetServerControls(LdapInterface $ldap)
+ protected function resetServerControls(LdapInterface $ldap): void
{
unset($this->query->controls[LDAP_CONTROL_PAGEDRESULTS]);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Slice.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Slice.php
new file mode 100644
index 0000000..2921724
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Query/Slice.php
@@ -0,0 +1,223 @@
+<?php
+
+namespace LdapRecord\Query;
+
+use ArrayAccess;
+use ArrayIterator;
+use IteratorAggregate;
+use JsonSerializable;
+
+class Slice implements ArrayAccess, IteratorAggregate, JsonSerializable
+{
+ /**
+ * All the items in the slice.
+ */
+ protected Collection|array $items;
+
+ /**
+ * The number of items to be shown per page.
+ */
+ protected int $perPage;
+
+ /**
+ * The total number of items before slicing.
+ */
+ protected int $total;
+
+ /**
+ * The last available page.
+ */
+ protected int $lastPage;
+
+ /**
+ * The current page being "viewed".
+ */
+ protected int $currentPage;
+
+ /**
+ * Constructor.
+ */
+ public function __construct(Collection|array $items, int $total, int $perPage, ?int $currentPage = null)
+ {
+ $this->items = $items;
+ $this->total = $total;
+ $this->perPage = $perPage;
+ $this->lastPage = max((int) ceil($total / $perPage), 1);
+ $this->currentPage = $currentPage ?? 1;
+ }
+
+ /**
+ * Get the slice of items being paginated.
+ */
+ public function items(): Collection|array
+ {
+ return $this->items;
+ }
+
+ /**
+ * Get the total number of items being paginated.
+ */
+ public function total(): int
+ {
+ return $this->total;
+ }
+
+ /**
+ * Get the number of items shown per page.
+ */
+ public function perPage(): int
+ {
+ return $this->perPage;
+ }
+
+ /**
+ * Determine if there are more items in the data source.
+ */
+ public function hasMorePages(): bool
+ {
+ return $this->currentPage() < $this->lastPage();
+ }
+
+ /**
+ * Determine if there are enough items to split into multiple pages.
+ */
+ public function hasPages(): bool
+ {
+ return $this->currentPage() != 1 || $this->hasMorePages();
+ }
+
+ /**
+ * Determine if the paginator is on the first page.
+ */
+ public function onFirstPage(): bool
+ {
+ return $this->currentPage() <= 1;
+ }
+
+ /**
+ * Determine if the paginator is on the last page.
+ */
+ public function onLastPage(): bool
+ {
+ return ! $this->hasMorePages();
+ }
+
+ /**
+ * Get the current page.
+ */
+ public function currentPage(): int
+ {
+ return $this->currentPage;
+ }
+
+ /**
+ * Get the last page.
+ */
+ public function lastPage(): int
+ {
+ return $this->lastPage;
+ }
+
+ /**
+ * Get an iterator for the items.
+ */
+ #[\ReturnTypeWillChange]
+ public function getIterator(): ArrayIterator
+ {
+ return new ArrayIterator($this->items);
+ }
+
+ /**
+ * Determine if the list of items is empty.
+ */
+ public function isEmpty(): bool
+ {
+ return empty($this->items);
+ }
+
+ /**
+ * Determine if the list of items is not empty.
+ */
+ public function isNotEmpty(): bool
+ {
+ return ! $this->isEmpty();
+ }
+
+ /**
+ * Get the number of items for the current page.
+ */
+ #[\ReturnTypeWillChange]
+ public function count(): int
+ {
+ return count($this->items);
+ }
+
+ /**
+ * Determine if the given item exists.
+ */
+ #[\ReturnTypeWillChange]
+ public function offsetExists(mixed $offset): bool
+ {
+ return array_key_exists($offset, $this->items);
+ }
+
+ /**
+ * Get the item at the given offset.
+ */
+ #[\ReturnTypeWillChange]
+ public function offsetGet(mixed $offset): mixed
+ {
+ return $this->items[$offset] ?? null;
+ }
+
+ /**
+ * Set the item at the given offset.
+ */
+ #[\ReturnTypeWillChange]
+ public function offsetSet(mixed $offset, mixed $value): void
+ {
+ $this->items[$offset] = $value;
+ }
+
+ /**
+ * Unset the item at the given key.
+ */
+ #[\ReturnTypeWillChange]
+ public function offsetUnset(mixed $offset): void
+ {
+ unset($this->items[$offset]);
+ }
+
+ /**
+ * Convert the object into something JSON serializable.
+ */
+ #[\ReturnTypeWillChange]
+ public function jsonSerialize(): array
+ {
+ return $this->toArray();
+ }
+
+ /**
+ * Get the arrayable items.
+ */
+ public function getArrayableItems(): array
+ {
+ return $this->items instanceof Collection
+ ? $this->items->all()
+ : $this->items;
+ }
+
+ /**
+ * Get the instance as an array.
+ */
+ public function toArray(): array
+ {
+ return [
+ 'current_page' => $this->currentPage(),
+ 'data' => $this->getArrayableItems(),
+ 'last_page' => $this->lastPage(),
+ 'per_page' => $this->perPage(),
+ 'total' => $this->total(),
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Arr.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Arr.php
index 8fa87a2..6c3217a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Arr.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Arr.php
@@ -8,25 +8,16 @@
{
/**
* Determine whether the given value is array accessible.
- *
- * @param mixed $value
- *
- * @return bool
*/
- public static function accessible($value)
+ public static function accessible(mixed $value): bool
{
return is_array($value) || $value instanceof ArrayAccess;
}
/**
* Determine if the given key exists in the provided array.
- *
- * @param \ArrayAccess|array $array
- * @param string|int $key
- *
- * @return bool
*/
- public static function exists($array, $key)
+ public static function exists(ArrayAccess|array $array, string|int $key): bool
{
if ($array instanceof ArrayAccess) {
return $array->offsetExists($key);
@@ -37,12 +28,8 @@
/**
* If the given value is not an array and not null, wrap it in one.
- *
- * @param mixed $value
- *
- * @return array
*/
- public static function wrap($value)
+ public static function wrap(mixed $value): array
{
if (is_null($value)) {
return [];
@@ -52,15 +39,9 @@
}
/**
- * Return the first element in an array passing a given truth test.
- *
- * @param iterable $array
- * @param callable|null $callback
- * @param mixed $default
- *
- * @return mixed
+ * Get the first element in an array passing a given truth test.
*/
- public static function first($array, callable $callback = null, $default = null)
+ public static function first(iterable $array, ?callable $callback = null, mixed $default = null): mixed
{
if (is_null($callback)) {
if (empty($array)) {
@@ -82,15 +63,11 @@
}
/**
- * Return the last element in an array passing a given truth test.
+ * Get the last element in an array passing a given truth test.
*
- * @param array $array
- * @param callable|null $callback
- * @param mixed $default
- *
- * @return mixed
+ * @param array $array
*/
- public static function last($array, callable $callback = null, $default = null)
+ public static function last(iterable $array, ?callable $callback = null, mixed $default = null): mixed
{
if (is_null($callback)) {
return empty($array) ? Helpers::value($default) : end($array);
@@ -101,14 +78,8 @@
/**
* Get an item from an array using "dot" notation.
- *
- * @param ArrayAccess|array $array
- * @param string|int|null $key
- * @param mixed $default
- *
- * @return mixed
*/
- public static function get($array, $key, $default = null)
+ public static function get(ArrayAccess|array $array, string|int|null $key, mixed $default = null): mixed
{
if (! static::accessible($array)) {
return Helpers::value($default);
@@ -122,7 +93,7 @@
return $array[$key];
}
- if (strpos($key, '.') === false) {
+ if (str_contains($key, '.')) {
return $array[$key] ?? Helpers::value($default);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Helpers.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Helpers.php
index a55d1d2..5b4bd46 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Helpers.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Helpers.php
@@ -7,14 +7,10 @@
class Helpers
{
/**
- * Return the default value of the given value.
- *
- * @param mixed $value
- *
- * @return mixed
+ * Get the default value of the given value.
*/
- public static function value($value)
+ public static function value(mixed $value, mixed ...$args): mixed
{
- return $value instanceof Closure ? $value() : $value;
+ return $value instanceof Closure ? $value(...$args) : $value;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Str.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Str.php
new file mode 100644
index 0000000..ced2a5f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Support/Str.php
@@ -0,0 +1,134 @@
+<?php
+
+namespace LdapRecord\Support;
+
+class Str
+{
+ /**
+ * Determine if a given string matches a given pattern.
+ */
+ public static function is(string|iterable $pattern, string $value): bool
+ {
+ if (! is_iterable($pattern)) {
+ $pattern = [$pattern];
+ }
+
+ foreach ($pattern as $pattern) {
+ $pattern = (string) $pattern;
+
+ // If the given value is an exact match we can of course return true right
+ // from the beginning. Otherwise, we will translate asterisks and do an
+ // actual pattern match against the two strings to see if they match.
+ if ($pattern === $value) {
+ return true;
+ }
+
+ $pattern = preg_quote($pattern, '#');
+
+ // Asterisks are translated into zero-or-more regular expression wildcards
+ // to make it convenient to check if the strings starts with the given
+ // pattern such as "library/*", making any string check convenient.
+ $pattern = str_replace('\*', '.*', $pattern);
+
+ if (preg_match('#^'.$pattern.'\z#u', $value) === 1) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Get the remainder of a string after the last occurrence of a given value.
+ */
+ public static function afterLast(string $subject, string $search): string
+ {
+ if ($search === '') {
+ return $subject;
+ }
+
+ $position = strrpos($subject, $search);
+
+ if ($position === false) {
+ return $subject;
+ }
+
+ return substr($subject, $position + strlen($search));
+ }
+
+ /**
+ * Determine if a given string starts with a given substring.
+ */
+ public static function startsWith(string $haystack, array|string $needles): bool
+ {
+ foreach ((array) $needles as $needle) {
+ if ((string) $needle !== '' && str_starts_with($haystack, $needle)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Determine if a given string ends with a given substring.
+ */
+ public static function endsWith(string $haystack, array|string $needles): bool
+ {
+ foreach ((array) $needles as $needle) {
+ if (
+ $needle !== '' && $needle !== null
+ && str_ends_with($haystack, $needle)
+ ) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Execute a callback when a needle is found in the haystack.
+ */
+ public static function whenContains(string $haystack, array|string $needles, mixed $callback, mixed $default = null): mixed
+ {
+ foreach ((array) $needles as $needle) {
+ if (static::contains($haystack, $needle)) {
+ return Helpers::value($callback, $needle, $haystack);
+ }
+ }
+
+ return Helpers::value($default, $haystack);
+ }
+
+ /**
+ * Determine if a given string contains a given substring.
+ */
+ public static function contains(string $haystack, array|string $needles, bool $ignoreCase = false): bool
+ {
+ if ($ignoreCase) {
+ $haystack = mb_strtolower($haystack);
+ $needles = array_map('mb_strtolower', (array) $needles);
+ }
+
+ foreach ((array) $needles as $needle) {
+ if ($needle !== '' && str_contains((string) $haystack, $needle)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Get the number of substring occurrences.
+ */
+ public static function substrCount(string $haystack, string $needle, int $offset = 0, ?int $length = null): int
+ {
+ if (! is_null($length)) {
+ return substr_count($haystack, $needle, $offset, $length);
+ } else {
+ return substr_count($haystack, $needle, $offset);
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/AuthGuardFake.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/AuthGuardFake.php
index 4a69150..36574c0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/AuthGuardFake.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/AuthGuardFake.php
@@ -8,11 +8,6 @@
{
/**
* Always allow binding as configured user.
- *
- * @return bool
*/
- public function bindAsConfiguredUser()
- {
- return true;
- }
+ public function bindAsConfiguredUser(): void {}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/ConnectionFake.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/ConnectionFake.php
index 0aa12a1..2c76a06 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/ConnectionFake.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/ConnectionFake.php
@@ -4,6 +4,7 @@
use LdapRecord\Auth\Guard;
use LdapRecord\Connection;
+use LdapRecord\LdapInterface;
use LdapRecord\Models\Model;
class ConnectionFake extends Connection
@@ -13,26 +14,19 @@
*
* @var LdapFake
*/
- protected $ldap;
+ protected LdapInterface $ldap;
/**
* Whether the fake is connected.
- *
- * @var bool
*/
- protected $connected = false;
+ protected bool $connected = false;
/**
* Make a new fake LDAP connection instance.
- *
- * @param array $config
- * @param string $ldap
- *
- * @return static
*/
- public static function make(array $config = [], $ldap = LdapFake::class)
+ public static function make(array $config = [], string $ldap = LdapFake::class): static
{
- $connection = new static($config, new $ldap());
+ $connection = new static($config, new $ldap);
$connection->configure();
@@ -41,14 +35,10 @@
/**
* Set the user to authenticate as.
- *
- * @param Model|string $user
- *
- * @return $this
*/
- public function actingAs($user)
+ public function actingAs(Model|string $user): static
{
- $this->ldap->shouldAuthenticateWith(
+ $this->ldap->shouldAllowBindWith(
$user instanceof Model ? $user->getDn() : $user
);
@@ -57,10 +47,8 @@
/**
* Set the connection to bypass bind attempts as the configured user.
- *
- * @return $this
*/
- public function shouldBeConnected()
+ public function shouldBeConnected(): static
{
$this->connected = true;
@@ -73,10 +61,8 @@
/**
* Set the connection to attempt binding as the configured user.
- *
- * @return $this
*/
- public function shouldNotBeConnected()
+ public function shouldNotBeConnected(): static
{
$this->connected = false;
@@ -88,10 +74,20 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function isConnected()
+ public function isConnected(): bool
{
return $this->connected ?: parent::isConnected();
}
+
+ /**
+ * Perform tear down tasks on the fake.
+ *
+ * @throws LdapExpectationException
+ */
+ public function tearDown(): void
+ {
+ $this->ldap->assertMinimumExpectationCounts();
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php
index 9d50dcd..90cbf7a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/DirectoryFake.php
@@ -7,46 +7,50 @@
class DirectoryFake
{
/**
- * Setup the fake connection.
+ * The LDAP connections that were replaced with fakes.
*
- * @param string|null $name
- *
- * @return ConnectionFake
+ * @var \LdapRecord\Connection[]
+ */
+ protected static array $replaced = [];
+
+ /**
+ * Replace a connection a fake.
*
* @throws \LdapRecord\ContainerException
*/
- public static function setup($name = null)
+ public static function setup(?string $name = null): ConnectionFake
{
- $connection = Container::getConnection($name);
+ $name = $name ?? Container::getDefaultConnectionName();
+
+ $connection = static::$replaced[$name] = Container::getConnection($name);
$fake = static::makeConnectionFake(
$connection->getConfiguration()->all()
);
- // Replace the connection with a fake.
Container::addConnection($fake, $name);
return $fake;
}
/**
- * Reset the container.
- *
- * @return void
+ * Replace all faked connections with their original.
*/
- public static function tearDown()
+ public static function tearDown(): void
{
- Container::reset();
+ foreach (static::$replaced as $name => $connection) {
+ Container::getConnection($name)->tearDown();
+ }
+
+ Container::flush();
+
+ static::$replaced = [];
}
/**
* Make a connection fake.
- *
- * @param array $config
- *
- * @return ConnectionFake
*/
- public static function makeConnectionFake(array $config = [])
+ public static function makeConnectionFake(array $config = []): ConnectionFake
{
return ConnectionFake::make($config)->shouldBeConnected();
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapExpectation.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapExpectation.php
index 90a5fa2..2e010d7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapExpectation.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapExpectation.php
@@ -2,7 +2,11 @@
namespace LdapRecord\Testing;
+use Closure;
+use Exception;
use LdapRecord\LdapRecordException;
+use LdapRecord\LdapResultResponse;
+use PHPUnit\Framework\Constraint\Callback;
use PHPUnit\Framework\Constraint\Constraint;
use PHPUnit\Framework\Constraint\IsEqual;
use UnexpectedValueException;
@@ -11,114 +15,96 @@
{
/**
* The value to return from the expectation.
- *
- * @var mixed
*/
- protected $value;
+ protected mixed $value = null;
/**
* The exception to throw from the expectation.
- *
- * @var null|LdapRecordException|\Exception
*/
- protected $exception;
+ protected ?Exception $exception = null;
/**
- * The amount of times the expectation should be called.
- *
- * @var int
+ * The tracked number of times the expectation should be called.
*/
- protected $count = 1;
+ protected int $count = 1;
+
+ /**
+ * The original number of times the expectation should be called.
+ */
+ protected int $originalCount = 1;
+
+ /**
+ * The actual number of times the expectation was called.
+ */
+ protected int $called = 0;
/**
* The method that the expectation belongs to.
- *
- * @var string
*/
- protected $method;
+ protected ?string $method = null;
/**
* The methods argument's.
- *
- * @var array
*/
- protected $args = [];
+ protected array $args = [];
/**
* Whether the same expectation should be returned indefinitely.
- *
- * @var bool
*/
- protected $indefinitely = true;
+ protected bool $indefinitely = true;
/**
- * Whether the expectation should return errors.
- *
- * @var bool
+ * Whether the expectation should return an error.
*/
- protected $errors = false;
+ protected bool $errors = false;
/**
- * The error number to return.
- *
- * @var int
+ * The error code to return.
*/
- protected $errorCode = 1;
+ protected int $errorCode = 1;
/**
- * The last error string to return.
- *
- * @var string
+ * The error message to return.
*/
- protected $errorMessage = '';
+ protected string $errorMessage = 'Unknown error';
/**
* The diagnostic message string to return.
- *
- * @var string
*/
- protected $errorDiagnosticMessage = '';
+ protected ?string $errorDiagnosticMessage = null;
/**
* Constructor.
- *
- * @param string $method
*/
- public function __construct($method)
+ public function __construct(string $method)
{
$this->method = $method;
}
/**
* Set the arguments that the operation should receive.
- *
- * @param mixed $args
- *
- * @return $this
*/
- public function with($args)
+ public function with(mixed $args): static
{
- $args = is_array($args) ? $args : func_get_args();
-
- foreach ($args as $key => $arg) {
- if (! $arg instanceof Constraint) {
- $args[$key] = new IsEqual($arg);
+ $this->args = array_map(function ($arg) {
+ if ($arg instanceof Closure) {
+ return new Callback($arg);
}
- }
- $this->args = $args;
+ if (! $arg instanceof Constraint) {
+ return new IsEqual($arg);
+ }
+
+ return $arg;
+ }, is_array($args) ? $args : func_get_args());
return $this;
}
/**
* Set the expected value to return.
- *
- * @param mixed $value
- *
- * @return $this
*/
- public function andReturn($value)
+ public function andReturn(mixed $value): static
{
$this->value = $value;
@@ -126,33 +112,62 @@
}
/**
- * The error message to return from the expectation.
- *
- * @param int $code
- * @param string $error
- * @param string $diagnosticMessage
- *
- * @return $this
+ * Set the expected value to return true.
*/
- public function andReturnError($code = 1, $error = '', $diagnosticMessage = '')
+ public function andReturnTrue(): static
+ {
+ return $this->andReturn(true);
+ }
+
+ /**
+ * Set the expected value to return false.
+ */
+ public function andReturnFalse(): static
+ {
+ return $this->andReturn(false);
+ }
+
+ /**
+ * The error message to return from the expectation.
+ */
+ public function andReturnError(int $errorCode = 1, string $errorMessage = 'Unknown error', ?string $diagnosticMessage = null): static
{
$this->errors = true;
- $this->errorCode = $code;
- $this->errorMessage = $error;
+ $this->errorCode = $errorCode;
+ $this->errorMessage = $errorMessage;
$this->errorDiagnosticMessage = $diagnosticMessage;
return $this;
}
/**
- * Set the expected exception to throw.
- *
- * @param string|\Exception|LdapRecordException $exception
- *
- * @return $this
+ * Return an error LDAP result response.
*/
- public function andThrow($exception)
+ public function andReturnErrorResponse(int $code = 1, ?string $errorMessage = null): static
+ {
+ return $this->andReturnResponse($code, $errorMessage);
+ }
+
+ /**
+ * Return an LDAP result response.
+ */
+ public function andReturnResponse(
+ int $errorCode = 0,
+ ?string $matchedDn = null,
+ ?string $errorMessage = null,
+ array $referrals = [],
+ array $controls = []
+ ): static {
+ return $this->andReturn(
+ new LdapResultResponse($errorCode, $matchedDn, $errorMessage, $referrals, $controls)
+ );
+ }
+
+ /**
+ * Set the expected exception to throw.
+ */
+ public function andThrow(string|Exception $exception): static
{
if (is_string($exception)) {
$exception = new LdapRecordException($exception);
@@ -165,46 +180,36 @@
/**
* Set the expectation to be only called once.
- *
- * @return $this
*/
- public function once()
+ public function once(): static
{
- return $this->times(1);
+ return $this->times();
}
/**
* Set the expectation to be only called twice.
- *
- * @return $this
*/
- public function twice()
+ public function twice(): static
{
return $this->times(2);
}
/**
* Set the expectation to be called the given number of times.
- *
- * @param int $count
- *
- * @return $this
*/
- public function times($count = 1)
+ public function times(int $count = 1): static
{
$this->indefinitely = false;
- $this->count = $count;
+ $this->originalCount = $this->count = $count;
return $this;
}
/**
* Get the method the expectation belongs to.
- *
- * @return string
*/
- public function getMethod()
+ public function getMethod(): string
{
if (is_null($this->method)) {
throw new UnexpectedValueException('An expectation must have a method.');
@@ -215,89 +220,105 @@
/**
* Get the expected call count.
- *
- * @return int
*/
- public function getExpectedCount()
+ public function getExpectedCount(): int
{
return $this->count;
}
/**
+ * Get the original expected call count.
+ */
+ public function getOriginalExpectedCount(): int
+ {
+ return $this->originalCount;
+ }
+
+ /**
+ * Get the count that the expectation was called.
+ */
+ public function getCalledCount(): int
+ {
+ return $this->called;
+ }
+
+ /**
* Get the expected arguments.
*
* @return Constraint[]
*/
- public function getExpectedArgs()
+ public function getExpectedArgs(): array
{
return $this->args;
}
/**
* Get the expected exception.
- *
- * @return null|\Exception|LdapRecordException
*/
- public function getExpectedException()
+ public function getExpectedException(): ?Exception
{
return $this->exception;
}
/**
* Get the expected value.
- *
- * @return mixed
*/
- public function getExpectedValue()
+ public function getExpectedValue(): mixed
{
return $this->value;
}
/**
- * Determine whether the expectation is returning an error.
- *
- * @return bool
+ * Determine whether the expectation can be called indefinitely.
*/
- public function isReturningError()
+ public function isIndefinite(): bool
+ {
+ return $this->indefinitely;
+ }
+
+ /**
+ * Determine whether the expectation is returning an error.
+ */
+ public function isReturningError(): bool
{
return $this->errors;
}
/**
- * @return int
+ * Get the expected error code.
*/
- public function getExpectedErrorCode()
+ public function getExpectedErrorCode(): int
{
return $this->errorCode;
}
/**
- * @return string
+ * Get the expected error message.
*/
- public function getExpectedErrorMessage()
+ public function getExpectedErrorMessage(): ?string
{
return $this->errorMessage;
}
/**
- * @return string
+ * Get the expected diagnostic message.
*/
- public function getExpectedErrorDiagnosticMessage()
+ public function getExpectedErrorDiagnosticMessage(): ?string
{
return $this->errorDiagnosticMessage;
}
/**
- * Decrement the call count of the expectation.
- *
- * @return $this
+ * Decrement the expected count of the expectation.
*/
- public function decrementCallCount()
+ public function decrementExpectedCount(): static
{
if (! $this->indefinitely) {
$this->count -= 1;
}
+ $this->called++;
+
return $this;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapExpectationException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapExpectationException.php
new file mode 100644
index 0000000..74a3ebe
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapExpectationException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace LdapRecord\Testing;
+
+use Exception;
+
+class LdapExpectationException extends Exception {}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php
index 00470e1..ec1b332 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Testing/LdapFake.php
@@ -3,81 +3,62 @@
namespace LdapRecord\Testing;
use Closure;
-use Exception;
use LdapRecord\DetailedError;
use LdapRecord\DetectsErrors;
use LdapRecord\HandlesConnection;
use LdapRecord\LdapInterface;
+use LdapRecord\LdapResultResponse;
use LdapRecord\Support\Arr;
use PHPUnit\Framework\Assert as PHPUnit;
use PHPUnit\Framework\Constraint\Constraint;
class LdapFake implements LdapInterface
{
- use HandlesConnection, DetectsErrors;
+ use DetectsErrors;
+ use HandlesConnection;
/**
* The expectations of the LDAP fake.
*
- * @var array
+ * @var array<string,LdapExpectation[]>
*/
- protected $expectations = [];
+ protected array $expectations = [];
/**
* The default fake error number.
- *
- * @var int
*/
- protected $errNo = 1;
+ protected int $errNo = 1;
/**
* The default fake last error string.
- *
- * @var string
*/
- protected $lastError = '';
+ protected string $lastError = 'Unknown error';
/**
* The default fake diagnostic message string.
- *
- * @var string
*/
- protected $diagnosticMessage = '';
+ protected ?string $diagnosticMessage = null;
/**
* Create a new expected operation.
- *
- * @param string $method
- *
- * @return LdapExpectation
*/
- public static function operation($method)
+ public static function operation(string $method): LdapExpectation
{
return new LdapExpectation($method);
}
/**
- * Set the user that will pass binding.
- *
- * @param string $dn
- *
- * @return $this
+ * Set the fake LDAP host.
*/
- public function shouldAuthenticateWith($dn)
+ public function setHost(string $host): void
{
- return $this->expect(
- static::operation('bind')->with($dn, PHPUnit::anything())->andReturn(true)
- );
+ $this->host = $host;
}
/**
* Add an LDAP method expectation.
- *
- * @param LdapExpectation|array $expectations
- *
- * @return $this
*/
- public function expect($expectations = [])
+ public function expect(LdapExpectation|array $expectations = []): static
{
$expectations = Arr::wrap($expectations);
@@ -104,12 +85,8 @@
/**
* Determine if the method has any expectations.
- *
- * @param string $method
- *
- * @return bool
*/
- public function hasExpectations($method)
+ public function hasExpectations(string $method): bool
{
return count($this->getExpectations($method)) > 0;
}
@@ -117,36 +94,55 @@
/**
* Get expectations by method.
*
- * @param string $method
- *
- * @return LdapExpectation[]|mixed
+ * @return LdapExpectation[]
*/
- public function getExpectations($method)
+ public function getExpectations(string $method): array
{
return $this->expectations[$method] ?? [];
}
/**
* Remove an expectation by method and key.
- *
- * @param string $method
- * @param int $key
- *
- * @return void
*/
- public function removeExpectation($method, $key)
+ public function removeExpectation(string $method, int $key): void
{
unset($this->expectations[$method][$key]);
}
/**
- * Set the error number of a failed bind attempt.
- *
- * @param int $number
- *
- * @return $this
+ * Set the fake to allow any bind attempt.
*/
- public function shouldReturnErrorNumber($number = 1)
+ public function shouldAllowAnyBind(): static
+ {
+ return $this->expect(
+ static::operation('bind')->andReturnResponse()
+ );
+ }
+
+ /**
+ * Set the fake to allow any bind attempt with the given DN.
+ */
+ public function shouldAllowBindWith(string $dn): static
+ {
+ return $this->expect(
+ static::operation('bind')->with($dn, PHPUnit::anything())->andReturnResponse()
+ );
+ }
+
+ /**
+ * Set the user that will pass binding.
+ *
+ * @deprecated Use shouldAllowBindWith instead.
+ */
+ public function shouldAuthenticateWith(string $dn): static
+ {
+ return $this->shouldAllowBindWith($dn);
+ }
+
+ /**
+ * Set the error number of a failed bind attempt.
+ */
+ public function shouldReturnErrorNumber(int $number = 1): static
{
$this->errNo = $number;
@@ -155,12 +151,8 @@
/**
* Set the last error of a failed bind attempt.
- *
- * @param string $message
- *
- * @return $this
*/
- public function shouldReturnError($message = '')
+ public function shouldReturnError(string $message): static
{
$this->lastError = $message;
@@ -169,12 +161,8 @@
/**
* Set the diagnostic message of a failed bind attempt.
- *
- * @param string $message
- *
- * @return $this
*/
- public function shouldReturnDiagnosticMessage($message = '')
+ public function shouldReturnDiagnosticMessage(?string $message): static
{
$this->diagnosticMessage = $message;
@@ -183,38 +171,32 @@
/**
* Return a fake error number.
- *
- * @return int
*/
- public function errNo()
+ public function errNo(): int
{
return $this->errNo;
}
/**
* Return a fake error.
- *
- * @return string
*/
- public function getLastError()
+ public function getLastError(): string
{
return $this->lastError;
}
/**
- * @inheritdoc
+ * Return a fake diagnostic message.
*/
- public function getDiagnosticMessage()
+ public function getDiagnosticMessage(): ?string
{
return $this->diagnosticMessage;
}
/**
* Return a fake detailed error.
- *
- * @return DetailedError
*/
- public function getDetailedError()
+ public function getDetailedError(): DetailedError
{
return new DetailedError(
$this->errNo(),
@@ -224,249 +206,309 @@
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getEntries($searchResults)
+ public function getEntries(mixed $result): array
{
- return $searchResults;
+ return $result;
}
/**
- * @inheritdoc
+ * {@inheritDoc}
*/
- public function isUsingSSL()
+ public function getValuesLen(mixed $entry, string $attribute): array|false
{
- return $this->hasExpectations('isUsingSSL')
- ? $this->resolveExpectation('isUsingSSL')
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function compare(string $dn, string $attribute, string $value, ?array $controls = null): bool|int
+ {
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function setRebindCallback(callable $callback): bool
+ {
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function getFirstEntry(mixed $result): mixed
+ {
+ return $this->executeFailableOperation(function () use ($result) {
+ return ldap_first_entry($this->connection, $result);
+ });
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function getNextEntry(mixed $entry): mixed
+ {
+ return $this->executeFailableOperation(function () use ($entry) {
+ return ldap_next_entry($this->connection, $entry);
+ });
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function getAttributes(mixed $entry): array|false
+ {
+ return $this->executeFailableOperation(function () use ($entry) {
+ return ldap_get_attributes($this->connection, $entry);
+ });
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public function countEntries(mixed $result): int
+ {
+ return $this->executeFailableOperation(function () use ($result) {
+ return ldap_count_entries($this->connection, $result);
+ });
+ }
+
+ /**
+ * {@inheritdoc}
+ */
+ public function isUsingSSL(): bool
+ {
+ return $this->hasExpectations(__FUNCTION__)
+ ? $this->resolveExpectation(__FUNCTION__)
: $this->useSSL;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function isUsingTLS()
+ public function isUsingTLS(): bool
{
- return $this->hasExpectations('isUsingTLS')
- ? $this->resolveExpectation('isUsingTLS')
+ return $this->hasExpectations(__FUNCTION__)
+ ? $this->resolveExpectation(__FUNCTION__)
: $this->useTLS;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function isBound()
+ public function isBound(): bool
{
- return $this->hasExpectations('isBound')
- ? $this->resolveExpectation('isBound')
+ return $this->hasExpectations(__FUNCTION__)
+ ? $this->resolveExpectation(__FUNCTION__)
: $this->bound;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function setOption($option, $value)
+ public function setOption(int $option, mixed $value): bool
{
- return $this->hasExpectations('setOption')
- ? $this->resolveExpectation('setOption', func_get_args())
+ return $this->hasExpectations(__FUNCTION__)
+ ? $this->resolveExpectation(__FUNCTION__, func_get_args())
: true;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function getOption($option, &$value = null)
+ public function getOption(int $option, mixed &$value = null): mixed
{
- return $this->resolveExpectation('getOption', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function startTLS()
+ public function startTLS(): bool
{
- return $this->resolveExpectation('startTLS', func_get_args());
+ return $this->secure = $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function connect($hosts = [], $port = 389)
+ public function connect(string|array $hosts = [], int $port = 389, ?string $protocol = null): bool
{
$this->bound = false;
-
+ $this->protocol = $protocol;
$this->host = $this->makeConnectionUris($hosts, $port);
- return $this->connection = $this->hasExpectations('connect')
- ? $this->resolveExpectation('connect', func_get_args())
+ return $this->connection = $this->hasExpectations(__FUNCTION__)
+ ? $this->resolveExpectation(__FUNCTION__, func_get_args())
: true;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function close()
+ public function close(): bool
{
- $this->connection = null;
$this->bound = false;
- $this->host = null;
+ $this->secure = false;
- return $this->hasExpectations('close')
- ? $this->resolveExpectation('close')
+ $this->host = null;
+ $this->protocol = null;
+ $this->connection = null;
+
+ return $this->hasExpectations(__FUNCTION__)
+ ? $this->resolveExpectation(__FUNCTION__)
: true;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function bind($username, $password)
+ public function bind(?string $dn = null, ?string $password = null, ?array $controls = null): LdapResultResponse
{
- return $this->bound = $this->resolveExpectation('bind', func_get_args());
+ $result = $this->resolveExpectation(__FUNCTION__, func_get_args());
+
+ $this->handleBindResponse($result);
+
+ return $result;
}
/**
- * @inheritdoc
+ * {@inheritDoc}
*/
- public function search($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = [])
+ public function saslBind(?string $dn = null, ?string $password = null, ?array $options = null): bool
{
- return $this->resolveExpectation('search', func_get_args());
+ return $this->bound = $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function listing($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = [])
+ public function search(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed
{
- return $this->resolveExpectation('listing', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function read($dn, $filter, array $fields, $onlyAttributes = false, $size = 0, $time = 0, $deref = LDAP_DEREF_NEVER, $serverControls = [])
+ public function list(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed
{
- return $this->resolveExpectation('read', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function parseResult($result, &$errorCode, &$dn, &$errorMessage, &$referrals, &$serverControls = [])
+ public function read(string $dn, string $filter, array $fields, bool $onlyAttributes = false, int $size = 0, int $time = 0, int $deref = LDAP_DEREF_NEVER, ?array $controls = null): mixed
{
- return $this->resolveExpectation('parseResult', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function add($dn, array $entry)
+ public function parseResult(mixed $result, int &$errorCode = 0, ?string &$dn = null, ?string &$errorMessage = null, ?array &$referrals = null, ?array &$controls = null): LdapResultResponse|false
{
- return $this->resolveExpectation('add', func_get_args());
+ return $this->hasExpectations(__FUNCTION__)
+ ? $this->resolveExpectation(__FUNCTION__, func_get_args())
+ : new LdapResultResponse;
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function delete($dn)
+ public function add(string $dn, array $entry): bool
{
- return $this->resolveExpectation('delete', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function rename($dn, $newRdn, $newParent, $deleteOldRdn = false)
+ public function delete(string $dn): bool
{
- return $this->resolveExpectation('rename', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modify($dn, array $entry)
+ public function rename(string $dn, string $newRdn, string $newParent, bool $deleteOldRdn = false): bool
{
- return $this->resolveExpectation('modify', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modifyBatch($dn, array $values)
+ public function modify(string $dn, array $entry): bool
{
- return $this->resolveExpectation('modifyBatch', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modAdd($dn, array $entry)
+ public function modifyBatch(string $dn, array $values): bool
{
- return $this->resolveExpectation('modAdd', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modReplace($dn, array $entry)
+ public function modAdd(string $dn, array $entry): bool
{
- return $this->resolveExpectation('modReplace', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function modDelete($dn, array $entry)
+ public function modReplace(string $dn, array $entry): bool
{
- return $this->resolveExpectation('modDelete', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function controlPagedResult($pageSize = 1000, $isCritical = false, $cookie = '')
+ public function modDelete(string $dn, array $entry): bool
{
- return $this->resolveExpectation('controlPagedResult', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function controlPagedResultResponse($result, &$cookie)
+ public function freeResult(mixed $result): bool
{
- return $this->resolveExpectation('controlPagedResultResponse', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
- * @inheritdoc
+ * {@inheritdoc}
*/
- public function freeResult($result)
+ public function err2Str(int $number): string
{
- return $this->resolveExpectation('freeResult', func_get_args());
- }
-
- /**
- * @inheritdoc
- */
- public function err2Str($number)
- {
- return $this->resolveExpectation('err2Str', func_get_args());
+ return $this->resolveExpectation(__FUNCTION__, func_get_args());
}
/**
* Resolve the methods expectations.
*
- * @param string $method
- * @param array $args
- *
- * @return mixed
- *
- * @throws Exception
+ * @throws LdapExpectationException
*/
- protected function resolveExpectation($method, array $args = [])
+ protected function resolveExpectation(string $method, array $args = []): mixed
{
foreach ($this->getExpectations($method) as $key => $expectation) {
$this->assertMethodArgumentsMatch($method, $expectation->getExpectedArgs(), $args);
- $expectation->decrementCallCount();
+ $expectation->decrementExpectedCount();
if ($expectation->getExpectedCount() === 0) {
$this->removeExpectation($method, $key);
@@ -483,17 +525,13 @@
return $expectation->getExpectedValue();
}
- throw new Exception("LDAP method [$method] was unexpected.");
+ throw new LdapExpectationException("LDAP method [$method] was unexpected.");
}
/**
* Apply the expectation error to the fake.
- *
- * @param LdapExpectation $expectation
- *
- * @return void
*/
- protected function applyExpectationError(LdapExpectation $expectation)
+ protected function applyExpectationError(LdapExpectation $expectation): void
{
$this->shouldReturnError($expectation->getExpectedErrorMessage());
$this->shouldReturnErrorNumber($expectation->getExpectedErrorCode());
@@ -501,15 +539,29 @@
}
/**
+ * Assert that the expectations have been called their minimum amount of times.
+ *
+ * @throws LdapExpectationException
+ */
+ public function assertMinimumExpectationCounts(): void
+ {
+ foreach ($this->expectations as $method => $expectations) {
+ foreach ($expectations as $expectation) {
+ if (! $expectation->isIndefinite() && $expectation->getExpectedCount()) {
+ $remaining = ($original = $expectation->getOriginalExpectedCount()) - $expectation->getExpectedCount();
+
+ throw new LdapExpectationException("Method [$method] should be called $original times but was called $remaining times.");
+ }
+ }
+ }
+ }
+
+ /**
* Assert that the expected arguments match the operations arguments.
*
- * @param string $method
- * @param Constraint[] $expectedArgs
- * @param array $methodArgs
- *
- * @return void
+ * @param Constraint[] $expectedArgs
*/
- protected function assertMethodArgumentsMatch($method, array $expectedArgs = [], array $methodArgs = [])
+ protected function assertMethodArgumentsMatch(string $method, array $expectedArgs = [], array $methodArgs = []): void
{
foreach ($expectedArgs as $key => $constraint) {
$argNumber = $key + 1;
@@ -517,7 +569,7 @@
PHPUnit::assertArrayHasKey(
$key,
$methodArgs,
- "LDAP method [$method] argument #{$argNumber} does not exist."
+ "LDAP method [$method] argument #$argNumber does not exist."
);
$constraint->evaluate(
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Utilities.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Utilities.php
deleted file mode 100644
index 01d55c7..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/directorytree/ldaprecord/src/Utilities.php
+++ /dev/null
@@ -1,196 +0,0 @@
-<?php
-
-namespace LdapRecord;
-
-class Utilities
-{
- /**
- * Converts a DN string into an array of RDNs.
- *
- * This will also decode hex characters into their true
- * UTF-8 representation embedded inside the DN as well.
- *
- * @param string $dn
- * @param bool $removeAttributePrefixes
- *
- * @return array|false
- */
- public static function explodeDn($dn, $removeAttributePrefixes = true)
- {
- $dn = ldap_explode_dn($dn, ($removeAttributePrefixes ? 1 : 0));
-
- if (! is_array($dn)) {
- return false;
- }
-
- if (! array_key_exists('count', $dn)) {
- return false;
- }
-
- unset($dn['count']);
-
- foreach ($dn as $rdn => $value) {
- $dn[$rdn] = static::unescape($value);
- }
-
- return $dn;
- }
-
- /**
- * Un-escapes a hexadecimal string into its original string representation.
- *
- * @param string $value
- *
- * @return string
- */
- public static function unescape($value)
- {
- return preg_replace_callback('/\\\([0-9A-Fa-f]{2})/', function ($matches) {
- return chr(hexdec($matches[1]));
- }, $value);
- }
-
- /**
- * Convert a binary SID to a string SID.
- *
- * @author Chad Sikorra
- *
- * @see https://github.com/ChadSikorra
- * @see https://stackoverflow.com/questions/39533560/php-ldap-get-user-sid
- *
- * @param string $value The Binary SID
- *
- * @return string|null
- */
- public static function binarySidToString($value)
- {
- // Revision - 8bit unsigned int (C1)
- // Count - 8bit unsigned int (C1)
- // 2 null bytes
- // ID - 32bit unsigned long, big-endian order
- $sid = @unpack('C1rev/C1count/x2/N1id', $value);
-
- if (! isset($sid['id']) || ! isset($sid['rev'])) {
- return;
- }
-
- $revisionLevel = $sid['rev'];
-
- $identifierAuthority = $sid['id'];
-
- $subs = isset($sid['count']) ? $sid['count'] : 0;
-
- $sidHex = $subs ? bin2hex($value) : '';
-
- $subAuthorities = [];
-
- // The sub-authorities depend on the count, so only get as
- // many as the count, regardless of data beyond it.
- for ($i = 0; $i < $subs; $i++) {
- $data = implode(array_reverse(
- str_split(
- substr($sidHex, 16 + ($i * 8), 8),
- 2
- )
- ));
-
- $subAuthorities[] = hexdec($data);
- }
-
- // Tack on the 'S-' and glue it all together...
- return 'S-'.$revisionLevel.'-'.$identifierAuthority.implode(
- preg_filter('/^/', '-', $subAuthorities)
- );
- }
-
- /**
- * Convert a binary GUID to a string GUID.
- *
- * @param string $binGuid
- *
- * @return string|null
- */
- public static function binaryGuidToString($binGuid)
- {
- if (is_null($binGuid) || trim($binGuid) == '') {
- return;
- }
-
- $hex = unpack('H*hex', $binGuid)['hex'];
-
- $hex1 = substr($hex, -26, 2).substr($hex, -28, 2).substr($hex, -30, 2).substr($hex, -32, 2);
- $hex2 = substr($hex, -22, 2).substr($hex, -24, 2);
- $hex3 = substr($hex, -18, 2).substr($hex, -20, 2);
- $hex4 = substr($hex, -16, 4);
- $hex5 = substr($hex, -12, 12);
-
- return sprintf('%s-%s-%s-%s-%s', $hex1, $hex2, $hex3, $hex4, $hex5);
- }
-
- /**
- * Converts a string GUID to it's hex variant.
- *
- * @param string $string
- *
- * @return string
- */
- public static function stringGuidToHex($string)
- {
- $hex = '\\'.substr($string, 6, 2).'\\'.substr($string, 4, 2).'\\'.substr($string, 2, 2).'\\'.substr($string, 0, 2);
- $hex = $hex.'\\'.substr($string, 11, 2).'\\'.substr($string, 9, 2);
- $hex = $hex.'\\'.substr($string, 16, 2).'\\'.substr($string, 14, 2);
- $hex = $hex.'\\'.substr($string, 19, 2).'\\'.substr($string, 21, 2);
- $hex = $hex.'\\'.substr($string, 24, 2).'\\'.substr($string, 26, 2).'\\'.substr($string, 28, 2).'\\'.substr($string, 30, 2).'\\'.substr($string, 32, 2).'\\'.substr($string, 34, 2);
-
- return $hex;
- }
-
- /**
- * Round a Windows timestamp down to seconds and remove
- * the seconds between 1601-01-01 and 1970-01-01.
- *
- * @param float $windowsTime
- *
- * @return float
- */
- public static function convertWindowsTimeToUnixTime($windowsTime)
- {
- return round($windowsTime / 10000000) - 11644473600;
- }
-
- /**
- * Convert a Unix timestamp to Windows timestamp.
- *
- * @param float $unixTime
- *
- * @return float
- */
- public static function convertUnixTimeToWindowsTime($unixTime)
- {
- return ($unixTime + 11644473600) * 10000000;
- }
-
- /**
- * Validates that the inserted string is an object SID.
- *
- * @param string $sid
- *
- * @return bool
- */
- public static function isValidSid($sid)
- {
- return (bool) preg_match("/^S-\d(-\d{1,10}){1,16}$/i", (string) $sid);
- }
-
- /**
- * Validates that the inserted string is an object GUID.
- *
- * @param string $guid
- *
- * @return bool
- */
- public static function isValidGuid($guid)
- {
- return (bool) preg_match('/^([0-9a-fA-F]){8}(-([0-9a-fA-F]){4}){3}-([0-9a-fA-F]){12}$/', (string) $guid);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/CHANGELOG.md
new file mode 100644
index 0000000..35e97fe
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/CHANGELOG.md
@@ -0,0 +1,117 @@
+# Changelog
+
+## [6.5.0](https://github.com/firebase/php-jwt/compare/v6.4.0...v6.5.0) (2023-05-12)
+
+
+### Bug Fixes
+
+* allow KID of '0' ([#505](https://github.com/firebase/php-jwt/issues/505)) ([9dc46a9](https://github.com/firebase/php-jwt/commit/9dc46a9c3e5801294249cfd2554c5363c9f9326a))
+
+
+### Miscellaneous Chores
+
+* drop support for PHP 7.3 ([#495](https://github.com/firebase/php-jwt/issues/495))
+
+## [6.4.0](https://github.com/firebase/php-jwt/compare/v6.3.2...v6.4.0) (2023-02-08)
+
+
+### Features
+
+* add support for W3C ES256K ([#462](https://github.com/firebase/php-jwt/issues/462)) ([213924f](https://github.com/firebase/php-jwt/commit/213924f51936291fbbca99158b11bd4ae56c2c95))
+* improve caching by only decoding jwks when necessary ([#486](https://github.com/firebase/php-jwt/issues/486)) ([78d3ed1](https://github.com/firebase/php-jwt/commit/78d3ed1073553f7d0bbffa6c2010009a0d483d5c))
+
+## [6.3.2](https://github.com/firebase/php-jwt/compare/v6.3.1...v6.3.2) (2022-11-01)
+
+
+### Bug Fixes
+
+* check kid before using as array index ([bad1b04](https://github.com/firebase/php-jwt/commit/bad1b040d0c736bbf86814c6b5ae614f517cf7bd))
+
+## [6.3.1](https://github.com/firebase/php-jwt/compare/v6.3.0...v6.3.1) (2022-11-01)
+
+
+### Bug Fixes
+
+* casing of GET for PSR compat ([#451](https://github.com/firebase/php-jwt/issues/451)) ([60b52b7](https://github.com/firebase/php-jwt/commit/60b52b71978790eafcf3b95cfbd83db0439e8d22))
+* string interpolation format for php 8.2 ([#446](https://github.com/firebase/php-jwt/issues/446)) ([2e07d8a](https://github.com/firebase/php-jwt/commit/2e07d8a1524d12b69b110ad649f17461d068b8f2))
+
+## 6.3.0 / 2022-07-15
+
+ - Added ES256 support to JWK parsing ([#399](https://github.com/firebase/php-jwt/pull/399))
+ - Fixed potential caching error in `CachedKeySet` by caching jwks as strings ([#435](https://github.com/firebase/php-jwt/pull/435))
+
+## 6.2.0 / 2022-05-14
+
+ - Added `CachedKeySet` ([#397](https://github.com/firebase/php-jwt/pull/397))
+ - Added `$defaultAlg` parameter to `JWT::parseKey` and `JWT::parseKeySet` ([#426](https://github.com/firebase/php-jwt/pull/426)).
+
+## 6.1.0 / 2022-03-23
+
+ - Drop support for PHP 5.3, 5.4, 5.5, 5.6, and 7.0
+ - Add parameter typing and return types where possible
+
+## 6.0.0 / 2022-01-24
+
+ - **Backwards-Compatibility Breaking Changes**: See the [Release Notes](https://github.com/firebase/php-jwt/releases/tag/v6.0.0) for more information.
+ - New Key object to prevent key/algorithm type confusion (#365)
+ - Add JWK support (#273)
+ - Add ES256 support (#256)
+ - Add ES384 support (#324)
+ - Add Ed25519 support (#343)
+
+## 5.0.0 / 2017-06-26
+- Support RS384 and RS512.
+ See [#117](https://github.com/firebase/php-jwt/pull/117). Thanks [@joostfaassen](https://github.com/joostfaassen)!
+- Add an example for RS256 openssl.
+ See [#125](https://github.com/firebase/php-jwt/pull/125). Thanks [@akeeman](https://github.com/akeeman)!
+- Detect invalid Base64 encoding in signature.
+ See [#162](https://github.com/firebase/php-jwt/pull/162). Thanks [@psignoret](https://github.com/psignoret)!
+- Update `JWT::verify` to handle OpenSSL errors.
+ See [#159](https://github.com/firebase/php-jwt/pull/159). Thanks [@bshaffer](https://github.com/bshaffer)!
+- Add `array` type hinting to `decode` method
+ See [#101](https://github.com/firebase/php-jwt/pull/101). Thanks [@hywak](https://github.com/hywak)!
+- Add all JSON error types.
+ See [#110](https://github.com/firebase/php-jwt/pull/110). Thanks [@gbalduzzi](https://github.com/gbalduzzi)!
+- Bugfix 'kid' not in given key list.
+ See [#129](https://github.com/firebase/php-jwt/pull/129). Thanks [@stampycode](https://github.com/stampycode)!
+- Miscellaneous cleanup, documentation and test fixes.
+ See [#107](https://github.com/firebase/php-jwt/pull/107), [#115](https://github.com/firebase/php-jwt/pull/115),
+ [#160](https://github.com/firebase/php-jwt/pull/160), [#161](https://github.com/firebase/php-jwt/pull/161), and
+ [#165](https://github.com/firebase/php-jwt/pull/165). Thanks [@akeeman](https://github.com/akeeman),
+ [@chinedufn](https://github.com/chinedufn), and [@bshaffer](https://github.com/bshaffer)!
+
+## 4.0.0 / 2016-07-17
+- Add support for late static binding. See [#88](https://github.com/firebase/php-jwt/pull/88) for details. Thanks to [@chappy84](https://github.com/chappy84)!
+- Use static `$timestamp` instead of `time()` to improve unit testing. See [#93](https://github.com/firebase/php-jwt/pull/93) for details. Thanks to [@josephmcdermott](https://github.com/josephmcdermott)!
+- Fixes to exceptions classes. See [#81](https://github.com/firebase/php-jwt/pull/81) for details. Thanks to [@Maks3w](https://github.com/Maks3w)!
+- Fixes to PHPDoc. See [#76](https://github.com/firebase/php-jwt/pull/76) for details. Thanks to [@akeeman](https://github.com/akeeman)!
+
+## 3.0.0 / 2015-07-22
+- Minimum PHP version updated from `5.2.0` to `5.3.0`.
+- Add `\Firebase\JWT` namespace. See
+[#59](https://github.com/firebase/php-jwt/pull/59) for details. Thanks to
+[@Dashron](https://github.com/Dashron)!
+- Require a non-empty key to decode and verify a JWT. See
+[#60](https://github.com/firebase/php-jwt/pull/60) for details. Thanks to
+[@sjones608](https://github.com/sjones608)!
+- Cleaner documentation blocks in the code. See
+[#62](https://github.com/firebase/php-jwt/pull/62) for details. Thanks to
+[@johanderuijter](https://github.com/johanderuijter)!
+
+## 2.2.0 / 2015-06-22
+- Add support for adding custom, optional JWT headers to `JWT::encode()`. See
+[#53](https://github.com/firebase/php-jwt/pull/53/files) for details. Thanks to
+[@mcocaro](https://github.com/mcocaro)!
+
+## 2.1.0 / 2015-05-20
+- Add support for adding a leeway to `JWT:decode()` that accounts for clock skew
+between signing and verifying entities. Thanks to [@lcabral](https://github.com/lcabral)!
+- Add support for passing an object implementing the `ArrayAccess` interface for
+`$keys` argument in `JWT::decode()`. Thanks to [@aztech-dev](https://github.com/aztech-dev)!
+
+## 2.0.0 / 2015-04-01
+- **Note**: It is strongly recommended that you update to > v2.0.0 to address
+ known security vulnerabilities in prior versions when both symmetric and
+ asymmetric keys are used together.
+- Update signature for `JWT::decode(...)` to require an array of supported
+ algorithms to use when verifying token signatures.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/LICENSE
new file mode 100644
index 0000000..11c0146
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/LICENSE
@@ -0,0 +1,30 @@
+Copyright (c) 2011, Neuman Vong
+
+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 the copyright holder nor the names of other
+ 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/firebase/php-jwt/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/README.md
new file mode 100644
index 0000000..f038266
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/README.md
@@ -0,0 +1,419 @@
+
+[](https://packagist.org/packages/firebase/php-jwt)
+[](https://packagist.org/packages/firebase/php-jwt)
+[](https://packagist.org/packages/firebase/php-jwt)
+
+PHP-JWT
+=======
+A simple library to encode and decode JSON Web Tokens (JWT) in PHP, conforming to [RFC 7519](https://tools.ietf.org/html/rfc7519).
+
+Installation
+------------
+
+Use composer to manage your dependencies and download PHP-JWT:
+
+```bash
+composer require firebase/php-jwt
+```
+
+Optionally, install the `paragonie/sodium_compat` package from composer if your
+php is < 7.2 or does not have libsodium installed:
+
+```bash
+composer require paragonie/sodium_compat
+```
+
+Example
+-------
+```php
+use Firebase\JWT\JWT;
+use Firebase\JWT\Key;
+
+$key = 'example_key';
+$payload = [
+ 'iss' => 'http://example.org',
+ 'aud' => 'http://example.com',
+ 'iat' => 1356999524,
+ 'nbf' => 1357000000
+];
+
+/**
+ * IMPORTANT:
+ * You must specify supported algorithms for your application. See
+ * https://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms-40
+ * for a list of spec-compliant algorithms.
+ */
+$jwt = JWT::encode($payload, $key, 'HS256');
+$decoded = JWT::decode($jwt, new Key($key, 'HS256'));
+
+print_r($decoded);
+
+/*
+ NOTE: This will now be an object instead of an associative array. To get
+ an associative array, you will need to cast it as such:
+*/
+
+$decoded_array = (array) $decoded;
+
+/**
+ * You can add a leeway to account for when there is a clock skew times between
+ * the signing and verifying servers. It is recommended that this leeway should
+ * not be bigger than a few minutes.
+ *
+ * Source: http://self-issued.info/docs/draft-ietf-oauth-json-web-token.html#nbfDef
+ */
+JWT::$leeway = 60; // $leeway in seconds
+$decoded = JWT::decode($jwt, new Key($key, 'HS256'));
+```
+Example encode/decode headers
+-------
+Decoding the JWT headers without verifying the JWT first is NOT recommended, and is not supported by
+this library. This is because without verifying the JWT, the header values could have been tampered with.
+Any value pulled from an unverified header should be treated as if it could be any string sent in from an
+attacker. If this is something you still want to do in your application for whatever reason, it's possible to
+decode the header values manually simply by calling `json_decode` and `base64_decode` on the JWT
+header part:
+```php
+use Firebase\JWT\JWT;
+
+$key = 'example_key';
+$payload = [
+ 'iss' => 'http://example.org',
+ 'aud' => 'http://example.com',
+ 'iat' => 1356999524,
+ 'nbf' => 1357000000
+];
+
+$headers = [
+ 'x-forwarded-for' => 'www.google.com'
+];
+
+// Encode headers in the JWT string
+$jwt = JWT::encode($payload, $key, 'HS256', null, $headers);
+
+// Decode headers from the JWT string WITHOUT validation
+// **IMPORTANT**: This operation is vulnerable to attacks, as the JWT has not yet been verified.
+// These headers could be any value sent by an attacker.
+list($headersB64, $payloadB64, $sig) = explode('.', $jwt);
+$decoded = json_decode(base64_decode($headersB64), true);
+
+print_r($decoded);
+```
+Example with RS256 (openssl)
+----------------------------
+```php
+use Firebase\JWT\JWT;
+use Firebase\JWT\Key;
+
+$privateKey = <<<EOD
+-----BEGIN RSA PRIVATE KEY-----
+MIIEowIBAAKCAQEAuzWHNM5f+amCjQztc5QTfJfzCC5J4nuW+L/aOxZ4f8J3Frew
+M2c/dufrnmedsApb0By7WhaHlcqCh/ScAPyJhzkPYLae7bTVro3hok0zDITR8F6S
+JGL42JAEUk+ILkPI+DONM0+3vzk6Kvfe548tu4czCuqU8BGVOlnp6IqBHhAswNMM
+78pos/2z0CjPM4tbeXqSTTbNkXRboxjU29vSopcT51koWOgiTf3C7nJUoMWZHZI5
+HqnIhPAG9yv8HAgNk6CMk2CadVHDo4IxjxTzTTqo1SCSH2pooJl9O8at6kkRYsrZ
+WwsKlOFE2LUce7ObnXsYihStBUDoeBQlGG/BwQIDAQABAoIBAFtGaOqNKGwggn9k
+6yzr6GhZ6Wt2rh1Xpq8XUz514UBhPxD7dFRLpbzCrLVpzY80LbmVGJ9+1pJozyWc
+VKeCeUdNwbqkr240Oe7GTFmGjDoxU+5/HX/SJYPpC8JZ9oqgEA87iz+WQX9hVoP2
+oF6EB4ckDvXmk8FMwVZW2l2/kd5mrEVbDaXKxhvUDf52iVD+sGIlTif7mBgR99/b
+c3qiCnxCMmfYUnT2eh7Vv2LhCR/G9S6C3R4lA71rEyiU3KgsGfg0d82/XWXbegJW
+h3QbWNtQLxTuIvLq5aAryV3PfaHlPgdgK0ft6ocU2de2FagFka3nfVEyC7IUsNTK
+bq6nhAECgYEA7d/0DPOIaItl/8BWKyCuAHMss47j0wlGbBSHdJIiS55akMvnAG0M
+39y22Qqfzh1at9kBFeYeFIIU82ZLF3xOcE3z6pJZ4Dyvx4BYdXH77odo9uVK9s1l
+3T3BlMcqd1hvZLMS7dviyH79jZo4CXSHiKzc7pQ2YfK5eKxKqONeXuECgYEAyXlG
+vonaus/YTb1IBei9HwaccnQ/1HRn6MvfDjb7JJDIBhNClGPt6xRlzBbSZ73c2QEC
+6Fu9h36K/HZ2qcLd2bXiNyhIV7b6tVKk+0Psoj0dL9EbhsD1OsmE1nTPyAc9XZbb
+OPYxy+dpBCUA8/1U9+uiFoCa7mIbWcSQ+39gHuECgYAz82pQfct30aH4JiBrkNqP
+nJfRq05UY70uk5k1u0ikLTRoVS/hJu/d4E1Kv4hBMqYCavFSwAwnvHUo51lVCr/y
+xQOVYlsgnwBg2MX4+GjmIkqpSVCC8D7j/73MaWb746OIYZervQ8dbKahi2HbpsiG
+8AHcVSA/agxZr38qvWV54QKBgCD5TlDE8x18AuTGQ9FjxAAd7uD0kbXNz2vUYg9L
+hFL5tyL3aAAtUrUUw4xhd9IuysRhW/53dU+FsG2dXdJu6CxHjlyEpUJl2iZu/j15
+YnMzGWHIEX8+eWRDsw/+Ujtko/B7TinGcWPz3cYl4EAOiCeDUyXnqnO1btCEUU44
+DJ1BAoGBAJuPD27ErTSVtId90+M4zFPNibFP50KprVdc8CR37BE7r8vuGgNYXmnI
+RLnGP9p3pVgFCktORuYS2J/6t84I3+A17nEoB4xvhTLeAinAW/uTQOUmNicOP4Ek
+2MsLL2kHgL8bLTmvXV4FX+PXphrDKg1XxzOYn0otuoqdAQrkK4og
+-----END RSA PRIVATE KEY-----
+EOD;
+
+$publicKey = <<<EOD
+-----BEGIN PUBLIC KEY-----
+MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuzWHNM5f+amCjQztc5QT
+fJfzCC5J4nuW+L/aOxZ4f8J3FrewM2c/dufrnmedsApb0By7WhaHlcqCh/ScAPyJ
+hzkPYLae7bTVro3hok0zDITR8F6SJGL42JAEUk+ILkPI+DONM0+3vzk6Kvfe548t
+u4czCuqU8BGVOlnp6IqBHhAswNMM78pos/2z0CjPM4tbeXqSTTbNkXRboxjU29vS
+opcT51koWOgiTf3C7nJUoMWZHZI5HqnIhPAG9yv8HAgNk6CMk2CadVHDo4IxjxTz
+TTqo1SCSH2pooJl9O8at6kkRYsrZWwsKlOFE2LUce7ObnXsYihStBUDoeBQlGG/B
+wQIDAQAB
+-----END PUBLIC KEY-----
+EOD;
+
+$payload = [
+ 'iss' => 'example.org',
+ 'aud' => 'example.com',
+ 'iat' => 1356999524,
+ 'nbf' => 1357000000
+];
+
+$jwt = JWT::encode($payload, $privateKey, 'RS256');
+echo "Encode:\n" . print_r($jwt, true) . "\n";
+
+$decoded = JWT::decode($jwt, new Key($publicKey, 'RS256'));
+
+/*
+ NOTE: This will now be an object instead of an associative array. To get
+ an associative array, you will need to cast it as such:
+*/
+
+$decoded_array = (array) $decoded;
+echo "Decode:\n" . print_r($decoded_array, true) . "\n";
+```
+
+Example with a passphrase
+-------------------------
+
+```php
+use Firebase\JWT\JWT;
+use Firebase\JWT\Key;
+
+// Your passphrase
+$passphrase = '[YOUR_PASSPHRASE]';
+
+// Your private key file with passphrase
+// Can be generated with "ssh-keygen -t rsa -m pem"
+$privateKeyFile = '/path/to/key-with-passphrase.pem';
+
+// Create a private key of type "resource"
+$privateKey = openssl_pkey_get_private(
+ file_get_contents($privateKeyFile),
+ $passphrase
+);
+
+$payload = [
+ 'iss' => 'example.org',
+ 'aud' => 'example.com',
+ 'iat' => 1356999524,
+ 'nbf' => 1357000000
+];
+
+$jwt = JWT::encode($payload, $privateKey, 'RS256');
+echo "Encode:\n" . print_r($jwt, true) . "\n";
+
+// Get public key from the private key, or pull from from a file.
+$publicKey = openssl_pkey_get_details($privateKey)['key'];
+
+$decoded = JWT::decode($jwt, new Key($publicKey, 'RS256'));
+echo "Decode:\n" . print_r((array) $decoded, true) . "\n";
+```
+
+Example with EdDSA (libsodium and Ed25519 signature)
+----------------------------
+```php
+use Firebase\JWT\JWT;
+use Firebase\JWT\Key;
+
+// Public and private keys are expected to be Base64 encoded. The last
+// non-empty line is used so that keys can be generated with
+// sodium_crypto_sign_keypair(). The secret keys generated by other tools may
+// need to be adjusted to match the input expected by libsodium.
+
+$keyPair = sodium_crypto_sign_keypair();
+
+$privateKey = base64_encode(sodium_crypto_sign_secretkey($keyPair));
+
+$publicKey = base64_encode(sodium_crypto_sign_publickey($keyPair));
+
+$payload = [
+ 'iss' => 'example.org',
+ 'aud' => 'example.com',
+ 'iat' => 1356999524,
+ 'nbf' => 1357000000
+];
+
+$jwt = JWT::encode($payload, $privateKey, 'EdDSA');
+echo "Encode:\n" . print_r($jwt, true) . "\n";
+
+$decoded = JWT::decode($jwt, new Key($publicKey, 'EdDSA'));
+echo "Decode:\n" . print_r((array) $decoded, true) . "\n";
+````
+
+Example with multiple keys
+--------------------------
+```php
+use Firebase\JWT\JWT;
+use Firebase\JWT\Key;
+
+// Example RSA keys from previous example
+// $privateKey1 = '...';
+// $publicKey1 = '...';
+
+// Example EdDSA keys from previous example
+// $privateKey2 = '...';
+// $publicKey2 = '...';
+
+$payload = [
+ 'iss' => 'example.org',
+ 'aud' => 'example.com',
+ 'iat' => 1356999524,
+ 'nbf' => 1357000000
+];
+
+$jwt1 = JWT::encode($payload, $privateKey1, 'RS256', 'kid1');
+$jwt2 = JWT::encode($payload, $privateKey2, 'EdDSA', 'kid2');
+echo "Encode 1:\n" . print_r($jwt1, true) . "\n";
+echo "Encode 2:\n" . print_r($jwt2, true) . "\n";
+
+$keys = [
+ 'kid1' => new Key($publicKey1, 'RS256'),
+ 'kid2' => new Key($publicKey2, 'EdDSA'),
+];
+
+$decoded1 = JWT::decode($jwt1, $keys);
+$decoded2 = JWT::decode($jwt2, $keys);
+
+echo "Decode 1:\n" . print_r((array) $decoded1, true) . "\n";
+echo "Decode 2:\n" . print_r((array) $decoded2, true) . "\n";
+```
+
+Using JWKs
+----------
+
+```php
+use Firebase\JWT\JWK;
+use Firebase\JWT\JWT;
+
+// Set of keys. The "keys" key is required. For example, the JSON response to
+// this endpoint: https://www.gstatic.com/iap/verify/public_key-jwk
+$jwks = ['keys' => []];
+
+// JWK::parseKeySet($jwks) returns an associative array of **kid** to Firebase\JWT\Key
+// objects. Pass this as the second parameter to JWT::decode.
+JWT::decode($payload, JWK::parseKeySet($jwks));
+```
+
+Using Cached Key Sets
+---------------------
+
+The `CachedKeySet` class can be used to fetch and cache JWKS (JSON Web Key Sets) from a public URI.
+This has the following advantages:
+
+1. The results are cached for performance.
+2. If an unrecognized key is requested, the cache is refreshed, to accomodate for key rotation.
+3. If rate limiting is enabled, the JWKS URI will not make more than 10 requests a second.
+
+```php
+use Firebase\JWT\CachedKeySet;
+use Firebase\JWT\JWT;
+
+// The URI for the JWKS you wish to cache the results from
+$jwksUri = 'https://www.gstatic.com/iap/verify/public_key-jwk';
+
+// Create an HTTP client (can be any PSR-7 compatible HTTP client)
+$httpClient = new GuzzleHttp\Client();
+
+// Create an HTTP request factory (can be any PSR-17 compatible HTTP request factory)
+$httpFactory = new GuzzleHttp\Psr\HttpFactory();
+
+// Create a cache item pool (can be any PSR-6 compatible cache item pool)
+$cacheItemPool = Phpfastcache\CacheManager::getInstance('files');
+
+$keySet = new CachedKeySet(
+ $jwksUri,
+ $httpClient,
+ $httpFactory,
+ $cacheItemPool,
+ null, // $expiresAfter int seconds to set the JWKS to expire
+ true // $rateLimit true to enable rate limit of 10 RPS on lookup of invalid keys
+);
+
+$jwt = 'eyJhbGci...'; // Some JWT signed by a key from the $jwkUri above
+$decoded = JWT::decode($jwt, $keySet);
+```
+
+Miscellaneous
+-------------
+
+#### Exception Handling
+
+When a call to `JWT::decode` is invalid, it will throw one of the following exceptions:
+
+```php
+use Firebase\JWT\JWT;
+use Firebase\JWT\SignatureInvalidException;
+use Firebase\JWT\BeforeValidException;
+use Firebase\JWT\ExpiredException;
+use DomainException;
+use InvalidArgumentException;
+use UnexpectedValueException;
+
+try {
+ $decoded = JWT::decode($payload, $keys);
+} catch (InvalidArgumentException $e) {
+ // provided key/key-array is empty or malformed.
+} catch (DomainException $e) {
+ // provided algorithm is unsupported OR
+ // provided key is invalid OR
+ // unknown error thrown in openSSL or libsodium OR
+ // libsodium is required but not available.
+} catch (SignatureInvalidException $e) {
+ // provided JWT signature verification failed.
+} catch (BeforeValidException $e) {
+ // provided JWT is trying to be used before "nbf" claim OR
+ // provided JWT is trying to be used before "iat" claim.
+} catch (ExpiredException $e) {
+ // provided JWT is trying to be used after "exp" claim.
+} catch (UnexpectedValueException $e) {
+ // provided JWT is malformed OR
+ // provided JWT is missing an algorithm / using an unsupported algorithm OR
+ // provided JWT algorithm does not match provided key OR
+ // provided key ID in key/key-array is empty or invalid.
+}
+```
+
+All exceptions in the `Firebase\JWT` namespace extend `UnexpectedValueException`, and can be simplified
+like this:
+
+```php
+try {
+ $decoded = JWT::decode($payload, $keys);
+} catch (LogicException $e) {
+ // errors having to do with environmental setup or malformed JWT Keys
+} catch (UnexpectedValueException $e) {
+ // errors having to do with JWT signature and claims
+}
+```
+
+#### Casting to array
+
+The return value of `JWT::decode` is the generic PHP object `stdClass`. If you'd like to handle with arrays
+instead, you can do the following:
+
+```php
+// return type is stdClass
+$decoded = JWT::decode($payload, $keys);
+
+// cast to array
+$decoded = json_decode(json_encode($decoded), true);
+```
+
+Tests
+-----
+Run the tests using phpunit:
+
+```bash
+$ pear install PHPUnit
+$ phpunit --configuration phpunit.xml.dist
+PHPUnit 3.7.10 by Sebastian Bergmann.
+.....
+Time: 0 seconds, Memory: 2.50Mb
+OK (5 tests, 5 assertions)
+```
+
+New Lines in private keys
+-----
+
+If your private key contains `\n` characters, be sure to wrap it in double quotes `""`
+and not single quotes `''` in order to properly interpret the escaped characters.
+
+License
+-------
+[3-Clause BSD](http://opensource.org/licenses/BSD-3-Clause).
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/composer.json
new file mode 100644
index 0000000..e23dfe3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/composer.json
@@ -0,0 +1,42 @@
+{
+ "name": "firebase/php-jwt",
+ "description": "A simple library to encode and decode JSON Web Tokens (JWT) in PHP. Should conform to the current spec.",
+ "homepage": "https://github.com/firebase/php-jwt",
+ "keywords": [
+ "php",
+ "jwt"
+ ],
+ "authors": [
+ {
+ "name": "Neuman Vong",
+ "email": "neuman+pear@twilio.com",
+ "role": "Developer"
+ },
+ {
+ "name": "Anant Narayanan",
+ "email": "anant@php.net",
+ "role": "Developer"
+ }
+ ],
+ "license": "BSD-3-Clause",
+ "require": {
+ "php": "^7.4||^8.0"
+ },
+ "suggest": {
+ "paragonie/sodium_compat": "Support EdDSA (Ed25519) signatures when libsodium is not present",
+ "ext-sodium": "Support EdDSA (Ed25519) signatures"
+ },
+ "autoload": {
+ "psr-4": {
+ "Firebase\\JWT\\": "src"
+ }
+ },
+ "require-dev": {
+ "guzzlehttp/guzzle": "^6.5||^7.4",
+ "phpspec/prophecy-phpunit": "^2.0",
+ "phpunit/phpunit": "^9.5",
+ "psr/cache": "^1.0||^2.0",
+ "psr/http-client": "^1.0",
+ "psr/http-factory": "^1.0"
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/BeforeValidException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/BeforeValidException.php
new file mode 100644
index 0000000..c147852
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/BeforeValidException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace Firebase\JWT;
+
+class BeforeValidException extends \UnexpectedValueException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/CachedKeySet.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/CachedKeySet.php
new file mode 100644
index 0000000..baf801f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/CachedKeySet.php
@@ -0,0 +1,258 @@
+<?php
+
+namespace Firebase\JWT;
+
+use ArrayAccess;
+use InvalidArgumentException;
+use LogicException;
+use OutOfBoundsException;
+use Psr\Cache\CacheItemInterface;
+use Psr\Cache\CacheItemPoolInterface;
+use Psr\Http\Client\ClientInterface;
+use Psr\Http\Message\RequestFactoryInterface;
+use RuntimeException;
+use UnexpectedValueException;
+
+/**
+ * @implements ArrayAccess<string, Key>
+ */
+class CachedKeySet implements ArrayAccess
+{
+ /**
+ * @var string
+ */
+ private $jwksUri;
+ /**
+ * @var ClientInterface
+ */
+ private $httpClient;
+ /**
+ * @var RequestFactoryInterface
+ */
+ private $httpFactory;
+ /**
+ * @var CacheItemPoolInterface
+ */
+ private $cache;
+ /**
+ * @var ?int
+ */
+ private $expiresAfter;
+ /**
+ * @var ?CacheItemInterface
+ */
+ private $cacheItem;
+ /**
+ * @var array<string, array<mixed>>
+ */
+ private $keySet;
+ /**
+ * @var string
+ */
+ private $cacheKey;
+ /**
+ * @var string
+ */
+ private $cacheKeyPrefix = 'jwks';
+ /**
+ * @var int
+ */
+ private $maxKeyLength = 64;
+ /**
+ * @var bool
+ */
+ private $rateLimit;
+ /**
+ * @var string
+ */
+ private $rateLimitCacheKey;
+ /**
+ * @var int
+ */
+ private $maxCallsPerMinute = 10;
+ /**
+ * @var string|null
+ */
+ private $defaultAlg;
+
+ public function __construct(
+ string $jwksUri,
+ ClientInterface $httpClient,
+ RequestFactoryInterface $httpFactory,
+ CacheItemPoolInterface $cache,
+ int $expiresAfter = null,
+ bool $rateLimit = false,
+ string $defaultAlg = null
+ ) {
+ $this->jwksUri = $jwksUri;
+ $this->httpClient = $httpClient;
+ $this->httpFactory = $httpFactory;
+ $this->cache = $cache;
+ $this->expiresAfter = $expiresAfter;
+ $this->rateLimit = $rateLimit;
+ $this->defaultAlg = $defaultAlg;
+ $this->setCacheKeys();
+ }
+
+ /**
+ * @param string $keyId
+ * @return Key
+ */
+ public function offsetGet($keyId): Key
+ {
+ if (!$this->keyIdExists($keyId)) {
+ throw new OutOfBoundsException('Key ID not found');
+ }
+ return JWK::parseKey($this->keySet[$keyId], $this->defaultAlg);
+ }
+
+ /**
+ * @param string $keyId
+ * @return bool
+ */
+ public function offsetExists($keyId): bool
+ {
+ return $this->keyIdExists($keyId);
+ }
+
+ /**
+ * @param string $offset
+ * @param Key $value
+ */
+ public function offsetSet($offset, $value): void
+ {
+ throw new LogicException('Method not implemented');
+ }
+
+ /**
+ * @param string $offset
+ */
+ public function offsetUnset($offset): void
+ {
+ throw new LogicException('Method not implemented');
+ }
+
+ /**
+ * @return array<mixed>
+ */
+ private function formatJwksForCache(string $jwks): array
+ {
+ $jwks = json_decode($jwks, true);
+
+ if (!isset($jwks['keys'])) {
+ throw new UnexpectedValueException('"keys" member must exist in the JWK Set');
+ }
+
+ if (empty($jwks['keys'])) {
+ throw new InvalidArgumentException('JWK Set did not contain any keys');
+ }
+
+ $keys = [];
+ foreach ($jwks['keys'] as $k => $v) {
+ $kid = isset($v['kid']) ? $v['kid'] : $k;
+ $keys[(string) $kid] = $v;
+ }
+
+ return $keys;
+ }
+
+ private function keyIdExists(string $keyId): bool
+ {
+ if (null === $this->keySet) {
+ $item = $this->getCacheItem();
+ // Try to load keys from cache
+ if ($item->isHit()) {
+ // item found! retrieve it
+ $this->keySet = $item->get();
+ // If the cached item is a string, the JWKS response was cached (previous behavior).
+ // Parse this into expected format array<kid, jwk> instead.
+ if (\is_string($this->keySet)) {
+ $this->keySet = $this->formatJwksForCache($this->keySet);
+ }
+ }
+ }
+
+ if (!isset($this->keySet[$keyId])) {
+ if ($this->rateLimitExceeded()) {
+ return false;
+ }
+ $request = $this->httpFactory->createRequest('GET', $this->jwksUri);
+ $jwksResponse = $this->httpClient->sendRequest($request);
+ $this->keySet = $this->formatJwksForCache((string) $jwksResponse->getBody());
+
+ if (!isset($this->keySet[$keyId])) {
+ return false;
+ }
+
+ $item = $this->getCacheItem();
+ $item->set($this->keySet);
+ if ($this->expiresAfter) {
+ $item->expiresAfter($this->expiresAfter);
+ }
+ $this->cache->save($item);
+ }
+
+ return true;
+ }
+
+ private function rateLimitExceeded(): bool
+ {
+ if (!$this->rateLimit) {
+ return false;
+ }
+
+ $cacheItem = $this->cache->getItem($this->rateLimitCacheKey);
+ if (!$cacheItem->isHit()) {
+ $cacheItem->expiresAfter(1); // # of calls are cached each minute
+ }
+
+ $callsPerMinute = (int) $cacheItem->get();
+ if (++$callsPerMinute > $this->maxCallsPerMinute) {
+ return true;
+ }
+ $cacheItem->set($callsPerMinute);
+ $this->cache->save($cacheItem);
+ return false;
+ }
+
+ private function getCacheItem(): CacheItemInterface
+ {
+ if (\is_null($this->cacheItem)) {
+ $this->cacheItem = $this->cache->getItem($this->cacheKey);
+ }
+
+ return $this->cacheItem;
+ }
+
+ private function setCacheKeys(): void
+ {
+ if (empty($this->jwksUri)) {
+ throw new RuntimeException('JWKS URI is empty');
+ }
+
+ // ensure we do not have illegal characters
+ $key = preg_replace('|[^a-zA-Z0-9_\.!]|', '', $this->jwksUri);
+
+ // add prefix
+ $key = $this->cacheKeyPrefix . $key;
+
+ // Hash keys if they exceed $maxKeyLength of 64
+ if (\strlen($key) > $this->maxKeyLength) {
+ $key = substr(hash('sha256', $key), 0, $this->maxKeyLength);
+ }
+
+ $this->cacheKey = $key;
+
+ if ($this->rateLimit) {
+ // add prefix
+ $rateLimitKey = $this->cacheKeyPrefix . 'ratelimit' . $key;
+
+ // Hash keys if they exceed $maxKeyLength of 64
+ if (\strlen($rateLimitKey) > $this->maxKeyLength) {
+ $rateLimitKey = substr(hash('sha256', $rateLimitKey), 0, $this->maxKeyLength);
+ }
+
+ $this->rateLimitCacheKey = $rateLimitKey;
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/ExpiredException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/ExpiredException.php
new file mode 100644
index 0000000..81ba52d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/ExpiredException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace Firebase\JWT;
+
+class ExpiredException extends \UnexpectedValueException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/JWK.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/JWK.php
new file mode 100644
index 0000000..c7eff8a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/JWK.php
@@ -0,0 +1,323 @@
+<?php
+
+namespace Firebase\JWT;
+
+use DomainException;
+use InvalidArgumentException;
+use UnexpectedValueException;
+
+/**
+ * JSON Web Key implementation, based on this spec:
+ * https://tools.ietf.org/html/draft-ietf-jose-json-web-key-41
+ *
+ * PHP version 5
+ *
+ * @category Authentication
+ * @package Authentication_JWT
+ * @author Bui Sy Nguyen <nguyenbs@gmail.com>
+ * @license http://opensource.org/licenses/BSD-3-Clause 3-clause BSD
+ * @link https://github.com/firebase/php-jwt
+ */
+class JWK
+{
+ private const OID = '1.2.840.10045.2.1';
+ private const ASN1_OBJECT_IDENTIFIER = 0x06;
+ private const ASN1_SEQUENCE = 0x10; // also defined in JWT
+ private const ASN1_BIT_STRING = 0x03;
+ private const EC_CURVES = [
+ 'P-256' => '1.2.840.10045.3.1.7', // Len: 64
+ 'secp256k1' => '1.3.132.0.10', // Len: 64
+ // 'P-384' => '1.3.132.0.34', // Len: 96 (not yet supported)
+ // 'P-521' => '1.3.132.0.35', // Len: 132 (not supported)
+ ];
+
+ /**
+ * Parse a set of JWK keys
+ *
+ * @param array<mixed> $jwks The JSON Web Key Set as an associative array
+ * @param string $defaultAlg The algorithm for the Key object if "alg" is not set in the
+ * JSON Web Key Set
+ *
+ * @return array<string, Key> An associative array of key IDs (kid) to Key objects
+ *
+ * @throws InvalidArgumentException Provided JWK Set is empty
+ * @throws UnexpectedValueException Provided JWK Set was invalid
+ * @throws DomainException OpenSSL failure
+ *
+ * @uses parseKey
+ */
+ public static function parseKeySet(array $jwks, string $defaultAlg = null): array
+ {
+ $keys = [];
+
+ if (!isset($jwks['keys'])) {
+ throw new UnexpectedValueException('"keys" member must exist in the JWK Set');
+ }
+
+ if (empty($jwks['keys'])) {
+ throw new InvalidArgumentException('JWK Set did not contain any keys');
+ }
+
+ foreach ($jwks['keys'] as $k => $v) {
+ $kid = isset($v['kid']) ? $v['kid'] : $k;
+ if ($key = self::parseKey($v, $defaultAlg)) {
+ $keys[(string) $kid] = $key;
+ }
+ }
+
+ if (0 === \count($keys)) {
+ throw new UnexpectedValueException('No supported algorithms found in JWK Set');
+ }
+
+ return $keys;
+ }
+
+ /**
+ * Parse a JWK key
+ *
+ * @param array<mixed> $jwk An individual JWK
+ * @param string $defaultAlg The algorithm for the Key object if "alg" is not set in the
+ * JSON Web Key Set
+ *
+ * @return Key The key object for the JWK
+ *
+ * @throws InvalidArgumentException Provided JWK is empty
+ * @throws UnexpectedValueException Provided JWK was invalid
+ * @throws DomainException OpenSSL failure
+ *
+ * @uses createPemFromModulusAndExponent
+ */
+ public static function parseKey(array $jwk, string $defaultAlg = null): ?Key
+ {
+ if (empty($jwk)) {
+ throw new InvalidArgumentException('JWK must not be empty');
+ }
+
+ if (!isset($jwk['kty'])) {
+ throw new UnexpectedValueException('JWK must contain a "kty" parameter');
+ }
+
+ if (!isset($jwk['alg'])) {
+ if (\is_null($defaultAlg)) {
+ // The "alg" parameter is optional in a KTY, but an algorithm is required
+ // for parsing in this library. Use the $defaultAlg parameter when parsing the
+ // key set in order to prevent this error.
+ // @see https://datatracker.ietf.org/doc/html/rfc7517#section-4.4
+ throw new UnexpectedValueException('JWK must contain an "alg" parameter');
+ }
+ $jwk['alg'] = $defaultAlg;
+ }
+
+ switch ($jwk['kty']) {
+ case 'RSA':
+ if (!empty($jwk['d'])) {
+ throw new UnexpectedValueException('RSA private keys are not supported');
+ }
+ if (!isset($jwk['n']) || !isset($jwk['e'])) {
+ throw new UnexpectedValueException('RSA keys must contain values for both "n" and "e"');
+ }
+
+ $pem = self::createPemFromModulusAndExponent($jwk['n'], $jwk['e']);
+ $publicKey = \openssl_pkey_get_public($pem);
+ if (false === $publicKey) {
+ throw new DomainException(
+ 'OpenSSL error: ' . \openssl_error_string()
+ );
+ }
+ return new Key($publicKey, $jwk['alg']);
+ case 'EC':
+ if (isset($jwk['d'])) {
+ // The key is actually a private key
+ throw new UnexpectedValueException('Key data must be for a public key');
+ }
+
+ if (empty($jwk['crv'])) {
+ throw new UnexpectedValueException('crv not set');
+ }
+
+ if (!isset(self::EC_CURVES[$jwk['crv']])) {
+ throw new DomainException('Unrecognised or unsupported EC curve');
+ }
+
+ if (empty($jwk['x']) || empty($jwk['y'])) {
+ throw new UnexpectedValueException('x and y not set');
+ }
+
+ $publicKey = self::createPemFromCrvAndXYCoordinates($jwk['crv'], $jwk['x'], $jwk['y']);
+ return new Key($publicKey, $jwk['alg']);
+ default:
+ // Currently only RSA is supported
+ break;
+ }
+
+ return null;
+ }
+
+ /**
+ * Converts the EC JWK values to pem format.
+ *
+ * @param string $crv The EC curve (only P-256 is supported)
+ * @param string $x The EC x-coordinate
+ * @param string $y The EC y-coordinate
+ *
+ * @return string
+ */
+ private static function createPemFromCrvAndXYCoordinates(string $crv, string $x, string $y): string
+ {
+ $pem =
+ self::encodeDER(
+ self::ASN1_SEQUENCE,
+ self::encodeDER(
+ self::ASN1_SEQUENCE,
+ self::encodeDER(
+ self::ASN1_OBJECT_IDENTIFIER,
+ self::encodeOID(self::OID)
+ )
+ . self::encodeDER(
+ self::ASN1_OBJECT_IDENTIFIER,
+ self::encodeOID(self::EC_CURVES[$crv])
+ )
+ ) .
+ self::encodeDER(
+ self::ASN1_BIT_STRING,
+ \chr(0x00) . \chr(0x04)
+ . JWT::urlsafeB64Decode($x)
+ . JWT::urlsafeB64Decode($y)
+ )
+ );
+
+ return sprintf(
+ "-----BEGIN PUBLIC KEY-----\n%s\n-----END PUBLIC KEY-----\n",
+ wordwrap(base64_encode($pem), 64, "\n", true)
+ );
+ }
+
+ /**
+ * Create a public key represented in PEM format from RSA modulus and exponent information
+ *
+ * @param string $n The RSA modulus encoded in Base64
+ * @param string $e The RSA exponent encoded in Base64
+ *
+ * @return string The RSA public key represented in PEM format
+ *
+ * @uses encodeLength
+ */
+ private static function createPemFromModulusAndExponent(
+ string $n,
+ string $e
+ ): string {
+ $mod = JWT::urlsafeB64Decode($n);
+ $exp = JWT::urlsafeB64Decode($e);
+
+ $modulus = \pack('Ca*a*', 2, self::encodeLength(\strlen($mod)), $mod);
+ $publicExponent = \pack('Ca*a*', 2, self::encodeLength(\strlen($exp)), $exp);
+
+ $rsaPublicKey = \pack(
+ 'Ca*a*a*',
+ 48,
+ self::encodeLength(\strlen($modulus) + \strlen($publicExponent)),
+ $modulus,
+ $publicExponent
+ );
+
+ // sequence(oid(1.2.840.113549.1.1.1), null)) = rsaEncryption.
+ $rsaOID = \pack('H*', '300d06092a864886f70d0101010500'); // hex version of MA0GCSqGSIb3DQEBAQUA
+ $rsaPublicKey = \chr(0) . $rsaPublicKey;
+ $rsaPublicKey = \chr(3) . self::encodeLength(\strlen($rsaPublicKey)) . $rsaPublicKey;
+
+ $rsaPublicKey = \pack(
+ 'Ca*a*',
+ 48,
+ self::encodeLength(\strlen($rsaOID . $rsaPublicKey)),
+ $rsaOID . $rsaPublicKey
+ );
+
+ return "-----BEGIN PUBLIC KEY-----\r\n" .
+ \chunk_split(\base64_encode($rsaPublicKey), 64) .
+ '-----END PUBLIC KEY-----';
+ }
+
+ /**
+ * DER-encode the length
+ *
+ * DER supports lengths up to (2**8)**127, however, we'll only support lengths up to (2**8)**4. See
+ * {@link http://itu.int/ITU-T/studygroups/com17/languages/X.690-0207.pdf#p=13 X.690 paragraph 8.1.3} for more information.
+ *
+ * @param int $length
+ * @return string
+ */
+ private static function encodeLength(int $length): string
+ {
+ if ($length <= 0x7F) {
+ return \chr($length);
+ }
+
+ $temp = \ltrim(\pack('N', $length), \chr(0));
+
+ return \pack('Ca*', 0x80 | \strlen($temp), $temp);
+ }
+
+ /**
+ * Encodes a value into a DER object.
+ * Also defined in Firebase\JWT\JWT
+ *
+ * @param int $type DER tag
+ * @param string $value the value to encode
+ * @return string the encoded object
+ */
+ private static function encodeDER(int $type, string $value): string
+ {
+ $tag_header = 0;
+ if ($type === self::ASN1_SEQUENCE) {
+ $tag_header |= 0x20;
+ }
+
+ // Type
+ $der = \chr($tag_header | $type);
+
+ // Length
+ $der .= \chr(\strlen($value));
+
+ return $der . $value;
+ }
+
+ /**
+ * Encodes a string into a DER-encoded OID.
+ *
+ * @param string $oid the OID string
+ * @return string the binary DER-encoded OID
+ */
+ private static function encodeOID(string $oid): string
+ {
+ $octets = explode('.', $oid);
+
+ // Get the first octet
+ $first = (int) array_shift($octets);
+ $second = (int) array_shift($octets);
+ $oid = \chr($first * 40 + $second);
+
+ // Iterate over subsequent octets
+ foreach ($octets as $octet) {
+ if ($octet == 0) {
+ $oid .= \chr(0x00);
+ continue;
+ }
+ $bin = '';
+
+ while ($octet) {
+ $bin .= \chr(0x80 | ($octet & 0x7f));
+ $octet >>= 7;
+ }
+ $bin[0] = $bin[0] & \chr(0x7f);
+
+ // Convert to big endian if necessary
+ if (pack('V', 65534) == pack('L', 65534)) {
+ $oid .= strrev($bin);
+ } else {
+ $oid .= $bin;
+ }
+ }
+
+ return $oid;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/JWT.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/JWT.php
new file mode 100644
index 0000000..c83ff09
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/JWT.php
@@ -0,0 +1,642 @@
+<?php
+
+namespace Firebase\JWT;
+
+use ArrayAccess;
+use DateTime;
+use DomainException;
+use Exception;
+use InvalidArgumentException;
+use OpenSSLAsymmetricKey;
+use OpenSSLCertificate;
+use stdClass;
+use UnexpectedValueException;
+
+/**
+ * JSON Web Token implementation, based on this spec:
+ * https://tools.ietf.org/html/rfc7519
+ *
+ * PHP version 5
+ *
+ * @category Authentication
+ * @package Authentication_JWT
+ * @author Neuman Vong <neuman@twilio.com>
+ * @author Anant Narayanan <anant@php.net>
+ * @license http://opensource.org/licenses/BSD-3-Clause 3-clause BSD
+ * @link https://github.com/firebase/php-jwt
+ */
+class JWT
+{
+ private const ASN1_INTEGER = 0x02;
+ private const ASN1_SEQUENCE = 0x10;
+ private const ASN1_BIT_STRING = 0x03;
+
+ /**
+ * When checking nbf, iat or expiration times,
+ * we want to provide some extra leeway time to
+ * account for clock skew.
+ *
+ * @var int
+ */
+ public static $leeway = 0;
+
+ /**
+ * Allow the current timestamp to be specified.
+ * Useful for fixing a value within unit testing.
+ * Will default to PHP time() value if null.
+ *
+ * @var ?int
+ */
+ public static $timestamp = null;
+
+ /**
+ * @var array<string, string[]>
+ */
+ public static $supported_algs = [
+ 'ES384' => ['openssl', 'SHA384'],
+ 'ES256' => ['openssl', 'SHA256'],
+ 'ES256K' => ['openssl', 'SHA256'],
+ 'HS256' => ['hash_hmac', 'SHA256'],
+ 'HS384' => ['hash_hmac', 'SHA384'],
+ 'HS512' => ['hash_hmac', 'SHA512'],
+ 'RS256' => ['openssl', 'SHA256'],
+ 'RS384' => ['openssl', 'SHA384'],
+ 'RS512' => ['openssl', 'SHA512'],
+ 'EdDSA' => ['sodium_crypto', 'EdDSA'],
+ ];
+
+ /**
+ * Decodes a JWT string into a PHP object.
+ *
+ * @param string $jwt The JWT
+ * @param Key|ArrayAccess<string,Key>|array<string,Key> $keyOrKeyArray The Key or associative array of key IDs
+ * (kid) to Key objects.
+ * If the algorithm used is asymmetric, this is
+ * the public key.
+ * Each Key object contains an algorithm and
+ * matching key.
+ * Supported algorithms are 'ES384','ES256',
+ * 'HS256', 'HS384', 'HS512', 'RS256', 'RS384'
+ * and 'RS512'.
+ *
+ * @return stdClass The JWT's payload as a PHP object
+ *
+ * @throws InvalidArgumentException Provided key/key-array was empty or malformed
+ * @throws DomainException Provided JWT is malformed
+ * @throws UnexpectedValueException Provided JWT was invalid
+ * @throws SignatureInvalidException Provided JWT was invalid because the signature verification failed
+ * @throws BeforeValidException Provided JWT is trying to be used before it's eligible as defined by 'nbf'
+ * @throws BeforeValidException Provided JWT is trying to be used before it's been created as defined by 'iat'
+ * @throws ExpiredException Provided JWT has since expired, as defined by the 'exp' claim
+ *
+ * @uses jsonDecode
+ * @uses urlsafeB64Decode
+ */
+ public static function decode(
+ string $jwt,
+ $keyOrKeyArray
+ ): stdClass {
+ // Validate JWT
+ $timestamp = \is_null(static::$timestamp) ? \time() : static::$timestamp;
+
+ if (empty($keyOrKeyArray)) {
+ throw new InvalidArgumentException('Key may not be empty');
+ }
+ $tks = \explode('.', $jwt);
+ if (\count($tks) !== 3) {
+ throw new UnexpectedValueException('Wrong number of segments');
+ }
+ list($headb64, $bodyb64, $cryptob64) = $tks;
+ $headerRaw = static::urlsafeB64Decode($headb64);
+ if (null === ($header = static::jsonDecode($headerRaw))) {
+ throw new UnexpectedValueException('Invalid header encoding');
+ }
+ $payloadRaw = static::urlsafeB64Decode($bodyb64);
+ if (null === ($payload = static::jsonDecode($payloadRaw))) {
+ throw new UnexpectedValueException('Invalid claims encoding');
+ }
+ if (\is_array($payload)) {
+ // prevent PHP Fatal Error in edge-cases when payload is empty array
+ $payload = (object) $payload;
+ }
+ if (!$payload instanceof stdClass) {
+ throw new UnexpectedValueException('Payload must be a JSON object');
+ }
+ $sig = static::urlsafeB64Decode($cryptob64);
+ if (empty($header->alg)) {
+ throw new UnexpectedValueException('Empty algorithm');
+ }
+ if (empty(static::$supported_algs[$header->alg])) {
+ throw new UnexpectedValueException('Algorithm not supported');
+ }
+
+ $key = self::getKey($keyOrKeyArray, property_exists($header, 'kid') ? $header->kid : null);
+
+ // Check the algorithm
+ if (!self::constantTimeEquals($key->getAlgorithm(), $header->alg)) {
+ // See issue #351
+ throw new UnexpectedValueException('Incorrect key for this algorithm');
+ }
+ if (\in_array($header->alg, ['ES256', 'ES256K', 'ES384'], true)) {
+ // OpenSSL expects an ASN.1 DER sequence for ES256/ES256K/ES384 signatures
+ $sig = self::signatureToDER($sig);
+ }
+ if (!self::verify("{$headb64}.{$bodyb64}", $sig, $key->getKeyMaterial(), $header->alg)) {
+ throw new SignatureInvalidException('Signature verification failed');
+ }
+
+ // Check the nbf if it is defined. This is the time that the
+ // token can actually be used. If it's not yet that time, abort.
+ if (isset($payload->nbf) && $payload->nbf > ($timestamp + static::$leeway)) {
+ throw new BeforeValidException(
+ 'Cannot handle token prior to ' . \date(DateTime::ISO8601, $payload->nbf)
+ );
+ }
+
+ // Check that this token has been created before 'now'. This prevents
+ // using tokens that have been created for later use (and haven't
+ // correctly used the nbf claim).
+ if (isset($payload->iat) && $payload->iat > ($timestamp + static::$leeway)) {
+ throw new BeforeValidException(
+ 'Cannot handle token prior to ' . \date(DateTime::ISO8601, $payload->iat)
+ );
+ }
+
+ // Check if this token has expired.
+ if (isset($payload->exp) && ($timestamp - static::$leeway) >= $payload->exp) {
+ throw new ExpiredException('Expired token');
+ }
+
+ return $payload;
+ }
+
+ /**
+ * Converts and signs a PHP array into a JWT string.
+ *
+ * @param array<mixed> $payload PHP array
+ * @param string|resource|OpenSSLAsymmetricKey|OpenSSLCertificate $key The secret key.
+ * @param string $alg Supported algorithms are 'ES384','ES256', 'ES256K', 'HS256',
+ * 'HS384', 'HS512', 'RS256', 'RS384', and 'RS512'
+ * @param string $keyId
+ * @param array<string, string> $head An array with header elements to attach
+ *
+ * @return string A signed JWT
+ *
+ * @uses jsonEncode
+ * @uses urlsafeB64Encode
+ */
+ public static function encode(
+ array $payload,
+ $key,
+ string $alg,
+ string $keyId = null,
+ array $head = null
+ ): string {
+ $header = ['typ' => 'JWT', 'alg' => $alg];
+ if ($keyId !== null) {
+ $header['kid'] = $keyId;
+ }
+ if (isset($head) && \is_array($head)) {
+ $header = \array_merge($head, $header);
+ }
+ $segments = [];
+ $segments[] = static::urlsafeB64Encode((string) static::jsonEncode($header));
+ $segments[] = static::urlsafeB64Encode((string) static::jsonEncode($payload));
+ $signing_input = \implode('.', $segments);
+
+ $signature = static::sign($signing_input, $key, $alg);
+ $segments[] = static::urlsafeB64Encode($signature);
+
+ return \implode('.', $segments);
+ }
+
+ /**
+ * Sign a string with a given key and algorithm.
+ *
+ * @param string $msg The message to sign
+ * @param string|resource|OpenSSLAsymmetricKey|OpenSSLCertificate $key The secret key.
+ * @param string $alg Supported algorithms are 'ES384','ES256', 'ES256K', 'HS256',
+ * 'HS384', 'HS512', 'RS256', 'RS384', and 'RS512'
+ *
+ * @return string An encrypted message
+ *
+ * @throws DomainException Unsupported algorithm or bad key was specified
+ */
+ public static function sign(
+ string $msg,
+ $key,
+ string $alg
+ ): string {
+ if (empty(static::$supported_algs[$alg])) {
+ throw new DomainException('Algorithm not supported');
+ }
+ list($function, $algorithm) = static::$supported_algs[$alg];
+ switch ($function) {
+ case 'hash_hmac':
+ if (!\is_string($key)) {
+ throw new InvalidArgumentException('key must be a string when using hmac');
+ }
+ return \hash_hmac($algorithm, $msg, $key, true);
+ case 'openssl':
+ $signature = '';
+ $success = \openssl_sign($msg, $signature, $key, $algorithm); // @phpstan-ignore-line
+ if (!$success) {
+ throw new DomainException('OpenSSL unable to sign data');
+ }
+ if ($alg === 'ES256' || $alg === 'ES256K') {
+ $signature = self::signatureFromDER($signature, 256);
+ } elseif ($alg === 'ES384') {
+ $signature = self::signatureFromDER($signature, 384);
+ }
+ return $signature;
+ case 'sodium_crypto':
+ if (!\function_exists('sodium_crypto_sign_detached')) {
+ throw new DomainException('libsodium is not available');
+ }
+ if (!\is_string($key)) {
+ throw new InvalidArgumentException('key must be a string when using EdDSA');
+ }
+ try {
+ // The last non-empty line is used as the key.
+ $lines = array_filter(explode("\n", $key));
+ $key = base64_decode((string) end($lines));
+ if (\strlen($key) === 0) {
+ throw new DomainException('Key cannot be empty string');
+ }
+ return sodium_crypto_sign_detached($msg, $key);
+ } catch (Exception $e) {
+ throw new DomainException($e->getMessage(), 0, $e);
+ }
+ }
+
+ throw new DomainException('Algorithm not supported');
+ }
+
+ /**
+ * Verify a signature with the message, key and method. Not all methods
+ * are symmetric, so we must have a separate verify and sign method.
+ *
+ * @param string $msg The original message (header and body)
+ * @param string $signature The original signature
+ * @param string|resource|OpenSSLAsymmetricKey|OpenSSLCertificate $keyMaterial For HS*, a string key works. for RS*, must be an instance of OpenSSLAsymmetricKey
+ * @param string $alg The algorithm
+ *
+ * @return bool
+ *
+ * @throws DomainException Invalid Algorithm, bad key, or OpenSSL failure
+ */
+ private static function verify(
+ string $msg,
+ string $signature,
+ $keyMaterial,
+ string $alg
+ ): bool {
+ if (empty(static::$supported_algs[$alg])) {
+ throw new DomainException('Algorithm not supported');
+ }
+
+ list($function, $algorithm) = static::$supported_algs[$alg];
+ switch ($function) {
+ case 'openssl':
+ $success = \openssl_verify($msg, $signature, $keyMaterial, $algorithm); // @phpstan-ignore-line
+ if ($success === 1) {
+ return true;
+ }
+ if ($success === 0) {
+ return false;
+ }
+ // returns 1 on success, 0 on failure, -1 on error.
+ throw new DomainException(
+ 'OpenSSL error: ' . \openssl_error_string()
+ );
+ case 'sodium_crypto':
+ if (!\function_exists('sodium_crypto_sign_verify_detached')) {
+ throw new DomainException('libsodium is not available');
+ }
+ if (!\is_string($keyMaterial)) {
+ throw new InvalidArgumentException('key must be a string when using EdDSA');
+ }
+ try {
+ // The last non-empty line is used as the key.
+ $lines = array_filter(explode("\n", $keyMaterial));
+ $key = base64_decode((string) end($lines));
+ if (\strlen($key) === 0) {
+ throw new DomainException('Key cannot be empty string');
+ }
+ if (\strlen($signature) === 0) {
+ throw new DomainException('Signature cannot be empty string');
+ }
+ return sodium_crypto_sign_verify_detached($signature, $msg, $key);
+ } catch (Exception $e) {
+ throw new DomainException($e->getMessage(), 0, $e);
+ }
+ case 'hash_hmac':
+ default:
+ if (!\is_string($keyMaterial)) {
+ throw new InvalidArgumentException('key must be a string when using hmac');
+ }
+ $hash = \hash_hmac($algorithm, $msg, $keyMaterial, true);
+ return self::constantTimeEquals($hash, $signature);
+ }
+ }
+
+ /**
+ * Decode a JSON string into a PHP object.
+ *
+ * @param string $input JSON string
+ *
+ * @return mixed The decoded JSON string
+ *
+ * @throws DomainException Provided string was invalid JSON
+ */
+ public static function jsonDecode(string $input)
+ {
+ $obj = \json_decode($input, false, 512, JSON_BIGINT_AS_STRING);
+
+ if ($errno = \json_last_error()) {
+ self::handleJsonError($errno);
+ } elseif ($obj === null && $input !== 'null') {
+ throw new DomainException('Null result with non-null input');
+ }
+ return $obj;
+ }
+
+ /**
+ * Encode a PHP array into a JSON string.
+ *
+ * @param array<mixed> $input A PHP array
+ *
+ * @return string JSON representation of the PHP array
+ *
+ * @throws DomainException Provided object could not be encoded to valid JSON
+ */
+ public static function jsonEncode(array $input): string
+ {
+ if (PHP_VERSION_ID >= 50400) {
+ $json = \json_encode($input, \JSON_UNESCAPED_SLASHES);
+ } else {
+ // PHP 5.3 only
+ $json = \json_encode($input);
+ }
+ if ($errno = \json_last_error()) {
+ self::handleJsonError($errno);
+ } elseif ($json === 'null') {
+ throw new DomainException('Null result with non-null input');
+ }
+ if ($json === false) {
+ throw new DomainException('Provided object could not be encoded to valid JSON');
+ }
+ return $json;
+ }
+
+ /**
+ * Decode a string with URL-safe Base64.
+ *
+ * @param string $input A Base64 encoded string
+ *
+ * @return string A decoded string
+ *
+ * @throws InvalidArgumentException invalid base64 characters
+ */
+ public static function urlsafeB64Decode(string $input): string
+ {
+ $remainder = \strlen($input) % 4;
+ if ($remainder) {
+ $padlen = 4 - $remainder;
+ $input .= \str_repeat('=', $padlen);
+ }
+ return \base64_decode(\strtr($input, '-_', '+/'));
+ }
+
+ /**
+ * Encode a string with URL-safe Base64.
+ *
+ * @param string $input The string you want encoded
+ *
+ * @return string The base64 encode of what you passed in
+ */
+ public static function urlsafeB64Encode(string $input): string
+ {
+ return \str_replace('=', '', \strtr(\base64_encode($input), '+/', '-_'));
+ }
+
+
+ /**
+ * Determine if an algorithm has been provided for each Key
+ *
+ * @param Key|ArrayAccess<string,Key>|array<string,Key> $keyOrKeyArray
+ * @param string|null $kid
+ *
+ * @throws UnexpectedValueException
+ *
+ * @return Key
+ */
+ private static function getKey(
+ $keyOrKeyArray,
+ ?string $kid
+ ): Key {
+ if ($keyOrKeyArray instanceof Key) {
+ return $keyOrKeyArray;
+ }
+
+ if (empty($kid) && $kid !== '0') {
+ throw new UnexpectedValueException('"kid" empty, unable to lookup correct key');
+ }
+
+ if ($keyOrKeyArray instanceof CachedKeySet) {
+ // Skip "isset" check, as this will automatically refresh if not set
+ return $keyOrKeyArray[$kid];
+ }
+
+ if (!isset($keyOrKeyArray[$kid])) {
+ throw new UnexpectedValueException('"kid" invalid, unable to lookup correct key');
+ }
+
+ return $keyOrKeyArray[$kid];
+ }
+
+ /**
+ * @param string $left The string of known length to compare against
+ * @param string $right The user-supplied string
+ * @return bool
+ */
+ public static function constantTimeEquals(string $left, string $right): bool
+ {
+ if (\function_exists('hash_equals')) {
+ return \hash_equals($left, $right);
+ }
+ $len = \min(self::safeStrlen($left), self::safeStrlen($right));
+
+ $status = 0;
+ for ($i = 0; $i < $len; $i++) {
+ $status |= (\ord($left[$i]) ^ \ord($right[$i]));
+ }
+ $status |= (self::safeStrlen($left) ^ self::safeStrlen($right));
+
+ return ($status === 0);
+ }
+
+ /**
+ * Helper method to create a JSON error.
+ *
+ * @param int $errno An error number from json_last_error()
+ *
+ * @throws DomainException
+ *
+ * @return void
+ */
+ private static function handleJsonError(int $errno): void
+ {
+ $messages = [
+ JSON_ERROR_DEPTH => 'Maximum stack depth exceeded',
+ JSON_ERROR_STATE_MISMATCH => 'Invalid or malformed JSON',
+ JSON_ERROR_CTRL_CHAR => 'Unexpected control character found',
+ JSON_ERROR_SYNTAX => 'Syntax error, malformed JSON',
+ JSON_ERROR_UTF8 => 'Malformed UTF-8 characters' //PHP >= 5.3.3
+ ];
+ throw new DomainException(
+ isset($messages[$errno])
+ ? $messages[$errno]
+ : 'Unknown JSON error: ' . $errno
+ );
+ }
+
+ /**
+ * Get the number of bytes in cryptographic strings.
+ *
+ * @param string $str
+ *
+ * @return int
+ */
+ private static function safeStrlen(string $str): int
+ {
+ if (\function_exists('mb_strlen')) {
+ return \mb_strlen($str, '8bit');
+ }
+ return \strlen($str);
+ }
+
+ /**
+ * Convert an ECDSA signature to an ASN.1 DER sequence
+ *
+ * @param string $sig The ECDSA signature to convert
+ * @return string The encoded DER object
+ */
+ private static function signatureToDER(string $sig): string
+ {
+ // Separate the signature into r-value and s-value
+ $length = max(1, (int) (\strlen($sig) / 2));
+ list($r, $s) = \str_split($sig, $length);
+
+ // Trim leading zeros
+ $r = \ltrim($r, "\x00");
+ $s = \ltrim($s, "\x00");
+
+ // Convert r-value and s-value from unsigned big-endian integers to
+ // signed two's complement
+ if (\ord($r[0]) > 0x7f) {
+ $r = "\x00" . $r;
+ }
+ if (\ord($s[0]) > 0x7f) {
+ $s = "\x00" . $s;
+ }
+
+ return self::encodeDER(
+ self::ASN1_SEQUENCE,
+ self::encodeDER(self::ASN1_INTEGER, $r) .
+ self::encodeDER(self::ASN1_INTEGER, $s)
+ );
+ }
+
+ /**
+ * Encodes a value into a DER object.
+ *
+ * @param int $type DER tag
+ * @param string $value the value to encode
+ *
+ * @return string the encoded object
+ */
+ private static function encodeDER(int $type, string $value): string
+ {
+ $tag_header = 0;
+ if ($type === self::ASN1_SEQUENCE) {
+ $tag_header |= 0x20;
+ }
+
+ // Type
+ $der = \chr($tag_header | $type);
+
+ // Length
+ $der .= \chr(\strlen($value));
+
+ return $der . $value;
+ }
+
+ /**
+ * Encodes signature from a DER object.
+ *
+ * @param string $der binary signature in DER format
+ * @param int $keySize the number of bits in the key
+ *
+ * @return string the signature
+ */
+ private static function signatureFromDER(string $der, int $keySize): string
+ {
+ // OpenSSL returns the ECDSA signatures as a binary ASN.1 DER SEQUENCE
+ list($offset, $_) = self::readDER($der);
+ list($offset, $r) = self::readDER($der, $offset);
+ list($offset, $s) = self::readDER($der, $offset);
+
+ // Convert r-value and s-value from signed two's compliment to unsigned
+ // big-endian integers
+ $r = \ltrim($r, "\x00");
+ $s = \ltrim($s, "\x00");
+
+ // Pad out r and s so that they are $keySize bits long
+ $r = \str_pad($r, $keySize / 8, "\x00", STR_PAD_LEFT);
+ $s = \str_pad($s, $keySize / 8, "\x00", STR_PAD_LEFT);
+
+ return $r . $s;
+ }
+
+ /**
+ * Reads binary DER-encoded data and decodes into a single object
+ *
+ * @param string $der the binary data in DER format
+ * @param int $offset the offset of the data stream containing the object
+ * to decode
+ *
+ * @return array{int, string|null} the new offset and the decoded object
+ */
+ private static function readDER(string $der, int $offset = 0): array
+ {
+ $pos = $offset;
+ $size = \strlen($der);
+ $constructed = (\ord($der[$pos]) >> 5) & 0x01;
+ $type = \ord($der[$pos++]) & 0x1f;
+
+ // Length
+ $len = \ord($der[$pos++]);
+ if ($len & 0x80) {
+ $n = $len & 0x1f;
+ $len = 0;
+ while ($n-- && $pos < $size) {
+ $len = ($len << 8) | \ord($der[$pos++]);
+ }
+ }
+
+ // Value
+ if ($type === self::ASN1_BIT_STRING) {
+ $pos++; // Skip the first contents octet (padding indicator)
+ $data = \substr($der, $pos, $len - 1);
+ $pos += $len - 1;
+ } elseif (!$constructed) {
+ $data = \substr($der, $pos, $len);
+ $pos += $len;
+ } else {
+ $data = null;
+ }
+
+ return [$pos, $data];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/Key.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/Key.php
new file mode 100644
index 0000000..00cf7f2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/Key.php
@@ -0,0 +1,64 @@
+<?php
+
+namespace Firebase\JWT;
+
+use InvalidArgumentException;
+use OpenSSLAsymmetricKey;
+use OpenSSLCertificate;
+use TypeError;
+
+class Key
+{
+ /** @var string|resource|OpenSSLAsymmetricKey|OpenSSLCertificate */
+ private $keyMaterial;
+ /** @var string */
+ private $algorithm;
+
+ /**
+ * @param string|resource|OpenSSLAsymmetricKey|OpenSSLCertificate $keyMaterial
+ * @param string $algorithm
+ */
+ public function __construct(
+ $keyMaterial,
+ string $algorithm
+ ) {
+ if (
+ !\is_string($keyMaterial)
+ && !$keyMaterial instanceof OpenSSLAsymmetricKey
+ && !$keyMaterial instanceof OpenSSLCertificate
+ && !\is_resource($keyMaterial)
+ ) {
+ throw new TypeError('Key material must be a string, resource, or OpenSSLAsymmetricKey');
+ }
+
+ if (empty($keyMaterial)) {
+ throw new InvalidArgumentException('Key material must not be empty');
+ }
+
+ if (empty($algorithm)) {
+ throw new InvalidArgumentException('Algorithm must not be empty');
+ }
+
+ // TODO: Remove in PHP 8.0 in favor of class constructor property promotion
+ $this->keyMaterial = $keyMaterial;
+ $this->algorithm = $algorithm;
+ }
+
+ /**
+ * Return the algorithm valid for this key
+ *
+ * @return string
+ */
+ public function getAlgorithm(): string
+ {
+ return $this->algorithm;
+ }
+
+ /**
+ * @return string|resource|OpenSSLAsymmetricKey|OpenSSLCertificate
+ */
+ public function getKeyMaterial()
+ {
+ return $this->keyMaterial;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/SignatureInvalidException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/SignatureInvalidException.php
new file mode 100644
index 0000000..d35dee9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/firebase/php-jwt/src/SignatureInvalidException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace Firebase\JWT;
+
+class SignatureInvalidException extends \UnexpectedValueException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/CHANGELOG.md
new file mode 100644
index 0000000..12949ba
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/CHANGELOG.md
@@ -0,0 +1,1519 @@
+# Change Log
+
+Please refer to [UPGRADING](UPGRADING.md) guide for upgrading to a major version.
+
+## 7.5.0 - 2022-08-28
+
+### Added
+
+- Support PHP 8.2
+- Add request to delay closure params
+
+## 7.4.5 - 2022-06-20
+
+* Fix change in port should be considered a change in origin
+* Fix `CURLOPT_HTTPAUTH` option not cleared on change of origin
+
+## 7.4.4 - 2022-06-09
+
+* Fix failure to strip Authorization header on HTTP downgrade
+* Fix failure to strip the Cookie header on change in host or HTTP downgrade
+
+## 7.4.3 - 2022-05-25
+
+* Fix cross-domain cookie leakage
+
+## 7.4.2 - 2022-03-20
+
+### Fixed
+
+- Remove curl auth on cross-domain redirects to align with the Authorization HTTP header
+- Reject non-HTTP schemes in StreamHandler
+- Set a default ssl.peer_name context in StreamHandler to allow `force_ip_resolve`
+
+## 7.4.1 - 2021-12-06
+
+### Changed
+
+- Replaced implicit URI to string coercion [#2946](https://github.com/guzzle/guzzle/pull/2946)
+- Allow `symfony/deprecation-contracts` version 3 [#2961](https://github.com/guzzle/guzzle/pull/2961)
+
+### Fixed
+
+- Only close curl handle if it's done [#2950](https://github.com/guzzle/guzzle/pull/2950)
+
+## 7.4.0 - 2021-10-18
+
+### Added
+
+- Support PHP 8.1 [#2929](https://github.com/guzzle/guzzle/pull/2929), [#2939](https://github.com/guzzle/guzzle/pull/2939)
+- Support `psr/log` version 2 and 3 [#2943](https://github.com/guzzle/guzzle/pull/2943)
+
+### Fixed
+
+- Make sure we always call `restore_error_handler()` [#2915](https://github.com/guzzle/guzzle/pull/2915)
+- Fix progress parameter type compatibility between the cURL and stream handlers [#2936](https://github.com/guzzle/guzzle/pull/2936)
+- Throw `InvalidArgumentException` when an incorrect `headers` array is provided [#2916](https://github.com/guzzle/guzzle/pull/2916), [#2942](https://github.com/guzzle/guzzle/pull/2942)
+
+### Changed
+
+- Be more strict with types [#2914](https://github.com/guzzle/guzzle/pull/2914), [#2917](https://github.com/guzzle/guzzle/pull/2917), [#2919](https://github.com/guzzle/guzzle/pull/2919), [#2945](https://github.com/guzzle/guzzle/pull/2945)
+
+## 7.3.0 - 2021-03-23
+
+### Added
+
+- Support for DER and P12 certificates [#2413](https://github.com/guzzle/guzzle/pull/2413)
+- Support the cURL (http://) scheme for StreamHandler proxies [#2850](https://github.com/guzzle/guzzle/pull/2850)
+- Support for `guzzlehttp/psr7:^2.0` [#2878](https://github.com/guzzle/guzzle/pull/2878)
+
+### Fixed
+
+- Handle exceptions on invalid header consistently between PHP versions and handlers [#2872](https://github.com/guzzle/guzzle/pull/2872)
+
+## 7.2.0 - 2020-10-10
+
+### Added
+
+- Support for PHP 8 [#2712](https://github.com/guzzle/guzzle/pull/2712), [#2715](https://github.com/guzzle/guzzle/pull/2715), [#2789](https://github.com/guzzle/guzzle/pull/2789)
+- Support passing a body summarizer to the http errors middleware [#2795](https://github.com/guzzle/guzzle/pull/2795)
+
+### Fixed
+
+- Handle exceptions during response creation [#2591](https://github.com/guzzle/guzzle/pull/2591)
+- Fix CURLOPT_ENCODING not to be overwritten [#2595](https://github.com/guzzle/guzzle/pull/2595)
+- Make sure the Request always has a body object [#2804](https://github.com/guzzle/guzzle/pull/2804)
+
+### Changed
+
+- The `TooManyRedirectsException` has a response [#2660](https://github.com/guzzle/guzzle/pull/2660)
+- Avoid "functions" from dependencies [#2712](https://github.com/guzzle/guzzle/pull/2712)
+
+### Deprecated
+
+- Using environment variable GUZZLE_CURL_SELECT_TIMEOUT [#2786](https://github.com/guzzle/guzzle/pull/2786)
+
+## 7.1.1 - 2020-09-30
+
+### Fixed
+
+- Incorrect EOF detection for response body streams on Windows.
+
+### Changed
+
+- We dont connect curl `sink` on HEAD requests.
+- Removed some PHP 5 workarounds
+
+## 7.1.0 - 2020-09-22
+
+### Added
+
+- `GuzzleHttp\MessageFormatterInterface`
+
+### Fixed
+
+- Fixed issue that caused cookies with no value not to be stored.
+- On redirects, we allow all safe methods like GET, HEAD and OPTIONS.
+- Fixed logging on empty responses.
+- Make sure MessageFormatter::format returns string
+
+### Deprecated
+
+- All functions in `GuzzleHttp` has been deprecated. Use static methods on `Utils` instead.
+- `ClientInterface::getConfig()`
+- `Client::getConfig()`
+- `Client::__call()`
+- `Utils::defaultCaBundle()`
+- `CurlFactory::LOW_CURL_VERSION_NUMBER`
+
+## 7.0.1 - 2020-06-27
+
+* Fix multiply defined functions fatal error [#2699](https://github.com/guzzle/guzzle/pull/2699)
+
+## 7.0.0 - 2020-06-27
+
+No changes since 7.0.0-rc1.
+
+## 7.0.0-rc1 - 2020-06-15
+
+### Changed
+
+* Use error level for logging errors in Middleware [#2629](https://github.com/guzzle/guzzle/pull/2629)
+* Disabled IDN support by default and require ext-intl to use it [#2675](https://github.com/guzzle/guzzle/pull/2675)
+
+## 7.0.0-beta2 - 2020-05-25
+
+### Added
+
+* Using `Utils` class instead of functions in the `GuzzleHttp` namespace. [#2546](https://github.com/guzzle/guzzle/pull/2546)
+* `ClientInterface::MAJOR_VERSION` [#2583](https://github.com/guzzle/guzzle/pull/2583)
+
+### Changed
+
+* Avoid the `getenv` function when unsafe [#2531](https://github.com/guzzle/guzzle/pull/2531)
+* Added real client methods [#2529](https://github.com/guzzle/guzzle/pull/2529)
+* Avoid functions due to global install conflicts [#2546](https://github.com/guzzle/guzzle/pull/2546)
+* Use Symfony intl-idn polyfill [#2550](https://github.com/guzzle/guzzle/pull/2550)
+* Adding methods for HTTP verbs like `Client::get()`, `Client::head()`, `Client::patch()` etc [#2529](https://github.com/guzzle/guzzle/pull/2529)
+* `ConnectException` extends `TransferException` [#2541](https://github.com/guzzle/guzzle/pull/2541)
+* Updated the default User Agent to "GuzzleHttp/7" [#2654](https://github.com/guzzle/guzzle/pull/2654)
+
+### Fixed
+
+* Various intl icu issues [#2626](https://github.com/guzzle/guzzle/pull/2626)
+
+### Removed
+
+* Pool option `pool_size` [#2528](https://github.com/guzzle/guzzle/pull/2528)
+
+## 7.0.0-beta1 - 2019-12-30
+
+The diff might look very big but 95% of Guzzle users will be able to upgrade without modification.
+Please see [the upgrade document](UPGRADING.md) that describes all BC breaking changes.
+
+### Added
+
+* Implement PSR-18 and dropped PHP 5 support [#2421](https://github.com/guzzle/guzzle/pull/2421) [#2474](https://github.com/guzzle/guzzle/pull/2474)
+* PHP 7 types [#2442](https://github.com/guzzle/guzzle/pull/2442) [#2449](https://github.com/guzzle/guzzle/pull/2449) [#2466](https://github.com/guzzle/guzzle/pull/2466) [#2497](https://github.com/guzzle/guzzle/pull/2497) [#2499](https://github.com/guzzle/guzzle/pull/2499)
+* IDN support for redirects [2424](https://github.com/guzzle/guzzle/pull/2424)
+
+### Changed
+
+* Dont allow passing null as third argument to `BadResponseException::__construct()` [#2427](https://github.com/guzzle/guzzle/pull/2427)
+* Use SAPI constant instead of method call [#2450](https://github.com/guzzle/guzzle/pull/2450)
+* Use native function invocation [#2444](https://github.com/guzzle/guzzle/pull/2444)
+* Better defaults for PHP installations with old ICU lib [2454](https://github.com/guzzle/guzzle/pull/2454)
+* Added visibility to all constants [#2462](https://github.com/guzzle/guzzle/pull/2462)
+* Dont allow passing `null` as URI to `Client::request()` and `Client::requestAsync()` [#2461](https://github.com/guzzle/guzzle/pull/2461)
+* Widen the exception argument to throwable [#2495](https://github.com/guzzle/guzzle/pull/2495)
+
+### Fixed
+
+* Logging when Promise rejected with a string [#2311](https://github.com/guzzle/guzzle/pull/2311)
+
+### Removed
+
+* Class `SeekException` [#2162](https://github.com/guzzle/guzzle/pull/2162)
+* `RequestException::getResponseBodySummary()` [#2425](https://github.com/guzzle/guzzle/pull/2425)
+* `CookieJar::getCookieValue()` [#2433](https://github.com/guzzle/guzzle/pull/2433)
+* `uri_template()` and `UriTemplate` [#2440](https://github.com/guzzle/guzzle/pull/2440)
+* Request options `save_to` and `exceptions` [#2464](https://github.com/guzzle/guzzle/pull/2464)
+
+## 6.5.2 - 2019-12-23
+
+* idn_to_ascii() fix for old PHP versions [#2489](https://github.com/guzzle/guzzle/pull/2489)
+
+## 6.5.1 - 2019-12-21
+
+* Better defaults for PHP installations with old ICU lib [#2454](https://github.com/guzzle/guzzle/pull/2454)
+* IDN support for redirects [#2424](https://github.com/guzzle/guzzle/pull/2424)
+
+## 6.5.0 - 2019-12-07
+
+* Improvement: Added support for reset internal queue in MockHandler. [#2143](https://github.com/guzzle/guzzle/pull/2143)
+* Improvement: Added support to pass arbitrary options to `curl_multi_init`. [#2287](https://github.com/guzzle/guzzle/pull/2287)
+* Fix: Gracefully handle passing `null` to the `header` option. [#2132](https://github.com/guzzle/guzzle/pull/2132)
+* Fix: `RetryMiddleware` did not do exponential delay between retires due unit mismatch. [#2132](https://github.com/guzzle/guzzle/pull/2132)
+* Fix: Prevent undefined offset when using array for ssl_key options. [#2348](https://github.com/guzzle/guzzle/pull/2348)
+* Deprecated `ClientInterface::VERSION`
+
+## 6.4.1 - 2019-10-23
+
+* No `guzzle.phar` was created in 6.4.0 due expired API token. This release will fix that
+* Added `parent::__construct()` to `FileCookieJar` and `SessionCookieJar`
+
+## 6.4.0 - 2019-10-23
+
+* Improvement: Improved error messages when using curl < 7.21.2 [#2108](https://github.com/guzzle/guzzle/pull/2108)
+* Fix: Test if response is readable before returning a summary in `RequestException::getResponseBodySummary()` [#2081](https://github.com/guzzle/guzzle/pull/2081)
+* Fix: Add support for GUZZLE_CURL_SELECT_TIMEOUT environment variable [#2161](https://github.com/guzzle/guzzle/pull/2161)
+* Improvement: Added `GuzzleHttp\Exception\InvalidArgumentException` [#2163](https://github.com/guzzle/guzzle/pull/2163)
+* Improvement: Added `GuzzleHttp\_current_time()` to use `hrtime()` if that function exists. [#2242](https://github.com/guzzle/guzzle/pull/2242)
+* Improvement: Added curl's `appconnect_time` in `TransferStats` [#2284](https://github.com/guzzle/guzzle/pull/2284)
+* Improvement: Make GuzzleException extend Throwable wherever it's available [#2273](https://github.com/guzzle/guzzle/pull/2273)
+* Fix: Prevent concurrent writes to file when saving `CookieJar` [#2335](https://github.com/guzzle/guzzle/pull/2335)
+* Improvement: Update `MockHandler` so we can test transfer time [#2362](https://github.com/guzzle/guzzle/pull/2362)
+
+## 6.3.3 - 2018-04-22
+
+* Fix: Default headers when decode_content is specified
+
+
+## 6.3.2 - 2018-03-26
+
+* Fix: Release process
+
+
+## 6.3.1 - 2018-03-26
+
+* Bug fix: Parsing 0 epoch expiry times in cookies [#2014](https://github.com/guzzle/guzzle/pull/2014)
+* Improvement: Better ConnectException detection [#2012](https://github.com/guzzle/guzzle/pull/2012)
+* Bug fix: Malformed domain that contains a "/" [#1999](https://github.com/guzzle/guzzle/pull/1999)
+* Bug fix: Undefined offset when a cookie has no first key-value pair [#1998](https://github.com/guzzle/guzzle/pull/1998)
+* Improvement: Support PHPUnit 6 [#1953](https://github.com/guzzle/guzzle/pull/1953)
+* Bug fix: Support empty headers [#1915](https://github.com/guzzle/guzzle/pull/1915)
+* Bug fix: Ignore case during header modifications [#1916](https://github.com/guzzle/guzzle/pull/1916)
+
++ Minor code cleanups, documentation fixes and clarifications.
+
+
+## 6.3.0 - 2017-06-22
+
+* Feature: force IP resolution (ipv4 or ipv6) [#1608](https://github.com/guzzle/guzzle/pull/1608), [#1659](https://github.com/guzzle/guzzle/pull/1659)
+* Improvement: Don't include summary in exception message when body is empty [#1621](https://github.com/guzzle/guzzle/pull/1621)
+* Improvement: Handle `on_headers` option in MockHandler [#1580](https://github.com/guzzle/guzzle/pull/1580)
+* Improvement: Added SUSE Linux CA path [#1609](https://github.com/guzzle/guzzle/issues/1609)
+* Improvement: Use class reference for getting the name of the class instead of using hardcoded strings [#1641](https://github.com/guzzle/guzzle/pull/1641)
+* Feature: Added `read_timeout` option [#1611](https://github.com/guzzle/guzzle/pull/1611)
+* Bug fix: PHP 7.x fixes [#1685](https://github.com/guzzle/guzzle/pull/1685), [#1686](https://github.com/guzzle/guzzle/pull/1686), [#1811](https://github.com/guzzle/guzzle/pull/1811)
+* Deprecation: BadResponseException instantiation without a response [#1642](https://github.com/guzzle/guzzle/pull/1642)
+* Feature: Added NTLM auth [#1569](https://github.com/guzzle/guzzle/pull/1569)
+* Feature: Track redirect HTTP status codes [#1711](https://github.com/guzzle/guzzle/pull/1711)
+* Improvement: Check handler type during construction [#1745](https://github.com/guzzle/guzzle/pull/1745)
+* Improvement: Always include the Content-Length if there's a body [#1721](https://github.com/guzzle/guzzle/pull/1721)
+* Feature: Added convenience method to access a cookie by name [#1318](https://github.com/guzzle/guzzle/pull/1318)
+* Bug fix: Fill `CURLOPT_CAPATH` and `CURLOPT_CAINFO` properly [#1684](https://github.com/guzzle/guzzle/pull/1684)
+* Improvement: Use `\GuzzleHttp\Promise\rejection_for` function instead of object init [#1827](https://github.com/guzzle/guzzle/pull/1827)
+
+
++ Minor code cleanups, documentation fixes and clarifications.
+
+## 6.2.3 - 2017-02-28
+
+* Fix deprecations with guzzle/psr7 version 1.4
+
+## 6.2.2 - 2016-10-08
+
+* Allow to pass nullable Response to delay callable
+* Only add scheme when host is present
+* Fix drain case where content-length is the literal string zero
+* Obfuscate in-URL credentials in exceptions
+
+## 6.2.1 - 2016-07-18
+
+* Address HTTP_PROXY security vulnerability, CVE-2016-5385:
+ https://httpoxy.org/
+* Fixing timeout bug with StreamHandler:
+ https://github.com/guzzle/guzzle/pull/1488
+* Only read up to `Content-Length` in PHP StreamHandler to avoid timeouts when
+ a server does not honor `Connection: close`.
+* Ignore URI fragment when sending requests.
+
+## 6.2.0 - 2016-03-21
+
+* Feature: added `GuzzleHttp\json_encode` and `GuzzleHttp\json_decode`.
+ https://github.com/guzzle/guzzle/pull/1389
+* Bug fix: Fix sleep calculation when waiting for delayed requests.
+ https://github.com/guzzle/guzzle/pull/1324
+* Feature: More flexible history containers.
+ https://github.com/guzzle/guzzle/pull/1373
+* Bug fix: defer sink stream opening in StreamHandler.
+ https://github.com/guzzle/guzzle/pull/1377
+* Bug fix: do not attempt to escape cookie values.
+ https://github.com/guzzle/guzzle/pull/1406
+* Feature: report original content encoding and length on decoded responses.
+ https://github.com/guzzle/guzzle/pull/1409
+* Bug fix: rewind seekable request bodies before dispatching to cURL.
+ https://github.com/guzzle/guzzle/pull/1422
+* Bug fix: provide an empty string to `http_build_query` for HHVM workaround.
+ https://github.com/guzzle/guzzle/pull/1367
+
+## 6.1.1 - 2015-11-22
+
+* Bug fix: Proxy::wrapSync() now correctly proxies to the appropriate handler
+ https://github.com/guzzle/guzzle/commit/911bcbc8b434adce64e223a6d1d14e9a8f63e4e4
+* Feature: HandlerStack is now more generic.
+ https://github.com/guzzle/guzzle/commit/f2102941331cda544745eedd97fc8fd46e1ee33e
+* Bug fix: setting verify to false in the StreamHandler now disables peer
+ verification. https://github.com/guzzle/guzzle/issues/1256
+* Feature: Middleware now uses an exception factory, including more error
+ context. https://github.com/guzzle/guzzle/pull/1282
+* Feature: better support for disabled functions.
+ https://github.com/guzzle/guzzle/pull/1287
+* Bug fix: fixed regression where MockHandler was not using `sink`.
+ https://github.com/guzzle/guzzle/pull/1292
+
+## 6.1.0 - 2015-09-08
+
+* Feature: Added the `on_stats` request option to provide access to transfer
+ statistics for requests. https://github.com/guzzle/guzzle/pull/1202
+* Feature: Added the ability to persist session cookies in CookieJars.
+ https://github.com/guzzle/guzzle/pull/1195
+* Feature: Some compatibility updates for Google APP Engine
+ https://github.com/guzzle/guzzle/pull/1216
+* Feature: Added support for NO_PROXY to prevent the use of a proxy based on
+ a simple set of rules. https://github.com/guzzle/guzzle/pull/1197
+* Feature: Cookies can now contain square brackets.
+ https://github.com/guzzle/guzzle/pull/1237
+* Bug fix: Now correctly parsing `=` inside of quotes in Cookies.
+ https://github.com/guzzle/guzzle/pull/1232
+* Bug fix: Cusotm cURL options now correctly override curl options of the
+ same name. https://github.com/guzzle/guzzle/pull/1221
+* Bug fix: Content-Type header is now added when using an explicitly provided
+ multipart body. https://github.com/guzzle/guzzle/pull/1218
+* Bug fix: Now ignoring Set-Cookie headers that have no name.
+* Bug fix: Reason phrase is no longer cast to an int in some cases in the
+ cURL handler. https://github.com/guzzle/guzzle/pull/1187
+* Bug fix: Remove the Authorization header when redirecting if the Host
+ header changes. https://github.com/guzzle/guzzle/pull/1207
+* Bug fix: Cookie path matching fixes
+ https://github.com/guzzle/guzzle/issues/1129
+* Bug fix: Fixing the cURL `body_as_string` setting
+ https://github.com/guzzle/guzzle/pull/1201
+* Bug fix: quotes are no longer stripped when parsing cookies.
+ https://github.com/guzzle/guzzle/issues/1172
+* Bug fix: `form_params` and `query` now always uses the `&` separator.
+ https://github.com/guzzle/guzzle/pull/1163
+* Bug fix: Adding a Content-Length to PHP stream wrapper requests if not set.
+ https://github.com/guzzle/guzzle/pull/1189
+
+## 6.0.2 - 2015-07-04
+
+* Fixed a memory leak in the curl handlers in which references to callbacks
+ were not being removed by `curl_reset`.
+* Cookies are now extracted properly before redirects.
+* Cookies now allow more character ranges.
+* Decoded Content-Encoding responses are now modified to correctly reflect
+ their state if the encoding was automatically removed by a handler. This
+ means that the `Content-Encoding` header may be removed an the
+ `Content-Length` modified to reflect the message size after removing the
+ encoding.
+* Added a more explicit error message when trying to use `form_params` and
+ `multipart` in the same request.
+* Several fixes for HHVM support.
+* Functions are now conditionally required using an additional level of
+ indirection to help with global Composer installations.
+
+## 6.0.1 - 2015-05-27
+
+* Fixed a bug with serializing the `query` request option where the `&`
+ separator was missing.
+* Added a better error message for when `body` is provided as an array. Please
+ use `form_params` or `multipart` instead.
+* Various doc fixes.
+
+## 6.0.0 - 2015-05-26
+
+* See the UPGRADING.md document for more information.
+* Added `multipart` and `form_params` request options.
+* Added `synchronous` request option.
+* Added the `on_headers` request option.
+* Fixed `expect` handling.
+* No longer adding default middlewares in the client ctor. These need to be
+ present on the provided handler in order to work.
+* Requests are no longer initiated when sending async requests with the
+ CurlMultiHandler. This prevents unexpected recursion from requests completing
+ while ticking the cURL loop.
+* Removed the semantics of setting `default` to `true`. This is no longer
+ required now that the cURL loop is not ticked for async requests.
+* Added request and response logging middleware.
+* No longer allowing self signed certificates when using the StreamHandler.
+* Ensuring that `sink` is valid if saving to a file.
+* Request exceptions now include a "handler context" which provides handler
+ specific contextual information.
+* Added `GuzzleHttp\RequestOptions` to allow request options to be applied
+ using constants.
+* `$maxHandles` has been removed from CurlMultiHandler.
+* `MultipartPostBody` is now part of the `guzzlehttp/psr7` package.
+
+## 5.3.0 - 2015-05-19
+
+* Mock now supports `save_to`
+* Marked `AbstractRequestEvent::getTransaction()` as public.
+* Fixed a bug in which multiple headers using different casing would overwrite
+ previous headers in the associative array.
+* Added `Utils::getDefaultHandler()`
+* Marked `GuzzleHttp\Client::getDefaultUserAgent` as deprecated.
+* URL scheme is now always lowercased.
+
+## 6.0.0-beta.1
+
+* Requires PHP >= 5.5
+* Updated to use PSR-7
+ * Requires immutable messages, which basically means an event based system
+ owned by a request instance is no longer possible.
+ * Utilizing the [Guzzle PSR-7 package](https://github.com/guzzle/psr7).
+ * Removed the dependency on `guzzlehttp/streams`. These stream abstractions
+ are available in the `guzzlehttp/psr7` package under the `GuzzleHttp\Psr7`
+ namespace.
+* Added middleware and handler system
+ * Replaced the Guzzle event and subscriber system with a middleware system.
+ * No longer depends on RingPHP, but rather places the HTTP handlers directly
+ in Guzzle, operating on PSR-7 messages.
+ * Retry logic is now encapsulated in `GuzzleHttp\Middleware::retry`, which
+ means the `guzzlehttp/retry-subscriber` is now obsolete.
+ * Mocking responses is now handled using `GuzzleHttp\Handler\MockHandler`.
+* Asynchronous responses
+ * No longer supports the `future` request option to send an async request.
+ Instead, use one of the `*Async` methods of a client (e.g., `requestAsync`,
+ `getAsync`, etc.).
+ * Utilizing `GuzzleHttp\Promise` instead of React's promise library to avoid
+ recursion required by chaining and forwarding react promises. See
+ https://github.com/guzzle/promises
+ * Added `requestAsync` and `sendAsync` to send request asynchronously.
+ * Added magic methods for `getAsync()`, `postAsync()`, etc. to send requests
+ asynchronously.
+* Request options
+ * POST and form updates
+ * Added the `form_fields` and `form_files` request options.
+ * Removed the `GuzzleHttp\Post` namespace.
+ * The `body` request option no longer accepts an array for POST requests.
+ * The `exceptions` request option has been deprecated in favor of the
+ `http_errors` request options.
+ * The `save_to` request option has been deprecated in favor of `sink` request
+ option.
+* Clients no longer accept an array of URI template string and variables for
+ URI variables. You will need to expand URI templates before passing them
+ into a client constructor or request method.
+* Client methods `get()`, `post()`, `put()`, `patch()`, `options()`, etc. are
+ now magic methods that will send synchronous requests.
+* Replaced `Utils.php` with plain functions in `functions.php`.
+* Removed `GuzzleHttp\Collection`.
+* Removed `GuzzleHttp\BatchResults`. Batched pool results are now returned as
+ an array.
+* Removed `GuzzleHttp\Query`. Query string handling is now handled using an
+ associative array passed into the `query` request option. The query string
+ is serialized using PHP's `http_build_query`. If you need more control, you
+ can pass the query string in as a string.
+* `GuzzleHttp\QueryParser` has been replaced with the
+ `GuzzleHttp\Psr7\parse_query`.
+
+## 5.2.0 - 2015-01-27
+
+* Added `AppliesHeadersInterface` to make applying headers to a request based
+ on the body more generic and not specific to `PostBodyInterface`.
+* Reduced the number of stack frames needed to send requests.
+* Nested futures are now resolved in the client rather than the RequestFsm
+* Finishing state transitions is now handled in the RequestFsm rather than the
+ RingBridge.
+* Added a guard in the Pool class to not use recursion for request retries.
+
+## 5.1.0 - 2014-12-19
+
+* Pool class no longer uses recursion when a request is intercepted.
+* The size of a Pool can now be dynamically adjusted using a callback.
+ See https://github.com/guzzle/guzzle/pull/943.
+* Setting a request option to `null` when creating a request with a client will
+ ensure that the option is not set. This allows you to overwrite default
+ request options on a per-request basis.
+ See https://github.com/guzzle/guzzle/pull/937.
+* Added the ability to limit which protocols are allowed for redirects by
+ specifying a `protocols` array in the `allow_redirects` request option.
+* Nested futures due to retries are now resolved when waiting for synchronous
+ responses. See https://github.com/guzzle/guzzle/pull/947.
+* `"0"` is now an allowed URI path. See
+ https://github.com/guzzle/guzzle/pull/935.
+* `Query` no longer typehints on the `$query` argument in the constructor,
+ allowing for strings and arrays.
+* Exceptions thrown in the `end` event are now correctly wrapped with Guzzle
+ specific exceptions if necessary.
+
+## 5.0.3 - 2014-11-03
+
+This change updates query strings so that they are treated as un-encoded values
+by default where the value represents an un-encoded value to send over the
+wire. A Query object then encodes the value before sending over the wire. This
+means that even value query string values (e.g., ":") are url encoded. This
+makes the Query class match PHP's http_build_query function. However, if you
+want to send requests over the wire using valid query string characters that do
+not need to be encoded, then you can provide a string to Url::setQuery() and
+pass true as the second argument to specify that the query string is a raw
+string that should not be parsed or encoded (unless a call to getQuery() is
+subsequently made, forcing the query-string to be converted into a Query
+object).
+
+## 5.0.2 - 2014-10-30
+
+* Added a trailing `\r\n` to multipart/form-data payloads. See
+ https://github.com/guzzle/guzzle/pull/871
+* Added a `GuzzleHttp\Pool::send()` convenience method to match the docs.
+* Status codes are now returned as integers. See
+ https://github.com/guzzle/guzzle/issues/881
+* No longer overwriting an existing `application/x-www-form-urlencoded` header
+ when sending POST requests, allowing for customized headers. See
+ https://github.com/guzzle/guzzle/issues/877
+* Improved path URL serialization.
+
+ * No longer double percent-encoding characters in the path or query string if
+ they are already encoded.
+ * Now properly encoding the supplied path to a URL object, instead of only
+ encoding ' ' and '?'.
+ * Note: This has been changed in 5.0.3 to now encode query string values by
+ default unless the `rawString` argument is provided when setting the query
+ string on a URL: Now allowing many more characters to be present in the
+ query string without being percent encoded. See https://tools.ietf.org/html/rfc3986#appendix-A
+
+## 5.0.1 - 2014-10-16
+
+Bugfix release.
+
+* Fixed an issue where connection errors still returned response object in
+ error and end events event though the response is unusable. This has been
+ corrected so that a response is not returned in the `getResponse` method of
+ these events if the response did not complete. https://github.com/guzzle/guzzle/issues/867
+* Fixed an issue where transfer statistics were not being populated in the
+ RingBridge. https://github.com/guzzle/guzzle/issues/866
+
+## 5.0.0 - 2014-10-12
+
+Adding support for non-blocking responses and some minor API cleanup.
+
+### New Features
+
+* Added support for non-blocking responses based on `guzzlehttp/guzzle-ring`.
+* Added a public API for creating a default HTTP adapter.
+* Updated the redirect plugin to be non-blocking so that redirects are sent
+ concurrently. Other plugins like this can now be updated to be non-blocking.
+* Added a "progress" event so that you can get upload and download progress
+ events.
+* Added `GuzzleHttp\Pool` which implements FutureInterface and transfers
+ requests concurrently using a capped pool size as efficiently as possible.
+* Added `hasListeners()` to EmitterInterface.
+* Removed `GuzzleHttp\ClientInterface::sendAll` and marked
+ `GuzzleHttp\Client::sendAll` as deprecated (it's still there, just not the
+ recommended way).
+
+### Breaking changes
+
+The breaking changes in this release are relatively minor. The biggest thing to
+look out for is that request and response objects no longer implement fluent
+interfaces.
+
+* Removed the fluent interfaces (i.e., `return $this`) from requests,
+ responses, `GuzzleHttp\Collection`, `GuzzleHttp\Url`,
+ `GuzzleHttp\Query`, `GuzzleHttp\Post\PostBody`, and
+ `GuzzleHttp\Cookie\SetCookie`. This blog post provides a good outline of
+ why I did this: https://ocramius.github.io/blog/fluent-interfaces-are-evil/.
+ This also makes the Guzzle message interfaces compatible with the current
+ PSR-7 message proposal.
+* Removed "functions.php", so that Guzzle is truly PSR-4 compliant. Except
+ for the HTTP request functions from function.php, these functions are now
+ implemented in `GuzzleHttp\Utils` using camelCase. `GuzzleHttp\json_decode`
+ moved to `GuzzleHttp\Utils::jsonDecode`. `GuzzleHttp\get_path` moved to
+ `GuzzleHttp\Utils::getPath`. `GuzzleHttp\set_path` moved to
+ `GuzzleHttp\Utils::setPath`. `GuzzleHttp\batch` should now be
+ `GuzzleHttp\Pool::batch`, which returns an `objectStorage`. Using functions.php
+ caused problems for many users: they aren't PSR-4 compliant, require an
+ explicit include, and needed an if-guard to ensure that the functions are not
+ declared multiple times.
+* Rewrote adapter layer.
+ * Removing all classes from `GuzzleHttp\Adapter`, these are now
+ implemented as callables that are stored in `GuzzleHttp\Ring\Client`.
+ * Removed the concept of "parallel adapters". Sending requests serially or
+ concurrently is now handled using a single adapter.
+ * Moved `GuzzleHttp\Adapter\Transaction` to `GuzzleHttp\Transaction`. The
+ Transaction object now exposes the request, response, and client as public
+ properties. The getters and setters have been removed.
+* Removed the "headers" event. This event was only useful for changing the
+ body a response once the headers of the response were known. You can implement
+ a similar behavior in a number of ways. One example might be to use a
+ FnStream that has access to the transaction being sent. For example, when the
+ first byte is written, you could check if the response headers match your
+ expectations, and if so, change the actual stream body that is being
+ written to.
+* Removed the `asArray` parameter from
+ `GuzzleHttp\Message\MessageInterface::getHeader`. If you want to get a header
+ value as an array, then use the newly added `getHeaderAsArray()` method of
+ `MessageInterface`. This change makes the Guzzle interfaces compatible with
+ the PSR-7 interfaces.
+* `GuzzleHttp\Message\MessageFactory` no longer allows subclasses to add
+ custom request options using double-dispatch (this was an implementation
+ detail). Instead, you should now provide an associative array to the
+ constructor which is a mapping of the request option name mapping to a
+ function that applies the option value to a request.
+* Removed the concept of "throwImmediately" from exceptions and error events.
+ This control mechanism was used to stop a transfer of concurrent requests
+ from completing. This can now be handled by throwing the exception or by
+ cancelling a pool of requests or each outstanding future request individually.
+* Updated to "GuzzleHttp\Streams" 3.0.
+ * `GuzzleHttp\Stream\StreamInterface::getContents()` no longer accepts a
+ `maxLen` parameter. This update makes the Guzzle streams project
+ compatible with the current PSR-7 proposal.
+ * `GuzzleHttp\Stream\Stream::__construct`,
+ `GuzzleHttp\Stream\Stream::factory`, and
+ `GuzzleHttp\Stream\Utils::create` no longer accept a size in the second
+ argument. They now accept an associative array of options, including the
+ "size" key and "metadata" key which can be used to provide custom metadata.
+
+## 4.2.2 - 2014-09-08
+
+* Fixed a memory leak in the CurlAdapter when reusing cURL handles.
+* No longer using `request_fulluri` in stream adapter proxies.
+* Relative redirects are now based on the last response, not the first response.
+
+## 4.2.1 - 2014-08-19
+
+* Ensuring that the StreamAdapter does not always add a Content-Type header
+* Adding automated github releases with a phar and zip
+
+## 4.2.0 - 2014-08-17
+
+* Now merging in default options using a case-insensitive comparison.
+ Closes https://github.com/guzzle/guzzle/issues/767
+* Added the ability to automatically decode `Content-Encoding` response bodies
+ using the `decode_content` request option. This is set to `true` by default
+ to decode the response body if it comes over the wire with a
+ `Content-Encoding`. Set this value to `false` to disable decoding the
+ response content, and pass a string to provide a request `Accept-Encoding`
+ header and turn on automatic response decoding. This feature now allows you
+ to pass an `Accept-Encoding` header in the headers of a request but still
+ disable automatic response decoding.
+ Closes https://github.com/guzzle/guzzle/issues/764
+* Added the ability to throw an exception immediately when transferring
+ requests in parallel. Closes https://github.com/guzzle/guzzle/issues/760
+* Updating guzzlehttp/streams dependency to ~2.1
+* No longer utilizing the now deprecated namespaced methods from the stream
+ package.
+
+## 4.1.8 - 2014-08-14
+
+* Fixed an issue in the CurlFactory that caused setting the `stream=false`
+ request option to throw an exception.
+ See: https://github.com/guzzle/guzzle/issues/769
+* TransactionIterator now calls rewind on the inner iterator.
+ See: https://github.com/guzzle/guzzle/pull/765
+* You can now set the `Content-Type` header to `multipart/form-data`
+ when creating POST requests to force multipart bodies.
+ See https://github.com/guzzle/guzzle/issues/768
+
+## 4.1.7 - 2014-08-07
+
+* Fixed an error in the HistoryPlugin that caused the same request and response
+ to be logged multiple times when an HTTP protocol error occurs.
+* Ensuring that cURL does not add a default Content-Type when no Content-Type
+ has been supplied by the user. This prevents the adapter layer from modifying
+ the request that is sent over the wire after any listeners may have already
+ put the request in a desired state (e.g., signed the request).
+* Throwing an exception when you attempt to send requests that have the
+ "stream" set to true in parallel using the MultiAdapter.
+* Only calling curl_multi_select when there are active cURL handles. This was
+ previously changed and caused performance problems on some systems due to PHP
+ always selecting until the maximum select timeout.
+* Fixed a bug where multipart/form-data POST fields were not correctly
+ aggregated (e.g., values with "&").
+
+## 4.1.6 - 2014-08-03
+
+* Added helper methods to make it easier to represent messages as strings,
+ including getting the start line and getting headers as a string.
+
+## 4.1.5 - 2014-08-02
+
+* Automatically retrying cURL "Connection died, retrying a fresh connect"
+ errors when possible.
+* cURL implementation cleanup
+* Allowing multiple event subscriber listeners to be registered per event by
+ passing an array of arrays of listener configuration.
+
+## 4.1.4 - 2014-07-22
+
+* Fixed a bug that caused multi-part POST requests with more than one field to
+ serialize incorrectly.
+* Paths can now be set to "0"
+* `ResponseInterface::xml` now accepts a `libxml_options` option and added a
+ missing default argument that was required when parsing XML response bodies.
+* A `save_to` stream is now created lazily, which means that files are not
+ created on disk unless a request succeeds.
+
+## 4.1.3 - 2014-07-15
+
+* Various fixes to multipart/form-data POST uploads
+* Wrapping function.php in an if-statement to ensure Guzzle can be used
+ globally and in a Composer install
+* Fixed an issue with generating and merging in events to an event array
+* POST headers are only applied before sending a request to allow you to change
+ the query aggregator used before uploading
+* Added much more robust query string parsing
+* Fixed various parsing and normalization issues with URLs
+* Fixing an issue where multi-valued headers were not being utilized correctly
+ in the StreamAdapter
+
+## 4.1.2 - 2014-06-18
+
+* Added support for sending payloads with GET requests
+
+## 4.1.1 - 2014-06-08
+
+* Fixed an issue related to using custom message factory options in subclasses
+* Fixed an issue with nested form fields in a multi-part POST
+* Fixed an issue with using the `json` request option for POST requests
+* Added `ToArrayInterface` to `GuzzleHttp\Cookie\CookieJar`
+
+## 4.1.0 - 2014-05-27
+
+* Added a `json` request option to easily serialize JSON payloads.
+* Added a `GuzzleHttp\json_decode()` wrapper to safely parse JSON.
+* Added `setPort()` and `getPort()` to `GuzzleHttp\Message\RequestInterface`.
+* Added the ability to provide an emitter to a client in the client constructor.
+* Added the ability to persist a cookie session using $_SESSION.
+* Added a trait that can be used to add event listeners to an iterator.
+* Removed request method constants from RequestInterface.
+* Fixed warning when invalid request start-lines are received.
+* Updated MessageFactory to work with custom request option methods.
+* Updated cacert bundle to latest build.
+
+4.0.2 (2014-04-16)
+------------------
+
+* Proxy requests using the StreamAdapter now properly use request_fulluri (#632)
+* Added the ability to set scalars as POST fields (#628)
+
+## 4.0.1 - 2014-04-04
+
+* The HTTP status code of a response is now set as the exception code of
+ RequestException objects.
+* 303 redirects will now correctly switch from POST to GET requests.
+* The default parallel adapter of a client now correctly uses the MultiAdapter.
+* HasDataTrait now initializes the internal data array as an empty array so
+ that the toArray() method always returns an array.
+
+## 4.0.0 - 2014-03-29
+
+* For information on changes and upgrading, see:
+ https://github.com/guzzle/guzzle/blob/master/UPGRADING.md#3x-to-40
+* Added `GuzzleHttp\batch()` as a convenience function for sending requests in
+ parallel without needing to write asynchronous code.
+* Restructured how events are added to `GuzzleHttp\ClientInterface::sendAll()`.
+ You can now pass a callable or an array of associative arrays where each
+ associative array contains the "fn", "priority", and "once" keys.
+
+## 4.0.0.rc-2 - 2014-03-25
+
+* Removed `getConfig()` and `setConfig()` from clients to avoid confusion
+ around whether things like base_url, message_factory, etc. should be able to
+ be retrieved or modified.
+* Added `getDefaultOption()` and `setDefaultOption()` to ClientInterface
+* functions.php functions were renamed using snake_case to match PHP idioms
+* Added support for `HTTP_PROXY`, `HTTPS_PROXY`, and
+ `GUZZLE_CURL_SELECT_TIMEOUT` environment variables
+* Added the ability to specify custom `sendAll()` event priorities
+* Added the ability to specify custom stream context options to the stream
+ adapter.
+* Added a functions.php function for `get_path()` and `set_path()`
+* CurlAdapter and MultiAdapter now use a callable to generate curl resources
+* MockAdapter now properly reads a body and emits a `headers` event
+* Updated Url class to check if a scheme and host are set before adding ":"
+ and "//". This allows empty Url (e.g., "") to be serialized as "".
+* Parsing invalid XML no longer emits warnings
+* Curl classes now properly throw AdapterExceptions
+* Various performance optimizations
+* Streams are created with the faster `Stream\create()` function
+* Marked deprecation_proxy() as internal
+* Test server is now a collection of static methods on a class
+
+## 4.0.0-rc.1 - 2014-03-15
+
+* See https://github.com/guzzle/guzzle/blob/master/UPGRADING.md#3x-to-40
+
+## 3.8.1 - 2014-01-28
+
+* Bug: Always using GET requests when redirecting from a 303 response
+* Bug: CURLOPT_SSL_VERIFYHOST is now correctly set to false when setting `$certificateAuthority` to false in
+ `Guzzle\Http\ClientInterface::setSslVerification()`
+* Bug: RedirectPlugin now uses strict RFC 3986 compliance when combining a base URL with a relative URL
+* Bug: The body of a request can now be set to `"0"`
+* Sending PHP stream requests no longer forces `HTTP/1.0`
+* Adding more information to ExceptionCollection exceptions so that users have more context, including a stack trace of
+ each sub-exception
+* Updated the `$ref` attribute in service descriptions to merge over any existing parameters of a schema (rather than
+ clobbering everything).
+* Merging URLs will now use the query string object from the relative URL (thus allowing custom query aggregators)
+* Query strings are now parsed in a way that they do no convert empty keys with no value to have a dangling `=`.
+ For example `foo&bar=baz` is now correctly parsed and recognized as `foo&bar=baz` rather than `foo=&bar=baz`.
+* Now properly escaping the regular expression delimiter when matching Cookie domains.
+* Network access is now disabled when loading XML documents
+
+## 3.8.0 - 2013-12-05
+
+* Added the ability to define a POST name for a file
+* JSON response parsing now properly walks additionalProperties
+* cURL error code 18 is now retried automatically in the BackoffPlugin
+* Fixed a cURL error when URLs contain fragments
+* Fixed an issue in the BackoffPlugin retry event where it was trying to access all exceptions as if they were
+ CurlExceptions
+* CURLOPT_PROGRESS function fix for PHP 5.5 (69fcc1e)
+* Added the ability for Guzzle to work with older versions of cURL that do not support `CURLOPT_TIMEOUT_MS`
+* Fixed a bug that was encountered when parsing empty header parameters
+* UriTemplate now has a `setRegex()` method to match the docs
+* The `debug` request parameter now checks if it is truthy rather than if it exists
+* Setting the `debug` request parameter to true shows verbose cURL output instead of using the LogPlugin
+* Added the ability to combine URLs using strict RFC 3986 compliance
+* Command objects can now return the validation errors encountered by the command
+* Various fixes to cache revalidation (#437 and 29797e5)
+* Various fixes to the AsyncPlugin
+* Cleaned up build scripts
+
+## 3.7.4 - 2013-10-02
+
+* Bug fix: 0 is now an allowed value in a description parameter that has a default value (#430)
+* Bug fix: SchemaFormatter now returns an integer when formatting to a Unix timestamp
+ (see https://github.com/aws/aws-sdk-php/issues/147)
+* Bug fix: Cleaned up and fixed URL dot segment removal to properly resolve internal dots
+* Minimum PHP version is now properly specified as 5.3.3 (up from 5.3.2) (#420)
+* Updated the bundled cacert.pem (#419)
+* OauthPlugin now supports adding authentication to headers or query string (#425)
+
+## 3.7.3 - 2013-09-08
+
+* Added the ability to get the exception associated with a request/command when using `MultiTransferException` and
+ `CommandTransferException`.
+* Setting `additionalParameters` of a response to false is now honored when parsing responses with a service description
+* Schemas are only injected into response models when explicitly configured.
+* No longer guessing Content-Type based on the path of a request. Content-Type is now only guessed based on the path of
+ an EntityBody.
+* Bug fix: ChunkedIterator can now properly chunk a \Traversable as well as an \Iterator.
+* Bug fix: FilterIterator now relies on `\Iterator` instead of `\Traversable`.
+* Bug fix: Gracefully handling malformed responses in RequestMediator::writeResponseBody()
+* Bug fix: Replaced call to canCache with canCacheRequest in the CallbackCanCacheStrategy of the CachePlugin
+* Bug fix: Visiting XML attributes first before visiting XML children when serializing requests
+* Bug fix: Properly parsing headers that contain commas contained in quotes
+* Bug fix: mimetype guessing based on a filename is now case-insensitive
+
+## 3.7.2 - 2013-08-02
+
+* Bug fix: Properly URL encoding paths when using the PHP-only version of the UriTemplate expander
+ See https://github.com/guzzle/guzzle/issues/371
+* Bug fix: Cookie domains are now matched correctly according to RFC 6265
+ See https://github.com/guzzle/guzzle/issues/377
+* Bug fix: GET parameters are now used when calculating an OAuth signature
+* Bug fix: Fixed an issue with cache revalidation where the If-None-Match header was being double quoted
+* `Guzzle\Common\AbstractHasDispatcher::dispatch()` now returns the event that was dispatched
+* `Guzzle\Http\QueryString::factory()` now guesses the most appropriate query aggregator to used based on the input.
+ See https://github.com/guzzle/guzzle/issues/379
+* Added a way to add custom domain objects to service description parsing using the `operation.parse_class` event. See
+ https://github.com/guzzle/guzzle/pull/380
+* cURL multi cleanup and optimizations
+
+## 3.7.1 - 2013-07-05
+
+* Bug fix: Setting default options on a client now works
+* Bug fix: Setting options on HEAD requests now works. See #352
+* Bug fix: Moving stream factory before send event to before building the stream. See #353
+* Bug fix: Cookies no longer match on IP addresses per RFC 6265
+* Bug fix: Correctly parsing header parameters that are in `<>` and quotes
+* Added `cert` and `ssl_key` as request options
+* `Host` header can now diverge from the host part of a URL if the header is set manually
+* `Guzzle\Service\Command\LocationVisitor\Request\XmlVisitor` was rewritten to change from using SimpleXML to XMLWriter
+* OAuth parameters are only added via the plugin if they aren't already set
+* Exceptions are now thrown when a URL cannot be parsed
+* Returning `false` if `Guzzle\Http\EntityBody::getContentMd5()` fails
+* Not setting a `Content-MD5` on a command if calculating the Content-MD5 fails via the CommandContentMd5Plugin
+
+## 3.7.0 - 2013-06-10
+
+* See UPGRADING.md for more information on how to upgrade.
+* Requests now support the ability to specify an array of $options when creating a request to more easily modify a
+ request. You can pass a 'request.options' configuration setting to a client to apply default request options to
+ every request created by a client (e.g. default query string variables, headers, curl options, etc.).
+* Added a static facade class that allows you to use Guzzle with static methods and mount the class to `\Guzzle`.
+ See `Guzzle\Http\StaticClient::mount`.
+* Added `command.request_options` to `Guzzle\Service\Command\AbstractCommand` to pass request options to requests
+ created by a command (e.g. custom headers, query string variables, timeout settings, etc.).
+* Stream size in `Guzzle\Stream\PhpStreamRequestFactory` will now be set if Content-Length is returned in the
+ headers of a response
+* Added `Guzzle\Common\Collection::setPath($path, $value)` to set a value into an array using a nested key
+ (e.g. `$collection->setPath('foo/baz/bar', 'test'); echo $collection['foo']['bar']['bar'];`)
+* ServiceBuilders now support storing and retrieving arbitrary data
+* CachePlugin can now purge all resources for a given URI
+* CachePlugin can automatically purge matching cached items when a non-idempotent request is sent to a resource
+* CachePlugin now uses the Vary header to determine if a resource is a cache hit
+* `Guzzle\Http\Message\Response` now implements `\Serializable`
+* Added `Guzzle\Cache\CacheAdapterFactory::fromCache()` to more easily create cache adapters
+* `Guzzle\Service\ClientInterface::execute()` now accepts an array, single command, or Traversable
+* Fixed a bug in `Guzzle\Http\Message\Header\Link::addLink()`
+* Better handling of calculating the size of a stream in `Guzzle\Stream\Stream` using fstat() and caching the size
+* `Guzzle\Common\Exception\ExceptionCollection` now creates a more readable exception message
+* Fixing BC break: Added back the MonologLogAdapter implementation rather than extending from PsrLog so that older
+ Symfony users can still use the old version of Monolog.
+* Fixing BC break: Added the implementation back in for `Guzzle\Http\Message\AbstractMessage::getTokenizedHeader()`.
+ Now triggering an E_USER_DEPRECATED warning when used. Use `$message->getHeader()->parseParams()`.
+* Several performance improvements to `Guzzle\Common\Collection`
+* Added an `$options` argument to the end of the following methods of `Guzzle\Http\ClientInterface`:
+ createRequest, head, delete, put, patch, post, options, prepareRequest
+* Added an `$options` argument to the end of `Guzzle\Http\Message\Request\RequestFactoryInterface::createRequest()`
+* Added an `applyOptions()` method to `Guzzle\Http\Message\Request\RequestFactoryInterface`
+* Changed `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $body = null)` to
+ `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $options = array())`. You can still pass in a
+ resource, string, or EntityBody into the $options parameter to specify the download location of the response.
+* Changed `Guzzle\Common\Collection::__construct($data)` to no longer accepts a null value for `$data` but a
+ default `array()`
+* Added `Guzzle\Stream\StreamInterface::isRepeatable`
+* Removed `Guzzle\Http\ClientInterface::setDefaultHeaders(). Use
+ $client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. or
+ $client->getConfig()->setPath('request.options/headers', array('header_name' => 'value'))`.
+* Removed `Guzzle\Http\ClientInterface::getDefaultHeaders(). Use $client->getConfig()->getPath('request.options/headers')`.
+* Removed `Guzzle\Http\ClientInterface::expandTemplate()`
+* Removed `Guzzle\Http\ClientInterface::setRequestFactory()`
+* Removed `Guzzle\Http\ClientInterface::getCurlMulti()`
+* Removed `Guzzle\Http\Message\RequestInterface::canCache`
+* Removed `Guzzle\Http\Message\RequestInterface::setIsRedirect`
+* Removed `Guzzle\Http\Message\RequestInterface::isRedirect`
+* Made `Guzzle\Http\Client::expandTemplate` and `getUriTemplate` protected methods.
+* You can now enable E_USER_DEPRECATED warnings to see if you are using a deprecated method by setting
+ `Guzzle\Common\Version::$emitWarnings` to true.
+* Marked `Guzzle\Http\Message\Request::isResponseBodyRepeatable()` as deprecated. Use
+ `$request->getResponseBody()->isRepeatable()` instead.
+* Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use
+ `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead.
+* Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use
+ `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead.
+* Marked `Guzzle\Http\Message\Request::setIsRedirect()` as deprecated. Use the HistoryPlugin instead.
+* Marked `Guzzle\Http\Message\Request::isRedirect()` as deprecated. Use the HistoryPlugin instead.
+* Marked `Guzzle\Cache\CacheAdapterFactory::factory()` as deprecated
+* Marked 'command.headers', 'command.response_body' and 'command.on_complete' as deprecated for AbstractCommand.
+ These will work through Guzzle 4.0
+* Marked 'request.params' for `Guzzle\Http\Client` as deprecated. Use [request.options][params].
+* Marked `Guzzle\Service\Client::enableMagicMethods()` as deprecated. Magic methods can no longer be disabled on a Guzzle\Service\Client.
+* Marked `Guzzle\Service\Client::getDefaultHeaders()` as deprecated. Use $client->getConfig()->getPath('request.options/headers')`.
+* Marked `Guzzle\Service\Client::setDefaultHeaders()` as deprecated. Use $client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`.
+* Marked `Guzzle\Parser\Url\UrlParser` as deprecated. Just use PHP's `parse_url()` and percent encode your UTF-8.
+* Marked `Guzzle\Common\Collection::inject()` as deprecated.
+* Marked `Guzzle\Plugin\CurlAuth\CurlAuthPlugin` as deprecated. Use `$client->getConfig()->setPath('request.options/auth', array('user', 'pass', 'Basic|Digest');`
+* CacheKeyProviderInterface and DefaultCacheKeyProvider are no longer used. All of this logic is handled in a
+ CacheStorageInterface. These two objects and interface will be removed in a future version.
+* Always setting X-cache headers on cached responses
+* Default cache TTLs are now handled by the CacheStorageInterface of a CachePlugin
+* `CacheStorageInterface::cache($key, Response $response, $ttl = null)` has changed to `cache(RequestInterface
+ $request, Response $response);`
+* `CacheStorageInterface::fetch($key)` has changed to `fetch(RequestInterface $request);`
+* `CacheStorageInterface::delete($key)` has changed to `delete(RequestInterface $request);`
+* Added `CacheStorageInterface::purge($url)`
+* `DefaultRevalidation::__construct(CacheKeyProviderInterface $cacheKey, CacheStorageInterface $cache, CachePlugin
+ $plugin)` has changed to `DefaultRevalidation::__construct(CacheStorageInterface $cache,
+ CanCacheStrategyInterface $canCache = null)`
+* Added `RevalidationInterface::shouldRevalidate(RequestInterface $request, Response $response)`
+
+## 3.6.0 - 2013-05-29
+
+* ServiceDescription now implements ToArrayInterface
+* Added command.hidden_params to blacklist certain headers from being treated as additionalParameters
+* Guzzle can now correctly parse incomplete URLs
+* Mixed casing of headers are now forced to be a single consistent casing across all values for that header.
+* Messages internally use a HeaderCollection object to delegate handling case-insensitive header resolution
+* Removed the whole changedHeader() function system of messages because all header changes now go through addHeader().
+* Specific header implementations can be created for complex headers. When a message creates a header, it uses a
+ HeaderFactory which can map specific headers to specific header classes. There is now a Link header and
+ CacheControl header implementation.
+* Removed from interface: Guzzle\Http\ClientInterface::setUriTemplate
+* Removed from interface: Guzzle\Http\ClientInterface::setCurlMulti()
+* Removed Guzzle\Http\Message\Request::receivedRequestHeader() and implemented this functionality in
+ Guzzle\Http\Curl\RequestMediator
+* Removed the optional $asString parameter from MessageInterface::getHeader(). Just cast the header to a string.
+* Removed the optional $tryChunkedTransfer option from Guzzle\Http\Message\EntityEnclosingRequestInterface
+* Removed the $asObjects argument from Guzzle\Http\Message\MessageInterface::getHeaders()
+* Removed Guzzle\Parser\ParserRegister::get(). Use getParser()
+* Removed Guzzle\Parser\ParserRegister::set(). Use registerParser().
+* All response header helper functions return a string rather than mixing Header objects and strings inconsistently
+* Removed cURL blacklist support. This is no longer necessary now that Expect, Accept, etc. are managed by Guzzle
+ directly via interfaces
+* Removed the injecting of a request object onto a response object. The methods to get and set a request still exist
+ but are a no-op until removed.
+* Most classes that used to require a `Guzzle\Service\Command\CommandInterface` typehint now request a
+ `Guzzle\Service\Command\ArrayCommandInterface`.
+* Added `Guzzle\Http\Message\RequestInterface::startResponse()` to the RequestInterface to handle injecting a response
+ on a request while the request is still being transferred
+* The ability to case-insensitively search for header values
+* Guzzle\Http\Message\Header::hasExactHeader
+* Guzzle\Http\Message\Header::raw. Use getAll()
+* Deprecated cache control specific methods on Guzzle\Http\Message\AbstractMessage. Use the CacheControl header object
+ instead.
+* `Guzzle\Service\Command\CommandInterface` now extends from ToArrayInterface and ArrayAccess
+* Added the ability to cast Model objects to a string to view debug information.
+
+## 3.5.0 - 2013-05-13
+
+* Bug: Fixed a regression so that request responses are parsed only once per oncomplete event rather than multiple times
+* Bug: Better cleanup of one-time events across the board (when an event is meant to fire once, it will now remove
+ itself from the EventDispatcher)
+* Bug: `Guzzle\Log\MessageFormatter` now properly writes "total_time" and "connect_time" values
+* Bug: Cloning an EntityEnclosingRequest now clones the EntityBody too
+* Bug: Fixed an undefined index error when parsing nested JSON responses with a sentAs parameter that reference a
+ non-existent key
+* Bug: All __call() method arguments are now required (helps with mocking frameworks)
+* Deprecating Response::getRequest() and now using a shallow clone of a request object to remove a circular reference
+ to help with refcount based garbage collection of resources created by sending a request
+* Deprecating ZF1 cache and log adapters. These will be removed in the next major version.
+* Deprecating `Response::getPreviousResponse()` (method signature still exists, but it's deprecated). Use the
+ HistoryPlugin for a history.
+* Added a `responseBody` alias for the `response_body` location
+* Refactored internals to no longer rely on Response::getRequest()
+* HistoryPlugin can now be cast to a string
+* HistoryPlugin now logs transactions rather than requests and responses to more accurately keep track of the requests
+ and responses that are sent over the wire
+* Added `getEffectiveUrl()` and `getRedirectCount()` to Response objects
+
+## 3.4.3 - 2013-04-30
+
+* Bug fix: Fixing bug introduced in 3.4.2 where redirect responses are duplicated on the final redirected response
+* Added a check to re-extract the temp cacert bundle from the phar before sending each request
+
+## 3.4.2 - 2013-04-29
+
+* Bug fix: Stream objects now work correctly with "a" and "a+" modes
+* Bug fix: Removing `Transfer-Encoding: chunked` header when a Content-Length is present
+* Bug fix: AsyncPlugin no longer forces HEAD requests
+* Bug fix: DateTime timezones are now properly handled when using the service description schema formatter
+* Bug fix: CachePlugin now properly handles stale-if-error directives when a request to the origin server fails
+* Setting a response on a request will write to the custom request body from the response body if one is specified
+* LogPlugin now writes to php://output when STDERR is undefined
+* Added the ability to set multiple POST files for the same key in a single call
+* application/x-www-form-urlencoded POSTs now use the utf-8 charset by default
+* Added the ability to queue CurlExceptions to the MockPlugin
+* Cleaned up how manual responses are queued on requests (removed "queued_response" and now using request.before_send)
+* Configuration loading now allows remote files
+
+## 3.4.1 - 2013-04-16
+
+* Large refactoring to how CurlMulti handles work. There is now a proxy that sits in front of a pool of CurlMulti
+ handles. This greatly simplifies the implementation, fixes a couple bugs, and provides a small performance boost.
+* Exceptions are now properly grouped when sending requests in parallel
+* Redirects are now properly aggregated when a multi transaction fails
+* Redirects now set the response on the original object even in the event of a failure
+* Bug fix: Model names are now properly set even when using $refs
+* Added support for PHP 5.5's CurlFile to prevent warnings with the deprecated @ syntax
+* Added support for oauth_callback in OAuth signatures
+* Added support for oauth_verifier in OAuth signatures
+* Added support to attempt to retrieve a command first literally, then ucfirst, the with inflection
+
+## 3.4.0 - 2013-04-11
+
+* Bug fix: URLs are now resolved correctly based on https://tools.ietf.org/html/rfc3986#section-5.2. #289
+* Bug fix: Absolute URLs with a path in a service description will now properly override the base URL. #289
+* Bug fix: Parsing a query string with a single PHP array value will now result in an array. #263
+* Bug fix: Better normalization of the User-Agent header to prevent duplicate headers. #264.
+* Bug fix: Added `number` type to service descriptions.
+* Bug fix: empty parameters are removed from an OAuth signature
+* Bug fix: Revalidating a cache entry prefers the Last-Modified over the Date header
+* Bug fix: Fixed "array to string" error when validating a union of types in a service description
+* Bug fix: Removed code that attempted to determine the size of a stream when data is written to the stream
+* Bug fix: Not including an `oauth_token` if the value is null in the OauthPlugin.
+* Bug fix: Now correctly aggregating successful requests and failed requests in CurlMulti when a redirect occurs.
+* The new default CURLOPT_TIMEOUT setting has been increased to 150 seconds so that Guzzle works on poor connections.
+* Added a feature to EntityEnclosingRequest::setBody() that will automatically set the Content-Type of the request if
+ the Content-Type can be determined based on the entity body or the path of the request.
+* Added the ability to overwrite configuration settings in a client when grabbing a throwaway client from a builder.
+* Added support for a PSR-3 LogAdapter.
+* Added a `command.after_prepare` event
+* Added `oauth_callback` parameter to the OauthPlugin
+* Added the ability to create a custom stream class when using a stream factory
+* Added a CachingEntityBody decorator
+* Added support for `additionalParameters` in service descriptions to define how custom parameters are serialized.
+* The bundled SSL certificate is now provided in the phar file and extracted when running Guzzle from a phar.
+* You can now send any EntityEnclosingRequest with POST fields or POST files and cURL will handle creating bodies
+* POST requests using a custom entity body are now treated exactly like PUT requests but with a custom cURL method. This
+ means that the redirect behavior of POST requests with custom bodies will not be the same as POST requests that use
+ POST fields or files (the latter is only used when emulating a form POST in the browser).
+* Lots of cleanup to CurlHandle::factory and RequestFactory::createRequest
+
+## 3.3.1 - 2013-03-10
+
+* Added the ability to create PHP streaming responses from HTTP requests
+* Bug fix: Running any filters when parsing response headers with service descriptions
+* Bug fix: OauthPlugin fixes to allow for multi-dimensional array signing, and sorting parameters before signing
+* Bug fix: Removed the adding of default empty arrays and false Booleans to responses in order to be consistent across
+ response location visitors.
+* Bug fix: Removed the possibility of creating configuration files with circular dependencies
+* RequestFactory::create() now uses the key of a POST file when setting the POST file name
+* Added xmlAllowEmpty to serialize an XML body even if no XML specific parameters are set
+
+## 3.3.0 - 2013-03-03
+
+* A large number of performance optimizations have been made
+* Bug fix: Added 'wb' as a valid write mode for streams
+* Bug fix: `Guzzle\Http\Message\Response::json()` now allows scalar values to be returned
+* Bug fix: Fixed bug in `Guzzle\Http\Message\Response` where wrapping quotes were stripped from `getEtag()`
+* BC: Removed `Guzzle\Http\Utils` class
+* BC: Setting a service description on a client will no longer modify the client's command factories.
+* BC: Emitting IO events from a RequestMediator is now a parameter that must be set in a request's curl options using
+ the 'emit_io' key. This was previously set under a request's parameters using 'curl.emit_io'
+* BC: `Guzzle\Stream\Stream::getWrapper()` and `Guzzle\Stream\Stream::getSteamType()` are no longer converted to
+ lowercase
+* Operation parameter objects are now lazy loaded internally
+* Added ErrorResponsePlugin that can throw errors for responses defined in service description operations' errorResponses
+* Added support for instantiating responseType=class responseClass classes. Classes must implement
+ `Guzzle\Service\Command\ResponseClassInterface`
+* Added support for additionalProperties for top-level parameters in responseType=model responseClasses. These
+ additional properties also support locations and can be used to parse JSON responses where the outermost part of the
+ JSON is an array
+* Added support for nested renaming of JSON models (rename sentAs to name)
+* CachePlugin
+ * Added support for stale-if-error so that the CachePlugin can now serve stale content from the cache on error
+ * Debug headers can now added to cached response in the CachePlugin
+
+## 3.2.0 - 2013-02-14
+
+* CurlMulti is no longer reused globally. A new multi object is created per-client. This helps to isolate clients.
+* URLs with no path no longer contain a "/" by default
+* Guzzle\Http\QueryString does no longer manages the leading "?". This is now handled in Guzzle\Http\Url.
+* BadResponseException no longer includes the full request and response message
+* Adding setData() to Guzzle\Service\Description\ServiceDescriptionInterface
+* Adding getResponseBody() to Guzzle\Http\Message\RequestInterface
+* Various updates to classes to use ServiceDescriptionInterface type hints rather than ServiceDescription
+* Header values can now be normalized into distinct values when multiple headers are combined with a comma separated list
+* xmlEncoding can now be customized for the XML declaration of a XML service description operation
+* Guzzle\Http\QueryString now uses Guzzle\Http\QueryAggregator\QueryAggregatorInterface objects to add custom value
+ aggregation and no longer uses callbacks
+* The URL encoding implementation of Guzzle\Http\QueryString can now be customized
+* Bug fix: Filters were not always invoked for array service description parameters
+* Bug fix: Redirects now use a target response body rather than a temporary response body
+* Bug fix: The default exponential backoff BackoffPlugin was not giving when the request threshold was exceeded
+* Bug fix: Guzzle now takes the first found value when grabbing Cache-Control directives
+
+## 3.1.2 - 2013-01-27
+
+* Refactored how operation responses are parsed. Visitors now include a before() method responsible for parsing the
+ response body. For example, the XmlVisitor now parses the XML response into an array in the before() method.
+* Fixed an issue where cURL would not automatically decompress responses when the Accept-Encoding header was sent
+* CURLOPT_SSL_VERIFYHOST is never set to 1 because it is deprecated (see 5e0ff2ef20f839e19d1eeb298f90ba3598784444)
+* Fixed a bug where redirect responses were not chained correctly using getPreviousResponse()
+* Setting default headers on a client after setting the user-agent will not erase the user-agent setting
+
+## 3.1.1 - 2013-01-20
+
+* Adding wildcard support to Guzzle\Common\Collection::getPath()
+* Adding alias support to ServiceBuilder configs
+* Adding Guzzle\Service\Resource\CompositeResourceIteratorFactory and cleaning up factory interface
+
+## 3.1.0 - 2013-01-12
+
+* BC: CurlException now extends from RequestException rather than BadResponseException
+* BC: Renamed Guzzle\Plugin\Cache\CanCacheStrategyInterface::canCache() to canCacheRequest() and added CanCacheResponse()
+* Added getData to ServiceDescriptionInterface
+* Added context array to RequestInterface::setState()
+* Bug: Removing hard dependency on the BackoffPlugin from Guzzle\Http
+* Bug: Adding required content-type when JSON request visitor adds JSON to a command
+* Bug: Fixing the serialization of a service description with custom data
+* Made it easier to deal with exceptions thrown when transferring commands or requests in parallel by providing
+ an array of successful and failed responses
+* Moved getPath from Guzzle\Service\Resource\Model to Guzzle\Common\Collection
+* Added Guzzle\Http\IoEmittingEntityBody
+* Moved command filtration from validators to location visitors
+* Added `extends` attributes to service description parameters
+* Added getModels to ServiceDescriptionInterface
+
+## 3.0.7 - 2012-12-19
+
+* Fixing phar detection when forcing a cacert to system if null or true
+* Allowing filename to be passed to `Guzzle\Http\Message\Request::setResponseBody()`
+* Cleaning up `Guzzle\Common\Collection::inject` method
+* Adding a response_body location to service descriptions
+
+## 3.0.6 - 2012-12-09
+
+* CurlMulti performance improvements
+* Adding setErrorResponses() to Operation
+* composer.json tweaks
+
+## 3.0.5 - 2012-11-18
+
+* Bug: Fixing an infinite recursion bug caused from revalidating with the CachePlugin
+* Bug: Response body can now be a string containing "0"
+* Bug: Using Guzzle inside of a phar uses system by default but now allows for a custom cacert
+* Bug: QueryString::fromString now properly parses query string parameters that contain equal signs
+* Added support for XML attributes in service description responses
+* DefaultRequestSerializer now supports array URI parameter values for URI template expansion
+* Added better mimetype guessing to requests and post files
+
+## 3.0.4 - 2012-11-11
+
+* Bug: Fixed a bug when adding multiple cookies to a request to use the correct glue value
+* Bug: Cookies can now be added that have a name, domain, or value set to "0"
+* Bug: Using the system cacert bundle when using the Phar
+* Added json and xml methods to Response to make it easier to parse JSON and XML response data into data structures
+* Enhanced cookie jar de-duplication
+* Added the ability to enable strict cookie jars that throw exceptions when invalid cookies are added
+* Added setStream to StreamInterface to actually make it possible to implement custom rewind behavior for entity bodies
+* Added the ability to create any sort of hash for a stream rather than just an MD5 hash
+
+## 3.0.3 - 2012-11-04
+
+* Implementing redirects in PHP rather than cURL
+* Added PECL URI template extension and using as default parser if available
+* Bug: Fixed Content-Length parsing of Response factory
+* Adding rewind() method to entity bodies and streams. Allows for custom rewinding of non-repeatable streams.
+* Adding ToArrayInterface throughout library
+* Fixing OauthPlugin to create unique nonce values per request
+
+## 3.0.2 - 2012-10-25
+
+* Magic methods are enabled by default on clients
+* Magic methods return the result of a command
+* Service clients no longer require a base_url option in the factory
+* Bug: Fixed an issue with URI templates where null template variables were being expanded
+
+## 3.0.1 - 2012-10-22
+
+* Models can now be used like regular collection objects by calling filter, map, etc.
+* Models no longer require a Parameter structure or initial data in the constructor
+* Added a custom AppendIterator to get around a PHP bug with the `\AppendIterator`
+
+## 3.0.0 - 2012-10-15
+
+* Rewrote service description format to be based on Swagger
+ * Now based on JSON schema
+ * Added nested input structures and nested response models
+ * Support for JSON and XML input and output models
+ * Renamed `commands` to `operations`
+ * Removed dot class notation
+ * Removed custom types
+* Broke the project into smaller top-level namespaces to be more component friendly
+* Removed support for XML configs and descriptions. Use arrays or JSON files.
+* Removed the Validation component and Inspector
+* Moved all cookie code to Guzzle\Plugin\Cookie
+* Magic methods on a Guzzle\Service\Client now return the command un-executed.
+* Calling getResult() or getResponse() on a command will lazily execute the command if needed.
+* Now shipping with cURL's CA certs and using it by default
+* Added previousResponse() method to response objects
+* No longer sending Accept and Accept-Encoding headers on every request
+* Only sending an Expect header by default when a payload is greater than 1MB
+* Added/moved client options:
+ * curl.blacklist to curl.option.blacklist
+ * Added ssl.certificate_authority
+* Added a Guzzle\Iterator component
+* Moved plugins from Guzzle\Http\Plugin to Guzzle\Plugin
+* Added a more robust backoff retry strategy (replaced the ExponentialBackoffPlugin)
+* Added a more robust caching plugin
+* Added setBody to response objects
+* Updating LogPlugin to use a more flexible MessageFormatter
+* Added a completely revamped build process
+* Cleaning up Collection class and removing default values from the get method
+* Fixed ZF2 cache adapters
+
+## 2.8.8 - 2012-10-15
+
+* Bug: Fixed a cookie issue that caused dot prefixed domains to not match where popular browsers did
+
+## 2.8.7 - 2012-09-30
+
+* Bug: Fixed config file aliases for JSON includes
+* Bug: Fixed cookie bug on a request object by using CookieParser to parse cookies on requests
+* Bug: Removing the path to a file when sending a Content-Disposition header on a POST upload
+* Bug: Hardening request and response parsing to account for missing parts
+* Bug: Fixed PEAR packaging
+* Bug: Fixed Request::getInfo
+* Bug: Fixed cases where CURLM_CALL_MULTI_PERFORM return codes were causing curl transactions to fail
+* Adding the ability for the namespace Iterator factory to look in multiple directories
+* Added more getters/setters/removers from service descriptions
+* Added the ability to remove POST fields from OAuth signatures
+* OAuth plugin now supports 2-legged OAuth
+
+## 2.8.6 - 2012-09-05
+
+* Added the ability to modify and build service descriptions
+* Added the use of visitors to apply parameters to locations in service descriptions using the dynamic command
+* Added a `json` parameter location
+* Now allowing dot notation for classes in the CacheAdapterFactory
+* Using the union of two arrays rather than an array_merge when extending service builder services and service params
+* Ensuring that a service is a string before doing strpos() checks on it when substituting services for references
+ in service builder config files.
+* Services defined in two different config files that include one another will by default replace the previously
+ defined service, but you can now create services that extend themselves and merge their settings over the previous
+* The JsonLoader now supports aliasing filenames with different filenames. This allows you to alias something like
+ '_default' with a default JSON configuration file.
+
+## 2.8.5 - 2012-08-29
+
+* Bug: Suppressed empty arrays from URI templates
+* Bug: Added the missing $options argument from ServiceDescription::factory to enable caching
+* Added support for HTTP responses that do not contain a reason phrase in the start-line
+* AbstractCommand commands are now invokable
+* Added a way to get the data used when signing an Oauth request before a request is sent
+
+## 2.8.4 - 2012-08-15
+
+* Bug: Custom delay time calculations are no longer ignored in the ExponentialBackoffPlugin
+* Added the ability to transfer entity bodies as a string rather than streamed. This gets around curl error 65. Set `body_as_string` in a request's curl options to enable.
+* Added a StreamInterface, EntityBodyInterface, and added ftell() to Guzzle\Common\Stream
+* Added an AbstractEntityBodyDecorator and a ReadLimitEntityBody decorator to transfer only a subset of a decorated stream
+* Stream and EntityBody objects will now return the file position to the previous position after a read required operation (e.g. getContentMd5())
+* Added additional response status codes
+* Removed SSL information from the default User-Agent header
+* DELETE requests can now send an entity body
+* Added an EventDispatcher to the ExponentialBackoffPlugin and added an ExponentialBackoffLogger to log backoff retries
+* Added the ability of the MockPlugin to consume mocked request bodies
+* LogPlugin now exposes request and response objects in the extras array
+
+## 2.8.3 - 2012-07-30
+
+* Bug: Fixed a case where empty POST requests were sent as GET requests
+* Bug: Fixed a bug in ExponentialBackoffPlugin that caused fatal errors when retrying an EntityEnclosingRequest that does not have a body
+* Bug: Setting the response body of a request to null after completing a request, not when setting the state of a request to new
+* Added multiple inheritance to service description commands
+* Added an ApiCommandInterface and added `getParamNames()` and `hasParam()`
+* Removed the default 2mb size cutoff from the Md5ValidatorPlugin so that it now defaults to validating everything
+* Changed CurlMulti::perform to pass a smaller timeout to CurlMulti::executeHandles
+
+## 2.8.2 - 2012-07-24
+
+* Bug: Query string values set to 0 are no longer dropped from the query string
+* Bug: A Collection object is no longer created each time a call is made to `Guzzle\Service\Command\AbstractCommand::getRequestHeaders()`
+* Bug: `+` is now treated as an encoded space when parsing query strings
+* QueryString and Collection performance improvements
+* Allowing dot notation for class paths in filters attribute of a service descriptions
+
+## 2.8.1 - 2012-07-16
+
+* Loosening Event Dispatcher dependency
+* POST redirects can now be customized using CURLOPT_POSTREDIR
+
+## 2.8.0 - 2012-07-15
+
+* BC: Guzzle\Http\Query
+ * Query strings with empty variables will always show an equal sign unless the variable is set to QueryString::BLANK (e.g. ?acl= vs ?acl)
+ * Changed isEncodingValues() and isEncodingFields() to isUrlEncoding()
+ * Changed setEncodeValues(bool) and setEncodeFields(bool) to useUrlEncoding(bool)
+ * Changed the aggregation functions of QueryString to be static methods
+ * Can now use fromString() with querystrings that have a leading ?
+* cURL configuration values can be specified in service descriptions using `curl.` prefixed parameters
+* Content-Length is set to 0 before emitting the request.before_send event when sending an empty request body
+* Cookies are no longer URL decoded by default
+* Bug: URI template variables set to null are no longer expanded
+
+## 2.7.2 - 2012-07-02
+
+* BC: Moving things to get ready for subtree splits. Moving Inflection into Common. Moving Guzzle\Http\Parser to Guzzle\Parser.
+* BC: Removing Guzzle\Common\Batch\Batch::count() and replacing it with isEmpty()
+* CachePlugin now allows for a custom request parameter function to check if a request can be cached
+* Bug fix: CachePlugin now only caches GET and HEAD requests by default
+* Bug fix: Using header glue when transferring headers over the wire
+* Allowing deeply nested arrays for composite variables in URI templates
+* Batch divisors can now return iterators or arrays
+
+## 2.7.1 - 2012-06-26
+
+* Minor patch to update version number in UA string
+* Updating build process
+
+## 2.7.0 - 2012-06-25
+
+* BC: Inflection classes moved to Guzzle\Inflection. No longer static methods. Can now inject custom inflectors into classes.
+* BC: Removed magic setX methods from commands
+* BC: Magic methods mapped to service description commands are now inflected in the command factory rather than the client __call() method
+* Verbose cURL options are no longer enabled by default. Set curl.debug to true on a client to enable.
+* Bug: Now allowing colons in a response start-line (e.g. HTTP/1.1 503 Service Unavailable: Back-end server is at capacity)
+* Guzzle\Service\Resource\ResourceIteratorApplyBatched now internally uses the Guzzle\Common\Batch namespace
+* Added Guzzle\Service\Plugin namespace and a PluginCollectionPlugin
+* Added the ability to set POST fields and files in a service description
+* Guzzle\Http\EntityBody::factory() now accepts objects with a __toString() method
+* Adding a command.before_prepare event to clients
+* Added BatchClosureTransfer and BatchClosureDivisor
+* BatchTransferException now includes references to the batch divisor and transfer strategies
+* Fixed some tests so that they pass more reliably
+* Added Guzzle\Common\Log\ArrayLogAdapter
+
+## 2.6.6 - 2012-06-10
+
+* BC: Removing Guzzle\Http\Plugin\BatchQueuePlugin
+* BC: Removing Guzzle\Service\Command\CommandSet
+* Adding generic batching system (replaces the batch queue plugin and command set)
+* Updating ZF cache and log adapters and now using ZF's composer repository
+* Bug: Setting the name of each ApiParam when creating through an ApiCommand
+* Adding result_type, result_doc, deprecated, and doc_url to service descriptions
+* Bug: Changed the default cookie header casing back to 'Cookie'
+
+## 2.6.5 - 2012-06-03
+
+* BC: Renaming Guzzle\Http\Message\RequestInterface::getResourceUri() to getResource()
+* BC: Removing unused AUTH_BASIC and AUTH_DIGEST constants from
+* BC: Guzzle\Http\Cookie is now used to manage Set-Cookie data, not Cookie data
+* BC: Renaming methods in the CookieJarInterface
+* Moving almost all cookie logic out of the CookiePlugin and into the Cookie or CookieJar implementations
+* Making the default glue for HTTP headers ';' instead of ','
+* Adding a removeValue to Guzzle\Http\Message\Header
+* Adding getCookies() to request interface.
+* Making it easier to add event subscribers to HasDispatcherInterface classes. Can now directly call addSubscriber()
+
+## 2.6.4 - 2012-05-30
+
+* BC: Cleaning up how POST files are stored in EntityEnclosingRequest objects. Adding PostFile class.
+* BC: Moving ApiCommand specific functionality from the Inspector and on to the ApiCommand
+* Bug: Fixing magic method command calls on clients
+* Bug: Email constraint only validates strings
+* Bug: Aggregate POST fields when POST files are present in curl handle
+* Bug: Fixing default User-Agent header
+* Bug: Only appending or prepending parameters in commands if they are specified
+* Bug: Not requiring response reason phrases or status codes to match a predefined list of codes
+* Allowing the use of dot notation for class namespaces when using instance_of constraint
+* Added any_match validation constraint
+* Added an AsyncPlugin
+* Passing request object to the calculateWait method of the ExponentialBackoffPlugin
+* Allowing the result of a command object to be changed
+* Parsing location and type sub values when instantiating a service description rather than over and over at runtime
+
+## 2.6.3 - 2012-05-23
+
+* [BC] Guzzle\Common\FromConfigInterface no longer requires any config options.
+* [BC] Refactoring how POST files are stored on an EntityEnclosingRequest. They are now separate from POST fields.
+* You can now use an array of data when creating PUT request bodies in the request factory.
+* Removing the requirement that HTTPS requests needed a Cache-Control: public directive to be cacheable.
+* [Http] Adding support for Content-Type in multipart POST uploads per upload
+* [Http] Added support for uploading multiple files using the same name (foo[0], foo[1])
+* Adding more POST data operations for easier manipulation of POST data.
+* You can now set empty POST fields.
+* The body of a request is only shown on EntityEnclosingRequest objects that do not use POST files.
+* Split the Guzzle\Service\Inspector::validateConfig method into two methods. One to initialize when a command is created, and one to validate.
+* CS updates
+
+## 2.6.2 - 2012-05-19
+
+* [Http] Better handling of nested scope requests in CurlMulti. Requests are now always prepares in the send() method rather than the addRequest() method.
+
+## 2.6.1 - 2012-05-19
+
+* [BC] Removing 'path' support in service descriptions. Use 'uri'.
+* [BC] Guzzle\Service\Inspector::parseDocBlock is now protected. Adding getApiParamsForClass() with cache.
+* [BC] Removing Guzzle\Common\NullObject. Use https://github.com/mtdowling/NullObject if you need it.
+* [BC] Removing Guzzle\Common\XmlElement.
+* All commands, both dynamic and concrete, have ApiCommand objects.
+* Adding a fix for CurlMulti so that if all of the connections encounter some sort of curl error, then the loop exits.
+* Adding checks to EntityEnclosingRequest so that empty POST files and fields are ignored.
+* Making the method signature of Guzzle\Service\Builder\ServiceBuilder::factory more flexible.
+
+## 2.6.0 - 2012-05-15
+
+* [BC] Moving Guzzle\Service\Builder to Guzzle\Service\Builder\ServiceBuilder
+* [BC] Executing a Command returns the result of the command rather than the command
+* [BC] Moving all HTTP parsing logic to Guzzle\Http\Parsers. Allows for faster C implementations if needed.
+* [BC] Changing the Guzzle\Http\Message\Response::setProtocol() method to accept a protocol and version in separate args.
+* [BC] Moving ResourceIterator* to Guzzle\Service\Resource
+* [BC] Completely refactored ResourceIterators to iterate over a cloned command object
+* [BC] Moved Guzzle\Http\UriTemplate to Guzzle\Http\Parser\UriTemplate\UriTemplate
+* [BC] Guzzle\Guzzle is now deprecated
+* Moving Guzzle\Common\Guzzle::inject to Guzzle\Common\Collection::inject
+* Adding Guzzle\Version class to give version information about Guzzle
+* Adding Guzzle\Http\Utils class to provide getDefaultUserAgent() and getHttpDate()
+* Adding Guzzle\Curl\CurlVersion to manage caching curl_version() data
+* ServiceDescription and ServiceBuilder are now cacheable using similar configs
+* Changing the format of XML and JSON service builder configs. Backwards compatible.
+* Cleaned up Cookie parsing
+* Trimming the default Guzzle User-Agent header
+* Adding a setOnComplete() method to Commands that is called when a command completes
+* Keeping track of requests that were mocked in the MockPlugin
+* Fixed a caching bug in the CacheAdapterFactory
+* Inspector objects can be injected into a Command object
+* Refactoring a lot of code and tests to be case insensitive when dealing with headers
+* Adding Guzzle\Http\Message\HeaderComparison for easy comparison of HTTP headers using a DSL
+* Adding the ability to set global option overrides to service builder configs
+* Adding the ability to include other service builder config files from within XML and JSON files
+* Moving the parseQuery method out of Url and on to QueryString::fromString() as a static factory method.
+
+## 2.5.0 - 2012-05-08
+
+* Major performance improvements
+* [BC] Simplifying Guzzle\Common\Collection. Please check to see if you are using features that are now deprecated.
+* [BC] Using a custom validation system that allows a flyweight implementation for much faster validation. No longer using Symfony2 Validation component.
+* [BC] No longer supporting "{{ }}" for injecting into command or UriTemplates. Use "{}"
+* Added the ability to passed parameters to all requests created by a client
+* Added callback functionality to the ExponentialBackoffPlugin
+* Using microtime in ExponentialBackoffPlugin to allow more granular backoff strategies.
+* Rewinding request stream bodies when retrying requests
+* Exception is thrown when JSON response body cannot be decoded
+* Added configurable magic method calls to clients and commands. This is off by default.
+* Fixed a defect that added a hash to every parsed URL part
+* Fixed duplicate none generation for OauthPlugin.
+* Emitting an event each time a client is generated by a ServiceBuilder
+* Using an ApiParams object instead of a Collection for parameters of an ApiCommand
+* cache.* request parameters should be renamed to params.cache.*
+* Added the ability to set arbitrary curl options on requests (disable_wire, progress, etc.). See CurlHandle.
+* Added the ability to disable type validation of service descriptions
+* ServiceDescriptions and ServiceBuilders are now Serializable
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/LICENSE
new file mode 100644
index 0000000..fd2375d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/LICENSE
@@ -0,0 +1,27 @@
+The MIT License (MIT)
+
+Copyright (c) 2011 Michael Dowling <mtdowling@gmail.com>
+Copyright (c) 2012 Jeremy Lindblom <jeremeamia@gmail.com>
+Copyright (c) 2014 Graham Campbell <hello@gjcampbell.co.uk>
+Copyright (c) 2015 Márk Sági-Kazár <mark.sagikazar@gmail.com>
+Copyright (c) 2015 Tobias Schultze <webmaster@tubo-world.de>
+Copyright (c) 2016 Tobias Nyholm <tobias.nyholm@gmail.com>
+Copyright (c) 2016 George Mponos <gmponos@gmail.com>
+
+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/guzzlehttp/guzzle/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/README.md
new file mode 100644
index 0000000..f287fa9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/README.md
@@ -0,0 +1,94 @@
+
+
+# Guzzle, PHP HTTP client
+
+[](https://github.com/guzzle/guzzle/releases)
+[](https://github.com/guzzle/guzzle/actions?query=workflow%3ACI)
+[](https://packagist.org/packages/guzzlehttp/guzzle)
+
+Guzzle is a PHP HTTP client that makes it easy to send HTTP requests and
+trivial to integrate with web services.
+
+- Simple interface for building query strings, POST requests, streaming large
+ uploads, streaming large downloads, using HTTP cookies, uploading JSON data,
+ etc...
+- Can send both synchronous and asynchronous requests using the same interface.
+- Uses PSR-7 interfaces for requests, responses, and streams. This allows you
+ to utilize other PSR-7 compatible libraries with Guzzle.
+- Supports PSR-18 allowing interoperability between other PSR-18 HTTP Clients.
+- Abstracts away the underlying HTTP transport, allowing you to write
+ environment and transport agnostic code; i.e., no hard dependency on cURL,
+ PHP streams, sockets, or non-blocking event loops.
+- Middleware system allows you to augment and compose client behavior.
+
+```php
+$client = new \GuzzleHttp\Client();
+$response = $client->request('GET', 'https://api.github.com/repos/guzzle/guzzle');
+
+echo $response->getStatusCode(); // 200
+echo $response->getHeaderLine('content-type'); // 'application/json; charset=utf8'
+echo $response->getBody(); // '{"id": 1420053, "name": "guzzle", ...}'
+
+// Send an asynchronous request.
+$request = new \GuzzleHttp\Psr7\Request('GET', 'http://httpbin.org');
+$promise = $client->sendAsync($request)->then(function ($response) {
+ echo 'I completed! ' . $response->getBody();
+});
+
+$promise->wait();
+```
+
+## Help and docs
+
+We use GitHub issues only to discuss bugs and new features. For support please refer to:
+
+- [Documentation](https://docs.guzzlephp.org)
+- [Stack Overflow](https://stackoverflow.com/questions/tagged/guzzle)
+- [#guzzle](https://app.slack.com/client/T0D2S9JCT/CE6UAAKL4) channel on [PHP-HTTP Slack](https://slack.httplug.io/)
+- [Gitter](https://gitter.im/guzzle/guzzle)
+
+
+## Installing Guzzle
+
+The recommended way to install Guzzle is through
+[Composer](https://getcomposer.org/).
+
+```bash
+composer require guzzlehttp/guzzle
+```
+
+
+## Version Guidance
+
+| Version | Status | Packagist | Namespace | Repo | Docs | PSR-7 | PHP Version |
+|---------|----------------|---------------------|--------------|---------------------|---------------------|-------|--------------|
+| 3.x | EOL | `guzzle/guzzle` | `Guzzle` | [v3][guzzle-3-repo] | [v3][guzzle-3-docs] | No | >=5.3.3,<7.0 |
+| 4.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v4][guzzle-4-repo] | N/A | No | >=5.4,<7.0 |
+| 5.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v5][guzzle-5-repo] | [v5][guzzle-5-docs] | No | >=5.4,<7.4 |
+| 6.x | Security fixes | `guzzlehttp/guzzle` | `GuzzleHttp` | [v6][guzzle-6-repo] | [v6][guzzle-6-docs] | Yes | >=5.5,<8.0 |
+| 7.x | Latest | `guzzlehttp/guzzle` | `GuzzleHttp` | [v7][guzzle-7-repo] | [v7][guzzle-7-docs] | Yes | >=7.2.5,<8.2 |
+
+[guzzle-3-repo]: https://github.com/guzzle/guzzle3
+[guzzle-4-repo]: https://github.com/guzzle/guzzle/tree/4.x
+[guzzle-5-repo]: https://github.com/guzzle/guzzle/tree/5.3
+[guzzle-6-repo]: https://github.com/guzzle/guzzle/tree/6.5
+[guzzle-7-repo]: https://github.com/guzzle/guzzle
+[guzzle-3-docs]: https://guzzle3.readthedocs.io/
+[guzzle-5-docs]: https://docs.guzzlephp.org/en/5.3/
+[guzzle-6-docs]: https://docs.guzzlephp.org/en/6.5/
+[guzzle-7-docs]: https://docs.guzzlephp.org/en/latest/
+
+
+## Security
+
+If you discover a security vulnerability within this package, please send an email to security@tidelift.com. All security vulnerabilities will be promptly addressed. Please do not disclose security-related issues publicly until a fix has been announced. Please see [Security Policy](https://github.com/guzzle/guzzle/security/policy) for more information.
+
+## License
+
+Guzzle is made available under the MIT License (MIT). Please see [License File](LICENSE) for more information.
+
+## For Enterprise
+
+Available as part of the Tidelift Subscription
+
+The maintainers of Guzzle and thousands of other packages are working with Tidelift to deliver commercial support and maintenance for the open source dependencies you use to build your applications. Save time, reduce risk, and improve code health, while paying the maintainers of the exact dependencies you use. [Learn more.](https://tidelift.com/subscription/pkg/packagist-guzzlehttp-guzzle?utm_source=packagist-guzzlehttp-guzzle&utm_medium=referral&utm_campaign=enterprise&utm_term=repo)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/UPGRADING.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/UPGRADING.md
new file mode 100644
index 0000000..45417a7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/UPGRADING.md
@@ -0,0 +1,1253 @@
+Guzzle Upgrade Guide
+====================
+
+6.0 to 7.0
+----------
+
+In order to take advantage of the new features of PHP, Guzzle dropped the support
+of PHP 5. The minimum supported PHP version is now PHP 7.2. Type hints and return
+types for functions and methods have been added wherever possible.
+
+Please make sure:
+- You are calling a function or a method with the correct type.
+- If you extend a class of Guzzle; update all signatures on methods you override.
+
+#### Other backwards compatibility breaking changes
+
+- Class `GuzzleHttp\UriTemplate` is removed.
+- Class `GuzzleHttp\Exception\SeekException` is removed.
+- Classes `GuzzleHttp\Exception\BadResponseException`, `GuzzleHttp\Exception\ClientException`,
+ `GuzzleHttp\Exception\ServerException` can no longer be initialized with an empty
+ Response as argument.
+- Class `GuzzleHttp\Exception\ConnectException` now extends `GuzzleHttp\Exception\TransferException`
+ instead of `GuzzleHttp\Exception\RequestException`.
+- Function `GuzzleHttp\Exception\ConnectException::getResponse()` is removed.
+- Function `GuzzleHttp\Exception\ConnectException::hasResponse()` is removed.
+- Constant `GuzzleHttp\ClientInterface::VERSION` is removed. Added `GuzzleHttp\ClientInterface::MAJOR_VERSION` instead.
+- Function `GuzzleHttp\Exception\RequestException::getResponseBodySummary` is removed.
+ Use `\GuzzleHttp\Psr7\get_message_body_summary` as an alternative.
+- Function `GuzzleHttp\Cookie\CookieJar::getCookieValue` is removed.
+- Request option `exception` is removed. Please use `http_errors`.
+- Request option `save_to` is removed. Please use `sink`.
+- Pool option `pool_size` is removed. Please use `concurrency`.
+- We now look for environment variables in the `$_SERVER` super global, due to thread safety issues with `getenv`. We continue to fallback to `getenv` in CLI environments, for maximum compatibility.
+- The `get`, `head`, `put`, `post`, `patch`, `delete`, `getAsync`, `headAsync`, `putAsync`, `postAsync`, `patchAsync`, and `deleteAsync` methods are now implemented as genuine methods on `GuzzleHttp\Client`, with strong typing. The original `__call` implementation remains unchanged for now, for maximum backwards compatibility, but won't be invoked under normal operation.
+- The `log` middleware will log the errors with level `error` instead of `notice`
+- Support for international domain names (IDN) is now disabled by default, and enabling it requires installing ext-intl, linked against a modern version of the C library (ICU 4.6 or higher).
+
+#### Native functions calls
+
+All internal native functions calls of Guzzle are now prefixed with a slash. This
+change makes it impossible for method overloading by other libraries or applications.
+Example:
+
+```php
+// Before:
+curl_version();
+
+// After:
+\curl_version();
+```
+
+For the full diff you can check [here](https://github.com/guzzle/guzzle/compare/6.5.4..master).
+
+5.0 to 6.0
+----------
+
+Guzzle now uses [PSR-7](https://www.php-fig.org/psr/psr-7/) for HTTP messages.
+Due to the fact that these messages are immutable, this prompted a refactoring
+of Guzzle to use a middleware based system rather than an event system. Any
+HTTP message interaction (e.g., `GuzzleHttp\Message\Request`) need to be
+updated to work with the new immutable PSR-7 request and response objects. Any
+event listeners or subscribers need to be updated to become middleware
+functions that wrap handlers (or are injected into a
+`GuzzleHttp\HandlerStack`).
+
+- Removed `GuzzleHttp\BatchResults`
+- Removed `GuzzleHttp\Collection`
+- Removed `GuzzleHttp\HasDataTrait`
+- Removed `GuzzleHttp\ToArrayInterface`
+- The `guzzlehttp/streams` dependency has been removed. Stream functionality
+ is now present in the `GuzzleHttp\Psr7` namespace provided by the
+ `guzzlehttp/psr7` package.
+- Guzzle no longer uses ReactPHP promises and now uses the
+ `guzzlehttp/promises` library. We use a custom promise library for three
+ significant reasons:
+ 1. React promises (at the time of writing this) are recursive. Promise
+ chaining and promise resolution will eventually blow the stack. Guzzle
+ promises are not recursive as they use a sort of trampolining technique.
+ Note: there has been movement in the React project to modify promises to
+ no longer utilize recursion.
+ 2. Guzzle needs to have the ability to synchronously block on a promise to
+ wait for a result. Guzzle promises allows this functionality (and does
+ not require the use of recursion).
+ 3. Because we need to be able to wait on a result, doing so using React
+ promises requires wrapping react promises with RingPHP futures. This
+ overhead is no longer needed, reducing stack sizes, reducing complexity,
+ and improving performance.
+- `GuzzleHttp\Mimetypes` has been moved to a function in
+ `GuzzleHttp\Psr7\mimetype_from_extension` and
+ `GuzzleHttp\Psr7\mimetype_from_filename`.
+- `GuzzleHttp\Query` and `GuzzleHttp\QueryParser` have been removed. Query
+ strings must now be passed into request objects as strings, or provided to
+ the `query` request option when creating requests with clients. The `query`
+ option uses PHP's `http_build_query` to convert an array to a string. If you
+ need a different serialization technique, you will need to pass the query
+ string in as a string. There are a couple helper functions that will make
+ working with query strings easier: `GuzzleHttp\Psr7\parse_query` and
+ `GuzzleHttp\Psr7\build_query`.
+- Guzzle no longer has a dependency on RingPHP. Due to the use of a middleware
+ system based on PSR-7, using RingPHP and it's middleware system as well adds
+ more complexity than the benefits it provides. All HTTP handlers that were
+ present in RingPHP have been modified to work directly with PSR-7 messages
+ and placed in the `GuzzleHttp\Handler` namespace. This significantly reduces
+ complexity in Guzzle, removes a dependency, and improves performance. RingPHP
+ will be maintained for Guzzle 5 support, but will no longer be a part of
+ Guzzle 6.
+- As Guzzle now uses a middleware based systems the event system and RingPHP
+ integration has been removed. Note: while the event system has been removed,
+ it is possible to add your own type of event system that is powered by the
+ middleware system.
+ - Removed the `Event` namespace.
+ - Removed the `Subscriber` namespace.
+ - Removed `Transaction` class
+ - Removed `RequestFsm`
+ - Removed `RingBridge`
+ - `GuzzleHttp\Subscriber\Cookie` is now provided by
+ `GuzzleHttp\Middleware::cookies`
+ - `GuzzleHttp\Subscriber\HttpError` is now provided by
+ `GuzzleHttp\Middleware::httpError`
+ - `GuzzleHttp\Subscriber\History` is now provided by
+ `GuzzleHttp\Middleware::history`
+ - `GuzzleHttp\Subscriber\Mock` is now provided by
+ `GuzzleHttp\Handler\MockHandler`
+ - `GuzzleHttp\Subscriber\Prepare` is now provided by
+ `GuzzleHttp\PrepareBodyMiddleware`
+ - `GuzzleHttp\Subscriber\Redirect` is now provided by
+ `GuzzleHttp\RedirectMiddleware`
+- Guzzle now uses `Psr\Http\Message\UriInterface` (implements in
+ `GuzzleHttp\Psr7\Uri`) for URI support. `GuzzleHttp\Url` is now gone.
+- Static functions in `GuzzleHttp\Utils` have been moved to namespaced
+ functions under the `GuzzleHttp` namespace. This requires either a Composer
+ based autoloader or you to include functions.php.
+- `GuzzleHttp\ClientInterface::getDefaultOption` has been renamed to
+ `GuzzleHttp\ClientInterface::getConfig`.
+- `GuzzleHttp\ClientInterface::setDefaultOption` has been removed.
+- The `json` and `xml` methods of response objects has been removed. With the
+ migration to strictly adhering to PSR-7 as the interface for Guzzle messages,
+ adding methods to message interfaces would actually require Guzzle messages
+ to extend from PSR-7 messages rather then work with them directly.
+
+## Migrating to middleware
+
+The change to PSR-7 unfortunately required significant refactoring to Guzzle
+due to the fact that PSR-7 messages are immutable. Guzzle 5 relied on an event
+system from plugins. The event system relied on mutability of HTTP messages and
+side effects in order to work. With immutable messages, you have to change your
+workflow to become more about either returning a value (e.g., functional
+middlewares) or setting a value on an object. Guzzle v6 has chosen the
+functional middleware approach.
+
+Instead of using the event system to listen for things like the `before` event,
+you now create a stack based middleware function that intercepts a request on
+the way in and the promise of the response on the way out. This is a much
+simpler and more predictable approach than the event system and works nicely
+with PSR-7 middleware. Due to the use of promises, the middleware system is
+also asynchronous.
+
+v5:
+
+```php
+use GuzzleHttp\Event\BeforeEvent;
+$client = new GuzzleHttp\Client();
+// Get the emitter and listen to the before event.
+$client->getEmitter()->on('before', function (BeforeEvent $e) {
+ // Guzzle v5 events relied on mutation
+ $e->getRequest()->setHeader('X-Foo', 'Bar');
+});
+```
+
+v6:
+
+In v6, you can modify the request before it is sent using the `mapRequest`
+middleware. The idiomatic way in v6 to modify the request/response lifecycle is
+to setup a handler middleware stack up front and inject the handler into a
+client.
+
+```php
+use GuzzleHttp\Middleware;
+// Create a handler stack that has all of the default middlewares attached
+$handler = GuzzleHttp\HandlerStack::create();
+// Push the handler onto the handler stack
+$handler->push(Middleware::mapRequest(function (RequestInterface $request) {
+ // Notice that we have to return a request object
+ return $request->withHeader('X-Foo', 'Bar');
+}));
+// Inject the handler into the client
+$client = new GuzzleHttp\Client(['handler' => $handler]);
+```
+
+## POST Requests
+
+This version added the [`form_params`](http://guzzle.readthedocs.org/en/latest/request-options.html#form_params)
+and `multipart` request options. `form_params` is an associative array of
+strings or array of strings and is used to serialize an
+`application/x-www-form-urlencoded` POST request. The
+[`multipart`](http://guzzle.readthedocs.org/en/latest/request-options.html#multipart)
+option is now used to send a multipart/form-data POST request.
+
+`GuzzleHttp\Post\PostFile` has been removed. Use the `multipart` option to add
+POST files to a multipart/form-data request.
+
+The `body` option no longer accepts an array to send POST requests. Please use
+`multipart` or `form_params` instead.
+
+The `base_url` option has been renamed to `base_uri`.
+
+4.x to 5.0
+----------
+
+## Rewritten Adapter Layer
+
+Guzzle now uses [RingPHP](http://ringphp.readthedocs.org/en/latest) to send
+HTTP requests. The `adapter` option in a `GuzzleHttp\Client` constructor
+is still supported, but it has now been renamed to `handler`. Instead of
+passing a `GuzzleHttp\Adapter\AdapterInterface`, you must now pass a PHP
+`callable` that follows the RingPHP specification.
+
+## Removed Fluent Interfaces
+
+[Fluent interfaces were removed](https://ocramius.github.io/blog/fluent-interfaces-are-evil/)
+from the following classes:
+
+- `GuzzleHttp\Collection`
+- `GuzzleHttp\Url`
+- `GuzzleHttp\Query`
+- `GuzzleHttp\Post\PostBody`
+- `GuzzleHttp\Cookie\SetCookie`
+
+## Removed functions.php
+
+Removed "functions.php", so that Guzzle is truly PSR-4 compliant. The following
+functions can be used as replacements.
+
+- `GuzzleHttp\json_decode` -> `GuzzleHttp\Utils::jsonDecode`
+- `GuzzleHttp\get_path` -> `GuzzleHttp\Utils::getPath`
+- `GuzzleHttp\Utils::setPath` -> `GuzzleHttp\set_path`
+- `GuzzleHttp\Pool::batch` -> `GuzzleHttp\batch`. This function is, however,
+ deprecated in favor of using `GuzzleHttp\Pool::batch()`.
+
+The "procedural" global client has been removed with no replacement (e.g.,
+`GuzzleHttp\get()`, `GuzzleHttp\post()`, etc.). Use a `GuzzleHttp\Client`
+object as a replacement.
+
+## `throwImmediately` has been removed
+
+The concept of "throwImmediately" has been removed from exceptions and error
+events. This control mechanism was used to stop a transfer of concurrent
+requests from completing. This can now be handled by throwing the exception or
+by cancelling a pool of requests or each outstanding future request
+individually.
+
+## headers event has been removed
+
+Removed the "headers" event. This event was only useful for changing the
+body a response once the headers of the response were known. You can implement
+a similar behavior in a number of ways. One example might be to use a
+FnStream that has access to the transaction being sent. For example, when the
+first byte is written, you could check if the response headers match your
+expectations, and if so, change the actual stream body that is being
+written to.
+
+## Updates to HTTP Messages
+
+Removed the `asArray` parameter from
+`GuzzleHttp\Message\MessageInterface::getHeader`. If you want to get a header
+value as an array, then use the newly added `getHeaderAsArray()` method of
+`MessageInterface`. This change makes the Guzzle interfaces compatible with
+the PSR-7 interfaces.
+
+3.x to 4.0
+----------
+
+## Overarching changes:
+
+- Now requires PHP 5.4 or greater.
+- No longer requires cURL to send requests.
+- Guzzle no longer wraps every exception it throws. Only exceptions that are
+ recoverable are now wrapped by Guzzle.
+- Various namespaces have been removed or renamed.
+- No longer requiring the Symfony EventDispatcher. A custom event dispatcher
+ based on the Symfony EventDispatcher is
+ now utilized in `GuzzleHttp\Event\EmitterInterface` (resulting in significant
+ speed and functionality improvements).
+
+Changes per Guzzle 3.x namespace are described below.
+
+## Batch
+
+The `Guzzle\Batch` namespace has been removed. This is best left to
+third-parties to implement on top of Guzzle's core HTTP library.
+
+## Cache
+
+The `Guzzle\Cache` namespace has been removed. (Todo: No suitable replacement
+has been implemented yet, but hoping to utilize a PSR cache interface).
+
+## Common
+
+- Removed all of the wrapped exceptions. It's better to use the standard PHP
+ library for unrecoverable exceptions.
+- `FromConfigInterface` has been removed.
+- `Guzzle\Common\Version` has been removed. The VERSION constant can be found
+ at `GuzzleHttp\ClientInterface::VERSION`.
+
+### Collection
+
+- `getAll` has been removed. Use `toArray` to convert a collection to an array.
+- `inject` has been removed.
+- `keySearch` has been removed.
+- `getPath` no longer supports wildcard expressions. Use something better like
+ JMESPath for this.
+- `setPath` now supports appending to an existing array via the `[]` notation.
+
+### Events
+
+Guzzle no longer requires Symfony's EventDispatcher component. Guzzle now uses
+`GuzzleHttp\Event\Emitter`.
+
+- `Symfony\Component\EventDispatcher\EventDispatcherInterface` is replaced by
+ `GuzzleHttp\Event\EmitterInterface`.
+- `Symfony\Component\EventDispatcher\EventDispatcher` is replaced by
+ `GuzzleHttp\Event\Emitter`.
+- `Symfony\Component\EventDispatcher\Event` is replaced by
+ `GuzzleHttp\Event\Event`, and Guzzle now has an EventInterface in
+ `GuzzleHttp\Event\EventInterface`.
+- `AbstractHasDispatcher` has moved to a trait, `HasEmitterTrait`, and
+ `HasDispatcherInterface` has moved to `HasEmitterInterface`. Retrieving the
+ event emitter of a request, client, etc. now uses the `getEmitter` method
+ rather than the `getDispatcher` method.
+
+#### Emitter
+
+- Use the `once()` method to add a listener that automatically removes itself
+ the first time it is invoked.
+- Use the `listeners()` method to retrieve a list of event listeners rather than
+ the `getListeners()` method.
+- Use `emit()` instead of `dispatch()` to emit an event from an emitter.
+- Use `attach()` instead of `addSubscriber()` and `detach()` instead of
+ `removeSubscriber()`.
+
+```php
+$mock = new Mock();
+// 3.x
+$request->getEventDispatcher()->addSubscriber($mock);
+$request->getEventDispatcher()->removeSubscriber($mock);
+// 4.x
+$request->getEmitter()->attach($mock);
+$request->getEmitter()->detach($mock);
+```
+
+Use the `on()` method to add a listener rather than the `addListener()` method.
+
+```php
+// 3.x
+$request->getEventDispatcher()->addListener('foo', function (Event $event) { /* ... */ } );
+// 4.x
+$request->getEmitter()->on('foo', function (Event $event, $name) { /* ... */ } );
+```
+
+## Http
+
+### General changes
+
+- The cacert.pem certificate has been moved to `src/cacert.pem`.
+- Added the concept of adapters that are used to transfer requests over the
+ wire.
+- Simplified the event system.
+- Sending requests in parallel is still possible, but batching is no longer a
+ concept of the HTTP layer. Instead, you must use the `complete` and `error`
+ events to asynchronously manage parallel request transfers.
+- `Guzzle\Http\Url` has moved to `GuzzleHttp\Url`.
+- `Guzzle\Http\QueryString` has moved to `GuzzleHttp\Query`.
+- QueryAggregators have been rewritten so that they are simply callable
+ functions.
+- `GuzzleHttp\StaticClient` has been removed. Use the functions provided in
+ `functions.php` for an easy to use static client instance.
+- Exceptions in `GuzzleHttp\Exception` have been updated to all extend from
+ `GuzzleHttp\Exception\TransferException`.
+
+### Client
+
+Calling methods like `get()`, `post()`, `head()`, etc. no longer create and
+return a request, but rather creates a request, sends the request, and returns
+the response.
+
+```php
+// 3.0
+$request = $client->get('/');
+$response = $request->send();
+
+// 4.0
+$response = $client->get('/');
+
+// or, to mirror the previous behavior
+$request = $client->createRequest('GET', '/');
+$response = $client->send($request);
+```
+
+`GuzzleHttp\ClientInterface` has changed.
+
+- The `send` method no longer accepts more than one request. Use `sendAll` to
+ send multiple requests in parallel.
+- `setUserAgent()` has been removed. Use a default request option instead. You
+ could, for example, do something like:
+ `$client->setConfig('defaults/headers/User-Agent', 'Foo/Bar ' . $client::getDefaultUserAgent())`.
+- `setSslVerification()` has been removed. Use default request options instead,
+ like `$client->setConfig('defaults/verify', true)`.
+
+`GuzzleHttp\Client` has changed.
+
+- The constructor now accepts only an associative array. You can include a
+ `base_url` string or array to use a URI template as the base URL of a client.
+ You can also specify a `defaults` key that is an associative array of default
+ request options. You can pass an `adapter` to use a custom adapter,
+ `batch_adapter` to use a custom adapter for sending requests in parallel, or
+ a `message_factory` to change the factory used to create HTTP requests and
+ responses.
+- The client no longer emits a `client.create_request` event.
+- Creating requests with a client no longer automatically utilize a URI
+ template. You must pass an array into a creational method (e.g.,
+ `createRequest`, `get`, `put`, etc.) in order to expand a URI template.
+
+### Messages
+
+Messages no longer have references to their counterparts (i.e., a request no
+longer has a reference to it's response, and a response no loger has a
+reference to its request). This association is now managed through a
+`GuzzleHttp\Adapter\TransactionInterface` object. You can get references to
+these transaction objects using request events that are emitted over the
+lifecycle of a request.
+
+#### Requests with a body
+
+- `GuzzleHttp\Message\EntityEnclosingRequest` and
+ `GuzzleHttp\Message\EntityEnclosingRequestInterface` have been removed. The
+ separation between requests that contain a body and requests that do not
+ contain a body has been removed, and now `GuzzleHttp\Message\RequestInterface`
+ handles both use cases.
+- Any method that previously accepts a `GuzzleHttp\Response` object now accept a
+ `GuzzleHttp\Message\ResponseInterface`.
+- `GuzzleHttp\Message\RequestFactoryInterface` has been renamed to
+ `GuzzleHttp\Message\MessageFactoryInterface`. This interface is used to create
+ both requests and responses and is implemented in
+ `GuzzleHttp\Message\MessageFactory`.
+- POST field and file methods have been removed from the request object. You
+ must now use the methods made available to `GuzzleHttp\Post\PostBodyInterface`
+ to control the format of a POST body. Requests that are created using a
+ standard `GuzzleHttp\Message\MessageFactoryInterface` will automatically use
+ a `GuzzleHttp\Post\PostBody` body if the body was passed as an array or if
+ the method is POST and no body is provided.
+
+```php
+$request = $client->createRequest('POST', '/');
+$request->getBody()->setField('foo', 'bar');
+$request->getBody()->addFile(new PostFile('file_key', fopen('/path/to/content', 'r')));
+```
+
+#### Headers
+
+- `GuzzleHttp\Message\Header` has been removed. Header values are now simply
+ represented by an array of values or as a string. Header values are returned
+ as a string by default when retrieving a header value from a message. You can
+ pass an optional argument of `true` to retrieve a header value as an array
+ of strings instead of a single concatenated string.
+- `GuzzleHttp\PostFile` and `GuzzleHttp\PostFileInterface` have been moved to
+ `GuzzleHttp\Post`. This interface has been simplified and now allows the
+ addition of arbitrary headers.
+- Custom headers like `GuzzleHttp\Message\Header\Link` have been removed. Most
+ of the custom headers are now handled separately in specific
+ subscribers/plugins, and `GuzzleHttp\Message\HeaderValues::parseParams()` has
+ been updated to properly handle headers that contain parameters (like the
+ `Link` header).
+
+#### Responses
+
+- `GuzzleHttp\Message\Response::getInfo()` and
+ `GuzzleHttp\Message\Response::setInfo()` have been removed. Use the event
+ system to retrieve this type of information.
+- `GuzzleHttp\Message\Response::getRawHeaders()` has been removed.
+- `GuzzleHttp\Message\Response::getMessage()` has been removed.
+- `GuzzleHttp\Message\Response::calculateAge()` and other cache specific
+ methods have moved to the CacheSubscriber.
+- Header specific helper functions like `getContentMd5()` have been removed.
+ Just use `getHeader('Content-MD5')` instead.
+- `GuzzleHttp\Message\Response::setRequest()` and
+ `GuzzleHttp\Message\Response::getRequest()` have been removed. Use the event
+ system to work with request and response objects as a transaction.
+- `GuzzleHttp\Message\Response::getRedirectCount()` has been removed. Use the
+ Redirect subscriber instead.
+- `GuzzleHttp\Message\Response::isSuccessful()` and other related methods have
+ been removed. Use `getStatusCode()` instead.
+
+#### Streaming responses
+
+Streaming requests can now be created by a client directly, returning a
+`GuzzleHttp\Message\ResponseInterface` object that contains a body stream
+referencing an open PHP HTTP stream.
+
+```php
+// 3.0
+use Guzzle\Stream\PhpStreamRequestFactory;
+$request = $client->get('/');
+$factory = new PhpStreamRequestFactory();
+$stream = $factory->fromRequest($request);
+$data = $stream->read(1024);
+
+// 4.0
+$response = $client->get('/', ['stream' => true]);
+// Read some data off of the stream in the response body
+$data = $response->getBody()->read(1024);
+```
+
+#### Redirects
+
+The `configureRedirects()` method has been removed in favor of a
+`allow_redirects` request option.
+
+```php
+// Standard redirects with a default of a max of 5 redirects
+$request = $client->createRequest('GET', '/', ['allow_redirects' => true]);
+
+// Strict redirects with a custom number of redirects
+$request = $client->createRequest('GET', '/', [
+ 'allow_redirects' => ['max' => 5, 'strict' => true]
+]);
+```
+
+#### EntityBody
+
+EntityBody interfaces and classes have been removed or moved to
+`GuzzleHttp\Stream`. All classes and interfaces that once required
+`GuzzleHttp\EntityBodyInterface` now require
+`GuzzleHttp\Stream\StreamInterface`. Creating a new body for a request no
+longer uses `GuzzleHttp\EntityBody::factory` but now uses
+`GuzzleHttp\Stream\Stream::factory` or even better:
+`GuzzleHttp\Stream\create()`.
+
+- `Guzzle\Http\EntityBodyInterface` is now `GuzzleHttp\Stream\StreamInterface`
+- `Guzzle\Http\EntityBody` is now `GuzzleHttp\Stream\Stream`
+- `Guzzle\Http\CachingEntityBody` is now `GuzzleHttp\Stream\CachingStream`
+- `Guzzle\Http\ReadLimitEntityBody` is now `GuzzleHttp\Stream\LimitStream`
+- `Guzzle\Http\IoEmittyinEntityBody` has been removed.
+
+#### Request lifecycle events
+
+Requests previously submitted a large number of requests. The number of events
+emitted over the lifecycle of a request has been significantly reduced to make
+it easier to understand how to extend the behavior of a request. All events
+emitted during the lifecycle of a request now emit a custom
+`GuzzleHttp\Event\EventInterface` object that contains context providing
+methods and a way in which to modify the transaction at that specific point in
+time (e.g., intercept the request and set a response on the transaction).
+
+- `request.before_send` has been renamed to `before` and now emits a
+ `GuzzleHttp\Event\BeforeEvent`
+- `request.complete` has been renamed to `complete` and now emits a
+ `GuzzleHttp\Event\CompleteEvent`.
+- `request.sent` has been removed. Use `complete`.
+- `request.success` has been removed. Use `complete`.
+- `error` is now an event that emits a `GuzzleHttp\Event\ErrorEvent`.
+- `request.exception` has been removed. Use `error`.
+- `request.receive.status_line` has been removed.
+- `curl.callback.progress` has been removed. Use a custom `StreamInterface` to
+ maintain a status update.
+- `curl.callback.write` has been removed. Use a custom `StreamInterface` to
+ intercept writes.
+- `curl.callback.read` has been removed. Use a custom `StreamInterface` to
+ intercept reads.
+
+`headers` is a new event that is emitted after the response headers of a
+request have been received before the body of the response is downloaded. This
+event emits a `GuzzleHttp\Event\HeadersEvent`.
+
+You can intercept a request and inject a response using the `intercept()` event
+of a `GuzzleHttp\Event\BeforeEvent`, `GuzzleHttp\Event\CompleteEvent`, and
+`GuzzleHttp\Event\ErrorEvent` event.
+
+See: http://docs.guzzlephp.org/en/latest/events.html
+
+## Inflection
+
+The `Guzzle\Inflection` namespace has been removed. This is not a core concern
+of Guzzle.
+
+## Iterator
+
+The `Guzzle\Iterator` namespace has been removed.
+
+- `Guzzle\Iterator\AppendIterator`, `Guzzle\Iterator\ChunkedIterator`, and
+ `Guzzle\Iterator\MethodProxyIterator` are nice, but not a core requirement of
+ Guzzle itself.
+- `Guzzle\Iterator\FilterIterator` is no longer needed because an equivalent
+ class is shipped with PHP 5.4.
+- `Guzzle\Iterator\MapIterator` is not really needed when using PHP 5.5 because
+ it's easier to just wrap an iterator in a generator that maps values.
+
+For a replacement of these iterators, see https://github.com/nikic/iter
+
+## Log
+
+The LogPlugin has moved to https://github.com/guzzle/log-subscriber. The
+`Guzzle\Log` namespace has been removed. Guzzle now relies on
+`Psr\Log\LoggerInterface` for all logging. The MessageFormatter class has been
+moved to `GuzzleHttp\Subscriber\Log\Formatter`.
+
+## Parser
+
+The `Guzzle\Parser` namespace has been removed. This was previously used to
+make it possible to plug in custom parsers for cookies, messages, URI
+templates, and URLs; however, this level of complexity is not needed in Guzzle
+so it has been removed.
+
+- Cookie: Cookie parsing logic has been moved to
+ `GuzzleHttp\Cookie\SetCookie::fromString`.
+- Message: Message parsing logic for both requests and responses has been moved
+ to `GuzzleHttp\Message\MessageFactory::fromMessage`. Message parsing is only
+ used in debugging or deserializing messages, so it doesn't make sense for
+ Guzzle as a library to add this level of complexity to parsing messages.
+- UriTemplate: URI template parsing has been moved to
+ `GuzzleHttp\UriTemplate`. The Guzzle library will automatically use the PECL
+ URI template library if it is installed.
+- Url: URL parsing is now performed in `GuzzleHttp\Url::fromString` (previously
+ it was `Guzzle\Http\Url::factory()`). If custom URL parsing is necessary,
+ then developers are free to subclass `GuzzleHttp\Url`.
+
+## Plugin
+
+The `Guzzle\Plugin` namespace has been renamed to `GuzzleHttp\Subscriber`.
+Several plugins are shipping with the core Guzzle library under this namespace.
+
+- `GuzzleHttp\Subscriber\Cookie`: Replaces the old CookiePlugin. Cookie jar
+ code has moved to `GuzzleHttp\Cookie`.
+- `GuzzleHttp\Subscriber\History`: Replaces the old HistoryPlugin.
+- `GuzzleHttp\Subscriber\HttpError`: Throws errors when a bad HTTP response is
+ received.
+- `GuzzleHttp\Subscriber\Mock`: Replaces the old MockPlugin.
+- `GuzzleHttp\Subscriber\Prepare`: Prepares the body of a request just before
+ sending. This subscriber is attached to all requests by default.
+- `GuzzleHttp\Subscriber\Redirect`: Replaces the RedirectPlugin.
+
+The following plugins have been removed (third-parties are free to re-implement
+these if needed):
+
+- `GuzzleHttp\Plugin\Async` has been removed.
+- `GuzzleHttp\Plugin\CurlAuth` has been removed.
+- `GuzzleHttp\Plugin\ErrorResponse\ErrorResponsePlugin` has been removed. This
+ functionality should instead be implemented with event listeners that occur
+ after normal response parsing occurs in the guzzle/command package.
+
+The following plugins are not part of the core Guzzle package, but are provided
+in separate repositories:
+
+- `Guzzle\Http\Plugin\BackoffPlugin` has been rewritten to be much simpler
+ to build custom retry policies using simple functions rather than various
+ chained classes. See: https://github.com/guzzle/retry-subscriber
+- `Guzzle\Http\Plugin\Cache\CachePlugin` has moved to
+ https://github.com/guzzle/cache-subscriber
+- `Guzzle\Http\Plugin\Log\LogPlugin` has moved to
+ https://github.com/guzzle/log-subscriber
+- `Guzzle\Http\Plugin\Md5\Md5Plugin` has moved to
+ https://github.com/guzzle/message-integrity-subscriber
+- `Guzzle\Http\Plugin\Mock\MockPlugin` has moved to
+ `GuzzleHttp\Subscriber\MockSubscriber`.
+- `Guzzle\Http\Plugin\Oauth\OauthPlugin` has moved to
+ https://github.com/guzzle/oauth-subscriber
+
+## Service
+
+The service description layer of Guzzle has moved into two separate packages:
+
+- http://github.com/guzzle/command Provides a high level abstraction over web
+ services by representing web service operations using commands.
+- http://github.com/guzzle/guzzle-services Provides an implementation of
+ guzzle/command that provides request serialization and response parsing using
+ Guzzle service descriptions.
+
+## Stream
+
+Stream have moved to a separate package available at
+https://github.com/guzzle/streams.
+
+`Guzzle\Stream\StreamInterface` has been given a large update to cleanly take
+on the responsibilities of `Guzzle\Http\EntityBody` and
+`Guzzle\Http\EntityBodyInterface` now that they have been removed. The number
+of methods implemented by the `StreamInterface` has been drastically reduced to
+allow developers to more easily extend and decorate stream behavior.
+
+## Removed methods from StreamInterface
+
+- `getStream` and `setStream` have been removed to better encapsulate streams.
+- `getMetadata` and `setMetadata` have been removed in favor of
+ `GuzzleHttp\Stream\MetadataStreamInterface`.
+- `getWrapper`, `getWrapperData`, `getStreamType`, and `getUri` have all been
+ removed. This data is accessible when
+ using streams that implement `GuzzleHttp\Stream\MetadataStreamInterface`.
+- `rewind` has been removed. Use `seek(0)` for a similar behavior.
+
+## Renamed methods
+
+- `detachStream` has been renamed to `detach`.
+- `feof` has been renamed to `eof`.
+- `ftell` has been renamed to `tell`.
+- `readLine` has moved from an instance method to a static class method of
+ `GuzzleHttp\Stream\Stream`.
+
+## Metadata streams
+
+`GuzzleHttp\Stream\MetadataStreamInterface` has been added to denote streams
+that contain additional metadata accessible via `getMetadata()`.
+`GuzzleHttp\Stream\StreamInterface::getMetadata` and
+`GuzzleHttp\Stream\StreamInterface::setMetadata` have been removed.
+
+## StreamRequestFactory
+
+The entire concept of the StreamRequestFactory has been removed. The way this
+was used in Guzzle 3 broke the actual interface of sending streaming requests
+(instead of getting back a Response, you got a StreamInterface). Streaming
+PHP requests are now implemented through the `GuzzleHttp\Adapter\StreamAdapter`.
+
+3.6 to 3.7
+----------
+
+### Deprecations
+
+- You can now enable E_USER_DEPRECATED warnings to see if you are using any deprecated methods.:
+
+```php
+\Guzzle\Common\Version::$emitWarnings = true;
+```
+
+The following APIs and options have been marked as deprecated:
+
+- Marked `Guzzle\Http\Message\Request::isResponseBodyRepeatable()` as deprecated. Use `$request->getResponseBody()->isRepeatable()` instead.
+- Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead.
+- Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead.
+- Marked `Guzzle\Http\Message\Request::setIsRedirect()` as deprecated. Use the HistoryPlugin instead.
+- Marked `Guzzle\Http\Message\Request::isRedirect()` as deprecated. Use the HistoryPlugin instead.
+- Marked `Guzzle\Cache\CacheAdapterFactory::factory()` as deprecated
+- Marked `Guzzle\Service\Client::enableMagicMethods()` as deprecated. Magic methods can no longer be disabled on a Guzzle\Service\Client.
+- Marked `Guzzle\Parser\Url\UrlParser` as deprecated. Just use PHP's `parse_url()` and percent encode your UTF-8.
+- Marked `Guzzle\Common\Collection::inject()` as deprecated.
+- Marked `Guzzle\Plugin\CurlAuth\CurlAuthPlugin` as deprecated. Use
+ `$client->getConfig()->setPath('request.options/auth', array('user', 'pass', 'Basic|Digest|NTLM|Any'));` or
+ `$client->setDefaultOption('auth', array('user', 'pass', 'Basic|Digest|NTLM|Any'));`
+
+3.7 introduces `request.options` as a parameter for a client configuration and as an optional argument to all creational
+request methods. When paired with a client's configuration settings, these options allow you to specify default settings
+for various aspects of a request. Because these options make other previous configuration options redundant, several
+configuration options and methods of a client and AbstractCommand have been deprecated.
+
+- Marked `Guzzle\Service\Client::getDefaultHeaders()` as deprecated. Use `$client->getDefaultOption('headers')`.
+- Marked `Guzzle\Service\Client::setDefaultHeaders()` as deprecated. Use `$client->setDefaultOption('headers/{header_name}', 'value')`.
+- Marked 'request.params' for `Guzzle\Http\Client` as deprecated. Use `$client->setDefaultOption('params/{param_name}', 'value')`
+- Marked 'command.headers', 'command.response_body' and 'command.on_complete' as deprecated for AbstractCommand. These will work through Guzzle 4.0
+
+ $command = $client->getCommand('foo', array(
+ 'command.headers' => array('Test' => '123'),
+ 'command.response_body' => '/path/to/file'
+ ));
+
+ // Should be changed to:
+
+ $command = $client->getCommand('foo', array(
+ 'command.request_options' => array(
+ 'headers' => array('Test' => '123'),
+ 'save_as' => '/path/to/file'
+ )
+ ));
+
+### Interface changes
+
+Additions and changes (you will need to update any implementations or subclasses you may have created):
+
+- Added an `$options` argument to the end of the following methods of `Guzzle\Http\ClientInterface`:
+ createRequest, head, delete, put, patch, post, options, prepareRequest
+- Added an `$options` argument to the end of `Guzzle\Http\Message\Request\RequestFactoryInterface::createRequest()`
+- Added an `applyOptions()` method to `Guzzle\Http\Message\Request\RequestFactoryInterface`
+- Changed `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $body = null)` to
+ `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $options = array())`. You can still pass in a
+ resource, string, or EntityBody into the $options parameter to specify the download location of the response.
+- Changed `Guzzle\Common\Collection::__construct($data)` to no longer accepts a null value for `$data` but a
+ default `array()`
+- Added `Guzzle\Stream\StreamInterface::isRepeatable`
+- Made `Guzzle\Http\Client::expandTemplate` and `getUriTemplate` protected methods.
+
+The following methods were removed from interfaces. All of these methods are still available in the concrete classes
+that implement them, but you should update your code to use alternative methods:
+
+- Removed `Guzzle\Http\ClientInterface::setDefaultHeaders(). Use
+ `$client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. or
+ `$client->getConfig()->setPath('request.options/headers', array('header_name' => 'value'))` or
+ `$client->setDefaultOption('headers/{header_name}', 'value')`. or
+ `$client->setDefaultOption('headers', array('header_name' => 'value'))`.
+- Removed `Guzzle\Http\ClientInterface::getDefaultHeaders(). Use `$client->getConfig()->getPath('request.options/headers')`.
+- Removed `Guzzle\Http\ClientInterface::expandTemplate()`. This is an implementation detail.
+- Removed `Guzzle\Http\ClientInterface::setRequestFactory()`. This is an implementation detail.
+- Removed `Guzzle\Http\ClientInterface::getCurlMulti()`. This is a very specific implementation detail.
+- Removed `Guzzle\Http\Message\RequestInterface::canCache`. Use the CachePlugin.
+- Removed `Guzzle\Http\Message\RequestInterface::setIsRedirect`. Use the HistoryPlugin.
+- Removed `Guzzle\Http\Message\RequestInterface::isRedirect`. Use the HistoryPlugin.
+
+### Cache plugin breaking changes
+
+- CacheKeyProviderInterface and DefaultCacheKeyProvider are no longer used. All of this logic is handled in a
+ CacheStorageInterface. These two objects and interface will be removed in a future version.
+- Always setting X-cache headers on cached responses
+- Default cache TTLs are now handled by the CacheStorageInterface of a CachePlugin
+- `CacheStorageInterface::cache($key, Response $response, $ttl = null)` has changed to `cache(RequestInterface
+ $request, Response $response);`
+- `CacheStorageInterface::fetch($key)` has changed to `fetch(RequestInterface $request);`
+- `CacheStorageInterface::delete($key)` has changed to `delete(RequestInterface $request);`
+- Added `CacheStorageInterface::purge($url)`
+- `DefaultRevalidation::__construct(CacheKeyProviderInterface $cacheKey, CacheStorageInterface $cache, CachePlugin
+ $plugin)` has changed to `DefaultRevalidation::__construct(CacheStorageInterface $cache,
+ CanCacheStrategyInterface $canCache = null)`
+- Added `RevalidationInterface::shouldRevalidate(RequestInterface $request, Response $response)`
+
+3.5 to 3.6
+----------
+
+* Mixed casing of headers are now forced to be a single consistent casing across all values for that header.
+* Messages internally use a HeaderCollection object to delegate handling case-insensitive header resolution
+* Removed the whole changedHeader() function system of messages because all header changes now go through addHeader().
+ For example, setHeader() first removes the header using unset on a HeaderCollection and then calls addHeader().
+ Keeping the Host header and URL host in sync is now handled by overriding the addHeader method in Request.
+* Specific header implementations can be created for complex headers. When a message creates a header, it uses a
+ HeaderFactory which can map specific headers to specific header classes. There is now a Link header and
+ CacheControl header implementation.
+* Moved getLinks() from Response to just be used on a Link header object.
+
+If you previously relied on Guzzle\Http\Message\Header::raw(), then you will need to update your code to use the
+HeaderInterface (e.g. toArray(), getAll(), etc.).
+
+### Interface changes
+
+* Removed from interface: Guzzle\Http\ClientInterface::setUriTemplate
+* Removed from interface: Guzzle\Http\ClientInterface::setCurlMulti()
+* Removed Guzzle\Http\Message\Request::receivedRequestHeader() and implemented this functionality in
+ Guzzle\Http\Curl\RequestMediator
+* Removed the optional $asString parameter from MessageInterface::getHeader(). Just cast the header to a string.
+* Removed the optional $tryChunkedTransfer option from Guzzle\Http\Message\EntityEnclosingRequestInterface
+* Removed the $asObjects argument from Guzzle\Http\Message\MessageInterface::getHeaders()
+
+### Removed deprecated functions
+
+* Removed Guzzle\Parser\ParserRegister::get(). Use getParser()
+* Removed Guzzle\Parser\ParserRegister::set(). Use registerParser().
+
+### Deprecations
+
+* The ability to case-insensitively search for header values
+* Guzzle\Http\Message\Header::hasExactHeader
+* Guzzle\Http\Message\Header::raw. Use getAll()
+* Deprecated cache control specific methods on Guzzle\Http\Message\AbstractMessage. Use the CacheControl header object
+ instead.
+
+### Other changes
+
+* All response header helper functions return a string rather than mixing Header objects and strings inconsistently
+* Removed cURL blacklist support. This is no longer necessary now that Expect, Accept, etc. are managed by Guzzle
+ directly via interfaces
+* Removed the injecting of a request object onto a response object. The methods to get and set a request still exist
+ but are a no-op until removed.
+* Most classes that used to require a `Guzzle\Service\Command\CommandInterface` typehint now request a
+ `Guzzle\Service\Command\ArrayCommandInterface`.
+* Added `Guzzle\Http\Message\RequestInterface::startResponse()` to the RequestInterface to handle injecting a response
+ on a request while the request is still being transferred
+* `Guzzle\Service\Command\CommandInterface` now extends from ToArrayInterface and ArrayAccess
+
+3.3 to 3.4
+----------
+
+Base URLs of a client now follow the rules of https://tools.ietf.org/html/rfc3986#section-5.2.2 when merging URLs.
+
+3.2 to 3.3
+----------
+
+### Response::getEtag() quote stripping removed
+
+`Guzzle\Http\Message\Response::getEtag()` no longer strips quotes around the ETag response header
+
+### Removed `Guzzle\Http\Utils`
+
+The `Guzzle\Http\Utils` class was removed. This class was only used for testing.
+
+### Stream wrapper and type
+
+`Guzzle\Stream\Stream::getWrapper()` and `Guzzle\Stream\Stream::getStreamType()` are no longer converted to lowercase.
+
+### curl.emit_io became emit_io
+
+Emitting IO events from a RequestMediator is now a parameter that must be set in a request's curl options using the
+'emit_io' key. This was previously set under a request's parameters using 'curl.emit_io'
+
+3.1 to 3.2
+----------
+
+### CurlMulti is no longer reused globally
+
+Before 3.2, the same CurlMulti object was reused globally for each client. This can cause issue where plugins added
+to a single client can pollute requests dispatched from other clients.
+
+If you still wish to reuse the same CurlMulti object with each client, then you can add a listener to the
+ServiceBuilder's `service_builder.create_client` event to inject a custom CurlMulti object into each client as it is
+created.
+
+```php
+$multi = new Guzzle\Http\Curl\CurlMulti();
+$builder = Guzzle\Service\Builder\ServiceBuilder::factory('/path/to/config.json');
+$builder->addListener('service_builder.create_client', function ($event) use ($multi) {
+ $event['client']->setCurlMulti($multi);
+}
+});
+```
+
+### No default path
+
+URLs no longer have a default path value of '/' if no path was specified.
+
+Before:
+
+```php
+$request = $client->get('http://www.foo.com');
+echo $request->getUrl();
+// >> http://www.foo.com/
+```
+
+After:
+
+```php
+$request = $client->get('http://www.foo.com');
+echo $request->getUrl();
+// >> http://www.foo.com
+```
+
+### Less verbose BadResponseException
+
+The exception message for `Guzzle\Http\Exception\BadResponseException` no longer contains the full HTTP request and
+response information. You can, however, get access to the request and response object by calling `getRequest()` or
+`getResponse()` on the exception object.
+
+### Query parameter aggregation
+
+Multi-valued query parameters are no longer aggregated using a callback function. `Guzzle\Http\Query` now has a
+setAggregator() method that accepts a `Guzzle\Http\QueryAggregator\QueryAggregatorInterface` object. This object is
+responsible for handling the aggregation of multi-valued query string variables into a flattened hash.
+
+2.8 to 3.x
+----------
+
+### Guzzle\Service\Inspector
+
+Change `\Guzzle\Service\Inspector::fromConfig` to `\Guzzle\Common\Collection::fromConfig`
+
+**Before**
+
+```php
+use Guzzle\Service\Inspector;
+
+class YourClient extends \Guzzle\Service\Client
+{
+ public static function factory($config = array())
+ {
+ $default = array();
+ $required = array('base_url', 'username', 'api_key');
+ $config = Inspector::fromConfig($config, $default, $required);
+
+ $client = new self(
+ $config->get('base_url'),
+ $config->get('username'),
+ $config->get('api_key')
+ );
+ $client->setConfig($config);
+
+ $client->setDescription(ServiceDescription::factory(__DIR__ . DIRECTORY_SEPARATOR . 'client.json'));
+
+ return $client;
+ }
+```
+
+**After**
+
+```php
+use Guzzle\Common\Collection;
+
+class YourClient extends \Guzzle\Service\Client
+{
+ public static function factory($config = array())
+ {
+ $default = array();
+ $required = array('base_url', 'username', 'api_key');
+ $config = Collection::fromConfig($config, $default, $required);
+
+ $client = new self(
+ $config->get('base_url'),
+ $config->get('username'),
+ $config->get('api_key')
+ );
+ $client->setConfig($config);
+
+ $client->setDescription(ServiceDescription::factory(__DIR__ . DIRECTORY_SEPARATOR . 'client.json'));
+
+ return $client;
+ }
+```
+
+### Convert XML Service Descriptions to JSON
+
+**Before**
+
+```xml
+<?xml version="1.0" encoding="UTF-8"?>
+<client>
+ <commands>
+ <!-- Groups -->
+ <command name="list_groups" method="GET" uri="groups.json">
+ <doc>Get a list of groups</doc>
+ </command>
+ <command name="search_groups" method="GET" uri='search.json?query="{{query}} type:group"'>
+ <doc>Uses a search query to get a list of groups</doc>
+ <param name="query" type="string" required="true" />
+ </command>
+ <command name="create_group" method="POST" uri="groups.json">
+ <doc>Create a group</doc>
+ <param name="data" type="array" location="body" filters="json_encode" doc="Group JSON"/>
+ <param name="Content-Type" location="header" static="application/json"/>
+ </command>
+ <command name="delete_group" method="DELETE" uri="groups/{{id}}.json">
+ <doc>Delete a group by ID</doc>
+ <param name="id" type="integer" required="true"/>
+ </command>
+ <command name="get_group" method="GET" uri="groups/{{id}}.json">
+ <param name="id" type="integer" required="true"/>
+ </command>
+ <command name="update_group" method="PUT" uri="groups/{{id}}.json">
+ <doc>Update a group</doc>
+ <param name="id" type="integer" required="true"/>
+ <param name="data" type="array" location="body" filters="json_encode" doc="Group JSON"/>
+ <param name="Content-Type" location="header" static="application/json"/>
+ </command>
+ </commands>
+</client>
+```
+
+**After**
+
+```json
+{
+ "name": "Zendesk REST API v2",
+ "apiVersion": "2012-12-31",
+ "description":"Provides access to Zendesk views, groups, tickets, ticket fields, and users",
+ "operations": {
+ "list_groups": {
+ "httpMethod":"GET",
+ "uri": "groups.json",
+ "summary": "Get a list of groups"
+ },
+ "search_groups":{
+ "httpMethod":"GET",
+ "uri": "search.json?query=\"{query} type:group\"",
+ "summary": "Uses a search query to get a list of groups",
+ "parameters":{
+ "query":{
+ "location": "uri",
+ "description":"Zendesk Search Query",
+ "type": "string",
+ "required": true
+ }
+ }
+ },
+ "create_group": {
+ "httpMethod":"POST",
+ "uri": "groups.json",
+ "summary": "Create a group",
+ "parameters":{
+ "data": {
+ "type": "array",
+ "location": "body",
+ "description":"Group JSON",
+ "filters": "json_encode",
+ "required": true
+ },
+ "Content-Type":{
+ "type": "string",
+ "location":"header",
+ "static": "application/json"
+ }
+ }
+ },
+ "delete_group": {
+ "httpMethod":"DELETE",
+ "uri": "groups/{id}.json",
+ "summary": "Delete a group",
+ "parameters":{
+ "id":{
+ "location": "uri",
+ "description":"Group to delete by ID",
+ "type": "integer",
+ "required": true
+ }
+ }
+ },
+ "get_group": {
+ "httpMethod":"GET",
+ "uri": "groups/{id}.json",
+ "summary": "Get a ticket",
+ "parameters":{
+ "id":{
+ "location": "uri",
+ "description":"Group to get by ID",
+ "type": "integer",
+ "required": true
+ }
+ }
+ },
+ "update_group": {
+ "httpMethod":"PUT",
+ "uri": "groups/{id}.json",
+ "summary": "Update a group",
+ "parameters":{
+ "id": {
+ "location": "uri",
+ "description":"Group to update by ID",
+ "type": "integer",
+ "required": true
+ },
+ "data": {
+ "type": "array",
+ "location": "body",
+ "description":"Group JSON",
+ "filters": "json_encode",
+ "required": true
+ },
+ "Content-Type":{
+ "type": "string",
+ "location":"header",
+ "static": "application/json"
+ }
+ }
+ }
+}
+```
+
+### Guzzle\Service\Description\ServiceDescription
+
+Commands are now called Operations
+
+**Before**
+
+```php
+use Guzzle\Service\Description\ServiceDescription;
+
+$sd = new ServiceDescription();
+$sd->getCommands(); // @returns ApiCommandInterface[]
+$sd->hasCommand($name);
+$sd->getCommand($name); // @returns ApiCommandInterface|null
+$sd->addCommand($command); // @param ApiCommandInterface $command
+```
+
+**After**
+
+```php
+use Guzzle\Service\Description\ServiceDescription;
+
+$sd = new ServiceDescription();
+$sd->getOperations(); // @returns OperationInterface[]
+$sd->hasOperation($name);
+$sd->getOperation($name); // @returns OperationInterface|null
+$sd->addOperation($operation); // @param OperationInterface $operation
+```
+
+### Guzzle\Common\Inflection\Inflector
+
+Namespace is now `Guzzle\Inflection\Inflector`
+
+### Guzzle\Http\Plugin
+
+Namespace is now `Guzzle\Plugin`. Many other changes occur within this namespace and are detailed in their own sections below.
+
+### Guzzle\Http\Plugin\LogPlugin and Guzzle\Common\Log
+
+Now `Guzzle\Plugin\Log\LogPlugin` and `Guzzle\Log` respectively.
+
+**Before**
+
+```php
+use Guzzle\Common\Log\ClosureLogAdapter;
+use Guzzle\Http\Plugin\LogPlugin;
+
+/** @var \Guzzle\Http\Client */
+$client;
+
+// $verbosity is an integer indicating desired message verbosity level
+$client->addSubscriber(new LogPlugin(new ClosureLogAdapter(function($m) { echo $m; }, $verbosity = LogPlugin::LOG_VERBOSE);
+```
+
+**After**
+
+```php
+use Guzzle\Log\ClosureLogAdapter;
+use Guzzle\Log\MessageFormatter;
+use Guzzle\Plugin\Log\LogPlugin;
+
+/** @var \Guzzle\Http\Client */
+$client;
+
+// $format is a string indicating desired message format -- @see MessageFormatter
+$client->addSubscriber(new LogPlugin(new ClosureLogAdapter(function($m) { echo $m; }, $format = MessageFormatter::DEBUG_FORMAT);
+```
+
+### Guzzle\Http\Plugin\CurlAuthPlugin
+
+Now `Guzzle\Plugin\CurlAuth\CurlAuthPlugin`.
+
+### Guzzle\Http\Plugin\ExponentialBackoffPlugin
+
+Now `Guzzle\Plugin\Backoff\BackoffPlugin`, and other changes.
+
+**Before**
+
+```php
+use Guzzle\Http\Plugin\ExponentialBackoffPlugin;
+
+$backoffPlugin = new ExponentialBackoffPlugin($maxRetries, array_merge(
+ ExponentialBackoffPlugin::getDefaultFailureCodes(), array(429)
+ ));
+
+$client->addSubscriber($backoffPlugin);
+```
+
+**After**
+
+```php
+use Guzzle\Plugin\Backoff\BackoffPlugin;
+use Guzzle\Plugin\Backoff\HttpBackoffStrategy;
+
+// Use convenient factory method instead -- see implementation for ideas of what
+// you can do with chaining backoff strategies
+$backoffPlugin = BackoffPlugin::getExponentialBackoff($maxRetries, array_merge(
+ HttpBackoffStrategy::getDefaultFailureCodes(), array(429)
+ ));
+$client->addSubscriber($backoffPlugin);
+```
+
+### Known Issues
+
+#### [BUG] Accept-Encoding header behavior changed unintentionally.
+
+(See #217) (Fixed in 09daeb8c666fb44499a0646d655a8ae36456575e)
+
+In version 2.8 setting the `Accept-Encoding` header would set the CURLOPT_ENCODING option, which permitted cURL to
+properly handle gzip/deflate compressed responses from the server. In versions affected by this bug this does not happen.
+See issue #217 for a workaround, or use a version containing the fix.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/composer.json
new file mode 100644
index 0000000..f369ce6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/composer.json
@@ -0,0 +1,105 @@
+{
+ "name": "guzzlehttp/guzzle",
+ "description": "Guzzle is a PHP HTTP client library",
+ "keywords": [
+ "framework",
+ "http",
+ "rest",
+ "web service",
+ "curl",
+ "client",
+ "HTTP client",
+ "PSR-7",
+ "PSR-18"
+ ],
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Jeremy Lindblom",
+ "email": "jeremeamia@gmail.com",
+ "homepage": "https://github.com/jeremeamia"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "require": {
+ "php": "^7.2.5 || ^8.0",
+ "ext-json": "*",
+ "guzzlehttp/promises": "^1.5",
+ "guzzlehttp/psr7": "^1.9 || ^2.4",
+ "psr/http-client": "^1.0",
+ "symfony/deprecation-contracts": "^2.2 || ^3.0"
+ },
+ "provide": {
+ "psr/http-client-implementation": "1.0"
+ },
+ "require-dev": {
+ "ext-curl": "*",
+ "bamarni/composer-bin-plugin": "^1.8.1",
+ "php-http/client-integration-tests": "^3.0",
+ "phpunit/phpunit": "^8.5.29 || ^9.5.23",
+ "psr/log": "^1.1 || ^2.0 || ^3.0"
+ },
+ "suggest": {
+ "ext-curl": "Required for CURL handler support",
+ "ext-intl": "Required for Internationalized Domain Name (IDN) support",
+ "psr/log": "Required for using the Log middleware"
+ },
+ "config": {
+ "allow-plugins": {
+ "bamarni/composer-bin-plugin": true
+ },
+ "preferred-install": "dist",
+ "sort-packages": true
+ },
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ },
+ "branch-alias": {
+ "dev-master": "7.5-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "GuzzleHttp\\": "src/"
+ },
+ "files": [
+ "src/functions_include.php"
+ ]
+ },
+ "autoload-dev": {
+ "psr-4": {
+ "GuzzleHttp\\Tests\\": "tests/"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/BodySummarizer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/BodySummarizer.php
new file mode 100644
index 0000000..6eca94e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/BodySummarizer.php
@@ -0,0 +1,28 @@
+<?php
+
+namespace GuzzleHttp;
+
+use Psr\Http\Message\MessageInterface;
+
+final class BodySummarizer implements BodySummarizerInterface
+{
+ /**
+ * @var int|null
+ */
+ private $truncateAt;
+
+ public function __construct(int $truncateAt = null)
+ {
+ $this->truncateAt = $truncateAt;
+ }
+
+ /**
+ * Returns a summarized message body.
+ */
+ public function summarize(MessageInterface $message): ?string
+ {
+ return $this->truncateAt === null
+ ? \GuzzleHttp\Psr7\Message::bodySummary($message)
+ : \GuzzleHttp\Psr7\Message::bodySummary($message, $this->truncateAt);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/BodySummarizerInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/BodySummarizerInterface.php
new file mode 100644
index 0000000..3e02e03
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/BodySummarizerInterface.php
@@ -0,0 +1,13 @@
+<?php
+
+namespace GuzzleHttp;
+
+use Psr\Http\Message\MessageInterface;
+
+interface BodySummarizerInterface
+{
+ /**
+ * Returns a summarized message body.
+ */
+ public function summarize(MessageInterface $message): ?string;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Client.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Client.php
new file mode 100644
index 0000000..58f1d89
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Client.php
@@ -0,0 +1,477 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Cookie\CookieJar;
+use GuzzleHttp\Exception\GuzzleException;
+use GuzzleHttp\Exception\InvalidArgumentException;
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * @final
+ */
+class Client implements ClientInterface, \Psr\Http\Client\ClientInterface
+{
+ use ClientTrait;
+
+ /**
+ * @var array Default request options
+ */
+ private $config;
+
+ /**
+ * Clients accept an array of constructor parameters.
+ *
+ * Here's an example of creating a client using a base_uri and an array of
+ * default request options to apply to each request:
+ *
+ * $client = new Client([
+ * 'base_uri' => 'http://www.foo.com/1.0/',
+ * 'timeout' => 0,
+ * 'allow_redirects' => false,
+ * 'proxy' => '192.168.16.1:10'
+ * ]);
+ *
+ * Client configuration settings include the following options:
+ *
+ * - handler: (callable) Function that transfers HTTP requests over the
+ * wire. The function is called with a Psr7\Http\Message\RequestInterface
+ * and array of transfer options, and must return a
+ * GuzzleHttp\Promise\PromiseInterface that is fulfilled with a
+ * Psr7\Http\Message\ResponseInterface on success.
+ * If no handler is provided, a default handler will be created
+ * that enables all of the request options below by attaching all of the
+ * default middleware to the handler.
+ * - base_uri: (string|UriInterface) Base URI of the client that is merged
+ * into relative URIs. Can be a string or instance of UriInterface.
+ * - **: any request option
+ *
+ * @param array $config Client configuration settings.
+ *
+ * @see \GuzzleHttp\RequestOptions for a list of available request options.
+ */
+ public function __construct(array $config = [])
+ {
+ if (!isset($config['handler'])) {
+ $config['handler'] = HandlerStack::create();
+ } elseif (!\is_callable($config['handler'])) {
+ throw new InvalidArgumentException('handler must be a callable');
+ }
+
+ // Convert the base_uri to a UriInterface
+ if (isset($config['base_uri'])) {
+ $config['base_uri'] = Psr7\Utils::uriFor($config['base_uri']);
+ }
+
+ $this->configureDefaults($config);
+ }
+
+ /**
+ * @param string $method
+ * @param array $args
+ *
+ * @return PromiseInterface|ResponseInterface
+ *
+ * @deprecated Client::__call will be removed in guzzlehttp/guzzle:8.0.
+ */
+ public function __call($method, $args)
+ {
+ if (\count($args) < 1) {
+ throw new InvalidArgumentException('Magic request methods require a URI and optional options array');
+ }
+
+ $uri = $args[0];
+ $opts = $args[1] ?? [];
+
+ return \substr($method, -5) === 'Async'
+ ? $this->requestAsync(\substr($method, 0, -5), $uri, $opts)
+ : $this->request($method, $uri, $opts);
+ }
+
+ /**
+ * Asynchronously send an HTTP request.
+ *
+ * @param array $options Request options to apply to the given
+ * request and to the transfer. See \GuzzleHttp\RequestOptions.
+ */
+ public function sendAsync(RequestInterface $request, array $options = []): PromiseInterface
+ {
+ // Merge the base URI into the request URI if needed.
+ $options = $this->prepareDefaults($options);
+
+ return $this->transfer(
+ $request->withUri($this->buildUri($request->getUri(), $options), $request->hasHeader('Host')),
+ $options
+ );
+ }
+
+ /**
+ * Send an HTTP request.
+ *
+ * @param array $options Request options to apply to the given
+ * request and to the transfer. See \GuzzleHttp\RequestOptions.
+ *
+ * @throws GuzzleException
+ */
+ public function send(RequestInterface $request, array $options = []): ResponseInterface
+ {
+ $options[RequestOptions::SYNCHRONOUS] = true;
+ return $this->sendAsync($request, $options)->wait();
+ }
+
+ /**
+ * The HttpClient PSR (PSR-18) specify this method.
+ *
+ * @inheritDoc
+ */
+ public function sendRequest(RequestInterface $request): ResponseInterface
+ {
+ $options[RequestOptions::SYNCHRONOUS] = true;
+ $options[RequestOptions::ALLOW_REDIRECTS] = false;
+ $options[RequestOptions::HTTP_ERRORS] = false;
+
+ return $this->sendAsync($request, $options)->wait();
+ }
+
+ /**
+ * Create and send an asynchronous HTTP request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string $method HTTP method
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions.
+ */
+ public function requestAsync(string $method, $uri = '', array $options = []): PromiseInterface
+ {
+ $options = $this->prepareDefaults($options);
+ // Remove request modifying parameter because it can be done up-front.
+ $headers = $options['headers'] ?? [];
+ $body = $options['body'] ?? null;
+ $version = $options['version'] ?? '1.1';
+ // Merge the URI into the base URI.
+ $uri = $this->buildUri(Psr7\Utils::uriFor($uri), $options);
+ if (\is_array($body)) {
+ throw $this->invalidBody();
+ }
+ $request = new Psr7\Request($method, $uri, $headers, $body, $version);
+ // Remove the option so that they are not doubly-applied.
+ unset($options['headers'], $options['body'], $options['version']);
+
+ return $this->transfer($request, $options);
+ }
+
+ /**
+ * Create and send an HTTP request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string $method HTTP method.
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions.
+ *
+ * @throws GuzzleException
+ */
+ public function request(string $method, $uri = '', array $options = []): ResponseInterface
+ {
+ $options[RequestOptions::SYNCHRONOUS] = true;
+ return $this->requestAsync($method, $uri, $options)->wait();
+ }
+
+ /**
+ * Get a client configuration option.
+ *
+ * These options include default request options of the client, a "handler"
+ * (if utilized by the concrete client), and a "base_uri" if utilized by
+ * the concrete client.
+ *
+ * @param string|null $option The config option to retrieve.
+ *
+ * @return mixed
+ *
+ * @deprecated Client::getConfig will be removed in guzzlehttp/guzzle:8.0.
+ */
+ public function getConfig(?string $option = null)
+ {
+ return $option === null
+ ? $this->config
+ : ($this->config[$option] ?? null);
+ }
+
+ private function buildUri(UriInterface $uri, array $config): UriInterface
+ {
+ if (isset($config['base_uri'])) {
+ $uri = Psr7\UriResolver::resolve(Psr7\Utils::uriFor($config['base_uri']), $uri);
+ }
+
+ if (isset($config['idn_conversion']) && ($config['idn_conversion'] !== false)) {
+ $idnOptions = ($config['idn_conversion'] === true) ? \IDNA_DEFAULT : $config['idn_conversion'];
+ $uri = Utils::idnUriConvert($uri, $idnOptions);
+ }
+
+ return $uri->getScheme() === '' && $uri->getHost() !== '' ? $uri->withScheme('http') : $uri;
+ }
+
+ /**
+ * Configures the default options for a client.
+ */
+ private function configureDefaults(array $config): void
+ {
+ $defaults = [
+ 'allow_redirects' => RedirectMiddleware::$defaultSettings,
+ 'http_errors' => true,
+ 'decode_content' => true,
+ 'verify' => true,
+ 'cookies' => false,
+ 'idn_conversion' => false,
+ ];
+
+ // Use the standard Linux HTTP_PROXY and HTTPS_PROXY if set.
+
+ // We can only trust the HTTP_PROXY environment variable in a CLI
+ // process due to the fact that PHP has no reliable mechanism to
+ // get environment variables that start with "HTTP_".
+ if (\PHP_SAPI === 'cli' && ($proxy = Utils::getenv('HTTP_PROXY'))) {
+ $defaults['proxy']['http'] = $proxy;
+ }
+
+ if ($proxy = Utils::getenv('HTTPS_PROXY')) {
+ $defaults['proxy']['https'] = $proxy;
+ }
+
+ if ($noProxy = Utils::getenv('NO_PROXY')) {
+ $cleanedNoProxy = \str_replace(' ', '', $noProxy);
+ $defaults['proxy']['no'] = \explode(',', $cleanedNoProxy);
+ }
+
+ $this->config = $config + $defaults;
+
+ if (!empty($config['cookies']) && $config['cookies'] === true) {
+ $this->config['cookies'] = new CookieJar();
+ }
+
+ // Add the default user-agent header.
+ if (!isset($this->config['headers'])) {
+ $this->config['headers'] = ['User-Agent' => Utils::defaultUserAgent()];
+ } else {
+ // Add the User-Agent header if one was not already set.
+ foreach (\array_keys($this->config['headers']) as $name) {
+ if (\strtolower($name) === 'user-agent') {
+ return;
+ }
+ }
+ $this->config['headers']['User-Agent'] = Utils::defaultUserAgent();
+ }
+ }
+
+ /**
+ * Merges default options into the array.
+ *
+ * @param array $options Options to modify by reference
+ */
+ private function prepareDefaults(array $options): array
+ {
+ $defaults = $this->config;
+
+ if (!empty($defaults['headers'])) {
+ // Default headers are only added if they are not present.
+ $defaults['_conditional'] = $defaults['headers'];
+ unset($defaults['headers']);
+ }
+
+ // Special handling for headers is required as they are added as
+ // conditional headers and as headers passed to a request ctor.
+ if (\array_key_exists('headers', $options)) {
+ // Allows default headers to be unset.
+ if ($options['headers'] === null) {
+ $defaults['_conditional'] = [];
+ unset($options['headers']);
+ } elseif (!\is_array($options['headers'])) {
+ throw new InvalidArgumentException('headers must be an array');
+ }
+ }
+
+ // Shallow merge defaults underneath options.
+ $result = $options + $defaults;
+
+ // Remove null values.
+ foreach ($result as $k => $v) {
+ if ($v === null) {
+ unset($result[$k]);
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Transfers the given request and applies request options.
+ *
+ * The URI of the request is not modified and the request options are used
+ * as-is without merging in default options.
+ *
+ * @param array $options See \GuzzleHttp\RequestOptions.
+ */
+ private function transfer(RequestInterface $request, array $options): PromiseInterface
+ {
+ $request = $this->applyOptions($request, $options);
+ /** @var HandlerStack $handler */
+ $handler = $options['handler'];
+
+ try {
+ return P\Create::promiseFor($handler($request, $options));
+ } catch (\Exception $e) {
+ return P\Create::rejectionFor($e);
+ }
+ }
+
+ /**
+ * Applies the array of request options to a request.
+ */
+ private function applyOptions(RequestInterface $request, array &$options): RequestInterface
+ {
+ $modify = [
+ 'set_headers' => [],
+ ];
+
+ if (isset($options['headers'])) {
+ if (array_keys($options['headers']) === range(0, count($options['headers']) - 1)) {
+ throw new InvalidArgumentException('The headers array must have header name as keys.');
+ }
+ $modify['set_headers'] = $options['headers'];
+ unset($options['headers']);
+ }
+
+ if (isset($options['form_params'])) {
+ if (isset($options['multipart'])) {
+ throw new InvalidArgumentException('You cannot use '
+ . 'form_params and multipart at the same time. Use the '
+ . 'form_params option if you want to send application/'
+ . 'x-www-form-urlencoded requests, and the multipart '
+ . 'option to send multipart/form-data requests.');
+ }
+ $options['body'] = \http_build_query($options['form_params'], '', '&');
+ unset($options['form_params']);
+ // Ensure that we don't have the header in different case and set the new value.
+ $options['_conditional'] = Psr7\Utils::caselessRemove(['Content-Type'], $options['_conditional']);
+ $options['_conditional']['Content-Type'] = 'application/x-www-form-urlencoded';
+ }
+
+ if (isset($options['multipart'])) {
+ $options['body'] = new Psr7\MultipartStream($options['multipart']);
+ unset($options['multipart']);
+ }
+
+ if (isset($options['json'])) {
+ $options['body'] = Utils::jsonEncode($options['json']);
+ unset($options['json']);
+ // Ensure that we don't have the header in different case and set the new value.
+ $options['_conditional'] = Psr7\Utils::caselessRemove(['Content-Type'], $options['_conditional']);
+ $options['_conditional']['Content-Type'] = 'application/json';
+ }
+
+ if (!empty($options['decode_content'])
+ && $options['decode_content'] !== true
+ ) {
+ // Ensure that we don't have the header in different case and set the new value.
+ $options['_conditional'] = Psr7\Utils::caselessRemove(['Accept-Encoding'], $options['_conditional']);
+ $modify['set_headers']['Accept-Encoding'] = $options['decode_content'];
+ }
+
+ if (isset($options['body'])) {
+ if (\is_array($options['body'])) {
+ throw $this->invalidBody();
+ }
+ $modify['body'] = Psr7\Utils::streamFor($options['body']);
+ unset($options['body']);
+ }
+
+ if (!empty($options['auth']) && \is_array($options['auth'])) {
+ $value = $options['auth'];
+ $type = isset($value[2]) ? \strtolower($value[2]) : 'basic';
+ switch ($type) {
+ case 'basic':
+ // Ensure that we don't have the header in different case and set the new value.
+ $modify['set_headers'] = Psr7\Utils::caselessRemove(['Authorization'], $modify['set_headers']);
+ $modify['set_headers']['Authorization'] = 'Basic '
+ . \base64_encode("$value[0]:$value[1]");
+ break;
+ case 'digest':
+ // @todo: Do not rely on curl
+ $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_DIGEST;
+ $options['curl'][\CURLOPT_USERPWD] = "$value[0]:$value[1]";
+ break;
+ case 'ntlm':
+ $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_NTLM;
+ $options['curl'][\CURLOPT_USERPWD] = "$value[0]:$value[1]";
+ break;
+ }
+ }
+
+ if (isset($options['query'])) {
+ $value = $options['query'];
+ if (\is_array($value)) {
+ $value = \http_build_query($value, '', '&', \PHP_QUERY_RFC3986);
+ }
+ if (!\is_string($value)) {
+ throw new InvalidArgumentException('query must be a string or array');
+ }
+ $modify['query'] = $value;
+ unset($options['query']);
+ }
+
+ // Ensure that sink is not an invalid value.
+ if (isset($options['sink'])) {
+ // TODO: Add more sink validation?
+ if (\is_bool($options['sink'])) {
+ throw new InvalidArgumentException('sink must not be a boolean');
+ }
+ }
+
+ $request = Psr7\Utils::modifyRequest($request, $modify);
+ if ($request->getBody() instanceof Psr7\MultipartStream) {
+ // Use a multipart/form-data POST if a Content-Type is not set.
+ // Ensure that we don't have the header in different case and set the new value.
+ $options['_conditional'] = Psr7\Utils::caselessRemove(['Content-Type'], $options['_conditional']);
+ $options['_conditional']['Content-Type'] = 'multipart/form-data; boundary='
+ . $request->getBody()->getBoundary();
+ }
+
+ // Merge in conditional headers if they are not present.
+ if (isset($options['_conditional'])) {
+ // Build up the changes so it's in a single clone of the message.
+ $modify = [];
+ foreach ($options['_conditional'] as $k => $v) {
+ if (!$request->hasHeader($k)) {
+ $modify['set_headers'][$k] = $v;
+ }
+ }
+ $request = Psr7\Utils::modifyRequest($request, $modify);
+ // Don't pass this internal value along to middleware/handlers.
+ unset($options['_conditional']);
+ }
+
+ return $request;
+ }
+
+ /**
+ * Return an InvalidArgumentException with pre-set message.
+ */
+ private function invalidBody(): InvalidArgumentException
+ {
+ return new InvalidArgumentException('Passing in the "body" request '
+ . 'option as an array to send a request is not supported. '
+ . 'Please use the "form_params" request option to send a '
+ . 'application/x-www-form-urlencoded request, or the "multipart" '
+ . 'request option to send a multipart/form-data request.');
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/ClientInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/ClientInterface.php
new file mode 100644
index 0000000..6aaee61
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/ClientInterface.php
@@ -0,0 +1,84 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Exception\GuzzleException;
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Client interface for sending HTTP requests.
+ */
+interface ClientInterface
+{
+ /**
+ * The Guzzle major version.
+ */
+ public const MAJOR_VERSION = 7;
+
+ /**
+ * Send an HTTP request.
+ *
+ * @param RequestInterface $request Request to send
+ * @param array $options Request options to apply to the given
+ * request and to the transfer.
+ *
+ * @throws GuzzleException
+ */
+ public function send(RequestInterface $request, array $options = []): ResponseInterface;
+
+ /**
+ * Asynchronously send an HTTP request.
+ *
+ * @param RequestInterface $request Request to send
+ * @param array $options Request options to apply to the given
+ * request and to the transfer.
+ */
+ public function sendAsync(RequestInterface $request, array $options = []): PromiseInterface;
+
+ /**
+ * Create and send an HTTP request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string $method HTTP method.
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ public function request(string $method, $uri, array $options = []): ResponseInterface;
+
+ /**
+ * Create and send an asynchronous HTTP request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string $method HTTP method
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ public function requestAsync(string $method, $uri, array $options = []): PromiseInterface;
+
+ /**
+ * Get a client configuration option.
+ *
+ * These options include default request options of the client, a "handler"
+ * (if utilized by the concrete client), and a "base_uri" if utilized by
+ * the concrete client.
+ *
+ * @param string|null $option The config option to retrieve.
+ *
+ * @return mixed
+ *
+ * @deprecated ClientInterface::getConfig will be removed in guzzlehttp/guzzle:8.0.
+ */
+ public function getConfig(?string $option = null);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/ClientTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/ClientTrait.php
new file mode 100644
index 0000000..c584c76
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/ClientTrait.php
@@ -0,0 +1,241 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Exception\GuzzleException;
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Client interface for sending HTTP requests.
+ */
+trait ClientTrait
+{
+ /**
+ * Create and send an HTTP request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string $method HTTP method.
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ abstract public function request(string $method, $uri, array $options = []): ResponseInterface;
+
+ /**
+ * Create and send an HTTP GET request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ public function get($uri, array $options = []): ResponseInterface
+ {
+ return $this->request('GET', $uri, $options);
+ }
+
+ /**
+ * Create and send an HTTP HEAD request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ public function head($uri, array $options = []): ResponseInterface
+ {
+ return $this->request('HEAD', $uri, $options);
+ }
+
+ /**
+ * Create and send an HTTP PUT request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ public function put($uri, array $options = []): ResponseInterface
+ {
+ return $this->request('PUT', $uri, $options);
+ }
+
+ /**
+ * Create and send an HTTP POST request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ public function post($uri, array $options = []): ResponseInterface
+ {
+ return $this->request('POST', $uri, $options);
+ }
+
+ /**
+ * Create and send an HTTP PATCH request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ public function patch($uri, array $options = []): ResponseInterface
+ {
+ return $this->request('PATCH', $uri, $options);
+ }
+
+ /**
+ * Create and send an HTTP DELETE request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ *
+ * @throws GuzzleException
+ */
+ public function delete($uri, array $options = []): ResponseInterface
+ {
+ return $this->request('DELETE', $uri, $options);
+ }
+
+ /**
+ * Create and send an asynchronous HTTP request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string $method HTTP method
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ abstract public function requestAsync(string $method, $uri, array $options = []): PromiseInterface;
+
+ /**
+ * Create and send an asynchronous HTTP GET request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ public function getAsync($uri, array $options = []): PromiseInterface
+ {
+ return $this->requestAsync('GET', $uri, $options);
+ }
+
+ /**
+ * Create and send an asynchronous HTTP HEAD request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ public function headAsync($uri, array $options = []): PromiseInterface
+ {
+ return $this->requestAsync('HEAD', $uri, $options);
+ }
+
+ /**
+ * Create and send an asynchronous HTTP PUT request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ public function putAsync($uri, array $options = []): PromiseInterface
+ {
+ return $this->requestAsync('PUT', $uri, $options);
+ }
+
+ /**
+ * Create and send an asynchronous HTTP POST request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ public function postAsync($uri, array $options = []): PromiseInterface
+ {
+ return $this->requestAsync('POST', $uri, $options);
+ }
+
+ /**
+ * Create and send an asynchronous HTTP PATCH request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ public function patchAsync($uri, array $options = []): PromiseInterface
+ {
+ return $this->requestAsync('PATCH', $uri, $options);
+ }
+
+ /**
+ * Create and send an asynchronous HTTP DELETE request.
+ *
+ * Use an absolute path to override the base path of the client, or a
+ * relative path to append to the base path of the client. The URL can
+ * contain the query string as well. Use an array to provide a URL
+ * template and additional variables to use in the URL template expansion.
+ *
+ * @param string|UriInterface $uri URI object or string.
+ * @param array $options Request options to apply.
+ */
+ public function deleteAsync($uri, array $options = []): PromiseInterface
+ {
+ return $this->requestAsync('DELETE', $uri, $options);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php
new file mode 100644
index 0000000..9985a98
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/CookieJar.php
@@ -0,0 +1,317 @@
+<?php
+
+namespace GuzzleHttp\Cookie;
+
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+/**
+ * Cookie jar that stores cookies as an array
+ */
+class CookieJar implements CookieJarInterface
+{
+ /**
+ * @var SetCookie[] Loaded cookie data
+ */
+ private $cookies = [];
+
+ /**
+ * @var bool
+ */
+ private $strictMode;
+
+ /**
+ * @param bool $strictMode Set to true to throw exceptions when invalid
+ * cookies are added to the cookie jar.
+ * @param array $cookieArray Array of SetCookie objects or a hash of
+ * arrays that can be used with the SetCookie
+ * constructor
+ */
+ public function __construct(bool $strictMode = false, array $cookieArray = [])
+ {
+ $this->strictMode = $strictMode;
+
+ foreach ($cookieArray as $cookie) {
+ if (!($cookie instanceof SetCookie)) {
+ $cookie = new SetCookie($cookie);
+ }
+ $this->setCookie($cookie);
+ }
+ }
+
+ /**
+ * Create a new Cookie jar from an associative array and domain.
+ *
+ * @param array $cookies Cookies to create the jar from
+ * @param string $domain Domain to set the cookies to
+ */
+ public static function fromArray(array $cookies, string $domain): self
+ {
+ $cookieJar = new self();
+ foreach ($cookies as $name => $value) {
+ $cookieJar->setCookie(new SetCookie([
+ 'Domain' => $domain,
+ 'Name' => $name,
+ 'Value' => $value,
+ 'Discard' => true
+ ]));
+ }
+
+ return $cookieJar;
+ }
+
+ /**
+ * Evaluate if this cookie should be persisted to storage
+ * that survives between requests.
+ *
+ * @param SetCookie $cookie Being evaluated.
+ * @param bool $allowSessionCookies If we should persist session cookies
+ */
+ public static function shouldPersist(SetCookie $cookie, bool $allowSessionCookies = false): bool
+ {
+ if ($cookie->getExpires() || $allowSessionCookies) {
+ if (!$cookie->getDiscard()) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Finds and returns the cookie based on the name
+ *
+ * @param string $name cookie name to search for
+ *
+ * @return SetCookie|null cookie that was found or null if not found
+ */
+ public function getCookieByName(string $name): ?SetCookie
+ {
+ foreach ($this->cookies as $cookie) {
+ if ($cookie->getName() !== null && \strcasecmp($cookie->getName(), $name) === 0) {
+ return $cookie;
+ }
+ }
+
+ return null;
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function toArray(): array
+ {
+ return \array_map(static function (SetCookie $cookie): array {
+ return $cookie->toArray();
+ }, $this->getIterator()->getArrayCopy());
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function clear(?string $domain = null, ?string $path = null, ?string $name = null): void
+ {
+ if (!$domain) {
+ $this->cookies = [];
+ return;
+ } elseif (!$path) {
+ $this->cookies = \array_filter(
+ $this->cookies,
+ static function (SetCookie $cookie) use ($domain): bool {
+ return !$cookie->matchesDomain($domain);
+ }
+ );
+ } elseif (!$name) {
+ $this->cookies = \array_filter(
+ $this->cookies,
+ static function (SetCookie $cookie) use ($path, $domain): bool {
+ return !($cookie->matchesPath($path) &&
+ $cookie->matchesDomain($domain));
+ }
+ );
+ } else {
+ $this->cookies = \array_filter(
+ $this->cookies,
+ static function (SetCookie $cookie) use ($path, $domain, $name) {
+ return !($cookie->getName() == $name &&
+ $cookie->matchesPath($path) &&
+ $cookie->matchesDomain($domain));
+ }
+ );
+ }
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function clearSessionCookies(): void
+ {
+ $this->cookies = \array_filter(
+ $this->cookies,
+ static function (SetCookie $cookie): bool {
+ return !$cookie->getDiscard() && $cookie->getExpires();
+ }
+ );
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function setCookie(SetCookie $cookie): bool
+ {
+ // If the name string is empty (but not 0), ignore the set-cookie
+ // string entirely.
+ $name = $cookie->getName();
+ if (!$name && $name !== '0') {
+ return false;
+ }
+
+ // Only allow cookies with set and valid domain, name, value
+ $result = $cookie->validate();
+ if ($result !== true) {
+ if ($this->strictMode) {
+ throw new \RuntimeException('Invalid cookie: ' . $result);
+ }
+ $this->removeCookieIfEmpty($cookie);
+ return false;
+ }
+
+ // Resolve conflicts with previously set cookies
+ foreach ($this->cookies as $i => $c) {
+ // Two cookies are identical, when their path, and domain are
+ // identical.
+ if ($c->getPath() != $cookie->getPath() ||
+ $c->getDomain() != $cookie->getDomain() ||
+ $c->getName() != $cookie->getName()
+ ) {
+ continue;
+ }
+
+ // The previously set cookie is a discard cookie and this one is
+ // not so allow the new cookie to be set
+ if (!$cookie->getDiscard() && $c->getDiscard()) {
+ unset($this->cookies[$i]);
+ continue;
+ }
+
+ // If the new cookie's expiration is further into the future, then
+ // replace the old cookie
+ if ($cookie->getExpires() > $c->getExpires()) {
+ unset($this->cookies[$i]);
+ continue;
+ }
+
+ // If the value has changed, we better change it
+ if ($cookie->getValue() !== $c->getValue()) {
+ unset($this->cookies[$i]);
+ continue;
+ }
+
+ // The cookie exists, so no need to continue
+ return false;
+ }
+
+ $this->cookies[] = $cookie;
+
+ return true;
+ }
+
+ public function count(): int
+ {
+ return \count($this->cookies);
+ }
+
+ /**
+ * @return \ArrayIterator<int, SetCookie>
+ */
+ public function getIterator(): \ArrayIterator
+ {
+ return new \ArrayIterator(\array_values($this->cookies));
+ }
+
+ public function extractCookies(RequestInterface $request, ResponseInterface $response): void
+ {
+ if ($cookieHeader = $response->getHeader('Set-Cookie')) {
+ foreach ($cookieHeader as $cookie) {
+ $sc = SetCookie::fromString($cookie);
+ if (!$sc->getDomain()) {
+ $sc->setDomain($request->getUri()->getHost());
+ }
+ if (0 !== \strpos($sc->getPath(), '/')) {
+ $sc->setPath($this->getCookiePathFromRequest($request));
+ }
+ if (!$sc->matchesDomain($request->getUri()->getHost())) {
+ continue;
+ }
+ // Note: At this point `$sc->getDomain()` being a public suffix should
+ // be rejected, but we don't want to pull in the full PSL dependency.
+ $this->setCookie($sc);
+ }
+ }
+ }
+
+ /**
+ * Computes cookie path following RFC 6265 section 5.1.4
+ *
+ * @link https://tools.ietf.org/html/rfc6265#section-5.1.4
+ */
+ private function getCookiePathFromRequest(RequestInterface $request): string
+ {
+ $uriPath = $request->getUri()->getPath();
+ if ('' === $uriPath) {
+ return '/';
+ }
+ if (0 !== \strpos($uriPath, '/')) {
+ return '/';
+ }
+ if ('/' === $uriPath) {
+ return '/';
+ }
+ $lastSlashPos = \strrpos($uriPath, '/');
+ if (0 === $lastSlashPos || false === $lastSlashPos) {
+ return '/';
+ }
+
+ return \substr($uriPath, 0, $lastSlashPos);
+ }
+
+ public function withCookieHeader(RequestInterface $request): RequestInterface
+ {
+ $values = [];
+ $uri = $request->getUri();
+ $scheme = $uri->getScheme();
+ $host = $uri->getHost();
+ $path = $uri->getPath() ?: '/';
+
+ foreach ($this->cookies as $cookie) {
+ if ($cookie->matchesPath($path) &&
+ $cookie->matchesDomain($host) &&
+ !$cookie->isExpired() &&
+ (!$cookie->getSecure() || $scheme === 'https')
+ ) {
+ $values[] = $cookie->getName() . '='
+ . $cookie->getValue();
+ }
+ }
+
+ return $values
+ ? $request->withHeader('Cookie', \implode('; ', $values))
+ : $request;
+ }
+
+ /**
+ * If a cookie already exists and the server asks to set it again with a
+ * null value, the cookie must be deleted.
+ */
+ private function removeCookieIfEmpty(SetCookie $cookie): void
+ {
+ $cookieValue = $cookie->getValue();
+ if ($cookieValue === null || $cookieValue === '') {
+ $this->clear(
+ $cookie->getDomain(),
+ $cookie->getPath(),
+ $cookie->getName()
+ );
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php
new file mode 100644
index 0000000..7df374b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php
@@ -0,0 +1,79 @@
+<?php
+
+namespace GuzzleHttp\Cookie;
+
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+/**
+ * Stores HTTP cookies.
+ *
+ * It extracts cookies from HTTP requests, and returns them in HTTP responses.
+ * CookieJarInterface instances automatically expire contained cookies when
+ * necessary. Subclasses are also responsible for storing and retrieving
+ * cookies from a file, database, etc.
+ *
+ * @link https://docs.python.org/2/library/cookielib.html Inspiration
+ * @extends \IteratorAggregate<SetCookie>
+ */
+interface CookieJarInterface extends \Countable, \IteratorAggregate
+{
+ /**
+ * Create a request with added cookie headers.
+ *
+ * If no matching cookies are found in the cookie jar, then no Cookie
+ * header is added to the request and the same request is returned.
+ *
+ * @param RequestInterface $request Request object to modify.
+ *
+ * @return RequestInterface returns the modified request.
+ */
+ public function withCookieHeader(RequestInterface $request): RequestInterface;
+
+ /**
+ * Extract cookies from an HTTP response and store them in the CookieJar.
+ *
+ * @param RequestInterface $request Request that was sent
+ * @param ResponseInterface $response Response that was received
+ */
+ public function extractCookies(RequestInterface $request, ResponseInterface $response): void;
+
+ /**
+ * Sets a cookie in the cookie jar.
+ *
+ * @param SetCookie $cookie Cookie to set.
+ *
+ * @return bool Returns true on success or false on failure
+ */
+ public function setCookie(SetCookie $cookie): bool;
+
+ /**
+ * Remove cookies currently held in the cookie jar.
+ *
+ * Invoking this method without arguments will empty the whole cookie jar.
+ * If given a $domain argument only cookies belonging to that domain will
+ * be removed. If given a $domain and $path argument, cookies belonging to
+ * the specified path within that domain are removed. If given all three
+ * arguments, then the cookie with the specified name, path and domain is
+ * removed.
+ *
+ * @param string|null $domain Clears cookies matching a domain
+ * @param string|null $path Clears cookies matching a domain and path
+ * @param string|null $name Clears cookies matching a domain, path, and name
+ */
+ public function clear(?string $domain = null, ?string $path = null, ?string $name = null): void;
+
+ /**
+ * Discard all sessions cookies.
+ *
+ * Removes cookies that don't have an expire field or a have a discard
+ * field set to true. To be called when the user agent shuts down according
+ * to RFC 2965.
+ */
+ public function clearSessionCookies(): void;
+
+ /**
+ * Converts the cookie jar to an array.
+ */
+ public function toArray(): array;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php
new file mode 100644
index 0000000..290236d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php
@@ -0,0 +1,101 @@
+<?php
+
+namespace GuzzleHttp\Cookie;
+
+use GuzzleHttp\Utils;
+
+/**
+ * Persists non-session cookies using a JSON formatted file
+ */
+class FileCookieJar extends CookieJar
+{
+ /**
+ * @var string filename
+ */
+ private $filename;
+
+ /**
+ * @var bool Control whether to persist session cookies or not.
+ */
+ private $storeSessionCookies;
+
+ /**
+ * Create a new FileCookieJar object
+ *
+ * @param string $cookieFile File to store the cookie data
+ * @param bool $storeSessionCookies Set to true to store session cookies
+ * in the cookie jar.
+ *
+ * @throws \RuntimeException if the file cannot be found or created
+ */
+ public function __construct(string $cookieFile, bool $storeSessionCookies = false)
+ {
+ parent::__construct();
+ $this->filename = $cookieFile;
+ $this->storeSessionCookies = $storeSessionCookies;
+
+ if (\file_exists($cookieFile)) {
+ $this->load($cookieFile);
+ }
+ }
+
+ /**
+ * Saves the file when shutting down
+ */
+ public function __destruct()
+ {
+ $this->save($this->filename);
+ }
+
+ /**
+ * Saves the cookies to a file.
+ *
+ * @param string $filename File to save
+ *
+ * @throws \RuntimeException if the file cannot be found or created
+ */
+ public function save(string $filename): void
+ {
+ $json = [];
+ /** @var SetCookie $cookie */
+ foreach ($this as $cookie) {
+ if (CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) {
+ $json[] = $cookie->toArray();
+ }
+ }
+
+ $jsonStr = Utils::jsonEncode($json);
+ if (false === \file_put_contents($filename, $jsonStr, \LOCK_EX)) {
+ throw new \RuntimeException("Unable to save file {$filename}");
+ }
+ }
+
+ /**
+ * Load cookies from a JSON formatted file.
+ *
+ * Old cookies are kept unless overwritten by newly loaded ones.
+ *
+ * @param string $filename Cookie file to load.
+ *
+ * @throws \RuntimeException if the file cannot be loaded.
+ */
+ public function load(string $filename): void
+ {
+ $json = \file_get_contents($filename);
+ if (false === $json) {
+ throw new \RuntimeException("Unable to load file {$filename}");
+ }
+ if ($json === '') {
+ return;
+ }
+
+ $data = Utils::jsonDecode($json, true);
+ if (\is_array($data)) {
+ foreach ($data as $cookie) {
+ $this->setCookie(new SetCookie($cookie));
+ }
+ } elseif (\is_scalar($data) && !empty($data)) {
+ throw new \RuntimeException("Invalid cookie file: {$filename}");
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php
new file mode 100644
index 0000000..5d51ca9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php
@@ -0,0 +1,77 @@
+<?php
+
+namespace GuzzleHttp\Cookie;
+
+/**
+ * Persists cookies in the client session
+ */
+class SessionCookieJar extends CookieJar
+{
+ /**
+ * @var string session key
+ */
+ private $sessionKey;
+
+ /**
+ * @var bool Control whether to persist session cookies or not.
+ */
+ private $storeSessionCookies;
+
+ /**
+ * Create a new SessionCookieJar object
+ *
+ * @param string $sessionKey Session key name to store the cookie
+ * data in session
+ * @param bool $storeSessionCookies Set to true to store session cookies
+ * in the cookie jar.
+ */
+ public function __construct(string $sessionKey, bool $storeSessionCookies = false)
+ {
+ parent::__construct();
+ $this->sessionKey = $sessionKey;
+ $this->storeSessionCookies = $storeSessionCookies;
+ $this->load();
+ }
+
+ /**
+ * Saves cookies to session when shutting down
+ */
+ public function __destruct()
+ {
+ $this->save();
+ }
+
+ /**
+ * Save cookies to the client session
+ */
+ public function save(): void
+ {
+ $json = [];
+ /** @var SetCookie $cookie */
+ foreach ($this as $cookie) {
+ if (CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) {
+ $json[] = $cookie->toArray();
+ }
+ }
+
+ $_SESSION[$this->sessionKey] = \json_encode($json);
+ }
+
+ /**
+ * Load the contents of the client session into the data array
+ */
+ protected function load(): void
+ {
+ if (!isset($_SESSION[$this->sessionKey])) {
+ return;
+ }
+ $data = \json_decode($_SESSION[$this->sessionKey], true);
+ if (\is_array($data)) {
+ foreach ($data as $cookie) {
+ $this->setCookie(new SetCookie($cookie));
+ }
+ } elseif (\strlen($data)) {
+ throw new \RuntimeException("Invalid cookie data");
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php
new file mode 100644
index 0000000..a613c77
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php
@@ -0,0 +1,446 @@
+<?php
+
+namespace GuzzleHttp\Cookie;
+
+/**
+ * Set-Cookie object
+ */
+class SetCookie
+{
+ /**
+ * @var array
+ */
+ private static $defaults = [
+ 'Name' => null,
+ 'Value' => null,
+ 'Domain' => null,
+ 'Path' => '/',
+ 'Max-Age' => null,
+ 'Expires' => null,
+ 'Secure' => false,
+ 'Discard' => false,
+ 'HttpOnly' => false
+ ];
+
+ /**
+ * @var array Cookie data
+ */
+ private $data;
+
+ /**
+ * Create a new SetCookie object from a string.
+ *
+ * @param string $cookie Set-Cookie header string
+ */
+ public static function fromString(string $cookie): self
+ {
+ // Create the default return array
+ $data = self::$defaults;
+ // Explode the cookie string using a series of semicolons
+ $pieces = \array_filter(\array_map('trim', \explode(';', $cookie)));
+ // The name of the cookie (first kvp) must exist and include an equal sign.
+ if (!isset($pieces[0]) || \strpos($pieces[0], '=') === false) {
+ return new self($data);
+ }
+
+ // Add the cookie pieces into the parsed data array
+ foreach ($pieces as $part) {
+ $cookieParts = \explode('=', $part, 2);
+ $key = \trim($cookieParts[0]);
+ $value = isset($cookieParts[1])
+ ? \trim($cookieParts[1], " \n\r\t\0\x0B")
+ : true;
+
+ // Only check for non-cookies when cookies have been found
+ if (!isset($data['Name'])) {
+ $data['Name'] = $key;
+ $data['Value'] = $value;
+ } else {
+ foreach (\array_keys(self::$defaults) as $search) {
+ if (!\strcasecmp($search, $key)) {
+ $data[$search] = $value;
+ continue 2;
+ }
+ }
+ $data[$key] = $value;
+ }
+ }
+
+ return new self($data);
+ }
+
+ /**
+ * @param array $data Array of cookie data provided by a Cookie parser
+ */
+ public function __construct(array $data = [])
+ {
+ /** @var array|null $replaced will be null in case of replace error */
+ $replaced = \array_replace(self::$defaults, $data);
+ if ($replaced === null) {
+ throw new \InvalidArgumentException('Unable to replace the default values for the Cookie.');
+ }
+
+ $this->data = $replaced;
+ // Extract the Expires value and turn it into a UNIX timestamp if needed
+ if (!$this->getExpires() && $this->getMaxAge()) {
+ // Calculate the Expires date
+ $this->setExpires(\time() + $this->getMaxAge());
+ } elseif (null !== ($expires = $this->getExpires()) && !\is_numeric($expires)) {
+ $this->setExpires($expires);
+ }
+ }
+
+ public function __toString()
+ {
+ $str = $this->data['Name'] . '=' . ($this->data['Value'] ?? '') . '; ';
+ foreach ($this->data as $k => $v) {
+ if ($k !== 'Name' && $k !== 'Value' && $v !== null && $v !== false) {
+ if ($k === 'Expires') {
+ $str .= 'Expires=' . \gmdate('D, d M Y H:i:s \G\M\T', $v) . '; ';
+ } else {
+ $str .= ($v === true ? $k : "{$k}={$v}") . '; ';
+ }
+ }
+ }
+
+ return \rtrim($str, '; ');
+ }
+
+ public function toArray(): array
+ {
+ return $this->data;
+ }
+
+ /**
+ * Get the cookie name.
+ *
+ * @return string
+ */
+ public function getName()
+ {
+ return $this->data['Name'];
+ }
+
+ /**
+ * Set the cookie name.
+ *
+ * @param string $name Cookie name
+ */
+ public function setName($name): void
+ {
+ if (!is_string($name)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a string to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Name'] = (string) $name;
+ }
+
+ /**
+ * Get the cookie value.
+ *
+ * @return string|null
+ */
+ public function getValue()
+ {
+ return $this->data['Value'];
+ }
+
+ /**
+ * Set the cookie value.
+ *
+ * @param string $value Cookie value
+ */
+ public function setValue($value): void
+ {
+ if (!is_string($value)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a string to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Value'] = (string) $value;
+ }
+
+ /**
+ * Get the domain.
+ *
+ * @return string|null
+ */
+ public function getDomain()
+ {
+ return $this->data['Domain'];
+ }
+
+ /**
+ * Set the domain of the cookie.
+ *
+ * @param string|null $domain
+ */
+ public function setDomain($domain): void
+ {
+ if (!is_string($domain) && null !== $domain) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a string or null to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Domain'] = null === $domain ? null : (string) $domain;
+ }
+
+ /**
+ * Get the path.
+ *
+ * @return string
+ */
+ public function getPath()
+ {
+ return $this->data['Path'];
+ }
+
+ /**
+ * Set the path of the cookie.
+ *
+ * @param string $path Path of the cookie
+ */
+ public function setPath($path): void
+ {
+ if (!is_string($path)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a string to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Path'] = (string) $path;
+ }
+
+ /**
+ * Maximum lifetime of the cookie in seconds.
+ *
+ * @return int|null
+ */
+ public function getMaxAge()
+ {
+ return null === $this->data['Max-Age'] ? null : (int) $this->data['Max-Age'];
+ }
+
+ /**
+ * Set the max-age of the cookie.
+ *
+ * @param int|null $maxAge Max age of the cookie in seconds
+ */
+ public function setMaxAge($maxAge): void
+ {
+ if (!is_int($maxAge) && null !== $maxAge) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing an int or null to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Max-Age'] = $maxAge === null ? null : (int) $maxAge;
+ }
+
+ /**
+ * The UNIX timestamp when the cookie Expires.
+ *
+ * @return string|int|null
+ */
+ public function getExpires()
+ {
+ return $this->data['Expires'];
+ }
+
+ /**
+ * Set the unix timestamp for which the cookie will expire.
+ *
+ * @param int|string|null $timestamp Unix timestamp or any English textual datetime description.
+ */
+ public function setExpires($timestamp): void
+ {
+ if (!is_int($timestamp) && !is_string($timestamp) && null !== $timestamp) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing an int, string or null to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Expires'] = null === $timestamp ? null : (\is_numeric($timestamp) ? (int) $timestamp : \strtotime((string) $timestamp));
+ }
+
+ /**
+ * Get whether or not this is a secure cookie.
+ *
+ * @return bool
+ */
+ public function getSecure()
+ {
+ return $this->data['Secure'];
+ }
+
+ /**
+ * Set whether or not the cookie is secure.
+ *
+ * @param bool $secure Set to true or false if secure
+ */
+ public function setSecure($secure): void
+ {
+ if (!is_bool($secure)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a bool to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Secure'] = (bool) $secure;
+ }
+
+ /**
+ * Get whether or not this is a session cookie.
+ *
+ * @return bool|null
+ */
+ public function getDiscard()
+ {
+ return $this->data['Discard'];
+ }
+
+ /**
+ * Set whether or not this is a session cookie.
+ *
+ * @param bool $discard Set to true or false if this is a session cookie
+ */
+ public function setDiscard($discard): void
+ {
+ if (!is_bool($discard)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a bool to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['Discard'] = (bool) $discard;
+ }
+
+ /**
+ * Get whether or not this is an HTTP only cookie.
+ *
+ * @return bool
+ */
+ public function getHttpOnly()
+ {
+ return $this->data['HttpOnly'];
+ }
+
+ /**
+ * Set whether or not this is an HTTP only cookie.
+ *
+ * @param bool $httpOnly Set to true or false if this is HTTP only
+ */
+ public function setHttpOnly($httpOnly): void
+ {
+ if (!is_bool($httpOnly)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a bool to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->data['HttpOnly'] = (bool) $httpOnly;
+ }
+
+ /**
+ * Check if the cookie matches a path value.
+ *
+ * A request-path path-matches a given cookie-path if at least one of
+ * the following conditions holds:
+ *
+ * - The cookie-path and the request-path are identical.
+ * - The cookie-path is a prefix of the request-path, and the last
+ * character of the cookie-path is %x2F ("/").
+ * - The cookie-path is a prefix of the request-path, and the first
+ * character of the request-path that is not included in the cookie-
+ * path is a %x2F ("/") character.
+ *
+ * @param string $requestPath Path to check against
+ */
+ public function matchesPath(string $requestPath): bool
+ {
+ $cookiePath = $this->getPath();
+
+ // Match on exact matches or when path is the default empty "/"
+ if ($cookiePath === '/' || $cookiePath == $requestPath) {
+ return true;
+ }
+
+ // Ensure that the cookie-path is a prefix of the request path.
+ if (0 !== \strpos($requestPath, $cookiePath)) {
+ return false;
+ }
+
+ // Match if the last character of the cookie-path is "/"
+ if (\substr($cookiePath, -1, 1) === '/') {
+ return true;
+ }
+
+ // Match if the first character not included in cookie path is "/"
+ return \substr($requestPath, \strlen($cookiePath), 1) === '/';
+ }
+
+ /**
+ * Check if the cookie matches a domain value.
+ *
+ * @param string $domain Domain to check against
+ */
+ public function matchesDomain(string $domain): bool
+ {
+ $cookieDomain = $this->getDomain();
+ if (null === $cookieDomain) {
+ return true;
+ }
+
+ // Remove the leading '.' as per spec in RFC 6265.
+ // https://tools.ietf.org/html/rfc6265#section-5.2.3
+ $cookieDomain = \ltrim(\strtolower($cookieDomain), '.');
+
+ $domain = \strtolower($domain);
+
+ // Domain not set or exact match.
+ if ('' === $cookieDomain || $domain === $cookieDomain) {
+ return true;
+ }
+
+ // Matching the subdomain according to RFC 6265.
+ // https://tools.ietf.org/html/rfc6265#section-5.1.3
+ if (\filter_var($domain, \FILTER_VALIDATE_IP)) {
+ return false;
+ }
+
+ return (bool) \preg_match('/\.' . \preg_quote($cookieDomain, '/') . '$/', $domain);
+ }
+
+ /**
+ * Check if the cookie is expired.
+ */
+ public function isExpired(): bool
+ {
+ return $this->getExpires() !== null && \time() > $this->getExpires();
+ }
+
+ /**
+ * Check if the cookie is valid according to RFC 6265.
+ *
+ * @return bool|string Returns true if valid or an error message if invalid
+ */
+ public function validate()
+ {
+ $name = $this->getName();
+ if ($name === '') {
+ return 'The cookie name must not be empty';
+ }
+
+ // Check if any of the invalid characters are present in the cookie name
+ if (\preg_match(
+ '/[\x00-\x20\x22\x28-\x29\x2c\x2f\x3a-\x40\x5c\x7b\x7d\x7f]/',
+ $name
+ )) {
+ return 'Cookie name must not contain invalid characters: ASCII '
+ . 'Control characters (0-31;127), space, tab and the '
+ . 'following characters: ()<>@,;:\"/?={}';
+ }
+
+ // Value must not be null. 0 and empty string are valid. Empty strings
+ // are technically against RFC 6265, but known to happen in the wild.
+ $value = $this->getValue();
+ if ($value === null) {
+ return 'The cookie value must not be empty';
+ }
+
+ // Domains must not be empty, but can be 0. "0" is not a valid internet
+ // domain, but may be used as server name in a private network.
+ $domain = $this->getDomain();
+ if ($domain === null || $domain === '') {
+ return 'The cookie domain must not be empty';
+ }
+
+ return true;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php
new file mode 100644
index 0000000..a80956c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php
@@ -0,0 +1,39 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+/**
+ * Exception when an HTTP error occurs (4xx or 5xx error)
+ */
+class BadResponseException extends RequestException
+{
+ public function __construct(
+ string $message,
+ RequestInterface $request,
+ ResponseInterface $response,
+ \Throwable $previous = null,
+ array $handlerContext = []
+ ) {
+ parent::__construct($message, $request, $response, $previous, $handlerContext);
+ }
+
+ /**
+ * Current exception and the ones that extend it will always have a response.
+ */
+ public function hasResponse(): bool
+ {
+ return true;
+ }
+
+ /**
+ * This function narrows the return type from the parent class and does not allow it to be nullable.
+ */
+ public function getResponse(): ResponseInterface
+ {
+ /** @var ResponseInterface */
+ return parent::getResponse();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ClientException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ClientException.php
new file mode 100644
index 0000000..12fa5e3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ClientException.php
@@ -0,0 +1,10 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+/**
+ * Exception when a client error is encountered (4xx codes)
+ */
+class ClientException extends BadResponseException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ConnectException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ConnectException.php
new file mode 100644
index 0000000..e1a3151
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ConnectException.php
@@ -0,0 +1,56 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+use Psr\Http\Client\NetworkExceptionInterface;
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Exception thrown when a connection cannot be established.
+ *
+ * Note that no response is present for a ConnectException
+ */
+class ConnectException extends TransferException implements NetworkExceptionInterface
+{
+ /**
+ * @var RequestInterface
+ */
+ private $request;
+
+ /**
+ * @var array
+ */
+ private $handlerContext;
+
+ public function __construct(
+ string $message,
+ RequestInterface $request,
+ \Throwable $previous = null,
+ array $handlerContext = []
+ ) {
+ parent::__construct($message, 0, $previous);
+ $this->request = $request;
+ $this->handlerContext = $handlerContext;
+ }
+
+ /**
+ * Get the request that caused the exception
+ */
+ public function getRequest(): RequestInterface
+ {
+ return $this->request;
+ }
+
+ /**
+ * Get contextual information about the error from the underlying handler.
+ *
+ * The contents of this array will vary depending on which handler you are
+ * using. It may also be just an empty array. Relying on this data will
+ * couple you to a specific handler, but can give more debug information
+ * when needed.
+ */
+ public function getHandlerContext(): array
+ {
+ return $this->handlerContext;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/GuzzleException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/GuzzleException.php
new file mode 100644
index 0000000..fa3ed69
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/GuzzleException.php
@@ -0,0 +1,9 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+use Psr\Http\Client\ClientExceptionInterface;
+
+interface GuzzleException extends ClientExceptionInterface
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php
new file mode 100644
index 0000000..bfd20e2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+final class InvalidArgumentException extends \InvalidArgumentException implements GuzzleException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php
new file mode 100644
index 0000000..c2d0a9c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php
@@ -0,0 +1,166 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+use GuzzleHttp\BodySummarizer;
+use GuzzleHttp\BodySummarizerInterface;
+use Psr\Http\Client\RequestExceptionInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * HTTP Request exception
+ */
+class RequestException extends TransferException implements RequestExceptionInterface
+{
+ /**
+ * @var RequestInterface
+ */
+ private $request;
+
+ /**
+ * @var ResponseInterface|null
+ */
+ private $response;
+
+ /**
+ * @var array
+ */
+ private $handlerContext;
+
+ public function __construct(
+ string $message,
+ RequestInterface $request,
+ ResponseInterface $response = null,
+ \Throwable $previous = null,
+ array $handlerContext = []
+ ) {
+ // Set the code of the exception if the response is set and not future.
+ $code = $response ? $response->getStatusCode() : 0;
+ parent::__construct($message, $code, $previous);
+ $this->request = $request;
+ $this->response = $response;
+ $this->handlerContext = $handlerContext;
+ }
+
+ /**
+ * Wrap non-RequestExceptions with a RequestException
+ */
+ public static function wrapException(RequestInterface $request, \Throwable $e): RequestException
+ {
+ return $e instanceof RequestException ? $e : new RequestException($e->getMessage(), $request, null, $e);
+ }
+
+ /**
+ * Factory method to create a new exception with a normalized error message
+ *
+ * @param RequestInterface $request Request sent
+ * @param ResponseInterface $response Response received
+ * @param \Throwable|null $previous Previous exception
+ * @param array $handlerContext Optional handler context
+ * @param BodySummarizerInterface|null $bodySummarizer Optional body summarizer
+ */
+ public static function create(
+ RequestInterface $request,
+ ResponseInterface $response = null,
+ \Throwable $previous = null,
+ array $handlerContext = [],
+ BodySummarizerInterface $bodySummarizer = null
+ ): self {
+ if (!$response) {
+ return new self(
+ 'Error completing request',
+ $request,
+ null,
+ $previous,
+ $handlerContext
+ );
+ }
+
+ $level = (int) \floor($response->getStatusCode() / 100);
+ if ($level === 4) {
+ $label = 'Client error';
+ $className = ClientException::class;
+ } elseif ($level === 5) {
+ $label = 'Server error';
+ $className = ServerException::class;
+ } else {
+ $label = 'Unsuccessful request';
+ $className = __CLASS__;
+ }
+
+ $uri = $request->getUri();
+ $uri = static::obfuscateUri($uri);
+
+ // Client Error: `GET /` resulted in a `404 Not Found` response:
+ // <html> ... (truncated)
+ $message = \sprintf(
+ '%s: `%s %s` resulted in a `%s %s` response',
+ $label,
+ $request->getMethod(),
+ $uri->__toString(),
+ $response->getStatusCode(),
+ $response->getReasonPhrase()
+ );
+
+ $summary = ($bodySummarizer ?? new BodySummarizer())->summarize($response);
+
+ if ($summary !== null) {
+ $message .= ":\n{$summary}\n";
+ }
+
+ return new $className($message, $request, $response, $previous, $handlerContext);
+ }
+
+ /**
+ * Obfuscates URI if there is a username and a password present
+ */
+ private static function obfuscateUri(UriInterface $uri): UriInterface
+ {
+ $userInfo = $uri->getUserInfo();
+
+ if (false !== ($pos = \strpos($userInfo, ':'))) {
+ return $uri->withUserInfo(\substr($userInfo, 0, $pos), '***');
+ }
+
+ return $uri;
+ }
+
+ /**
+ * Get the request that caused the exception
+ */
+ public function getRequest(): RequestInterface
+ {
+ return $this->request;
+ }
+
+ /**
+ * Get the associated response
+ */
+ public function getResponse(): ?ResponseInterface
+ {
+ return $this->response;
+ }
+
+ /**
+ * Check if a response was received
+ */
+ public function hasResponse(): bool
+ {
+ return $this->response !== null;
+ }
+
+ /**
+ * Get contextual information about the error from the underlying handler.
+ *
+ * The contents of this array will vary depending on which handler you are
+ * using. It may also be just an empty array. Relying on this data will
+ * couple you to a specific handler, but can give more debug information
+ * when needed.
+ */
+ public function getHandlerContext(): array
+ {
+ return $this->handlerContext;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php
new file mode 100644
index 0000000..8055e06
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php
@@ -0,0 +1,10 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+/**
+ * Exception when a server error is encountered (5xx codes)
+ */
+class ServerException extends BadResponseException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php
new file mode 100644
index 0000000..fad3a57
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+class TooManyRedirectsException extends RequestException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/TransferException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/TransferException.php
new file mode 100644
index 0000000..5076336
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Exception/TransferException.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace GuzzleHttp\Exception;
+
+class TransferException extends \RuntimeException implements GuzzleException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php
new file mode 100644
index 0000000..0c45089
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php
@@ -0,0 +1,595 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Exception\ConnectException;
+use GuzzleHttp\Exception\RequestException;
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\FulfilledPromise;
+use GuzzleHttp\Promise\PromiseInterface;
+use GuzzleHttp\Psr7\LazyOpenStream;
+use GuzzleHttp\TransferStats;
+use GuzzleHttp\Utils;
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Creates curl resources from a request
+ *
+ * @final
+ */
+class CurlFactory implements CurlFactoryInterface
+{
+ public const CURL_VERSION_STR = 'curl_version';
+
+ /**
+ * @deprecated
+ */
+ public const LOW_CURL_VERSION_NUMBER = '7.21.2';
+
+ /**
+ * @var resource[]|\CurlHandle[]
+ */
+ private $handles = [];
+
+ /**
+ * @var int Total number of idle handles to keep in cache
+ */
+ private $maxHandles;
+
+ /**
+ * @param int $maxHandles Maximum number of idle handles.
+ */
+ public function __construct(int $maxHandles)
+ {
+ $this->maxHandles = $maxHandles;
+ }
+
+ public function create(RequestInterface $request, array $options): EasyHandle
+ {
+ if (isset($options['curl']['body_as_string'])) {
+ $options['_body_as_string'] = $options['curl']['body_as_string'];
+ unset($options['curl']['body_as_string']);
+ }
+
+ $easy = new EasyHandle;
+ $easy->request = $request;
+ $easy->options = $options;
+ $conf = $this->getDefaultConf($easy);
+ $this->applyMethod($easy, $conf);
+ $this->applyHandlerOptions($easy, $conf);
+ $this->applyHeaders($easy, $conf);
+ unset($conf['_headers']);
+
+ // Add handler options from the request configuration options
+ if (isset($options['curl'])) {
+ $conf = \array_replace($conf, $options['curl']);
+ }
+
+ $conf[\CURLOPT_HEADERFUNCTION] = $this->createHeaderFn($easy);
+ $easy->handle = $this->handles ? \array_pop($this->handles) : \curl_init();
+ curl_setopt_array($easy->handle, $conf);
+
+ return $easy;
+ }
+
+ public function release(EasyHandle $easy): void
+ {
+ $resource = $easy->handle;
+ unset($easy->handle);
+
+ if (\count($this->handles) >= $this->maxHandles) {
+ \curl_close($resource);
+ } else {
+ // Remove all callback functions as they can hold onto references
+ // and are not cleaned up by curl_reset. Using curl_setopt_array
+ // does not work for some reason, so removing each one
+ // individually.
+ \curl_setopt($resource, \CURLOPT_HEADERFUNCTION, null);
+ \curl_setopt($resource, \CURLOPT_READFUNCTION, null);
+ \curl_setopt($resource, \CURLOPT_WRITEFUNCTION, null);
+ \curl_setopt($resource, \CURLOPT_PROGRESSFUNCTION, null);
+ \curl_reset($resource);
+ $this->handles[] = $resource;
+ }
+ }
+
+ /**
+ * Completes a cURL transaction, either returning a response promise or a
+ * rejected promise.
+ *
+ * @param callable(RequestInterface, array): PromiseInterface $handler
+ * @param CurlFactoryInterface $factory Dictates how the handle is released
+ */
+ public static function finish(callable $handler, EasyHandle $easy, CurlFactoryInterface $factory): PromiseInterface
+ {
+ if (isset($easy->options['on_stats'])) {
+ self::invokeStats($easy);
+ }
+
+ if (!$easy->response || $easy->errno) {
+ return self::finishError($handler, $easy, $factory);
+ }
+
+ // Return the response if it is present and there is no error.
+ $factory->release($easy);
+
+ // Rewind the body of the response if possible.
+ $body = $easy->response->getBody();
+ if ($body->isSeekable()) {
+ $body->rewind();
+ }
+
+ return new FulfilledPromise($easy->response);
+ }
+
+ private static function invokeStats(EasyHandle $easy): void
+ {
+ $curlStats = \curl_getinfo($easy->handle);
+ $curlStats['appconnect_time'] = \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME);
+ $stats = new TransferStats(
+ $easy->request,
+ $easy->response,
+ $curlStats['total_time'],
+ $easy->errno,
+ $curlStats
+ );
+ ($easy->options['on_stats'])($stats);
+ }
+
+ /**
+ * @param callable(RequestInterface, array): PromiseInterface $handler
+ */
+ private static function finishError(callable $handler, EasyHandle $easy, CurlFactoryInterface $factory): PromiseInterface
+ {
+ // Get error information and release the handle to the factory.
+ $ctx = [
+ 'errno' => $easy->errno,
+ 'error' => \curl_error($easy->handle),
+ 'appconnect_time' => \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME),
+ ] + \curl_getinfo($easy->handle);
+ $ctx[self::CURL_VERSION_STR] = \curl_version()['version'];
+ $factory->release($easy);
+
+ // Retry when nothing is present or when curl failed to rewind.
+ if (empty($easy->options['_err_message']) && (!$easy->errno || $easy->errno == 65)) {
+ return self::retryFailedRewind($handler, $easy, $ctx);
+ }
+
+ return self::createRejection($easy, $ctx);
+ }
+
+ private static function createRejection(EasyHandle $easy, array $ctx): PromiseInterface
+ {
+ static $connectionErrors = [
+ \CURLE_OPERATION_TIMEOUTED => true,
+ \CURLE_COULDNT_RESOLVE_HOST => true,
+ \CURLE_COULDNT_CONNECT => true,
+ \CURLE_SSL_CONNECT_ERROR => true,
+ \CURLE_GOT_NOTHING => true,
+ ];
+
+ if ($easy->createResponseException) {
+ return P\Create::rejectionFor(
+ new RequestException(
+ 'An error was encountered while creating the response',
+ $easy->request,
+ $easy->response,
+ $easy->createResponseException,
+ $ctx
+ )
+ );
+ }
+
+ // If an exception was encountered during the onHeaders event, then
+ // return a rejected promise that wraps that exception.
+ if ($easy->onHeadersException) {
+ return P\Create::rejectionFor(
+ new RequestException(
+ 'An error was encountered during the on_headers event',
+ $easy->request,
+ $easy->response,
+ $easy->onHeadersException,
+ $ctx
+ )
+ );
+ }
+
+ $message = \sprintf(
+ 'cURL error %s: %s (%s)',
+ $ctx['errno'],
+ $ctx['error'],
+ 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html'
+ );
+ $uriString = (string) $easy->request->getUri();
+ if ($uriString !== '' && false === \strpos($ctx['error'], $uriString)) {
+ $message .= \sprintf(' for %s', $uriString);
+ }
+
+ // Create a connection exception if it was a specific error code.
+ $error = isset($connectionErrors[$easy->errno])
+ ? new ConnectException($message, $easy->request, null, $ctx)
+ : new RequestException($message, $easy->request, $easy->response, null, $ctx);
+
+ return P\Create::rejectionFor($error);
+ }
+
+ /**
+ * @return array<int|string, mixed>
+ */
+ private function getDefaultConf(EasyHandle $easy): array
+ {
+ $conf = [
+ '_headers' => $easy->request->getHeaders(),
+ \CURLOPT_CUSTOMREQUEST => $easy->request->getMethod(),
+ \CURLOPT_URL => (string) $easy->request->getUri()->withFragment(''),
+ \CURLOPT_RETURNTRANSFER => false,
+ \CURLOPT_HEADER => false,
+ \CURLOPT_CONNECTTIMEOUT => 150,
+ ];
+
+ if (\defined('CURLOPT_PROTOCOLS')) {
+ $conf[\CURLOPT_PROTOCOLS] = \CURLPROTO_HTTP | \CURLPROTO_HTTPS;
+ }
+
+ $version = $easy->request->getProtocolVersion();
+ if ($version == 1.1) {
+ $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_1;
+ } elseif ($version == 2.0) {
+ $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_2_0;
+ } else {
+ $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_0;
+ }
+
+ return $conf;
+ }
+
+ private function applyMethod(EasyHandle $easy, array &$conf): void
+ {
+ $body = $easy->request->getBody();
+ $size = $body->getSize();
+
+ if ($size === null || $size > 0) {
+ $this->applyBody($easy->request, $easy->options, $conf);
+ return;
+ }
+
+ $method = $easy->request->getMethod();
+ if ($method === 'PUT' || $method === 'POST') {
+ // See https://tools.ietf.org/html/rfc7230#section-3.3.2
+ if (!$easy->request->hasHeader('Content-Length')) {
+ $conf[\CURLOPT_HTTPHEADER][] = 'Content-Length: 0';
+ }
+ } elseif ($method === 'HEAD') {
+ $conf[\CURLOPT_NOBODY] = true;
+ unset(
+ $conf[\CURLOPT_WRITEFUNCTION],
+ $conf[\CURLOPT_READFUNCTION],
+ $conf[\CURLOPT_FILE],
+ $conf[\CURLOPT_INFILE]
+ );
+ }
+ }
+
+ private function applyBody(RequestInterface $request, array $options, array &$conf): void
+ {
+ $size = $request->hasHeader('Content-Length')
+ ? (int) $request->getHeaderLine('Content-Length')
+ : null;
+
+ // Send the body as a string if the size is less than 1MB OR if the
+ // [curl][body_as_string] request value is set.
+ if (($size !== null && $size < 1000000) || !empty($options['_body_as_string'])) {
+ $conf[\CURLOPT_POSTFIELDS] = (string) $request->getBody();
+ // Don't duplicate the Content-Length header
+ $this->removeHeader('Content-Length', $conf);
+ $this->removeHeader('Transfer-Encoding', $conf);
+ } else {
+ $conf[\CURLOPT_UPLOAD] = true;
+ if ($size !== null) {
+ $conf[\CURLOPT_INFILESIZE] = $size;
+ $this->removeHeader('Content-Length', $conf);
+ }
+ $body = $request->getBody();
+ if ($body->isSeekable()) {
+ $body->rewind();
+ }
+ $conf[\CURLOPT_READFUNCTION] = static function ($ch, $fd, $length) use ($body) {
+ return $body->read($length);
+ };
+ }
+
+ // If the Expect header is not present, prevent curl from adding it
+ if (!$request->hasHeader('Expect')) {
+ $conf[\CURLOPT_HTTPHEADER][] = 'Expect:';
+ }
+
+ // cURL sometimes adds a content-type by default. Prevent this.
+ if (!$request->hasHeader('Content-Type')) {
+ $conf[\CURLOPT_HTTPHEADER][] = 'Content-Type:';
+ }
+ }
+
+ private function applyHeaders(EasyHandle $easy, array &$conf): void
+ {
+ foreach ($conf['_headers'] as $name => $values) {
+ foreach ($values as $value) {
+ $value = (string) $value;
+ if ($value === '') {
+ // cURL requires a special format for empty headers.
+ // See https://github.com/guzzle/guzzle/issues/1882 for more details.
+ $conf[\CURLOPT_HTTPHEADER][] = "$name;";
+ } else {
+ $conf[\CURLOPT_HTTPHEADER][] = "$name: $value";
+ }
+ }
+ }
+
+ // Remove the Accept header if one was not set
+ if (!$easy->request->hasHeader('Accept')) {
+ $conf[\CURLOPT_HTTPHEADER][] = 'Accept:';
+ }
+ }
+
+ /**
+ * Remove a header from the options array.
+ *
+ * @param string $name Case-insensitive header to remove
+ * @param array $options Array of options to modify
+ */
+ private function removeHeader(string $name, array &$options): void
+ {
+ foreach (\array_keys($options['_headers']) as $key) {
+ if (!\strcasecmp($key, $name)) {
+ unset($options['_headers'][$key]);
+ return;
+ }
+ }
+ }
+
+ private function applyHandlerOptions(EasyHandle $easy, array &$conf): void
+ {
+ $options = $easy->options;
+ if (isset($options['verify'])) {
+ if ($options['verify'] === false) {
+ unset($conf[\CURLOPT_CAINFO]);
+ $conf[\CURLOPT_SSL_VERIFYHOST] = 0;
+ $conf[\CURLOPT_SSL_VERIFYPEER] = false;
+ } else {
+ $conf[\CURLOPT_SSL_VERIFYHOST] = 2;
+ $conf[\CURLOPT_SSL_VERIFYPEER] = true;
+ if (\is_string($options['verify'])) {
+ // Throw an error if the file/folder/link path is not valid or doesn't exist.
+ if (!\file_exists($options['verify'])) {
+ throw new \InvalidArgumentException("SSL CA bundle not found: {$options['verify']}");
+ }
+ // If it's a directory or a link to a directory use CURLOPT_CAPATH.
+ // If not, it's probably a file, or a link to a file, so use CURLOPT_CAINFO.
+ if (
+ \is_dir($options['verify']) ||
+ (
+ \is_link($options['verify']) === true &&
+ ($verifyLink = \readlink($options['verify'])) !== false &&
+ \is_dir($verifyLink)
+ )
+ ) {
+ $conf[\CURLOPT_CAPATH] = $options['verify'];
+ } else {
+ $conf[\CURLOPT_CAINFO] = $options['verify'];
+ }
+ }
+ }
+ }
+
+ if (!isset($options['curl'][\CURLOPT_ENCODING]) && !empty($options['decode_content'])) {
+ $accept = $easy->request->getHeaderLine('Accept-Encoding');
+ if ($accept) {
+ $conf[\CURLOPT_ENCODING] = $accept;
+ } else {
+ // The empty string enables all available decoders and implicitly
+ // sets a matching 'Accept-Encoding' header.
+ $conf[\CURLOPT_ENCODING] = '';
+ // But as the user did not specify any acceptable encodings we need
+ // to overwrite this implicit header with an empty one.
+ $conf[\CURLOPT_HTTPHEADER][] = 'Accept-Encoding:';
+ }
+ }
+
+ if (!isset($options['sink'])) {
+ // Use a default temp stream if no sink was set.
+ $options['sink'] = \GuzzleHttp\Psr7\Utils::tryFopen('php://temp', 'w+');
+ }
+ $sink = $options['sink'];
+ if (!\is_string($sink)) {
+ $sink = \GuzzleHttp\Psr7\Utils::streamFor($sink);
+ } elseif (!\is_dir(\dirname($sink))) {
+ // Ensure that the directory exists before failing in curl.
+ throw new \RuntimeException(\sprintf('Directory %s does not exist for sink value of %s', \dirname($sink), $sink));
+ } else {
+ $sink = new LazyOpenStream($sink, 'w+');
+ }
+ $easy->sink = $sink;
+ $conf[\CURLOPT_WRITEFUNCTION] = static function ($ch, $write) use ($sink): int {
+ return $sink->write($write);
+ };
+
+ $timeoutRequiresNoSignal = false;
+ if (isset($options['timeout'])) {
+ $timeoutRequiresNoSignal |= $options['timeout'] < 1;
+ $conf[\CURLOPT_TIMEOUT_MS] = $options['timeout'] * 1000;
+ }
+
+ // CURL default value is CURL_IPRESOLVE_WHATEVER
+ if (isset($options['force_ip_resolve'])) {
+ if ('v4' === $options['force_ip_resolve']) {
+ $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V4;
+ } elseif ('v6' === $options['force_ip_resolve']) {
+ $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V6;
+ }
+ }
+
+ if (isset($options['connect_timeout'])) {
+ $timeoutRequiresNoSignal |= $options['connect_timeout'] < 1;
+ $conf[\CURLOPT_CONNECTTIMEOUT_MS] = $options['connect_timeout'] * 1000;
+ }
+
+ if ($timeoutRequiresNoSignal && \strtoupper(\substr(\PHP_OS, 0, 3)) !== 'WIN') {
+ $conf[\CURLOPT_NOSIGNAL] = true;
+ }
+
+ if (isset($options['proxy'])) {
+ if (!\is_array($options['proxy'])) {
+ $conf[\CURLOPT_PROXY] = $options['proxy'];
+ } else {
+ $scheme = $easy->request->getUri()->getScheme();
+ if (isset($options['proxy'][$scheme])) {
+ $host = $easy->request->getUri()->getHost();
+ if (!isset($options['proxy']['no']) || !Utils::isHostInNoProxy($host, $options['proxy']['no'])) {
+ $conf[\CURLOPT_PROXY] = $options['proxy'][$scheme];
+ }
+ }
+ }
+ }
+
+ if (isset($options['cert'])) {
+ $cert = $options['cert'];
+ if (\is_array($cert)) {
+ $conf[\CURLOPT_SSLCERTPASSWD] = $cert[1];
+ $cert = $cert[0];
+ }
+ if (!\file_exists($cert)) {
+ throw new \InvalidArgumentException("SSL certificate not found: {$cert}");
+ }
+ # OpenSSL (versions 0.9.3 and later) also support "P12" for PKCS#12-encoded files.
+ # see https://curl.se/libcurl/c/CURLOPT_SSLCERTTYPE.html
+ $ext = pathinfo($cert, \PATHINFO_EXTENSION);
+ if (preg_match('#^(der|p12)$#i', $ext)) {
+ $conf[\CURLOPT_SSLCERTTYPE] = strtoupper($ext);
+ }
+ $conf[\CURLOPT_SSLCERT] = $cert;
+ }
+
+ if (isset($options['ssl_key'])) {
+ if (\is_array($options['ssl_key'])) {
+ if (\count($options['ssl_key']) === 2) {
+ [$sslKey, $conf[\CURLOPT_SSLKEYPASSWD]] = $options['ssl_key'];
+ } else {
+ [$sslKey] = $options['ssl_key'];
+ }
+ }
+
+ $sslKey = $sslKey ?? $options['ssl_key'];
+
+ if (!\file_exists($sslKey)) {
+ throw new \InvalidArgumentException("SSL private key not found: {$sslKey}");
+ }
+ $conf[\CURLOPT_SSLKEY] = $sslKey;
+ }
+
+ if (isset($options['progress'])) {
+ $progress = $options['progress'];
+ if (!\is_callable($progress)) {
+ throw new \InvalidArgumentException('progress client option must be callable');
+ }
+ $conf[\CURLOPT_NOPROGRESS] = false;
+ $conf[\CURLOPT_PROGRESSFUNCTION] = static function ($resource, int $downloadSize, int $downloaded, int $uploadSize, int $uploaded) use ($progress) {
+ $progress($downloadSize, $downloaded, $uploadSize, $uploaded);
+ };
+ }
+
+ if (!empty($options['debug'])) {
+ $conf[\CURLOPT_STDERR] = Utils::debugResource($options['debug']);
+ $conf[\CURLOPT_VERBOSE] = true;
+ }
+ }
+
+ /**
+ * This function ensures that a response was set on a transaction. If one
+ * was not set, then the request is retried if possible. This error
+ * typically means you are sending a payload, curl encountered a
+ * "Connection died, retrying a fresh connect" error, tried to rewind the
+ * stream, and then encountered a "necessary data rewind wasn't possible"
+ * error, causing the request to be sent through curl_multi_info_read()
+ * without an error status.
+ *
+ * @param callable(RequestInterface, array): PromiseInterface $handler
+ */
+ private static function retryFailedRewind(callable $handler, EasyHandle $easy, array $ctx): PromiseInterface
+ {
+ try {
+ // Only rewind if the body has been read from.
+ $body = $easy->request->getBody();
+ if ($body->tell() > 0) {
+ $body->rewind();
+ }
+ } catch (\RuntimeException $e) {
+ $ctx['error'] = 'The connection unexpectedly failed without '
+ . 'providing an error. The request would have been retried, '
+ . 'but attempting to rewind the request body failed. '
+ . 'Exception: ' . $e;
+ return self::createRejection($easy, $ctx);
+ }
+
+ // Retry no more than 3 times before giving up.
+ if (!isset($easy->options['_curl_retries'])) {
+ $easy->options['_curl_retries'] = 1;
+ } elseif ($easy->options['_curl_retries'] == 2) {
+ $ctx['error'] = 'The cURL request was retried 3 times '
+ . 'and did not succeed. The most likely reason for the failure '
+ . 'is that cURL was unable to rewind the body of the request '
+ . 'and subsequent retries resulted in the same error. Turn on '
+ . 'the debug option to see what went wrong. See '
+ . 'https://bugs.php.net/bug.php?id=47204 for more information.';
+ return self::createRejection($easy, $ctx);
+ } else {
+ $easy->options['_curl_retries']++;
+ }
+
+ return $handler($easy->request, $easy->options);
+ }
+
+ private function createHeaderFn(EasyHandle $easy): callable
+ {
+ if (isset($easy->options['on_headers'])) {
+ $onHeaders = $easy->options['on_headers'];
+
+ if (!\is_callable($onHeaders)) {
+ throw new \InvalidArgumentException('on_headers must be callable');
+ }
+ } else {
+ $onHeaders = null;
+ }
+
+ return static function ($ch, $h) use (
+ $onHeaders,
+ $easy,
+ &$startingResponse
+ ) {
+ $value = \trim($h);
+ if ($value === '') {
+ $startingResponse = true;
+ try {
+ $easy->createResponse();
+ } catch (\Exception $e) {
+ $easy->createResponseException = $e;
+ return -1;
+ }
+ if ($onHeaders !== null) {
+ try {
+ $onHeaders($easy->response);
+ } catch (\Exception $e) {
+ // Associate the exception with the handle and trigger
+ // a curl header write error by returning 0.
+ $easy->onHeadersException = $e;
+ return -1;
+ }
+ }
+ } elseif ($startingResponse) {
+ $startingResponse = false;
+ $easy->headers = [$value];
+ } else {
+ $easy->headers[] = $value;
+ }
+ return \strlen($h);
+ };
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php
new file mode 100644
index 0000000..fe57ed5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php
@@ -0,0 +1,25 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use Psr\Http\Message\RequestInterface;
+
+interface CurlFactoryInterface
+{
+ /**
+ * Creates a cURL handle resource.
+ *
+ * @param RequestInterface $request Request
+ * @param array $options Transfer options
+ *
+ * @throws \RuntimeException when an option cannot be applied
+ */
+ public function create(RequestInterface $request, array $options): EasyHandle;
+
+ /**
+ * Release an easy handle, allowing it to be reused or closed.
+ *
+ * This function must call unset on the easy handle's "handle" property.
+ */
+ public function release(EasyHandle $easy): void;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php
new file mode 100644
index 0000000..9ad10a9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php
@@ -0,0 +1,49 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * HTTP handler that uses cURL easy handles as a transport layer.
+ *
+ * When using the CurlHandler, custom curl options can be specified as an
+ * associative array of curl option constants mapping to values in the
+ * **curl** key of the "client" key of the request.
+ *
+ * @final
+ */
+class CurlHandler
+{
+ /**
+ * @var CurlFactoryInterface
+ */
+ private $factory;
+
+ /**
+ * Accepts an associative array of options:
+ *
+ * - handle_factory: Optional curl factory used to create cURL handles.
+ *
+ * @param array{handle_factory?: ?CurlFactoryInterface} $options Array of options to use with the handler
+ */
+ public function __construct(array $options = [])
+ {
+ $this->factory = $options['handle_factory']
+ ?? new CurlFactory(3);
+ }
+
+ public function __invoke(RequestInterface $request, array $options): PromiseInterface
+ {
+ if (isset($options['delay'])) {
+ \usleep($options['delay'] * 1000);
+ }
+
+ $easy = $this->factory->create($request, $options);
+ \curl_exec($easy->handle);
+ $easy->errno = \curl_errno($easy->handle);
+
+ return CurlFactory::finish($this, $easy, $this->factory);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php
new file mode 100644
index 0000000..4356d02
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php
@@ -0,0 +1,262 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\Promise;
+use GuzzleHttp\Promise\PromiseInterface;
+use GuzzleHttp\Utils;
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Returns an asynchronous response using curl_multi_* functions.
+ *
+ * When using the CurlMultiHandler, custom curl options can be specified as an
+ * associative array of curl option constants mapping to values in the
+ * **curl** key of the provided request options.
+ *
+ * @property resource|\CurlMultiHandle $_mh Internal use only. Lazy loaded multi-handle.
+ *
+ * @final
+ */
+#[\AllowDynamicProperties]
+class CurlMultiHandler
+{
+ /**
+ * @var CurlFactoryInterface
+ */
+ private $factory;
+
+ /**
+ * @var int
+ */
+ private $selectTimeout;
+
+ /**
+ * @var int Will be higher than 0 when `curl_multi_exec` is still running.
+ */
+ private $active = 0;
+
+ /**
+ * @var array Request entry handles, indexed by handle id in `addRequest`.
+ *
+ * @see CurlMultiHandler::addRequest
+ */
+ private $handles = [];
+
+ /**
+ * @var array<int, float> An array of delay times, indexed by handle id in `addRequest`.
+ *
+ * @see CurlMultiHandler::addRequest
+ */
+ private $delays = [];
+
+ /**
+ * @var array<mixed> An associative array of CURLMOPT_* options and corresponding values for curl_multi_setopt()
+ */
+ private $options = [];
+
+ /**
+ * This handler accepts the following options:
+ *
+ * - handle_factory: An optional factory used to create curl handles
+ * - select_timeout: Optional timeout (in seconds) to block before timing
+ * out while selecting curl handles. Defaults to 1 second.
+ * - options: An associative array of CURLMOPT_* options and
+ * corresponding values for curl_multi_setopt()
+ */
+ public function __construct(array $options = [])
+ {
+ $this->factory = $options['handle_factory'] ?? new CurlFactory(50);
+
+ if (isset($options['select_timeout'])) {
+ $this->selectTimeout = $options['select_timeout'];
+ } elseif ($selectTimeout = Utils::getenv('GUZZLE_CURL_SELECT_TIMEOUT')) {
+ @trigger_error('Since guzzlehttp/guzzle 7.2.0: Using environment variable GUZZLE_CURL_SELECT_TIMEOUT is deprecated. Use option "select_timeout" instead.', \E_USER_DEPRECATED);
+ $this->selectTimeout = (int) $selectTimeout;
+ } else {
+ $this->selectTimeout = 1;
+ }
+
+ $this->options = $options['options'] ?? [];
+ }
+
+ /**
+ * @param string $name
+ *
+ * @return resource|\CurlMultiHandle
+ *
+ * @throws \BadMethodCallException when another field as `_mh` will be gotten
+ * @throws \RuntimeException when curl can not initialize a multi handle
+ */
+ public function __get($name)
+ {
+ if ($name !== '_mh') {
+ throw new \BadMethodCallException("Can not get other property as '_mh'.");
+ }
+
+ $multiHandle = \curl_multi_init();
+
+ if (false === $multiHandle) {
+ throw new \RuntimeException('Can not initialize curl multi handle.');
+ }
+
+ $this->_mh = $multiHandle;
+
+ foreach ($this->options as $option => $value) {
+ // A warning is raised in case of a wrong option.
+ curl_multi_setopt($this->_mh, $option, $value);
+ }
+
+ return $this->_mh;
+ }
+
+ public function __destruct()
+ {
+ if (isset($this->_mh)) {
+ \curl_multi_close($this->_mh);
+ unset($this->_mh);
+ }
+ }
+
+ public function __invoke(RequestInterface $request, array $options): PromiseInterface
+ {
+ $easy = $this->factory->create($request, $options);
+ $id = (int) $easy->handle;
+
+ $promise = new Promise(
+ [$this, 'execute'],
+ function () use ($id) {
+ return $this->cancel($id);
+ }
+ );
+
+ $this->addRequest(['easy' => $easy, 'deferred' => $promise]);
+
+ return $promise;
+ }
+
+ /**
+ * Ticks the curl event loop.
+ */
+ public function tick(): void
+ {
+ // Add any delayed handles if needed.
+ if ($this->delays) {
+ $currentTime = Utils::currentTime();
+ foreach ($this->delays as $id => $delay) {
+ if ($currentTime >= $delay) {
+ unset($this->delays[$id]);
+ \curl_multi_add_handle(
+ $this->_mh,
+ $this->handles[$id]['easy']->handle
+ );
+ }
+ }
+ }
+
+ // Step through the task queue which may add additional requests.
+ P\Utils::queue()->run();
+
+ if ($this->active && \curl_multi_select($this->_mh, $this->selectTimeout) === -1) {
+ // Perform a usleep if a select returns -1.
+ // See: https://bugs.php.net/bug.php?id=61141
+ \usleep(250);
+ }
+
+ while (\curl_multi_exec($this->_mh, $this->active) === \CURLM_CALL_MULTI_PERFORM);
+
+ $this->processMessages();
+ }
+
+ /**
+ * Runs until all outstanding connections have completed.
+ */
+ public function execute(): void
+ {
+ $queue = P\Utils::queue();
+
+ while ($this->handles || !$queue->isEmpty()) {
+ // If there are no transfers, then sleep for the next delay
+ if (!$this->active && $this->delays) {
+ \usleep($this->timeToNext());
+ }
+ $this->tick();
+ }
+ }
+
+ private function addRequest(array $entry): void
+ {
+ $easy = $entry['easy'];
+ $id = (int) $easy->handle;
+ $this->handles[$id] = $entry;
+ if (empty($easy->options['delay'])) {
+ \curl_multi_add_handle($this->_mh, $easy->handle);
+ } else {
+ $this->delays[$id] = Utils::currentTime() + ($easy->options['delay'] / 1000);
+ }
+ }
+
+ /**
+ * Cancels a handle from sending and removes references to it.
+ *
+ * @param int $id Handle ID to cancel and remove.
+ *
+ * @return bool True on success, false on failure.
+ */
+ private function cancel($id): bool
+ {
+ if (!is_int($id)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing an integer to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ // Cannot cancel if it has been processed.
+ if (!isset($this->handles[$id])) {
+ return false;
+ }
+
+ $handle = $this->handles[$id]['easy']->handle;
+ unset($this->delays[$id], $this->handles[$id]);
+ \curl_multi_remove_handle($this->_mh, $handle);
+ \curl_close($handle);
+
+ return true;
+ }
+
+ private function processMessages(): void
+ {
+ while ($done = \curl_multi_info_read($this->_mh)) {
+ if ($done['msg'] !== \CURLMSG_DONE) {
+ // if it's not done, then it would be premature to remove the handle. ref https://github.com/guzzle/guzzle/pull/2892#issuecomment-945150216
+ continue;
+ }
+ $id = (int) $done['handle'];
+ \curl_multi_remove_handle($this->_mh, $done['handle']);
+
+ if (!isset($this->handles[$id])) {
+ // Probably was cancelled.
+ continue;
+ }
+
+ $entry = $this->handles[$id];
+ unset($this->handles[$id], $this->delays[$id]);
+ $entry['easy']->errno = $done['result'];
+ $entry['deferred']->resolve(
+ CurlFactory::finish($this, $entry['easy'], $this->factory)
+ );
+ }
+ }
+
+ private function timeToNext(): int
+ {
+ $currentTime = Utils::currentTime();
+ $nextTime = \PHP_INT_MAX;
+ foreach ($this->delays as $time) {
+ if ($time < $nextTime) {
+ $nextTime = $time;
+ }
+ }
+
+ return ((int) \max(0, $nextTime - $currentTime)) * 1000000;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php
new file mode 100644
index 0000000..224344d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php
@@ -0,0 +1,112 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Psr7\Response;
+use GuzzleHttp\Utils;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Represents a cURL easy handle and the data it populates.
+ *
+ * @internal
+ */
+final class EasyHandle
+{
+ /**
+ * @var resource|\CurlHandle cURL resource
+ */
+ public $handle;
+
+ /**
+ * @var StreamInterface Where data is being written
+ */
+ public $sink;
+
+ /**
+ * @var array Received HTTP headers so far
+ */
+ public $headers = [];
+
+ /**
+ * @var ResponseInterface|null Received response (if any)
+ */
+ public $response;
+
+ /**
+ * @var RequestInterface Request being sent
+ */
+ public $request;
+
+ /**
+ * @var array Request options
+ */
+ public $options = [];
+
+ /**
+ * @var int cURL error number (if any)
+ */
+ public $errno = 0;
+
+ /**
+ * @var \Throwable|null Exception during on_headers (if any)
+ */
+ public $onHeadersException;
+
+ /**
+ * @var \Exception|null Exception during createResponse (if any)
+ */
+ public $createResponseException;
+
+ /**
+ * Attach a response to the easy handle based on the received headers.
+ *
+ * @throws \RuntimeException if no headers have been received or the first
+ * header line is invalid.
+ */
+ public function createResponse(): void
+ {
+ [$ver, $status, $reason, $headers] = HeaderProcessor::parseHeaders($this->headers);
+
+ $normalizedKeys = Utils::normalizeHeaderKeys($headers);
+
+ if (!empty($this->options['decode_content']) && isset($normalizedKeys['content-encoding'])) {
+ $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']];
+ unset($headers[$normalizedKeys['content-encoding']]);
+ if (isset($normalizedKeys['content-length'])) {
+ $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']];
+
+ $bodyLength = (int) $this->sink->getSize();
+ if ($bodyLength) {
+ $headers[$normalizedKeys['content-length']] = $bodyLength;
+ } else {
+ unset($headers[$normalizedKeys['content-length']]);
+ }
+ }
+ }
+
+ // Attach a response to the easy handle with the parsed headers.
+ $this->response = new Response(
+ $status,
+ $headers,
+ $this->sink,
+ $ver,
+ $reason
+ );
+ }
+
+ /**
+ * @param string $name
+ *
+ * @return void
+ *
+ * @throws \BadMethodCallException
+ */
+ public function __get($name)
+ {
+ $msg = $name === 'handle' ? 'The EasyHandle has been released' : 'Invalid property: ' . $name;
+ throw new \BadMethodCallException($msg);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php
new file mode 100644
index 0000000..a098884
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/HeaderProcessor.php
@@ -0,0 +1,42 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Utils;
+
+/**
+ * @internal
+ */
+final class HeaderProcessor
+{
+ /**
+ * Returns the HTTP version, status code, reason phrase, and headers.
+ *
+ * @param string[] $headers
+ *
+ * @throws \RuntimeException
+ *
+ * @return array{0:string, 1:int, 2:?string, 3:array}
+ */
+ public static function parseHeaders(array $headers): array
+ {
+ if ($headers === []) {
+ throw new \RuntimeException('Expected a non-empty array of header data');
+ }
+
+ $parts = \explode(' ', \array_shift($headers), 3);
+ $version = \explode('/', $parts[0])[1] ?? null;
+
+ if ($version === null) {
+ throw new \RuntimeException('HTTP version missing from header data');
+ }
+
+ $status = $parts[1] ?? null;
+
+ if ($status === null) {
+ throw new \RuntimeException('HTTP status code missing from header data');
+ }
+
+ return [$version, (int) $status, $parts[2] ?? null, Utils::headersFromLines($headers)];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/MockHandler.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/MockHandler.php
new file mode 100644
index 0000000..79664e2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/MockHandler.php
@@ -0,0 +1,211 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Exception\RequestException;
+use GuzzleHttp\HandlerStack;
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\PromiseInterface;
+use GuzzleHttp\TransferStats;
+use GuzzleHttp\Utils;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Handler that returns responses or throw exceptions from a queue.
+ *
+ * @final
+ */
+class MockHandler implements \Countable
+{
+ /**
+ * @var array
+ */
+ private $queue = [];
+
+ /**
+ * @var RequestInterface|null
+ */
+ private $lastRequest;
+
+ /**
+ * @var array
+ */
+ private $lastOptions = [];
+
+ /**
+ * @var callable|null
+ */
+ private $onFulfilled;
+
+ /**
+ * @var callable|null
+ */
+ private $onRejected;
+
+ /**
+ * Creates a new MockHandler that uses the default handler stack list of
+ * middlewares.
+ *
+ * @param array|null $queue Array of responses, callables, or exceptions.
+ * @param callable|null $onFulfilled Callback to invoke when the return value is fulfilled.
+ * @param callable|null $onRejected Callback to invoke when the return value is rejected.
+ */
+ public static function createWithMiddleware(array $queue = null, callable $onFulfilled = null, callable $onRejected = null): HandlerStack
+ {
+ return HandlerStack::create(new self($queue, $onFulfilled, $onRejected));
+ }
+
+ /**
+ * The passed in value must be an array of
+ * {@see \Psr\Http\Message\ResponseInterface} objects, Exceptions,
+ * callables, or Promises.
+ *
+ * @param array<int, mixed>|null $queue The parameters to be passed to the append function, as an indexed array.
+ * @param callable|null $onFulfilled Callback to invoke when the return value is fulfilled.
+ * @param callable|null $onRejected Callback to invoke when the return value is rejected.
+ */
+ public function __construct(array $queue = null, callable $onFulfilled = null, callable $onRejected = null)
+ {
+ $this->onFulfilled = $onFulfilled;
+ $this->onRejected = $onRejected;
+
+ if ($queue) {
+ // array_values included for BC
+ $this->append(...array_values($queue));
+ }
+ }
+
+ public function __invoke(RequestInterface $request, array $options): PromiseInterface
+ {
+ if (!$this->queue) {
+ throw new \OutOfBoundsException('Mock queue is empty');
+ }
+
+ if (isset($options['delay']) && \is_numeric($options['delay'])) {
+ \usleep((int) $options['delay'] * 1000);
+ }
+
+ $this->lastRequest = $request;
+ $this->lastOptions = $options;
+ $response = \array_shift($this->queue);
+
+ if (isset($options['on_headers'])) {
+ if (!\is_callable($options['on_headers'])) {
+ throw new \InvalidArgumentException('on_headers must be callable');
+ }
+ try {
+ $options['on_headers']($response);
+ } catch (\Exception $e) {
+ $msg = 'An error was encountered during the on_headers event';
+ $response = new RequestException($msg, $request, $response, $e);
+ }
+ }
+
+ if (\is_callable($response)) {
+ $response = $response($request, $options);
+ }
+
+ $response = $response instanceof \Throwable
+ ? P\Create::rejectionFor($response)
+ : P\Create::promiseFor($response);
+
+ return $response->then(
+ function (?ResponseInterface $value) use ($request, $options) {
+ $this->invokeStats($request, $options, $value);
+ if ($this->onFulfilled) {
+ ($this->onFulfilled)($value);
+ }
+
+ if ($value !== null && isset($options['sink'])) {
+ $contents = (string) $value->getBody();
+ $sink = $options['sink'];
+
+ if (\is_resource($sink)) {
+ \fwrite($sink, $contents);
+ } elseif (\is_string($sink)) {
+ \file_put_contents($sink, $contents);
+ } elseif ($sink instanceof StreamInterface) {
+ $sink->write($contents);
+ }
+ }
+
+ return $value;
+ },
+ function ($reason) use ($request, $options) {
+ $this->invokeStats($request, $options, null, $reason);
+ if ($this->onRejected) {
+ ($this->onRejected)($reason);
+ }
+ return P\Create::rejectionFor($reason);
+ }
+ );
+ }
+
+ /**
+ * Adds one or more variadic requests, exceptions, callables, or promises
+ * to the queue.
+ *
+ * @param mixed ...$values
+ */
+ public function append(...$values): void
+ {
+ foreach ($values as $value) {
+ if ($value instanceof ResponseInterface
+ || $value instanceof \Throwable
+ || $value instanceof PromiseInterface
+ || \is_callable($value)
+ ) {
+ $this->queue[] = $value;
+ } else {
+ throw new \TypeError('Expected a Response, Promise, Throwable or callable. Found ' . Utils::describeType($value));
+ }
+ }
+ }
+
+ /**
+ * Get the last received request.
+ */
+ public function getLastRequest(): ?RequestInterface
+ {
+ return $this->lastRequest;
+ }
+
+ /**
+ * Get the last received request options.
+ */
+ public function getLastOptions(): array
+ {
+ return $this->lastOptions;
+ }
+
+ /**
+ * Returns the number of remaining items in the queue.
+ */
+ public function count(): int
+ {
+ return \count($this->queue);
+ }
+
+ public function reset(): void
+ {
+ $this->queue = [];
+ }
+
+ /**
+ * @param mixed $reason Promise or reason.
+ */
+ private function invokeStats(
+ RequestInterface $request,
+ array $options,
+ ResponseInterface $response = null,
+ $reason = null
+ ): void {
+ if (isset($options['on_stats'])) {
+ $transferTime = $options['transfer_time'] ?? 0;
+ $stats = new TransferStats($request, $response, $transferTime, $reason);
+ ($options['on_stats'])($stats);
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php
new file mode 100644
index 0000000..f045b52
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php
@@ -0,0 +1,51 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Promise\PromiseInterface;
+use GuzzleHttp\RequestOptions;
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Provides basic proxies for handlers.
+ *
+ * @final
+ */
+class Proxy
+{
+ /**
+ * Sends synchronous requests to a specific handler while sending all other
+ * requests to another handler.
+ *
+ * @param callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $default Handler used for normal responses
+ * @param callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $sync Handler used for synchronous responses.
+ *
+ * @return callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the composed handler.
+ */
+ public static function wrapSync(callable $default, callable $sync): callable
+ {
+ return static function (RequestInterface $request, array $options) use ($default, $sync): PromiseInterface {
+ return empty($options[RequestOptions::SYNCHRONOUS]) ? $default($request, $options) : $sync($request, $options);
+ };
+ }
+
+ /**
+ * Sends streaming requests to a streaming compatible handler while sending
+ * all other requests to a default handler.
+ *
+ * This, for example, could be useful for taking advantage of the
+ * performance benefits of curl while still supporting true streaming
+ * through the StreamHandler.
+ *
+ * @param callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $default Handler used for non-streaming responses
+ * @param callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface $streaming Handler used for streaming responses
+ *
+ * @return callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the composed handler.
+ */
+ public static function wrapStreaming(callable $default, callable $streaming): callable
+ {
+ return static function (RequestInterface $request, array $options) use ($default, $streaming): PromiseInterface {
+ return empty($options['stream']) ? $default($request, $options) : $streaming($request, $options);
+ };
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/StreamHandler.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/StreamHandler.php
new file mode 100644
index 0000000..543f825
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Handler/StreamHandler.php
@@ -0,0 +1,593 @@
+<?php
+
+namespace GuzzleHttp\Handler;
+
+use GuzzleHttp\Exception\ConnectException;
+use GuzzleHttp\Exception\RequestException;
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\FulfilledPromise;
+use GuzzleHttp\Promise\PromiseInterface;
+use GuzzleHttp\Psr7;
+use GuzzleHttp\TransferStats;
+use GuzzleHttp\Utils;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\StreamInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * HTTP handler that uses PHP's HTTP stream wrapper.
+ *
+ * @final
+ */
+class StreamHandler
+{
+ /**
+ * @var array
+ */
+ private $lastHeaders = [];
+
+ /**
+ * Sends an HTTP request.
+ *
+ * @param RequestInterface $request Request to send.
+ * @param array $options Request transfer options.
+ */
+ public function __invoke(RequestInterface $request, array $options): PromiseInterface
+ {
+ // Sleep if there is a delay specified.
+ if (isset($options['delay'])) {
+ \usleep($options['delay'] * 1000);
+ }
+
+ $startTime = isset($options['on_stats']) ? Utils::currentTime() : null;
+
+ try {
+ // Does not support the expect header.
+ $request = $request->withoutHeader('Expect');
+
+ // Append a content-length header if body size is zero to match
+ // cURL's behavior.
+ if (0 === $request->getBody()->getSize()) {
+ $request = $request->withHeader('Content-Length', '0');
+ }
+
+ return $this->createResponse(
+ $request,
+ $options,
+ $this->createStream($request, $options),
+ $startTime
+ );
+ } catch (\InvalidArgumentException $e) {
+ throw $e;
+ } catch (\Exception $e) {
+ // Determine if the error was a networking error.
+ $message = $e->getMessage();
+ // This list can probably get more comprehensive.
+ if (false !== \strpos($message, 'getaddrinfo') // DNS lookup failed
+ || false !== \strpos($message, 'Connection refused')
+ || false !== \strpos($message, "couldn't connect to host") // error on HHVM
+ || false !== \strpos($message, "connection attempt failed")
+ ) {
+ $e = new ConnectException($e->getMessage(), $request, $e);
+ } else {
+ $e = RequestException::wrapException($request, $e);
+ }
+ $this->invokeStats($options, $request, $startTime, null, $e);
+
+ return P\Create::rejectionFor($e);
+ }
+ }
+
+ private function invokeStats(
+ array $options,
+ RequestInterface $request,
+ ?float $startTime,
+ ResponseInterface $response = null,
+ \Throwable $error = null
+ ): void {
+ if (isset($options['on_stats'])) {
+ $stats = new TransferStats($request, $response, Utils::currentTime() - $startTime, $error, []);
+ ($options['on_stats'])($stats);
+ }
+ }
+
+ /**
+ * @param resource $stream
+ */
+ private function createResponse(RequestInterface $request, array $options, $stream, ?float $startTime): PromiseInterface
+ {
+ $hdrs = $this->lastHeaders;
+ $this->lastHeaders = [];
+
+ try {
+ [$ver, $status, $reason, $headers] = HeaderProcessor::parseHeaders($hdrs);
+ } catch (\Exception $e) {
+ return P\Create::rejectionFor(
+ new RequestException('An error was encountered while creating the response', $request, null, $e)
+ );
+ }
+
+ [$stream, $headers] = $this->checkDecode($options, $headers, $stream);
+ $stream = Psr7\Utils::streamFor($stream);
+ $sink = $stream;
+
+ if (\strcasecmp('HEAD', $request->getMethod())) {
+ $sink = $this->createSink($stream, $options);
+ }
+
+ try {
+ $response = new Psr7\Response($status, $headers, $sink, $ver, $reason);
+ } catch (\Exception $e) {
+ return P\Create::rejectionFor(
+ new RequestException('An error was encountered while creating the response', $request, null, $e)
+ );
+ }
+
+ if (isset($options['on_headers'])) {
+ try {
+ $options['on_headers']($response);
+ } catch (\Exception $e) {
+ return P\Create::rejectionFor(
+ new RequestException('An error was encountered during the on_headers event', $request, $response, $e)
+ );
+ }
+ }
+
+ // Do not drain when the request is a HEAD request because they have
+ // no body.
+ if ($sink !== $stream) {
+ $this->drain($stream, $sink, $response->getHeaderLine('Content-Length'));
+ }
+
+ $this->invokeStats($options, $request, $startTime, $response, null);
+
+ return new FulfilledPromise($response);
+ }
+
+ private function createSink(StreamInterface $stream, array $options): StreamInterface
+ {
+ if (!empty($options['stream'])) {
+ return $stream;
+ }
+
+ $sink = $options['sink'] ?? Psr7\Utils::tryFopen('php://temp', 'r+');
+
+ return \is_string($sink) ? new Psr7\LazyOpenStream($sink, 'w+') : Psr7\Utils::streamFor($sink);
+ }
+
+ /**
+ * @param resource $stream
+ */
+ private function checkDecode(array $options, array $headers, $stream): array
+ {
+ // Automatically decode responses when instructed.
+ if (!empty($options['decode_content'])) {
+ $normalizedKeys = Utils::normalizeHeaderKeys($headers);
+ if (isset($normalizedKeys['content-encoding'])) {
+ $encoding = $headers[$normalizedKeys['content-encoding']];
+ if ($encoding[0] === 'gzip' || $encoding[0] === 'deflate') {
+ $stream = new Psr7\InflateStream(Psr7\Utils::streamFor($stream));
+ $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']];
+
+ // Remove content-encoding header
+ unset($headers[$normalizedKeys['content-encoding']]);
+
+ // Fix content-length header
+ if (isset($normalizedKeys['content-length'])) {
+ $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']];
+ $length = (int) $stream->getSize();
+ if ($length === 0) {
+ unset($headers[$normalizedKeys['content-length']]);
+ } else {
+ $headers[$normalizedKeys['content-length']] = [$length];
+ }
+ }
+ }
+ }
+ }
+
+ return [$stream, $headers];
+ }
+
+ /**
+ * Drains the source stream into the "sink" client option.
+ *
+ * @param string $contentLength Header specifying the amount of
+ * data to read.
+ *
+ * @throws \RuntimeException when the sink option is invalid.
+ */
+ private function drain(StreamInterface $source, StreamInterface $sink, string $contentLength): StreamInterface
+ {
+ // If a content-length header is provided, then stop reading once
+ // that number of bytes has been read. This can prevent infinitely
+ // reading from a stream when dealing with servers that do not honor
+ // Connection: Close headers.
+ Psr7\Utils::copyToStream(
+ $source,
+ $sink,
+ (\strlen($contentLength) > 0 && (int) $contentLength > 0) ? (int) $contentLength : -1
+ );
+
+ $sink->seek(0);
+ $source->close();
+
+ return $sink;
+ }
+
+ /**
+ * Create a resource and check to ensure it was created successfully
+ *
+ * @param callable $callback Callable that returns stream resource
+ *
+ * @return resource
+ *
+ * @throws \RuntimeException on error
+ */
+ private function createResource(callable $callback)
+ {
+ $errors = [];
+ \set_error_handler(static function ($_, $msg, $file, $line) use (&$errors): bool {
+ $errors[] = [
+ 'message' => $msg,
+ 'file' => $file,
+ 'line' => $line
+ ];
+ return true;
+ });
+
+ try {
+ $resource = $callback();
+ } finally {
+ \restore_error_handler();
+ }
+
+ if (!$resource) {
+ $message = 'Error creating resource: ';
+ foreach ($errors as $err) {
+ foreach ($err as $key => $value) {
+ $message .= "[$key] $value" . \PHP_EOL;
+ }
+ }
+ throw new \RuntimeException(\trim($message));
+ }
+
+ return $resource;
+ }
+
+ /**
+ * @return resource
+ */
+ private function createStream(RequestInterface $request, array $options)
+ {
+ static $methods;
+ if (!$methods) {
+ $methods = \array_flip(\get_class_methods(__CLASS__));
+ }
+
+ if (!\in_array($request->getUri()->getScheme(), ['http', 'https'])) {
+ throw new RequestException(\sprintf("The scheme '%s' is not supported.", $request->getUri()->getScheme()), $request);
+ }
+
+ // HTTP/1.1 streams using the PHP stream wrapper require a
+ // Connection: close header
+ if ($request->getProtocolVersion() == '1.1'
+ && !$request->hasHeader('Connection')
+ ) {
+ $request = $request->withHeader('Connection', 'close');
+ }
+
+ // Ensure SSL is verified by default
+ if (!isset($options['verify'])) {
+ $options['verify'] = true;
+ }
+
+ $params = [];
+ $context = $this->getDefaultContext($request);
+
+ if (isset($options['on_headers']) && !\is_callable($options['on_headers'])) {
+ throw new \InvalidArgumentException('on_headers must be callable');
+ }
+
+ if (!empty($options)) {
+ foreach ($options as $key => $value) {
+ $method = "add_{$key}";
+ if (isset($methods[$method])) {
+ $this->{$method}($request, $context, $value, $params);
+ }
+ }
+ }
+
+ if (isset($options['stream_context'])) {
+ if (!\is_array($options['stream_context'])) {
+ throw new \InvalidArgumentException('stream_context must be an array');
+ }
+ $context = \array_replace_recursive($context, $options['stream_context']);
+ }
+
+ // Microsoft NTLM authentication only supported with curl handler
+ if (isset($options['auth'][2]) && 'ntlm' === $options['auth'][2]) {
+ throw new \InvalidArgumentException('Microsoft NTLM authentication only supported with curl handler');
+ }
+
+ $uri = $this->resolveHost($request, $options);
+
+ $contextResource = $this->createResource(
+ static function () use ($context, $params) {
+ return \stream_context_create($context, $params);
+ }
+ );
+
+ return $this->createResource(
+ function () use ($uri, &$http_response_header, $contextResource, $context, $options, $request) {
+ $resource = @\fopen((string) $uri, 'r', false, $contextResource);
+ $this->lastHeaders = $http_response_header ?? [];
+
+ if (false === $resource) {
+ throw new ConnectException(sprintf('Connection refused for URI %s', $uri), $request, null, $context);
+ }
+
+ if (isset($options['read_timeout'])) {
+ $readTimeout = $options['read_timeout'];
+ $sec = (int) $readTimeout;
+ $usec = ($readTimeout - $sec) * 100000;
+ \stream_set_timeout($resource, $sec, $usec);
+ }
+
+ return $resource;
+ }
+ );
+ }
+
+ private function resolveHost(RequestInterface $request, array $options): UriInterface
+ {
+ $uri = $request->getUri();
+
+ if (isset($options['force_ip_resolve']) && !\filter_var($uri->getHost(), \FILTER_VALIDATE_IP)) {
+ if ('v4' === $options['force_ip_resolve']) {
+ $records = \dns_get_record($uri->getHost(), \DNS_A);
+ if (false === $records || !isset($records[0]['ip'])) {
+ throw new ConnectException(\sprintf("Could not resolve IPv4 address for host '%s'", $uri->getHost()), $request);
+ }
+ return $uri->withHost($records[0]['ip']);
+ }
+ if ('v6' === $options['force_ip_resolve']) {
+ $records = \dns_get_record($uri->getHost(), \DNS_AAAA);
+ if (false === $records || !isset($records[0]['ipv6'])) {
+ throw new ConnectException(\sprintf("Could not resolve IPv6 address for host '%s'", $uri->getHost()), $request);
+ }
+ return $uri->withHost('[' . $records[0]['ipv6'] . ']');
+ }
+ }
+
+ return $uri;
+ }
+
+ private function getDefaultContext(RequestInterface $request): array
+ {
+ $headers = '';
+ foreach ($request->getHeaders() as $name => $value) {
+ foreach ($value as $val) {
+ $headers .= "$name: $val\r\n";
+ }
+ }
+
+ $context = [
+ 'http' => [
+ 'method' => $request->getMethod(),
+ 'header' => $headers,
+ 'protocol_version' => $request->getProtocolVersion(),
+ 'ignore_errors' => true,
+ 'follow_location' => 0,
+ ],
+ 'ssl' => [
+ 'peer_name' => $request->getUri()->getHost(),
+ ],
+ ];
+
+ $body = (string) $request->getBody();
+
+ if (!empty($body)) {
+ $context['http']['content'] = $body;
+ // Prevent the HTTP handler from adding a Content-Type header.
+ if (!$request->hasHeader('Content-Type')) {
+ $context['http']['header'] .= "Content-Type:\r\n";
+ }
+ }
+
+ $context['http']['header'] = \rtrim($context['http']['header']);
+
+ return $context;
+ }
+
+ /**
+ * @param mixed $value as passed via Request transfer options.
+ */
+ private function add_proxy(RequestInterface $request, array &$options, $value, array &$params): void
+ {
+ $uri = null;
+
+ if (!\is_array($value)) {
+ $uri = $value;
+ } else {
+ $scheme = $request->getUri()->getScheme();
+ if (isset($value[$scheme])) {
+ if (!isset($value['no']) || !Utils::isHostInNoProxy($request->getUri()->getHost(), $value['no'])) {
+ $uri = $value[$scheme];
+ }
+ }
+ }
+
+ if (!$uri) {
+ return;
+ }
+
+ $parsed = $this->parse_proxy($uri);
+ $options['http']['proxy'] = $parsed['proxy'];
+
+ if ($parsed['auth']) {
+ if (!isset($options['http']['header'])) {
+ $options['http']['header'] = [];
+ }
+ $options['http']['header'] .= "\r\nProxy-Authorization: {$parsed['auth']}";
+ }
+ }
+
+ /**
+ * Parses the given proxy URL to make it compatible with the format PHP's stream context expects.
+ */
+ private function parse_proxy(string $url): array
+ {
+ $parsed = \parse_url($url);
+
+ if ($parsed !== false && isset($parsed['scheme']) && $parsed['scheme'] === 'http') {
+ if (isset($parsed['host']) && isset($parsed['port'])) {
+ $auth = null;
+ if (isset($parsed['user']) && isset($parsed['pass'])) {
+ $auth = \base64_encode("{$parsed['user']}:{$parsed['pass']}");
+ }
+
+ return [
+ 'proxy' => "tcp://{$parsed['host']}:{$parsed['port']}",
+ 'auth' => $auth ? "Basic {$auth}" : null,
+ ];
+ }
+ }
+
+ // Return proxy as-is.
+ return [
+ 'proxy' => $url,
+ 'auth' => null,
+ ];
+ }
+
+ /**
+ * @param mixed $value as passed via Request transfer options.
+ */
+ private function add_timeout(RequestInterface $request, array &$options, $value, array &$params): void
+ {
+ if ($value > 0) {
+ $options['http']['timeout'] = $value;
+ }
+ }
+
+ /**
+ * @param mixed $value as passed via Request transfer options.
+ */
+ private function add_verify(RequestInterface $request, array &$options, $value, array &$params): void
+ {
+ if ($value === false) {
+ $options['ssl']['verify_peer'] = false;
+ $options['ssl']['verify_peer_name'] = false;
+
+ return;
+ }
+
+ if (\is_string($value)) {
+ $options['ssl']['cafile'] = $value;
+ if (!\file_exists($value)) {
+ throw new \RuntimeException("SSL CA bundle not found: $value");
+ }
+ } elseif ($value !== true) {
+ throw new \InvalidArgumentException('Invalid verify request option');
+ }
+
+ $options['ssl']['verify_peer'] = true;
+ $options['ssl']['verify_peer_name'] = true;
+ $options['ssl']['allow_self_signed'] = false;
+ }
+
+ /**
+ * @param mixed $value as passed via Request transfer options.
+ */
+ private function add_cert(RequestInterface $request, array &$options, $value, array &$params): void
+ {
+ if (\is_array($value)) {
+ $options['ssl']['passphrase'] = $value[1];
+ $value = $value[0];
+ }
+
+ if (!\file_exists($value)) {
+ throw new \RuntimeException("SSL certificate not found: {$value}");
+ }
+
+ $options['ssl']['local_cert'] = $value;
+ }
+
+ /**
+ * @param mixed $value as passed via Request transfer options.
+ */
+ private function add_progress(RequestInterface $request, array &$options, $value, array &$params): void
+ {
+ self::addNotification(
+ $params,
+ static function ($code, $a, $b, $c, $transferred, $total) use ($value) {
+ if ($code == \STREAM_NOTIFY_PROGRESS) {
+ // The upload progress cannot be determined. Use 0 for cURL compatibility:
+ // https://curl.se/libcurl/c/CURLOPT_PROGRESSFUNCTION.html
+ $value($total, $transferred, 0, 0);
+ }
+ }
+ );
+ }
+
+ /**
+ * @param mixed $value as passed via Request transfer options.
+ */
+ private function add_debug(RequestInterface $request, array &$options, $value, array &$params): void
+ {
+ if ($value === false) {
+ return;
+ }
+
+ static $map = [
+ \STREAM_NOTIFY_CONNECT => 'CONNECT',
+ \STREAM_NOTIFY_AUTH_REQUIRED => 'AUTH_REQUIRED',
+ \STREAM_NOTIFY_AUTH_RESULT => 'AUTH_RESULT',
+ \STREAM_NOTIFY_MIME_TYPE_IS => 'MIME_TYPE_IS',
+ \STREAM_NOTIFY_FILE_SIZE_IS => 'FILE_SIZE_IS',
+ \STREAM_NOTIFY_REDIRECTED => 'REDIRECTED',
+ \STREAM_NOTIFY_PROGRESS => 'PROGRESS',
+ \STREAM_NOTIFY_FAILURE => 'FAILURE',
+ \STREAM_NOTIFY_COMPLETED => 'COMPLETED',
+ \STREAM_NOTIFY_RESOLVE => 'RESOLVE',
+ ];
+ static $args = ['severity', 'message', 'message_code', 'bytes_transferred', 'bytes_max'];
+
+ $value = Utils::debugResource($value);
+ $ident = $request->getMethod() . ' ' . $request->getUri()->withFragment('');
+ self::addNotification(
+ $params,
+ static function (int $code, ...$passed) use ($ident, $value, $map, $args): void {
+ \fprintf($value, '<%s> [%s] ', $ident, $map[$code]);
+ foreach (\array_filter($passed) as $i => $v) {
+ \fwrite($value, $args[$i] . ': "' . $v . '" ');
+ }
+ \fwrite($value, "\n");
+ }
+ );
+ }
+
+ private static function addNotification(array &$params, callable $notify): void
+ {
+ // Wrap the existing function if needed.
+ if (!isset($params['notification'])) {
+ $params['notification'] = $notify;
+ } else {
+ $params['notification'] = self::callArray([
+ $params['notification'],
+ $notify
+ ]);
+ }
+ }
+
+ private static function callArray(array $functions): callable
+ {
+ return static function (...$args) use ($functions) {
+ foreach ($functions as $fn) {
+ $fn(...$args);
+ }
+ };
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/HandlerStack.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/HandlerStack.php
new file mode 100644
index 0000000..e0a1d11
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/HandlerStack.php
@@ -0,0 +1,275 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+/**
+ * Creates a composed Guzzle handler function by stacking middlewares on top of
+ * an HTTP handler function.
+ *
+ * @final
+ */
+class HandlerStack
+{
+ /**
+ * @var (callable(RequestInterface, array): PromiseInterface)|null
+ */
+ private $handler;
+
+ /**
+ * @var array{(callable(callable(RequestInterface, array): PromiseInterface): callable), (string|null)}[]
+ */
+ private $stack = [];
+
+ /**
+ * @var (callable(RequestInterface, array): PromiseInterface)|null
+ */
+ private $cached;
+
+ /**
+ * Creates a default handler stack that can be used by clients.
+ *
+ * The returned handler will wrap the provided handler or use the most
+ * appropriate default handler for your system. The returned HandlerStack has
+ * support for cookies, redirects, HTTP error exceptions, and preparing a body
+ * before sending.
+ *
+ * The returned handler stack can be passed to a client in the "handler"
+ * option.
+ *
+ * @param (callable(RequestInterface, array): PromiseInterface)|null $handler HTTP handler function to use with the stack. If no
+ * handler is provided, the best handler for your
+ * system will be utilized.
+ */
+ public static function create(?callable $handler = null): self
+ {
+ $stack = new self($handler ?: Utils::chooseHandler());
+ $stack->push(Middleware::httpErrors(), 'http_errors');
+ $stack->push(Middleware::redirect(), 'allow_redirects');
+ $stack->push(Middleware::cookies(), 'cookies');
+ $stack->push(Middleware::prepareBody(), 'prepare_body');
+
+ return $stack;
+ }
+
+ /**
+ * @param (callable(RequestInterface, array): PromiseInterface)|null $handler Underlying HTTP handler.
+ */
+ public function __construct(callable $handler = null)
+ {
+ $this->handler = $handler;
+ }
+
+ /**
+ * Invokes the handler stack as a composed handler
+ *
+ * @return ResponseInterface|PromiseInterface
+ */
+ public function __invoke(RequestInterface $request, array $options)
+ {
+ $handler = $this->resolve();
+
+ return $handler($request, $options);
+ }
+
+ /**
+ * Dumps a string representation of the stack.
+ *
+ * @return string
+ */
+ public function __toString()
+ {
+ $depth = 0;
+ $stack = [];
+
+ if ($this->handler !== null) {
+ $stack[] = "0) Handler: " . $this->debugCallable($this->handler);
+ }
+
+ $result = '';
+ foreach (\array_reverse($this->stack) as $tuple) {
+ $depth++;
+ $str = "{$depth}) Name: '{$tuple[1]}', ";
+ $str .= "Function: " . $this->debugCallable($tuple[0]);
+ $result = "> {$str}\n{$result}";
+ $stack[] = $str;
+ }
+
+ foreach (\array_keys($stack) as $k) {
+ $result .= "< {$stack[$k]}\n";
+ }
+
+ return $result;
+ }
+
+ /**
+ * Set the HTTP handler that actually returns a promise.
+ *
+ * @param callable(RequestInterface, array): PromiseInterface $handler Accepts a request and array of options and
+ * returns a Promise.
+ */
+ public function setHandler(callable $handler): void
+ {
+ $this->handler = $handler;
+ $this->cached = null;
+ }
+
+ /**
+ * Returns true if the builder has a handler.
+ */
+ public function hasHandler(): bool
+ {
+ return $this->handler !== null ;
+ }
+
+ /**
+ * Unshift a middleware to the bottom of the stack.
+ *
+ * @param callable(callable): callable $middleware Middleware function
+ * @param string $name Name to register for this middleware.
+ */
+ public function unshift(callable $middleware, ?string $name = null): void
+ {
+ \array_unshift($this->stack, [$middleware, $name]);
+ $this->cached = null;
+ }
+
+ /**
+ * Push a middleware to the top of the stack.
+ *
+ * @param callable(callable): callable $middleware Middleware function
+ * @param string $name Name to register for this middleware.
+ */
+ public function push(callable $middleware, string $name = ''): void
+ {
+ $this->stack[] = [$middleware, $name];
+ $this->cached = null;
+ }
+
+ /**
+ * Add a middleware before another middleware by name.
+ *
+ * @param string $findName Middleware to find
+ * @param callable(callable): callable $middleware Middleware function
+ * @param string $withName Name to register for this middleware.
+ */
+ public function before(string $findName, callable $middleware, string $withName = ''): void
+ {
+ $this->splice($findName, $withName, $middleware, true);
+ }
+
+ /**
+ * Add a middleware after another middleware by name.
+ *
+ * @param string $findName Middleware to find
+ * @param callable(callable): callable $middleware Middleware function
+ * @param string $withName Name to register for this middleware.
+ */
+ public function after(string $findName, callable $middleware, string $withName = ''): void
+ {
+ $this->splice($findName, $withName, $middleware, false);
+ }
+
+ /**
+ * Remove a middleware by instance or name from the stack.
+ *
+ * @param callable|string $remove Middleware to remove by instance or name.
+ */
+ public function remove($remove): void
+ {
+ if (!is_string($remove) && !is_callable($remove)) {
+ trigger_deprecation('guzzlehttp/guzzle', '7.4', 'Not passing a callable or string to %s::%s() is deprecated and will cause an error in 8.0.', __CLASS__, __FUNCTION__);
+ }
+
+ $this->cached = null;
+ $idx = \is_callable($remove) ? 0 : 1;
+ $this->stack = \array_values(\array_filter(
+ $this->stack,
+ static function ($tuple) use ($idx, $remove) {
+ return $tuple[$idx] !== $remove;
+ }
+ ));
+ }
+
+ /**
+ * Compose the middleware and handler into a single callable function.
+ *
+ * @return callable(RequestInterface, array): PromiseInterface
+ */
+ public function resolve(): callable
+ {
+ if ($this->cached === null) {
+ if (($prev = $this->handler) === null) {
+ throw new \LogicException('No handler has been specified');
+ }
+
+ foreach (\array_reverse($this->stack) as $fn) {
+ /** @var callable(RequestInterface, array): PromiseInterface $prev */
+ $prev = $fn[0]($prev);
+ }
+
+ $this->cached = $prev;
+ }
+
+ return $this->cached;
+ }
+
+ private function findByName(string $name): int
+ {
+ foreach ($this->stack as $k => $v) {
+ if ($v[1] === $name) {
+ return $k;
+ }
+ }
+
+ throw new \InvalidArgumentException("Middleware not found: $name");
+ }
+
+ /**
+ * Splices a function into the middleware list at a specific position.
+ */
+ private function splice(string $findName, string $withName, callable $middleware, bool $before): void
+ {
+ $this->cached = null;
+ $idx = $this->findByName($findName);
+ $tuple = [$middleware, $withName];
+
+ if ($before) {
+ if ($idx === 0) {
+ \array_unshift($this->stack, $tuple);
+ } else {
+ $replacement = [$tuple, $this->stack[$idx]];
+ \array_splice($this->stack, $idx, 1, $replacement);
+ }
+ } elseif ($idx === \count($this->stack) - 1) {
+ $this->stack[] = $tuple;
+ } else {
+ $replacement = [$this->stack[$idx], $tuple];
+ \array_splice($this->stack, $idx, 1, $replacement);
+ }
+ }
+
+ /**
+ * Provides a debug string for a given callable.
+ *
+ * @param callable|string $fn Function to write as a string.
+ */
+ private function debugCallable($fn): string
+ {
+ if (\is_string($fn)) {
+ return "callable({$fn})";
+ }
+
+ if (\is_array($fn)) {
+ return \is_string($fn[0])
+ ? "callable({$fn[0]}::{$fn[1]})"
+ : "callable(['" . \get_class($fn[0]) . "', '{$fn[1]}'])";
+ }
+
+ /** @var object $fn */
+ return 'callable(' . \spl_object_hash($fn) . ')';
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/MessageFormatter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/MessageFormatter.php
new file mode 100644
index 0000000..da49954
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/MessageFormatter.php
@@ -0,0 +1,198 @@
+<?php
+
+namespace GuzzleHttp;
+
+use Psr\Http\Message\MessageInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+/**
+ * Formats log messages using variable substitutions for requests, responses,
+ * and other transactional data.
+ *
+ * The following variable substitutions are supported:
+ *
+ * - {request}: Full HTTP request message
+ * - {response}: Full HTTP response message
+ * - {ts}: ISO 8601 date in GMT
+ * - {date_iso_8601} ISO 8601 date in GMT
+ * - {date_common_log} Apache common log date using the configured timezone.
+ * - {host}: Host of the request
+ * - {method}: Method of the request
+ * - {uri}: URI of the request
+ * - {version}: Protocol version
+ * - {target}: Request target of the request (path + query + fragment)
+ * - {hostname}: Hostname of the machine that sent the request
+ * - {code}: Status code of the response (if available)
+ * - {phrase}: Reason phrase of the response (if available)
+ * - {error}: Any error messages (if available)
+ * - {req_header_*}: Replace `*` with the lowercased name of a request header to add to the message
+ * - {res_header_*}: Replace `*` with the lowercased name of a response header to add to the message
+ * - {req_headers}: Request headers
+ * - {res_headers}: Response headers
+ * - {req_body}: Request body
+ * - {res_body}: Response body
+ *
+ * @final
+ */
+class MessageFormatter implements MessageFormatterInterface
+{
+ /**
+ * Apache Common Log Format.
+ *
+ * @link https://httpd.apache.org/docs/2.4/logs.html#common
+ *
+ * @var string
+ */
+ public const CLF = "{hostname} {req_header_User-Agent} - [{date_common_log}] \"{method} {target} HTTP/{version}\" {code} {res_header_Content-Length}";
+ public const DEBUG = ">>>>>>>>\n{request}\n<<<<<<<<\n{response}\n--------\n{error}";
+ public const SHORT = '[{ts}] "{method} {target} HTTP/{version}" {code}';
+
+ /**
+ * @var string Template used to format log messages
+ */
+ private $template;
+
+ /**
+ * @param string $template Log message template
+ */
+ public function __construct(?string $template = self::CLF)
+ {
+ $this->template = $template ?: self::CLF;
+ }
+
+ /**
+ * Returns a formatted message string.
+ *
+ * @param RequestInterface $request Request that was sent
+ * @param ResponseInterface|null $response Response that was received
+ * @param \Throwable|null $error Exception that was received
+ */
+ public function format(RequestInterface $request, ?ResponseInterface $response = null, ?\Throwable $error = null): string
+ {
+ $cache = [];
+
+ /** @var string */
+ return \preg_replace_callback(
+ '/{\s*([A-Za-z_\-\.0-9]+)\s*}/',
+ function (array $matches) use ($request, $response, $error, &$cache) {
+ if (isset($cache[$matches[1]])) {
+ return $cache[$matches[1]];
+ }
+
+ $result = '';
+ switch ($matches[1]) {
+ case 'request':
+ $result = Psr7\Message::toString($request);
+ break;
+ case 'response':
+ $result = $response ? Psr7\Message::toString($response) : '';
+ break;
+ case 'req_headers':
+ $result = \trim($request->getMethod()
+ . ' ' . $request->getRequestTarget())
+ . ' HTTP/' . $request->getProtocolVersion() . "\r\n"
+ . $this->headers($request);
+ break;
+ case 'res_headers':
+ $result = $response ?
+ \sprintf(
+ 'HTTP/%s %d %s',
+ $response->getProtocolVersion(),
+ $response->getStatusCode(),
+ $response->getReasonPhrase()
+ ) . "\r\n" . $this->headers($response)
+ : 'NULL';
+ break;
+ case 'req_body':
+ $result = $request->getBody()->__toString();
+ break;
+ case 'res_body':
+ if (!$response instanceof ResponseInterface) {
+ $result = 'NULL';
+ break;
+ }
+
+ $body = $response->getBody();
+
+ if (!$body->isSeekable()) {
+ $result = 'RESPONSE_NOT_LOGGEABLE';
+ break;
+ }
+
+ $result = $response->getBody()->__toString();
+ break;
+ case 'ts':
+ case 'date_iso_8601':
+ $result = \gmdate('c');
+ break;
+ case 'date_common_log':
+ $result = \date('d/M/Y:H:i:s O');
+ break;
+ case 'method':
+ $result = $request->getMethod();
+ break;
+ case 'version':
+ $result = $request->getProtocolVersion();
+ break;
+ case 'uri':
+ case 'url':
+ $result = $request->getUri()->__toString();
+ break;
+ case 'target':
+ $result = $request->getRequestTarget();
+ break;
+ case 'req_version':
+ $result = $request->getProtocolVersion();
+ break;
+ case 'res_version':
+ $result = $response
+ ? $response->getProtocolVersion()
+ : 'NULL';
+ break;
+ case 'host':
+ $result = $request->getHeaderLine('Host');
+ break;
+ case 'hostname':
+ $result = \gethostname();
+ break;
+ case 'code':
+ $result = $response ? $response->getStatusCode() : 'NULL';
+ break;
+ case 'phrase':
+ $result = $response ? $response->getReasonPhrase() : 'NULL';
+ break;
+ case 'error':
+ $result = $error ? $error->getMessage() : 'NULL';
+ break;
+ default:
+ // handle prefixed dynamic headers
+ if (\strpos($matches[1], 'req_header_') === 0) {
+ $result = $request->getHeaderLine(\substr($matches[1], 11));
+ } elseif (\strpos($matches[1], 'res_header_') === 0) {
+ $result = $response
+ ? $response->getHeaderLine(\substr($matches[1], 11))
+ : 'NULL';
+ }
+ }
+
+ $cache[$matches[1]] = $result;
+ return $result;
+ },
+ $this->template
+ );
+ }
+
+ /**
+ * Get headers from message as string
+ */
+ private function headers(MessageInterface $message): string
+ {
+ $result = '';
+ foreach ($message->getHeaders() as $name => $values) {
+ $result .= $name . ': ' . \implode(', ', $values) . "\r\n";
+ }
+
+ return \trim($result);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/MessageFormatterInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/MessageFormatterInterface.php
new file mode 100644
index 0000000..a39ac24
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/MessageFormatterInterface.php
@@ -0,0 +1,18 @@
+<?php
+
+namespace GuzzleHttp;
+
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+interface MessageFormatterInterface
+{
+ /**
+ * Returns a formatted message string.
+ *
+ * @param RequestInterface $request Request that was sent
+ * @param ResponseInterface|null $response Response that was received
+ * @param \Throwable|null $error Exception that was received
+ */
+ public function format(RequestInterface $request, ?ResponseInterface $response = null, ?\Throwable $error = null): string;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Middleware.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Middleware.php
new file mode 100644
index 0000000..7035c77
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Middleware.php
@@ -0,0 +1,260 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Cookie\CookieJarInterface;
+use GuzzleHttp\Exception\RequestException;
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Log\LoggerInterface;
+
+/**
+ * Functions used to create and wrap handlers with handler middleware.
+ */
+final class Middleware
+{
+ /**
+ * Middleware that adds cookies to requests.
+ *
+ * The options array must be set to a CookieJarInterface in order to use
+ * cookies. This is typically handled for you by a client.
+ *
+ * @return callable Returns a function that accepts the next handler.
+ */
+ public static function cookies(): callable
+ {
+ return static function (callable $handler): callable {
+ return static function ($request, array $options) use ($handler) {
+ if (empty($options['cookies'])) {
+ return $handler($request, $options);
+ } elseif (!($options['cookies'] instanceof CookieJarInterface)) {
+ throw new \InvalidArgumentException('cookies must be an instance of GuzzleHttp\Cookie\CookieJarInterface');
+ }
+ $cookieJar = $options['cookies'];
+ $request = $cookieJar->withCookieHeader($request);
+ return $handler($request, $options)
+ ->then(
+ static function (ResponseInterface $response) use ($cookieJar, $request): ResponseInterface {
+ $cookieJar->extractCookies($request, $response);
+ return $response;
+ }
+ );
+ };
+ };
+ }
+
+ /**
+ * Middleware that throws exceptions for 4xx or 5xx responses when the
+ * "http_errors" request option is set to true.
+ *
+ * @param BodySummarizerInterface|null $bodySummarizer The body summarizer to use in exception messages.
+ *
+ * @return callable(callable): callable Returns a function that accepts the next handler.
+ */
+ public static function httpErrors(BodySummarizerInterface $bodySummarizer = null): callable
+ {
+ return static function (callable $handler) use ($bodySummarizer): callable {
+ return static function ($request, array $options) use ($handler, $bodySummarizer) {
+ if (empty($options['http_errors'])) {
+ return $handler($request, $options);
+ }
+ return $handler($request, $options)->then(
+ static function (ResponseInterface $response) use ($request, $bodySummarizer) {
+ $code = $response->getStatusCode();
+ if ($code < 400) {
+ return $response;
+ }
+ throw RequestException::create($request, $response, null, [], $bodySummarizer);
+ }
+ );
+ };
+ };
+ }
+
+ /**
+ * Middleware that pushes history data to an ArrayAccess container.
+ *
+ * @param array|\ArrayAccess<int, array> $container Container to hold the history (by reference).
+ *
+ * @return callable(callable): callable Returns a function that accepts the next handler.
+ *
+ * @throws \InvalidArgumentException if container is not an array or ArrayAccess.
+ */
+ public static function history(&$container): callable
+ {
+ if (!\is_array($container) && !$container instanceof \ArrayAccess) {
+ throw new \InvalidArgumentException('history container must be an array or object implementing ArrayAccess');
+ }
+
+ return static function (callable $handler) use (&$container): callable {
+ return static function (RequestInterface $request, array $options) use ($handler, &$container) {
+ return $handler($request, $options)->then(
+ static function ($value) use ($request, &$container, $options) {
+ $container[] = [
+ 'request' => $request,
+ 'response' => $value,
+ 'error' => null,
+ 'options' => $options
+ ];
+ return $value;
+ },
+ static function ($reason) use ($request, &$container, $options) {
+ $container[] = [
+ 'request' => $request,
+ 'response' => null,
+ 'error' => $reason,
+ 'options' => $options
+ ];
+ return P\Create::rejectionFor($reason);
+ }
+ );
+ };
+ };
+ }
+
+ /**
+ * Middleware that invokes a callback before and after sending a request.
+ *
+ * The provided listener cannot modify or alter the response. It simply
+ * "taps" into the chain to be notified before returning the promise. The
+ * before listener accepts a request and options array, and the after
+ * listener accepts a request, options array, and response promise.
+ *
+ * @param callable $before Function to invoke before forwarding the request.
+ * @param callable $after Function invoked after forwarding.
+ *
+ * @return callable Returns a function that accepts the next handler.
+ */
+ public static function tap(callable $before = null, callable $after = null): callable
+ {
+ return static function (callable $handler) use ($before, $after): callable {
+ return static function (RequestInterface $request, array $options) use ($handler, $before, $after) {
+ if ($before) {
+ $before($request, $options);
+ }
+ $response = $handler($request, $options);
+ if ($after) {
+ $after($request, $options, $response);
+ }
+ return $response;
+ };
+ };
+ }
+
+ /**
+ * Middleware that handles request redirects.
+ *
+ * @return callable Returns a function that accepts the next handler.
+ */
+ public static function redirect(): callable
+ {
+ return static function (callable $handler): RedirectMiddleware {
+ return new RedirectMiddleware($handler);
+ };
+ }
+
+ /**
+ * Middleware that retries requests based on the boolean result of
+ * invoking the provided "decider" function.
+ *
+ * If no delay function is provided, a simple implementation of exponential
+ * backoff will be utilized.
+ *
+ * @param callable $decider Function that accepts the number of retries,
+ * a request, [response], and [exception] and
+ * returns true if the request is to be retried.
+ * @param callable $delay Function that accepts the number of retries and
+ * returns the number of milliseconds to delay.
+ *
+ * @return callable Returns a function that accepts the next handler.
+ */
+ public static function retry(callable $decider, callable $delay = null): callable
+ {
+ return static function (callable $handler) use ($decider, $delay): RetryMiddleware {
+ return new RetryMiddleware($decider, $handler, $delay);
+ };
+ }
+
+ /**
+ * Middleware that logs requests, responses, and errors using a message
+ * formatter.
+ *
+ * @phpstan-param \Psr\Log\LogLevel::* $logLevel Level at which to log requests.
+ *
+ * @param LoggerInterface $logger Logs messages.
+ * @param MessageFormatterInterface|MessageFormatter $formatter Formatter used to create message strings.
+ * @param string $logLevel Level at which to log requests.
+ *
+ * @return callable Returns a function that accepts the next handler.
+ */
+ public static function log(LoggerInterface $logger, $formatter, string $logLevel = 'info'): callable
+ {
+ // To be compatible with Guzzle 7.1.x we need to allow users to pass a MessageFormatter
+ if (!$formatter instanceof MessageFormatter && !$formatter instanceof MessageFormatterInterface) {
+ throw new \LogicException(sprintf('Argument 2 to %s::log() must be of type %s', self::class, MessageFormatterInterface::class));
+ }
+
+ return static function (callable $handler) use ($logger, $formatter, $logLevel): callable {
+ return static function (RequestInterface $request, array $options = []) use ($handler, $logger, $formatter, $logLevel) {
+ return $handler($request, $options)->then(
+ static function ($response) use ($logger, $request, $formatter, $logLevel): ResponseInterface {
+ $message = $formatter->format($request, $response);
+ $logger->log($logLevel, $message);
+ return $response;
+ },
+ static function ($reason) use ($logger, $request, $formatter): PromiseInterface {
+ $response = $reason instanceof RequestException ? $reason->getResponse() : null;
+ $message = $formatter->format($request, $response, P\Create::exceptionFor($reason));
+ $logger->error($message);
+ return P\Create::rejectionFor($reason);
+ }
+ );
+ };
+ };
+ }
+
+ /**
+ * This middleware adds a default content-type if possible, a default
+ * content-length or transfer-encoding header, and the expect header.
+ */
+ public static function prepareBody(): callable
+ {
+ return static function (callable $handler): PrepareBodyMiddleware {
+ return new PrepareBodyMiddleware($handler);
+ };
+ }
+
+ /**
+ * Middleware that applies a map function to the request before passing to
+ * the next handler.
+ *
+ * @param callable $fn Function that accepts a RequestInterface and returns
+ * a RequestInterface.
+ */
+ public static function mapRequest(callable $fn): callable
+ {
+ return static function (callable $handler) use ($fn): callable {
+ return static function (RequestInterface $request, array $options) use ($handler, $fn) {
+ return $handler($fn($request), $options);
+ };
+ };
+ }
+
+ /**
+ * Middleware that applies a map function to the resolved promise's
+ * response.
+ *
+ * @param callable $fn Function that accepts a ResponseInterface and
+ * returns a ResponseInterface.
+ */
+ public static function mapResponse(callable $fn): callable
+ {
+ return static function (callable $handler) use ($fn): callable {
+ return static function (RequestInterface $request, array $options) use ($handler, $fn) {
+ return $handler($request, $options)->then($fn);
+ };
+ };
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Pool.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Pool.php
new file mode 100644
index 0000000..6277c61
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Pool.php
@@ -0,0 +1,125 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\EachPromise;
+use GuzzleHttp\Promise\PromiseInterface;
+use GuzzleHttp\Promise\PromisorInterface;
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Sends an iterator of requests concurrently using a capped pool size.
+ *
+ * The pool will read from an iterator until it is cancelled or until the
+ * iterator is consumed. When a request is yielded, the request is sent after
+ * applying the "request_options" request options (if provided in the ctor).
+ *
+ * When a function is yielded by the iterator, the function is provided the
+ * "request_options" array that should be merged on top of any existing
+ * options, and the function MUST then return a wait-able promise.
+ *
+ * @final
+ */
+class Pool implements PromisorInterface
+{
+ /**
+ * @var EachPromise
+ */
+ private $each;
+
+ /**
+ * @param ClientInterface $client Client used to send the requests.
+ * @param array|\Iterator $requests Requests or functions that return
+ * requests to send concurrently.
+ * @param array $config Associative array of options
+ * - concurrency: (int) Maximum number of requests to send concurrently
+ * - options: Array of request options to apply to each request.
+ * - fulfilled: (callable) Function to invoke when a request completes.
+ * - rejected: (callable) Function to invoke when a request is rejected.
+ */
+ public function __construct(ClientInterface $client, $requests, array $config = [])
+ {
+ if (!isset($config['concurrency'])) {
+ $config['concurrency'] = 25;
+ }
+
+ if (isset($config['options'])) {
+ $opts = $config['options'];
+ unset($config['options']);
+ } else {
+ $opts = [];
+ }
+
+ $iterable = P\Create::iterFor($requests);
+ $requests = static function () use ($iterable, $client, $opts) {
+ foreach ($iterable as $key => $rfn) {
+ if ($rfn instanceof RequestInterface) {
+ yield $key => $client->sendAsync($rfn, $opts);
+ } elseif (\is_callable($rfn)) {
+ yield $key => $rfn($opts);
+ } else {
+ throw new \InvalidArgumentException('Each value yielded by the iterator must be a Psr7\Http\Message\RequestInterface or a callable that returns a promise that fulfills with a Psr7\Message\Http\ResponseInterface object.');
+ }
+ }
+ };
+
+ $this->each = new EachPromise($requests(), $config);
+ }
+
+ /**
+ * Get promise
+ */
+ public function promise(): PromiseInterface
+ {
+ return $this->each->promise();
+ }
+
+ /**
+ * Sends multiple requests concurrently and returns an array of responses
+ * and exceptions that uses the same ordering as the provided requests.
+ *
+ * IMPORTANT: This method keeps every request and response in memory, and
+ * as such, is NOT recommended when sending a large number or an
+ * indeterminate number of requests concurrently.
+ *
+ * @param ClientInterface $client Client used to send the requests
+ * @param array|\Iterator $requests Requests to send concurrently.
+ * @param array $options Passes through the options available in
+ * {@see \GuzzleHttp\Pool::__construct}
+ *
+ * @return array Returns an array containing the response or an exception
+ * in the same order that the requests were sent.
+ *
+ * @throws \InvalidArgumentException if the event format is incorrect.
+ */
+ public static function batch(ClientInterface $client, $requests, array $options = []): array
+ {
+ $res = [];
+ self::cmpCallback($options, 'fulfilled', $res);
+ self::cmpCallback($options, 'rejected', $res);
+ $pool = new static($client, $requests, $options);
+ $pool->promise()->wait();
+ \ksort($res);
+
+ return $res;
+ }
+
+ /**
+ * Execute callback(s)
+ */
+ private static function cmpCallback(array &$options, string $name, array &$results): void
+ {
+ if (!isset($options[$name])) {
+ $options[$name] = static function ($v, $k) use (&$results) {
+ $results[$k] = $v;
+ };
+ } else {
+ $currentFn = $options[$name];
+ $options[$name] = static function ($v, $k) use (&$results, $currentFn) {
+ $currentFn($v, $k);
+ $results[$k] = $v;
+ };
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php
new file mode 100644
index 0000000..7ca6283
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php
@@ -0,0 +1,104 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Prepares requests that contain a body, adding the Content-Length,
+ * Content-Type, and Expect headers.
+ *
+ * @final
+ */
+class PrepareBodyMiddleware
+{
+ /**
+ * @var callable(RequestInterface, array): PromiseInterface
+ */
+ private $nextHandler;
+
+ /**
+ * @param callable(RequestInterface, array): PromiseInterface $nextHandler Next handler to invoke.
+ */
+ public function __construct(callable $nextHandler)
+ {
+ $this->nextHandler = $nextHandler;
+ }
+
+ public function __invoke(RequestInterface $request, array $options): PromiseInterface
+ {
+ $fn = $this->nextHandler;
+
+ // Don't do anything if the request has no body.
+ if ($request->getBody()->getSize() === 0) {
+ return $fn($request, $options);
+ }
+
+ $modify = [];
+
+ // Add a default content-type if possible.
+ if (!$request->hasHeader('Content-Type')) {
+ if ($uri = $request->getBody()->getMetadata('uri')) {
+ if (is_string($uri) && $type = Psr7\MimeType::fromFilename($uri)) {
+ $modify['set_headers']['Content-Type'] = $type;
+ }
+ }
+ }
+
+ // Add a default content-length or transfer-encoding header.
+ if (!$request->hasHeader('Content-Length')
+ && !$request->hasHeader('Transfer-Encoding')
+ ) {
+ $size = $request->getBody()->getSize();
+ if ($size !== null) {
+ $modify['set_headers']['Content-Length'] = $size;
+ } else {
+ $modify['set_headers']['Transfer-Encoding'] = 'chunked';
+ }
+ }
+
+ // Add the expect header if needed.
+ $this->addExpectHeader($request, $options, $modify);
+
+ return $fn(Psr7\Utils::modifyRequest($request, $modify), $options);
+ }
+
+ /**
+ * Add expect header
+ */
+ private function addExpectHeader(RequestInterface $request, array $options, array &$modify): void
+ {
+ // Determine if the Expect header should be used
+ if ($request->hasHeader('Expect')) {
+ return;
+ }
+
+ $expect = $options['expect'] ?? null;
+
+ // Return if disabled or if you're not using HTTP/1.1 or HTTP/2.0
+ if ($expect === false || $request->getProtocolVersion() < 1.1) {
+ return;
+ }
+
+ // The expect header is unconditionally enabled
+ if ($expect === true) {
+ $modify['set_headers']['Expect'] = '100-Continue';
+ return;
+ }
+
+ // By default, send the expect header when the payload is > 1mb
+ if ($expect === null) {
+ $expect = 1048576;
+ }
+
+ // Always add if the body cannot be rewound, the size cannot be
+ // determined, or the size is greater than the cutoff threshold
+ $body = $request->getBody();
+ $size = $body->getSize();
+
+ if ($size === null || $size >= (int) $expect || !$body->isSeekable()) {
+ $modify['set_headers']['Expect'] = '100-Continue';
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php
new file mode 100644
index 0000000..f67d448
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php
@@ -0,0 +1,228 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Exception\BadResponseException;
+use GuzzleHttp\Exception\TooManyRedirectsException;
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Request redirect middleware.
+ *
+ * Apply this middleware like other middleware using
+ * {@see \GuzzleHttp\Middleware::redirect()}.
+ *
+ * @final
+ */
+class RedirectMiddleware
+{
+ public const HISTORY_HEADER = 'X-Guzzle-Redirect-History';
+
+ public const STATUS_HISTORY_HEADER = 'X-Guzzle-Redirect-Status-History';
+
+ /**
+ * @var array
+ */
+ public static $defaultSettings = [
+ 'max' => 5,
+ 'protocols' => ['http', 'https'],
+ 'strict' => false,
+ 'referer' => false,
+ 'track_redirects' => false,
+ ];
+
+ /**
+ * @var callable(RequestInterface, array): PromiseInterface
+ */
+ private $nextHandler;
+
+ /**
+ * @param callable(RequestInterface, array): PromiseInterface $nextHandler Next handler to invoke.
+ */
+ public function __construct(callable $nextHandler)
+ {
+ $this->nextHandler = $nextHandler;
+ }
+
+ public function __invoke(RequestInterface $request, array $options): PromiseInterface
+ {
+ $fn = $this->nextHandler;
+
+ if (empty($options['allow_redirects'])) {
+ return $fn($request, $options);
+ }
+
+ if ($options['allow_redirects'] === true) {
+ $options['allow_redirects'] = self::$defaultSettings;
+ } elseif (!\is_array($options['allow_redirects'])) {
+ throw new \InvalidArgumentException('allow_redirects must be true, false, or array');
+ } else {
+ // Merge the default settings with the provided settings
+ $options['allow_redirects'] += self::$defaultSettings;
+ }
+
+ if (empty($options['allow_redirects']['max'])) {
+ return $fn($request, $options);
+ }
+
+ return $fn($request, $options)
+ ->then(function (ResponseInterface $response) use ($request, $options) {
+ return $this->checkRedirect($request, $options, $response);
+ });
+ }
+
+ /**
+ * @return ResponseInterface|PromiseInterface
+ */
+ public function checkRedirect(RequestInterface $request, array $options, ResponseInterface $response)
+ {
+ if (\strpos((string) $response->getStatusCode(), '3') !== 0
+ || !$response->hasHeader('Location')
+ ) {
+ return $response;
+ }
+
+ $this->guardMax($request, $response, $options);
+ $nextRequest = $this->modifyRequest($request, $options, $response);
+
+ // If authorization is handled by curl, unset it if URI is cross-origin.
+ if (Psr7\UriComparator::isCrossOrigin($request->getUri(), $nextRequest->getUri()) && defined('\CURLOPT_HTTPAUTH')) {
+ unset(
+ $options['curl'][\CURLOPT_HTTPAUTH],
+ $options['curl'][\CURLOPT_USERPWD]
+ );
+ }
+
+ if (isset($options['allow_redirects']['on_redirect'])) {
+ ($options['allow_redirects']['on_redirect'])(
+ $request,
+ $response,
+ $nextRequest->getUri()
+ );
+ }
+
+ $promise = $this($nextRequest, $options);
+
+ // Add headers to be able to track history of redirects.
+ if (!empty($options['allow_redirects']['track_redirects'])) {
+ return $this->withTracking(
+ $promise,
+ (string) $nextRequest->getUri(),
+ $response->getStatusCode()
+ );
+ }
+
+ return $promise;
+ }
+
+ /**
+ * Enable tracking on promise.
+ */
+ private function withTracking(PromiseInterface $promise, string $uri, int $statusCode): PromiseInterface
+ {
+ return $promise->then(
+ static function (ResponseInterface $response) use ($uri, $statusCode) {
+ // Note that we are pushing to the front of the list as this
+ // would be an earlier response than what is currently present
+ // in the history header.
+ $historyHeader = $response->getHeader(self::HISTORY_HEADER);
+ $statusHeader = $response->getHeader(self::STATUS_HISTORY_HEADER);
+ \array_unshift($historyHeader, $uri);
+ \array_unshift($statusHeader, (string) $statusCode);
+
+ return $response->withHeader(self::HISTORY_HEADER, $historyHeader)
+ ->withHeader(self::STATUS_HISTORY_HEADER, $statusHeader);
+ }
+ );
+ }
+
+ /**
+ * Check for too many redirects.
+ *
+ * @throws TooManyRedirectsException Too many redirects.
+ */
+ private function guardMax(RequestInterface $request, ResponseInterface $response, array &$options): void
+ {
+ $current = $options['__redirect_count']
+ ?? 0;
+ $options['__redirect_count'] = $current + 1;
+ $max = $options['allow_redirects']['max'];
+
+ if ($options['__redirect_count'] > $max) {
+ throw new TooManyRedirectsException("Will not follow more than {$max} redirects", $request, $response);
+ }
+ }
+
+ public function modifyRequest(RequestInterface $request, array $options, ResponseInterface $response): RequestInterface
+ {
+ // Request modifications to apply.
+ $modify = [];
+ $protocols = $options['allow_redirects']['protocols'];
+
+ // Use a GET request if this is an entity enclosing request and we are
+ // not forcing RFC compliance, but rather emulating what all browsers
+ // would do.
+ $statusCode = $response->getStatusCode();
+ if ($statusCode == 303 ||
+ ($statusCode <= 302 && !$options['allow_redirects']['strict'])
+ ) {
+ $safeMethods = ['GET', 'HEAD', 'OPTIONS'];
+ $requestMethod = $request->getMethod();
+
+ $modify['method'] = in_array($requestMethod, $safeMethods) ? $requestMethod : 'GET';
+ $modify['body'] = '';
+ }
+
+ $uri = self::redirectUri($request, $response, $protocols);
+ if (isset($options['idn_conversion']) && ($options['idn_conversion'] !== false)) {
+ $idnOptions = ($options['idn_conversion'] === true) ? \IDNA_DEFAULT : $options['idn_conversion'];
+ $uri = Utils::idnUriConvert($uri, $idnOptions);
+ }
+
+ $modify['uri'] = $uri;
+ Psr7\Message::rewindBody($request);
+
+ // Add the Referer header if it is told to do so and only
+ // add the header if we are not redirecting from https to http.
+ if ($options['allow_redirects']['referer']
+ && $modify['uri']->getScheme() === $request->getUri()->getScheme()
+ ) {
+ $uri = $request->getUri()->withUserInfo('');
+ $modify['set_headers']['Referer'] = (string) $uri;
+ } else {
+ $modify['remove_headers'][] = 'Referer';
+ }
+
+ // Remove Authorization and Cookie headers if URI is cross-origin.
+ if (Psr7\UriComparator::isCrossOrigin($request->getUri(), $modify['uri'])) {
+ $modify['remove_headers'][] = 'Authorization';
+ $modify['remove_headers'][] = 'Cookie';
+ }
+
+ return Psr7\Utils::modifyRequest($request, $modify);
+ }
+
+ /**
+ * Set the appropriate URL on the request based on the location header.
+ */
+ private static function redirectUri(
+ RequestInterface $request,
+ ResponseInterface $response,
+ array $protocols
+ ): UriInterface {
+ $location = Psr7\UriResolver::resolve(
+ $request->getUri(),
+ new Psr7\Uri($response->getHeaderLine('Location'))
+ );
+
+ // Ensure that the redirect URI is allowed based on the protocols.
+ if (!\in_array($location->getScheme(), $protocols)) {
+ throw new BadResponseException(\sprintf('Redirect URI, %s, does not use one of the allowed redirect protocols: %s', $location, \implode(', ', $protocols)), $request, $response);
+ }
+
+ return $location;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RequestOptions.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RequestOptions.php
new file mode 100644
index 0000000..20b31bc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RequestOptions.php
@@ -0,0 +1,264 @@
+<?php
+
+namespace GuzzleHttp;
+
+/**
+ * This class contains a list of built-in Guzzle request options.
+ *
+ * More documentation for each option can be found at http://guzzlephp.org/.
+ *
+ * @link http://docs.guzzlephp.org/en/v6/request-options.html
+ */
+final class RequestOptions
+{
+ /**
+ * allow_redirects: (bool|array) Controls redirect behavior. Pass false
+ * to disable redirects, pass true to enable redirects, pass an
+ * associative to provide custom redirect settings. Defaults to "false".
+ * This option only works if your handler has the RedirectMiddleware. When
+ * passing an associative array, you can provide the following key value
+ * pairs:
+ *
+ * - max: (int, default=5) maximum number of allowed redirects.
+ * - strict: (bool, default=false) Set to true to use strict redirects
+ * meaning redirect POST requests with POST requests vs. doing what most
+ * browsers do which is redirect POST requests with GET requests
+ * - referer: (bool, default=false) Set to true to enable the Referer
+ * header.
+ * - protocols: (array, default=['http', 'https']) Allowed redirect
+ * protocols.
+ * - on_redirect: (callable) PHP callable that is invoked when a redirect
+ * is encountered. The callable is invoked with the request, the redirect
+ * response that was received, and the effective URI. Any return value
+ * from the on_redirect function is ignored.
+ */
+ public const ALLOW_REDIRECTS = 'allow_redirects';
+
+ /**
+ * auth: (array) Pass an array of HTTP authentication parameters to use
+ * with the request. The array must contain the username in index [0],
+ * the password in index [1], and you can optionally provide a built-in
+ * authentication type in index [2]. Pass null to disable authentication
+ * for a request.
+ */
+ public const AUTH = 'auth';
+
+ /**
+ * body: (resource|string|null|int|float|StreamInterface|callable|\Iterator)
+ * Body to send in the request.
+ */
+ public const BODY = 'body';
+
+ /**
+ * cert: (string|array) Set to a string to specify the path to a file
+ * containing a PEM formatted SSL client side certificate. If a password
+ * is required, then set cert to an array containing the path to the PEM
+ * file in the first array element followed by the certificate password
+ * in the second array element.
+ */
+ public const CERT = 'cert';
+
+ /**
+ * cookies: (bool|GuzzleHttp\Cookie\CookieJarInterface, default=false)
+ * Specifies whether or not cookies are used in a request or what cookie
+ * jar to use or what cookies to send. This option only works if your
+ * handler has the `cookie` middleware. Valid values are `false` and
+ * an instance of {@see \GuzzleHttp\Cookie\CookieJarInterface}.
+ */
+ public const COOKIES = 'cookies';
+
+ /**
+ * connect_timeout: (float, default=0) Float describing the number of
+ * seconds to wait while trying to connect to a server. Use 0 to wait
+ * indefinitely (the default behavior).
+ */
+ public const CONNECT_TIMEOUT = 'connect_timeout';
+
+ /**
+ * debug: (bool|resource) Set to true or set to a PHP stream returned by
+ * fopen() enable debug output with the HTTP handler used to send a
+ * request.
+ */
+ public const DEBUG = 'debug';
+
+ /**
+ * decode_content: (bool, default=true) Specify whether or not
+ * Content-Encoding responses (gzip, deflate, etc.) are automatically
+ * decoded.
+ */
+ public const DECODE_CONTENT = 'decode_content';
+
+ /**
+ * delay: (int) The amount of time to delay before sending in milliseconds.
+ */
+ public const DELAY = 'delay';
+
+ /**
+ * expect: (bool|integer) Controls the behavior of the
+ * "Expect: 100-Continue" header.
+ *
+ * Set to `true` to enable the "Expect: 100-Continue" header for all
+ * requests that sends a body. Set to `false` to disable the
+ * "Expect: 100-Continue" header for all requests. Set to a number so that
+ * the size of the payload must be greater than the number in order to send
+ * the Expect header. Setting to a number will send the Expect header for
+ * all requests in which the size of the payload cannot be determined or
+ * where the body is not rewindable.
+ *
+ * By default, Guzzle will add the "Expect: 100-Continue" header when the
+ * size of the body of a request is greater than 1 MB and a request is
+ * using HTTP/1.1.
+ */
+ public const EXPECT = 'expect';
+
+ /**
+ * form_params: (array) Associative array of form field names to values
+ * where each value is a string or array of strings. Sets the Content-Type
+ * header to application/x-www-form-urlencoded when no Content-Type header
+ * is already present.
+ */
+ public const FORM_PARAMS = 'form_params';
+
+ /**
+ * headers: (array) Associative array of HTTP headers. Each value MUST be
+ * a string or array of strings.
+ */
+ public const HEADERS = 'headers';
+
+ /**
+ * http_errors: (bool, default=true) Set to false to disable exceptions
+ * when a non- successful HTTP response is received. By default,
+ * exceptions will be thrown for 4xx and 5xx responses. This option only
+ * works if your handler has the `httpErrors` middleware.
+ */
+ public const HTTP_ERRORS = 'http_errors';
+
+ /**
+ * idn: (bool|int, default=true) A combination of IDNA_* constants for
+ * idn_to_ascii() PHP's function (see "options" parameter). Set to false to
+ * disable IDN support completely, or to true to use the default
+ * configuration (IDNA_DEFAULT constant).
+ */
+ public const IDN_CONVERSION = 'idn_conversion';
+
+ /**
+ * json: (mixed) Adds JSON data to a request. The provided value is JSON
+ * encoded and a Content-Type header of application/json will be added to
+ * the request if no Content-Type header is already present.
+ */
+ public const JSON = 'json';
+
+ /**
+ * multipart: (array) Array of associative arrays, each containing a
+ * required "name" key mapping to the form field, name, a required
+ * "contents" key mapping to a StreamInterface|resource|string, an
+ * optional "headers" associative array of custom headers, and an
+ * optional "filename" key mapping to a string to send as the filename in
+ * the part. If no "filename" key is present, then no "filename" attribute
+ * will be added to the part.
+ */
+ public const MULTIPART = 'multipart';
+
+ /**
+ * on_headers: (callable) A callable that is invoked when the HTTP headers
+ * of the response have been received but the body has not yet begun to
+ * download.
+ */
+ public const ON_HEADERS = 'on_headers';
+
+ /**
+ * on_stats: (callable) allows you to get access to transfer statistics of
+ * a request and access the lower level transfer details of the handler
+ * associated with your client. ``on_stats`` is a callable that is invoked
+ * when a handler has finished sending a request. The callback is invoked
+ * with transfer statistics about the request, the response received, or
+ * the error encountered. Included in the data is the total amount of time
+ * taken to send the request.
+ */
+ public const ON_STATS = 'on_stats';
+
+ /**
+ * progress: (callable) Defines a function to invoke when transfer
+ * progress is made. The function accepts the following positional
+ * arguments: the total number of bytes expected to be downloaded, the
+ * number of bytes downloaded so far, the number of bytes expected to be
+ * uploaded, the number of bytes uploaded so far.
+ */
+ public const PROGRESS = 'progress';
+
+ /**
+ * proxy: (string|array) Pass a string to specify an HTTP proxy, or an
+ * array to specify different proxies for different protocols (where the
+ * key is the protocol and the value is a proxy string).
+ */
+ public const PROXY = 'proxy';
+
+ /**
+ * query: (array|string) Associative array of query string values to add
+ * to the request. This option uses PHP's http_build_query() to create
+ * the string representation. Pass a string value if you need more
+ * control than what this method provides
+ */
+ public const QUERY = 'query';
+
+ /**
+ * sink: (resource|string|StreamInterface) Where the data of the
+ * response is written to. Defaults to a PHP temp stream. Providing a
+ * string will write data to a file by the given name.
+ */
+ public const SINK = 'sink';
+
+ /**
+ * synchronous: (bool) Set to true to inform HTTP handlers that you intend
+ * on waiting on the response. This can be useful for optimizations. Note
+ * that a promise is still returned if you are using one of the async
+ * client methods.
+ */
+ public const SYNCHRONOUS = 'synchronous';
+
+ /**
+ * ssl_key: (array|string) Specify the path to a file containing a private
+ * SSL key in PEM format. If a password is required, then set to an array
+ * containing the path to the SSL key in the first array element followed
+ * by the password required for the certificate in the second element.
+ */
+ public const SSL_KEY = 'ssl_key';
+
+ /**
+ * stream: Set to true to attempt to stream a response rather than
+ * download it all up-front.
+ */
+ public const STREAM = 'stream';
+
+ /**
+ * verify: (bool|string, default=true) Describes the SSL certificate
+ * verification behavior of a request. Set to true to enable SSL
+ * certificate verification using the system CA bundle when available
+ * (the default). Set to false to disable certificate verification (this
+ * is insecure!). Set to a string to provide the path to a CA bundle on
+ * disk to enable verification using a custom certificate.
+ */
+ public const VERIFY = 'verify';
+
+ /**
+ * timeout: (float, default=0) Float describing the timeout of the
+ * request in seconds. Use 0 to wait indefinitely (the default behavior).
+ */
+ public const TIMEOUT = 'timeout';
+
+ /**
+ * read_timeout: (float, default=default_socket_timeout ini setting) Float describing
+ * the body read timeout, for stream requests.
+ */
+ public const READ_TIMEOUT = 'read_timeout';
+
+ /**
+ * version: (float) Specifies the HTTP protocol version to attempt to use.
+ */
+ public const VERSION = 'version';
+
+ /**
+ * force_ip_resolve: (bool) Force client to use only ipv4 or ipv6 protocol
+ */
+ public const FORCE_IP_RESOLVE = 'force_ip_resolve';
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RetryMiddleware.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RetryMiddleware.php
new file mode 100644
index 0000000..0236a9d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/RetryMiddleware.php
@@ -0,0 +1,116 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Promise as P;
+use GuzzleHttp\Promise\PromiseInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+/**
+ * Middleware that retries requests based on the boolean result of
+ * invoking the provided "decider" function.
+ *
+ * @final
+ */
+class RetryMiddleware
+{
+ /**
+ * @var callable(RequestInterface, array): PromiseInterface
+ */
+ private $nextHandler;
+
+ /**
+ * @var callable
+ */
+ private $decider;
+
+ /**
+ * @var callable(int)
+ */
+ private $delay;
+
+ /**
+ * @param callable $decider Function that accepts the number of retries,
+ * a request, [response], and [exception] and
+ * returns true if the request is to be
+ * retried.
+ * @param callable(RequestInterface, array): PromiseInterface $nextHandler Next handler to invoke.
+ * @param (callable(int): int)|null $delay Function that accepts the number of retries
+ * and returns the number of
+ * milliseconds to delay.
+ */
+ public function __construct(callable $decider, callable $nextHandler, callable $delay = null)
+ {
+ $this->decider = $decider;
+ $this->nextHandler = $nextHandler;
+ $this->delay = $delay ?: __CLASS__ . '::exponentialDelay';
+ }
+
+ /**
+ * Default exponential backoff delay function.
+ *
+ * @return int milliseconds.
+ */
+ public static function exponentialDelay(int $retries): int
+ {
+ return (int) \pow(2, $retries - 1) * 1000;
+ }
+
+ public function __invoke(RequestInterface $request, array $options): PromiseInterface
+ {
+ if (!isset($options['retries'])) {
+ $options['retries'] = 0;
+ }
+
+ $fn = $this->nextHandler;
+ return $fn($request, $options)
+ ->then(
+ $this->onFulfilled($request, $options),
+ $this->onRejected($request, $options)
+ );
+ }
+
+ /**
+ * Execute fulfilled closure
+ */
+ private function onFulfilled(RequestInterface $request, array $options): callable
+ {
+ return function ($value) use ($request, $options) {
+ if (!($this->decider)(
+ $options['retries'],
+ $request,
+ $value,
+ null
+ )) {
+ return $value;
+ }
+ return $this->doRetry($request, $options, $value);
+ };
+ }
+
+ /**
+ * Execute rejected closure
+ */
+ private function onRejected(RequestInterface $req, array $options): callable
+ {
+ return function ($reason) use ($req, $options) {
+ if (!($this->decider)(
+ $options['retries'],
+ $req,
+ null,
+ $reason
+ )) {
+ return P\Create::rejectionFor($reason);
+ }
+ return $this->doRetry($req, $options);
+ };
+ }
+
+ private function doRetry(RequestInterface $request, array $options, ResponseInterface $response = null): PromiseInterface
+ {
+ $options['delay'] = ($this->delay)(++$options['retries'], $response, $request);
+
+ return $this($request, $options);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/TransferStats.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/TransferStats.php
new file mode 100644
index 0000000..93fa334
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/TransferStats.php
@@ -0,0 +1,133 @@
+<?php
+
+namespace GuzzleHttp;
+
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Represents data at the point after it was transferred either successfully
+ * or after a network error.
+ */
+final class TransferStats
+{
+ /**
+ * @var RequestInterface
+ */
+ private $request;
+
+ /**
+ * @var ResponseInterface|null
+ */
+ private $response;
+
+ /**
+ * @var float|null
+ */
+ private $transferTime;
+
+ /**
+ * @var array
+ */
+ private $handlerStats;
+
+ /**
+ * @var mixed|null
+ */
+ private $handlerErrorData;
+
+ /**
+ * @param RequestInterface $request Request that was sent.
+ * @param ResponseInterface|null $response Response received (if any)
+ * @param float|null $transferTime Total handler transfer time.
+ * @param mixed $handlerErrorData Handler error data.
+ * @param array $handlerStats Handler specific stats.
+ */
+ public function __construct(
+ RequestInterface $request,
+ ?ResponseInterface $response = null,
+ ?float $transferTime = null,
+ $handlerErrorData = null,
+ array $handlerStats = []
+ ) {
+ $this->request = $request;
+ $this->response = $response;
+ $this->transferTime = $transferTime;
+ $this->handlerErrorData = $handlerErrorData;
+ $this->handlerStats = $handlerStats;
+ }
+
+ public function getRequest(): RequestInterface
+ {
+ return $this->request;
+ }
+
+ /**
+ * Returns the response that was received (if any).
+ */
+ public function getResponse(): ?ResponseInterface
+ {
+ return $this->response;
+ }
+
+ /**
+ * Returns true if a response was received.
+ */
+ public function hasResponse(): bool
+ {
+ return $this->response !== null;
+ }
+
+ /**
+ * Gets handler specific error data.
+ *
+ * This might be an exception, a integer representing an error code, or
+ * anything else. Relying on this value assumes that you know what handler
+ * you are using.
+ *
+ * @return mixed
+ */
+ public function getHandlerErrorData()
+ {
+ return $this->handlerErrorData;
+ }
+
+ /**
+ * Get the effective URI the request was sent to.
+ */
+ public function getEffectiveUri(): UriInterface
+ {
+ return $this->request->getUri();
+ }
+
+ /**
+ * Get the estimated time the request was being transferred by the handler.
+ *
+ * @return float|null Time in seconds.
+ */
+ public function getTransferTime(): ?float
+ {
+ return $this->transferTime;
+ }
+
+ /**
+ * Gets an array of all of the handler specific transfer data.
+ */
+ public function getHandlerStats(): array
+ {
+ return $this->handlerStats;
+ }
+
+ /**
+ * Get a specific handler statistic from the handler by name.
+ *
+ * @param string $stat Handler specific transfer stat to retrieve.
+ *
+ * @return mixed|null
+ */
+ public function getHandlerStat(string $stat)
+ {
+ return $this->handlerStats[$stat] ?? null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Utils.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Utils.php
new file mode 100644
index 0000000..e355f32
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/Utils.php
@@ -0,0 +1,385 @@
+<?php
+
+namespace GuzzleHttp;
+
+use GuzzleHttp\Exception\InvalidArgumentException;
+use GuzzleHttp\Handler\CurlHandler;
+use GuzzleHttp\Handler\CurlMultiHandler;
+use GuzzleHttp\Handler\Proxy;
+use GuzzleHttp\Handler\StreamHandler;
+use Psr\Http\Message\UriInterface;
+
+final class Utils
+{
+ /**
+ * Debug function used to describe the provided value type and class.
+ *
+ * @param mixed $input
+ *
+ * @return string Returns a string containing the type of the variable and
+ * if a class is provided, the class name.
+ */
+ public static function describeType($input): string
+ {
+ switch (\gettype($input)) {
+ case 'object':
+ return 'object(' . \get_class($input) . ')';
+ case 'array':
+ return 'array(' . \count($input) . ')';
+ default:
+ \ob_start();
+ \var_dump($input);
+ // normalize float vs double
+ /** @var string $varDumpContent */
+ $varDumpContent = \ob_get_clean();
+
+ return \str_replace('double(', 'float(', \rtrim($varDumpContent));
+ }
+ }
+
+ /**
+ * Parses an array of header lines into an associative array of headers.
+ *
+ * @param iterable $lines Header lines array of strings in the following
+ * format: "Name: Value"
+ */
+ public static function headersFromLines(iterable $lines): array
+ {
+ $headers = [];
+
+ foreach ($lines as $line) {
+ $parts = \explode(':', $line, 2);
+ $headers[\trim($parts[0])][] = isset($parts[1]) ? \trim($parts[1]) : null;
+ }
+
+ return $headers;
+ }
+
+ /**
+ * Returns a debug stream based on the provided variable.
+ *
+ * @param mixed $value Optional value
+ *
+ * @return resource
+ */
+ public static function debugResource($value = null)
+ {
+ if (\is_resource($value)) {
+ return $value;
+ }
+ if (\defined('STDOUT')) {
+ return \STDOUT;
+ }
+
+ return \GuzzleHttp\Psr7\Utils::tryFopen('php://output', 'w');
+ }
+
+ /**
+ * Chooses and creates a default handler to use based on the environment.
+ *
+ * The returned handler is not wrapped by any default middlewares.
+ *
+ * @throws \RuntimeException if no viable Handler is available.
+ *
+ * @return callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the best handler for the given system.
+ */
+ public static function chooseHandler(): callable
+ {
+ $handler = null;
+
+ if (\defined('CURLOPT_CUSTOMREQUEST')) {
+ if (\function_exists('curl_multi_exec') && \function_exists('curl_exec')) {
+ $handler = Proxy::wrapSync(new CurlMultiHandler(), new CurlHandler());
+ } elseif (\function_exists('curl_exec')) {
+ $handler = new CurlHandler();
+ } elseif (\function_exists('curl_multi_exec')) {
+ $handler = new CurlMultiHandler();
+ }
+ }
+
+ if (\ini_get('allow_url_fopen')) {
+ $handler = $handler
+ ? Proxy::wrapStreaming($handler, new StreamHandler())
+ : new StreamHandler();
+ } elseif (!$handler) {
+ throw new \RuntimeException('GuzzleHttp requires cURL, the allow_url_fopen ini setting, or a custom HTTP handler.');
+ }
+
+ return $handler;
+ }
+
+ /**
+ * Get the default User-Agent string to use with Guzzle.
+ */
+ public static function defaultUserAgent(): string
+ {
+ return sprintf('GuzzleHttp/%d', ClientInterface::MAJOR_VERSION);
+ }
+
+ /**
+ * Returns the default cacert bundle for the current system.
+ *
+ * First, the openssl.cafile and curl.cainfo php.ini settings are checked.
+ * If those settings are not configured, then the common locations for
+ * bundles found on Red Hat, CentOS, Fedora, Ubuntu, Debian, FreeBSD, OS X
+ * and Windows are checked. If any of these file locations are found on
+ * disk, they will be utilized.
+ *
+ * Note: the result of this function is cached for subsequent calls.
+ *
+ * @throws \RuntimeException if no bundle can be found.
+ *
+ * @deprecated Utils::defaultCaBundle will be removed in guzzlehttp/guzzle:8.0. This method is not needed in PHP 5.6+.
+ */
+ public static function defaultCaBundle(): string
+ {
+ static $cached = null;
+ static $cafiles = [
+ // Red Hat, CentOS, Fedora (provided by the ca-certificates package)
+ '/etc/pki/tls/certs/ca-bundle.crt',
+ // Ubuntu, Debian (provided by the ca-certificates package)
+ '/etc/ssl/certs/ca-certificates.crt',
+ // FreeBSD (provided by the ca_root_nss package)
+ '/usr/local/share/certs/ca-root-nss.crt',
+ // SLES 12 (provided by the ca-certificates package)
+ '/var/lib/ca-certificates/ca-bundle.pem',
+ // OS X provided by homebrew (using the default path)
+ '/usr/local/etc/openssl/cert.pem',
+ // Google app engine
+ '/etc/ca-certificates.crt',
+ // Windows?
+ 'C:\\windows\\system32\\curl-ca-bundle.crt',
+ 'C:\\windows\\curl-ca-bundle.crt',
+ ];
+
+ if ($cached) {
+ return $cached;
+ }
+
+ if ($ca = \ini_get('openssl.cafile')) {
+ return $cached = $ca;
+ }
+
+ if ($ca = \ini_get('curl.cainfo')) {
+ return $cached = $ca;
+ }
+
+ foreach ($cafiles as $filename) {
+ if (\file_exists($filename)) {
+ return $cached = $filename;
+ }
+ }
+
+ throw new \RuntimeException(
+ <<< EOT
+No system CA bundle could be found in any of the the common system locations.
+PHP versions earlier than 5.6 are not properly configured to use the system's
+CA bundle by default. In order to verify peer certificates, you will need to
+supply the path on disk to a certificate bundle to the 'verify' request
+option: http://docs.guzzlephp.org/en/latest/clients.html#verify. If you do not
+need a specific certificate bundle, then Mozilla provides a commonly used CA
+bundle which can be downloaded here (provided by the maintainer of cURL):
+https://curl.haxx.se/ca/cacert.pem. Once
+you have a CA bundle available on disk, you can set the 'openssl.cafile' PHP
+ini setting to point to the path to the file, allowing you to omit the 'verify'
+request option. See https://curl.haxx.se/docs/sslcerts.html for more
+information.
+EOT
+ );
+ }
+
+ /**
+ * Creates an associative array of lowercase header names to the actual
+ * header casing.
+ */
+ public static function normalizeHeaderKeys(array $headers): array
+ {
+ $result = [];
+ foreach (\array_keys($headers) as $key) {
+ $result[\strtolower($key)] = $key;
+ }
+
+ return $result;
+ }
+
+ /**
+ * Returns true if the provided host matches any of the no proxy areas.
+ *
+ * This method will strip a port from the host if it is present. Each pattern
+ * can be matched with an exact match (e.g., "foo.com" == "foo.com") or a
+ * partial match: (e.g., "foo.com" == "baz.foo.com" and ".foo.com" ==
+ * "baz.foo.com", but ".foo.com" != "foo.com").
+ *
+ * Areas are matched in the following cases:
+ * 1. "*" (without quotes) always matches any hosts.
+ * 2. An exact match.
+ * 3. The area starts with "." and the area is the last part of the host. e.g.
+ * '.mit.edu' will match any host that ends with '.mit.edu'.
+ *
+ * @param string $host Host to check against the patterns.
+ * @param string[] $noProxyArray An array of host patterns.
+ *
+ * @throws InvalidArgumentException
+ */
+ public static function isHostInNoProxy(string $host, array $noProxyArray): bool
+ {
+ if (\strlen($host) === 0) {
+ throw new InvalidArgumentException('Empty host provided');
+ }
+
+ // Strip port if present.
+ [$host] = \explode(':', $host, 2);
+
+ foreach ($noProxyArray as $area) {
+ // Always match on wildcards.
+ if ($area === '*') {
+ return true;
+ }
+
+ if (empty($area)) {
+ // Don't match on empty values.
+ continue;
+ }
+
+ if ($area === $host) {
+ // Exact matches.
+ return true;
+ }
+ // Special match if the area when prefixed with ".". Remove any
+ // existing leading "." and add a new leading ".".
+ $area = '.' . \ltrim($area, '.');
+ if (\substr($host, -(\strlen($area))) === $area) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Wrapper for json_decode that throws when an error occurs.
+ *
+ * @param string $json JSON data to parse
+ * @param bool $assoc When true, returned objects will be converted
+ * into associative arrays.
+ * @param int $depth User specified recursion depth.
+ * @param int $options Bitmask of JSON decode options.
+ *
+ * @return object|array|string|int|float|bool|null
+ *
+ * @throws InvalidArgumentException if the JSON cannot be decoded.
+ *
+ * @link https://www.php.net/manual/en/function.json-decode.php
+ */
+ public static function jsonDecode(string $json, bool $assoc = false, int $depth = 512, int $options = 0)
+ {
+ $data = \json_decode($json, $assoc, $depth, $options);
+ if (\JSON_ERROR_NONE !== \json_last_error()) {
+ throw new InvalidArgumentException('json_decode error: ' . \json_last_error_msg());
+ }
+
+ return $data;
+ }
+
+ /**
+ * Wrapper for JSON encoding that throws when an error occurs.
+ *
+ * @param mixed $value The value being encoded
+ * @param int $options JSON encode option bitmask
+ * @param int $depth Set the maximum depth. Must be greater than zero.
+ *
+ * @throws InvalidArgumentException if the JSON cannot be encoded.
+ *
+ * @link https://www.php.net/manual/en/function.json-encode.php
+ */
+ public static function jsonEncode($value, int $options = 0, int $depth = 512): string
+ {
+ $json = \json_encode($value, $options, $depth);
+ if (\JSON_ERROR_NONE !== \json_last_error()) {
+ throw new InvalidArgumentException('json_encode error: ' . \json_last_error_msg());
+ }
+
+ /** @var string */
+ return $json;
+ }
+
+ /**
+ * Wrapper for the hrtime() or microtime() functions
+ * (depending on the PHP version, one of the two is used)
+ *
+ * @return float UNIX timestamp
+ *
+ * @internal
+ */
+ public static function currentTime(): float
+ {
+ return (float) \function_exists('hrtime') ? \hrtime(true) / 1e9 : \microtime(true);
+ }
+
+ /**
+ * @throws InvalidArgumentException
+ *
+ * @internal
+ */
+ public static function idnUriConvert(UriInterface $uri, int $options = 0): UriInterface
+ {
+ if ($uri->getHost()) {
+ $asciiHost = self::idnToAsci($uri->getHost(), $options, $info);
+ if ($asciiHost === false) {
+ $errorBitSet = $info['errors'] ?? 0;
+
+ $errorConstants = array_filter(array_keys(get_defined_constants()), static function (string $name): bool {
+ return substr($name, 0, 11) === 'IDNA_ERROR_';
+ });
+
+ $errors = [];
+ foreach ($errorConstants as $errorConstant) {
+ if ($errorBitSet & constant($errorConstant)) {
+ $errors[] = $errorConstant;
+ }
+ }
+
+ $errorMessage = 'IDN conversion failed';
+ if ($errors) {
+ $errorMessage .= ' (errors: ' . implode(', ', $errors) . ')';
+ }
+
+ throw new InvalidArgumentException($errorMessage);
+ }
+ if ($uri->getHost() !== $asciiHost) {
+ // Replace URI only if the ASCII version is different
+ $uri = $uri->withHost($asciiHost);
+ }
+ }
+
+ return $uri;
+ }
+
+ /**
+ * @internal
+ */
+ public static function getenv(string $name): ?string
+ {
+ if (isset($_SERVER[$name])) {
+ return (string) $_SERVER[$name];
+ }
+
+ if (\PHP_SAPI === 'cli' && ($value = \getenv($name)) !== false && $value !== null) {
+ return (string) $value;
+ }
+
+ return null;
+ }
+
+ /**
+ * @return string|false
+ */
+ private static function idnToAsci(string $domain, int $options, ?array &$info = [])
+ {
+ if (\function_exists('idn_to_ascii') && \defined('INTL_IDNA_VARIANT_UTS46')) {
+ return \idn_to_ascii($domain, $options, \INTL_IDNA_VARIANT_UTS46, $info);
+ }
+
+ throw new \Error('ext-idn or symfony/polyfill-intl-idn not loaded or too old');
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/functions.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/functions.php
new file mode 100644
index 0000000..a70d2cb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/functions.php
@@ -0,0 +1,167 @@
+<?php
+
+namespace GuzzleHttp;
+
+/**
+ * Debug function used to describe the provided value type and class.
+ *
+ * @param mixed $input Any type of variable to describe the type of. This
+ * parameter misses a typehint because of that.
+ *
+ * @return string Returns a string containing the type of the variable and
+ * if a class is provided, the class name.
+ *
+ * @deprecated describe_type will be removed in guzzlehttp/guzzle:8.0. Use Utils::describeType instead.
+ */
+function describe_type($input): string
+{
+ return Utils::describeType($input);
+}
+
+/**
+ * Parses an array of header lines into an associative array of headers.
+ *
+ * @param iterable $lines Header lines array of strings in the following
+ * format: "Name: Value"
+ *
+ * @deprecated headers_from_lines will be removed in guzzlehttp/guzzle:8.0. Use Utils::headersFromLines instead.
+ */
+function headers_from_lines(iterable $lines): array
+{
+ return Utils::headersFromLines($lines);
+}
+
+/**
+ * Returns a debug stream based on the provided variable.
+ *
+ * @param mixed $value Optional value
+ *
+ * @return resource
+ *
+ * @deprecated debug_resource will be removed in guzzlehttp/guzzle:8.0. Use Utils::debugResource instead.
+ */
+function debug_resource($value = null)
+{
+ return Utils::debugResource($value);
+}
+
+/**
+ * Chooses and creates a default handler to use based on the environment.
+ *
+ * The returned handler is not wrapped by any default middlewares.
+ *
+ * @throws \RuntimeException if no viable Handler is available.
+ *
+ * @return callable(\Psr\Http\Message\RequestInterface, array): \GuzzleHttp\Promise\PromiseInterface Returns the best handler for the given system.
+ *
+ * @deprecated choose_handler will be removed in guzzlehttp/guzzle:8.0. Use Utils::chooseHandler instead.
+ */
+function choose_handler(): callable
+{
+ return Utils::chooseHandler();
+}
+
+/**
+ * Get the default User-Agent string to use with Guzzle.
+ *
+ * @deprecated default_user_agent will be removed in guzzlehttp/guzzle:8.0. Use Utils::defaultUserAgent instead.
+ */
+function default_user_agent(): string
+{
+ return Utils::defaultUserAgent();
+}
+
+/**
+ * Returns the default cacert bundle for the current system.
+ *
+ * First, the openssl.cafile and curl.cainfo php.ini settings are checked.
+ * If those settings are not configured, then the common locations for
+ * bundles found on Red Hat, CentOS, Fedora, Ubuntu, Debian, FreeBSD, OS X
+ * and Windows are checked. If any of these file locations are found on
+ * disk, they will be utilized.
+ *
+ * Note: the result of this function is cached for subsequent calls.
+ *
+ * @throws \RuntimeException if no bundle can be found.
+ *
+ * @deprecated default_ca_bundle will be removed in guzzlehttp/guzzle:8.0. This function is not needed in PHP 5.6+.
+ */
+function default_ca_bundle(): string
+{
+ return Utils::defaultCaBundle();
+}
+
+/**
+ * Creates an associative array of lowercase header names to the actual
+ * header casing.
+ *
+ * @deprecated normalize_header_keys will be removed in guzzlehttp/guzzle:8.0. Use Utils::normalizeHeaderKeys instead.
+ */
+function normalize_header_keys(array $headers): array
+{
+ return Utils::normalizeHeaderKeys($headers);
+}
+
+/**
+ * Returns true if the provided host matches any of the no proxy areas.
+ *
+ * This method will strip a port from the host if it is present. Each pattern
+ * can be matched with an exact match (e.g., "foo.com" == "foo.com") or a
+ * partial match: (e.g., "foo.com" == "baz.foo.com" and ".foo.com" ==
+ * "baz.foo.com", but ".foo.com" != "foo.com").
+ *
+ * Areas are matched in the following cases:
+ * 1. "*" (without quotes) always matches any hosts.
+ * 2. An exact match.
+ * 3. The area starts with "." and the area is the last part of the host. e.g.
+ * '.mit.edu' will match any host that ends with '.mit.edu'.
+ *
+ * @param string $host Host to check against the patterns.
+ * @param string[] $noProxyArray An array of host patterns.
+ *
+ * @throws Exception\InvalidArgumentException
+ *
+ * @deprecated is_host_in_noproxy will be removed in guzzlehttp/guzzle:8.0. Use Utils::isHostInNoProxy instead.
+ */
+function is_host_in_noproxy(string $host, array $noProxyArray): bool
+{
+ return Utils::isHostInNoProxy($host, $noProxyArray);
+}
+
+/**
+ * Wrapper for json_decode that throws when an error occurs.
+ *
+ * @param string $json JSON data to parse
+ * @param bool $assoc When true, returned objects will be converted
+ * into associative arrays.
+ * @param int $depth User specified recursion depth.
+ * @param int $options Bitmask of JSON decode options.
+ *
+ * @return object|array|string|int|float|bool|null
+ *
+ * @throws Exception\InvalidArgumentException if the JSON cannot be decoded.
+ *
+ * @link https://www.php.net/manual/en/function.json-decode.php
+ * @deprecated json_decode will be removed in guzzlehttp/guzzle:8.0. Use Utils::jsonDecode instead.
+ */
+function json_decode(string $json, bool $assoc = false, int $depth = 512, int $options = 0)
+{
+ return Utils::jsonDecode($json, $assoc, $depth, $options);
+}
+
+/**
+ * Wrapper for JSON encoding that throws when an error occurs.
+ *
+ * @param mixed $value The value being encoded
+ * @param int $options JSON encode option bitmask
+ * @param int $depth Set the maximum depth. Must be greater than zero.
+ *
+ * @throws Exception\InvalidArgumentException if the JSON cannot be encoded.
+ *
+ * @link https://www.php.net/manual/en/function.json-encode.php
+ * @deprecated json_encode will be removed in guzzlehttp/guzzle:8.0. Use Utils::jsonEncode instead.
+ */
+function json_encode($value, int $options = 0, int $depth = 512): string
+{
+ return Utils::jsonEncode($value, $options, $depth);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/functions_include.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/functions_include.php
new file mode 100644
index 0000000..6636a42
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/guzzle/src/functions_include.php
@@ -0,0 +1,6 @@
+<?php
+
+// Don't redefine the functions if included multiple times.
+if (!\function_exists('GuzzleHttp\describe_type')) {
+ require __DIR__ . '/functions.php';
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/CHANGELOG.md
new file mode 100644
index 0000000..253282e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/CHANGELOG.md
@@ -0,0 +1,110 @@
+# CHANGELOG
+
+## 1.5.2 - 2022-08-07
+
+### Changed
+
+- Officially support PHP 8.2
+
+## 1.5.1 - 2021-10-22
+
+### Fixed
+
+- Revert "Call handler when waiting on fulfilled/rejected Promise"
+- Fix pool memory leak when empty array of promises provided
+
+## 1.5.0 - 2021-10-07
+
+### Changed
+
+- Call handler when waiting on fulfilled/rejected Promise
+- Officially support PHP 8.1
+
+### Fixed
+
+- Fix manually settle promises generated with `Utils::task`
+
+## 1.4.1 - 2021-02-18
+
+### Fixed
+
+- Fixed `each_limit` skipping promises and failing
+
+## 1.4.0 - 2020-09-30
+
+### Added
+
+- Support for PHP 8
+- Optional `$recursive` flag to `all`
+- Replaced functions by static methods
+
+### Fixed
+
+- Fix empty `each` processing
+- Fix promise handling for Iterators of non-unique keys
+- Fixed `method_exists` crashes on PHP 8
+- Memory leak on exceptions
+
+
+## 1.3.1 - 2016-12-20
+
+### Fixed
+
+- `wait()` foreign promise compatibility
+
+
+## 1.3.0 - 2016-11-18
+
+### Added
+
+- Adds support for custom task queues.
+
+### Fixed
+
+- Fixed coroutine promise memory leak.
+
+
+## 1.2.0 - 2016-05-18
+
+### Changed
+
+- Update to now catch `\Throwable` on PHP 7+
+
+
+## 1.1.0 - 2016-03-07
+
+### Changed
+
+- Update EachPromise to prevent recurring on a iterator when advancing, as this
+ could trigger fatal generator errors.
+- Update Promise to allow recursive waiting without unwrapping exceptions.
+
+
+## 1.0.3 - 2015-10-15
+
+### Changed
+
+- Update EachPromise to immediately resolve when the underlying promise iterator
+ is empty. Previously, such a promise would throw an exception when its `wait`
+ function was called.
+
+
+## 1.0.2 - 2015-05-15
+
+### Changed
+
+- Conditionally require functions.php.
+
+
+## 1.0.1 - 2015-06-24
+
+### Changed
+
+- Updating EachPromise to call next on the underlying promise iterator as late
+ as possible to ensure that generators that generate new requests based on
+ callbacks are not iterated until after callbacks are invoked.
+
+
+## 1.0.0 - 2015-05-12
+
+- Initial release
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/LICENSE
new file mode 100644
index 0000000..9f0f943
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/LICENSE
@@ -0,0 +1,24 @@
+The MIT License (MIT)
+
+Copyright (c) 2015 Michael Dowling <mtdowling@gmail.com>
+Copyright (c) 2015 Graham Campbell <hello@gjcampbell.co.uk>
+Copyright (c) 2017 Tobias Schultze <webmaster@tubo-world.de>
+Copyright (c) 2020 Tobias Nyholm <tobias.nyholm@gmail.com>
+
+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/guzzlehttp/promises/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/README.md
new file mode 100644
index 0000000..1ea667a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/README.md
@@ -0,0 +1,546 @@
+# Guzzle Promises
+
+[Promises/A+](https://promisesaplus.com/) implementation that handles promise
+chaining and resolution iteratively, allowing for "infinite" promise chaining
+while keeping the stack size constant. Read [this blog post](https://blog.domenic.me/youre-missing-the-point-of-promises/)
+for a general introduction to promises.
+
+- [Features](#features)
+- [Quick start](#quick-start)
+- [Synchronous wait](#synchronous-wait)
+- [Cancellation](#cancellation)
+- [API](#api)
+ - [Promise](#promise)
+ - [FulfilledPromise](#fulfilledpromise)
+ - [RejectedPromise](#rejectedpromise)
+- [Promise interop](#promise-interop)
+- [Implementation notes](#implementation-notes)
+
+
+## Features
+
+- [Promises/A+](https://promisesaplus.com/) implementation.
+- Promise resolution and chaining is handled iteratively, allowing for
+ "infinite" promise chaining.
+- Promises have a synchronous `wait` method.
+- Promises can be cancelled.
+- Works with any object that has a `then` function.
+- C# style async/await coroutine promises using
+ `GuzzleHttp\Promise\Coroutine::of()`.
+
+
+## Quick Start
+
+A *promise* represents the eventual result of an asynchronous operation. The
+primary way of interacting with a promise is through its `then` method, which
+registers callbacks to receive either a promise's eventual value or the reason
+why the promise cannot be fulfilled.
+
+### Callbacks
+
+Callbacks are registered with the `then` method by providing an optional
+`$onFulfilled` followed by an optional `$onRejected` function.
+
+
+```php
+use GuzzleHttp\Promise\Promise;
+
+$promise = new Promise();
+$promise->then(
+ // $onFulfilled
+ function ($value) {
+ echo 'The promise was fulfilled.';
+ },
+ // $onRejected
+ function ($reason) {
+ echo 'The promise was rejected.';
+ }
+);
+```
+
+*Resolving* a promise means that you either fulfill a promise with a *value* or
+reject a promise with a *reason*. Resolving a promise triggers callbacks
+registered with the promise's `then` method. These callbacks are triggered
+only once and in the order in which they were added.
+
+### Resolving a Promise
+
+Promises are fulfilled using the `resolve($value)` method. Resolving a promise
+with any value other than a `GuzzleHttp\Promise\RejectedPromise` will trigger
+all of the onFulfilled callbacks (resolving a promise with a rejected promise
+will reject the promise and trigger the `$onRejected` callbacks).
+
+```php
+use GuzzleHttp\Promise\Promise;
+
+$promise = new Promise();
+$promise
+ ->then(function ($value) {
+ // Return a value and don't break the chain
+ return "Hello, " . $value;
+ })
+ // This then is executed after the first then and receives the value
+ // returned from the first then.
+ ->then(function ($value) {
+ echo $value;
+ });
+
+// Resolving the promise triggers the $onFulfilled callbacks and outputs
+// "Hello, reader."
+$promise->resolve('reader.');
+```
+
+### Promise Forwarding
+
+Promises can be chained one after the other. Each then in the chain is a new
+promise. The return value of a promise is what's forwarded to the next
+promise in the chain. Returning a promise in a `then` callback will cause the
+subsequent promises in the chain to only be fulfilled when the returned promise
+has been fulfilled. The next promise in the chain will be invoked with the
+resolved value of the promise.
+
+```php
+use GuzzleHttp\Promise\Promise;
+
+$promise = new Promise();
+$nextPromise = new Promise();
+
+$promise
+ ->then(function ($value) use ($nextPromise) {
+ echo $value;
+ return $nextPromise;
+ })
+ ->then(function ($value) {
+ echo $value;
+ });
+
+// Triggers the first callback and outputs "A"
+$promise->resolve('A');
+// Triggers the second callback and outputs "B"
+$nextPromise->resolve('B');
+```
+
+### Promise Rejection
+
+When a promise is rejected, the `$onRejected` callbacks are invoked with the
+rejection reason.
+
+```php
+use GuzzleHttp\Promise\Promise;
+
+$promise = new Promise();
+$promise->then(null, function ($reason) {
+ echo $reason;
+});
+
+$promise->reject('Error!');
+// Outputs "Error!"
+```
+
+### Rejection Forwarding
+
+If an exception is thrown in an `$onRejected` callback, subsequent
+`$onRejected` callbacks are invoked with the thrown exception as the reason.
+
+```php
+use GuzzleHttp\Promise\Promise;
+
+$promise = new Promise();
+$promise->then(null, function ($reason) {
+ throw new Exception($reason);
+})->then(null, function ($reason) {
+ assert($reason->getMessage() === 'Error!');
+});
+
+$promise->reject('Error!');
+```
+
+You can also forward a rejection down the promise chain by returning a
+`GuzzleHttp\Promise\RejectedPromise` in either an `$onFulfilled` or
+`$onRejected` callback.
+
+```php
+use GuzzleHttp\Promise\Promise;
+use GuzzleHttp\Promise\RejectedPromise;
+
+$promise = new Promise();
+$promise->then(null, function ($reason) {
+ return new RejectedPromise($reason);
+})->then(null, function ($reason) {
+ assert($reason === 'Error!');
+});
+
+$promise->reject('Error!');
+```
+
+If an exception is not thrown in a `$onRejected` callback and the callback
+does not return a rejected promise, downstream `$onFulfilled` callbacks are
+invoked using the value returned from the `$onRejected` callback.
+
+```php
+use GuzzleHttp\Promise\Promise;
+
+$promise = new Promise();
+$promise
+ ->then(null, function ($reason) {
+ return "It's ok";
+ })
+ ->then(function ($value) {
+ assert($value === "It's ok");
+ });
+
+$promise->reject('Error!');
+```
+
+
+## Synchronous Wait
+
+You can synchronously force promises to complete using a promise's `wait`
+method. When creating a promise, you can provide a wait function that is used
+to synchronously force a promise to complete. When a wait function is invoked
+it is expected to deliver a value to the promise or reject the promise. If the
+wait function does not deliver a value, then an exception is thrown. The wait
+function provided to a promise constructor is invoked when the `wait` function
+of the promise is called.
+
+```php
+$promise = new Promise(function () use (&$promise) {
+ $promise->resolve('foo');
+});
+
+// Calling wait will return the value of the promise.
+echo $promise->wait(); // outputs "foo"
+```
+
+If an exception is encountered while invoking the wait function of a promise,
+the promise is rejected with the exception and the exception is thrown.
+
+```php
+$promise = new Promise(function () use (&$promise) {
+ throw new Exception('foo');
+});
+
+$promise->wait(); // throws the exception.
+```
+
+Calling `wait` on a promise that has been fulfilled will not trigger the wait
+function. It will simply return the previously resolved value.
+
+```php
+$promise = new Promise(function () { die('this is not called!'); });
+$promise->resolve('foo');
+echo $promise->wait(); // outputs "foo"
+```
+
+Calling `wait` on a promise that has been rejected will throw an exception. If
+the rejection reason is an instance of `\Exception` the reason is thrown.
+Otherwise, a `GuzzleHttp\Promise\RejectionException` is thrown and the reason
+can be obtained by calling the `getReason` method of the exception.
+
+```php
+$promise = new Promise();
+$promise->reject('foo');
+$promise->wait();
+```
+
+> PHP Fatal error: Uncaught exception 'GuzzleHttp\Promise\RejectionException' with message 'The promise was rejected with value: foo'
+
+### Unwrapping a Promise
+
+When synchronously waiting on a promise, you are joining the state of the
+promise into the current state of execution (i.e., return the value of the
+promise if it was fulfilled or throw an exception if it was rejected). This is
+called "unwrapping" the promise. Waiting on a promise will by default unwrap
+the promise state.
+
+You can force a promise to resolve and *not* unwrap the state of the promise
+by passing `false` to the first argument of the `wait` function:
+
+```php
+$promise = new Promise();
+$promise->reject('foo');
+// This will not throw an exception. It simply ensures the promise has
+// been resolved.
+$promise->wait(false);
+```
+
+When unwrapping a promise, the resolved value of the promise will be waited
+upon until the unwrapped value is not a promise. This means that if you resolve
+promise A with a promise B and unwrap promise A, the value returned by the
+wait function will be the value delivered to promise B.
+
+**Note**: when you do not unwrap the promise, no value is returned.
+
+
+## Cancellation
+
+You can cancel a promise that has not yet been fulfilled using the `cancel()`
+method of a promise. When creating a promise you can provide an optional
+cancel function that when invoked cancels the action of computing a resolution
+of the promise.
+
+
+## API
+
+### Promise
+
+When creating a promise object, you can provide an optional `$waitFn` and
+`$cancelFn`. `$waitFn` is a function that is invoked with no arguments and is
+expected to resolve the promise. `$cancelFn` is a function with no arguments
+that is expected to cancel the computation of a promise. It is invoked when the
+`cancel()` method of a promise is called.
+
+```php
+use GuzzleHttp\Promise\Promise;
+
+$promise = new Promise(
+ function () use (&$promise) {
+ $promise->resolve('waited');
+ },
+ function () {
+ // do something that will cancel the promise computation (e.g., close
+ // a socket, cancel a database query, etc...)
+ }
+);
+
+assert('waited' === $promise->wait());
+```
+
+A promise has the following methods:
+
+- `then(callable $onFulfilled, callable $onRejected) : PromiseInterface`
+
+ Appends fulfillment and rejection handlers to the promise, and returns a new promise resolving to the return value of the called handler.
+
+- `otherwise(callable $onRejected) : PromiseInterface`
+
+ Appends a rejection handler callback to the promise, and returns a new promise resolving to the return value of the callback if it is called, or to its original fulfillment value if the promise is instead fulfilled.
+
+- `wait($unwrap = true) : mixed`
+
+ Synchronously waits on the promise to complete.
+
+ `$unwrap` controls whether or not the value of the promise is returned for a
+ fulfilled promise or if an exception is thrown if the promise is rejected.
+ This is set to `true` by default.
+
+- `cancel()`
+
+ Attempts to cancel the promise if possible. The promise being cancelled and
+ the parent most ancestor that has not yet been resolved will also be
+ cancelled. Any promises waiting on the cancelled promise to resolve will also
+ be cancelled.
+
+- `getState() : string`
+
+ Returns the state of the promise. One of `pending`, `fulfilled`, or
+ `rejected`.
+
+- `resolve($value)`
+
+ Fulfills the promise with the given `$value`.
+
+- `reject($reason)`
+
+ Rejects the promise with the given `$reason`.
+
+
+### FulfilledPromise
+
+A fulfilled promise can be created to represent a promise that has been
+fulfilled.
+
+```php
+use GuzzleHttp\Promise\FulfilledPromise;
+
+$promise = new FulfilledPromise('value');
+
+// Fulfilled callbacks are immediately invoked.
+$promise->then(function ($value) {
+ echo $value;
+});
+```
+
+
+### RejectedPromise
+
+A rejected promise can be created to represent a promise that has been
+rejected.
+
+```php
+use GuzzleHttp\Promise\RejectedPromise;
+
+$promise = new RejectedPromise('Error');
+
+// Rejected callbacks are immediately invoked.
+$promise->then(null, function ($reason) {
+ echo $reason;
+});
+```
+
+
+## Promise Interoperability
+
+This library works with foreign promises that have a `then` method. This means
+you can use Guzzle promises with [React promises](https://github.com/reactphp/promise)
+for example. When a foreign promise is returned inside of a then method
+callback, promise resolution will occur recursively.
+
+```php
+// Create a React promise
+$deferred = new React\Promise\Deferred();
+$reactPromise = $deferred->promise();
+
+// Create a Guzzle promise that is fulfilled with a React promise.
+$guzzlePromise = new GuzzleHttp\Promise\Promise();
+$guzzlePromise->then(function ($value) use ($reactPromise) {
+ // Do something something with the value...
+ // Return the React promise
+ return $reactPromise;
+});
+```
+
+Please note that wait and cancel chaining is no longer possible when forwarding
+a foreign promise. You will need to wrap a third-party promise with a Guzzle
+promise in order to utilize wait and cancel functions with foreign promises.
+
+
+### Event Loop Integration
+
+In order to keep the stack size constant, Guzzle promises are resolved
+asynchronously using a task queue. When waiting on promises synchronously, the
+task queue will be automatically run to ensure that the blocking promise and
+any forwarded promises are resolved. When using promises asynchronously in an
+event loop, you will need to run the task queue on each tick of the loop. If
+you do not run the task queue, then promises will not be resolved.
+
+You can run the task queue using the `run()` method of the global task queue
+instance.
+
+```php
+// Get the global task queue
+$queue = GuzzleHttp\Promise\Utils::queue();
+$queue->run();
+```
+
+For example, you could use Guzzle promises with React using a periodic timer:
+
+```php
+$loop = React\EventLoop\Factory::create();
+$loop->addPeriodicTimer(0, [$queue, 'run']);
+```
+
+*TODO*: Perhaps adding a `futureTick()` on each tick would be faster?
+
+
+## Implementation Notes
+
+### Promise Resolution and Chaining is Handled Iteratively
+
+By shuffling pending handlers from one owner to another, promises are
+resolved iteratively, allowing for "infinite" then chaining.
+
+```php
+<?php
+require 'vendor/autoload.php';
+
+use GuzzleHttp\Promise\Promise;
+
+$parent = new Promise();
+$p = $parent;
+
+for ($i = 0; $i < 1000; $i++) {
+ $p = $p->then(function ($v) {
+ // The stack size remains constant (a good thing)
+ echo xdebug_get_stack_depth() . ', ';
+ return $v + 1;
+ });
+}
+
+$parent->resolve(0);
+var_dump($p->wait()); // int(1000)
+
+```
+
+When a promise is fulfilled or rejected with a non-promise value, the promise
+then takes ownership of the handlers of each child promise and delivers values
+down the chain without using recursion.
+
+When a promise is resolved with another promise, the original promise transfers
+all of its pending handlers to the new promise. When the new promise is
+eventually resolved, all of the pending handlers are delivered the forwarded
+value.
+
+### A Promise is the Deferred
+
+Some promise libraries implement promises using a deferred object to represent
+a computation and a promise object to represent the delivery of the result of
+the computation. This is a nice separation of computation and delivery because
+consumers of the promise cannot modify the value that will be eventually
+delivered.
+
+One side effect of being able to implement promise resolution and chaining
+iteratively is that you need to be able for one promise to reach into the state
+of another promise to shuffle around ownership of handlers. In order to achieve
+this without making the handlers of a promise publicly mutable, a promise is
+also the deferred value, allowing promises of the same parent class to reach
+into and modify the private properties of promises of the same type. While this
+does allow consumers of the value to modify the resolution or rejection of the
+deferred, it is a small price to pay for keeping the stack size constant.
+
+```php
+$promise = new Promise();
+$promise->then(function ($value) { echo $value; });
+// The promise is the deferred value, so you can deliver a value to it.
+$promise->resolve('foo');
+// prints "foo"
+```
+
+
+## Upgrading from Function API
+
+A static API was first introduced in 1.4.0, in order to mitigate problems with
+functions conflicting between global and local copies of the package. The
+function API will be removed in 2.0.0. A migration table has been provided here
+for your convenience:
+
+| Original Function | Replacement Method |
+|----------------|----------------|
+| `queue` | `Utils::queue` |
+| `task` | `Utils::task` |
+| `promise_for` | `Create::promiseFor` |
+| `rejection_for` | `Create::rejectionFor` |
+| `exception_for` | `Create::exceptionFor` |
+| `iter_for` | `Create::iterFor` |
+| `inspect` | `Utils::inspect` |
+| `inspect_all` | `Utils::inspectAll` |
+| `unwrap` | `Utils::unwrap` |
+| `all` | `Utils::all` |
+| `some` | `Utils::some` |
+| `any` | `Utils::any` |
+| `settle` | `Utils::settle` |
+| `each` | `Each::of` |
+| `each_limit` | `Each::ofLimit` |
+| `each_limit_all` | `Each::ofLimitAll` |
+| `!is_fulfilled` | `Is::pending` |
+| `is_fulfilled` | `Is::fulfilled` |
+| `is_rejected` | `Is::rejected` |
+| `is_settled` | `Is::settled` |
+| `coroutine` | `Coroutine::of` |
+
+
+## Security
+
+If you discover a security vulnerability within this package, please send an email to security@tidelift.com. All security vulnerabilities will be promptly addressed. Please do not disclose security-related issues publicly until a fix has been announced. Please see [Security Policy](https://github.com/guzzle/promises/security/policy) for more information.
+
+
+## License
+
+Guzzle is made available under the MIT License (MIT). Please see [License File](LICENSE) for more information.
+
+
+## For Enterprise
+
+Available as part of the Tidelift Subscription
+
+The maintainers of Guzzle and thousands of other packages are working with Tidelift to deliver commercial support and maintenance for the open source dependencies you use to build your applications. Save time, reduce risk, and improve code health, while paying the maintainers of the exact dependencies you use. [Learn more.](https://tidelift.com/subscription/pkg/packagist-guzzlehttp-promises?utm_source=packagist-guzzlehttp-promises&utm_medium=referral&utm_campaign=enterprise&utm_term=repo)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/composer.json
new file mode 100644
index 0000000..c959fb3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/composer.json
@@ -0,0 +1,58 @@
+{
+ "name": "guzzlehttp/promises",
+ "description": "Guzzle promises library",
+ "keywords": ["promise"],
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ }
+ ],
+ "require": {
+ "php": ">=5.5"
+ },
+ "require-dev": {
+ "symfony/phpunit-bridge": "^4.4 || ^5.1"
+ },
+ "autoload": {
+ "psr-4": {
+ "GuzzleHttp\\Promise\\": "src/"
+ },
+ "files": ["src/functions_include.php"]
+ },
+ "autoload-dev": {
+ "psr-4": {
+ "GuzzleHttp\\Promise\\Tests\\": "tests/"
+ }
+ },
+ "scripts": {
+ "test": "vendor/bin/simple-phpunit",
+ "test-ci": "vendor/bin/simple-phpunit --coverage-text"
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.5-dev"
+ }
+ },
+ "config": {
+ "preferred-install": "dist",
+ "sort-packages": true
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/AggregateException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/AggregateException.php
new file mode 100644
index 0000000..d2b5712
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/AggregateException.php
@@ -0,0 +1,17 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * Exception thrown when too many errors occur in the some() or any() methods.
+ */
+class AggregateException extends RejectionException
+{
+ public function __construct($msg, array $reasons)
+ {
+ parent::__construct(
+ $reasons,
+ sprintf('%s; %d rejected promises', $msg, count($reasons))
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/CancellationException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/CancellationException.php
new file mode 100644
index 0000000..56a1ed6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/CancellationException.php
@@ -0,0 +1,10 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * Exception that is set as the reason for a promise that has been cancelled.
+ */
+class CancellationException extends RejectionException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Coroutine.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Coroutine.php
new file mode 100644
index 0000000..670da47
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Coroutine.php
@@ -0,0 +1,169 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+use Exception;
+use Generator;
+use Throwable;
+
+/**
+ * Creates a promise that is resolved using a generator that yields values or
+ * promises (somewhat similar to C#'s async keyword).
+ *
+ * When called, the Coroutine::of method will start an instance of the generator
+ * and returns a promise that is fulfilled with its final yielded value.
+ *
+ * Control is returned back to the generator when the yielded promise settles.
+ * This can lead to less verbose code when doing lots of sequential async calls
+ * with minimal processing in between.
+ *
+ * use GuzzleHttp\Promise;
+ *
+ * function createPromise($value) {
+ * return new Promise\FulfilledPromise($value);
+ * }
+ *
+ * $promise = Promise\Coroutine::of(function () {
+ * $value = (yield createPromise('a'));
+ * try {
+ * $value = (yield createPromise($value . 'b'));
+ * } catch (\Exception $e) {
+ * // The promise was rejected.
+ * }
+ * yield $value . 'c';
+ * });
+ *
+ * // Outputs "abc"
+ * $promise->then(function ($v) { echo $v; });
+ *
+ * @param callable $generatorFn Generator function to wrap into a promise.
+ *
+ * @return Promise
+ *
+ * @link https://github.com/petkaantonov/bluebird/blob/master/API.md#generators inspiration
+ */
+final class Coroutine implements PromiseInterface
+{
+ /**
+ * @var PromiseInterface|null
+ */
+ private $currentPromise;
+
+ /**
+ * @var Generator
+ */
+ private $generator;
+
+ /**
+ * @var Promise
+ */
+ private $result;
+
+ public function __construct(callable $generatorFn)
+ {
+ $this->generator = $generatorFn();
+ $this->result = new Promise(function () {
+ while (isset($this->currentPromise)) {
+ $this->currentPromise->wait();
+ }
+ });
+ try {
+ $this->nextCoroutine($this->generator->current());
+ } catch (\Exception $exception) {
+ $this->result->reject($exception);
+ } catch (Throwable $throwable) {
+ $this->result->reject($throwable);
+ }
+ }
+
+ /**
+ * Create a new coroutine.
+ *
+ * @return self
+ */
+ public static function of(callable $generatorFn)
+ {
+ return new self($generatorFn);
+ }
+
+ public function then(
+ callable $onFulfilled = null,
+ callable $onRejected = null
+ ) {
+ return $this->result->then($onFulfilled, $onRejected);
+ }
+
+ public function otherwise(callable $onRejected)
+ {
+ return $this->result->otherwise($onRejected);
+ }
+
+ public function wait($unwrap = true)
+ {
+ return $this->result->wait($unwrap);
+ }
+
+ public function getState()
+ {
+ return $this->result->getState();
+ }
+
+ public function resolve($value)
+ {
+ $this->result->resolve($value);
+ }
+
+ public function reject($reason)
+ {
+ $this->result->reject($reason);
+ }
+
+ public function cancel()
+ {
+ $this->currentPromise->cancel();
+ $this->result->cancel();
+ }
+
+ private function nextCoroutine($yielded)
+ {
+ $this->currentPromise = Create::promiseFor($yielded)
+ ->then([$this, '_handleSuccess'], [$this, '_handleFailure']);
+ }
+
+ /**
+ * @internal
+ */
+ public function _handleSuccess($value)
+ {
+ unset($this->currentPromise);
+ try {
+ $next = $this->generator->send($value);
+ if ($this->generator->valid()) {
+ $this->nextCoroutine($next);
+ } else {
+ $this->result->resolve($value);
+ }
+ } catch (Exception $exception) {
+ $this->result->reject($exception);
+ } catch (Throwable $throwable) {
+ $this->result->reject($throwable);
+ }
+ }
+
+ /**
+ * @internal
+ */
+ public function _handleFailure($reason)
+ {
+ unset($this->currentPromise);
+ try {
+ $nextYield = $this->generator->throw(Create::exceptionFor($reason));
+ // The throw was caught, so keep iterating on the coroutine
+ $this->nextCoroutine($nextYield);
+ } catch (Exception $exception) {
+ $this->result->reject($exception);
+ } catch (Throwable $throwable) {
+ $this->result->reject($throwable);
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Create.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Create.php
new file mode 100644
index 0000000..8d038e9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Create.php
@@ -0,0 +1,84 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+final class Create
+{
+ /**
+ * Creates a promise for a value if the value is not a promise.
+ *
+ * @param mixed $value Promise or value.
+ *
+ * @return PromiseInterface
+ */
+ public static function promiseFor($value)
+ {
+ if ($value instanceof PromiseInterface) {
+ return $value;
+ }
+
+ // Return a Guzzle promise that shadows the given promise.
+ if (is_object($value) && method_exists($value, 'then')) {
+ $wfn = method_exists($value, 'wait') ? [$value, 'wait'] : null;
+ $cfn = method_exists($value, 'cancel') ? [$value, 'cancel'] : null;
+ $promise = new Promise($wfn, $cfn);
+ $value->then([$promise, 'resolve'], [$promise, 'reject']);
+ return $promise;
+ }
+
+ return new FulfilledPromise($value);
+ }
+
+ /**
+ * Creates a rejected promise for a reason if the reason is not a promise.
+ * If the provided reason is a promise, then it is returned as-is.
+ *
+ * @param mixed $reason Promise or reason.
+ *
+ * @return PromiseInterface
+ */
+ public static function rejectionFor($reason)
+ {
+ if ($reason instanceof PromiseInterface) {
+ return $reason;
+ }
+
+ return new RejectedPromise($reason);
+ }
+
+ /**
+ * Create an exception for a rejected promise value.
+ *
+ * @param mixed $reason
+ *
+ * @return \Exception|\Throwable
+ */
+ public static function exceptionFor($reason)
+ {
+ if ($reason instanceof \Exception || $reason instanceof \Throwable) {
+ return $reason;
+ }
+
+ return new RejectionException($reason);
+ }
+
+ /**
+ * Returns an iterator for the given value.
+ *
+ * @param mixed $value
+ *
+ * @return \Iterator
+ */
+ public static function iterFor($value)
+ {
+ if ($value instanceof \Iterator) {
+ return $value;
+ }
+
+ if (is_array($value)) {
+ return new \ArrayIterator($value);
+ }
+
+ return new \ArrayIterator([$value]);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Each.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Each.php
new file mode 100644
index 0000000..1dda354
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Each.php
@@ -0,0 +1,90 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+final class Each
+{
+ /**
+ * Given an iterator that yields promises or values, returns a promise that
+ * is fulfilled with a null value when the iterator has been consumed or
+ * the aggregate promise has been fulfilled or rejected.
+ *
+ * $onFulfilled is a function that accepts the fulfilled value, iterator
+ * index, and the aggregate promise. The callback can invoke any necessary
+ * side effects and choose to resolve or reject the aggregate if needed.
+ *
+ * $onRejected is a function that accepts the rejection reason, iterator
+ * index, and the aggregate promise. The callback can invoke any necessary
+ * side effects and choose to resolve or reject the aggregate if needed.
+ *
+ * @param mixed $iterable Iterator or array to iterate over.
+ * @param callable $onFulfilled
+ * @param callable $onRejected
+ *
+ * @return PromiseInterface
+ */
+ public static function of(
+ $iterable,
+ callable $onFulfilled = null,
+ callable $onRejected = null
+ ) {
+ return (new EachPromise($iterable, [
+ 'fulfilled' => $onFulfilled,
+ 'rejected' => $onRejected
+ ]))->promise();
+ }
+
+ /**
+ * Like of, but only allows a certain number of outstanding promises at any
+ * given time.
+ *
+ * $concurrency may be an integer or a function that accepts the number of
+ * pending promises and returns a numeric concurrency limit value to allow
+ * for dynamic a concurrency size.
+ *
+ * @param mixed $iterable
+ * @param int|callable $concurrency
+ * @param callable $onFulfilled
+ * @param callable $onRejected
+ *
+ * @return PromiseInterface
+ */
+ public static function ofLimit(
+ $iterable,
+ $concurrency,
+ callable $onFulfilled = null,
+ callable $onRejected = null
+ ) {
+ return (new EachPromise($iterable, [
+ 'fulfilled' => $onFulfilled,
+ 'rejected' => $onRejected,
+ 'concurrency' => $concurrency
+ ]))->promise();
+ }
+
+ /**
+ * Like limit, but ensures that no promise in the given $iterable argument
+ * is rejected. If any promise is rejected, then the aggregate promise is
+ * rejected with the encountered rejection.
+ *
+ * @param mixed $iterable
+ * @param int|callable $concurrency
+ * @param callable $onFulfilled
+ *
+ * @return PromiseInterface
+ */
+ public static function ofLimitAll(
+ $iterable,
+ $concurrency,
+ callable $onFulfilled = null
+ ) {
+ return each_limit(
+ $iterable,
+ $concurrency,
+ $onFulfilled,
+ function ($reason, $idx, PromiseInterface $aggregate) {
+ $aggregate->reject($reason);
+ }
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/EachPromise.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/EachPromise.php
new file mode 100644
index 0000000..280d799
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/EachPromise.php
@@ -0,0 +1,247 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * Represents a promise that iterates over many promises and invokes
+ * side-effect functions in the process.
+ */
+class EachPromise implements PromisorInterface
+{
+ private $pending = [];
+
+ private $nextPendingIndex = 0;
+
+ /** @var \Iterator|null */
+ private $iterable;
+
+ /** @var callable|int|null */
+ private $concurrency;
+
+ /** @var callable|null */
+ private $onFulfilled;
+
+ /** @var callable|null */
+ private $onRejected;
+
+ /** @var Promise|null */
+ private $aggregate;
+
+ /** @var bool|null */
+ private $mutex;
+
+ /**
+ * Configuration hash can include the following key value pairs:
+ *
+ * - fulfilled: (callable) Invoked when a promise fulfills. The function
+ * is invoked with three arguments: the fulfillment value, the index
+ * position from the iterable list of the promise, and the aggregate
+ * promise that manages all of the promises. The aggregate promise may
+ * be resolved from within the callback to short-circuit the promise.
+ * - rejected: (callable) Invoked when a promise is rejected. The
+ * function is invoked with three arguments: the rejection reason, the
+ * index position from the iterable list of the promise, and the
+ * aggregate promise that manages all of the promises. The aggregate
+ * promise may be resolved from within the callback to short-circuit
+ * the promise.
+ * - concurrency: (integer) Pass this configuration option to limit the
+ * allowed number of outstanding concurrently executing promises,
+ * creating a capped pool of promises. There is no limit by default.
+ *
+ * @param mixed $iterable Promises or values to iterate.
+ * @param array $config Configuration options
+ */
+ public function __construct($iterable, array $config = [])
+ {
+ $this->iterable = Create::iterFor($iterable);
+
+ if (isset($config['concurrency'])) {
+ $this->concurrency = $config['concurrency'];
+ }
+
+ if (isset($config['fulfilled'])) {
+ $this->onFulfilled = $config['fulfilled'];
+ }
+
+ if (isset($config['rejected'])) {
+ $this->onRejected = $config['rejected'];
+ }
+ }
+
+ /** @psalm-suppress InvalidNullableReturnType */
+ public function promise()
+ {
+ if ($this->aggregate) {
+ return $this->aggregate;
+ }
+
+ try {
+ $this->createPromise();
+ /** @psalm-assert Promise $this->aggregate */
+ $this->iterable->rewind();
+ $this->refillPending();
+ } catch (\Throwable $e) {
+ $this->aggregate->reject($e);
+ } catch (\Exception $e) {
+ $this->aggregate->reject($e);
+ }
+
+ /**
+ * @psalm-suppress NullableReturnStatement
+ * @phpstan-ignore-next-line
+ */
+ return $this->aggregate;
+ }
+
+ private function createPromise()
+ {
+ $this->mutex = false;
+ $this->aggregate = new Promise(function () {
+ if ($this->checkIfFinished()) {
+ return;
+ }
+ reset($this->pending);
+ // Consume a potentially fluctuating list of promises while
+ // ensuring that indexes are maintained (precluding array_shift).
+ while ($promise = current($this->pending)) {
+ next($this->pending);
+ $promise->wait();
+ if (Is::settled($this->aggregate)) {
+ return;
+ }
+ }
+ });
+
+ // Clear the references when the promise is resolved.
+ $clearFn = function () {
+ $this->iterable = $this->concurrency = $this->pending = null;
+ $this->onFulfilled = $this->onRejected = null;
+ $this->nextPendingIndex = 0;
+ };
+
+ $this->aggregate->then($clearFn, $clearFn);
+ }
+
+ private function refillPending()
+ {
+ if (!$this->concurrency) {
+ // Add all pending promises.
+ while ($this->addPending() && $this->advanceIterator());
+ return;
+ }
+
+ // Add only up to N pending promises.
+ $concurrency = is_callable($this->concurrency)
+ ? call_user_func($this->concurrency, count($this->pending))
+ : $this->concurrency;
+ $concurrency = max($concurrency - count($this->pending), 0);
+ // Concurrency may be set to 0 to disallow new promises.
+ if (!$concurrency) {
+ return;
+ }
+ // Add the first pending promise.
+ $this->addPending();
+ // Note this is special handling for concurrency=1 so that we do
+ // not advance the iterator after adding the first promise. This
+ // helps work around issues with generators that might not have the
+ // next value to yield until promise callbacks are called.
+ while (--$concurrency
+ && $this->advanceIterator()
+ && $this->addPending());
+ }
+
+ private function addPending()
+ {
+ if (!$this->iterable || !$this->iterable->valid()) {
+ return false;
+ }
+
+ $promise = Create::promiseFor($this->iterable->current());
+ $key = $this->iterable->key();
+
+ // Iterable keys may not be unique, so we use a counter to
+ // guarantee uniqueness
+ $idx = $this->nextPendingIndex++;
+
+ $this->pending[$idx] = $promise->then(
+ function ($value) use ($idx, $key) {
+ if ($this->onFulfilled) {
+ call_user_func(
+ $this->onFulfilled,
+ $value,
+ $key,
+ $this->aggregate
+ );
+ }
+ $this->step($idx);
+ },
+ function ($reason) use ($idx, $key) {
+ if ($this->onRejected) {
+ call_user_func(
+ $this->onRejected,
+ $reason,
+ $key,
+ $this->aggregate
+ );
+ }
+ $this->step($idx);
+ }
+ );
+
+ return true;
+ }
+
+ private function advanceIterator()
+ {
+ // Place a lock on the iterator so that we ensure to not recurse,
+ // preventing fatal generator errors.
+ if ($this->mutex) {
+ return false;
+ }
+
+ $this->mutex = true;
+
+ try {
+ $this->iterable->next();
+ $this->mutex = false;
+ return true;
+ } catch (\Throwable $e) {
+ $this->aggregate->reject($e);
+ $this->mutex = false;
+ return false;
+ } catch (\Exception $e) {
+ $this->aggregate->reject($e);
+ $this->mutex = false;
+ return false;
+ }
+ }
+
+ private function step($idx)
+ {
+ // If the promise was already resolved, then ignore this step.
+ if (Is::settled($this->aggregate)) {
+ return;
+ }
+
+ unset($this->pending[$idx]);
+
+ // Only refill pending promises if we are not locked, preventing the
+ // EachPromise to recursively invoke the provided iterator, which
+ // cause a fatal error: "Cannot resume an already running generator"
+ if ($this->advanceIterator() && !$this->checkIfFinished()) {
+ // Add more pending promises if possible.
+ $this->refillPending();
+ }
+ }
+
+ private function checkIfFinished()
+ {
+ if (!$this->pending && !$this->iterable->valid()) {
+ // Resolve the promise if there's nothing left to do.
+ $this->aggregate->resolve(null);
+ return true;
+ }
+
+ return false;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/FulfilledPromise.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/FulfilledPromise.php
new file mode 100644
index 0000000..98f72a6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/FulfilledPromise.php
@@ -0,0 +1,84 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * A promise that has been fulfilled.
+ *
+ * Thenning off of this promise will invoke the onFulfilled callback
+ * immediately and ignore other callbacks.
+ */
+class FulfilledPromise implements PromiseInterface
+{
+ private $value;
+
+ public function __construct($value)
+ {
+ if (is_object($value) && method_exists($value, 'then')) {
+ throw new \InvalidArgumentException(
+ 'You cannot create a FulfilledPromise with a promise.'
+ );
+ }
+
+ $this->value = $value;
+ }
+
+ public function then(
+ callable $onFulfilled = null,
+ callable $onRejected = null
+ ) {
+ // Return itself if there is no onFulfilled function.
+ if (!$onFulfilled) {
+ return $this;
+ }
+
+ $queue = Utils::queue();
+ $p = new Promise([$queue, 'run']);
+ $value = $this->value;
+ $queue->add(static function () use ($p, $value, $onFulfilled) {
+ if (Is::pending($p)) {
+ try {
+ $p->resolve($onFulfilled($value));
+ } catch (\Throwable $e) {
+ $p->reject($e);
+ } catch (\Exception $e) {
+ $p->reject($e);
+ }
+ }
+ });
+
+ return $p;
+ }
+
+ public function otherwise(callable $onRejected)
+ {
+ return $this->then(null, $onRejected);
+ }
+
+ public function wait($unwrap = true, $defaultDelivery = null)
+ {
+ return $unwrap ? $this->value : null;
+ }
+
+ public function getState()
+ {
+ return self::FULFILLED;
+ }
+
+ public function resolve($value)
+ {
+ if ($value !== $this->value) {
+ throw new \LogicException("Cannot resolve a fulfilled promise");
+ }
+ }
+
+ public function reject($reason)
+ {
+ throw new \LogicException("Cannot reject a fulfilled promise");
+ }
+
+ public function cancel()
+ {
+ // pass
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Is.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Is.php
new file mode 100644
index 0000000..c3ed8d0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Is.php
@@ -0,0 +1,46 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+final class Is
+{
+ /**
+ * Returns true if a promise is pending.
+ *
+ * @return bool
+ */
+ public static function pending(PromiseInterface $promise)
+ {
+ return $promise->getState() === PromiseInterface::PENDING;
+ }
+
+ /**
+ * Returns true if a promise is fulfilled or rejected.
+ *
+ * @return bool
+ */
+ public static function settled(PromiseInterface $promise)
+ {
+ return $promise->getState() !== PromiseInterface::PENDING;
+ }
+
+ /**
+ * Returns true if a promise is fulfilled.
+ *
+ * @return bool
+ */
+ public static function fulfilled(PromiseInterface $promise)
+ {
+ return $promise->getState() === PromiseInterface::FULFILLED;
+ }
+
+ /**
+ * Returns true if a promise is rejected.
+ *
+ * @return bool
+ */
+ public static function rejected(PromiseInterface $promise)
+ {
+ return $promise->getState() === PromiseInterface::REJECTED;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Promise.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Promise.php
new file mode 100644
index 0000000..7593905
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Promise.php
@@ -0,0 +1,278 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * Promises/A+ implementation that avoids recursion when possible.
+ *
+ * @link https://promisesaplus.com/
+ */
+class Promise implements PromiseInterface
+{
+ private $state = self::PENDING;
+ private $result;
+ private $cancelFn;
+ private $waitFn;
+ private $waitList;
+ private $handlers = [];
+
+ /**
+ * @param callable $waitFn Fn that when invoked resolves the promise.
+ * @param callable $cancelFn Fn that when invoked cancels the promise.
+ */
+ public function __construct(
+ callable $waitFn = null,
+ callable $cancelFn = null
+ ) {
+ $this->waitFn = $waitFn;
+ $this->cancelFn = $cancelFn;
+ }
+
+ public function then(
+ callable $onFulfilled = null,
+ callable $onRejected = null
+ ) {
+ if ($this->state === self::PENDING) {
+ $p = new Promise(null, [$this, 'cancel']);
+ $this->handlers[] = [$p, $onFulfilled, $onRejected];
+ $p->waitList = $this->waitList;
+ $p->waitList[] = $this;
+ return $p;
+ }
+
+ // Return a fulfilled promise and immediately invoke any callbacks.
+ if ($this->state === self::FULFILLED) {
+ $promise = Create::promiseFor($this->result);
+ return $onFulfilled ? $promise->then($onFulfilled) : $promise;
+ }
+
+ // It's either cancelled or rejected, so return a rejected promise
+ // and immediately invoke any callbacks.
+ $rejection = Create::rejectionFor($this->result);
+ return $onRejected ? $rejection->then(null, $onRejected) : $rejection;
+ }
+
+ public function otherwise(callable $onRejected)
+ {
+ return $this->then(null, $onRejected);
+ }
+
+ public function wait($unwrap = true)
+ {
+ $this->waitIfPending();
+
+ if ($this->result instanceof PromiseInterface) {
+ return $this->result->wait($unwrap);
+ }
+ if ($unwrap) {
+ if ($this->state === self::FULFILLED) {
+ return $this->result;
+ }
+ // It's rejected so "unwrap" and throw an exception.
+ throw Create::exceptionFor($this->result);
+ }
+ }
+
+ public function getState()
+ {
+ return $this->state;
+ }
+
+ public function cancel()
+ {
+ if ($this->state !== self::PENDING) {
+ return;
+ }
+
+ $this->waitFn = $this->waitList = null;
+
+ if ($this->cancelFn) {
+ $fn = $this->cancelFn;
+ $this->cancelFn = null;
+ try {
+ $fn();
+ } catch (\Throwable $e) {
+ $this->reject($e);
+ } catch (\Exception $e) {
+ $this->reject($e);
+ }
+ }
+
+ // Reject the promise only if it wasn't rejected in a then callback.
+ /** @psalm-suppress RedundantCondition */
+ if ($this->state === self::PENDING) {
+ $this->reject(new CancellationException('Promise has been cancelled'));
+ }
+ }
+
+ public function resolve($value)
+ {
+ $this->settle(self::FULFILLED, $value);
+ }
+
+ public function reject($reason)
+ {
+ $this->settle(self::REJECTED, $reason);
+ }
+
+ private function settle($state, $value)
+ {
+ if ($this->state !== self::PENDING) {
+ // Ignore calls with the same resolution.
+ if ($state === $this->state && $value === $this->result) {
+ return;
+ }
+ throw $this->state === $state
+ ? new \LogicException("The promise is already {$state}.")
+ : new \LogicException("Cannot change a {$this->state} promise to {$state}");
+ }
+
+ if ($value === $this) {
+ throw new \LogicException('Cannot fulfill or reject a promise with itself');
+ }
+
+ // Clear out the state of the promise but stash the handlers.
+ $this->state = $state;
+ $this->result = $value;
+ $handlers = $this->handlers;
+ $this->handlers = null;
+ $this->waitList = $this->waitFn = null;
+ $this->cancelFn = null;
+
+ if (!$handlers) {
+ return;
+ }
+
+ // If the value was not a settled promise or a thenable, then resolve
+ // it in the task queue using the correct ID.
+ if (!is_object($value) || !method_exists($value, 'then')) {
+ $id = $state === self::FULFILLED ? 1 : 2;
+ // It's a success, so resolve the handlers in the queue.
+ Utils::queue()->add(static function () use ($id, $value, $handlers) {
+ foreach ($handlers as $handler) {
+ self::callHandler($id, $value, $handler);
+ }
+ });
+ } elseif ($value instanceof Promise && Is::pending($value)) {
+ // We can just merge our handlers onto the next promise.
+ $value->handlers = array_merge($value->handlers, $handlers);
+ } else {
+ // Resolve the handlers when the forwarded promise is resolved.
+ $value->then(
+ static function ($value) use ($handlers) {
+ foreach ($handlers as $handler) {
+ self::callHandler(1, $value, $handler);
+ }
+ },
+ static function ($reason) use ($handlers) {
+ foreach ($handlers as $handler) {
+ self::callHandler(2, $reason, $handler);
+ }
+ }
+ );
+ }
+ }
+
+ /**
+ * Call a stack of handlers using a specific callback index and value.
+ *
+ * @param int $index 1 (resolve) or 2 (reject).
+ * @param mixed $value Value to pass to the callback.
+ * @param array $handler Array of handler data (promise and callbacks).
+ */
+ private static function callHandler($index, $value, array $handler)
+ {
+ /** @var PromiseInterface $promise */
+ $promise = $handler[0];
+
+ // The promise may have been cancelled or resolved before placing
+ // this thunk in the queue.
+ if (Is::settled($promise)) {
+ return;
+ }
+
+ try {
+ if (isset($handler[$index])) {
+ /*
+ * If $f throws an exception, then $handler will be in the exception
+ * stack trace. Since $handler contains a reference to the callable
+ * itself we get a circular reference. We clear the $handler
+ * here to avoid that memory leak.
+ */
+ $f = $handler[$index];
+ unset($handler);
+ $promise->resolve($f($value));
+ } elseif ($index === 1) {
+ // Forward resolution values as-is.
+ $promise->resolve($value);
+ } else {
+ // Forward rejections down the chain.
+ $promise->reject($value);
+ }
+ } catch (\Throwable $reason) {
+ $promise->reject($reason);
+ } catch (\Exception $reason) {
+ $promise->reject($reason);
+ }
+ }
+
+ private function waitIfPending()
+ {
+ if ($this->state !== self::PENDING) {
+ return;
+ } elseif ($this->waitFn) {
+ $this->invokeWaitFn();
+ } elseif ($this->waitList) {
+ $this->invokeWaitList();
+ } else {
+ // If there's no wait function, then reject the promise.
+ $this->reject('Cannot wait on a promise that has '
+ . 'no internal wait function. You must provide a wait '
+ . 'function when constructing the promise to be able to '
+ . 'wait on a promise.');
+ }
+
+ Utils::queue()->run();
+
+ /** @psalm-suppress RedundantCondition */
+ if ($this->state === self::PENDING) {
+ $this->reject('Invoking the wait callback did not resolve the promise');
+ }
+ }
+
+ private function invokeWaitFn()
+ {
+ try {
+ $wfn = $this->waitFn;
+ $this->waitFn = null;
+ $wfn(true);
+ } catch (\Exception $reason) {
+ if ($this->state === self::PENDING) {
+ // The promise has not been resolved yet, so reject the promise
+ // with the exception.
+ $this->reject($reason);
+ } else {
+ // The promise was already resolved, so there's a problem in
+ // the application.
+ throw $reason;
+ }
+ }
+ }
+
+ private function invokeWaitList()
+ {
+ $waitList = $this->waitList;
+ $this->waitList = null;
+
+ foreach ($waitList as $result) {
+ do {
+ $result->waitIfPending();
+ $result = $result->result;
+ } while ($result instanceof Promise);
+
+ if ($result instanceof PromiseInterface) {
+ $result->wait(false);
+ }
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/PromiseInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/PromiseInterface.php
new file mode 100644
index 0000000..e598331
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/PromiseInterface.php
@@ -0,0 +1,97 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * A promise represents the eventual result of an asynchronous operation.
+ *
+ * The primary way of interacting with a promise is through its then method,
+ * which registers callbacks to receive either a promise’s eventual value or
+ * the reason why the promise cannot be fulfilled.
+ *
+ * @link https://promisesaplus.com/
+ */
+interface PromiseInterface
+{
+ const PENDING = 'pending';
+ const FULFILLED = 'fulfilled';
+ const REJECTED = 'rejected';
+
+ /**
+ * Appends fulfillment and rejection handlers to the promise, and returns
+ * a new promise resolving to the return value of the called handler.
+ *
+ * @param callable $onFulfilled Invoked when the promise fulfills.
+ * @param callable $onRejected Invoked when the promise is rejected.
+ *
+ * @return PromiseInterface
+ */
+ public function then(
+ callable $onFulfilled = null,
+ callable $onRejected = null
+ );
+
+ /**
+ * Appends a rejection handler callback to the promise, and returns a new
+ * promise resolving to the return value of the callback if it is called,
+ * or to its original fulfillment value if the promise is instead
+ * fulfilled.
+ *
+ * @param callable $onRejected Invoked when the promise is rejected.
+ *
+ * @return PromiseInterface
+ */
+ public function otherwise(callable $onRejected);
+
+ /**
+ * Get the state of the promise ("pending", "rejected", or "fulfilled").
+ *
+ * The three states can be checked against the constants defined on
+ * PromiseInterface: PENDING, FULFILLED, and REJECTED.
+ *
+ * @return string
+ */
+ public function getState();
+
+ /**
+ * Resolve the promise with the given value.
+ *
+ * @param mixed $value
+ *
+ * @throws \RuntimeException if the promise is already resolved.
+ */
+ public function resolve($value);
+
+ /**
+ * Reject the promise with the given reason.
+ *
+ * @param mixed $reason
+ *
+ * @throws \RuntimeException if the promise is already resolved.
+ */
+ public function reject($reason);
+
+ /**
+ * Cancels the promise if possible.
+ *
+ * @link https://github.com/promises-aplus/cancellation-spec/issues/7
+ */
+ public function cancel();
+
+ /**
+ * Waits until the promise completes if possible.
+ *
+ * Pass $unwrap as true to unwrap the result of the promise, either
+ * returning the resolved value or throwing the rejected exception.
+ *
+ * If the promise cannot be waited on, then the promise will be rejected.
+ *
+ * @param bool $unwrap
+ *
+ * @return mixed
+ *
+ * @throws \LogicException if the promise has no wait function or if the
+ * promise does not settle after waiting.
+ */
+ public function wait($unwrap = true);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/PromisorInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/PromisorInterface.php
new file mode 100644
index 0000000..2d2e342
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/PromisorInterface.php
@@ -0,0 +1,16 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * Interface used with classes that return a promise.
+ */
+interface PromisorInterface
+{
+ /**
+ * Returns a promise.
+ *
+ * @return PromiseInterface
+ */
+ public function promise();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/RejectedPromise.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/RejectedPromise.php
new file mode 100644
index 0000000..d291846
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/RejectedPromise.php
@@ -0,0 +1,91 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * A promise that has been rejected.
+ *
+ * Thenning off of this promise will invoke the onRejected callback
+ * immediately and ignore other callbacks.
+ */
+class RejectedPromise implements PromiseInterface
+{
+ private $reason;
+
+ public function __construct($reason)
+ {
+ if (is_object($reason) && method_exists($reason, 'then')) {
+ throw new \InvalidArgumentException(
+ 'You cannot create a RejectedPromise with a promise.'
+ );
+ }
+
+ $this->reason = $reason;
+ }
+
+ public function then(
+ callable $onFulfilled = null,
+ callable $onRejected = null
+ ) {
+ // If there's no onRejected callback then just return self.
+ if (!$onRejected) {
+ return $this;
+ }
+
+ $queue = Utils::queue();
+ $reason = $this->reason;
+ $p = new Promise([$queue, 'run']);
+ $queue->add(static function () use ($p, $reason, $onRejected) {
+ if (Is::pending($p)) {
+ try {
+ // Return a resolved promise if onRejected does not throw.
+ $p->resolve($onRejected($reason));
+ } catch (\Throwable $e) {
+ // onRejected threw, so return a rejected promise.
+ $p->reject($e);
+ } catch (\Exception $e) {
+ // onRejected threw, so return a rejected promise.
+ $p->reject($e);
+ }
+ }
+ });
+
+ return $p;
+ }
+
+ public function otherwise(callable $onRejected)
+ {
+ return $this->then(null, $onRejected);
+ }
+
+ public function wait($unwrap = true, $defaultDelivery = null)
+ {
+ if ($unwrap) {
+ throw Create::exceptionFor($this->reason);
+ }
+
+ return null;
+ }
+
+ public function getState()
+ {
+ return self::REJECTED;
+ }
+
+ public function resolve($value)
+ {
+ throw new \LogicException("Cannot resolve a rejected promise");
+ }
+
+ public function reject($reason)
+ {
+ if ($reason !== $this->reason) {
+ throw new \LogicException("Cannot reject a rejected promise");
+ }
+ }
+
+ public function cancel()
+ {
+ // pass
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/RejectionException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/RejectionException.php
new file mode 100644
index 0000000..e2f1377
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/RejectionException.php
@@ -0,0 +1,48 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * A special exception that is thrown when waiting on a rejected promise.
+ *
+ * The reason value is available via the getReason() method.
+ */
+class RejectionException extends \RuntimeException
+{
+ /** @var mixed Rejection reason. */
+ private $reason;
+
+ /**
+ * @param mixed $reason Rejection reason.
+ * @param string $description Optional description
+ */
+ public function __construct($reason, $description = null)
+ {
+ $this->reason = $reason;
+
+ $message = 'The promise was rejected';
+
+ if ($description) {
+ $message .= ' with reason: ' . $description;
+ } elseif (is_string($reason)
+ || (is_object($reason) && method_exists($reason, '__toString'))
+ ) {
+ $message .= ' with reason: ' . $this->reason;
+ } elseif ($reason instanceof \JsonSerializable) {
+ $message .= ' with reason: '
+ . json_encode($this->reason, JSON_PRETTY_PRINT);
+ }
+
+ parent::__construct($message);
+ }
+
+ /**
+ * Returns the rejection reason.
+ *
+ * @return mixed
+ */
+ public function getReason()
+ {
+ return $this->reason;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/TaskQueue.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/TaskQueue.php
new file mode 100644
index 0000000..f0fba2c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/TaskQueue.php
@@ -0,0 +1,67 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * A task queue that executes tasks in a FIFO order.
+ *
+ * This task queue class is used to settle promises asynchronously and
+ * maintains a constant stack size. You can use the task queue asynchronously
+ * by calling the `run()` function of the global task queue in an event loop.
+ *
+ * GuzzleHttp\Promise\Utils::queue()->run();
+ */
+class TaskQueue implements TaskQueueInterface
+{
+ private $enableShutdown = true;
+ private $queue = [];
+
+ public function __construct($withShutdown = true)
+ {
+ if ($withShutdown) {
+ register_shutdown_function(function () {
+ if ($this->enableShutdown) {
+ // Only run the tasks if an E_ERROR didn't occur.
+ $err = error_get_last();
+ if (!$err || ($err['type'] ^ E_ERROR)) {
+ $this->run();
+ }
+ }
+ });
+ }
+ }
+
+ public function isEmpty()
+ {
+ return !$this->queue;
+ }
+
+ public function add(callable $task)
+ {
+ $this->queue[] = $task;
+ }
+
+ public function run()
+ {
+ while ($task = array_shift($this->queue)) {
+ /** @var callable $task */
+ $task();
+ }
+ }
+
+ /**
+ * The task queue will be run and exhausted by default when the process
+ * exits IFF the exit is not the result of a PHP E_ERROR error.
+ *
+ * You can disable running the automatic shutdown of the queue by calling
+ * this function. If you disable the task queue shutdown process, then you
+ * MUST either run the task queue (as a result of running your event loop
+ * or manually using the run() method) or wait on each outstanding promise.
+ *
+ * Note: This shutdown will occur before any destructors are triggered.
+ */
+ public function disableShutdown()
+ {
+ $this->enableShutdown = false;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/TaskQueueInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/TaskQueueInterface.php
new file mode 100644
index 0000000..723d4d5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/TaskQueueInterface.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+interface TaskQueueInterface
+{
+ /**
+ * Returns true if the queue is empty.
+ *
+ * @return bool
+ */
+ public function isEmpty();
+
+ /**
+ * Adds a task to the queue that will be executed the next time run is
+ * called.
+ */
+ public function add(callable $task);
+
+ /**
+ * Execute all of the pending task in the queue.
+ */
+ public function run();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Utils.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Utils.php
new file mode 100644
index 0000000..8647126
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/Utils.php
@@ -0,0 +1,276 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+final class Utils
+{
+ /**
+ * Get the global task queue used for promise resolution.
+ *
+ * This task queue MUST be run in an event loop in order for promises to be
+ * settled asynchronously. It will be automatically run when synchronously
+ * waiting on a promise.
+ *
+ * <code>
+ * while ($eventLoop->isRunning()) {
+ * GuzzleHttp\Promise\Utils::queue()->run();
+ * }
+ * </code>
+ *
+ * @param TaskQueueInterface $assign Optionally specify a new queue instance.
+ *
+ * @return TaskQueueInterface
+ */
+ public static function queue(TaskQueueInterface $assign = null)
+ {
+ static $queue;
+
+ if ($assign) {
+ $queue = $assign;
+ } elseif (!$queue) {
+ $queue = new TaskQueue();
+ }
+
+ return $queue;
+ }
+
+ /**
+ * Adds a function to run in the task queue when it is next `run()` and
+ * returns a promise that is fulfilled or rejected with the result.
+ *
+ * @param callable $task Task function to run.
+ *
+ * @return PromiseInterface
+ */
+ public static function task(callable $task)
+ {
+ $queue = self::queue();
+ $promise = new Promise([$queue, 'run']);
+ $queue->add(function () use ($task, $promise) {
+ try {
+ if (Is::pending($promise)) {
+ $promise->resolve($task());
+ }
+ } catch (\Throwable $e) {
+ $promise->reject($e);
+ } catch (\Exception $e) {
+ $promise->reject($e);
+ }
+ });
+
+ return $promise;
+ }
+
+ /**
+ * Synchronously waits on a promise to resolve and returns an inspection
+ * state array.
+ *
+ * Returns a state associative array containing a "state" key mapping to a
+ * valid promise state. If the state of the promise is "fulfilled", the
+ * array will contain a "value" key mapping to the fulfilled value of the
+ * promise. If the promise is rejected, the array will contain a "reason"
+ * key mapping to the rejection reason of the promise.
+ *
+ * @param PromiseInterface $promise Promise or value.
+ *
+ * @return array
+ */
+ public static function inspect(PromiseInterface $promise)
+ {
+ try {
+ return [
+ 'state' => PromiseInterface::FULFILLED,
+ 'value' => $promise->wait()
+ ];
+ } catch (RejectionException $e) {
+ return ['state' => PromiseInterface::REJECTED, 'reason' => $e->getReason()];
+ } catch (\Throwable $e) {
+ return ['state' => PromiseInterface::REJECTED, 'reason' => $e];
+ } catch (\Exception $e) {
+ return ['state' => PromiseInterface::REJECTED, 'reason' => $e];
+ }
+ }
+
+ /**
+ * Waits on all of the provided promises, but does not unwrap rejected
+ * promises as thrown exception.
+ *
+ * Returns an array of inspection state arrays.
+ *
+ * @see inspect for the inspection state array format.
+ *
+ * @param PromiseInterface[] $promises Traversable of promises to wait upon.
+ *
+ * @return array
+ */
+ public static function inspectAll($promises)
+ {
+ $results = [];
+ foreach ($promises as $key => $promise) {
+ $results[$key] = inspect($promise);
+ }
+
+ return $results;
+ }
+
+ /**
+ * Waits on all of the provided promises and returns the fulfilled values.
+ *
+ * Returns an array that contains the value of each promise (in the same
+ * order the promises were provided). An exception is thrown if any of the
+ * promises are rejected.
+ *
+ * @param iterable<PromiseInterface> $promises Iterable of PromiseInterface objects to wait on.
+ *
+ * @return array
+ *
+ * @throws \Exception on error
+ * @throws \Throwable on error in PHP >=7
+ */
+ public static function unwrap($promises)
+ {
+ $results = [];
+ foreach ($promises as $key => $promise) {
+ $results[$key] = $promise->wait();
+ }
+
+ return $results;
+ }
+
+ /**
+ * Given an array of promises, return a promise that is fulfilled when all
+ * the items in the array are fulfilled.
+ *
+ * The promise's fulfillment value is an array with fulfillment values at
+ * respective positions to the original array. If any promise in the array
+ * rejects, the returned promise is rejected with the rejection reason.
+ *
+ * @param mixed $promises Promises or values.
+ * @param bool $recursive If true, resolves new promises that might have been added to the stack during its own resolution.
+ *
+ * @return PromiseInterface
+ */
+ public static function all($promises, $recursive = false)
+ {
+ $results = [];
+ $promise = Each::of(
+ $promises,
+ function ($value, $idx) use (&$results) {
+ $results[$idx] = $value;
+ },
+ function ($reason, $idx, Promise $aggregate) {
+ $aggregate->reject($reason);
+ }
+ )->then(function () use (&$results) {
+ ksort($results);
+ return $results;
+ });
+
+ if (true === $recursive) {
+ $promise = $promise->then(function ($results) use ($recursive, &$promises) {
+ foreach ($promises as $promise) {
+ if (Is::pending($promise)) {
+ return self::all($promises, $recursive);
+ }
+ }
+ return $results;
+ });
+ }
+
+ return $promise;
+ }
+
+ /**
+ * Initiate a competitive race between multiple promises or values (values
+ * will become immediately fulfilled promises).
+ *
+ * When count amount of promises have been fulfilled, the returned promise
+ * is fulfilled with an array that contains the fulfillment values of the
+ * winners in order of resolution.
+ *
+ * This promise is rejected with a {@see AggregateException} if the number
+ * of fulfilled promises is less than the desired $count.
+ *
+ * @param int $count Total number of promises.
+ * @param mixed $promises Promises or values.
+ *
+ * @return PromiseInterface
+ */
+ public static function some($count, $promises)
+ {
+ $results = [];
+ $rejections = [];
+
+ return Each::of(
+ $promises,
+ function ($value, $idx, PromiseInterface $p) use (&$results, $count) {
+ if (Is::settled($p)) {
+ return;
+ }
+ $results[$idx] = $value;
+ if (count($results) >= $count) {
+ $p->resolve(null);
+ }
+ },
+ function ($reason) use (&$rejections) {
+ $rejections[] = $reason;
+ }
+ )->then(
+ function () use (&$results, &$rejections, $count) {
+ if (count($results) !== $count) {
+ throw new AggregateException(
+ 'Not enough promises to fulfill count',
+ $rejections
+ );
+ }
+ ksort($results);
+ return array_values($results);
+ }
+ );
+ }
+
+ /**
+ * Like some(), with 1 as count. However, if the promise fulfills, the
+ * fulfillment value is not an array of 1 but the value directly.
+ *
+ * @param mixed $promises Promises or values.
+ *
+ * @return PromiseInterface
+ */
+ public static function any($promises)
+ {
+ return self::some(1, $promises)->then(function ($values) {
+ return $values[0];
+ });
+ }
+
+ /**
+ * Returns a promise that is fulfilled when all of the provided promises have
+ * been fulfilled or rejected.
+ *
+ * The returned promise is fulfilled with an array of inspection state arrays.
+ *
+ * @see inspect for the inspection state array format.
+ *
+ * @param mixed $promises Promises or values.
+ *
+ * @return PromiseInterface
+ */
+ public static function settle($promises)
+ {
+ $results = [];
+
+ return Each::of(
+ $promises,
+ function ($value, $idx) use (&$results) {
+ $results[$idx] = ['state' => PromiseInterface::FULFILLED, 'value' => $value];
+ },
+ function ($reason, $idx) use (&$results) {
+ $results[$idx] = ['state' => PromiseInterface::REJECTED, 'reason' => $reason];
+ }
+ )->then(function () use (&$results) {
+ ksort($results);
+ return $results;
+ });
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/functions.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/functions.php
new file mode 100644
index 0000000..c03d39d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/functions.php
@@ -0,0 +1,363 @@
+<?php
+
+namespace GuzzleHttp\Promise;
+
+/**
+ * Get the global task queue used for promise resolution.
+ *
+ * This task queue MUST be run in an event loop in order for promises to be
+ * settled asynchronously. It will be automatically run when synchronously
+ * waiting on a promise.
+ *
+ * <code>
+ * while ($eventLoop->isRunning()) {
+ * GuzzleHttp\Promise\queue()->run();
+ * }
+ * </code>
+ *
+ * @param TaskQueueInterface $assign Optionally specify a new queue instance.
+ *
+ * @return TaskQueueInterface
+ *
+ * @deprecated queue will be removed in guzzlehttp/promises:2.0. Use Utils::queue instead.
+ */
+function queue(TaskQueueInterface $assign = null)
+{
+ return Utils::queue($assign);
+}
+
+/**
+ * Adds a function to run in the task queue when it is next `run()` and returns
+ * a promise that is fulfilled or rejected with the result.
+ *
+ * @param callable $task Task function to run.
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated task will be removed in guzzlehttp/promises:2.0. Use Utils::task instead.
+ */
+function task(callable $task)
+{
+ return Utils::task($task);
+}
+
+/**
+ * Creates a promise for a value if the value is not a promise.
+ *
+ * @param mixed $value Promise or value.
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated promise_for will be removed in guzzlehttp/promises:2.0. Use Create::promiseFor instead.
+ */
+function promise_for($value)
+{
+ return Create::promiseFor($value);
+}
+
+/**
+ * Creates a rejected promise for a reason if the reason is not a promise. If
+ * the provided reason is a promise, then it is returned as-is.
+ *
+ * @param mixed $reason Promise or reason.
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated rejection_for will be removed in guzzlehttp/promises:2.0. Use Create::rejectionFor instead.
+ */
+function rejection_for($reason)
+{
+ return Create::rejectionFor($reason);
+}
+
+/**
+ * Create an exception for a rejected promise value.
+ *
+ * @param mixed $reason
+ *
+ * @return \Exception|\Throwable
+ *
+ * @deprecated exception_for will be removed in guzzlehttp/promises:2.0. Use Create::exceptionFor instead.
+ */
+function exception_for($reason)
+{
+ return Create::exceptionFor($reason);
+}
+
+/**
+ * Returns an iterator for the given value.
+ *
+ * @param mixed $value
+ *
+ * @return \Iterator
+ *
+ * @deprecated iter_for will be removed in guzzlehttp/promises:2.0. Use Create::iterFor instead.
+ */
+function iter_for($value)
+{
+ return Create::iterFor($value);
+}
+
+/**
+ * Synchronously waits on a promise to resolve and returns an inspection state
+ * array.
+ *
+ * Returns a state associative array containing a "state" key mapping to a
+ * valid promise state. If the state of the promise is "fulfilled", the array
+ * will contain a "value" key mapping to the fulfilled value of the promise. If
+ * the promise is rejected, the array will contain a "reason" key mapping to
+ * the rejection reason of the promise.
+ *
+ * @param PromiseInterface $promise Promise or value.
+ *
+ * @return array
+ *
+ * @deprecated inspect will be removed in guzzlehttp/promises:2.0. Use Utils::inspect instead.
+ */
+function inspect(PromiseInterface $promise)
+{
+ return Utils::inspect($promise);
+}
+
+/**
+ * Waits on all of the provided promises, but does not unwrap rejected promises
+ * as thrown exception.
+ *
+ * Returns an array of inspection state arrays.
+ *
+ * @see inspect for the inspection state array format.
+ *
+ * @param PromiseInterface[] $promises Traversable of promises to wait upon.
+ *
+ * @return array
+ *
+ * @deprecated inspect will be removed in guzzlehttp/promises:2.0. Use Utils::inspectAll instead.
+ */
+function inspect_all($promises)
+{
+ return Utils::inspectAll($promises);
+}
+
+/**
+ * Waits on all of the provided promises and returns the fulfilled values.
+ *
+ * Returns an array that contains the value of each promise (in the same order
+ * the promises were provided). An exception is thrown if any of the promises
+ * are rejected.
+ *
+ * @param iterable<PromiseInterface> $promises Iterable of PromiseInterface objects to wait on.
+ *
+ * @return array
+ *
+ * @throws \Exception on error
+ * @throws \Throwable on error in PHP >=7
+ *
+ * @deprecated unwrap will be removed in guzzlehttp/promises:2.0. Use Utils::unwrap instead.
+ */
+function unwrap($promises)
+{
+ return Utils::unwrap($promises);
+}
+
+/**
+ * Given an array of promises, return a promise that is fulfilled when all the
+ * items in the array are fulfilled.
+ *
+ * The promise's fulfillment value is an array with fulfillment values at
+ * respective positions to the original array. If any promise in the array
+ * rejects, the returned promise is rejected with the rejection reason.
+ *
+ * @param mixed $promises Promises or values.
+ * @param bool $recursive If true, resolves new promises that might have been added to the stack during its own resolution.
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated all will be removed in guzzlehttp/promises:2.0. Use Utils::all instead.
+ */
+function all($promises, $recursive = false)
+{
+ return Utils::all($promises, $recursive);
+}
+
+/**
+ * Initiate a competitive race between multiple promises or values (values will
+ * become immediately fulfilled promises).
+ *
+ * When count amount of promises have been fulfilled, the returned promise is
+ * fulfilled with an array that contains the fulfillment values of the winners
+ * in order of resolution.
+ *
+ * This promise is rejected with a {@see AggregateException} if the number of
+ * fulfilled promises is less than the desired $count.
+ *
+ * @param int $count Total number of promises.
+ * @param mixed $promises Promises or values.
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated some will be removed in guzzlehttp/promises:2.0. Use Utils::some instead.
+ */
+function some($count, $promises)
+{
+ return Utils::some($count, $promises);
+}
+
+/**
+ * Like some(), with 1 as count. However, if the promise fulfills, the
+ * fulfillment value is not an array of 1 but the value directly.
+ *
+ * @param mixed $promises Promises or values.
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated any will be removed in guzzlehttp/promises:2.0. Use Utils::any instead.
+ */
+function any($promises)
+{
+ return Utils::any($promises);
+}
+
+/**
+ * Returns a promise that is fulfilled when all of the provided promises have
+ * been fulfilled or rejected.
+ *
+ * The returned promise is fulfilled with an array of inspection state arrays.
+ *
+ * @see inspect for the inspection state array format.
+ *
+ * @param mixed $promises Promises or values.
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated settle will be removed in guzzlehttp/promises:2.0. Use Utils::settle instead.
+ */
+function settle($promises)
+{
+ return Utils::settle($promises);
+}
+
+/**
+ * Given an iterator that yields promises or values, returns a promise that is
+ * fulfilled with a null value when the iterator has been consumed or the
+ * aggregate promise has been fulfilled or rejected.
+ *
+ * $onFulfilled is a function that accepts the fulfilled value, iterator index,
+ * and the aggregate promise. The callback can invoke any necessary side
+ * effects and choose to resolve or reject the aggregate if needed.
+ *
+ * $onRejected is a function that accepts the rejection reason, iterator index,
+ * and the aggregate promise. The callback can invoke any necessary side
+ * effects and choose to resolve or reject the aggregate if needed.
+ *
+ * @param mixed $iterable Iterator or array to iterate over.
+ * @param callable $onFulfilled
+ * @param callable $onRejected
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated each will be removed in guzzlehttp/promises:2.0. Use Each::of instead.
+ */
+function each(
+ $iterable,
+ callable $onFulfilled = null,
+ callable $onRejected = null
+) {
+ return Each::of($iterable, $onFulfilled, $onRejected);
+}
+
+/**
+ * Like each, but only allows a certain number of outstanding promises at any
+ * given time.
+ *
+ * $concurrency may be an integer or a function that accepts the number of
+ * pending promises and returns a numeric concurrency limit value to allow for
+ * dynamic a concurrency size.
+ *
+ * @param mixed $iterable
+ * @param int|callable $concurrency
+ * @param callable $onFulfilled
+ * @param callable $onRejected
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated each_limit will be removed in guzzlehttp/promises:2.0. Use Each::ofLimit instead.
+ */
+function each_limit(
+ $iterable,
+ $concurrency,
+ callable $onFulfilled = null,
+ callable $onRejected = null
+) {
+ return Each::ofLimit($iterable, $concurrency, $onFulfilled, $onRejected);
+}
+
+/**
+ * Like each_limit, but ensures that no promise in the given $iterable argument
+ * is rejected. If any promise is rejected, then the aggregate promise is
+ * rejected with the encountered rejection.
+ *
+ * @param mixed $iterable
+ * @param int|callable $concurrency
+ * @param callable $onFulfilled
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated each_limit_all will be removed in guzzlehttp/promises:2.0. Use Each::ofLimitAll instead.
+ */
+function each_limit_all(
+ $iterable,
+ $concurrency,
+ callable $onFulfilled = null
+) {
+ return Each::ofLimitAll($iterable, $concurrency, $onFulfilled);
+}
+
+/**
+ * Returns true if a promise is fulfilled.
+ *
+ * @return bool
+ *
+ * @deprecated is_fulfilled will be removed in guzzlehttp/promises:2.0. Use Is::fulfilled instead.
+ */
+function is_fulfilled(PromiseInterface $promise)
+{
+ return Is::fulfilled($promise);
+}
+
+/**
+ * Returns true if a promise is rejected.
+ *
+ * @return bool
+ *
+ * @deprecated is_rejected will be removed in guzzlehttp/promises:2.0. Use Is::rejected instead.
+ */
+function is_rejected(PromiseInterface $promise)
+{
+ return Is::rejected($promise);
+}
+
+/**
+ * Returns true if a promise is fulfilled or rejected.
+ *
+ * @return bool
+ *
+ * @deprecated is_settled will be removed in guzzlehttp/promises:2.0. Use Is::settled instead.
+ */
+function is_settled(PromiseInterface $promise)
+{
+ return Is::settled($promise);
+}
+
+/**
+ * Create a new coroutine.
+ *
+ * @see Coroutine
+ *
+ * @return PromiseInterface
+ *
+ * @deprecated coroutine will be removed in guzzlehttp/promises:2.0. Use Coroutine::of instead.
+ */
+function coroutine(callable $generatorFn)
+{
+ return Coroutine::of($generatorFn);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/functions_include.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/functions_include.php
new file mode 100644
index 0000000..34cd171
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/promises/src/functions_include.php
@@ -0,0 +1,6 @@
+<?php
+
+// Don't redefine the functions if included multiple times.
+if (!function_exists('GuzzleHttp\Promise\promise_for')) {
+ require __DIR__ . '/functions.php';
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/CHANGELOG.md
new file mode 100644
index 0000000..49e0c12
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/CHANGELOG.md
@@ -0,0 +1,410 @@
+# Change Log
+
+All notable changes to this project will be documented in this file.
+
+The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
+and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
+
+## Unreleased
+
+## 2.4.5 - 2023-04-17
+
+### Fixed
+
+- Prevent possible warnings on unset variables in `ServerRequest::normalizeNestedFileSpec`
+- Fixed `Message::bodySummary` when `preg_match` fails
+- Fixed header validation issue
+
+## 2.4.4 - 2023-03-09
+
+### Changed
+
+- Removed the need for `AllowDynamicProperties` in `LazyOpenStream`
+
+## 2.4.3 - 2022-10-26
+
+### Changed
+
+- Replaced `sha1(uniqid())` by `bin2hex(random_bytes(20))`
+
+## 2.4.2 - 2022-10-25
+
+### Fixed
+
+- Fixed erroneous behaviour when combining host and relative path
+
+## 2.4.1 - 2022-08-28
+
+### Fixed
+
+- Rewind body before reading in `Message::bodySummary`
+
+## 2.4.0 - 2022-06-20
+
+### Added
+
+- Added provisional PHP 8.2 support
+- Added `UriComparator::isCrossOrigin` method
+
+## 2.3.0 - 2022-06-09
+
+### Fixed
+
+- Added `Header::splitList` method
+- Added `Utils::tryGetContents` method
+- Improved `Stream::getContents` method
+- Updated mimetype mappings
+
+## 2.2.2 - 2022-06-08
+
+### Fixed
+
+- Fix `Message::parseRequestUri` for numeric headers
+- Re-wrap exceptions thrown in `fread` into runtime exceptions
+- Throw an exception when multipart options is misformatted
+
+## 2.2.1 - 2022-03-20
+
+### Fixed
+
+- Correct header value validation
+
+## 2.2.0 - 2022-03-20
+
+### Added
+
+- A more compressive list of mime types
+- Add JsonSerializable to Uri
+- Missing return types
+
+### Fixed
+
+- Bug MultipartStream no `uri` metadata
+- Bug MultipartStream with filename for `data://` streams
+- Fixed new line handling in MultipartStream
+- Reduced RAM usage when copying streams
+- Updated parsing in `Header::normalize()`
+
+## 2.1.1 - 2022-03-20
+
+### Fixed
+
+- Validate header values properly
+
+## 2.1.0 - 2021-10-06
+
+### Changed
+
+- Attempting to create a `Uri` object from a malformed URI will no longer throw a generic
+ `InvalidArgumentException`, but rather a `MalformedUriException`, which inherits from the former
+ for backwards compatibility. Callers relying on the exception being thrown to detect invalid
+ URIs should catch the new exception.
+
+### Fixed
+
+- Return `null` in caching stream size if remote size is `null`
+
+## 2.0.0 - 2021-06-30
+
+Identical to the RC release.
+
+## 2.0.0@RC-1 - 2021-04-29
+
+### Fixed
+
+- Handle possibly unset `url` in `stream_get_meta_data`
+
+## 2.0.0@beta-1 - 2021-03-21
+
+### Added
+
+- PSR-17 factories
+- Made classes final
+- PHP7 type hints
+
+### Changed
+
+- When building a query string, booleans are represented as 1 and 0.
+
+### Removed
+
+- PHP < 7.2 support
+- All functions in the `GuzzleHttp\Psr7` namespace
+
+## 1.8.1 - 2021-03-21
+
+### Fixed
+
+- Issue parsing IPv6 URLs
+- Issue modifying ServerRequest lost all its attributes
+
+## 1.8.0 - 2021-03-21
+
+### Added
+
+- Locale independent URL parsing
+- Most classes got a `@final` annotation to prepare for 2.0
+
+### Fixed
+
+- Issue when creating stream from `php://input` and curl-ext is not installed
+- Broken `Utils::tryFopen()` on PHP 8
+
+## 1.7.0 - 2020-09-30
+
+### Added
+
+- Replaced functions by static methods
+
+### Fixed
+
+- Converting a non-seekable stream to a string
+- Handle multiple Set-Cookie correctly
+- Ignore array keys in header values when merging
+- Allow multibyte characters to be parsed in `Message:bodySummary()`
+
+### Changed
+
+- Restored partial HHVM 3 support
+
+
+## [1.6.1] - 2019-07-02
+
+### Fixed
+
+- Accept null and bool header values again
+
+
+## [1.6.0] - 2019-06-30
+
+### Added
+
+- Allowed version `^3.0` of `ralouphie/getallheaders` dependency (#244)
+- Added MIME type for WEBP image format (#246)
+- Added more validation of values according to PSR-7 and RFC standards, e.g. status code range (#250, #272)
+
+### Changed
+
+- Tests don't pass with HHVM 4.0, so HHVM support got dropped. Other libraries like composer have done the same. (#262)
+- Accept port number 0 to be valid (#270)
+
+### Fixed
+
+- Fixed subsequent reads from `php://input` in ServerRequest (#247)
+- Fixed readable/writable detection for certain stream modes (#248)
+- Fixed encoding of special characters in the `userInfo` component of an URI (#253)
+
+
+## [1.5.2] - 2018-12-04
+
+### Fixed
+
+- Check body size when getting the message summary
+
+
+## [1.5.1] - 2018-12-04
+
+### Fixed
+
+- Get the summary of a body only if it is readable
+
+
+## [1.5.0] - 2018-12-03
+
+### Added
+
+- Response first-line to response string exception (fixes #145)
+- A test for #129 behavior
+- `get_message_body_summary` function in order to get the message summary
+- `3gp` and `mkv` mime types
+
+### Changed
+
+- Clarify exception message when stream is detached
+
+### Deprecated
+
+- Deprecated parsing folded header lines as per RFC 7230
+
+### Fixed
+
+- Fix `AppendStream::detach` to not close streams
+- `InflateStream` preserves `isSeekable` attribute of the underlying stream
+- `ServerRequest::getUriFromGlobals` to support URLs in query parameters
+
+
+Several other fixes and improvements.
+
+
+## [1.4.2] - 2017-03-20
+
+### Fixed
+
+- Reverted BC break to `Uri::resolve` and `Uri::removeDotSegments` by removing
+ calls to `trigger_error` when deprecated methods are invoked.
+
+
+## [1.4.1] - 2017-02-27
+
+### Added
+
+- Rriggering of silenced deprecation warnings.
+
+### Fixed
+
+- Reverted BC break by reintroducing behavior to automagically fix a URI with a
+ relative path and an authority by adding a leading slash to the path. It's only
+ deprecated now.
+
+
+## [1.4.0] - 2017-02-21
+
+### Added
+
+- Added common URI utility methods based on RFC 3986 (see documentation in the readme):
+ - `Uri::isDefaultPort`
+ - `Uri::isAbsolute`
+ - `Uri::isNetworkPathReference`
+ - `Uri::isAbsolutePathReference`
+ - `Uri::isRelativePathReference`
+ - `Uri::isSameDocumentReference`
+ - `Uri::composeComponents`
+ - `UriNormalizer::normalize`
+ - `UriNormalizer::isEquivalent`
+ - `UriResolver::relativize`
+
+### Changed
+
+- Ensure `ServerRequest::getUriFromGlobals` returns a URI in absolute form.
+- Allow `parse_response` to parse a response without delimiting space and reason.
+- Ensure each URI modification results in a valid URI according to PSR-7 discussions.
+ Invalid modifications will throw an exception instead of returning a wrong URI or
+ doing some magic.
+ - `(new Uri)->withPath('foo')->withHost('example.com')` will throw an exception
+ because the path of a URI with an authority must start with a slash "/" or be empty
+ - `(new Uri())->withScheme('http')` will return `'http://localhost'`
+
+### Deprecated
+
+- `Uri::resolve` in favor of `UriResolver::resolve`
+- `Uri::removeDotSegments` in favor of `UriResolver::removeDotSegments`
+
+### Fixed
+
+- `Stream::read` when length parameter <= 0.
+- `copy_to_stream` reads bytes in chunks instead of `maxLen` into memory.
+- `ServerRequest::getUriFromGlobals` when `Host` header contains port.
+- Compatibility of URIs with `file` scheme and empty host.
+
+
+## [1.3.1] - 2016-06-25
+
+### Fixed
+
+- `Uri::__toString` for network path references, e.g. `//example.org`.
+- Missing lowercase normalization for host.
+- Handling of URI components in case they are `'0'` in a lot of places,
+ e.g. as a user info password.
+- `Uri::withAddedHeader` to correctly merge headers with different case.
+- Trimming of header values in `Uri::withAddedHeader`. Header values may
+ be surrounded by whitespace which should be ignored according to RFC 7230
+ Section 3.2.4. This does not apply to header names.
+- `Uri::withAddedHeader` with an array of header values.
+- `Uri::resolve` when base path has no slash and handling of fragment.
+- Handling of encoding in `Uri::with(out)QueryValue` so one can pass the
+ key/value both in encoded as well as decoded form to those methods. This is
+ consistent with withPath, withQuery etc.
+- `ServerRequest::withoutAttribute` when attribute value is null.
+
+
+## [1.3.0] - 2016-04-13
+
+### Added
+
+- Remaining interfaces needed for full PSR7 compatibility
+ (ServerRequestInterface, UploadedFileInterface, etc.).
+- Support for stream_for from scalars.
+
+### Changed
+
+- Can now extend Uri.
+
+### Fixed
+- A bug in validating request methods by making it more permissive.
+
+
+## [1.2.3] - 2016-02-18
+
+### Fixed
+
+- Support in `GuzzleHttp\Psr7\CachingStream` for seeking forward on remote
+ streams, which can sometimes return fewer bytes than requested with `fread`.
+- Handling of gzipped responses with FNAME headers.
+
+
+## [1.2.2] - 2016-01-22
+
+### Added
+
+- Support for URIs without any authority.
+- Support for HTTP 451 'Unavailable For Legal Reasons.'
+- Support for using '0' as a filename.
+- Support for including non-standard ports in Host headers.
+
+
+## [1.2.1] - 2015-11-02
+
+### Changes
+
+- Now supporting negative offsets when seeking to SEEK_END.
+
+
+## [1.2.0] - 2015-08-15
+
+### Changed
+
+- Body as `"0"` is now properly added to a response.
+- Now allowing forward seeking in CachingStream.
+- Now properly parsing HTTP requests that contain proxy targets in
+ `parse_request`.
+- functions.php is now conditionally required.
+- user-info is no longer dropped when resolving URIs.
+
+
+## [1.1.0] - 2015-06-24
+
+### Changed
+
+- URIs can now be relative.
+- `multipart/form-data` headers are now overridden case-insensitively.
+- URI paths no longer encode the following characters because they are allowed
+ in URIs: "(", ")", "*", "!", "'"
+- A port is no longer added to a URI when the scheme is missing and no port is
+ present.
+
+
+## 1.0.0 - 2015-05-19
+
+Initial release.
+
+Currently unsupported:
+
+- `Psr\Http\Message\ServerRequestInterface`
+- `Psr\Http\Message\UploadedFileInterface`
+
+
+
+[1.6.0]: https://github.com/guzzle/psr7/compare/1.5.2...1.6.0
+[1.5.2]: https://github.com/guzzle/psr7/compare/1.5.1...1.5.2
+[1.5.1]: https://github.com/guzzle/psr7/compare/1.5.0...1.5.1
+[1.5.0]: https://github.com/guzzle/psr7/compare/1.4.2...1.5.0
+[1.4.2]: https://github.com/guzzle/psr7/compare/1.4.1...1.4.2
+[1.4.1]: https://github.com/guzzle/psr7/compare/1.4.0...1.4.1
+[1.4.0]: https://github.com/guzzle/psr7/compare/1.3.1...1.4.0
+[1.3.1]: https://github.com/guzzle/psr7/compare/1.3.0...1.3.1
+[1.3.0]: https://github.com/guzzle/psr7/compare/1.2.3...1.3.0
+[1.2.3]: https://github.com/guzzle/psr7/compare/1.2.2...1.2.3
+[1.2.2]: https://github.com/guzzle/psr7/compare/1.2.1...1.2.2
+[1.2.1]: https://github.com/guzzle/psr7/compare/1.2.0...1.2.1
+[1.2.0]: https://github.com/guzzle/psr7/compare/1.1.0...1.2.0
+[1.1.0]: https://github.com/guzzle/psr7/compare/1.0.0...1.1.0
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/LICENSE
new file mode 100644
index 0000000..51c7ec8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/LICENSE
@@ -0,0 +1,26 @@
+The MIT License (MIT)
+
+Copyright (c) 2015 Michael Dowling <mtdowling@gmail.com>
+Copyright (c) 2015 Márk Sági-Kazár <mark.sagikazar@gmail.com>
+Copyright (c) 2015 Graham Campbell <hello@gjcampbell.co.uk>
+Copyright (c) 2016 Tobias Schultze <webmaster@tubo-world.de>
+Copyright (c) 2016 George Mponos <gmponos@gmail.com>
+Copyright (c) 2018 Tobias Nyholm <tobias.nyholm@gmail.com>
+
+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/guzzlehttp/psr7/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/README.md
new file mode 100644
index 0000000..9566a7d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/README.md
@@ -0,0 +1,880 @@
+# PSR-7 Message Implementation
+
+This repository contains a full [PSR-7](https://www.php-fig.org/psr/psr-7/)
+message implementation, several stream decorators, and some helpful
+functionality like query string parsing.
+
+
+
+
+
+# Installation
+
+```shell
+composer require guzzlehttp/psr7
+```
+
+# Stream implementation
+
+This package comes with a number of stream implementations and stream
+decorators.
+
+
+## AppendStream
+
+`GuzzleHttp\Psr7\AppendStream`
+
+Reads from multiple streams, one after the other.
+
+```php
+use GuzzleHttp\Psr7;
+
+$a = Psr7\Utils::streamFor('abc, ');
+$b = Psr7\Utils::streamFor('123.');
+$composed = new Psr7\AppendStream([$a, $b]);
+
+$composed->addStream(Psr7\Utils::streamFor(' Above all listen to me'));
+
+echo $composed; // abc, 123. Above all listen to me.
+```
+
+
+## BufferStream
+
+`GuzzleHttp\Psr7\BufferStream`
+
+Provides a buffer stream that can be written to fill a buffer, and read
+from to remove bytes from the buffer.
+
+This stream returns a "hwm" metadata value that tells upstream consumers
+what the configured high water mark of the stream is, or the maximum
+preferred size of the buffer.
+
+```php
+use GuzzleHttp\Psr7;
+
+// When more than 1024 bytes are in the buffer, it will begin returning
+// false to writes. This is an indication that writers should slow down.
+$buffer = new Psr7\BufferStream(1024);
+```
+
+
+## CachingStream
+
+The CachingStream is used to allow seeking over previously read bytes on
+non-seekable streams. This can be useful when transferring a non-seekable
+entity body fails due to needing to rewind the stream (for example, resulting
+from a redirect). Data that is read from the remote stream will be buffered in
+a PHP temp stream so that previously read bytes are cached first in memory,
+then on disk.
+
+```php
+use GuzzleHttp\Psr7;
+
+$original = Psr7\Utils::streamFor(fopen('http://www.google.com', 'r'));
+$stream = new Psr7\CachingStream($original);
+
+$stream->read(1024);
+echo $stream->tell();
+// 1024
+
+$stream->seek(0);
+echo $stream->tell();
+// 0
+```
+
+
+## DroppingStream
+
+`GuzzleHttp\Psr7\DroppingStream`
+
+Stream decorator that begins dropping data once the size of the underlying
+stream becomes too full.
+
+```php
+use GuzzleHttp\Psr7;
+
+// Create an empty stream
+$stream = Psr7\Utils::streamFor();
+
+// Start dropping data when the stream has more than 10 bytes
+$dropping = new Psr7\DroppingStream($stream, 10);
+
+$dropping->write('01234567890123456789');
+echo $stream; // 0123456789
+```
+
+
+## FnStream
+
+`GuzzleHttp\Psr7\FnStream`
+
+Compose stream implementations based on a hash of functions.
+
+Allows for easy testing and extension of a provided stream without needing
+to create a concrete class for a simple extension point.
+
+```php
+
+use GuzzleHttp\Psr7;
+
+$stream = Psr7\Utils::streamFor('hi');
+$fnStream = Psr7\FnStream::decorate($stream, [
+ 'rewind' => function () use ($stream) {
+ echo 'About to rewind - ';
+ $stream->rewind();
+ echo 'rewound!';
+ }
+]);
+
+$fnStream->rewind();
+// Outputs: About to rewind - rewound!
+```
+
+
+## InflateStream
+
+`GuzzleHttp\Psr7\InflateStream`
+
+Uses PHP's zlib.inflate filter to inflate zlib (HTTP deflate, RFC1950) or gzipped (RFC1952) content.
+
+This stream decorator converts the provided stream to a PHP stream resource,
+then appends the zlib.inflate filter. The stream is then converted back
+to a Guzzle stream resource to be used as a Guzzle stream.
+
+
+## LazyOpenStream
+
+`GuzzleHttp\Psr7\LazyOpenStream`
+
+Lazily reads or writes to a file that is opened only after an IO operation
+take place on the stream.
+
+```php
+use GuzzleHttp\Psr7;
+
+$stream = new Psr7\LazyOpenStream('/path/to/file', 'r');
+// The file has not yet been opened...
+
+echo $stream->read(10);
+// The file is opened and read from only when needed.
+```
+
+
+## LimitStream
+
+`GuzzleHttp\Psr7\LimitStream`
+
+LimitStream can be used to read a subset or slice of an existing stream object.
+This can be useful for breaking a large file into smaller pieces to be sent in
+chunks (e.g. Amazon S3's multipart upload API).
+
+```php
+use GuzzleHttp\Psr7;
+
+$original = Psr7\Utils::streamFor(fopen('/tmp/test.txt', 'r+'));
+echo $original->getSize();
+// >>> 1048576
+
+// Limit the size of the body to 1024 bytes and start reading from byte 2048
+$stream = new Psr7\LimitStream($original, 1024, 2048);
+echo $stream->getSize();
+// >>> 1024
+echo $stream->tell();
+// >>> 0
+```
+
+
+## MultipartStream
+
+`GuzzleHttp\Psr7\MultipartStream`
+
+Stream that when read returns bytes for a streaming multipart or
+multipart/form-data stream.
+
+
+## NoSeekStream
+
+`GuzzleHttp\Psr7\NoSeekStream`
+
+NoSeekStream wraps a stream and does not allow seeking.
+
+```php
+use GuzzleHttp\Psr7;
+
+$original = Psr7\Utils::streamFor('foo');
+$noSeek = new Psr7\NoSeekStream($original);
+
+echo $noSeek->read(3);
+// foo
+var_export($noSeek->isSeekable());
+// false
+$noSeek->seek(0);
+var_export($noSeek->read(3));
+// NULL
+```
+
+
+## PumpStream
+
+`GuzzleHttp\Psr7\PumpStream`
+
+Provides a read only stream that pumps data from a PHP callable.
+
+When invoking the provided callable, the PumpStream will pass the amount of
+data requested to read to the callable. The callable can choose to ignore
+this value and return fewer or more bytes than requested. Any extra data
+returned by the provided callable is buffered internally until drained using
+the read() function of the PumpStream. The provided callable MUST return
+false when there is no more data to read.
+
+
+## Implementing stream decorators
+
+Creating a stream decorator is very easy thanks to the
+`GuzzleHttp\Psr7\StreamDecoratorTrait`. This trait provides methods that
+implement `Psr\Http\Message\StreamInterface` by proxying to an underlying
+stream. Just `use` the `StreamDecoratorTrait` and implement your custom
+methods.
+
+For example, let's say we wanted to call a specific function each time the last
+byte is read from a stream. This could be implemented by overriding the
+`read()` method.
+
+```php
+use Psr\Http\Message\StreamInterface;
+use GuzzleHttp\Psr7\StreamDecoratorTrait;
+
+class EofCallbackStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ private $callback;
+
+ private $stream;
+
+ public function __construct(StreamInterface $stream, callable $cb)
+ {
+ $this->stream = $stream;
+ $this->callback = $cb;
+ }
+
+ public function read($length)
+ {
+ $result = $this->stream->read($length);
+
+ // Invoke the callback when EOF is hit.
+ if ($this->eof()) {
+ call_user_func($this->callback);
+ }
+
+ return $result;
+ }
+}
+```
+
+This decorator could be added to any existing stream and used like so:
+
+```php
+use GuzzleHttp\Psr7;
+
+$original = Psr7\Utils::streamFor('foo');
+
+$eofStream = new EofCallbackStream($original, function () {
+ echo 'EOF!';
+});
+
+$eofStream->read(2);
+$eofStream->read(1);
+// echoes "EOF!"
+$eofStream->seek(0);
+$eofStream->read(3);
+// echoes "EOF!"
+```
+
+
+## PHP StreamWrapper
+
+You can use the `GuzzleHttp\Psr7\StreamWrapper` class if you need to use a
+PSR-7 stream as a PHP stream resource.
+
+Use the `GuzzleHttp\Psr7\StreamWrapper::getResource()` method to create a PHP
+stream from a PSR-7 stream.
+
+```php
+use GuzzleHttp\Psr7\StreamWrapper;
+
+$stream = GuzzleHttp\Psr7\Utils::streamFor('hello!');
+$resource = StreamWrapper::getResource($stream);
+echo fread($resource, 6); // outputs hello!
+```
+
+
+# Static API
+
+There are various static methods available under the `GuzzleHttp\Psr7` namespace.
+
+
+## `GuzzleHttp\Psr7\Message::toString`
+
+`public static function toString(MessageInterface $message): string`
+
+Returns the string representation of an HTTP message.
+
+```php
+$request = new GuzzleHttp\Psr7\Request('GET', 'http://example.com');
+echo GuzzleHttp\Psr7\Message::toString($request);
+```
+
+
+## `GuzzleHttp\Psr7\Message::bodySummary`
+
+`public static function bodySummary(MessageInterface $message, int $truncateAt = 120): string|null`
+
+Get a short summary of the message body.
+
+Will return `null` if the response is not printable.
+
+
+## `GuzzleHttp\Psr7\Message::rewindBody`
+
+`public static function rewindBody(MessageInterface $message): void`
+
+Attempts to rewind a message body and throws an exception on failure.
+
+The body of the message will only be rewound if a call to `tell()`
+returns a value other than `0`.
+
+
+## `GuzzleHttp\Psr7\Message::parseMessage`
+
+`public static function parseMessage(string $message): array`
+
+Parses an HTTP message into an associative array.
+
+The array contains the "start-line" key containing the start line of
+the message, "headers" key containing an associative array of header
+array values, and a "body" key containing the body of the message.
+
+
+## `GuzzleHttp\Psr7\Message::parseRequestUri`
+
+`public static function parseRequestUri(string $path, array $headers): string`
+
+Constructs a URI for an HTTP request message.
+
+
+## `GuzzleHttp\Psr7\Message::parseRequest`
+
+`public static function parseRequest(string $message): Request`
+
+Parses a request message string into a request object.
+
+
+## `GuzzleHttp\Psr7\Message::parseResponse`
+
+`public static function parseResponse(string $message): Response`
+
+Parses a response message string into a response object.
+
+
+## `GuzzleHttp\Psr7\Header::parse`
+
+`public static function parse(string|array $header): array`
+
+Parse an array of header values containing ";" separated data into an
+array of associative arrays representing the header key value pair data
+of the header. When a parameter does not contain a value, but just
+contains a key, this function will inject a key with a '' string value.
+
+
+## `GuzzleHttp\Psr7\Header::splitList`
+
+`public static function splitList(string|string[] $header): string[]`
+
+Splits a HTTP header defined to contain a comma-separated list into
+each individual value:
+
+```
+$knownEtags = Header::splitList($request->getHeader('if-none-match'));
+```
+
+Example headers include `accept`, `cache-control` and `if-none-match`.
+
+
+## `GuzzleHttp\Psr7\Header::normalize` (deprecated)
+
+`public static function normalize(string|array $header): array`
+
+`Header::normalize()` is deprecated in favor of [`Header::splitList()`](README.md#guzzlehttppsr7headersplitlist)
+which performs the same operation with a cleaned up API and improved
+documentation.
+
+Converts an array of header values that may contain comma separated
+headers into an array of headers with no comma separated values.
+
+
+## `GuzzleHttp\Psr7\Query::parse`
+
+`public static function parse(string $str, int|bool $urlEncoding = true): array`
+
+Parse a query string into an associative array.
+
+If multiple values are found for the same key, the value of that key
+value pair will become an array. This function does not parse nested
+PHP style arrays into an associative array (e.g., `foo[a]=1&foo[b]=2`
+will be parsed into `['foo[a]' => '1', 'foo[b]' => '2'])`.
+
+
+## `GuzzleHttp\Psr7\Query::build`
+
+`public static function build(array $params, int|false $encoding = PHP_QUERY_RFC3986): string`
+
+Build a query string from an array of key value pairs.
+
+This function can use the return value of `parse()` to build a query
+string. This function does not modify the provided keys when an array is
+encountered (like `http_build_query()` would).
+
+
+## `GuzzleHttp\Psr7\Utils::caselessRemove`
+
+`public static function caselessRemove(iterable<string> $keys, $keys, array $data): array`
+
+Remove the items given by the keys, case insensitively from the data.
+
+
+## `GuzzleHttp\Psr7\Utils::copyToStream`
+
+`public static function copyToStream(StreamInterface $source, StreamInterface $dest, int $maxLen = -1): void`
+
+Copy the contents of a stream into another stream until the given number
+of bytes have been read.
+
+
+## `GuzzleHttp\Psr7\Utils::copyToString`
+
+`public static function copyToString(StreamInterface $stream, int $maxLen = -1): string`
+
+Copy the contents of a stream into a string until the given number of
+bytes have been read.
+
+
+## `GuzzleHttp\Psr7\Utils::hash`
+
+`public static function hash(StreamInterface $stream, string $algo, bool $rawOutput = false): string`
+
+Calculate a hash of a stream.
+
+This method reads the entire stream to calculate a rolling hash, based on
+PHP's `hash_init` functions.
+
+
+## `GuzzleHttp\Psr7\Utils::modifyRequest`
+
+`public static function modifyRequest(RequestInterface $request, array $changes): RequestInterface`
+
+Clone and modify a request with the given changes.
+
+This method is useful for reducing the number of clones needed to mutate
+a message.
+
+- method: (string) Changes the HTTP method.
+- set_headers: (array) Sets the given headers.
+- remove_headers: (array) Remove the given headers.
+- body: (mixed) Sets the given body.
+- uri: (UriInterface) Set the URI.
+- query: (string) Set the query string value of the URI.
+- version: (string) Set the protocol version.
+
+
+## `GuzzleHttp\Psr7\Utils::readLine`
+
+`public static function readLine(StreamInterface $stream, int $maxLength = null): string`
+
+Read a line from the stream up to the maximum allowed buffer length.
+
+
+## `GuzzleHttp\Psr7\Utils::streamFor`
+
+`public static function streamFor(resource|string|null|int|float|bool|StreamInterface|callable|\Iterator $resource = '', array $options = []): StreamInterface`
+
+Create a new stream based on the input type.
+
+Options is an associative array that can contain the following keys:
+
+- metadata: Array of custom metadata.
+- size: Size of the stream.
+
+This method accepts the following `$resource` types:
+
+- `Psr\Http\Message\StreamInterface`: Returns the value as-is.
+- `string`: Creates a stream object that uses the given string as the contents.
+- `resource`: Creates a stream object that wraps the given PHP stream resource.
+- `Iterator`: If the provided value implements `Iterator`, then a read-only
+ stream object will be created that wraps the given iterable. Each time the
+ stream is read from, data from the iterator will fill a buffer and will be
+ continuously called until the buffer is equal to the requested read size.
+ Subsequent read calls will first read from the buffer and then call `next`
+ on the underlying iterator until it is exhausted.
+- `object` with `__toString()`: If the object has the `__toString()` method,
+ the object will be cast to a string and then a stream will be returned that
+ uses the string value.
+- `NULL`: When `null` is passed, an empty stream object is returned.
+- `callable` When a callable is passed, a read-only stream object will be
+ created that invokes the given callable. The callable is invoked with the
+ number of suggested bytes to read. The callable can return any number of
+ bytes, but MUST return `false` when there is no more data to return. The
+ stream object that wraps the callable will invoke the callable until the
+ number of requested bytes are available. Any additional bytes will be
+ buffered and used in subsequent reads.
+
+```php
+$stream = GuzzleHttp\Psr7\Utils::streamFor('foo');
+$stream = GuzzleHttp\Psr7\Utils::streamFor(fopen('/path/to/file', 'r'));
+
+$generator = function ($bytes) {
+ for ($i = 0; $i < $bytes; $i++) {
+ yield ' ';
+ }
+}
+
+$stream = GuzzleHttp\Psr7\Utils::streamFor($generator(100));
+```
+
+
+## `GuzzleHttp\Psr7\Utils::tryFopen`
+
+`public static function tryFopen(string $filename, string $mode): resource`
+
+Safely opens a PHP stream resource using a filename.
+
+When fopen fails, PHP normally raises a warning. This function adds an
+error handler that checks for errors and throws an exception instead.
+
+
+## `GuzzleHttp\Psr7\Utils::tryGetContents`
+
+`public static function tryGetContents(resource $stream): string`
+
+Safely gets the contents of a given stream.
+
+When stream_get_contents fails, PHP normally raises a warning. This
+function adds an error handler that checks for errors and throws an
+exception instead.
+
+
+## `GuzzleHttp\Psr7\Utils::uriFor`
+
+`public static function uriFor(string|UriInterface $uri): UriInterface`
+
+Returns a UriInterface for the given value.
+
+This function accepts a string or UriInterface and returns a
+UriInterface for the given value. If the value is already a
+UriInterface, it is returned as-is.
+
+
+## `GuzzleHttp\Psr7\MimeType::fromFilename`
+
+`public static function fromFilename(string $filename): string|null`
+
+Determines the mimetype of a file by looking at its extension.
+
+
+## `GuzzleHttp\Psr7\MimeType::fromExtension`
+
+`public static function fromExtension(string $extension): string|null`
+
+Maps a file extensions to a mimetype.
+
+
+## Upgrading from Function API
+
+The static API was first introduced in 1.7.0, in order to mitigate problems with functions conflicting between global and local copies of the package. The function API was removed in 2.0.0. A migration table has been provided here for your convenience:
+
+| Original Function | Replacement Method |
+|----------------|----------------|
+| `str` | `Message::toString` |
+| `uri_for` | `Utils::uriFor` |
+| `stream_for` | `Utils::streamFor` |
+| `parse_header` | `Header::parse` |
+| `normalize_header` | `Header::normalize` |
+| `modify_request` | `Utils::modifyRequest` |
+| `rewind_body` | `Message::rewindBody` |
+| `try_fopen` | `Utils::tryFopen` |
+| `copy_to_string` | `Utils::copyToString` |
+| `copy_to_stream` | `Utils::copyToStream` |
+| `hash` | `Utils::hash` |
+| `readline` | `Utils::readLine` |
+| `parse_request` | `Message::parseRequest` |
+| `parse_response` | `Message::parseResponse` |
+| `parse_query` | `Query::parse` |
+| `build_query` | `Query::build` |
+| `mimetype_from_filename` | `MimeType::fromFilename` |
+| `mimetype_from_extension` | `MimeType::fromExtension` |
+| `_parse_message` | `Message::parseMessage` |
+| `_parse_request_uri` | `Message::parseRequestUri` |
+| `get_message_body_summary` | `Message::bodySummary` |
+| `_caseless_remove` | `Utils::caselessRemove` |
+
+
+# Additional URI Methods
+
+Aside from the standard `Psr\Http\Message\UriInterface` implementation in form of the `GuzzleHttp\Psr7\Uri` class,
+this library also provides additional functionality when working with URIs as static methods.
+
+## URI Types
+
+An instance of `Psr\Http\Message\UriInterface` can either be an absolute URI or a relative reference.
+An absolute URI has a scheme. A relative reference is used to express a URI relative to another URI,
+the base URI. Relative references can be divided into several forms according to
+[RFC 3986 Section 4.2](https://tools.ietf.org/html/rfc3986#section-4.2):
+
+- network-path references, e.g. `//example.com/path`
+- absolute-path references, e.g. `/path`
+- relative-path references, e.g. `subpath`
+
+The following methods can be used to identify the type of the URI.
+
+### `GuzzleHttp\Psr7\Uri::isAbsolute`
+
+`public static function isAbsolute(UriInterface $uri): bool`
+
+Whether the URI is absolute, i.e. it has a scheme.
+
+### `GuzzleHttp\Psr7\Uri::isNetworkPathReference`
+
+`public static function isNetworkPathReference(UriInterface $uri): bool`
+
+Whether the URI is a network-path reference. A relative reference that begins with two slash characters is
+termed an network-path reference.
+
+### `GuzzleHttp\Psr7\Uri::isAbsolutePathReference`
+
+`public static function isAbsolutePathReference(UriInterface $uri): bool`
+
+Whether the URI is a absolute-path reference. A relative reference that begins with a single slash character is
+termed an absolute-path reference.
+
+### `GuzzleHttp\Psr7\Uri::isRelativePathReference`
+
+`public static function isRelativePathReference(UriInterface $uri): bool`
+
+Whether the URI is a relative-path reference. A relative reference that does not begin with a slash character is
+termed a relative-path reference.
+
+### `GuzzleHttp\Psr7\Uri::isSameDocumentReference`
+
+`public static function isSameDocumentReference(UriInterface $uri, UriInterface $base = null): bool`
+
+Whether the URI is a same-document reference. A same-document reference refers to a URI that is, aside from its
+fragment component, identical to the base URI. When no base URI is given, only an empty URI reference
+(apart from its fragment) is considered a same-document reference.
+
+## URI Components
+
+Additional methods to work with URI components.
+
+### `GuzzleHttp\Psr7\Uri::isDefaultPort`
+
+`public static function isDefaultPort(UriInterface $uri): bool`
+
+Whether the URI has the default port of the current scheme. `Psr\Http\Message\UriInterface::getPort` may return null
+or the standard port. This method can be used independently of the implementation.
+
+### `GuzzleHttp\Psr7\Uri::composeComponents`
+
+`public static function composeComponents($scheme, $authority, $path, $query, $fragment): string`
+
+Composes a URI reference string from its various components according to
+[RFC 3986 Section 5.3](https://tools.ietf.org/html/rfc3986#section-5.3). Usually this method does not need to be called
+manually but instead is used indirectly via `Psr\Http\Message\UriInterface::__toString`.
+
+### `GuzzleHttp\Psr7\Uri::fromParts`
+
+`public static function fromParts(array $parts): UriInterface`
+
+Creates a URI from a hash of [`parse_url`](https://www.php.net/manual/en/function.parse-url.php) components.
+
+
+### `GuzzleHttp\Psr7\Uri::withQueryValue`
+
+`public static function withQueryValue(UriInterface $uri, $key, $value): UriInterface`
+
+Creates a new URI with a specific query string value. Any existing query string values that exactly match the
+provided key are removed and replaced with the given key value pair. A value of null will set the query string
+key without a value, e.g. "key" instead of "key=value".
+
+### `GuzzleHttp\Psr7\Uri::withQueryValues`
+
+`public static function withQueryValues(UriInterface $uri, array $keyValueArray): UriInterface`
+
+Creates a new URI with multiple query string values. It has the same behavior as `withQueryValue()` but for an
+associative array of key => value.
+
+### `GuzzleHttp\Psr7\Uri::withoutQueryValue`
+
+`public static function withoutQueryValue(UriInterface $uri, $key): UriInterface`
+
+Creates a new URI with a specific query string value removed. Any existing query string values that exactly match the
+provided key are removed.
+
+## Cross-Origin Detection
+
+`GuzzleHttp\Psr7\UriComparator` provides methods to determine if a modified URL should be considered cross-origin.
+
+### `GuzzleHttp\Psr7\UriComparator::isCrossOrigin`
+
+`public static function isCrossOrigin(UriInterface $original, UriInterface $modified): bool`
+
+Determines if a modified URL should be considered cross-origin with respect to an original URL.
+
+## Reference Resolution
+
+`GuzzleHttp\Psr7\UriResolver` provides methods to resolve a URI reference in the context of a base URI according
+to [RFC 3986 Section 5](https://tools.ietf.org/html/rfc3986#section-5). This is for example also what web browsers
+do when resolving a link in a website based on the current request URI.
+
+### `GuzzleHttp\Psr7\UriResolver::resolve`
+
+`public static function resolve(UriInterface $base, UriInterface $rel): UriInterface`
+
+Converts the relative URI into a new URI that is resolved against the base URI.
+
+### `GuzzleHttp\Psr7\UriResolver::removeDotSegments`
+
+`public static function removeDotSegments(string $path): string`
+
+Removes dot segments from a path and returns the new path according to
+[RFC 3986 Section 5.2.4](https://tools.ietf.org/html/rfc3986#section-5.2.4).
+
+### `GuzzleHttp\Psr7\UriResolver::relativize`
+
+`public static function relativize(UriInterface $base, UriInterface $target): UriInterface`
+
+Returns the target URI as a relative reference from the base URI. This method is the counterpart to resolve():
+
+```php
+(string) $target === (string) UriResolver::resolve($base, UriResolver::relativize($base, $target))
+```
+
+One use-case is to use the current request URI as base URI and then generate relative links in your documents
+to reduce the document size or offer self-contained downloadable document archives.
+
+```php
+$base = new Uri('http://example.com/a/b/');
+echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'.
+echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'.
+echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'.
+echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'.
+```
+
+## Normalization and Comparison
+
+`GuzzleHttp\Psr7\UriNormalizer` provides methods to normalize and compare URIs according to
+[RFC 3986 Section 6](https://tools.ietf.org/html/rfc3986#section-6).
+
+### `GuzzleHttp\Psr7\UriNormalizer::normalize`
+
+`public static function normalize(UriInterface $uri, $flags = self::PRESERVING_NORMALIZATIONS): UriInterface`
+
+Returns a normalized URI. The scheme and host component are already normalized to lowercase per PSR-7 UriInterface.
+This methods adds additional normalizations that can be configured with the `$flags` parameter which is a bitmask
+of normalizations to apply. The following normalizations are available:
+
+- `UriNormalizer::PRESERVING_NORMALIZATIONS`
+
+ Default normalizations which only include the ones that preserve semantics.
+
+- `UriNormalizer::CAPITALIZE_PERCENT_ENCODING`
+
+ All letters within a percent-encoding triplet (e.g., "%3A") are case-insensitive, and should be capitalized.
+
+ Example: `http://example.org/a%c2%b1b` → `http://example.org/a%C2%B1b`
+
+- `UriNormalizer::DECODE_UNRESERVED_CHARACTERS`
+
+ Decodes percent-encoded octets of unreserved characters. For consistency, percent-encoded octets in the ranges of
+ ALPHA (%41–%5A and %61–%7A), DIGIT (%30–%39), hyphen (%2D), period (%2E), underscore (%5F), or tilde (%7E) should
+ not be created by URI producers and, when found in a URI, should be decoded to their corresponding unreserved
+ characters by URI normalizers.
+
+ Example: `http://example.org/%7Eusern%61me/` → `http://example.org/~username/`
+
+- `UriNormalizer::CONVERT_EMPTY_PATH`
+
+ Converts the empty path to "/" for http and https URIs.
+
+ Example: `http://example.org` → `http://example.org/`
+
+- `UriNormalizer::REMOVE_DEFAULT_HOST`
+
+ Removes the default host of the given URI scheme from the URI. Only the "file" scheme defines the default host
+ "localhost". All of `file:/myfile`, `file:///myfile`, and `file://localhost/myfile` are equivalent according to
+ RFC 3986.
+
+ Example: `file://localhost/myfile` → `file:///myfile`
+
+- `UriNormalizer::REMOVE_DEFAULT_PORT`
+
+ Removes the default port of the given URI scheme from the URI.
+
+ Example: `http://example.org:80/` → `http://example.org/`
+
+- `UriNormalizer::REMOVE_DOT_SEGMENTS`
+
+ Removes unnecessary dot-segments. Dot-segments in relative-path references are not removed as it would
+ change the semantics of the URI reference.
+
+ Example: `http://example.org/../a/b/../c/./d.html` → `http://example.org/a/c/d.html`
+
+- `UriNormalizer::REMOVE_DUPLICATE_SLASHES`
+
+ Paths which include two or more adjacent slashes are converted to one. Webservers usually ignore duplicate slashes
+ and treat those URIs equivalent. But in theory those URIs do not need to be equivalent. So this normalization
+ may change the semantics. Encoded slashes (%2F) are not removed.
+
+ Example: `http://example.org//foo///bar.html` → `http://example.org/foo/bar.html`
+
+- `UriNormalizer::SORT_QUERY_PARAMETERS`
+
+ Sort query parameters with their values in alphabetical order. However, the order of parameters in a URI may be
+ significant (this is not defined by the standard). So this normalization is not safe and may change the semantics
+ of the URI.
+
+ Example: `?lang=en&article=fred` → `?article=fred&lang=en`
+
+### `GuzzleHttp\Psr7\UriNormalizer::isEquivalent`
+
+`public static function isEquivalent(UriInterface $uri1, UriInterface $uri2, $normalizations = self::PRESERVING_NORMALIZATIONS): bool`
+
+Whether two URIs can be considered equivalent. Both URIs are normalized automatically before comparison with the given
+`$normalizations` bitmask. The method also accepts relative URI references and returns true when they are equivalent.
+This of course assumes they will be resolved against the same base URI. If this is not the case, determination of
+equivalence or difference of relative references does not mean anything.
+
+
+## Version Guidance
+
+| Version | Status | PHP Version |
+|---------|----------------|------------------|
+| 1.x | Security fixes | >=5.4,<8.1 |
+| 2.x | Latest | ^7.2.5 \|\| ^8.0 |
+
+
+## Security
+
+If you discover a security vulnerability within this package, please send an email to security@tidelift.com. All security vulnerabilities will be promptly addressed. Please do not disclose security-related issues publicly until a fix has been announced. Please see [Security Policy](https://github.com/guzzle/psr7/security/policy) for more information.
+
+
+## License
+
+Guzzle is made available under the MIT License (MIT). Please see [License File](LICENSE) for more information.
+
+
+## For Enterprise
+
+Available as part of the Tidelift Subscription
+
+The maintainers of Guzzle and thousands of other packages are working with Tidelift to deliver commercial support and maintenance for the open source dependencies you use to build your applications. Save time, reduce risk, and improve code health, while paying the maintainers of the exact dependencies you use. [Learn more.](https://tidelift.com/subscription/pkg/packagist-guzzlehttp-psr7?utm_source=packagist-guzzlehttp-psr7&utm_medium=referral&utm_campaign=enterprise&utm_term=repo)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/composer.json
new file mode 100644
index 0000000..c0e7236
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/composer.json
@@ -0,0 +1,93 @@
+{
+ "name": "guzzlehttp/psr7",
+ "description": "PSR-7 message implementation that also provides common utility methods",
+ "keywords": [
+ "request",
+ "response",
+ "message",
+ "stream",
+ "http",
+ "uri",
+ "url",
+ "psr-7"
+ ],
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "Graham Campbell",
+ "email": "hello@gjcampbell.co.uk",
+ "homepage": "https://github.com/GrahamCampbell"
+ },
+ {
+ "name": "Michael Dowling",
+ "email": "mtdowling@gmail.com",
+ "homepage": "https://github.com/mtdowling"
+ },
+ {
+ "name": "George Mponos",
+ "email": "gmponos@gmail.com",
+ "homepage": "https://github.com/gmponos"
+ },
+ {
+ "name": "Tobias Nyholm",
+ "email": "tobias.nyholm@gmail.com",
+ "homepage": "https://github.com/Nyholm"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://github.com/sagikazarmark"
+ },
+ {
+ "name": "Tobias Schultze",
+ "email": "webmaster@tubo-world.de",
+ "homepage": "https://github.com/Tobion"
+ },
+ {
+ "name": "Márk Sági-Kazár",
+ "email": "mark.sagikazar@gmail.com",
+ "homepage": "https://sagikazarmark.hu"
+ }
+ ],
+ "require": {
+ "php": "^7.2.5 || ^8.0",
+ "psr/http-factory": "^1.0",
+ "psr/http-message": "^1.0",
+ "ralouphie/getallheaders": "^3.0"
+ },
+ "provide": {
+ "psr/http-factory-implementation": "1.0",
+ "psr/http-message-implementation": "1.0"
+ },
+ "require-dev": {
+ "bamarni/composer-bin-plugin": "^1.8.1",
+ "http-interop/http-factory-tests": "^0.9",
+ "phpunit/phpunit": "^8.5.29 || ^9.5.23"
+ },
+ "suggest": {
+ "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses"
+ },
+ "autoload": {
+ "psr-4": {
+ "GuzzleHttp\\Psr7\\": "src/"
+ }
+ },
+ "autoload-dev": {
+ "psr-4": {
+ "GuzzleHttp\\Tests\\Psr7\\": "tests/"
+ }
+ },
+ "extra": {
+ "bamarni-bin": {
+ "bin-links": true,
+ "forward-command": false
+ }
+ },
+ "config": {
+ "allow-plugins": {
+ "bamarni/composer-bin-plugin": true
+ },
+ "preferred-install": "dist",
+ "sort-packages": true
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/AppendStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/AppendStream.php
new file mode 100644
index 0000000..cbcfaee
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/AppendStream.php
@@ -0,0 +1,248 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Reads from multiple streams, one after the other.
+ *
+ * This is a read-only stream decorator.
+ */
+final class AppendStream implements StreamInterface
+{
+ /** @var StreamInterface[] Streams being decorated */
+ private $streams = [];
+
+ /** @var bool */
+ private $seekable = true;
+
+ /** @var int */
+ private $current = 0;
+
+ /** @var int */
+ private $pos = 0;
+
+ /**
+ * @param StreamInterface[] $streams Streams to decorate. Each stream must
+ * be readable.
+ */
+ public function __construct(array $streams = [])
+ {
+ foreach ($streams as $stream) {
+ $this->addStream($stream);
+ }
+ }
+
+ public function __toString(): string
+ {
+ try {
+ $this->rewind();
+ return $this->getContents();
+ } catch (\Throwable $e) {
+ if (\PHP_VERSION_ID >= 70400) {
+ throw $e;
+ }
+ trigger_error(sprintf('%s::__toString exception: %s', self::class, (string) $e), E_USER_ERROR);
+ return '';
+ }
+ }
+
+ /**
+ * Add a stream to the AppendStream
+ *
+ * @param StreamInterface $stream Stream to append. Must be readable.
+ *
+ * @throws \InvalidArgumentException if the stream is not readable
+ */
+ public function addStream(StreamInterface $stream): void
+ {
+ if (!$stream->isReadable()) {
+ throw new \InvalidArgumentException('Each stream must be readable');
+ }
+
+ // The stream is only seekable if all streams are seekable
+ if (!$stream->isSeekable()) {
+ $this->seekable = false;
+ }
+
+ $this->streams[] = $stream;
+ }
+
+ public function getContents(): string
+ {
+ return Utils::copyToString($this);
+ }
+
+ /**
+ * Closes each attached stream.
+ */
+ public function close(): void
+ {
+ $this->pos = $this->current = 0;
+ $this->seekable = true;
+
+ foreach ($this->streams as $stream) {
+ $stream->close();
+ }
+
+ $this->streams = [];
+ }
+
+ /**
+ * Detaches each attached stream.
+ *
+ * Returns null as it's not clear which underlying stream resource to return.
+ */
+ public function detach()
+ {
+ $this->pos = $this->current = 0;
+ $this->seekable = true;
+
+ foreach ($this->streams as $stream) {
+ $stream->detach();
+ }
+
+ $this->streams = [];
+
+ return null;
+ }
+
+ public function tell(): int
+ {
+ return $this->pos;
+ }
+
+ /**
+ * Tries to calculate the size by adding the size of each stream.
+ *
+ * If any of the streams do not return a valid number, then the size of the
+ * append stream cannot be determined and null is returned.
+ */
+ public function getSize(): ?int
+ {
+ $size = 0;
+
+ foreach ($this->streams as $stream) {
+ $s = $stream->getSize();
+ if ($s === null) {
+ return null;
+ }
+ $size += $s;
+ }
+
+ return $size;
+ }
+
+ public function eof(): bool
+ {
+ return !$this->streams ||
+ ($this->current >= count($this->streams) - 1 &&
+ $this->streams[$this->current]->eof());
+ }
+
+ public function rewind(): void
+ {
+ $this->seek(0);
+ }
+
+ /**
+ * Attempts to seek to the given position. Only supports SEEK_SET.
+ */
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ if (!$this->seekable) {
+ throw new \RuntimeException('This AppendStream is not seekable');
+ } elseif ($whence !== SEEK_SET) {
+ throw new \RuntimeException('The AppendStream can only seek with SEEK_SET');
+ }
+
+ $this->pos = $this->current = 0;
+
+ // Rewind each stream
+ foreach ($this->streams as $i => $stream) {
+ try {
+ $stream->rewind();
+ } catch (\Exception $e) {
+ throw new \RuntimeException('Unable to seek stream '
+ . $i . ' of the AppendStream', 0, $e);
+ }
+ }
+
+ // Seek to the actual position by reading from each stream
+ while ($this->pos < $offset && !$this->eof()) {
+ $result = $this->read(min(8096, $offset - $this->pos));
+ if ($result === '') {
+ break;
+ }
+ }
+ }
+
+ /**
+ * Reads from all of the appended streams until the length is met or EOF.
+ */
+ public function read($length): string
+ {
+ $buffer = '';
+ $total = count($this->streams) - 1;
+ $remaining = $length;
+ $progressToNext = false;
+
+ while ($remaining > 0) {
+ // Progress to the next stream if needed.
+ if ($progressToNext || $this->streams[$this->current]->eof()) {
+ $progressToNext = false;
+ if ($this->current === $total) {
+ break;
+ }
+ $this->current++;
+ }
+
+ $result = $this->streams[$this->current]->read($remaining);
+
+ if ($result === '') {
+ $progressToNext = true;
+ continue;
+ }
+
+ $buffer .= $result;
+ $remaining = $length - strlen($buffer);
+ }
+
+ $this->pos += strlen($buffer);
+
+ return $buffer;
+ }
+
+ public function isReadable(): bool
+ {
+ return true;
+ }
+
+ public function isWritable(): bool
+ {
+ return false;
+ }
+
+ public function isSeekable(): bool
+ {
+ return $this->seekable;
+ }
+
+ public function write($string): int
+ {
+ throw new \RuntimeException('Cannot write to an AppendStream');
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return mixed
+ */
+ public function getMetadata($key = null)
+ {
+ return $key ? null : [];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/BufferStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/BufferStream.php
new file mode 100644
index 0000000..21be8c0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/BufferStream.php
@@ -0,0 +1,149 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Provides a buffer stream that can be written to to fill a buffer, and read
+ * from to remove bytes from the buffer.
+ *
+ * This stream returns a "hwm" metadata value that tells upstream consumers
+ * what the configured high water mark of the stream is, or the maximum
+ * preferred size of the buffer.
+ */
+final class BufferStream implements StreamInterface
+{
+ /** @var int */
+ private $hwm;
+
+ /** @var string */
+ private $buffer = '';
+
+ /**
+ * @param int $hwm High water mark, representing the preferred maximum
+ * buffer size. If the size of the buffer exceeds the high
+ * water mark, then calls to write will continue to succeed
+ * but will return 0 to inform writers to slow down
+ * until the buffer has been drained by reading from it.
+ */
+ public function __construct(int $hwm = 16384)
+ {
+ $this->hwm = $hwm;
+ }
+
+ public function __toString(): string
+ {
+ return $this->getContents();
+ }
+
+ public function getContents(): string
+ {
+ $buffer = $this->buffer;
+ $this->buffer = '';
+
+ return $buffer;
+ }
+
+ public function close(): void
+ {
+ $this->buffer = '';
+ }
+
+ public function detach()
+ {
+ $this->close();
+
+ return null;
+ }
+
+ public function getSize(): ?int
+ {
+ return strlen($this->buffer);
+ }
+
+ public function isReadable(): bool
+ {
+ return true;
+ }
+
+ public function isWritable(): bool
+ {
+ return true;
+ }
+
+ public function isSeekable(): bool
+ {
+ return false;
+ }
+
+ public function rewind(): void
+ {
+ $this->seek(0);
+ }
+
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ throw new \RuntimeException('Cannot seek a BufferStream');
+ }
+
+ public function eof(): bool
+ {
+ return strlen($this->buffer) === 0;
+ }
+
+ public function tell(): int
+ {
+ throw new \RuntimeException('Cannot determine the position of a BufferStream');
+ }
+
+ /**
+ * Reads data from the buffer.
+ */
+ public function read($length): string
+ {
+ $currentLength = strlen($this->buffer);
+
+ if ($length >= $currentLength) {
+ // No need to slice the buffer because we don't have enough data.
+ $result = $this->buffer;
+ $this->buffer = '';
+ } else {
+ // Slice up the result to provide a subset of the buffer.
+ $result = substr($this->buffer, 0, $length);
+ $this->buffer = substr($this->buffer, $length);
+ }
+
+ return $result;
+ }
+
+ /**
+ * Writes data to the buffer.
+ */
+ public function write($string): int
+ {
+ $this->buffer .= $string;
+
+ if (strlen($this->buffer) >= $this->hwm) {
+ return 0;
+ }
+
+ return strlen($string);
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return mixed
+ */
+ public function getMetadata($key = null)
+ {
+ if ($key === 'hwm') {
+ return $this->hwm;
+ }
+
+ return $key ? null : [];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/CachingStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/CachingStream.php
new file mode 100644
index 0000000..f34722c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/CachingStream.php
@@ -0,0 +1,153 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Stream decorator that can cache previously read bytes from a sequentially
+ * read stream.
+ */
+final class CachingStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ /** @var StreamInterface Stream being wrapped */
+ private $remoteStream;
+
+ /** @var int Number of bytes to skip reading due to a write on the buffer */
+ private $skipReadBytes = 0;
+
+ /**
+ * @var StreamInterface
+ */
+ private $stream;
+
+ /**
+ * We will treat the buffer object as the body of the stream
+ *
+ * @param StreamInterface $stream Stream to cache. The cursor is assumed to be at the beginning of the stream.
+ * @param StreamInterface $target Optionally specify where data is cached
+ */
+ public function __construct(
+ StreamInterface $stream,
+ StreamInterface $target = null
+ ) {
+ $this->remoteStream = $stream;
+ $this->stream = $target ?: new Stream(Utils::tryFopen('php://temp', 'r+'));
+ }
+
+ public function getSize(): ?int
+ {
+ $remoteSize = $this->remoteStream->getSize();
+
+ if (null === $remoteSize) {
+ return null;
+ }
+
+ return max($this->stream->getSize(), $remoteSize);
+ }
+
+ public function rewind(): void
+ {
+ $this->seek(0);
+ }
+
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ if ($whence === SEEK_SET) {
+ $byte = $offset;
+ } elseif ($whence === SEEK_CUR) {
+ $byte = $offset + $this->tell();
+ } elseif ($whence === SEEK_END) {
+ $size = $this->remoteStream->getSize();
+ if ($size === null) {
+ $size = $this->cacheEntireStream();
+ }
+ $byte = $size + $offset;
+ } else {
+ throw new \InvalidArgumentException('Invalid whence');
+ }
+
+ $diff = $byte - $this->stream->getSize();
+
+ if ($diff > 0) {
+ // Read the remoteStream until we have read in at least the amount
+ // of bytes requested, or we reach the end of the file.
+ while ($diff > 0 && !$this->remoteStream->eof()) {
+ $this->read($diff);
+ $diff = $byte - $this->stream->getSize();
+ }
+ } else {
+ // We can just do a normal seek since we've already seen this byte.
+ $this->stream->seek($byte);
+ }
+ }
+
+ public function read($length): string
+ {
+ // Perform a regular read on any previously read data from the buffer
+ $data = $this->stream->read($length);
+ $remaining = $length - strlen($data);
+
+ // More data was requested so read from the remote stream
+ if ($remaining) {
+ // If data was written to the buffer in a position that would have
+ // been filled from the remote stream, then we must skip bytes on
+ // the remote stream to emulate overwriting bytes from that
+ // position. This mimics the behavior of other PHP stream wrappers.
+ $remoteData = $this->remoteStream->read(
+ $remaining + $this->skipReadBytes
+ );
+
+ if ($this->skipReadBytes) {
+ $len = strlen($remoteData);
+ $remoteData = substr($remoteData, $this->skipReadBytes);
+ $this->skipReadBytes = max(0, $this->skipReadBytes - $len);
+ }
+
+ $data .= $remoteData;
+ $this->stream->write($remoteData);
+ }
+
+ return $data;
+ }
+
+ public function write($string): int
+ {
+ // When appending to the end of the currently read stream, you'll want
+ // to skip bytes from being read from the remote stream to emulate
+ // other stream wrappers. Basically replacing bytes of data of a fixed
+ // length.
+ $overflow = (strlen($string) + $this->tell()) - $this->remoteStream->tell();
+ if ($overflow > 0) {
+ $this->skipReadBytes += $overflow;
+ }
+
+ return $this->stream->write($string);
+ }
+
+ public function eof(): bool
+ {
+ return $this->stream->eof() && $this->remoteStream->eof();
+ }
+
+ /**
+ * Close both the remote stream and buffer stream
+ */
+ public function close(): void
+ {
+ $this->remoteStream->close();
+ $this->stream->close();
+ }
+
+ private function cacheEntireStream(): int
+ {
+ $target = new FnStream(['write' => 'strlen']);
+ Utils::copyToStream($this, $target);
+
+ return $this->tell();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/DroppingStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/DroppingStream.php
new file mode 100644
index 0000000..6e3d209
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/DroppingStream.php
@@ -0,0 +1,49 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Stream decorator that begins dropping data once the size of the underlying
+ * stream becomes too full.
+ */
+final class DroppingStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ /** @var int */
+ private $maxLength;
+
+ /** @var StreamInterface */
+ private $stream;
+
+ /**
+ * @param StreamInterface $stream Underlying stream to decorate.
+ * @param int $maxLength Maximum size before dropping data.
+ */
+ public function __construct(StreamInterface $stream, int $maxLength)
+ {
+ $this->stream = $stream;
+ $this->maxLength = $maxLength;
+ }
+
+ public function write($string): int
+ {
+ $diff = $this->maxLength - $this->stream->getSize();
+
+ // Begin returning 0 when the underlying stream is too large.
+ if ($diff <= 0) {
+ return 0;
+ }
+
+ // Write the stream or a subset of the stream if needed.
+ if (strlen($string) < $diff) {
+ return $this->stream->write($string);
+ }
+
+ return $this->stream->write(substr($string, 0, $diff));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Exception/MalformedUriException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Exception/MalformedUriException.php
new file mode 100644
index 0000000..3a08477
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Exception/MalformedUriException.php
@@ -0,0 +1,14 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7\Exception;
+
+use InvalidArgumentException;
+
+/**
+ * Exception thrown if a URI cannot be parsed because it's malformed.
+ */
+class MalformedUriException extends InvalidArgumentException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/FnStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/FnStream.php
new file mode 100644
index 0000000..3a1a951
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/FnStream.php
@@ -0,0 +1,180 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Compose stream implementations based on a hash of functions.
+ *
+ * Allows for easy testing and extension of a provided stream without needing
+ * to create a concrete class for a simple extension point.
+ */
+#[\AllowDynamicProperties]
+final class FnStream implements StreamInterface
+{
+ private const SLOTS = [
+ '__toString', 'close', 'detach', 'rewind',
+ 'getSize', 'tell', 'eof', 'isSeekable', 'seek', 'isWritable', 'write',
+ 'isReadable', 'read', 'getContents', 'getMetadata'
+ ];
+
+ /** @var array<string, callable> */
+ private $methods;
+
+ /**
+ * @param array<string, callable> $methods Hash of method name to a callable.
+ */
+ public function __construct(array $methods)
+ {
+ $this->methods = $methods;
+
+ // Create the functions on the class
+ foreach ($methods as $name => $fn) {
+ $this->{'_fn_' . $name} = $fn;
+ }
+ }
+
+ /**
+ * Lazily determine which methods are not implemented.
+ *
+ * @throws \BadMethodCallException
+ */
+ public function __get(string $name): void
+ {
+ throw new \BadMethodCallException(str_replace('_fn_', '', $name)
+ . '() is not implemented in the FnStream');
+ }
+
+ /**
+ * The close method is called on the underlying stream only if possible.
+ */
+ public function __destruct()
+ {
+ if (isset($this->_fn_close)) {
+ call_user_func($this->_fn_close);
+ }
+ }
+
+ /**
+ * An unserialize would allow the __destruct to run when the unserialized value goes out of scope.
+ *
+ * @throws \LogicException
+ */
+ public function __wakeup(): void
+ {
+ throw new \LogicException('FnStream should never be unserialized');
+ }
+
+ /**
+ * Adds custom functionality to an underlying stream by intercepting
+ * specific method calls.
+ *
+ * @param StreamInterface $stream Stream to decorate
+ * @param array<string, callable> $methods Hash of method name to a closure
+ *
+ * @return FnStream
+ */
+ public static function decorate(StreamInterface $stream, array $methods)
+ {
+ // If any of the required methods were not provided, then simply
+ // proxy to the decorated stream.
+ foreach (array_diff(self::SLOTS, array_keys($methods)) as $diff) {
+ /** @var callable $callable */
+ $callable = [$stream, $diff];
+ $methods[$diff] = $callable;
+ }
+
+ return new self($methods);
+ }
+
+ public function __toString(): string
+ {
+ try {
+ return call_user_func($this->_fn___toString);
+ } catch (\Throwable $e) {
+ if (\PHP_VERSION_ID >= 70400) {
+ throw $e;
+ }
+ trigger_error(sprintf('%s::__toString exception: %s', self::class, (string) $e), E_USER_ERROR);
+ return '';
+ }
+ }
+
+ public function close(): void
+ {
+ call_user_func($this->_fn_close);
+ }
+
+ public function detach()
+ {
+ return call_user_func($this->_fn_detach);
+ }
+
+ public function getSize(): ?int
+ {
+ return call_user_func($this->_fn_getSize);
+ }
+
+ public function tell(): int
+ {
+ return call_user_func($this->_fn_tell);
+ }
+
+ public function eof(): bool
+ {
+ return call_user_func($this->_fn_eof);
+ }
+
+ public function isSeekable(): bool
+ {
+ return call_user_func($this->_fn_isSeekable);
+ }
+
+ public function rewind(): void
+ {
+ call_user_func($this->_fn_rewind);
+ }
+
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ call_user_func($this->_fn_seek, $offset, $whence);
+ }
+
+ public function isWritable(): bool
+ {
+ return call_user_func($this->_fn_isWritable);
+ }
+
+ public function write($string): int
+ {
+ return call_user_func($this->_fn_write, $string);
+ }
+
+ public function isReadable(): bool
+ {
+ return call_user_func($this->_fn_isReadable);
+ }
+
+ public function read($length): string
+ {
+ return call_user_func($this->_fn_read, $length);
+ }
+
+ public function getContents(): string
+ {
+ return call_user_func($this->_fn_getContents);
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return mixed
+ */
+ public function getMetadata($key = null)
+ {
+ return call_user_func($this->_fn_getMetadata, $key);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Header.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Header.php
new file mode 100644
index 0000000..4d7005b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Header.php
@@ -0,0 +1,134 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+final class Header
+{
+ /**
+ * Parse an array of header values containing ";" separated data into an
+ * array of associative arrays representing the header key value pair data
+ * of the header. When a parameter does not contain a value, but just
+ * contains a key, this function will inject a key with a '' string value.
+ *
+ * @param string|array $header Header to parse into components.
+ */
+ public static function parse($header): array
+ {
+ static $trimmed = "\"' \n\t\r";
+ $params = $matches = [];
+
+ foreach ((array) $header as $value) {
+ foreach (self::splitList($value) as $val) {
+ $part = [];
+ foreach (preg_split('/;(?=([^"]*"[^"]*")*[^"]*$)/', $val) as $kvp) {
+ if (preg_match_all('/<[^>]+>|[^=]+/', $kvp, $matches)) {
+ $m = $matches[0];
+ if (isset($m[1])) {
+ $part[trim($m[0], $trimmed)] = trim($m[1], $trimmed);
+ } else {
+ $part[] = trim($m[0], $trimmed);
+ }
+ }
+ }
+ if ($part) {
+ $params[] = $part;
+ }
+ }
+ }
+
+ return $params;
+ }
+
+ /**
+ * Converts an array of header values that may contain comma separated
+ * headers into an array of headers with no comma separated values.
+ *
+ * @param string|array $header Header to normalize.
+ *
+ * @deprecated Use self::splitList() instead.
+ */
+ public static function normalize($header): array
+ {
+ $result = [];
+ foreach ((array) $header as $value) {
+ foreach (self::splitList($value) as $parsed) {
+ $result[] = $parsed;
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Splits a HTTP header defined to contain a comma-separated list into
+ * each individual value. Empty values will be removed.
+ *
+ * Example headers include 'accept', 'cache-control' and 'if-none-match'.
+ *
+ * This method must not be used to parse headers that are not defined as
+ * a list, such as 'user-agent' or 'set-cookie'.
+ *
+ * @param string|string[] $values Header value as returned by MessageInterface::getHeader()
+ *
+ * @return string[]
+ */
+ public static function splitList($values): array
+ {
+ if (!\is_array($values)) {
+ $values = [$values];
+ }
+
+ $result = [];
+ foreach ($values as $value) {
+ if (!\is_string($value)) {
+ throw new \TypeError('$header must either be a string or an array containing strings.');
+ }
+
+ $v = '';
+ $isQuoted = false;
+ $isEscaped = false;
+ for ($i = 0, $max = \strlen($value); $i < $max; $i++) {
+ if ($isEscaped) {
+ $v .= $value[$i];
+ $isEscaped = false;
+
+ continue;
+ }
+
+ if (!$isQuoted && $value[$i] === ',') {
+ $v = \trim($v);
+ if ($v !== '') {
+ $result[] = $v;
+ }
+
+ $v = '';
+ continue;
+ }
+
+ if ($isQuoted && $value[$i] === '\\') {
+ $isEscaped = true;
+ $v .= $value[$i];
+
+ continue;
+ }
+ if ($value[$i] === '"') {
+ $isQuoted = !$isQuoted;
+ $v .= $value[$i];
+
+ continue;
+ }
+
+ $v .= $value[$i];
+ }
+
+ $v = \trim($v);
+ if ($v !== '') {
+ $result[] = $v;
+ }
+ }
+
+ return $result;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/HttpFactory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/HttpFactory.php
new file mode 100644
index 0000000..30be222
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/HttpFactory.php
@@ -0,0 +1,100 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\RequestFactoryInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseFactoryInterface;
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\ServerRequestFactoryInterface;
+use Psr\Http\Message\ServerRequestInterface;
+use Psr\Http\Message\StreamFactoryInterface;
+use Psr\Http\Message\StreamInterface;
+use Psr\Http\Message\UploadedFileFactoryInterface;
+use Psr\Http\Message\UploadedFileInterface;
+use Psr\Http\Message\UriFactoryInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Implements all of the PSR-17 interfaces.
+ *
+ * Note: in consuming code it is recommended to require the implemented interfaces
+ * and inject the instance of this class multiple times.
+ */
+final class HttpFactory implements
+ RequestFactoryInterface,
+ ResponseFactoryInterface,
+ ServerRequestFactoryInterface,
+ StreamFactoryInterface,
+ UploadedFileFactoryInterface,
+ UriFactoryInterface
+{
+ public function createUploadedFile(
+ StreamInterface $stream,
+ int $size = null,
+ int $error = \UPLOAD_ERR_OK,
+ string $clientFilename = null,
+ string $clientMediaType = null
+ ): UploadedFileInterface {
+ if ($size === null) {
+ $size = $stream->getSize();
+ }
+
+ return new UploadedFile($stream, $size, $error, $clientFilename, $clientMediaType);
+ }
+
+ public function createStream(string $content = ''): StreamInterface
+ {
+ return Utils::streamFor($content);
+ }
+
+ public function createStreamFromFile(string $file, string $mode = 'r'): StreamInterface
+ {
+ try {
+ $resource = Utils::tryFopen($file, $mode);
+ } catch (\RuntimeException $e) {
+ if ('' === $mode || false === \in_array($mode[0], ['r', 'w', 'a', 'x', 'c'], true)) {
+ throw new \InvalidArgumentException(sprintf('Invalid file opening mode "%s"', $mode), 0, $e);
+ }
+
+ throw $e;
+ }
+
+ return Utils::streamFor($resource);
+ }
+
+ public function createStreamFromResource($resource): StreamInterface
+ {
+ return Utils::streamFor($resource);
+ }
+
+ public function createServerRequest(string $method, $uri, array $serverParams = []): ServerRequestInterface
+ {
+ if (empty($method)) {
+ if (!empty($serverParams['REQUEST_METHOD'])) {
+ $method = $serverParams['REQUEST_METHOD'];
+ } else {
+ throw new \InvalidArgumentException('Cannot determine HTTP method');
+ }
+ }
+
+ return new ServerRequest($method, $uri, [], null, '1.1', $serverParams);
+ }
+
+ public function createResponse(int $code = 200, string $reasonPhrase = ''): ResponseInterface
+ {
+ return new Response($code, [], null, '1.1', $reasonPhrase);
+ }
+
+ public function createRequest(string $method, $uri): RequestInterface
+ {
+ return new Request($method, $uri);
+ }
+
+ public function createUri(string $uri = ''): UriInterface
+ {
+ return new Uri($uri);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/InflateStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/InflateStream.php
new file mode 100644
index 0000000..8e00f1c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/InflateStream.php
@@ -0,0 +1,37 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Uses PHP's zlib.inflate filter to inflate zlib (HTTP deflate, RFC1950) or gzipped (RFC1952) content.
+ *
+ * This stream decorator converts the provided stream to a PHP stream resource,
+ * then appends the zlib.inflate filter. The stream is then converted back
+ * to a Guzzle stream resource to be used as a Guzzle stream.
+ *
+ * @link http://tools.ietf.org/html/rfc1950
+ * @link http://tools.ietf.org/html/rfc1952
+ * @link http://php.net/manual/en/filters.compression.php
+ */
+final class InflateStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ /** @var StreamInterface */
+ private $stream;
+
+ public function __construct(StreamInterface $stream)
+ {
+ $resource = StreamWrapper::getResource($stream);
+ // Specify window=15+32, so zlib will use header detection to both gzip (with header) and zlib data
+ // See http://www.zlib.net/manual.html#Advanced definition of inflateInit2
+ // "Add 32 to windowBits to enable zlib and gzip decoding with automatic header detection"
+ // Default window size is 15.
+ stream_filter_append($resource, 'zlib.inflate', STREAM_FILTER_READ, ['window' => 15 + 32]);
+ $this->stream = $stream->isSeekable() ? new Stream($resource) : new NoSeekStream(new Stream($resource));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/LazyOpenStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/LazyOpenStream.php
new file mode 100644
index 0000000..f6c8490
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/LazyOpenStream.php
@@ -0,0 +1,49 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Lazily reads or writes to a file that is opened only after an IO operation
+ * take place on the stream.
+ */
+final class LazyOpenStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ /** @var string */
+ private $filename;
+
+ /** @var string */
+ private $mode;
+
+ /**
+ * @var StreamInterface
+ */
+ private $stream;
+
+ /**
+ * @param string $filename File to lazily open
+ * @param string $mode fopen mode to use when opening the stream
+ */
+ public function __construct(string $filename, string $mode)
+ {
+ $this->filename = $filename;
+ $this->mode = $mode;
+
+ // unsetting the property forces the first access to go through
+ // __get().
+ unset($this->stream);
+ }
+
+ /**
+ * Creates the underlying stream lazily when required.
+ */
+ protected function createStream(): StreamInterface
+ {
+ return Utils::streamFor(Utils::tryFopen($this->filename, $this->mode));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/LimitStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/LimitStream.php
new file mode 100644
index 0000000..fb22325
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/LimitStream.php
@@ -0,0 +1,157 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Decorator used to return only a subset of a stream.
+ */
+final class LimitStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ /** @var int Offset to start reading from */
+ private $offset;
+
+ /** @var int Limit the number of bytes that can be read */
+ private $limit;
+
+ /** @var StreamInterface */
+ private $stream;
+
+ /**
+ * @param StreamInterface $stream Stream to wrap
+ * @param int $limit Total number of bytes to allow to be read
+ * from the stream. Pass -1 for no limit.
+ * @param int $offset Position to seek to before reading (only
+ * works on seekable streams).
+ */
+ public function __construct(
+ StreamInterface $stream,
+ int $limit = -1,
+ int $offset = 0
+ ) {
+ $this->stream = $stream;
+ $this->setLimit($limit);
+ $this->setOffset($offset);
+ }
+
+ public function eof(): bool
+ {
+ // Always return true if the underlying stream is EOF
+ if ($this->stream->eof()) {
+ return true;
+ }
+
+ // No limit and the underlying stream is not at EOF
+ if ($this->limit === -1) {
+ return false;
+ }
+
+ return $this->stream->tell() >= $this->offset + $this->limit;
+ }
+
+ /**
+ * Returns the size of the limited subset of data
+ */
+ public function getSize(): ?int
+ {
+ if (null === ($length = $this->stream->getSize())) {
+ return null;
+ } elseif ($this->limit === -1) {
+ return $length - $this->offset;
+ } else {
+ return min($this->limit, $length - $this->offset);
+ }
+ }
+
+ /**
+ * Allow for a bounded seek on the read limited stream
+ */
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ if ($whence !== SEEK_SET || $offset < 0) {
+ throw new \RuntimeException(sprintf(
+ 'Cannot seek to offset %s with whence %s',
+ $offset,
+ $whence
+ ));
+ }
+
+ $offset += $this->offset;
+
+ if ($this->limit !== -1) {
+ if ($offset > $this->offset + $this->limit) {
+ $offset = $this->offset + $this->limit;
+ }
+ }
+
+ $this->stream->seek($offset);
+ }
+
+ /**
+ * Give a relative tell()
+ */
+ public function tell(): int
+ {
+ return $this->stream->tell() - $this->offset;
+ }
+
+ /**
+ * Set the offset to start limiting from
+ *
+ * @param int $offset Offset to seek to and begin byte limiting from
+ *
+ * @throws \RuntimeException if the stream cannot be seeked.
+ */
+ public function setOffset(int $offset): void
+ {
+ $current = $this->stream->tell();
+
+ if ($current !== $offset) {
+ // If the stream cannot seek to the offset position, then read to it
+ if ($this->stream->isSeekable()) {
+ $this->stream->seek($offset);
+ } elseif ($current > $offset) {
+ throw new \RuntimeException("Could not seek to stream offset $offset");
+ } else {
+ $this->stream->read($offset - $current);
+ }
+ }
+
+ $this->offset = $offset;
+ }
+
+ /**
+ * Set the limit of bytes that the decorator allows to be read from the
+ * stream.
+ *
+ * @param int $limit Number of bytes to allow to be read from the stream.
+ * Use -1 for no limit.
+ */
+ public function setLimit(int $limit): void
+ {
+ $this->limit = $limit;
+ }
+
+ public function read($length): string
+ {
+ if ($this->limit === -1) {
+ return $this->stream->read($length);
+ }
+
+ // Check if the current position is less than the total allowed
+ // bytes + original offset
+ $remaining = ($this->offset + $this->limit) - $this->stream->tell();
+ if ($remaining > 0) {
+ // Only return the amount of requested data, ensuring that the byte
+ // limit is not exceeded
+ return $this->stream->read(min($remaining, $length));
+ }
+
+ return '';
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Message.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Message.php
new file mode 100644
index 0000000..c1e15f8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Message.php
@@ -0,0 +1,246 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\MessageInterface;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+final class Message
+{
+ /**
+ * Returns the string representation of an HTTP message.
+ *
+ * @param MessageInterface $message Message to convert to a string.
+ */
+ public static function toString(MessageInterface $message): string
+ {
+ if ($message instanceof RequestInterface) {
+ $msg = trim($message->getMethod() . ' '
+ . $message->getRequestTarget())
+ . ' HTTP/' . $message->getProtocolVersion();
+ if (!$message->hasHeader('host')) {
+ $msg .= "\r\nHost: " . $message->getUri()->getHost();
+ }
+ } elseif ($message instanceof ResponseInterface) {
+ $msg = 'HTTP/' . $message->getProtocolVersion() . ' '
+ . $message->getStatusCode() . ' '
+ . $message->getReasonPhrase();
+ } else {
+ throw new \InvalidArgumentException('Unknown message type');
+ }
+
+ foreach ($message->getHeaders() as $name => $values) {
+ if (strtolower($name) === 'set-cookie') {
+ foreach ($values as $value) {
+ $msg .= "\r\n{$name}: " . $value;
+ }
+ } else {
+ $msg .= "\r\n{$name}: " . implode(', ', $values);
+ }
+ }
+
+ return "{$msg}\r\n\r\n" . $message->getBody();
+ }
+
+ /**
+ * Get a short summary of the message body.
+ *
+ * Will return `null` if the response is not printable.
+ *
+ * @param MessageInterface $message The message to get the body summary
+ * @param int $truncateAt The maximum allowed size of the summary
+ */
+ public static function bodySummary(MessageInterface $message, int $truncateAt = 120): ?string
+ {
+ $body = $message->getBody();
+
+ if (!$body->isSeekable() || !$body->isReadable()) {
+ return null;
+ }
+
+ $size = $body->getSize();
+
+ if ($size === 0) {
+ return null;
+ }
+
+ $body->rewind();
+ $summary = $body->read($truncateAt);
+ $body->rewind();
+
+ if ($size > $truncateAt) {
+ $summary .= ' (truncated...)';
+ }
+
+ // Matches any printable character, including unicode characters:
+ // letters, marks, numbers, punctuation, spacing, and separators.
+ if (preg_match('/[^\pL\pM\pN\pP\pS\pZ\n\r\t]/u', $summary) !== 0) {
+ return null;
+ }
+
+ return $summary;
+ }
+
+ /**
+ * Attempts to rewind a message body and throws an exception on failure.
+ *
+ * The body of the message will only be rewound if a call to `tell()`
+ * returns a value other than `0`.
+ *
+ * @param MessageInterface $message Message to rewind
+ *
+ * @throws \RuntimeException
+ */
+ public static function rewindBody(MessageInterface $message): void
+ {
+ $body = $message->getBody();
+
+ if ($body->tell()) {
+ $body->rewind();
+ }
+ }
+
+ /**
+ * Parses an HTTP message into an associative array.
+ *
+ * The array contains the "start-line" key containing the start line of
+ * the message, "headers" key containing an associative array of header
+ * array values, and a "body" key containing the body of the message.
+ *
+ * @param string $message HTTP request or response to parse.
+ */
+ public static function parseMessage(string $message): array
+ {
+ if (!$message) {
+ throw new \InvalidArgumentException('Invalid message');
+ }
+
+ $message = ltrim($message, "\r\n");
+
+ $messageParts = preg_split("/\r?\n\r?\n/", $message, 2);
+
+ if ($messageParts === false || count($messageParts) !== 2) {
+ throw new \InvalidArgumentException('Invalid message: Missing header delimiter');
+ }
+
+ [$rawHeaders, $body] = $messageParts;
+ $rawHeaders .= "\r\n"; // Put back the delimiter we split previously
+ $headerParts = preg_split("/\r?\n/", $rawHeaders, 2);
+
+ if ($headerParts === false || count($headerParts) !== 2) {
+ throw new \InvalidArgumentException('Invalid message: Missing status line');
+ }
+
+ [$startLine, $rawHeaders] = $headerParts;
+
+ if (preg_match("/(?:^HTTP\/|^[A-Z]+ \S+ HTTP\/)(\d+(?:\.\d+)?)/i", $startLine, $matches) && $matches[1] === '1.0') {
+ // Header folding is deprecated for HTTP/1.1, but allowed in HTTP/1.0
+ $rawHeaders = preg_replace(Rfc7230::HEADER_FOLD_REGEX, ' ', $rawHeaders);
+ }
+
+ /** @var array[] $headerLines */
+ $count = preg_match_all(Rfc7230::HEADER_REGEX, $rawHeaders, $headerLines, PREG_SET_ORDER);
+
+ // If these aren't the same, then one line didn't match and there's an invalid header.
+ if ($count !== substr_count($rawHeaders, "\n")) {
+ // Folding is deprecated, see https://tools.ietf.org/html/rfc7230#section-3.2.4
+ if (preg_match(Rfc7230::HEADER_FOLD_REGEX, $rawHeaders)) {
+ throw new \InvalidArgumentException('Invalid header syntax: Obsolete line folding');
+ }
+
+ throw new \InvalidArgumentException('Invalid header syntax');
+ }
+
+ $headers = [];
+
+ foreach ($headerLines as $headerLine) {
+ $headers[$headerLine[1]][] = $headerLine[2];
+ }
+
+ return [
+ 'start-line' => $startLine,
+ 'headers' => $headers,
+ 'body' => $body,
+ ];
+ }
+
+ /**
+ * Constructs a URI for an HTTP request message.
+ *
+ * @param string $path Path from the start-line
+ * @param array $headers Array of headers (each value an array).
+ */
+ public static function parseRequestUri(string $path, array $headers): string
+ {
+ $hostKey = array_filter(array_keys($headers), function ($k) {
+ // Numeric array keys are converted to int by PHP.
+ $k = (string) $k;
+
+ return strtolower($k) === 'host';
+ });
+
+ // If no host is found, then a full URI cannot be constructed.
+ if (!$hostKey) {
+ return $path;
+ }
+
+ $host = $headers[reset($hostKey)][0];
+ $scheme = substr($host, -4) === ':443' ? 'https' : 'http';
+
+ return $scheme . '://' . $host . '/' . ltrim($path, '/');
+ }
+
+ /**
+ * Parses a request message string into a request object.
+ *
+ * @param string $message Request message string.
+ */
+ public static function parseRequest(string $message): RequestInterface
+ {
+ $data = self::parseMessage($message);
+ $matches = [];
+ if (!preg_match('/^[\S]+\s+([a-zA-Z]+:\/\/|\/).*/', $data['start-line'], $matches)) {
+ throw new \InvalidArgumentException('Invalid request string');
+ }
+ $parts = explode(' ', $data['start-line'], 3);
+ $version = isset($parts[2]) ? explode('/', $parts[2])[1] : '1.1';
+
+ $request = new Request(
+ $parts[0],
+ $matches[1] === '/' ? self::parseRequestUri($parts[1], $data['headers']) : $parts[1],
+ $data['headers'],
+ $data['body'],
+ $version
+ );
+
+ return $matches[1] === '/' ? $request : $request->withRequestTarget($parts[1]);
+ }
+
+ /**
+ * Parses a response message string into a response object.
+ *
+ * @param string $message Response message string.
+ */
+ public static function parseResponse(string $message): ResponseInterface
+ {
+ $data = self::parseMessage($message);
+ // According to https://tools.ietf.org/html/rfc7230#section-3.1.2 the space
+ // between status-code and reason-phrase is required. But browsers accept
+ // responses without space and reason as well.
+ if (!preg_match('/^HTTP\/.* [0-9]{3}( .*|$)/', $data['start-line'])) {
+ throw new \InvalidArgumentException('Invalid response string: ' . $data['start-line']);
+ }
+ $parts = explode(' ', $data['start-line'], 3);
+
+ return new Response(
+ (int) $parts[1],
+ $data['headers'],
+ $data['body'],
+ explode('/', $parts[0])[1],
+ $parts[2] ?? null
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MessageTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MessageTrait.php
new file mode 100644
index 0000000..464bdfa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MessageTrait.php
@@ -0,0 +1,263 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\MessageInterface;
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Trait implementing functionality common to requests and responses.
+ */
+trait MessageTrait
+{
+ /** @var array<string, string[]> Map of all registered headers, as original name => array of values */
+ private $headers = [];
+
+ /** @var array<string, string> Map of lowercase header name => original name at registration */
+ private $headerNames = [];
+
+ /** @var string */
+ private $protocol = '1.1';
+
+ /** @var StreamInterface|null */
+ private $stream;
+
+ public function getProtocolVersion(): string
+ {
+ return $this->protocol;
+ }
+
+ public function withProtocolVersion($version): MessageInterface
+ {
+ if ($this->protocol === $version) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->protocol = $version;
+ return $new;
+ }
+
+ public function getHeaders(): array
+ {
+ return $this->headers;
+ }
+
+ public function hasHeader($header): bool
+ {
+ return isset($this->headerNames[strtolower($header)]);
+ }
+
+ public function getHeader($header): array
+ {
+ $header = strtolower($header);
+
+ if (!isset($this->headerNames[$header])) {
+ return [];
+ }
+
+ $header = $this->headerNames[$header];
+
+ return $this->headers[$header];
+ }
+
+ public function getHeaderLine($header): string
+ {
+ return implode(', ', $this->getHeader($header));
+ }
+
+ public function withHeader($header, $value): MessageInterface
+ {
+ $this->assertHeader($header);
+ $value = $this->normalizeHeaderValue($value);
+ $normalized = strtolower($header);
+
+ $new = clone $this;
+ if (isset($new->headerNames[$normalized])) {
+ unset($new->headers[$new->headerNames[$normalized]]);
+ }
+ $new->headerNames[$normalized] = $header;
+ $new->headers[$header] = $value;
+
+ return $new;
+ }
+
+ public function withAddedHeader($header, $value): MessageInterface
+ {
+ $this->assertHeader($header);
+ $value = $this->normalizeHeaderValue($value);
+ $normalized = strtolower($header);
+
+ $new = clone $this;
+ if (isset($new->headerNames[$normalized])) {
+ $header = $this->headerNames[$normalized];
+ $new->headers[$header] = array_merge($this->headers[$header], $value);
+ } else {
+ $new->headerNames[$normalized] = $header;
+ $new->headers[$header] = $value;
+ }
+
+ return $new;
+ }
+
+ public function withoutHeader($header): MessageInterface
+ {
+ $normalized = strtolower($header);
+
+ if (!isset($this->headerNames[$normalized])) {
+ return $this;
+ }
+
+ $header = $this->headerNames[$normalized];
+
+ $new = clone $this;
+ unset($new->headers[$header], $new->headerNames[$normalized]);
+
+ return $new;
+ }
+
+ public function getBody(): StreamInterface
+ {
+ if (!$this->stream) {
+ $this->stream = Utils::streamFor('');
+ }
+
+ return $this->stream;
+ }
+
+ public function withBody(StreamInterface $body): MessageInterface
+ {
+ if ($body === $this->stream) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->stream = $body;
+ return $new;
+ }
+
+ /**
+ * @param array<string|int, string|string[]> $headers
+ */
+ private function setHeaders(array $headers): void
+ {
+ $this->headerNames = $this->headers = [];
+ foreach ($headers as $header => $value) {
+ // Numeric array keys are converted to int by PHP.
+ $header = (string) $header;
+
+ $this->assertHeader($header);
+ $value = $this->normalizeHeaderValue($value);
+ $normalized = strtolower($header);
+ if (isset($this->headerNames[$normalized])) {
+ $header = $this->headerNames[$normalized];
+ $this->headers[$header] = array_merge($this->headers[$header], $value);
+ } else {
+ $this->headerNames[$normalized] = $header;
+ $this->headers[$header] = $value;
+ }
+ }
+ }
+
+ /**
+ * @param mixed $value
+ *
+ * @return string[]
+ */
+ private function normalizeHeaderValue($value): array
+ {
+ if (!is_array($value)) {
+ return $this->trimAndValidateHeaderValues([$value]);
+ }
+
+ if (count($value) === 0) {
+ throw new \InvalidArgumentException('Header value can not be an empty array.');
+ }
+
+ return $this->trimAndValidateHeaderValues($value);
+ }
+
+ /**
+ * Trims whitespace from the header values.
+ *
+ * Spaces and tabs ought to be excluded by parsers when extracting the field value from a header field.
+ *
+ * header-field = field-name ":" OWS field-value OWS
+ * OWS = *( SP / HTAB )
+ *
+ * @param mixed[] $values Header values
+ *
+ * @return string[] Trimmed header values
+ *
+ * @see https://tools.ietf.org/html/rfc7230#section-3.2.4
+ */
+ private function trimAndValidateHeaderValues(array $values): array
+ {
+ return array_map(function ($value) {
+ if (!is_scalar($value) && null !== $value) {
+ throw new \InvalidArgumentException(sprintf(
+ 'Header value must be scalar or null but %s provided.',
+ is_object($value) ? get_class($value) : gettype($value)
+ ));
+ }
+
+ $trimmed = trim((string) $value, " \t");
+ $this->assertValue($trimmed);
+
+ return $trimmed;
+ }, array_values($values));
+ }
+
+ /**
+ * @see https://tools.ietf.org/html/rfc7230#section-3.2
+ *
+ * @param mixed $header
+ */
+ private function assertHeader($header): void
+ {
+ if (!is_string($header)) {
+ throw new \InvalidArgumentException(sprintf(
+ 'Header name must be a string but %s provided.',
+ is_object($header) ? get_class($header) : gettype($header)
+ ));
+ }
+
+ if (! preg_match('/^[a-zA-Z0-9\'`#$%&*+.^_|~!-]+$/D', $header)) {
+ throw new \InvalidArgumentException(
+ sprintf('"%s" is not valid header name.', $header)
+ );
+ }
+ }
+
+ /**
+ * @see https://tools.ietf.org/html/rfc7230#section-3.2
+ *
+ * field-value = *( field-content / obs-fold )
+ * field-content = field-vchar [ 1*( SP / HTAB ) field-vchar ]
+ * field-vchar = VCHAR / obs-text
+ * VCHAR = %x21-7E
+ * obs-text = %x80-FF
+ * obs-fold = CRLF 1*( SP / HTAB )
+ */
+ private function assertValue(string $value): void
+ {
+ // The regular expression intentionally does not support the obs-fold production, because as
+ // per RFC 7230#3.2.4:
+ //
+ // A sender MUST NOT generate a message that includes
+ // line folding (i.e., that has any field-value that contains a match to
+ // the obs-fold rule) unless the message is intended for packaging
+ // within the message/http media type.
+ //
+ // Clients must not send a request with line folding and a server sending folded headers is
+ // likely very rare. Line folding is a fairly obscure feature of HTTP/1.1 and thus not accepting
+ // folding is not likely to break any legitimate use case.
+ if (! preg_match('/^[\x20\x09\x21-\x7E\x80-\xFF]*$/D', $value)) {
+ throw new \InvalidArgumentException(
+ sprintf('"%s" is not valid header value.', $value)
+ );
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MimeType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MimeType.php
new file mode 100644
index 0000000..0debbd1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MimeType.php
@@ -0,0 +1,1237 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+final class MimeType
+{
+ private const MIME_TYPES = [
+ '1km' => 'application/vnd.1000minds.decision-model+xml',
+ '3dml' => 'text/vnd.in3d.3dml',
+ '3ds' => 'image/x-3ds',
+ '3g2' => 'video/3gpp2',
+ '3gp' => 'video/3gp',
+ '3gpp' => 'video/3gpp',
+ '3mf' => 'model/3mf',
+ '7z' => 'application/x-7z-compressed',
+ '7zip' => 'application/x-7z-compressed',
+ '123' => 'application/vnd.lotus-1-2-3',
+ 'aab' => 'application/x-authorware-bin',
+ 'aac' => 'audio/x-acc',
+ 'aam' => 'application/x-authorware-map',
+ 'aas' => 'application/x-authorware-seg',
+ 'abw' => 'application/x-abiword',
+ 'ac' => 'application/vnd.nokia.n-gage.ac+xml',
+ 'ac3' => 'audio/ac3',
+ 'acc' => 'application/vnd.americandynamics.acc',
+ 'ace' => 'application/x-ace-compressed',
+ 'acu' => 'application/vnd.acucobol',
+ 'acutc' => 'application/vnd.acucorp',
+ 'adp' => 'audio/adpcm',
+ 'aep' => 'application/vnd.audiograph',
+ 'afm' => 'application/x-font-type1',
+ 'afp' => 'application/vnd.ibm.modcap',
+ 'age' => 'application/vnd.age',
+ 'ahead' => 'application/vnd.ahead.space',
+ 'ai' => 'application/pdf',
+ 'aif' => 'audio/x-aiff',
+ 'aifc' => 'audio/x-aiff',
+ 'aiff' => 'audio/x-aiff',
+ 'air' => 'application/vnd.adobe.air-application-installer-package+zip',
+ 'ait' => 'application/vnd.dvb.ait',
+ 'ami' => 'application/vnd.amiga.ami',
+ 'amr' => 'audio/amr',
+ 'apk' => 'application/vnd.android.package-archive',
+ 'apng' => 'image/apng',
+ 'appcache' => 'text/cache-manifest',
+ 'application' => 'application/x-ms-application',
+ 'apr' => 'application/vnd.lotus-approach',
+ 'arc' => 'application/x-freearc',
+ 'arj' => 'application/x-arj',
+ 'asc' => 'application/pgp-signature',
+ 'asf' => 'video/x-ms-asf',
+ 'asm' => 'text/x-asm',
+ 'aso' => 'application/vnd.accpac.simply.aso',
+ 'asx' => 'video/x-ms-asf',
+ 'atc' => 'application/vnd.acucorp',
+ 'atom' => 'application/atom+xml',
+ 'atomcat' => 'application/atomcat+xml',
+ 'atomdeleted' => 'application/atomdeleted+xml',
+ 'atomsvc' => 'application/atomsvc+xml',
+ 'atx' => 'application/vnd.antix.game-component',
+ 'au' => 'audio/x-au',
+ 'avci' => 'image/avci',
+ 'avcs' => 'image/avcs',
+ 'avi' => 'video/x-msvideo',
+ 'avif' => 'image/avif',
+ 'aw' => 'application/applixware',
+ 'azf' => 'application/vnd.airzip.filesecure.azf',
+ 'azs' => 'application/vnd.airzip.filesecure.azs',
+ 'azv' => 'image/vnd.airzip.accelerator.azv',
+ 'azw' => 'application/vnd.amazon.ebook',
+ 'b16' => 'image/vnd.pco.b16',
+ 'bat' => 'application/x-msdownload',
+ 'bcpio' => 'application/x-bcpio',
+ 'bdf' => 'application/x-font-bdf',
+ 'bdm' => 'application/vnd.syncml.dm+wbxml',
+ 'bdoc' => 'application/x-bdoc',
+ 'bed' => 'application/vnd.realvnc.bed',
+ 'bh2' => 'application/vnd.fujitsu.oasysprs',
+ 'bin' => 'application/octet-stream',
+ 'blb' => 'application/x-blorb',
+ 'blorb' => 'application/x-blorb',
+ 'bmi' => 'application/vnd.bmi',
+ 'bmml' => 'application/vnd.balsamiq.bmml+xml',
+ 'bmp' => 'image/bmp',
+ 'book' => 'application/vnd.framemaker',
+ 'box' => 'application/vnd.previewsystems.box',
+ 'boz' => 'application/x-bzip2',
+ 'bpk' => 'application/octet-stream',
+ 'bpmn' => 'application/octet-stream',
+ 'bsp' => 'model/vnd.valve.source.compiled-map',
+ 'btif' => 'image/prs.btif',
+ 'buffer' => 'application/octet-stream',
+ 'bz' => 'application/x-bzip',
+ 'bz2' => 'application/x-bzip2',
+ 'c' => 'text/x-c',
+ 'c4d' => 'application/vnd.clonk.c4group',
+ 'c4f' => 'application/vnd.clonk.c4group',
+ 'c4g' => 'application/vnd.clonk.c4group',
+ 'c4p' => 'application/vnd.clonk.c4group',
+ 'c4u' => 'application/vnd.clonk.c4group',
+ 'c11amc' => 'application/vnd.cluetrust.cartomobile-config',
+ 'c11amz' => 'application/vnd.cluetrust.cartomobile-config-pkg',
+ 'cab' => 'application/vnd.ms-cab-compressed',
+ 'caf' => 'audio/x-caf',
+ 'cap' => 'application/vnd.tcpdump.pcap',
+ 'car' => 'application/vnd.curl.car',
+ 'cat' => 'application/vnd.ms-pki.seccat',
+ 'cb7' => 'application/x-cbr',
+ 'cba' => 'application/x-cbr',
+ 'cbr' => 'application/x-cbr',
+ 'cbt' => 'application/x-cbr',
+ 'cbz' => 'application/x-cbr',
+ 'cc' => 'text/x-c',
+ 'cco' => 'application/x-cocoa',
+ 'cct' => 'application/x-director',
+ 'ccxml' => 'application/ccxml+xml',
+ 'cdbcmsg' => 'application/vnd.contact.cmsg',
+ 'cdf' => 'application/x-netcdf',
+ 'cdfx' => 'application/cdfx+xml',
+ 'cdkey' => 'application/vnd.mediastation.cdkey',
+ 'cdmia' => 'application/cdmi-capability',
+ 'cdmic' => 'application/cdmi-container',
+ 'cdmid' => 'application/cdmi-domain',
+ 'cdmio' => 'application/cdmi-object',
+ 'cdmiq' => 'application/cdmi-queue',
+ 'cdr' => 'application/cdr',
+ 'cdx' => 'chemical/x-cdx',
+ 'cdxml' => 'application/vnd.chemdraw+xml',
+ 'cdy' => 'application/vnd.cinderella',
+ 'cer' => 'application/pkix-cert',
+ 'cfs' => 'application/x-cfs-compressed',
+ 'cgm' => 'image/cgm',
+ 'chat' => 'application/x-chat',
+ 'chm' => 'application/vnd.ms-htmlhelp',
+ 'chrt' => 'application/vnd.kde.kchart',
+ 'cif' => 'chemical/x-cif',
+ 'cii' => 'application/vnd.anser-web-certificate-issue-initiation',
+ 'cil' => 'application/vnd.ms-artgalry',
+ 'cjs' => 'application/node',
+ 'cla' => 'application/vnd.claymore',
+ 'class' => 'application/octet-stream',
+ 'clkk' => 'application/vnd.crick.clicker.keyboard',
+ 'clkp' => 'application/vnd.crick.clicker.palette',
+ 'clkt' => 'application/vnd.crick.clicker.template',
+ 'clkw' => 'application/vnd.crick.clicker.wordbank',
+ 'clkx' => 'application/vnd.crick.clicker',
+ 'clp' => 'application/x-msclip',
+ 'cmc' => 'application/vnd.cosmocaller',
+ 'cmdf' => 'chemical/x-cmdf',
+ 'cml' => 'chemical/x-cml',
+ 'cmp' => 'application/vnd.yellowriver-custom-menu',
+ 'cmx' => 'image/x-cmx',
+ 'cod' => 'application/vnd.rim.cod',
+ 'coffee' => 'text/coffeescript',
+ 'com' => 'application/x-msdownload',
+ 'conf' => 'text/plain',
+ 'cpio' => 'application/x-cpio',
+ 'cpl' => 'application/cpl+xml',
+ 'cpp' => 'text/x-c',
+ 'cpt' => 'application/mac-compactpro',
+ 'crd' => 'application/x-mscardfile',
+ 'crl' => 'application/pkix-crl',
+ 'crt' => 'application/x-x509-ca-cert',
+ 'crx' => 'application/x-chrome-extension',
+ 'cryptonote' => 'application/vnd.rig.cryptonote',
+ 'csh' => 'application/x-csh',
+ 'csl' => 'application/vnd.citationstyles.style+xml',
+ 'csml' => 'chemical/x-csml',
+ 'csp' => 'application/vnd.commonspace',
+ 'csr' => 'application/octet-stream',
+ 'css' => 'text/css',
+ 'cst' => 'application/x-director',
+ 'csv' => 'text/csv',
+ 'cu' => 'application/cu-seeme',
+ 'curl' => 'text/vnd.curl',
+ 'cww' => 'application/prs.cww',
+ 'cxt' => 'application/x-director',
+ 'cxx' => 'text/x-c',
+ 'dae' => 'model/vnd.collada+xml',
+ 'daf' => 'application/vnd.mobius.daf',
+ 'dart' => 'application/vnd.dart',
+ 'dataless' => 'application/vnd.fdsn.seed',
+ 'davmount' => 'application/davmount+xml',
+ 'dbf' => 'application/vnd.dbf',
+ 'dbk' => 'application/docbook+xml',
+ 'dcr' => 'application/x-director',
+ 'dcurl' => 'text/vnd.curl.dcurl',
+ 'dd2' => 'application/vnd.oma.dd2+xml',
+ 'ddd' => 'application/vnd.fujixerox.ddd',
+ 'ddf' => 'application/vnd.syncml.dmddf+xml',
+ 'dds' => 'image/vnd.ms-dds',
+ 'deb' => 'application/x-debian-package',
+ 'def' => 'text/plain',
+ 'deploy' => 'application/octet-stream',
+ 'der' => 'application/x-x509-ca-cert',
+ 'dfac' => 'application/vnd.dreamfactory',
+ 'dgc' => 'application/x-dgc-compressed',
+ 'dic' => 'text/x-c',
+ 'dir' => 'application/x-director',
+ 'dis' => 'application/vnd.mobius.dis',
+ 'disposition-notification' => 'message/disposition-notification',
+ 'dist' => 'application/octet-stream',
+ 'distz' => 'application/octet-stream',
+ 'djv' => 'image/vnd.djvu',
+ 'djvu' => 'image/vnd.djvu',
+ 'dll' => 'application/octet-stream',
+ 'dmg' => 'application/x-apple-diskimage',
+ 'dmn' => 'application/octet-stream',
+ 'dmp' => 'application/vnd.tcpdump.pcap',
+ 'dms' => 'application/octet-stream',
+ 'dna' => 'application/vnd.dna',
+ 'doc' => 'application/msword',
+ 'docm' => 'application/vnd.ms-word.template.macroEnabled.12',
+ 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
+ 'dot' => 'application/msword',
+ 'dotm' => 'application/vnd.ms-word.template.macroEnabled.12',
+ 'dotx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.template',
+ 'dp' => 'application/vnd.osgi.dp',
+ 'dpg' => 'application/vnd.dpgraph',
+ 'dra' => 'audio/vnd.dra',
+ 'drle' => 'image/dicom-rle',
+ 'dsc' => 'text/prs.lines.tag',
+ 'dssc' => 'application/dssc+der',
+ 'dtb' => 'application/x-dtbook+xml',
+ 'dtd' => 'application/xml-dtd',
+ 'dts' => 'audio/vnd.dts',
+ 'dtshd' => 'audio/vnd.dts.hd',
+ 'dump' => 'application/octet-stream',
+ 'dvb' => 'video/vnd.dvb.file',
+ 'dvi' => 'application/x-dvi',
+ 'dwd' => 'application/atsc-dwd+xml',
+ 'dwf' => 'model/vnd.dwf',
+ 'dwg' => 'image/vnd.dwg',
+ 'dxf' => 'image/vnd.dxf',
+ 'dxp' => 'application/vnd.spotfire.dxp',
+ 'dxr' => 'application/x-director',
+ 'ear' => 'application/java-archive',
+ 'ecelp4800' => 'audio/vnd.nuera.ecelp4800',
+ 'ecelp7470' => 'audio/vnd.nuera.ecelp7470',
+ 'ecelp9600' => 'audio/vnd.nuera.ecelp9600',
+ 'ecma' => 'application/ecmascript',
+ 'edm' => 'application/vnd.novadigm.edm',
+ 'edx' => 'application/vnd.novadigm.edx',
+ 'efif' => 'application/vnd.picsel',
+ 'ei6' => 'application/vnd.pg.osasli',
+ 'elc' => 'application/octet-stream',
+ 'emf' => 'image/emf',
+ 'eml' => 'message/rfc822',
+ 'emma' => 'application/emma+xml',
+ 'emotionml' => 'application/emotionml+xml',
+ 'emz' => 'application/x-msmetafile',
+ 'eol' => 'audio/vnd.digital-winds',
+ 'eot' => 'application/vnd.ms-fontobject',
+ 'eps' => 'application/postscript',
+ 'epub' => 'application/epub+zip',
+ 'es' => 'application/ecmascript',
+ 'es3' => 'application/vnd.eszigno3+xml',
+ 'esa' => 'application/vnd.osgi.subsystem',
+ 'esf' => 'application/vnd.epson.esf',
+ 'et3' => 'application/vnd.eszigno3+xml',
+ 'etx' => 'text/x-setext',
+ 'eva' => 'application/x-eva',
+ 'evy' => 'application/x-envoy',
+ 'exe' => 'application/octet-stream',
+ 'exi' => 'application/exi',
+ 'exp' => 'application/express',
+ 'exr' => 'image/aces',
+ 'ext' => 'application/vnd.novadigm.ext',
+ 'ez' => 'application/andrew-inset',
+ 'ez2' => 'application/vnd.ezpix-album',
+ 'ez3' => 'application/vnd.ezpix-package',
+ 'f' => 'text/x-fortran',
+ 'f4v' => 'video/mp4',
+ 'f77' => 'text/x-fortran',
+ 'f90' => 'text/x-fortran',
+ 'fbs' => 'image/vnd.fastbidsheet',
+ 'fcdt' => 'application/vnd.adobe.formscentral.fcdt',
+ 'fcs' => 'application/vnd.isac.fcs',
+ 'fdf' => 'application/vnd.fdf',
+ 'fdt' => 'application/fdt+xml',
+ 'fe_launch' => 'application/vnd.denovo.fcselayout-link',
+ 'fg5' => 'application/vnd.fujitsu.oasysgp',
+ 'fgd' => 'application/x-director',
+ 'fh' => 'image/x-freehand',
+ 'fh4' => 'image/x-freehand',
+ 'fh5' => 'image/x-freehand',
+ 'fh7' => 'image/x-freehand',
+ 'fhc' => 'image/x-freehand',
+ 'fig' => 'application/x-xfig',
+ 'fits' => 'image/fits',
+ 'flac' => 'audio/x-flac',
+ 'fli' => 'video/x-fli',
+ 'flo' => 'application/vnd.micrografx.flo',
+ 'flv' => 'video/x-flv',
+ 'flw' => 'application/vnd.kde.kivio',
+ 'flx' => 'text/vnd.fmi.flexstor',
+ 'fly' => 'text/vnd.fly',
+ 'fm' => 'application/vnd.framemaker',
+ 'fnc' => 'application/vnd.frogans.fnc',
+ 'fo' => 'application/vnd.software602.filler.form+xml',
+ 'for' => 'text/x-fortran',
+ 'fpx' => 'image/vnd.fpx',
+ 'frame' => 'application/vnd.framemaker',
+ 'fsc' => 'application/vnd.fsc.weblaunch',
+ 'fst' => 'image/vnd.fst',
+ 'ftc' => 'application/vnd.fluxtime.clip',
+ 'fti' => 'application/vnd.anser-web-funds-transfer-initiation',
+ 'fvt' => 'video/vnd.fvt',
+ 'fxp' => 'application/vnd.adobe.fxp',
+ 'fxpl' => 'application/vnd.adobe.fxp',
+ 'fzs' => 'application/vnd.fuzzysheet',
+ 'g2w' => 'application/vnd.geoplan',
+ 'g3' => 'image/g3fax',
+ 'g3w' => 'application/vnd.geospace',
+ 'gac' => 'application/vnd.groove-account',
+ 'gam' => 'application/x-tads',
+ 'gbr' => 'application/rpki-ghostbusters',
+ 'gca' => 'application/x-gca-compressed',
+ 'gdl' => 'model/vnd.gdl',
+ 'gdoc' => 'application/vnd.google-apps.document',
+ 'ged' => 'text/vnd.familysearch.gedcom',
+ 'geo' => 'application/vnd.dynageo',
+ 'geojson' => 'application/geo+json',
+ 'gex' => 'application/vnd.geometry-explorer',
+ 'ggb' => 'application/vnd.geogebra.file',
+ 'ggt' => 'application/vnd.geogebra.tool',
+ 'ghf' => 'application/vnd.groove-help',
+ 'gif' => 'image/gif',
+ 'gim' => 'application/vnd.groove-identity-message',
+ 'glb' => 'model/gltf-binary',
+ 'gltf' => 'model/gltf+json',
+ 'gml' => 'application/gml+xml',
+ 'gmx' => 'application/vnd.gmx',
+ 'gnumeric' => 'application/x-gnumeric',
+ 'gpg' => 'application/gpg-keys',
+ 'gph' => 'application/vnd.flographit',
+ 'gpx' => 'application/gpx+xml',
+ 'gqf' => 'application/vnd.grafeq',
+ 'gqs' => 'application/vnd.grafeq',
+ 'gram' => 'application/srgs',
+ 'gramps' => 'application/x-gramps-xml',
+ 'gre' => 'application/vnd.geometry-explorer',
+ 'grv' => 'application/vnd.groove-injector',
+ 'grxml' => 'application/srgs+xml',
+ 'gsf' => 'application/x-font-ghostscript',
+ 'gsheet' => 'application/vnd.google-apps.spreadsheet',
+ 'gslides' => 'application/vnd.google-apps.presentation',
+ 'gtar' => 'application/x-gtar',
+ 'gtm' => 'application/vnd.groove-tool-message',
+ 'gtw' => 'model/vnd.gtw',
+ 'gv' => 'text/vnd.graphviz',
+ 'gxf' => 'application/gxf',
+ 'gxt' => 'application/vnd.geonext',
+ 'gz' => 'application/gzip',
+ 'gzip' => 'application/gzip',
+ 'h' => 'text/x-c',
+ 'h261' => 'video/h261',
+ 'h263' => 'video/h263',
+ 'h264' => 'video/h264',
+ 'hal' => 'application/vnd.hal+xml',
+ 'hbci' => 'application/vnd.hbci',
+ 'hbs' => 'text/x-handlebars-template',
+ 'hdd' => 'application/x-virtualbox-hdd',
+ 'hdf' => 'application/x-hdf',
+ 'heic' => 'image/heic',
+ 'heics' => 'image/heic-sequence',
+ 'heif' => 'image/heif',
+ 'heifs' => 'image/heif-sequence',
+ 'hej2' => 'image/hej2k',
+ 'held' => 'application/atsc-held+xml',
+ 'hh' => 'text/x-c',
+ 'hjson' => 'application/hjson',
+ 'hlp' => 'application/winhlp',
+ 'hpgl' => 'application/vnd.hp-hpgl',
+ 'hpid' => 'application/vnd.hp-hpid',
+ 'hps' => 'application/vnd.hp-hps',
+ 'hqx' => 'application/mac-binhex40',
+ 'hsj2' => 'image/hsj2',
+ 'htc' => 'text/x-component',
+ 'htke' => 'application/vnd.kenameaapp',
+ 'htm' => 'text/html',
+ 'html' => 'text/html',
+ 'hvd' => 'application/vnd.yamaha.hv-dic',
+ 'hvp' => 'application/vnd.yamaha.hv-voice',
+ 'hvs' => 'application/vnd.yamaha.hv-script',
+ 'i2g' => 'application/vnd.intergeo',
+ 'icc' => 'application/vnd.iccprofile',
+ 'ice' => 'x-conference/x-cooltalk',
+ 'icm' => 'application/vnd.iccprofile',
+ 'ico' => 'image/x-icon',
+ 'ics' => 'text/calendar',
+ 'ief' => 'image/ief',
+ 'ifb' => 'text/calendar',
+ 'ifm' => 'application/vnd.shana.informed.formdata',
+ 'iges' => 'model/iges',
+ 'igl' => 'application/vnd.igloader',
+ 'igm' => 'application/vnd.insors.igm',
+ 'igs' => 'model/iges',
+ 'igx' => 'application/vnd.micrografx.igx',
+ 'iif' => 'application/vnd.shana.informed.interchange',
+ 'img' => 'application/octet-stream',
+ 'imp' => 'application/vnd.accpac.simply.imp',
+ 'ims' => 'application/vnd.ms-ims',
+ 'in' => 'text/plain',
+ 'ini' => 'text/plain',
+ 'ink' => 'application/inkml+xml',
+ 'inkml' => 'application/inkml+xml',
+ 'install' => 'application/x-install-instructions',
+ 'iota' => 'application/vnd.astraea-software.iota',
+ 'ipfix' => 'application/ipfix',
+ 'ipk' => 'application/vnd.shana.informed.package',
+ 'irm' => 'application/vnd.ibm.rights-management',
+ 'irp' => 'application/vnd.irepository.package+xml',
+ 'iso' => 'application/x-iso9660-image',
+ 'itp' => 'application/vnd.shana.informed.formtemplate',
+ 'its' => 'application/its+xml',
+ 'ivp' => 'application/vnd.immervision-ivp',
+ 'ivu' => 'application/vnd.immervision-ivu',
+ 'jad' => 'text/vnd.sun.j2me.app-descriptor',
+ 'jade' => 'text/jade',
+ 'jam' => 'application/vnd.jam',
+ 'jar' => 'application/java-archive',
+ 'jardiff' => 'application/x-java-archive-diff',
+ 'java' => 'text/x-java-source',
+ 'jhc' => 'image/jphc',
+ 'jisp' => 'application/vnd.jisp',
+ 'jls' => 'image/jls',
+ 'jlt' => 'application/vnd.hp-jlyt',
+ 'jng' => 'image/x-jng',
+ 'jnlp' => 'application/x-java-jnlp-file',
+ 'joda' => 'application/vnd.joost.joda-archive',
+ 'jp2' => 'image/jp2',
+ 'jpe' => 'image/jpeg',
+ 'jpeg' => 'image/jpeg',
+ 'jpf' => 'image/jpx',
+ 'jpg' => 'image/jpeg',
+ 'jpg2' => 'image/jp2',
+ 'jpgm' => 'video/jpm',
+ 'jpgv' => 'video/jpeg',
+ 'jph' => 'image/jph',
+ 'jpm' => 'video/jpm',
+ 'jpx' => 'image/jpx',
+ 'js' => 'application/javascript',
+ 'json' => 'application/json',
+ 'json5' => 'application/json5',
+ 'jsonld' => 'application/ld+json',
+ 'jsonml' => 'application/jsonml+json',
+ 'jsx' => 'text/jsx',
+ 'jxr' => 'image/jxr',
+ 'jxra' => 'image/jxra',
+ 'jxrs' => 'image/jxrs',
+ 'jxs' => 'image/jxs',
+ 'jxsc' => 'image/jxsc',
+ 'jxsi' => 'image/jxsi',
+ 'jxss' => 'image/jxss',
+ 'kar' => 'audio/midi',
+ 'karbon' => 'application/vnd.kde.karbon',
+ 'kdb' => 'application/octet-stream',
+ 'kdbx' => 'application/x-keepass2',
+ 'key' => 'application/x-iwork-keynote-sffkey',
+ 'kfo' => 'application/vnd.kde.kformula',
+ 'kia' => 'application/vnd.kidspiration',
+ 'kml' => 'application/vnd.google-earth.kml+xml',
+ 'kmz' => 'application/vnd.google-earth.kmz',
+ 'kne' => 'application/vnd.kinar',
+ 'knp' => 'application/vnd.kinar',
+ 'kon' => 'application/vnd.kde.kontour',
+ 'kpr' => 'application/vnd.kde.kpresenter',
+ 'kpt' => 'application/vnd.kde.kpresenter',
+ 'kpxx' => 'application/vnd.ds-keypoint',
+ 'ksp' => 'application/vnd.kde.kspread',
+ 'ktr' => 'application/vnd.kahootz',
+ 'ktx' => 'image/ktx',
+ 'ktx2' => 'image/ktx2',
+ 'ktz' => 'application/vnd.kahootz',
+ 'kwd' => 'application/vnd.kde.kword',
+ 'kwt' => 'application/vnd.kde.kword',
+ 'lasxml' => 'application/vnd.las.las+xml',
+ 'latex' => 'application/x-latex',
+ 'lbd' => 'application/vnd.llamagraphics.life-balance.desktop',
+ 'lbe' => 'application/vnd.llamagraphics.life-balance.exchange+xml',
+ 'les' => 'application/vnd.hhe.lesson-player',
+ 'less' => 'text/less',
+ 'lgr' => 'application/lgr+xml',
+ 'lha' => 'application/octet-stream',
+ 'link66' => 'application/vnd.route66.link66+xml',
+ 'list' => 'text/plain',
+ 'list3820' => 'application/vnd.ibm.modcap',
+ 'listafp' => 'application/vnd.ibm.modcap',
+ 'litcoffee' => 'text/coffeescript',
+ 'lnk' => 'application/x-ms-shortcut',
+ 'log' => 'text/plain',
+ 'lostxml' => 'application/lost+xml',
+ 'lrf' => 'application/octet-stream',
+ 'lrm' => 'application/vnd.ms-lrm',
+ 'ltf' => 'application/vnd.frogans.ltf',
+ 'lua' => 'text/x-lua',
+ 'luac' => 'application/x-lua-bytecode',
+ 'lvp' => 'audio/vnd.lucent.voice',
+ 'lwp' => 'application/vnd.lotus-wordpro',
+ 'lzh' => 'application/octet-stream',
+ 'm1v' => 'video/mpeg',
+ 'm2a' => 'audio/mpeg',
+ 'm2v' => 'video/mpeg',
+ 'm3a' => 'audio/mpeg',
+ 'm3u' => 'text/plain',
+ 'm3u8' => 'application/vnd.apple.mpegurl',
+ 'm4a' => 'audio/x-m4a',
+ 'm4p' => 'application/mp4',
+ 'm4s' => 'video/iso.segment',
+ 'm4u' => 'application/vnd.mpegurl',
+ 'm4v' => 'video/x-m4v',
+ 'm13' => 'application/x-msmediaview',
+ 'm14' => 'application/x-msmediaview',
+ 'm21' => 'application/mp21',
+ 'ma' => 'application/mathematica',
+ 'mads' => 'application/mads+xml',
+ 'maei' => 'application/mmt-aei+xml',
+ 'mag' => 'application/vnd.ecowin.chart',
+ 'maker' => 'application/vnd.framemaker',
+ 'man' => 'text/troff',
+ 'manifest' => 'text/cache-manifest',
+ 'map' => 'application/json',
+ 'mar' => 'application/octet-stream',
+ 'markdown' => 'text/markdown',
+ 'mathml' => 'application/mathml+xml',
+ 'mb' => 'application/mathematica',
+ 'mbk' => 'application/vnd.mobius.mbk',
+ 'mbox' => 'application/mbox',
+ 'mc1' => 'application/vnd.medcalcdata',
+ 'mcd' => 'application/vnd.mcd',
+ 'mcurl' => 'text/vnd.curl.mcurl',
+ 'md' => 'text/markdown',
+ 'mdb' => 'application/x-msaccess',
+ 'mdi' => 'image/vnd.ms-modi',
+ 'mdx' => 'text/mdx',
+ 'me' => 'text/troff',
+ 'mesh' => 'model/mesh',
+ 'meta4' => 'application/metalink4+xml',
+ 'metalink' => 'application/metalink+xml',
+ 'mets' => 'application/mets+xml',
+ 'mfm' => 'application/vnd.mfmp',
+ 'mft' => 'application/rpki-manifest',
+ 'mgp' => 'application/vnd.osgeo.mapguide.package',
+ 'mgz' => 'application/vnd.proteus.magazine',
+ 'mid' => 'audio/midi',
+ 'midi' => 'audio/midi',
+ 'mie' => 'application/x-mie',
+ 'mif' => 'application/vnd.mif',
+ 'mime' => 'message/rfc822',
+ 'mj2' => 'video/mj2',
+ 'mjp2' => 'video/mj2',
+ 'mjs' => 'application/javascript',
+ 'mk3d' => 'video/x-matroska',
+ 'mka' => 'audio/x-matroska',
+ 'mkd' => 'text/x-markdown',
+ 'mks' => 'video/x-matroska',
+ 'mkv' => 'video/x-matroska',
+ 'mlp' => 'application/vnd.dolby.mlp',
+ 'mmd' => 'application/vnd.chipnuts.karaoke-mmd',
+ 'mmf' => 'application/vnd.smaf',
+ 'mml' => 'text/mathml',
+ 'mmr' => 'image/vnd.fujixerox.edmics-mmr',
+ 'mng' => 'video/x-mng',
+ 'mny' => 'application/x-msmoney',
+ 'mobi' => 'application/x-mobipocket-ebook',
+ 'mods' => 'application/mods+xml',
+ 'mov' => 'video/quicktime',
+ 'movie' => 'video/x-sgi-movie',
+ 'mp2' => 'audio/mpeg',
+ 'mp2a' => 'audio/mpeg',
+ 'mp3' => 'audio/mpeg',
+ 'mp4' => 'video/mp4',
+ 'mp4a' => 'audio/mp4',
+ 'mp4s' => 'application/mp4',
+ 'mp4v' => 'video/mp4',
+ 'mp21' => 'application/mp21',
+ 'mpc' => 'application/vnd.mophun.certificate',
+ 'mpd' => 'application/dash+xml',
+ 'mpe' => 'video/mpeg',
+ 'mpeg' => 'video/mpeg',
+ 'mpf' => 'application/media-policy-dataset+xml',
+ 'mpg' => 'video/mpeg',
+ 'mpg4' => 'video/mp4',
+ 'mpga' => 'audio/mpeg',
+ 'mpkg' => 'application/vnd.apple.installer+xml',
+ 'mpm' => 'application/vnd.blueice.multipass',
+ 'mpn' => 'application/vnd.mophun.application',
+ 'mpp' => 'application/vnd.ms-project',
+ 'mpt' => 'application/vnd.ms-project',
+ 'mpy' => 'application/vnd.ibm.minipay',
+ 'mqy' => 'application/vnd.mobius.mqy',
+ 'mrc' => 'application/marc',
+ 'mrcx' => 'application/marcxml+xml',
+ 'ms' => 'text/troff',
+ 'mscml' => 'application/mediaservercontrol+xml',
+ 'mseed' => 'application/vnd.fdsn.mseed',
+ 'mseq' => 'application/vnd.mseq',
+ 'msf' => 'application/vnd.epson.msf',
+ 'msg' => 'application/vnd.ms-outlook',
+ 'msh' => 'model/mesh',
+ 'msi' => 'application/x-msdownload',
+ 'msl' => 'application/vnd.mobius.msl',
+ 'msm' => 'application/octet-stream',
+ 'msp' => 'application/octet-stream',
+ 'msty' => 'application/vnd.muvee.style',
+ 'mtl' => 'model/mtl',
+ 'mts' => 'model/vnd.mts',
+ 'mus' => 'application/vnd.musician',
+ 'musd' => 'application/mmt-usd+xml',
+ 'musicxml' => 'application/vnd.recordare.musicxml+xml',
+ 'mvb' => 'application/x-msmediaview',
+ 'mvt' => 'application/vnd.mapbox-vector-tile',
+ 'mwf' => 'application/vnd.mfer',
+ 'mxf' => 'application/mxf',
+ 'mxl' => 'application/vnd.recordare.musicxml',
+ 'mxmf' => 'audio/mobile-xmf',
+ 'mxml' => 'application/xv+xml',
+ 'mxs' => 'application/vnd.triscape.mxs',
+ 'mxu' => 'video/vnd.mpegurl',
+ 'n-gage' => 'application/vnd.nokia.n-gage.symbian.install',
+ 'n3' => 'text/n3',
+ 'nb' => 'application/mathematica',
+ 'nbp' => 'application/vnd.wolfram.player',
+ 'nc' => 'application/x-netcdf',
+ 'ncx' => 'application/x-dtbncx+xml',
+ 'nfo' => 'text/x-nfo',
+ 'ngdat' => 'application/vnd.nokia.n-gage.data',
+ 'nitf' => 'application/vnd.nitf',
+ 'nlu' => 'application/vnd.neurolanguage.nlu',
+ 'nml' => 'application/vnd.enliven',
+ 'nnd' => 'application/vnd.noblenet-directory',
+ 'nns' => 'application/vnd.noblenet-sealer',
+ 'nnw' => 'application/vnd.noblenet-web',
+ 'npx' => 'image/vnd.net-fpx',
+ 'nq' => 'application/n-quads',
+ 'nsc' => 'application/x-conference',
+ 'nsf' => 'application/vnd.lotus-notes',
+ 'nt' => 'application/n-triples',
+ 'ntf' => 'application/vnd.nitf',
+ 'numbers' => 'application/x-iwork-numbers-sffnumbers',
+ 'nzb' => 'application/x-nzb',
+ 'oa2' => 'application/vnd.fujitsu.oasys2',
+ 'oa3' => 'application/vnd.fujitsu.oasys3',
+ 'oas' => 'application/vnd.fujitsu.oasys',
+ 'obd' => 'application/x-msbinder',
+ 'obgx' => 'application/vnd.openblox.game+xml',
+ 'obj' => 'model/obj',
+ 'oda' => 'application/oda',
+ 'odb' => 'application/vnd.oasis.opendocument.database',
+ 'odc' => 'application/vnd.oasis.opendocument.chart',
+ 'odf' => 'application/vnd.oasis.opendocument.formula',
+ 'odft' => 'application/vnd.oasis.opendocument.formula-template',
+ 'odg' => 'application/vnd.oasis.opendocument.graphics',
+ 'odi' => 'application/vnd.oasis.opendocument.image',
+ 'odm' => 'application/vnd.oasis.opendocument.text-master',
+ 'odp' => 'application/vnd.oasis.opendocument.presentation',
+ 'ods' => 'application/vnd.oasis.opendocument.spreadsheet',
+ 'odt' => 'application/vnd.oasis.opendocument.text',
+ 'oga' => 'audio/ogg',
+ 'ogex' => 'model/vnd.opengex',
+ 'ogg' => 'audio/ogg',
+ 'ogv' => 'video/ogg',
+ 'ogx' => 'application/ogg',
+ 'omdoc' => 'application/omdoc+xml',
+ 'onepkg' => 'application/onenote',
+ 'onetmp' => 'application/onenote',
+ 'onetoc' => 'application/onenote',
+ 'onetoc2' => 'application/onenote',
+ 'opf' => 'application/oebps-package+xml',
+ 'opml' => 'text/x-opml',
+ 'oprc' => 'application/vnd.palm',
+ 'opus' => 'audio/ogg',
+ 'org' => 'text/x-org',
+ 'osf' => 'application/vnd.yamaha.openscoreformat',
+ 'osfpvg' => 'application/vnd.yamaha.openscoreformat.osfpvg+xml',
+ 'osm' => 'application/vnd.openstreetmap.data+xml',
+ 'otc' => 'application/vnd.oasis.opendocument.chart-template',
+ 'otf' => 'font/otf',
+ 'otg' => 'application/vnd.oasis.opendocument.graphics-template',
+ 'oth' => 'application/vnd.oasis.opendocument.text-web',
+ 'oti' => 'application/vnd.oasis.opendocument.image-template',
+ 'otp' => 'application/vnd.oasis.opendocument.presentation-template',
+ 'ots' => 'application/vnd.oasis.opendocument.spreadsheet-template',
+ 'ott' => 'application/vnd.oasis.opendocument.text-template',
+ 'ova' => 'application/x-virtualbox-ova',
+ 'ovf' => 'application/x-virtualbox-ovf',
+ 'owl' => 'application/rdf+xml',
+ 'oxps' => 'application/oxps',
+ 'oxt' => 'application/vnd.openofficeorg.extension',
+ 'p' => 'text/x-pascal',
+ 'p7a' => 'application/x-pkcs7-signature',
+ 'p7b' => 'application/x-pkcs7-certificates',
+ 'p7c' => 'application/pkcs7-mime',
+ 'p7m' => 'application/pkcs7-mime',
+ 'p7r' => 'application/x-pkcs7-certreqresp',
+ 'p7s' => 'application/pkcs7-signature',
+ 'p8' => 'application/pkcs8',
+ 'p10' => 'application/x-pkcs10',
+ 'p12' => 'application/x-pkcs12',
+ 'pac' => 'application/x-ns-proxy-autoconfig',
+ 'pages' => 'application/x-iwork-pages-sffpages',
+ 'pas' => 'text/x-pascal',
+ 'paw' => 'application/vnd.pawaafile',
+ 'pbd' => 'application/vnd.powerbuilder6',
+ 'pbm' => 'image/x-portable-bitmap',
+ 'pcap' => 'application/vnd.tcpdump.pcap',
+ 'pcf' => 'application/x-font-pcf',
+ 'pcl' => 'application/vnd.hp-pcl',
+ 'pclxl' => 'application/vnd.hp-pclxl',
+ 'pct' => 'image/x-pict',
+ 'pcurl' => 'application/vnd.curl.pcurl',
+ 'pcx' => 'image/x-pcx',
+ 'pdb' => 'application/x-pilot',
+ 'pde' => 'text/x-processing',
+ 'pdf' => 'application/pdf',
+ 'pem' => 'application/x-x509-user-cert',
+ 'pfa' => 'application/x-font-type1',
+ 'pfb' => 'application/x-font-type1',
+ 'pfm' => 'application/x-font-type1',
+ 'pfr' => 'application/font-tdpfr',
+ 'pfx' => 'application/x-pkcs12',
+ 'pgm' => 'image/x-portable-graymap',
+ 'pgn' => 'application/x-chess-pgn',
+ 'pgp' => 'application/pgp',
+ 'phar' => 'application/octet-stream',
+ 'php' => 'application/x-httpd-php',
+ 'php3' => 'application/x-httpd-php',
+ 'php4' => 'application/x-httpd-php',
+ 'phps' => 'application/x-httpd-php-source',
+ 'phtml' => 'application/x-httpd-php',
+ 'pic' => 'image/x-pict',
+ 'pkg' => 'application/octet-stream',
+ 'pki' => 'application/pkixcmp',
+ 'pkipath' => 'application/pkix-pkipath',
+ 'pkpass' => 'application/vnd.apple.pkpass',
+ 'pl' => 'application/x-perl',
+ 'plb' => 'application/vnd.3gpp.pic-bw-large',
+ 'plc' => 'application/vnd.mobius.plc',
+ 'plf' => 'application/vnd.pocketlearn',
+ 'pls' => 'application/pls+xml',
+ 'pm' => 'application/x-perl',
+ 'pml' => 'application/vnd.ctc-posml',
+ 'png' => 'image/png',
+ 'pnm' => 'image/x-portable-anymap',
+ 'portpkg' => 'application/vnd.macports.portpkg',
+ 'pot' => 'application/vnd.ms-powerpoint',
+ 'potm' => 'application/vnd.ms-powerpoint.presentation.macroEnabled.12',
+ 'potx' => 'application/vnd.openxmlformats-officedocument.presentationml.template',
+ 'ppa' => 'application/vnd.ms-powerpoint',
+ 'ppam' => 'application/vnd.ms-powerpoint.addin.macroEnabled.12',
+ 'ppd' => 'application/vnd.cups-ppd',
+ 'ppm' => 'image/x-portable-pixmap',
+ 'pps' => 'application/vnd.ms-powerpoint',
+ 'ppsm' => 'application/vnd.ms-powerpoint.slideshow.macroEnabled.12',
+ 'ppsx' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',
+ 'ppt' => 'application/powerpoint',
+ 'pptm' => 'application/vnd.ms-powerpoint.presentation.macroEnabled.12',
+ 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
+ 'pqa' => 'application/vnd.palm',
+ 'prc' => 'model/prc',
+ 'pre' => 'application/vnd.lotus-freelance',
+ 'prf' => 'application/pics-rules',
+ 'provx' => 'application/provenance+xml',
+ 'ps' => 'application/postscript',
+ 'psb' => 'application/vnd.3gpp.pic-bw-small',
+ 'psd' => 'application/x-photoshop',
+ 'psf' => 'application/x-font-linux-psf',
+ 'pskcxml' => 'application/pskc+xml',
+ 'pti' => 'image/prs.pti',
+ 'ptid' => 'application/vnd.pvi.ptid1',
+ 'pub' => 'application/x-mspublisher',
+ 'pvb' => 'application/vnd.3gpp.pic-bw-var',
+ 'pwn' => 'application/vnd.3m.post-it-notes',
+ 'pya' => 'audio/vnd.ms-playready.media.pya',
+ 'pyv' => 'video/vnd.ms-playready.media.pyv',
+ 'qam' => 'application/vnd.epson.quickanime',
+ 'qbo' => 'application/vnd.intu.qbo',
+ 'qfx' => 'application/vnd.intu.qfx',
+ 'qps' => 'application/vnd.publishare-delta-tree',
+ 'qt' => 'video/quicktime',
+ 'qwd' => 'application/vnd.quark.quarkxpress',
+ 'qwt' => 'application/vnd.quark.quarkxpress',
+ 'qxb' => 'application/vnd.quark.quarkxpress',
+ 'qxd' => 'application/vnd.quark.quarkxpress',
+ 'qxl' => 'application/vnd.quark.quarkxpress',
+ 'qxt' => 'application/vnd.quark.quarkxpress',
+ 'ra' => 'audio/x-realaudio',
+ 'ram' => 'audio/x-pn-realaudio',
+ 'raml' => 'application/raml+yaml',
+ 'rapd' => 'application/route-apd+xml',
+ 'rar' => 'application/x-rar',
+ 'ras' => 'image/x-cmu-raster',
+ 'rcprofile' => 'application/vnd.ipunplugged.rcprofile',
+ 'rdf' => 'application/rdf+xml',
+ 'rdz' => 'application/vnd.data-vision.rdz',
+ 'relo' => 'application/p2p-overlay+xml',
+ 'rep' => 'application/vnd.businessobjects',
+ 'res' => 'application/x-dtbresource+xml',
+ 'rgb' => 'image/x-rgb',
+ 'rif' => 'application/reginfo+xml',
+ 'rip' => 'audio/vnd.rip',
+ 'ris' => 'application/x-research-info-systems',
+ 'rl' => 'application/resource-lists+xml',
+ 'rlc' => 'image/vnd.fujixerox.edmics-rlc',
+ 'rld' => 'application/resource-lists-diff+xml',
+ 'rm' => 'audio/x-pn-realaudio',
+ 'rmi' => 'audio/midi',
+ 'rmp' => 'audio/x-pn-realaudio-plugin',
+ 'rms' => 'application/vnd.jcp.javame.midlet-rms',
+ 'rmvb' => 'application/vnd.rn-realmedia-vbr',
+ 'rnc' => 'application/relax-ng-compact-syntax',
+ 'rng' => 'application/xml',
+ 'roa' => 'application/rpki-roa',
+ 'roff' => 'text/troff',
+ 'rp9' => 'application/vnd.cloanto.rp9',
+ 'rpm' => 'audio/x-pn-realaudio-plugin',
+ 'rpss' => 'application/vnd.nokia.radio-presets',
+ 'rpst' => 'application/vnd.nokia.radio-preset',
+ 'rq' => 'application/sparql-query',
+ 'rs' => 'application/rls-services+xml',
+ 'rsa' => 'application/x-pkcs7',
+ 'rsat' => 'application/atsc-rsat+xml',
+ 'rsd' => 'application/rsd+xml',
+ 'rsheet' => 'application/urc-ressheet+xml',
+ 'rss' => 'application/rss+xml',
+ 'rtf' => 'text/rtf',
+ 'rtx' => 'text/richtext',
+ 'run' => 'application/x-makeself',
+ 'rusd' => 'application/route-usd+xml',
+ 'rv' => 'video/vnd.rn-realvideo',
+ 's' => 'text/x-asm',
+ 's3m' => 'audio/s3m',
+ 'saf' => 'application/vnd.yamaha.smaf-audio',
+ 'sass' => 'text/x-sass',
+ 'sbml' => 'application/sbml+xml',
+ 'sc' => 'application/vnd.ibm.secure-container',
+ 'scd' => 'application/x-msschedule',
+ 'scm' => 'application/vnd.lotus-screencam',
+ 'scq' => 'application/scvp-cv-request',
+ 'scs' => 'application/scvp-cv-response',
+ 'scss' => 'text/x-scss',
+ 'scurl' => 'text/vnd.curl.scurl',
+ 'sda' => 'application/vnd.stardivision.draw',
+ 'sdc' => 'application/vnd.stardivision.calc',
+ 'sdd' => 'application/vnd.stardivision.impress',
+ 'sdkd' => 'application/vnd.solent.sdkm+xml',
+ 'sdkm' => 'application/vnd.solent.sdkm+xml',
+ 'sdp' => 'application/sdp',
+ 'sdw' => 'application/vnd.stardivision.writer',
+ 'sea' => 'application/octet-stream',
+ 'see' => 'application/vnd.seemail',
+ 'seed' => 'application/vnd.fdsn.seed',
+ 'sema' => 'application/vnd.sema',
+ 'semd' => 'application/vnd.semd',
+ 'semf' => 'application/vnd.semf',
+ 'senmlx' => 'application/senml+xml',
+ 'sensmlx' => 'application/sensml+xml',
+ 'ser' => 'application/java-serialized-object',
+ 'setpay' => 'application/set-payment-initiation',
+ 'setreg' => 'application/set-registration-initiation',
+ 'sfd-hdstx' => 'application/vnd.hydrostatix.sof-data',
+ 'sfs' => 'application/vnd.spotfire.sfs',
+ 'sfv' => 'text/x-sfv',
+ 'sgi' => 'image/sgi',
+ 'sgl' => 'application/vnd.stardivision.writer-global',
+ 'sgm' => 'text/sgml',
+ 'sgml' => 'text/sgml',
+ 'sh' => 'application/x-sh',
+ 'shar' => 'application/x-shar',
+ 'shex' => 'text/shex',
+ 'shf' => 'application/shf+xml',
+ 'shtml' => 'text/html',
+ 'sid' => 'image/x-mrsid-image',
+ 'sieve' => 'application/sieve',
+ 'sig' => 'application/pgp-signature',
+ 'sil' => 'audio/silk',
+ 'silo' => 'model/mesh',
+ 'sis' => 'application/vnd.symbian.install',
+ 'sisx' => 'application/vnd.symbian.install',
+ 'sit' => 'application/x-stuffit',
+ 'sitx' => 'application/x-stuffitx',
+ 'siv' => 'application/sieve',
+ 'skd' => 'application/vnd.koan',
+ 'skm' => 'application/vnd.koan',
+ 'skp' => 'application/vnd.koan',
+ 'skt' => 'application/vnd.koan',
+ 'sldm' => 'application/vnd.ms-powerpoint.slide.macroenabled.12',
+ 'sldx' => 'application/vnd.openxmlformats-officedocument.presentationml.slide',
+ 'slim' => 'text/slim',
+ 'slm' => 'text/slim',
+ 'sls' => 'application/route-s-tsid+xml',
+ 'slt' => 'application/vnd.epson.salt',
+ 'sm' => 'application/vnd.stepmania.stepchart',
+ 'smf' => 'application/vnd.stardivision.math',
+ 'smi' => 'application/smil',
+ 'smil' => 'application/smil',
+ 'smv' => 'video/x-smv',
+ 'smzip' => 'application/vnd.stepmania.package',
+ 'snd' => 'audio/basic',
+ 'snf' => 'application/x-font-snf',
+ 'so' => 'application/octet-stream',
+ 'spc' => 'application/x-pkcs7-certificates',
+ 'spdx' => 'text/spdx',
+ 'spf' => 'application/vnd.yamaha.smaf-phrase',
+ 'spl' => 'application/x-futuresplash',
+ 'spot' => 'text/vnd.in3d.spot',
+ 'spp' => 'application/scvp-vp-response',
+ 'spq' => 'application/scvp-vp-request',
+ 'spx' => 'audio/ogg',
+ 'sql' => 'application/x-sql',
+ 'src' => 'application/x-wais-source',
+ 'srt' => 'application/x-subrip',
+ 'sru' => 'application/sru+xml',
+ 'srx' => 'application/sparql-results+xml',
+ 'ssdl' => 'application/ssdl+xml',
+ 'sse' => 'application/vnd.kodak-descriptor',
+ 'ssf' => 'application/vnd.epson.ssf',
+ 'ssml' => 'application/ssml+xml',
+ 'sst' => 'application/octet-stream',
+ 'st' => 'application/vnd.sailingtracker.track',
+ 'stc' => 'application/vnd.sun.xml.calc.template',
+ 'std' => 'application/vnd.sun.xml.draw.template',
+ 'stf' => 'application/vnd.wt.stf',
+ 'sti' => 'application/vnd.sun.xml.impress.template',
+ 'stk' => 'application/hyperstudio',
+ 'stl' => 'model/stl',
+ 'stpx' => 'model/step+xml',
+ 'stpxz' => 'model/step-xml+zip',
+ 'stpz' => 'model/step+zip',
+ 'str' => 'application/vnd.pg.format',
+ 'stw' => 'application/vnd.sun.xml.writer.template',
+ 'styl' => 'text/stylus',
+ 'stylus' => 'text/stylus',
+ 'sub' => 'text/vnd.dvb.subtitle',
+ 'sus' => 'application/vnd.sus-calendar',
+ 'susp' => 'application/vnd.sus-calendar',
+ 'sv4cpio' => 'application/x-sv4cpio',
+ 'sv4crc' => 'application/x-sv4crc',
+ 'svc' => 'application/vnd.dvb.service',
+ 'svd' => 'application/vnd.svd',
+ 'svg' => 'image/svg+xml',
+ 'svgz' => 'image/svg+xml',
+ 'swa' => 'application/x-director',
+ 'swf' => 'application/x-shockwave-flash',
+ 'swi' => 'application/vnd.aristanetworks.swi',
+ 'swidtag' => 'application/swid+xml',
+ 'sxc' => 'application/vnd.sun.xml.calc',
+ 'sxd' => 'application/vnd.sun.xml.draw',
+ 'sxg' => 'application/vnd.sun.xml.writer.global',
+ 'sxi' => 'application/vnd.sun.xml.impress',
+ 'sxm' => 'application/vnd.sun.xml.math',
+ 'sxw' => 'application/vnd.sun.xml.writer',
+ 't' => 'text/troff',
+ 't3' => 'application/x-t3vm-image',
+ 't38' => 'image/t38',
+ 'taglet' => 'application/vnd.mynfc',
+ 'tao' => 'application/vnd.tao.intent-module-archive',
+ 'tap' => 'image/vnd.tencent.tap',
+ 'tar' => 'application/x-tar',
+ 'tcap' => 'application/vnd.3gpp2.tcap',
+ 'tcl' => 'application/x-tcl',
+ 'td' => 'application/urc-targetdesc+xml',
+ 'teacher' => 'application/vnd.smart.teacher',
+ 'tei' => 'application/tei+xml',
+ 'teicorpus' => 'application/tei+xml',
+ 'tex' => 'application/x-tex',
+ 'texi' => 'application/x-texinfo',
+ 'texinfo' => 'application/x-texinfo',
+ 'text' => 'text/plain',
+ 'tfi' => 'application/thraud+xml',
+ 'tfm' => 'application/x-tex-tfm',
+ 'tfx' => 'image/tiff-fx',
+ 'tga' => 'image/x-tga',
+ 'tgz' => 'application/x-tar',
+ 'thmx' => 'application/vnd.ms-officetheme',
+ 'tif' => 'image/tiff',
+ 'tiff' => 'image/tiff',
+ 'tk' => 'application/x-tcl',
+ 'tmo' => 'application/vnd.tmobile-livetv',
+ 'toml' => 'application/toml',
+ 'torrent' => 'application/x-bittorrent',
+ 'tpl' => 'application/vnd.groove-tool-template',
+ 'tpt' => 'application/vnd.trid.tpt',
+ 'tr' => 'text/troff',
+ 'tra' => 'application/vnd.trueapp',
+ 'trig' => 'application/trig',
+ 'trm' => 'application/x-msterminal',
+ 'ts' => 'video/mp2t',
+ 'tsd' => 'application/timestamped-data',
+ 'tsv' => 'text/tab-separated-values',
+ 'ttc' => 'font/collection',
+ 'ttf' => 'font/ttf',
+ 'ttl' => 'text/turtle',
+ 'ttml' => 'application/ttml+xml',
+ 'twd' => 'application/vnd.simtech-mindmapper',
+ 'twds' => 'application/vnd.simtech-mindmapper',
+ 'txd' => 'application/vnd.genomatix.tuxedo',
+ 'txf' => 'application/vnd.mobius.txf',
+ 'txt' => 'text/plain',
+ 'u3d' => 'model/u3d',
+ 'u8dsn' => 'message/global-delivery-status',
+ 'u8hdr' => 'message/global-headers',
+ 'u8mdn' => 'message/global-disposition-notification',
+ 'u8msg' => 'message/global',
+ 'u32' => 'application/x-authorware-bin',
+ 'ubj' => 'application/ubjson',
+ 'udeb' => 'application/x-debian-package',
+ 'ufd' => 'application/vnd.ufdl',
+ 'ufdl' => 'application/vnd.ufdl',
+ 'ulx' => 'application/x-glulx',
+ 'umj' => 'application/vnd.umajin',
+ 'unityweb' => 'application/vnd.unity',
+ 'uoml' => 'application/vnd.uoml+xml',
+ 'uri' => 'text/uri-list',
+ 'uris' => 'text/uri-list',
+ 'urls' => 'text/uri-list',
+ 'usdz' => 'model/vnd.usdz+zip',
+ 'ustar' => 'application/x-ustar',
+ 'utz' => 'application/vnd.uiq.theme',
+ 'uu' => 'text/x-uuencode',
+ 'uva' => 'audio/vnd.dece.audio',
+ 'uvd' => 'application/vnd.dece.data',
+ 'uvf' => 'application/vnd.dece.data',
+ 'uvg' => 'image/vnd.dece.graphic',
+ 'uvh' => 'video/vnd.dece.hd',
+ 'uvi' => 'image/vnd.dece.graphic',
+ 'uvm' => 'video/vnd.dece.mobile',
+ 'uvp' => 'video/vnd.dece.pd',
+ 'uvs' => 'video/vnd.dece.sd',
+ 'uvt' => 'application/vnd.dece.ttml+xml',
+ 'uvu' => 'video/vnd.uvvu.mp4',
+ 'uvv' => 'video/vnd.dece.video',
+ 'uvva' => 'audio/vnd.dece.audio',
+ 'uvvd' => 'application/vnd.dece.data',
+ 'uvvf' => 'application/vnd.dece.data',
+ 'uvvg' => 'image/vnd.dece.graphic',
+ 'uvvh' => 'video/vnd.dece.hd',
+ 'uvvi' => 'image/vnd.dece.graphic',
+ 'uvvm' => 'video/vnd.dece.mobile',
+ 'uvvp' => 'video/vnd.dece.pd',
+ 'uvvs' => 'video/vnd.dece.sd',
+ 'uvvt' => 'application/vnd.dece.ttml+xml',
+ 'uvvu' => 'video/vnd.uvvu.mp4',
+ 'uvvv' => 'video/vnd.dece.video',
+ 'uvvx' => 'application/vnd.dece.unspecified',
+ 'uvvz' => 'application/vnd.dece.zip',
+ 'uvx' => 'application/vnd.dece.unspecified',
+ 'uvz' => 'application/vnd.dece.zip',
+ 'vbox' => 'application/x-virtualbox-vbox',
+ 'vbox-extpack' => 'application/x-virtualbox-vbox-extpack',
+ 'vcard' => 'text/vcard',
+ 'vcd' => 'application/x-cdlink',
+ 'vcf' => 'text/x-vcard',
+ 'vcg' => 'application/vnd.groove-vcard',
+ 'vcs' => 'text/x-vcalendar',
+ 'vcx' => 'application/vnd.vcx',
+ 'vdi' => 'application/x-virtualbox-vdi',
+ 'vds' => 'model/vnd.sap.vds',
+ 'vhd' => 'application/x-virtualbox-vhd',
+ 'vis' => 'application/vnd.visionary',
+ 'viv' => 'video/vnd.vivo',
+ 'vlc' => 'application/videolan',
+ 'vmdk' => 'application/x-virtualbox-vmdk',
+ 'vob' => 'video/x-ms-vob',
+ 'vor' => 'application/vnd.stardivision.writer',
+ 'vox' => 'application/x-authorware-bin',
+ 'vrml' => 'model/vrml',
+ 'vsd' => 'application/vnd.visio',
+ 'vsf' => 'application/vnd.vsf',
+ 'vss' => 'application/vnd.visio',
+ 'vst' => 'application/vnd.visio',
+ 'vsw' => 'application/vnd.visio',
+ 'vtf' => 'image/vnd.valve.source.texture',
+ 'vtt' => 'text/vtt',
+ 'vtu' => 'model/vnd.vtu',
+ 'vxml' => 'application/voicexml+xml',
+ 'w3d' => 'application/x-director',
+ 'wad' => 'application/x-doom',
+ 'wadl' => 'application/vnd.sun.wadl+xml',
+ 'war' => 'application/java-archive',
+ 'wasm' => 'application/wasm',
+ 'wav' => 'audio/x-wav',
+ 'wax' => 'audio/x-ms-wax',
+ 'wbmp' => 'image/vnd.wap.wbmp',
+ 'wbs' => 'application/vnd.criticaltools.wbs+xml',
+ 'wbxml' => 'application/wbxml',
+ 'wcm' => 'application/vnd.ms-works',
+ 'wdb' => 'application/vnd.ms-works',
+ 'wdp' => 'image/vnd.ms-photo',
+ 'weba' => 'audio/webm',
+ 'webapp' => 'application/x-web-app-manifest+json',
+ 'webm' => 'video/webm',
+ 'webmanifest' => 'application/manifest+json',
+ 'webp' => 'image/webp',
+ 'wg' => 'application/vnd.pmi.widget',
+ 'wgt' => 'application/widget',
+ 'wif' => 'application/watcherinfo+xml',
+ 'wks' => 'application/vnd.ms-works',
+ 'wm' => 'video/x-ms-wm',
+ 'wma' => 'audio/x-ms-wma',
+ 'wmd' => 'application/x-ms-wmd',
+ 'wmf' => 'image/wmf',
+ 'wml' => 'text/vnd.wap.wml',
+ 'wmlc' => 'application/wmlc',
+ 'wmls' => 'text/vnd.wap.wmlscript',
+ 'wmlsc' => 'application/vnd.wap.wmlscriptc',
+ 'wmv' => 'video/x-ms-wmv',
+ 'wmx' => 'video/x-ms-wmx',
+ 'wmz' => 'application/x-msmetafile',
+ 'woff' => 'font/woff',
+ 'woff2' => 'font/woff2',
+ 'word' => 'application/msword',
+ 'wpd' => 'application/vnd.wordperfect',
+ 'wpl' => 'application/vnd.ms-wpl',
+ 'wps' => 'application/vnd.ms-works',
+ 'wqd' => 'application/vnd.wqd',
+ 'wri' => 'application/x-mswrite',
+ 'wrl' => 'model/vrml',
+ 'wsc' => 'message/vnd.wfa.wsc',
+ 'wsdl' => 'application/wsdl+xml',
+ 'wspolicy' => 'application/wspolicy+xml',
+ 'wtb' => 'application/vnd.webturbo',
+ 'wvx' => 'video/x-ms-wvx',
+ 'x3d' => 'model/x3d+xml',
+ 'x3db' => 'model/x3d+fastinfoset',
+ 'x3dbz' => 'model/x3d+binary',
+ 'x3dv' => 'model/x3d-vrml',
+ 'x3dvz' => 'model/x3d+vrml',
+ 'x3dz' => 'model/x3d+xml',
+ 'x32' => 'application/x-authorware-bin',
+ 'x_b' => 'model/vnd.parasolid.transmit.binary',
+ 'x_t' => 'model/vnd.parasolid.transmit.text',
+ 'xaml' => 'application/xaml+xml',
+ 'xap' => 'application/x-silverlight-app',
+ 'xar' => 'application/vnd.xara',
+ 'xav' => 'application/xcap-att+xml',
+ 'xbap' => 'application/x-ms-xbap',
+ 'xbd' => 'application/vnd.fujixerox.docuworks.binder',
+ 'xbm' => 'image/x-xbitmap',
+ 'xca' => 'application/xcap-caps+xml',
+ 'xcs' => 'application/calendar+xml',
+ 'xdf' => 'application/xcap-diff+xml',
+ 'xdm' => 'application/vnd.syncml.dm+xml',
+ 'xdp' => 'application/vnd.adobe.xdp+xml',
+ 'xdssc' => 'application/dssc+xml',
+ 'xdw' => 'application/vnd.fujixerox.docuworks',
+ 'xel' => 'application/xcap-el+xml',
+ 'xenc' => 'application/xenc+xml',
+ 'xer' => 'application/patch-ops-error+xml',
+ 'xfdf' => 'application/vnd.adobe.xfdf',
+ 'xfdl' => 'application/vnd.xfdl',
+ 'xht' => 'application/xhtml+xml',
+ 'xhtml' => 'application/xhtml+xml',
+ 'xhvml' => 'application/xv+xml',
+ 'xif' => 'image/vnd.xiff',
+ 'xl' => 'application/excel',
+ 'xla' => 'application/vnd.ms-excel',
+ 'xlam' => 'application/vnd.ms-excel.addin.macroEnabled.12',
+ 'xlc' => 'application/vnd.ms-excel',
+ 'xlf' => 'application/xliff+xml',
+ 'xlm' => 'application/vnd.ms-excel',
+ 'xls' => 'application/vnd.ms-excel',
+ 'xlsb' => 'application/vnd.ms-excel.sheet.binary.macroEnabled.12',
+ 'xlsm' => 'application/vnd.ms-excel.sheet.macroEnabled.12',
+ 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
+ 'xlt' => 'application/vnd.ms-excel',
+ 'xltm' => 'application/vnd.ms-excel.template.macroEnabled.12',
+ 'xltx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.template',
+ 'xlw' => 'application/vnd.ms-excel',
+ 'xm' => 'audio/xm',
+ 'xml' => 'application/xml',
+ 'xns' => 'application/xcap-ns+xml',
+ 'xo' => 'application/vnd.olpc-sugar',
+ 'xop' => 'application/xop+xml',
+ 'xpi' => 'application/x-xpinstall',
+ 'xpl' => 'application/xproc+xml',
+ 'xpm' => 'image/x-xpixmap',
+ 'xpr' => 'application/vnd.is-xpr',
+ 'xps' => 'application/vnd.ms-xpsdocument',
+ 'xpw' => 'application/vnd.intercon.formnet',
+ 'xpx' => 'application/vnd.intercon.formnet',
+ 'xsd' => 'application/xml',
+ 'xsl' => 'application/xml',
+ 'xslt' => 'application/xslt+xml',
+ 'xsm' => 'application/vnd.syncml+xml',
+ 'xspf' => 'application/xspf+xml',
+ 'xul' => 'application/vnd.mozilla.xul+xml',
+ 'xvm' => 'application/xv+xml',
+ 'xvml' => 'application/xv+xml',
+ 'xwd' => 'image/x-xwindowdump',
+ 'xyz' => 'chemical/x-xyz',
+ 'xz' => 'application/x-xz',
+ 'yaml' => 'text/yaml',
+ 'yang' => 'application/yang',
+ 'yin' => 'application/yin+xml',
+ 'yml' => 'text/yaml',
+ 'ymp' => 'text/x-suse-ymp',
+ 'z' => 'application/x-compress',
+ 'z1' => 'application/x-zmachine',
+ 'z2' => 'application/x-zmachine',
+ 'z3' => 'application/x-zmachine',
+ 'z4' => 'application/x-zmachine',
+ 'z5' => 'application/x-zmachine',
+ 'z6' => 'application/x-zmachine',
+ 'z7' => 'application/x-zmachine',
+ 'z8' => 'application/x-zmachine',
+ 'zaz' => 'application/vnd.zzazz.deck+xml',
+ 'zip' => 'application/zip',
+ 'zir' => 'application/vnd.zul',
+ 'zirz' => 'application/vnd.zul',
+ 'zmm' => 'application/vnd.handheld-entertainment+xml',
+ 'zsh' => 'text/x-scriptzsh',
+ ];
+
+ /**
+ * Determines the mimetype of a file by looking at its extension.
+ *
+ * @link https://raw.githubusercontent.com/jshttp/mime-db/master/db.json
+ */
+ public static function fromFilename(string $filename): ?string
+ {
+ return self::fromExtension(pathinfo($filename, PATHINFO_EXTENSION));
+ }
+
+ /**
+ * Maps a file extensions to a mimetype.
+ *
+ * @link https://raw.githubusercontent.com/jshttp/mime-db/master/db.json
+ */
+ public static function fromExtension(string $extension): ?string
+ {
+ return self::MIME_TYPES[strtolower($extension)] ?? null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MultipartStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MultipartStream.php
new file mode 100644
index 0000000..3e12b74
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/MultipartStream.php
@@ -0,0 +1,159 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Stream that when read returns bytes for a streaming multipart or
+ * multipart/form-data stream.
+ */
+final class MultipartStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ /** @var string */
+ private $boundary;
+
+ /** @var StreamInterface */
+ private $stream;
+
+ /**
+ * @param array $elements Array of associative arrays, each containing a
+ * required "name" key mapping to the form field,
+ * name, a required "contents" key mapping to a
+ * StreamInterface/resource/string, an optional
+ * "headers" associative array of custom headers,
+ * and an optional "filename" key mapping to a
+ * string to send as the filename in the part.
+ * @param string $boundary You can optionally provide a specific boundary
+ *
+ * @throws \InvalidArgumentException
+ */
+ public function __construct(array $elements = [], string $boundary = null)
+ {
+ $this->boundary = $boundary ?: bin2hex(random_bytes(20));
+ $this->stream = $this->createStream($elements);
+ }
+
+ public function getBoundary(): string
+ {
+ return $this->boundary;
+ }
+
+ public function isWritable(): bool
+ {
+ return false;
+ }
+
+ /**
+ * Get the headers needed before transferring the content of a POST file
+ *
+ * @param array<string, string> $headers
+ */
+ private function getHeaders(array $headers): string
+ {
+ $str = '';
+ foreach ($headers as $key => $value) {
+ $str .= "{$key}: {$value}\r\n";
+ }
+
+ return "--{$this->boundary}\r\n" . trim($str) . "\r\n\r\n";
+ }
+
+ /**
+ * Create the aggregate stream that will be used to upload the POST data
+ */
+ protected function createStream(array $elements = []): StreamInterface
+ {
+ $stream = new AppendStream();
+
+ foreach ($elements as $element) {
+ if (!is_array($element)) {
+ throw new \UnexpectedValueException("An array is expected");
+ }
+ $this->addElement($stream, $element);
+ }
+
+ // Add the trailing boundary with CRLF
+ $stream->addStream(Utils::streamFor("--{$this->boundary}--\r\n"));
+
+ return $stream;
+ }
+
+ private function addElement(AppendStream $stream, array $element): void
+ {
+ foreach (['contents', 'name'] as $key) {
+ if (!array_key_exists($key, $element)) {
+ throw new \InvalidArgumentException("A '{$key}' key is required");
+ }
+ }
+
+ $element['contents'] = Utils::streamFor($element['contents']);
+
+ if (empty($element['filename'])) {
+ $uri = $element['contents']->getMetadata('uri');
+ if ($uri && \is_string($uri) && \substr($uri, 0, 6) !== 'php://' && \substr($uri, 0, 7) !== 'data://') {
+ $element['filename'] = $uri;
+ }
+ }
+
+ [$body, $headers] = $this->createElement(
+ $element['name'],
+ $element['contents'],
+ $element['filename'] ?? null,
+ $element['headers'] ?? []
+ );
+
+ $stream->addStream(Utils::streamFor($this->getHeaders($headers)));
+ $stream->addStream($body);
+ $stream->addStream(Utils::streamFor("\r\n"));
+ }
+
+ private function createElement(string $name, StreamInterface $stream, ?string $filename, array $headers): array
+ {
+ // Set a default content-disposition header if one was no provided
+ $disposition = $this->getHeader($headers, 'content-disposition');
+ if (!$disposition) {
+ $headers['Content-Disposition'] = ($filename === '0' || $filename)
+ ? sprintf(
+ 'form-data; name="%s"; filename="%s"',
+ $name,
+ basename($filename)
+ )
+ : "form-data; name=\"{$name}\"";
+ }
+
+ // Set a default content-length header if one was no provided
+ $length = $this->getHeader($headers, 'content-length');
+ if (!$length) {
+ if ($length = $stream->getSize()) {
+ $headers['Content-Length'] = (string) $length;
+ }
+ }
+
+ // Set a default Content-Type if one was not supplied
+ $type = $this->getHeader($headers, 'content-type');
+ if (!$type && ($filename === '0' || $filename)) {
+ if ($type = MimeType::fromFilename($filename)) {
+ $headers['Content-Type'] = $type;
+ }
+ }
+
+ return [$stream, $headers];
+ }
+
+ private function getHeader(array $headers, string $key)
+ {
+ $lowercaseHeader = strtolower($key);
+ foreach ($headers as $k => $v) {
+ if (strtolower($k) === $lowercaseHeader) {
+ return $v;
+ }
+ }
+
+ return null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/NoSeekStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/NoSeekStream.php
new file mode 100644
index 0000000..161a224
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/NoSeekStream.php
@@ -0,0 +1,28 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Stream decorator that prevents a stream from being seeked.
+ */
+final class NoSeekStream implements StreamInterface
+{
+ use StreamDecoratorTrait;
+
+ /** @var StreamInterface */
+ private $stream;
+
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ throw new \RuntimeException('Cannot seek a NoSeekStream');
+ }
+
+ public function isSeekable(): bool
+ {
+ return false;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/PumpStream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/PumpStream.php
new file mode 100644
index 0000000..e90389c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/PumpStream.php
@@ -0,0 +1,179 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Provides a read only stream that pumps data from a PHP callable.
+ *
+ * When invoking the provided callable, the PumpStream will pass the amount of
+ * data requested to read to the callable. The callable can choose to ignore
+ * this value and return fewer or more bytes than requested. Any extra data
+ * returned by the provided callable is buffered internally until drained using
+ * the read() function of the PumpStream. The provided callable MUST return
+ * false when there is no more data to read.
+ */
+final class PumpStream implements StreamInterface
+{
+ /** @var callable|null */
+ private $source;
+
+ /** @var int|null */
+ private $size;
+
+ /** @var int */
+ private $tellPos = 0;
+
+ /** @var array */
+ private $metadata;
+
+ /** @var BufferStream */
+ private $buffer;
+
+ /**
+ * @param callable(int): (string|null|false) $source Source of the stream data. The callable MAY
+ * accept an integer argument used to control the
+ * amount of data to return. The callable MUST
+ * return a string when called, or false|null on error
+ * or EOF.
+ * @param array{size?: int, metadata?: array} $options Stream options:
+ * - metadata: Hash of metadata to use with stream.
+ * - size: Size of the stream, if known.
+ */
+ public function __construct(callable $source, array $options = [])
+ {
+ $this->source = $source;
+ $this->size = $options['size'] ?? null;
+ $this->metadata = $options['metadata'] ?? [];
+ $this->buffer = new BufferStream();
+ }
+
+ public function __toString(): string
+ {
+ try {
+ return Utils::copyToString($this);
+ } catch (\Throwable $e) {
+ if (\PHP_VERSION_ID >= 70400) {
+ throw $e;
+ }
+ trigger_error(sprintf('%s::__toString exception: %s', self::class, (string) $e), E_USER_ERROR);
+ return '';
+ }
+ }
+
+ public function close(): void
+ {
+ $this->detach();
+ }
+
+ public function detach()
+ {
+ $this->tellPos = 0;
+ $this->source = null;
+
+ return null;
+ }
+
+ public function getSize(): ?int
+ {
+ return $this->size;
+ }
+
+ public function tell(): int
+ {
+ return $this->tellPos;
+ }
+
+ public function eof(): bool
+ {
+ return $this->source === null;
+ }
+
+ public function isSeekable(): bool
+ {
+ return false;
+ }
+
+ public function rewind(): void
+ {
+ $this->seek(0);
+ }
+
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ throw new \RuntimeException('Cannot seek a PumpStream');
+ }
+
+ public function isWritable(): bool
+ {
+ return false;
+ }
+
+ public function write($string): int
+ {
+ throw new \RuntimeException('Cannot write to a PumpStream');
+ }
+
+ public function isReadable(): bool
+ {
+ return true;
+ }
+
+ public function read($length): string
+ {
+ $data = $this->buffer->read($length);
+ $readLen = strlen($data);
+ $this->tellPos += $readLen;
+ $remaining = $length - $readLen;
+
+ if ($remaining) {
+ $this->pump($remaining);
+ $data .= $this->buffer->read($remaining);
+ $this->tellPos += strlen($data) - $readLen;
+ }
+
+ return $data;
+ }
+
+ public function getContents(): string
+ {
+ $result = '';
+ while (!$this->eof()) {
+ $result .= $this->read(1000000);
+ }
+
+ return $result;
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return mixed
+ */
+ public function getMetadata($key = null)
+ {
+ if (!$key) {
+ return $this->metadata;
+ }
+
+ return $this->metadata[$key] ?? null;
+ }
+
+ private function pump(int $length): void
+ {
+ if ($this->source) {
+ do {
+ $data = call_user_func($this->source, $length);
+ if ($data === false || $data === null) {
+ $this->source = null;
+ return;
+ }
+ $this->buffer->write($data);
+ $length -= strlen($data);
+ } while ($length > 0);
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Query.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Query.php
new file mode 100644
index 0000000..2faab3a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Query.php
@@ -0,0 +1,113 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+final class Query
+{
+ /**
+ * Parse a query string into an associative array.
+ *
+ * If multiple values are found for the same key, the value of that key
+ * value pair will become an array. This function does not parse nested
+ * PHP style arrays into an associative array (e.g., `foo[a]=1&foo[b]=2`
+ * will be parsed into `['foo[a]' => '1', 'foo[b]' => '2'])`.
+ *
+ * @param string $str Query string to parse
+ * @param int|bool $urlEncoding How the query string is encoded
+ */
+ public static function parse(string $str, $urlEncoding = true): array
+ {
+ $result = [];
+
+ if ($str === '') {
+ return $result;
+ }
+
+ if ($urlEncoding === true) {
+ $decoder = function ($value) {
+ return rawurldecode(str_replace('+', ' ', (string) $value));
+ };
+ } elseif ($urlEncoding === PHP_QUERY_RFC3986) {
+ $decoder = 'rawurldecode';
+ } elseif ($urlEncoding === PHP_QUERY_RFC1738) {
+ $decoder = 'urldecode';
+ } else {
+ $decoder = function ($str) {
+ return $str;
+ };
+ }
+
+ foreach (explode('&', $str) as $kvp) {
+ $parts = explode('=', $kvp, 2);
+ $key = $decoder($parts[0]);
+ $value = isset($parts[1]) ? $decoder($parts[1]) : null;
+ if (!array_key_exists($key, $result)) {
+ $result[$key] = $value;
+ } else {
+ if (!is_array($result[$key])) {
+ $result[$key] = [$result[$key]];
+ }
+ $result[$key][] = $value;
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Build a query string from an array of key value pairs.
+ *
+ * This function can use the return value of `parse()` to build a query
+ * string. This function does not modify the provided keys when an array is
+ * encountered (like `http_build_query()` would).
+ *
+ * @param array $params Query string parameters.
+ * @param int|false $encoding Set to false to not encode, PHP_QUERY_RFC3986
+ * to encode using RFC3986, or PHP_QUERY_RFC1738
+ * to encode using RFC1738.
+ */
+ public static function build(array $params, $encoding = PHP_QUERY_RFC3986): string
+ {
+ if (!$params) {
+ return '';
+ }
+
+ if ($encoding === false) {
+ $encoder = function (string $str): string {
+ return $str;
+ };
+ } elseif ($encoding === PHP_QUERY_RFC3986) {
+ $encoder = 'rawurlencode';
+ } elseif ($encoding === PHP_QUERY_RFC1738) {
+ $encoder = 'urlencode';
+ } else {
+ throw new \InvalidArgumentException('Invalid type');
+ }
+
+ $qs = '';
+ foreach ($params as $k => $v) {
+ $k = $encoder((string) $k);
+ if (!is_array($v)) {
+ $qs .= $k;
+ $v = is_bool($v) ? (int) $v : $v;
+ if ($v !== null) {
+ $qs .= '=' . $encoder((string) $v);
+ }
+ $qs .= '&';
+ } else {
+ foreach ($v as $vv) {
+ $qs .= $k;
+ $vv = is_bool($vv) ? (int) $vv : $vv;
+ if ($vv !== null) {
+ $qs .= '=' . $encoder((string) $vv);
+ }
+ $qs .= '&';
+ }
+ }
+ }
+
+ return $qs ? (string) substr($qs, 0, -1) : '';
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Request.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Request.php
new file mode 100644
index 0000000..b17af66
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Request.php
@@ -0,0 +1,157 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use InvalidArgumentException;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\StreamInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * PSR-7 request implementation.
+ */
+class Request implements RequestInterface
+{
+ use MessageTrait;
+
+ /** @var string */
+ private $method;
+
+ /** @var string|null */
+ private $requestTarget;
+
+ /** @var UriInterface */
+ private $uri;
+
+ /**
+ * @param string $method HTTP method
+ * @param string|UriInterface $uri URI
+ * @param array<string, string|string[]> $headers Request headers
+ * @param string|resource|StreamInterface|null $body Request body
+ * @param string $version Protocol version
+ */
+ public function __construct(
+ string $method,
+ $uri,
+ array $headers = [],
+ $body = null,
+ string $version = '1.1'
+ ) {
+ $this->assertMethod($method);
+ if (!($uri instanceof UriInterface)) {
+ $uri = new Uri($uri);
+ }
+
+ $this->method = strtoupper($method);
+ $this->uri = $uri;
+ $this->setHeaders($headers);
+ $this->protocol = $version;
+
+ if (!isset($this->headerNames['host'])) {
+ $this->updateHostFromUri();
+ }
+
+ if ($body !== '' && $body !== null) {
+ $this->stream = Utils::streamFor($body);
+ }
+ }
+
+ public function getRequestTarget(): string
+ {
+ if ($this->requestTarget !== null) {
+ return $this->requestTarget;
+ }
+
+ $target = $this->uri->getPath();
+ if ($target === '') {
+ $target = '/';
+ }
+ if ($this->uri->getQuery() != '') {
+ $target .= '?' . $this->uri->getQuery();
+ }
+
+ return $target;
+ }
+
+ public function withRequestTarget($requestTarget): RequestInterface
+ {
+ if (preg_match('#\s#', $requestTarget)) {
+ throw new InvalidArgumentException(
+ 'Invalid request target provided; cannot contain whitespace'
+ );
+ }
+
+ $new = clone $this;
+ $new->requestTarget = $requestTarget;
+ return $new;
+ }
+
+ public function getMethod(): string
+ {
+ return $this->method;
+ }
+
+ public function withMethod($method): RequestInterface
+ {
+ $this->assertMethod($method);
+ $new = clone $this;
+ $new->method = strtoupper($method);
+ return $new;
+ }
+
+ public function getUri(): UriInterface
+ {
+ return $this->uri;
+ }
+
+ public function withUri(UriInterface $uri, $preserveHost = false): RequestInterface
+ {
+ if ($uri === $this->uri) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->uri = $uri;
+
+ if (!$preserveHost || !isset($this->headerNames['host'])) {
+ $new->updateHostFromUri();
+ }
+
+ return $new;
+ }
+
+ private function updateHostFromUri(): void
+ {
+ $host = $this->uri->getHost();
+
+ if ($host == '') {
+ return;
+ }
+
+ if (($port = $this->uri->getPort()) !== null) {
+ $host .= ':' . $port;
+ }
+
+ if (isset($this->headerNames['host'])) {
+ $header = $this->headerNames['host'];
+ } else {
+ $header = 'Host';
+ $this->headerNames['host'] = 'Host';
+ }
+ // Ensure Host is the first header.
+ // See: http://tools.ietf.org/html/rfc7230#section-5.4
+ $this->headers = [$header => [$host]] + $this->headers;
+ }
+
+ /**
+ * @param mixed $method
+ */
+ private function assertMethod($method): void
+ {
+ if (!is_string($method) || $method === '') {
+ throw new InvalidArgumentException('Method must be a non-empty string.');
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Response.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Response.php
new file mode 100644
index 0000000..4c6ee6f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Response.php
@@ -0,0 +1,160 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\ResponseInterface;
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * PSR-7 response implementation.
+ */
+class Response implements ResponseInterface
+{
+ use MessageTrait;
+
+ /** Map of standard HTTP status code/reason phrases */
+ private const PHRASES = [
+ 100 => 'Continue',
+ 101 => 'Switching Protocols',
+ 102 => 'Processing',
+ 200 => 'OK',
+ 201 => 'Created',
+ 202 => 'Accepted',
+ 203 => 'Non-Authoritative Information',
+ 204 => 'No Content',
+ 205 => 'Reset Content',
+ 206 => 'Partial Content',
+ 207 => 'Multi-status',
+ 208 => 'Already Reported',
+ 300 => 'Multiple Choices',
+ 301 => 'Moved Permanently',
+ 302 => 'Found',
+ 303 => 'See Other',
+ 304 => 'Not Modified',
+ 305 => 'Use Proxy',
+ 306 => 'Switch Proxy',
+ 307 => 'Temporary Redirect',
+ 308 => 'Permanent Redirect',
+ 400 => 'Bad Request',
+ 401 => 'Unauthorized',
+ 402 => 'Payment Required',
+ 403 => 'Forbidden',
+ 404 => 'Not Found',
+ 405 => 'Method Not Allowed',
+ 406 => 'Not Acceptable',
+ 407 => 'Proxy Authentication Required',
+ 408 => 'Request Time-out',
+ 409 => 'Conflict',
+ 410 => 'Gone',
+ 411 => 'Length Required',
+ 412 => 'Precondition Failed',
+ 413 => 'Request Entity Too Large',
+ 414 => 'Request-URI Too Large',
+ 415 => 'Unsupported Media Type',
+ 416 => 'Requested range not satisfiable',
+ 417 => 'Expectation Failed',
+ 418 => 'I\'m a teapot',
+ 422 => 'Unprocessable Entity',
+ 423 => 'Locked',
+ 424 => 'Failed Dependency',
+ 425 => 'Unordered Collection',
+ 426 => 'Upgrade Required',
+ 428 => 'Precondition Required',
+ 429 => 'Too Many Requests',
+ 431 => 'Request Header Fields Too Large',
+ 451 => 'Unavailable For Legal Reasons',
+ 500 => 'Internal Server Error',
+ 501 => 'Not Implemented',
+ 502 => 'Bad Gateway',
+ 503 => 'Service Unavailable',
+ 504 => 'Gateway Time-out',
+ 505 => 'HTTP Version not supported',
+ 506 => 'Variant Also Negotiates',
+ 507 => 'Insufficient Storage',
+ 508 => 'Loop Detected',
+ 510 => 'Not Extended',
+ 511 => 'Network Authentication Required',
+ ];
+
+ /** @var string */
+ private $reasonPhrase;
+
+ /** @var int */
+ private $statusCode;
+
+ /**
+ * @param int $status Status code
+ * @param array<string, string|string[]> $headers Response headers
+ * @param string|resource|StreamInterface|null $body Response body
+ * @param string $version Protocol version
+ * @param string|null $reason Reason phrase (when empty a default will be used based on the status code)
+ */
+ public function __construct(
+ int $status = 200,
+ array $headers = [],
+ $body = null,
+ string $version = '1.1',
+ string $reason = null
+ ) {
+ $this->assertStatusCodeRange($status);
+
+ $this->statusCode = $status;
+
+ if ($body !== '' && $body !== null) {
+ $this->stream = Utils::streamFor($body);
+ }
+
+ $this->setHeaders($headers);
+ if ($reason == '' && isset(self::PHRASES[$this->statusCode])) {
+ $this->reasonPhrase = self::PHRASES[$this->statusCode];
+ } else {
+ $this->reasonPhrase = (string) $reason;
+ }
+
+ $this->protocol = $version;
+ }
+
+ public function getStatusCode(): int
+ {
+ return $this->statusCode;
+ }
+
+ public function getReasonPhrase(): string
+ {
+ return $this->reasonPhrase;
+ }
+
+ public function withStatus($code, $reasonPhrase = ''): ResponseInterface
+ {
+ $this->assertStatusCodeIsInteger($code);
+ $code = (int) $code;
+ $this->assertStatusCodeRange($code);
+
+ $new = clone $this;
+ $new->statusCode = $code;
+ if ($reasonPhrase == '' && isset(self::PHRASES[$new->statusCode])) {
+ $reasonPhrase = self::PHRASES[$new->statusCode];
+ }
+ $new->reasonPhrase = (string) $reasonPhrase;
+ return $new;
+ }
+
+ /**
+ * @param mixed $statusCode
+ */
+ private function assertStatusCodeIsInteger($statusCode): void
+ {
+ if (filter_var($statusCode, FILTER_VALIDATE_INT) === false) {
+ throw new \InvalidArgumentException('Status code must be an integer value.');
+ }
+ }
+
+ private function assertStatusCodeRange(int $statusCode): void
+ {
+ if ($statusCode < 100 || $statusCode >= 600) {
+ throw new \InvalidArgumentException('Status code must be an integer value between 1xx and 5xx.');
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Rfc7230.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Rfc7230.php
new file mode 100644
index 0000000..3022401
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Rfc7230.php
@@ -0,0 +1,23 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+/**
+ * @internal
+ */
+final class Rfc7230
+{
+ /**
+ * Header related regular expressions (based on amphp/http package)
+ *
+ * Note: header delimiter (\r\n) is modified to \r?\n to accept line feed only delimiters for BC reasons.
+ *
+ * @link https://github.com/amphp/http/blob/v1.0.1/src/Rfc7230.php#L12-L15
+ *
+ * @license https://github.com/amphp/http/blob/v1.0.1/LICENSE
+ */
+ public const HEADER_REGEX = "(^([^()<>@,;:\\\"/[\]?={}\x01-\x20\x7F]++):[ \t]*+((?:[ \t]*+[\x21-\x7E\x80-\xFF]++)*+)[ \t]*+\r?\n)m";
+ public const HEADER_FOLD_REGEX = "(\r?\n[ \t]++)";
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/ServerRequest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/ServerRequest.php
new file mode 100644
index 0000000..b2aa382
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/ServerRequest.php
@@ -0,0 +1,344 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use InvalidArgumentException;
+use Psr\Http\Message\ServerRequestInterface;
+use Psr\Http\Message\StreamInterface;
+use Psr\Http\Message\UploadedFileInterface;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Server-side HTTP request
+ *
+ * Extends the Request definition to add methods for accessing incoming data,
+ * specifically server parameters, cookies, matched path parameters, query
+ * string arguments, body parameters, and upload file information.
+ *
+ * "Attributes" are discovered via decomposing the request (and usually
+ * specifically the URI path), and typically will be injected by the application.
+ *
+ * Requests are considered immutable; all methods that might change state are
+ * implemented such that they retain the internal state of the current
+ * message and return a new instance that contains the changed state.
+ */
+class ServerRequest extends Request implements ServerRequestInterface
+{
+ /**
+ * @var array
+ */
+ private $attributes = [];
+
+ /**
+ * @var array
+ */
+ private $cookieParams = [];
+
+ /**
+ * @var array|object|null
+ */
+ private $parsedBody;
+
+ /**
+ * @var array
+ */
+ private $queryParams = [];
+
+ /**
+ * @var array
+ */
+ private $serverParams;
+
+ /**
+ * @var array
+ */
+ private $uploadedFiles = [];
+
+ /**
+ * @param string $method HTTP method
+ * @param string|UriInterface $uri URI
+ * @param array<string, string|string[]> $headers Request headers
+ * @param string|resource|StreamInterface|null $body Request body
+ * @param string $version Protocol version
+ * @param array $serverParams Typically the $_SERVER superglobal
+ */
+ public function __construct(
+ string $method,
+ $uri,
+ array $headers = [],
+ $body = null,
+ string $version = '1.1',
+ array $serverParams = []
+ ) {
+ $this->serverParams = $serverParams;
+
+ parent::__construct($method, $uri, $headers, $body, $version);
+ }
+
+ /**
+ * Return an UploadedFile instance array.
+ *
+ * @param array $files An array which respect $_FILES structure
+ *
+ * @throws InvalidArgumentException for unrecognized values
+ */
+ public static function normalizeFiles(array $files): array
+ {
+ $normalized = [];
+
+ foreach ($files as $key => $value) {
+ if ($value instanceof UploadedFileInterface) {
+ $normalized[$key] = $value;
+ } elseif (is_array($value) && isset($value['tmp_name'])) {
+ $normalized[$key] = self::createUploadedFileFromSpec($value);
+ } elseif (is_array($value)) {
+ $normalized[$key] = self::normalizeFiles($value);
+ continue;
+ } else {
+ throw new InvalidArgumentException('Invalid value in files specification');
+ }
+ }
+
+ return $normalized;
+ }
+
+ /**
+ * Create and return an UploadedFile instance from a $_FILES specification.
+ *
+ * If the specification represents an array of values, this method will
+ * delegate to normalizeNestedFileSpec() and return that return value.
+ *
+ * @param array $value $_FILES struct
+ *
+ * @return UploadedFileInterface|UploadedFileInterface[]
+ */
+ private static function createUploadedFileFromSpec(array $value)
+ {
+ if (is_array($value['tmp_name'])) {
+ return self::normalizeNestedFileSpec($value);
+ }
+
+ return new UploadedFile(
+ $value['tmp_name'],
+ (int) $value['size'],
+ (int) $value['error'],
+ $value['name'],
+ $value['type']
+ );
+ }
+
+ /**
+ * Normalize an array of file specifications.
+ *
+ * Loops through all nested files and returns a normalized array of
+ * UploadedFileInterface instances.
+ *
+ * @return UploadedFileInterface[]
+ */
+ private static function normalizeNestedFileSpec(array $files = []): array
+ {
+ $normalizedFiles = [];
+
+ foreach (array_keys($files['tmp_name']) as $key) {
+ $spec = [
+ 'tmp_name' => $files['tmp_name'][$key],
+ 'size' => $files['size'][$key] ?? null,
+ 'error' => $files['error'][$key] ?? null,
+ 'name' => $files['name'][$key] ?? null,
+ 'type' => $files['type'][$key] ?? null,
+ ];
+ $normalizedFiles[$key] = self::createUploadedFileFromSpec($spec);
+ }
+
+ return $normalizedFiles;
+ }
+
+ /**
+ * Return a ServerRequest populated with superglobals:
+ * $_GET
+ * $_POST
+ * $_COOKIE
+ * $_FILES
+ * $_SERVER
+ */
+ public static function fromGlobals(): ServerRequestInterface
+ {
+ $method = $_SERVER['REQUEST_METHOD'] ?? 'GET';
+ $headers = getallheaders();
+ $uri = self::getUriFromGlobals();
+ $body = new CachingStream(new LazyOpenStream('php://input', 'r+'));
+ $protocol = isset($_SERVER['SERVER_PROTOCOL']) ? str_replace('HTTP/', '', $_SERVER['SERVER_PROTOCOL']) : '1.1';
+
+ $serverRequest = new ServerRequest($method, $uri, $headers, $body, $protocol, $_SERVER);
+
+ return $serverRequest
+ ->withCookieParams($_COOKIE)
+ ->withQueryParams($_GET)
+ ->withParsedBody($_POST)
+ ->withUploadedFiles(self::normalizeFiles($_FILES));
+ }
+
+ private static function extractHostAndPortFromAuthority(string $authority): array
+ {
+ $uri = 'http://' . $authority;
+ $parts = parse_url($uri);
+ if (false === $parts) {
+ return [null, null];
+ }
+
+ $host = $parts['host'] ?? null;
+ $port = $parts['port'] ?? null;
+
+ return [$host, $port];
+ }
+
+ /**
+ * Get a Uri populated with values from $_SERVER.
+ */
+ public static function getUriFromGlobals(): UriInterface
+ {
+ $uri = new Uri('');
+
+ $uri = $uri->withScheme(!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http');
+
+ $hasPort = false;
+ if (isset($_SERVER['HTTP_HOST'])) {
+ [$host, $port] = self::extractHostAndPortFromAuthority($_SERVER['HTTP_HOST']);
+ if ($host !== null) {
+ $uri = $uri->withHost($host);
+ }
+
+ if ($port !== null) {
+ $hasPort = true;
+ $uri = $uri->withPort($port);
+ }
+ } elseif (isset($_SERVER['SERVER_NAME'])) {
+ $uri = $uri->withHost($_SERVER['SERVER_NAME']);
+ } elseif (isset($_SERVER['SERVER_ADDR'])) {
+ $uri = $uri->withHost($_SERVER['SERVER_ADDR']);
+ }
+
+ if (!$hasPort && isset($_SERVER['SERVER_PORT'])) {
+ $uri = $uri->withPort($_SERVER['SERVER_PORT']);
+ }
+
+ $hasQuery = false;
+ if (isset($_SERVER['REQUEST_URI'])) {
+ $requestUriParts = explode('?', $_SERVER['REQUEST_URI'], 2);
+ $uri = $uri->withPath($requestUriParts[0]);
+ if (isset($requestUriParts[1])) {
+ $hasQuery = true;
+ $uri = $uri->withQuery($requestUriParts[1]);
+ }
+ }
+
+ if (!$hasQuery && isset($_SERVER['QUERY_STRING'])) {
+ $uri = $uri->withQuery($_SERVER['QUERY_STRING']);
+ }
+
+ return $uri;
+ }
+
+ public function getServerParams(): array
+ {
+ return $this->serverParams;
+ }
+
+ public function getUploadedFiles(): array
+ {
+ return $this->uploadedFiles;
+ }
+
+ public function withUploadedFiles(array $uploadedFiles): ServerRequestInterface
+ {
+ $new = clone $this;
+ $new->uploadedFiles = $uploadedFiles;
+
+ return $new;
+ }
+
+ public function getCookieParams(): array
+ {
+ return $this->cookieParams;
+ }
+
+ public function withCookieParams(array $cookies): ServerRequestInterface
+ {
+ $new = clone $this;
+ $new->cookieParams = $cookies;
+
+ return $new;
+ }
+
+ public function getQueryParams(): array
+ {
+ return $this->queryParams;
+ }
+
+ public function withQueryParams(array $query): ServerRequestInterface
+ {
+ $new = clone $this;
+ $new->queryParams = $query;
+
+ return $new;
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return array|object|null
+ */
+ public function getParsedBody()
+ {
+ return $this->parsedBody;
+ }
+
+ public function withParsedBody($data): ServerRequestInterface
+ {
+ $new = clone $this;
+ $new->parsedBody = $data;
+
+ return $new;
+ }
+
+ public function getAttributes(): array
+ {
+ return $this->attributes;
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return mixed
+ */
+ public function getAttribute($attribute, $default = null)
+ {
+ if (false === array_key_exists($attribute, $this->attributes)) {
+ return $default;
+ }
+
+ return $this->attributes[$attribute];
+ }
+
+ public function withAttribute($attribute, $value): ServerRequestInterface
+ {
+ $new = clone $this;
+ $new->attributes[$attribute] = $value;
+
+ return $new;
+ }
+
+ public function withoutAttribute($attribute): ServerRequestInterface
+ {
+ if (false === array_key_exists($attribute, $this->attributes)) {
+ return $this;
+ }
+
+ $new = clone $this;
+ unset($new->attributes[$attribute]);
+
+ return $new;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Stream.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Stream.php
new file mode 100644
index 0000000..ecd3186
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Stream.php
@@ -0,0 +1,282 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * PHP stream implementation.
+ */
+class Stream implements StreamInterface
+{
+ /**
+ * @see http://php.net/manual/function.fopen.php
+ * @see http://php.net/manual/en/function.gzopen.php
+ */
+ private const READABLE_MODES = '/r|a\+|ab\+|w\+|wb\+|x\+|xb\+|c\+|cb\+/';
+ private const WRITABLE_MODES = '/a|w|r\+|rb\+|rw|x|c/';
+
+ /** @var resource */
+ private $stream;
+ /** @var int|null */
+ private $size;
+ /** @var bool */
+ private $seekable;
+ /** @var bool */
+ private $readable;
+ /** @var bool */
+ private $writable;
+ /** @var string|null */
+ private $uri;
+ /** @var mixed[] */
+ private $customMetadata;
+
+ /**
+ * This constructor accepts an associative array of options.
+ *
+ * - size: (int) If a read stream would otherwise have an indeterminate
+ * size, but the size is known due to foreknowledge, then you can
+ * provide that size, in bytes.
+ * - metadata: (array) Any additional metadata to return when the metadata
+ * of the stream is accessed.
+ *
+ * @param resource $stream Stream resource to wrap.
+ * @param array{size?: int, metadata?: array} $options Associative array of options.
+ *
+ * @throws \InvalidArgumentException if the stream is not a stream resource
+ */
+ public function __construct($stream, array $options = [])
+ {
+ if (!is_resource($stream)) {
+ throw new \InvalidArgumentException('Stream must be a resource');
+ }
+
+ if (isset($options['size'])) {
+ $this->size = $options['size'];
+ }
+
+ $this->customMetadata = $options['metadata'] ?? [];
+ $this->stream = $stream;
+ $meta = stream_get_meta_data($this->stream);
+ $this->seekable = $meta['seekable'];
+ $this->readable = (bool)preg_match(self::READABLE_MODES, $meta['mode']);
+ $this->writable = (bool)preg_match(self::WRITABLE_MODES, $meta['mode']);
+ $this->uri = $this->getMetadata('uri');
+ }
+
+ /**
+ * Closes the stream when the destructed
+ */
+ public function __destruct()
+ {
+ $this->close();
+ }
+
+ public function __toString(): string
+ {
+ try {
+ if ($this->isSeekable()) {
+ $this->seek(0);
+ }
+ return $this->getContents();
+ } catch (\Throwable $e) {
+ if (\PHP_VERSION_ID >= 70400) {
+ throw $e;
+ }
+ trigger_error(sprintf('%s::__toString exception: %s', self::class, (string) $e), E_USER_ERROR);
+ return '';
+ }
+ }
+
+ public function getContents(): string
+ {
+ if (!isset($this->stream)) {
+ throw new \RuntimeException('Stream is detached');
+ }
+
+ if (!$this->readable) {
+ throw new \RuntimeException('Cannot read from non-readable stream');
+ }
+
+ return Utils::tryGetContents($this->stream);
+ }
+
+ public function close(): void
+ {
+ if (isset($this->stream)) {
+ if (is_resource($this->stream)) {
+ fclose($this->stream);
+ }
+ $this->detach();
+ }
+ }
+
+ public function detach()
+ {
+ if (!isset($this->stream)) {
+ return null;
+ }
+
+ $result = $this->stream;
+ unset($this->stream);
+ $this->size = $this->uri = null;
+ $this->readable = $this->writable = $this->seekable = false;
+
+ return $result;
+ }
+
+ public function getSize(): ?int
+ {
+ if ($this->size !== null) {
+ return $this->size;
+ }
+
+ if (!isset($this->stream)) {
+ return null;
+ }
+
+ // Clear the stat cache if the stream has a URI
+ if ($this->uri) {
+ clearstatcache(true, $this->uri);
+ }
+
+ $stats = fstat($this->stream);
+ if (is_array($stats) && isset($stats['size'])) {
+ $this->size = $stats['size'];
+ return $this->size;
+ }
+
+ return null;
+ }
+
+ public function isReadable(): bool
+ {
+ return $this->readable;
+ }
+
+ public function isWritable(): bool
+ {
+ return $this->writable;
+ }
+
+ public function isSeekable(): bool
+ {
+ return $this->seekable;
+ }
+
+ public function eof(): bool
+ {
+ if (!isset($this->stream)) {
+ throw new \RuntimeException('Stream is detached');
+ }
+
+ return feof($this->stream);
+ }
+
+ public function tell(): int
+ {
+ if (!isset($this->stream)) {
+ throw new \RuntimeException('Stream is detached');
+ }
+
+ $result = ftell($this->stream);
+
+ if ($result === false) {
+ throw new \RuntimeException('Unable to determine stream position');
+ }
+
+ return $result;
+ }
+
+ public function rewind(): void
+ {
+ $this->seek(0);
+ }
+
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ $whence = (int) $whence;
+
+ if (!isset($this->stream)) {
+ throw new \RuntimeException('Stream is detached');
+ }
+ if (!$this->seekable) {
+ throw new \RuntimeException('Stream is not seekable');
+ }
+ if (fseek($this->stream, $offset, $whence) === -1) {
+ throw new \RuntimeException('Unable to seek to stream position '
+ . $offset . ' with whence ' . var_export($whence, true));
+ }
+ }
+
+ public function read($length): string
+ {
+ if (!isset($this->stream)) {
+ throw new \RuntimeException('Stream is detached');
+ }
+ if (!$this->readable) {
+ throw new \RuntimeException('Cannot read from non-readable stream');
+ }
+ if ($length < 0) {
+ throw new \RuntimeException('Length parameter cannot be negative');
+ }
+
+ if (0 === $length) {
+ return '';
+ }
+
+ try {
+ $string = fread($this->stream, $length);
+ } catch (\Exception $e) {
+ throw new \RuntimeException('Unable to read from stream', 0, $e);
+ }
+
+ if (false === $string) {
+ throw new \RuntimeException('Unable to read from stream');
+ }
+
+ return $string;
+ }
+
+ public function write($string): int
+ {
+ if (!isset($this->stream)) {
+ throw new \RuntimeException('Stream is detached');
+ }
+ if (!$this->writable) {
+ throw new \RuntimeException('Cannot write to a non-writable stream');
+ }
+
+ // We can't know the size after writing anything
+ $this->size = null;
+ $result = fwrite($this->stream, $string);
+
+ if ($result === false) {
+ throw new \RuntimeException('Unable to write to stream');
+ }
+
+ return $result;
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return mixed
+ */
+ public function getMetadata($key = null)
+ {
+ if (!isset($this->stream)) {
+ return $key ? null : [];
+ } elseif (!$key) {
+ return $this->customMetadata + stream_get_meta_data($this->stream);
+ } elseif (isset($this->customMetadata[$key])) {
+ return $this->customMetadata[$key];
+ }
+
+ $meta = stream_get_meta_data($this->stream);
+
+ return $meta[$key] ?? null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/StreamDecoratorTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/StreamDecoratorTrait.php
new file mode 100644
index 0000000..56d4104
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/StreamDecoratorTrait.php
@@ -0,0 +1,155 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Stream decorator trait
+ *
+ * @property StreamInterface $stream
+ */
+trait StreamDecoratorTrait
+{
+ /**
+ * @param StreamInterface $stream Stream to decorate
+ */
+ public function __construct(StreamInterface $stream)
+ {
+ $this->stream = $stream;
+ }
+
+ /**
+ * Magic method used to create a new stream if streams are not added in
+ * the constructor of a decorator (e.g., LazyOpenStream).
+ *
+ * @return StreamInterface
+ */
+ public function __get(string $name)
+ {
+ if ($name === 'stream') {
+ $this->stream = $this->createStream();
+ return $this->stream;
+ }
+
+ throw new \UnexpectedValueException("$name not found on class");
+ }
+
+ public function __toString(): string
+ {
+ try {
+ if ($this->isSeekable()) {
+ $this->seek(0);
+ }
+ return $this->getContents();
+ } catch (\Throwable $e) {
+ if (\PHP_VERSION_ID >= 70400) {
+ throw $e;
+ }
+ trigger_error(sprintf('%s::__toString exception: %s', self::class, (string) $e), E_USER_ERROR);
+ return '';
+ }
+ }
+
+ public function getContents(): string
+ {
+ return Utils::copyToString($this);
+ }
+
+ /**
+ * Allow decorators to implement custom methods
+ *
+ * @return mixed
+ */
+ public function __call(string $method, array $args)
+ {
+ /** @var callable $callable */
+ $callable = [$this->stream, $method];
+ $result = call_user_func_array($callable, $args);
+
+ // Always return the wrapped object if the result is a return $this
+ return $result === $this->stream ? $this : $result;
+ }
+
+ public function close(): void
+ {
+ $this->stream->close();
+ }
+
+ /**
+ * {@inheritdoc}
+ *
+ * @return mixed
+ */
+ public function getMetadata($key = null)
+ {
+ return $this->stream->getMetadata($key);
+ }
+
+ public function detach()
+ {
+ return $this->stream->detach();
+ }
+
+ public function getSize(): ?int
+ {
+ return $this->stream->getSize();
+ }
+
+ public function eof(): bool
+ {
+ return $this->stream->eof();
+ }
+
+ public function tell(): int
+ {
+ return $this->stream->tell();
+ }
+
+ public function isReadable(): bool
+ {
+ return $this->stream->isReadable();
+ }
+
+ public function isWritable(): bool
+ {
+ return $this->stream->isWritable();
+ }
+
+ public function isSeekable(): bool
+ {
+ return $this->stream->isSeekable();
+ }
+
+ public function rewind(): void
+ {
+ $this->seek(0);
+ }
+
+ public function seek($offset, $whence = SEEK_SET): void
+ {
+ $this->stream->seek($offset, $whence);
+ }
+
+ public function read($length): string
+ {
+ return $this->stream->read($length);
+ }
+
+ public function write($string): int
+ {
+ return $this->stream->write($string);
+ }
+
+ /**
+ * Implement in subclasses to dynamically create streams when requested.
+ *
+ * @throws \BadMethodCallException
+ */
+ protected function createStream(): StreamInterface
+ {
+ throw new \BadMethodCallException('Not implemented');
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/StreamWrapper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/StreamWrapper.php
new file mode 100644
index 0000000..2a93464
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/StreamWrapper.php
@@ -0,0 +1,175 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\StreamInterface;
+
+/**
+ * Converts Guzzle streams into PHP stream resources.
+ *
+ * @see https://www.php.net/streamwrapper
+ */
+final class StreamWrapper
+{
+ /** @var resource */
+ public $context;
+
+ /** @var StreamInterface */
+ private $stream;
+
+ /** @var string r, r+, or w */
+ private $mode;
+
+ /**
+ * Returns a resource representing the stream.
+ *
+ * @param StreamInterface $stream The stream to get a resource for
+ *
+ * @return resource
+ *
+ * @throws \InvalidArgumentException if stream is not readable or writable
+ */
+ public static function getResource(StreamInterface $stream)
+ {
+ self::register();
+
+ if ($stream->isReadable()) {
+ $mode = $stream->isWritable() ? 'r+' : 'r';
+ } elseif ($stream->isWritable()) {
+ $mode = 'w';
+ } else {
+ throw new \InvalidArgumentException('The stream must be readable, '
+ . 'writable, or both.');
+ }
+
+ return fopen('guzzle://stream', $mode, false, self::createStreamContext($stream));
+ }
+
+ /**
+ * Creates a stream context that can be used to open a stream as a php stream resource.
+ *
+ * @return resource
+ */
+ public static function createStreamContext(StreamInterface $stream)
+ {
+ return stream_context_create([
+ 'guzzle' => ['stream' => $stream]
+ ]);
+ }
+
+ /**
+ * Registers the stream wrapper if needed
+ */
+ public static function register(): void
+ {
+ if (!in_array('guzzle', stream_get_wrappers())) {
+ stream_wrapper_register('guzzle', __CLASS__);
+ }
+ }
+
+ public function stream_open(string $path, string $mode, int $options, string &$opened_path = null): bool
+ {
+ $options = stream_context_get_options($this->context);
+
+ if (!isset($options['guzzle']['stream'])) {
+ return false;
+ }
+
+ $this->mode = $mode;
+ $this->stream = $options['guzzle']['stream'];
+
+ return true;
+ }
+
+ public function stream_read(int $count): string
+ {
+ return $this->stream->read($count);
+ }
+
+ public function stream_write(string $data): int
+ {
+ return $this->stream->write($data);
+ }
+
+ public function stream_tell(): int
+ {
+ return $this->stream->tell();
+ }
+
+ public function stream_eof(): bool
+ {
+ return $this->stream->eof();
+ }
+
+ public function stream_seek(int $offset, int $whence): bool
+ {
+ $this->stream->seek($offset, $whence);
+
+ return true;
+ }
+
+ /**
+ * @return resource|false
+ */
+ public function stream_cast(int $cast_as)
+ {
+ $stream = clone($this->stream);
+ $resource = $stream->detach();
+
+ return $resource ?? false;
+ }
+
+ /**
+ * @return array<int|string, int>
+ */
+ public function stream_stat(): array
+ {
+ static $modeMap = [
+ 'r' => 33060,
+ 'rb' => 33060,
+ 'r+' => 33206,
+ 'w' => 33188,
+ 'wb' => 33188
+ ];
+
+ return [
+ 'dev' => 0,
+ 'ino' => 0,
+ 'mode' => $modeMap[$this->mode],
+ 'nlink' => 0,
+ 'uid' => 0,
+ 'gid' => 0,
+ 'rdev' => 0,
+ 'size' => $this->stream->getSize() ?: 0,
+ 'atime' => 0,
+ 'mtime' => 0,
+ 'ctime' => 0,
+ 'blksize' => 0,
+ 'blocks' => 0
+ ];
+ }
+
+ /**
+ * @return array<int|string, int>
+ */
+ public function url_stat(string $path, int $flags): array
+ {
+ return [
+ 'dev' => 0,
+ 'ino' => 0,
+ 'mode' => 0,
+ 'nlink' => 0,
+ 'uid' => 0,
+ 'gid' => 0,
+ 'rdev' => 0,
+ 'size' => 0,
+ 'atime' => 0,
+ 'mtime' => 0,
+ 'ctime' => 0,
+ 'blksize' => 0,
+ 'blocks' => 0
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UploadedFile.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UploadedFile.php
new file mode 100644
index 0000000..b1521bc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UploadedFile.php
@@ -0,0 +1,211 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use InvalidArgumentException;
+use Psr\Http\Message\StreamInterface;
+use Psr\Http\Message\UploadedFileInterface;
+use RuntimeException;
+
+class UploadedFile implements UploadedFileInterface
+{
+ private const ERRORS = [
+ UPLOAD_ERR_OK,
+ UPLOAD_ERR_INI_SIZE,
+ UPLOAD_ERR_FORM_SIZE,
+ UPLOAD_ERR_PARTIAL,
+ UPLOAD_ERR_NO_FILE,
+ UPLOAD_ERR_NO_TMP_DIR,
+ UPLOAD_ERR_CANT_WRITE,
+ UPLOAD_ERR_EXTENSION,
+ ];
+
+ /**
+ * @var string|null
+ */
+ private $clientFilename;
+
+ /**
+ * @var string|null
+ */
+ private $clientMediaType;
+
+ /**
+ * @var int
+ */
+ private $error;
+
+ /**
+ * @var string|null
+ */
+ private $file;
+
+ /**
+ * @var bool
+ */
+ private $moved = false;
+
+ /**
+ * @var int|null
+ */
+ private $size;
+
+ /**
+ * @var StreamInterface|null
+ */
+ private $stream;
+
+ /**
+ * @param StreamInterface|string|resource $streamOrFile
+ */
+ public function __construct(
+ $streamOrFile,
+ ?int $size,
+ int $errorStatus,
+ string $clientFilename = null,
+ string $clientMediaType = null
+ ) {
+ $this->setError($errorStatus);
+ $this->size = $size;
+ $this->clientFilename = $clientFilename;
+ $this->clientMediaType = $clientMediaType;
+
+ if ($this->isOk()) {
+ $this->setStreamOrFile($streamOrFile);
+ }
+ }
+
+ /**
+ * Depending on the value set file or stream variable
+ *
+ * @param StreamInterface|string|resource $streamOrFile
+ *
+ * @throws InvalidArgumentException
+ */
+ private function setStreamOrFile($streamOrFile): void
+ {
+ if (is_string($streamOrFile)) {
+ $this->file = $streamOrFile;
+ } elseif (is_resource($streamOrFile)) {
+ $this->stream = new Stream($streamOrFile);
+ } elseif ($streamOrFile instanceof StreamInterface) {
+ $this->stream = $streamOrFile;
+ } else {
+ throw new InvalidArgumentException(
+ 'Invalid stream or file provided for UploadedFile'
+ );
+ }
+ }
+
+ /**
+ * @throws InvalidArgumentException
+ */
+ private function setError(int $error): void
+ {
+ if (false === in_array($error, UploadedFile::ERRORS, true)) {
+ throw new InvalidArgumentException(
+ 'Invalid error status for UploadedFile'
+ );
+ }
+
+ $this->error = $error;
+ }
+
+ private function isStringNotEmpty($param): bool
+ {
+ return is_string($param) && false === empty($param);
+ }
+
+ /**
+ * Return true if there is no upload error
+ */
+ private function isOk(): bool
+ {
+ return $this->error === UPLOAD_ERR_OK;
+ }
+
+ public function isMoved(): bool
+ {
+ return $this->moved;
+ }
+
+ /**
+ * @throws RuntimeException if is moved or not ok
+ */
+ private function validateActive(): void
+ {
+ if (false === $this->isOk()) {
+ throw new RuntimeException('Cannot retrieve stream due to upload error');
+ }
+
+ if ($this->isMoved()) {
+ throw new RuntimeException('Cannot retrieve stream after it has already been moved');
+ }
+ }
+
+ public function getStream(): StreamInterface
+ {
+ $this->validateActive();
+
+ if ($this->stream instanceof StreamInterface) {
+ return $this->stream;
+ }
+
+ /** @var string $file */
+ $file = $this->file;
+
+ return new LazyOpenStream($file, 'r+');
+ }
+
+ public function moveTo($targetPath): void
+ {
+ $this->validateActive();
+
+ if (false === $this->isStringNotEmpty($targetPath)) {
+ throw new InvalidArgumentException(
+ 'Invalid path provided for move operation; must be a non-empty string'
+ );
+ }
+
+ if ($this->file) {
+ $this->moved = PHP_SAPI === 'cli'
+ ? rename($this->file, $targetPath)
+ : move_uploaded_file($this->file, $targetPath);
+ } else {
+ Utils::copyToStream(
+ $this->getStream(),
+ new LazyOpenStream($targetPath, 'w')
+ );
+
+ $this->moved = true;
+ }
+
+ if (false === $this->moved) {
+ throw new RuntimeException(
+ sprintf('Uploaded file could not be moved to %s', $targetPath)
+ );
+ }
+ }
+
+ public function getSize(): ?int
+ {
+ return $this->size;
+ }
+
+ public function getError(): int
+ {
+ return $this->error;
+ }
+
+ public function getClientFilename(): ?string
+ {
+ return $this->clientFilename;
+ }
+
+ public function getClientMediaType(): ?string
+ {
+ return $this->clientMediaType;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Uri.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Uri.php
new file mode 100644
index 0000000..09e878d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Uri.php
@@ -0,0 +1,740 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use GuzzleHttp\Psr7\Exception\MalformedUriException;
+use Psr\Http\Message\UriInterface;
+
+/**
+ * PSR-7 URI implementation.
+ *
+ * @author Michael Dowling
+ * @author Tobias Schultze
+ * @author Matthew Weier O'Phinney
+ */
+class Uri implements UriInterface, \JsonSerializable
+{
+ /**
+ * Absolute http and https URIs require a host per RFC 7230 Section 2.7
+ * but in generic URIs the host can be empty. So for http(s) URIs
+ * we apply this default host when no host is given yet to form a
+ * valid URI.
+ */
+ private const HTTP_DEFAULT_HOST = 'localhost';
+
+ private const DEFAULT_PORTS = [
+ 'http' => 80,
+ 'https' => 443,
+ 'ftp' => 21,
+ 'gopher' => 70,
+ 'nntp' => 119,
+ 'news' => 119,
+ 'telnet' => 23,
+ 'tn3270' => 23,
+ 'imap' => 143,
+ 'pop' => 110,
+ 'ldap' => 389,
+ ];
+
+ /**
+ * Unreserved characters for use in a regex.
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-2.3
+ */
+ private const CHAR_UNRESERVED = 'a-zA-Z0-9_\-\.~';
+
+ /**
+ * Sub-delims for use in a regex.
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-2.2
+ */
+ private const CHAR_SUB_DELIMS = '!\$&\'\(\)\*\+,;=';
+ private const QUERY_SEPARATORS_REPLACEMENT = ['=' => '%3D', '&' => '%26'];
+
+ /** @var string Uri scheme. */
+ private $scheme = '';
+
+ /** @var string Uri user info. */
+ private $userInfo = '';
+
+ /** @var string Uri host. */
+ private $host = '';
+
+ /** @var int|null Uri port. */
+ private $port;
+
+ /** @var string Uri path. */
+ private $path = '';
+
+ /** @var string Uri query string. */
+ private $query = '';
+
+ /** @var string Uri fragment. */
+ private $fragment = '';
+
+ /** @var string|null String representation */
+ private $composedComponents;
+
+ public function __construct(string $uri = '')
+ {
+ if ($uri !== '') {
+ $parts = self::parse($uri);
+ if ($parts === false) {
+ throw new MalformedUriException("Unable to parse URI: $uri");
+ }
+ $this->applyParts($parts);
+ }
+ }
+ /**
+ * UTF-8 aware \parse_url() replacement.
+ *
+ * The internal function produces broken output for non ASCII domain names
+ * (IDN) when used with locales other than "C".
+ *
+ * On the other hand, cURL understands IDN correctly only when UTF-8 locale
+ * is configured ("C.UTF-8", "en_US.UTF-8", etc.).
+ *
+ * @see https://bugs.php.net/bug.php?id=52923
+ * @see https://www.php.net/manual/en/function.parse-url.php#114817
+ * @see https://curl.haxx.se/libcurl/c/CURLOPT_URL.html#ENCODING
+ *
+ * @return array|false
+ */
+ private static function parse(string $url)
+ {
+ // If IPv6
+ $prefix = '';
+ if (preg_match('%^(.*://\[[0-9:a-f]+\])(.*?)$%', $url, $matches)) {
+ /** @var array{0:string, 1:string, 2:string} $matches */
+ $prefix = $matches[1];
+ $url = $matches[2];
+ }
+
+ /** @var string */
+ $encodedUrl = preg_replace_callback(
+ '%[^:/@?&=#]+%usD',
+ static function ($matches) {
+ return urlencode($matches[0]);
+ },
+ $url
+ );
+
+ $result = parse_url($prefix . $encodedUrl);
+
+ if ($result === false) {
+ return false;
+ }
+
+ return array_map('urldecode', $result);
+ }
+
+ public function __toString(): string
+ {
+ if ($this->composedComponents === null) {
+ $this->composedComponents = self::composeComponents(
+ $this->scheme,
+ $this->getAuthority(),
+ $this->path,
+ $this->query,
+ $this->fragment
+ );
+ }
+
+ return $this->composedComponents;
+ }
+
+ /**
+ * Composes a URI reference string from its various components.
+ *
+ * Usually this method does not need to be called manually but instead is used indirectly via
+ * `Psr\Http\Message\UriInterface::__toString`.
+ *
+ * PSR-7 UriInterface treats an empty component the same as a missing component as
+ * getQuery(), getFragment() etc. always return a string. This explains the slight
+ * difference to RFC 3986 Section 5.3.
+ *
+ * Another adjustment is that the authority separator is added even when the authority is missing/empty
+ * for the "file" scheme. This is because PHP stream functions like `file_get_contents` only work with
+ * `file:///myfile` but not with `file:/myfile` although they are equivalent according to RFC 3986. But
+ * `file:///` is the more common syntax for the file scheme anyway (Chrome for example redirects to
+ * that format).
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-5.3
+ */
+ public static function composeComponents(?string $scheme, ?string $authority, string $path, ?string $query, ?string $fragment): string
+ {
+ $uri = '';
+
+ // weak type checks to also accept null until we can add scalar type hints
+ if ($scheme != '') {
+ $uri .= $scheme . ':';
+ }
+
+ if ($authority != '' || $scheme === 'file') {
+ $uri .= '//' . $authority;
+ }
+
+ if ($authority != '' && $path != '' && $path[0] != '/') {
+ $path = '/' . $path;
+ }
+
+ $uri .= $path;
+
+ if ($query != '') {
+ $uri .= '?' . $query;
+ }
+
+ if ($fragment != '') {
+ $uri .= '#' . $fragment;
+ }
+
+ return $uri;
+ }
+
+ /**
+ * Whether the URI has the default port of the current scheme.
+ *
+ * `Psr\Http\Message\UriInterface::getPort` may return null or the standard port. This method can be used
+ * independently of the implementation.
+ */
+ public static function isDefaultPort(UriInterface $uri): bool
+ {
+ return $uri->getPort() === null
+ || (isset(self::DEFAULT_PORTS[$uri->getScheme()]) && $uri->getPort() === self::DEFAULT_PORTS[$uri->getScheme()]);
+ }
+
+ /**
+ * Whether the URI is absolute, i.e. it has a scheme.
+ *
+ * An instance of UriInterface can either be an absolute URI or a relative reference. This method returns true
+ * if it is the former. An absolute URI has a scheme. A relative reference is used to express a URI relative
+ * to another URI, the base URI. Relative references can be divided into several forms:
+ * - network-path references, e.g. '//example.com/path'
+ * - absolute-path references, e.g. '/path'
+ * - relative-path references, e.g. 'subpath'
+ *
+ * @see Uri::isNetworkPathReference
+ * @see Uri::isAbsolutePathReference
+ * @see Uri::isRelativePathReference
+ * @link https://tools.ietf.org/html/rfc3986#section-4
+ */
+ public static function isAbsolute(UriInterface $uri): bool
+ {
+ return $uri->getScheme() !== '';
+ }
+
+ /**
+ * Whether the URI is a network-path reference.
+ *
+ * A relative reference that begins with two slash characters is termed an network-path reference.
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-4.2
+ */
+ public static function isNetworkPathReference(UriInterface $uri): bool
+ {
+ return $uri->getScheme() === '' && $uri->getAuthority() !== '';
+ }
+
+ /**
+ * Whether the URI is a absolute-path reference.
+ *
+ * A relative reference that begins with a single slash character is termed an absolute-path reference.
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-4.2
+ */
+ public static function isAbsolutePathReference(UriInterface $uri): bool
+ {
+ return $uri->getScheme() === ''
+ && $uri->getAuthority() === ''
+ && isset($uri->getPath()[0])
+ && $uri->getPath()[0] === '/';
+ }
+
+ /**
+ * Whether the URI is a relative-path reference.
+ *
+ * A relative reference that does not begin with a slash character is termed a relative-path reference.
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-4.2
+ */
+ public static function isRelativePathReference(UriInterface $uri): bool
+ {
+ return $uri->getScheme() === ''
+ && $uri->getAuthority() === ''
+ && (!isset($uri->getPath()[0]) || $uri->getPath()[0] !== '/');
+ }
+
+ /**
+ * Whether the URI is a same-document reference.
+ *
+ * A same-document reference refers to a URI that is, aside from its fragment
+ * component, identical to the base URI. When no base URI is given, only an empty
+ * URI reference (apart from its fragment) is considered a same-document reference.
+ *
+ * @param UriInterface $uri The URI to check
+ * @param UriInterface|null $base An optional base URI to compare against
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-4.4
+ */
+ public static function isSameDocumentReference(UriInterface $uri, UriInterface $base = null): bool
+ {
+ if ($base !== null) {
+ $uri = UriResolver::resolve($base, $uri);
+
+ return ($uri->getScheme() === $base->getScheme())
+ && ($uri->getAuthority() === $base->getAuthority())
+ && ($uri->getPath() === $base->getPath())
+ && ($uri->getQuery() === $base->getQuery());
+ }
+
+ return $uri->getScheme() === '' && $uri->getAuthority() === '' && $uri->getPath() === '' && $uri->getQuery() === '';
+ }
+
+ /**
+ * Creates a new URI with a specific query string value removed.
+ *
+ * Any existing query string values that exactly match the provided key are
+ * removed.
+ *
+ * @param UriInterface $uri URI to use as a base.
+ * @param string $key Query string key to remove.
+ */
+ public static function withoutQueryValue(UriInterface $uri, string $key): UriInterface
+ {
+ $result = self::getFilteredQueryString($uri, [$key]);
+
+ return $uri->withQuery(implode('&', $result));
+ }
+
+ /**
+ * Creates a new URI with a specific query string value.
+ *
+ * Any existing query string values that exactly match the provided key are
+ * removed and replaced with the given key value pair.
+ *
+ * A value of null will set the query string key without a value, e.g. "key"
+ * instead of "key=value".
+ *
+ * @param UriInterface $uri URI to use as a base.
+ * @param string $key Key to set.
+ * @param string|null $value Value to set
+ */
+ public static function withQueryValue(UriInterface $uri, string $key, ?string $value): UriInterface
+ {
+ $result = self::getFilteredQueryString($uri, [$key]);
+
+ $result[] = self::generateQueryString($key, $value);
+
+ return $uri->withQuery(implode('&', $result));
+ }
+
+ /**
+ * Creates a new URI with multiple specific query string values.
+ *
+ * It has the same behavior as withQueryValue() but for an associative array of key => value.
+ *
+ * @param UriInterface $uri URI to use as a base.
+ * @param array<string, string|null> $keyValueArray Associative array of key and values
+ */
+ public static function withQueryValues(UriInterface $uri, array $keyValueArray): UriInterface
+ {
+ $result = self::getFilteredQueryString($uri, array_keys($keyValueArray));
+
+ foreach ($keyValueArray as $key => $value) {
+ $result[] = self::generateQueryString((string) $key, $value !== null ? (string) $value : null);
+ }
+
+ return $uri->withQuery(implode('&', $result));
+ }
+
+ /**
+ * Creates a URI from a hash of `parse_url` components.
+ *
+ * @link http://php.net/manual/en/function.parse-url.php
+ *
+ * @throws MalformedUriException If the components do not form a valid URI.
+ */
+ public static function fromParts(array $parts): UriInterface
+ {
+ $uri = new self();
+ $uri->applyParts($parts);
+ $uri->validateState();
+
+ return $uri;
+ }
+
+ public function getScheme(): string
+ {
+ return $this->scheme;
+ }
+
+ public function getAuthority(): string
+ {
+ $authority = $this->host;
+ if ($this->userInfo !== '') {
+ $authority = $this->userInfo . '@' . $authority;
+ }
+
+ if ($this->port !== null) {
+ $authority .= ':' . $this->port;
+ }
+
+ return $authority;
+ }
+
+ public function getUserInfo(): string
+ {
+ return $this->userInfo;
+ }
+
+ public function getHost(): string
+ {
+ return $this->host;
+ }
+
+ public function getPort(): ?int
+ {
+ return $this->port;
+ }
+
+ public function getPath(): string
+ {
+ return $this->path;
+ }
+
+ public function getQuery(): string
+ {
+ return $this->query;
+ }
+
+ public function getFragment(): string
+ {
+ return $this->fragment;
+ }
+
+ public function withScheme($scheme): UriInterface
+ {
+ $scheme = $this->filterScheme($scheme);
+
+ if ($this->scheme === $scheme) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->scheme = $scheme;
+ $new->composedComponents = null;
+ $new->removeDefaultPort();
+ $new->validateState();
+
+ return $new;
+ }
+
+ public function withUserInfo($user, $password = null): UriInterface
+ {
+ $info = $this->filterUserInfoComponent($user);
+ if ($password !== null) {
+ $info .= ':' . $this->filterUserInfoComponent($password);
+ }
+
+ if ($this->userInfo === $info) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->userInfo = $info;
+ $new->composedComponents = null;
+ $new->validateState();
+
+ return $new;
+ }
+
+ public function withHost($host): UriInterface
+ {
+ $host = $this->filterHost($host);
+
+ if ($this->host === $host) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->host = $host;
+ $new->composedComponents = null;
+ $new->validateState();
+
+ return $new;
+ }
+
+ public function withPort($port): UriInterface
+ {
+ $port = $this->filterPort($port);
+
+ if ($this->port === $port) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->port = $port;
+ $new->composedComponents = null;
+ $new->removeDefaultPort();
+ $new->validateState();
+
+ return $new;
+ }
+
+ public function withPath($path): UriInterface
+ {
+ $path = $this->filterPath($path);
+
+ if ($this->path === $path) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->path = $path;
+ $new->composedComponents = null;
+ $new->validateState();
+
+ return $new;
+ }
+
+ public function withQuery($query): UriInterface
+ {
+ $query = $this->filterQueryAndFragment($query);
+
+ if ($this->query === $query) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->query = $query;
+ $new->composedComponents = null;
+
+ return $new;
+ }
+
+ public function withFragment($fragment): UriInterface
+ {
+ $fragment = $this->filterQueryAndFragment($fragment);
+
+ if ($this->fragment === $fragment) {
+ return $this;
+ }
+
+ $new = clone $this;
+ $new->fragment = $fragment;
+ $new->composedComponents = null;
+
+ return $new;
+ }
+
+ public function jsonSerialize(): string
+ {
+ return $this->__toString();
+ }
+
+ /**
+ * Apply parse_url parts to a URI.
+ *
+ * @param array $parts Array of parse_url parts to apply.
+ */
+ private function applyParts(array $parts): void
+ {
+ $this->scheme = isset($parts['scheme'])
+ ? $this->filterScheme($parts['scheme'])
+ : '';
+ $this->userInfo = isset($parts['user'])
+ ? $this->filterUserInfoComponent($parts['user'])
+ : '';
+ $this->host = isset($parts['host'])
+ ? $this->filterHost($parts['host'])
+ : '';
+ $this->port = isset($parts['port'])
+ ? $this->filterPort($parts['port'])
+ : null;
+ $this->path = isset($parts['path'])
+ ? $this->filterPath($parts['path'])
+ : '';
+ $this->query = isset($parts['query'])
+ ? $this->filterQueryAndFragment($parts['query'])
+ : '';
+ $this->fragment = isset($parts['fragment'])
+ ? $this->filterQueryAndFragment($parts['fragment'])
+ : '';
+ if (isset($parts['pass'])) {
+ $this->userInfo .= ':' . $this->filterUserInfoComponent($parts['pass']);
+ }
+
+ $this->removeDefaultPort();
+ }
+
+ /**
+ * @param mixed $scheme
+ *
+ * @throws \InvalidArgumentException If the scheme is invalid.
+ */
+ private function filterScheme($scheme): string
+ {
+ if (!is_string($scheme)) {
+ throw new \InvalidArgumentException('Scheme must be a string');
+ }
+
+ return \strtr($scheme, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz');
+ }
+
+ /**
+ * @param mixed $component
+ *
+ * @throws \InvalidArgumentException If the user info is invalid.
+ */
+ private function filterUserInfoComponent($component): string
+ {
+ if (!is_string($component)) {
+ throw new \InvalidArgumentException('User info must be a string');
+ }
+
+ return preg_replace_callback(
+ '/(?:[^%' . self::CHAR_UNRESERVED . self::CHAR_SUB_DELIMS . ']+|%(?![A-Fa-f0-9]{2}))/',
+ [$this, 'rawurlencodeMatchZero'],
+ $component
+ );
+ }
+
+ /**
+ * @param mixed $host
+ *
+ * @throws \InvalidArgumentException If the host is invalid.
+ */
+ private function filterHost($host): string
+ {
+ if (!is_string($host)) {
+ throw new \InvalidArgumentException('Host must be a string');
+ }
+
+ return \strtr($host, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz');
+ }
+
+ /**
+ * @param mixed $port
+ *
+ * @throws \InvalidArgumentException If the port is invalid.
+ */
+ private function filterPort($port): ?int
+ {
+ if ($port === null) {
+ return null;
+ }
+
+ $port = (int) $port;
+ if (0 > $port || 0xffff < $port) {
+ throw new \InvalidArgumentException(
+ sprintf('Invalid port: %d. Must be between 0 and 65535', $port)
+ );
+ }
+
+ return $port;
+ }
+
+ /**
+ * @param string[] $keys
+ *
+ * @return string[]
+ */
+ private static function getFilteredQueryString(UriInterface $uri, array $keys): array
+ {
+ $current = $uri->getQuery();
+
+ if ($current === '') {
+ return [];
+ }
+
+ $decodedKeys = array_map('rawurldecode', $keys);
+
+ return array_filter(explode('&', $current), function ($part) use ($decodedKeys) {
+ return !in_array(rawurldecode(explode('=', $part)[0]), $decodedKeys, true);
+ });
+ }
+
+ private static function generateQueryString(string $key, ?string $value): string
+ {
+ // Query string separators ("=", "&") within the key or value need to be encoded
+ // (while preventing double-encoding) before setting the query string. All other
+ // chars that need percent-encoding will be encoded by withQuery().
+ $queryString = strtr($key, self::QUERY_SEPARATORS_REPLACEMENT);
+
+ if ($value !== null) {
+ $queryString .= '=' . strtr($value, self::QUERY_SEPARATORS_REPLACEMENT);
+ }
+
+ return $queryString;
+ }
+
+ private function removeDefaultPort(): void
+ {
+ if ($this->port !== null && self::isDefaultPort($this)) {
+ $this->port = null;
+ }
+ }
+
+ /**
+ * Filters the path of a URI
+ *
+ * @param mixed $path
+ *
+ * @throws \InvalidArgumentException If the path is invalid.
+ */
+ private function filterPath($path): string
+ {
+ if (!is_string($path)) {
+ throw new \InvalidArgumentException('Path must be a string');
+ }
+
+ return preg_replace_callback(
+ '/(?:[^' . self::CHAR_UNRESERVED . self::CHAR_SUB_DELIMS . '%:@\/]++|%(?![A-Fa-f0-9]{2}))/',
+ [$this, 'rawurlencodeMatchZero'],
+ $path
+ );
+ }
+
+ /**
+ * Filters the query string or fragment of a URI.
+ *
+ * @param mixed $str
+ *
+ * @throws \InvalidArgumentException If the query or fragment is invalid.
+ */
+ private function filterQueryAndFragment($str): string
+ {
+ if (!is_string($str)) {
+ throw new \InvalidArgumentException('Query and fragment must be a string');
+ }
+
+ return preg_replace_callback(
+ '/(?:[^' . self::CHAR_UNRESERVED . self::CHAR_SUB_DELIMS . '%:@\/\?]++|%(?![A-Fa-f0-9]{2}))/',
+ [$this, 'rawurlencodeMatchZero'],
+ $str
+ );
+ }
+
+ private function rawurlencodeMatchZero(array $match): string
+ {
+ return rawurlencode($match[0]);
+ }
+
+ private function validateState(): void
+ {
+ if ($this->host === '' && ($this->scheme === 'http' || $this->scheme === 'https')) {
+ $this->host = self::HTTP_DEFAULT_HOST;
+ }
+
+ if ($this->getAuthority() === '') {
+ if (0 === strpos($this->path, '//')) {
+ throw new MalformedUriException('The path of a URI without an authority must not start with two slashes "//"');
+ }
+ if ($this->scheme === '' && false !== strpos(explode('/', $this->path, 2)[0], ':')) {
+ throw new MalformedUriException('A relative URI must not have a path beginning with a segment containing a colon');
+ }
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriComparator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriComparator.php
new file mode 100644
index 0000000..70c582a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriComparator.php
@@ -0,0 +1,52 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Provides methods to determine if a modified URL should be considered cross-origin.
+ *
+ * @author Graham Campbell
+ */
+final class UriComparator
+{
+ /**
+ * Determines if a modified URL should be considered cross-origin with
+ * respect to an original URL.
+ */
+ public static function isCrossOrigin(UriInterface $original, UriInterface $modified): bool
+ {
+ if (\strcasecmp($original->getHost(), $modified->getHost()) !== 0) {
+ return true;
+ }
+
+ if ($original->getScheme() !== $modified->getScheme()) {
+ return true;
+ }
+
+ if (self::computePort($original) !== self::computePort($modified)) {
+ return true;
+ }
+
+ return false;
+ }
+
+ private static function computePort(UriInterface $uri): int
+ {
+ $port = $uri->getPort();
+
+ if (null !== $port) {
+ return $port;
+ }
+
+ return 'https' === $uri->getScheme() ? 443 : 80;
+ }
+
+ private function __construct()
+ {
+ // cannot be instantiated
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriNormalizer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriNormalizer.php
new file mode 100644
index 0000000..e12971e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriNormalizer.php
@@ -0,0 +1,220 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Provides methods to normalize and compare URIs.
+ *
+ * @author Tobias Schultze
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-6
+ */
+final class UriNormalizer
+{
+ /**
+ * Default normalizations which only include the ones that preserve semantics.
+ */
+ public const PRESERVING_NORMALIZATIONS =
+ self::CAPITALIZE_PERCENT_ENCODING |
+ self::DECODE_UNRESERVED_CHARACTERS |
+ self::CONVERT_EMPTY_PATH |
+ self::REMOVE_DEFAULT_HOST |
+ self::REMOVE_DEFAULT_PORT |
+ self::REMOVE_DOT_SEGMENTS;
+
+ /**
+ * All letters within a percent-encoding triplet (e.g., "%3A") are case-insensitive, and should be capitalized.
+ *
+ * Example: http://example.org/a%c2%b1b → http://example.org/a%C2%B1b
+ */
+ public const CAPITALIZE_PERCENT_ENCODING = 1;
+
+ /**
+ * Decodes percent-encoded octets of unreserved characters.
+ *
+ * For consistency, percent-encoded octets in the ranges of ALPHA (%41–%5A and %61–%7A), DIGIT (%30–%39),
+ * hyphen (%2D), period (%2E), underscore (%5F), or tilde (%7E) should not be created by URI producers and,
+ * when found in a URI, should be decoded to their corresponding unreserved characters by URI normalizers.
+ *
+ * Example: http://example.org/%7Eusern%61me/ → http://example.org/~username/
+ */
+ public const DECODE_UNRESERVED_CHARACTERS = 2;
+
+ /**
+ * Converts the empty path to "/" for http and https URIs.
+ *
+ * Example: http://example.org → http://example.org/
+ */
+ public const CONVERT_EMPTY_PATH = 4;
+
+ /**
+ * Removes the default host of the given URI scheme from the URI.
+ *
+ * Only the "file" scheme defines the default host "localhost".
+ * All of `file:/myfile`, `file:///myfile`, and `file://localhost/myfile`
+ * are equivalent according to RFC 3986. The first format is not accepted
+ * by PHPs stream functions and thus already normalized implicitly to the
+ * second format in the Uri class. See `GuzzleHttp\Psr7\Uri::composeComponents`.
+ *
+ * Example: file://localhost/myfile → file:///myfile
+ */
+ public const REMOVE_DEFAULT_HOST = 8;
+
+ /**
+ * Removes the default port of the given URI scheme from the URI.
+ *
+ * Example: http://example.org:80/ → http://example.org/
+ */
+ public const REMOVE_DEFAULT_PORT = 16;
+
+ /**
+ * Removes unnecessary dot-segments.
+ *
+ * Dot-segments in relative-path references are not removed as it would
+ * change the semantics of the URI reference.
+ *
+ * Example: http://example.org/../a/b/../c/./d.html → http://example.org/a/c/d.html
+ */
+ public const REMOVE_DOT_SEGMENTS = 32;
+
+ /**
+ * Paths which include two or more adjacent slashes are converted to one.
+ *
+ * Webservers usually ignore duplicate slashes and treat those URIs equivalent.
+ * But in theory those URIs do not need to be equivalent. So this normalization
+ * may change the semantics. Encoded slashes (%2F) are not removed.
+ *
+ * Example: http://example.org//foo///bar.html → http://example.org/foo/bar.html
+ */
+ public const REMOVE_DUPLICATE_SLASHES = 64;
+
+ /**
+ * Sort query parameters with their values in alphabetical order.
+ *
+ * However, the order of parameters in a URI may be significant (this is not defined by the standard).
+ * So this normalization is not safe and may change the semantics of the URI.
+ *
+ * Example: ?lang=en&article=fred → ?article=fred&lang=en
+ *
+ * Note: The sorting is neither locale nor Unicode aware (the URI query does not get decoded at all) as the
+ * purpose is to be able to compare URIs in a reproducible way, not to have the params sorted perfectly.
+ */
+ public const SORT_QUERY_PARAMETERS = 128;
+
+ /**
+ * Returns a normalized URI.
+ *
+ * The scheme and host component are already normalized to lowercase per PSR-7 UriInterface.
+ * This methods adds additional normalizations that can be configured with the $flags parameter.
+ *
+ * PSR-7 UriInterface cannot distinguish between an empty component and a missing component as
+ * getQuery(), getFragment() etc. always return a string. This means the URIs "/?#" and "/" are
+ * treated equivalent which is not necessarily true according to RFC 3986. But that difference
+ * is highly uncommon in reality. So this potential normalization is implied in PSR-7 as well.
+ *
+ * @param UriInterface $uri The URI to normalize
+ * @param int $flags A bitmask of normalizations to apply, see constants
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-6.2
+ */
+ public static function normalize(UriInterface $uri, int $flags = self::PRESERVING_NORMALIZATIONS): UriInterface
+ {
+ if ($flags & self::CAPITALIZE_PERCENT_ENCODING) {
+ $uri = self::capitalizePercentEncoding($uri);
+ }
+
+ if ($flags & self::DECODE_UNRESERVED_CHARACTERS) {
+ $uri = self::decodeUnreservedCharacters($uri);
+ }
+
+ if ($flags & self::CONVERT_EMPTY_PATH && $uri->getPath() === '' &&
+ ($uri->getScheme() === 'http' || $uri->getScheme() === 'https')
+ ) {
+ $uri = $uri->withPath('/');
+ }
+
+ if ($flags & self::REMOVE_DEFAULT_HOST && $uri->getScheme() === 'file' && $uri->getHost() === 'localhost') {
+ $uri = $uri->withHost('');
+ }
+
+ if ($flags & self::REMOVE_DEFAULT_PORT && $uri->getPort() !== null && Uri::isDefaultPort($uri)) {
+ $uri = $uri->withPort(null);
+ }
+
+ if ($flags & self::REMOVE_DOT_SEGMENTS && !Uri::isRelativePathReference($uri)) {
+ $uri = $uri->withPath(UriResolver::removeDotSegments($uri->getPath()));
+ }
+
+ if ($flags & self::REMOVE_DUPLICATE_SLASHES) {
+ $uri = $uri->withPath(preg_replace('#//++#', '/', $uri->getPath()));
+ }
+
+ if ($flags & self::SORT_QUERY_PARAMETERS && $uri->getQuery() !== '') {
+ $queryKeyValues = explode('&', $uri->getQuery());
+ sort($queryKeyValues);
+ $uri = $uri->withQuery(implode('&', $queryKeyValues));
+ }
+
+ return $uri;
+ }
+
+ /**
+ * Whether two URIs can be considered equivalent.
+ *
+ * Both URIs are normalized automatically before comparison with the given $normalizations bitmask. The method also
+ * accepts relative URI references and returns true when they are equivalent. This of course assumes they will be
+ * resolved against the same base URI. If this is not the case, determination of equivalence or difference of
+ * relative references does not mean anything.
+ *
+ * @param UriInterface $uri1 An URI to compare
+ * @param UriInterface $uri2 An URI to compare
+ * @param int $normalizations A bitmask of normalizations to apply, see constants
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-6.1
+ */
+ public static function isEquivalent(UriInterface $uri1, UriInterface $uri2, int $normalizations = self::PRESERVING_NORMALIZATIONS): bool
+ {
+ return (string) self::normalize($uri1, $normalizations) === (string) self::normalize($uri2, $normalizations);
+ }
+
+ private static function capitalizePercentEncoding(UriInterface $uri): UriInterface
+ {
+ $regex = '/(?:%[A-Fa-f0-9]{2})++/';
+
+ $callback = function (array $match) {
+ return strtoupper($match[0]);
+ };
+
+ return
+ $uri->withPath(
+ preg_replace_callback($regex, $callback, $uri->getPath())
+ )->withQuery(
+ preg_replace_callback($regex, $callback, $uri->getQuery())
+ );
+ }
+
+ private static function decodeUnreservedCharacters(UriInterface $uri): UriInterface
+ {
+ $regex = '/%(?:2D|2E|5F|7E|3[0-9]|[46][1-9A-F]|[57][0-9A])/i';
+
+ $callback = function (array $match) {
+ return rawurldecode($match[0]);
+ };
+
+ return
+ $uri->withPath(
+ preg_replace_callback($regex, $callback, $uri->getPath())
+ )->withQuery(
+ preg_replace_callback($regex, $callback, $uri->getQuery())
+ );
+ }
+
+ private function __construct()
+ {
+ // cannot be instantiated
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriResolver.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriResolver.php
new file mode 100644
index 0000000..426e5c9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/UriResolver.php
@@ -0,0 +1,211 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\UriInterface;
+
+/**
+ * Resolves a URI reference in the context of a base URI and the opposite way.
+ *
+ * @author Tobias Schultze
+ *
+ * @link https://tools.ietf.org/html/rfc3986#section-5
+ */
+final class UriResolver
+{
+ /**
+ * Removes dot segments from a path and returns the new path.
+ *
+ * @link http://tools.ietf.org/html/rfc3986#section-5.2.4
+ */
+ public static function removeDotSegments(string $path): string
+ {
+ if ($path === '' || $path === '/') {
+ return $path;
+ }
+
+ $results = [];
+ $segments = explode('/', $path);
+ foreach ($segments as $segment) {
+ if ($segment === '..') {
+ array_pop($results);
+ } elseif ($segment !== '.') {
+ $results[] = $segment;
+ }
+ }
+
+ $newPath = implode('/', $results);
+
+ if ($path[0] === '/' && (!isset($newPath[0]) || $newPath[0] !== '/')) {
+ // Re-add the leading slash if necessary for cases like "/.."
+ $newPath = '/' . $newPath;
+ } elseif ($newPath !== '' && ($segment === '.' || $segment === '..')) {
+ // Add the trailing slash if necessary
+ // If newPath is not empty, then $segment must be set and is the last segment from the foreach
+ $newPath .= '/';
+ }
+
+ return $newPath;
+ }
+
+ /**
+ * Converts the relative URI into a new URI that is resolved against the base URI.
+ *
+ * @link http://tools.ietf.org/html/rfc3986#section-5.2
+ */
+ public static function resolve(UriInterface $base, UriInterface $rel): UriInterface
+ {
+ if ((string) $rel === '') {
+ // we can simply return the same base URI instance for this same-document reference
+ return $base;
+ }
+
+ if ($rel->getScheme() != '') {
+ return $rel->withPath(self::removeDotSegments($rel->getPath()));
+ }
+
+ if ($rel->getAuthority() != '') {
+ $targetAuthority = $rel->getAuthority();
+ $targetPath = self::removeDotSegments($rel->getPath());
+ $targetQuery = $rel->getQuery();
+ } else {
+ $targetAuthority = $base->getAuthority();
+ if ($rel->getPath() === '') {
+ $targetPath = $base->getPath();
+ $targetQuery = $rel->getQuery() != '' ? $rel->getQuery() : $base->getQuery();
+ } else {
+ if ($rel->getPath()[0] === '/') {
+ $targetPath = $rel->getPath();
+ } else {
+ if ($targetAuthority != '' && $base->getPath() === '') {
+ $targetPath = '/' . $rel->getPath();
+ } else {
+ $lastSlashPos = strrpos($base->getPath(), '/');
+ if ($lastSlashPos === false) {
+ $targetPath = $rel->getPath();
+ } else {
+ $targetPath = substr($base->getPath(), 0, $lastSlashPos + 1) . $rel->getPath();
+ }
+ }
+ }
+ $targetPath = self::removeDotSegments($targetPath);
+ $targetQuery = $rel->getQuery();
+ }
+ }
+
+ return new Uri(Uri::composeComponents(
+ $base->getScheme(),
+ $targetAuthority,
+ $targetPath,
+ $targetQuery,
+ $rel->getFragment()
+ ));
+ }
+
+ /**
+ * Returns the target URI as a relative reference from the base URI.
+ *
+ * This method is the counterpart to resolve():
+ *
+ * (string) $target === (string) UriResolver::resolve($base, UriResolver::relativize($base, $target))
+ *
+ * One use-case is to use the current request URI as base URI and then generate relative links in your documents
+ * to reduce the document size or offer self-contained downloadable document archives.
+ *
+ * $base = new Uri('http://example.com/a/b/');
+ * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'.
+ * echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'.
+ * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'.
+ * echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'.
+ *
+ * This method also accepts a target that is already relative and will try to relativize it further. Only a
+ * relative-path reference will be returned as-is.
+ *
+ * echo UriResolver::relativize($base, new Uri('/a/b/c')); // prints 'c' as well
+ */
+ public static function relativize(UriInterface $base, UriInterface $target): UriInterface
+ {
+ if ($target->getScheme() !== '' &&
+ ($base->getScheme() !== $target->getScheme() || $target->getAuthority() === '' && $base->getAuthority() !== '')
+ ) {
+ return $target;
+ }
+
+ if (Uri::isRelativePathReference($target)) {
+ // As the target is already highly relative we return it as-is. It would be possible to resolve
+ // the target with `$target = self::resolve($base, $target);` and then try make it more relative
+ // by removing a duplicate query. But let's not do that automatically.
+ return $target;
+ }
+
+ if ($target->getAuthority() !== '' && $base->getAuthority() !== $target->getAuthority()) {
+ return $target->withScheme('');
+ }
+
+ // We must remove the path before removing the authority because if the path starts with two slashes, the URI
+ // would turn invalid. And we also cannot set a relative path before removing the authority, as that is also
+ // invalid.
+ $emptyPathUri = $target->withScheme('')->withPath('')->withUserInfo('')->withPort(null)->withHost('');
+
+ if ($base->getPath() !== $target->getPath()) {
+ return $emptyPathUri->withPath(self::getRelativePath($base, $target));
+ }
+
+ if ($base->getQuery() === $target->getQuery()) {
+ // Only the target fragment is left. And it must be returned even if base and target fragment are the same.
+ return $emptyPathUri->withQuery('');
+ }
+
+ // If the base URI has a query but the target has none, we cannot return an empty path reference as it would
+ // inherit the base query component when resolving.
+ if ($target->getQuery() === '') {
+ $segments = explode('/', $target->getPath());
+ /** @var string $lastSegment */
+ $lastSegment = end($segments);
+
+ return $emptyPathUri->withPath($lastSegment === '' ? './' : $lastSegment);
+ }
+
+ return $emptyPathUri;
+ }
+
+ private static function getRelativePath(UriInterface $base, UriInterface $target): string
+ {
+ $sourceSegments = explode('/', $base->getPath());
+ $targetSegments = explode('/', $target->getPath());
+ array_pop($sourceSegments);
+ $targetLastSegment = array_pop($targetSegments);
+ foreach ($sourceSegments as $i => $segment) {
+ if (isset($targetSegments[$i]) && $segment === $targetSegments[$i]) {
+ unset($sourceSegments[$i], $targetSegments[$i]);
+ } else {
+ break;
+ }
+ }
+ $targetSegments[] = $targetLastSegment;
+ $relativePath = str_repeat('../', count($sourceSegments)) . implode('/', $targetSegments);
+
+ // A reference to am empty last segment or an empty first sub-segment must be prefixed with "./".
+ // This also applies to a segment with a colon character (e.g., "file:colon") that cannot be used
+ // as the first segment of a relative-path reference, as it would be mistaken for a scheme name.
+ if ('' === $relativePath || false !== strpos(explode('/', $relativePath, 2)[0], ':')) {
+ $relativePath = "./$relativePath";
+ } elseif ('/' === $relativePath[0]) {
+ if ($base->getAuthority() != '' && $base->getPath() === '') {
+ // In this case an extra slash is added by resolve() automatically. So we must not add one here.
+ $relativePath = ".$relativePath";
+ } else {
+ $relativePath = "./$relativePath";
+ }
+ }
+
+ return $relativePath;
+ }
+
+ private function __construct()
+ {
+ // cannot be instantiated
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Utils.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Utils.php
new file mode 100644
index 0000000..3a4cf39
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/guzzlehttp/psr7/src/Utils.php
@@ -0,0 +1,459 @@
+<?php
+
+declare(strict_types=1);
+
+namespace GuzzleHttp\Psr7;
+
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ServerRequestInterface;
+use Psr\Http\Message\StreamInterface;
+use Psr\Http\Message\UriInterface;
+
+final class Utils
+{
+ /**
+ * Remove the items given by the keys, case insensitively from the data.
+ *
+ * @param string[] $keys
+ */
+ public static function caselessRemove(array $keys, array $data): array
+ {
+ $result = [];
+
+ foreach ($keys as &$key) {
+ $key = strtolower($key);
+ }
+
+ foreach ($data as $k => $v) {
+ if (!is_string($k) || !in_array(strtolower($k), $keys)) {
+ $result[$k] = $v;
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Copy the contents of a stream into another stream until the given number
+ * of bytes have been read.
+ *
+ * @param StreamInterface $source Stream to read from
+ * @param StreamInterface $dest Stream to write to
+ * @param int $maxLen Maximum number of bytes to read. Pass -1
+ * to read the entire stream.
+ *
+ * @throws \RuntimeException on error.
+ */
+ public static function copyToStream(StreamInterface $source, StreamInterface $dest, int $maxLen = -1): void
+ {
+ $bufferSize = 8192;
+
+ if ($maxLen === -1) {
+ while (!$source->eof()) {
+ if (!$dest->write($source->read($bufferSize))) {
+ break;
+ }
+ }
+ } else {
+ $remaining = $maxLen;
+ while ($remaining > 0 && !$source->eof()) {
+ $buf = $source->read(min($bufferSize, $remaining));
+ $len = strlen($buf);
+ if (!$len) {
+ break;
+ }
+ $remaining -= $len;
+ $dest->write($buf);
+ }
+ }
+ }
+
+ /**
+ * Copy the contents of a stream into a string until the given number of
+ * bytes have been read.
+ *
+ * @param StreamInterface $stream Stream to read
+ * @param int $maxLen Maximum number of bytes to read. Pass -1
+ * to read the entire stream.
+ *
+ * @throws \RuntimeException on error.
+ */
+ public static function copyToString(StreamInterface $stream, int $maxLen = -1): string
+ {
+ $buffer = '';
+
+ if ($maxLen === -1) {
+ while (!$stream->eof()) {
+ $buf = $stream->read(1048576);
+ if ($buf === '') {
+ break;
+ }
+ $buffer .= $buf;
+ }
+ return $buffer;
+ }
+
+ $len = 0;
+ while (!$stream->eof() && $len < $maxLen) {
+ $buf = $stream->read($maxLen - $len);
+ if ($buf === '') {
+ break;
+ }
+ $buffer .= $buf;
+ $len = strlen($buffer);
+ }
+
+ return $buffer;
+ }
+
+ /**
+ * Calculate a hash of a stream.
+ *
+ * This method reads the entire stream to calculate a rolling hash, based
+ * on PHP's `hash_init` functions.
+ *
+ * @param StreamInterface $stream Stream to calculate the hash for
+ * @param string $algo Hash algorithm (e.g. md5, crc32, etc)
+ * @param bool $rawOutput Whether or not to use raw output
+ *
+ * @throws \RuntimeException on error.
+ */
+ public static function hash(StreamInterface $stream, string $algo, bool $rawOutput = false): string
+ {
+ $pos = $stream->tell();
+
+ if ($pos > 0) {
+ $stream->rewind();
+ }
+
+ $ctx = hash_init($algo);
+ while (!$stream->eof()) {
+ hash_update($ctx, $stream->read(1048576));
+ }
+
+ $out = hash_final($ctx, $rawOutput);
+ $stream->seek($pos);
+
+ return $out;
+ }
+
+ /**
+ * Clone and modify a request with the given changes.
+ *
+ * This method is useful for reducing the number of clones needed to mutate
+ * a message.
+ *
+ * The changes can be one of:
+ * - method: (string) Changes the HTTP method.
+ * - set_headers: (array) Sets the given headers.
+ * - remove_headers: (array) Remove the given headers.
+ * - body: (mixed) Sets the given body.
+ * - uri: (UriInterface) Set the URI.
+ * - query: (string) Set the query string value of the URI.
+ * - version: (string) Set the protocol version.
+ *
+ * @param RequestInterface $request Request to clone and modify.
+ * @param array $changes Changes to apply.
+ */
+ public static function modifyRequest(RequestInterface $request, array $changes): RequestInterface
+ {
+ if (!$changes) {
+ return $request;
+ }
+
+ $headers = $request->getHeaders();
+
+ if (!isset($changes['uri'])) {
+ $uri = $request->getUri();
+ } else {
+ // Remove the host header if one is on the URI
+ if ($host = $changes['uri']->getHost()) {
+ $changes['set_headers']['Host'] = $host;
+
+ if ($port = $changes['uri']->getPort()) {
+ $standardPorts = ['http' => 80, 'https' => 443];
+ $scheme = $changes['uri']->getScheme();
+ if (isset($standardPorts[$scheme]) && $port != $standardPorts[$scheme]) {
+ $changes['set_headers']['Host'] .= ':' . $port;
+ }
+ }
+ }
+ $uri = $changes['uri'];
+ }
+
+ if (!empty($changes['remove_headers'])) {
+ $headers = self::caselessRemove($changes['remove_headers'], $headers);
+ }
+
+ if (!empty($changes['set_headers'])) {
+ $headers = self::caselessRemove(array_keys($changes['set_headers']), $headers);
+ $headers = $changes['set_headers'] + $headers;
+ }
+
+ if (isset($changes['query'])) {
+ $uri = $uri->withQuery($changes['query']);
+ }
+
+ if ($request instanceof ServerRequestInterface) {
+ $new = (new ServerRequest(
+ $changes['method'] ?? $request->getMethod(),
+ $uri,
+ $headers,
+ $changes['body'] ?? $request->getBody(),
+ $changes['version'] ?? $request->getProtocolVersion(),
+ $request->getServerParams()
+ ))
+ ->withParsedBody($request->getParsedBody())
+ ->withQueryParams($request->getQueryParams())
+ ->withCookieParams($request->getCookieParams())
+ ->withUploadedFiles($request->getUploadedFiles());
+
+ foreach ($request->getAttributes() as $key => $value) {
+ $new = $new->withAttribute($key, $value);
+ }
+
+ return $new;
+ }
+
+ return new Request(
+ $changes['method'] ?? $request->getMethod(),
+ $uri,
+ $headers,
+ $changes['body'] ?? $request->getBody(),
+ $changes['version'] ?? $request->getProtocolVersion()
+ );
+ }
+
+ /**
+ * Read a line from the stream up to the maximum allowed buffer length.
+ *
+ * @param StreamInterface $stream Stream to read from
+ * @param int|null $maxLength Maximum buffer length
+ */
+ public static function readLine(StreamInterface $stream, ?int $maxLength = null): string
+ {
+ $buffer = '';
+ $size = 0;
+
+ while (!$stream->eof()) {
+ if ('' === ($byte = $stream->read(1))) {
+ return $buffer;
+ }
+ $buffer .= $byte;
+ // Break when a new line is found or the max length - 1 is reached
+ if ($byte === "\n" || ++$size === $maxLength - 1) {
+ break;
+ }
+ }
+
+ return $buffer;
+ }
+
+ /**
+ * Create a new stream based on the input type.
+ *
+ * Options is an associative array that can contain the following keys:
+ * - metadata: Array of custom metadata.
+ * - size: Size of the stream.
+ *
+ * This method accepts the following `$resource` types:
+ * - `Psr\Http\Message\StreamInterface`: Returns the value as-is.
+ * - `string`: Creates a stream object that uses the given string as the contents.
+ * - `resource`: Creates a stream object that wraps the given PHP stream resource.
+ * - `Iterator`: If the provided value implements `Iterator`, then a read-only
+ * stream object will be created that wraps the given iterable. Each time the
+ * stream is read from, data from the iterator will fill a buffer and will be
+ * continuously called until the buffer is equal to the requested read size.
+ * Subsequent read calls will first read from the buffer and then call `next`
+ * on the underlying iterator until it is exhausted.
+ * - `object` with `__toString()`: If the object has the `__toString()` method,
+ * the object will be cast to a string and then a stream will be returned that
+ * uses the string value.
+ * - `NULL`: When `null` is passed, an empty stream object is returned.
+ * - `callable` When a callable is passed, a read-only stream object will be
+ * created that invokes the given callable. The callable is invoked with the
+ * number of suggested bytes to read. The callable can return any number of
+ * bytes, but MUST return `false` when there is no more data to return. The
+ * stream object that wraps the callable will invoke the callable until the
+ * number of requested bytes are available. Any additional bytes will be
+ * buffered and used in subsequent reads.
+ *
+ * @param resource|string|int|float|bool|StreamInterface|callable|\Iterator|null $resource Entity body data
+ * @param array{size?: int, metadata?: array} $options Additional options
+ *
+ * @throws \InvalidArgumentException if the $resource arg is not valid.
+ */
+ public static function streamFor($resource = '', array $options = []): StreamInterface
+ {
+ if (is_scalar($resource)) {
+ $stream = self::tryFopen('php://temp', 'r+');
+ if ($resource !== '') {
+ fwrite($stream, (string) $resource);
+ fseek($stream, 0);
+ }
+ return new Stream($stream, $options);
+ }
+
+ switch (gettype($resource)) {
+ case 'resource':
+ /*
+ * The 'php://input' is a special stream with quirks and inconsistencies.
+ * We avoid using that stream by reading it into php://temp
+ */
+
+ /** @var resource $resource */
+ if ((\stream_get_meta_data($resource)['uri'] ?? '') === 'php://input') {
+ $stream = self::tryFopen('php://temp', 'w+');
+ stream_copy_to_stream($resource, $stream);
+ fseek($stream, 0);
+ $resource = $stream;
+ }
+ return new Stream($resource, $options);
+ case 'object':
+ /** @var object $resource */
+ if ($resource instanceof StreamInterface) {
+ return $resource;
+ } elseif ($resource instanceof \Iterator) {
+ return new PumpStream(function () use ($resource) {
+ if (!$resource->valid()) {
+ return false;
+ }
+ $result = $resource->current();
+ $resource->next();
+ return $result;
+ }, $options);
+ } elseif (method_exists($resource, '__toString')) {
+ return self::streamFor((string) $resource, $options);
+ }
+ break;
+ case 'NULL':
+ return new Stream(self::tryFopen('php://temp', 'r+'), $options);
+ }
+
+ if (is_callable($resource)) {
+ return new PumpStream($resource, $options);
+ }
+
+ throw new \InvalidArgumentException('Invalid resource type: ' . gettype($resource));
+ }
+
+ /**
+ * Safely opens a PHP stream resource using a filename.
+ *
+ * When fopen fails, PHP normally raises a warning. This function adds an
+ * error handler that checks for errors and throws an exception instead.
+ *
+ * @param string $filename File to open
+ * @param string $mode Mode used to open the file
+ *
+ * @return resource
+ *
+ * @throws \RuntimeException if the file cannot be opened
+ */
+ public static function tryFopen(string $filename, string $mode)
+ {
+ $ex = null;
+ set_error_handler(static function (int $errno, string $errstr) use ($filename, $mode, &$ex): bool {
+ $ex = new \RuntimeException(sprintf(
+ 'Unable to open "%s" using mode "%s": %s',
+ $filename,
+ $mode,
+ $errstr
+ ));
+
+ return true;
+ });
+
+ try {
+ /** @var resource $handle */
+ $handle = fopen($filename, $mode);
+ } catch (\Throwable $e) {
+ $ex = new \RuntimeException(sprintf(
+ 'Unable to open "%s" using mode "%s": %s',
+ $filename,
+ $mode,
+ $e->getMessage()
+ ), 0, $e);
+ }
+
+ restore_error_handler();
+
+ if ($ex) {
+ /** @var $ex \RuntimeException */
+ throw $ex;
+ }
+
+ return $handle;
+ }
+
+ /**
+ * Safely gets the contents of a given stream.
+ *
+ * When stream_get_contents fails, PHP normally raises a warning. This
+ * function adds an error handler that checks for errors and throws an
+ * exception instead.
+ *
+ * @param resource $stream
+ *
+ * @throws \RuntimeException if the stream cannot be read
+ */
+ public static function tryGetContents($stream): string
+ {
+ $ex = null;
+ set_error_handler(static function (int $errno, string $errstr) use (&$ex): bool {
+ $ex = new \RuntimeException(sprintf(
+ 'Unable to read stream contents: %s',
+ $errstr
+ ));
+
+ return true;
+ });
+
+ try {
+ /** @var string|false $contents */
+ $contents = stream_get_contents($stream);
+
+ if ($contents === false) {
+ $ex = new \RuntimeException('Unable to read stream contents');
+ }
+ } catch (\Throwable $e) {
+ $ex = new \RuntimeException(sprintf(
+ 'Unable to read stream contents: %s',
+ $e->getMessage()
+ ), 0, $e);
+ }
+
+ restore_error_handler();
+
+ if ($ex) {
+ /** @var $ex \RuntimeException */
+ throw $ex;
+ }
+
+ return $contents;
+ }
+
+ /**
+ * Returns a UriInterface for the given value.
+ *
+ * This function accepts a string or UriInterface and returns a
+ * UriInterface for the given value. If the value is already a
+ * UriInterface, it is returned as-is.
+ *
+ * @param string|UriInterface $uri
+ *
+ * @throws \InvalidArgumentException
+ */
+ public static function uriFor($uri): UriInterface
+ {
+ if ($uri instanceof UriInterface) {
+ return $uri;
+ }
+
+ if (is_string($uri)) {
+ return new Uri($uri);
+ }
+
+ throw new \InvalidArgumentException('URI must be a string or UriInterface');
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Arr.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Arr.php
new file mode 100644
index 0000000..d83cf5f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Arr.php
@@ -0,0 +1,939 @@
+<?php
+
+namespace Illuminate\Support;
+
+use ArgumentCountError;
+use ArrayAccess;
+use Illuminate\Support\Traits\Macroable;
+use InvalidArgumentException;
+
+class Arr
+{
+ use Macroable;
+
+ /**
+ * Determine whether the given value is array accessible.
+ *
+ * @param mixed $value
+ * @return bool
+ */
+ public static function accessible($value)
+ {
+ return is_array($value) || $value instanceof ArrayAccess;
+ }
+
+ /**
+ * Add an element to an array using "dot" notation if it doesn't exist.
+ *
+ * @param array $array
+ * @param string|int|float $key
+ * @param mixed $value
+ * @return array
+ */
+ public static function add($array, $key, $value)
+ {
+ if (is_null(static::get($array, $key))) {
+ static::set($array, $key, $value);
+ }
+
+ return $array;
+ }
+
+ /**
+ * Collapse an array of arrays into a single array.
+ *
+ * @param iterable $array
+ * @return array
+ */
+ public static function collapse($array)
+ {
+ $results = [];
+
+ foreach ($array as $values) {
+ if ($values instanceof Collection) {
+ $values = $values->all();
+ } elseif (! is_array($values)) {
+ continue;
+ }
+
+ $results[] = $values;
+ }
+
+ return array_merge([], ...$results);
+ }
+
+ /**
+ * Cross join the given arrays, returning all possible permutations.
+ *
+ * @param iterable ...$arrays
+ * @return array
+ */
+ public static function crossJoin(...$arrays)
+ {
+ $results = [[]];
+
+ foreach ($arrays as $index => $array) {
+ $append = [];
+
+ foreach ($results as $product) {
+ foreach ($array as $item) {
+ $product[$index] = $item;
+
+ $append[] = $product;
+ }
+ }
+
+ $results = $append;
+ }
+
+ return $results;
+ }
+
+ /**
+ * Divide an array into two arrays. One with keys and the other with values.
+ *
+ * @param array $array
+ * @return array
+ */
+ public static function divide($array)
+ {
+ return [array_keys($array), array_values($array)];
+ }
+
+ /**
+ * Flatten a multi-dimensional associative array with dots.
+ *
+ * @param iterable $array
+ * @param string $prepend
+ * @return array
+ */
+ public static function dot($array, $prepend = '')
+ {
+ $results = [];
+
+ foreach ($array as $key => $value) {
+ if (is_array($value) && ! empty($value)) {
+ $results = array_merge($results, static::dot($value, $prepend.$key.'.'));
+ } else {
+ $results[$prepend.$key] = $value;
+ }
+ }
+
+ return $results;
+ }
+
+ /**
+ * Convert a flatten "dot" notation array into an expanded array.
+ *
+ * @param iterable $array
+ * @return array
+ */
+ public static function undot($array)
+ {
+ $results = [];
+
+ foreach ($array as $key => $value) {
+ static::set($results, $key, $value);
+ }
+
+ return $results;
+ }
+
+ /**
+ * Get all of the given array except for a specified array of keys.
+ *
+ * @param array $array
+ * @param array|string|int|float $keys
+ * @return array
+ */
+ public static function except($array, $keys)
+ {
+ static::forget($array, $keys);
+
+ return $array;
+ }
+
+ /**
+ * Determine if the given key exists in the provided array.
+ *
+ * @param \ArrayAccess|array $array
+ * @param string|int $key
+ * @return bool
+ */
+ public static function exists($array, $key)
+ {
+ if ($array instanceof Enumerable) {
+ return $array->has($key);
+ }
+
+ if ($array instanceof ArrayAccess) {
+ return $array->offsetExists($key);
+ }
+
+ if (is_float($key)) {
+ $key = (string) $key;
+ }
+
+ return array_key_exists($key, $array);
+ }
+
+ /**
+ * Return the first element in an array passing a given truth test.
+ *
+ * @param iterable $array
+ * @param callable|null $callback
+ * @param mixed $default
+ * @return mixed
+ */
+ public static function first($array, ?callable $callback = null, $default = null)
+ {
+ if (is_null($callback)) {
+ if (empty($array)) {
+ return value($default);
+ }
+
+ foreach ($array as $item) {
+ return $item;
+ }
+
+ return value($default);
+ }
+
+ foreach ($array as $key => $value) {
+ if ($callback($value, $key)) {
+ return $value;
+ }
+ }
+
+ return value($default);
+ }
+
+ /**
+ * Return the last element in an array passing a given truth test.
+ *
+ * @param array $array
+ * @param callable|null $callback
+ * @param mixed $default
+ * @return mixed
+ */
+ public static function last($array, ?callable $callback = null, $default = null)
+ {
+ if (is_null($callback)) {
+ return empty($array) ? value($default) : end($array);
+ }
+
+ return static::first(array_reverse($array, true), $callback, $default);
+ }
+
+ /**
+ * Take the first or last {$limit} items from an array.
+ *
+ * @param array $array
+ * @param int $limit
+ * @return array
+ */
+ public static function take($array, $limit)
+ {
+ if ($limit < 0) {
+ return array_slice($array, $limit, abs($limit));
+ }
+
+ return array_slice($array, 0, $limit);
+ }
+
+ /**
+ * Flatten a multi-dimensional array into a single level.
+ *
+ * @param iterable $array
+ * @param int $depth
+ * @return array
+ */
+ public static function flatten($array, $depth = INF)
+ {
+ $result = [];
+
+ foreach ($array as $item) {
+ $item = $item instanceof Collection ? $item->all() : $item;
+
+ if (! is_array($item)) {
+ $result[] = $item;
+ } else {
+ $values = $depth === 1
+ ? array_values($item)
+ : static::flatten($item, $depth - 1);
+
+ foreach ($values as $value) {
+ $result[] = $value;
+ }
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Remove one or many array items from a given array using "dot" notation.
+ *
+ * @param array $array
+ * @param array|string|int|float $keys
+ * @return void
+ */
+ public static function forget(&$array, $keys)
+ {
+ $original = &$array;
+
+ $keys = (array) $keys;
+
+ if (count($keys) === 0) {
+ return;
+ }
+
+ foreach ($keys as $key) {
+ // if the exact key exists in the top-level, remove it
+ if (static::exists($array, $key)) {
+ unset($array[$key]);
+
+ continue;
+ }
+
+ $parts = explode('.', $key);
+
+ // clean up before each pass
+ $array = &$original;
+
+ while (count($parts) > 1) {
+ $part = array_shift($parts);
+
+ if (isset($array[$part]) && static::accessible($array[$part])) {
+ $array = &$array[$part];
+ } else {
+ continue 2;
+ }
+ }
+
+ unset($array[array_shift($parts)]);
+ }
+ }
+
+ /**
+ * Get an item from an array using "dot" notation.
+ *
+ * @param \ArrayAccess|array $array
+ * @param string|int|null $key
+ * @param mixed $default
+ * @return mixed
+ */
+ public static function get($array, $key, $default = null)
+ {
+ if (! static::accessible($array)) {
+ return value($default);
+ }
+
+ if (is_null($key)) {
+ return $array;
+ }
+
+ if (static::exists($array, $key)) {
+ return $array[$key];
+ }
+
+ if (! str_contains($key, '.')) {
+ return $array[$key] ?? value($default);
+ }
+
+ foreach (explode('.', $key) as $segment) {
+ if (static::accessible($array) && static::exists($array, $segment)) {
+ $array = $array[$segment];
+ } else {
+ return value($default);
+ }
+ }
+
+ return $array;
+ }
+
+ /**
+ * Check if an item or items exist in an array using "dot" notation.
+ *
+ * @param \ArrayAccess|array $array
+ * @param string|array $keys
+ * @return bool
+ */
+ public static function has($array, $keys)
+ {
+ $keys = (array) $keys;
+
+ if (! $array || $keys === []) {
+ return false;
+ }
+
+ foreach ($keys as $key) {
+ $subKeyArray = $array;
+
+ if (static::exists($array, $key)) {
+ continue;
+ }
+
+ foreach (explode('.', $key) as $segment) {
+ if (static::accessible($subKeyArray) && static::exists($subKeyArray, $segment)) {
+ $subKeyArray = $subKeyArray[$segment];
+ } else {
+ return false;
+ }
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Determine if any of the keys exist in an array using "dot" notation.
+ *
+ * @param \ArrayAccess|array $array
+ * @param string|array $keys
+ * @return bool
+ */
+ public static function hasAny($array, $keys)
+ {
+ if (is_null($keys)) {
+ return false;
+ }
+
+ $keys = (array) $keys;
+
+ if (! $array) {
+ return false;
+ }
+
+ if ($keys === []) {
+ return false;
+ }
+
+ foreach ($keys as $key) {
+ if (static::has($array, $key)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Determines if an array is associative.
+ *
+ * An array is "associative" if it doesn't have sequential numerical keys beginning with zero.
+ *
+ * @param array $array
+ * @return bool
+ */
+ public static function isAssoc(array $array)
+ {
+ return ! array_is_list($array);
+ }
+
+ /**
+ * Determines if an array is a list.
+ *
+ * An array is a "list" if all array keys are sequential integers starting from 0 with no gaps in between.
+ *
+ * @param array $array
+ * @return bool
+ */
+ public static function isList($array)
+ {
+ return array_is_list($array);
+ }
+
+ /**
+ * Join all items using a string. The final items can use a separate glue string.
+ *
+ * @param array $array
+ * @param string $glue
+ * @param string $finalGlue
+ * @return string
+ */
+ public static function join($array, $glue, $finalGlue = '')
+ {
+ if ($finalGlue === '') {
+ return implode($glue, $array);
+ }
+
+ if (count($array) === 0) {
+ return '';
+ }
+
+ if (count($array) === 1) {
+ return end($array);
+ }
+
+ $finalItem = array_pop($array);
+
+ return implode($glue, $array).$finalGlue.$finalItem;
+ }
+
+ /**
+ * Key an associative array by a field or using a callback.
+ *
+ * @param array $array
+ * @param callable|array|string $keyBy
+ * @return array
+ */
+ public static function keyBy($array, $keyBy)
+ {
+ return Collection::make($array)->keyBy($keyBy)->all();
+ }
+
+ /**
+ * Prepend the key names of an associative array.
+ *
+ * @param array $array
+ * @param string $prependWith
+ * @return array
+ */
+ public static function prependKeysWith($array, $prependWith)
+ {
+ return static::mapWithKeys($array, fn ($item, $key) => [$prependWith.$key => $item]);
+ }
+
+ /**
+ * Get a subset of the items from the given array.
+ *
+ * @param array $array
+ * @param array|string $keys
+ * @return array
+ */
+ public static function only($array, $keys)
+ {
+ return array_intersect_key($array, array_flip((array) $keys));
+ }
+
+ /**
+ * Select an array of values from an array.
+ *
+ * @param array $array
+ * @param array|string $keys
+ * @return array
+ */
+ public static function select($array, $keys)
+ {
+ $keys = static::wrap($keys);
+
+ return static::map($array, function ($item) use ($keys) {
+ $result = [];
+
+ foreach ($keys as $key) {
+ if (Arr::accessible($item) && Arr::exists($item, $key)) {
+ $result[$key] = $item[$key];
+ } elseif (is_object($item) && isset($item->{$key})) {
+ $result[$key] = $item->{$key};
+ }
+ }
+
+ return $result;
+ });
+ }
+
+ /**
+ * Pluck an array of values from an array.
+ *
+ * @param iterable $array
+ * @param string|array|int|null $value
+ * @param string|array|null $key
+ * @return array
+ */
+ public static function pluck($array, $value, $key = null)
+ {
+ $results = [];
+
+ [$value, $key] = static::explodePluckParameters($value, $key);
+
+ foreach ($array as $item) {
+ $itemValue = data_get($item, $value);
+
+ // If the key is "null", we will just append the value to the array and keep
+ // looping. Otherwise we will key the array using the value of the key we
+ // received from the developer. Then we'll return the final array form.
+ if (is_null($key)) {
+ $results[] = $itemValue;
+ } else {
+ $itemKey = data_get($item, $key);
+
+ if (is_object($itemKey) && method_exists($itemKey, '__toString')) {
+ $itemKey = (string) $itemKey;
+ }
+
+ $results[$itemKey] = $itemValue;
+ }
+ }
+
+ return $results;
+ }
+
+ /**
+ * Explode the "value" and "key" arguments passed to "pluck".
+ *
+ * @param string|array $value
+ * @param string|array|null $key
+ * @return array
+ */
+ protected static function explodePluckParameters($value, $key)
+ {
+ $value = is_string($value) ? explode('.', $value) : $value;
+
+ $key = is_null($key) || is_array($key) ? $key : explode('.', $key);
+
+ return [$value, $key];
+ }
+
+ /**
+ * Run a map over each of the items in the array.
+ *
+ * @param array $array
+ * @param callable $callback
+ * @return array
+ */
+ public static function map(array $array, callable $callback)
+ {
+ $keys = array_keys($array);
+
+ try {
+ $items = array_map($callback, $array, $keys);
+ } catch (ArgumentCountError) {
+ $items = array_map($callback, $array);
+ }
+
+ return array_combine($keys, $items);
+ }
+
+ /**
+ * Run an associative map over each of the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TKey
+ * @template TValue
+ * @template TMapWithKeysKey of array-key
+ * @template TMapWithKeysValue
+ *
+ * @param array<TKey, TValue> $array
+ * @param callable(TValue, TKey): array<TMapWithKeysKey, TMapWithKeysValue> $callback
+ * @return array
+ */
+ public static function mapWithKeys(array $array, callable $callback)
+ {
+ $result = [];
+
+ foreach ($array as $key => $value) {
+ $assoc = $callback($value, $key);
+
+ foreach ($assoc as $mapKey => $mapValue) {
+ $result[$mapKey] = $mapValue;
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Push an item onto the beginning of an array.
+ *
+ * @param array $array
+ * @param mixed $value
+ * @param mixed $key
+ * @return array
+ */
+ public static function prepend($array, $value, $key = null)
+ {
+ if (func_num_args() == 2) {
+ array_unshift($array, $value);
+ } else {
+ $array = [$key => $value] + $array;
+ }
+
+ return $array;
+ }
+
+ /**
+ * Get a value from the array, and remove it.
+ *
+ * @param array $array
+ * @param string|int $key
+ * @param mixed $default
+ * @return mixed
+ */
+ public static function pull(&$array, $key, $default = null)
+ {
+ $value = static::get($array, $key, $default);
+
+ static::forget($array, $key);
+
+ return $value;
+ }
+
+ /**
+ * Convert the array into a query string.
+ *
+ * @param array $array
+ * @return string
+ */
+ public static function query($array)
+ {
+ return http_build_query($array, '', '&', PHP_QUERY_RFC3986);
+ }
+
+ /**
+ * Get one or a specified number of random values from an array.
+ *
+ * @param array $array
+ * @param int|null $number
+ * @param bool $preserveKeys
+ * @return mixed
+ *
+ * @throws \InvalidArgumentException
+ */
+ public static function random($array, $number = null, $preserveKeys = false)
+ {
+ $requested = is_null($number) ? 1 : $number;
+
+ $count = count($array);
+
+ if ($requested > $count) {
+ throw new InvalidArgumentException(
+ "You requested {$requested} items, but there are only {$count} items available."
+ );
+ }
+
+ if (is_null($number)) {
+ return $array[array_rand($array)];
+ }
+
+ if ((int) $number === 0) {
+ return [];
+ }
+
+ $keys = array_rand($array, $number);
+
+ $results = [];
+
+ if ($preserveKeys) {
+ foreach ((array) $keys as $key) {
+ $results[$key] = $array[$key];
+ }
+ } else {
+ foreach ((array) $keys as $key) {
+ $results[] = $array[$key];
+ }
+ }
+
+ return $results;
+ }
+
+ /**
+ * Set an array item to a given value using "dot" notation.
+ *
+ * If no key is given to the method, the entire array will be replaced.
+ *
+ * @param array $array
+ * @param string|int|null $key
+ * @param mixed $value
+ * @return array
+ */
+ public static function set(&$array, $key, $value)
+ {
+ if (is_null($key)) {
+ return $array = $value;
+ }
+
+ $keys = explode('.', $key);
+
+ foreach ($keys as $i => $key) {
+ if (count($keys) === 1) {
+ break;
+ }
+
+ unset($keys[$i]);
+
+ // If the key doesn't exist at this depth, we will just create an empty array
+ // to hold the next value, allowing us to create the arrays to hold final
+ // values at the correct depth. Then we'll keep digging into the array.
+ if (! isset($array[$key]) || ! is_array($array[$key])) {
+ $array[$key] = [];
+ }
+
+ $array = &$array[$key];
+ }
+
+ $array[array_shift($keys)] = $value;
+
+ return $array;
+ }
+
+ /**
+ * Shuffle the given array and return the result.
+ *
+ * @param array $array
+ * @param int|null $seed
+ * @return array
+ */
+ public static function shuffle($array, $seed = null)
+ {
+ if (is_null($seed)) {
+ shuffle($array);
+ } else {
+ mt_srand($seed);
+ shuffle($array);
+ mt_srand();
+ }
+
+ return $array;
+ }
+
+ /**
+ * Sort the array using the given callback or "dot" notation.
+ *
+ * @param array $array
+ * @param callable|array|string|null $callback
+ * @return array
+ */
+ public static function sort($array, $callback = null)
+ {
+ return Collection::make($array)->sortBy($callback)->all();
+ }
+
+ /**
+ * Sort the array in descending order using the given callback or "dot" notation.
+ *
+ * @param array $array
+ * @param callable|array|string|null $callback
+ * @return array
+ */
+ public static function sortDesc($array, $callback = null)
+ {
+ return Collection::make($array)->sortByDesc($callback)->all();
+ }
+
+ /**
+ * Recursively sort an array by keys and values.
+ *
+ * @param array $array
+ * @param int $options
+ * @param bool $descending
+ * @return array
+ */
+ public static function sortRecursive($array, $options = SORT_REGULAR, $descending = false)
+ {
+ foreach ($array as &$value) {
+ if (is_array($value)) {
+ $value = static::sortRecursive($value, $options, $descending);
+ }
+ }
+
+ if (! array_is_list($array)) {
+ $descending
+ ? krsort($array, $options)
+ : ksort($array, $options);
+ } else {
+ $descending
+ ? rsort($array, $options)
+ : sort($array, $options);
+ }
+
+ return $array;
+ }
+
+ /**
+ * Recursively sort an array by keys and values in descending order.
+ *
+ * @param array $array
+ * @param int $options
+ * @return array
+ */
+ public static function sortRecursiveDesc($array, $options = SORT_REGULAR)
+ {
+ return static::sortRecursive($array, $options, true);
+ }
+
+ /**
+ * Conditionally compile classes from an array into a CSS class list.
+ *
+ * @param array $array
+ * @return string
+ */
+ public static function toCssClasses($array)
+ {
+ $classList = static::wrap($array);
+
+ $classes = [];
+
+ foreach ($classList as $class => $constraint) {
+ if (is_numeric($class)) {
+ $classes[] = $constraint;
+ } elseif ($constraint) {
+ $classes[] = $class;
+ }
+ }
+
+ return implode(' ', $classes);
+ }
+
+ /**
+ * Conditionally compile styles from an array into a style list.
+ *
+ * @param array $array
+ * @return string
+ */
+ public static function toCssStyles($array)
+ {
+ $styleList = static::wrap($array);
+
+ $styles = [];
+
+ foreach ($styleList as $class => $constraint) {
+ if (is_numeric($class)) {
+ $styles[] = Str::finish($constraint, ';');
+ } elseif ($constraint) {
+ $styles[] = Str::finish($class, ';');
+ }
+ }
+
+ return implode(' ', $styles);
+ }
+
+ /**
+ * Filter the array using the given callback.
+ *
+ * @param array $array
+ * @param callable $callback
+ * @return array
+ */
+ public static function where($array, callable $callback)
+ {
+ return array_filter($array, $callback, ARRAY_FILTER_USE_BOTH);
+ }
+
+ /**
+ * Filter items where the value is not null.
+ *
+ * @param array $array
+ * @return array
+ */
+ public static function whereNotNull($array)
+ {
+ return static::where($array, fn ($value) => ! is_null($value));
+ }
+
+ /**
+ * If the given value is not an array and not null, wrap it in one.
+ *
+ * @param mixed $value
+ * @return array
+ */
+ public static function wrap($value)
+ {
+ if (is_null($value)) {
+ return [];
+ }
+
+ return is_array($value) ? $value : [$value];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Collection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Collection.php
new file mode 100644
index 0000000..2f0c768
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Collection.php
@@ -0,0 +1,1821 @@
+<?php
+
+namespace Illuminate\Support;
+
+use ArrayAccess;
+use ArrayIterator;
+use Illuminate\Contracts\Support\CanBeEscapedWhenCastToString;
+use Illuminate\Support\Traits\EnumeratesValues;
+use Illuminate\Support\Traits\Macroable;
+use InvalidArgumentException;
+use stdClass;
+use Traversable;
+
+/**
+ * @template TKey of array-key
+ *
+ * @template-covariant TValue
+ *
+ * @implements \ArrayAccess<TKey, TValue>
+ * @implements \Illuminate\Support\Enumerable<TKey, TValue>
+ */
+class Collection implements ArrayAccess, CanBeEscapedWhenCastToString, Enumerable
+{
+ /**
+ * @use \Illuminate\Support\Traits\EnumeratesValues<TKey, TValue>
+ */
+ use EnumeratesValues, Macroable;
+
+ /**
+ * The items contained in the collection.
+ *
+ * @var array<TKey, TValue>
+ */
+ protected $items = [];
+
+ /**
+ * Create a new collection.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue>|null $items
+ * @return void
+ */
+ public function __construct($items = [])
+ {
+ $this->items = $this->getArrayableItems($items);
+ }
+
+ /**
+ * Create a collection with the given range.
+ *
+ * @param int $from
+ * @param int $to
+ * @return static<int, int>
+ */
+ public static function range($from, $to)
+ {
+ return new static(range($from, $to));
+ }
+
+ /**
+ * Get all of the items in the collection.
+ *
+ * @return array<TKey, TValue>
+ */
+ public function all()
+ {
+ return $this->items;
+ }
+
+ /**
+ * Get a lazy collection for the items in this collection.
+ *
+ * @return \Illuminate\Support\LazyCollection<TKey, TValue>
+ */
+ public function lazy()
+ {
+ return new LazyCollection($this->items);
+ }
+
+ /**
+ * Get the average value of a given key.
+ *
+ * @param (callable(TValue): float|int)|string|null $callback
+ * @return float|int|null
+ */
+ public function avg($callback = null)
+ {
+ $callback = $this->valueRetriever($callback);
+
+ $items = $this
+ ->map(fn ($value) => $callback($value))
+ ->filter(fn ($value) => ! is_null($value));
+
+ if ($count = $items->count()) {
+ return $items->sum() / $count;
+ }
+ }
+
+ /**
+ * Get the median of a given key.
+ *
+ * @param string|array<array-key, string>|null $key
+ * @return float|int|null
+ */
+ public function median($key = null)
+ {
+ $values = (isset($key) ? $this->pluck($key) : $this)
+ ->filter(fn ($item) => ! is_null($item))
+ ->sort()->values();
+
+ $count = $values->count();
+
+ if ($count === 0) {
+ return;
+ }
+
+ $middle = (int) ($count / 2);
+
+ if ($count % 2) {
+ return $values->get($middle);
+ }
+
+ return (new static([
+ $values->get($middle - 1), $values->get($middle),
+ ]))->average();
+ }
+
+ /**
+ * Get the mode of a given key.
+ *
+ * @param string|array<array-key, string>|null $key
+ * @return array<int, float|int>|null
+ */
+ public function mode($key = null)
+ {
+ if ($this->count() === 0) {
+ return;
+ }
+
+ $collection = isset($key) ? $this->pluck($key) : $this;
+
+ $counts = new static;
+
+ $collection->each(fn ($value) => $counts[$value] = isset($counts[$value]) ? $counts[$value] + 1 : 1);
+
+ $sorted = $counts->sort();
+
+ $highestValue = $sorted->last();
+
+ return $sorted->filter(fn ($value) => $value == $highestValue)
+ ->sort()->keys()->all();
+ }
+
+ /**
+ * Collapse the collection of items into a single array.
+ *
+ * @return static<int, mixed>
+ */
+ public function collapse()
+ {
+ return new static(Arr::collapse($this->items));
+ }
+
+ /**
+ * Determine if an item exists in the collection.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function contains($key, $operator = null, $value = null)
+ {
+ if (func_num_args() === 1) {
+ if ($this->useAsCallable($key)) {
+ $placeholder = new stdClass;
+
+ return $this->first($key, $placeholder) !== $placeholder;
+ }
+
+ return in_array($key, $this->items);
+ }
+
+ return $this->contains($this->operatorForWhere(...func_get_args()));
+ }
+
+ /**
+ * Determine if an item exists, using strict comparison.
+ *
+ * @param (callable(TValue): bool)|TValue|array-key $key
+ * @param TValue|null $value
+ * @return bool
+ */
+ public function containsStrict($key, $value = null)
+ {
+ if (func_num_args() === 2) {
+ return $this->contains(fn ($item) => data_get($item, $key) === $value);
+ }
+
+ if ($this->useAsCallable($key)) {
+ return ! is_null($this->first($key));
+ }
+
+ return in_array($key, $this->items, true);
+ }
+
+ /**
+ * Determine if an item is not contained in the collection.
+ *
+ * @param mixed $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function doesntContain($key, $operator = null, $value = null)
+ {
+ return ! $this->contains(...func_get_args());
+ }
+
+ /**
+ * Cross join with the given lists, returning all possible permutations.
+ *
+ * @template TCrossJoinKey
+ * @template TCrossJoinValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TCrossJoinKey, TCrossJoinValue>|iterable<TCrossJoinKey, TCrossJoinValue> ...$lists
+ * @return static<int, array<int, TValue|TCrossJoinValue>>
+ */
+ public function crossJoin(...$lists)
+ {
+ return new static(Arr::crossJoin(
+ $this->items, ...array_map([$this, 'getArrayableItems'], $lists)
+ ));
+ }
+
+ /**
+ * Get the items in the collection that are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @return static
+ */
+ public function diff($items)
+ {
+ return new static(array_diff($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Get the items in the collection that are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @param callable(TValue, TValue): int $callback
+ * @return static
+ */
+ public function diffUsing($items, callable $callback)
+ {
+ return new static(array_udiff($this->items, $this->getArrayableItems($items), $callback));
+ }
+
+ /**
+ * Get the items in the collection whose keys and values are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function diffAssoc($items)
+ {
+ return new static(array_diff_assoc($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Get the items in the collection whose keys and values are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function diffAssocUsing($items, callable $callback)
+ {
+ return new static(array_diff_uassoc($this->items, $this->getArrayableItems($items), $callback));
+ }
+
+ /**
+ * Get the items in the collection whose keys are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function diffKeys($items)
+ {
+ return new static(array_diff_key($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Get the items in the collection whose keys are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function diffKeysUsing($items, callable $callback)
+ {
+ return new static(array_diff_ukey($this->items, $this->getArrayableItems($items), $callback));
+ }
+
+ /**
+ * Retrieve duplicate items from the collection.
+ *
+ * @param (callable(TValue): bool)|string|null $callback
+ * @param bool $strict
+ * @return static
+ */
+ public function duplicates($callback = null, $strict = false)
+ {
+ $items = $this->map($this->valueRetriever($callback));
+
+ $uniqueItems = $items->unique(null, $strict);
+
+ $compare = $this->duplicateComparator($strict);
+
+ $duplicates = new static;
+
+ foreach ($items as $key => $value) {
+ if ($uniqueItems->isNotEmpty() && $compare($value, $uniqueItems->first())) {
+ $uniqueItems->shift();
+ } else {
+ $duplicates[$key] = $value;
+ }
+ }
+
+ return $duplicates;
+ }
+
+ /**
+ * Retrieve duplicate items from the collection using strict comparison.
+ *
+ * @param (callable(TValue): bool)|string|null $callback
+ * @return static
+ */
+ public function duplicatesStrict($callback = null)
+ {
+ return $this->duplicates($callback, true);
+ }
+
+ /**
+ * Get the comparison function to detect duplicates.
+ *
+ * @param bool $strict
+ * @return callable(TValue, TValue): bool
+ */
+ protected function duplicateComparator($strict)
+ {
+ if ($strict) {
+ return fn ($a, $b) => $a === $b;
+ }
+
+ return fn ($a, $b) => $a == $b;
+ }
+
+ /**
+ * Get all items except for those with the specified keys.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey>|string $keys
+ * @return static
+ */
+ public function except($keys)
+ {
+ if (is_null($keys)) {
+ return new static($this->items);
+ }
+
+ if ($keys instanceof Enumerable) {
+ $keys = $keys->all();
+ } elseif (! is_array($keys)) {
+ $keys = func_get_args();
+ }
+
+ return new static(Arr::except($this->items, $keys));
+ }
+
+ /**
+ * Run a filter over each of the items.
+ *
+ * @param (callable(TValue, TKey): bool)|null $callback
+ * @return static
+ */
+ public function filter(?callable $callback = null)
+ {
+ if ($callback) {
+ return new static(Arr::where($this->items, $callback));
+ }
+
+ return new static(array_filter($this->items));
+ }
+
+ /**
+ * Get the first item from the collection passing the given truth test.
+ *
+ * @template TFirstDefault
+ *
+ * @param (callable(TValue, TKey): bool)|null $callback
+ * @param TFirstDefault|(\Closure(): TFirstDefault) $default
+ * @return TValue|TFirstDefault
+ */
+ public function first(?callable $callback = null, $default = null)
+ {
+ return Arr::first($this->items, $callback, $default);
+ }
+
+ /**
+ * Get a flattened array of the items in the collection.
+ *
+ * @param int $depth
+ * @return static<int, mixed>
+ */
+ public function flatten($depth = INF)
+ {
+ return new static(Arr::flatten($this->items, $depth));
+ }
+
+ /**
+ * Flip the items in the collection.
+ *
+ * @return static<TValue, TKey>
+ */
+ public function flip()
+ {
+ return new static(array_flip($this->items));
+ }
+
+ /**
+ * Remove an item from the collection by key.
+ *
+ * \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TKey>|TKey $keys
+ *
+ * @return $this
+ */
+ public function forget($keys)
+ {
+ foreach ($this->getArrayableItems($keys) as $key) {
+ $this->offsetUnset($key);
+ }
+
+ return $this;
+ }
+
+ /**
+ * Get an item from the collection by key.
+ *
+ * @template TGetDefault
+ *
+ * @param TKey $key
+ * @param TGetDefault|(\Closure(): TGetDefault) $default
+ * @return TValue|TGetDefault
+ */
+ public function get($key, $default = null)
+ {
+ if (array_key_exists($key, $this->items)) {
+ return $this->items[$key];
+ }
+
+ return value($default);
+ }
+
+ /**
+ * Get an item from the collection by key or add it to collection if it does not exist.
+ *
+ * @template TGetOrPutValue
+ *
+ * @param mixed $key
+ * @param TGetOrPutValue|(\Closure(): TGetOrPutValue) $value
+ * @return TValue|TGetOrPutValue
+ */
+ public function getOrPut($key, $value)
+ {
+ if (array_key_exists($key, $this->items)) {
+ return $this->items[$key];
+ }
+
+ $this->offsetSet($key, $value = value($value));
+
+ return $value;
+ }
+
+ /**
+ * Group an associative array by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|array|string $groupBy
+ * @param bool $preserveKeys
+ * @return static<array-key, static<array-key, TValue>>
+ */
+ public function groupBy($groupBy, $preserveKeys = false)
+ {
+ if (! $this->useAsCallable($groupBy) && is_array($groupBy)) {
+ $nextGroups = $groupBy;
+
+ $groupBy = array_shift($nextGroups);
+ }
+
+ $groupBy = $this->valueRetriever($groupBy);
+
+ $results = [];
+
+ foreach ($this->items as $key => $value) {
+ $groupKeys = $groupBy($value, $key);
+
+ if (! is_array($groupKeys)) {
+ $groupKeys = [$groupKeys];
+ }
+
+ foreach ($groupKeys as $groupKey) {
+ $groupKey = match (true) {
+ is_bool($groupKey) => (int) $groupKey,
+ $groupKey instanceof \BackedEnum => $groupKey->value,
+ $groupKey instanceof \Stringable => (string) $groupKey,
+ default => $groupKey,
+ };
+
+ if (! array_key_exists($groupKey, $results)) {
+ $results[$groupKey] = new static;
+ }
+
+ $results[$groupKey]->offsetSet($preserveKeys ? $key : null, $value);
+ }
+ }
+
+ $result = new static($results);
+
+ if (! empty($nextGroups)) {
+ return $result->map->groupBy($nextGroups, $preserveKeys);
+ }
+
+ return $result;
+ }
+
+ /**
+ * Key an associative array by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|array|string $keyBy
+ * @return static<array-key, TValue>
+ */
+ public function keyBy($keyBy)
+ {
+ $keyBy = $this->valueRetriever($keyBy);
+
+ $results = [];
+
+ foreach ($this->items as $key => $item) {
+ $resolvedKey = $keyBy($item, $key);
+
+ if (is_object($resolvedKey)) {
+ $resolvedKey = (string) $resolvedKey;
+ }
+
+ $results[$resolvedKey] = $item;
+ }
+
+ return new static($results);
+ }
+
+ /**
+ * Determine if an item exists in the collection by key.
+ *
+ * @param TKey|array<array-key, TKey> $key
+ * @return bool
+ */
+ public function has($key)
+ {
+ $keys = is_array($key) ? $key : func_get_args();
+
+ foreach ($keys as $value) {
+ if (! array_key_exists($value, $this->items)) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Determine if any of the keys exist in the collection.
+ *
+ * @param mixed $key
+ * @return bool
+ */
+ public function hasAny($key)
+ {
+ if ($this->isEmpty()) {
+ return false;
+ }
+
+ $keys = is_array($key) ? $key : func_get_args();
+
+ foreach ($keys as $value) {
+ if ($this->has($value)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Concatenate values of a given key as a string.
+ *
+ * @param callable|string $value
+ * @param string|null $glue
+ * @return string
+ */
+ public function implode($value, $glue = null)
+ {
+ if ($this->useAsCallable($value)) {
+ return implode($glue ?? '', $this->map($value)->all());
+ }
+
+ $first = $this->first();
+
+ if (is_array($first) || (is_object($first) && ! $first instanceof Stringable)) {
+ return implode($glue ?? '', $this->pluck($value)->all());
+ }
+
+ return implode($value ?? '', $this->items);
+ }
+
+ /**
+ * Intersect the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersect($items)
+ {
+ return new static(array_intersect($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Intersect the collection with the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @param callable(TValue, TValue): int $callback
+ * @return static
+ */
+ public function intersectUsing($items, callable $callback)
+ {
+ return new static(array_uintersect($this->items, $this->getArrayableItems($items), $callback));
+ }
+
+ /**
+ * Intersect the collection with the given items with additional index check.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersectAssoc($items)
+ {
+ return new static(array_intersect_assoc($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Intersect the collection with the given items with additional index check, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @param callable(TValue, TValue): int $callback
+ * @return static
+ */
+ public function intersectAssocUsing($items, callable $callback)
+ {
+ return new static(array_intersect_uassoc($this->items, $this->getArrayableItems($items), $callback));
+ }
+
+ /**
+ * Intersect the collection with the given items by key.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersectByKeys($items)
+ {
+ return new static(array_intersect_key(
+ $this->items, $this->getArrayableItems($items)
+ ));
+ }
+
+ /**
+ * Determine if the collection is empty or not.
+ *
+ * @return bool
+ */
+ public function isEmpty()
+ {
+ return empty($this->items);
+ }
+
+ /**
+ * Determine if the collection contains a single item.
+ *
+ * @return bool
+ */
+ public function containsOneItem()
+ {
+ return $this->count() === 1;
+ }
+
+ /**
+ * Join all items from the collection using a string. The final items can use a separate glue string.
+ *
+ * @param string $glue
+ * @param string $finalGlue
+ * @return string
+ */
+ public function join($glue, $finalGlue = '')
+ {
+ if ($finalGlue === '') {
+ return $this->implode($glue);
+ }
+
+ $count = $this->count();
+
+ if ($count === 0) {
+ return '';
+ }
+
+ if ($count === 1) {
+ return $this->last();
+ }
+
+ $collection = new static($this->items);
+
+ $finalItem = $collection->pop();
+
+ return $collection->implode($glue).$finalGlue.$finalItem;
+ }
+
+ /**
+ * Get the keys of the collection items.
+ *
+ * @return static<int, TKey>
+ */
+ public function keys()
+ {
+ return new static(array_keys($this->items));
+ }
+
+ /**
+ * Get the last item from the collection.
+ *
+ * @template TLastDefault
+ *
+ * @param (callable(TValue, TKey): bool)|null $callback
+ * @param TLastDefault|(\Closure(): TLastDefault) $default
+ * @return TValue|TLastDefault
+ */
+ public function last(?callable $callback = null, $default = null)
+ {
+ return Arr::last($this->items, $callback, $default);
+ }
+
+ /**
+ * Get the values of a given key.
+ *
+ * @param string|int|array<array-key, string> $value
+ * @param string|null $key
+ * @return static<array-key, mixed>
+ */
+ public function pluck($value, $key = null)
+ {
+ return new static(Arr::pluck($this->items, $value, $key));
+ }
+
+ /**
+ * Run a map over each of the items.
+ *
+ * @template TMapValue
+ *
+ * @param callable(TValue, TKey): TMapValue $callback
+ * @return static<TKey, TMapValue>
+ */
+ public function map(callable $callback)
+ {
+ return new static(Arr::map($this->items, $callback));
+ }
+
+ /**
+ * Run a dictionary map over the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapToDictionaryKey of array-key
+ * @template TMapToDictionaryValue
+ *
+ * @param callable(TValue, TKey): array<TMapToDictionaryKey, TMapToDictionaryValue> $callback
+ * @return static<TMapToDictionaryKey, array<int, TMapToDictionaryValue>>
+ */
+ public function mapToDictionary(callable $callback)
+ {
+ $dictionary = [];
+
+ foreach ($this->items as $key => $item) {
+ $pair = $callback($item, $key);
+
+ $key = key($pair);
+
+ $value = reset($pair);
+
+ if (! isset($dictionary[$key])) {
+ $dictionary[$key] = [];
+ }
+
+ $dictionary[$key][] = $value;
+ }
+
+ return new static($dictionary);
+ }
+
+ /**
+ * Run an associative map over each of the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapWithKeysKey of array-key
+ * @template TMapWithKeysValue
+ *
+ * @param callable(TValue, TKey): array<TMapWithKeysKey, TMapWithKeysValue> $callback
+ * @return static<TMapWithKeysKey, TMapWithKeysValue>
+ */
+ public function mapWithKeys(callable $callback)
+ {
+ return new static(Arr::mapWithKeys($this->items, $callback));
+ }
+
+ /**
+ * Merge the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function merge($items)
+ {
+ return new static(array_merge($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Recursively merge the collection with the given items.
+ *
+ * @template TMergeRecursiveValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TMergeRecursiveValue>|iterable<TKey, TMergeRecursiveValue> $items
+ * @return static<TKey, TValue|TMergeRecursiveValue>
+ */
+ public function mergeRecursive($items)
+ {
+ return new static(array_merge_recursive($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Create a collection by using this collection for keys and another for its values.
+ *
+ * @template TCombineValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TCombineValue>|iterable<array-key, TCombineValue> $values
+ * @return static<TValue, TCombineValue>
+ */
+ public function combine($values)
+ {
+ return new static(array_combine($this->all(), $this->getArrayableItems($values)));
+ }
+
+ /**
+ * Union the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function union($items)
+ {
+ return new static($this->items + $this->getArrayableItems($items));
+ }
+
+ /**
+ * Create a new collection consisting of every n-th element.
+ *
+ * @param int $step
+ * @param int $offset
+ * @return static
+ */
+ public function nth($step, $offset = 0)
+ {
+ $new = [];
+
+ $position = 0;
+
+ foreach ($this->slice($offset)->items as $item) {
+ if ($position % $step === 0) {
+ $new[] = $item;
+ }
+
+ $position++;
+ }
+
+ return new static($new);
+ }
+
+ /**
+ * Get the items with the specified keys.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey>|string|null $keys
+ * @return static
+ */
+ public function only($keys)
+ {
+ if (is_null($keys)) {
+ return new static($this->items);
+ }
+
+ if ($keys instanceof Enumerable) {
+ $keys = $keys->all();
+ }
+
+ $keys = is_array($keys) ? $keys : func_get_args();
+
+ return new static(Arr::only($this->items, $keys));
+ }
+
+ /**
+ * Select specific values from the items within the collection.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey>|string|null $keys
+ * @return static
+ */
+ public function select($keys)
+ {
+ if (is_null($keys)) {
+ return new static($this->items);
+ }
+
+ if ($keys instanceof Enumerable) {
+ $keys = $keys->all();
+ }
+
+ $keys = is_array($keys) ? $keys : func_get_args();
+
+ return new static(Arr::select($this->items, $keys));
+ }
+
+ /**
+ * Get and remove the last N items from the collection.
+ *
+ * @param int $count
+ * @return static<int, TValue>|TValue|null
+ */
+ public function pop($count = 1)
+ {
+ if ($count === 1) {
+ return array_pop($this->items);
+ }
+
+ if ($this->isEmpty()) {
+ return new static;
+ }
+
+ $results = [];
+
+ $collectionCount = $this->count();
+
+ foreach (range(1, min($count, $collectionCount)) as $item) {
+ array_push($results, array_pop($this->items));
+ }
+
+ return new static($results);
+ }
+
+ /**
+ * Push an item onto the beginning of the collection.
+ *
+ * @param TValue $value
+ * @param TKey $key
+ * @return $this
+ */
+ public function prepend($value, $key = null)
+ {
+ $this->items = Arr::prepend($this->items, ...func_get_args());
+
+ return $this;
+ }
+
+ /**
+ * Push one or more items onto the end of the collection.
+ *
+ * @param TValue ...$values
+ * @return $this
+ */
+ public function push(...$values)
+ {
+ foreach ($values as $value) {
+ $this->items[] = $value;
+ }
+
+ return $this;
+ }
+
+ /**
+ * Push all of the given items onto the collection.
+ *
+ * @template TConcatKey of array-key
+ * @template TConcatValue
+ *
+ * @param iterable<TConcatKey, TConcatValue> $source
+ * @return static<TKey|TConcatKey, TValue|TConcatValue>
+ */
+ public function concat($source)
+ {
+ $result = new static($this);
+
+ foreach ($source as $item) {
+ $result->push($item);
+ }
+
+ return $result;
+ }
+
+ /**
+ * Get and remove an item from the collection.
+ *
+ * @template TPullDefault
+ *
+ * @param TKey $key
+ * @param TPullDefault|(\Closure(): TPullDefault) $default
+ * @return TValue|TPullDefault
+ */
+ public function pull($key, $default = null)
+ {
+ return Arr::pull($this->items, $key, $default);
+ }
+
+ /**
+ * Put an item in the collection by key.
+ *
+ * @param TKey $key
+ * @param TValue $value
+ * @return $this
+ */
+ public function put($key, $value)
+ {
+ $this->offsetSet($key, $value);
+
+ return $this;
+ }
+
+ /**
+ * Get one or a specified number of items randomly from the collection.
+ *
+ * @param (callable(self<TKey, TValue>): int)|int|null $number
+ * @param bool $preserveKeys
+ * @return static<int, TValue>|TValue
+ *
+ * @throws \InvalidArgumentException
+ */
+ public function random($number = null, $preserveKeys = false)
+ {
+ if (is_null($number)) {
+ return Arr::random($this->items);
+ }
+
+ if (is_callable($number)) {
+ return new static(Arr::random($this->items, $number($this), $preserveKeys));
+ }
+
+ return new static(Arr::random($this->items, $number, $preserveKeys));
+ }
+
+ /**
+ * Replace the collection items with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function replace($items)
+ {
+ return new static(array_replace($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Recursively replace the collection items with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function replaceRecursive($items)
+ {
+ return new static(array_replace_recursive($this->items, $this->getArrayableItems($items)));
+ }
+
+ /**
+ * Reverse items order.
+ *
+ * @return static
+ */
+ public function reverse()
+ {
+ return new static(array_reverse($this->items, true));
+ }
+
+ /**
+ * Search the collection for a given value and return the corresponding key if successful.
+ *
+ * @param TValue|(callable(TValue,TKey): bool) $value
+ * @param bool $strict
+ * @return TKey|false
+ */
+ public function search($value, $strict = false)
+ {
+ if (! $this->useAsCallable($value)) {
+ return array_search($value, $this->items, $strict);
+ }
+
+ foreach ($this->items as $key => $item) {
+ if ($value($item, $key)) {
+ return $key;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Get and remove the first N items from the collection.
+ *
+ * @param int $count
+ * @return static<int, TValue>|TValue|null
+ *
+ * @throws \InvalidArgumentException
+ */
+ public function shift($count = 1)
+ {
+ if ($count < 0) {
+ throw new InvalidArgumentException('Number of shifted items may not be less than zero.');
+ }
+
+ if ($this->isEmpty()) {
+ return null;
+ }
+
+ if ($count === 0) {
+ return new static;
+ }
+
+ if ($count === 1) {
+ return array_shift($this->items);
+ }
+
+ $results = [];
+
+ $collectionCount = $this->count();
+
+ foreach (range(1, min($count, $collectionCount)) as $item) {
+ array_push($results, array_shift($this->items));
+ }
+
+ return new static($results);
+ }
+
+ /**
+ * Shuffle the items in the collection.
+ *
+ * @param int|null $seed
+ * @return static
+ */
+ public function shuffle($seed = null)
+ {
+ return new static(Arr::shuffle($this->items, $seed));
+ }
+
+ /**
+ * Create chunks representing a "sliding window" view of the items in the collection.
+ *
+ * @param int $size
+ * @param int $step
+ * @return static<int, static>
+ */
+ public function sliding($size = 2, $step = 1)
+ {
+ $chunks = floor(($this->count() - $size) / $step) + 1;
+
+ return static::times($chunks, fn ($number) => $this->slice(($number - 1) * $step, $size));
+ }
+
+ /**
+ * Skip the first {$count} items.
+ *
+ * @param int $count
+ * @return static
+ */
+ public function skip($count)
+ {
+ return $this->slice($count);
+ }
+
+ /**
+ * Skip items in the collection until the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function skipUntil($value)
+ {
+ return new static($this->lazy()->skipUntil($value)->all());
+ }
+
+ /**
+ * Skip items in the collection while the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function skipWhile($value)
+ {
+ return new static($this->lazy()->skipWhile($value)->all());
+ }
+
+ /**
+ * Slice the underlying collection array.
+ *
+ * @param int $offset
+ * @param int|null $length
+ * @return static
+ */
+ public function slice($offset, $length = null)
+ {
+ return new static(array_slice($this->items, $offset, $length, true));
+ }
+
+ /**
+ * Split a collection into a certain number of groups.
+ *
+ * @param int $numberOfGroups
+ * @return static<int, static>
+ */
+ public function split($numberOfGroups)
+ {
+ if ($this->isEmpty()) {
+ return new static;
+ }
+
+ $groups = new static;
+
+ $groupSize = floor($this->count() / $numberOfGroups);
+
+ $remain = $this->count() % $numberOfGroups;
+
+ $start = 0;
+
+ for ($i = 0; $i < $numberOfGroups; $i++) {
+ $size = $groupSize;
+
+ if ($i < $remain) {
+ $size++;
+ }
+
+ if ($size) {
+ $groups->push(new static(array_slice($this->items, $start, $size)));
+
+ $start += $size;
+ }
+ }
+
+ return $groups;
+ }
+
+ /**
+ * Split a collection into a certain number of groups, and fill the first groups completely.
+ *
+ * @param int $numberOfGroups
+ * @return static<int, static>
+ */
+ public function splitIn($numberOfGroups)
+ {
+ return $this->chunk(ceil($this->count() / $numberOfGroups));
+ }
+
+ /**
+ * Get the first item in the collection, but only if exactly one item exists. Otherwise, throw an exception.
+ *
+ * @param (callable(TValue, TKey): bool)|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue
+ *
+ * @throws \Illuminate\Support\ItemNotFoundException
+ * @throws \Illuminate\Support\MultipleItemsFoundException
+ */
+ public function sole($key = null, $operator = null, $value = null)
+ {
+ $filter = func_num_args() > 1
+ ? $this->operatorForWhere(...func_get_args())
+ : $key;
+
+ $items = $this->unless($filter == null)->filter($filter);
+
+ $count = $items->count();
+
+ if ($count === 0) {
+ throw new ItemNotFoundException;
+ }
+
+ if ($count > 1) {
+ throw new MultipleItemsFoundException($count);
+ }
+
+ return $items->first();
+ }
+
+ /**
+ * Get the first item in the collection but throw an exception if no matching items exist.
+ *
+ * @param (callable(TValue, TKey): bool)|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue
+ *
+ * @throws \Illuminate\Support\ItemNotFoundException
+ */
+ public function firstOrFail($key = null, $operator = null, $value = null)
+ {
+ $filter = func_num_args() > 1
+ ? $this->operatorForWhere(...func_get_args())
+ : $key;
+
+ $placeholder = new stdClass();
+
+ $item = $this->first($filter, $placeholder);
+
+ if ($item === $placeholder) {
+ throw new ItemNotFoundException;
+ }
+
+ return $item;
+ }
+
+ /**
+ * Chunk the collection into chunks of the given size.
+ *
+ * @param int $size
+ * @return static<int, static>
+ */
+ public function chunk($size)
+ {
+ if ($size <= 0) {
+ return new static;
+ }
+
+ $chunks = [];
+
+ foreach (array_chunk($this->items, $size, true) as $chunk) {
+ $chunks[] = new static($chunk);
+ }
+
+ return new static($chunks);
+ }
+
+ /**
+ * Chunk the collection into chunks with a callback.
+ *
+ * @param callable(TValue, TKey, static<int, TValue>): bool $callback
+ * @return static<int, static<int, TValue>>
+ */
+ public function chunkWhile(callable $callback)
+ {
+ return new static(
+ $this->lazy()->chunkWhile($callback)->mapInto(static::class)
+ );
+ }
+
+ /**
+ * Sort through each item with a callback.
+ *
+ * @param (callable(TValue, TValue): int)|null|int $callback
+ * @return static
+ */
+ public function sort($callback = null)
+ {
+ $items = $this->items;
+
+ $callback && is_callable($callback)
+ ? uasort($items, $callback)
+ : asort($items, $callback ?? SORT_REGULAR);
+
+ return new static($items);
+ }
+
+ /**
+ * Sort items in descending order.
+ *
+ * @param int $options
+ * @return static
+ */
+ public function sortDesc($options = SORT_REGULAR)
+ {
+ $items = $this->items;
+
+ arsort($items, $options);
+
+ return new static($items);
+ }
+
+ /**
+ * Sort the collection using the given callback.
+ *
+ * @param array<array-key, (callable(TValue, TValue): mixed)|(callable(TValue, TKey): mixed)|string|array{string, string}>|(callable(TValue, TKey): mixed)|string $callback
+ * @param int $options
+ * @param bool $descending
+ * @return static
+ */
+ public function sortBy($callback, $options = SORT_REGULAR, $descending = false)
+ {
+ if (is_array($callback) && ! is_callable($callback)) {
+ return $this->sortByMany($callback, $options);
+ }
+
+ $results = [];
+
+ $callback = $this->valueRetriever($callback);
+
+ // First we will loop through the items and get the comparator from a callback
+ // function which we were given. Then, we will sort the returned values and
+ // grab all the corresponding values for the sorted keys from this array.
+ foreach ($this->items as $key => $value) {
+ $results[$key] = $callback($value, $key);
+ }
+
+ $descending ? arsort($results, $options)
+ : asort($results, $options);
+
+ // Once we have sorted all of the keys in the array, we will loop through them
+ // and grab the corresponding model so we can set the underlying items list
+ // to the sorted version. Then we'll just return the collection instance.
+ foreach (array_keys($results) as $key) {
+ $results[$key] = $this->items[$key];
+ }
+
+ return new static($results);
+ }
+
+ /**
+ * Sort the collection using multiple comparisons.
+ *
+ * @param array<array-key, (callable(TValue, TValue): mixed)|(callable(TValue, TKey): mixed)|string|array{string, string}> $comparisons
+ * @param int $options
+ * @return static
+ */
+ protected function sortByMany(array $comparisons = [], int $options = SORT_REGULAR)
+ {
+ $items = $this->items;
+
+ uasort($items, function ($a, $b) use ($comparisons, $options) {
+ foreach ($comparisons as $comparison) {
+ $comparison = Arr::wrap($comparison);
+
+ $prop = $comparison[0];
+
+ $ascending = Arr::get($comparison, 1, true) === true ||
+ Arr::get($comparison, 1, true) === 'asc';
+
+ if (! is_string($prop) && is_callable($prop)) {
+ $result = $prop($a, $b);
+ } else {
+ $values = [data_get($a, $prop), data_get($b, $prop)];
+
+ if (! $ascending) {
+ $values = array_reverse($values);
+ }
+
+ if (($options & SORT_FLAG_CASE) === SORT_FLAG_CASE) {
+ if (($options & SORT_NATURAL) === SORT_NATURAL) {
+ $result = strnatcasecmp($values[0], $values[1]);
+ } else {
+ $result = strcasecmp($values[0], $values[1]);
+ }
+ } else {
+ $result = match ($options) {
+ SORT_NUMERIC => intval($values[0]) <=> intval($values[1]),
+ SORT_STRING => strcmp($values[0], $values[1]),
+ SORT_NATURAL => strnatcmp($values[0], $values[1]),
+ SORT_LOCALE_STRING => strcoll($values[0], $values[1]),
+ default => $values[0] <=> $values[1],
+ };
+ }
+ }
+
+ if ($result === 0) {
+ continue;
+ }
+
+ return $result;
+ }
+ });
+
+ return new static($items);
+ }
+
+ /**
+ * Sort the collection in descending order using the given callback.
+ *
+ * @param array<array-key, (callable(TValue, TValue): mixed)|(callable(TValue, TKey): mixed)|string|array{string, string}>|(callable(TValue, TKey): mixed)|string $callback
+ * @param int $options
+ * @return static
+ */
+ public function sortByDesc($callback, $options = SORT_REGULAR)
+ {
+ if (is_array($callback) && ! is_callable($callback)) {
+ foreach ($callback as $index => $key) {
+ $comparison = Arr::wrap($key);
+
+ $comparison[1] = 'desc';
+
+ $callback[$index] = $comparison;
+ }
+ }
+
+ return $this->sortBy($callback, $options, true);
+ }
+
+ /**
+ * Sort the collection keys.
+ *
+ * @param int $options
+ * @param bool $descending
+ * @return static
+ */
+ public function sortKeys($options = SORT_REGULAR, $descending = false)
+ {
+ $items = $this->items;
+
+ $descending ? krsort($items, $options) : ksort($items, $options);
+
+ return new static($items);
+ }
+
+ /**
+ * Sort the collection keys in descending order.
+ *
+ * @param int $options
+ * @return static
+ */
+ public function sortKeysDesc($options = SORT_REGULAR)
+ {
+ return $this->sortKeys($options, true);
+ }
+
+ /**
+ * Sort the collection keys using a callback.
+ *
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function sortKeysUsing(callable $callback)
+ {
+ $items = $this->items;
+
+ uksort($items, $callback);
+
+ return new static($items);
+ }
+
+ /**
+ * Splice a portion of the underlying collection array.
+ *
+ * @param int $offset
+ * @param int|null $length
+ * @param array<array-key, TValue> $replacement
+ * @return static
+ */
+ public function splice($offset, $length = null, $replacement = [])
+ {
+ if (func_num_args() === 1) {
+ return new static(array_splice($this->items, $offset));
+ }
+
+ return new static(array_splice($this->items, $offset, $length, $this->getArrayableItems($replacement)));
+ }
+
+ /**
+ * Take the first or last {$limit} items.
+ *
+ * @param int $limit
+ * @return static
+ */
+ public function take($limit)
+ {
+ if ($limit < 0) {
+ return $this->slice($limit, abs($limit));
+ }
+
+ return $this->slice(0, $limit);
+ }
+
+ /**
+ * Take items in the collection until the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function takeUntil($value)
+ {
+ return new static($this->lazy()->takeUntil($value)->all());
+ }
+
+ /**
+ * Take items in the collection while the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function takeWhile($value)
+ {
+ return new static($this->lazy()->takeWhile($value)->all());
+ }
+
+ /**
+ * Transform each item in the collection using a callback.
+ *
+ * @param callable(TValue, TKey): TValue $callback
+ * @return $this
+ */
+ public function transform(callable $callback)
+ {
+ $this->items = $this->map($callback)->all();
+
+ return $this;
+ }
+
+ /**
+ * Flatten a multi-dimensional associative array with dots.
+ *
+ * @return static
+ */
+ public function dot()
+ {
+ return new static(Arr::dot($this->all()));
+ }
+
+ /**
+ * Convert a flatten "dot" notation array into an expanded array.
+ *
+ * @return static
+ */
+ public function undot()
+ {
+ return new static(Arr::undot($this->all()));
+ }
+
+ /**
+ * Return only unique items from the collection array.
+ *
+ * @param (callable(TValue, TKey): mixed)|string|null $key
+ * @param bool $strict
+ * @return static
+ */
+ public function unique($key = null, $strict = false)
+ {
+ if (is_null($key) && $strict === false) {
+ return new static(array_unique($this->items, SORT_REGULAR));
+ }
+
+ $callback = $this->valueRetriever($key);
+
+ $exists = [];
+
+ return $this->reject(function ($item, $key) use ($callback, $strict, &$exists) {
+ if (in_array($id = $callback($item, $key), $exists, $strict)) {
+ return true;
+ }
+
+ $exists[] = $id;
+ });
+ }
+
+ /**
+ * Reset the keys on the underlying array.
+ *
+ * @return static<int, TValue>
+ */
+ public function values()
+ {
+ return new static(array_values($this->items));
+ }
+
+ /**
+ * Zip the collection together with one or more arrays.
+ *
+ * e.g. new Collection([1, 2, 3])->zip([4, 5, 6]);
+ * => [[1, 4], [2, 5], [3, 6]]
+ *
+ * @template TZipValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TZipValue>|iterable<array-key, TZipValue> ...$items
+ * @return static<int, static<int, TValue|TZipValue>>
+ */
+ public function zip($items)
+ {
+ $arrayableItems = array_map(fn ($items) => $this->getArrayableItems($items), func_get_args());
+
+ $params = array_merge([fn () => new static(func_get_args()), $this->items], $arrayableItems);
+
+ return new static(array_map(...$params));
+ }
+
+ /**
+ * Pad collection to the specified length with a value.
+ *
+ * @template TPadValue
+ *
+ * @param int $size
+ * @param TPadValue $value
+ * @return static<int, TValue|TPadValue>
+ */
+ public function pad($size, $value)
+ {
+ return new static(array_pad($this->items, $size, $value));
+ }
+
+ /**
+ * Get an iterator for the items.
+ *
+ * @return \ArrayIterator<TKey, TValue>
+ */
+ public function getIterator(): Traversable
+ {
+ return new ArrayIterator($this->items);
+ }
+
+ /**
+ * Count the number of items in the collection.
+ *
+ * @return int
+ */
+ public function count(): int
+ {
+ return count($this->items);
+ }
+
+ /**
+ * Count the number of items in the collection by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|string|null $countBy
+ * @return static<array-key, int>
+ */
+ public function countBy($countBy = null)
+ {
+ return new static($this->lazy()->countBy($countBy)->all());
+ }
+
+ /**
+ * Add an item to the collection.
+ *
+ * @param TValue $item
+ * @return $this
+ */
+ public function add($item)
+ {
+ $this->items[] = $item;
+
+ return $this;
+ }
+
+ /**
+ * Get a base Support collection instance from this collection.
+ *
+ * @return \Illuminate\Support\Collection<TKey, TValue>
+ */
+ public function toBase()
+ {
+ return new self($this);
+ }
+
+ /**
+ * Determine if an item exists at an offset.
+ *
+ * @param TKey $key
+ * @return bool
+ */
+ public function offsetExists($key): bool
+ {
+ return isset($this->items[$key]);
+ }
+
+ /**
+ * Get an item at a given offset.
+ *
+ * @param TKey $key
+ * @return TValue
+ */
+ public function offsetGet($key): mixed
+ {
+ return $this->items[$key];
+ }
+
+ /**
+ * Set the item at a given offset.
+ *
+ * @param TKey|null $key
+ * @param TValue $value
+ * @return void
+ */
+ public function offsetSet($key, $value): void
+ {
+ if (is_null($key)) {
+ $this->items[] = $value;
+ } else {
+ $this->items[$key] = $value;
+ }
+ }
+
+ /**
+ * Unset the item at a given offset.
+ *
+ * @param TKey $key
+ * @return void
+ */
+ public function offsetUnset($key): void
+ {
+ unset($this->items[$key]);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Enumerable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Enumerable.php
new file mode 100644
index 0000000..806a692
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Enumerable.php
@@ -0,0 +1,1263 @@
+<?php
+
+namespace Illuminate\Support;
+
+use CachingIterator;
+use Countable;
+use Illuminate\Contracts\Support\Arrayable;
+use Illuminate\Contracts\Support\Jsonable;
+use IteratorAggregate;
+use JsonSerializable;
+use Traversable;
+
+/**
+ * @template TKey of array-key
+ *
+ * @template-covariant TValue
+ *
+ * @extends \Illuminate\Contracts\Support\Arrayable<TKey, TValue>
+ * @extends \IteratorAggregate<TKey, TValue>
+ */
+interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, JsonSerializable
+{
+ /**
+ * Create a new collection instance if the value isn't one already.
+ *
+ * @template TMakeKey of array-key
+ * @template TMakeValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TMakeKey, TMakeValue>|iterable<TMakeKey, TMakeValue>|null $items
+ * @return static<TMakeKey, TMakeValue>
+ */
+ public static function make($items = []);
+
+ /**
+ * Create a new instance by invoking the callback a given amount of times.
+ *
+ * @param int $number
+ * @param callable|null $callback
+ * @return static
+ */
+ public static function times($number, ?callable $callback = null);
+
+ /**
+ * Create a collection with the given range.
+ *
+ * @param int $from
+ * @param int $to
+ * @return static
+ */
+ public static function range($from, $to);
+
+ /**
+ * Wrap the given value in a collection if applicable.
+ *
+ * @template TWrapValue
+ *
+ * @param iterable<array-key, TWrapValue>|TWrapValue $value
+ * @return static<array-key, TWrapValue>
+ */
+ public static function wrap($value);
+
+ /**
+ * Get the underlying items from the given collection if applicable.
+ *
+ * @template TUnwrapKey of array-key
+ * @template TUnwrapValue
+ *
+ * @param array<TUnwrapKey, TUnwrapValue>|static<TUnwrapKey, TUnwrapValue> $value
+ * @return array<TUnwrapKey, TUnwrapValue>
+ */
+ public static function unwrap($value);
+
+ /**
+ * Create a new instance with no items.
+ *
+ * @return static
+ */
+ public static function empty();
+
+ /**
+ * Get all items in the enumerable.
+ *
+ * @return array
+ */
+ public function all();
+
+ /**
+ * Alias for the "avg" method.
+ *
+ * @param (callable(TValue): float|int)|string|null $callback
+ * @return float|int|null
+ */
+ public function average($callback = null);
+
+ /**
+ * Get the median of a given key.
+ *
+ * @param string|array<array-key, string>|null $key
+ * @return float|int|null
+ */
+ public function median($key = null);
+
+ /**
+ * Get the mode of a given key.
+ *
+ * @param string|array<array-key, string>|null $key
+ * @return array<int, float|int>|null
+ */
+ public function mode($key = null);
+
+ /**
+ * Collapse the items into a single enumerable.
+ *
+ * @return static<int, mixed>
+ */
+ public function collapse();
+
+ /**
+ * Alias for the "contains" method.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function some($key, $operator = null, $value = null);
+
+ /**
+ * Determine if an item exists, using strict comparison.
+ *
+ * @param (callable(TValue): bool)|TValue|array-key $key
+ * @param TValue|null $value
+ * @return bool
+ */
+ public function containsStrict($key, $value = null);
+
+ /**
+ * Get the average value of a given key.
+ *
+ * @param (callable(TValue): float|int)|string|null $callback
+ * @return float|int|null
+ */
+ public function avg($callback = null);
+
+ /**
+ * Determine if an item exists in the enumerable.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function contains($key, $operator = null, $value = null);
+
+ /**
+ * Determine if an item is not contained in the collection.
+ *
+ * @param mixed $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function doesntContain($key, $operator = null, $value = null);
+
+ /**
+ * Cross join with the given lists, returning all possible permutations.
+ *
+ * @template TCrossJoinKey
+ * @template TCrossJoinValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TCrossJoinKey, TCrossJoinValue>|iterable<TCrossJoinKey, TCrossJoinValue> ...$lists
+ * @return static<int, array<int, TValue|TCrossJoinValue>>
+ */
+ public function crossJoin(...$lists);
+
+ /**
+ * Dump the collection and end the script.
+ *
+ * @param mixed ...$args
+ * @return never
+ */
+ public function dd(...$args);
+
+ /**
+ * Dump the collection.
+ *
+ * @return $this
+ */
+ public function dump();
+
+ /**
+ * Get the items that are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @return static
+ */
+ public function diff($items);
+
+ /**
+ * Get the items that are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @param callable(TValue, TValue): int $callback
+ * @return static
+ */
+ public function diffUsing($items, callable $callback);
+
+ /**
+ * Get the items whose keys and values are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function diffAssoc($items);
+
+ /**
+ * Get the items whose keys and values are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function diffAssocUsing($items, callable $callback);
+
+ /**
+ * Get the items whose keys are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function diffKeys($items);
+
+ /**
+ * Get the items whose keys are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function diffKeysUsing($items, callable $callback);
+
+ /**
+ * Retrieve duplicate items.
+ *
+ * @param (callable(TValue): bool)|string|null $callback
+ * @param bool $strict
+ * @return static
+ */
+ public function duplicates($callback = null, $strict = false);
+
+ /**
+ * Retrieve duplicate items using strict comparison.
+ *
+ * @param (callable(TValue): bool)|string|null $callback
+ * @return static
+ */
+ public function duplicatesStrict($callback = null);
+
+ /**
+ * Execute a callback over each item.
+ *
+ * @param callable(TValue, TKey): mixed $callback
+ * @return $this
+ */
+ public function each(callable $callback);
+
+ /**
+ * Execute a callback over each nested chunk of items.
+ *
+ * @param callable $callback
+ * @return static
+ */
+ public function eachSpread(callable $callback);
+
+ /**
+ * Determine if all items pass the given truth test.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function every($key, $operator = null, $value = null);
+
+ /**
+ * Get all items except for those with the specified keys.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey> $keys
+ * @return static
+ */
+ public function except($keys);
+
+ /**
+ * Run a filter over each of the items.
+ *
+ * @param (callable(TValue): bool)|null $callback
+ * @return static
+ */
+ public function filter(?callable $callback = null);
+
+ /**
+ * Apply the callback if the given "value" is (or resolves to) truthy.
+ *
+ * @template TWhenReturnType as null
+ *
+ * @param bool $value
+ * @param (callable($this): TWhenReturnType)|null $callback
+ * @param (callable($this): TWhenReturnType)|null $default
+ * @return $this|TWhenReturnType
+ */
+ public function when($value, ?callable $callback = null, ?callable $default = null);
+
+ /**
+ * Apply the callback if the collection is empty.
+ *
+ * @template TWhenEmptyReturnType
+ *
+ * @param (callable($this): TWhenEmptyReturnType) $callback
+ * @param (callable($this): TWhenEmptyReturnType)|null $default
+ * @return $this|TWhenEmptyReturnType
+ */
+ public function whenEmpty(callable $callback, ?callable $default = null);
+
+ /**
+ * Apply the callback if the collection is not empty.
+ *
+ * @template TWhenNotEmptyReturnType
+ *
+ * @param callable($this): TWhenNotEmptyReturnType $callback
+ * @param (callable($this): TWhenNotEmptyReturnType)|null $default
+ * @return $this|TWhenNotEmptyReturnType
+ */
+ public function whenNotEmpty(callable $callback, ?callable $default = null);
+
+ /**
+ * Apply the callback if the given "value" is (or resolves to) truthy.
+ *
+ * @template TUnlessReturnType
+ *
+ * @param bool $value
+ * @param (callable($this): TUnlessReturnType) $callback
+ * @param (callable($this): TUnlessReturnType)|null $default
+ * @return $this|TUnlessReturnType
+ */
+ public function unless($value, callable $callback, ?callable $default = null);
+
+ /**
+ * Apply the callback unless the collection is empty.
+ *
+ * @template TUnlessEmptyReturnType
+ *
+ * @param callable($this): TUnlessEmptyReturnType $callback
+ * @param (callable($this): TUnlessEmptyReturnType)|null $default
+ * @return $this|TUnlessEmptyReturnType
+ */
+ public function unlessEmpty(callable $callback, ?callable $default = null);
+
+ /**
+ * Apply the callback unless the collection is not empty.
+ *
+ * @template TUnlessNotEmptyReturnType
+ *
+ * @param callable($this): TUnlessNotEmptyReturnType $callback
+ * @param (callable($this): TUnlessNotEmptyReturnType)|null $default
+ * @return $this|TUnlessNotEmptyReturnType
+ */
+ public function unlessNotEmpty(callable $callback, ?callable $default = null);
+
+ /**
+ * Filter items by the given key value pair.
+ *
+ * @param string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return static
+ */
+ public function where($key, $operator = null, $value = null);
+
+ /**
+ * Filter items where the value for the given key is null.
+ *
+ * @param string|null $key
+ * @return static
+ */
+ public function whereNull($key = null);
+
+ /**
+ * Filter items where the value for the given key is not null.
+ *
+ * @param string|null $key
+ * @return static
+ */
+ public function whereNotNull($key = null);
+
+ /**
+ * Filter items by the given key value pair using strict comparison.
+ *
+ * @param string $key
+ * @param mixed $value
+ * @return static
+ */
+ public function whereStrict($key, $value);
+
+ /**
+ * Filter items by the given key value pair.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @param bool $strict
+ * @return static
+ */
+ public function whereIn($key, $values, $strict = false);
+
+ /**
+ * Filter items by the given key value pair using strict comparison.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereInStrict($key, $values);
+
+ /**
+ * Filter items such that the value of the given key is between the given values.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereBetween($key, $values);
+
+ /**
+ * Filter items such that the value of the given key is not between the given values.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereNotBetween($key, $values);
+
+ /**
+ * Filter items by the given key value pair.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @param bool $strict
+ * @return static
+ */
+ public function whereNotIn($key, $values, $strict = false);
+
+ /**
+ * Filter items by the given key value pair using strict comparison.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereNotInStrict($key, $values);
+
+ /**
+ * Filter the items, removing any items that don't match the given type(s).
+ *
+ * @template TWhereInstanceOf
+ *
+ * @param class-string<TWhereInstanceOf>|array<array-key, class-string<TWhereInstanceOf>> $type
+ * @return static<TKey, TWhereInstanceOf>
+ */
+ public function whereInstanceOf($type);
+
+ /**
+ * Get the first item from the enumerable passing the given truth test.
+ *
+ * @template TFirstDefault
+ *
+ * @param (callable(TValue,TKey): bool)|null $callback
+ * @param TFirstDefault|(\Closure(): TFirstDefault) $default
+ * @return TValue|TFirstDefault
+ */
+ public function first(?callable $callback = null, $default = null);
+
+ /**
+ * Get the first item by the given key value pair.
+ *
+ * @param string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue|null
+ */
+ public function firstWhere($key, $operator = null, $value = null);
+
+ /**
+ * Get a flattened array of the items in the collection.
+ *
+ * @param int $depth
+ * @return static
+ */
+ public function flatten($depth = INF);
+
+ /**
+ * Flip the values with their keys.
+ *
+ * @return static<TValue, TKey>
+ */
+ public function flip();
+
+ /**
+ * Get an item from the collection by key.
+ *
+ * @template TGetDefault
+ *
+ * @param TKey $key
+ * @param TGetDefault|(\Closure(): TGetDefault) $default
+ * @return TValue|TGetDefault
+ */
+ public function get($key, $default = null);
+
+ /**
+ * Group an associative array by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|array|string $groupBy
+ * @param bool $preserveKeys
+ * @return static<array-key, static<array-key, TValue>>
+ */
+ public function groupBy($groupBy, $preserveKeys = false);
+
+ /**
+ * Key an associative array by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|array|string $keyBy
+ * @return static<array-key, TValue>
+ */
+ public function keyBy($keyBy);
+
+ /**
+ * Determine if an item exists in the collection by key.
+ *
+ * @param TKey|array<array-key, TKey> $key
+ * @return bool
+ */
+ public function has($key);
+
+ /**
+ * Determine if any of the keys exist in the collection.
+ *
+ * @param mixed $key
+ * @return bool
+ */
+ public function hasAny($key);
+
+ /**
+ * Concatenate values of a given key as a string.
+ *
+ * @param callable|string $value
+ * @param string|null $glue
+ * @return string
+ */
+ public function implode($value, $glue = null);
+
+ /**
+ * Intersect the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersect($items);
+
+ /**
+ * Intersect the collection with the given items by key.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersectByKeys($items);
+
+ /**
+ * Determine if the collection is empty or not.
+ *
+ * @return bool
+ */
+ public function isEmpty();
+
+ /**
+ * Determine if the collection is not empty.
+ *
+ * @return bool
+ */
+ public function isNotEmpty();
+
+ /**
+ * Determine if the collection contains a single item.
+ *
+ * @return bool
+ */
+ public function containsOneItem();
+
+ /**
+ * Join all items from the collection using a string. The final items can use a separate glue string.
+ *
+ * @param string $glue
+ * @param string $finalGlue
+ * @return string
+ */
+ public function join($glue, $finalGlue = '');
+
+ /**
+ * Get the keys of the collection items.
+ *
+ * @return static<int, TKey>
+ */
+ public function keys();
+
+ /**
+ * Get the last item from the collection.
+ *
+ * @template TLastDefault
+ *
+ * @param (callable(TValue, TKey): bool)|null $callback
+ * @param TLastDefault|(\Closure(): TLastDefault) $default
+ * @return TValue|TLastDefault
+ */
+ public function last(?callable $callback = null, $default = null);
+
+ /**
+ * Run a map over each of the items.
+ *
+ * @template TMapValue
+ *
+ * @param callable(TValue, TKey): TMapValue $callback
+ * @return static<TKey, TMapValue>
+ */
+ public function map(callable $callback);
+
+ /**
+ * Run a map over each nested chunk of items.
+ *
+ * @param callable $callback
+ * @return static
+ */
+ public function mapSpread(callable $callback);
+
+ /**
+ * Run a dictionary map over the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapToDictionaryKey of array-key
+ * @template TMapToDictionaryValue
+ *
+ * @param callable(TValue, TKey): array<TMapToDictionaryKey, TMapToDictionaryValue> $callback
+ * @return static<TMapToDictionaryKey, array<int, TMapToDictionaryValue>>
+ */
+ public function mapToDictionary(callable $callback);
+
+ /**
+ * Run a grouping map over the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapToGroupsKey of array-key
+ * @template TMapToGroupsValue
+ *
+ * @param callable(TValue, TKey): array<TMapToGroupsKey, TMapToGroupsValue> $callback
+ * @return static<TMapToGroupsKey, static<int, TMapToGroupsValue>>
+ */
+ public function mapToGroups(callable $callback);
+
+ /**
+ * Run an associative map over each of the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapWithKeysKey of array-key
+ * @template TMapWithKeysValue
+ *
+ * @param callable(TValue, TKey): array<TMapWithKeysKey, TMapWithKeysValue> $callback
+ * @return static<TMapWithKeysKey, TMapWithKeysValue>
+ */
+ public function mapWithKeys(callable $callback);
+
+ /**
+ * Map a collection and flatten the result by a single level.
+ *
+ * @template TFlatMapKey of array-key
+ * @template TFlatMapValue
+ *
+ * @param callable(TValue, TKey): (\Illuminate\Support\Collection<TFlatMapKey, TFlatMapValue>|array<TFlatMapKey, TFlatMapValue>) $callback
+ * @return static<TFlatMapKey, TFlatMapValue>
+ */
+ public function flatMap(callable $callback);
+
+ /**
+ * Map the values into a new class.
+ *
+ * @template TMapIntoValue
+ *
+ * @param class-string<TMapIntoValue> $class
+ * @return static<TKey, TMapIntoValue>
+ */
+ public function mapInto($class);
+
+ /**
+ * Merge the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function merge($items);
+
+ /**
+ * Recursively merge the collection with the given items.
+ *
+ * @template TMergeRecursiveValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TMergeRecursiveValue>|iterable<TKey, TMergeRecursiveValue> $items
+ * @return static<TKey, TValue|TMergeRecursiveValue>
+ */
+ public function mergeRecursive($items);
+
+ /**
+ * Create a collection by using this collection for keys and another for its values.
+ *
+ * @template TCombineValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TCombineValue>|iterable<array-key, TCombineValue> $values
+ * @return static<TValue, TCombineValue>
+ */
+ public function combine($values);
+
+ /**
+ * Union the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function union($items);
+
+ /**
+ * Get the min value of a given key.
+ *
+ * @param (callable(TValue):mixed)|string|null $callback
+ * @return mixed
+ */
+ public function min($callback = null);
+
+ /**
+ * Get the max value of a given key.
+ *
+ * @param (callable(TValue):mixed)|string|null $callback
+ * @return mixed
+ */
+ public function max($callback = null);
+
+ /**
+ * Create a new collection consisting of every n-th element.
+ *
+ * @param int $step
+ * @param int $offset
+ * @return static
+ */
+ public function nth($step, $offset = 0);
+
+ /**
+ * Get the items with the specified keys.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey>|string $keys
+ * @return static
+ */
+ public function only($keys);
+
+ /**
+ * "Paginate" the collection by slicing it into a smaller collection.
+ *
+ * @param int $page
+ * @param int $perPage
+ * @return static
+ */
+ public function forPage($page, $perPage);
+
+ /**
+ * Partition the collection into two arrays using the given callback or key.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return static<int<0, 1>, static<TKey, TValue>>
+ */
+ public function partition($key, $operator = null, $value = null);
+
+ /**
+ * Push all of the given items onto the collection.
+ *
+ * @template TConcatKey of array-key
+ * @template TConcatValue
+ *
+ * @param iterable<TConcatKey, TConcatValue> $source
+ * @return static<TKey|TConcatKey, TValue|TConcatValue>
+ */
+ public function concat($source);
+
+ /**
+ * Get one or a specified number of items randomly from the collection.
+ *
+ * @param int|null $number
+ * @return static<int, TValue>|TValue
+ *
+ * @throws \InvalidArgumentException
+ */
+ public function random($number = null);
+
+ /**
+ * Reduce the collection to a single value.
+ *
+ * @template TReduceInitial
+ * @template TReduceReturnType
+ *
+ * @param callable(TReduceInitial|TReduceReturnType, TValue, TKey): TReduceReturnType $callback
+ * @param TReduceInitial $initial
+ * @return TReduceReturnType
+ */
+ public function reduce(callable $callback, $initial = null);
+
+ /**
+ * Reduce the collection to multiple aggregate values.
+ *
+ * @param callable $callback
+ * @param mixed ...$initial
+ * @return array
+ *
+ * @throws \UnexpectedValueException
+ */
+ public function reduceSpread(callable $callback, ...$initial);
+
+ /**
+ * Replace the collection items with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function replace($items);
+
+ /**
+ * Recursively replace the collection items with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function replaceRecursive($items);
+
+ /**
+ * Reverse items order.
+ *
+ * @return static
+ */
+ public function reverse();
+
+ /**
+ * Search the collection for a given value and return the corresponding key if successful.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @param bool $strict
+ * @return TKey|bool
+ */
+ public function search($value, $strict = false);
+
+ /**
+ * Shuffle the items in the collection.
+ *
+ * @param int|null $seed
+ * @return static
+ */
+ public function shuffle($seed = null);
+
+ /**
+ * Create chunks representing a "sliding window" view of the items in the collection.
+ *
+ * @param int $size
+ * @param int $step
+ * @return static<int, static>
+ */
+ public function sliding($size = 2, $step = 1);
+
+ /**
+ * Skip the first {$count} items.
+ *
+ * @param int $count
+ * @return static
+ */
+ public function skip($count);
+
+ /**
+ * Skip items in the collection until the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function skipUntil($value);
+
+ /**
+ * Skip items in the collection while the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function skipWhile($value);
+
+ /**
+ * Get a slice of items from the enumerable.
+ *
+ * @param int $offset
+ * @param int|null $length
+ * @return static
+ */
+ public function slice($offset, $length = null);
+
+ /**
+ * Split a collection into a certain number of groups.
+ *
+ * @param int $numberOfGroups
+ * @return static<int, static>
+ */
+ public function split($numberOfGroups);
+
+ /**
+ * Get the first item in the collection, but only if exactly one item exists. Otherwise, throw an exception.
+ *
+ * @param (callable(TValue, TKey): bool)|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue
+ *
+ * @throws \Illuminate\Support\ItemNotFoundException
+ * @throws \Illuminate\Support\MultipleItemsFoundException
+ */
+ public function sole($key = null, $operator = null, $value = null);
+
+ /**
+ * Get the first item in the collection but throw an exception if no matching items exist.
+ *
+ * @param (callable(TValue, TKey): bool)|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue
+ *
+ * @throws \Illuminate\Support\ItemNotFoundException
+ */
+ public function firstOrFail($key = null, $operator = null, $value = null);
+
+ /**
+ * Chunk the collection into chunks of the given size.
+ *
+ * @param int $size
+ * @return static<int, static>
+ */
+ public function chunk($size);
+
+ /**
+ * Chunk the collection into chunks with a callback.
+ *
+ * @param callable(TValue, TKey, static<int, TValue>): bool $callback
+ * @return static<int, static<int, TValue>>
+ */
+ public function chunkWhile(callable $callback);
+
+ /**
+ * Split a collection into a certain number of groups, and fill the first groups completely.
+ *
+ * @param int $numberOfGroups
+ * @return static<int, static>
+ */
+ public function splitIn($numberOfGroups);
+
+ /**
+ * Sort through each item with a callback.
+ *
+ * @param (callable(TValue, TValue): int)|null|int $callback
+ * @return static
+ */
+ public function sort($callback = null);
+
+ /**
+ * Sort items in descending order.
+ *
+ * @param int $options
+ * @return static
+ */
+ public function sortDesc($options = SORT_REGULAR);
+
+ /**
+ * Sort the collection using the given callback.
+ *
+ * @param array<array-key, (callable(TValue, TValue): mixed)|(callable(TValue, TKey): mixed)|string|array{string, string}>|(callable(TValue, TKey): mixed)|string $callback
+ * @param int $options
+ * @param bool $descending
+ * @return static
+ */
+ public function sortBy($callback, $options = SORT_REGULAR, $descending = false);
+
+ /**
+ * Sort the collection in descending order using the given callback.
+ *
+ * @param array<array-key, (callable(TValue, TValue): mixed)|(callable(TValue, TKey): mixed)|string|array{string, string}>|(callable(TValue, TKey): mixed)|string $callback
+ * @param int $options
+ * @return static
+ */
+ public function sortByDesc($callback, $options = SORT_REGULAR);
+
+ /**
+ * Sort the collection keys.
+ *
+ * @param int $options
+ * @param bool $descending
+ * @return static
+ */
+ public function sortKeys($options = SORT_REGULAR, $descending = false);
+
+ /**
+ * Sort the collection keys in descending order.
+ *
+ * @param int $options
+ * @return static
+ */
+ public function sortKeysDesc($options = SORT_REGULAR);
+
+ /**
+ * Sort the collection keys using a callback.
+ *
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function sortKeysUsing(callable $callback);
+
+ /**
+ * Get the sum of the given values.
+ *
+ * @param (callable(TValue): mixed)|string|null $callback
+ * @return mixed
+ */
+ public function sum($callback = null);
+
+ /**
+ * Take the first or last {$limit} items.
+ *
+ * @param int $limit
+ * @return static
+ */
+ public function take($limit);
+
+ /**
+ * Take items in the collection until the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function takeUntil($value);
+
+ /**
+ * Take items in the collection while the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function takeWhile($value);
+
+ /**
+ * Pass the collection to the given callback and then return it.
+ *
+ * @param callable(TValue): mixed $callback
+ * @return $this
+ */
+ public function tap(callable $callback);
+
+ /**
+ * Pass the enumerable to the given callback and return the result.
+ *
+ * @template TPipeReturnType
+ *
+ * @param callable($this): TPipeReturnType $callback
+ * @return TPipeReturnType
+ */
+ public function pipe(callable $callback);
+
+ /**
+ * Pass the collection into a new class.
+ *
+ * @template TPipeIntoValue
+ *
+ * @param class-string<TPipeIntoValue> $class
+ * @return TPipeIntoValue
+ */
+ public function pipeInto($class);
+
+ /**
+ * Pass the collection through a series of callable pipes and return the result.
+ *
+ * @param array<callable> $pipes
+ * @return mixed
+ */
+ public function pipeThrough($pipes);
+
+ /**
+ * Get the values of a given key.
+ *
+ * @param string|array<array-key, string> $value
+ * @param string|null $key
+ * @return static<int, mixed>
+ */
+ public function pluck($value, $key = null);
+
+ /**
+ * Create a collection of all elements that do not pass a given truth test.
+ *
+ * @param (callable(TValue, TKey): bool)|bool|TValue $callback
+ * @return static
+ */
+ public function reject($callback = true);
+
+ /**
+ * Convert a flatten "dot" notation array into an expanded array.
+ *
+ * @return static
+ */
+ public function undot();
+
+ /**
+ * Return only unique items from the collection array.
+ *
+ * @param (callable(TValue, TKey): mixed)|string|null $key
+ * @param bool $strict
+ * @return static
+ */
+ public function unique($key = null, $strict = false);
+
+ /**
+ * Return only unique items from the collection array using strict comparison.
+ *
+ * @param (callable(TValue, TKey): mixed)|string|null $key
+ * @return static
+ */
+ public function uniqueStrict($key = null);
+
+ /**
+ * Reset the keys on the underlying array.
+ *
+ * @return static<int, TValue>
+ */
+ public function values();
+
+ /**
+ * Pad collection to the specified length with a value.
+ *
+ * @template TPadValue
+ *
+ * @param int $size
+ * @param TPadValue $value
+ * @return static<int, TValue|TPadValue>
+ */
+ public function pad($size, $value);
+
+ /**
+ * Get the values iterator.
+ *
+ * @return \Traversable<TKey, TValue>
+ */
+ public function getIterator(): Traversable;
+
+ /**
+ * Count the number of items in the collection.
+ *
+ * @return int
+ */
+ public function count(): int;
+
+ /**
+ * Count the number of items in the collection by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|string|null $countBy
+ * @return static<array-key, int>
+ */
+ public function countBy($countBy = null);
+
+ /**
+ * Zip the collection together with one or more arrays.
+ *
+ * e.g. new Collection([1, 2, 3])->zip([4, 5, 6]);
+ * => [[1, 4], [2, 5], [3, 6]]
+ *
+ * @template TZipValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TZipValue>|iterable<array-key, TZipValue> ...$items
+ * @return static<int, static<int, TValue|TZipValue>>
+ */
+ public function zip($items);
+
+ /**
+ * Collect the values into a collection.
+ *
+ * @return \Illuminate\Support\Collection<TKey, TValue>
+ */
+ public function collect();
+
+ /**
+ * Get the collection of items as a plain array.
+ *
+ * @return array<TKey, mixed>
+ */
+ public function toArray();
+
+ /**
+ * Convert the object into something JSON serializable.
+ *
+ * @return mixed
+ */
+ public function jsonSerialize(): mixed;
+
+ /**
+ * Get the collection of items as JSON.
+ *
+ * @param int $options
+ * @return string
+ */
+ public function toJson($options = 0);
+
+ /**
+ * Get a CachingIterator instance.
+ *
+ * @param int $flags
+ * @return \CachingIterator
+ */
+ public function getCachingIterator($flags = CachingIterator::CALL_TOSTRING);
+
+ /**
+ * Convert the collection to its string representation.
+ *
+ * @return string
+ */
+ public function __toString();
+
+ /**
+ * Indicate that the model's string representation should be escaped when __toString is invoked.
+ *
+ * @param bool $escape
+ * @return $this
+ */
+ public function escapeWhenCastingToString($escape = true);
+
+ /**
+ * Add a method to the list of proxied methods.
+ *
+ * @param string $method
+ * @return void
+ */
+ public static function proxy($method);
+
+ /**
+ * Dynamically access collection proxies.
+ *
+ * @param string $key
+ * @return mixed
+ *
+ * @throws \Exception
+ */
+ public function __get($key);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/HigherOrderCollectionProxy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/HigherOrderCollectionProxy.php
new file mode 100644
index 0000000..106356c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/HigherOrderCollectionProxy.php
@@ -0,0 +1,63 @@
+<?php
+
+namespace Illuminate\Support;
+
+/**
+ * @mixin \Illuminate\Support\Enumerable
+ */
+class HigherOrderCollectionProxy
+{
+ /**
+ * The collection being operated on.
+ *
+ * @var \Illuminate\Support\Enumerable
+ */
+ protected $collection;
+
+ /**
+ * The method being proxied.
+ *
+ * @var string
+ */
+ protected $method;
+
+ /**
+ * Create a new proxy instance.
+ *
+ * @param \Illuminate\Support\Enumerable $collection
+ * @param string $method
+ * @return void
+ */
+ public function __construct(Enumerable $collection, $method)
+ {
+ $this->method = $method;
+ $this->collection = $collection;
+ }
+
+ /**
+ * Proxy accessing an attribute onto the collection items.
+ *
+ * @param string $key
+ * @return mixed
+ */
+ public function __get($key)
+ {
+ return $this->collection->{$this->method}(function ($value) use ($key) {
+ return is_array($value) ? $value[$key] : $value->{$key};
+ });
+ }
+
+ /**
+ * Proxy a method call onto the collection items.
+ *
+ * @param string $method
+ * @param array $parameters
+ * @return mixed
+ */
+ public function __call($method, $parameters)
+ {
+ return $this->collection->{$this->method}(function ($value) use ($method, $parameters) {
+ return $value->{$method}(...$parameters);
+ });
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/ItemNotFoundException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/ItemNotFoundException.php
new file mode 100644
index 0000000..05a51d9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/ItemNotFoundException.php
@@ -0,0 +1,9 @@
+<?php
+
+namespace Illuminate\Support;
+
+use RuntimeException;
+
+class ItemNotFoundException extends RuntimeException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/LICENSE.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/LICENSE.md
new file mode 100644
index 0000000..79810c8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/LICENSE.md
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Taylor Otwell
+
+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/illuminate/collections/LazyCollection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/LazyCollection.php
new file mode 100644
index 0000000..cd268b7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/LazyCollection.php
@@ -0,0 +1,1785 @@
+<?php
+
+namespace Illuminate\Support;
+
+use ArrayIterator;
+use Closure;
+use DateTimeInterface;
+use Generator;
+use Illuminate\Contracts\Support\CanBeEscapedWhenCastToString;
+use Illuminate\Support\Traits\EnumeratesValues;
+use Illuminate\Support\Traits\Macroable;
+use InvalidArgumentException;
+use IteratorAggregate;
+use stdClass;
+use Traversable;
+
+/**
+ * @template TKey of array-key
+ *
+ * @template-covariant TValue
+ *
+ * @implements \Illuminate\Support\Enumerable<TKey, TValue>
+ */
+class LazyCollection implements CanBeEscapedWhenCastToString, Enumerable
+{
+ /**
+ * @use \Illuminate\Support\Traits\EnumeratesValues<TKey, TValue>
+ */
+ use EnumeratesValues, Macroable;
+
+ /**
+ * The source from which to generate items.
+ *
+ * @var (Closure(): \Generator<TKey, TValue, mixed, void>)|static|array<TKey, TValue>
+ */
+ public $source;
+
+ /**
+ * Create a new lazy collection instance.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue>|(Closure(): \Generator<TKey, TValue, mixed, void>)|self<TKey, TValue>|array<TKey, TValue>|null $source
+ * @return void
+ */
+ public function __construct($source = null)
+ {
+ if ($source instanceof Closure || $source instanceof self) {
+ $this->source = $source;
+ } elseif (is_null($source)) {
+ $this->source = static::empty();
+ } elseif ($source instanceof Generator) {
+ throw new InvalidArgumentException(
+ 'Generators should not be passed directly to LazyCollection. Instead, pass a generator function.'
+ );
+ } else {
+ $this->source = $this->getArrayableItems($source);
+ }
+ }
+
+ /**
+ * Create a new collection instance if the value isn't one already.
+ *
+ * @template TMakeKey of array-key
+ * @template TMakeValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TMakeKey, TMakeValue>|iterable<TMakeKey, TMakeValue>|(Closure(): \Generator<TMakeKey, TMakeValue, mixed, void>)|self<TMakeKey, TMakeValue>|array<TMakeKey, TMakeValue>|null $items
+ * @return static<TMakeKey, TMakeValue>
+ */
+ public static function make($items = [])
+ {
+ return new static($items);
+ }
+
+ /**
+ * Create a collection with the given range.
+ *
+ * @param int $from
+ * @param int $to
+ * @return static<int, int>
+ */
+ public static function range($from, $to)
+ {
+ return new static(function () use ($from, $to) {
+ if ($from <= $to) {
+ for (; $from <= $to; $from++) {
+ yield $from;
+ }
+ } else {
+ for (; $from >= $to; $from--) {
+ yield $from;
+ }
+ }
+ });
+ }
+
+ /**
+ * Get all items in the enumerable.
+ *
+ * @return array<TKey, TValue>
+ */
+ public function all()
+ {
+ if (is_array($this->source)) {
+ return $this->source;
+ }
+
+ return iterator_to_array($this->getIterator());
+ }
+
+ /**
+ * Eager load all items into a new lazy collection backed by an array.
+ *
+ * @return static
+ */
+ public function eager()
+ {
+ return new static($this->all());
+ }
+
+ /**
+ * Cache values as they're enumerated.
+ *
+ * @return static
+ */
+ public function remember()
+ {
+ $iterator = $this->getIterator();
+
+ $iteratorIndex = 0;
+
+ $cache = [];
+
+ return new static(function () use ($iterator, &$iteratorIndex, &$cache) {
+ for ($index = 0; true; $index++) {
+ if (array_key_exists($index, $cache)) {
+ yield $cache[$index][0] => $cache[$index][1];
+
+ continue;
+ }
+
+ if ($iteratorIndex < $index) {
+ $iterator->next();
+
+ $iteratorIndex++;
+ }
+
+ if (! $iterator->valid()) {
+ break;
+ }
+
+ $cache[$index] = [$iterator->key(), $iterator->current()];
+
+ yield $cache[$index][0] => $cache[$index][1];
+ }
+ });
+ }
+
+ /**
+ * Get the average value of a given key.
+ *
+ * @param (callable(TValue): float|int)|string|null $callback
+ * @return float|int|null
+ */
+ public function avg($callback = null)
+ {
+ return $this->collect()->avg($callback);
+ }
+
+ /**
+ * Get the median of a given key.
+ *
+ * @param string|array<array-key, string>|null $key
+ * @return float|int|null
+ */
+ public function median($key = null)
+ {
+ return $this->collect()->median($key);
+ }
+
+ /**
+ * Get the mode of a given key.
+ *
+ * @param string|array<string>|null $key
+ * @return array<int, float|int>|null
+ */
+ public function mode($key = null)
+ {
+ return $this->collect()->mode($key);
+ }
+
+ /**
+ * Collapse the collection of items into a single array.
+ *
+ * @return static<int, mixed>
+ */
+ public function collapse()
+ {
+ return new static(function () {
+ foreach ($this as $values) {
+ if (is_array($values) || $values instanceof Enumerable) {
+ foreach ($values as $value) {
+ yield $value;
+ }
+ }
+ }
+ });
+ }
+
+ /**
+ * Determine if an item exists in the enumerable.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function contains($key, $operator = null, $value = null)
+ {
+ if (func_num_args() === 1 && $this->useAsCallable($key)) {
+ $placeholder = new stdClass;
+
+ /** @var callable $key */
+ return $this->first($key, $placeholder) !== $placeholder;
+ }
+
+ if (func_num_args() === 1) {
+ $needle = $key;
+
+ foreach ($this as $value) {
+ if ($value == $needle) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ return $this->contains($this->operatorForWhere(...func_get_args()));
+ }
+
+ /**
+ * Determine if an item exists, using strict comparison.
+ *
+ * @param (callable(TValue): bool)|TValue|array-key $key
+ * @param TValue|null $value
+ * @return bool
+ */
+ public function containsStrict($key, $value = null)
+ {
+ if (func_num_args() === 2) {
+ return $this->contains(fn ($item) => data_get($item, $key) === $value);
+ }
+
+ if ($this->useAsCallable($key)) {
+ return ! is_null($this->first($key));
+ }
+
+ foreach ($this as $item) {
+ if ($item === $key) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Determine if an item is not contained in the enumerable.
+ *
+ * @param mixed $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function doesntContain($key, $operator = null, $value = null)
+ {
+ return ! $this->contains(...func_get_args());
+ }
+
+ /**
+ * Cross join the given iterables, returning all possible permutations.
+ *
+ * @template TCrossJoinKey
+ * @template TCrossJoinValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TCrossJoinKey, TCrossJoinValue>|iterable<TCrossJoinKey, TCrossJoinValue> ...$arrays
+ * @return static<int, array<int, TValue|TCrossJoinValue>>
+ */
+ public function crossJoin(...$arrays)
+ {
+ return $this->passthru('crossJoin', func_get_args());
+ }
+
+ /**
+ * Count the number of items in the collection by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|string|null $countBy
+ * @return static<array-key, int>
+ */
+ public function countBy($countBy = null)
+ {
+ $countBy = is_null($countBy)
+ ? $this->identity()
+ : $this->valueRetriever($countBy);
+
+ return new static(function () use ($countBy) {
+ $counts = [];
+
+ foreach ($this as $key => $value) {
+ $group = $countBy($value, $key);
+
+ if (empty($counts[$group])) {
+ $counts[$group] = 0;
+ }
+
+ $counts[$group]++;
+ }
+
+ yield from $counts;
+ });
+ }
+
+ /**
+ * Get the items that are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @return static
+ */
+ public function diff($items)
+ {
+ return $this->passthru('diff', func_get_args());
+ }
+
+ /**
+ * Get the items that are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @param callable(TValue, TValue): int $callback
+ * @return static
+ */
+ public function diffUsing($items, callable $callback)
+ {
+ return $this->passthru('diffUsing', func_get_args());
+ }
+
+ /**
+ * Get the items whose keys and values are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function diffAssoc($items)
+ {
+ return $this->passthru('diffAssoc', func_get_args());
+ }
+
+ /**
+ * Get the items whose keys and values are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function diffAssocUsing($items, callable $callback)
+ {
+ return $this->passthru('diffAssocUsing', func_get_args());
+ }
+
+ /**
+ * Get the items whose keys are not present in the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function diffKeys($items)
+ {
+ return $this->passthru('diffKeys', func_get_args());
+ }
+
+ /**
+ * Get the items whose keys are not present in the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function diffKeysUsing($items, callable $callback)
+ {
+ return $this->passthru('diffKeysUsing', func_get_args());
+ }
+
+ /**
+ * Retrieve duplicate items.
+ *
+ * @param (callable(TValue): bool)|string|null $callback
+ * @param bool $strict
+ * @return static
+ */
+ public function duplicates($callback = null, $strict = false)
+ {
+ return $this->passthru('duplicates', func_get_args());
+ }
+
+ /**
+ * Retrieve duplicate items using strict comparison.
+ *
+ * @param (callable(TValue): bool)|string|null $callback
+ * @return static
+ */
+ public function duplicatesStrict($callback = null)
+ {
+ return $this->passthru('duplicatesStrict', func_get_args());
+ }
+
+ /**
+ * Get all items except for those with the specified keys.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey> $keys
+ * @return static
+ */
+ public function except($keys)
+ {
+ return $this->passthru('except', func_get_args());
+ }
+
+ /**
+ * Run a filter over each of the items.
+ *
+ * @param (callable(TValue, TKey): bool)|null $callback
+ * @return static
+ */
+ public function filter(?callable $callback = null)
+ {
+ if (is_null($callback)) {
+ $callback = fn ($value) => (bool) $value;
+ }
+
+ return new static(function () use ($callback) {
+ foreach ($this as $key => $value) {
+ if ($callback($value, $key)) {
+ yield $key => $value;
+ }
+ }
+ });
+ }
+
+ /**
+ * Get the first item from the enumerable passing the given truth test.
+ *
+ * @template TFirstDefault
+ *
+ * @param (callable(TValue): bool)|null $callback
+ * @param TFirstDefault|(\Closure(): TFirstDefault) $default
+ * @return TValue|TFirstDefault
+ */
+ public function first(?callable $callback = null, $default = null)
+ {
+ $iterator = $this->getIterator();
+
+ if (is_null($callback)) {
+ if (! $iterator->valid()) {
+ return value($default);
+ }
+
+ return $iterator->current();
+ }
+
+ foreach ($iterator as $key => $value) {
+ if ($callback($value, $key)) {
+ return $value;
+ }
+ }
+
+ return value($default);
+ }
+
+ /**
+ * Get a flattened list of the items in the collection.
+ *
+ * @param int $depth
+ * @return static<int, mixed>
+ */
+ public function flatten($depth = INF)
+ {
+ $instance = new static(function () use ($depth) {
+ foreach ($this as $item) {
+ if (! is_array($item) && ! $item instanceof Enumerable) {
+ yield $item;
+ } elseif ($depth === 1) {
+ yield from $item;
+ } else {
+ yield from (new static($item))->flatten($depth - 1);
+ }
+ }
+ });
+
+ return $instance->values();
+ }
+
+ /**
+ * Flip the items in the collection.
+ *
+ * @return static<TValue, TKey>
+ */
+ public function flip()
+ {
+ return new static(function () {
+ foreach ($this as $key => $value) {
+ yield $value => $key;
+ }
+ });
+ }
+
+ /**
+ * Get an item by key.
+ *
+ * @template TGetDefault
+ *
+ * @param TKey|null $key
+ * @param TGetDefault|(\Closure(): TGetDefault) $default
+ * @return TValue|TGetDefault
+ */
+ public function get($key, $default = null)
+ {
+ if (is_null($key)) {
+ return;
+ }
+
+ foreach ($this as $outerKey => $outerValue) {
+ if ($outerKey == $key) {
+ return $outerValue;
+ }
+ }
+
+ return value($default);
+ }
+
+ /**
+ * Group an associative array by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|array|string $groupBy
+ * @param bool $preserveKeys
+ * @return static<array-key, static<array-key, TValue>>
+ */
+ public function groupBy($groupBy, $preserveKeys = false)
+ {
+ return $this->passthru('groupBy', func_get_args());
+ }
+
+ /**
+ * Key an associative array by a field or using a callback.
+ *
+ * @param (callable(TValue, TKey): array-key)|array|string $keyBy
+ * @return static<array-key, TValue>
+ */
+ public function keyBy($keyBy)
+ {
+ return new static(function () use ($keyBy) {
+ $keyBy = $this->valueRetriever($keyBy);
+
+ foreach ($this as $key => $item) {
+ $resolvedKey = $keyBy($item, $key);
+
+ if (is_object($resolvedKey)) {
+ $resolvedKey = (string) $resolvedKey;
+ }
+
+ yield $resolvedKey => $item;
+ }
+ });
+ }
+
+ /**
+ * Determine if an item exists in the collection by key.
+ *
+ * @param mixed $key
+ * @return bool
+ */
+ public function has($key)
+ {
+ $keys = array_flip(is_array($key) ? $key : func_get_args());
+ $count = count($keys);
+
+ foreach ($this as $key => $value) {
+ if (array_key_exists($key, $keys) && --$count == 0) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Determine if any of the keys exist in the collection.
+ *
+ * @param mixed $key
+ * @return bool
+ */
+ public function hasAny($key)
+ {
+ $keys = array_flip(is_array($key) ? $key : func_get_args());
+
+ foreach ($this as $key => $value) {
+ if (array_key_exists($key, $keys)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Concatenate values of a given key as a string.
+ *
+ * @param callable|string $value
+ * @param string|null $glue
+ * @return string
+ */
+ public function implode($value, $glue = null)
+ {
+ return $this->collect()->implode(...func_get_args());
+ }
+
+ /**
+ * Intersect the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersect($items)
+ {
+ return $this->passthru('intersect', func_get_args());
+ }
+
+ /**
+ * Intersect the collection with the given items, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @param callable(TValue, TValue): int $callback
+ * @return static
+ */
+ public function intersectUsing()
+ {
+ return $this->passthru('intersectUsing', func_get_args());
+ }
+
+ /**
+ * Intersect the collection with the given items with additional index check.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersectAssoc($items)
+ {
+ return $this->passthru('intersectAssoc', func_get_args());
+ }
+
+ /**
+ * Intersect the collection with the given items with additional index check, using the callback.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TValue>|iterable<array-key, TValue> $items
+ * @param callable(TValue, TValue): int $callback
+ * @return static
+ */
+ public function intersectAssocUsing($items, callable $callback)
+ {
+ return $this->passthru('intersectAssocUsing', func_get_args());
+ }
+
+ /**
+ * Intersect the collection with the given items by key.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function intersectByKeys($items)
+ {
+ return $this->passthru('intersectByKeys', func_get_args());
+ }
+
+ /**
+ * Determine if the items are empty or not.
+ *
+ * @return bool
+ */
+ public function isEmpty()
+ {
+ return ! $this->getIterator()->valid();
+ }
+
+ /**
+ * Determine if the collection contains a single item.
+ *
+ * @return bool
+ */
+ public function containsOneItem()
+ {
+ return $this->take(2)->count() === 1;
+ }
+
+ /**
+ * Join all items from the collection using a string. The final items can use a separate glue string.
+ *
+ * @param string $glue
+ * @param string $finalGlue
+ * @return string
+ */
+ public function join($glue, $finalGlue = '')
+ {
+ return $this->collect()->join(...func_get_args());
+ }
+
+ /**
+ * Get the keys of the collection items.
+ *
+ * @return static<int, TKey>
+ */
+ public function keys()
+ {
+ return new static(function () {
+ foreach ($this as $key => $value) {
+ yield $key;
+ }
+ });
+ }
+
+ /**
+ * Get the last item from the collection.
+ *
+ * @template TLastDefault
+ *
+ * @param (callable(TValue, TKey): bool)|null $callback
+ * @param TLastDefault|(\Closure(): TLastDefault) $default
+ * @return TValue|TLastDefault
+ */
+ public function last(?callable $callback = null, $default = null)
+ {
+ $needle = $placeholder = new stdClass;
+
+ foreach ($this as $key => $value) {
+ if (is_null($callback) || $callback($value, $key)) {
+ $needle = $value;
+ }
+ }
+
+ return $needle === $placeholder ? value($default) : $needle;
+ }
+
+ /**
+ * Get the values of a given key.
+ *
+ * @param string|array<array-key, string> $value
+ * @param string|null $key
+ * @return static<int, mixed>
+ */
+ public function pluck($value, $key = null)
+ {
+ return new static(function () use ($value, $key) {
+ [$value, $key] = $this->explodePluckParameters($value, $key);
+
+ foreach ($this as $item) {
+ $itemValue = data_get($item, $value);
+
+ if (is_null($key)) {
+ yield $itemValue;
+ } else {
+ $itemKey = data_get($item, $key);
+
+ if (is_object($itemKey) && method_exists($itemKey, '__toString')) {
+ $itemKey = (string) $itemKey;
+ }
+
+ yield $itemKey => $itemValue;
+ }
+ }
+ });
+ }
+
+ /**
+ * Run a map over each of the items.
+ *
+ * @template TMapValue
+ *
+ * @param callable(TValue, TKey): TMapValue $callback
+ * @return static<TKey, TMapValue>
+ */
+ public function map(callable $callback)
+ {
+ return new static(function () use ($callback) {
+ foreach ($this as $key => $value) {
+ yield $key => $callback($value, $key);
+ }
+ });
+ }
+
+ /**
+ * Run a dictionary map over the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapToDictionaryKey of array-key
+ * @template TMapToDictionaryValue
+ *
+ * @param callable(TValue, TKey): array<TMapToDictionaryKey, TMapToDictionaryValue> $callback
+ * @return static<TMapToDictionaryKey, array<int, TMapToDictionaryValue>>
+ */
+ public function mapToDictionary(callable $callback)
+ {
+ return $this->passthru('mapToDictionary', func_get_args());
+ }
+
+ /**
+ * Run an associative map over each of the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapWithKeysKey of array-key
+ * @template TMapWithKeysValue
+ *
+ * @param callable(TValue, TKey): array<TMapWithKeysKey, TMapWithKeysValue> $callback
+ * @return static<TMapWithKeysKey, TMapWithKeysValue>
+ */
+ public function mapWithKeys(callable $callback)
+ {
+ return new static(function () use ($callback) {
+ foreach ($this as $key => $value) {
+ yield from $callback($value, $key);
+ }
+ });
+ }
+
+ /**
+ * Merge the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function merge($items)
+ {
+ return $this->passthru('merge', func_get_args());
+ }
+
+ /**
+ * Recursively merge the collection with the given items.
+ *
+ * @template TMergeRecursiveValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TMergeRecursiveValue>|iterable<TKey, TMergeRecursiveValue> $items
+ * @return static<TKey, TValue|TMergeRecursiveValue>
+ */
+ public function mergeRecursive($items)
+ {
+ return $this->passthru('mergeRecursive', func_get_args());
+ }
+
+ /**
+ * Create a collection by using this collection for keys and another for its values.
+ *
+ * @template TCombineValue
+ *
+ * @param \IteratorAggregate<array-key, TCombineValue>|array<array-key, TCombineValue>|(callable(): \Generator<array-key, TCombineValue>) $values
+ * @return static<TValue, TCombineValue>
+ */
+ public function combine($values)
+ {
+ return new static(function () use ($values) {
+ $values = $this->makeIterator($values);
+
+ $errorMessage = 'Both parameters should have an equal number of elements';
+
+ foreach ($this as $key) {
+ if (! $values->valid()) {
+ trigger_error($errorMessage, E_USER_WARNING);
+
+ break;
+ }
+
+ yield $key => $values->current();
+
+ $values->next();
+ }
+
+ if ($values->valid()) {
+ trigger_error($errorMessage, E_USER_WARNING);
+ }
+ });
+ }
+
+ /**
+ * Union the collection with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function union($items)
+ {
+ return $this->passthru('union', func_get_args());
+ }
+
+ /**
+ * Create a new collection consisting of every n-th element.
+ *
+ * @param int $step
+ * @param int $offset
+ * @return static
+ */
+ public function nth($step, $offset = 0)
+ {
+ return new static(function () use ($step, $offset) {
+ $position = 0;
+
+ foreach ($this->slice($offset) as $item) {
+ if ($position % $step === 0) {
+ yield $item;
+ }
+
+ $position++;
+ }
+ });
+ }
+
+ /**
+ * Get the items with the specified keys.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey>|string $keys
+ * @return static
+ */
+ public function only($keys)
+ {
+ if ($keys instanceof Enumerable) {
+ $keys = $keys->all();
+ } elseif (! is_null($keys)) {
+ $keys = is_array($keys) ? $keys : func_get_args();
+ }
+
+ return new static(function () use ($keys) {
+ if (is_null($keys)) {
+ yield from $this;
+ } else {
+ $keys = array_flip($keys);
+
+ foreach ($this as $key => $value) {
+ if (array_key_exists($key, $keys)) {
+ yield $key => $value;
+
+ unset($keys[$key]);
+
+ if (empty($keys)) {
+ break;
+ }
+ }
+ }
+ }
+ });
+ }
+
+ /**
+ * Select specific values from the items within the collection.
+ *
+ * @param \Illuminate\Support\Enumerable<array-key, TKey>|array<array-key, TKey>|string $keys
+ * @return static
+ */
+ public function select($keys)
+ {
+ if ($keys instanceof Enumerable) {
+ $keys = $keys->all();
+ } elseif (! is_null($keys)) {
+ $keys = is_array($keys) ? $keys : func_get_args();
+ }
+
+ return new static(function () use ($keys) {
+ if (is_null($keys)) {
+ yield from $this;
+ } else {
+ foreach ($this as $item) {
+ $result = [];
+
+ foreach ($keys as $key) {
+ if (Arr::accessible($item) && Arr::exists($item, $key)) {
+ $result[$key] = $item[$key];
+ } elseif (is_object($item) && isset($item->{$key})) {
+ $result[$key] = $item->{$key};
+ }
+ }
+
+ yield $result;
+ }
+ }
+ });
+ }
+
+ /**
+ * Push all of the given items onto the collection.
+ *
+ * @template TConcatKey of array-key
+ * @template TConcatValue
+ *
+ * @param iterable<TConcatKey, TConcatValue> $source
+ * @return static<TKey|TConcatKey, TValue|TConcatValue>
+ */
+ public function concat($source)
+ {
+ return (new static(function () use ($source) {
+ yield from $this;
+ yield from $source;
+ }))->values();
+ }
+
+ /**
+ * Get one or a specified number of items randomly from the collection.
+ *
+ * @param int|null $number
+ * @return static<int, TValue>|TValue
+ *
+ * @throws \InvalidArgumentException
+ */
+ public function random($number = null)
+ {
+ $result = $this->collect()->random(...func_get_args());
+
+ return is_null($number) ? $result : new static($result);
+ }
+
+ /**
+ * Replace the collection items with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function replace($items)
+ {
+ return new static(function () use ($items) {
+ $items = $this->getArrayableItems($items);
+
+ foreach ($this as $key => $value) {
+ if (array_key_exists($key, $items)) {
+ yield $key => $items[$key];
+
+ unset($items[$key]);
+ } else {
+ yield $key => $value;
+ }
+ }
+
+ foreach ($items as $key => $value) {
+ yield $key => $value;
+ }
+ });
+ }
+
+ /**
+ * Recursively replace the collection items with the given items.
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue> $items
+ * @return static
+ */
+ public function replaceRecursive($items)
+ {
+ return $this->passthru('replaceRecursive', func_get_args());
+ }
+
+ /**
+ * Reverse items order.
+ *
+ * @return static
+ */
+ public function reverse()
+ {
+ return $this->passthru('reverse', func_get_args());
+ }
+
+ /**
+ * Search the collection for a given value and return the corresponding key if successful.
+ *
+ * @param TValue|(callable(TValue,TKey): bool) $value
+ * @param bool $strict
+ * @return TKey|false
+ */
+ public function search($value, $strict = false)
+ {
+ /** @var (callable(TValue,TKey): bool) $predicate */
+ $predicate = $this->useAsCallable($value)
+ ? $value
+ : function ($item) use ($value, $strict) {
+ return $strict ? $item === $value : $item == $value;
+ };
+
+ foreach ($this as $key => $item) {
+ if ($predicate($item, $key)) {
+ return $key;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Shuffle the items in the collection.
+ *
+ * @param int|null $seed
+ * @return static
+ */
+ public function shuffle($seed = null)
+ {
+ return $this->passthru('shuffle', func_get_args());
+ }
+
+ /**
+ * Create chunks representing a "sliding window" view of the items in the collection.
+ *
+ * @param int $size
+ * @param int $step
+ * @return static<int, static>
+ */
+ public function sliding($size = 2, $step = 1)
+ {
+ return new static(function () use ($size, $step) {
+ $iterator = $this->getIterator();
+
+ $chunk = [];
+
+ while ($iterator->valid()) {
+ $chunk[$iterator->key()] = $iterator->current();
+
+ if (count($chunk) == $size) {
+ yield (new static($chunk))->tap(function () use (&$chunk, $step) {
+ $chunk = array_slice($chunk, $step, null, true);
+ });
+
+ // If the $step between chunks is bigger than each chunk's $size
+ // we will skip the extra items (which should never be in any
+ // chunk) before we continue to the next chunk in the loop.
+ if ($step > $size) {
+ $skip = $step - $size;
+
+ for ($i = 0; $i < $skip && $iterator->valid(); $i++) {
+ $iterator->next();
+ }
+ }
+ }
+
+ $iterator->next();
+ }
+ });
+ }
+
+ /**
+ * Skip the first {$count} items.
+ *
+ * @param int $count
+ * @return static
+ */
+ public function skip($count)
+ {
+ return new static(function () use ($count) {
+ $iterator = $this->getIterator();
+
+ while ($iterator->valid() && $count--) {
+ $iterator->next();
+ }
+
+ while ($iterator->valid()) {
+ yield $iterator->key() => $iterator->current();
+
+ $iterator->next();
+ }
+ });
+ }
+
+ /**
+ * Skip items in the collection until the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function skipUntil($value)
+ {
+ $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
+
+ return $this->skipWhile($this->negate($callback));
+ }
+
+ /**
+ * Skip items in the collection while the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function skipWhile($value)
+ {
+ $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
+
+ return new static(function () use ($callback) {
+ $iterator = $this->getIterator();
+
+ while ($iterator->valid() && $callback($iterator->current(), $iterator->key())) {
+ $iterator->next();
+ }
+
+ while ($iterator->valid()) {
+ yield $iterator->key() => $iterator->current();
+
+ $iterator->next();
+ }
+ });
+ }
+
+ /**
+ * Get a slice of items from the enumerable.
+ *
+ * @param int $offset
+ * @param int|null $length
+ * @return static
+ */
+ public function slice($offset, $length = null)
+ {
+ if ($offset < 0 || $length < 0) {
+ return $this->passthru('slice', func_get_args());
+ }
+
+ $instance = $this->skip($offset);
+
+ return is_null($length) ? $instance : $instance->take($length);
+ }
+
+ /**
+ * Split a collection into a certain number of groups.
+ *
+ * @param int $numberOfGroups
+ * @return static<int, static>
+ */
+ public function split($numberOfGroups)
+ {
+ return $this->passthru('split', func_get_args());
+ }
+
+ /**
+ * Get the first item in the collection, but only if exactly one item exists. Otherwise, throw an exception.
+ *
+ * @param (callable(TValue, TKey): bool)|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue
+ *
+ * @throws \Illuminate\Support\ItemNotFoundException
+ * @throws \Illuminate\Support\MultipleItemsFoundException
+ */
+ public function sole($key = null, $operator = null, $value = null)
+ {
+ $filter = func_num_args() > 1
+ ? $this->operatorForWhere(...func_get_args())
+ : $key;
+
+ return $this
+ ->unless($filter == null)
+ ->filter($filter)
+ ->take(2)
+ ->collect()
+ ->sole();
+ }
+
+ /**
+ * Get the first item in the collection but throw an exception if no matching items exist.
+ *
+ * @param (callable(TValue, TKey): bool)|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue
+ *
+ * @throws \Illuminate\Support\ItemNotFoundException
+ */
+ public function firstOrFail($key = null, $operator = null, $value = null)
+ {
+ $filter = func_num_args() > 1
+ ? $this->operatorForWhere(...func_get_args())
+ : $key;
+
+ return $this
+ ->unless($filter == null)
+ ->filter($filter)
+ ->take(1)
+ ->collect()
+ ->firstOrFail();
+ }
+
+ /**
+ * Chunk the collection into chunks of the given size.
+ *
+ * @param int $size
+ * @return static<int, static>
+ */
+ public function chunk($size)
+ {
+ if ($size <= 0) {
+ return static::empty();
+ }
+
+ return new static(function () use ($size) {
+ $iterator = $this->getIterator();
+
+ while ($iterator->valid()) {
+ $chunk = [];
+
+ while (true) {
+ $chunk[$iterator->key()] = $iterator->current();
+
+ if (count($chunk) < $size) {
+ $iterator->next();
+
+ if (! $iterator->valid()) {
+ break;
+ }
+ } else {
+ break;
+ }
+ }
+
+ yield new static($chunk);
+
+ $iterator->next();
+ }
+ });
+ }
+
+ /**
+ * Split a collection into a certain number of groups, and fill the first groups completely.
+ *
+ * @param int $numberOfGroups
+ * @return static<int, static>
+ */
+ public function splitIn($numberOfGroups)
+ {
+ return $this->chunk(ceil($this->count() / $numberOfGroups));
+ }
+
+ /**
+ * Chunk the collection into chunks with a callback.
+ *
+ * @param callable(TValue, TKey, Collection<TKey, TValue>): bool $callback
+ * @return static<int, static<int, TValue>>
+ */
+ public function chunkWhile(callable $callback)
+ {
+ return new static(function () use ($callback) {
+ $iterator = $this->getIterator();
+
+ $chunk = new Collection;
+
+ if ($iterator->valid()) {
+ $chunk[$iterator->key()] = $iterator->current();
+
+ $iterator->next();
+ }
+
+ while ($iterator->valid()) {
+ if (! $callback($iterator->current(), $iterator->key(), $chunk)) {
+ yield new static($chunk);
+
+ $chunk = new Collection;
+ }
+
+ $chunk[$iterator->key()] = $iterator->current();
+
+ $iterator->next();
+ }
+
+ if ($chunk->isNotEmpty()) {
+ yield new static($chunk);
+ }
+ });
+ }
+
+ /**
+ * Sort through each item with a callback.
+ *
+ * @param (callable(TValue, TValue): int)|null|int $callback
+ * @return static
+ */
+ public function sort($callback = null)
+ {
+ return $this->passthru('sort', func_get_args());
+ }
+
+ /**
+ * Sort items in descending order.
+ *
+ * @param int $options
+ * @return static
+ */
+ public function sortDesc($options = SORT_REGULAR)
+ {
+ return $this->passthru('sortDesc', func_get_args());
+ }
+
+ /**
+ * Sort the collection using the given callback.
+ *
+ * @param array<array-key, (callable(TValue, TValue): mixed)|(callable(TValue, TKey): mixed)|string|array{string, string}>|(callable(TValue, TKey): mixed)|string $callback
+ * @param int $options
+ * @param bool $descending
+ * @return static
+ */
+ public function sortBy($callback, $options = SORT_REGULAR, $descending = false)
+ {
+ return $this->passthru('sortBy', func_get_args());
+ }
+
+ /**
+ * Sort the collection in descending order using the given callback.
+ *
+ * @param array<array-key, (callable(TValue, TValue): mixed)|(callable(TValue, TKey): mixed)|string|array{string, string}>|(callable(TValue, TKey): mixed)|string $callback
+ * @param int $options
+ * @return static
+ */
+ public function sortByDesc($callback, $options = SORT_REGULAR)
+ {
+ return $this->passthru('sortByDesc', func_get_args());
+ }
+
+ /**
+ * Sort the collection keys.
+ *
+ * @param int $options
+ * @param bool $descending
+ * @return static
+ */
+ public function sortKeys($options = SORT_REGULAR, $descending = false)
+ {
+ return $this->passthru('sortKeys', func_get_args());
+ }
+
+ /**
+ * Sort the collection keys in descending order.
+ *
+ * @param int $options
+ * @return static
+ */
+ public function sortKeysDesc($options = SORT_REGULAR)
+ {
+ return $this->passthru('sortKeysDesc', func_get_args());
+ }
+
+ /**
+ * Sort the collection keys using a callback.
+ *
+ * @param callable(TKey, TKey): int $callback
+ * @return static
+ */
+ public function sortKeysUsing(callable $callback)
+ {
+ return $this->passthru('sortKeysUsing', func_get_args());
+ }
+
+ /**
+ * Take the first or last {$limit} items.
+ *
+ * @param int $limit
+ * @return static
+ */
+ public function take($limit)
+ {
+ if ($limit < 0) {
+ return new static(function () use ($limit) {
+ $limit = abs($limit);
+ $ringBuffer = [];
+ $position = 0;
+
+ foreach ($this as $key => $value) {
+ $ringBuffer[$position] = [$key, $value];
+ $position = ($position + 1) % $limit;
+ }
+
+ for ($i = 0, $end = min($limit, count($ringBuffer)); $i < $end; $i++) {
+ $pointer = ($position + $i) % $limit;
+ yield $ringBuffer[$pointer][0] => $ringBuffer[$pointer][1];
+ }
+ });
+ }
+
+ return new static(function () use ($limit) {
+ $iterator = $this->getIterator();
+
+ while ($limit--) {
+ if (! $iterator->valid()) {
+ break;
+ }
+
+ yield $iterator->key() => $iterator->current();
+
+ if ($limit) {
+ $iterator->next();
+ }
+ }
+ });
+ }
+
+ /**
+ * Take items in the collection until the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function takeUntil($value)
+ {
+ /** @var callable(TValue, TKey): bool $callback */
+ $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
+
+ return new static(function () use ($callback) {
+ foreach ($this as $key => $item) {
+ if ($callback($item, $key)) {
+ break;
+ }
+
+ yield $key => $item;
+ }
+ });
+ }
+
+ /**
+ * Take items in the collection until a given point in time.
+ *
+ * @param \DateTimeInterface $timeout
+ * @return static
+ */
+ public function takeUntilTimeout(DateTimeInterface $timeout)
+ {
+ $timeout = $timeout->getTimestamp();
+
+ return new static(function () use ($timeout) {
+ if ($this->now() >= $timeout) {
+ return;
+ }
+
+ foreach ($this as $key => $value) {
+ yield $key => $value;
+
+ if ($this->now() >= $timeout) {
+ break;
+ }
+ }
+ });
+ }
+
+ /**
+ * Take items in the collection while the given condition is met.
+ *
+ * @param TValue|callable(TValue,TKey): bool $value
+ * @return static
+ */
+ public function takeWhile($value)
+ {
+ /** @var callable(TValue, TKey): bool $callback */
+ $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
+
+ return $this->takeUntil(fn ($item, $key) => ! $callback($item, $key));
+ }
+
+ /**
+ * Pass each item in the collection to the given callback, lazily.
+ *
+ * @param callable(TValue, TKey): mixed $callback
+ * @return static
+ */
+ public function tapEach(callable $callback)
+ {
+ return new static(function () use ($callback) {
+ foreach ($this as $key => $value) {
+ $callback($value, $key);
+
+ yield $key => $value;
+ }
+ });
+ }
+
+ /**
+ * Flatten a multi-dimensional associative array with dots.
+ *
+ * @return static
+ */
+ public function dot()
+ {
+ return $this->passthru('dot', []);
+ }
+
+ /**
+ * Convert a flatten "dot" notation array into an expanded array.
+ *
+ * @return static
+ */
+ public function undot()
+ {
+ return $this->passthru('undot', []);
+ }
+
+ /**
+ * Return only unique items from the collection array.
+ *
+ * @param (callable(TValue, TKey): mixed)|string|null $key
+ * @param bool $strict
+ * @return static
+ */
+ public function unique($key = null, $strict = false)
+ {
+ $callback = $this->valueRetriever($key);
+
+ return new static(function () use ($callback, $strict) {
+ $exists = [];
+
+ foreach ($this as $key => $item) {
+ if (! in_array($id = $callback($item, $key), $exists, $strict)) {
+ yield $key => $item;
+
+ $exists[] = $id;
+ }
+ }
+ });
+ }
+
+ /**
+ * Reset the keys on the underlying array.
+ *
+ * @return static<int, TValue>
+ */
+ public function values()
+ {
+ return new static(function () {
+ foreach ($this as $item) {
+ yield $item;
+ }
+ });
+ }
+
+ /**
+ * Zip the collection together with one or more arrays.
+ *
+ * e.g. new LazyCollection([1, 2, 3])->zip([4, 5, 6]);
+ * => [[1, 4], [2, 5], [3, 6]]
+ *
+ * @template TZipValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<array-key, TZipValue>|iterable<array-key, TZipValue> ...$items
+ * @return static<int, static<int, TValue|TZipValue>>
+ */
+ public function zip($items)
+ {
+ $iterables = func_get_args();
+
+ return new static(function () use ($iterables) {
+ $iterators = Collection::make($iterables)->map(function ($iterable) {
+ return $this->makeIterator($iterable);
+ })->prepend($this->getIterator());
+
+ while ($iterators->contains->valid()) {
+ yield new static($iterators->map->current());
+
+ $iterators->each->next();
+ }
+ });
+ }
+
+ /**
+ * Pad collection to the specified length with a value.
+ *
+ * @template TPadValue
+ *
+ * @param int $size
+ * @param TPadValue $value
+ * @return static<int, TValue|TPadValue>
+ */
+ public function pad($size, $value)
+ {
+ if ($size < 0) {
+ return $this->passthru('pad', func_get_args());
+ }
+
+ return new static(function () use ($size, $value) {
+ $yielded = 0;
+
+ foreach ($this as $index => $item) {
+ yield $index => $item;
+
+ $yielded++;
+ }
+
+ while ($yielded++ < $size) {
+ yield $value;
+ }
+ });
+ }
+
+ /**
+ * Get the values iterator.
+ *
+ * @return \Traversable<TKey, TValue>
+ */
+ public function getIterator(): Traversable
+ {
+ return $this->makeIterator($this->source);
+ }
+
+ /**
+ * Count the number of items in the collection.
+ *
+ * @return int
+ */
+ public function count(): int
+ {
+ if (is_array($this->source)) {
+ return count($this->source);
+ }
+
+ return iterator_count($this->getIterator());
+ }
+
+ /**
+ * Make an iterator from the given source.
+ *
+ * @template TIteratorKey of array-key
+ * @template TIteratorValue
+ *
+ * @param \IteratorAggregate<TIteratorKey, TIteratorValue>|array<TIteratorKey, TIteratorValue>|(callable(): \Generator<TIteratorKey, TIteratorValue>) $source
+ * @return \Traversable<TIteratorKey, TIteratorValue>
+ */
+ protected function makeIterator($source)
+ {
+ if ($source instanceof IteratorAggregate) {
+ return $source->getIterator();
+ }
+
+ if (is_array($source)) {
+ return new ArrayIterator($source);
+ }
+
+ if (is_callable($source)) {
+ $maybeTraversable = $source();
+
+ return $maybeTraversable instanceof Traversable
+ ? $maybeTraversable
+ : new ArrayIterator(Arr::wrap($maybeTraversable));
+ }
+
+ return new ArrayIterator((array) $source);
+ }
+
+ /**
+ * Explode the "value" and "key" arguments passed to "pluck".
+ *
+ * @param string|string[] $value
+ * @param string|string[]|null $key
+ * @return array{string[],string[]|null}
+ */
+ protected function explodePluckParameters($value, $key)
+ {
+ $value = is_string($value) ? explode('.', $value) : $value;
+
+ $key = is_null($key) || is_array($key) ? $key : explode('.', $key);
+
+ return [$value, $key];
+ }
+
+ /**
+ * Pass this lazy collection through a method on the collection class.
+ *
+ * @param string $method
+ * @param array<mixed> $params
+ * @return static
+ */
+ protected function passthru($method, array $params)
+ {
+ return new static(function () use ($method, $params) {
+ yield from $this->collect()->$method(...$params);
+ });
+ }
+
+ /**
+ * Get the current time.
+ *
+ * @return int
+ */
+ protected function now()
+ {
+ return class_exists(Carbon::class)
+ ? Carbon::now()->timestamp
+ : time();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/MultipleItemsFoundException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/MultipleItemsFoundException.php
new file mode 100644
index 0000000..d90d835
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/MultipleItemsFoundException.php
@@ -0,0 +1,40 @@
+<?php
+
+namespace Illuminate\Support;
+
+use RuntimeException;
+
+class MultipleItemsFoundException extends RuntimeException
+{
+ /**
+ * The number of items found.
+ *
+ * @var int
+ */
+ public $count;
+
+ /**
+ * Create a new exception instance.
+ *
+ * @param int $count
+ * @param int $code
+ * @param \Throwable|null $previous
+ * @return void
+ */
+ public function __construct($count, $code = 0, $previous = null)
+ {
+ $this->count = $count;
+
+ parent::__construct("$count items were found.", $code, $previous);
+ }
+
+ /**
+ * Get the number of items found.
+ *
+ * @return int
+ */
+ public function getCount()
+ {
+ return $this->count;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Traits/EnumeratesValues.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Traits/EnumeratesValues.php
new file mode 100644
index 0000000..9718f5b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/Traits/EnumeratesValues.php
@@ -0,0 +1,1152 @@
+<?php
+
+namespace Illuminate\Support\Traits;
+
+use CachingIterator;
+use Closure;
+use Exception;
+use Illuminate\Contracts\Support\Arrayable;
+use Illuminate\Contracts\Support\Jsonable;
+use Illuminate\Support\Arr;
+use Illuminate\Support\Collection;
+use Illuminate\Support\Enumerable;
+use Illuminate\Support\HigherOrderCollectionProxy;
+use InvalidArgumentException;
+use JsonSerializable;
+use Symfony\Component\VarDumper\VarDumper;
+use Traversable;
+use UnexpectedValueException;
+use UnitEnum;
+use WeakMap;
+
+/**
+ * @template TKey of array-key
+ *
+ * @template-covariant TValue
+ *
+ * @property-read HigherOrderCollectionProxy $average
+ * @property-read HigherOrderCollectionProxy $avg
+ * @property-read HigherOrderCollectionProxy $contains
+ * @property-read HigherOrderCollectionProxy $doesntContain
+ * @property-read HigherOrderCollectionProxy $each
+ * @property-read HigherOrderCollectionProxy $every
+ * @property-read HigherOrderCollectionProxy $filter
+ * @property-read HigherOrderCollectionProxy $first
+ * @property-read HigherOrderCollectionProxy $flatMap
+ * @property-read HigherOrderCollectionProxy $groupBy
+ * @property-read HigherOrderCollectionProxy $keyBy
+ * @property-read HigherOrderCollectionProxy $map
+ * @property-read HigherOrderCollectionProxy $max
+ * @property-read HigherOrderCollectionProxy $min
+ * @property-read HigherOrderCollectionProxy $partition
+ * @property-read HigherOrderCollectionProxy $percentage
+ * @property-read HigherOrderCollectionProxy $reject
+ * @property-read HigherOrderCollectionProxy $skipUntil
+ * @property-read HigherOrderCollectionProxy $skipWhile
+ * @property-read HigherOrderCollectionProxy $some
+ * @property-read HigherOrderCollectionProxy $sortBy
+ * @property-read HigherOrderCollectionProxy $sortByDesc
+ * @property-read HigherOrderCollectionProxy $sum
+ * @property-read HigherOrderCollectionProxy $takeUntil
+ * @property-read HigherOrderCollectionProxy $takeWhile
+ * @property-read HigherOrderCollectionProxy $unique
+ * @property-read HigherOrderCollectionProxy $unless
+ * @property-read HigherOrderCollectionProxy $until
+ * @property-read HigherOrderCollectionProxy $when
+ */
+trait EnumeratesValues
+{
+ use Conditionable;
+
+ /**
+ * Indicates that the object's string representation should be escaped when __toString is invoked.
+ *
+ * @var bool
+ */
+ protected $escapeWhenCastingToString = false;
+
+ /**
+ * The methods that can be proxied.
+ *
+ * @var array<int, string>
+ */
+ protected static $proxies = [
+ 'average',
+ 'avg',
+ 'contains',
+ 'doesntContain',
+ 'each',
+ 'every',
+ 'filter',
+ 'first',
+ 'flatMap',
+ 'groupBy',
+ 'keyBy',
+ 'map',
+ 'max',
+ 'min',
+ 'partition',
+ 'percentage',
+ 'reject',
+ 'skipUntil',
+ 'skipWhile',
+ 'some',
+ 'sortBy',
+ 'sortByDesc',
+ 'sum',
+ 'takeUntil',
+ 'takeWhile',
+ 'unique',
+ 'unless',
+ 'until',
+ 'when',
+ ];
+
+ /**
+ * Create a new collection instance if the value isn't one already.
+ *
+ * @template TMakeKey of array-key
+ * @template TMakeValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TMakeKey, TMakeValue>|iterable<TMakeKey, TMakeValue>|null $items
+ * @return static<TMakeKey, TMakeValue>
+ */
+ public static function make($items = [])
+ {
+ return new static($items);
+ }
+
+ /**
+ * Wrap the given value in a collection if applicable.
+ *
+ * @template TWrapValue
+ *
+ * @param iterable<array-key, TWrapValue>|TWrapValue $value
+ * @return static<array-key, TWrapValue>
+ */
+ public static function wrap($value)
+ {
+ return $value instanceof Enumerable
+ ? new static($value)
+ : new static(Arr::wrap($value));
+ }
+
+ /**
+ * Get the underlying items from the given collection if applicable.
+ *
+ * @template TUnwrapKey of array-key
+ * @template TUnwrapValue
+ *
+ * @param array<TUnwrapKey, TUnwrapValue>|static<TUnwrapKey, TUnwrapValue> $value
+ * @return array<TUnwrapKey, TUnwrapValue>
+ */
+ public static function unwrap($value)
+ {
+ return $value instanceof Enumerable ? $value->all() : $value;
+ }
+
+ /**
+ * Create a new instance with no items.
+ *
+ * @return static
+ */
+ public static function empty()
+ {
+ return new static([]);
+ }
+
+ /**
+ * Create a new collection by invoking the callback a given amount of times.
+ *
+ * @template TTimesValue
+ *
+ * @param int $number
+ * @param (callable(int): TTimesValue)|null $callback
+ * @return static<int, TTimesValue>
+ */
+ public static function times($number, ?callable $callback = null)
+ {
+ if ($number < 1) {
+ return new static;
+ }
+
+ return static::range(1, $number)
+ ->unless($callback == null)
+ ->map($callback);
+ }
+
+ /**
+ * Alias for the "avg" method.
+ *
+ * @param (callable(TValue): float|int)|string|null $callback
+ * @return float|int|null
+ */
+ public function average($callback = null)
+ {
+ return $this->avg($callback);
+ }
+
+ /**
+ * Alias for the "contains" method.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function some($key, $operator = null, $value = null)
+ {
+ return $this->contains(...func_get_args());
+ }
+
+ /**
+ * Dump the items and end the script.
+ *
+ * @param mixed ...$args
+ * @return never
+ */
+ public function dd(...$args)
+ {
+ $this->dump(...$args);
+
+ exit(1);
+ }
+
+ /**
+ * Dump the items.
+ *
+ * @return $this
+ */
+ public function dump()
+ {
+ (new Collection(func_get_args()))
+ ->push($this->all())
+ ->each(function ($item) {
+ VarDumper::dump($item);
+ });
+
+ return $this;
+ }
+
+ /**
+ * Execute a callback over each item.
+ *
+ * @param callable(TValue, TKey): mixed $callback
+ * @return $this
+ */
+ public function each(callable $callback)
+ {
+ foreach ($this as $key => $item) {
+ if ($callback($item, $key) === false) {
+ break;
+ }
+ }
+
+ return $this;
+ }
+
+ /**
+ * Execute a callback over each nested chunk of items.
+ *
+ * @param callable(...mixed): mixed $callback
+ * @return static
+ */
+ public function eachSpread(callable $callback)
+ {
+ return $this->each(function ($chunk, $key) use ($callback) {
+ $chunk[] = $key;
+
+ return $callback(...$chunk);
+ });
+ }
+
+ /**
+ * Determine if all items pass the given truth test.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return bool
+ */
+ public function every($key, $operator = null, $value = null)
+ {
+ if (func_num_args() === 1) {
+ $callback = $this->valueRetriever($key);
+
+ foreach ($this as $k => $v) {
+ if (! $callback($v, $k)) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ return $this->every($this->operatorForWhere(...func_get_args()));
+ }
+
+ /**
+ * Get the first item by the given key value pair.
+ *
+ * @param callable|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return TValue|null
+ */
+ public function firstWhere($key, $operator = null, $value = null)
+ {
+ return $this->first($this->operatorForWhere(...func_get_args()));
+ }
+
+ /**
+ * Get a single key's value from the first matching item in the collection.
+ *
+ * @template TValueDefault
+ *
+ * @param string $key
+ * @param TValueDefault|(\Closure(): TValueDefault) $default
+ * @return TValue|TValueDefault
+ */
+ public function value($key, $default = null)
+ {
+ if ($value = $this->firstWhere($key)) {
+ return data_get($value, $key, $default);
+ }
+
+ return value($default);
+ }
+
+ /**
+ * Ensure that every item in the collection is of the expected type.
+ *
+ * @template TEnsureOfType
+ *
+ * @param class-string<TEnsureOfType>|array<array-key, class-string<TEnsureOfType>> $type
+ * @return static<TKey, TEnsureOfType>
+ *
+ * @throws \UnexpectedValueException
+ */
+ public function ensure($type)
+ {
+ $allowedTypes = is_array($type) ? $type : [$type];
+
+ return $this->each(function ($item) use ($allowedTypes) {
+ $itemType = get_debug_type($item);
+
+ foreach ($allowedTypes as $allowedType) {
+ if ($itemType === $allowedType || $item instanceof $allowedType) {
+ return true;
+ }
+ }
+
+ throw new UnexpectedValueException(
+ sprintf("Collection should only include [%s] items, but '%s' found.", implode(', ', $allowedTypes), $itemType)
+ );
+ });
+ }
+
+ /**
+ * Determine if the collection is not empty.
+ *
+ * @return bool
+ */
+ public function isNotEmpty()
+ {
+ return ! $this->isEmpty();
+ }
+
+ /**
+ * Run a map over each nested chunk of items.
+ *
+ * @template TMapSpreadValue
+ *
+ * @param callable(mixed...): TMapSpreadValue $callback
+ * @return static<TKey, TMapSpreadValue>
+ */
+ public function mapSpread(callable $callback)
+ {
+ return $this->map(function ($chunk, $key) use ($callback) {
+ $chunk[] = $key;
+
+ return $callback(...$chunk);
+ });
+ }
+
+ /**
+ * Run a grouping map over the items.
+ *
+ * The callback should return an associative array with a single key/value pair.
+ *
+ * @template TMapToGroupsKey of array-key
+ * @template TMapToGroupsValue
+ *
+ * @param callable(TValue, TKey): array<TMapToGroupsKey, TMapToGroupsValue> $callback
+ * @return static<TMapToGroupsKey, static<int, TMapToGroupsValue>>
+ */
+ public function mapToGroups(callable $callback)
+ {
+ $groups = $this->mapToDictionary($callback);
+
+ return $groups->map([$this, 'make']);
+ }
+
+ /**
+ * Map a collection and flatten the result by a single level.
+ *
+ * @template TFlatMapKey of array-key
+ * @template TFlatMapValue
+ *
+ * @param callable(TValue, TKey): (\Illuminate\Support\Collection<TFlatMapKey, TFlatMapValue>|array<TFlatMapKey, TFlatMapValue>) $callback
+ * @return static<TFlatMapKey, TFlatMapValue>
+ */
+ public function flatMap(callable $callback)
+ {
+ return $this->map($callback)->collapse();
+ }
+
+ /**
+ * Map the values into a new class.
+ *
+ * @template TMapIntoValue
+ *
+ * @param class-string<TMapIntoValue> $class
+ * @return static<TKey, TMapIntoValue>
+ */
+ public function mapInto($class)
+ {
+ return $this->map(fn ($value, $key) => new $class($value, $key));
+ }
+
+ /**
+ * Get the min value of a given key.
+ *
+ * @param (callable(TValue):mixed)|string|null $callback
+ * @return mixed
+ */
+ public function min($callback = null)
+ {
+ $callback = $this->valueRetriever($callback);
+
+ return $this->map(fn ($value) => $callback($value))
+ ->filter(fn ($value) => ! is_null($value))
+ ->reduce(fn ($result, $value) => is_null($result) || $value < $result ? $value : $result);
+ }
+
+ /**
+ * Get the max value of a given key.
+ *
+ * @param (callable(TValue):mixed)|string|null $callback
+ * @return mixed
+ */
+ public function max($callback = null)
+ {
+ $callback = $this->valueRetriever($callback);
+
+ return $this->filter(fn ($value) => ! is_null($value))->reduce(function ($result, $item) use ($callback) {
+ $value = $callback($item);
+
+ return is_null($result) || $value > $result ? $value : $result;
+ });
+ }
+
+ /**
+ * "Paginate" the collection by slicing it into a smaller collection.
+ *
+ * @param int $page
+ * @param int $perPage
+ * @return static
+ */
+ public function forPage($page, $perPage)
+ {
+ $offset = max(0, ($page - 1) * $perPage);
+
+ return $this->slice($offset, $perPage);
+ }
+
+ /**
+ * Partition the collection into two arrays using the given callback or key.
+ *
+ * @param (callable(TValue, TKey): bool)|TValue|string $key
+ * @param TValue|string|null $operator
+ * @param TValue|null $value
+ * @return static<int<0, 1>, static<TKey, TValue>>
+ */
+ public function partition($key, $operator = null, $value = null)
+ {
+ $passed = [];
+ $failed = [];
+
+ $callback = func_num_args() === 1
+ ? $this->valueRetriever($key)
+ : $this->operatorForWhere(...func_get_args());
+
+ foreach ($this as $key => $item) {
+ if ($callback($item, $key)) {
+ $passed[$key] = $item;
+ } else {
+ $failed[$key] = $item;
+ }
+ }
+
+ return new static([new static($passed), new static($failed)]);
+ }
+
+ /**
+ * Calculate the percentage of items that pass a given truth test.
+ *
+ * @param (callable(TValue, TKey): bool) $callback
+ * @param int $precision
+ * @return float|null
+ */
+ public function percentage(callable $callback, int $precision = 2)
+ {
+ if ($this->isEmpty()) {
+ return null;
+ }
+
+ return round(
+ $this->filter($callback)->count() / $this->count() * 100,
+ $precision
+ );
+ }
+
+ /**
+ * Get the sum of the given values.
+ *
+ * @param (callable(TValue): mixed)|string|null $callback
+ * @return mixed
+ */
+ public function sum($callback = null)
+ {
+ $callback = is_null($callback)
+ ? $this->identity()
+ : $this->valueRetriever($callback);
+
+ return $this->reduce(fn ($result, $item) => $result + $callback($item), 0);
+ }
+
+ /**
+ * Apply the callback if the collection is empty.
+ *
+ * @template TWhenEmptyReturnType
+ *
+ * @param (callable($this): TWhenEmptyReturnType) $callback
+ * @param (callable($this): TWhenEmptyReturnType)|null $default
+ * @return $this|TWhenEmptyReturnType
+ */
+ public function whenEmpty(callable $callback, ?callable $default = null)
+ {
+ return $this->when($this->isEmpty(), $callback, $default);
+ }
+
+ /**
+ * Apply the callback if the collection is not empty.
+ *
+ * @template TWhenNotEmptyReturnType
+ *
+ * @param callable($this): TWhenNotEmptyReturnType $callback
+ * @param (callable($this): TWhenNotEmptyReturnType)|null $default
+ * @return $this|TWhenNotEmptyReturnType
+ */
+ public function whenNotEmpty(callable $callback, ?callable $default = null)
+ {
+ return $this->when($this->isNotEmpty(), $callback, $default);
+ }
+
+ /**
+ * Apply the callback unless the collection is empty.
+ *
+ * @template TUnlessEmptyReturnType
+ *
+ * @param callable($this): TUnlessEmptyReturnType $callback
+ * @param (callable($this): TUnlessEmptyReturnType)|null $default
+ * @return $this|TUnlessEmptyReturnType
+ */
+ public function unlessEmpty(callable $callback, ?callable $default = null)
+ {
+ return $this->whenNotEmpty($callback, $default);
+ }
+
+ /**
+ * Apply the callback unless the collection is not empty.
+ *
+ * @template TUnlessNotEmptyReturnType
+ *
+ * @param callable($this): TUnlessNotEmptyReturnType $callback
+ * @param (callable($this): TUnlessNotEmptyReturnType)|null $default
+ * @return $this|TUnlessNotEmptyReturnType
+ */
+ public function unlessNotEmpty(callable $callback, ?callable $default = null)
+ {
+ return $this->whenEmpty($callback, $default);
+ }
+
+ /**
+ * Filter items by the given key value pair.
+ *
+ * @param callable|string $key
+ * @param mixed $operator
+ * @param mixed $value
+ * @return static
+ */
+ public function where($key, $operator = null, $value = null)
+ {
+ return $this->filter($this->operatorForWhere(...func_get_args()));
+ }
+
+ /**
+ * Filter items where the value for the given key is null.
+ *
+ * @param string|null $key
+ * @return static
+ */
+ public function whereNull($key = null)
+ {
+ return $this->whereStrict($key, null);
+ }
+
+ /**
+ * Filter items where the value for the given key is not null.
+ *
+ * @param string|null $key
+ * @return static
+ */
+ public function whereNotNull($key = null)
+ {
+ return $this->where($key, '!==', null);
+ }
+
+ /**
+ * Filter items by the given key value pair using strict comparison.
+ *
+ * @param string $key
+ * @param mixed $value
+ * @return static
+ */
+ public function whereStrict($key, $value)
+ {
+ return $this->where($key, '===', $value);
+ }
+
+ /**
+ * Filter items by the given key value pair.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @param bool $strict
+ * @return static
+ */
+ public function whereIn($key, $values, $strict = false)
+ {
+ $values = $this->getArrayableItems($values);
+
+ return $this->filter(fn ($item) => in_array(data_get($item, $key), $values, $strict));
+ }
+
+ /**
+ * Filter items by the given key value pair using strict comparison.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereInStrict($key, $values)
+ {
+ return $this->whereIn($key, $values, true);
+ }
+
+ /**
+ * Filter items such that the value of the given key is between the given values.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereBetween($key, $values)
+ {
+ return $this->where($key, '>=', reset($values))->where($key, '<=', end($values));
+ }
+
+ /**
+ * Filter items such that the value of the given key is not between the given values.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereNotBetween($key, $values)
+ {
+ return $this->filter(
+ fn ($item) => data_get($item, $key) < reset($values) || data_get($item, $key) > end($values)
+ );
+ }
+
+ /**
+ * Filter items by the given key value pair.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @param bool $strict
+ * @return static
+ */
+ public function whereNotIn($key, $values, $strict = false)
+ {
+ $values = $this->getArrayableItems($values);
+
+ return $this->reject(fn ($item) => in_array(data_get($item, $key), $values, $strict));
+ }
+
+ /**
+ * Filter items by the given key value pair using strict comparison.
+ *
+ * @param string $key
+ * @param \Illuminate\Contracts\Support\Arrayable|iterable $values
+ * @return static
+ */
+ public function whereNotInStrict($key, $values)
+ {
+ return $this->whereNotIn($key, $values, true);
+ }
+
+ /**
+ * Filter the items, removing any items that don't match the given type(s).
+ *
+ * @template TWhereInstanceOf
+ *
+ * @param class-string<TWhereInstanceOf>|array<array-key, class-string<TWhereInstanceOf>> $type
+ * @return static<TKey, TWhereInstanceOf>
+ */
+ public function whereInstanceOf($type)
+ {
+ return $this->filter(function ($value) use ($type) {
+ if (is_array($type)) {
+ foreach ($type as $classType) {
+ if ($value instanceof $classType) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ return $value instanceof $type;
+ });
+ }
+
+ /**
+ * Pass the collection to the given callback and return the result.
+ *
+ * @template TPipeReturnType
+ *
+ * @param callable($this): TPipeReturnType $callback
+ * @return TPipeReturnType
+ */
+ public function pipe(callable $callback)
+ {
+ return $callback($this);
+ }
+
+ /**
+ * Pass the collection into a new class.
+ *
+ * @template TPipeIntoValue
+ *
+ * @param class-string<TPipeIntoValue> $class
+ * @return TPipeIntoValue
+ */
+ public function pipeInto($class)
+ {
+ return new $class($this);
+ }
+
+ /**
+ * Pass the collection through a series of callable pipes and return the result.
+ *
+ * @param array<callable> $callbacks
+ * @return mixed
+ */
+ public function pipeThrough($callbacks)
+ {
+ return Collection::make($callbacks)->reduce(
+ fn ($carry, $callback) => $callback($carry),
+ $this,
+ );
+ }
+
+ /**
+ * Reduce the collection to a single value.
+ *
+ * @template TReduceInitial
+ * @template TReduceReturnType
+ *
+ * @param callable(TReduceInitial|TReduceReturnType, TValue, TKey): TReduceReturnType $callback
+ * @param TReduceInitial $initial
+ * @return TReduceReturnType
+ */
+ public function reduce(callable $callback, $initial = null)
+ {
+ $result = $initial;
+
+ foreach ($this as $key => $value) {
+ $result = $callback($result, $value, $key);
+ }
+
+ return $result;
+ }
+
+ /**
+ * Reduce the collection to multiple aggregate values.
+ *
+ * @param callable $callback
+ * @param mixed ...$initial
+ * @return array
+ *
+ * @throws \UnexpectedValueException
+ */
+ public function reduceSpread(callable $callback, ...$initial)
+ {
+ $result = $initial;
+
+ foreach ($this as $key => $value) {
+ $result = call_user_func_array($callback, array_merge($result, [$value, $key]));
+
+ if (! is_array($result)) {
+ throw new UnexpectedValueException(sprintf(
+ "%s::reduceSpread expects reducer to return an array, but got a '%s' instead.",
+ class_basename(static::class), gettype($result)
+ ));
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Reduce an associative collection to a single value.
+ *
+ * @template TReduceWithKeysInitial
+ * @template TReduceWithKeysReturnType
+ *
+ * @param callable(TReduceWithKeysInitial|TReduceWithKeysReturnType, TValue, TKey): TReduceWithKeysReturnType $callback
+ * @param TReduceWithKeysInitial $initial
+ * @return TReduceWithKeysReturnType
+ */
+ public function reduceWithKeys(callable $callback, $initial = null)
+ {
+ return $this->reduce($callback, $initial);
+ }
+
+ /**
+ * Create a collection of all elements that do not pass a given truth test.
+ *
+ * @param (callable(TValue, TKey): bool)|bool|TValue $callback
+ * @return static
+ */
+ public function reject($callback = true)
+ {
+ $useAsCallable = $this->useAsCallable($callback);
+
+ return $this->filter(function ($value, $key) use ($callback, $useAsCallable) {
+ return $useAsCallable
+ ? ! $callback($value, $key)
+ : $value != $callback;
+ });
+ }
+
+ /**
+ * Pass the collection to the given callback and then return it.
+ *
+ * @param callable($this): mixed $callback
+ * @return $this
+ */
+ public function tap(callable $callback)
+ {
+ $callback($this);
+
+ return $this;
+ }
+
+ /**
+ * Return only unique items from the collection array.
+ *
+ * @param (callable(TValue, TKey): mixed)|string|null $key
+ * @param bool $strict
+ * @return static
+ */
+ public function unique($key = null, $strict = false)
+ {
+ $callback = $this->valueRetriever($key);
+
+ $exists = [];
+
+ return $this->reject(function ($item, $key) use ($callback, $strict, &$exists) {
+ if (in_array($id = $callback($item, $key), $exists, $strict)) {
+ return true;
+ }
+
+ $exists[] = $id;
+ });
+ }
+
+ /**
+ * Return only unique items from the collection array using strict comparison.
+ *
+ * @param (callable(TValue, TKey): mixed)|string|null $key
+ * @return static
+ */
+ public function uniqueStrict($key = null)
+ {
+ return $this->unique($key, true);
+ }
+
+ /**
+ * Collect the values into a collection.
+ *
+ * @return \Illuminate\Support\Collection<TKey, TValue>
+ */
+ public function collect()
+ {
+ return new Collection($this->all());
+ }
+
+ /**
+ * Get the collection of items as a plain array.
+ *
+ * @return array<TKey, mixed>
+ */
+ public function toArray()
+ {
+ return $this->map(fn ($value) => $value instanceof Arrayable ? $value->toArray() : $value)->all();
+ }
+
+ /**
+ * Convert the object into something JSON serializable.
+ *
+ * @return array<TKey, mixed>
+ */
+ public function jsonSerialize(): array
+ {
+ return array_map(function ($value) {
+ if ($value instanceof JsonSerializable) {
+ return $value->jsonSerialize();
+ } elseif ($value instanceof Jsonable) {
+ return json_decode($value->toJson(), true);
+ } elseif ($value instanceof Arrayable) {
+ return $value->toArray();
+ }
+
+ return $value;
+ }, $this->all());
+ }
+
+ /**
+ * Get the collection of items as JSON.
+ *
+ * @param int $options
+ * @return string
+ */
+ public function toJson($options = 0)
+ {
+ return json_encode($this->jsonSerialize(), $options);
+ }
+
+ /**
+ * Get a CachingIterator instance.
+ *
+ * @param int $flags
+ * @return \CachingIterator
+ */
+ public function getCachingIterator($flags = CachingIterator::CALL_TOSTRING)
+ {
+ return new CachingIterator($this->getIterator(), $flags);
+ }
+
+ /**
+ * Convert the collection to its string representation.
+ *
+ * @return string
+ */
+ public function __toString()
+ {
+ return $this->escapeWhenCastingToString
+ ? e($this->toJson())
+ : $this->toJson();
+ }
+
+ /**
+ * Indicate that the model's string representation should be escaped when __toString is invoked.
+ *
+ * @param bool $escape
+ * @return $this
+ */
+ public function escapeWhenCastingToString($escape = true)
+ {
+ $this->escapeWhenCastingToString = $escape;
+
+ return $this;
+ }
+
+ /**
+ * Add a method to the list of proxied methods.
+ *
+ * @param string $method
+ * @return void
+ */
+ public static function proxy($method)
+ {
+ static::$proxies[] = $method;
+ }
+
+ /**
+ * Dynamically access collection proxies.
+ *
+ * @param string $key
+ * @return mixed
+ *
+ * @throws \Exception
+ */
+ public function __get($key)
+ {
+ if (! in_array($key, static::$proxies)) {
+ throw new Exception("Property [{$key}] does not exist on this collection instance.");
+ }
+
+ return new HigherOrderCollectionProxy($this, $key);
+ }
+
+ /**
+ * Results array of items from Collection or Arrayable.
+ *
+ * @param mixed $items
+ * @return array<TKey, TValue>
+ */
+ protected function getArrayableItems($items)
+ {
+ if (is_array($items)) {
+ return $items;
+ }
+
+ return match (true) {
+ $items instanceof WeakMap => throw new InvalidArgumentException('Collections can not be created using instances of WeakMap.'),
+ $items instanceof Enumerable => $items->all(),
+ $items instanceof Arrayable => $items->toArray(),
+ $items instanceof Traversable => iterator_to_array($items),
+ $items instanceof Jsonable => json_decode($items->toJson(), true),
+ $items instanceof JsonSerializable => (array) $items->jsonSerialize(),
+ $items instanceof UnitEnum => [$items],
+ default => (array) $items,
+ };
+ }
+
+ /**
+ * Get an operator checker callback.
+ *
+ * @param callable|string $key
+ * @param string|null $operator
+ * @param mixed $value
+ * @return \Closure
+ */
+ protected function operatorForWhere($key, $operator = null, $value = null)
+ {
+ if ($this->useAsCallable($key)) {
+ return $key;
+ }
+
+ if (func_num_args() === 1) {
+ $value = true;
+
+ $operator = '=';
+ }
+
+ if (func_num_args() === 2) {
+ $value = $operator;
+
+ $operator = '=';
+ }
+
+ return function ($item) use ($key, $operator, $value) {
+ $retrieved = data_get($item, $key);
+
+ $strings = array_filter([$retrieved, $value], function ($value) {
+ return is_string($value) || (is_object($value) && method_exists($value, '__toString'));
+ });
+
+ if (count($strings) < 2 && count(array_filter([$retrieved, $value], 'is_object')) == 1) {
+ return in_array($operator, ['!=', '<>', '!==']);
+ }
+
+ switch ($operator) {
+ default:
+ case '=':
+ case '==': return $retrieved == $value;
+ case '!=':
+ case '<>': return $retrieved != $value;
+ case '<': return $retrieved < $value;
+ case '>': return $retrieved > $value;
+ case '<=': return $retrieved <= $value;
+ case '>=': return $retrieved >= $value;
+ case '===': return $retrieved === $value;
+ case '!==': return $retrieved !== $value;
+ case '<=>': return $retrieved <=> $value;
+ }
+ };
+ }
+
+ /**
+ * Determine if the given value is callable, but not a string.
+ *
+ * @param mixed $value
+ * @return bool
+ */
+ protected function useAsCallable($value)
+ {
+ return ! is_string($value) && is_callable($value);
+ }
+
+ /**
+ * Get a value retrieving callback.
+ *
+ * @param callable|string|null $value
+ * @return callable
+ */
+ protected function valueRetriever($value)
+ {
+ if ($this->useAsCallable($value)) {
+ return $value;
+ }
+
+ return fn ($item) => data_get($item, $value);
+ }
+
+ /**
+ * Make a function to check an item's equality.
+ *
+ * @param mixed $value
+ * @return \Closure(mixed): bool
+ */
+ protected function equality($value)
+ {
+ return fn ($item) => $item === $value;
+ }
+
+ /**
+ * Make a function using another function, by negating its result.
+ *
+ * @param \Closure $callback
+ * @return \Closure
+ */
+ protected function negate(Closure $callback)
+ {
+ return fn (...$params) => ! $callback(...$params);
+ }
+
+ /**
+ * Make a function that returns what's passed to it.
+ *
+ * @return \Closure(TValue): TValue
+ */
+ protected function identity()
+ {
+ return fn ($value) => $value;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/composer.json
new file mode 100644
index 0000000..5e11a78
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/composer.json
@@ -0,0 +1,42 @@
+{
+ "name": "illuminate/collections",
+ "description": "The Illuminate Collections package.",
+ "license": "MIT",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "require": {
+ "php": "^8.1",
+ "illuminate/conditionable": "^10.0",
+ "illuminate/contracts": "^10.0",
+ "illuminate/macroable": "^10.0"
+ },
+ "autoload": {
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ },
+ "files": [
+ "helpers.php"
+ ]
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "suggest": {
+ "symfony/var-dumper": "Required to use the dump method (^6.2)."
+ },
+ "config": {
+ "sort-packages": true
+ },
+ "minimum-stability": "dev"
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/functions.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/functions.php
new file mode 100644
index 0000000..6ccd9b3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/functions.php
@@ -0,0 +1,27 @@
+<?php
+
+namespace Illuminate\Support;
+
+if (! function_exists('Illuminate\Support\enum_value')) {
+ /**
+ * Return a scalar value for the given value that might be an enum.
+ *
+ * @internal
+ *
+ * @template TValue
+ * @template TDefault
+ *
+ * @param TValue $value
+ * @param TDefault|callable(TValue): TDefault $default
+ * @return ($value is empty ? TDefault : mixed)
+ */
+ function enum_value($value, $default = null)
+ {
+ return match (true) {
+ $value instanceof \BackedEnum => $value->value,
+ $value instanceof \UnitEnum => $value->name,
+
+ default => $value ?? value($default),
+ };
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/helpers.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/helpers.php
new file mode 100644
index 0000000..235edce
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/collections/helpers.php
@@ -0,0 +1,226 @@
+<?php
+
+use Illuminate\Support\Arr;
+use Illuminate\Support\Collection;
+
+if (! function_exists('collect')) {
+ /**
+ * Create a collection from the given value.
+ *
+ * @template TKey of array-key
+ * @template TValue
+ *
+ * @param \Illuminate\Contracts\Support\Arrayable<TKey, TValue>|iterable<TKey, TValue>|null $value
+ * @return \Illuminate\Support\Collection<TKey, TValue>
+ */
+ function collect($value = [])
+ {
+ return new Collection($value);
+ }
+}
+
+if (! function_exists('data_fill')) {
+ /**
+ * Fill in data where it's missing.
+ *
+ * @param mixed $target
+ * @param string|array $key
+ * @param mixed $value
+ * @return mixed
+ */
+ function data_fill(&$target, $key, $value)
+ {
+ return data_set($target, $key, $value, false);
+ }
+}
+
+if (! function_exists('data_get')) {
+ /**
+ * Get an item from an array or object using "dot" notation.
+ *
+ * @param mixed $target
+ * @param string|array|int|null $key
+ * @param mixed $default
+ * @return mixed
+ */
+ function data_get($target, $key, $default = null)
+ {
+ if (is_null($key)) {
+ return $target;
+ }
+
+ $key = is_array($key) ? $key : explode('.', $key);
+
+ foreach ($key as $i => $segment) {
+ unset($key[$i]);
+
+ if (is_null($segment)) {
+ return $target;
+ }
+
+ if ($segment === '*') {
+ if ($target instanceof Collection) {
+ $target = $target->all();
+ } elseif (! is_iterable($target)) {
+ return value($default);
+ }
+
+ $result = [];
+
+ foreach ($target as $item) {
+ $result[] = data_get($item, $key);
+ }
+
+ return in_array('*', $key) ? Arr::collapse($result) : $result;
+ }
+
+ if (Arr::accessible($target) && Arr::exists($target, $segment)) {
+ $target = $target[$segment];
+ } elseif (is_object($target) && isset($target->{$segment})) {
+ $target = $target->{$segment};
+ } else {
+ return value($default);
+ }
+ }
+
+ return $target;
+ }
+}
+
+if (! function_exists('data_set')) {
+ /**
+ * Set an item on an array or object using dot notation.
+ *
+ * @param mixed $target
+ * @param string|array $key
+ * @param mixed $value
+ * @param bool $overwrite
+ * @return mixed
+ */
+ function data_set(&$target, $key, $value, $overwrite = true)
+ {
+ $segments = is_array($key) ? $key : explode('.', $key);
+
+ if (($segment = array_shift($segments)) === '*') {
+ if (! Arr::accessible($target)) {
+ $target = [];
+ }
+
+ if ($segments) {
+ foreach ($target as &$inner) {
+ data_set($inner, $segments, $value, $overwrite);
+ }
+ } elseif ($overwrite) {
+ foreach ($target as &$inner) {
+ $inner = $value;
+ }
+ }
+ } elseif (Arr::accessible($target)) {
+ if ($segments) {
+ if (! Arr::exists($target, $segment)) {
+ $target[$segment] = [];
+ }
+
+ data_set($target[$segment], $segments, $value, $overwrite);
+ } elseif ($overwrite || ! Arr::exists($target, $segment)) {
+ $target[$segment] = $value;
+ }
+ } elseif (is_object($target)) {
+ if ($segments) {
+ if (! isset($target->{$segment})) {
+ $target->{$segment} = [];
+ }
+
+ data_set($target->{$segment}, $segments, $value, $overwrite);
+ } elseif ($overwrite || ! isset($target->{$segment})) {
+ $target->{$segment} = $value;
+ }
+ } else {
+ $target = [];
+
+ if ($segments) {
+ data_set($target[$segment], $segments, $value, $overwrite);
+ } elseif ($overwrite) {
+ $target[$segment] = $value;
+ }
+ }
+
+ return $target;
+ }
+}
+
+if (! function_exists('data_forget')) {
+ /**
+ * Remove / unset an item from an array or object using "dot" notation.
+ *
+ * @param mixed $target
+ * @param string|array|int|null $key
+ * @return mixed
+ */
+ function data_forget(&$target, $key)
+ {
+ $segments = is_array($key) ? $key : explode('.', $key);
+
+ if (($segment = array_shift($segments)) === '*' && Arr::accessible($target)) {
+ if ($segments) {
+ foreach ($target as &$inner) {
+ data_forget($inner, $segments);
+ }
+ }
+ } elseif (Arr::accessible($target)) {
+ if ($segments && Arr::exists($target, $segment)) {
+ data_forget($target[$segment], $segments);
+ } else {
+ Arr::forget($target, $segment);
+ }
+ } elseif (is_object($target)) {
+ if ($segments && isset($target->{$segment})) {
+ data_forget($target->{$segment}, $segments);
+ } elseif (isset($target->{$segment})) {
+ unset($target->{$segment});
+ }
+ }
+
+ return $target;
+ }
+}
+
+if (! function_exists('head')) {
+ /**
+ * Get the first element of an array. Useful for method chaining.
+ *
+ * @param array $array
+ * @return mixed
+ */
+ function head($array)
+ {
+ return reset($array);
+ }
+}
+
+if (! function_exists('last')) {
+ /**
+ * Get the last element from an array.
+ *
+ * @param array $array
+ * @return mixed
+ */
+ function last($array)
+ {
+ return end($array);
+ }
+}
+
+if (! function_exists('value')) {
+ /**
+ * Return the default value of the given value.
+ *
+ * @param mixed $value
+ * @param mixed ...$args
+ * @return mixed
+ */
+ function value($value, ...$args)
+ {
+ return $value instanceof Closure ? $value(...$args) : $value;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/HigherOrderWhenProxy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/HigherOrderWhenProxy.php
new file mode 100644
index 0000000..579114c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/HigherOrderWhenProxy.php
@@ -0,0 +1,109 @@
+<?php
+
+namespace Illuminate\Support;
+
+class HigherOrderWhenProxy
+{
+ /**
+ * The target being conditionally operated on.
+ *
+ * @var mixed
+ */
+ protected $target;
+
+ /**
+ * The condition for proxying.
+ *
+ * @var bool
+ */
+ protected $condition;
+
+ /**
+ * Indicates whether the proxy has a condition.
+ *
+ * @var bool
+ */
+ protected $hasCondition = false;
+
+ /**
+ * Determine whether the condition should be negated.
+ *
+ * @var bool
+ */
+ protected $negateConditionOnCapture;
+
+ /**
+ * Create a new proxy instance.
+ *
+ * @param mixed $target
+ * @return void
+ */
+ public function __construct($target)
+ {
+ $this->target = $target;
+ }
+
+ /**
+ * Set the condition on the proxy.
+ *
+ * @param bool $condition
+ * @return $this
+ */
+ public function condition($condition)
+ {
+ [$this->condition, $this->hasCondition] = [$condition, true];
+
+ return $this;
+ }
+
+ /**
+ * Indicate that the condition should be negated.
+ *
+ * @return $this
+ */
+ public function negateConditionOnCapture()
+ {
+ $this->negateConditionOnCapture = true;
+
+ return $this;
+ }
+
+ /**
+ * Proxy accessing an attribute onto the target.
+ *
+ * @param string $key
+ * @return mixed
+ */
+ public function __get($key)
+ {
+ if (! $this->hasCondition) {
+ $condition = $this->target->{$key};
+
+ return $this->condition($this->negateConditionOnCapture ? ! $condition : $condition);
+ }
+
+ return $this->condition
+ ? $this->target->{$key}
+ : $this->target;
+ }
+
+ /**
+ * Proxy a method call on the target.
+ *
+ * @param string $method
+ * @param array $parameters
+ * @return mixed
+ */
+ public function __call($method, $parameters)
+ {
+ if (! $this->hasCondition) {
+ $condition = $this->target->{$method}(...$parameters);
+
+ return $this->condition($this->negateConditionOnCapture ? ! $condition : $condition);
+ }
+
+ return $this->condition
+ ? $this->target->{$method}(...$parameters)
+ : $this->target;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/LICENSE.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/LICENSE.md
new file mode 100644
index 0000000..79810c8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/LICENSE.md
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Taylor Otwell
+
+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/illuminate/conditionable/Traits/Conditionable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/Traits/Conditionable.php
new file mode 100644
index 0000000..5e3194b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/Traits/Conditionable.php
@@ -0,0 +1,73 @@
+<?php
+
+namespace Illuminate\Support\Traits;
+
+use Closure;
+use Illuminate\Support\HigherOrderWhenProxy;
+
+trait Conditionable
+{
+ /**
+ * Apply the callback if the given "value" is (or resolves to) truthy.
+ *
+ * @template TWhenParameter
+ * @template TWhenReturnType
+ *
+ * @param (\Closure($this): TWhenParameter)|TWhenParameter|null $value
+ * @param (callable($this, TWhenParameter): TWhenReturnType)|null $callback
+ * @param (callable($this, TWhenParameter): TWhenReturnType)|null $default
+ * @return $this|TWhenReturnType
+ */
+ public function when($value = null, ?callable $callback = null, ?callable $default = null)
+ {
+ $value = $value instanceof Closure ? $value($this) : $value;
+
+ if (func_num_args() === 0) {
+ return new HigherOrderWhenProxy($this);
+ }
+
+ if (func_num_args() === 1) {
+ return (new HigherOrderWhenProxy($this))->condition($value);
+ }
+
+ if ($value) {
+ return $callback($this, $value) ?? $this;
+ } elseif ($default) {
+ return $default($this, $value) ?? $this;
+ }
+
+ return $this;
+ }
+
+ /**
+ * Apply the callback if the given "value" is (or resolves to) falsy.
+ *
+ * @template TUnlessParameter
+ * @template TUnlessReturnType
+ *
+ * @param (\Closure($this): TUnlessParameter)|TUnlessParameter|null $value
+ * @param (callable($this, TUnlessParameter): TUnlessReturnType)|null $callback
+ * @param (callable($this, TUnlessParameter): TUnlessReturnType)|null $default
+ * @return $this|TUnlessReturnType
+ */
+ public function unless($value = null, ?callable $callback = null, ?callable $default = null)
+ {
+ $value = $value instanceof Closure ? $value($this) : $value;
+
+ if (func_num_args() === 0) {
+ return (new HigherOrderWhenProxy($this))->negateConditionOnCapture();
+ }
+
+ if (func_num_args() === 1) {
+ return (new HigherOrderWhenProxy($this))->condition(! $value);
+ }
+
+ if (! $value) {
+ return $callback($this, $value) ?? $this;
+ } elseif ($default) {
+ return $default($this, $value) ?? $this;
+ }
+
+ return $this;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/composer.json
new file mode 100644
index 0000000..40b0808
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/conditionable/composer.json
@@ -0,0 +1,33 @@
+{
+ "name": "illuminate/conditionable",
+ "description": "The Illuminate Conditionable package.",
+ "license": "MIT",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "require": {
+ "php": "^8.0.2"
+ },
+ "autoload": {
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "config": {
+ "sort-packages": true
+ },
+ "minimum-stability": "dev"
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Auth/Access/Gate.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Auth/Access/Gate.php
index b88ab17..eb605d8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Auth/Access/Gate.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Auth/Access/Gate.php
@@ -57,18 +57,18 @@
public function after(callable $callback);
/**
- * Determine if the given ability should be granted for the current user.
+ * Determine if all of the given abilities should be granted for the current user.
*
- * @param string $ability
+ * @param iterable|string $ability
* @param array|mixed $arguments
* @return bool
*/
public function allows($ability, $arguments = []);
/**
- * Determine if the given ability should be denied for the current user.
+ * Determine if any of the given abilities should be denied for the current user.
*
- * @param string $ability
+ * @param iterable|string $ability
* @param array|mixed $arguments
* @return bool
*/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/ShouldBeUnique.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/ShouldBeUnique.php
new file mode 100644
index 0000000..c72b7a8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Broadcasting/ShouldBeUnique.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace Illuminate\Contracts\Broadcasting;
+
+interface ShouldBeUnique
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cache/Repository.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cache/Repository.php
index 5b78af5..4bc4638 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cache/Repository.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cache/Repository.php
@@ -10,9 +10,11 @@
/**
* Retrieve an item from the cache and delete it.
*
- * @param string $key
- * @param mixed $default
- * @return mixed
+ * @template TCacheValue
+ *
+ * @param array|string $key
+ * @param TCacheValue|(\Closure(): TCacheValue) $default
+ * @return (TCacheValue is null ? mixed : TCacheValue)
*/
public function pull($key, $default = null);
@@ -66,28 +68,34 @@
/**
* Get an item from the cache, or execute the given Closure and store the result.
*
+ * @template TCacheValue
+ *
* @param string $key
- * @param \DateTimeInterface|\DateInterval|int|null $ttl
- * @param \Closure $callback
- * @return mixed
+ * @param \DateTimeInterface|\DateInterval|\Closure|int|null $ttl
+ * @param \Closure(): TCacheValue $callback
+ * @return TCacheValue
*/
public function remember($key, $ttl, Closure $callback);
/**
* Get an item from the cache, or execute the given Closure and store the result forever.
*
+ * @template TCacheValue
+ *
* @param string $key
- * @param \Closure $callback
- * @return mixed
+ * @param \Closure(): TCacheValue $callback
+ * @return TCacheValue
*/
public function sear($key, Closure $callback);
/**
* Get an item from the cache, or execute the given Closure and store the result forever.
*
+ * @template TCacheValue
+ *
* @param string $key
- * @param \Closure $callback
- * @return mixed
+ * @param \Closure(): TCacheValue $callback
+ * @return TCacheValue
*/
public function rememberForever($key, Closure $callback);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Console/Isolatable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Console/Isolatable.php
new file mode 100644
index 0000000..d652be3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Console/Isolatable.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace Illuminate\Contracts\Console;
+
+interface Isolatable
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Console/PromptsForMissingInput.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Console/PromptsForMissingInput.php
new file mode 100644
index 0000000..ccac1ed
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Console/PromptsForMissingInput.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace Illuminate\Contracts\Console;
+
+interface PromptsForMissingInput
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php
index 7d7f2c9..1472a2e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/Container.php
@@ -54,6 +54,15 @@
public function bind($abstract, $concrete = null, $shared = false);
/**
+ * Bind a callback to resolve with Container::call.
+ *
+ * @param array|string $method
+ * @param \Closure $callback
+ * @return void
+ */
+ public function bindMethod($method, $callback);
+
+ /**
* Register a binding if it hasn't already been registered.
*
* @param string $abstract
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php
index 1fc7fc1..1d84ef8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Container/ContextualBindingBuilder.php
@@ -32,7 +32,7 @@
* Specify the configuration item to bind as a primitive.
*
* @param string $key
- * @param ?string $default
+ * @param mixed $default
* @return void
*/
public function giveConfig($key, $default = null);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cookie/QueueingFactory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cookie/QueueingFactory.php
index d6c74b8..2d5f51a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cookie/QueueingFactory.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Cookie/QueueingFactory.php
@@ -7,7 +7,7 @@
/**
* Queue a cookie to send with the next response.
*
- * @param array $parameters
+ * @param mixed ...$parameters
* @return void
*/
public function queue(...$parameters);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/Castable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/Castable.php
index 911b1cf..776d4fc 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/Castable.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/Castable.php
@@ -8,8 +8,7 @@
* Get the name of the caster class to use when casting from / to this cast target.
*
* @param array $arguments
- * @return string
- * @return string|\Illuminate\Contracts\Database\Eloquent\CastsAttributes|\Illuminate\Contracts\Database\Eloquent\CastsInboundAttributes
+ * @return class-string<CastsAttributes|CastsInboundAttributes>|CastsAttributes|CastsInboundAttributes
*/
public static function castUsing(array $arguments);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsAttributes.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsAttributes.php
index 808d005..89cec66 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsAttributes.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsAttributes.php
@@ -2,6 +2,12 @@
namespace Illuminate\Contracts\Database\Eloquent;
+use Illuminate\Database\Eloquent\Model;
+
+/**
+ * @template TGet
+ * @template TSet
+ */
interface CastsAttributes
{
/**
@@ -10,19 +16,19 @@
* @param \Illuminate\Database\Eloquent\Model $model
* @param string $key
* @param mixed $value
- * @param array $attributes
- * @return mixed
+ * @param array<string, mixed> $attributes
+ * @return TGet|null
*/
- public function get($model, string $key, $value, array $attributes);
+ public function get(Model $model, string $key, mixed $value, array $attributes);
/**
* Transform the attribute to its underlying model values.
*
* @param \Illuminate\Database\Eloquent\Model $model
* @param string $key
- * @param mixed $value
- * @param array $attributes
+ * @param TSet|null $value
+ * @param array<string, mixed> $attributes
* @return mixed
*/
- public function set($model, string $key, $value, array $attributes);
+ public function set(Model $model, string $key, mixed $value, array $attributes);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsInboundAttributes.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsInboundAttributes.php
index 4c7801b..6a3e2ef 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsInboundAttributes.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/CastsInboundAttributes.php
@@ -2,6 +2,8 @@
namespace Illuminate\Contracts\Database\Eloquent;
+use Illuminate\Database\Eloquent\Model;
+
interface CastsInboundAttributes
{
/**
@@ -13,5 +15,5 @@
* @param array $attributes
* @return mixed
*/
- public function set($model, string $key, $value, array $attributes);
+ public function set(Model $model, string $key, mixed $value, array $attributes);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/SerializesCastableAttributes.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/SerializesCastableAttributes.php
index a89f910..a2ecf16 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/SerializesCastableAttributes.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Eloquent/SerializesCastableAttributes.php
@@ -2,6 +2,8 @@
namespace Illuminate\Contracts\Database\Eloquent;
+use Illuminate\Database\Eloquent\Model;
+
interface SerializesCastableAttributes
{
/**
@@ -13,5 +15,5 @@
* @param array $attributes
* @return mixed
*/
- public function serialize($model, string $key, $value, array $attributes);
+ public function serialize(Model $model, string $key, mixed $value, array $attributes);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/ModelIdentifier.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/ModelIdentifier.php
index 9893d28..aacd18c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/ModelIdentifier.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/ModelIdentifier.php
@@ -35,6 +35,13 @@
public $connection;
/**
+ * The class name of the model collection.
+ *
+ * @var string|null
+ */
+ public $collectionClass;
+
+ /**
* Create a new model identifier.
*
* @param string $class
@@ -50,4 +57,17 @@
$this->relations = $relations;
$this->connection = $connection;
}
+
+ /**
+ * Specify the collection class that should be used when serializing / restoring collections.
+ *
+ * @param string|null $collectionClass
+ * @return $this
+ */
+ public function useCollectionClass(?string $collectionClass)
+ {
+ $this->collectionClass = $collectionClass;
+
+ return $this;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Query/ConditionExpression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Query/ConditionExpression.php
new file mode 100644
index 0000000..b2e97a6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Query/ConditionExpression.php
@@ -0,0 +1,7 @@
+<?php
+
+namespace Illuminate\Contracts\Database\Query;
+
+interface ConditionExpression extends Expression
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Query/Expression.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Query/Expression.php
new file mode 100644
index 0000000..9e08682
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Database/Query/Expression.php
@@ -0,0 +1,16 @@
+<?php
+
+namespace Illuminate\Contracts\Database\Query;
+
+use Illuminate\Database\Grammar;
+
+interface Expression
+{
+ /**
+ * Get the value of the expression.
+ *
+ * @param \Illuminate\Database\Grammar $grammar
+ * @return string|int|float
+ */
+ public function getValue(Grammar $grammar);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/Dispatcher.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/Dispatcher.php
index 6386106..7f4096a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/Dispatcher.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/Dispatcher.php
@@ -34,7 +34,7 @@
*
* @param string|object $event
* @param mixed $payload
- * @return array|null
+ * @return mixed
*/
public function until($event, $payload = []);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/ShouldDispatchAfterCommit.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/ShouldDispatchAfterCommit.php
new file mode 100644
index 0000000..8f1fbdd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/ShouldDispatchAfterCommit.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace Illuminate\Contracts\Events;
+
+interface ShouldDispatchAfterCommit
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/ShouldHandleEventsAfterCommit.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/ShouldHandleEventsAfterCommit.php
new file mode 100644
index 0000000..8c70510
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Events/ShouldHandleEventsAfterCommit.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace Illuminate\Contracts\Events;
+
+interface ShouldHandleEventsAfterCommit
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Filesystem/Filesystem.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Filesystem/Filesystem.php
index 6d2fd57..e92d7ef 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Filesystem/Filesystem.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Filesystem/Filesystem.php
@@ -46,7 +46,7 @@
* Write the contents of a file.
*
* @param string $path
- * @param string|resource $contents
+ * @param \Psr\Http\Message\StreamInterface|\Illuminate\Http\File|\Illuminate\Http\UploadedFile|string|resource $contents
* @param mixed $options
* @return bool
*/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Foundation/Application.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Foundation/Application.php
index b46c6de..f768eb9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Foundation/Application.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Foundation/Application.php
@@ -46,6 +46,22 @@
public function databasePath($path = '');
/**
+ * Get the path to the language files.
+ *
+ * @param string $path
+ * @return string
+ */
+ public function langPath($path = '');
+
+ /**
+ * Get the path to the public directory.
+ *
+ * @param string $path
+ * @return string
+ */
+ public function publicPath($path = '');
+
+ /**
* Get the path to the resources directory.
*
* @param string $path
@@ -64,7 +80,7 @@
/**
* Get or check the current application environment.
*
- * @param string|array $environments
+ * @param string|array ...$environments
* @return string|bool
*/
public function environment(...$environments);
@@ -84,6 +100,13 @@
public function runningUnitTests();
/**
+ * Determine if the application is running with debug mode enabled.
+ *
+ * @return bool
+ */
+ public function hasDebugModeEnabled();
+
+ /**
* Get an instance of the maintenance mode manager implementation.
*
* @return \Illuminate\Contracts\Foundation\MaintenanceMode
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Attachable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Attachable.php
new file mode 100644
index 0000000..6804ec3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Attachable.php
@@ -0,0 +1,13 @@
+<?php
+
+namespace Illuminate\Contracts\Mail;
+
+interface Attachable
+{
+ /**
+ * Get an attachment instance for this entity.
+ *
+ * @return \Illuminate\Mail\Attachment
+ */
+ public function toMailAttachment();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailable.php
index c5df7e8..b7fdd42 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailable.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailable.php
@@ -10,7 +10,7 @@
* Send the message using the given mailer.
*
* @param \Illuminate\Contracts\Mail\Factory|\Illuminate\Contracts\Mail\Mailer $mailer
- * @return void
+ * @return \Illuminate\Mail\SentMessage|null
*/
public function send($mailer);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailer.php
index 38f9e3b..4d97f3e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailer.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Mail/Mailer.php
@@ -25,7 +25,7 @@
*
* @param string $text
* @param mixed $callback
- * @return void
+ * @return \Illuminate\Mail\SentMessage|null
*/
public function raw($text, $callback);
@@ -35,7 +35,7 @@
* @param \Illuminate\Contracts\Mail\Mailable|string|array $view
* @param array $data
* @param \Closure|string|null $callback
- * @return void
+ * @return \Illuminate\Mail\SentMessage|null
*/
public function send($view, array $data = [], $callback = null);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/CursorPaginator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/CursorPaginator.php
index 2d62d3a..c6b96fb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/CursorPaginator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/CursorPaginator.php
@@ -30,6 +30,13 @@
public function fragment($fragment = null);
/**
+ * Add all current query string values to the paginator.
+ *
+ * @return $this
+ */
+ public function withQueryString();
+
+ /**
* Get the URL for the previous page, or null.
*
* @return string|null
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/Paginator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/Paginator.php
index 49bafaa..04201ce 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/Paginator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Pagination/Paginator.php
@@ -15,7 +15,7 @@
/**
* Add a set of query string values to the paginator.
*
- * @param array|string $key
+ * @param array|string|null $key
* @param string|null $value
* @return $this
*/
@@ -25,7 +25,7 @@
* Get / set the URL fragment to be appended to URLs.
*
* @param string|null $fragment
- * @return $this|string
+ * @return $this|string|null
*/
public function fragment($fragment = null);
@@ -53,14 +53,14 @@
/**
* Get the "index" of the first item being paginated.
*
- * @return int
+ * @return int|null
*/
public function firstItem();
/**
* Get the "index" of the last item being paginated.
*
- * @return int
+ * @return int|null
*/
public function lastItem();
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Process/InvokedProcess.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Process/InvokedProcess.php
new file mode 100644
index 0000000..d272d37
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Process/InvokedProcess.php
@@ -0,0 +1,64 @@
+<?php
+
+namespace Illuminate\Contracts\Process;
+
+interface InvokedProcess
+{
+ /**
+ * Get the process ID if the process is still running.
+ *
+ * @return int|null
+ */
+ public function id();
+
+ /**
+ * Send a signal to the process.
+ *
+ * @param int $signal
+ * @return $this
+ */
+ public function signal(int $signal);
+
+ /**
+ * Determine if the process is still running.
+ *
+ * @return bool
+ */
+ public function running();
+
+ /**
+ * Get the standard output for the process.
+ *
+ * @return string
+ */
+ public function output();
+
+ /**
+ * Get the error output for the process.
+ *
+ * @return string
+ */
+ public function errorOutput();
+
+ /**
+ * Get the latest standard output for the process.
+ *
+ * @return string
+ */
+ public function latestOutput();
+
+ /**
+ * Get the latest error output for the process.
+ *
+ * @return string
+ */
+ public function latestErrorOutput();
+
+ /**
+ * Wait for the process to finish.
+ *
+ * @param callable|null $output
+ * @return \Illuminate\Console\Process\ProcessResult
+ */
+ public function wait(callable $output = null);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Process/ProcessResult.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Process/ProcessResult.php
new file mode 100644
index 0000000..702701e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Process/ProcessResult.php
@@ -0,0 +1,65 @@
+<?php
+
+namespace Illuminate\Contracts\Process;
+
+interface ProcessResult
+{
+ /**
+ * Get the original command executed by the process.
+ *
+ * @return string
+ */
+ public function command();
+
+ /**
+ * Determine if the process was successful.
+ *
+ * @return bool
+ */
+ public function successful();
+
+ /**
+ * Determine if the process failed.
+ *
+ * @return bool
+ */
+ public function failed();
+
+ /**
+ * Get the exit code of the process.
+ *
+ * @return int|null
+ */
+ public function exitCode();
+
+ /**
+ * Get the standard output of the process.
+ *
+ * @return string
+ */
+ public function output();
+
+ /**
+ * Get the error output of the process.
+ *
+ * @return string
+ */
+ public function errorOutput();
+
+ /**
+ * Throw an exception if the process failed.
+ *
+ * @param callable|null $callback
+ * @return $this
+ */
+ public function throw(callable $callback = null);
+
+ /**
+ * Throw an exception if the process failed and the given condition is true.
+ *
+ * @param bool $condition
+ * @param callable|null $callback
+ * @return $this
+ */
+ public function throwIf(bool $condition, callable $callback = null);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Queue/Monitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Queue/Monitor.php
index 7da62d3..87677f0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Queue/Monitor.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Queue/Monitor.php
@@ -13,7 +13,7 @@
public function looping($callback);
/**
- * Register a callback to be executed when a job fails after the maximum amount of retries.
+ * Register a callback to be executed when a job fails after the maximum number of retries.
*
* @param mixed $callback
* @return void
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Queue/ShouldQueueAfterCommit.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Queue/ShouldQueueAfterCommit.php
new file mode 100644
index 0000000..8545ad3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Queue/ShouldQueueAfterCommit.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace Illuminate\Contracts\Queue;
+
+interface ShouldQueueAfterCommit extends ShouldQueue
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php
index 86c16ca..0aa51d5 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Routing/ResponseFactory.php
@@ -60,7 +60,7 @@
/**
* Create a new streamed response instance.
*
- * @param \Closure $callback
+ * @param callable $callback
* @param int $status
* @param array $headers
* @return \Symfony\Component\HttpFoundation\StreamedResponse
@@ -70,7 +70,7 @@
/**
* Create a new streamed response instance as a file download.
*
- * @param \Closure $callback
+ * @param callable $callback
* @param string|null $name
* @param array $headers
* @param string|null $disposition
@@ -123,7 +123,7 @@
/**
* Create a new redirect response to a controller action.
*
- * @param string $action
+ * @param array|string $action
* @param mixed $parameters
* @param int $status
* @param array $headers
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Session/Middleware/AuthenticatesSessions.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Session/Middleware/AuthenticatesSessions.php
new file mode 100644
index 0000000..113f420
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Session/Middleware/AuthenticatesSessions.php
@@ -0,0 +1,8 @@
+<?php
+
+namespace Illuminate\Contracts\Session\Middleware;
+
+interface AuthenticatesSessions
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Support/MessageBag.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Support/MessageBag.php
index 7f708ac..14855d0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Support/MessageBag.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Support/MessageBag.php
@@ -65,6 +65,14 @@
public function all($format = null);
/**
+ * Remove a message from the bag.
+ *
+ * @param string $key
+ * @return $this
+ */
+ public function forget($key);
+
+ /**
* Get the raw messages in the container.
*
* @return array
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Translation/Translator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Translation/Translator.php
index 6eae491..ded1a8b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Translation/Translator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Translation/Translator.php
@@ -18,7 +18,7 @@
* Get a translation according to an integer value.
*
* @param string $key
- * @param \Countable|int|array $number
+ * @param \Countable|int|float|array $number
* @param array $replace
* @param string|null $locale
* @return string
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/DataAwareRule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/DataAwareRule.php
index 7ec7ab5..739626c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/DataAwareRule.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/DataAwareRule.php
@@ -10,5 +10,5 @@
* @param array $data
* @return $this
*/
- public function setData($data);
+ public function setData(array $data);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Factory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Factory.php
index 104675a..70687e8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Factory.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Factory.php
@@ -10,10 +10,10 @@
* @param array $data
* @param array $rules
* @param array $messages
- * @param array $customAttributes
+ * @param array $attributes
* @return \Illuminate\Contracts\Validation\Validator
*/
- public function make(array $data, array $rules, array $messages = [], array $customAttributes = []);
+ public function make(array $data, array $rules, array $messages = [], array $attributes = []);
/**
* Register a custom validator extension.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ImplicitRule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ImplicitRule.php
index bbc64f4..ac5df83 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ImplicitRule.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ImplicitRule.php
@@ -2,6 +2,9 @@
namespace Illuminate\Contracts\Validation;
+/**
+ * @deprecated see ValidationRule
+ */
interface ImplicitRule extends Rule
{
//
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/InvokableRule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/InvokableRule.php
new file mode 100644
index 0000000..c7ac9c2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/InvokableRule.php
@@ -0,0 +1,21 @@
+<?php
+
+namespace Illuminate\Contracts\Validation;
+
+use Closure;
+
+/**
+ * @deprecated see ValidationRule
+ */
+interface InvokableRule
+{
+ /**
+ * Run the validation rule.
+ *
+ * @param string $attribute
+ * @param mixed $value
+ * @param \Closure(string): \Illuminate\Translation\PotentiallyTranslatedString $fail
+ * @return void
+ */
+ public function __invoke(string $attribute, mixed $value, Closure $fail);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Rule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Rule.php
index cc03777..102cc53 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Rule.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/Rule.php
@@ -2,6 +2,9 @@
namespace Illuminate\Contracts\Validation;
+/**
+ * @deprecated see ValidationRule
+ */
interface Rule
{
/**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ValidationRule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ValidationRule.php
new file mode 100644
index 0000000..1c95b97
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ValidationRule.php
@@ -0,0 +1,18 @@
+<?php
+
+namespace Illuminate\Contracts\Validation;
+
+use Closure;
+
+interface ValidationRule
+{
+ /**
+ * Run the validation rule.
+ *
+ * @param string $attribute
+ * @param mixed $value
+ * @param \Closure(string): \Illuminate\Translation\PotentiallyTranslatedString $fail
+ * @return void
+ */
+ public function validate(string $attribute, mixed $value, Closure $fail): void;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ValidatorAwareRule.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ValidatorAwareRule.php
index 053f4fa..0baf274 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ValidatorAwareRule.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/Validation/ValidatorAwareRule.php
@@ -2,6 +2,8 @@
namespace Illuminate\Contracts\Validation;
+use Illuminate\Validation\Validator;
+
interface ValidatorAwareRule
{
/**
@@ -10,5 +12,5 @@
* @param \Illuminate\Validation\Validator $validator
* @return $this
*/
- public function setValidator($validator);
+ public function setValidator(Validator $validator);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/View/ViewCompilationException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/View/ViewCompilationException.php
new file mode 100644
index 0000000..5c57619
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/View/ViewCompilationException.php
@@ -0,0 +1,10 @@
+<?php
+
+namespace Illuminate\Contracts\View;
+
+use Exception;
+
+class ViewCompilationException extends Exception
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/composer.json
index 9296ba9..acae4be 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/contracts/composer.json
@@ -14,7 +14,7 @@
}
],
"require": {
- "php": "^8.0.2",
+ "php": "^8.1",
"psr/container": "^1.1.1|^2.0.1",
"psr/simple-cache": "^1.0|^2.0|^3.0"
},
@@ -25,7 +25,7 @@
},
"extra": {
"branch-alias": {
- "dev-master": "9.x-dev"
+ "dev-master": "10.x-dev"
}
},
"config": {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/LICENSE.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/LICENSE.md
new file mode 100644
index 0000000..79810c8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/LICENSE.md
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Taylor Otwell
+
+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/illuminate/macroable/Traits/Macroable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/Traits/Macroable.php
new file mode 100644
index 0000000..3e6d96a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/Traits/Macroable.php
@@ -0,0 +1,125 @@
+<?php
+
+namespace Illuminate\Support\Traits;
+
+use BadMethodCallException;
+use Closure;
+use ReflectionClass;
+use ReflectionMethod;
+
+trait Macroable
+{
+ /**
+ * The registered string macros.
+ *
+ * @var array
+ */
+ protected static $macros = [];
+
+ /**
+ * Register a custom macro.
+ *
+ * @param string $name
+ * @param object|callable $macro
+ * @return void
+ */
+ public static function macro($name, $macro)
+ {
+ static::$macros[$name] = $macro;
+ }
+
+ /**
+ * Mix another object into the class.
+ *
+ * @param object $mixin
+ * @param bool $replace
+ * @return void
+ *
+ * @throws \ReflectionException
+ */
+ public static function mixin($mixin, $replace = true)
+ {
+ $methods = (new ReflectionClass($mixin))->getMethods(
+ ReflectionMethod::IS_PUBLIC | ReflectionMethod::IS_PROTECTED
+ );
+
+ foreach ($methods as $method) {
+ if ($replace || ! static::hasMacro($method->name)) {
+ static::macro($method->name, $method->invoke($mixin));
+ }
+ }
+ }
+
+ /**
+ * Checks if macro is registered.
+ *
+ * @param string $name
+ * @return bool
+ */
+ public static function hasMacro($name)
+ {
+ return isset(static::$macros[$name]);
+ }
+
+ /**
+ * Flush the existing macros.
+ *
+ * @return void
+ */
+ public static function flushMacros()
+ {
+ static::$macros = [];
+ }
+
+ /**
+ * Dynamically handle calls to the class.
+ *
+ * @param string $method
+ * @param array $parameters
+ * @return mixed
+ *
+ * @throws \BadMethodCallException
+ */
+ public static function __callStatic($method, $parameters)
+ {
+ if (! static::hasMacro($method)) {
+ throw new BadMethodCallException(sprintf(
+ 'Method %s::%s does not exist.', static::class, $method
+ ));
+ }
+
+ $macro = static::$macros[$method];
+
+ if ($macro instanceof Closure) {
+ $macro = $macro->bindTo(null, static::class);
+ }
+
+ return $macro(...$parameters);
+ }
+
+ /**
+ * Dynamically handle calls to the class.
+ *
+ * @param string $method
+ * @param array $parameters
+ * @return mixed
+ *
+ * @throws \BadMethodCallException
+ */
+ public function __call($method, $parameters)
+ {
+ if (! static::hasMacro($method)) {
+ throw new BadMethodCallException(sprintf(
+ 'Method %s::%s does not exist.', static::class, $method
+ ));
+ }
+
+ $macro = static::$macros[$method];
+
+ if ($macro instanceof Closure) {
+ $macro = $macro->bindTo($this, static::class);
+ }
+
+ return $macro(...$parameters);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/composer.json
new file mode 100644
index 0000000..231d233
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/illuminate/macroable/composer.json
@@ -0,0 +1,33 @@
+{
+ "name": "illuminate/macroable",
+ "description": "The Illuminate Macroable package.",
+ "license": "MIT",
+ "homepage": "https://laravel.com",
+ "support": {
+ "issues": "https://github.com/laravel/framework/issues",
+ "source": "https://github.com/laravel/framework"
+ },
+ "authors": [
+ {
+ "name": "Taylor Otwell",
+ "email": "taylor@laravel.com"
+ }
+ ],
+ "require": {
+ "php": "^8.1"
+ },
+ "autoload": {
+ "psr-4": {
+ "Illuminate\\Support\\": ""
+ }
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "10.x-dev"
+ }
+ },
+ "config": {
+ "sort-packages": true
+ },
+ "minimum-stability": "dev"
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/LICENSE
new file mode 100644
index 0000000..7dfa39b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2013-2020 Alex Bilbie <hello@alexbilbie.com>
+
+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/league/oauth2-client/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/README.md
new file mode 100644
index 0000000..cbb449d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/README.md
@@ -0,0 +1,58 @@
+# OAuth 2.0 Client
+
+This package provides a base for integrating with [OAuth 2.0](http://oauth.net/2/) service providers.
+
+[](https://gitter.im/thephpleague/oauth2-client)
+[](https://github.com/thephpleague/oauth2-client)
+[](https://github.com/thephpleague/oauth2-client/releases)
+[](https://github.com/thephpleague/oauth2-client/blob/master/LICENSE)
+[](https://github.com/thephpleague/oauth2-client/actions?query=workflow%3ACI)
+[](https://codecov.io/gh/thephpleague/oauth2-client)
+[](https://packagist.org/packages/league/oauth2-client)
+
+---
+
+The OAuth 2.0 login flow, seen commonly around the web in the form of "Connect with Facebook/Google/etc." buttons, is a common integration added to web applications, but it can be tricky and tedious to do right. To help, we've created the `league/oauth2-client` package, which provides a base for integrating with various OAuth 2.0 providers, without overburdening your application with the concerns of [RFC 6749](http://tools.ietf.org/html/rfc6749).
+
+This OAuth 2.0 client library will work with any OAuth 2.0 provider that conforms to the OAuth 2.0 Authorization Framework. Out-of-the-box, we provide a `GenericProvider` class to connect to any service provider that uses [Bearer tokens](http://tools.ietf.org/html/rfc6750). See our [basic usage guide](https://oauth2-client.thephpleague.com/usage/) for examples using `GenericProvider`.
+
+Many service providers provide additional functionality above and beyond the OAuth 2.0 specification. For this reason, you may extend and wrap this library to support additional behavior. There are already many [official](https://oauth2-client.thephpleague.com/providers/league/) and [third-party](https://oauth2-client.thephpleague.com/providers/thirdparty/) provider clients available (e.g., Facebook, GitHub, Google, Instagram, LinkedIn, etc.). If your provider isn't in the list, feel free to add it.
+
+This package is compliant with [PSR-1][], [PSR-2][], [PSR-4][], and [PSR-7][]. If you notice compliance oversights, please send a patch via pull request. If you're interested in contributing to this library, please take a look at our [contributing guidelines](https://github.com/thephpleague/oauth2-client/blob/master/CONTRIBUTING.md).
+
+## Requirements
+
+We support the following versions of PHP:
+
+* PHP 8.1
+* PHP 8.0
+* PHP 7.4
+* PHP 7.3
+* PHP 7.2
+* PHP 7.1
+* PHP 7.0
+* PHP 5.6
+
+## Provider Clients
+
+We provide a list of [official PHP League provider clients](https://oauth2-client.thephpleague.com/providers/league/), as well as [third-party provider clients](https://oauth2-client.thephpleague.com/providers/thirdparty/).
+
+To build your own provider client, please refer to "[Implementing a Provider Client](https://oauth2-client.thephpleague.com/providers/implementing/)."
+
+## Usage
+
+For usage and code examples, check out our [basic usage guide](https://oauth2-client.thephpleague.com/usage/).
+
+## Contributing
+
+Please see [our contributing guidelines](https://github.com/thephpleague/oauth2-client/blob/master/CONTRIBUTING.md) for details.
+
+## License
+
+The MIT License (MIT). Please see [LICENSE](https://github.com/thephpleague/oauth2-client/blob/master/LICENSE) for more information.
+
+
+[PSR-1]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-1-basic-coding-standard.md
+[PSR-2]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md
+[PSR-4]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-4-autoloader.md
+[PSR-7]: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-7-http-message.md
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/composer.json
new file mode 100644
index 0000000..59201f4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/composer.json
@@ -0,0 +1,58 @@
+{
+ "name": "league/oauth2-client",
+ "description": "OAuth 2.0 Client Library",
+ "license": "MIT",
+ "config": {
+ "sort-packages": true
+ },
+ "require": {
+ "php": "^5.6 || ^7.0 || ^8.0",
+ "guzzlehttp/guzzle": "^6.0 || ^7.0",
+ "paragonie/random_compat": "^1 || ^2 || ^9.99"
+ },
+ "require-dev": {
+ "mockery/mockery": "^1.3.5",
+ "php-parallel-lint/php-parallel-lint": "^1.3.1",
+ "phpunit/phpunit": "^5.7 || ^6.0 || ^9.5",
+ "squizlabs/php_codesniffer": "^2.3 || ^3.0"
+ },
+ "keywords": [
+ "oauth",
+ "oauth2",
+ "authorization",
+ "authentication",
+ "idp",
+ "identity",
+ "sso",
+ "single sign on"
+ ],
+ "authors": [
+ {
+ "name": "Alex Bilbie",
+ "email": "hello@alexbilbie.com",
+ "homepage": "http://www.alexbilbie.com",
+ "role": "Developer"
+ },
+ {
+ "name": "Woody Gilk",
+ "homepage": "https://github.com/shadowhand",
+ "role": "Contributor"
+ }
+
+ ],
+ "autoload": {
+ "psr-4": {
+ "League\\OAuth2\\Client\\": "src/"
+ }
+ },
+ "autoload-dev": {
+ "psr-4": {
+ "League\\OAuth2\\Client\\Test\\": "test/src/"
+ }
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-2.x": "2.0.x-dev"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/AbstractGrant.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/AbstractGrant.php
new file mode 100644
index 0000000..2c0244b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/AbstractGrant.php
@@ -0,0 +1,80 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Grant;
+
+use League\OAuth2\Client\Tool\RequiredParameterTrait;
+
+/**
+ * Represents a type of authorization grant.
+ *
+ * An authorization grant is a credential representing the resource
+ * owner's authorization (to access its protected resources) used by the
+ * client to obtain an access token. OAuth 2.0 defines four
+ * grant types -- authorization code, implicit, resource owner password
+ * credentials, and client credentials -- as well as an extensibility
+ * mechanism for defining additional types.
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-1.3 Authorization Grant (RFC 6749, §1.3)
+ */
+abstract class AbstractGrant
+{
+ use RequiredParameterTrait;
+
+ /**
+ * Returns the name of this grant, eg. 'grant_name', which is used as the
+ * grant type when encoding URL query parameters.
+ *
+ * @return string
+ */
+ abstract protected function getName();
+
+ /**
+ * Returns a list of all required request parameters.
+ *
+ * @return array
+ */
+ abstract protected function getRequiredRequestParameters();
+
+ /**
+ * Returns this grant's name as its string representation. This allows for
+ * string interpolation when building URL query parameters.
+ *
+ * @return string
+ */
+ public function __toString()
+ {
+ return $this->getName();
+ }
+
+ /**
+ * Prepares an access token request's parameters by checking that all
+ * required parameters are set, then merging with any given defaults.
+ *
+ * @param array $defaults
+ * @param array $options
+ * @return array
+ */
+ public function prepareRequestParameters(array $defaults, array $options)
+ {
+ $defaults['grant_type'] = $this->getName();
+
+ $required = $this->getRequiredRequestParameters();
+ $provided = array_merge($defaults, $options);
+
+ $this->checkRequiredParameters($required, $provided);
+
+ return $provided;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/AuthorizationCode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/AuthorizationCode.php
new file mode 100644
index 0000000..c49460c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/AuthorizationCode.php
@@ -0,0 +1,41 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Grant;
+
+/**
+ * Represents an authorization code grant.
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-1.3.1 Authorization Code (RFC 6749, §1.3.1)
+ */
+class AuthorizationCode extends AbstractGrant
+{
+ /**
+ * @inheritdoc
+ */
+ protected function getName()
+ {
+ return 'authorization_code';
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getRequiredRequestParameters()
+ {
+ return [
+ 'code',
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/ClientCredentials.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/ClientCredentials.php
new file mode 100644
index 0000000..dc78c4f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/ClientCredentials.php
@@ -0,0 +1,39 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Grant;
+
+/**
+ * Represents a client credentials grant.
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-1.3.4 Client Credentials (RFC 6749, §1.3.4)
+ */
+class ClientCredentials extends AbstractGrant
+{
+ /**
+ * @inheritdoc
+ */
+ protected function getName()
+ {
+ return 'client_credentials';
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getRequiredRequestParameters()
+ {
+ return [];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/Exception/InvalidGrantException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/Exception/InvalidGrantException.php
new file mode 100644
index 0000000..c3c4e67
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/Exception/InvalidGrantException.php
@@ -0,0 +1,26 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Grant\Exception;
+
+use InvalidArgumentException;
+
+/**
+ * Exception thrown if the grant does not extend from AbstractGrant.
+ *
+ * @see League\OAuth2\Client\Grant\AbstractGrant
+ */
+class InvalidGrantException extends InvalidArgumentException
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/GrantFactory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/GrantFactory.php
new file mode 100644
index 0000000..71990e8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/GrantFactory.php
@@ -0,0 +1,104 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Grant;
+
+use League\OAuth2\Client\Grant\Exception\InvalidGrantException;
+
+/**
+ * Represents a factory used when retrieving an authorization grant type.
+ */
+class GrantFactory
+{
+ /**
+ * @var array
+ */
+ protected $registry = [];
+
+ /**
+ * Defines a grant singleton in the registry.
+ *
+ * @param string $name
+ * @param AbstractGrant $grant
+ * @return self
+ */
+ public function setGrant($name, AbstractGrant $grant)
+ {
+ $this->registry[$name] = $grant;
+
+ return $this;
+ }
+
+ /**
+ * Returns a grant singleton by name.
+ *
+ * If the grant has not be registered, a default grant will be loaded.
+ *
+ * @param string $name
+ * @return AbstractGrant
+ */
+ public function getGrant($name)
+ {
+ if (empty($this->registry[$name])) {
+ $this->registerDefaultGrant($name);
+ }
+
+ return $this->registry[$name];
+ }
+
+ /**
+ * Registers a default grant singleton by name.
+ *
+ * @param string $name
+ * @return self
+ */
+ protected function registerDefaultGrant($name)
+ {
+ // PascalCase the grant. E.g: 'authorization_code' becomes 'AuthorizationCode'
+ $class = str_replace(' ', '', ucwords(str_replace(['-', '_'], ' ', $name)));
+ $class = 'League\\OAuth2\\Client\\Grant\\' . $class;
+
+ $this->checkGrant($class);
+
+ return $this->setGrant($name, new $class);
+ }
+
+ /**
+ * Determines if a variable is a valid grant.
+ *
+ * @param mixed $class
+ * @return boolean
+ */
+ public function isGrant($class)
+ {
+ return is_subclass_of($class, AbstractGrant::class);
+ }
+
+ /**
+ * Checks if a variable is a valid grant.
+ *
+ * @throws InvalidGrantException
+ * @param mixed $class
+ * @return void
+ */
+ public function checkGrant($class)
+ {
+ if (!$this->isGrant($class)) {
+ throw new InvalidGrantException(sprintf(
+ 'Grant "%s" must extend AbstractGrant',
+ is_object($class) ? get_class($class) : $class
+ ));
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/Password.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/Password.php
new file mode 100644
index 0000000..6543b2e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/Password.php
@@ -0,0 +1,42 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Grant;
+
+/**
+ * Represents a resource owner password credentials grant.
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-1.3.3 Resource Owner Password Credentials (RFC 6749, §1.3.3)
+ */
+class Password extends AbstractGrant
+{
+ /**
+ * @inheritdoc
+ */
+ protected function getName()
+ {
+ return 'password';
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getRequiredRequestParameters()
+ {
+ return [
+ 'username',
+ 'password',
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/RefreshToken.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/RefreshToken.php
new file mode 100644
index 0000000..8192182
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Grant/RefreshToken.php
@@ -0,0 +1,41 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Grant;
+
+/**
+ * Represents a refresh token grant.
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-6 Refreshing an Access Token (RFC 6749, §6)
+ */
+class RefreshToken extends AbstractGrant
+{
+ /**
+ * @inheritdoc
+ */
+ protected function getName()
+ {
+ return 'refresh_token';
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getRequiredRequestParameters()
+ {
+ return [
+ 'refresh_token',
+ ];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/HttpBasicAuthOptionProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/HttpBasicAuthOptionProvider.php
new file mode 100644
index 0000000..3da4065
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/HttpBasicAuthOptionProvider.php
@@ -0,0 +1,42 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\OptionProvider;
+
+use InvalidArgumentException;
+
+/**
+ * Add http basic auth into access token request options
+ * @link https://tools.ietf.org/html/rfc6749#section-2.3.1
+ */
+class HttpBasicAuthOptionProvider extends PostAuthOptionProvider
+{
+ /**
+ * @inheritdoc
+ */
+ public function getAccessTokenOptions($method, array $params)
+ {
+ if (empty($params['client_id']) || empty($params['client_secret'])) {
+ throw new InvalidArgumentException('clientId and clientSecret are required for http basic auth');
+ }
+
+ $encodedCredentials = base64_encode(sprintf('%s:%s', $params['client_id'], $params['client_secret']));
+ unset($params['client_id'], $params['client_secret']);
+
+ $options = parent::getAccessTokenOptions($method, $params);
+ $options['headers']['Authorization'] = 'Basic ' . $encodedCredentials;
+
+ return $options;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/OptionProviderInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/OptionProviderInterface.php
new file mode 100644
index 0000000..1126d25
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/OptionProviderInterface.php
@@ -0,0 +1,30 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\OptionProvider;
+
+/**
+ * Interface for access token options provider
+ */
+interface OptionProviderInterface
+{
+ /**
+ * Builds request options used for requesting an access token.
+ *
+ * @param string $method
+ * @param array $params
+ * @return array
+ */
+ public function getAccessTokenOptions($method, array $params);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/PostAuthOptionProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/PostAuthOptionProvider.php
new file mode 100644
index 0000000..12d920e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/OptionProvider/PostAuthOptionProvider.php
@@ -0,0 +1,51 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\OptionProvider;
+
+use League\OAuth2\Client\Provider\AbstractProvider;
+use League\OAuth2\Client\Tool\QueryBuilderTrait;
+
+/**
+ * Provide options for access token
+ */
+class PostAuthOptionProvider implements OptionProviderInterface
+{
+ use QueryBuilderTrait;
+
+ /**
+ * @inheritdoc
+ */
+ public function getAccessTokenOptions($method, array $params)
+ {
+ $options = ['headers' => ['content-type' => 'application/x-www-form-urlencoded']];
+
+ if ($method === AbstractProvider::METHOD_POST) {
+ $options['body'] = $this->getAccessTokenBody($params);
+ }
+
+ return $options;
+ }
+
+ /**
+ * Returns the request body for requesting an access token.
+ *
+ * @param array $params
+ * @return string
+ */
+ protected function getAccessTokenBody(array $params)
+ {
+ return $this->buildQueryString($params);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/AbstractProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/AbstractProvider.php
new file mode 100644
index 0000000..293a54d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/AbstractProvider.php
@@ -0,0 +1,941 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Provider;
+
+use GuzzleHttp\Client as HttpClient;
+use GuzzleHttp\ClientInterface as HttpClientInterface;
+use GuzzleHttp\Exception\BadResponseException;
+use InvalidArgumentException;
+use League\OAuth2\Client\Grant\AbstractGrant;
+use League\OAuth2\Client\Grant\GrantFactory;
+use League\OAuth2\Client\OptionProvider\OptionProviderInterface;
+use League\OAuth2\Client\OptionProvider\PostAuthOptionProvider;
+use League\OAuth2\Client\Provider\Exception\IdentityProviderException;
+use League\OAuth2\Client\Token\AccessToken;
+use League\OAuth2\Client\Token\AccessTokenInterface;
+use League\OAuth2\Client\Tool\ArrayAccessorTrait;
+use League\OAuth2\Client\Tool\GuardedPropertyTrait;
+use League\OAuth2\Client\Tool\QueryBuilderTrait;
+use League\OAuth2\Client\Tool\RequestFactory;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+use UnexpectedValueException;
+
+/**
+ * Represents a service provider (authorization server).
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-1.1 Roles (RFC 6749, §1.1)
+ */
+abstract class AbstractProvider
+{
+ use ArrayAccessorTrait;
+ use GuardedPropertyTrait;
+ use QueryBuilderTrait;
+
+ /**
+ * @var string|null Key used in a token response to identify the resource owner.
+ */
+ const ACCESS_TOKEN_RESOURCE_OWNER_ID = null;
+
+ /**
+ * @var string HTTP method used to fetch access tokens.
+ */
+ const METHOD_GET = 'GET';
+
+ /**
+ * @var string HTTP method used to fetch access tokens.
+ */
+ const METHOD_POST = 'POST';
+
+ /**
+ * @var string PKCE method used to fetch authorization token.
+ * The PKCE code challenge will be hashed with sha256 (recommended).
+ */
+ const PKCE_METHOD_S256 = 'S256';
+
+ /**
+ * @var string PKCE method used to fetch authorization token.
+ * The PKCE code challenge will be sent as plain text, this is NOT recommended.
+ * Only use `plain` if no other option is possible.
+ */
+ const PKCE_METHOD_PLAIN = 'plain';
+
+ /**
+ * @var string
+ */
+ protected $clientId;
+
+ /**
+ * @var string
+ */
+ protected $clientSecret;
+
+ /**
+ * @var string
+ */
+ protected $redirectUri;
+
+ /**
+ * @var string
+ */
+ protected $state;
+
+ /**
+ * @var string|null
+ */
+ protected $pkceCode = null;
+
+ /**
+ * @var GrantFactory
+ */
+ protected $grantFactory;
+
+ /**
+ * @var RequestFactory
+ */
+ protected $requestFactory;
+
+ /**
+ * @var HttpClientInterface
+ */
+ protected $httpClient;
+
+ /**
+ * @var OptionProviderInterface
+ */
+ protected $optionProvider;
+
+ /**
+ * Constructs an OAuth 2.0 service provider.
+ *
+ * @param array $options An array of options to set on this provider.
+ * Options include `clientId`, `clientSecret`, `redirectUri`, and `state`.
+ * Individual providers may introduce more options, as needed.
+ * @param array $collaborators An array of collaborators that may be used to
+ * override this provider's default behavior. Collaborators include
+ * `grantFactory`, `requestFactory`, and `httpClient`.
+ * Individual providers may introduce more collaborators, as needed.
+ */
+ public function __construct(array $options = [], array $collaborators = [])
+ {
+ // We'll let the GuardedPropertyTrait handle mass assignment of incoming
+ // options, skipping any blacklisted properties defined in the provider
+ $this->fillProperties($options);
+
+ if (empty($collaborators['grantFactory'])) {
+ $collaborators['grantFactory'] = new GrantFactory();
+ }
+ $this->setGrantFactory($collaborators['grantFactory']);
+
+ if (empty($collaborators['requestFactory'])) {
+ $collaborators['requestFactory'] = new RequestFactory();
+ }
+ $this->setRequestFactory($collaborators['requestFactory']);
+
+ if (empty($collaborators['httpClient'])) {
+ $client_options = $this->getAllowedClientOptions($options);
+
+ $collaborators['httpClient'] = new HttpClient(
+ array_intersect_key($options, array_flip($client_options))
+ );
+ }
+ $this->setHttpClient($collaborators['httpClient']);
+
+ if (empty($collaborators['optionProvider'])) {
+ $collaborators['optionProvider'] = new PostAuthOptionProvider();
+ }
+ $this->setOptionProvider($collaborators['optionProvider']);
+ }
+
+ /**
+ * Returns the list of options that can be passed to the HttpClient
+ *
+ * @param array $options An array of options to set on this provider.
+ * Options include `clientId`, `clientSecret`, `redirectUri`, and `state`.
+ * Individual providers may introduce more options, as needed.
+ * @return array The options to pass to the HttpClient constructor
+ */
+ protected function getAllowedClientOptions(array $options)
+ {
+ $client_options = ['timeout', 'proxy'];
+
+ // Only allow turning off ssl verification if it's for a proxy
+ if (!empty($options['proxy'])) {
+ $client_options[] = 'verify';
+ }
+
+ return $client_options;
+ }
+
+ /**
+ * Sets the grant factory instance.
+ *
+ * @param GrantFactory $factory
+ * @return self
+ */
+ public function setGrantFactory(GrantFactory $factory)
+ {
+ $this->grantFactory = $factory;
+
+ return $this;
+ }
+
+ /**
+ * Returns the current grant factory instance.
+ *
+ * @return GrantFactory
+ */
+ public function getGrantFactory()
+ {
+ return $this->grantFactory;
+ }
+
+ /**
+ * Sets the request factory instance.
+ *
+ * @param RequestFactory $factory
+ * @return self
+ */
+ public function setRequestFactory(RequestFactory $factory)
+ {
+ $this->requestFactory = $factory;
+
+ return $this;
+ }
+
+ /**
+ * Returns the request factory instance.
+ *
+ * @return RequestFactory
+ */
+ public function getRequestFactory()
+ {
+ return $this->requestFactory;
+ }
+
+ /**
+ * Sets the HTTP client instance.
+ *
+ * @param HttpClientInterface $client
+ * @return self
+ */
+ public function setHttpClient(HttpClientInterface $client)
+ {
+ $this->httpClient = $client;
+
+ return $this;
+ }
+
+ /**
+ * Returns the HTTP client instance.
+ *
+ * @return HttpClientInterface
+ */
+ public function getHttpClient()
+ {
+ return $this->httpClient;
+ }
+
+ /**
+ * Sets the option provider instance.
+ *
+ * @param OptionProviderInterface $provider
+ * @return self
+ */
+ public function setOptionProvider(OptionProviderInterface $provider)
+ {
+ $this->optionProvider = $provider;
+
+ return $this;
+ }
+
+ /**
+ * Returns the option provider instance.
+ *
+ * @return OptionProviderInterface
+ */
+ public function getOptionProvider()
+ {
+ return $this->optionProvider;
+ }
+
+ /**
+ * Returns the current value of the state parameter.
+ *
+ * This can be accessed by the redirect handler during authorization.
+ *
+ * @return string
+ */
+ public function getState()
+ {
+ return $this->state;
+ }
+
+ /**
+ * Set the value of the pkceCode parameter.
+ *
+ * When using PKCE this should be set before requesting an access token.
+ *
+ * @param string $pkceCode
+ * @return self
+ */
+ public function setPkceCode($pkceCode)
+ {
+ $this->pkceCode = $pkceCode;
+ return $this;
+ }
+
+ /**
+ * Returns the current value of the pkceCode parameter.
+ *
+ * This can be accessed by the redirect handler during authorization.
+ *
+ * @return string|null
+ */
+ public function getPkceCode()
+ {
+ return $this->pkceCode;
+ }
+
+ /**
+ * Returns the base URL for authorizing a client.
+ *
+ * Eg. https://oauth.service.com/authorize
+ *
+ * @return string
+ */
+ abstract public function getBaseAuthorizationUrl();
+
+ /**
+ * Returns the base URL for requesting an access token.
+ *
+ * Eg. https://oauth.service.com/token
+ *
+ * @param array $params
+ * @return string
+ */
+ abstract public function getBaseAccessTokenUrl(array $params);
+
+ /**
+ * Returns the URL for requesting the resource owner's details.
+ *
+ * @param AccessToken $token
+ * @return string
+ */
+ abstract public function getResourceOwnerDetailsUrl(AccessToken $token);
+
+ /**
+ * Returns a new random string to use as the state parameter in an
+ * authorization flow.
+ *
+ * @param int $length Length of the random string to be generated.
+ * @return string
+ */
+ protected function getRandomState($length = 32)
+ {
+ // Converting bytes to hex will always double length. Hence, we can reduce
+ // the amount of bytes by half to produce the correct length.
+ return bin2hex(random_bytes($length / 2));
+ }
+
+ /**
+ * Returns a new random string to use as PKCE code_verifier and
+ * hashed as code_challenge parameters in an authorization flow.
+ * Must be between 43 and 128 characters long.
+ *
+ * @param int $length Length of the random string to be generated.
+ * @return string
+ */
+ protected function getRandomPkceCode($length = 64)
+ {
+ return substr(
+ strtr(
+ base64_encode(random_bytes($length)),
+ '+/',
+ '-_'
+ ),
+ 0,
+ $length
+ );
+ }
+
+ /**
+ * Returns the default scopes used by this provider.
+ *
+ * This should only be the scopes that are required to request the details
+ * of the resource owner, rather than all the available scopes.
+ *
+ * @return array
+ */
+ abstract protected function getDefaultScopes();
+
+ /**
+ * Returns the string that should be used to separate scopes when building
+ * the URL for requesting an access token.
+ *
+ * @return string Scope separator, defaults to ','
+ */
+ protected function getScopeSeparator()
+ {
+ return ',';
+ }
+
+ /**
+ * @return string|null
+ */
+ protected function getPkceMethod()
+ {
+ return null;
+ }
+
+ /**
+ * Returns authorization parameters based on provided options.
+ *
+ * @param array $options
+ * @return array Authorization parameters
+ */
+ protected function getAuthorizationParameters(array $options)
+ {
+ if (empty($options['state'])) {
+ $options['state'] = $this->getRandomState();
+ }
+
+ if (empty($options['scope'])) {
+ $options['scope'] = $this->getDefaultScopes();
+ }
+
+ $options += [
+ 'response_type' => 'code',
+ 'approval_prompt' => 'auto'
+ ];
+
+ if (is_array($options['scope'])) {
+ $separator = $this->getScopeSeparator();
+ $options['scope'] = implode($separator, $options['scope']);
+ }
+
+ // Store the state as it may need to be accessed later on.
+ $this->state = $options['state'];
+
+ $pkceMethod = $this->getPkceMethod();
+ if (!empty($pkceMethod)) {
+ $this->pkceCode = $this->getRandomPkceCode();
+ if ($pkceMethod === static::PKCE_METHOD_S256) {
+ $options['code_challenge'] = trim(
+ strtr(
+ base64_encode(hash('sha256', $this->pkceCode, true)),
+ '+/',
+ '-_'
+ ),
+ '='
+ );
+ } elseif ($pkceMethod === static::PKCE_METHOD_PLAIN) {
+ $options['code_challenge'] = $this->pkceCode;
+ } else {
+ throw new InvalidArgumentException('Unknown PKCE method "' . $pkceMethod . '".');
+ }
+ $options['code_challenge_method'] = $pkceMethod;
+ }
+
+ // Business code layer might set a different redirect_uri parameter
+ // depending on the context, leave it as-is
+ if (!isset($options['redirect_uri'])) {
+ $options['redirect_uri'] = $this->redirectUri;
+ }
+
+ $options['client_id'] = $this->clientId;
+
+ return $options;
+ }
+
+ /**
+ * Builds the authorization URL's query string.
+ *
+ * @param array $params Query parameters
+ * @return string Query string
+ */
+ protected function getAuthorizationQuery(array $params)
+ {
+ return $this->buildQueryString($params);
+ }
+
+ /**
+ * Builds the authorization URL.
+ *
+ * @param array $options
+ * @return string Authorization URL
+ */
+ public function getAuthorizationUrl(array $options = [])
+ {
+ $base = $this->getBaseAuthorizationUrl();
+ $params = $this->getAuthorizationParameters($options);
+ $query = $this->getAuthorizationQuery($params);
+
+ return $this->appendQuery($base, $query);
+ }
+
+ /**
+ * Redirects the client for authorization.
+ *
+ * @param array $options
+ * @param callable|null $redirectHandler
+ * @return mixed
+ */
+ public function authorize(
+ array $options = [],
+ callable $redirectHandler = null
+ ) {
+ $url = $this->getAuthorizationUrl($options);
+ if ($redirectHandler) {
+ return $redirectHandler($url, $this);
+ }
+
+ // @codeCoverageIgnoreStart
+ header('Location: ' . $url);
+ exit;
+ // @codeCoverageIgnoreEnd
+ }
+
+ /**
+ * Appends a query string to a URL.
+ *
+ * @param string $url The URL to append the query to
+ * @param string $query The HTTP query string
+ * @return string The resulting URL
+ */
+ protected function appendQuery($url, $query)
+ {
+ $query = trim($query, '?&');
+
+ if ($query) {
+ $glue = strstr($url, '?') === false ? '?' : '&';
+ return $url . $glue . $query;
+ }
+
+ return $url;
+ }
+
+ /**
+ * Returns the method to use when requesting an access token.
+ *
+ * @return string HTTP method
+ */
+ protected function getAccessTokenMethod()
+ {
+ return self::METHOD_POST;
+ }
+
+ /**
+ * Returns the key used in the access token response to identify the resource owner.
+ *
+ * @return string|null Resource owner identifier key
+ */
+ protected function getAccessTokenResourceOwnerId()
+ {
+ return static::ACCESS_TOKEN_RESOURCE_OWNER_ID;
+ }
+
+ /**
+ * Builds the access token URL's query string.
+ *
+ * @param array $params Query parameters
+ * @return string Query string
+ */
+ protected function getAccessTokenQuery(array $params)
+ {
+ return $this->buildQueryString($params);
+ }
+
+ /**
+ * Checks that a provided grant is valid, or attempts to produce one if the
+ * provided grant is a string.
+ *
+ * @param AbstractGrant|string $grant
+ * @return AbstractGrant
+ */
+ protected function verifyGrant($grant)
+ {
+ if (is_string($grant)) {
+ return $this->grantFactory->getGrant($grant);
+ }
+
+ $this->grantFactory->checkGrant($grant);
+ return $grant;
+ }
+
+ /**
+ * Returns the full URL to use when requesting an access token.
+ *
+ * @param array $params Query parameters
+ * @return string
+ */
+ protected function getAccessTokenUrl(array $params)
+ {
+ $url = $this->getBaseAccessTokenUrl($params);
+
+ if ($this->getAccessTokenMethod() === self::METHOD_GET) {
+ $query = $this->getAccessTokenQuery($params);
+ return $this->appendQuery($url, $query);
+ }
+
+ return $url;
+ }
+
+ /**
+ * Returns a prepared request for requesting an access token.
+ *
+ * @param array $params Query string parameters
+ * @return RequestInterface
+ */
+ protected function getAccessTokenRequest(array $params)
+ {
+ $method = $this->getAccessTokenMethod();
+ $url = $this->getAccessTokenUrl($params);
+ $options = $this->optionProvider->getAccessTokenOptions($this->getAccessTokenMethod(), $params);
+
+ return $this->getRequest($method, $url, $options);
+ }
+
+ /**
+ * Requests an access token using a specified grant and option set.
+ *
+ * @param mixed $grant
+ * @param array<string, mixed> $options
+ * @throws IdentityProviderException
+ * @return AccessTokenInterface
+ */
+ public function getAccessToken($grant, array $options = [])
+ {
+ $grant = $this->verifyGrant($grant);
+
+ $params = [
+ 'client_id' => $this->clientId,
+ 'client_secret' => $this->clientSecret,
+ 'redirect_uri' => $this->redirectUri,
+ ];
+
+ if (!empty($this->pkceCode)) {
+ $params['code_verifier'] = $this->pkceCode;
+ }
+
+ $params = $grant->prepareRequestParameters($params, $options);
+ $request = $this->getAccessTokenRequest($params);
+ $response = $this->getParsedResponse($request);
+ if (false === is_array($response)) {
+ throw new UnexpectedValueException(
+ 'Invalid response received from Authorization Server. Expected JSON.'
+ );
+ }
+ $prepared = $this->prepareAccessTokenResponse($response);
+ $token = $this->createAccessToken($prepared, $grant);
+
+ return $token;
+ }
+
+ /**
+ * Returns a PSR-7 request instance that is not authenticated.
+ *
+ * @param string $method
+ * @param string $url
+ * @param array $options
+ * @return RequestInterface
+ */
+ public function getRequest($method, $url, array $options = [])
+ {
+ return $this->createRequest($method, $url, null, $options);
+ }
+
+ /**
+ * Returns an authenticated PSR-7 request instance.
+ *
+ * @param string $method
+ * @param string $url
+ * @param AccessTokenInterface|string|null $token
+ * @param array $options Any of "headers", "body", and "protocolVersion".
+ * @return RequestInterface
+ */
+ public function getAuthenticatedRequest($method, $url, $token, array $options = [])
+ {
+ return $this->createRequest($method, $url, $token, $options);
+ }
+
+ /**
+ * Creates a PSR-7 request instance.
+ *
+ * @param string $method
+ * @param string $url
+ * @param AccessTokenInterface|string|null $token
+ * @param array $options
+ * @return RequestInterface
+ */
+ protected function createRequest($method, $url, $token, array $options)
+ {
+ $defaults = [
+ 'headers' => $this->getHeaders($token),
+ ];
+
+ $options = array_merge_recursive($defaults, $options);
+ $factory = $this->getRequestFactory();
+
+ return $factory->getRequestWithOptions($method, $url, $options);
+ }
+
+ /**
+ * Sends a request instance and returns a response instance.
+ *
+ * WARNING: This method does not attempt to catch exceptions caused by HTTP
+ * errors! It is recommended to wrap this method in a try/catch block.
+ *
+ * @param RequestInterface $request
+ * @return ResponseInterface
+ */
+ public function getResponse(RequestInterface $request)
+ {
+ return $this->getHttpClient()->send($request);
+ }
+
+ /**
+ * Sends a request and returns the parsed response.
+ *
+ * @param RequestInterface $request
+ * @throws IdentityProviderException
+ * @return mixed
+ */
+ public function getParsedResponse(RequestInterface $request)
+ {
+ try {
+ $response = $this->getResponse($request);
+ } catch (BadResponseException $e) {
+ $response = $e->getResponse();
+ }
+
+ $parsed = $this->parseResponse($response);
+
+ $this->checkResponse($response, $parsed);
+
+ return $parsed;
+ }
+
+ /**
+ * Attempts to parse a JSON response.
+ *
+ * @param string $content JSON content from response body
+ * @return array Parsed JSON data
+ * @throws UnexpectedValueException if the content could not be parsed
+ */
+ protected function parseJson($content)
+ {
+ $content = json_decode($content, true);
+
+ if (json_last_error() !== JSON_ERROR_NONE) {
+ throw new UnexpectedValueException(sprintf(
+ "Failed to parse JSON response: %s",
+ json_last_error_msg()
+ ));
+ }
+
+ return $content;
+ }
+
+ /**
+ * Returns the content type header of a response.
+ *
+ * @param ResponseInterface $response
+ * @return string Semi-colon separated join of content-type headers.
+ */
+ protected function getContentType(ResponseInterface $response)
+ {
+ return join(';', (array) $response->getHeader('content-type'));
+ }
+
+ /**
+ * Parses the response according to its content-type header.
+ *
+ * @throws UnexpectedValueException
+ * @param ResponseInterface $response
+ * @return array
+ */
+ protected function parseResponse(ResponseInterface $response)
+ {
+ $content = (string) $response->getBody();
+ $type = $this->getContentType($response);
+
+ if (strpos($type, 'urlencoded') !== false) {
+ parse_str($content, $parsed);
+ return $parsed;
+ }
+
+ // Attempt to parse the string as JSON regardless of content type,
+ // since some providers use non-standard content types. Only throw an
+ // exception if the JSON could not be parsed when it was expected to.
+ try {
+ return $this->parseJson($content);
+ } catch (UnexpectedValueException $e) {
+ if (strpos($type, 'json') !== false) {
+ throw $e;
+ }
+
+ if ($response->getStatusCode() == 500) {
+ throw new UnexpectedValueException(
+ 'An OAuth server error was encountered that did not contain a JSON body',
+ 0,
+ $e
+ );
+ }
+
+ return $content;
+ }
+ }
+
+ /**
+ * Checks a provider response for errors.
+ *
+ * @throws IdentityProviderException
+ * @param ResponseInterface $response
+ * @param array|string $data Parsed response data
+ * @return void
+ */
+ abstract protected function checkResponse(ResponseInterface $response, $data);
+
+ /**
+ * Prepares an parsed access token response for a grant.
+ *
+ * Custom mapping of expiration, etc should be done here. Always call the
+ * parent method when overloading this method.
+ *
+ * @param mixed $result
+ * @return array
+ */
+ protected function prepareAccessTokenResponse(array $result)
+ {
+ if ($this->getAccessTokenResourceOwnerId() !== null) {
+ $result['resource_owner_id'] = $this->getValueByKey(
+ $result,
+ $this->getAccessTokenResourceOwnerId()
+ );
+ }
+ return $result;
+ }
+
+ /**
+ * Creates an access token from a response.
+ *
+ * The grant that was used to fetch the response can be used to provide
+ * additional context.
+ *
+ * @param array $response
+ * @param AbstractGrant $grant
+ * @return AccessTokenInterface
+ */
+ protected function createAccessToken(array $response, AbstractGrant $grant)
+ {
+ return new AccessToken($response);
+ }
+
+ /**
+ * Generates a resource owner object from a successful resource owner
+ * details request.
+ *
+ * @param array $response
+ * @param AccessToken $token
+ * @return ResourceOwnerInterface
+ */
+ abstract protected function createResourceOwner(array $response, AccessToken $token);
+
+ /**
+ * Requests and returns the resource owner of given access token.
+ *
+ * @param AccessToken $token
+ * @return ResourceOwnerInterface
+ */
+ public function getResourceOwner(AccessToken $token)
+ {
+ $response = $this->fetchResourceOwnerDetails($token);
+
+ return $this->createResourceOwner($response, $token);
+ }
+
+ /**
+ * Requests resource owner details.
+ *
+ * @param AccessToken $token
+ * @return mixed
+ */
+ protected function fetchResourceOwnerDetails(AccessToken $token)
+ {
+ $url = $this->getResourceOwnerDetailsUrl($token);
+
+ $request = $this->getAuthenticatedRequest(self::METHOD_GET, $url, $token);
+
+ $response = $this->getParsedResponse($request);
+
+ if (false === is_array($response)) {
+ throw new UnexpectedValueException(
+ 'Invalid response received from Authorization Server. Expected JSON.'
+ );
+ }
+
+ return $response;
+ }
+
+ /**
+ * Returns the default headers used by this provider.
+ *
+ * Typically this is used to set 'Accept' or 'Content-Type' headers.
+ *
+ * @return array
+ */
+ protected function getDefaultHeaders()
+ {
+ return [];
+ }
+
+ /**
+ * Returns the authorization headers used by this provider.
+ *
+ * Typically this is "Bearer" or "MAC". For more information see:
+ * http://tools.ietf.org/html/rfc6749#section-7.1
+ *
+ * No default is provided, providers must overload this method to activate
+ * authorization headers.
+ *
+ * @param mixed|null $token Either a string or an access token instance
+ * @return array
+ */
+ protected function getAuthorizationHeaders($token = null)
+ {
+ return [];
+ }
+
+ /**
+ * Returns all headers used by this provider for a request.
+ *
+ * The request will be authenticated if an access token is provided.
+ *
+ * @param mixed|null $token object or string
+ * @return array
+ */
+ public function getHeaders($token = null)
+ {
+ if ($token) {
+ return array_merge(
+ $this->getDefaultHeaders(),
+ $this->getAuthorizationHeaders($token)
+ );
+ }
+
+ return $this->getDefaultHeaders();
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/Exception/IdentityProviderException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/Exception/IdentityProviderException.php
new file mode 100644
index 0000000..55cb438
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/Exception/IdentityProviderException.php
@@ -0,0 +1,48 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Provider\Exception;
+
+/**
+ * Exception thrown if the provider response contains errors.
+ */
+class IdentityProviderException extends \Exception
+{
+ /**
+ * @var mixed
+ */
+ protected $response;
+
+ /**
+ * @param string $message
+ * @param int $code
+ * @param mixed $response The response body
+ */
+ public function __construct($message, $code, $response)
+ {
+ $this->response = $response;
+
+ parent::__construct($message, $code);
+ }
+
+ /**
+ * Returns the exception's response body.
+ *
+ * @return mixed
+ */
+ public function getResponseBody()
+ {
+ return $this->response;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/GenericProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/GenericProvider.php
new file mode 100644
index 0000000..0fc95f2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/GenericProvider.php
@@ -0,0 +1,247 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Provider;
+
+use InvalidArgumentException;
+use League\OAuth2\Client\Provider\Exception\IdentityProviderException;
+use League\OAuth2\Client\Token\AccessToken;
+use League\OAuth2\Client\Tool\BearerAuthorizationTrait;
+use Psr\Http\Message\ResponseInterface;
+
+/**
+ * Represents a generic service provider that may be used to interact with any
+ * OAuth 2.0 service provider, using Bearer token authentication.
+ */
+class GenericProvider extends AbstractProvider
+{
+ use BearerAuthorizationTrait;
+
+ /**
+ * @var string
+ */
+ private $urlAuthorize;
+
+ /**
+ * @var string
+ */
+ private $urlAccessToken;
+
+ /**
+ * @var string
+ */
+ private $urlResourceOwnerDetails;
+
+ /**
+ * @var string
+ */
+ private $accessTokenMethod;
+
+ /**
+ * @var string
+ */
+ private $accessTokenResourceOwnerId;
+
+ /**
+ * @var array|null
+ */
+ private $scopes = null;
+
+ /**
+ * @var string
+ */
+ private $scopeSeparator;
+
+ /**
+ * @var string
+ */
+ private $responseError = 'error';
+
+ /**
+ * @var string
+ */
+ private $responseCode;
+
+ /**
+ * @var string
+ */
+ private $responseResourceOwnerId = 'id';
+
+ /**
+ * @var string|null
+ */
+ private $pkceMethod = null;
+
+ /**
+ * @param array $options
+ * @param array $collaborators
+ */
+ public function __construct(array $options = [], array $collaborators = [])
+ {
+ $this->assertRequiredOptions($options);
+
+ $possible = $this->getConfigurableOptions();
+ $configured = array_intersect_key($options, array_flip($possible));
+
+ foreach ($configured as $key => $value) {
+ $this->$key = $value;
+ }
+
+ // Remove all options that are only used locally
+ $options = array_diff_key($options, $configured);
+
+ parent::__construct($options, $collaborators);
+ }
+
+ /**
+ * Returns all options that can be configured.
+ *
+ * @return array
+ */
+ protected function getConfigurableOptions()
+ {
+ return array_merge($this->getRequiredOptions(), [
+ 'accessTokenMethod',
+ 'accessTokenResourceOwnerId',
+ 'scopeSeparator',
+ 'responseError',
+ 'responseCode',
+ 'responseResourceOwnerId',
+ 'scopes',
+ 'pkceMethod',
+ ]);
+ }
+
+ /**
+ * Returns all options that are required.
+ *
+ * @return array
+ */
+ protected function getRequiredOptions()
+ {
+ return [
+ 'urlAuthorize',
+ 'urlAccessToken',
+ 'urlResourceOwnerDetails',
+ ];
+ }
+
+ /**
+ * Verifies that all required options have been passed.
+ *
+ * @param array $options
+ * @return void
+ * @throws InvalidArgumentException
+ */
+ private function assertRequiredOptions(array $options)
+ {
+ $missing = array_diff_key(array_flip($this->getRequiredOptions()), $options);
+
+ if (!empty($missing)) {
+ throw new InvalidArgumentException(
+ 'Required options not defined: ' . implode(', ', array_keys($missing))
+ );
+ }
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getBaseAuthorizationUrl()
+ {
+ return $this->urlAuthorize;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getBaseAccessTokenUrl(array $params)
+ {
+ return $this->urlAccessToken;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getResourceOwnerDetailsUrl(AccessToken $token)
+ {
+ return $this->urlResourceOwnerDetails;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getDefaultScopes()
+ {
+ return $this->scopes;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getAccessTokenMethod()
+ {
+ return $this->accessTokenMethod ?: parent::getAccessTokenMethod();
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getAccessTokenResourceOwnerId()
+ {
+ return $this->accessTokenResourceOwnerId ?: parent::getAccessTokenResourceOwnerId();
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getScopeSeparator()
+ {
+ return $this->scopeSeparator ?: parent::getScopeSeparator();
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function getPkceMethod()
+ {
+ return $this->pkceMethod ?: parent::getPkceMethod();
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function checkResponse(ResponseInterface $response, $data)
+ {
+ if (!empty($data[$this->responseError])) {
+ $error = $data[$this->responseError];
+ if (!is_string($error)) {
+ $error = var_export($error, true);
+ }
+ $code = $this->responseCode && !empty($data[$this->responseCode])? $data[$this->responseCode] : 0;
+ if (!is_int($code)) {
+ $code = intval($code);
+ }
+ throw new IdentityProviderException($error, $code, $data);
+ }
+ }
+
+ /**
+ * @inheritdoc
+ */
+ protected function createResourceOwner(array $response, AccessToken $token)
+ {
+ return new GenericResourceOwner($response, $this->responseResourceOwnerId);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/GenericResourceOwner.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/GenericResourceOwner.php
new file mode 100644
index 0000000..f876614
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/GenericResourceOwner.php
@@ -0,0 +1,61 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Provider;
+
+/**
+ * Represents a generic resource owner for use with the GenericProvider.
+ */
+class GenericResourceOwner implements ResourceOwnerInterface
+{
+ /**
+ * @var array
+ */
+ protected $response;
+
+ /**
+ * @var string
+ */
+ protected $resourceOwnerId;
+
+ /**
+ * @param array $response
+ * @param string $resourceOwnerId
+ */
+ public function __construct(array $response, $resourceOwnerId)
+ {
+ $this->response = $response;
+ $this->resourceOwnerId = $resourceOwnerId;
+ }
+
+ /**
+ * Returns the identifier of the authorized resource owner.
+ *
+ * @return mixed
+ */
+ public function getId()
+ {
+ return $this->response[$this->resourceOwnerId];
+ }
+
+ /**
+ * Returns the raw resource owner response.
+ *
+ * @return array
+ */
+ public function toArray()
+ {
+ return $this->response;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/ResourceOwnerInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/ResourceOwnerInterface.php
new file mode 100644
index 0000000..8284424
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Provider/ResourceOwnerInterface.php
@@ -0,0 +1,36 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Provider;
+
+/**
+ * Classes implementing `ResourceOwnerInterface` may be used to represent
+ * the resource owner authenticated with a service provider.
+ */
+interface ResourceOwnerInterface
+{
+ /**
+ * Returns the identifier of the authorized resource owner.
+ *
+ * @return mixed
+ */
+ public function getId();
+
+ /**
+ * Return all of the owner details available as an array.
+ *
+ * @return array
+ */
+ public function toArray();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/AccessToken.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/AccessToken.php
new file mode 100644
index 0000000..81533c3
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/AccessToken.php
@@ -0,0 +1,243 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Token;
+
+use InvalidArgumentException;
+use RuntimeException;
+
+/**
+ * Represents an access token.
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-1.4 Access Token (RFC 6749, §1.4)
+ */
+class AccessToken implements AccessTokenInterface, ResourceOwnerAccessTokenInterface
+{
+ /**
+ * @var string
+ */
+ protected $accessToken;
+
+ /**
+ * @var int
+ */
+ protected $expires;
+
+ /**
+ * @var string
+ */
+ protected $refreshToken;
+
+ /**
+ * @var string
+ */
+ protected $resourceOwnerId;
+
+ /**
+ * @var array
+ */
+ protected $values = [];
+
+ /**
+ * @var int
+ */
+ private static $timeNow;
+
+ /**
+ * Set the time now. This should only be used for testing purposes.
+ *
+ * @param int $timeNow the time in seconds since epoch
+ * @return void
+ */
+ public static function setTimeNow($timeNow)
+ {
+ self::$timeNow = $timeNow;
+ }
+
+ /**
+ * Reset the time now if it was set for test purposes.
+ *
+ * @return void
+ */
+ public static function resetTimeNow()
+ {
+ self::$timeNow = null;
+ }
+
+ /**
+ * @return int
+ */
+ public function getTimeNow()
+ {
+ return self::$timeNow ? self::$timeNow : time();
+ }
+
+ /**
+ * Constructs an access token.
+ *
+ * @param array $options An array of options returned by the service provider
+ * in the access token request. The `access_token` option is required.
+ * @throws InvalidArgumentException if `access_token` is not provided in `$options`.
+ */
+ public function __construct(array $options = [])
+ {
+ if (empty($options['access_token'])) {
+ throw new InvalidArgumentException('Required option not passed: "access_token"');
+ }
+
+ $this->accessToken = $options['access_token'];
+
+ if (!empty($options['resource_owner_id'])) {
+ $this->resourceOwnerId = $options['resource_owner_id'];
+ }
+
+ if (!empty($options['refresh_token'])) {
+ $this->refreshToken = $options['refresh_token'];
+ }
+
+ // We need to know when the token expires. Show preference to
+ // 'expires_in' since it is defined in RFC6749 Section 5.1.
+ // Defer to 'expires' if it is provided instead.
+ if (isset($options['expires_in'])) {
+ if (!is_numeric($options['expires_in'])) {
+ throw new \InvalidArgumentException('expires_in value must be an integer');
+ }
+
+ $this->expires = $options['expires_in'] != 0 ? $this->getTimeNow() + $options['expires_in'] : 0;
+ } elseif (!empty($options['expires'])) {
+ // Some providers supply the seconds until expiration rather than
+ // the exact timestamp. Take a best guess at which we received.
+ $expires = $options['expires'];
+
+ if (!$this->isExpirationTimestamp($expires)) {
+ $expires += $this->getTimeNow();
+ }
+
+ $this->expires = $expires;
+ }
+
+ // Capture any additional values that might exist in the token but are
+ // not part of the standard response. Vendors will sometimes pass
+ // additional user data this way.
+ $this->values = array_diff_key($options, array_flip([
+ 'access_token',
+ 'resource_owner_id',
+ 'refresh_token',
+ 'expires_in',
+ 'expires',
+ ]));
+ }
+
+ /**
+ * Check if a value is an expiration timestamp or second value.
+ *
+ * @param integer $value
+ * @return bool
+ */
+ protected function isExpirationTimestamp($value)
+ {
+ // If the given value is larger than the original OAuth 2 draft date,
+ // assume that it is meant to be a (possible expired) timestamp.
+ $oauth2InceptionDate = 1349067600; // 2012-10-01
+ return ($value > $oauth2InceptionDate);
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getToken()
+ {
+ return $this->accessToken;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getRefreshToken()
+ {
+ return $this->refreshToken;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getExpires()
+ {
+ return $this->expires;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getResourceOwnerId()
+ {
+ return $this->resourceOwnerId;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function hasExpired()
+ {
+ $expires = $this->getExpires();
+
+ if (empty($expires)) {
+ throw new RuntimeException('"expires" is not set on the token');
+ }
+
+ return $expires < time();
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function getValues()
+ {
+ return $this->values;
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function __toString()
+ {
+ return (string) $this->getToken();
+ }
+
+ /**
+ * @inheritdoc
+ */
+ public function jsonSerialize()
+ {
+ $parameters = $this->values;
+
+ if ($this->accessToken) {
+ $parameters['access_token'] = $this->accessToken;
+ }
+
+ if ($this->refreshToken) {
+ $parameters['refresh_token'] = $this->refreshToken;
+ }
+
+ if ($this->expires) {
+ $parameters['expires'] = $this->expires;
+ }
+
+ if ($this->resourceOwnerId) {
+ $parameters['resource_owner_id'] = $this->resourceOwnerId;
+ }
+
+ return $parameters;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/AccessTokenInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/AccessTokenInterface.php
new file mode 100644
index 0000000..5fd219f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/AccessTokenInterface.php
@@ -0,0 +1,74 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Token;
+
+use JsonSerializable;
+use ReturnTypeWillChange;
+use RuntimeException;
+
+interface AccessTokenInterface extends JsonSerializable
+{
+ /**
+ * Returns the access token string of this instance.
+ *
+ * @return string
+ */
+ public function getToken();
+
+ /**
+ * Returns the refresh token, if defined.
+ *
+ * @return string|null
+ */
+ public function getRefreshToken();
+
+ /**
+ * Returns the expiration timestamp in seconds, if defined.
+ *
+ * @return integer|null
+ */
+ public function getExpires();
+
+ /**
+ * Checks if this token has expired.
+ *
+ * @return boolean true if the token has expired, false otherwise.
+ * @throws RuntimeException if 'expires' is not set on the token.
+ */
+ public function hasExpired();
+
+ /**
+ * Returns additional vendor values stored in the token.
+ *
+ * @return array
+ */
+ public function getValues();
+
+ /**
+ * Returns a string representation of the access token
+ *
+ * @return string
+ */
+ public function __toString();
+
+ /**
+ * Returns an array of parameters to serialize when this is serialized with
+ * json_encode().
+ *
+ * @return array
+ */
+ #[ReturnTypeWillChange]
+ public function jsonSerialize();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/ResourceOwnerAccessTokenInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/ResourceOwnerAccessTokenInterface.php
new file mode 100644
index 0000000..51e4ce4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Token/ResourceOwnerAccessTokenInterface.php
@@ -0,0 +1,25 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Token;
+
+interface ResourceOwnerAccessTokenInterface extends AccessTokenInterface
+{
+ /**
+ * Returns the resource owner identifier, if defined.
+ *
+ * @return string|null
+ */
+ public function getResourceOwnerId();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/ArrayAccessorTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/ArrayAccessorTrait.php
new file mode 100644
index 0000000..a18198c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/ArrayAccessorTrait.php
@@ -0,0 +1,52 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Tool;
+
+/**
+ * Provides generic array navigation tools.
+ */
+trait ArrayAccessorTrait
+{
+ /**
+ * Returns a value by key using dot notation.
+ *
+ * @param array $data
+ * @param string $key
+ * @param mixed|null $default
+ * @return mixed
+ */
+ private function getValueByKey(array $data, $key, $default = null)
+ {
+ if (!is_string($key) || empty($key) || !count($data)) {
+ return $default;
+ }
+
+ if (strpos($key, '.') !== false) {
+ $keys = explode('.', $key);
+
+ foreach ($keys as $innerKey) {
+ if (!is_array($data) || !array_key_exists($innerKey, $data)) {
+ return $default;
+ }
+
+ $data = $data[$innerKey];
+ }
+
+ return $data;
+ }
+
+ return array_key_exists($key, $data) ? $data[$key] : $default;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/BearerAuthorizationTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/BearerAuthorizationTrait.php
new file mode 100644
index 0000000..081c7c8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/BearerAuthorizationTrait.php
@@ -0,0 +1,36 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Tool;
+
+use League\OAuth2\Client\Token\AccessTokenInterface;
+
+/**
+ * Enables `Bearer` header authorization for providers.
+ *
+ * @link http://tools.ietf.org/html/rfc6750 Bearer Token Usage (RFC 6750)
+ */
+trait BearerAuthorizationTrait
+{
+ /**
+ * Returns authorization headers for the 'bearer' grant.
+ *
+ * @param AccessTokenInterface|string|null $token Either a string or an access token instance
+ * @return array
+ */
+ protected function getAuthorizationHeaders($token = null)
+ {
+ return ['Authorization' => 'Bearer ' . $token];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/GuardedPropertyTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/GuardedPropertyTrait.php
new file mode 100644
index 0000000..02c9ba5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/GuardedPropertyTrait.php
@@ -0,0 +1,70 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Tool;
+
+/**
+ * Provides support for blacklisting explicit properties from the
+ * mass assignment behavior.
+ */
+trait GuardedPropertyTrait
+{
+ /**
+ * The properties that aren't mass assignable.
+ *
+ * @var array
+ */
+ protected $guarded = [];
+
+ /**
+ * Attempts to mass assign the given options to explicitly defined properties,
+ * skipping over any properties that are defined in the guarded array.
+ *
+ * @param array $options
+ * @return mixed
+ */
+ protected function fillProperties(array $options = [])
+ {
+ if (isset($options['guarded'])) {
+ unset($options['guarded']);
+ }
+
+ foreach ($options as $option => $value) {
+ if (property_exists($this, $option) && !$this->isGuarded($option)) {
+ $this->{$option} = $value;
+ }
+ }
+ }
+
+ /**
+ * Returns current guarded properties.
+ *
+ * @return array
+ */
+ public function getGuarded()
+ {
+ return $this->guarded;
+ }
+
+ /**
+ * Determines if the given property is guarded.
+ *
+ * @param string $property
+ * @return bool
+ */
+ public function isGuarded($property)
+ {
+ return in_array($property, $this->getGuarded());
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/MacAuthorizationTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/MacAuthorizationTrait.php
new file mode 100644
index 0000000..f8dcd77
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/MacAuthorizationTrait.php
@@ -0,0 +1,83 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Tool;
+
+use League\OAuth2\Client\Token\AccessToken;
+use League\OAuth2\Client\Token\AccessTokenInterface;
+
+/**
+ * Enables `MAC` header authorization for providers.
+ *
+ * @link http://tools.ietf.org/html/draft-ietf-oauth-v2-http-mac-05 Message Authentication Code (MAC) Tokens
+ */
+trait MacAuthorizationTrait
+{
+ /**
+ * Returns the id of this token for MAC generation.
+ *
+ * @param AccessToken $token
+ * @return string
+ */
+ abstract protected function getTokenId(AccessToken $token);
+
+ /**
+ * Returns the MAC signature for the current request.
+ *
+ * @param string $id
+ * @param integer $ts
+ * @param string $nonce
+ * @return string
+ */
+ abstract protected function getMacSignature($id, $ts, $nonce);
+
+ /**
+ * Returns a new random string to use as the state parameter in an
+ * authorization flow.
+ *
+ * @param int $length Length of the random string to be generated.
+ * @return string
+ */
+ abstract protected function getRandomState($length = 32);
+
+ /**
+ * Returns the authorization headers for the 'mac' grant.
+ *
+ * @param AccessTokenInterface|string|null $token Either a string or an access token instance
+ * @return array
+ * @codeCoverageIgnore
+ *
+ * @todo This is currently untested and provided only as an example. If you
+ * complete the implementation, please create a pull request for
+ * https://github.com/thephpleague/oauth2-client
+ */
+ protected function getAuthorizationHeaders($token = null)
+ {
+ if ($token === null) {
+ return [];
+ }
+
+ $ts = time();
+ $id = $this->getTokenId($token);
+ $nonce = $this->getRandomState(16);
+ $mac = $this->getMacSignature($id, $ts, $nonce);
+
+ $parts = [];
+ foreach (compact('id', 'ts', 'nonce', 'mac') as $key => $value) {
+ $parts[] = sprintf('%s="%s"', $key, $value);
+ }
+
+ return ['Authorization' => 'MAC ' . implode(', ', $parts)];
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/ProviderRedirectTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/ProviderRedirectTrait.php
new file mode 100644
index 0000000..f81b511
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/ProviderRedirectTrait.php
@@ -0,0 +1,122 @@
+<?php
+
+namespace League\OAuth2\Client\Tool;
+
+use GuzzleHttp\Exception\BadResponseException;
+use GuzzleHttp\Psr7\Uri;
+use InvalidArgumentException;
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+trait ProviderRedirectTrait
+{
+ /**
+ * Maximum number of times to follow provider initiated redirects
+ *
+ * @var integer
+ */
+ protected $redirectLimit = 2;
+
+ /**
+ * Retrieves a response for a given request and retrieves subsequent
+ * responses, with authorization headers, if a redirect is detected.
+ *
+ * @param RequestInterface $request
+ * @return ResponseInterface
+ * @throws BadResponseException
+ */
+ protected function followRequestRedirects(RequestInterface $request)
+ {
+ $response = null;
+ $attempts = 0;
+
+ while ($attempts < $this->redirectLimit) {
+ $attempts++;
+ $response = $this->getHttpClient()->send($request, [
+ 'allow_redirects' => false
+ ]);
+
+ if ($this->isRedirect($response)) {
+ $redirectUrl = new Uri($response->getHeader('Location')[0]);
+ $request = $request->withUri($redirectUrl);
+ } else {
+ break;
+ }
+ }
+
+ return $response;
+ }
+
+ /**
+ * Returns the HTTP client instance.
+ *
+ * @return GuzzleHttp\ClientInterface
+ */
+ abstract public function getHttpClient();
+
+ /**
+ * Retrieves current redirect limit.
+ *
+ * @return integer
+ */
+ public function getRedirectLimit()
+ {
+ return $this->redirectLimit;
+ }
+
+ /**
+ * Determines if a given response is a redirect.
+ *
+ * @param ResponseInterface $response
+ *
+ * @return boolean
+ */
+ protected function isRedirect(ResponseInterface $response)
+ {
+ $statusCode = $response->getStatusCode();
+
+ return $statusCode > 300 && $statusCode < 400 && $response->hasHeader('Location');
+ }
+
+ /**
+ * Sends a request instance and returns a response instance.
+ *
+ * WARNING: This method does not attempt to catch exceptions caused by HTTP
+ * errors! It is recommended to wrap this method in a try/catch block.
+ *
+ * @param RequestInterface $request
+ * @return ResponseInterface
+ */
+ public function getResponse(RequestInterface $request)
+ {
+ try {
+ $response = $this->followRequestRedirects($request);
+ } catch (BadResponseException $e) {
+ $response = $e->getResponse();
+ }
+
+ return $response;
+ }
+
+ /**
+ * Updates the redirect limit.
+ *
+ * @param integer $limit
+ * @return League\OAuth2\Client\Provider\AbstractProvider
+ * @throws InvalidArgumentException
+ */
+ public function setRedirectLimit($limit)
+ {
+ if (!is_int($limit)) {
+ throw new InvalidArgumentException('redirectLimit must be an integer.');
+ }
+
+ if ($limit < 1) {
+ throw new InvalidArgumentException('redirectLimit must be greater than or equal to one.');
+ }
+
+ $this->redirectLimit = $limit;
+
+ return $this;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/QueryBuilderTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/QueryBuilderTrait.php
new file mode 100644
index 0000000..bdda3e7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/QueryBuilderTrait.php
@@ -0,0 +1,33 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Tool;
+
+/**
+ * Provides a standard way to generate query strings.
+ */
+trait QueryBuilderTrait
+{
+ /**
+ * Build a query string from an array.
+ *
+ * @param array $params
+ *
+ * @return string
+ */
+ protected function buildQueryString(array $params)
+ {
+ return http_build_query($params, '', '&', \PHP_QUERY_RFC3986);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/RequestFactory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/RequestFactory.php
new file mode 100644
index 0000000..1af4342
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/RequestFactory.php
@@ -0,0 +1,87 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Tool;
+
+use GuzzleHttp\Psr7\Request;
+
+/**
+ * Used to produce PSR-7 Request instances.
+ *
+ * @link https://github.com/guzzle/guzzle/pull/1101
+ */
+class RequestFactory
+{
+ /**
+ * Creates a PSR-7 Request instance.
+ *
+ * @param null|string $method HTTP method for the request.
+ * @param null|string $uri URI for the request.
+ * @param array $headers Headers for the message.
+ * @param string|resource|StreamInterface $body Message body.
+ * @param string $version HTTP protocol version.
+ *
+ * @return Request
+ */
+ public function getRequest(
+ $method,
+ $uri,
+ array $headers = [],
+ $body = null,
+ $version = '1.1'
+ ) {
+ return new Request($method, $uri, $headers, $body, $version);
+ }
+
+ /**
+ * Parses simplified options.
+ *
+ * @param array $options Simplified options.
+ *
+ * @return array Extended options for use with getRequest.
+ */
+ protected function parseOptions(array $options)
+ {
+ // Should match default values for getRequest
+ $defaults = [
+ 'headers' => [],
+ 'body' => null,
+ 'version' => '1.1',
+ ];
+
+ return array_merge($defaults, $options);
+ }
+
+ /**
+ * Creates a request using a simplified array of options.
+ *
+ * @param null|string $method
+ * @param null|string $uri
+ * @param array $options
+ *
+ * @return Request
+ */
+ public function getRequestWithOptions($method, $uri, array $options = [])
+ {
+ $options = $this->parseOptions($options);
+
+ return $this->getRequest(
+ $method,
+ $uri,
+ $options['headers'],
+ $options['body'],
+ $options['version']
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/RequiredParameterTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/RequiredParameterTrait.php
new file mode 100644
index 0000000..47da977
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/league/oauth2-client/src/Tool/RequiredParameterTrait.php
@@ -0,0 +1,56 @@
+<?php
+/**
+ * This file is part of the league/oauth2-client library
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ *
+ * @copyright Copyright (c) Alex Bilbie <hello@alexbilbie.com>
+ * @license http://opensource.org/licenses/MIT MIT
+ * @link http://thephpleague.com/oauth2-client/ Documentation
+ * @link https://packagist.org/packages/league/oauth2-client Packagist
+ * @link https://github.com/thephpleague/oauth2-client GitHub
+ */
+
+namespace League\OAuth2\Client\Tool;
+
+use BadMethodCallException;
+
+/**
+ * Provides functionality to check for required parameters.
+ */
+trait RequiredParameterTrait
+{
+ /**
+ * Checks for a required parameter in a hash.
+ *
+ * @throws BadMethodCallException
+ * @param string $name
+ * @param array $params
+ * @return void
+ */
+ private function checkRequiredParameter($name, array $params)
+ {
+ if (!isset($params[$name])) {
+ throw new BadMethodCallException(sprintf(
+ 'Required parameter not passed: "%s"',
+ $name
+ ));
+ }
+ }
+
+ /**
+ * Checks for multiple required parameters in a hash.
+ *
+ * @throws InvalidArgumentException
+ * @param array $names
+ * @param array $params
+ * @return void
+ */
+ private function checkRequiredParameters(array $names, array $params)
+ {
+ foreach ($names as $name) {
+ $this->checkRequiredParameter($name, $params);
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/.phpstorm.meta.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/.phpstorm.meta.php
new file mode 100644
index 0000000..bd7c7e0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/.phpstorm.meta.php
@@ -0,0 +1,10 @@
+<?php
+namespace PHPSTORM_META {
+ registerArgumentsSet("date_units", "millenania", "millennium", "century", "centuries", "decade", "decades", "year", "years", "y", "yr", "yrs", "quarter", "quarters", "month", "months", "mo", "mos", "week", "weeks", "w", "day", "days", "d", "hour", "hours", "h", "minute", "minutes", "m", "second", "seconds", "s", "millisecond", "milliseconds", "milli", "ms", "microsecond", "microseconds", "micro", "µs");
+ expectedArguments(\Carbon\Traits\Units::add(), 0, argumentsSet("date_units"));
+ expectedArguments(\Carbon\Traits\Units::add(), 1, argumentsSet("date_units"));
+ expectedArguments(\Carbon\CarbonInterface::add(), 0, argumentsSet("date_units"));
+ expectedArguments(\Carbon\CarbonInterface::add(), 1, argumentsSet("date_units"));
+
+ expectedArguments(\Carbon\CarbonInterface::getTimeFormatByPrecision(), 0, "minute", "second", "m", "millisecond", "µ", "microsecond", "minutes", "seconds", "ms", "milliseconds", "µs", "microseconds");
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/composer.json
index 84ec136..48366b5 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/composer.json
@@ -1,14 +1,13 @@
{
"name": "nesbot/carbon",
- "type": "library",
"description": "An API extension for DateTime that supports 281 different languages.",
+ "license": "MIT",
+ "type": "library",
"keywords": [
"date",
"time",
"DateTime"
],
- "homepage": "https://carbon.nesbot.com",
- "license": "MIT",
"authors": [
{
"name": "Brian Nesbitt",
@@ -20,31 +19,77 @@
"homepage": "https://github.com/kylekatarnls"
}
],
+ "homepage": "https://carbon.nesbot.com",
+ "support": {
+ "issues": "https://github.com/briannesbitt/Carbon/issues",
+ "source": "https://github.com/briannesbitt/Carbon",
+ "docs": "https://carbon.nesbot.com/docs"
+ },
+ "funding": [
+ {
+ "url": "https://github.com/sponsors/kylekatarnls",
+ "type": "github"
+ },
+ {
+ "url": "https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme",
+ "type": "tidelift"
+ },
+ {
+ "url": "https://opencollective.com/Carbon#sponsor",
+ "type": "opencollective"
+ }
+ ],
"require": {
"php": "^7.1.8 || ^8.0",
"ext-json": "*",
+ "carbonphp/carbon-doctrine-types": "*",
+ "psr/clock": "^1.0",
"symfony/polyfill-mbstring": "^1.0",
"symfony/polyfill-php80": "^1.16",
"symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0"
},
"require-dev": {
- "doctrine/dbal": "^2.0 || ^3.0",
- "doctrine/orm": "^2.7",
+ "doctrine/dbal": "^2.0 || ^3.1.4 || ^4.0",
+ "doctrine/orm": "^2.7 || ^3.0",
"friendsofphp/php-cs-fixer": "^3.0",
"kylekatarnls/multi-tester": "^2.0",
+ "ondrejmirtes/better-reflection": "*",
"phpmd/phpmd": "^2.9",
"phpstan/extension-installer": "^1.0",
- "phpstan/phpstan": "^0.12.54 || ^1.0",
- "phpunit/phpunit": "^7.5.20 || ^8.5.14",
+ "phpstan/phpstan": "^0.12.99 || ^1.7.14",
+ "phpunit/php-file-iterator": "^2.0.5 || ^3.0.6",
+ "phpunit/phpunit": "^7.5.20 || ^8.5.26 || ^9.5.20",
"squizlabs/php_codesniffer": "^3.4"
},
- "config": {
- "process-timeout": 0,
- "sort-packages": true,
- "allow-plugins": {
- "phpstan/extension-installer": true
+ "provide": {
+ "psr/clock-implementation": "1.0"
+ },
+ "minimum-stability": "dev",
+ "prefer-stable": true,
+ "autoload": {
+ "psr-4": {
+ "Carbon\\": "src/Carbon/"
}
},
+ "autoload-dev": {
+ "psr-4": {
+ "Tests\\": "tests/"
+ },
+ "files": [
+ "tests/Laravel/ServiceProvider.php"
+ ]
+ },
+ "bin": [
+ "bin/carbon"
+ ],
+ "config": {
+ "allow-plugins": {
+ "phpstan/extension-installer": true,
+ "composer/package-versions-deprecated": true
+ },
+ "process-timeout": 0,
+ "sort-packages": true
+ },
"extra": {
"branch-alias": {
"dev-3.x": "3.x-dev",
@@ -61,28 +106,11 @@
]
}
},
- "autoload": {
- "psr-4": {
- "Carbon\\": "src/Carbon/"
- }
- },
- "autoload-dev": {
- "psr-4": {
- "Tests\\": "tests/"
- },
- "files": [
- "tests/Laravel/ServiceProvider.php"
- ]
- },
- "minimum-stability": "dev",
- "prefer-stable": true,
- "bin": [
- "bin/carbon"
- ],
"scripts": {
"phpcs": "php-cs-fixer fix -v --diff --dry-run",
"phpdoc": "php phpdoc.php",
"phpmd": "phpmd src text /phpmd.xml",
+ "phpmd-test": "phpmd tests text /tests/phpmd-test.xml",
"phpstan": "phpstan analyse --configuration phpstan.neon",
"phpunit": "phpunit --verbose",
"style-check": [
@@ -93,11 +121,7 @@
"test": [
"@phpunit",
"@style-check"
- ]
- },
- "support": {
- "issues": "https://github.com/briannesbitt/Carbon/issues",
- "source": "https://github.com/briannesbitt/Carbon",
- "docs": "https://carbon.nesbot.com/docs"
+ ],
+ "sponsors": "php sponsors.php"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/MessageFormatter/MessageFormatterMapperStrongType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/MessageFormatter/MessageFormatterMapperStrongType.php
new file mode 100644
index 0000000..c2f4bf0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/MessageFormatter/MessageFormatterMapperStrongType.php
@@ -0,0 +1,28 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\MessageFormatter;
+
+use Symfony\Component\Translation\Formatter\MessageFormatterInterface;
+
+if (!class_exists(LazyMessageFormatter::class, false)) {
+ abstract class LazyMessageFormatter implements MessageFormatterInterface
+ {
+ public function format(string $message, string $locale, array $parameters = []): string
+ {
+ return $this->formatter->format(
+ $message,
+ $this->transformLocale($locale),
+ $parameters
+ );
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/MessageFormatter/MessageFormatterMapperWeakType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/MessageFormatter/MessageFormatterMapperWeakType.php
new file mode 100644
index 0000000..cbd890d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/MessageFormatter/MessageFormatterMapperWeakType.php
@@ -0,0 +1,36 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\MessageFormatter;
+
+use Symfony\Component\Translation\Formatter\ChoiceMessageFormatterInterface;
+use Symfony\Component\Translation\Formatter\MessageFormatterInterface;
+
+if (!class_exists(LazyMessageFormatter::class, false)) {
+ abstract class LazyMessageFormatter implements MessageFormatterInterface, ChoiceMessageFormatterInterface
+ {
+ abstract protected function transformLocale(?string $locale): ?string;
+
+ public function format($message, $locale, array $parameters = [])
+ {
+ return $this->formatter->format(
+ $message,
+ $this->transformLocale($locale),
+ $parameters
+ );
+ }
+
+ public function choiceFormat($message, $number, $locale, array $parameters = [])
+ {
+ return $this->formatter->choiceFormat($message, $number, $locale, $parameters);
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/AbstractMacroBuiltin.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/AbstractMacroBuiltin.php
new file mode 100644
index 0000000..ba7cf63
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/AbstractMacroBuiltin.php
@@ -0,0 +1,36 @@
+<?php
+
+declare(strict_types=1);
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\PHPStan;
+
+use PHPStan\BetterReflection\Reflection;
+use ReflectionMethod;
+
+if (!class_exists(AbstractReflectionMacro::class, false)) {
+ abstract class AbstractReflectionMacro extends AbstractMacro
+ {
+ /**
+ * {@inheritdoc}
+ */
+ public function getReflection(): ?ReflectionMethod
+ {
+ if ($this->reflectionFunction instanceof Reflection\ReflectionMethod) {
+ return new Reflection\Adapter\ReflectionMethod($this->reflectionFunction);
+ }
+
+ return $this->reflectionFunction instanceof ReflectionMethod
+ ? $this->reflectionFunction
+ : null;
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/AbstractMacroStatic.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/AbstractMacroStatic.php
new file mode 100644
index 0000000..bd4c8e8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/AbstractMacroStatic.php
@@ -0,0 +1,45 @@
+<?php
+
+declare(strict_types=1);
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\PHPStan;
+
+use PHPStan\BetterReflection\Reflection;
+use ReflectionMethod;
+
+if (!class_exists(AbstractReflectionMacro::class, false)) {
+ abstract class AbstractReflectionMacro extends AbstractMacro
+ {
+ /**
+ * {@inheritdoc}
+ */
+ public function getReflection(): ?Reflection\Adapter\ReflectionMethod
+ {
+ if ($this->reflectionFunction instanceof Reflection\Adapter\ReflectionMethod) {
+ return $this->reflectionFunction;
+ }
+
+ if ($this->reflectionFunction instanceof Reflection\ReflectionMethod) {
+ return new Reflection\Adapter\ReflectionMethod($this->reflectionFunction);
+ }
+
+ return $this->reflectionFunction instanceof ReflectionMethod
+ ? new Reflection\Adapter\ReflectionMethod(
+ Reflection\ReflectionMethod::createFromName(
+ $this->reflectionFunction->getDeclaringClass()->getName(),
+ $this->reflectionFunction->getName()
+ )
+ )
+ : null;
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroStrongType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroStrongType.php
index eacd9c1..f615b3a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroStrongType.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroStrongType.php
@@ -14,14 +14,16 @@
namespace Carbon\PHPStan;
if (!class_exists(LazyMacro::class, false)) {
- abstract class LazyMacro extends AbstractMacro
+ abstract class LazyMacro extends AbstractReflectionMacro
{
/**
* {@inheritdoc}
*/
public function getFileName(): ?string
{
- return $this->reflectionFunction->getFileName();
+ $file = $this->reflectionFunction->getFileName();
+
+ return (($file ? realpath($file) : null) ?: $file) ?: null;
}
/**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroWeakType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroWeakType.php
index 3e9fcf4..bf64c1d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroWeakType.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/lazy/Carbon/PHPStan/MacroWeakType.php
@@ -14,7 +14,7 @@
namespace Carbon\PHPStan;
if (!class_exists(LazyMacro::class, false)) {
- abstract class LazyMacro extends AbstractMacro
+ abstract class LazyMacro extends AbstractReflectionMacro
{
/**
* {@inheritdoc}
@@ -23,7 +23,9 @@
*/
public function getFileName()
{
- return $this->reflectionFunction->getFileName();
+ $file = $this->reflectionFunction->getFileName();
+
+ return (($file ? realpath($file) : null) ?: $file) ?: null;
}
/**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/readme.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/readme.md
index 5d82721..3f41177 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/readme.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/readme.md
@@ -2,7 +2,7 @@
[](https://packagist.org/packages/nesbot/carbon)
[](https://packagist.org/packages/nesbot/carbon)
-[](https://actions-badge.atrox.dev/briannesbitt/Carbon/goto)
+[](https://github.com/briannesbitt/Carbon/actions)
[](https://codecov.io/github/briannesbitt/Carbon?branch=master)
[](https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme)
@@ -119,21 +119,52 @@
Support this project by becoming a sponsor. Your logo will show up here with a link to your website.
-<a href="https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme" target="_blank"><img src="https://carbon.nesbot.com/tidelift-brand.png" width="256" height="64"></a>
-<a href="https://onlinecasinohex.ca/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img src="https://images.opencollective.com/hexcasinoca/2da3af2/logo/256.png" width="85" height="64"></a>
-<a href="https://opencollective.com/Carbon/sponsor/0/website" target="_blank"><img src="https://opencollective.com/Carbon/sponsor/0/avatar.svg"></a>
-<a href="https://opencollective.com/Carbon/sponsor/1/website" target="_blank"><img src="https://opencollective.com/Carbon/sponsor/1/avatar.svg"></a>
-<a href="https://opencollective.com/Carbon/sponsor/2/website" target="_blank"><img src="https://opencollective.com/Carbon/sponsor/2/avatar.svg"></a>
-<a href="https://opencollective.com/Carbon/sponsor/3/website" target="_blank"><img src="https://opencollective.com/Carbon/sponsor/3/avatar.svg"></a>
-<a href="https://opencollective.com/Carbon/sponsor/4/website" target="_blank"><img src="https://opencollective.com/Carbon/sponsor/4/avatar.svg"></a>
+<a href="https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme" target="_blank"><img src="https://carbon.nesbot.com/tidelift-brand.png" width="256" height="64"></a><!-- <open-collective-sponsors> -->
+<a title="Онлайн казино 777 Україна" href="https://777.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн казино" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/7e572d50-1ce8-4d69-ae12-86cc80371373/ok-ua-777.png" width="64" height="64"></a>
+<a title="#1 Guide To Online Gambling In Canada" href="https://casinohex.org/canada/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="CasinoHex Canada" src="https://opencollective-production.s3.us-west-1.amazonaws.com/79fdbcc0-a997-11eb-abbc-25e48b63c6dc.jpg" width="85" height="64"></a>
+<a title="Znajdź najlepsze zakłady bukmacherskie w Polsce w 2023 roku. Probukmacher.pl to Twoje kompendium wiedzy na temat bukmacherów!" href="https://www.probukmacher.pl?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Probukmacher" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/caf50271-4560-4ffe-a434-ea15239168db/Screenshot_1.png" width="89" height="64"></a>
+<a title="Gives a fun for our users" href="https://slotoking.ua/games/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Игровые автоматы" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/94601d07-3205-4c60-9c2d-9b8194dbefb7/skg-blue.png" width="64" height="64"></a>
+<a title="Casino-portugal.pt" href="https://casino-portugal.pt/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Casino-portugal.pt" src="https://logo.clearbit.com/casino-portugal.pt" width="64" height="64"></a>
+<a title="Slots City® ➢ Лучшее лицензионно казино онлайн и оффлайн на гривны в Украине. 【 Более1500 игровых автоматов и слотов】✅ Официально и Безопасно" href="https://slotscity.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Slots City" src="https://opencollective-production.s3.us-west-1.amazonaws.com/d7e298c0-7abe-11ed-8553-230872f5e54d.png" width="90" height="64"></a>
+<a title="inkedin" href="https://inkedin.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="inkedin" src="https://logo.clearbit.com/inkedin.com" width="64" height="64"></a>
+<a title="Актуальний та повносправний рейтинг онлайн казино України, ґрунтований на відгуках реальних гравців." href="https://uk.onlinecasino.in.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн казино України" src="https://opencollective-production.s3.us-west-1.amazonaws.com/c0b4b090-eef8-11ec-9cb7-0527a205b226.png" width="64" height="64"></a>
+<a title="OnlineCasinosSpelen" href="https://onlinecasinosspelen.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="OnlineCasinosSpelen" src="https://logo.clearbit.com/onlinecasinosspelen.com" width="64" height="64"></a>
+<a title="Best non Gamstop sites in the UK" href="https://nongamstopcasinos.net/gb/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Best non Gamstop sites in the UK" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/34e340b8-e1de-4932-8a76-1b3ce2ec7ee8/logo_white%20bg%20(8).png" width="64" height="64"></a>
+<a title="Real Money Pokies" href="https://www.nzfirst.org.nz/real-money-pokies/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Real Money Pokies" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/30d38232-a9d6-4e95-a48c-641fdc4d96fd/NZ_logo%20(6)%20(1)%20(1).jpg" width="64" height="64"></a>
+<a title="Non GamStop Bookies UK" href="https://nongamstopbookies.com/uk/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Non GamStop Bookies UK" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/43c5561c-8907-4ef7-a4ee-c6da054788b8/logo-site%20(3).jpg" width="64" height="64"></a>
+<a title="Актуальний топ-рейтинг українських онлайн казино на гривні! Щоденне оновлення топу та унікальна система ранжування, основана на відгуках гравців!" href="https://onlinecasino.in.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн Казино Украины" src="https://opencollective-production.s3.us-west-1.amazonaws.com/8fdd8aa0-e273-11ec-a95e-d38fd331cabf.png" width="64" height="64"></a>
+<a title="Twitter Video Downloader HD Tool allows you to store tweets on your device (mobile or PC) for free." href="https://ssstwitter.online/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="SSSTwitter" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/ba0d1daf-a894-4d98-95f7-a44d321364b3/Screenshot%202024-01-16%20at%2011.43.22.png" width="76" height="64"></a>
+<a title="Entertainment" href="https://www.nongamstopbets.com/casinos-not-on-gamstop/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Non-GamStop Bets UK" src="https://logo.clearbit.com/nongamstopbets.com" width="64" height="64"></a>
+<a title="Chudovo - international software development company with representative offices in Kyiv, Cologne, New York, Tallinn and London. It has been working on the market since 2006. Company has domain expertise in video security, logistics, medicine, finance and" href="https://chudovo.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Chudovo" src="https://opencollective-production.s3.us-west-1.amazonaws.com/326c19a0-2e87-11eb-a13a-c99a2a201d11.png" width="84" height="42"></a>
+<a title="Entertainment" href="https://casinogap.org/uk/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="UK Casino Gap" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/143f9301-beec-4118-89d5-9a07a01345f3/casinogap-uk.png" width="42" height="42"></a>
+<a title="NZ Gaming Portal" href="https://casinodeps.co.nz?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="NZ Casino Deps" src="https://logo.clearbit.com/casinodeps.co.nz" width="42" height="42"></a>
+<a title="NonStop Sites" href="https://uk.nonstopcasino.org/non-gamstop-casinos/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="NonStopCasino.org" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/fd7ad905-8752-468f-ad20-582a24cca9d9/non-stop-casino.png" width="42" height="42"></a>
+<a title="Siti Non AAMS" href="https://www.outlookindia.com/outlook-spotlight/migliori-siti-non-aams-siti-scommesse-senza-licenza-sicuri-news-294715?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Migliori Siti Non AAMS" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/392810da-6cb6-4938-a3cb-38bd0e1eb7de/migliori-siti-non-aams.png" width="42" height="42"></a>
+<a title="List of trusted non GamStop casino reviews" href="https://nongamstopcasinos.org?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="UK NonGamStopCasinos" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/cbda0ee1-26ea-4252-9580-f1f9b317b1f7/nongamstopcasinos-uk.png" width="42" height="42"></a>
+<a title="Online TikTok Video Download Tool" href="https://snaptik.pro?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="SnapTik" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/546bcd53-6615-457d-ab21-1db1c52b3af5/logo.jpg" width="42" height="42"></a>
+<a title="IG Downloader is an Instagram Downloader service that offers a variety of tools to download Instagram content for free. Listed below are all the tools" href="https://indownloader.app/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="IG Downloader" src="https://logo.clearbit.com/indownloader.app" width="42" height="42"></a>
+<a title="Proxidize is a mobile proxy creation and management platform that provides all needed components from hardware to cloud software and SIM cards." href="https://proxidize.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Proxidize" src="https://logo.clearbit.com/proxidize.com" width="42" height="42"></a>
+<a title="Blastup offers Instagram growth services like buying likes, views, and followers, emphasizing real user engagement and instant delivery." href="https://blastup.com/buy-instagram-likes?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Blastup" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/955a0beb-9fe8-4753-ad92-fae8ef5382fc/favicon--dark.jpg" width="42" height="42"></a>
+<a title="A self-hosted web radio management suite, including turnkey installer tools and an easy-to-use web app to manage your stations." href="https://azuracast.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="AzuraCast" src="https://opencollective-production.s3.us-west-1.amazonaws.com/3c12ea10-cdfb-11eb-9cf4-3760b386b76d.png" width="42" height="42"></a>
+<a title="Triplebyte is the first software engineering job platform that is on the developer's side. Take our coding quiz!" href="https://triplebyte.com/os/opencollective?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Triplebyte" src="https://opencollective-production.s3.us-west-1.amazonaws.com/43e4f9d0-30cd-11ea-9c6b-e1142996e8b2.png" width="42" height="42"></a>
+<a title="Connect your Collective to GitHub Sponsors: https://docs.opencollective.com/help/collectives/github-sponsors" href="https://github.com/sponsors/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="GitHub Sponsors" src="https://opencollective-production.s3.us-west-1.amazonaws.com/87b1d240-f617-11ea-9960-fd7e8ab20fe4.png" width="48" height="42"></a>
+<a title="Salesforce" href="https://engineering.salesforce.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Salesforce" src="https://opencollective-production.s3.us-west-1.amazonaws.com/24d34880-df8d-11e9-949c-6bc2037b6bd5.png" width="42" height="42"></a>
+<!-- </open-collective-sponsors> -->
-[[Become a sponsor](https://opencollective.com/Carbon#sponsor)]
+[[Become a sponsor via OpenCollective](https://opencollective.com/Carbon#sponsor)]
+
+<a href="https://github.com/johnrsimeone" target="_blank"><img src="https://avatars.githubusercontent.com/u/22871068?s=70&v=4" width="64" height="64"></a>
+<a href="https://github.com/taylorotwell" target="_blank"><img src="https://avatars.githubusercontent.com/u/463230?s=128&v=4" width="64" height="64"></a>
+<a href="https://github.com/getsentry" target="_blank"><img src="https://avatars.githubusercontent.com/u/1396951?s=128&v=4" width="64" height="64"></a>
+<a href="https://github.com/codecov" target="_blank"><img src="https://avatars.githubusercontent.com/u/8226205?s=128&v=4" width="64" height="64"></a>
+
+[[Become a sponsor via GitHub](https://github.com/sponsors/kylekatarnls)]
### Backers
Thank you to all our backers! 🙏
-<a href="https://opencollective.com/Carbon#backers" target="_blank"><img src="https://opencollective.com/Carbon/backers.svg?width=890"></a>
+<a href="https://opencollective.com/Carbon#backers" target="_blank"><img src="https://opencollective.com/Carbon/backers.svg?width=890&version=2023-06-08-07-12"></a>
[[Become a backer](https://opencollective.com/Carbon#backer)]
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/sponsors.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/sponsors.php
new file mode 100644
index 0000000..67b2171
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/sponsors.php
@@ -0,0 +1,129 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+use Carbon\CarbonImmutable;
+
+require_once __DIR__.'/vendor/autoload.php';
+
+function getMaxHistoryMonthsByAmount($amount): int
+{
+ if ($amount >= 50) {
+ return 6;
+ }
+
+ if ($amount >= 20) {
+ return 4;
+ }
+
+ return 2;
+}
+
+function getHtmlAttribute($rawValue): string
+{
+ return str_replace(
+ ['', "\r"],
+ '',
+ trim(htmlspecialchars((string) $rawValue), " \n\r\t\v\0"),
+ );
+}
+
+function getOpenCollectiveSponsors(): string
+{
+ $customSponsorImages = [
+ // For consistency and equity among sponsors, as of now, we kindly ask our sponsors
+ // to provide an image having a width/height ratio between 1/1 and 2/1.
+ // By default, we'll show the member picture from OpenCollective, and will resize it if bigger
+ // int(OpenCollective.MemberId) => ImageURL
+ ];
+
+ $members = json_decode(file_get_contents('https://opencollective.com/carbon/members/all.json'), true);
+
+ $list = array_filter($members, static function ($member): bool {
+ return ($member['lastTransactionAmount'] > 3 || $member['isActive']) &&
+ $member['role'] === 'BACKER' &&
+ $member['type'] !== 'USER' &&
+ (
+ $member['totalAmountDonated'] > 100 ||
+ $member['lastTransactionAt'] > CarbonImmutable::now()
+ ->subMonthsNoOverflow(getMaxHistoryMonthsByAmount($member['lastTransactionAmount']))
+ ->format('Y-m-d h:i') ||
+ $member['isActive'] && $member['lastTransactionAmount'] >= 30
+ );
+ });
+
+ $list = array_map(static function (array $member): array {
+ $createdAt = CarbonImmutable::parse($member['createdAt']);
+ $lastTransactionAt = CarbonImmutable::parse($member['lastTransactionAt']);
+
+ if ($createdAt->format('d H:i:s.u') > $lastTransactionAt->format('d H:i:s.u')) {
+ $createdAt = $createdAt
+ ->setDay($lastTransactionAt->day)
+ ->modify($lastTransactionAt->format('H:i:s.u'));
+ }
+
+ $monthlyContribution = (float) ($member['totalAmountDonated'] / ceil($createdAt->floatDiffInMonths()));
+
+ if (
+ $lastTransactionAt->isAfter('last month') &&
+ $member['lastTransactionAmount'] > $monthlyContribution
+ ) {
+ $monthlyContribution = (float) $member['lastTransactionAmount'];
+ }
+
+ $yearlyContribution = (float) ($member['totalAmountDonated'] / max(1, $createdAt->floatDiffInYears()));
+ $status = null;
+
+ if ($monthlyContribution > 29) {
+ $status = 'sponsor';
+ } elseif ($monthlyContribution > 4.5 || $yearlyContribution > 29) {
+ $status = 'backer';
+ } elseif ($member['totalAmountDonated'] > 0) {
+ $status = 'helper';
+ }
+
+ return array_merge($member, [
+ 'star' => ($monthlyContribution > 98 || $yearlyContribution > 500),
+ 'status' => $status,
+ 'monthlyContribution' => $monthlyContribution,
+ 'yearlyContribution' => $yearlyContribution,
+ ]);
+ }, $list);
+
+ usort($list, static function (array $a, array $b): int {
+ return ($b['monthlyContribution'] <=> $a['monthlyContribution'])
+ ?: ($b['totalAmountDonated'] <=> $a['totalAmountDonated']);
+ });
+
+ return implode('', array_map(static function (array $member) use ($customSponsorImages): string {
+ $href = htmlspecialchars($member['website'] ?? $member['profile']);
+ $src = $customSponsorImages[$member['MemberId'] ?? ''] ?? $member['image'] ?? (strtr($member['profile'], ['https://opencollective.com/' => 'https://images.opencollective.com/']).'/avatar/256.png');
+ [$x, $y] = @getimagesize($src) ?: [0, 0];
+ $validImage = ($x && $y);
+ $src = $validImage ? htmlspecialchars($src) : 'https://opencollective.com/static/images/default-guest-logo.svg';
+ $height = $member['status'] === 'sponsor' ? 64 : 42;
+ $width = min($height * 2, $validImage ? round($x * $height / $y) : $height);
+ $href .= (strpos($href, '?') === false ? '?' : '&').'utm_source=opencollective&utm_medium=github&utm_campaign=Carbon';
+ $title = getHtmlAttribute(($member['description'] ?? null) ?: $member['name']);
+ $alt = getHtmlAttribute($member['name']);
+
+ return "\n".'<a title="'.$title.'" href="'.$href.'" target="_blank">'.
+ '<img alt="'.$alt.'" src="'.$src.'" width="'.$width.'" height="'.$height.'">'.
+ '</a>';
+ }, $list))."\n";
+}
+
+file_put_contents('readme.md', preg_replace_callback(
+ '/(<!-- <open-collective-sponsors> -->)[\s\S]+(<!-- <\/open-collective-sponsors> -->)/',
+ static function (array $match): string {
+ return $match[1].getOpenCollectiveSponsors().$match[2];
+ },
+ file_get_contents('readme.md')
+));
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/AbstractTranslator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/AbstractTranslator.php
index 48441e7..8b8fe08 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/AbstractTranslator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/AbstractTranslator.php
@@ -11,6 +11,7 @@
namespace Carbon;
+use Carbon\MessageFormatter\MessageFormatterMapper;
use Closure;
use ReflectionException;
use ReflectionFunction;
@@ -51,7 +52,7 @@
/**
* List of locales aliases.
*
- * @var string[]
+ * @var array<string, string>
*/
protected $aliases = [
'me' => 'sr_Latn_ME',
@@ -83,7 +84,7 @@
$this->initializing = true;
$this->directories = [__DIR__.'/Lang'];
$this->addLoader('array', new ArrayLoader());
- parent::__construct($locale, $formatter, $cacheDir, $debug);
+ parent::__construct($locale, new MessageFormatterMapper($formatter), $cacheDir, $debug);
$this->initializing = false;
}
@@ -220,8 +221,8 @@
$catalogue = $this->getCatalogue($locale);
$format = $this instanceof TranslatorStrongTypeInterface
- ? $this->getFromCatalogue($catalogue, (string) $id, $domain) // @codeCoverageIgnore
- : $this->getCatalogue($locale)->get((string) $id, $domain);
+ ? $this->getFromCatalogue($catalogue, (string) $id, $domain)
+ : $this->getCatalogue($locale)->get((string) $id, $domain); // @codeCoverageIgnore
if ($format instanceof Closure) {
// @codeCoverageIgnoreStart
@@ -250,11 +251,7 @@
*/
protected function loadMessagesFromFile($locale)
{
- if (isset($this->messages[$locale])) {
- return true;
- }
-
- return $this->resetMessages($locale);
+ return isset($this->messages[$locale]) || $this->resetMessages($locale);
}
/**
@@ -311,7 +308,7 @@
*/
public function setLocale($locale)
{
- $locale = preg_replace_callback('/[-_]([a-z]{2,}|[0-9]{2,})/', function ($matches) {
+ $locale = preg_replace_callback('/[-_]([a-z]{2,}|\d{2,})/', function ($matches) {
// _2-letters or YUE is a region, _3+-letters is a variant
$upper = strtoupper($matches[1]);
@@ -359,13 +356,13 @@
parent::setLocale($macroLocale);
}
- if ($this->loadMessagesFromFile($locale) || $this->initializing) {
- parent::setLocale($locale);
-
- return true;
+ if (!$this->loadMessagesFromFile($locale) && !$this->initializing) {
+ return false;
}
- return false;
+ parent::setLocale($locale);
+
+ return true;
}
/**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php
index e327590..e32569a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Carbon.php
@@ -33,477 +33,477 @@
* @property int $second
* @property int $micro
* @property int $microsecond
- * @property int|float|string $timestamp seconds since the Unix Epoch
- * @property string $englishDayOfWeek the day of week in English
- * @property string $shortEnglishDayOfWeek the abbreviated day of week in English
- * @property string $englishMonth the month in English
- * @property string $shortEnglishMonth the abbreviated month in English
+ * @property int|float|string $timestamp seconds since the Unix Epoch
+ * @property string $englishDayOfWeek the day of week in English
+ * @property string $shortEnglishDayOfWeek the abbreviated day of week in English
+ * @property string $englishMonth the month in English
+ * @property string $shortEnglishMonth the abbreviated month in English
* @property int $milliseconds
* @property int $millisecond
* @property int $milli
- * @property int $week 1 through 53
- * @property int $isoWeek 1 through 53
- * @property int $weekYear year according to week format
- * @property int $isoWeekYear year according to ISO week format
- * @property int $dayOfYear 1 through 366
- * @property int $age does a diffInYears() with default parameters
- * @property int $offset the timezone offset in seconds from UTC
- * @property int $offsetMinutes the timezone offset in minutes from UTC
- * @property int $offsetHours the timezone offset in hours from UTC
- * @property CarbonTimeZone $timezone the current timezone
- * @property CarbonTimeZone $tz alias of $timezone
- * @property-read int $dayOfWeek 0 (for Sunday) through 6 (for Saturday)
- * @property-read int $dayOfWeekIso 1 (for Monday) through 7 (for Sunday)
- * @property-read int $weekOfYear ISO-8601 week number of year, weeks starting on Monday
- * @property-read int $daysInMonth number of days in the given month
- * @property-read string $latinMeridiem "am"/"pm" (Ante meridiem or Post meridiem latin lowercase mark)
- * @property-read string $latinUpperMeridiem "AM"/"PM" (Ante meridiem or Post meridiem latin uppercase mark)
- * @property-read string $timezoneAbbreviatedName the current timezone abbreviated name
- * @property-read string $tzAbbrName alias of $timezoneAbbreviatedName
- * @property-read string $dayName long name of weekday translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $shortDayName short name of weekday translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $minDayName very short name of weekday translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $monthName long name of month translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $shortMonthName short name of month translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $meridiem lowercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
- * @property-read string $upperMeridiem uppercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
- * @property-read int $noZeroHour current hour from 1 to 24
- * @property-read int $weeksInYear 51 through 53
- * @property-read int $isoWeeksInYear 51 through 53
- * @property-read int $weekOfMonth 1 through 5
- * @property-read int $weekNumberInMonth 1 through 5
- * @property-read int $firstWeekDay 0 through 6
- * @property-read int $lastWeekDay 0 through 6
- * @property-read int $daysInYear 365 or 366
- * @property-read int $quarter the quarter of this instance, 1 - 4
- * @property-read int $decade the decade of this instance
- * @property-read int $century the century of this instance
- * @property-read int $millennium the millennium of this instance
- * @property-read bool $dst daylight savings time indicator, true if DST, false otherwise
- * @property-read bool $local checks if the timezone is local, true if local, false otherwise
- * @property-read bool $utc checks if the timezone is UTC, true if UTC, false otherwise
- * @property-read string $timezoneName the current timezone name
- * @property-read string $tzName alias of $timezoneName
- * @property-read string $locale locale of the current instance
+ * @property int $week 1 through 53
+ * @property int $isoWeek 1 through 53
+ * @property int $weekYear year according to week format
+ * @property int $isoWeekYear year according to ISO week format
+ * @property int $dayOfYear 1 through 366
+ * @property int $age does a diffInYears() with default parameters
+ * @property int $offset the timezone offset in seconds from UTC
+ * @property int $offsetMinutes the timezone offset in minutes from UTC
+ * @property int $offsetHours the timezone offset in hours from UTC
+ * @property CarbonTimeZone $timezone the current timezone
+ * @property CarbonTimeZone $tz alias of $timezone
+ * @property-read int $dayOfWeek 0 (for Sunday) through 6 (for Saturday)
+ * @property-read int $dayOfWeekIso 1 (for Monday) through 7 (for Sunday)
+ * @property-read int $weekOfYear ISO-8601 week number of year, weeks starting on Monday
+ * @property-read int $daysInMonth number of days in the given month
+ * @property-read string $latinMeridiem "am"/"pm" (Ante meridiem or Post meridiem latin lowercase mark)
+ * @property-read string $latinUpperMeridiem "AM"/"PM" (Ante meridiem or Post meridiem latin uppercase mark)
+ * @property-read string $timezoneAbbreviatedName the current timezone abbreviated name
+ * @property-read string $tzAbbrName alias of $timezoneAbbreviatedName
+ * @property-read string $dayName long name of weekday translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $shortDayName short name of weekday translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $minDayName very short name of weekday translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $monthName long name of month translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $shortMonthName short name of month translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $meridiem lowercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
+ * @property-read string $upperMeridiem uppercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
+ * @property-read int $noZeroHour current hour from 1 to 24
+ * @property-read int $weeksInYear 51 through 53
+ * @property-read int $isoWeeksInYear 51 through 53
+ * @property-read int $weekOfMonth 1 through 5
+ * @property-read int $weekNumberInMonth 1 through 5
+ * @property-read int $firstWeekDay 0 through 6
+ * @property-read int $lastWeekDay 0 through 6
+ * @property-read int $daysInYear 365 or 366
+ * @property-read int $quarter the quarter of this instance, 1 - 4
+ * @property-read int $decade the decade of this instance
+ * @property-read int $century the century of this instance
+ * @property-read int $millennium the millennium of this instance
+ * @property-read bool $dst daylight savings time indicator, true if DST, false otherwise
+ * @property-read bool $local checks if the timezone is local, true if local, false otherwise
+ * @property-read bool $utc checks if the timezone is UTC, true if UTC, false otherwise
+ * @property-read string $timezoneName the current timezone name
+ * @property-read string $tzName alias of $timezoneName
+ * @property-read string $locale locale of the current instance
*
- * @method bool isUtc() Check if the current instance has UTC timezone. (Both isUtc and isUTC cases are valid.)
- * @method bool isLocal() Check if the current instance has non-UTC timezone.
- * @method bool isValid() Check if the current instance is a valid date.
- * @method bool isDST() Check if the current instance is in a daylight saving time.
- * @method bool isSunday() Checks if the instance day is sunday.
- * @method bool isMonday() Checks if the instance day is monday.
- * @method bool isTuesday() Checks if the instance day is tuesday.
- * @method bool isWednesday() Checks if the instance day is wednesday.
- * @method bool isThursday() Checks if the instance day is thursday.
- * @method bool isFriday() Checks if the instance day is friday.
- * @method bool isSaturday() Checks if the instance day is saturday.
- * @method bool isSameYear(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same year as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentYear() Checks if the instance is in the same year as the current moment.
- * @method bool isNextYear() Checks if the instance is in the same year as the current moment next year.
- * @method bool isLastYear() Checks if the instance is in the same year as the current moment last year.
- * @method bool isSameWeek(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same week as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentWeek() Checks if the instance is in the same week as the current moment.
- * @method bool isNextWeek() Checks if the instance is in the same week as the current moment next week.
- * @method bool isLastWeek() Checks if the instance is in the same week as the current moment last week.
- * @method bool isSameDay(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same day as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentDay() Checks if the instance is in the same day as the current moment.
- * @method bool isNextDay() Checks if the instance is in the same day as the current moment next day.
- * @method bool isLastDay() Checks if the instance is in the same day as the current moment last day.
- * @method bool isSameHour(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same hour as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentHour() Checks if the instance is in the same hour as the current moment.
- * @method bool isNextHour() Checks if the instance is in the same hour as the current moment next hour.
- * @method bool isLastHour() Checks if the instance is in the same hour as the current moment last hour.
- * @method bool isSameMinute(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same minute as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMinute() Checks if the instance is in the same minute as the current moment.
- * @method bool isNextMinute() Checks if the instance is in the same minute as the current moment next minute.
- * @method bool isLastMinute() Checks if the instance is in the same minute as the current moment last minute.
- * @method bool isSameSecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same second as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentSecond() Checks if the instance is in the same second as the current moment.
- * @method bool isNextSecond() Checks if the instance is in the same second as the current moment next second.
- * @method bool isLastSecond() Checks if the instance is in the same second as the current moment last second.
- * @method bool isSameMicro(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMicro() Checks if the instance is in the same microsecond as the current moment.
- * @method bool isNextMicro() Checks if the instance is in the same microsecond as the current moment next microsecond.
- * @method bool isLastMicro() Checks if the instance is in the same microsecond as the current moment last microsecond.
- * @method bool isSameMicrosecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMicrosecond() Checks if the instance is in the same microsecond as the current moment.
- * @method bool isNextMicrosecond() Checks if the instance is in the same microsecond as the current moment next microsecond.
- * @method bool isLastMicrosecond() Checks if the instance is in the same microsecond as the current moment last microsecond.
- * @method bool isCurrentMonth() Checks if the instance is in the same month as the current moment.
- * @method bool isNextMonth() Checks if the instance is in the same month as the current moment next month.
- * @method bool isLastMonth() Checks if the instance is in the same month as the current moment last month.
- * @method bool isCurrentQuarter() Checks if the instance is in the same quarter as the current moment.
- * @method bool isNextQuarter() Checks if the instance is in the same quarter as the current moment next quarter.
- * @method bool isLastQuarter() Checks if the instance is in the same quarter as the current moment last quarter.
- * @method bool isSameDecade(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same decade as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentDecade() Checks if the instance is in the same decade as the current moment.
- * @method bool isNextDecade() Checks if the instance is in the same decade as the current moment next decade.
- * @method bool isLastDecade() Checks if the instance is in the same decade as the current moment last decade.
- * @method bool isSameCentury(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same century as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentCentury() Checks if the instance is in the same century as the current moment.
- * @method bool isNextCentury() Checks if the instance is in the same century as the current moment next century.
- * @method bool isLastCentury() Checks if the instance is in the same century as the current moment last century.
- * @method bool isSameMillennium(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same millennium as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMillennium() Checks if the instance is in the same millennium as the current moment.
- * @method bool isNextMillennium() Checks if the instance is in the same millennium as the current moment next millennium.
- * @method bool isLastMillennium() Checks if the instance is in the same millennium as the current moment last millennium.
- * @method $this years(int $value) Set current instance year to the given value.
- * @method $this year(int $value) Set current instance year to the given value.
- * @method $this setYears(int $value) Set current instance year to the given value.
- * @method $this setYear(int $value) Set current instance year to the given value.
- * @method $this months(int $value) Set current instance month to the given value.
- * @method $this month(int $value) Set current instance month to the given value.
- * @method $this setMonths(int $value) Set current instance month to the given value.
- * @method $this setMonth(int $value) Set current instance month to the given value.
- * @method $this days(int $value) Set current instance day to the given value.
- * @method $this day(int $value) Set current instance day to the given value.
- * @method $this setDays(int $value) Set current instance day to the given value.
- * @method $this setDay(int $value) Set current instance day to the given value.
- * @method $this hours(int $value) Set current instance hour to the given value.
- * @method $this hour(int $value) Set current instance hour to the given value.
- * @method $this setHours(int $value) Set current instance hour to the given value.
- * @method $this setHour(int $value) Set current instance hour to the given value.
- * @method $this minutes(int $value) Set current instance minute to the given value.
- * @method $this minute(int $value) Set current instance minute to the given value.
- * @method $this setMinutes(int $value) Set current instance minute to the given value.
- * @method $this setMinute(int $value) Set current instance minute to the given value.
- * @method $this seconds(int $value) Set current instance second to the given value.
- * @method $this second(int $value) Set current instance second to the given value.
- * @method $this setSeconds(int $value) Set current instance second to the given value.
- * @method $this setSecond(int $value) Set current instance second to the given value.
- * @method $this millis(int $value) Set current instance millisecond to the given value.
- * @method $this milli(int $value) Set current instance millisecond to the given value.
- * @method $this setMillis(int $value) Set current instance millisecond to the given value.
- * @method $this setMilli(int $value) Set current instance millisecond to the given value.
- * @method $this milliseconds(int $value) Set current instance millisecond to the given value.
- * @method $this millisecond(int $value) Set current instance millisecond to the given value.
- * @method $this setMilliseconds(int $value) Set current instance millisecond to the given value.
- * @method $this setMillisecond(int $value) Set current instance millisecond to the given value.
- * @method $this micros(int $value) Set current instance microsecond to the given value.
- * @method $this micro(int $value) Set current instance microsecond to the given value.
- * @method $this setMicros(int $value) Set current instance microsecond to the given value.
- * @method $this setMicro(int $value) Set current instance microsecond to the given value.
- * @method $this microseconds(int $value) Set current instance microsecond to the given value.
- * @method $this microsecond(int $value) Set current instance microsecond to the given value.
- * @method $this setMicroseconds(int $value) Set current instance microsecond to the given value.
- * @method $this setMicrosecond(int $value) Set current instance microsecond to the given value.
- * @method $this addYears(int $value = 1) Add years (the $value count passed in) to the instance (using date interval).
- * @method $this addYear() Add one year to the instance (using date interval).
- * @method $this subYears(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval).
- * @method $this subYear() Sub one year to the instance (using date interval).
- * @method $this addYearsWithOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addYearWithOverflow() Add one year to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subYearsWithOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subYearWithOverflow() Sub one year to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addYearsWithoutOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addYearWithoutOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subYearsWithoutOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subYearWithoutOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addYearsWithNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addYearWithNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subYearsWithNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subYearWithNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addYearsNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addYearNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subYearsNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subYearNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMonths(int $value = 1) Add months (the $value count passed in) to the instance (using date interval).
- * @method $this addMonth() Add one month to the instance (using date interval).
- * @method $this subMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval).
- * @method $this subMonth() Sub one month to the instance (using date interval).
- * @method $this addMonthsWithOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addMonthWithOverflow() Add one month to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subMonthsWithOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subMonthWithOverflow() Sub one month to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addMonthsWithoutOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMonthWithoutOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMonthsWithoutOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMonthWithoutOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMonthsWithNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMonthWithNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMonthsWithNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMonthWithNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMonthsNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMonthNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMonthsNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMonthNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addDays(int $value = 1) Add days (the $value count passed in) to the instance (using date interval).
- * @method $this addDay() Add one day to the instance (using date interval).
- * @method $this subDays(int $value = 1) Sub days (the $value count passed in) to the instance (using date interval).
- * @method $this subDay() Sub one day to the instance (using date interval).
- * @method $this addHours(int $value = 1) Add hours (the $value count passed in) to the instance (using date interval).
- * @method $this addHour() Add one hour to the instance (using date interval).
- * @method $this subHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using date interval).
- * @method $this subHour() Sub one hour to the instance (using date interval).
- * @method $this addMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using date interval).
- * @method $this addMinute() Add one minute to the instance (using date interval).
- * @method $this subMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using date interval).
- * @method $this subMinute() Sub one minute to the instance (using date interval).
- * @method $this addSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using date interval).
- * @method $this addSecond() Add one second to the instance (using date interval).
- * @method $this subSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using date interval).
- * @method $this subSecond() Sub one second to the instance (using date interval).
- * @method $this addMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
- * @method $this addMilli() Add one millisecond to the instance (using date interval).
- * @method $this subMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
- * @method $this subMilli() Sub one millisecond to the instance (using date interval).
- * @method $this addMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
- * @method $this addMillisecond() Add one millisecond to the instance (using date interval).
- * @method $this subMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
- * @method $this subMillisecond() Sub one millisecond to the instance (using date interval).
- * @method $this addMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
- * @method $this addMicro() Add one microsecond to the instance (using date interval).
- * @method $this subMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
- * @method $this subMicro() Sub one microsecond to the instance (using date interval).
- * @method $this addMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
- * @method $this addMicrosecond() Add one microsecond to the instance (using date interval).
- * @method $this subMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
- * @method $this subMicrosecond() Sub one microsecond to the instance (using date interval).
- * @method $this addMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval).
- * @method $this addMillennium() Add one millennium to the instance (using date interval).
- * @method $this subMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval).
- * @method $this subMillennium() Sub one millennium to the instance (using date interval).
- * @method $this addMillenniaWithOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addMillenniumWithOverflow() Add one millennium to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subMillenniaWithOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subMillenniumWithOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addMillenniaWithoutOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMillenniumWithoutOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMillenniaWithoutOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMillenniumWithoutOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMillenniaWithNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMillenniumWithNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMillenniaWithNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMillenniumWithNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMillenniaNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addMillenniumNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMillenniaNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subMillenniumNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval).
- * @method $this addCentury() Add one century to the instance (using date interval).
- * @method $this subCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval).
- * @method $this subCentury() Sub one century to the instance (using date interval).
- * @method $this addCenturiesWithOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addCenturyWithOverflow() Add one century to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subCenturiesWithOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subCenturyWithOverflow() Sub one century to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addCenturiesWithoutOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addCenturyWithoutOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subCenturiesWithoutOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subCenturyWithoutOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addCenturiesWithNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addCenturyWithNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subCenturiesWithNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subCenturyWithNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addCenturiesNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addCenturyNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subCenturiesNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subCenturyNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval).
- * @method $this addDecade() Add one decade to the instance (using date interval).
- * @method $this subDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval).
- * @method $this subDecade() Sub one decade to the instance (using date interval).
- * @method $this addDecadesWithOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addDecadeWithOverflow() Add one decade to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subDecadesWithOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subDecadeWithOverflow() Sub one decade to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addDecadesWithoutOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addDecadeWithoutOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subDecadesWithoutOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subDecadeWithoutOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addDecadesWithNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addDecadeWithNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subDecadesWithNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subDecadeWithNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addDecadesNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addDecadeNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subDecadesNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subDecadeNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval).
- * @method $this addQuarter() Add one quarter to the instance (using date interval).
- * @method $this subQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval).
- * @method $this subQuarter() Sub one quarter to the instance (using date interval).
- * @method $this addQuartersWithOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addQuarterWithOverflow() Add one quarter to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subQuartersWithOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method $this subQuarterWithOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly allowed.
- * @method $this addQuartersWithoutOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addQuarterWithoutOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subQuartersWithoutOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subQuarterWithoutOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addQuartersWithNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addQuarterWithNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subQuartersWithNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subQuarterWithNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addQuartersNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addQuarterNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subQuartersNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this subQuarterNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method $this addWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using date interval).
- * @method $this addWeek() Add one week to the instance (using date interval).
- * @method $this subWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using date interval).
- * @method $this subWeek() Sub one week to the instance (using date interval).
- * @method $this addWeekdays(int $value = 1) Add weekdays (the $value count passed in) to the instance (using date interval).
- * @method $this addWeekday() Add one weekday to the instance (using date interval).
- * @method $this subWeekdays(int $value = 1) Sub weekdays (the $value count passed in) to the instance (using date interval).
- * @method $this subWeekday() Sub one weekday to the instance (using date interval).
- * @method $this addRealMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealMicro() Add one microsecond to the instance (using timestamp).
- * @method $this subRealMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealMicro() Sub one microsecond to the instance (using timestamp).
- * @method CarbonPeriod microsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
- * @method $this addRealMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealMicrosecond() Add one microsecond to the instance (using timestamp).
- * @method $this subRealMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealMicrosecond() Sub one microsecond to the instance (using timestamp).
- * @method CarbonPeriod microsecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
- * @method $this addRealMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealMilli() Add one millisecond to the instance (using timestamp).
- * @method $this subRealMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealMilli() Sub one millisecond to the instance (using timestamp).
- * @method CarbonPeriod millisUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
- * @method $this addRealMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealMillisecond() Add one millisecond to the instance (using timestamp).
- * @method $this subRealMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealMillisecond() Sub one millisecond to the instance (using timestamp).
- * @method CarbonPeriod millisecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
- * @method $this addRealSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealSecond() Add one second to the instance (using timestamp).
- * @method $this subRealSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealSecond() Sub one second to the instance (using timestamp).
- * @method CarbonPeriod secondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each second or every X seconds if a factor is given.
- * @method $this addRealMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealMinute() Add one minute to the instance (using timestamp).
- * @method $this subRealMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealMinute() Sub one minute to the instance (using timestamp).
- * @method CarbonPeriod minutesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each minute or every X minutes if a factor is given.
- * @method $this addRealHours(int $value = 1) Add hours (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealHour() Add one hour to the instance (using timestamp).
- * @method $this subRealHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealHour() Sub one hour to the instance (using timestamp).
- * @method CarbonPeriod hoursUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each hour or every X hours if a factor is given.
- * @method $this addRealDays(int $value = 1) Add days (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealDay() Add one day to the instance (using timestamp).
- * @method $this subRealDays(int $value = 1) Sub days (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealDay() Sub one day to the instance (using timestamp).
- * @method CarbonPeriod daysUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each day or every X days if a factor is given.
- * @method $this addRealWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealWeek() Add one week to the instance (using timestamp).
- * @method $this subRealWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealWeek() Sub one week to the instance (using timestamp).
- * @method CarbonPeriod weeksUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each week or every X weeks if a factor is given.
- * @method $this addRealMonths(int $value = 1) Add months (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealMonth() Add one month to the instance (using timestamp).
- * @method $this subRealMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealMonth() Sub one month to the instance (using timestamp).
- * @method CarbonPeriod monthsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each month or every X months if a factor is given.
- * @method $this addRealQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealQuarter() Add one quarter to the instance (using timestamp).
- * @method $this subRealQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealQuarter() Sub one quarter to the instance (using timestamp).
- * @method CarbonPeriod quartersUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each quarter or every X quarters if a factor is given.
- * @method $this addRealYears(int $value = 1) Add years (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealYear() Add one year to the instance (using timestamp).
- * @method $this subRealYears(int $value = 1) Sub years (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealYear() Sub one year to the instance (using timestamp).
- * @method CarbonPeriod yearsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each year or every X years if a factor is given.
- * @method $this addRealDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealDecade() Add one decade to the instance (using timestamp).
- * @method $this subRealDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealDecade() Sub one decade to the instance (using timestamp).
- * @method CarbonPeriod decadesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each decade or every X decades if a factor is given.
- * @method $this addRealCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealCentury() Add one century to the instance (using timestamp).
- * @method $this subRealCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealCentury() Sub one century to the instance (using timestamp).
- * @method CarbonPeriod centuriesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each century or every X centuries if a factor is given.
- * @method $this addRealMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using timestamp).
- * @method $this addRealMillennium() Add one millennium to the instance (using timestamp).
- * @method $this subRealMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using timestamp).
- * @method $this subRealMillennium() Sub one millennium to the instance (using timestamp).
- * @method CarbonPeriod millenniaUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millennium or every X millennia if a factor is given.
- * @method $this roundYear(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
- * @method $this roundYears(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
- * @method $this floorYear(float $precision = 1) Truncate the current instance year with given precision.
- * @method $this floorYears(float $precision = 1) Truncate the current instance year with given precision.
- * @method $this ceilYear(float $precision = 1) Ceil the current instance year with given precision.
- * @method $this ceilYears(float $precision = 1) Ceil the current instance year with given precision.
- * @method $this roundMonth(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
- * @method $this roundMonths(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
- * @method $this floorMonth(float $precision = 1) Truncate the current instance month with given precision.
- * @method $this floorMonths(float $precision = 1) Truncate the current instance month with given precision.
- * @method $this ceilMonth(float $precision = 1) Ceil the current instance month with given precision.
- * @method $this ceilMonths(float $precision = 1) Ceil the current instance month with given precision.
- * @method $this roundDay(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
- * @method $this roundDays(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
- * @method $this floorDay(float $precision = 1) Truncate the current instance day with given precision.
- * @method $this floorDays(float $precision = 1) Truncate the current instance day with given precision.
- * @method $this ceilDay(float $precision = 1) Ceil the current instance day with given precision.
- * @method $this ceilDays(float $precision = 1) Ceil the current instance day with given precision.
- * @method $this roundHour(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
- * @method $this roundHours(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
- * @method $this floorHour(float $precision = 1) Truncate the current instance hour with given precision.
- * @method $this floorHours(float $precision = 1) Truncate the current instance hour with given precision.
- * @method $this ceilHour(float $precision = 1) Ceil the current instance hour with given precision.
- * @method $this ceilHours(float $precision = 1) Ceil the current instance hour with given precision.
- * @method $this roundMinute(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
- * @method $this roundMinutes(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
- * @method $this floorMinute(float $precision = 1) Truncate the current instance minute with given precision.
- * @method $this floorMinutes(float $precision = 1) Truncate the current instance minute with given precision.
- * @method $this ceilMinute(float $precision = 1) Ceil the current instance minute with given precision.
- * @method $this ceilMinutes(float $precision = 1) Ceil the current instance minute with given precision.
- * @method $this roundSecond(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
- * @method $this roundSeconds(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
- * @method $this floorSecond(float $precision = 1) Truncate the current instance second with given precision.
- * @method $this floorSeconds(float $precision = 1) Truncate the current instance second with given precision.
- * @method $this ceilSecond(float $precision = 1) Ceil the current instance second with given precision.
- * @method $this ceilSeconds(float $precision = 1) Ceil the current instance second with given precision.
- * @method $this roundMillennium(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
- * @method $this roundMillennia(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
- * @method $this floorMillennium(float $precision = 1) Truncate the current instance millennium with given precision.
- * @method $this floorMillennia(float $precision = 1) Truncate the current instance millennium with given precision.
- * @method $this ceilMillennium(float $precision = 1) Ceil the current instance millennium with given precision.
- * @method $this ceilMillennia(float $precision = 1) Ceil the current instance millennium with given precision.
- * @method $this roundCentury(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
- * @method $this roundCenturies(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
- * @method $this floorCentury(float $precision = 1) Truncate the current instance century with given precision.
- * @method $this floorCenturies(float $precision = 1) Truncate the current instance century with given precision.
- * @method $this ceilCentury(float $precision = 1) Ceil the current instance century with given precision.
- * @method $this ceilCenturies(float $precision = 1) Ceil the current instance century with given precision.
- * @method $this roundDecade(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
- * @method $this roundDecades(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
- * @method $this floorDecade(float $precision = 1) Truncate the current instance decade with given precision.
- * @method $this floorDecades(float $precision = 1) Truncate the current instance decade with given precision.
- * @method $this ceilDecade(float $precision = 1) Ceil the current instance decade with given precision.
- * @method $this ceilDecades(float $precision = 1) Ceil the current instance decade with given precision.
- * @method $this roundQuarter(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
- * @method $this roundQuarters(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
- * @method $this floorQuarter(float $precision = 1) Truncate the current instance quarter with given precision.
- * @method $this floorQuarters(float $precision = 1) Truncate the current instance quarter with given precision.
- * @method $this ceilQuarter(float $precision = 1) Ceil the current instance quarter with given precision.
- * @method $this ceilQuarters(float $precision = 1) Ceil the current instance quarter with given precision.
- * @method $this roundMillisecond(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
- * @method $this roundMilliseconds(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
- * @method $this floorMillisecond(float $precision = 1) Truncate the current instance millisecond with given precision.
- * @method $this floorMilliseconds(float $precision = 1) Truncate the current instance millisecond with given precision.
- * @method $this ceilMillisecond(float $precision = 1) Ceil the current instance millisecond with given precision.
- * @method $this ceilMilliseconds(float $precision = 1) Ceil the current instance millisecond with given precision.
- * @method $this roundMicrosecond(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
- * @method $this roundMicroseconds(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
- * @method $this floorMicrosecond(float $precision = 1) Truncate the current instance microsecond with given precision.
- * @method $this floorMicroseconds(float $precision = 1) Truncate the current instance microsecond with given precision.
- * @method $this ceilMicrosecond(float $precision = 1) Ceil the current instance microsecond with given precision.
- * @method $this ceilMicroseconds(float $precision = 1) Ceil the current instance microsecond with given precision.
- * @method string shortAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string shortRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string shortRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string shortRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method static Carbon|false createFromFormat(string $format, string $time, string|DateTimeZone $timezone = null) Parse a string into a new Carbon object according to the specified format.
- * @method static Carbon __set_state(array $array) https://php.net/manual/en/datetime.set-state.php
+ * @method bool isUtc() Check if the current instance has UTC timezone. (Both isUtc and isUTC cases are valid.)
+ * @method bool isLocal() Check if the current instance has non-UTC timezone.
+ * @method bool isValid() Check if the current instance is a valid date.
+ * @method bool isDST() Check if the current instance is in a daylight saving time.
+ * @method bool isSunday() Checks if the instance day is sunday.
+ * @method bool isMonday() Checks if the instance day is monday.
+ * @method bool isTuesday() Checks if the instance day is tuesday.
+ * @method bool isWednesday() Checks if the instance day is wednesday.
+ * @method bool isThursday() Checks if the instance day is thursday.
+ * @method bool isFriday() Checks if the instance day is friday.
+ * @method bool isSaturday() Checks if the instance day is saturday.
+ * @method bool isSameYear(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same year as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentYear() Checks if the instance is in the same year as the current moment.
+ * @method bool isNextYear() Checks if the instance is in the same year as the current moment next year.
+ * @method bool isLastYear() Checks if the instance is in the same year as the current moment last year.
+ * @method bool isSameWeek(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same week as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentWeek() Checks if the instance is in the same week as the current moment.
+ * @method bool isNextWeek() Checks if the instance is in the same week as the current moment next week.
+ * @method bool isLastWeek() Checks if the instance is in the same week as the current moment last week.
+ * @method bool isSameDay(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same day as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentDay() Checks if the instance is in the same day as the current moment.
+ * @method bool isNextDay() Checks if the instance is in the same day as the current moment next day.
+ * @method bool isLastDay() Checks if the instance is in the same day as the current moment last day.
+ * @method bool isSameHour(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same hour as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentHour() Checks if the instance is in the same hour as the current moment.
+ * @method bool isNextHour() Checks if the instance is in the same hour as the current moment next hour.
+ * @method bool isLastHour() Checks if the instance is in the same hour as the current moment last hour.
+ * @method bool isSameMinute(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same minute as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMinute() Checks if the instance is in the same minute as the current moment.
+ * @method bool isNextMinute() Checks if the instance is in the same minute as the current moment next minute.
+ * @method bool isLastMinute() Checks if the instance is in the same minute as the current moment last minute.
+ * @method bool isSameSecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same second as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentSecond() Checks if the instance is in the same second as the current moment.
+ * @method bool isNextSecond() Checks if the instance is in the same second as the current moment next second.
+ * @method bool isLastSecond() Checks if the instance is in the same second as the current moment last second.
+ * @method bool isSameMicro(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMicro() Checks if the instance is in the same microsecond as the current moment.
+ * @method bool isNextMicro() Checks if the instance is in the same microsecond as the current moment next microsecond.
+ * @method bool isLastMicro() Checks if the instance is in the same microsecond as the current moment last microsecond.
+ * @method bool isSameMicrosecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMicrosecond() Checks if the instance is in the same microsecond as the current moment.
+ * @method bool isNextMicrosecond() Checks if the instance is in the same microsecond as the current moment next microsecond.
+ * @method bool isLastMicrosecond() Checks if the instance is in the same microsecond as the current moment last microsecond.
+ * @method bool isCurrentMonth() Checks if the instance is in the same month as the current moment.
+ * @method bool isNextMonth() Checks if the instance is in the same month as the current moment next month.
+ * @method bool isLastMonth() Checks if the instance is in the same month as the current moment last month.
+ * @method bool isCurrentQuarter() Checks if the instance is in the same quarter as the current moment.
+ * @method bool isNextQuarter() Checks if the instance is in the same quarter as the current moment next quarter.
+ * @method bool isLastQuarter() Checks if the instance is in the same quarter as the current moment last quarter.
+ * @method bool isSameDecade(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same decade as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentDecade() Checks if the instance is in the same decade as the current moment.
+ * @method bool isNextDecade() Checks if the instance is in the same decade as the current moment next decade.
+ * @method bool isLastDecade() Checks if the instance is in the same decade as the current moment last decade.
+ * @method bool isSameCentury(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same century as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentCentury() Checks if the instance is in the same century as the current moment.
+ * @method bool isNextCentury() Checks if the instance is in the same century as the current moment next century.
+ * @method bool isLastCentury() Checks if the instance is in the same century as the current moment last century.
+ * @method bool isSameMillennium(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same millennium as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMillennium() Checks if the instance is in the same millennium as the current moment.
+ * @method bool isNextMillennium() Checks if the instance is in the same millennium as the current moment next millennium.
+ * @method bool isLastMillennium() Checks if the instance is in the same millennium as the current moment last millennium.
+ * @method $this years(int $value) Set current instance year to the given value.
+ * @method $this year(int $value) Set current instance year to the given value.
+ * @method $this setYears(int $value) Set current instance year to the given value.
+ * @method $this setYear(int $value) Set current instance year to the given value.
+ * @method $this months(int $value) Set current instance month to the given value.
+ * @method $this month(int $value) Set current instance month to the given value.
+ * @method $this setMonths(int $value) Set current instance month to the given value.
+ * @method $this setMonth(int $value) Set current instance month to the given value.
+ * @method $this days(int $value) Set current instance day to the given value.
+ * @method $this day(int $value) Set current instance day to the given value.
+ * @method $this setDays(int $value) Set current instance day to the given value.
+ * @method $this setDay(int $value) Set current instance day to the given value.
+ * @method $this hours(int $value) Set current instance hour to the given value.
+ * @method $this hour(int $value) Set current instance hour to the given value.
+ * @method $this setHours(int $value) Set current instance hour to the given value.
+ * @method $this setHour(int $value) Set current instance hour to the given value.
+ * @method $this minutes(int $value) Set current instance minute to the given value.
+ * @method $this minute(int $value) Set current instance minute to the given value.
+ * @method $this setMinutes(int $value) Set current instance minute to the given value.
+ * @method $this setMinute(int $value) Set current instance minute to the given value.
+ * @method $this seconds(int $value) Set current instance second to the given value.
+ * @method $this second(int $value) Set current instance second to the given value.
+ * @method $this setSeconds(int $value) Set current instance second to the given value.
+ * @method $this setSecond(int $value) Set current instance second to the given value.
+ * @method $this millis(int $value) Set current instance millisecond to the given value.
+ * @method $this milli(int $value) Set current instance millisecond to the given value.
+ * @method $this setMillis(int $value) Set current instance millisecond to the given value.
+ * @method $this setMilli(int $value) Set current instance millisecond to the given value.
+ * @method $this milliseconds(int $value) Set current instance millisecond to the given value.
+ * @method $this millisecond(int $value) Set current instance millisecond to the given value.
+ * @method $this setMilliseconds(int $value) Set current instance millisecond to the given value.
+ * @method $this setMillisecond(int $value) Set current instance millisecond to the given value.
+ * @method $this micros(int $value) Set current instance microsecond to the given value.
+ * @method $this micro(int $value) Set current instance microsecond to the given value.
+ * @method $this setMicros(int $value) Set current instance microsecond to the given value.
+ * @method $this setMicro(int $value) Set current instance microsecond to the given value.
+ * @method $this microseconds(int $value) Set current instance microsecond to the given value.
+ * @method $this microsecond(int $value) Set current instance microsecond to the given value.
+ * @method $this setMicroseconds(int $value) Set current instance microsecond to the given value.
+ * @method $this setMicrosecond(int $value) Set current instance microsecond to the given value.
+ * @method $this addYears(int $value = 1) Add years (the $value count passed in) to the instance (using date interval).
+ * @method $this addYear() Add one year to the instance (using date interval).
+ * @method $this subYears(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval).
+ * @method $this subYear() Sub one year to the instance (using date interval).
+ * @method $this addYearsWithOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addYearWithOverflow() Add one year to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subYearsWithOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subYearWithOverflow() Sub one year to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addYearsWithoutOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addYearWithoutOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subYearsWithoutOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subYearWithoutOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addYearsWithNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addYearWithNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subYearsWithNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subYearWithNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addYearsNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addYearNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subYearsNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subYearNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMonths(int $value = 1) Add months (the $value count passed in) to the instance (using date interval).
+ * @method $this addMonth() Add one month to the instance (using date interval).
+ * @method $this subMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval).
+ * @method $this subMonth() Sub one month to the instance (using date interval).
+ * @method $this addMonthsWithOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addMonthWithOverflow() Add one month to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subMonthsWithOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subMonthWithOverflow() Sub one month to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addMonthsWithoutOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMonthWithoutOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMonthsWithoutOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMonthWithoutOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMonthsWithNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMonthWithNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMonthsWithNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMonthWithNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMonthsNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMonthNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMonthsNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMonthNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addDays(int $value = 1) Add days (the $value count passed in) to the instance (using date interval).
+ * @method $this addDay() Add one day to the instance (using date interval).
+ * @method $this subDays(int $value = 1) Sub days (the $value count passed in) to the instance (using date interval).
+ * @method $this subDay() Sub one day to the instance (using date interval).
+ * @method $this addHours(int $value = 1) Add hours (the $value count passed in) to the instance (using date interval).
+ * @method $this addHour() Add one hour to the instance (using date interval).
+ * @method $this subHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using date interval).
+ * @method $this subHour() Sub one hour to the instance (using date interval).
+ * @method $this addMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using date interval).
+ * @method $this addMinute() Add one minute to the instance (using date interval).
+ * @method $this subMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using date interval).
+ * @method $this subMinute() Sub one minute to the instance (using date interval).
+ * @method $this addSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using date interval).
+ * @method $this addSecond() Add one second to the instance (using date interval).
+ * @method $this subSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using date interval).
+ * @method $this subSecond() Sub one second to the instance (using date interval).
+ * @method $this addMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this addMilli() Add one millisecond to the instance (using date interval).
+ * @method $this subMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this subMilli() Sub one millisecond to the instance (using date interval).
+ * @method $this addMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this addMillisecond() Add one millisecond to the instance (using date interval).
+ * @method $this subMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this subMillisecond() Sub one millisecond to the instance (using date interval).
+ * @method $this addMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this addMicro() Add one microsecond to the instance (using date interval).
+ * @method $this subMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this subMicro() Sub one microsecond to the instance (using date interval).
+ * @method $this addMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this addMicrosecond() Add one microsecond to the instance (using date interval).
+ * @method $this subMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
+ * @method $this subMicrosecond() Sub one microsecond to the instance (using date interval).
+ * @method $this addMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval).
+ * @method $this addMillennium() Add one millennium to the instance (using date interval).
+ * @method $this subMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval).
+ * @method $this subMillennium() Sub one millennium to the instance (using date interval).
+ * @method $this addMillenniaWithOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addMillenniumWithOverflow() Add one millennium to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subMillenniaWithOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subMillenniumWithOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addMillenniaWithoutOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMillenniumWithoutOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMillenniaWithoutOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMillenniumWithoutOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMillenniaWithNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMillenniumWithNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMillenniaWithNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMillenniumWithNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMillenniaNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addMillenniumNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMillenniaNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subMillenniumNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval).
+ * @method $this addCentury() Add one century to the instance (using date interval).
+ * @method $this subCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval).
+ * @method $this subCentury() Sub one century to the instance (using date interval).
+ * @method $this addCenturiesWithOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addCenturyWithOverflow() Add one century to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subCenturiesWithOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subCenturyWithOverflow() Sub one century to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addCenturiesWithoutOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addCenturyWithoutOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subCenturiesWithoutOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subCenturyWithoutOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addCenturiesWithNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addCenturyWithNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subCenturiesWithNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subCenturyWithNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addCenturiesNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addCenturyNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subCenturiesNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subCenturyNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval).
+ * @method $this addDecade() Add one decade to the instance (using date interval).
+ * @method $this subDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval).
+ * @method $this subDecade() Sub one decade to the instance (using date interval).
+ * @method $this addDecadesWithOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addDecadeWithOverflow() Add one decade to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subDecadesWithOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subDecadeWithOverflow() Sub one decade to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addDecadesWithoutOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addDecadeWithoutOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subDecadesWithoutOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subDecadeWithoutOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addDecadesWithNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addDecadeWithNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subDecadesWithNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subDecadeWithNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addDecadesNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addDecadeNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subDecadesNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subDecadeNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval).
+ * @method $this addQuarter() Add one quarter to the instance (using date interval).
+ * @method $this subQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval).
+ * @method $this subQuarter() Sub one quarter to the instance (using date interval).
+ * @method $this addQuartersWithOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addQuarterWithOverflow() Add one quarter to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subQuartersWithOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this subQuarterWithOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly allowed.
+ * @method $this addQuartersWithoutOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addQuarterWithoutOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subQuartersWithoutOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subQuarterWithoutOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addQuartersWithNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addQuarterWithNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subQuartersWithNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subQuarterWithNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addQuartersNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addQuarterNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subQuartersNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this subQuarterNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method $this addWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using date interval).
+ * @method $this addWeek() Add one week to the instance (using date interval).
+ * @method $this subWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using date interval).
+ * @method $this subWeek() Sub one week to the instance (using date interval).
+ * @method $this addWeekdays(int $value = 1) Add weekdays (the $value count passed in) to the instance (using date interval).
+ * @method $this addWeekday() Add one weekday to the instance (using date interval).
+ * @method $this subWeekdays(int $value = 1) Sub weekdays (the $value count passed in) to the instance (using date interval).
+ * @method $this subWeekday() Sub one weekday to the instance (using date interval).
+ * @method $this addRealMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealMicro() Add one microsecond to the instance (using timestamp).
+ * @method $this subRealMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealMicro() Sub one microsecond to the instance (using timestamp).
+ * @method CarbonPeriod microsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
+ * @method $this addRealMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealMicrosecond() Add one microsecond to the instance (using timestamp).
+ * @method $this subRealMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealMicrosecond() Sub one microsecond to the instance (using timestamp).
+ * @method CarbonPeriod microsecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
+ * @method $this addRealMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealMilli() Add one millisecond to the instance (using timestamp).
+ * @method $this subRealMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealMilli() Sub one millisecond to the instance (using timestamp).
+ * @method CarbonPeriod millisUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
+ * @method $this addRealMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealMillisecond() Add one millisecond to the instance (using timestamp).
+ * @method $this subRealMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealMillisecond() Sub one millisecond to the instance (using timestamp).
+ * @method CarbonPeriod millisecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
+ * @method $this addRealSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealSecond() Add one second to the instance (using timestamp).
+ * @method $this subRealSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealSecond() Sub one second to the instance (using timestamp).
+ * @method CarbonPeriod secondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each second or every X seconds if a factor is given.
+ * @method $this addRealMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealMinute() Add one minute to the instance (using timestamp).
+ * @method $this subRealMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealMinute() Sub one minute to the instance (using timestamp).
+ * @method CarbonPeriod minutesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each minute or every X minutes if a factor is given.
+ * @method $this addRealHours(int $value = 1) Add hours (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealHour() Add one hour to the instance (using timestamp).
+ * @method $this subRealHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealHour() Sub one hour to the instance (using timestamp).
+ * @method CarbonPeriod hoursUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each hour or every X hours if a factor is given.
+ * @method $this addRealDays(int $value = 1) Add days (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealDay() Add one day to the instance (using timestamp).
+ * @method $this subRealDays(int $value = 1) Sub days (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealDay() Sub one day to the instance (using timestamp).
+ * @method CarbonPeriod daysUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each day or every X days if a factor is given.
+ * @method $this addRealWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealWeek() Add one week to the instance (using timestamp).
+ * @method $this subRealWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealWeek() Sub one week to the instance (using timestamp).
+ * @method CarbonPeriod weeksUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each week or every X weeks if a factor is given.
+ * @method $this addRealMonths(int $value = 1) Add months (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealMonth() Add one month to the instance (using timestamp).
+ * @method $this subRealMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealMonth() Sub one month to the instance (using timestamp).
+ * @method CarbonPeriod monthsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each month or every X months if a factor is given.
+ * @method $this addRealQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealQuarter() Add one quarter to the instance (using timestamp).
+ * @method $this subRealQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealQuarter() Sub one quarter to the instance (using timestamp).
+ * @method CarbonPeriod quartersUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each quarter or every X quarters if a factor is given.
+ * @method $this addRealYears(int $value = 1) Add years (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealYear() Add one year to the instance (using timestamp).
+ * @method $this subRealYears(int $value = 1) Sub years (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealYear() Sub one year to the instance (using timestamp).
+ * @method CarbonPeriod yearsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each year or every X years if a factor is given.
+ * @method $this addRealDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealDecade() Add one decade to the instance (using timestamp).
+ * @method $this subRealDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealDecade() Sub one decade to the instance (using timestamp).
+ * @method CarbonPeriod decadesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each decade or every X decades if a factor is given.
+ * @method $this addRealCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealCentury() Add one century to the instance (using timestamp).
+ * @method $this subRealCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealCentury() Sub one century to the instance (using timestamp).
+ * @method CarbonPeriod centuriesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each century or every X centuries if a factor is given.
+ * @method $this addRealMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using timestamp).
+ * @method $this addRealMillennium() Add one millennium to the instance (using timestamp).
+ * @method $this subRealMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using timestamp).
+ * @method $this subRealMillennium() Sub one millennium to the instance (using timestamp).
+ * @method CarbonPeriod millenniaUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millennium or every X millennia if a factor is given.
+ * @method $this roundYear(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
+ * @method $this roundYears(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
+ * @method $this floorYear(float $precision = 1) Truncate the current instance year with given precision.
+ * @method $this floorYears(float $precision = 1) Truncate the current instance year with given precision.
+ * @method $this ceilYear(float $precision = 1) Ceil the current instance year with given precision.
+ * @method $this ceilYears(float $precision = 1) Ceil the current instance year with given precision.
+ * @method $this roundMonth(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
+ * @method $this roundMonths(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
+ * @method $this floorMonth(float $precision = 1) Truncate the current instance month with given precision.
+ * @method $this floorMonths(float $precision = 1) Truncate the current instance month with given precision.
+ * @method $this ceilMonth(float $precision = 1) Ceil the current instance month with given precision.
+ * @method $this ceilMonths(float $precision = 1) Ceil the current instance month with given precision.
+ * @method $this roundDay(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
+ * @method $this roundDays(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
+ * @method $this floorDay(float $precision = 1) Truncate the current instance day with given precision.
+ * @method $this floorDays(float $precision = 1) Truncate the current instance day with given precision.
+ * @method $this ceilDay(float $precision = 1) Ceil the current instance day with given precision.
+ * @method $this ceilDays(float $precision = 1) Ceil the current instance day with given precision.
+ * @method $this roundHour(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
+ * @method $this roundHours(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
+ * @method $this floorHour(float $precision = 1) Truncate the current instance hour with given precision.
+ * @method $this floorHours(float $precision = 1) Truncate the current instance hour with given precision.
+ * @method $this ceilHour(float $precision = 1) Ceil the current instance hour with given precision.
+ * @method $this ceilHours(float $precision = 1) Ceil the current instance hour with given precision.
+ * @method $this roundMinute(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
+ * @method $this roundMinutes(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
+ * @method $this floorMinute(float $precision = 1) Truncate the current instance minute with given precision.
+ * @method $this floorMinutes(float $precision = 1) Truncate the current instance minute with given precision.
+ * @method $this ceilMinute(float $precision = 1) Ceil the current instance minute with given precision.
+ * @method $this ceilMinutes(float $precision = 1) Ceil the current instance minute with given precision.
+ * @method $this roundSecond(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
+ * @method $this roundSeconds(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
+ * @method $this floorSecond(float $precision = 1) Truncate the current instance second with given precision.
+ * @method $this floorSeconds(float $precision = 1) Truncate the current instance second with given precision.
+ * @method $this ceilSecond(float $precision = 1) Ceil the current instance second with given precision.
+ * @method $this ceilSeconds(float $precision = 1) Ceil the current instance second with given precision.
+ * @method $this roundMillennium(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
+ * @method $this roundMillennia(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
+ * @method $this floorMillennium(float $precision = 1) Truncate the current instance millennium with given precision.
+ * @method $this floorMillennia(float $precision = 1) Truncate the current instance millennium with given precision.
+ * @method $this ceilMillennium(float $precision = 1) Ceil the current instance millennium with given precision.
+ * @method $this ceilMillennia(float $precision = 1) Ceil the current instance millennium with given precision.
+ * @method $this roundCentury(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
+ * @method $this roundCenturies(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
+ * @method $this floorCentury(float $precision = 1) Truncate the current instance century with given precision.
+ * @method $this floorCenturies(float $precision = 1) Truncate the current instance century with given precision.
+ * @method $this ceilCentury(float $precision = 1) Ceil the current instance century with given precision.
+ * @method $this ceilCenturies(float $precision = 1) Ceil the current instance century with given precision.
+ * @method $this roundDecade(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
+ * @method $this roundDecades(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
+ * @method $this floorDecade(float $precision = 1) Truncate the current instance decade with given precision.
+ * @method $this floorDecades(float $precision = 1) Truncate the current instance decade with given precision.
+ * @method $this ceilDecade(float $precision = 1) Ceil the current instance decade with given precision.
+ * @method $this ceilDecades(float $precision = 1) Ceil the current instance decade with given precision.
+ * @method $this roundQuarter(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
+ * @method $this roundQuarters(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
+ * @method $this floorQuarter(float $precision = 1) Truncate the current instance quarter with given precision.
+ * @method $this floorQuarters(float $precision = 1) Truncate the current instance quarter with given precision.
+ * @method $this ceilQuarter(float $precision = 1) Ceil the current instance quarter with given precision.
+ * @method $this ceilQuarters(float $precision = 1) Ceil the current instance quarter with given precision.
+ * @method $this roundMillisecond(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
+ * @method $this roundMilliseconds(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
+ * @method $this floorMillisecond(float $precision = 1) Truncate the current instance millisecond with given precision.
+ * @method $this floorMilliseconds(float $precision = 1) Truncate the current instance millisecond with given precision.
+ * @method $this ceilMillisecond(float $precision = 1) Ceil the current instance millisecond with given precision.
+ * @method $this ceilMilliseconds(float $precision = 1) Ceil the current instance millisecond with given precision.
+ * @method $this roundMicrosecond(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
+ * @method $this roundMicroseconds(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
+ * @method $this floorMicrosecond(float $precision = 1) Truncate the current instance microsecond with given precision.
+ * @method $this floorMicroseconds(float $precision = 1) Truncate the current instance microsecond with given precision.
+ * @method $this ceilMicrosecond(float $precision = 1) Ceil the current instance microsecond with given precision.
+ * @method $this ceilMicroseconds(float $precision = 1) Ceil the current instance microsecond with given precision.
+ * @method string shortAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string shortRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string shortRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string shortRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method static static|false createFromFormat(string $format, string $time, DateTimeZone|string|false|null $timezone = null) Parse a string into a new Carbon object according to the specified format.
+ * @method static static __set_state(array $array) https://php.net/manual/en/datetime.set-state.php
*
* </autodoc>
*/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php
index 6d1194e..4c9c1cf 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonImmutable.php
@@ -24,486 +24,486 @@
*
* <autodoc generated by `composer phpdoc`>
*
- * @property int $year
- * @property int $yearIso
- * @property int $month
- * @property int $day
- * @property int $hour
- * @property int $minute
- * @property int $second
- * @property int $micro
- * @property int $microsecond
- * @property int|float|string $timestamp seconds since the Unix Epoch
- * @property string $englishDayOfWeek the day of week in English
- * @property string $shortEnglishDayOfWeek the abbreviated day of week in English
- * @property string $englishMonth the month in English
- * @property string $shortEnglishMonth the abbreviated month in English
- * @property int $milliseconds
- * @property int $millisecond
- * @property int $milli
- * @property int $week 1 through 53
- * @property int $isoWeek 1 through 53
- * @property int $weekYear year according to week format
- * @property int $isoWeekYear year according to ISO week format
- * @property int $dayOfYear 1 through 366
- * @property int $age does a diffInYears() with default parameters
- * @property int $offset the timezone offset in seconds from UTC
- * @property int $offsetMinutes the timezone offset in minutes from UTC
- * @property int $offsetHours the timezone offset in hours from UTC
- * @property CarbonTimeZone $timezone the current timezone
- * @property CarbonTimeZone $tz alias of $timezone
- * @property-read int $dayOfWeek 0 (for Sunday) through 6 (for Saturday)
- * @property-read int $dayOfWeekIso 1 (for Monday) through 7 (for Sunday)
- * @property-read int $weekOfYear ISO-8601 week number of year, weeks starting on Monday
- * @property-read int $daysInMonth number of days in the given month
- * @property-read string $latinMeridiem "am"/"pm" (Ante meridiem or Post meridiem latin lowercase mark)
- * @property-read string $latinUpperMeridiem "AM"/"PM" (Ante meridiem or Post meridiem latin uppercase mark)
- * @property-read string $timezoneAbbreviatedName the current timezone abbreviated name
- * @property-read string $tzAbbrName alias of $timezoneAbbreviatedName
- * @property-read string $dayName long name of weekday translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $shortDayName short name of weekday translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $minDayName very short name of weekday translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $monthName long name of month translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $shortMonthName short name of month translated according to Carbon locale, in english if no translation available for current language
- * @property-read string $meridiem lowercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
- * @property-read string $upperMeridiem uppercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
- * @property-read int $noZeroHour current hour from 1 to 24
- * @property-read int $weeksInYear 51 through 53
- * @property-read int $isoWeeksInYear 51 through 53
- * @property-read int $weekOfMonth 1 through 5
- * @property-read int $weekNumberInMonth 1 through 5
- * @property-read int $firstWeekDay 0 through 6
- * @property-read int $lastWeekDay 0 through 6
- * @property-read int $daysInYear 365 or 366
- * @property-read int $quarter the quarter of this instance, 1 - 4
- * @property-read int $decade the decade of this instance
- * @property-read int $century the century of this instance
- * @property-read int $millennium the millennium of this instance
- * @property-read bool $dst daylight savings time indicator, true if DST, false otherwise
- * @property-read bool $local checks if the timezone is local, true if local, false otherwise
- * @property-read bool $utc checks if the timezone is UTC, true if UTC, false otherwise
- * @property-read string $timezoneName the current timezone name
- * @property-read string $tzName alias of $timezoneName
- * @property-read string $locale locale of the current instance
+ * @property int $year
+ * @property int $yearIso
+ * @property int $month
+ * @property int $day
+ * @property int $hour
+ * @property int $minute
+ * @property int $second
+ * @property int $micro
+ * @property int $microsecond
+ * @property int|float|string $timestamp seconds since the Unix Epoch
+ * @property string $englishDayOfWeek the day of week in English
+ * @property string $shortEnglishDayOfWeek the abbreviated day of week in English
+ * @property string $englishMonth the month in English
+ * @property string $shortEnglishMonth the abbreviated month in English
+ * @property int $milliseconds
+ * @property int $millisecond
+ * @property int $milli
+ * @property int $week 1 through 53
+ * @property int $isoWeek 1 through 53
+ * @property int $weekYear year according to week format
+ * @property int $isoWeekYear year according to ISO week format
+ * @property int $dayOfYear 1 through 366
+ * @property int $age does a diffInYears() with default parameters
+ * @property int $offset the timezone offset in seconds from UTC
+ * @property int $offsetMinutes the timezone offset in minutes from UTC
+ * @property int $offsetHours the timezone offset in hours from UTC
+ * @property CarbonTimeZone $timezone the current timezone
+ * @property CarbonTimeZone $tz alias of $timezone
+ * @property-read int $dayOfWeek 0 (for Sunday) through 6 (for Saturday)
+ * @property-read int $dayOfWeekIso 1 (for Monday) through 7 (for Sunday)
+ * @property-read int $weekOfYear ISO-8601 week number of year, weeks starting on Monday
+ * @property-read int $daysInMonth number of days in the given month
+ * @property-read string $latinMeridiem "am"/"pm" (Ante meridiem or Post meridiem latin lowercase mark)
+ * @property-read string $latinUpperMeridiem "AM"/"PM" (Ante meridiem or Post meridiem latin uppercase mark)
+ * @property-read string $timezoneAbbreviatedName the current timezone abbreviated name
+ * @property-read string $tzAbbrName alias of $timezoneAbbreviatedName
+ * @property-read string $dayName long name of weekday translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $shortDayName short name of weekday translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $minDayName very short name of weekday translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $monthName long name of month translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $shortMonthName short name of month translated according to Carbon locale, in english if no translation available for current language
+ * @property-read string $meridiem lowercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
+ * @property-read string $upperMeridiem uppercase meridiem mark translated according to Carbon locale, in latin if no translation available for current language
+ * @property-read int $noZeroHour current hour from 1 to 24
+ * @property-read int $weeksInYear 51 through 53
+ * @property-read int $isoWeeksInYear 51 through 53
+ * @property-read int $weekOfMonth 1 through 5
+ * @property-read int $weekNumberInMonth 1 through 5
+ * @property-read int $firstWeekDay 0 through 6
+ * @property-read int $lastWeekDay 0 through 6
+ * @property-read int $daysInYear 365 or 366
+ * @property-read int $quarter the quarter of this instance, 1 - 4
+ * @property-read int $decade the decade of this instance
+ * @property-read int $century the century of this instance
+ * @property-read int $millennium the millennium of this instance
+ * @property-read bool $dst daylight savings time indicator, true if DST, false otherwise
+ * @property-read bool $local checks if the timezone is local, true if local, false otherwise
+ * @property-read bool $utc checks if the timezone is UTC, true if UTC, false otherwise
+ * @property-read string $timezoneName the current timezone name
+ * @property-read string $tzName alias of $timezoneName
+ * @property-read string $locale locale of the current instance
*
- * @method bool isUtc() Check if the current instance has UTC timezone. (Both isUtc and isUTC cases are valid.)
- * @method bool isLocal() Check if the current instance has non-UTC timezone.
- * @method bool isValid() Check if the current instance is a valid date.
- * @method bool isDST() Check if the current instance is in a daylight saving time.
- * @method bool isSunday() Checks if the instance day is sunday.
- * @method bool isMonday() Checks if the instance day is monday.
- * @method bool isTuesday() Checks if the instance day is tuesday.
- * @method bool isWednesday() Checks if the instance day is wednesday.
- * @method bool isThursday() Checks if the instance day is thursday.
- * @method bool isFriday() Checks if the instance day is friday.
- * @method bool isSaturday() Checks if the instance day is saturday.
- * @method bool isSameYear(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same year as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentYear() Checks if the instance is in the same year as the current moment.
- * @method bool isNextYear() Checks if the instance is in the same year as the current moment next year.
- * @method bool isLastYear() Checks if the instance is in the same year as the current moment last year.
- * @method bool isSameWeek(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same week as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentWeek() Checks if the instance is in the same week as the current moment.
- * @method bool isNextWeek() Checks if the instance is in the same week as the current moment next week.
- * @method bool isLastWeek() Checks if the instance is in the same week as the current moment last week.
- * @method bool isSameDay(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same day as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentDay() Checks if the instance is in the same day as the current moment.
- * @method bool isNextDay() Checks if the instance is in the same day as the current moment next day.
- * @method bool isLastDay() Checks if the instance is in the same day as the current moment last day.
- * @method bool isSameHour(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same hour as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentHour() Checks if the instance is in the same hour as the current moment.
- * @method bool isNextHour() Checks if the instance is in the same hour as the current moment next hour.
- * @method bool isLastHour() Checks if the instance is in the same hour as the current moment last hour.
- * @method bool isSameMinute(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same minute as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMinute() Checks if the instance is in the same minute as the current moment.
- * @method bool isNextMinute() Checks if the instance is in the same minute as the current moment next minute.
- * @method bool isLastMinute() Checks if the instance is in the same minute as the current moment last minute.
- * @method bool isSameSecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same second as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentSecond() Checks if the instance is in the same second as the current moment.
- * @method bool isNextSecond() Checks if the instance is in the same second as the current moment next second.
- * @method bool isLastSecond() Checks if the instance is in the same second as the current moment last second.
- * @method bool isSameMicro(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMicro() Checks if the instance is in the same microsecond as the current moment.
- * @method bool isNextMicro() Checks if the instance is in the same microsecond as the current moment next microsecond.
- * @method bool isLastMicro() Checks if the instance is in the same microsecond as the current moment last microsecond.
- * @method bool isSameMicrosecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMicrosecond() Checks if the instance is in the same microsecond as the current moment.
- * @method bool isNextMicrosecond() Checks if the instance is in the same microsecond as the current moment next microsecond.
- * @method bool isLastMicrosecond() Checks if the instance is in the same microsecond as the current moment last microsecond.
- * @method bool isCurrentMonth() Checks if the instance is in the same month as the current moment.
- * @method bool isNextMonth() Checks if the instance is in the same month as the current moment next month.
- * @method bool isLastMonth() Checks if the instance is in the same month as the current moment last month.
- * @method bool isCurrentQuarter() Checks if the instance is in the same quarter as the current moment.
- * @method bool isNextQuarter() Checks if the instance is in the same quarter as the current moment next quarter.
- * @method bool isLastQuarter() Checks if the instance is in the same quarter as the current moment last quarter.
- * @method bool isSameDecade(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same decade as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentDecade() Checks if the instance is in the same decade as the current moment.
- * @method bool isNextDecade() Checks if the instance is in the same decade as the current moment next decade.
- * @method bool isLastDecade() Checks if the instance is in the same decade as the current moment last decade.
- * @method bool isSameCentury(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same century as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentCentury() Checks if the instance is in the same century as the current moment.
- * @method bool isNextCentury() Checks if the instance is in the same century as the current moment next century.
- * @method bool isLastCentury() Checks if the instance is in the same century as the current moment last century.
- * @method bool isSameMillennium(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same millennium as the instance. If null passed, compare to now (with the same timezone).
- * @method bool isCurrentMillennium() Checks if the instance is in the same millennium as the current moment.
- * @method bool isNextMillennium() Checks if the instance is in the same millennium as the current moment next millennium.
- * @method bool isLastMillennium() Checks if the instance is in the same millennium as the current moment last millennium.
- * @method CarbonImmutable years(int $value) Set current instance year to the given value.
- * @method CarbonImmutable year(int $value) Set current instance year to the given value.
- * @method CarbonImmutable setYears(int $value) Set current instance year to the given value.
- * @method CarbonImmutable setYear(int $value) Set current instance year to the given value.
- * @method CarbonImmutable months(int $value) Set current instance month to the given value.
- * @method CarbonImmutable month(int $value) Set current instance month to the given value.
- * @method CarbonImmutable setMonths(int $value) Set current instance month to the given value.
- * @method CarbonImmutable setMonth(int $value) Set current instance month to the given value.
- * @method CarbonImmutable days(int $value) Set current instance day to the given value.
- * @method CarbonImmutable day(int $value) Set current instance day to the given value.
- * @method CarbonImmutable setDays(int $value) Set current instance day to the given value.
- * @method CarbonImmutable setDay(int $value) Set current instance day to the given value.
- * @method CarbonImmutable hours(int $value) Set current instance hour to the given value.
- * @method CarbonImmutable hour(int $value) Set current instance hour to the given value.
- * @method CarbonImmutable setHours(int $value) Set current instance hour to the given value.
- * @method CarbonImmutable setHour(int $value) Set current instance hour to the given value.
- * @method CarbonImmutable minutes(int $value) Set current instance minute to the given value.
- * @method CarbonImmutable minute(int $value) Set current instance minute to the given value.
- * @method CarbonImmutable setMinutes(int $value) Set current instance minute to the given value.
- * @method CarbonImmutable setMinute(int $value) Set current instance minute to the given value.
- * @method CarbonImmutable seconds(int $value) Set current instance second to the given value.
- * @method CarbonImmutable second(int $value) Set current instance second to the given value.
- * @method CarbonImmutable setSeconds(int $value) Set current instance second to the given value.
- * @method CarbonImmutable setSecond(int $value) Set current instance second to the given value.
- * @method CarbonImmutable millis(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable milli(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable setMillis(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable setMilli(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable milliseconds(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable millisecond(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable setMilliseconds(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable setMillisecond(int $value) Set current instance millisecond to the given value.
- * @method CarbonImmutable micros(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable micro(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable setMicros(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable setMicro(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable microseconds(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable microsecond(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable setMicroseconds(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable setMicrosecond(int $value) Set current instance microsecond to the given value.
- * @method CarbonImmutable addYears(int $value = 1) Add years (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addYear() Add one year to the instance (using date interval).
- * @method CarbonImmutable subYears(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subYear() Sub one year to the instance (using date interval).
- * @method CarbonImmutable addYearsWithOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addYearWithOverflow() Add one year to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subYearsWithOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subYearWithOverflow() Sub one year to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addYearsWithoutOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addYearWithoutOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subYearsWithoutOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subYearWithoutOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addYearsWithNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addYearWithNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subYearsWithNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subYearWithNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addYearsNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addYearNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subYearsNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subYearNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMonths(int $value = 1) Add months (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addMonth() Add one month to the instance (using date interval).
- * @method CarbonImmutable subMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subMonth() Sub one month to the instance (using date interval).
- * @method CarbonImmutable addMonthsWithOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addMonthWithOverflow() Add one month to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subMonthsWithOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subMonthWithOverflow() Sub one month to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addMonthsWithoutOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMonthWithoutOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMonthsWithoutOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMonthWithoutOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMonthsWithNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMonthWithNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMonthsWithNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMonthWithNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMonthsNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMonthNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMonthsNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMonthNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addDays(int $value = 1) Add days (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addDay() Add one day to the instance (using date interval).
- * @method CarbonImmutable subDays(int $value = 1) Sub days (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subDay() Sub one day to the instance (using date interval).
- * @method CarbonImmutable addHours(int $value = 1) Add hours (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addHour() Add one hour to the instance (using date interval).
- * @method CarbonImmutable subHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subHour() Sub one hour to the instance (using date interval).
- * @method CarbonImmutable addMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addMinute() Add one minute to the instance (using date interval).
- * @method CarbonImmutable subMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subMinute() Sub one minute to the instance (using date interval).
- * @method CarbonImmutable addSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addSecond() Add one second to the instance (using date interval).
- * @method CarbonImmutable subSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subSecond() Sub one second to the instance (using date interval).
- * @method CarbonImmutable addMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addMilli() Add one millisecond to the instance (using date interval).
- * @method CarbonImmutable subMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subMilli() Sub one millisecond to the instance (using date interval).
- * @method CarbonImmutable addMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addMillisecond() Add one millisecond to the instance (using date interval).
- * @method CarbonImmutable subMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subMillisecond() Sub one millisecond to the instance (using date interval).
- * @method CarbonImmutable addMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addMicro() Add one microsecond to the instance (using date interval).
- * @method CarbonImmutable subMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subMicro() Sub one microsecond to the instance (using date interval).
- * @method CarbonImmutable addMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addMicrosecond() Add one microsecond to the instance (using date interval).
- * @method CarbonImmutable subMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subMicrosecond() Sub one microsecond to the instance (using date interval).
- * @method CarbonImmutable addMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addMillennium() Add one millennium to the instance (using date interval).
- * @method CarbonImmutable subMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subMillennium() Sub one millennium to the instance (using date interval).
- * @method CarbonImmutable addMillenniaWithOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addMillenniumWithOverflow() Add one millennium to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subMillenniaWithOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subMillenniumWithOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addMillenniaWithoutOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMillenniumWithoutOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMillenniaWithoutOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMillenniumWithoutOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMillenniaWithNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMillenniumWithNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMillenniaWithNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMillenniumWithNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMillenniaNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addMillenniumNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMillenniaNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subMillenniumNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addCentury() Add one century to the instance (using date interval).
- * @method CarbonImmutable subCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subCentury() Sub one century to the instance (using date interval).
- * @method CarbonImmutable addCenturiesWithOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addCenturyWithOverflow() Add one century to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subCenturiesWithOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subCenturyWithOverflow() Sub one century to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addCenturiesWithoutOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addCenturyWithoutOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subCenturiesWithoutOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subCenturyWithoutOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addCenturiesWithNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addCenturyWithNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subCenturiesWithNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subCenturyWithNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addCenturiesNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addCenturyNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subCenturiesNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subCenturyNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addDecade() Add one decade to the instance (using date interval).
- * @method CarbonImmutable subDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subDecade() Sub one decade to the instance (using date interval).
- * @method CarbonImmutable addDecadesWithOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addDecadeWithOverflow() Add one decade to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subDecadesWithOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subDecadeWithOverflow() Sub one decade to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addDecadesWithoutOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addDecadeWithoutOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subDecadesWithoutOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subDecadeWithoutOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addDecadesWithNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addDecadeWithNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subDecadesWithNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subDecadeWithNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addDecadesNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addDecadeNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subDecadesNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subDecadeNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addQuarter() Add one quarter to the instance (using date interval).
- * @method CarbonImmutable subQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subQuarter() Sub one quarter to the instance (using date interval).
- * @method CarbonImmutable addQuartersWithOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addQuarterWithOverflow() Add one quarter to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subQuartersWithOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable subQuarterWithOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly allowed.
- * @method CarbonImmutable addQuartersWithoutOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addQuarterWithoutOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subQuartersWithoutOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subQuarterWithoutOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addQuartersWithNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addQuarterWithNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subQuartersWithNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subQuarterWithNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addQuartersNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addQuarterNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subQuartersNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable subQuarterNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
- * @method CarbonImmutable addWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addWeek() Add one week to the instance (using date interval).
- * @method CarbonImmutable subWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subWeek() Sub one week to the instance (using date interval).
- * @method CarbonImmutable addWeekdays(int $value = 1) Add weekdays (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable addWeekday() Add one weekday to the instance (using date interval).
- * @method CarbonImmutable subWeekdays(int $value = 1) Sub weekdays (the $value count passed in) to the instance (using date interval).
- * @method CarbonImmutable subWeekday() Sub one weekday to the instance (using date interval).
- * @method CarbonImmutable addRealMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealMicro() Add one microsecond to the instance (using timestamp).
- * @method CarbonImmutable subRealMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealMicro() Sub one microsecond to the instance (using timestamp).
- * @method CarbonPeriod microsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
- * @method CarbonImmutable addRealMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealMicrosecond() Add one microsecond to the instance (using timestamp).
- * @method CarbonImmutable subRealMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealMicrosecond() Sub one microsecond to the instance (using timestamp).
- * @method CarbonPeriod microsecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
- * @method CarbonImmutable addRealMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealMilli() Add one millisecond to the instance (using timestamp).
- * @method CarbonImmutable subRealMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealMilli() Sub one millisecond to the instance (using timestamp).
- * @method CarbonPeriod millisUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
- * @method CarbonImmutable addRealMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealMillisecond() Add one millisecond to the instance (using timestamp).
- * @method CarbonImmutable subRealMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealMillisecond() Sub one millisecond to the instance (using timestamp).
- * @method CarbonPeriod millisecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
- * @method CarbonImmutable addRealSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealSecond() Add one second to the instance (using timestamp).
- * @method CarbonImmutable subRealSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealSecond() Sub one second to the instance (using timestamp).
- * @method CarbonPeriod secondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each second or every X seconds if a factor is given.
- * @method CarbonImmutable addRealMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealMinute() Add one minute to the instance (using timestamp).
- * @method CarbonImmutable subRealMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealMinute() Sub one minute to the instance (using timestamp).
- * @method CarbonPeriod minutesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each minute or every X minutes if a factor is given.
- * @method CarbonImmutable addRealHours(int $value = 1) Add hours (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealHour() Add one hour to the instance (using timestamp).
- * @method CarbonImmutable subRealHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealHour() Sub one hour to the instance (using timestamp).
- * @method CarbonPeriod hoursUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each hour or every X hours if a factor is given.
- * @method CarbonImmutable addRealDays(int $value = 1) Add days (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealDay() Add one day to the instance (using timestamp).
- * @method CarbonImmutable subRealDays(int $value = 1) Sub days (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealDay() Sub one day to the instance (using timestamp).
- * @method CarbonPeriod daysUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each day or every X days if a factor is given.
- * @method CarbonImmutable addRealWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealWeek() Add one week to the instance (using timestamp).
- * @method CarbonImmutable subRealWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealWeek() Sub one week to the instance (using timestamp).
- * @method CarbonPeriod weeksUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each week or every X weeks if a factor is given.
- * @method CarbonImmutable addRealMonths(int $value = 1) Add months (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealMonth() Add one month to the instance (using timestamp).
- * @method CarbonImmutable subRealMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealMonth() Sub one month to the instance (using timestamp).
- * @method CarbonPeriod monthsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each month or every X months if a factor is given.
- * @method CarbonImmutable addRealQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealQuarter() Add one quarter to the instance (using timestamp).
- * @method CarbonImmutable subRealQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealQuarter() Sub one quarter to the instance (using timestamp).
- * @method CarbonPeriod quartersUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each quarter or every X quarters if a factor is given.
- * @method CarbonImmutable addRealYears(int $value = 1) Add years (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealYear() Add one year to the instance (using timestamp).
- * @method CarbonImmutable subRealYears(int $value = 1) Sub years (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealYear() Sub one year to the instance (using timestamp).
- * @method CarbonPeriod yearsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each year or every X years if a factor is given.
- * @method CarbonImmutable addRealDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealDecade() Add one decade to the instance (using timestamp).
- * @method CarbonImmutable subRealDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealDecade() Sub one decade to the instance (using timestamp).
- * @method CarbonPeriod decadesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each decade or every X decades if a factor is given.
- * @method CarbonImmutable addRealCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealCentury() Add one century to the instance (using timestamp).
- * @method CarbonImmutable subRealCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealCentury() Sub one century to the instance (using timestamp).
- * @method CarbonPeriod centuriesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each century or every X centuries if a factor is given.
- * @method CarbonImmutable addRealMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable addRealMillennium() Add one millennium to the instance (using timestamp).
- * @method CarbonImmutable subRealMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using timestamp).
- * @method CarbonImmutable subRealMillennium() Sub one millennium to the instance (using timestamp).
- * @method CarbonPeriod millenniaUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millennium or every X millennia if a factor is given.
- * @method CarbonImmutable roundYear(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
- * @method CarbonImmutable roundYears(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
- * @method CarbonImmutable floorYear(float $precision = 1) Truncate the current instance year with given precision.
- * @method CarbonImmutable floorYears(float $precision = 1) Truncate the current instance year with given precision.
- * @method CarbonImmutable ceilYear(float $precision = 1) Ceil the current instance year with given precision.
- * @method CarbonImmutable ceilYears(float $precision = 1) Ceil the current instance year with given precision.
- * @method CarbonImmutable roundMonth(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
- * @method CarbonImmutable roundMonths(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
- * @method CarbonImmutable floorMonth(float $precision = 1) Truncate the current instance month with given precision.
- * @method CarbonImmutable floorMonths(float $precision = 1) Truncate the current instance month with given precision.
- * @method CarbonImmutable ceilMonth(float $precision = 1) Ceil the current instance month with given precision.
- * @method CarbonImmutable ceilMonths(float $precision = 1) Ceil the current instance month with given precision.
- * @method CarbonImmutable roundDay(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
- * @method CarbonImmutable roundDays(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
- * @method CarbonImmutable floorDay(float $precision = 1) Truncate the current instance day with given precision.
- * @method CarbonImmutable floorDays(float $precision = 1) Truncate the current instance day with given precision.
- * @method CarbonImmutable ceilDay(float $precision = 1) Ceil the current instance day with given precision.
- * @method CarbonImmutable ceilDays(float $precision = 1) Ceil the current instance day with given precision.
- * @method CarbonImmutable roundHour(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
- * @method CarbonImmutable roundHours(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
- * @method CarbonImmutable floorHour(float $precision = 1) Truncate the current instance hour with given precision.
- * @method CarbonImmutable floorHours(float $precision = 1) Truncate the current instance hour with given precision.
- * @method CarbonImmutable ceilHour(float $precision = 1) Ceil the current instance hour with given precision.
- * @method CarbonImmutable ceilHours(float $precision = 1) Ceil the current instance hour with given precision.
- * @method CarbonImmutable roundMinute(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
- * @method CarbonImmutable roundMinutes(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
- * @method CarbonImmutable floorMinute(float $precision = 1) Truncate the current instance minute with given precision.
- * @method CarbonImmutable floorMinutes(float $precision = 1) Truncate the current instance minute with given precision.
- * @method CarbonImmutable ceilMinute(float $precision = 1) Ceil the current instance minute with given precision.
- * @method CarbonImmutable ceilMinutes(float $precision = 1) Ceil the current instance minute with given precision.
- * @method CarbonImmutable roundSecond(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
- * @method CarbonImmutable roundSeconds(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
- * @method CarbonImmutable floorSecond(float $precision = 1) Truncate the current instance second with given precision.
- * @method CarbonImmutable floorSeconds(float $precision = 1) Truncate the current instance second with given precision.
- * @method CarbonImmutable ceilSecond(float $precision = 1) Ceil the current instance second with given precision.
- * @method CarbonImmutable ceilSeconds(float $precision = 1) Ceil the current instance second with given precision.
- * @method CarbonImmutable roundMillennium(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
- * @method CarbonImmutable roundMillennia(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
- * @method CarbonImmutable floorMillennium(float $precision = 1) Truncate the current instance millennium with given precision.
- * @method CarbonImmutable floorMillennia(float $precision = 1) Truncate the current instance millennium with given precision.
- * @method CarbonImmutable ceilMillennium(float $precision = 1) Ceil the current instance millennium with given precision.
- * @method CarbonImmutable ceilMillennia(float $precision = 1) Ceil the current instance millennium with given precision.
- * @method CarbonImmutable roundCentury(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
- * @method CarbonImmutable roundCenturies(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
- * @method CarbonImmutable floorCentury(float $precision = 1) Truncate the current instance century with given precision.
- * @method CarbonImmutable floorCenturies(float $precision = 1) Truncate the current instance century with given precision.
- * @method CarbonImmutable ceilCentury(float $precision = 1) Ceil the current instance century with given precision.
- * @method CarbonImmutable ceilCenturies(float $precision = 1) Ceil the current instance century with given precision.
- * @method CarbonImmutable roundDecade(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
- * @method CarbonImmutable roundDecades(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
- * @method CarbonImmutable floorDecade(float $precision = 1) Truncate the current instance decade with given precision.
- * @method CarbonImmutable floorDecades(float $precision = 1) Truncate the current instance decade with given precision.
- * @method CarbonImmutable ceilDecade(float $precision = 1) Ceil the current instance decade with given precision.
- * @method CarbonImmutable ceilDecades(float $precision = 1) Ceil the current instance decade with given precision.
- * @method CarbonImmutable roundQuarter(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
- * @method CarbonImmutable roundQuarters(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
- * @method CarbonImmutable floorQuarter(float $precision = 1) Truncate the current instance quarter with given precision.
- * @method CarbonImmutable floorQuarters(float $precision = 1) Truncate the current instance quarter with given precision.
- * @method CarbonImmutable ceilQuarter(float $precision = 1) Ceil the current instance quarter with given precision.
- * @method CarbonImmutable ceilQuarters(float $precision = 1) Ceil the current instance quarter with given precision.
- * @method CarbonImmutable roundMillisecond(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
- * @method CarbonImmutable roundMilliseconds(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
- * @method CarbonImmutable floorMillisecond(float $precision = 1) Truncate the current instance millisecond with given precision.
- * @method CarbonImmutable floorMilliseconds(float $precision = 1) Truncate the current instance millisecond with given precision.
- * @method CarbonImmutable ceilMillisecond(float $precision = 1) Ceil the current instance millisecond with given precision.
- * @method CarbonImmutable ceilMilliseconds(float $precision = 1) Ceil the current instance millisecond with given precision.
- * @method CarbonImmutable roundMicrosecond(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
- * @method CarbonImmutable roundMicroseconds(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
- * @method CarbonImmutable floorMicrosecond(float $precision = 1) Truncate the current instance microsecond with given precision.
- * @method CarbonImmutable floorMicroseconds(float $precision = 1) Truncate the current instance microsecond with given precision.
- * @method CarbonImmutable ceilMicrosecond(float $precision = 1) Ceil the current instance microsecond with given precision.
- * @method CarbonImmutable ceilMicroseconds(float $precision = 1) Ceil the current instance microsecond with given precision.
- * @method string shortAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string shortRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string shortRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string shortRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method string longRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
- * @method static CarbonImmutable|false createFromFormat(string $format, string $time, string|DateTimeZone $timezone = null) Parse a string into a new CarbonImmutable object according to the specified format.
- * @method static CarbonImmutable __set_state(array $array) https://php.net/manual/en/datetime.set-state.php
+ * @method bool isUtc() Check if the current instance has UTC timezone. (Both isUtc and isUTC cases are valid.)
+ * @method bool isLocal() Check if the current instance has non-UTC timezone.
+ * @method bool isValid() Check if the current instance is a valid date.
+ * @method bool isDST() Check if the current instance is in a daylight saving time.
+ * @method bool isSunday() Checks if the instance day is sunday.
+ * @method bool isMonday() Checks if the instance day is monday.
+ * @method bool isTuesday() Checks if the instance day is tuesday.
+ * @method bool isWednesday() Checks if the instance day is wednesday.
+ * @method bool isThursday() Checks if the instance day is thursday.
+ * @method bool isFriday() Checks if the instance day is friday.
+ * @method bool isSaturday() Checks if the instance day is saturday.
+ * @method bool isSameYear(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same year as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentYear() Checks if the instance is in the same year as the current moment.
+ * @method bool isNextYear() Checks if the instance is in the same year as the current moment next year.
+ * @method bool isLastYear() Checks if the instance is in the same year as the current moment last year.
+ * @method bool isSameWeek(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same week as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentWeek() Checks if the instance is in the same week as the current moment.
+ * @method bool isNextWeek() Checks if the instance is in the same week as the current moment next week.
+ * @method bool isLastWeek() Checks if the instance is in the same week as the current moment last week.
+ * @method bool isSameDay(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same day as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentDay() Checks if the instance is in the same day as the current moment.
+ * @method bool isNextDay() Checks if the instance is in the same day as the current moment next day.
+ * @method bool isLastDay() Checks if the instance is in the same day as the current moment last day.
+ * @method bool isSameHour(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same hour as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentHour() Checks if the instance is in the same hour as the current moment.
+ * @method bool isNextHour() Checks if the instance is in the same hour as the current moment next hour.
+ * @method bool isLastHour() Checks if the instance is in the same hour as the current moment last hour.
+ * @method bool isSameMinute(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same minute as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMinute() Checks if the instance is in the same minute as the current moment.
+ * @method bool isNextMinute() Checks if the instance is in the same minute as the current moment next minute.
+ * @method bool isLastMinute() Checks if the instance is in the same minute as the current moment last minute.
+ * @method bool isSameSecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same second as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentSecond() Checks if the instance is in the same second as the current moment.
+ * @method bool isNextSecond() Checks if the instance is in the same second as the current moment next second.
+ * @method bool isLastSecond() Checks if the instance is in the same second as the current moment last second.
+ * @method bool isSameMicro(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMicro() Checks if the instance is in the same microsecond as the current moment.
+ * @method bool isNextMicro() Checks if the instance is in the same microsecond as the current moment next microsecond.
+ * @method bool isLastMicro() Checks if the instance is in the same microsecond as the current moment last microsecond.
+ * @method bool isSameMicrosecond(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same microsecond as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMicrosecond() Checks if the instance is in the same microsecond as the current moment.
+ * @method bool isNextMicrosecond() Checks if the instance is in the same microsecond as the current moment next microsecond.
+ * @method bool isLastMicrosecond() Checks if the instance is in the same microsecond as the current moment last microsecond.
+ * @method bool isCurrentMonth() Checks if the instance is in the same month as the current moment.
+ * @method bool isNextMonth() Checks if the instance is in the same month as the current moment next month.
+ * @method bool isLastMonth() Checks if the instance is in the same month as the current moment last month.
+ * @method bool isCurrentQuarter() Checks if the instance is in the same quarter as the current moment.
+ * @method bool isNextQuarter() Checks if the instance is in the same quarter as the current moment next quarter.
+ * @method bool isLastQuarter() Checks if the instance is in the same quarter as the current moment last quarter.
+ * @method bool isSameDecade(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same decade as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentDecade() Checks if the instance is in the same decade as the current moment.
+ * @method bool isNextDecade() Checks if the instance is in the same decade as the current moment next decade.
+ * @method bool isLastDecade() Checks if the instance is in the same decade as the current moment last decade.
+ * @method bool isSameCentury(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same century as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentCentury() Checks if the instance is in the same century as the current moment.
+ * @method bool isNextCentury() Checks if the instance is in the same century as the current moment next century.
+ * @method bool isLastCentury() Checks if the instance is in the same century as the current moment last century.
+ * @method bool isSameMillennium(Carbon|DateTimeInterface|string|null $date = null) Checks if the given date is in the same millennium as the instance. If null passed, compare to now (with the same timezone).
+ * @method bool isCurrentMillennium() Checks if the instance is in the same millennium as the current moment.
+ * @method bool isNextMillennium() Checks if the instance is in the same millennium as the current moment next millennium.
+ * @method bool isLastMillennium() Checks if the instance is in the same millennium as the current moment last millennium.
+ * @method CarbonImmutable years(int $value) Set current instance year to the given value.
+ * @method CarbonImmutable year(int $value) Set current instance year to the given value.
+ * @method CarbonImmutable setYears(int $value) Set current instance year to the given value.
+ * @method CarbonImmutable setYear(int $value) Set current instance year to the given value.
+ * @method CarbonImmutable months(int $value) Set current instance month to the given value.
+ * @method CarbonImmutable month(int $value) Set current instance month to the given value.
+ * @method CarbonImmutable setMonths(int $value) Set current instance month to the given value.
+ * @method CarbonImmutable setMonth(int $value) Set current instance month to the given value.
+ * @method CarbonImmutable days(int $value) Set current instance day to the given value.
+ * @method CarbonImmutable day(int $value) Set current instance day to the given value.
+ * @method CarbonImmutable setDays(int $value) Set current instance day to the given value.
+ * @method CarbonImmutable setDay(int $value) Set current instance day to the given value.
+ * @method CarbonImmutable hours(int $value) Set current instance hour to the given value.
+ * @method CarbonImmutable hour(int $value) Set current instance hour to the given value.
+ * @method CarbonImmutable setHours(int $value) Set current instance hour to the given value.
+ * @method CarbonImmutable setHour(int $value) Set current instance hour to the given value.
+ * @method CarbonImmutable minutes(int $value) Set current instance minute to the given value.
+ * @method CarbonImmutable minute(int $value) Set current instance minute to the given value.
+ * @method CarbonImmutable setMinutes(int $value) Set current instance minute to the given value.
+ * @method CarbonImmutable setMinute(int $value) Set current instance minute to the given value.
+ * @method CarbonImmutable seconds(int $value) Set current instance second to the given value.
+ * @method CarbonImmutable second(int $value) Set current instance second to the given value.
+ * @method CarbonImmutable setSeconds(int $value) Set current instance second to the given value.
+ * @method CarbonImmutable setSecond(int $value) Set current instance second to the given value.
+ * @method CarbonImmutable millis(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable milli(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable setMillis(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable setMilli(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable milliseconds(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable millisecond(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable setMilliseconds(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable setMillisecond(int $value) Set current instance millisecond to the given value.
+ * @method CarbonImmutable micros(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable micro(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable setMicros(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable setMicro(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable microseconds(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable microsecond(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable setMicroseconds(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable setMicrosecond(int $value) Set current instance microsecond to the given value.
+ * @method CarbonImmutable addYears(int $value = 1) Add years (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addYear() Add one year to the instance (using date interval).
+ * @method CarbonImmutable subYears(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subYear() Sub one year to the instance (using date interval).
+ * @method CarbonImmutable addYearsWithOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addYearWithOverflow() Add one year to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subYearsWithOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subYearWithOverflow() Sub one year to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addYearsWithoutOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addYearWithoutOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subYearsWithoutOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subYearWithoutOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addYearsWithNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addYearWithNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subYearsWithNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subYearWithNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addYearsNoOverflow(int $value = 1) Add years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addYearNoOverflow() Add one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subYearsNoOverflow(int $value = 1) Sub years (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subYearNoOverflow() Sub one year to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMonths(int $value = 1) Add months (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addMonth() Add one month to the instance (using date interval).
+ * @method CarbonImmutable subMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subMonth() Sub one month to the instance (using date interval).
+ * @method CarbonImmutable addMonthsWithOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addMonthWithOverflow() Add one month to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subMonthsWithOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subMonthWithOverflow() Sub one month to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addMonthsWithoutOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMonthWithoutOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMonthsWithoutOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMonthWithoutOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMonthsWithNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMonthWithNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMonthsWithNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMonthWithNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMonthsNoOverflow(int $value = 1) Add months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMonthNoOverflow() Add one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMonthsNoOverflow(int $value = 1) Sub months (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMonthNoOverflow() Sub one month to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addDays(int $value = 1) Add days (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addDay() Add one day to the instance (using date interval).
+ * @method CarbonImmutable subDays(int $value = 1) Sub days (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subDay() Sub one day to the instance (using date interval).
+ * @method CarbonImmutable addHours(int $value = 1) Add hours (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addHour() Add one hour to the instance (using date interval).
+ * @method CarbonImmutable subHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subHour() Sub one hour to the instance (using date interval).
+ * @method CarbonImmutable addMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addMinute() Add one minute to the instance (using date interval).
+ * @method CarbonImmutable subMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subMinute() Sub one minute to the instance (using date interval).
+ * @method CarbonImmutable addSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addSecond() Add one second to the instance (using date interval).
+ * @method CarbonImmutable subSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subSecond() Sub one second to the instance (using date interval).
+ * @method CarbonImmutable addMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addMilli() Add one millisecond to the instance (using date interval).
+ * @method CarbonImmutable subMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subMilli() Sub one millisecond to the instance (using date interval).
+ * @method CarbonImmutable addMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addMillisecond() Add one millisecond to the instance (using date interval).
+ * @method CarbonImmutable subMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subMillisecond() Sub one millisecond to the instance (using date interval).
+ * @method CarbonImmutable addMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addMicro() Add one microsecond to the instance (using date interval).
+ * @method CarbonImmutable subMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subMicro() Sub one microsecond to the instance (using date interval).
+ * @method CarbonImmutable addMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addMicrosecond() Add one microsecond to the instance (using date interval).
+ * @method CarbonImmutable subMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subMicrosecond() Sub one microsecond to the instance (using date interval).
+ * @method CarbonImmutable addMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addMillennium() Add one millennium to the instance (using date interval).
+ * @method CarbonImmutable subMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subMillennium() Sub one millennium to the instance (using date interval).
+ * @method CarbonImmutable addMillenniaWithOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addMillenniumWithOverflow() Add one millennium to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subMillenniaWithOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subMillenniumWithOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addMillenniaWithoutOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMillenniumWithoutOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMillenniaWithoutOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMillenniumWithoutOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMillenniaWithNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMillenniumWithNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMillenniaWithNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMillenniumWithNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMillenniaNoOverflow(int $value = 1) Add millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addMillenniumNoOverflow() Add one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMillenniaNoOverflow(int $value = 1) Sub millennia (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subMillenniumNoOverflow() Sub one millennium to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addCentury() Add one century to the instance (using date interval).
+ * @method CarbonImmutable subCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subCentury() Sub one century to the instance (using date interval).
+ * @method CarbonImmutable addCenturiesWithOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addCenturyWithOverflow() Add one century to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subCenturiesWithOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subCenturyWithOverflow() Sub one century to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addCenturiesWithoutOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addCenturyWithoutOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subCenturiesWithoutOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subCenturyWithoutOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addCenturiesWithNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addCenturyWithNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subCenturiesWithNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subCenturyWithNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addCenturiesNoOverflow(int $value = 1) Add centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addCenturyNoOverflow() Add one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subCenturiesNoOverflow(int $value = 1) Sub centuries (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subCenturyNoOverflow() Sub one century to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addDecade() Add one decade to the instance (using date interval).
+ * @method CarbonImmutable subDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subDecade() Sub one decade to the instance (using date interval).
+ * @method CarbonImmutable addDecadesWithOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addDecadeWithOverflow() Add one decade to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subDecadesWithOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subDecadeWithOverflow() Sub one decade to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addDecadesWithoutOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addDecadeWithoutOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subDecadesWithoutOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subDecadeWithoutOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addDecadesWithNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addDecadeWithNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subDecadesWithNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subDecadeWithNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addDecadesNoOverflow(int $value = 1) Add decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addDecadeNoOverflow() Add one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subDecadesNoOverflow(int $value = 1) Sub decades (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subDecadeNoOverflow() Sub one decade to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addQuarter() Add one quarter to the instance (using date interval).
+ * @method CarbonImmutable subQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subQuarter() Sub one quarter to the instance (using date interval).
+ * @method CarbonImmutable addQuartersWithOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addQuarterWithOverflow() Add one quarter to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subQuartersWithOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable subQuarterWithOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly allowed.
+ * @method CarbonImmutable addQuartersWithoutOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addQuarterWithoutOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subQuartersWithoutOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subQuarterWithoutOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addQuartersWithNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addQuarterWithNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subQuartersWithNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subQuarterWithNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addQuartersNoOverflow(int $value = 1) Add quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addQuarterNoOverflow() Add one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subQuartersNoOverflow(int $value = 1) Sub quarters (the $value count passed in) to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable subQuarterNoOverflow() Sub one quarter to the instance (using date interval) with overflow explicitly forbidden.
+ * @method CarbonImmutable addWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addWeek() Add one week to the instance (using date interval).
+ * @method CarbonImmutable subWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subWeek() Sub one week to the instance (using date interval).
+ * @method CarbonImmutable addWeekdays(int $value = 1) Add weekdays (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable addWeekday() Add one weekday to the instance (using date interval).
+ * @method CarbonImmutable subWeekdays(int $value = 1) Sub weekdays (the $value count passed in) to the instance (using date interval).
+ * @method CarbonImmutable subWeekday() Sub one weekday to the instance (using date interval).
+ * @method CarbonImmutable addRealMicros(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealMicro() Add one microsecond to the instance (using timestamp).
+ * @method CarbonImmutable subRealMicros(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealMicro() Sub one microsecond to the instance (using timestamp).
+ * @method CarbonPeriod microsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
+ * @method CarbonImmutable addRealMicroseconds(int $value = 1) Add microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealMicrosecond() Add one microsecond to the instance (using timestamp).
+ * @method CarbonImmutable subRealMicroseconds(int $value = 1) Sub microseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealMicrosecond() Sub one microsecond to the instance (using timestamp).
+ * @method CarbonPeriod microsecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each microsecond or every X microseconds if a factor is given.
+ * @method CarbonImmutable addRealMillis(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealMilli() Add one millisecond to the instance (using timestamp).
+ * @method CarbonImmutable subRealMillis(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealMilli() Sub one millisecond to the instance (using timestamp).
+ * @method CarbonPeriod millisUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
+ * @method CarbonImmutable addRealMilliseconds(int $value = 1) Add milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealMillisecond() Add one millisecond to the instance (using timestamp).
+ * @method CarbonImmutable subRealMilliseconds(int $value = 1) Sub milliseconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealMillisecond() Sub one millisecond to the instance (using timestamp).
+ * @method CarbonPeriod millisecondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millisecond or every X milliseconds if a factor is given.
+ * @method CarbonImmutable addRealSeconds(int $value = 1) Add seconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealSecond() Add one second to the instance (using timestamp).
+ * @method CarbonImmutable subRealSeconds(int $value = 1) Sub seconds (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealSecond() Sub one second to the instance (using timestamp).
+ * @method CarbonPeriod secondsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each second or every X seconds if a factor is given.
+ * @method CarbonImmutable addRealMinutes(int $value = 1) Add minutes (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealMinute() Add one minute to the instance (using timestamp).
+ * @method CarbonImmutable subRealMinutes(int $value = 1) Sub minutes (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealMinute() Sub one minute to the instance (using timestamp).
+ * @method CarbonPeriod minutesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each minute or every X minutes if a factor is given.
+ * @method CarbonImmutable addRealHours(int $value = 1) Add hours (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealHour() Add one hour to the instance (using timestamp).
+ * @method CarbonImmutable subRealHours(int $value = 1) Sub hours (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealHour() Sub one hour to the instance (using timestamp).
+ * @method CarbonPeriod hoursUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each hour or every X hours if a factor is given.
+ * @method CarbonImmutable addRealDays(int $value = 1) Add days (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealDay() Add one day to the instance (using timestamp).
+ * @method CarbonImmutable subRealDays(int $value = 1) Sub days (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealDay() Sub one day to the instance (using timestamp).
+ * @method CarbonPeriod daysUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each day or every X days if a factor is given.
+ * @method CarbonImmutable addRealWeeks(int $value = 1) Add weeks (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealWeek() Add one week to the instance (using timestamp).
+ * @method CarbonImmutable subRealWeeks(int $value = 1) Sub weeks (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealWeek() Sub one week to the instance (using timestamp).
+ * @method CarbonPeriod weeksUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each week or every X weeks if a factor is given.
+ * @method CarbonImmutable addRealMonths(int $value = 1) Add months (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealMonth() Add one month to the instance (using timestamp).
+ * @method CarbonImmutable subRealMonths(int $value = 1) Sub months (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealMonth() Sub one month to the instance (using timestamp).
+ * @method CarbonPeriod monthsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each month or every X months if a factor is given.
+ * @method CarbonImmutable addRealQuarters(int $value = 1) Add quarters (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealQuarter() Add one quarter to the instance (using timestamp).
+ * @method CarbonImmutable subRealQuarters(int $value = 1) Sub quarters (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealQuarter() Sub one quarter to the instance (using timestamp).
+ * @method CarbonPeriod quartersUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each quarter or every X quarters if a factor is given.
+ * @method CarbonImmutable addRealYears(int $value = 1) Add years (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealYear() Add one year to the instance (using timestamp).
+ * @method CarbonImmutable subRealYears(int $value = 1) Sub years (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealYear() Sub one year to the instance (using timestamp).
+ * @method CarbonPeriod yearsUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each year or every X years if a factor is given.
+ * @method CarbonImmutable addRealDecades(int $value = 1) Add decades (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealDecade() Add one decade to the instance (using timestamp).
+ * @method CarbonImmutable subRealDecades(int $value = 1) Sub decades (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealDecade() Sub one decade to the instance (using timestamp).
+ * @method CarbonPeriod decadesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each decade or every X decades if a factor is given.
+ * @method CarbonImmutable addRealCenturies(int $value = 1) Add centuries (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealCentury() Add one century to the instance (using timestamp).
+ * @method CarbonImmutable subRealCenturies(int $value = 1) Sub centuries (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealCentury() Sub one century to the instance (using timestamp).
+ * @method CarbonPeriod centuriesUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each century or every X centuries if a factor is given.
+ * @method CarbonImmutable addRealMillennia(int $value = 1) Add millennia (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable addRealMillennium() Add one millennium to the instance (using timestamp).
+ * @method CarbonImmutable subRealMillennia(int $value = 1) Sub millennia (the $value count passed in) to the instance (using timestamp).
+ * @method CarbonImmutable subRealMillennium() Sub one millennium to the instance (using timestamp).
+ * @method CarbonPeriod millenniaUntil($endDate = null, int $factor = 1) Return an iterable period from current date to given end (string, DateTime or Carbon instance) for each millennium or every X millennia if a factor is given.
+ * @method CarbonImmutable roundYear(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
+ * @method CarbonImmutable roundYears(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
+ * @method CarbonImmutable floorYear(float $precision = 1) Truncate the current instance year with given precision.
+ * @method CarbonImmutable floorYears(float $precision = 1) Truncate the current instance year with given precision.
+ * @method CarbonImmutable ceilYear(float $precision = 1) Ceil the current instance year with given precision.
+ * @method CarbonImmutable ceilYears(float $precision = 1) Ceil the current instance year with given precision.
+ * @method CarbonImmutable roundMonth(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
+ * @method CarbonImmutable roundMonths(float $precision = 1, string $function = "round") Round the current instance month with given precision using the given function.
+ * @method CarbonImmutable floorMonth(float $precision = 1) Truncate the current instance month with given precision.
+ * @method CarbonImmutable floorMonths(float $precision = 1) Truncate the current instance month with given precision.
+ * @method CarbonImmutable ceilMonth(float $precision = 1) Ceil the current instance month with given precision.
+ * @method CarbonImmutable ceilMonths(float $precision = 1) Ceil the current instance month with given precision.
+ * @method CarbonImmutable roundDay(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
+ * @method CarbonImmutable roundDays(float $precision = 1, string $function = "round") Round the current instance day with given precision using the given function.
+ * @method CarbonImmutable floorDay(float $precision = 1) Truncate the current instance day with given precision.
+ * @method CarbonImmutable floorDays(float $precision = 1) Truncate the current instance day with given precision.
+ * @method CarbonImmutable ceilDay(float $precision = 1) Ceil the current instance day with given precision.
+ * @method CarbonImmutable ceilDays(float $precision = 1) Ceil the current instance day with given precision.
+ * @method CarbonImmutable roundHour(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
+ * @method CarbonImmutable roundHours(float $precision = 1, string $function = "round") Round the current instance hour with given precision using the given function.
+ * @method CarbonImmutable floorHour(float $precision = 1) Truncate the current instance hour with given precision.
+ * @method CarbonImmutable floorHours(float $precision = 1) Truncate the current instance hour with given precision.
+ * @method CarbonImmutable ceilHour(float $precision = 1) Ceil the current instance hour with given precision.
+ * @method CarbonImmutable ceilHours(float $precision = 1) Ceil the current instance hour with given precision.
+ * @method CarbonImmutable roundMinute(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
+ * @method CarbonImmutable roundMinutes(float $precision = 1, string $function = "round") Round the current instance minute with given precision using the given function.
+ * @method CarbonImmutable floorMinute(float $precision = 1) Truncate the current instance minute with given precision.
+ * @method CarbonImmutable floorMinutes(float $precision = 1) Truncate the current instance minute with given precision.
+ * @method CarbonImmutable ceilMinute(float $precision = 1) Ceil the current instance minute with given precision.
+ * @method CarbonImmutable ceilMinutes(float $precision = 1) Ceil the current instance minute with given precision.
+ * @method CarbonImmutable roundSecond(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
+ * @method CarbonImmutable roundSeconds(float $precision = 1, string $function = "round") Round the current instance second with given precision using the given function.
+ * @method CarbonImmutable floorSecond(float $precision = 1) Truncate the current instance second with given precision.
+ * @method CarbonImmutable floorSeconds(float $precision = 1) Truncate the current instance second with given precision.
+ * @method CarbonImmutable ceilSecond(float $precision = 1) Ceil the current instance second with given precision.
+ * @method CarbonImmutable ceilSeconds(float $precision = 1) Ceil the current instance second with given precision.
+ * @method CarbonImmutable roundMillennium(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
+ * @method CarbonImmutable roundMillennia(float $precision = 1, string $function = "round") Round the current instance millennium with given precision using the given function.
+ * @method CarbonImmutable floorMillennium(float $precision = 1) Truncate the current instance millennium with given precision.
+ * @method CarbonImmutable floorMillennia(float $precision = 1) Truncate the current instance millennium with given precision.
+ * @method CarbonImmutable ceilMillennium(float $precision = 1) Ceil the current instance millennium with given precision.
+ * @method CarbonImmutable ceilMillennia(float $precision = 1) Ceil the current instance millennium with given precision.
+ * @method CarbonImmutable roundCentury(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
+ * @method CarbonImmutable roundCenturies(float $precision = 1, string $function = "round") Round the current instance century with given precision using the given function.
+ * @method CarbonImmutable floorCentury(float $precision = 1) Truncate the current instance century with given precision.
+ * @method CarbonImmutable floorCenturies(float $precision = 1) Truncate the current instance century with given precision.
+ * @method CarbonImmutable ceilCentury(float $precision = 1) Ceil the current instance century with given precision.
+ * @method CarbonImmutable ceilCenturies(float $precision = 1) Ceil the current instance century with given precision.
+ * @method CarbonImmutable roundDecade(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
+ * @method CarbonImmutable roundDecades(float $precision = 1, string $function = "round") Round the current instance decade with given precision using the given function.
+ * @method CarbonImmutable floorDecade(float $precision = 1) Truncate the current instance decade with given precision.
+ * @method CarbonImmutable floorDecades(float $precision = 1) Truncate the current instance decade with given precision.
+ * @method CarbonImmutable ceilDecade(float $precision = 1) Ceil the current instance decade with given precision.
+ * @method CarbonImmutable ceilDecades(float $precision = 1) Ceil the current instance decade with given precision.
+ * @method CarbonImmutable roundQuarter(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
+ * @method CarbonImmutable roundQuarters(float $precision = 1, string $function = "round") Round the current instance quarter with given precision using the given function.
+ * @method CarbonImmutable floorQuarter(float $precision = 1) Truncate the current instance quarter with given precision.
+ * @method CarbonImmutable floorQuarters(float $precision = 1) Truncate the current instance quarter with given precision.
+ * @method CarbonImmutable ceilQuarter(float $precision = 1) Ceil the current instance quarter with given precision.
+ * @method CarbonImmutable ceilQuarters(float $precision = 1) Ceil the current instance quarter with given precision.
+ * @method CarbonImmutable roundMillisecond(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
+ * @method CarbonImmutable roundMilliseconds(float $precision = 1, string $function = "round") Round the current instance millisecond with given precision using the given function.
+ * @method CarbonImmutable floorMillisecond(float $precision = 1) Truncate the current instance millisecond with given precision.
+ * @method CarbonImmutable floorMilliseconds(float $precision = 1) Truncate the current instance millisecond with given precision.
+ * @method CarbonImmutable ceilMillisecond(float $precision = 1) Ceil the current instance millisecond with given precision.
+ * @method CarbonImmutable ceilMilliseconds(float $precision = 1) Ceil the current instance millisecond with given precision.
+ * @method CarbonImmutable roundMicrosecond(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
+ * @method CarbonImmutable roundMicroseconds(float $precision = 1, string $function = "round") Round the current instance microsecond with given precision using the given function.
+ * @method CarbonImmutable floorMicrosecond(float $precision = 1) Truncate the current instance microsecond with given precision.
+ * @method CarbonImmutable floorMicroseconds(float $precision = 1) Truncate the current instance microsecond with given precision.
+ * @method CarbonImmutable ceilMicrosecond(float $precision = 1) Ceil the current instance microsecond with given precision.
+ * @method CarbonImmutable ceilMicroseconds(float $precision = 1) Ceil the current instance microsecond with given precision.
+ * @method string shortAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longAbsoluteDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Absolute' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string shortRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longRelativeDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'Relative' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string shortRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longRelativeToNowDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToNow' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string shortRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (short format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method string longRelativeToOtherDiffForHumans(DateTimeInterface $other = null, int $parts = 1) Get the difference (long format, 'RelativeToOther' mode) in a human readable format in the current locale. ($other and $parts parameters can be swapped.)
+ * @method static static|false createFromFormat(string $format, string $time, DateTimeZone|string|false|null $timezone = null) Parse a string into a new CarbonImmutable object according to the specified format.
+ * @method static static __set_state(array $array) https://php.net/manual/en/datetime.set-state.php
*
* </autodoc>
*/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php
index 15e2061..b90e298 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterface.php
@@ -586,6 +586,7 @@
public const YEARS_PER_DECADE = 10;
public const MONTHS_PER_YEAR = 12;
public const MONTHS_PER_QUARTER = 3;
+ public const QUARTERS_PER_YEAR = 4;
public const WEEKS_PER_YEAR = 52;
public const WEEKS_PER_MONTH = 4;
public const DAYS_PER_YEAR = 365;
@@ -726,6 +727,8 @@
/**
* Returns the list of properties to dump on serialize() called on.
*
+ * Only used by PHP < 7.4.
+ *
* @return array
*/
public function __sleep();
@@ -735,7 +738,7 @@
*
* @example
* ```
- * echo Carbon::now(); // Carbon instances can be casted to string
+ * echo Carbon::now(); // Carbon instances can be cast to string
* ```
*
* @return string
@@ -987,7 +990,7 @@
*
* @param string $modifier
*
- * @return static
+ * @return static|false
*/
public function change($modifier);
@@ -1038,13 +1041,13 @@
* If $hour is not null then the default values for $minute and $second
* will be 0.
*
- * @param int|null $year
- * @param int|null $month
- * @param int|null $day
- * @param int|null $hour
- * @param int|null $minute
- * @param int|null $second
- * @param DateTimeZone|string|null $tz
+ * @param DateTimeInterface|int|null $year
+ * @param int|null $month
+ * @param int|null $day
+ * @param int|null $hour
+ * @param int|null $minute
+ * @param int|null $second
+ * @param DateTimeZone|string|null $tz
*
* @throws InvalidFormatException
*
@@ -1276,7 +1279,7 @@
*
* @return CarbonInterval
*/
- public function diffAsCarbonInterval($date = null, $absolute = true);
+ public function diffAsCarbonInterval($date = null, $absolute = true, array $skip = []);
/**
* Get the difference by the given interval using a filter closure.
@@ -2117,6 +2120,18 @@
public static function getDays();
/**
+ * Return the number of days since the start of the week (using the current locale or the first parameter
+ * if explicitly given).
+ *
+ * @param int|null $weekStartsAt optional start allow you to specify the day of week to use to start the week,
+ * if not provided, start of week is inferred from the locale
+ * (Sunday for en_US, Monday for de_DE, etc.)
+ *
+ * @return int
+ */
+ public function getDaysFromStartOfWeek(?int $weekStartsAt = null): int;
+
+ /**
* Get the fallback locale.
*
* @see https://symfony.com/doc/current/components/translation.html#fallback-locales
@@ -2738,12 +2753,35 @@
public function isLeapYear();
/**
- * Determines if the instance is a long year
+ * Determines if the instance is a long year (using ISO 8601 year).
*
* @example
* ```
- * Carbon::parse('2015-01-01')->isLongYear(); // true
- * Carbon::parse('2016-01-01')->isLongYear(); // false
+ * Carbon::parse('2015-01-01')->isLongIsoYear(); // true
+ * Carbon::parse('2016-01-01')->isLongIsoYear(); // true
+ * Carbon::parse('2016-01-03')->isLongIsoYear(); // false
+ * Carbon::parse('2019-12-29')->isLongIsoYear(); // false
+ * Carbon::parse('2019-12-30')->isLongIsoYear(); // true
+ * ```
+ *
+ * @see https://en.wikipedia.org/wiki/ISO_8601#Week_dates
+ *
+ * @return bool
+ */
+ public function isLongIsoYear();
+
+ /**
+ * Determines if the instance is a long year (using calendar year).
+ *
+ * ⚠️ This method completely ignores month and day to use the numeric year number,
+ * it's not correct if the exact date matters. For instance as `2019-12-30` is already
+ * in the first week of the 2020 year, if you want to know from this date if ISO week
+ * year 2020 is a long year, use `isLongIsoYear` instead.
+ *
+ * @example
+ * ```
+ * Carbon::create(2015)->isLongYear(); // true
+ * Carbon::create(2016)->isLongYear(); // false
* ```
*
* @see https://en.wikipedia.org/wiki/ISO_8601#Week_dates
@@ -3382,7 +3420,7 @@
*
* @param string|int|null $modifier
*
- * @return static
+ * @return static|false
*/
public function next($modifier = null);
@@ -3528,7 +3566,7 @@
*
* @param string|int|null $modifier
*
- * @return static
+ * @return static|false
*/
public function previous($modifier = null);
@@ -3774,6 +3812,19 @@
public function setDateTimeFrom($date = null);
/**
+ * Set the day (keeping the current time) to the start of the week + the number of days passed as the first
+ * parameter. First day of week is driven by the locale unless explicitly set with the second parameter.
+ *
+ * @param int $numberOfDays number of days to add after the start of the current week
+ * @param int|null $weekStartsAt optional start allow you to specify the day of week to use to start the week,
+ * if not provided, start of week is inferred from the locale
+ * (Sunday for en_US, Monday for de_DE, etc.)
+ *
+ * @return static
+ */
+ public function setDaysFromStartOfWeek(int $numberOfDays, ?int $weekStartsAt = null);
+
+ /**
* Set the fallback locale.
*
* @see https://symfony.com/doc/current/components/translation.html#fallback-locales
@@ -3860,7 +3911,7 @@
*
* /!\ Use this method for unit tests only.
*
- * @param Closure|static|string|false|null $testNow real or mock Carbon instance
+ * @param DateTimeInterface|Closure|static|string|false|null $testNow real or mock Carbon instance
*/
public static function setTestNow($testNow = null);
@@ -3881,7 +3932,7 @@
*
* /!\ Use this method for unit tests only.
*
- * @param Closure|static|string|false|null $testNow real or mock Carbon instance
+ * @param DateTimeInterface|Closure|static|string|false|null $testNow real or mock Carbon instance
*/
public static function setTestNowAndTimezone($testNow = null, $tz = null);
@@ -3942,11 +3993,11 @@
/**
* @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
- * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and
- * use other method or custom format passed to format() method if you need to dump an other string
+ * You should rather let Carbon object being cast to string with DEFAULT_TO_STRING_FORMAT, and
+ * use other method or custom format passed to format() method if you need to dump another string
* format.
*
- * Set the default format used when type juggling a Carbon instance to a string
+ * Set the default format used when type juggling a Carbon instance to a string.
*
* @param string|Closure|null $format
*
@@ -4538,6 +4589,18 @@
public function toFormattedDateString();
/**
+ * Format the instance with the day, and a readable date
+ *
+ * @example
+ * ```
+ * echo Carbon::now()->toFormattedDayDateString();
+ * ```
+ *
+ * @return string
+ */
+ public function toFormattedDayDateString(): string;
+
+ /**
* Return the ISO-8601 string (ex: 1977-04-22T06:00:00Z, if $keepOffset truthy, offset will be kept:
* 1977-04-22T01:00:00-05:00).
*
@@ -5057,12 +5120,14 @@
*
* /!\ Use this method for unit tests only.
*
- * @param Closure|static|string|false|null $testNow real or mock Carbon instance
- * @param Closure|null $callback
+ * @template T
*
- * @return mixed
+ * @param DateTimeInterface|Closure|static|string|false|null $testNow real or mock Carbon instance
+ * @param Closure(): T $callback
+ *
+ * @return T
*/
- public static function withTestNow($testNow = null, $callback = null);
+ public static function withTestNow($testNow, $callback);
/**
* Create a Carbon instance for yesterday.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php
index d465bea..8437c54 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php
@@ -15,6 +15,7 @@
use Carbon\Exceptions\BadFluentSetterException;
use Carbon\Exceptions\InvalidCastException;
use Carbon\Exceptions\InvalidIntervalException;
+use Carbon\Exceptions\OutOfRangeException;
use Carbon\Exceptions\ParseErrorException;
use Carbon\Exceptions\UnitNotConfiguredException;
use Carbon\Exceptions\UnknownGetterException;
@@ -22,15 +23,20 @@
use Carbon\Exceptions\UnknownUnitException;
use Carbon\Traits\IntervalRounding;
use Carbon\Traits\IntervalStep;
+use Carbon\Traits\MagicParameter;
use Carbon\Traits\Mixin;
use Carbon\Traits\Options;
+use Carbon\Traits\ToStringFormat;
use Closure;
use DateInterval;
+use DateMalformedIntervalStringException;
use DateTimeInterface;
use DateTimeZone;
use Exception;
+use InvalidArgumentException;
use ReflectionException;
use ReturnTypeWillChange;
+use RuntimeException;
use Throwable;
/**
@@ -46,7 +52,7 @@
* @property int $minutes Total minutes of the current interval.
* @property int $seconds Total seconds of the current interval.
* @property int $microseconds Total microseconds of the current interval.
- * @property int $milliseconds Total microseconds of the current interval.
+ * @property int $milliseconds Total milliseconds of the current interval.
* @property int $microExcludeMilli Remaining microseconds without the milliseconds.
* @property int $dayzExcludeWeeks Total days remaining in the final week of the current instance (days % 7).
* @property int $daysExcludeWeeks alias of dayzExcludeWeeks
@@ -184,10 +190,12 @@
{
use IntervalRounding;
use IntervalStep;
+ use MagicParameter;
use Mixin {
Mixin::mixin as baseMixin;
}
use Options;
+ use ToStringFormat;
/**
* Interval spec period designators
@@ -242,6 +250,11 @@
private static $flipCascadeFactors;
/**
+ * @var bool
+ */
+ private static $floatSettersEnabled = false;
+
+ /**
* The registered macros.
*
* @var array
@@ -294,7 +307,12 @@
*/
public static function getCascadeFactors()
{
- return static::$cascadeFactors ?: [
+ return static::$cascadeFactors ?: static::getDefaultCascadeFactors();
+ }
+
+ protected static function getDefaultCascadeFactors(): array
+ {
+ return [
'milliseconds' => [Carbon::MICROSECONDS_PER_MILLISECOND, 'microseconds'],
'seconds' => [Carbon::MILLISECONDS_PER_SECOND, 'milliseconds'],
'minutes' => [Carbon::SECONDS_PER_MINUTE, 'seconds'],
@@ -337,6 +355,19 @@
static::$cascadeFactors = $cascadeFactors;
}
+ /**
+ * This option allow you to opt-in for the Carbon 3 behavior where float
+ * values will no longer be cast to integer (so truncated).
+ *
+ * ⚠️ This settings will be applied globally, which mean your whole application
+ * code including the third-party dependencies that also may use Carbon will
+ * adopt the new behavior.
+ */
+ public static function enableFloatSetters(bool $floatSettersEnabled = true): void
+ {
+ self::$floatSettersEnabled = $floatSettersEnabled;
+ }
+
///////////////////////////////////////////////////////////////////
//////////////////////////// CONSTRUCTORS /////////////////////////
///////////////////////////////////////////////////////////////////
@@ -344,14 +375,14 @@
/**
* Create a new CarbonInterval instance.
*
- * @param int|null $years
- * @param int|null $months
- * @param int|null $weeks
- * @param int|null $days
- * @param int|null $hours
- * @param int|null $minutes
- * @param int|null $seconds
- * @param int|null $microseconds
+ * @param Closure|DateInterval|string|int|null $years
+ * @param int|float|null $months
+ * @param int|float|null $weeks
+ * @param int|float|null $days
+ * @param int|float|null $hours
+ * @param int|float|null $minutes
+ * @param int|float|null $seconds
+ * @param int|float|null $microseconds
*
* @throws Exception when the interval_spec (passed as $years) cannot be parsed as an interval.
*/
@@ -371,8 +402,9 @@
}
$spec = $years;
+ $isStringSpec = (\is_string($spec) && !preg_match('/^[\d.]/', $spec));
- if (!\is_string($spec) || (float) $years || preg_match('/^[0-9.]/', $years)) {
+ if (!$isStringSpec || (float) $years) {
$spec = static::PERIOD_PREFIX;
$spec .= $years > 0 ? $years.static::PERIOD_YEARS : '';
@@ -397,7 +429,74 @@
}
}
- parent::__construct($spec);
+ try {
+ parent::__construct($spec);
+ } catch (Throwable $exception) {
+ try {
+ parent::__construct('PT0S');
+
+ if ($isStringSpec) {
+ if (!preg_match('/^P
+ (?:(?<year>[+-]?\d*(?:\.\d+)?)Y)?
+ (?:(?<month>[+-]?\d*(?:\.\d+)?)M)?
+ (?:(?<week>[+-]?\d*(?:\.\d+)?)W)?
+ (?:(?<day>[+-]?\d*(?:\.\d+)?)D)?
+ (?:T
+ (?:(?<hour>[+-]?\d*(?:\.\d+)?)H)?
+ (?:(?<minute>[+-]?\d*(?:\.\d+)?)M)?
+ (?:(?<second>[+-]?\d*(?:\.\d+)?)S)?
+ )?
+ $/x', $spec, $match)) {
+ throw new InvalidArgumentException("Invalid duration: $spec");
+ }
+
+ $years = (float) ($match['year'] ?? 0);
+ $this->assertSafeForInteger('year', $years);
+ $months = (float) ($match['month'] ?? 0);
+ $this->assertSafeForInteger('month', $months);
+ $weeks = (float) ($match['week'] ?? 0);
+ $this->assertSafeForInteger('week', $weeks);
+ $days = (float) ($match['day'] ?? 0);
+ $this->assertSafeForInteger('day', $days);
+ $hours = (float) ($match['hour'] ?? 0);
+ $this->assertSafeForInteger('hour', $hours);
+ $minutes = (float) ($match['minute'] ?? 0);
+ $this->assertSafeForInteger('minute', $minutes);
+ $seconds = (float) ($match['second'] ?? 0);
+ $this->assertSafeForInteger('second', $seconds);
+ }
+
+ $totalDays = (($weeks * static::getDaysPerWeek()) + $days);
+ $this->assertSafeForInteger('days total (including weeks)', $totalDays);
+
+ $this->y = (int) $years;
+ $this->m = (int) $months;
+ $this->d = (int) $totalDays;
+ $this->h = (int) $hours;
+ $this->i = (int) $minutes;
+ $this->s = (int) $seconds;
+
+ if (
+ ((float) $this->y) !== $years ||
+ ((float) $this->m) !== $months ||
+ ((float) $this->d) !== $totalDays ||
+ ((float) $this->h) !== $hours ||
+ ((float) $this->i) !== $minutes ||
+ ((float) $this->s) !== $seconds
+ ) {
+ $this->add(static::fromString(
+ ($years - $this->y).' years '.
+ ($months - $this->m).' months '.
+ ($totalDays - $this->d).' days '.
+ ($hours - $this->h).' hours '.
+ ($minutes - $this->i).' minutes '.
+ ($seconds - $this->s).' seconds '
+ ));
+ }
+ } catch (Throwable $secondException) {
+ throw $secondException instanceof OutOfRangeException ? $secondException : $exception;
+ }
+ }
if ($microseconds !== null) {
$this->f = $microseconds / Carbon::MICROSECONDS_PER_SECOND;
@@ -410,7 +509,7 @@
* @param string $source
* @param string $target
*
- * @return int|null
+ * @return int|float|null
*/
public static function getFactor($source, $target)
{
@@ -438,7 +537,7 @@
* @param string $source
* @param string $target
*
- * @return int|null
+ * @return int|float|null
*/
public static function getFactorWithDefault($source, $target)
{
@@ -465,7 +564,7 @@
/**
* Returns current config for days per week.
*
- * @return int
+ * @return int|float
*/
public static function getDaysPerWeek()
{
@@ -475,7 +574,7 @@
/**
* Returns current config for hours per day.
*
- * @return int
+ * @return int|float
*/
public static function getHoursPerDay()
{
@@ -485,7 +584,7 @@
/**
* Returns current config for minutes per hour.
*
- * @return int
+ * @return int|float
*/
public static function getMinutesPerHour()
{
@@ -495,7 +594,7 @@
/**
* Returns current config for seconds per minute.
*
- * @return int
+ * @return int|float
*/
public static function getSecondsPerMinute()
{
@@ -505,7 +604,7 @@
/**
* Returns current config for microseconds per second.
*
- * @return int
+ * @return int|float
*/
public static function getMillisecondsPerSecond()
{
@@ -515,7 +614,7 @@
/**
* Returns current config for microseconds per second.
*
- * @return int
+ * @return int|float
*/
public static function getMicrosecondsPerMillisecond()
{
@@ -674,6 +773,23 @@
}
/**
+ * Evaluate the PHP generated by var_export() and recreate the exported CarbonInterval instance.
+ *
+ * @param array $dump data as exported by var_export()
+ *
+ * @return static
+ */
+ #[ReturnTypeWillChange]
+ public static function __set_state($dump)
+ {
+ /** @noinspection PhpVoidFunctionResultUsedInspection */
+ /** @var DateInterval $dateInterval */
+ $dateInterval = parent::__set_state($dump);
+
+ return static::instance($dateInterval);
+ }
+
+ /**
* Return the current context from inside a macro callee or a new one if static.
*
* @return static
@@ -767,6 +883,8 @@
case 'year':
case 'years':
case 'y':
+ case 'yr':
+ case 'yrs':
$years += $intValue;
break;
@@ -780,6 +898,7 @@
case 'month':
case 'months':
case 'mo':
+ case 'mos':
$months += $intValue;
break;
@@ -882,7 +1001,7 @@
return static::fromString(Carbon::translateTimeString($interval, $locale ?: static::getLocale(), 'en'));
}
- private static function castIntervalToClass(DateInterval $interval, string $className)
+ private static function castIntervalToClass(DateInterval $interval, string $className, array $skip = [])
{
$mainClass = DateInterval::class;
@@ -891,7 +1010,7 @@
}
$microseconds = $interval->f;
- $instance = new $className(static::getDateIntervalSpec($interval));
+ $instance = new $className(static::getDateIntervalSpec($interval, false, $skip));
if ($microseconds) {
$instance->f = $microseconds;
@@ -940,12 +1059,19 @@
* set the $days field.
*
* @param DateInterval $interval
+ * @param bool $skipCopy set to true to return the passed object
+ * (without copying it) if it's already of the
+ * current class
*
* @return static
*/
- public static function instance(DateInterval $interval)
+ public static function instance(DateInterval $interval, array $skip = [], bool $skipCopy = false)
{
- return self::castIntervalToClass($interval, static::class);
+ if ($skipCopy && $interval instanceof static) {
+ return $interval;
+ }
+
+ return self::castIntervalToClass($interval, static::class, $skip);
}
/**
@@ -956,17 +1082,20 @@
*
* @param mixed|int|DateInterval|string|Closure|null $interval interval or number of the given $unit
* @param string|null $unit if specified, $interval must be an integer
+ * @param bool $skipCopy set to true to return the passed object
+ * (without copying it) if it's already of the
+ * current class
*
* @return static|null
*/
- public static function make($interval, $unit = null)
+ public static function make($interval, $unit = null, bool $skipCopy = false)
{
if ($unit) {
$interval = "$interval ".Carbon::pluralUnit($unit);
}
if ($interval instanceof DateInterval) {
- return static::instance($interval);
+ return static::instance($interval, [], $skipCopy);
}
if ($interval instanceof Closure) {
@@ -984,7 +1113,7 @@
{
$interval = preg_replace('/\s+/', ' ', trim($interval));
- if (preg_match('/^P[T0-9]/', $interval)) {
+ if (preg_match('/^P[T\d]/', $interval)) {
return new static($interval);
}
@@ -992,8 +1121,14 @@
return static::fromString($interval);
}
- /** @var static $interval */
- $interval = static::createFromDateString($interval);
+ // @codeCoverageIgnoreStart
+ try {
+ /** @var static $interval */
+ $interval = static::createFromDateString($interval);
+ } catch (DateMalformedIntervalStringException $e) {
+ return null;
+ }
+ // @codeCoverageIgnoreEnd
return !$interval || $interval->isEmpty() ? null : $interval;
}
@@ -1081,11 +1216,11 @@
return (int) round($this->f * Carbon::MICROSECONDS_PER_SECOND) % Carbon::MICROSECONDS_PER_MILLISECOND;
case 'weeks':
- return (int) ($this->d / static::getDaysPerWeek());
+ return (int) ($this->d / (int) static::getDaysPerWeek());
case 'daysExcludeWeeks':
case 'dayzExcludeWeeks':
- return $this->d % static::getDaysPerWeek();
+ return $this->d % (int) static::getDaysPerWeek();
case 'locale':
return $this->getTranslatorLocale();
@@ -1126,43 +1261,63 @@
foreach ($properties as $key => $value) {
switch (Carbon::singularUnit(rtrim($key, 'z'))) {
case 'year':
+ $this->checkIntegerValue($key, $value);
$this->y = $value;
+ $this->handleDecimalPart('year', $value, $this->y);
break;
case 'month':
+ $this->checkIntegerValue($key, $value);
$this->m = $value;
+ $this->handleDecimalPart('month', $value, $this->m);
break;
case 'week':
- $this->d = $value * static::getDaysPerWeek();
+ $this->checkIntegerValue($key, $value);
+ $days = $value * (int) static::getDaysPerWeek();
+ $this->assertSafeForInteger('days total (including weeks)', $days);
+ $this->d = $days;
+ $this->handleDecimalPart('day', $days, $this->d);
break;
case 'day':
+ $this->checkIntegerValue($key, $value);
$this->d = $value;
+ $this->handleDecimalPart('day', $value, $this->d);
break;
case 'daysexcludeweek':
case 'dayzexcludeweek':
- $this->d = $this->weeks * static::getDaysPerWeek() + $value;
+ $this->checkIntegerValue($key, $value);
+ $days = $this->weeks * (int) static::getDaysPerWeek() + $value;
+ $this->assertSafeForInteger('days total (including weeks)', $days);
+ $this->d = $days;
+ $this->handleDecimalPart('day', $days, $this->d);
break;
case 'hour':
+ $this->checkIntegerValue($key, $value);
$this->h = $value;
+ $this->handleDecimalPart('hour', $value, $this->h);
break;
case 'minute':
+ $this->checkIntegerValue($key, $value);
$this->i = $value;
+ $this->handleDecimalPart('minute', $value, $this->i);
break;
case 'second':
+ $this->checkIntegerValue($key, $value);
$this->s = $value;
+ $this->handleDecimalPart('second', $value, $this->s);
break;
@@ -1355,11 +1510,15 @@
}
if (preg_match('/^(?<method>add|sub)(?<unit>[A-Z].*)$/', $method, $match)) {
- return $this->{$match['method']}($parameters[0], $match['unit']);
+ $value = $this->getMagicParameter($parameters, 0, Carbon::pluralUnit($match['unit']), 0);
+
+ return $this->{$match['method']}($value, $match['unit']);
}
+ $value = $this->getMagicParameter($parameters, 0, Carbon::pluralUnit($method), 1);
+
try {
- $this->set($method, \count($parameters) === 0 ? 1 : $parameters[0]);
+ $this->set($method, $value);
} catch (UnknownSetterException $exception) {
if ($this->localStrictModeEnabled ?? Carbon::isStrictModeEnabled()) {
throw new BadFluentSetterException($method, 0, $exception);
@@ -1410,9 +1569,9 @@
$minimumUnit = 's';
$skip = [];
extract($this->getForHumansInitialVariables($syntax, $short));
- $skip = array_filter((array) $skip, static function ($value) {
+ $skip = array_map('strtolower', array_filter((array) $skip, static function ($value) {
return \is_string($value) && $value !== '';
- });
+ }));
if ($syntax === null) {
$syntax = CarbonInterface::DIFF_ABSOLUTE;
@@ -1435,11 +1594,9 @@
];
}
- if ($altNumbers) {
- if ($altNumbers !== true) {
- $language = new Language($this->locale);
- $altNumbers = \in_array($language->getCode(), (array) $altNumbers);
- }
+ if ($altNumbers && $altNumbers !== true) {
+ $language = new Language($this->locale);
+ $altNumbers = \in_array($language->getCode(), (array) $altNumbers, true);
}
if (\is_array($join)) {
@@ -1620,18 +1777,23 @@
$unit = $short ? 's' : 'second';
$isFuture = $this->invert === 1;
$transId = $relativeToNow ? ($isFuture ? 'from_now' : 'ago') : ($isFuture ? 'after' : 'before');
+ $declensionMode = null;
/** @var \Symfony\Component\Translation\Translator $translator */
$translator = $this->getLocalTranslator();
- $handleDeclensions = function ($unit, $count) use ($interpolations, $transId, $translator, $altNumbers, $absolute) {
+ $handleDeclensions = function ($unit, $count, $index = 0, $parts = 1) use ($interpolations, $transId, $translator, $altNumbers, $absolute, &$declensionMode) {
if (!$absolute) {
- // Some languages have special pluralization for past and future tense.
- $key = $unit.'_'.$transId;
- $result = $this->translate($key, $interpolations, $count, $translator, $altNumbers);
+ $declensionMode = $declensionMode ?? $this->translate($transId.'_mode');
- if ($result !== $key) {
- return $result;
+ if ($this->needsDeclension($declensionMode, $index, $parts)) {
+ // Some languages have special pluralization for past and future tense.
+ $key = $unit.'_'.$transId;
+ $result = $this->translate($key, $interpolations, $count, $translator, $altNumbers);
+
+ if ($result !== $key) {
+ return $result;
+ }
}
}
@@ -1696,17 +1858,17 @@
}
}
- $transChoice = function ($short, $unitData) use ($absolute, $handleDeclensions, $translator, $aUnit, $altNumbers, $interpolations) {
+ $transChoice = function ($short, $unitData, $index, $parts) use ($absolute, $handleDeclensions, $translator, $aUnit, $altNumbers, $interpolations) {
$count = $unitData['value'];
if ($short) {
- $result = $handleDeclensions($unitData['unitShort'], $count);
+ $result = $handleDeclensions($unitData['unitShort'], $count, $index, $parts);
if ($result !== null) {
return $result;
}
} elseif ($aUnit) {
- $result = $handleDeclensions('a_'.$unitData['unit'], $count);
+ $result = $handleDeclensions('a_'.$unitData['unit'], $count, $index, $parts);
if ($result !== null) {
return $result;
@@ -1714,7 +1876,7 @@
}
if (!$absolute) {
- return $handleDeclensions($unitData['unit'], $count);
+ return $handleDeclensions($unitData['unit'], $count, $index, $parts);
}
return $this->translate($unitData['unit'], $interpolations, $count, $translator, $altNumbers);
@@ -1726,7 +1888,7 @@
if ($diffIntervalData['value'] > 0) {
$unit = $short ? $diffIntervalData['unitShort'] : $diffIntervalData['unit'];
$count = $diffIntervalData['value'];
- $interval[] = $transChoice($short, $diffIntervalData);
+ $interval[] = [$short, $diffIntervalData];
} elseif ($options & CarbonInterface::SEQUENTIAL_PARTS_ONLY && \count($interval) > 0) {
break;
}
@@ -1737,13 +1899,19 @@
}
// break the loop after we have reached the minimum unit
- if (\in_array($minimumUnit, [$diffIntervalData['unit'], $diffIntervalData['unitShort']])) {
+ if (\in_array($minimumUnit, [$diffIntervalData['unit'], $diffIntervalData['unitShort']], true)) {
$fallbackUnit = [$diffIntervalData['unit'], $diffIntervalData['unitShort']];
break;
}
}
+ $actualParts = \count($interval);
+
+ foreach ($interval as $index => &$item) {
+ $item = $transChoice($item[0], $item[1], $index, $actualParts);
+ }
+
if (\count($interval) === 0) {
if ($relativeToNow && $options & CarbonInterface::JUST_NOW) {
$key = 'diff_now';
@@ -1812,17 +1980,17 @@
*/
public function __toString()
{
- $format = $this->localToStringFormat;
+ $format = $this->localToStringFormat ?? static::$toStringFormat;
- if ($format) {
- if ($format instanceof Closure) {
- return $format($this);
- }
-
- return $this->format($format);
+ if (!$format) {
+ return $this->forHumans();
}
- return $this->forHumans();
+ if ($format instanceof Closure) {
+ return $format($this);
+ }
+
+ return $this->format($format);
}
/**
@@ -1863,7 +2031,7 @@
/**
* Invert the interval.
*
- * @param bool|int $inverted if a parameter is passed, the passed value casted as 1 or 0 is used
+ * @param bool|int $inverted if a parameter is passed, the passed value cast as 1 or 0 is used
* as the new value of the ->invert property.
*
* @return $this
@@ -2141,7 +2309,7 @@
*
* @return string
*/
- public static function getDateIntervalSpec(DateInterval $interval)
+ public static function getDateIntervalSpec(DateInterval $interval, bool $microseconds = false, array $skip = [])
{
$date = array_filter([
static::PERIOD_YEARS => abs($interval->y),
@@ -2149,10 +2317,25 @@
static::PERIOD_DAYS => abs($interval->d),
]);
+ if (
+ $interval->days >= CarbonInterface::DAYS_PER_WEEK * CarbonInterface::WEEKS_PER_MONTH &&
+ (!isset($date[static::PERIOD_YEARS]) || \count(array_intersect(['y', 'year', 'years'], $skip))) &&
+ (!isset($date[static::PERIOD_MONTHS]) || \count(array_intersect(['m', 'month', 'months'], $skip)))
+ ) {
+ $date = [
+ static::PERIOD_DAYS => abs($interval->days),
+ ];
+ }
+
+ $seconds = abs($interval->s);
+ if ($microseconds && $interval->f > 0) {
+ $seconds = sprintf('%d.%06d', $seconds, abs($interval->f) * 1000000);
+ }
+
$time = array_filter([
static::PERIOD_HOURS => abs($interval->h),
static::PERIOD_MINUTES => abs($interval->i),
- static::PERIOD_SECONDS => abs($interval->s),
+ static::PERIOD_SECONDS => $seconds,
]);
$specString = static::PERIOD_PREFIX;
@@ -2176,9 +2359,9 @@
*
* @return string
*/
- public function spec()
+ public function spec(bool $microseconds = false)
{
- return static::getDateIntervalSpec($this);
+ return static::getDateIntervalSpec($this, $microseconds);
}
/**
@@ -2229,9 +2412,11 @@
$originalData = $this->toArray();
$originalData['milliseconds'] = (int) ($originalData['microseconds'] / static::getMicrosecondsPerMillisecond());
$originalData['microseconds'] = $originalData['microseconds'] % static::getMicrosecondsPerMillisecond();
- $originalData['daysExcludeWeeks'] = $originalData['days'];
+ $originalData['weeks'] = (int) ($this->d / static::getDaysPerWeek());
+ $originalData['daysExcludeWeeks'] = fmod($this->d, static::getDaysPerWeek());
unset($originalData['days']);
$newData = $originalData;
+ $previous = [];
foreach (self::getFlipCascadeFactors() as $source => [$target, $factor]) {
foreach (['source', 'target'] as $key) {
@@ -2241,9 +2426,29 @@
}
$value = $newData[$source];
- $modulo = ($factor + ($value % $factor)) % $factor;
+ $modulo = fmod($factor + fmod($value, $factor), $factor);
$newData[$source] = $modulo;
$newData[$target] += ($value - $modulo) / $factor;
+
+ $decimalPart = fmod($newData[$source], 1);
+
+ if ($decimalPart !== 0.0) {
+ $unit = $source;
+
+ foreach ($previous as [$subUnit, $subFactor]) {
+ $newData[$unit] -= $decimalPart;
+ $newData[$subUnit] += $decimalPart * $subFactor;
+ $decimalPart = fmod($newData[$subUnit], 1);
+
+ if ($decimalPart === 0.0) {
+ break;
+ }
+
+ $unit = $subUnit;
+ }
+ }
+
+ array_unshift($previous, [$source, $factor]);
}
$positive = null;
@@ -2324,13 +2529,13 @@
$cumulativeFactor = 0;
$unitFound = false;
$factors = self::getFlipCascadeFactors();
- $daysPerWeek = static::getDaysPerWeek();
+ $daysPerWeek = (int) static::getDaysPerWeek();
$values = [
'years' => $this->years,
'months' => $this->months,
'weeks' => (int) ($this->d / $daysPerWeek),
- 'dayz' => $this->d % $daysPerWeek,
+ 'dayz' => fmod($this->d, $daysPerWeek),
'hours' => $this->hours,
'minutes' => $this->minutes,
'seconds' => $this->seconds,
@@ -2391,10 +2596,11 @@
}
if ($unit === 'weeks') {
- return $result / $daysPerWeek;
+ $result /= $daysPerWeek;
}
- return $result;
+ // Cast as int numbers with no decimal part
+ return fmod($result, 1) === 0.0 ? (int) $result : $result;
}
/**
@@ -2662,6 +2868,15 @@
*/
public function roundUnit($unit, $precision = 1, $function = 'round')
{
+ if (static::getCascadeFactors() !== static::getDefaultCascadeFactors()) {
+ $value = $function($this->total($unit) / $precision) * $precision;
+ $inverted = $value < 0;
+
+ return $this->copyProperties(self::fromString(
+ number_format(abs($value), 12, '.', '').' '.$unit
+ )->invert($inverted)->cascade());
+ }
+
$base = CarbonImmutable::parse('2000-01-01 00:00:00', 'UTC')
->roundUnit($unit, $precision, $function);
$next = $base->add($this);
@@ -2752,4 +2967,88 @@
{
return $this->round($precision, 'ceil');
}
+
+ private function needsDeclension(string $mode, int $index, int $parts): bool
+ {
+ switch ($mode) {
+ case 'last':
+ return $index === $parts - 1;
+ default:
+ return true;
+ }
+ }
+
+ private function checkIntegerValue(string $name, $value)
+ {
+ if (\is_int($value)) {
+ return;
+ }
+
+ $this->assertSafeForInteger($name, $value);
+
+ if (\is_float($value) && (((float) (int) $value) === $value)) {
+ return;
+ }
+
+ if (!self::$floatSettersEnabled) {
+ $type = \gettype($value);
+ @trigger_error(
+ "Since 2.70.0, it's deprecated to pass $type value for $name.\n".
+ "It's truncated when stored as an integer interval unit.\n".
+ "From 3.0.0, decimal part will no longer be truncated and will be cascaded to smaller units.\n".
+ "- To maintain the current behavior, use explicit cast: $name((int) \$value)\n".
+ "- To adopt the new behavior globally, call CarbonInterval::enableFloatSetters()\n",
+ \E_USER_DEPRECATED
+ );
+ }
+ }
+
+ /**
+ * Throw an exception if precision loss when storing the given value as an integer would be >= 1.0.
+ */
+ private function assertSafeForInteger(string $name, $value)
+ {
+ if ($value && !\is_int($value) && ($value >= 0x7fffffffffffffff || $value <= -0x7fffffffffffffff)) {
+ throw new OutOfRangeException($name, -0x7fffffffffffffff, 0x7fffffffffffffff, $value);
+ }
+ }
+
+ private function handleDecimalPart(string $unit, $value, $integerValue)
+ {
+ if (self::$floatSettersEnabled) {
+ $floatValue = (float) $value;
+ $base = (float) $integerValue;
+
+ if ($floatValue === $base) {
+ return;
+ }
+
+ $units = [
+ 'y' => 'year',
+ 'm' => 'month',
+ 'd' => 'day',
+ 'h' => 'hour',
+ 'i' => 'minute',
+ 's' => 'second',
+ ];
+ $upper = true;
+
+ foreach ($units as $property => $name) {
+ if ($name === $unit) {
+ $upper = false;
+
+ continue;
+ }
+
+ if (!$upper && $this->$property !== 0) {
+ throw new RuntimeException(
+ "You cannot set $unit to a float value as $name would be overridden, ".
+ 'set it first to 0 explicitly if you really want to erase its value'
+ );
+ }
+ }
+
+ $this->add($unit, $floatValue - $base);
+ }
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php
index 0e81e75..d12a986 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriod.php
@@ -11,6 +11,7 @@
namespace Carbon;
+use Carbon\Exceptions\EndLessPeriodException;
use Carbon\Exceptions\InvalidCastException;
use Carbon\Exceptions\InvalidIntervalException;
use Carbon\Exceptions\InvalidPeriodDateException;
@@ -23,11 +24,13 @@
use Carbon\Traits\IntervalRounding;
use Carbon\Traits\Mixin;
use Carbon\Traits\Options;
+use Carbon\Traits\ToStringFormat;
use Closure;
use Countable;
use DateInterval;
use DatePeriod;
use DateTime;
+use DateTimeImmutable;
use DateTimeInterface;
use DateTimeZone;
use InvalidArgumentException;
@@ -48,43 +51,47 @@
* @property-read CarbonInterface $end Period end date.
* @property-read CarbonInterval $interval Underlying date interval instance. Always present, one day by default.
*
- * @method static CarbonPeriod start($date, $inclusive = null) Create instance specifying start date or modify the start date if called on an instance.
- * @method static CarbonPeriod since($date, $inclusive = null) Alias for start().
- * @method static CarbonPeriod sinceNow($inclusive = null) Create instance with start date set to now or set the start date to now if called on an instance.
- * @method static CarbonPeriod end($date = null, $inclusive = null) Create instance specifying end date or modify the end date if called on an instance.
- * @method static CarbonPeriod until($date = null, $inclusive = null) Alias for end().
- * @method static CarbonPeriod untilNow($inclusive = null) Create instance with end date set to now or set the end date to now if called on an instance.
- * @method static CarbonPeriod dates($start, $end = null) Create instance with start and end dates or modify the start and end dates if called on an instance.
- * @method static CarbonPeriod between($start, $end = null) Create instance with start and end dates or modify the start and end dates if called on an instance.
- * @method static CarbonPeriod recurrences($recurrences = null) Create instance with maximum number of recurrences or modify the number of recurrences if called on an instance.
- * @method static CarbonPeriod times($recurrences = null) Alias for recurrences().
- * @method static CarbonPeriod options($options = null) Create instance with options or modify the options if called on an instance.
- * @method static CarbonPeriod toggle($options, $state = null) Create instance with options toggled on or off, or toggle options if called on an instance.
- * @method static CarbonPeriod filter($callback, $name = null) Create instance with filter added to the stack or append a filter if called on an instance.
- * @method static CarbonPeriod push($callback, $name = null) Alias for filter().
- * @method static CarbonPeriod prepend($callback, $name = null) Create instance with filter prepended to the stack or prepend a filter if called on an instance.
- * @method static CarbonPeriod filters(array $filters = []) Create instance with filters stack or replace the whole filters stack if called on an instance.
- * @method static CarbonPeriod interval($interval) Create instance with given date interval or modify the interval if called on an instance.
- * @method static CarbonPeriod each($interval) Create instance with given date interval or modify the interval if called on an instance.
- * @method static CarbonPeriod every($interval) Create instance with given date interval or modify the interval if called on an instance.
- * @method static CarbonPeriod step($interval) Create instance with given date interval or modify the interval if called on an instance.
- * @method static CarbonPeriod stepBy($interval) Create instance with given date interval or modify the interval if called on an instance.
- * @method static CarbonPeriod invert() Create instance with inverted date interval or invert the interval if called on an instance.
- * @method static CarbonPeriod years($years = 1) Create instance specifying a number of years for date interval or replace the interval by the given a number of years if called on an instance.
- * @method static CarbonPeriod year($years = 1) Alias for years().
- * @method static CarbonPeriod months($months = 1) Create instance specifying a number of months for date interval or replace the interval by the given a number of months if called on an instance.
- * @method static CarbonPeriod month($months = 1) Alias for months().
- * @method static CarbonPeriod weeks($weeks = 1) Create instance specifying a number of weeks for date interval or replace the interval by the given a number of weeks if called on an instance.
- * @method static CarbonPeriod week($weeks = 1) Alias for weeks().
- * @method static CarbonPeriod days($days = 1) Create instance specifying a number of days for date interval or replace the interval by the given a number of days if called on an instance.
- * @method static CarbonPeriod dayz($days = 1) Alias for days().
- * @method static CarbonPeriod day($days = 1) Alias for days().
- * @method static CarbonPeriod hours($hours = 1) Create instance specifying a number of hours for date interval or replace the interval by the given a number of hours if called on an instance.
- * @method static CarbonPeriod hour($hours = 1) Alias for hours().
- * @method static CarbonPeriod minutes($minutes = 1) Create instance specifying a number of minutes for date interval or replace the interval by the given a number of minutes if called on an instance.
- * @method static CarbonPeriod minute($minutes = 1) Alias for minutes().
- * @method static CarbonPeriod seconds($seconds = 1) Create instance specifying a number of seconds for date interval or replace the interval by the given a number of seconds if called on an instance.
- * @method static CarbonPeriod second($seconds = 1) Alias for seconds().
+ * @method static static start($date, $inclusive = null) Create instance specifying start date or modify the start date if called on an instance.
+ * @method static static since($date, $inclusive = null) Alias for start().
+ * @method static static sinceNow($inclusive = null) Create instance with start date set to now or set the start date to now if called on an instance.
+ * @method static static end($date = null, $inclusive = null) Create instance specifying end date or modify the end date if called on an instance.
+ * @method static static until($date = null, $inclusive = null) Alias for end().
+ * @method static static untilNow($inclusive = null) Create instance with end date set to now or set the end date to now if called on an instance.
+ * @method static static dates($start, $end = null) Create instance with start and end dates or modify the start and end dates if called on an instance.
+ * @method static static between($start, $end = null) Create instance with start and end dates or modify the start and end dates if called on an instance.
+ * @method static static recurrences($recurrences = null) Create instance with maximum number of recurrences or modify the number of recurrences if called on an instance.
+ * @method static static times($recurrences = null) Alias for recurrences().
+ * @method static static options($options = null) Create instance with options or modify the options if called on an instance.
+ * @method static static toggle($options, $state = null) Create instance with options toggled on or off, or toggle options if called on an instance.
+ * @method static static filter($callback, $name = null) Create instance with filter added to the stack or append a filter if called on an instance.
+ * @method static static push($callback, $name = null) Alias for filter().
+ * @method static static prepend($callback, $name = null) Create instance with filter prepended to the stack or prepend a filter if called on an instance.
+ * @method static static filters(array $filters = []) Create instance with filters stack or replace the whole filters stack if called on an instance.
+ * @method static static interval($interval) Create instance with given date interval or modify the interval if called on an instance.
+ * @method static static each($interval) Create instance with given date interval or modify the interval if called on an instance.
+ * @method static static every($interval) Create instance with given date interval or modify the interval if called on an instance.
+ * @method static static step($interval) Create instance with given date interval or modify the interval if called on an instance.
+ * @method static static stepBy($interval) Create instance with given date interval or modify the interval if called on an instance.
+ * @method static static invert() Create instance with inverted date interval or invert the interval if called on an instance.
+ * @method static static years($years = 1) Create instance specifying a number of years for date interval or replace the interval by the given a number of years if called on an instance.
+ * @method static static year($years = 1) Alias for years().
+ * @method static static months($months = 1) Create instance specifying a number of months for date interval or replace the interval by the given a number of months if called on an instance.
+ * @method static static month($months = 1) Alias for months().
+ * @method static static weeks($weeks = 1) Create instance specifying a number of weeks for date interval or replace the interval by the given a number of weeks if called on an instance.
+ * @method static static week($weeks = 1) Alias for weeks().
+ * @method static static days($days = 1) Create instance specifying a number of days for date interval or replace the interval by the given a number of days if called on an instance.
+ * @method static static dayz($days = 1) Alias for days().
+ * @method static static day($days = 1) Alias for days().
+ * @method static static hours($hours = 1) Create instance specifying a number of hours for date interval or replace the interval by the given a number of hours if called on an instance.
+ * @method static static hour($hours = 1) Alias for hours().
+ * @method static static minutes($minutes = 1) Create instance specifying a number of minutes for date interval or replace the interval by the given a number of minutes if called on an instance.
+ * @method static static minute($minutes = 1) Alias for minutes().
+ * @method static static seconds($seconds = 1) Create instance specifying a number of seconds for date interval or replace the interval by the given a number of seconds if called on an instance.
+ * @method static static second($seconds = 1) Alias for seconds().
+ * @method static static milliseconds($milliseconds = 1) Create instance specifying a number of milliseconds for date interval or replace the interval by the given a number of milliseconds if called on an instance.
+ * @method static static millisecond($milliseconds = 1) Alias for milliseconds().
+ * @method static static microseconds($microseconds = 1) Create instance specifying a number of microseconds for date interval or replace the interval by the given a number of microseconds if called on an instance.
+ * @method static static microsecond($microseconds = 1) Alias for microseconds().
* @method $this roundYear(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
* @method $this roundYears(float $precision = 1, string $function = "round") Round the current instance year with given precision using the given function.
* @method $this floorYear(float $precision = 1) Truncate the current instance year with given precision.
@@ -173,6 +180,7 @@
Mixin::mixin as baseMixin;
}
use Options;
+ use ToStringFormat;
/**
* Built-in filter for limit by recurrences.
@@ -231,6 +239,13 @@
public const END_MAX_ATTEMPTS = 10000;
/**
+ * Default date class of iteration items.
+ *
+ * @var string
+ */
+ protected const DEFAULT_DATE_CLASS = Carbon::class;
+
+ /**
* The registered macros.
*
* @var array
@@ -252,6 +267,13 @@
protected $dateInterval;
/**
+ * True once __construct is finished.
+ *
+ * @var bool
+ */
+ protected $constructed = false;
+
+ /**
* Whether current date interval was set by default.
*
* @var bool
@@ -377,7 +399,7 @@
);
}
- $class = \get_called_class();
+ $class = static::class;
$type = \gettype($period);
throw new NotAPeriodException(
@@ -482,15 +504,16 @@
$interval = null;
$start = null;
$end = null;
+ $dateClass = static::DEFAULT_DATE_CLASS;
foreach (explode('/', $iso) as $key => $part) {
- if ($key === 0 && preg_match('/^R([0-9]*|INF)$/', $part, $match)) {
+ if ($key === 0 && preg_match('/^R(\d*|INF)$/', $part, $match)) {
$parsed = \strlen($match[1]) ? (($match[1] !== 'INF') ? (int) $match[1] : INF) : null;
} elseif ($interval === null && $parsed = CarbonInterval::make($part)) {
$interval = $part;
- } elseif ($start === null && $parsed = Carbon::make($part)) {
+ } elseif ($start === null && $parsed = $dateClass::make($part)) {
$start = $part;
- } elseif ($end === null && $parsed = Carbon::make(static::addMissingParts($start ?? '', $part))) {
+ } elseif ($end === null && $parsed = $dateClass::make(static::addMissingParts($start ?? '', $part))) {
$end = $part;
} else {
throw new InvalidPeriodParameterException("Invalid ISO 8601 specification: $iso.");
@@ -503,7 +526,7 @@
}
/**
- * Add missing parts of the target date from the soure date.
+ * Add missing parts of the target date from the source date.
*
* @param string $source
* @param string $target
@@ -512,7 +535,7 @@
*/
protected static function addMissingParts($source, $target)
{
- $pattern = '/'.preg_replace('/[0-9]+/', '[0-9]+', preg_quote($target, '/')).'$/';
+ $pattern = '/'.preg_replace('/\d+/', '[0-9]+', preg_quote($target, '/')).'$/';
$result = preg_replace($pattern, $target, $source, 1, $count);
@@ -621,6 +644,10 @@
*/
public function __construct(...$arguments)
{
+ if (is_a($this->dateClass, DateTimeImmutable::class, true)) {
+ $this->options = static::IMMUTABLE;
+ }
+
// Parse and assign arguments one by one. First argument may be an ISO 8601 spec,
// which will be first parsed into parts and then processed the same way.
@@ -648,6 +675,8 @@
}
}
+ $optionsSet = false;
+
foreach ($arguments as $argument) {
$parsedDate = null;
@@ -655,10 +684,10 @@
$this->setTimezone($argument);
} elseif ($this->dateInterval === null &&
(
- \is_string($argument) && preg_match(
- '/^(-?\d(\d(?![\/-])|[^\d\/-]([\/-])?)*|P[T0-9].*|(?:\h*\d+(?:\.\d+)?\h*[a-z]+)+)$/i',
+ (\is_string($argument) && preg_match(
+ '/^(-?\d(\d(?![\/-])|[^\d\/-]([\/-])?)*|P[T\d].*|(?:\h*\d+(?:\.\d+)?\h*[a-z]+)+)$/i',
$argument
- ) ||
+ )) ||
$argument instanceof DateInterval ||
$argument instanceof Closure
) &&
@@ -671,15 +700,17 @@
$this->setEndDate($parsedDate);
} elseif ($this->recurrences === null && $this->endDate === null && is_numeric($argument)) {
$this->setRecurrences($argument);
- } elseif ($this->options === null && (\is_int($argument) || $argument === null)) {
- $this->setOptions($argument);
+ } elseif (!$optionsSet && (\is_int($argument) || $argument === null)) {
+ $optionsSet = true;
+ $this->setOptions(((int) $this->options) | ((int) $argument));
} else {
throw new InvalidPeriodParameterException('Invalid constructor parameters.');
}
}
if ($this->startDate === null) {
- $this->setStartDate(Carbon::now());
+ $dateClass = $this->dateClass;
+ $this->setStartDate($dateClass::now());
}
if ($this->dateInterval === null) {
@@ -691,6 +722,8 @@
if ($this->options === null) {
$this->setOptions(0);
}
+
+ $this->constructed = true;
}
/**
@@ -704,6 +737,17 @@
}
/**
+ * Prepare the instance to be set (self if mutable to be mutated,
+ * copy if immutable to generate a new instance).
+ *
+ * @return static
+ */
+ protected function copyIfImmutable()
+ {
+ return $this;
+ }
+
+ /**
* Get the getter for a property allowing both `DatePeriod` snakeCase and camelCase names.
*
* @param string $name
@@ -794,7 +838,7 @@
*
* @param string $dateClass
*
- * @return $this
+ * @return static
*/
public function setDateClass(string $dateClass)
{
@@ -802,15 +846,16 @@
throw new NotACarbonClassException($dateClass);
}
- $this->dateClass = $dateClass;
+ $self = $this->copyIfImmutable();
+ $self->dateClass = $dateClass;
if (is_a($dateClass, Carbon::class, true)) {
- $this->toggleOptions(static::IMMUTABLE, false);
+ $self->options = $self->options & ~static::IMMUTABLE;
} elseif (is_a($dateClass, CarbonImmutable::class, true)) {
- $this->toggleOptions(static::IMMUTABLE, true);
+ $self->options = $self->options | static::IMMUTABLE;
}
- return $this;
+ return $self;
}
/**
@@ -830,7 +875,7 @@
*
* @throws InvalidIntervalException
*
- * @return $this
+ * @return static
*/
public function setDateInterval($interval)
{
@@ -842,25 +887,24 @@
throw new InvalidIntervalException('Empty interval is not accepted.');
}
- $this->dateInterval = $interval;
+ $self = $this->copyIfImmutable();
+ $self->dateInterval = $interval;
- $this->isDefaultInterval = false;
+ $self->isDefaultInterval = false;
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
* Invert the period date interval.
*
- * @return $this
+ * @return static
*/
public function invertDateInterval()
{
- $interval = $this->dateInterval->invert();
-
- return $this->setDateInterval($interval);
+ return $this->setDateInterval($this->dateInterval->invert());
}
/**
@@ -869,14 +913,11 @@
* @param DateTime|DateTimeInterface|string $start
* @param DateTime|DateTimeInterface|string|null $end
*
- * @return $this
+ * @return static
*/
public function setDates($start, $end)
{
- $this->setStartDate($start);
- $this->setEndDate($end);
-
- return $this;
+ return $this->setStartDate($start)->setEndDate($end);
}
/**
@@ -886,7 +927,7 @@
*
* @throws InvalidArgumentException
*
- * @return $this
+ * @return static
*/
public function setOptions($options)
{
@@ -894,11 +935,12 @@
throw new InvalidPeriodParameterException('Invalid options.');
}
- $this->options = $options ?: 0;
+ $self = $this->copyIfImmutable();
+ $self->options = $options ?: 0;
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
@@ -919,7 +961,7 @@
*
* @throws \InvalidArgumentException
*
- * @return $this
+ * @return static
*/
public function toggleOptions($options, $state = null)
{
@@ -939,7 +981,7 @@
*
* @param bool $state
*
- * @return $this
+ * @return static
*/
public function excludeStartDate($state = true)
{
@@ -951,7 +993,7 @@
*
* @param bool $state
*
- * @return $this
+ * @return static
*/
public function excludeEndDate($state = true)
{
@@ -1095,17 +1137,18 @@
* @param callable $callback
* @param string $name
*
- * @return $this
+ * @return static
*/
public function addFilter($callback, $name = null)
{
- $tuple = $this->createFilterTuple(\func_get_args());
+ $self = $this->copyIfImmutable();
+ $tuple = $self->createFilterTuple(\func_get_args());
- $this->filters[] = $tuple;
+ $self->filters[] = $tuple;
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
@@ -1116,17 +1159,18 @@
* @param callable $callback
* @param string $name
*
- * @return $this
+ * @return static
*/
public function prependFilter($callback, $name = null)
{
- $tuple = $this->createFilterTuple(\func_get_args());
+ $self = $this->copyIfImmutable();
+ $tuple = $self->createFilterTuple(\func_get_args());
- array_unshift($this->filters, $tuple);
+ array_unshift($self->filters, $tuple);
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
@@ -1134,24 +1178,25 @@
*
* @param callable|string $filter
*
- * @return $this
+ * @return static
*/
public function removeFilter($filter)
{
+ $self = $this->copyIfImmutable();
$key = \is_callable($filter) ? 0 : 1;
- $this->filters = array_values(array_filter(
+ $self->filters = array_values(array_filter(
$this->filters,
function ($tuple) use ($key, $filter) {
return $tuple[$key] !== $filter;
}
));
- $this->updateInternalState();
+ $self->updateInternalState();
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
@@ -1189,39 +1234,41 @@
*
* @param array $filters
*
- * @return $this
+ * @return static
*/
public function setFilters(array $filters)
{
- $this->filters = $filters;
+ $self = $this->copyIfImmutable();
+ $self->filters = $filters;
- $this->updateInternalState();
+ $self->updateInternalState();
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
* Reset filters stack.
*
- * @return $this
+ * @return static
*/
public function resetFilters()
{
- $this->filters = [];
+ $self = $this->copyIfImmutable();
+ $self->filters = [];
- if ($this->endDate !== null) {
- $this->filters[] = [static::END_DATE_FILTER, null];
+ if ($self->endDate !== null) {
+ $self->filters[] = [static::END_DATE_FILTER, null];
}
- if ($this->recurrences !== null) {
- $this->filters[] = [static::RECURRENCES_FILTER, null];
+ if ($self->recurrences !== null) {
+ $self->filters[] = [static::RECURRENCES_FILTER, null];
}
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
@@ -1231,11 +1278,11 @@
*
* @throws InvalidArgumentException
*
- * @return $this
+ * @return static
*/
public function setRecurrences($recurrences)
{
- if (!is_numeric($recurrences) && $recurrences !== null || $recurrences < 0) {
+ if ((!is_numeric($recurrences) && $recurrences !== null) || $recurrences < 0) {
throw new InvalidPeriodParameterException('Invalid number of recurrences.');
}
@@ -1243,15 +1290,17 @@
return $this->removeFilter(static::RECURRENCES_FILTER);
}
- $this->recurrences = $recurrences === INF ? INF : (int) $recurrences;
+ /** @var self $self */
+ $self = $this->copyIfImmutable();
+ $self->recurrences = $recurrences === INF ? INF : (int) $recurrences;
- if (!$this->hasFilter(static::RECURRENCES_FILTER)) {
- return $this->addFilter(static::RECURRENCES_FILTER);
+ if (!$self->hasFilter(static::RECURRENCES_FILTER)) {
+ return $self->addFilter(static::RECURRENCES_FILTER);
}
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
@@ -1262,21 +1311,22 @@
*
* @throws InvalidPeriodDateException
*
- * @return $this
+ * @return static
*/
public function setStartDate($date, $inclusive = null)
{
- if (!$date = ([$this->dateClass, 'make'])($date)) {
+ if (!$this->isInfiniteDate($date) && !($date = ([$this->dateClass, 'make'])($date))) {
throw new InvalidPeriodDateException('Invalid start date.');
}
- $this->startDate = $date;
+ $self = $this->copyIfImmutable();
+ $self->startDate = $date;
if ($inclusive !== null) {
- $this->toggleOptions(static::EXCLUDE_START_DATE, !$inclusive);
+ $self = $self->toggleOptions(static::EXCLUDE_START_DATE, !$inclusive);
}
- return $this;
+ return $self;
}
/**
@@ -1287,11 +1337,11 @@
*
* @throws \InvalidArgumentException
*
- * @return $this
+ * @return static
*/
public function setEndDate($date, $inclusive = null)
{
- if ($date !== null && !$date = ([$this->dateClass, 'make'])($date)) {
+ if ($date !== null && !$this->isInfiniteDate($date) && !$date = ([$this->dateClass, 'make'])($date)) {
throw new InvalidPeriodDateException('Invalid end date.');
}
@@ -1299,19 +1349,20 @@
return $this->removeFilter(static::END_DATE_FILTER);
}
- $this->endDate = $date;
+ $self = $this->copyIfImmutable();
+ $self->endDate = $date;
if ($inclusive !== null) {
- $this->toggleOptions(static::EXCLUDE_END_DATE, !$inclusive);
+ $self = $self->toggleOptions(static::EXCLUDE_END_DATE, !$inclusive);
}
- if (!$this->hasFilter(static::END_DATE_FILTER)) {
- return $this->addFilter(static::END_DATE_FILTER);
+ if (!$self->hasFilter(static::END_DATE_FILTER)) {
+ return $self->addFilter(static::END_DATE_FILTER);
}
- $this->handleChangedParameters();
+ $self->handleChangedParameters();
- return $this;
+ return $self;
}
/**
@@ -1457,13 +1508,21 @@
*/
public function toString()
{
+ $format = $this->localToStringFormat ?? static::$toStringFormat;
+
+ if ($format instanceof Closure) {
+ return $format($this);
+ }
+
$translator = ([$this->dateClass, 'getTranslator'])();
$parts = [];
- $format = !$this->startDate->isStartOfDay() || $this->endDate && !$this->endDate->isStartOfDay()
- ? 'Y-m-d H:i:s'
- : 'Y-m-d';
+ $format = $format ?? (
+ !$this->startDate->isStartOfDay() || ($this->endDate && !$this->endDate->isStartOfDay())
+ ? 'Y-m-d H:i:s'
+ : 'Y-m-d'
+ );
if ($this->recurrences !== null) {
$parts[] = $this->translate('period_recurrences', [], $this->recurrences, $translator);
@@ -1506,9 +1565,9 @@
if (!method_exists($className, 'instance')) {
if (is_a($className, DatePeriod::class, true)) {
return new $className(
- $this->getStartDate(),
+ $this->rawDate($this->getStartDate()),
$this->getDateInterval(),
- $this->getEndDate() ? $this->getIncludedEndDate() : $this->getRecurrences(),
+ $this->getEndDate() ? $this->rawDate($this->getIncludedEndDate()) : $this->getRecurrences(),
$this->isStartExcluded() ? DatePeriod::EXCLUDE_START_DATE : 0
);
}
@@ -1535,12 +1594,49 @@
}
/**
+ * Return `true` if the period has no custom filter and is guaranteed to be endless.
+ *
+ * Note that we can't check if a period is endless as soon as it has custom filters
+ * because filters can emit `CarbonPeriod::END_ITERATION` to stop the iteration in
+ * a way we can't predict without actually iterating the period.
+ */
+ public function isUnfilteredAndEndLess(): bool
+ {
+ foreach ($this->filters as $filter) {
+ switch ($filter) {
+ case [static::RECURRENCES_FILTER, null]:
+ if ($this->recurrences !== null && is_finite($this->recurrences)) {
+ return false;
+ }
+
+ break;
+
+ case [static::END_DATE_FILTER, null]:
+ if ($this->endDate !== null && !$this->endDate->isEndOfTime()) {
+ return false;
+ }
+
+ break;
+
+ default:
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ /**
* Convert the date period into an array without changing current iteration state.
*
* @return CarbonInterface[]
*/
public function toArray()
{
+ if ($this->isUnfilteredAndEndLess()) {
+ throw new EndLessPeriodException("Endless period can't be converted to array nor counted.");
+ }
+
$state = [
$this->key,
$this->current ? $this->current->avoidMutation() : null,
@@ -1572,6 +1668,16 @@
*/
public function first()
{
+ if ($this->isUnfilteredAndEndLess()) {
+ foreach ($this as $date) {
+ $this->rewind();
+
+ return $date;
+ }
+
+ return null;
+ }
+
return ($this->toArray() ?: [])[0] ?? null;
}
@@ -1626,54 +1732,80 @@
return $roundedValue;
}
- $first = \count($parameters) >= 1 ? $parameters[0] : null;
- $second = \count($parameters) >= 2 ? $parameters[1] : null;
-
switch ($method) {
case 'start':
case 'since':
- return $this->setStartDate($first, $second);
+ self::setDefaultParameters($parameters, [
+ [0, 'date', null],
+ ]);
+
+ return $this->setStartDate(...$parameters);
case 'sinceNow':
- return $this->setStartDate(new Carbon(), $first);
+ return $this->setStartDate(new Carbon(), ...$parameters);
case 'end':
case 'until':
- return $this->setEndDate($first, $second);
+ self::setDefaultParameters($parameters, [
+ [0, 'date', null],
+ ]);
+
+ return $this->setEndDate(...$parameters);
case 'untilNow':
- return $this->setEndDate(new Carbon(), $first);
+ return $this->setEndDate(new Carbon(), ...$parameters);
case 'dates':
case 'between':
- return $this->setDates($first, $second);
+ self::setDefaultParameters($parameters, [
+ [0, 'start', null],
+ [1, 'end', null],
+ ]);
+
+ return $this->setDates(...$parameters);
case 'recurrences':
case 'times':
- return $this->setRecurrences($first);
+ self::setDefaultParameters($parameters, [
+ [0, 'recurrences', null],
+ ]);
+
+ return $this->setRecurrences(...$parameters);
case 'options':
- return $this->setOptions($first);
+ self::setDefaultParameters($parameters, [
+ [0, 'options', null],
+ ]);
+
+ return $this->setOptions(...$parameters);
case 'toggle':
- return $this->toggleOptions($first, $second);
+ self::setDefaultParameters($parameters, [
+ [0, 'options', null],
+ ]);
+
+ return $this->toggleOptions(...$parameters);
case 'filter':
case 'push':
- return $this->addFilter($first, $second);
+ return $this->addFilter(...$parameters);
case 'prepend':
- return $this->prependFilter($first, $second);
+ return $this->prependFilter(...$parameters);
case 'filters':
- return $this->setFilters($first ?: []);
+ self::setDefaultParameters($parameters, [
+ [0, 'filters', []],
+ ]);
+
+ return $this->setFilters(...$parameters);
case 'interval':
case 'each':
case 'every':
case 'step':
case 'stepBy':
- return $this->setDateInterval($first);
+ return $this->setDateInterval(...$parameters);
case 'invert':
return $this->invertDateInterval();
@@ -1693,15 +1825,19 @@
case 'minute':
case 'seconds':
case 'second':
+ case 'milliseconds':
+ case 'millisecond':
+ case 'microseconds':
+ case 'microsecond':
return $this->setDateInterval((
// Override default P1D when instantiating via fluent setters.
[$this->isDefaultInterval ? new CarbonInterval('PT0S') : $this->dateInterval, $method]
- )(
- \count($parameters) === 0 ? 1 : $first
- ));
+ )(...$parameters));
}
- if ($this->localStrictModeEnabled ?? Carbon::isStrictModeEnabled()) {
+ $dateClass = $this->dateClass;
+
+ if ($this->localStrictModeEnabled ?? $dateClass::isStrictModeEnabled()) {
throw new UnknownMethodException($method);
}
@@ -1717,18 +1853,19 @@
*/
public function setTimezone($timezone)
{
- $this->tzName = $timezone;
- $this->timezone = $timezone;
+ $self = $this->copyIfImmutable();
+ $self->tzName = $timezone;
+ $self->timezone = $timezone;
- if ($this->startDate) {
- $this->setStartDate($this->startDate->setTimezone($timezone));
+ if ($self->startDate) {
+ $self = $self->setStartDate($self->startDate->setTimezone($timezone));
}
- if ($this->endDate) {
- $this->setEndDate($this->endDate->setTimezone($timezone));
+ if ($self->endDate) {
+ $self = $self->setEndDate($self->endDate->setTimezone($timezone));
}
- return $this;
+ return $self;
}
/**
@@ -1740,18 +1877,19 @@
*/
public function shiftTimezone($timezone)
{
- $this->tzName = $timezone;
- $this->timezone = $timezone;
+ $self = $this->copyIfImmutable();
+ $self->tzName = $timezone;
+ $self->timezone = $timezone;
- if ($this->startDate) {
- $this->setStartDate($this->startDate->shiftTimezone($timezone));
+ if ($self->startDate) {
+ $self = $self->setStartDate($self->startDate->shiftTimezone($timezone));
}
- if ($this->endDate) {
- $this->setEndDate($this->endDate->shiftTimezone($timezone));
+ if ($self->endDate) {
+ $self = $self->setEndDate($self->endDate->shiftTimezone($timezone));
}
- return $this;
+ return $self;
}
/**
@@ -1896,7 +2034,7 @@
/**
* Determines if the instance is equal to another.
- * Warning: if options differ, instances wil never be equal.
+ * Warning: if options differ, instances will never be equal.
*
* @param mixed $period
*
@@ -1911,7 +2049,7 @@
/**
* Determines if the instance is equal to another.
- * Warning: if options differ, instances wil never be equal.
+ * Warning: if options differ, instances will never be equal.
*
* @param mixed $period
*
@@ -1934,7 +2072,7 @@
/**
* Determines if the instance is not equal to another.
- * Warning: if options differ, instances wil never be equal.
+ * Warning: if options differ, instances will never be equal.
*
* @param mixed $period
*
@@ -1949,7 +2087,7 @@
/**
* Determines if the instance is not equal to another.
- * Warning: if options differ, instances wil never be equal.
+ * Warning: if options differ, instances will never be equal.
*
* @param mixed $period
*
@@ -2130,19 +2268,18 @@
* @param float|int|string|\DateInterval|null $precision
* @param string $function
*
- * @return $this
+ * @return static
*/
public function roundUnit($unit, $precision = 1, $function = 'round')
{
- $this->setStartDate($this->getStartDate()->roundUnit($unit, $precision, $function));
+ $self = $this->copyIfImmutable();
+ $self = $self->setStartDate($self->getStartDate()->roundUnit($unit, $precision, $function));
- if ($this->endDate) {
- $this->setEndDate($this->getEndDate()->roundUnit($unit, $precision, $function));
+ if ($self->endDate) {
+ $self = $self->setEndDate($self->getEndDate()->roundUnit($unit, $precision, $function));
}
- $this->setDateInterval($this->getDateInterval()->roundUnit($unit, $precision, $function));
-
- return $this;
+ return $self->setDateInterval($self->getDateInterval()->roundUnit($unit, $precision, $function));
}
/**
@@ -2151,7 +2288,7 @@
* @param string $unit
* @param float|int|string|\DateInterval|null $precision
*
- * @return $this
+ * @return static
*/
public function floorUnit($unit, $precision = 1)
{
@@ -2164,7 +2301,7 @@
* @param string $unit
* @param float|int|string|\DateInterval|null $precision
*
- * @return $this
+ * @return static
*/
public function ceilUnit($unit, $precision = 1)
{
@@ -2177,7 +2314,7 @@
* @param float|int|string|\DateInterval|null $precision
* @param string $function
*
- * @return $this
+ * @return static
*/
public function round($precision = null, $function = 'round')
{
@@ -2192,7 +2329,7 @@
*
* @param float|int|string|\DateInterval|null $precision
*
- * @return $this
+ * @return static
*/
public function floor($precision = null)
{
@@ -2204,7 +2341,7 @@
*
* @param float|int|string|\DateInterval|null $precision
*
- * @return $this
+ * @return static
*/
public function ceil($precision = null)
{
@@ -2393,9 +2530,9 @@
protected function handleChangedParameters()
{
if (($this->getOptions() & static::IMMUTABLE) && $this->dateClass === Carbon::class) {
- $this->setDateClass(CarbonImmutable::class);
+ $this->dateClass = CarbonImmutable::class;
} elseif (!($this->getOptions() & static::IMMUTABLE) && $this->dateClass === CarbonImmutable::class) {
- $this->setDateClass(Carbon::class);
+ $this->dateClass = Carbon::class;
}
$this->validationResult = null;
@@ -2555,14 +2692,51 @@
if (\is_string($value)) {
$value = trim($value);
- if (!preg_match('/^P[0-9T]/', $value) &&
- !preg_match('/^R[0-9]/', $value) &&
- preg_match('/[a-z0-9]/i', $value)
+ if (!preg_match('/^P[\dT]/', $value) &&
+ !preg_match('/^R\d/', $value) &&
+ preg_match('/[a-z\d]/i', $value)
) {
- return Carbon::parse($value, $this->tzName);
+ $dateClass = $this->dateClass;
+
+ return $dateClass::parse($value, $this->tzName);
}
}
return null;
}
+
+ private function isInfiniteDate($date): bool
+ {
+ return $date instanceof CarbonInterface && ($date->isEndOfTime() || $date->isStartOfTime());
+ }
+
+ private function rawDate($date): ?DateTimeInterface
+ {
+ if ($date === false || $date === null) {
+ return null;
+ }
+
+ if ($date instanceof CarbonInterface) {
+ return $date->isMutable()
+ ? $date->toDateTime()
+ : $date->toDateTimeImmutable();
+ }
+
+ if (\in_array(\get_class($date), [DateTime::class, DateTimeImmutable::class], true)) {
+ return $date;
+ }
+
+ $class = $date instanceof DateTime ? DateTime::class : DateTimeImmutable::class;
+
+ return new $class($date->format('Y-m-d H:i:s.u'), $date->getTimezone());
+ }
+
+ private static function setDefaultParameters(array &$parameters, array $defaults): void
+ {
+ foreach ($defaults as [$index, $name, $value]) {
+ if (!\array_key_exists($index, $parameters) && !\array_key_exists($name, $parameters)) {
+ $parameters[$index] = $value;
+ }
+ }
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriodImmutable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriodImmutable.php
new file mode 100644
index 0000000..f0d0ee2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonPeriodImmutable.php
@@ -0,0 +1,40 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon;
+
+class CarbonPeriodImmutable extends CarbonPeriod
+{
+ /**
+ * Default date class of iteration items.
+ *
+ * @var string
+ */
+ protected const DEFAULT_DATE_CLASS = CarbonImmutable::class;
+
+ /**
+ * Date class of iteration items.
+ *
+ * @var string
+ */
+ protected $dateClass = CarbonImmutable::class;
+
+ /**
+ * Prepare the instance to be set (self if mutable to be mutated,
+ * copy if immutable to generate a new instance).
+ *
+ * @return static
+ */
+ protected function copyIfImmutable()
+ {
+ return $this->constructed ? clone $this : $this;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php
index b4d16ba..c81899f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/CarbonTimeZone.php
@@ -30,7 +30,7 @@
throw new InvalidTimeZoneException('Absolute timezone offset cannot be greater than 100.');
}
- return ($timezone >= 0 ? '+' : '').$timezone.':00';
+ return ($timezone >= 0 ? '+' : '').ltrim($timezone, '+').':00';
}
protected static function getDateTimeZoneNameFromMixed($timezone)
@@ -101,15 +101,15 @@
$tz = static::getDateTimeZoneFromName($object);
}
- if ($tz === false) {
- if (Carbon::isStrictModeEnabled()) {
- throw new InvalidTimeZoneException('Unknown or bad timezone ('.($objectDump ?: $object).')');
- }
-
- return false;
+ if ($tz !== false) {
+ return new static($tz->getName());
}
- return new static($tz->getName());
+ if (Carbon::isStrictModeEnabled()) {
+ throw new InvalidTimeZoneException('Unknown or bad timezone ('.($objectDump ?: $object).')');
+ }
+
+ return false;
}
/**
@@ -231,15 +231,15 @@
{
$tz = $this->toRegionName($date);
- if ($tz === false) {
- if (Carbon::isStrictModeEnabled()) {
- throw new InvalidTimeZoneException('Unknown timezone for offset '.$this->getOffset($date ?: Carbon::now($this)).' seconds.');
- }
-
- return false;
+ if ($tz !== false) {
+ return new static($tz);
}
- return new static($tz);
+ if (Carbon::isStrictModeEnabled()) {
+ throw new InvalidTimeZoneException('Unknown timezone for offset '.$this->getOffset($date ?: Carbon::now($this)).' seconds.');
+ }
+
+ return false;
}
/**
@@ -253,6 +253,18 @@
}
/**
+ * Return the type number:
+ *
+ * Type 1; A UTC offset, such as -0300
+ * Type 2; A timezone abbreviation, such as GMT
+ * Type 3: A timezone identifier, such as Europe/London
+ */
+ public function getType(): int
+ {
+ return preg_match('/"timezone_type";i:(\d)/', serialize($this), $match) ? (int) $match[1] : 3;
+ }
+
+ /**
* Create a CarbonTimeZone from mixed input.
*
* @param DateTimeZone|string|int|null $object
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonDoctrineType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonDoctrineType.php
deleted file mode 100644
index ccc457f..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonDoctrineType.php
+++ /dev/null
@@ -1,23 +0,0 @@
-<?php
-
-/**
- * This file is part of the Carbon package.
- *
- * (c) Brian Nesbitt <brian@nesbot.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-
-namespace Carbon\Doctrine;
-
-use Doctrine\DBAL\Platforms\AbstractPlatform;
-
-interface CarbonDoctrineType
-{
- public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform);
-
- public function convertToPHPValue($value, AbstractPlatform $platform);
-
- public function convertToDatabaseValue($value, AbstractPlatform $platform);
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonImmutableType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonImmutableType.php
deleted file mode 100644
index bf476a7..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonImmutableType.php
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-
-/**
- * This file is part of the Carbon package.
- *
- * (c) Brian Nesbitt <brian@nesbot.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-
-namespace Carbon\Doctrine;
-
-use Doctrine\DBAL\Platforms\AbstractPlatform;
-
-class CarbonImmutableType extends DateTimeImmutableType implements CarbonDoctrineType
-{
- /**
- * {@inheritdoc}
- *
- * @return string
- */
- public function getName()
- {
- return 'carbon_immutable';
- }
-
- /**
- * {@inheritdoc}
- *
- * @return bool
- */
- public function requiresSQLCommentHint(AbstractPlatform $platform)
- {
- return true;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonType.php
deleted file mode 100644
index 9289d84..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonType.php
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-
-/**
- * This file is part of the Carbon package.
- *
- * (c) Brian Nesbitt <brian@nesbot.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-
-namespace Carbon\Doctrine;
-
-use Doctrine\DBAL\Platforms\AbstractPlatform;
-
-class CarbonType extends DateTimeType implements CarbonDoctrineType
-{
- /**
- * {@inheritdoc}
- *
- * @return string
- */
- public function getName()
- {
- return 'carbon';
- }
-
- /**
- * {@inheritdoc}
- *
- * @return bool
- */
- public function requiresSQLCommentHint(AbstractPlatform $platform)
- {
- return true;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonTypeConverter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonTypeConverter.php
deleted file mode 100644
index ecfe17e..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/CarbonTypeConverter.php
+++ /dev/null
@@ -1,123 +0,0 @@
-<?php
-
-/**
- * This file is part of the Carbon package.
- *
- * (c) Brian Nesbitt <brian@nesbot.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-
-namespace Carbon\Doctrine;
-
-use Carbon\Carbon;
-use Carbon\CarbonInterface;
-use DateTimeInterface;
-use Doctrine\DBAL\Platforms\AbstractPlatform;
-use Doctrine\DBAL\Types\ConversionException;
-use Exception;
-
-/**
- * @template T of CarbonInterface
- */
-trait CarbonTypeConverter
-{
- /**
- * @return class-string<T>
- */
- protected function getCarbonClassName(): string
- {
- return Carbon::class;
- }
-
- /**
- * @return string
- */
- public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform)
- {
- $precision = $fieldDeclaration['precision'] ?: 10;
-
- if ($fieldDeclaration['secondPrecision'] ?? false) {
- $precision = 0;
- }
-
- if ($precision === 10) {
- $precision = DateTimeDefaultPrecision::get();
- }
-
- $type = parent::getSQLDeclaration($fieldDeclaration, $platform);
-
- if (!$precision) {
- return $type;
- }
-
- if (str_contains($type, '(')) {
- return preg_replace('/\(\d+\)/', "($precision)", $type);
- }
-
- [$before, $after] = explode(' ', "$type ");
-
- return trim("$before($precision) $after");
- }
-
- /**
- * @SuppressWarnings(PHPMD.UnusedFormalParameter)
- *
- * @return T|null
- */
- public function convertToPHPValue($value, AbstractPlatform $platform)
- {
- $class = $this->getCarbonClassName();
-
- if ($value === null || is_a($value, $class)) {
- return $value;
- }
-
- if ($value instanceof DateTimeInterface) {
- return $class::instance($value);
- }
-
- $date = null;
- $error = null;
-
- try {
- $date = $class::parse($value);
- } catch (Exception $exception) {
- $error = $exception;
- }
-
- if (!$date) {
- throw ConversionException::conversionFailedFormat(
- $value,
- $this->getName(),
- 'Y-m-d H:i:s.u or any format supported by '.$class.'::parse()',
- $error
- );
- }
-
- return $date;
- }
-
- /**
- * @SuppressWarnings(PHPMD.UnusedFormalParameter)
- *
- * @return string|null
- */
- public function convertToDatabaseValue($value, AbstractPlatform $platform)
- {
- if ($value === null) {
- return $value;
- }
-
- if ($value instanceof DateTimeInterface) {
- return $value->format('Y-m-d H:i:s.u');
- }
-
- throw ConversionException::conversionFailedInvalidType(
- $value,
- $this->getName(),
- ['null', 'DateTime', 'Carbon']
- );
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeDefaultPrecision.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeDefaultPrecision.php
deleted file mode 100644
index 642fd41..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeDefaultPrecision.php
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-
-/**
- * This file is part of the Carbon package.
- *
- * (c) Brian Nesbitt <brian@nesbot.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-
-namespace Carbon\Doctrine;
-
-class DateTimeDefaultPrecision
-{
- private static $precision = 6;
-
- /**
- * Change the default Doctrine datetime and datetime_immutable precision.
- *
- * @param int $precision
- */
- public static function set(int $precision): void
- {
- self::$precision = $precision;
- }
-
- /**
- * Get the default Doctrine datetime and datetime_immutable precision.
- *
- * @return int
- */
- public static function get(): int
- {
- return self::$precision;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeImmutableType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeImmutableType.php
deleted file mode 100644
index 4992710..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeImmutableType.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-
-/**
- * Thanks to https://github.com/flaushi for his suggestion:
- * https://github.com/doctrine/dbal/issues/2873#issuecomment-534956358
- */
-namespace Carbon\Doctrine;
-
-use Carbon\CarbonImmutable;
-use Doctrine\DBAL\Types\VarDateTimeImmutableType;
-
-class DateTimeImmutableType extends VarDateTimeImmutableType implements CarbonDoctrineType
-{
- /** @use CarbonTypeConverter<CarbonImmutable> */
- use CarbonTypeConverter;
-
- /**
- * @return class-string<CarbonImmutable>
- */
- protected function getCarbonClassName(): string
- {
- return CarbonImmutable::class;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeType.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeType.php
deleted file mode 100644
index 29b0bb9..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Doctrine/DateTimeType.php
+++ /dev/null
@@ -1,16 +0,0 @@
-<?php
-
-/**
- * Thanks to https://github.com/flaushi for his suggestion:
- * https://github.com/doctrine/dbal/issues/2873#issuecomment-534956358
- */
-namespace Carbon\Doctrine;
-
-use Carbon\Carbon;
-use Doctrine\DBAL\Types\VarDateTimeType;
-
-class DateTimeType extends VarDateTimeType implements CarbonDoctrineType
-{
- /** @use CarbonTypeConverter<Carbon> */
- use CarbonTypeConverter;
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php
index b3a0871..3ca8837 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadComparisonUnitException.php
@@ -11,19 +11,38 @@
namespace Carbon\Exceptions;
-use Exception;
+use Throwable;
class BadComparisonUnitException extends UnitException
{
/**
+ * The unit.
+ *
+ * @var string
+ */
+ protected $unit;
+
+ /**
* Constructor.
*
* @param string $unit
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($unit, $code = 0, Exception $previous = null)
+ public function __construct($unit, $code = 0, Throwable $previous = null)
{
+ $this->unit = $unit;
+
parent::__construct("Bad comparison unit: '$unit'", $code, $previous);
}
+
+ /**
+ * Get the unit.
+ *
+ * @return string
+ */
+ public function getUnit(): string
+ {
+ return $this->unit;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php
index d5cd556..2e222e5 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentConstructorException.php
@@ -12,19 +12,38 @@
namespace Carbon\Exceptions;
use BadMethodCallException as BaseBadMethodCallException;
-use Exception;
+use Throwable;
class BadFluentConstructorException extends BaseBadMethodCallException implements BadMethodCallException
{
/**
+ * The method.
+ *
+ * @var string
+ */
+ protected $method;
+
+ /**
* Constructor.
*
* @param string $method
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($method, $code = 0, Exception $previous = null)
+ public function __construct($method, $code = 0, Throwable $previous = null)
{
+ $this->method = $method;
+
parent::__construct(sprintf("Unknown fluent constructor '%s'.", $method), $code, $previous);
}
+
+ /**
+ * Get the method.
+ *
+ * @return string
+ */
+ public function getMethod(): string
+ {
+ return $this->method;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php
index 1d7ec54..4ceaa2e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadFluentSetterException.php
@@ -12,19 +12,38 @@
namespace Carbon\Exceptions;
use BadMethodCallException as BaseBadMethodCallException;
-use Exception;
+use Throwable;
class BadFluentSetterException extends BaseBadMethodCallException implements BadMethodCallException
{
/**
+ * The setter.
+ *
+ * @var string
+ */
+ protected $setter;
+
+ /**
* Constructor.
*
- * @param string $method
+ * @param string $setter
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($method, $code = 0, Exception $previous = null)
+ public function __construct($setter, $code = 0, Throwable $previous = null)
{
- parent::__construct(sprintf("Unknown fluent setter '%s'", $method), $code, $previous);
+ $this->setter = $setter;
+
+ parent::__construct(sprintf("Unknown fluent setter '%s'", $setter), $code, $previous);
+ }
+
+ /**
+ * Get the setter.
+ *
+ * @return string
+ */
+ public function getSetter(): string
+ {
+ return $this->setter;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php
index 73c2dd8..108206d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/BadMethodCallException.php
@@ -13,4 +13,5 @@
interface BadMethodCallException extends Exception
{
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/EndLessPeriodException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/EndLessPeriodException.php
new file mode 100644
index 0000000..e104926
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/EndLessPeriodException.php
@@ -0,0 +1,19 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\Exceptions;
+
+use RuntimeException as BaseRuntimeException;
+
+final class EndLessPeriodException extends BaseRuntimeException implements RuntimeException
+{
+ //
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php
index 3bbbd77..8ad747e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/Exception.php
@@ -13,4 +13,5 @@
interface Exception
{
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php
index a48d4f9..db334c6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ImmutableException.php
@@ -11,20 +11,38 @@
namespace Carbon\Exceptions;
-use Exception;
use RuntimeException as BaseRuntimeException;
+use Throwable;
class ImmutableException extends BaseRuntimeException implements RuntimeException
{
/**
+ * The value.
+ *
+ * @var string
+ */
+ protected $value;
+
+ /**
* Constructor.
*
* @param string $value the immutable type/value
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($value, $code = 0, Exception $previous = null)
+ public function __construct($value, $code = 0, Throwable $previous = null)
{
+ $this->value = $value;
parent::__construct("$value is immutable.", $code, $previous);
}
+
+ /**
+ * Get the value.
+ *
+ * @return string
+ */
+ public function getValue(): string
+ {
+ return $this->value;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php
index 9739f4d..5b013cd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidArgumentException.php
@@ -13,4 +13,5 @@
interface InvalidArgumentException extends Exception
{
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php
index d2f3701..a421401 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidCastException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class InvalidCastException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php
index 99bb91c..c9ecb6b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidDateException.php
@@ -11,8 +11,8 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
+use Throwable;
class InvalidDateException extends BaseInvalidArgumentException implements InvalidArgumentException
{
@@ -36,9 +36,9 @@
* @param string $field
* @param mixed $value
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($field, $value, $code = 0, Exception $previous = null)
+ public function __construct($field, $value, $code = 0, Throwable $previous = null)
{
$this->field = $field;
$this->value = $value;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php
index 3341b49..92d55fe 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidFormatException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class InvalidFormatException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php
index 5f9f142..69cf412 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidIntervalException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class InvalidIntervalException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php
index a37e3f5..9bd84a9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodDateException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class InvalidPeriodDateException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php
index ede4771..cf2c902 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidPeriodParameterException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class InvalidPeriodParameterException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php
index 892e16e..f725955 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTimeZoneException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class InvalidTimeZoneException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php
index 3fbe3fc..2c8ec9b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/InvalidTypeException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class InvalidTypeException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php
index 2b4c48e..7a87632 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotACarbonClassException.php
@@ -12,24 +12,39 @@
namespace Carbon\Exceptions;
use Carbon\CarbonInterface;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
+use Throwable;
class NotACarbonClassException extends BaseInvalidArgumentException implements InvalidArgumentException
{
/**
+ * The className.
+ *
+ * @var string
+ */
+ protected $className;
+
+ /**
* Constructor.
*
* @param string $className
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($className, $code = 0, Exception $previous = null)
+ public function __construct($className, $code = 0, Throwable $previous = null)
{
- parent::__construct(sprintf(
- 'Given class does not implement %s: %s',
- CarbonInterface::class,
- $className
- ), $code, $previous);
+ $this->className = $className;
+
+ parent::__construct(sprintf('Given class does not implement %s: %s', CarbonInterface::class, $className), $code, $previous);
+ }
+
+ /**
+ * Get the className.
+ *
+ * @return string
+ */
+ public function getClassName(): string
+ {
+ return $this->className;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php
index 41bb629..4edd7a4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotAPeriodException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class NotAPeriodException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php
index adbc36c..f2c5468 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php
@@ -11,8 +11,8 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
+use Throwable;
class NotLocaleAwareException extends BaseInvalidArgumentException implements InvalidArgumentException
{
@@ -21,9 +21,9 @@
*
* @param mixed $object
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($object, $code = 0, Exception $previous = null)
+ public function __construct($object, $code = 0, Throwable $previous = null)
{
$dump = \is_object($object) ? \get_class($object) : \gettype($object);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php
index 54822d9..2c586d0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/OutOfRangeException.php
@@ -11,8 +11,8 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
+use Throwable;
// This will extends OutOfRangeException instead of InvalidArgumentException since 3.0.0
// use OutOfRangeException as BaseOutOfRangeException;
@@ -55,9 +55,9 @@
* @param mixed $max
* @param mixed $value
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($unit, $min, $max, $value, $code = 0, Exception $previous = null)
+ public function __construct($unit, $min, $max, $value, $code = 0, Throwable $previous = null)
{
$this->unit = $unit;
$this->min = $min;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php
index 0314c5d..5416fd1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/ParseErrorException.php
@@ -11,23 +11,78 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
+use Throwable;
class ParseErrorException extends BaseInvalidArgumentException implements InvalidArgumentException
{
/**
+ * The expected.
+ *
+ * @var string
+ */
+ protected $expected;
+
+ /**
+ * The actual.
+ *
+ * @var string
+ */
+ protected $actual;
+
+ /**
+ * The help message.
+ *
+ * @var string
+ */
+ protected $help;
+
+ /**
* Constructor.
*
* @param string $expected
* @param string $actual
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($expected, $actual, $help = '', $code = 0, Exception $previous = null)
+ public function __construct($expected, $actual, $help = '', $code = 0, Throwable $previous = null)
{
+ $this->expected = $expected;
+ $this->actual = $actual;
+ $this->help = $help;
+
$actual = $actual === '' ? 'data is missing' : "get '$actual'";
parent::__construct(trim("Format expected $expected but $actual\n$help"), $code, $previous);
}
+
+ /**
+ * Get the expected.
+ *
+ * @return string
+ */
+ public function getExpected(): string
+ {
+ return $this->expected;
+ }
+
+ /**
+ * Get the actual.
+ *
+ * @return string
+ */
+ public function getActual(): string
+ {
+ return $this->actual;
+ }
+
+ /**
+ * Get the help message.
+ *
+ * @return string
+ */
+ public function getHelp(): string
+ {
+ return $this->help;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php
index 24bf5a6..ad196f7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/RuntimeException.php
@@ -13,4 +13,5 @@
interface RuntimeException extends Exception
{
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php
index 8bd8653..ee99953 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
class UnitException extends BaseInvalidArgumentException implements InvalidArgumentException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php
index 39ee12c..0e72305 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnitNotConfiguredException.php
@@ -11,19 +11,38 @@
namespace Carbon\Exceptions;
-use Exception;
+use Throwable;
class UnitNotConfiguredException extends UnitException
{
/**
+ * The unit.
+ *
+ * @var string
+ */
+ protected $unit;
+
+ /**
* Constructor.
*
* @param string $unit
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($unit, $code = 0, Exception $previous = null)
+ public function __construct($unit, $code = 0, Throwable $previous = null)
{
+ $this->unit = $unit;
+
parent::__construct("Unit $unit have no configuration to get total from other units.", $code, $previous);
}
+
+ /**
+ * Get the unit.
+ *
+ * @return string
+ */
+ public function getUnit(): string
+ {
+ return $this->unit;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php
index 6c8c01b..5c50497 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownGetterException.php
@@ -11,20 +11,39 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
+use Throwable;
class UnknownGetterException extends BaseInvalidArgumentException implements InvalidArgumentException
{
/**
+ * The getter.
+ *
+ * @var string
+ */
+ protected $getter;
+
+ /**
* Constructor.
*
- * @param string $name getter name
+ * @param string $getter getter name
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($name, $code = 0, Exception $previous = null)
+ public function __construct($getter, $code = 0, Throwable $previous = null)
{
- parent::__construct("Unknown getter '$name'", $code, $previous);
+ $this->getter = $getter;
+
+ parent::__construct("Unknown getter '$getter'", $code, $previous);
+ }
+
+ /**
+ * Get the getter.
+ *
+ * @return string
+ */
+ public function getGetter(): string
+ {
+ return $this->getter;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php
index 901db98..75273a7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownMethodException.php
@@ -12,19 +12,38 @@
namespace Carbon\Exceptions;
use BadMethodCallException as BaseBadMethodCallException;
-use Exception;
+use Throwable;
class UnknownMethodException extends BaseBadMethodCallException implements BadMethodCallException
{
/**
+ * The method.
+ *
+ * @var string
+ */
+ protected $method;
+
+ /**
* Constructor.
*
* @param string $method
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($method, $code = 0, Exception $previous = null)
+ public function __construct($method, $code = 0, Throwable $previous = null)
{
+ $this->method = $method;
+
parent::__construct("Method $method does not exist.", $code, $previous);
}
+
+ /**
+ * Get the method.
+ *
+ * @return string
+ */
+ public function getMethod(): string
+ {
+ return $this->method;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php
index c9e9c9f..a795f5d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownSetterException.php
@@ -11,20 +11,39 @@
namespace Carbon\Exceptions;
-use Exception;
use InvalidArgumentException as BaseInvalidArgumentException;
+use Throwable;
class UnknownSetterException extends BaseInvalidArgumentException implements BadMethodCallException
{
/**
+ * The setter.
+ *
+ * @var string
+ */
+ protected $setter;
+
+ /**
* Constructor.
*
- * @param string $name setter name
+ * @param string $setter setter name
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($name, $code = 0, Exception $previous = null)
+ public function __construct($setter, $code = 0, Throwable $previous = null)
{
- parent::__construct("Unknown setter '$name'", $code, $previous);
+ $this->setter = $setter;
+
+ parent::__construct("Unknown setter '$setter'", $code, $previous);
+ }
+
+ /**
+ * Get the setter.
+ *
+ * @return string
+ */
+ public function getSetter(): string
+ {
+ return $this->setter;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php
index d965c82..ecd7f7a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnknownUnitException.php
@@ -11,19 +11,38 @@
namespace Carbon\Exceptions;
-use Exception;
+use Throwable;
class UnknownUnitException extends UnitException
{
/**
+ * The unit.
+ *
+ * @var string
+ */
+ protected $unit;
+
+ /**
* Constructor.
*
* @param string $unit
* @param int $code
- * @param Exception|null $previous
+ * @param Throwable|null $previous
*/
- public function __construct($unit, $code = 0, Exception $previous = null)
+ public function __construct($unit, $code = 0, Throwable $previous = null)
{
+ $this->unit = $unit;
+
parent::__construct("Unknown unit '$unit'.", $code, $previous);
}
+
+ /**
+ * Get the unit.
+ *
+ * @return string
+ */
+ public function getUnit(): string
+ {
+ return $this->unit;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php
index 6f8b39f..1654ab1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Exceptions/UnreachableException.php
@@ -11,20 +11,9 @@
namespace Carbon\Exceptions;
-use Exception;
use RuntimeException as BaseRuntimeException;
class UnreachableException extends BaseRuntimeException implements RuntimeException
{
- /**
- * Constructor.
- *
- * @param string $message
- * @param int $code
- * @param Exception|null $previous
- */
- public function __construct($message, $code = 0, Exception $previous = null)
- {
- parent::__construct($message, $code, $previous);
- }
+ //
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php
index f8c7289..d497535 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Factory.php
@@ -177,10 +177,10 @@
* parameter of null.
* /!\ Use this method for unit tests only.
* @method void setToStringFormat($format) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
- * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and
- * use other method or custom format passed to format() method if you need to dump an other string
+ * You should rather let Carbon object being cast to string with DEFAULT_TO_STRING_FORMAT, and
+ * use other method or custom format passed to format() method if you need to dump another string
* format.
- * Set the default format used when type juggling a Carbon instance to a string
+ * Set the default format used when type juggling a Carbon instance to a string.
* @method void setTranslator(TranslatorInterface $translator) Set the default translator instance to use.
* @method Carbon setUtf8($utf8) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
* You should rather use UTF-8 language packages on every machine.
@@ -231,7 +231,7 @@
* You should rather use the ->settings() method.
* Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants
* are available for quarters, years, decade, centuries, millennia (singular and plural forms).
- * @method mixed withTestNow($testNow = null, $callback = null) Temporarily sets a static date to be used within the callback.
+ * @method mixed withTestNow($testNow, $callback) Temporarily sets a static date to be used within the callback.
* Using setTestNow to set the date, executing the callback, then
* clearing the test instance.
* /!\ Use this method for unit tests only.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php
index 596ee80..d88a1cf 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/FactoryImmutable.php
@@ -12,6 +12,9 @@
namespace Carbon;
use Closure;
+use DateTimeImmutable;
+use DateTimeZone;
+use Psr\Clock\ClockInterface;
/**
* A factory to generate CarbonImmutable instances with common settings.
@@ -111,7 +114,6 @@
* @method CarbonImmutable maxValue() Create a Carbon instance for the greatest supported date.
* @method CarbonImmutable minValue() Create a Carbon instance for the lowest supported date.
* @method void mixin($mixin) Mix another object into the class.
- * @method CarbonImmutable now($tz = null) Get a Carbon instance for the current date and time.
* @method CarbonImmutable parse($time = null, $tz = null) Create a carbon instance from a string.
* This is an alias for the constructor that allows better fluent syntax
* as it allows you to do Carbon::parse('Monday next week')->fn() rather
@@ -175,10 +177,10 @@
* parameter of null.
* /!\ Use this method for unit tests only.
* @method void setToStringFormat($format) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
- * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and
- * use other method or custom format passed to format() method if you need to dump an other string
+ * You should rather let Carbon object being cast to string with DEFAULT_TO_STRING_FORMAT, and
+ * use other method or custom format passed to format() method if you need to dump another string
* format.
- * Set the default format used when type juggling a Carbon instance to a string
+ * Set the default format used when type juggling a Carbon instance to a string.
* @method void setTranslator(TranslatorInterface $translator) Set the default translator instance to use.
* @method CarbonImmutable setUtf8($utf8) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
* You should rather use UTF-8 language packages on every machine.
@@ -229,7 +231,7 @@
* You should rather use the ->settings() method.
* Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants
* are available for quarters, years, decade, centuries, millennia (singular and plural forms).
- * @method mixed withTestNow($testNow = null, $callback = null) Temporarily sets a static date to be used within the callback.
+ * @method mixed withTestNow($testNow, $callback) Temporarily sets a static date to be used within the callback.
* Using setTestNow to set the date, executing the callback, then
* clearing the test instance.
* /!\ Use this method for unit tests only.
@@ -237,7 +239,21 @@
*
* </autodoc>
*/
-class FactoryImmutable extends Factory
+class FactoryImmutable extends Factory implements ClockInterface
{
protected $className = CarbonImmutable::class;
+
+ /**
+ * Get a Carbon instance for the current date and time.
+ *
+ * @param DateTimeZone|string|int|null $tz
+ *
+ * @return CarbonImmutable
+ */
+ public function now($tz = null): DateTimeImmutable
+ {
+ $className = $this->className;
+
+ return new $className(null, $tz);
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_AE.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_AE.php
index 75fe47f..35a22b1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_AE.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_AE.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_BH.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_BH.php
index 362009e..3518096 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_BH.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_BH.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EG.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EG.php
index 362009e..3518096 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EG.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_EG.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IQ.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IQ.php
index 0ac0995..2d42008 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IQ.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_IQ.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_JO.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_JO.php
index 0ac0995..2d42008 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_JO.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_JO.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KW.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KW.php
index e6f0531..b3fb1cf 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KW.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_KW.php
@@ -16,6 +16,7 @@
* - JD Isaacks
* - Atef Ben Ali (atefBB)
* - Mohamed Sabil (mohamedsabil83)
+ * - Abdullah-Alhariri
*/
$months = [
'يناير',
@@ -90,4 +91,5 @@
],
'meridiem' => ['ص', 'م'],
'weekend' => [5, 6],
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_LB.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_LB.php
index 55bb10c..2792745 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_LB.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_LB.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_OM.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_OM.php
index 362009e..3518096 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_OM.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_OM.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php
index e790b99..503c60d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_PS.php
@@ -9,5 +9,10 @@
* file that was distributed with this source code.
*/
+/*
+ * Authors:
+ * - Abdullah-Alhariri
+ */
return array_replace_recursive(require __DIR__.'/ar.php', [
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_QA.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_QA.php
index 362009e..3518096 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_QA.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_QA.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SA.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SA.php
index 10aaa2e..550b0c7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SA.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SA.php
@@ -15,6 +15,7 @@
* - JD Isaacks
* - Atef Ben Ali (atefBB)
* - Mohamed Sabil (mohamedsabil83)
+ * - Abdullah-Alhariri
*/
$months = [
'يناير',
@@ -89,4 +90,5 @@
],
'meridiem' => ['ص', 'م'],
'weekend' => [5, 6],
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SD.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SD.php
index 362009e..3518096 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SD.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SD.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SY.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SY.php
index 0ac0995..2d42008 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SY.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_SY.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -24,4 +25,5 @@
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_YE.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_YE.php
index 5dc2938..169fe88 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_YE.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ar_YE.php
@@ -12,6 +12,7 @@
/*
* Authors:
* - IBM Globalization Center of Competency, Yamato Software Laboratory bug-glibc-locales@gnu.org
+ * - Abdullah-Alhariri
*/
return array_replace_recursive(require __DIR__.'/ar.php', [
'formats' => [
@@ -23,4 +24,5 @@
'weekdays_short' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
'day_of_first_week_of_year' => 1,
+ 'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰٤', '۰٥', '۰٦', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱٤', '۱٥', '۱٦', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲٤', '۲٥', '۲٦', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳٤', '۳٥', '۳٦', '۳۷', '۳۸', '۳۹', '٤۰', '٤۱', '٤۲', '٤۳', '٤٤', '٤٥', '٤٦', '٤۷', '٤۸', '٤۹', '٥۰', '٥۱', '٥۲', '٥۳', '٥٤', '٥٥', '٥٦', '٥۷', '٥۸', '٥۹', '٦۰', '٦۱', '٦۲', '٦۳', '٦٤', '٦٥', '٦٦', '٦۷', '٦۸', '٦۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷٤', '۷٥', '۷٦', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸٤', '۸٥', '۸٦', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹٤', '۹٥', '۹٦', '۹۷', '۹۸', '۹۹'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php
index 51b4d0c..ee73636 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/be.php
@@ -9,13 +9,12 @@
* file that was distributed with this source code.
*/
-// @codeCoverageIgnoreStart
-
use Carbon\CarbonInterface;
use Symfony\Component\Translation\PluralizationRules;
-if (class_exists('Symfony\\Component\\Translation\\PluralizationRules')) {
- PluralizationRules::set(function ($number) {
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
return (($number % 10 == 1) && ($number % 100 != 11)) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2);
}, 'be');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php
index 861acd2..1c16421 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ca_ES_Valencia.php
@@ -9,5 +9,15 @@
* file that was distributed with this source code.
*/
+use Symfony\Component\Translation\PluralizationRules;
+
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
+ return PluralizationRules::get($number, 'ca');
+ }, 'ca_ES_Valencia');
+}
+// @codeCoverageIgnoreEnd
+
return array_replace_recursive(require __DIR__.'/ca.php', [
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ckb.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ckb.php
new file mode 100644
index 0000000..acf4dc2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ckb.php
@@ -0,0 +1,89 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+/*
+ * Authors:
+ * - Swara Mohammed
+ */
+$months = [
+ 'ڕێبەندان',
+ 'ڕەشەمە',
+ 'نەورۆز',
+ 'گوڵان',
+ 'جۆزەردان',
+ 'پوشپەڕ',
+ 'گەلاوێژ',
+ 'خەرمانان',
+ 'ڕەزبەر',
+ 'گەڵاڕێزان',
+ 'سەرماوەرز',
+ 'بەفرانبار',
+];
+
+return [
+ 'year' => implode('|', ['{0}:count ساڵێک', '{1}ساڵێک', '{2}دوو ساڵ', ']2,11[:count ساڵ', ']10,Inf[:count ساڵ']),
+ 'a_year' => implode('|', ['{0}:count ساڵێک', '{1}ساڵێک', '{2}دوو ساڵ', ']2,11[:count ساڵ', ']10,Inf[:count ساڵ']),
+ 'month' => implode('|', ['{0}:count مانگێک', '{1}مانگێک', '{2}دوو مانگ', ']2,11[:count مانگ', ']10,Inf[:count مانگ']),
+ 'a_month' => implode('|', ['{0}:count مانگێک', '{1}مانگێک', '{2}دوو مانگ', ']2,11[:count مانگ', ']10,Inf[:count مانگ']),
+ 'week' => implode('|', ['{0}:count هەفتەیەک', '{1}هەفتەیەک', '{2}دوو هەفتە', ']2,11[:count هەفتە', ']10,Inf[:count هەفتە']),
+ 'a_week' => implode('|', ['{0}:count هەفتەیەک', '{1}هەفتەیەک', '{2}دوو هەفتە', ']2,11[:count هەفتە', ']10,Inf[:count هەفتە']),
+ 'day' => implode('|', ['{0}:count ڕۆژێک', '{1}ڕۆژێک', '{2}دوو ڕۆژ', ']2,11[:count ڕۆژ', ']10,Inf[:count ڕۆژ']),
+ 'a_day' => implode('|', ['{0}:count ڕۆژێک', '{1}ڕۆژێک', '{2}دوو ڕۆژ', ']2,11[:count ڕۆژ', ']10,Inf[:count ڕۆژ']),
+ 'hour' => implode('|', ['{0}:count کاتژمێرێک', '{1}کاتژمێرێک', '{2}دوو کاتژمێر', ']2,11[:count کاتژمێر', ']10,Inf[:count کاتژمێر']),
+ 'a_hour' => implode('|', ['{0}:count کاتژمێرێک', '{1}کاتژمێرێک', '{2}دوو کاتژمێر', ']2,11[:count کاتژمێر', ']10,Inf[:count کاتژمێر']),
+ 'minute' => implode('|', ['{0}:count خولەکێک', '{1}خولەکێک', '{2}دوو خولەک', ']2,11[:count خولەک', ']10,Inf[:count خولەک']),
+ 'a_minute' => implode('|', ['{0}:count خولەکێک', '{1}خولەکێک', '{2}دوو خولەک', ']2,11[:count خولەک', ']10,Inf[:count خولەک']),
+ 'second' => implode('|', ['{0}:count چرکەیەک', '{1}چرکەیەک', '{2}دوو چرکە', ']2,11[:count چرکە', ']10,Inf[:count چرکە']),
+ 'a_second' => implode('|', ['{0}:count چرکەیەک', '{1}چرکەیەک', '{2}دوو چرکە', ']2,11[:count چرکە', ']10,Inf[:count چرکە']),
+ 'ago' => 'پێش :time',
+ 'from_now' => ':time لە ئێستاوە',
+ 'after' => 'دوای :time',
+ 'before' => 'پێش :time',
+ 'diff_now' => 'ئێستا',
+ 'diff_today' => 'ئەمڕۆ',
+ 'diff_today_regexp' => 'ڕۆژ(?:\\s+لە)?(?:\\s+کاتژمێر)?',
+ 'diff_yesterday' => 'دوێنێ',
+ 'diff_yesterday_regexp' => 'دوێنێ(?:\\s+لە)?(?:\\s+کاتژمێر)?',
+ 'diff_tomorrow' => 'سبەینێ',
+ 'diff_tomorrow_regexp' => 'سبەینێ(?:\\s+لە)?(?:\\s+کاتژمێر)?',
+ 'diff_before_yesterday' => 'پێش دوێنێ',
+ 'diff_after_tomorrow' => 'دوای سبەینێ',
+ 'period_recurrences' => implode('|', ['{0}جار', '{1}جار', '{2}:count دووجار', ']2,11[:count جار', ']10,Inf[:count جار']),
+ 'period_interval' => 'هەموو :interval',
+ 'period_start_date' => 'لە :date',
+ 'period_end_date' => 'بۆ :date',
+ 'months' => $months,
+ 'months_short' => $months,
+ 'weekdays' => ['یەکشەممە', 'دووشەممە', 'سێشەممە', 'چوارشەممە', 'پێنجشەممە', 'هەینی', 'شەممە'],
+ 'weekdays_short' => ['یەکشەممە', 'دووشەممە', 'سێشەممە', 'چوارشەممە', 'پێنجشەممە', 'هەینی', 'شەممە'],
+ 'weekdays_min' => ['یەکشەممە', 'دووشەممە', 'سێشەممە', 'چوارشەممە', 'پێنجشەممە', 'هەینی', 'شەممە'],
+ 'list' => ['، ', ' و '],
+ 'first_day_of_week' => 6,
+ 'day_of_first_week_of_year' => 1,
+ 'formats' => [
+ 'LT' => 'HH:mm',
+ 'LTS' => 'HH:mm:ss',
+ 'L' => 'D/M/YYYY',
+ 'LL' => 'D MMMM YYYY',
+ 'LLL' => 'D MMMM YYYY HH:mm',
+ 'LLLL' => 'dddd D MMMM YYYY HH:mm',
+ ],
+ 'calendar' => [
+ 'sameDay' => '[ئەمڕۆ لە کاتژمێر] LT',
+ 'nextDay' => '[سبەینێ لە کاتژمێر] LT',
+ 'nextWeek' => 'dddd [لە کاتژمێر] LT',
+ 'lastDay' => '[دوێنێ لە کاتژمێر] LT',
+ 'lastWeek' => 'dddd [لە کاتژمێر] LT',
+ 'sameElse' => 'L',
+ ],
+ 'meridiem' => ['پ.ن', 'د.ن'],
+ 'weekend' => [5, 6],
+];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs.php
index 8cff9a0..c01e3cc 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cs.php
@@ -101,7 +101,8 @@
'after' => $za,
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 4,
- 'months' => ['leden', 'únor', 'březen', 'duben', 'květen', 'červen', 'červenec', 'srpen', 'září', 'říjen', 'listopad', 'prosinec'],
+ 'months' => ['ledna', 'února', 'března', 'dubna', 'května', 'června', 'července', 'srpna', 'září', 'října', 'listopadu', 'prosince'],
+ 'months_standalone' => ['leden', 'únor', 'březen', 'duben', 'květen', 'červen', 'červenec', 'srpen', 'září', 'říjen', 'listopad', 'prosinec'],
'months_short' => ['led', 'úno', 'bře', 'dub', 'kvě', 'čvn', 'čvc', 'srp', 'zář', 'říj', 'lis', 'pro'],
'weekdays' => ['neděle', 'pondělí', 'úterý', 'středa', 'čtvrtek', 'pátek', 'sobota'],
'weekdays_short' => ['ned', 'pon', 'úte', 'stř', 'čtv', 'pát', 'sob'],
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy.php
index ab7c45a..119274f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/cy.php
@@ -60,7 +60,7 @@
'ordinal' => function ($number) {
return $number.(
$number > 20
- ? (\in_array($number, [40, 50, 60, 80, 100]) ? 'fed' : 'ain')
+ ? (\in_array((int) $number, [40, 50, 60, 80, 100], true) ? 'fed' : 'ain')
: ([
'', 'af', 'il', 'ydd', 'ydd', 'ed', 'ed', 'ed', 'fed', 'fed', 'fed', // 1af to 10fed
'eg', 'fed', 'eg', 'eg', 'fed', 'eg', 'eg', 'fed', 'eg', 'fed', // 11eg to 20fed
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da.php
index 4e6640a..322f91d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/da.php
@@ -18,6 +18,7 @@
* - Jens Herlevsen
* - Ulrik McArdle (mcardle)
* - Frederik Sauer (FrittenKeeZ)
+ * - Janus Bahs Jacquet (kokoshneta)
*/
return [
'year' => ':count år|:count år',
@@ -41,7 +42,7 @@
'second' => ':count sekund|:count sekunder',
'a_second' => 'få sekunder|:count sekunder',
's' => ':count s.',
- 'ago' => ':time siden',
+ 'ago' => 'for :time siden',
'from_now' => 'om :time',
'after' => ':time efter',
'before' => ':time før',
@@ -70,9 +71,9 @@
],
'ordinal' => ':number.',
'months' => ['januar', 'februar', 'marts', 'april', 'maj', 'juni', 'juli', 'august', 'september', 'oktober', 'november', 'december'],
- 'months_short' => ['jan', 'feb', 'mar', 'apr', 'maj', 'jun', 'jul', 'aug', 'sep', 'okt', 'nov', 'dec'],
+ 'months_short' => ['jan.', 'feb.', 'mar.', 'apr.', 'maj.', 'jun.', 'jul.', 'aug.', 'sep.', 'okt.', 'nov.', 'dec.'],
'weekdays' => ['søndag', 'mandag', 'tirsdag', 'onsdag', 'torsdag', 'fredag', 'lørdag'],
- 'weekdays_short' => ['søn', 'man', 'tir', 'ons', 'tor', 'fre', 'lør'],
+ 'weekdays_short' => ['søn.', 'man.', 'tir.', 'ons.', 'tor.', 'fre.', 'lør.'],
'weekdays_min' => ['sø', 'ma', 'ti', 'on', 'to', 'fr', 'lø'],
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 4,
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de.php
index ff00c97..3b70750 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/de.php
@@ -105,4 +105,13 @@
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 4,
'list' => [', ', ' und '],
+ 'ordinal_words' => [
+ 'of' => 'im',
+ 'first' => 'erster',
+ 'second' => 'zweiter',
+ 'third' => 'dritter',
+ 'fourth' => 'vierten',
+ 'fifth' => 'fünfter',
+ 'last' => 'letzten',
+ ],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en.php
index a8633fe..f81f617 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en.php
@@ -72,7 +72,7 @@
$lastDigit = $number % 10;
return $number.(
- (~~($number % 100 / 10) === 1) ? 'th' : (
+ ((int) ($number % 100 / 10) === 1) ? 'th' : (
($lastDigit === 1) ? 'st' : (
($lastDigit === 2) ? 'nd' : (
($lastDigit === 3) ? 'rd' : 'th'
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php
index e2dd81d..10d9cd8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/en_CH.php
@@ -11,4 +11,12 @@
return array_replace_recursive(require __DIR__.'/en.php', [
'first_day_of_week' => 1,
+ 'formats' => [
+ 'LT' => 'HH:mm',
+ 'LTS' => 'HH:mm:ss',
+ 'L' => 'DD.MM.YYYY',
+ 'LL' => 'D MMMM YYYY',
+ 'LLL' => 'D MMMM YYYY HH:mm',
+ 'LLLL' => 'dddd D MMMM YYYY HH:mm',
+ ],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php
index f77ec39..1c4fcfd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/es.php
@@ -26,6 +26,7 @@
* - quinterocesar
* - Daniel Commesse Liévanos (danielcommesse)
* - Pete Scopes (pdscopes)
+ * - gam04
*/
use Carbon\CarbonInterface;
@@ -108,4 +109,13 @@
'day_of_first_week_of_year' => 4,
'list' => [', ', ' y '],
'meridiem' => ['a. m.', 'p. m.'],
+ 'ordinal_words' => [
+ 'of' => 'de',
+ 'first' => 'primer',
+ 'second' => 'segundo',
+ 'third' => 'tercer',
+ 'fourth' => 'cuarto',
+ 'fifth' => 'quinto',
+ 'last' => 'último',
+ ],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi.php
index 2003e1e..edf2d6d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fi.php
@@ -74,8 +74,10 @@
'LTS' => 'HH.mm:ss',
'L' => 'D.M.YYYY',
'LL' => 'dddd D. MMMM[ta] YYYY',
+ 'll' => 'ddd D. MMM YYYY',
'LLL' => 'D.MM. HH.mm',
'LLLL' => 'D. MMMM[ta] YYYY HH.mm',
+ 'llll' => 'D. MMM YY HH.mm',
],
'weekdays' => ['sunnuntai', 'maanantai', 'tiistai', 'keskiviikko', 'torstai', 'perjantai', 'lauantai'],
'weekdays_short' => ['su', 'ma', 'ti', 'ke', 'to', 'pe', 'la'],
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr.php
index 73fe5e4..f4c7247 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/fr.php
@@ -90,7 +90,7 @@
'weekdays_min' => ['di', 'lu', 'ma', 'me', 'je', 've', 'sa'],
'ordinal' => function ($number, $period) {
switch ($period) {
- // In french, only the first has be ordinal, other number remains cardinal
+ // In French, only the first has to be ordinal, other number remains cardinal
// @link https://fr.wikihow.com/%C3%A9crire-la-date-en-fran%C3%A7ais
case 'D':
return $number.($number === 1 ? 'er' : '');
@@ -111,4 +111,13 @@
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 4,
'list' => [', ', ' et '],
+ 'ordinal_words' => [
+ 'of' => 'de',
+ 'first' => 'premier',
+ 'second' => 'deuxième',
+ 'third' => 'troisième',
+ 'fourth' => 'quatrième',
+ 'fifth' => 'cinquième',
+ 'last' => 'dernier',
+ ],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php
index b2d2ac1..b7583ee 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/hu.php
@@ -82,7 +82,7 @@
'second_before' => ':count másodperccel',
's_before' => ':count másodperccel',
'months' => ['január', 'február', 'március', 'április', 'május', 'június', 'július', 'augusztus', 'szeptember', 'október', 'november', 'december'],
- 'months_short' => ['jan.', 'feb.', 'márc.', 'ápr.', 'máj.', 'jún.', 'júl.', 'aug.', 'szept.', 'okt.', 'nov.', 'dec.'],
+ 'months_short' => ['jan.', 'febr.', 'márc.', 'ápr.', 'máj.', 'jún.', 'júl.', 'aug.', 'szept.', 'okt.', 'nov.', 'dec.'],
'weekdays' => ['vasárnap', 'hétfő', 'kedd', 'szerda', 'csütörtök', 'péntek', 'szombat'],
'weekdays_short' => ['vas', 'hét', 'kedd', 'sze', 'csüt', 'pén', 'szo'],
'weekdays_min' => ['v', 'h', 'k', 'sze', 'cs', 'p', 'sz'],
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php
index 605bcbb..49875d7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/it.php
@@ -55,7 +55,7 @@
'µs' => ':countµs',
'ago' => ':time fa',
'from_now' => function ($time) {
- return (preg_match('/^[0-9].+$/', $time) ? 'tra' : 'in')." $time";
+ return (preg_match('/^\d.+$/', $time) ? 'tra' : 'in')." $time";
},
'after' => ':time dopo',
'before' => ':time prima',
@@ -103,4 +103,13 @@
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 4,
'list' => [', ', ' e '],
+ 'ordinal_words' => [
+ 'of' => 'di',
+ 'first' => 'primo',
+ 'second' => 'secondo',
+ 'third' => 'terzo',
+ 'fourth' => 'quarto',
+ 'fifth' => 'quinto',
+ 'last' => 'ultimo',
+ ],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku.php
index b001e30..189960c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ku.php
@@ -11,31 +11,29 @@
/*
* Authors:
- * - Halwest Manguri
- * - Kardo Qadir
+ * - Unicode, Inc.
*/
-$months = ['کانونی دووەم', 'شوبات', 'ئازار', 'نیسان', 'ئایار', 'حوزەیران', 'تەمموز', 'ئاب', 'ئەیلول', 'تشرینی یەکەم', 'تشرینی دووەم', 'کانونی یەکەم'];
-
-$weekdays = ['دوو شەممە', 'سێ شەممە', 'چوار شەممە', 'پێنج شەممە', 'هەینی', 'شەممە', 'یەک شەممە'];
return [
- 'ago' => 'پێش :time',
- 'from_now' => ':time لە ئێستاوە',
- 'after' => 'دوای :time',
- 'before' => 'پێش :time',
- 'year' => '{0}ساڵ|{1}ساڵێک|{2}٢ ساڵ|[3,10]:count ساڵ|[11,Inf]:count ساڵ',
- 'month' => '{0}مانگ|{1}مانگێک|{2}٢ مانگ|[3,10]:count مانگ|[11,Inf]:count مانگ',
- 'week' => '{0}هەفتە|{1}هەفتەیەک|{2}٢ هەفتە|[3,10]:count هەفتە|[11,Inf]:count هەفتە',
- 'day' => '{0}ڕۆژ|{1}ڕۆژێک|{2}٢ ڕۆژ|[3,10]:count ڕۆژ|[11,Inf]:count ڕۆژ',
- 'hour' => '{0}کاتژمێر|{1}کاتژمێرێک|{2}٢ کاتژمێر|[3,10]:count کاتژمێر|[11,Inf]:count کاتژمێر',
- 'minute' => '{0}خولەک|{1}خولەکێک|{2}٢ خولەک|[3,10]:count خولەک|[11,Inf]:count خولەک',
- 'second' => '{0}چرکە|{1}چرکەیەک|{2}٢ چرکە|[3,10]:count چرکە|[11,Inf]:count چرکە',
- 'months' => $months,
- 'months_standalone' => $months,
- 'months_short' => $months,
- 'weekdays' => $weekdays,
- 'weekdays_short' => $weekdays,
- 'weekdays_min' => $weekdays,
+ 'ago' => 'berî :time',
+ 'from_now' => 'di :time de',
+ 'after' => ':time piştî',
+ 'before' => ':time berê',
+ 'year' => ':count sal',
+ 'year_ago' => ':count salê|:count salan',
+ 'year_from_now' => 'salekê|:count salan',
+ 'month' => ':count meh',
+ 'week' => ':count hefte',
+ 'day' => ':count roj',
+ 'hour' => ':count saet',
+ 'minute' => ':count deqîqe',
+ 'second' => ':count saniye',
+ 'months' => ['rêbendanê', 'reşemiyê', 'adarê', 'avrêlê', 'gulanê', 'pûşperê', 'tîrmehê', 'gelawêjê', 'rezberê', 'kewçêrê', 'sermawezê', 'berfanbarê'],
+ 'months_standalone' => ['rêbendan', 'reşemî', 'adar', 'avrêl', 'gulan', 'pûşper', 'tîrmeh', 'gelawêj', 'rezber', 'kewçêr', 'sermawez', 'berfanbar'],
+ 'months_short' => ['rêb', 'reş', 'ada', 'avr', 'gul', 'pûş', 'tîr', 'gel', 'rez', 'kew', 'ser', 'ber'],
+ 'weekdays' => ['yekşem', 'duşem', 'sêşem', 'çarşem', 'pêncşem', 'în', 'şemî'],
+ 'weekdays_short' => ['yş', 'dş', 'sş', 'çş', 'pş', 'în', 'ş'],
+ 'weekdays_min' => ['Y', 'D', 'S', 'Ç', 'P', 'Î', 'Ş'],
'list' => [', ', ' û '],
'first_day_of_week' => 6,
'day_of_first_week_of_year' => 1,
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php
index 693eceb..d5cba7c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/lv.php
@@ -176,7 +176,8 @@
'weekdays' => $daysOfWeek,
'weekdays_short' => ['Sv.', 'P.', 'O.', 'T.', 'C.', 'Pk.', 'S.'],
'weekdays_min' => ['Sv.', 'P.', 'O.', 'T.', 'C.', 'Pk.', 'S.'],
- 'months' => ['janvārī', 'februārī', 'martā', 'aprīlī', 'maijā', 'jūnijā', 'jūlijā', 'augustā', 'septembrī', 'oktobrī', 'novembrī', 'decembrī'],
+ 'months' => ['janvāris', 'februāris', 'marts', 'aprīlis', 'maijs', 'jūnijs', 'jūlijs', 'augusts', 'septembris', 'oktobris', 'novembris', 'decembris'],
+ 'months_standalone' => ['janvārī', 'februārī', 'martā', 'aprīlī', 'maijā', 'jūnijā', 'jūlijā', 'augustā', 'septembrī', 'oktobrī', 'novembrī', 'decembrī'],
'months_short' => ['janv.', 'febr.', 'martā', 'apr.', 'maijā', 'jūn.', 'jūl.', 'aug.', 'sept.', 'okt.', 'nov.', 'dec.'],
'meridiem' => ['priekšpusdiena', 'pēcpusdiena'],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php
index 717d199..38c6434 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/mn.php
@@ -26,6 +26,7 @@
* - Nicolás Hock Isaza
* - Ochirkhuyag
* - Batmandakh
+ * - lucifer-crybaby
*/
return [
'year' => ':count жил',
@@ -43,38 +44,55 @@
'second' => ':count секунд',
's' => ':countс',
- 'ago' => ':timeн өмнө',
- 'year_ago' => ':count жилий',
- 'month_ago' => ':count сары',
- 'day_ago' => ':count хоногий',
- 'hour_ago' => ':count цагий',
- 'minute_ago' => ':count минуты',
- 'second_ago' => ':count секунды',
+ 'ago_mode' => 'last',
+ 'ago' => ':time өмнө',
+ 'year_ago' => ':count жилийн',
+ 'y_ago' => ':count жилийн',
+ 'month_ago' => ':count сарын',
+ 'm_ago' => ':count сарын',
+ 'day_ago' => ':count хоногийн',
+ 'd_ago' => ':count хоногийн',
+ 'week_ago' => ':count долоо хоногийн',
+ 'w_ago' => ':count долоо хоногийн',
+ 'hour_ago' => ':count цагийн',
+ 'minute_ago' => ':count минутын',
+ 'second_ago' => ':count секундын',
+ 'from_now_mode' => 'last',
'from_now' => 'одоогоос :time',
'year_from_now' => ':count жилийн дараа',
+ 'y_from_now' => ':count жилийн дараа',
'month_from_now' => ':count сарын дараа',
+ 'm_from_now' => ':count сарын дараа',
'day_from_now' => ':count хоногийн дараа',
+ 'd_from_now' => ':count хоногийн дараа',
'hour_from_now' => ':count цагийн дараа',
'minute_from_now' => ':count минутын дараа',
'second_from_now' => ':count секундын дараа',
- // Does it required to make translation for before, after as follows? hmm, I think we've made it with ago and from now keywords already. Anyway, I've included it just in case of undesired action...
- 'after' => ':timeн дараа',
- 'year_after' => ':count жилий',
- 'month_after' => ':count сары',
- 'day_after' => ':count хоногий',
- 'hour_after' => ':count цагий',
- 'minute_after' => ':count минуты',
- 'second_after' => ':count секунды',
+ 'after_mode' => 'last',
+ 'after' => ':time дараа',
+ 'year_after' => ':count жилийн',
+ 'y_after' => ':count жилийн',
+ 'month_after' => ':count сарын',
+ 'm_after' => ':count сарын',
+ 'day_after' => ':count хоногийн',
+ 'd_after' => ':count хоногийн',
+ 'hour_after' => ':count цагийн',
+ 'minute_after' => ':count минутын',
+ 'second_after' => ':count секундын',
- 'before' => ':timeн өмнө',
- 'year_before' => ':count жилий',
- 'month_before' => ':count сары',
- 'day_before' => ':count хоногий',
- 'hour_before' => ':count цагий',
- 'minute_before' => ':count минуты',
- 'second_before' => ':count секунды',
+ 'before_mode' => 'last',
+ 'before' => ':time өмнө',
+ 'year_before' => ':count жилийн',
+ 'y_before' => ':count жилийн',
+ 'month_before' => ':count сарын',
+ 'm_before' => ':count сарын',
+ 'day_before' => ':count хоногийн',
+ 'd_before' => ':count хоногийн',
+ 'hour_before' => ':count цагийн',
+ 'minute_before' => ':count минутын',
+ 'second_before' => ':count секундын',
'list' => ', ',
'diff_now' => 'одоо',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php
index 36934ee..c9e8085 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ms.php
@@ -48,7 +48,7 @@
'ago' => ':time yang lepas',
'from_now' => ':time dari sekarang',
'after' => ':time kemudian',
- 'before' => ':time lepas',
+ 'before' => ':time sebelum',
'diff_now' => 'sekarang',
'diff_today' => 'Hari',
'diff_today_regexp' => 'Hari(?:\\s+ini)?(?:\\s+pukul)?',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php
index 89693e6..c9411d6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/oc.php
@@ -17,7 +17,7 @@
use Symfony\Component\Translation\PluralizationRules;
if (class_exists('Symfony\\Component\\Translation\\PluralizationRules')) {
- PluralizationRules::set(function ($number) {
+ PluralizationRules::set(static function ($number) {
return $number == 1 ? 0 : 1;
}, 'oc');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php
index f0196c0..b720535 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pl.php
@@ -62,7 +62,7 @@
},
'after' => ':time po',
'before' => ':time przed',
- 'diff_now' => 'przed chwilą',
+ 'diff_now' => 'teraz',
'diff_today' => 'Dziś',
'diff_today_regexp' => 'Dziś(?:\\s+o)?',
'diff_yesterday' => 'wczoraj',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php
index 0af8949..bb6359b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/pt.php
@@ -104,4 +104,13 @@
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 4,
'list' => [', ', ' e '],
+ 'ordinal_words' => [
+ 'of' => 'de',
+ 'first' => 'primeira',
+ 'second' => 'segunda',
+ 'third' => 'terceira',
+ 'fourth' => 'quarta',
+ 'fifth' => 'quinta',
+ 'last' => 'última',
+ ],
];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php
index e4aa5a1..e03b506 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sh.php
@@ -13,7 +13,7 @@
use Symfony\Component\Translation\PluralizationRules;
if (class_exists('Symfony\\Component\\Translation\\PluralizationRules')) {
- PluralizationRules::set(function ($number) {
+ PluralizationRules::set(static function ($number) {
return (($number % 10 == 1) && ($number % 100 != 11)) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2);
}, 'sh');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk.php
index fd0f6b3..f9702e9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sk.php
@@ -31,33 +31,89 @@
* - jofi
* - Jakub ADAMEC
* - Marek Adamický
+ * - AlterwebStudio
*/
+
+use Carbon\CarbonInterface;
+
+$fromNow = function ($time) {
+ return 'o '.strtr($time, [
+ 'hodina' => 'hodinu',
+ 'minúta' => 'minútu',
+ 'sekunda' => 'sekundu',
+ ]);
+};
+
+$ago = function ($time) {
+ $replacements = [
+ '/\bhodina\b/' => 'hodinou',
+ '/\bminúta\b/' => 'minútou',
+ '/\bsekunda\b/' => 'sekundou',
+ '/\bdeň\b/u' => 'dňom',
+ '/\btýždeň\b/u' => 'týždňom',
+ '/\bmesiac\b/' => 'mesiacom',
+ '/\brok\b/' => 'rokom',
+ ];
+
+ $replacementsPlural = [
+ '/\bhodiny\b/' => 'hodinami',
+ '/\bminúty\b/' => 'minútami',
+ '/\bsekundy\b/' => 'sekundami',
+ '/\bdni\b/' => 'dňami',
+ '/\btýždne\b/' => 'týždňami',
+ '/\bmesiace\b/' => 'mesiacmi',
+ '/\broky\b/' => 'rokmi',
+ ];
+
+ foreach ($replacements + $replacementsPlural as $pattern => $replacement) {
+ $time = preg_replace($pattern, $replacement, $time);
+ }
+
+ return "pred $time";
+};
+
return [
- 'year' => 'rok|:count roky|:count rokov',
+ 'year' => ':count rok|:count roky|:count rokov',
+ 'a_year' => 'rok|:count roky|:count rokov',
'y' => ':count r',
- 'month' => 'mesiac|:count mesiace|:count mesiacov',
+ 'month' => ':count mesiac|:count mesiace|:count mesiacov',
+ 'a_month' => 'mesiac|:count mesiace|:count mesiacov',
'm' => ':count m',
- 'week' => 'týždeň|:count týždne|:count týždňov',
+ 'week' => ':count týždeň|:count týždne|:count týždňov',
+ 'a_week' => 'týždeň|:count týždne|:count týždňov',
'w' => ':count t',
- 'day' => 'deň|:count dni|:count dní',
+ 'day' => ':count deň|:count dni|:count dní',
+ 'a_day' => 'deň|:count dni|:count dní',
'd' => ':count d',
- 'hour' => 'hodinu|:count hodiny|:count hodín',
+ 'hour' => ':count hodina|:count hodiny|:count hodín',
+ 'a_hour' => 'hodina|:count hodiny|:count hodín',
'h' => ':count h',
- 'minute' => 'minútu|:count minúty|:count minút',
+ 'minute' => ':count minúta|:count minúty|:count minút',
+ 'a_minute' => 'minúta|:count minúty|:count minút',
'min' => ':count min',
- 'second' => 'sekundu|:count sekundy|:count sekúnd',
+ 'second' => ':count sekunda|:count sekundy|:count sekúnd',
+ 'a_second' => 'sekunda|:count sekundy|:count sekúnd',
's' => ':count s',
- 'ago' => 'pred :time',
- 'from_now' => 'za :time',
- 'after' => 'o :time neskôr',
- 'before' => ':time predtým',
- 'year_ago' => 'rokom|:count rokmi|:count rokmi',
- 'month_ago' => 'mesiacom|:count mesiacmi|:count mesiacmi',
- 'week_ago' => 'týždňom|:count týždňami|:count týždňami',
- 'day_ago' => 'dňom|:count dňami|:count dňami',
- 'hour_ago' => 'hodinou|:count hodinami|:count hodinami',
- 'minute_ago' => 'minútou|:count minútami|:count minútami',
- 'second_ago' => 'sekundou|:count sekundami|:count sekundami',
+ 'millisecond' => ':count milisekunda|:count milisekundy|:count milisekúnd',
+ 'a_millisecond' => 'milisekunda|:count milisekundy|:count milisekúnd',
+ 'ms' => ':count ms',
+ 'microsecond' => ':count mikrosekunda|:count mikrosekundy|:count mikrosekúnd',
+ 'a_microsecond' => 'mikrosekunda|:count mikrosekundy|:count mikrosekúnd',
+ 'µs' => ':count µs',
+
+ 'ago' => $ago,
+ 'from_now' => $fromNow,
+ 'before' => ':time pred',
+ 'after' => ':time po',
+
+ 'hour_after' => ':count hodinu|:count hodiny|:count hodín',
+ 'minute_after' => ':count minútu|:count minúty|:count minút',
+ 'second_after' => ':count sekundu|:count sekundy|:count sekúnd',
+
+ 'hour_before' => ':count hodinu|:count hodiny|:count hodín',
+ 'minute_before' => ':count minútu|:count minúty|:count minút',
+ 'second_before' => ':count sekundu|:count sekundy|:count sekúnd',
+
'first_day_of_week' => 1,
'day_of_first_week_of_year' => 4,
'list' => [', ', ' a '],
@@ -72,8 +128,26 @@
'LLL' => 'D. M. HH:mm',
'LLLL' => 'dddd D. MMMM YYYY HH:mm',
],
+ 'calendar' => [
+ 'sameDay' => '[dnes o] LT',
+ 'nextDay' => '[zajtra o] LT',
+ 'lastDay' => '[včera o] LT',
+ 'nextWeek' => 'dddd [o] LT',
+ 'lastWeek' => static function (CarbonInterface $date) {
+ switch ($date->dayOfWeek) {
+ case 1:
+ case 2:
+ case 4:
+ case 5:
+ return '[minulý] dddd [o] LT'; //pondelok/utorok/štvrtok/piatok
+ default:
+ return '[minulá] dddd [o] LT';
+ }
+ },
+ 'sameElse' => 'L',
+ ],
'weekdays' => ['nedeľa', 'pondelok', 'utorok', 'streda', 'štvrtok', 'piatok', 'sobota'],
- 'weekdays_short' => ['ne', 'po', 'ut', 'st', 'št', 'pi', 'so'],
+ 'weekdays_short' => ['ned', 'pon', 'uto', 'str', 'štv', 'pia', 'sob'],
'weekdays_min' => ['ne', 'po', 'ut', 'st', 'št', 'pi', 'so'],
'months' => ['január', 'február', 'marec', 'apríl', 'máj', 'jún', 'júl', 'august', 'september', 'október', 'november', 'december'],
'months_short' => ['jan', 'feb', 'mar', 'apr', 'máj', 'jún', 'júl', 'aug', 'sep', 'okt', 'nov', 'dec'],
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php
index 2e19721..1f1d1b3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sl.php
@@ -49,9 +49,9 @@
'a_second' => '{1}nekaj sekund|:count sekunda|:count sekundi|:count sekunde|:count sekund',
's' => ':count s',
- 'year_ago' => ':count letom|:count leti|:count leti|:count leti',
- 'y_ago' => ':count letom|:count leti|:count leti|:count leti',
- 'month_ago' => ':count mesecem|:count meseci|:count meseci|:count meseci',
+ 'year_ago' => ':count letom|:count letoma|:count leti|:count leti',
+ 'y_ago' => ':count letom|:count letoma|:count leti|:count leti',
+ 'month_ago' => ':count mesecem|:count mesecema|:count meseci|:count meseci',
'week_ago' => ':count tednom|:count tednoma|:count tedni|:count tedni',
'day_ago' => ':count dnem|:count dnevoma|:count dnevi|:count dnevi',
'd_ago' => ':count dnem|:count dnevoma|:count dnevi|:count dnevi',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php
index c09df19..8becbc5 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl.php
@@ -24,28 +24,28 @@
use Carbon\CarbonInterface;
return [
- 'year' => '{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година',
+ 'year' => ':count година|:count године|:count година',
'y' => ':count г.',
- 'month' => '{1}:count месец|{2,3,4}:count месеца|[0,Inf[:count месеци',
+ 'month' => ':count месец|:count месеца|:count месеци',
'm' => ':count м.',
- 'week' => '{1}:count недеља|{2,3,4}:count недеље|[0,Inf[:count недеља',
+ 'week' => ':count недеља|:count недеље|:count недеља',
'w' => ':count нед.',
- 'day' => '{1,21,31}:count дан|[0,Inf[:count дана',
+ 'day' => ':count дан|:count дана|:count дана',
'd' => ':count д.',
- 'hour' => '{1,21}:count сат|{2,3,4,22,23,24}:count сата|[0,Inf[:count сати',
+ 'hour' => ':count сат|:count сата|:count сати',
'h' => ':count ч.',
- 'minute' => '{1,21,31,41,51}:count минут|[0,Inf[:count минута',
+ 'minute' => ':count минут|:count минута|:count минута',
'min' => ':count мин.',
- 'second' => '{1,21,31,41,51}:count секунд|{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count секунде|[0,Inf[:count секунди',
+ 'second' => ':count секунд|:count секунде|:count секунди',
's' => ':count сек.',
'ago' => 'пре :time',
'from_now' => 'за :time',
'after' => ':time након',
'before' => ':time пре',
- 'year_from_now' => '{1,21,31,41,51}:count годину|{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година',
- 'year_ago' => '{1,21,31,41,51}:count годину|{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година',
- 'week_from_now' => '{1}:count недељу|{2,3,4}:count недеље|[0,Inf[:count недеља',
- 'week_ago' => '{1}:count недељу|{2,3,4}:count недеље|[0,Inf[:count недеља',
+ 'year_from_now' => ':count годину|:count године|:count година',
+ 'year_ago' => ':count годину|:count године|:count година',
+ 'week_from_now' => ':count недељу|:count недеље|:count недеља',
+ 'week_ago' => ':count недељу|:count недеље|:count недеља',
'diff_now' => 'управо сада',
'diff_today' => 'данас',
'diff_today_regexp' => 'данас(?:\\s+у)?',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php
index 0fb63d7..4b29a45 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_BA.php
@@ -9,6 +9,16 @@
* file that was distributed with this source code.
*/
+use Symfony\Component\Translation\PluralizationRules;
+
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
+ return PluralizationRules::get($number, 'sr');
+ }, 'sr_Cyrl_BA');
+}
+// @codeCoverageIgnoreEnd
+
return array_replace_recursive(require __DIR__.'/sr_Cyrl.php', [
'formats' => [
'LT' => 'HH:mm',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php
index d13229a..28d22fd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_ME.php
@@ -16,32 +16,41 @@
*/
use Carbon\CarbonInterface;
+use Symfony\Component\Translation\PluralizationRules;
+
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
+ return PluralizationRules::get($number, 'sr');
+ }, 'sr_Cyrl_ME');
+}
+// @codeCoverageIgnoreEnd
return [
- 'year' => '{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година',
+ 'year' => ':count година|:count године|:count година',
'y' => ':count г.',
- 'month' => '{1}:count мјесец|{2,3,4}:count мјесеца|[0,Inf[:count мјесеци',
+ 'month' => ':count мјесец|:count мјесеца|:count мјесеци',
'm' => ':count мј.',
- 'week' => '{1}:count недјеља|{2,3,4}:count недјеље|[0,Inf[:count недјеља',
+ 'week' => ':count недјеља|:count недјеље|:count недјеља',
'w' => ':count нед.',
- 'day' => '{1,21,31}:count дан|[0,Inf[:count дана',
+ 'day' => ':count дан|:count дана|:count дана',
'd' => ':count д.',
- 'hour' => '{1,21}:count сат|{2,3,4,22,23,24}:count сата|[0,Inf[:count сати',
+ 'hour' => ':count сат|:count сата|:count сати',
'h' => ':count ч.',
- 'minute' => '{1,21,31,41,51}:count минут|[0,Inf[:count минута',
+ 'minute' => ':count минут|:count минута|:count минута',
'min' => ':count мин.',
- 'second' => '{1,21,31,41,51}:count секунд|{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count секунде|[0,Inf[:count секунди',
+ 'second' => ':count секунд|:count секунде|:count секунди',
's' => ':count сек.',
'ago' => 'прије :time',
'from_now' => 'за :time',
'after' => ':time након',
'before' => ':time прије',
- 'year_from_now' => '{1,21,31,41,51}:count годину|{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година',
- 'year_ago' => '{1,21,31,41,51}:count годину|{2,3,4,22,23,24,32,33,34,42,43,44,52,53,54}:count године|[0,Inf[:count година',
+ 'year_from_now' => ':count годину|:count године|:count година',
+ 'year_ago' => ':count годину|:count године|:count година',
- 'week_from_now' => '{1}:count недјељу|{2,3,4}:count недјеље|[0,Inf[:count недјеља',
- 'week_ago' => '{1}:count недјељу|{2,3,4}:count недјеље|[0,Inf[:count недјеља',
+ 'week_from_now' => ':count недјељу|:count недјеље|:count недјеља',
+ 'week_ago' => ':count недјељу|:count недјеље|:count недјеља',
'diff_now' => 'управо сада',
'diff_today' => 'данас',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php
index 492baf0..d6e29b8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Cyrl_XK.php
@@ -9,6 +9,16 @@
* file that was distributed with this source code.
*/
+use Symfony\Component\Translation\PluralizationRules;
+
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
+ return PluralizationRules::get($number, 'sr');
+ }, 'sr_Cyrl_XK');
+}
+// @codeCoverageIgnoreEnd
+
return array_replace_recursive(require __DIR__.'/sr_Cyrl_BA.php', [
'weekdays' => ['недеља', 'понедељак', 'уторак', 'среда', 'четвртак', 'петак', 'субота'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php
index 897c674..95b2770 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_BA.php
@@ -9,6 +9,16 @@
* file that was distributed with this source code.
*/
+use Symfony\Component\Translation\PluralizationRules;
+
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
+ return PluralizationRules::get($number, 'sr');
+ }, 'sr_Latn_BA');
+}
+// @codeCoverageIgnoreEnd
+
return array_replace_recursive(require __DIR__.'/sr_Latn.php', [
'formats' => [
'LT' => 'HH:mm',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php
index e2133ef..5b8f2d0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_ME.php
@@ -16,6 +16,15 @@
*/
use Carbon\CarbonInterface;
+use Symfony\Component\Translation\PluralizationRules;
+
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
+ return PluralizationRules::get($number, 'sr');
+ }, 'sr_Latn_ME');
+}
+// @codeCoverageIgnoreEnd
return array_replace_recursive(require __DIR__.'/sr.php', [
'month' => ':count mjesec|:count mjeseca|:count mjeseci',
@@ -27,6 +36,7 @@
'before' => ':time prije',
'week_from_now' => ':count nedjelju|:count nedjelje|:count nedjelja',
'week_ago' => ':count nedjelju|:count nedjelje|:count nedjelja',
+ 'second_ago' => ':count sekund|:count sekunde|:count sekundi',
'diff_tomorrow' => 'sjutra',
'calendar' => [
'nextDay' => '[sjutra u] LT',
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php
index d0b9d10..5278e2e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sr_Latn_XK.php
@@ -9,6 +9,16 @@
* file that was distributed with this source code.
*/
+use Symfony\Component\Translation\PluralizationRules;
+
+// @codeCoverageIgnoreStart
+if (class_exists(PluralizationRules::class)) {
+ PluralizationRules::set(static function ($number) {
+ return PluralizationRules::get($number, 'sr');
+ }, 'sr_Latn_XK');
+}
+// @codeCoverageIgnoreEnd
+
return array_replace_recursive(require __DIR__.'/sr_Latn_BA.php', [
'weekdays' => ['nedelja', 'ponedeljak', 'utorak', 'sreda', 'četvrtak', 'petak', 'subota'],
]);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss.php
index cd4b919..1c52c9b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/ss.php
@@ -50,7 +50,7 @@
$lastDigit = $number % 10;
return $number.(
- (~~($number % 100 / 10) === 1) ? 'e' : (
+ ((int) ($number % 100 / 10) === 1) ? 'e' : (
($lastDigit === 1 || $lastDigit === 2) ? 'a' : 'e'
)
);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv.php
index ca33e1c..1706c71 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/sv.php
@@ -70,7 +70,7 @@
$lastDigit = $number % 10;
return $number.(
- (~~($number % 100 / 10) === 1) ? 'e' : (
+ ((int) ($number % 100 / 10) === 1) ? 'e' : (
($lastDigit === 1 || $lastDigit === 2) ? 'a' : 'e'
)
);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php
index b267b00..4217d16 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Lang/uk.php
@@ -55,7 +55,7 @@
*/
return [
'year' => ':count рік|:count роки|:count років',
- 'y' => ':countр',
+ 'y' => ':countр|:countрр|:countрр',
'a_year' => '{1}рік|:count рік|:count роки|:count років',
'month' => ':count місяць|:count місяці|:count місяців',
'm' => ':countм',
@@ -193,6 +193,7 @@
'genitive' => ['неділі', 'понеділка', 'вівторка', 'середи', 'четверга', 'п’ятниці', 'суботи'],
];
+ $format = $format ?? '';
$nounCase = preg_match('/(\[(В|в|У|у)\])\s+dddd/u', $format)
? 'accusative'
: (
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php
index 8be0569..84e241e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Laravel/ServiceProvider.php
@@ -24,6 +24,22 @@
class ServiceProvider extends \Illuminate\Support\ServiceProvider
{
+ /** @var callable|null */
+ protected $appGetter = null;
+
+ /** @var callable|null */
+ protected $localeGetter = null;
+
+ public function setAppGetter(?callable $appGetter): void
+ {
+ $this->appGetter = $appGetter;
+ }
+
+ public function setLocaleGetter(?callable $localeGetter): void
+ {
+ $this->localeGetter = $localeGetter;
+ }
+
public function boot()
{
$this->updateLocale();
@@ -44,8 +60,12 @@
public function updateLocale()
{
- $app = $this->app && method_exists($this->app, 'getLocale') ? $this->app : app('translator');
- $locale = $app->getLocale();
+ $locale = $this->getLocale();
+
+ if ($locale === null) {
+ return;
+ }
+
Carbon::setLocale($locale);
CarbonImmutable::setLocale($locale);
CarbonPeriod::setLocale($locale);
@@ -70,6 +90,34 @@
// Needed for Laravel < 5.3 compatibility
}
+ protected function getLocale()
+ {
+ if ($this->localeGetter) {
+ return ($this->localeGetter)();
+ }
+
+ $app = $this->getApp();
+ $app = $app && method_exists($app, 'getLocale')
+ ? $app
+ : $this->getGlobalApp('translator');
+
+ return $app ? $app->getLocale() : null;
+ }
+
+ protected function getApp()
+ {
+ if ($this->appGetter) {
+ return ($this->appGetter)();
+ }
+
+ return $this->app ?? $this->getGlobalApp();
+ }
+
+ protected function getGlobalApp(...$args)
+ {
+ return \function_exists('app') ? \app(...$args) : null;
+ }
+
protected function isEventDispatcher($instance)
{
return $instance instanceof EventDispatcher
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/MessageFormatter/MessageFormatterMapper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/MessageFormatter/MessageFormatterMapper.php
new file mode 100644
index 0000000..c054808
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/MessageFormatter/MessageFormatterMapper.php
@@ -0,0 +1,44 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\MessageFormatter;
+
+use ReflectionMethod;
+use Symfony\Component\Translation\Formatter\MessageFormatter;
+use Symfony\Component\Translation\Formatter\MessageFormatterInterface;
+
+// @codeCoverageIgnoreStart
+$transMethod = new ReflectionMethod(MessageFormatterInterface::class, 'format');
+
+require $transMethod->getParameters()[0]->hasType()
+ ? __DIR__.'/../../../lazy/Carbon/MessageFormatter/MessageFormatterMapperStrongType.php'
+ : __DIR__.'/../../../lazy/Carbon/MessageFormatter/MessageFormatterMapperWeakType.php';
+// @codeCoverageIgnoreEnd
+
+final class MessageFormatterMapper extends LazyMessageFormatter
+{
+ /**
+ * Wrapped formatter.
+ *
+ * @var MessageFormatterInterface
+ */
+ protected $formatter;
+
+ public function __construct(?MessageFormatterInterface $formatter = null)
+ {
+ $this->formatter = $formatter ?? new MessageFormatter();
+ }
+
+ protected function transformLocale(?string $locale): ?string
+ {
+ return $locale ? preg_replace('/[_@][A-Za-z][a-z]{2,}/', '', $locale) : $locale;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/AbstractMacro.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/AbstractMacro.php
index fc6fd2a..fde67b3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/AbstractMacro.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/AbstractMacro.php
@@ -14,6 +14,12 @@
namespace Carbon\PHPStan;
use Closure;
+use InvalidArgumentException;
+use PHPStan\BetterReflection\Reflection\Adapter\ReflectionParameter as AdapterReflectionParameter;
+use PHPStan\BetterReflection\Reflection\Adapter\ReflectionType as AdapterReflectionType;
+use PHPStan\BetterReflection\Reflection\ReflectionClass as BetterReflectionClass;
+use PHPStan\BetterReflection\Reflection\ReflectionFunction as BetterReflectionFunction;
+use PHPStan\BetterReflection\Reflection\ReflectionParameter as BetterReflectionParameter;
use PHPStan\Reflection\Php\BuiltinMethodReflection;
use PHPStan\TrinaryLogic;
use ReflectionClass;
@@ -64,24 +70,34 @@
/**
* Macro constructor.
*
- * @param string $className
- * @phpstan-param class-string $className
- *
- * @param string $methodName
- * @param callable $macro
+ * @param class-string $className
+ * @param string $methodName
+ * @param callable $macro
*/
public function __construct(string $className, string $methodName, $macro)
{
$this->className = $className;
$this->methodName = $methodName;
- $this->reflectionFunction = \is_array($macro)
+ $rawReflectionFunction = \is_array($macro)
? new ReflectionMethod($macro[0], $macro[1])
: new ReflectionFunction($macro);
- $this->parameters = $this->reflectionFunction->getParameters();
+ $this->reflectionFunction = self::hasModernParser()
+ ? $this->getReflectionFunction($macro)
+ : $rawReflectionFunction; // @codeCoverageIgnore
+ $this->parameters = array_map(
+ function ($parameter) {
+ if ($parameter instanceof BetterReflectionParameter) {
+ return new AdapterReflectionParameter($parameter);
+ }
- if ($this->reflectionFunction->isClosure()) {
+ return $parameter; // @codeCoverageIgnore
+ },
+ $this->reflectionFunction->getParameters()
+ );
+
+ if ($rawReflectionFunction->isClosure()) {
try {
- $closure = $this->reflectionFunction->getClosure();
+ $closure = $rawReflectionFunction->getClosure();
$boundClosure = Closure::bind($closure, new stdClass());
$this->static = (!$boundClosure || (new ReflectionFunction($boundClosure))->getClosureThis() === null);
} catch (Throwable $e) {
@@ -90,6 +106,31 @@
}
}
+ private function getReflectionFunction($spec)
+ {
+ if (\is_array($spec) && \count($spec) === 2 && \is_string($spec[1])) {
+ \assert($spec[1] !== '');
+
+ if (\is_object($spec[0])) {
+ return BetterReflectionClass::createFromInstance($spec[0])
+ ->getMethod($spec[1]);
+ }
+
+ return BetterReflectionClass::createFromName($spec[0])
+ ->getMethod($spec[1]);
+ }
+
+ if (\is_string($spec)) {
+ return BetterReflectionFunction::createFromName($spec);
+ }
+
+ if ($spec instanceof Closure) {
+ return BetterReflectionFunction::createFromClosure($spec);
+ }
+
+ throw new InvalidArgumentException('Could not create reflection from the spec given'); // @codeCoverageIgnore
+ }
+
/**
* {@inheritdoc}
*/
@@ -175,7 +216,13 @@
*/
public function getReturnType(): ?ReflectionType
{
- return $this->reflectionFunction->getReturnType();
+ $type = $this->reflectionFunction->getReturnType();
+
+ if ($type instanceof ReflectionType) {
+ return $type; // @codeCoverageIgnore
+ }
+
+ return self::adaptType($type);
}
/**
@@ -205,18 +252,35 @@
return $this;
}
- /**
- * {@inheritdoc}
- */
- public function getReflection(): ?ReflectionMethod
- {
- return $this->reflectionFunction instanceof ReflectionMethod
- ? $this->reflectionFunction
- : null;
- }
-
public function getTentativeReturnType(): ?ReflectionType
{
return null;
}
+
+ public function returnsByReference(): TrinaryLogic
+ {
+ return TrinaryLogic::createNo();
+ }
+
+ private static function adaptType($type)
+ {
+ $method = method_exists(AdapterReflectionType::class, 'fromTypeOrNull')
+ ? 'fromTypeOrNull'
+ : 'fromReturnTypeOrNull'; // @codeCoverageIgnore
+
+ return AdapterReflectionType::$method($type);
+ }
+
+ private static function hasModernParser(): bool
+ {
+ static $modernParser = null;
+
+ if ($modernParser !== null) {
+ return $modernParser;
+ }
+
+ $modernParser = method_exists(AdapterReflectionType::class, 'fromTypeOrNull');
+
+ return $modernParser;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php
index 8392587..de3e51f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/Macro.php
@@ -13,9 +13,16 @@
namespace Carbon\PHPStan;
+use PHPStan\BetterReflection\Reflection\Adapter;
use PHPStan\Reflection\Php\BuiltinMethodReflection;
use ReflectionMethod;
+$method = new ReflectionMethod(BuiltinMethodReflection::class, 'getReflection');
+
+require $method->hasReturnType() && $method->getReturnType()->getName() === Adapter\ReflectionMethod::class
+ ? __DIR__.'/../../../lazy/Carbon/PHPStan/AbstractMacroStatic.php'
+ : __DIR__.'/../../../lazy/Carbon/PHPStan/AbstractMacroBuiltin.php';
+
$method = new ReflectionMethod(BuiltinMethodReflection::class, 'getFileName');
require $method->hasReturnType()
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php
index 8e2524c..2cd6fce 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroExtension.php
@@ -11,10 +11,12 @@
namespace Carbon\PHPStan;
+use PHPStan\Reflection\Assertions;
use PHPStan\Reflection\ClassReflection;
use PHPStan\Reflection\MethodReflection;
use PHPStan\Reflection\MethodsClassReflectionExtension;
use PHPStan\Reflection\Php\PhpMethodReflectionFactory;
+use PHPStan\Reflection\ReflectionProvider;
use PHPStan\Type\TypehintHelper;
/**
@@ -38,10 +40,13 @@
* Extension constructor.
*
* @param PhpMethodReflectionFactory $methodReflectionFactory
+ * @param ReflectionProvider $reflectionProvider
*/
- public function __construct(PhpMethodReflectionFactory $methodReflectionFactory)
- {
- $this->scanner = new MacroScanner();
+ public function __construct(
+ PhpMethodReflectionFactory $methodReflectionFactory,
+ ReflectionProvider $reflectionProvider
+ ) {
+ $this->scanner = new MacroScanner($reflectionProvider);
$this->methodReflectionFactory = $methodReflectionFactory;
}
@@ -59,6 +64,7 @@
public function getMethod(ClassReflection $classReflection, string $methodName): MethodReflection
{
$builtinMacro = $this->scanner->getMethod($classReflection->getName(), $methodName);
+ $supportAssertions = class_exists(Assertions::class);
return $this->methodReflectionFactory->create(
$classReflection,
@@ -72,7 +78,11 @@
$builtinMacro->isDeprecated()->yes(),
$builtinMacro->isInternal(),
$builtinMacro->isFinal(),
- $builtinMacro->getDocComment()
+ $supportAssertions ? null : $builtinMacro->getDocComment(),
+ $supportAssertions ? Assertions::createEmpty() : null,
+ null,
+ $builtinMacro->getDocComment(),
+ []
);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php
index d169939..eb8957d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/PHPStan/MacroScanner.php
@@ -12,35 +12,55 @@
namespace Carbon\PHPStan;
use Carbon\CarbonInterface;
+use PHPStan\Reflection\ReflectionProvider;
use ReflectionClass;
use ReflectionException;
final class MacroScanner
{
/**
+ * @var \PHPStan\Reflection\ReflectionProvider
+ */
+ private $reflectionProvider;
+
+ /**
+ * MacroScanner constructor.
+ *
+ * @param \PHPStan\Reflection\ReflectionProvider $reflectionProvider
+ */
+ public function __construct(ReflectionProvider $reflectionProvider)
+ {
+ $this->reflectionProvider = $reflectionProvider;
+ }
+
+ /**
* Return true if the given pair class-method is a Carbon macro.
*
- * @param string $className
- * @phpstan-param class-string $className
- *
- * @param string $methodName
+ * @param class-string $className
+ * @param string $methodName
*
* @return bool
*/
public function hasMethod(string $className, string $methodName): bool
{
- return is_a($className, CarbonInterface::class, true) &&
- \is_callable([$className, 'hasMacro']) &&
+ $classReflection = $this->reflectionProvider->getClass($className);
+
+ if (
+ $classReflection->getName() !== CarbonInterface::class &&
+ !$classReflection->isSubclassOf(CarbonInterface::class)
+ ) {
+ return false;
+ }
+
+ return \is_callable([$className, 'hasMacro']) &&
$className::hasMacro($methodName);
}
/**
* Return the Macro for a given pair class-method.
*
- * @param string $className
- * @phpstan-param class-string $className
- *
- * @param string $methodName
+ * @param class-string $className
+ * @param string $methodName
*
* @throws ReflectionException
*
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php
index a23e6ed..f6261d8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Comparison.php
@@ -75,6 +75,9 @@
*/
public function equalTo($date): bool
{
+ $this->discourageNull($date);
+ $this->discourageBoolean($date);
+
return $this == $this->resolveCarbon($date);
}
@@ -155,6 +158,9 @@
*/
public function greaterThan($date): bool
{
+ $this->discourageNull($date);
+ $this->discourageBoolean($date);
+
return $this > $this->resolveCarbon($date);
}
@@ -216,7 +222,10 @@
*/
public function greaterThanOrEqualTo($date): bool
{
- return $this >= $date;
+ $this->discourageNull($date);
+ $this->discourageBoolean($date);
+
+ return $this >= $this->resolveCarbon($date);
}
/**
@@ -256,6 +265,9 @@
*/
public function lessThan($date): bool
{
+ $this->discourageNull($date);
+ $this->discourageBoolean($date);
+
return $this < $this->resolveCarbon($date);
}
@@ -317,7 +329,10 @@
*/
public function lessThanOrEqualTo($date): bool
{
- return $this <= $date;
+ $this->discourageNull($date);
+ $this->discourageBoolean($date);
+
+ return $this <= $this->resolveCarbon($date);
}
/**
@@ -351,10 +366,10 @@
}
if ($equal) {
- return $this->greaterThanOrEqualTo($date1) && $this->lessThanOrEqualTo($date2);
+ return $this >= $date1 && $this <= $date2;
}
- return $this->greaterThan($date1) && $this->lessThan($date2);
+ return $this > $date1 && $this < $date2;
}
/**
@@ -448,7 +463,7 @@
*/
public function isWeekend()
{
- return \in_array($this->dayOfWeek, static::$weekendDays);
+ return \in_array($this->dayOfWeek, static::$weekendDays, true);
}
/**
@@ -548,12 +563,17 @@
}
/**
- * Determines if the instance is a long year
+ * Determines if the instance is a long year (using calendar year).
+ *
+ * ⚠️ This method completely ignores month and day to use the numeric year number,
+ * it's not correct if the exact date matters. For instance as `2019-12-30` is already
+ * in the first week of the 2020 year, if you want to know from this date if ISO week
+ * year 2020 is a long year, use `isLongIsoYear` instead.
*
* @example
* ```
- * Carbon::parse('2015-01-01')->isLongYear(); // true
- * Carbon::parse('2016-01-01')->isLongYear(); // false
+ * Carbon::create(2015)->isLongYear(); // true
+ * Carbon::create(2016)->isLongYear(); // false
* ```
*
* @see https://en.wikipedia.org/wiki/ISO_8601#Week_dates
@@ -566,6 +586,27 @@
}
/**
+ * Determines if the instance is a long year (using ISO 8601 year).
+ *
+ * @example
+ * ```
+ * Carbon::parse('2015-01-01')->isLongIsoYear(); // true
+ * Carbon::parse('2016-01-01')->isLongIsoYear(); // true
+ * Carbon::parse('2016-01-03')->isLongIsoYear(); // false
+ * Carbon::parse('2019-12-29')->isLongIsoYear(); // false
+ * Carbon::parse('2019-12-30')->isLongIsoYear(); // true
+ * ```
+ *
+ * @see https://en.wikipedia.org/wiki/ISO_8601#Week_dates
+ *
+ * @return bool
+ */
+ public function isLongIsoYear()
+ {
+ return static::create($this->isoWeekYear, 12, 28, 0, 0, 0, $this->tz)->weekOfYear === 53;
+ }
+
+ /**
* Compares the formatted values of the two dates.
*
* @example
@@ -621,19 +662,19 @@
'microsecond' => 'Y-m-d H:i:s.u',
];
- if (!isset($units[$unit])) {
- if (isset($this->$unit)) {
- return $this->resolveCarbon($date)->$unit === $this->$unit;
- }
-
- if ($this->localStrictModeEnabled ?? static::isStrictModeEnabled()) {
- throw new BadComparisonUnitException($unit);
- }
-
- return false;
+ if (isset($units[$unit])) {
+ return $this->isSameAs($units[$unit], $date);
}
- return $this->isSameAs($units[$unit], $date);
+ if (isset($this->$unit)) {
+ return $this->resolveCarbon($date)->$unit === $this->$unit;
+ }
+
+ if ($this->localStrictModeEnabled ?? static::isStrictModeEnabled()) {
+ throw new BadComparisonUnitException($unit);
+ }
+
+ return false;
}
/**
@@ -981,12 +1022,12 @@
return $current->startOfMinute()->eq($other);
}
- if (preg_match('/\d(h|am|pm)$/', $tester)) {
+ if (preg_match('/\d(?:h|am|pm)$/', $tester)) {
return $current->startOfHour()->eq($other);
}
if (preg_match(
- '/^(january|february|march|april|may|june|july|august|september|october|november|december)\s+\d+$/i',
+ '/^(?:january|february|march|april|may|june|july|august|september|october|november|december)(?:\s+\d+)?$/i',
$tester
)) {
return $current->startOfMonth()->eq($other->startOfMonth());
@@ -1067,4 +1108,18 @@
{
return $this->endOfTime ?? false;
}
+
+ private function discourageNull($value): void
+ {
+ if ($value === null) {
+ @trigger_error("Since 2.61.0, it's deprecated to compare a date to null, meaning of such comparison is ambiguous and will no longer be possible in 3.0.0, you should explicitly pass 'now' or make an other check to eliminate null values.", \E_USER_DEPRECATED);
+ }
+ }
+
+ private function discourageBoolean($value): void
+ {
+ if (\is_bool($value)) {
+ @trigger_error("Since 2.61.0, it's deprecated to compare a date to true or false, meaning of such comparison is ambiguous and will no longer be possible in 3.0.0, you should explicitly pass 'now' or make an other check to eliminate boolean values.", \E_USER_DEPRECATED);
+ }
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php
index 8fe008a..fff8a60 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Converter.php
@@ -16,6 +16,7 @@
use Carbon\CarbonInterface;
use Carbon\CarbonInterval;
use Carbon\CarbonPeriod;
+use Carbon\CarbonPeriodImmutable;
use Carbon\Exceptions\UnitException;
use Closure;
use DateTime;
@@ -34,39 +35,7 @@
*/
trait Converter
{
- /**
- * Format to use for __toString method when type juggling occurs.
- *
- * @var string|Closure|null
- */
- protected static $toStringFormat;
-
- /**
- * Reset the format used to the default when type juggling a Carbon instance to a string
- *
- * @return void
- */
- public static function resetToStringFormat()
- {
- static::setToStringFormat(null);
- }
-
- /**
- * @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
- * You should rather let Carbon object being casted to string with DEFAULT_TO_STRING_FORMAT, and
- * use other method or custom format passed to format() method if you need to dump an other string
- * format.
- *
- * Set the default format used when type juggling a Carbon instance to a string
- *
- * @param string|Closure|null $format
- *
- * @return void
- */
- public static function setToStringFormat($format)
- {
- static::$toStringFormat = $format;
- }
+ use ToStringFormat;
/**
* Returns the formatted date string on success or FALSE on failure.
@@ -110,7 +79,7 @@
*
* @example
* ```
- * echo Carbon::now(); // Carbon instances can be casted to string
+ * echo Carbon::now(); // Carbon instances can be cast to string
* ```
*
* @return string
@@ -159,6 +128,21 @@
}
/**
+ * Format the instance with the day, and a readable date
+ *
+ * @example
+ * ```
+ * echo Carbon::now()->toFormattedDayDateString();
+ * ```
+ *
+ * @return string
+ */
+ public function toFormattedDayDateString(): string
+ {
+ return $this->rawFormat('D, M j, Y');
+ }
+
+ /**
* Format the instance as time
*
* @example
@@ -622,16 +606,18 @@
$interval = CarbonInterval::make("$interval ".static::pluralUnit($unit));
}
- $period = (new CarbonPeriod())->setDateClass(static::class)->setStartDate($this);
+ $period = ($this->isMutable() ? new CarbonPeriod() : new CarbonPeriodImmutable())
+ ->setDateClass(static::class)
+ ->setStartDate($this);
if ($interval) {
- $period->setDateInterval($interval);
+ $period = $period->setDateInterval($interval);
}
- if (\is_int($end) || \is_string($end) && ctype_digit($end)) {
- $period->setRecurrences($end);
+ if (\is_int($end) || (\is_string($end) && ctype_digit($end))) {
+ $period = $period->setRecurrences($end);
} elseif ($end) {
- $period->setEndDate($end);
+ $period = $period->setEndDate($end);
}
return $period;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php
index f2adee5..0d611ea 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Creator.php
@@ -19,6 +19,8 @@
use Carbon\Exceptions\OutOfRangeException;
use Carbon\Translator;
use Closure;
+use DateMalformedStringException;
+use DateTimeImmutable;
use DateTimeInterface;
use DateTimeZone;
use Exception;
@@ -79,8 +81,8 @@
// Work-around for PHP bug https://bugs.php.net/bug.php?id=67127
if (!str_contains((string) .1, '.')) {
- $locale = setlocale(LC_NUMERIC, '0');
- setlocale(LC_NUMERIC, 'C');
+ $locale = setlocale(LC_NUMERIC, '0'); // @codeCoverageIgnore
+ setlocale(LC_NUMERIC, 'C'); // @codeCoverageIgnore
}
try {
@@ -92,7 +94,7 @@
$this->constructedObjectId = spl_object_hash($this);
if (isset($locale)) {
- setlocale(LC_NUMERIC, $locale);
+ setlocale(LC_NUMERIC, $locale); // @codeCoverageIgnore
}
self::setLastErrors(parent::getLastErrors());
@@ -112,7 +114,7 @@
$safeTz = static::safeCreateDateTimeZone($tz);
if ($safeTz) {
- return $date->setTimezone($safeTz);
+ return ($date instanceof DateTimeImmutable ? $date : clone $date)->setTimezone($safeTz);
}
return $date;
@@ -148,7 +150,7 @@
$instance = new static($date->format('Y-m-d H:i:s.u'), $date->getTimezone());
- if ($date instanceof CarbonInterface || $date instanceof Options) {
+ if ($date instanceof CarbonInterface) {
$settings = $date->getSettings();
if (!$date->hasLocalTranslator()) {
@@ -184,7 +186,13 @@
try {
return new static($time, $tz);
} catch (Exception $exception) {
- $date = @static::now($tz)->change($time);
+ // @codeCoverageIgnoreStart
+ try {
+ $date = @static::now($tz)->change($time);
+ } catch (DateMalformedStringException $ignoredException) {
+ $date = null;
+ }
+ // @codeCoverageIgnoreEnd
if (!$date) {
throw new InvalidFormatException("Could not parse '$time': ".$exception->getMessage(), 0, $exception);
@@ -354,13 +362,13 @@
* If $hour is not null then the default values for $minute and $second
* will be 0.
*
- * @param int|null $year
- * @param int|null $month
- * @param int|null $day
- * @param int|null $hour
- * @param int|null $minute
- * @param int|null $second
- * @param DateTimeZone|string|null $tz
+ * @param DateTimeInterface|int|null $year
+ * @param int|null $month
+ * @param int|null $day
+ * @param int|null $hour
+ * @param int|null $minute
+ * @param int|null $second
+ * @param DateTimeZone|string|null $tz
*
* @throws InvalidFormatException
*
@@ -368,7 +376,7 @@
*/
public static function create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $tz = null)
{
- if (\is_string($year) && !is_numeric($year) || $year instanceof DateTimeInterface) {
+ if ((\is_string($year) && !is_numeric($year)) || $year instanceof DateTimeInterface) {
return static::parse($year, $tz ?: (\is_string($month) || $month instanceof DateTimeZone ? $month : null));
}
@@ -634,6 +642,10 @@
$time = preg_replace('/^(.*)(am|pm|AM|PM)(.*)$/U', '$1$3 $2', $time);
}
+ if ($tz === false) {
+ $tz = null;
+ }
+
// First attempt to create an instance, so that error messages are based on the unmodified format.
$date = self::createFromFormatAndTimezone($format, $time, $tz);
$lastErrors = parent::getLastErrors();
@@ -651,12 +663,14 @@
$tz = clone $mock->getTimezone();
}
- // Set microseconds to zero to match behavior of DateTime::createFromFormat()
- // See https://bugs.php.net/bug.php?id=74332
- $mock = $mock->copy()->microsecond(0);
+ $mock = $mock->copy();
// Prepend mock datetime only if the format does not contain non escaped unix epoch reset flag.
if (!preg_match("/{$nonEscaped}[!|]/", $format)) {
+ if (preg_match('/[HhGgisvuB]/', $format)) {
+ $mock = $mock->setTime(0, 0);
+ }
+
$format = static::MOCK_DATETIME_FORMAT.' '.$format;
$time = ($mock instanceof self ? $mock->rawFormat(static::MOCK_DATETIME_FORMAT) : $mock->format(static::MOCK_DATETIME_FORMAT)).' '.$time;
}
@@ -862,6 +876,19 @@
*/
public static function createFromLocaleFormat($format, $locale, $time, $tz = null)
{
+ $format = preg_replace_callback(
+ '/(?:\\\\[a-zA-Z]|[bfkqCEJKQRV]){2,}/',
+ static function (array $match) use ($locale): string {
+ $word = str_replace('\\', '', $match[0]);
+ $translatedWord = static::translateTimeString($word, $locale, 'en');
+
+ return $word === $translatedWord
+ ? $match[0]
+ : preg_replace('/[a-zA-Z]/', '\\\\$0', $translatedWord);
+ },
+ $format
+ );
+
return static::rawCreateFromFormat($format, static::translateTimeString($time, $locale, 'en'), $tz);
}
@@ -907,9 +934,9 @@
if (\is_string($var)) {
$var = trim($var);
- if (!preg_match('/^P[0-9T]/', $var) &&
- !preg_match('/^R[0-9]/', $var) &&
- preg_match('/[a-z0-9]/i', $var)
+ if (!preg_match('/^P[\dT]/', $var) &&
+ !preg_match('/^R\d/', $var) &&
+ preg_match('/[a-z\d]/i', $var)
) {
$date = static::parse($var);
}
@@ -921,13 +948,20 @@
/**
* Set last errors.
*
- * @param array $lastErrors
+ * @param array|bool $lastErrors
*
* @return void
*/
- private static function setLastErrors(array $lastErrors)
+ private static function setLastErrors($lastErrors)
{
- static::$lastErrors = $lastErrors;
+ if (\is_array($lastErrors) || $lastErrors === false) {
+ static::$lastErrors = \is_array($lastErrors) ? $lastErrors : [
+ 'warning_count' => 0,
+ 'warnings' => [],
+ 'error_count' => 0,
+ 'errors' => [],
+ ];
+ }
}
/**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php
index 8c8af6f..8ae5c17 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Date.php
@@ -532,6 +532,7 @@
use Creator;
use Difference;
use Macro;
+ use MagicParameter;
use Modifiers;
use Mutability;
use ObjectInitialisation;
@@ -641,9 +642,11 @@
/**
* List of minimum and maximums for each unit.
*
+ * @param int $daysInMonth
+ *
* @return array
*/
- protected static function getRangesByUnit()
+ protected static function getRangesByUnit(int $daysInMonth = 31): array
{
return [
// @call roundUnit
@@ -651,7 +654,7 @@
// @call roundUnit
'month' => [1, static::MONTHS_PER_YEAR],
// @call roundUnit
- 'day' => [1, 31],
+ 'day' => [1, $daysInMonth],
// @call roundUnit
'hour' => [0, static::HOURS_PER_DAY - 1],
// @call roundUnit
@@ -940,7 +943,7 @@
case $name === 'millisecond':
// @property int
case $name === 'milli':
- return (int) floor($this->rawFormat('u') / 1000);
+ return (int) floor(((int) $this->rawFormat('u')) / 1000);
// @property int 1 through 53
case $name === 'week':
@@ -1250,7 +1253,7 @@
protected function getTranslatedFormByRegExp($baseKey, $keySuffix, $context, $subKey, $defaultValue)
{
$key = $baseKey.$keySuffix;
- $standaloneKey = "${key}_standalone";
+ $standaloneKey = "{$key}_standalone";
$baseTranslation = $this->getTranslationMessage($key);
if ($baseTranslation instanceof Closure) {
@@ -1259,7 +1262,7 @@
if (
$this->getTranslationMessage("$standaloneKey.$subKey") &&
- (!$context || ($regExp = $this->getTranslationMessage("${baseKey}_regexp")) && !preg_match($regExp, $context))
+ (!$context || (($regExp = $this->getTranslationMessage("{$baseKey}_regexp")) && !preg_match($regExp, $context)))
) {
$key = $standaloneKey;
}
@@ -1354,9 +1357,14 @@
*/
public function weekday($value = null)
{
- $dayOfWeek = ($this->dayOfWeek + 7 - (int) ($this->getTranslationMessage('first_day_of_week') ?? 0)) % 7;
+ if ($value === null) {
+ return $this->dayOfWeek;
+ }
- return $value === null ? $dayOfWeek : $this->addDays($value - $dayOfWeek);
+ $firstDay = (int) ($this->getTranslationMessage('first_day_of_week') ?? 0);
+ $dayOfWeek = ($this->dayOfWeek + 7 - $firstDay) % 7;
+
+ return $this->addDays((($value + 7 - $firstDay) % 7) - $dayOfWeek);
}
/**
@@ -1374,6 +1382,39 @@
}
/**
+ * Return the number of days since the start of the week (using the current locale or the first parameter
+ * if explicitly given).
+ *
+ * @param int|null $weekStartsAt optional start allow you to specify the day of week to use to start the week,
+ * if not provided, start of week is inferred from the locale
+ * (Sunday for en_US, Monday for de_DE, etc.)
+ *
+ * @return int
+ */
+ public function getDaysFromStartOfWeek(int $weekStartsAt = null): int
+ {
+ $firstDay = (int) ($weekStartsAt ?? $this->getTranslationMessage('first_day_of_week') ?? 0);
+
+ return ($this->dayOfWeek + 7 - $firstDay) % 7;
+ }
+
+ /**
+ * Set the day (keeping the current time) to the start of the week + the number of days passed as the first
+ * parameter. First day of week is driven by the locale unless explicitly set with the second parameter.
+ *
+ * @param int $numberOfDays number of days to add after the start of the current week
+ * @param int|null $weekStartsAt optional start allow you to specify the day of week to use to start the week,
+ * if not provided, start of week is inferred from the locale
+ * (Sunday for en_US, Monday for de_DE, etc.)
+ *
+ * @return static
+ */
+ public function setDaysFromStartOfWeek(int $numberOfDays, int $weekStartsAt = null)
+ {
+ return $this->addDays($numberOfDays - $this->getDaysFromStartOfWeek($weekStartsAt));
+ }
+
+ /**
* Set any unit to a new value without overflowing current other unit given.
*
* @param string $valueUnit unit name to modify
@@ -1848,9 +1889,18 @@
$format = preg_replace('#(?<!%)((?:%%)*)%e#', '\1%#d', $format); // @codeCoverageIgnore
}
- $formatted = strftime($format, strtotime($this->toDateTimeString()));
+ $time = strtotime($this->toDateTimeString());
+ $formatted = ($this->localStrictModeEnabled ?? static::isStrictModeEnabled())
+ ? strftime($format, $time)
+ : @strftime($format, $time);
- return static::$utf8 ? utf8_encode($formatted) : $formatted;
+ return static::$utf8
+ ? (
+ \function_exists('mb_convert_encoding')
+ ? mb_convert_encoding($formatted, 'UTF-8', mb_list_encodings())
+ : utf8_encode($formatted)
+ )
+ : $formatted;
}
/**
@@ -1869,6 +1919,10 @@
'LL' => $this->getTranslationMessage('formats.LL', $locale, 'MMMM D, YYYY'),
'LLL' => $this->getTranslationMessage('formats.LLL', $locale, 'MMMM D, YYYY h:mm A'),
'LLLL' => $this->getTranslationMessage('formats.LLLL', $locale, 'dddd, MMMM D, YYYY h:mm A'),
+ 'l' => $this->getTranslationMessage('formats.l', $locale),
+ 'll' => $this->getTranslationMessage('formats.ll', $locale),
+ 'lll' => $this->getTranslationMessage('formats.lll', $locale),
+ 'llll' => $this->getTranslationMessage('formats.llll', $locale),
];
}
@@ -2152,7 +2206,7 @@
$input = mb_substr($format, $i);
- if (preg_match('/^(LTS|LT|[Ll]{1,4})/', $input, $match)) {
+ if (preg_match('/^(LTS|LT|l{1,4}|L{1,4})/', $input, $match)) {
if ($formats === null) {
$formats = $this->getIsoFormats();
}
@@ -2256,6 +2310,7 @@
'c' => true,
'r' => true,
'U' => true,
+ 'T' => true,
];
}
@@ -2359,7 +2414,7 @@
$symbol = $second < 0 ? '-' : '+';
$minute = abs($second) / static::SECONDS_PER_MINUTE;
$hour = str_pad((string) floor($minute / static::MINUTES_PER_HOUR), 2, '0', STR_PAD_LEFT);
- $minute = str_pad((string) ($minute % static::MINUTES_PER_HOUR), 2, '0', STR_PAD_LEFT);
+ $minute = str_pad((string) (((int) $minute) % static::MINUTES_PER_HOUR), 2, '0', STR_PAD_LEFT);
return "$symbol$hour$separator$minute";
}
@@ -2479,7 +2534,7 @@
return 'millennia';
}
- return "${unit}s";
+ return "{$unit}s";
}
protected function executeCallable($macro, ...$parameters)
@@ -2566,7 +2621,7 @@
if (str_starts_with($unit, 'is')) {
$word = substr($unit, 2);
- if (\in_array($word, static::$days)) {
+ if (\in_array($word, static::$days, true)) {
return $this->isDayOfWeek($word);
}
@@ -2594,7 +2649,7 @@
$unit = strtolower(substr($unit, 3));
}
- if (\in_array($unit, static::$units)) {
+ if (\in_array($unit, static::$units, true)) {
return $this->setUnit($unit, ...$parameters);
}
@@ -2604,7 +2659,7 @@
if (str_starts_with($unit, 'Real')) {
$unit = static::singularUnit(substr($unit, 4));
- return $this->{"${action}RealUnit"}($unit, ...$parameters);
+ return $this->{"{$action}RealUnit"}($unit, ...$parameters);
}
if (preg_match('/^(Month|Quarter|Year|Decade|Century|Centurie|Millennium|Millennia)s?(No|With|Without|WithNo)Overflow$/', $unit, $match)) {
@@ -2616,7 +2671,7 @@
}
if (static::isModifiableUnit($unit)) {
- return $this->{"${action}Unit"}($unit, $parameters[0] ?? 1, $overflow);
+ return $this->{"{$action}Unit"}($unit, $this->getMagicParameter($parameters, 0, 'value', 1), $overflow);
}
$sixFirstLetters = substr($unit, 0, 6);
@@ -2655,7 +2710,11 @@
try {
$unit = static::singularUnit(substr($method, 0, -5));
- return $this->range($parameters[0] ?? $this, $parameters[1] ?? 1, $unit);
+ return $this->range(
+ $this->getMagicParameter($parameters, 0, 'endDate', $this),
+ $this->getMagicParameter($parameters, 1, 'factor', 1),
+ $unit
+ );
} catch (InvalidArgumentException $exception) {
// Try macros
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php
index cce1d2c..ab5b65d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Difference.php
@@ -83,9 +83,9 @@
*
* @return CarbonInterval
*/
- protected static function fixDiffInterval(DateInterval $diff, $absolute)
+ protected static function fixDiffInterval(DateInterval $diff, $absolute, array $skip = [])
{
- $diff = CarbonInterval::instance($diff);
+ $diff = CarbonInterval::instance($diff, $skip);
// Work-around for https://bugs.php.net/bug.php?id=77145
// @codeCoverageIgnoreStart
@@ -148,9 +148,9 @@
*
* @return CarbonInterval
*/
- public function diffAsCarbonInterval($date = null, $absolute = true)
+ public function diffAsCarbonInterval($date = null, $absolute = true, array $skip = [])
{
- return static::fixDiffInterval($this->diff($this->resolveCarbon($date), $absolute), $absolute);
+ return static::fixDiffInterval($this->diff($this->resolveCarbon($date), $absolute), $absolute, $skip);
}
/**
@@ -189,9 +189,21 @@
*/
public function diffInMonths($date = null, $absolute = true)
{
- $date = $this->resolveCarbon($date);
+ $date = $this->resolveCarbon($date)->avoidMutation()->tz($this->tz);
- return $this->diffInYears($date, $absolute) * static::MONTHS_PER_YEAR + (int) $this->diff($date, $absolute)->format('%r%m');
+ [$yearStart, $monthStart, $dayStart] = explode('-', $this->format('Y-m-dHisu'));
+ [$yearEnd, $monthEnd, $dayEnd] = explode('-', $date->format('Y-m-dHisu'));
+
+ $diff = (((int) $yearEnd) - ((int) $yearStart)) * static::MONTHS_PER_YEAR +
+ ((int) $monthEnd) - ((int) $monthStart);
+
+ if ($diff > 0) {
+ $diff -= ($dayStart > $dayEnd ? 1 : 0);
+ } elseif ($diff < 0) {
+ $diff += ($dayStart < $dayEnd ? 1 : 0);
+ }
+
+ return $absolute ? abs($diff) : $diff;
}
/**
@@ -286,9 +298,9 @@
*/
public function diffInWeekdays($date = null, $absolute = true)
{
- return $this->diffInDaysFiltered(function (CarbonInterface $date) {
+ return $this->diffInDaysFiltered(static function (CarbonInterface $date) {
return $date->isWeekday();
- }, $date, $absolute);
+ }, $this->resolveCarbon($date)->avoidMutation()->modify($this->format('H:i:s.u')), $absolute);
}
/**
@@ -301,9 +313,9 @@
*/
public function diffInWeekendDays($date = null, $absolute = true)
{
- return $this->diffInDaysFiltered(function (CarbonInterface $date) {
+ return $this->diffInDaysFiltered(static function (CarbonInterface $date) {
return $date->isWeekend();
- }, $date, $absolute);
+ }, $this->resolveCarbon($date)->avoidMutation()->modify($this->format('H:i:s.u')), $absolute);
}
/**
@@ -472,7 +484,7 @@
*/
public function floatDiffInSeconds($date = null, $absolute = true)
{
- return $this->diffInMicroseconds($date, $absolute) / static::MICROSECONDS_PER_SECOND;
+ return (float) ($this->diffInMicroseconds($date, $absolute) / static::MICROSECONDS_PER_SECOND);
}
/**
@@ -830,8 +842,9 @@
$intSyntax = $intSyntax === static::DIFF_RELATIVE_AUTO && $other === null ? static::DIFF_RELATIVE_TO_NOW : $intSyntax;
$parts = min(7, max(1, (int) $parts));
+ $skip = \is_array($syntax) ? ($syntax['skip'] ?? []) : [];
- return $this->diffAsCarbonInterval($other, false)
+ return $this->diffAsCarbonInterval($other, false, (array) $skip)
->setLocalTranslator($this->getLocalTranslator())
->forHumans($syntax, (bool) $short, $parts, $options ?? $this->localHumanDiffOptions ?? static::getHumanDiffOptions());
}
@@ -1161,7 +1174,7 @@
version_compare(PHP_VERSION, '8.1.0-dev', '<') &&
abs($interval->d - $daysDiff) === 1
) {
- $daysDiff = abs($interval->d);
+ $daysDiff = abs($interval->d); // @codeCoverageIgnore
}
return $daysDiff * $sign;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php
index 4cd66b6..f069c28 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/IntervalRounding.php
@@ -40,7 +40,7 @@
$unit = 'second';
if ($precision instanceof DateInterval) {
- $precision = (string) CarbonInterval::instance($precision);
+ $precision = (string) CarbonInterval::instance($precision, [], true);
}
if (\is_string($precision) && preg_match('/^\s*(?<precision>\d+)?\s*(?<unit>\w+)(?<other>\W.*)?$/', $precision, $match)) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php
index ddd2b4e..46aff11 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Localization.php
@@ -23,12 +23,16 @@
use Symfony\Contracts\Translation\LocaleAwareInterface;
use Symfony\Contracts\Translation\TranslatorInterface as ContractsTranslatorInterface;
-if (!interface_exists('Symfony\\Component\\Translation\\TranslatorInterface')) {
+// @codeCoverageIgnoreStart
+if (interface_exists('Symfony\\Contracts\\Translation\\TranslatorInterface') &&
+ !interface_exists('Symfony\\Component\\Translation\\TranslatorInterface')
+) {
class_alias(
'Symfony\\Contracts\\Translation\\TranslatorInterface',
'Symfony\\Component\\Translation\\TranslatorInterface'
);
}
+// @codeCoverageIgnoreEnd
/**
* Trait Localization.
@@ -355,6 +359,13 @@
$weekdays = $messages['weekdays'] ?? [];
$meridiem = $messages['meridiem'] ?? ['AM', 'PM'];
+ if (isset($messages['ordinal_words'])) {
+ $timeString = self::replaceOrdinalWords(
+ $timeString,
+ $key === 'from' ? array_flip($messages['ordinal_words']) : $messages['ordinal_words']
+ );
+ }
+
if ($key === 'from') {
foreach (['months', 'weekdays'] as $variable) {
$list = $messages[$variable.'_standalone'] ?? null;
@@ -454,7 +465,7 @@
}
}
- $this->setLocalTranslator($translator);
+ $this->localTranslator = $translator;
}
return $this;
@@ -555,17 +566,13 @@
public static function localeHasShortUnits($locale)
{
return static::executeWithLocale($locale, function ($newLocale, TranslatorInterface $translator) {
- return $newLocale &&
- (
- ($y = static::translateWith($translator, 'y')) !== 'y' &&
- $y !== static::translateWith($translator, 'year')
- ) || (
- ($y = static::translateWith($translator, 'd')) !== 'd' &&
+ return ($newLocale && (($y = static::translateWith($translator, 'y')) !== 'y' && $y !== static::translateWith($translator, 'year'))) || (
+ ($y = static::translateWith($translator, 'd')) !== 'd' &&
$y !== static::translateWith($translator, 'day')
- ) || (
- ($y = static::translateWith($translator, 'h')) !== 'h' &&
+ ) || (
+ ($y = static::translateWith($translator, 'h')) !== 'h' &&
$y !== static::translateWith($translator, 'hour')
- );
+ );
});
}
@@ -734,7 +741,7 @@
}
if ($translator && !($translator instanceof LocaleAwareInterface || method_exists($translator, 'getLocale'))) {
- throw new NotLocaleAwareException($translator);
+ throw new NotLocaleAwareException($translator); // @codeCoverageIgnore
}
return $translator;
@@ -823,4 +830,11 @@
return $list;
}
+
+ private static function replaceOrdinalWords(string $timeString, array $ordinalWords): string
+ {
+ return preg_replace_callback('/(?<![a-z])[a-z]+(?![a-z])/i', function (array $match) use ($ordinalWords) {
+ return $ordinalWords[mb_strtolower($match[0])] ?? $match[0];
+ }, $timeString);
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/MagicParameter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/MagicParameter.php
new file mode 100644
index 0000000..310a44d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/MagicParameter.php
@@ -0,0 +1,33 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\Traits;
+
+/**
+ * Trait MagicParameter.
+ *
+ * Allows to retrieve parameter in magic calls by index or name.
+ */
+trait MagicParameter
+{
+ private function getMagicParameter(array $parameters, int $index, string $key, $default)
+ {
+ if (\array_key_exists($index, $parameters)) {
+ return $parameters[$index];
+ }
+
+ if (\array_key_exists($key, $parameters)) {
+ return $parameters[$key];
+ }
+
+ return $default;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php
index 88b251d..5822454 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Mixin.php
@@ -11,6 +11,9 @@
namespace Carbon\Traits;
+use Carbon\CarbonInterface;
+use Carbon\CarbonInterval;
+use Carbon\CarbonPeriod;
use Closure;
use Generator;
use ReflectionClass;
@@ -99,12 +102,13 @@
{
$context = eval(self::getAnonymousClassCodeForTrait($trait));
$className = \get_class($context);
+ $baseClass = static::class;
foreach (self::getMixableMethods($context) as $name) {
$closureBase = Closure::fromCallable([$context, $name]);
- static::macro($name, function () use ($closureBase, $className) {
- /** @phpstan-ignore-next-line */
+ static::macro($name, function (...$parameters) use ($closureBase, $className, $baseClass) {
+ $downContext = isset($this) ? ($this) : new $baseClass();
$context = isset($this) ? $this->cast($className) : new $className();
try {
@@ -117,7 +121,48 @@
// in case of errors not converted into exceptions
$closure = $closure ?: $closureBase;
- return $closure(...\func_get_args());
+ $result = $closure(...$parameters);
+
+ if (!($result instanceof $className)) {
+ return $result;
+ }
+
+ if ($downContext instanceof CarbonInterface && $result instanceof CarbonInterface) {
+ if ($context !== $result) {
+ $downContext = $downContext->copy();
+ }
+
+ return $downContext
+ ->setTimezone($result->getTimezone())
+ ->modify($result->format('Y-m-d H:i:s.u'))
+ ->settings($result->getSettings());
+ }
+
+ if ($downContext instanceof CarbonInterval && $result instanceof CarbonInterval) {
+ if ($context !== $result) {
+ $downContext = $downContext->copy();
+ }
+
+ $downContext->copyProperties($result);
+ self::copyStep($downContext, $result);
+ self::copyNegativeUnits($downContext, $result);
+
+ return $downContext->settings($result->getSettings());
+ }
+
+ if ($downContext instanceof CarbonPeriod && $result instanceof CarbonPeriod) {
+ if ($context !== $result) {
+ $downContext = $downContext->copy();
+ }
+
+ return $downContext
+ ->setDates($result->getStartDate(), $result->getEndDate())
+ ->setRecurrences($result->getRecurrences())
+ ->setOptions($result->getOptions())
+ ->settings($result->getSettings());
+ }
+
+ return $result;
});
}
}
@@ -151,22 +196,12 @@
protected static function bindMacroContext($context, callable $callable)
{
static::$macroContextStack[] = $context;
- $exception = null;
- $result = null;
try {
- $result = $callable();
- } catch (Throwable $throwable) {
- $exception = $throwable;
+ return $callable();
+ } finally {
+ array_pop(static::$macroContextStack);
}
-
- array_pop(static::$macroContextStack);
-
- if ($exception) {
- throw $exception;
- }
-
- return $result;
}
/**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php
index 164dbbd..39343d8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Modifiers.php
@@ -75,7 +75,7 @@
*
* @param string|int|null $modifier
*
- * @return static
+ * @return static|false
*/
public function next($modifier = null)
{
@@ -157,7 +157,7 @@
*
* @param string|int|null $modifier
*
- * @return static
+ * @return static|false
*/
public function previous($modifier = null)
{
@@ -451,7 +451,7 @@
*
* @param string $modifier
*
- * @return static
+ * @return static|false
*/
public function change($modifier)
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php
index 0ddee8d..48f9739 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Options.php
@@ -22,7 +22,7 @@
*
* Depends on the following methods:
*
- * @method \Carbon\Carbon|\Carbon\CarbonImmutable shiftTimezone($timezone) Set the timezone
+ * @method static shiftTimezone($timezone) Set the timezone
*/
trait Options
{
@@ -422,7 +422,7 @@
foreach ($map as $property => $key) {
$value = $this->$property ?? null;
- if ($value !== null) {
+ if ($value !== null && ($key !== 'locale' || $value !== 'en' || $this->localTranslator)) {
$settings[$key] = $value;
}
}
@@ -437,11 +437,11 @@
*/
public function __debugInfo()
{
- $infos = array_filter(get_object_vars($this), function ($var) {
+ $infos = array_filter(get_object_vars($this), static function ($var) {
return $var;
});
- foreach (['dumpProperties', 'constructedObjectId'] as $property) {
+ foreach (['dumpProperties', 'constructedObjectId', 'constructed'] as $property) {
if (isset($infos[$property])) {
unset($infos[$property]);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php
index 3306239..85ff5a7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Rounding.php
@@ -52,12 +52,11 @@
'millisecond' => [1000, 'microsecond'],
];
$normalizedUnit = static::singularUnit($unit);
- $ranges = array_merge(static::getRangesByUnit(), [
+ $ranges = array_merge(static::getRangesByUnit($this->daysInMonth), [
// @call roundUnit
'microsecond' => [0, 999999],
]);
$factor = 1;
- $initialMonth = $this->month;
if ($normalizedUnit === 'week') {
$normalizedUnit = 'day';
@@ -77,12 +76,15 @@
$found = false;
$fraction = 0;
$arguments = null;
+ $initialValue = null;
$factor = $this->year < 0 ? -1 : 1;
$changes = [];
+ $minimumInc = null;
foreach ($ranges as $unit => [$minimum, $maximum]) {
if ($normalizedUnit === $unit) {
$arguments = [$this->$unit, $minimum];
+ $initialValue = $this->$unit;
$fraction = $precision - floor($precision);
$found = true;
@@ -93,7 +95,23 @@
$delta = $maximum + 1 - $minimum;
$factor /= $delta;
$fraction *= $delta;
- $arguments[0] += $this->$unit * $factor;
+ $inc = ($this->$unit - $minimum) * $factor;
+
+ if ($inc !== 0.0) {
+ $minimumInc = $minimumInc ?? ($arguments[0] / pow(2, 52));
+
+ // If value is still the same when adding a non-zero increment/decrement,
+ // it means precision got lost in the addition
+ if (abs($inc) < $minimumInc) {
+ $inc = $minimumInc * ($inc < 0 ? -1 : 1);
+ }
+
+ // If greater than $precision, assume precision loss caused an overflow
+ if ($function !== 'floor' || abs($arguments[0] + $inc - $initialValue) >= $precision) {
+ $arguments[0] += $inc;
+ }
+ }
+
$changes[$unit] = round(
$minimum + ($fraction ? $fraction * $function(($this->$unit - $minimum) / $fraction) : 0)
);
@@ -111,16 +129,13 @@
$normalizedValue = floor($function(($value - $minimum) / $precision) * $precision + $minimum);
/** @var CarbonInterface $result */
- $result = $this->$normalizedUnit($normalizedValue);
+ $result = $this;
foreach ($changes as $unit => $value) {
$result = $result->$unit($value);
}
- return $normalizedUnit === 'month' && $precision <= 1 && abs($result->month - $initialMonth) === 2
- // Re-run the change in case an overflow occurred
- ? $result->$normalizedUnit($normalizedValue)
- : $result;
+ return $result->$normalizedUnit($normalizedValue);
}
/**
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php
index eebc69b..c1d5c5e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Serialization.php
@@ -120,6 +120,8 @@
/**
* Returns the list of properties to dump on serialize() called on.
*
+ * Only used by PHP < 7.4.
+ *
* @return array
*/
public function __sleep()
@@ -135,21 +137,69 @@
}
/**
+ * Returns the values to dump on serialize() called on.
+ *
+ * Only used by PHP >= 7.4.
+ *
+ * @return array
+ */
+ public function __serialize(): array
+ {
+ // @codeCoverageIgnoreStart
+ if (isset($this->timezone_type, $this->timezone, $this->date)) {
+ return [
+ 'date' => $this->date ?? null,
+ 'timezone_type' => $this->timezone_type,
+ 'timezone' => $this->timezone ?? null,
+ ];
+ }
+ // @codeCoverageIgnoreEnd
+
+ $timezone = $this->getTimezone();
+ $export = [
+ 'date' => $this->format('Y-m-d H:i:s.u'),
+ 'timezone_type' => $timezone->getType(),
+ 'timezone' => $timezone->getName(),
+ ];
+
+ // @codeCoverageIgnoreStart
+ if (\extension_loaded('msgpack') && isset($this->constructedObjectId)) {
+ $export['dumpDateProperties'] = [
+ 'date' => $this->format('Y-m-d H:i:s.u'),
+ 'timezone' => serialize($this->timezone ?? null),
+ ];
+ }
+ // @codeCoverageIgnoreEnd
+
+ if ($this->localTranslator ?? null) {
+ $export['dumpLocale'] = $this->locale ?? null;
+ }
+
+ return $export;
+ }
+
+ /**
* Set locale if specified on unserialize() called.
*
+ * Only used by PHP < 7.4.
+ *
* @return void
*/
#[ReturnTypeWillChange]
public function __wakeup()
{
- if (get_parent_class() && method_exists(parent::class, '__wakeup')) {
+ if (parent::class && method_exists(parent::class, '__wakeup')) {
// @codeCoverageIgnoreStart
try {
parent::__wakeup();
} catch (Throwable $exception) {
- // FatalError occurs when calling msgpack_unpack() in PHP 7.4 or later.
- ['date' => $date, 'timezone' => $timezone] = $this->dumpDateProperties;
- parent::__construct($date, unserialize($timezone));
+ try {
+ // FatalError occurs when calling msgpack_unpack() in PHP 7.4 or later.
+ ['date' => $date, 'timezone' => $timezone] = $this->dumpDateProperties;
+ parent::__construct($date, unserialize($timezone));
+ } catch (Throwable $ignoredException) {
+ throw $exception;
+ }
}
// @codeCoverageIgnoreEnd
}
@@ -165,6 +215,38 @@
}
/**
+ * Set locale if specified on unserialize() called.
+ *
+ * Only used by PHP >= 7.4.
+ *
+ * @return void
+ */
+ public function __unserialize(array $data): void
+ {
+ // @codeCoverageIgnoreStart
+ try {
+ $this->__construct($data['date'] ?? null, $data['timezone'] ?? null);
+ } catch (Throwable $exception) {
+ if (!isset($data['dumpDateProperties']['date'], $data['dumpDateProperties']['timezone'])) {
+ throw $exception;
+ }
+
+ try {
+ // FatalError occurs when calling msgpack_unpack() in PHP 7.4 or later.
+ ['date' => $date, 'timezone' => $timezone] = $data['dumpDateProperties'];
+ $this->__construct($date, unserialize($timezone));
+ } catch (Throwable $ignoredException) {
+ throw $exception;
+ }
+ }
+ // @codeCoverageIgnoreEnd
+
+ if (isset($data['dumpLocale'])) {
+ $this->locale($data['dumpLocale']);
+ }
+ }
+
+ /**
* Prepare the object for JSON serialization.
*
* @return array|string
@@ -207,11 +289,15 @@
*/
public function cleanupDumpProperties()
{
- foreach ($this->dumpProperties as $property) {
- if (isset($this->$property)) {
- unset($this->$property);
+ // @codeCoverageIgnoreStart
+ if (PHP_VERSION < 8.2) {
+ foreach ($this->dumpProperties as $property) {
+ if (isset($this->$property)) {
+ unset($this->$property);
+ }
}
}
+ // @codeCoverageIgnoreEnd
return $this;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php
index c86faa7..f23c72e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Test.php
@@ -28,7 +28,7 @@
/**
* A test Carbon instance to be returned when now instances are created.
*
- * @var static
+ * @var Closure|static|null
*/
protected static $testNow;
@@ -59,15 +59,13 @@
*
* /!\ Use this method for unit tests only.
*
- * @param Closure|static|string|false|null $testNow real or mock Carbon instance
+ * @param DateTimeInterface|Closure|static|string|false|null $testNow real or mock Carbon instance
*/
public static function setTestNow($testNow = null)
{
- if ($testNow === false) {
- $testNow = null;
- }
-
- static::$testNow = \is_string($testNow) ? static::parse($testNow) : $testNow;
+ static::$testNow = $testNow instanceof self || $testNow instanceof Closure
+ ? $testNow
+ : static::make($testNow);
}
/**
@@ -87,7 +85,7 @@
*
* /!\ Use this method for unit tests only.
*
- * @param Closure|static|string|false|null $testNow real or mock Carbon instance
+ * @param DateTimeInterface|Closure|static|string|false|null $testNow real or mock Carbon instance
*/
public static function setTestNowAndTimezone($testNow = null, $tz = null)
{
@@ -121,16 +119,22 @@
*
* /!\ Use this method for unit tests only.
*
- * @param Closure|static|string|false|null $testNow real or mock Carbon instance
- * @param Closure|null $callback
+ * @template T
*
- * @return mixed
+ * @param DateTimeInterface|Closure|static|string|false|null $testNow real or mock Carbon instance
+ * @param Closure(): T $callback
+ *
+ * @return T
*/
- public static function withTestNow($testNow = null, $callback = null)
+ public static function withTestNow($testNow, $callback)
{
static::setTestNow($testNow);
- $result = $callback();
- static::setTestNow();
+
+ try {
+ $result = $callback();
+ } finally {
+ static::setTestNow();
+ }
return $result;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php
index 2cb5c48..88a465c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Timestamp.php
@@ -63,7 +63,7 @@
public static function createFromTimestampMsUTC($timestamp)
{
[$milliseconds, $microseconds] = self::getIntegerAndDecimalParts($timestamp, 3);
- $sign = $milliseconds < 0 || $milliseconds === 0.0 && $microseconds < 0 ? -1 : 1;
+ $sign = $milliseconds < 0 || ($milliseconds === 0.0 && $microseconds < 0) ? -1 : 1;
$milliseconds = abs($milliseconds);
$microseconds = $sign * abs($microseconds) + static::MICROSECONDS_PER_MILLISECOND * ($milliseconds % static::MILLISECONDS_PER_SECOND);
$seconds = $sign * floor($milliseconds / static::MILLISECONDS_PER_SECOND);
@@ -125,7 +125,7 @@
*/
public function getPreciseTimestamp($precision = 6)
{
- return round($this->rawFormat('Uu') / pow(10, 6 - $precision));
+ return round(((float) $this->rawFormat('Uu')) / pow(10, 6 - $precision));
}
/**
@@ -182,7 +182,7 @@
$integer = 0;
$decimal = 0;
- foreach (preg_split('`[^0-9.]+`', $numbers) as $chunk) {
+ foreach (preg_split('`[^\d.]+`', $numbers) as $chunk) {
[$integerPart, $decimalPart] = explode('.', "$chunk.");
$integer += (int) $integerPart;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/ToStringFormat.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/ToStringFormat.php
new file mode 100644
index 0000000..a81164f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/ToStringFormat.php
@@ -0,0 +1,56 @@
+<?php
+
+/**
+ * This file is part of the Carbon package.
+ *
+ * (c) Brian Nesbitt <brian@nesbot.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace Carbon\Traits;
+
+use Closure;
+
+/**
+ * Trait ToStringFormat.
+ *
+ * Handle global format customization for string cast of the object.
+ */
+trait ToStringFormat
+{
+ /**
+ * Format to use for __toString method when type juggling occurs.
+ *
+ * @var string|Closure|null
+ */
+ protected static $toStringFormat;
+
+ /**
+ * Reset the format used to the default when type juggling a Carbon instance to a string
+ *
+ * @return void
+ */
+ public static function resetToStringFormat()
+ {
+ static::setToStringFormat(null);
+ }
+
+ /**
+ * @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
+ * You should rather let Carbon object being cast to string with DEFAULT_TO_STRING_FORMAT, and
+ * use other method or custom format passed to format() method if you need to dump another string
+ * format.
+ *
+ * Set the default format used when type juggling a Carbon instance to a string.
+ *
+ * @param string|Closure|null $format
+ *
+ * @return void
+ */
+ public static function setToStringFormat($format)
+ {
+ static::$toStringFormat = $format;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php
index 2902a8b..5be14ec 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/Traits/Units.php
@@ -17,6 +17,7 @@
use Carbon\Exceptions\UnitException;
use Closure;
use DateInterval;
+use DateMalformedStringException;
use ReturnTypeWillChange;
/**
@@ -60,8 +61,6 @@
case 'millisecond':
return $this->addRealUnit('microsecond', $value * static::MICROSECONDS_PER_MILLISECOND);
- break;
-
// @call addRealUnit
case 'second':
break;
@@ -167,7 +166,7 @@
'weekday',
];
- return \in_array($unit, $modifiableUnits) || \in_array($unit, static::$units);
+ return \in_array($unit, $modifiableUnits, true) || \in_array($unit, static::$units, true);
}
/**
@@ -199,7 +198,7 @@
public function add($unit, $value = 1, $overflow = null)
{
if (\is_string($unit) && \func_num_args() === 1) {
- $unit = CarbonInterval::make($unit);
+ $unit = CarbonInterval::make($unit, [], true);
}
if ($unit instanceof CarbonConverterInterface) {
@@ -232,6 +231,8 @@
*/
public function addUnit($unit, $value = 1, $overflow = null)
{
+ $originalArgs = \func_get_args();
+
$date = $this;
if (!is_numeric($value) || !(float) $value) {
@@ -264,7 +265,7 @@
/** @var static $date */
$date = $date->addDays($sign);
- while (\in_array($date->dayOfWeek, $weekendDays)) {
+ while (\in_array($date->dayOfWeek, $weekendDays, true)) {
$date = $date->addDays($sign);
}
}
@@ -274,14 +275,14 @@
}
$timeString = $date->toTimeString();
- } elseif ($canOverflow = \in_array($unit, [
+ } elseif ($canOverflow = (\in_array($unit, [
'month',
'year',
]) && ($overflow === false || (
$overflow === null &&
($ucUnit = ucfirst($unit).'s') &&
!($this->{'local'.$ucUnit.'Overflow'} ?? static::{'shouldOverflow'.$ucUnit}())
- ))) {
+ )))) {
$day = $date->day;
}
@@ -304,16 +305,21 @@
$unit = 'second';
$value = $second;
}
- $date = $date->modify("$value $unit");
- if (isset($timeString)) {
- $date = $date->setTimeFromTimeString($timeString);
- } elseif (isset($canOverflow, $day) && $canOverflow && $day !== $date->day) {
- $date = $date->modify('last day of previous month');
+ try {
+ $date = $date->modify("$value $unit");
+
+ if (isset($timeString)) {
+ $date = $date->setTimeFromTimeString($timeString);
+ } elseif (isset($canOverflow, $day) && $canOverflow && $day !== $date->day) {
+ $date = $date->modify('last day of previous month');
+ }
+ } catch (DateMalformedStringException $ignoredException) { // @codeCoverageIgnore
+ $date = null; // @codeCoverageIgnore
}
if (!$date) {
- throw new UnitException('Unable to add unit '.var_export(\func_get_args(), true));
+ throw new UnitException('Unable to add unit '.var_export($originalArgs, true));
}
return $date;
@@ -362,7 +368,7 @@
public function sub($unit, $value = 1, $overflow = null)
{
if (\is_string($unit) && \func_num_args() === 1) {
- $unit = CarbonInterval::make($unit);
+ $unit = CarbonInterval::make($unit, [], true);
}
if ($unit instanceof CarbonConverterInterface) {
@@ -398,7 +404,7 @@
public function subtract($unit, $value = 1, $overflow = null)
{
if (\is_string($unit) && \func_num_args() === 1) {
- $unit = CarbonInterval::make($unit);
+ $unit = CarbonInterval::make($unit, [], true);
}
return $this->sub($unit, $value, $overflow);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php
index ad36c67..ce6b2f9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php
@@ -66,7 +66,7 @@
/**
* @codeCoverageIgnore
*/
- public function setConfigCacheFactory(ConfigCacheFactoryInterface $configCacheFactory)
+ public function setConfigCacheFactory(ConfigCacheFactoryInterface $configCacheFactory): void
{
$this->disallowMutation(__METHOD__);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/CHANGELOG.md
new file mode 100644
index 0000000..3cd6b9b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/CHANGELOG.md
@@ -0,0 +1,11 @@
+# Changelog
+
+All notable changes to this project will be documented in this file, in reverse chronological order by release.
+
+## 1.0.0
+
+First stable release after PSR-20 acceptance
+
+## 0.1.0
+
+First release
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/LICENSE
new file mode 100644
index 0000000..be68342
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2017 PHP Framework Interoperability Group
+
+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/psr/clock/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/README.md
new file mode 100644
index 0000000..6ca877e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/README.md
@@ -0,0 +1,61 @@
+# PSR Clock
+
+This repository holds the interface for [PSR-20][psr-url].
+
+Note that this is not a clock of its own. It is merely an interface that
+describes a clock. See the specification for more details.
+
+## Installation
+
+```bash
+composer require psr/clock
+```
+
+## Usage
+
+If you need a clock, you can use the interface like this:
+
+```php
+<?php
+
+use Psr\Clock\ClockInterface;
+
+class Foo
+{
+ private ClockInterface $clock;
+
+ public function __construct(ClockInterface $clock)
+ {
+ $this->clock = $clock;
+ }
+
+ public function doSomething()
+ {
+ /** @var DateTimeImmutable $currentDateAndTime */
+ $currentDateAndTime = $this->clock->now();
+ // do something useful with that information
+ }
+}
+```
+
+You can then pick one of the [implementations][implementation-url] of the interface to get a clock.
+
+If you want to implement the interface, you can require this package and
+implement `Psr\Clock\ClockInterface` in your code.
+
+Don't forget to add `psr/clock-implementation` to your `composer.json`s `provides`-section like this:
+
+```json
+{
+ "provides": {
+ "psr/clock-implementation": "1.0"
+ }
+}
+```
+
+And please read the [specification text][specification-url] for details on the interface.
+
+[psr-url]: https://www.php-fig.org/psr/psr-20
+[package-url]: https://packagist.org/packages/psr/clock
+[implementation-url]: https://packagist.org/providers/psr/clock-implementation
+[specification-url]: https://github.com/php-fig/fig-standards/blob/master/proposed/clock.md
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/composer.json
new file mode 100644
index 0000000..77992ed
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/composer.json
@@ -0,0 +1,21 @@
+{
+ "name": "psr/clock",
+ "description": "Common interface for reading the clock.",
+ "keywords": ["psr", "psr-20", "time", "clock", "now"],
+ "homepage": "https://github.com/php-fig/clock",
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "https://www.php-fig.org/"
+ }
+ ],
+ "require": {
+ "php": "^7.0 || ^8.0"
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Clock\\": "src/"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/src/ClockInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/src/ClockInterface.php
new file mode 100644
index 0000000..7b6d8d8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/clock/src/ClockInterface.php
@@ -0,0 +1,13 @@
+<?php
+
+namespace Psr\Clock;
+
+use DateTimeImmutable;
+
+interface ClockInterface
+{
+ /**
+ * Returns the current time as a DateTimeImmutable Object
+ */
+ public function now(): DateTimeImmutable;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/CHANGELOG.md
new file mode 100644
index 0000000..e2dc25f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/CHANGELOG.md
@@ -0,0 +1,23 @@
+# Changelog
+
+All notable changes to this project will be documented in this file, in reverse chronological order by release.
+
+## 1.0.1
+
+Allow installation with PHP 8. No code changes.
+
+## 1.0.0
+
+First stable release. No changes since 0.3.0.
+
+## 0.3.0
+
+Added Interface suffix on exceptions
+
+## 0.2.0
+
+All exceptions are in `Psr\Http\Client` namespace
+
+## 0.1.0
+
+First release
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/LICENSE
new file mode 100644
index 0000000..cd5e002
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2017 PHP Framework Interoperability Group
+
+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/psr/http-client/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/README.md
new file mode 100644
index 0000000..6876b84
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/README.md
@@ -0,0 +1,12 @@
+HTTP Client
+===========
+
+This repository holds all the common code related to [PSR-18 (HTTP Client)][psr-url].
+
+Note that this is not a HTTP Client implementation of its own. It is merely abstractions that describe the components of a HTTP Client.
+
+The installable [package][package-url] and [implementations][implementation-url] are listed on Packagist.
+
+[psr-url]: http://www.php-fig.org/psr/psr-18
+[package-url]: https://packagist.org/packages/psr/http-client
+[implementation-url]: https://packagist.org/providers/psr/http-client-implementation
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/composer.json
new file mode 100644
index 0000000..c195f8f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/composer.json
@@ -0,0 +1,27 @@
+{
+ "name": "psr/http-client",
+ "description": "Common interface for HTTP clients",
+ "keywords": ["psr", "psr-18", "http", "http-client"],
+ "homepage": "https://github.com/php-fig/http-client",
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "require": {
+ "php": "^7.0 || ^8.0",
+ "psr/http-message": "^1.0"
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Client\\": "src/"
+ }
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/ClientExceptionInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/ClientExceptionInterface.php
new file mode 100644
index 0000000..aa0b9cf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/ClientExceptionInterface.php
@@ -0,0 +1,10 @@
+<?php
+
+namespace Psr\Http\Client;
+
+/**
+ * Every HTTP client related exception MUST implement this interface.
+ */
+interface ClientExceptionInterface extends \Throwable
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/ClientInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/ClientInterface.php
new file mode 100644
index 0000000..ad99fd4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/ClientInterface.php
@@ -0,0 +1,20 @@
+<?php
+
+namespace Psr\Http\Client;
+
+use Psr\Http\Message\RequestInterface;
+use Psr\Http\Message\ResponseInterface;
+
+interface ClientInterface
+{
+ /**
+ * Sends a PSR-7 request and returns a PSR-7 response.
+ *
+ * @param RequestInterface $request
+ *
+ * @return ResponseInterface
+ *
+ * @throws \Psr\Http\Client\ClientExceptionInterface If an error happens while processing the request.
+ */
+ public function sendRequest(RequestInterface $request): ResponseInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/NetworkExceptionInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/NetworkExceptionInterface.php
new file mode 100644
index 0000000..4a11627
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/NetworkExceptionInterface.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace Psr\Http\Client;
+
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Thrown when the request cannot be completed because of network issues.
+ *
+ * There is no response object as this exception is thrown when no response has been received.
+ *
+ * Example: the target host name can not be resolved or the connection failed.
+ */
+interface NetworkExceptionInterface extends ClientExceptionInterface
+{
+ /**
+ * Returns the request.
+ *
+ * The request object MAY be a different object from the one passed to ClientInterface::sendRequest()
+ *
+ * @return RequestInterface
+ */
+ public function getRequest(): RequestInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/RequestExceptionInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/RequestExceptionInterface.php
new file mode 100644
index 0000000..b17fc34
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-client/src/RequestExceptionInterface.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace Psr\Http\Client;
+
+use Psr\Http\Message\RequestInterface;
+
+/**
+ * Exception for when a request failed.
+ *
+ * Examples:
+ * - Request is invalid (e.g. method is missing)
+ * - Runtime request errors (e.g. the body stream is not seekable)
+ */
+interface RequestExceptionInterface extends ClientExceptionInterface
+{
+ /**
+ * Returns the request.
+ *
+ * The request object MAY be a different object from the one passed to ClientInterface::sendRequest()
+ *
+ * @return RequestInterface
+ */
+ public function getRequest(): RequestInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/.gitignore b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/.gitignore
new file mode 100644
index 0000000..d8a7996
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/.gitignore
@@ -0,0 +1,2 @@
+composer.lock
+vendor/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/.pullapprove.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/.pullapprove.yml
new file mode 100644
index 0000000..8cf0819
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/.pullapprove.yml
@@ -0,0 +1,7 @@
+extends: default
+reviewers:
+ -
+ name: contributors
+ required: 1
+ teams:
+ - http-factory-contributors
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/LICENSE
new file mode 100644
index 0000000..3f1559b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/LICENSE
@@ -0,0 +1,21 @@
+MIT License
+
+Copyright (c) 2018 PHP-FIG
+
+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/psr/http-factory/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/README.md
new file mode 100644
index 0000000..41d362a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/README.md
@@ -0,0 +1,10 @@
+HTTP Factories
+==============
+
+This repository holds all interfaces related to [PSR-17 (HTTP Message Factories)][psr-17].
+Please refer to the specification for a description.
+
+You can find implementations of the specification by looking for packages providing the
+[psr/http-factory-implementation](https://packagist.org/providers/psr/http-factory-implementation) virtual package.
+
+[psr-17]: https://www.php-fig.org/psr/psr-17/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/composer.json
new file mode 100644
index 0000000..af62b29
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/composer.json
@@ -0,0 +1,35 @@
+{
+ "name": "psr/http-factory",
+ "description": "Common interfaces for PSR-7 HTTP message factories",
+ "keywords": [
+ "psr",
+ "psr-7",
+ "psr-17",
+ "http",
+ "factory",
+ "message",
+ "request",
+ "response"
+ ],
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "require": {
+ "php": ">=7.0.0",
+ "psr/http-message": "^1.0"
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/RequestFactoryInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/RequestFactoryInterface.php
new file mode 100644
index 0000000..cb39a08
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/RequestFactoryInterface.php
@@ -0,0 +1,18 @@
+<?php
+
+namespace Psr\Http\Message;
+
+interface RequestFactoryInterface
+{
+ /**
+ * Create a new request.
+ *
+ * @param string $method The HTTP method associated with the request.
+ * @param UriInterface|string $uri The URI associated with the request. If
+ * the value is a string, the factory MUST create a UriInterface
+ * instance based on it.
+ *
+ * @return RequestInterface
+ */
+ public function createRequest(string $method, $uri): RequestInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/ResponseFactoryInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/ResponseFactoryInterface.php
new file mode 100644
index 0000000..212562f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/ResponseFactoryInterface.php
@@ -0,0 +1,18 @@
+<?php
+
+namespace Psr\Http\Message;
+
+interface ResponseFactoryInterface
+{
+ /**
+ * Create a new response.
+ *
+ * @param int $code HTTP status code; defaults to 200
+ * @param string $reasonPhrase Reason phrase to associate with status code
+ * in generated response; if none is provided implementations MAY use
+ * the defaults as suggested in the HTTP specification.
+ *
+ * @return ResponseInterface
+ */
+ public function createResponse(int $code = 200, string $reasonPhrase = ''): ResponseInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/ServerRequestFactoryInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/ServerRequestFactoryInterface.php
new file mode 100644
index 0000000..9fe031a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/ServerRequestFactoryInterface.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace Psr\Http\Message;
+
+interface ServerRequestFactoryInterface
+{
+ /**
+ * Create a new server request.
+ *
+ * Note that server-params are taken precisely as given - no parsing/processing
+ * of the given values is performed, and, in particular, no attempt is made to
+ * determine the HTTP method or URI, which must be provided explicitly.
+ *
+ * @param string $method The HTTP method associated with the request.
+ * @param UriInterface|string $uri The URI associated with the request. If
+ * the value is a string, the factory MUST create a UriInterface
+ * instance based on it.
+ * @param array $serverParams Array of SAPI parameters with which to seed
+ * the generated request instance.
+ *
+ * @return ServerRequestInterface
+ */
+ public function createServerRequest(string $method, $uri, array $serverParams = []): ServerRequestInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/StreamFactoryInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/StreamFactoryInterface.php
new file mode 100644
index 0000000..90e3240
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/StreamFactoryInterface.php
@@ -0,0 +1,45 @@
+<?php
+
+namespace Psr\Http\Message;
+
+interface StreamFactoryInterface
+{
+ /**
+ * Create a new stream from a string.
+ *
+ * The stream SHOULD be created with a temporary resource.
+ *
+ * @param string $content String content with which to populate the stream.
+ *
+ * @return StreamInterface
+ */
+ public function createStream(string $content = ''): StreamInterface;
+
+ /**
+ * Create a stream from an existing file.
+ *
+ * The file MUST be opened using the given mode, which may be any mode
+ * supported by the `fopen` function.
+ *
+ * The `$filename` MAY be any string supported by `fopen()`.
+ *
+ * @param string $filename Filename or stream URI to use as basis of stream.
+ * @param string $mode Mode with which to open the underlying filename/stream.
+ *
+ * @return StreamInterface
+ * @throws \RuntimeException If the file cannot be opened.
+ * @throws \InvalidArgumentException If the mode is invalid.
+ */
+ public function createStreamFromFile(string $filename, string $mode = 'r'): StreamInterface;
+
+ /**
+ * Create a new stream from an existing resource.
+ *
+ * The stream MUST be readable and may be writable.
+ *
+ * @param resource $resource PHP resource to use as basis of stream.
+ *
+ * @return StreamInterface
+ */
+ public function createStreamFromResource($resource): StreamInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/UploadedFileFactoryInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/UploadedFileFactoryInterface.php
new file mode 100644
index 0000000..7db4e30
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/UploadedFileFactoryInterface.php
@@ -0,0 +1,34 @@
+<?php
+
+namespace Psr\Http\Message;
+
+interface UploadedFileFactoryInterface
+{
+ /**
+ * Create a new uploaded file.
+ *
+ * If a size is not provided it will be determined by checking the size of
+ * the file.
+ *
+ * @see http://php.net/manual/features.file-upload.post-method.php
+ * @see http://php.net/manual/features.file-upload.errors.php
+ *
+ * @param StreamInterface $stream Underlying stream representing the
+ * uploaded file content.
+ * @param int $size in bytes
+ * @param int $error PHP file upload error
+ * @param string $clientFilename Filename as provided by the client, if any.
+ * @param string $clientMediaType Media type as provided by the client, if any.
+ *
+ * @return UploadedFileInterface
+ *
+ * @throws \InvalidArgumentException If the file resource is not readable.
+ */
+ public function createUploadedFile(
+ StreamInterface $stream,
+ int $size = null,
+ int $error = \UPLOAD_ERR_OK,
+ string $clientFilename = null,
+ string $clientMediaType = null
+ ): UploadedFileInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/UriFactoryInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/UriFactoryInterface.php
new file mode 100644
index 0000000..06df0b4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-factory/src/UriFactoryInterface.php
@@ -0,0 +1,17 @@
+<?php
+
+namespace Psr\Http\Message;
+
+interface UriFactoryInterface
+{
+ /**
+ * Create a new URI.
+ *
+ * @param string $uri
+ *
+ * @return UriInterface
+ *
+ * @throws \InvalidArgumentException If the given URI cannot be parsed.
+ */
+ public function createUri(string $uri = ''): UriInterface;
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/CHANGELOG.md
new file mode 100644
index 0000000..74b1ef9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/CHANGELOG.md
@@ -0,0 +1,36 @@
+# Changelog
+
+All notable changes to this project will be documented in this file, in reverse chronological order by release.
+
+## 1.0.1 - 2016-08-06
+
+### Added
+
+- Nothing.
+
+### Deprecated
+
+- Nothing.
+
+### Removed
+
+- Nothing.
+
+### Fixed
+
+- Updated all `@return self` annotation references in interfaces to use
+ `@return static`, which more closelly follows the semantics of the
+ specification.
+- Updated the `MessageInterface::getHeaders()` return annotation to use the
+ value `string[][]`, indicating the format is a nested array of strings.
+- Updated the `@link` annotation for `RequestInterface::withRequestTarget()`
+ to point to the correct section of RFC 7230.
+- Updated the `ServerRequestInterface::withUploadedFiles()` parameter annotation
+ to add the parameter name (`$uploadedFiles`).
+- Updated a `@throws` annotation for the `UploadedFileInterface::moveTo()`
+ method to correctly reference the method parameter (it was referencing an
+ incorrect parameter name previously).
+
+## 1.0.0 - 2016-05-18
+
+Initial stable release; reflects accepted PSR-7 specification.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/LICENSE
new file mode 100644
index 0000000..c2d8e45
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2014 PHP Framework Interoperability Group
+
+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/psr/http-message/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/README.md
new file mode 100644
index 0000000..2818533
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/README.md
@@ -0,0 +1,13 @@
+PSR Http Message
+================
+
+This repository holds all interfaces/classes/traits related to
+[PSR-7](http://www.php-fig.org/psr/psr-7/).
+
+Note that this is not a HTTP message implementation of its own. It is merely an
+interface that describes a HTTP message. See the specification for more details.
+
+Usage
+-----
+
+We'll certainly need some stuff in here.
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/composer.json
new file mode 100644
index 0000000..b0d2937
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/composer.json
@@ -0,0 +1,26 @@
+{
+ "name": "psr/http-message",
+ "description": "Common interface for HTTP messages",
+ "keywords": ["psr", "psr-7", "http", "http-message", "request", "response"],
+ "homepage": "https://github.com/php-fig/http-message",
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "PHP-FIG",
+ "homepage": "http://www.php-fig.org/"
+ }
+ ],
+ "require": {
+ "php": ">=5.3.0"
+ },
+ "autoload": {
+ "psr-4": {
+ "Psr\\Http\\Message\\": "src/"
+ }
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/MessageInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/MessageInterface.php
new file mode 100644
index 0000000..dd46e5e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/MessageInterface.php
@@ -0,0 +1,187 @@
+<?php
+
+namespace Psr\Http\Message;
+
+/**
+ * HTTP messages consist of requests from a client to a server and responses
+ * from a server to a client. This interface defines the methods common to
+ * each.
+ *
+ * Messages are considered immutable; all methods that might change state MUST
+ * be implemented such that they retain the internal state of the current
+ * message and return an instance that contains the changed state.
+ *
+ * @link http://www.ietf.org/rfc/rfc7230.txt
+ * @link http://www.ietf.org/rfc/rfc7231.txt
+ */
+interface MessageInterface
+{
+ /**
+ * Retrieves the HTTP protocol version as a string.
+ *
+ * The string MUST contain only the HTTP version number (e.g., "1.1", "1.0").
+ *
+ * @return string HTTP protocol version.
+ */
+ public function getProtocolVersion();
+
+ /**
+ * Return an instance with the specified HTTP protocol version.
+ *
+ * The version string MUST contain only the HTTP version number (e.g.,
+ * "1.1", "1.0").
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * new protocol version.
+ *
+ * @param string $version HTTP protocol version
+ * @return static
+ */
+ public function withProtocolVersion($version);
+
+ /**
+ * Retrieves all message header values.
+ *
+ * The keys represent the header name as it will be sent over the wire, and
+ * each value is an array of strings associated with the header.
+ *
+ * // Represent the headers as a string
+ * foreach ($message->getHeaders() as $name => $values) {
+ * echo $name . ": " . implode(", ", $values);
+ * }
+ *
+ * // Emit headers iteratively:
+ * foreach ($message->getHeaders() as $name => $values) {
+ * foreach ($values as $value) {
+ * header(sprintf('%s: %s', $name, $value), false);
+ * }
+ * }
+ *
+ * While header names are not case-sensitive, getHeaders() will preserve the
+ * exact case in which headers were originally specified.
+ *
+ * @return string[][] Returns an associative array of the message's headers. Each
+ * key MUST be a header name, and each value MUST be an array of strings
+ * for that header.
+ */
+ public function getHeaders();
+
+ /**
+ * Checks if a header exists by the given case-insensitive name.
+ *
+ * @param string $name Case-insensitive header field name.
+ * @return bool Returns true if any header names match the given header
+ * name using a case-insensitive string comparison. Returns false if
+ * no matching header name is found in the message.
+ */
+ public function hasHeader($name);
+
+ /**
+ * Retrieves a message header value by the given case-insensitive name.
+ *
+ * This method returns an array of all the header values of the given
+ * case-insensitive header name.
+ *
+ * If the header does not appear in the message, this method MUST return an
+ * empty array.
+ *
+ * @param string $name Case-insensitive header field name.
+ * @return string[] An array of string values as provided for the given
+ * header. If the header does not appear in the message, this method MUST
+ * return an empty array.
+ */
+ public function getHeader($name);
+
+ /**
+ * Retrieves a comma-separated string of the values for a single header.
+ *
+ * This method returns all of the header values of the given
+ * case-insensitive header name as a string concatenated together using
+ * a comma.
+ *
+ * NOTE: Not all header values may be appropriately represented using
+ * comma concatenation. For such headers, use getHeader() instead
+ * and supply your own delimiter when concatenating.
+ *
+ * If the header does not appear in the message, this method MUST return
+ * an empty string.
+ *
+ * @param string $name Case-insensitive header field name.
+ * @return string A string of values as provided for the given header
+ * concatenated together using a comma. If the header does not appear in
+ * the message, this method MUST return an empty string.
+ */
+ public function getHeaderLine($name);
+
+ /**
+ * Return an instance with the provided value replacing the specified header.
+ *
+ * While header names are case-insensitive, the casing of the header will
+ * be preserved by this function, and returned from getHeaders().
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * new and/or updated header and value.
+ *
+ * @param string $name Case-insensitive header field name.
+ * @param string|string[] $value Header value(s).
+ * @return static
+ * @throws \InvalidArgumentException for invalid header names or values.
+ */
+ public function withHeader($name, $value);
+
+ /**
+ * Return an instance with the specified header appended with the given value.
+ *
+ * Existing values for the specified header will be maintained. The new
+ * value(s) will be appended to the existing list. If the header did not
+ * exist previously, it will be added.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * new header and/or value.
+ *
+ * @param string $name Case-insensitive header field name to add.
+ * @param string|string[] $value Header value(s).
+ * @return static
+ * @throws \InvalidArgumentException for invalid header names or values.
+ */
+ public function withAddedHeader($name, $value);
+
+ /**
+ * Return an instance without the specified header.
+ *
+ * Header resolution MUST be done without case-sensitivity.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that removes
+ * the named header.
+ *
+ * @param string $name Case-insensitive header field name to remove.
+ * @return static
+ */
+ public function withoutHeader($name);
+
+ /**
+ * Gets the body of the message.
+ *
+ * @return StreamInterface Returns the body as a stream.
+ */
+ public function getBody();
+
+ /**
+ * Return an instance with the specified message body.
+ *
+ * The body MUST be a StreamInterface object.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return a new instance that has the
+ * new body stream.
+ *
+ * @param StreamInterface $body Body.
+ * @return static
+ * @throws \InvalidArgumentException When the body is not valid.
+ */
+ public function withBody(StreamInterface $body);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/RequestInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/RequestInterface.php
new file mode 100644
index 0000000..a96d4fd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/RequestInterface.php
@@ -0,0 +1,129 @@
+<?php
+
+namespace Psr\Http\Message;
+
+/**
+ * Representation of an outgoing, client-side request.
+ *
+ * Per the HTTP specification, this interface includes properties for
+ * each of the following:
+ *
+ * - Protocol version
+ * - HTTP method
+ * - URI
+ * - Headers
+ * - Message body
+ *
+ * During construction, implementations MUST attempt to set the Host header from
+ * a provided URI if no Host header is provided.
+ *
+ * Requests are considered immutable; all methods that might change state MUST
+ * be implemented such that they retain the internal state of the current
+ * message and return an instance that contains the changed state.
+ */
+interface RequestInterface extends MessageInterface
+{
+ /**
+ * Retrieves the message's request target.
+ *
+ * Retrieves the message's request-target either as it will appear (for
+ * clients), as it appeared at request (for servers), or as it was
+ * specified for the instance (see withRequestTarget()).
+ *
+ * In most cases, this will be the origin-form of the composed URI,
+ * unless a value was provided to the concrete implementation (see
+ * withRequestTarget() below).
+ *
+ * If no URI is available, and no request-target has been specifically
+ * provided, this method MUST return the string "/".
+ *
+ * @return string
+ */
+ public function getRequestTarget();
+
+ /**
+ * Return an instance with the specific request-target.
+ *
+ * If the request needs a non-origin-form request-target — e.g., for
+ * specifying an absolute-form, authority-form, or asterisk-form —
+ * this method may be used to create an instance with the specified
+ * request-target, verbatim.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * changed request target.
+ *
+ * @link http://tools.ietf.org/html/rfc7230#section-5.3 (for the various
+ * request-target forms allowed in request messages)
+ * @param mixed $requestTarget
+ * @return static
+ */
+ public function withRequestTarget($requestTarget);
+
+ /**
+ * Retrieves the HTTP method of the request.
+ *
+ * @return string Returns the request method.
+ */
+ public function getMethod();
+
+ /**
+ * Return an instance with the provided HTTP method.
+ *
+ * While HTTP method names are typically all uppercase characters, HTTP
+ * method names are case-sensitive and thus implementations SHOULD NOT
+ * modify the given string.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * changed request method.
+ *
+ * @param string $method Case-sensitive method.
+ * @return static
+ * @throws \InvalidArgumentException for invalid HTTP methods.
+ */
+ public function withMethod($method);
+
+ /**
+ * Retrieves the URI instance.
+ *
+ * This method MUST return a UriInterface instance.
+ *
+ * @link http://tools.ietf.org/html/rfc3986#section-4.3
+ * @return UriInterface Returns a UriInterface instance
+ * representing the URI of the request.
+ */
+ public function getUri();
+
+ /**
+ * Returns an instance with the provided URI.
+ *
+ * This method MUST update the Host header of the returned request by
+ * default if the URI contains a host component. If the URI does not
+ * contain a host component, any pre-existing Host header MUST be carried
+ * over to the returned request.
+ *
+ * You can opt-in to preserving the original state of the Host header by
+ * setting `$preserveHost` to `true`. When `$preserveHost` is set to
+ * `true`, this method interacts with the Host header in the following ways:
+ *
+ * - If the Host header is missing or empty, and the new URI contains
+ * a host component, this method MUST update the Host header in the returned
+ * request.
+ * - If the Host header is missing or empty, and the new URI does not contain a
+ * host component, this method MUST NOT update the Host header in the returned
+ * request.
+ * - If a Host header is present and non-empty, this method MUST NOT update
+ * the Host header in the returned request.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * new UriInterface instance.
+ *
+ * @link http://tools.ietf.org/html/rfc3986#section-4.3
+ * @param UriInterface $uri New request URI to use.
+ * @param bool $preserveHost Preserve the original state of the Host header.
+ * @return static
+ */
+ public function withUri(UriInterface $uri, $preserveHost = false);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/ResponseInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/ResponseInterface.php
new file mode 100644
index 0000000..c306514
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/ResponseInterface.php
@@ -0,0 +1,68 @@
+<?php
+
+namespace Psr\Http\Message;
+
+/**
+ * Representation of an outgoing, server-side response.
+ *
+ * Per the HTTP specification, this interface includes properties for
+ * each of the following:
+ *
+ * - Protocol version
+ * - Status code and reason phrase
+ * - Headers
+ * - Message body
+ *
+ * Responses are considered immutable; all methods that might change state MUST
+ * be implemented such that they retain the internal state of the current
+ * message and return an instance that contains the changed state.
+ */
+interface ResponseInterface extends MessageInterface
+{
+ /**
+ * Gets the response status code.
+ *
+ * The status code is a 3-digit integer result code of the server's attempt
+ * to understand and satisfy the request.
+ *
+ * @return int Status code.
+ */
+ public function getStatusCode();
+
+ /**
+ * Return an instance with the specified status code and, optionally, reason phrase.
+ *
+ * If no reason phrase is specified, implementations MAY choose to default
+ * to the RFC 7231 or IANA recommended reason phrase for the response's
+ * status code.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * updated status and reason phrase.
+ *
+ * @link http://tools.ietf.org/html/rfc7231#section-6
+ * @link http://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml
+ * @param int $code The 3-digit integer result code to set.
+ * @param string $reasonPhrase The reason phrase to use with the
+ * provided status code; if none is provided, implementations MAY
+ * use the defaults as suggested in the HTTP specification.
+ * @return static
+ * @throws \InvalidArgumentException For invalid status code arguments.
+ */
+ public function withStatus($code, $reasonPhrase = '');
+
+ /**
+ * Gets the response reason phrase associated with the status code.
+ *
+ * Because a reason phrase is not a required element in a response
+ * status line, the reason phrase value MAY be null. Implementations MAY
+ * choose to return the default RFC 7231 recommended reason phrase (or those
+ * listed in the IANA HTTP Status Code Registry) for the response's
+ * status code.
+ *
+ * @link http://tools.ietf.org/html/rfc7231#section-6
+ * @link http://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml
+ * @return string Reason phrase; must return an empty string if none present.
+ */
+ public function getReasonPhrase();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/ServerRequestInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/ServerRequestInterface.php
new file mode 100644
index 0000000..0251234
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/ServerRequestInterface.php
@@ -0,0 +1,261 @@
+<?php
+
+namespace Psr\Http\Message;
+
+/**
+ * Representation of an incoming, server-side HTTP request.
+ *
+ * Per the HTTP specification, this interface includes properties for
+ * each of the following:
+ *
+ * - Protocol version
+ * - HTTP method
+ * - URI
+ * - Headers
+ * - Message body
+ *
+ * Additionally, it encapsulates all data as it has arrived to the
+ * application from the CGI and/or PHP environment, including:
+ *
+ * - The values represented in $_SERVER.
+ * - Any cookies provided (generally via $_COOKIE)
+ * - Query string arguments (generally via $_GET, or as parsed via parse_str())
+ * - Upload files, if any (as represented by $_FILES)
+ * - Deserialized body parameters (generally from $_POST)
+ *
+ * $_SERVER values MUST be treated as immutable, as they represent application
+ * state at the time of request; as such, no methods are provided to allow
+ * modification of those values. The other values provide such methods, as they
+ * can be restored from $_SERVER or the request body, and may need treatment
+ * during the application (e.g., body parameters may be deserialized based on
+ * content type).
+ *
+ * Additionally, this interface recognizes the utility of introspecting a
+ * request to derive and match additional parameters (e.g., via URI path
+ * matching, decrypting cookie values, deserializing non-form-encoded body
+ * content, matching authorization headers to users, etc). These parameters
+ * are stored in an "attributes" property.
+ *
+ * Requests are considered immutable; all methods that might change state MUST
+ * be implemented such that they retain the internal state of the current
+ * message and return an instance that contains the changed state.
+ */
+interface ServerRequestInterface extends RequestInterface
+{
+ /**
+ * Retrieve server parameters.
+ *
+ * Retrieves data related to the incoming request environment,
+ * typically derived from PHP's $_SERVER superglobal. The data IS NOT
+ * REQUIRED to originate from $_SERVER.
+ *
+ * @return array
+ */
+ public function getServerParams();
+
+ /**
+ * Retrieve cookies.
+ *
+ * Retrieves cookies sent by the client to the server.
+ *
+ * The data MUST be compatible with the structure of the $_COOKIE
+ * superglobal.
+ *
+ * @return array
+ */
+ public function getCookieParams();
+
+ /**
+ * Return an instance with the specified cookies.
+ *
+ * The data IS NOT REQUIRED to come from the $_COOKIE superglobal, but MUST
+ * be compatible with the structure of $_COOKIE. Typically, this data will
+ * be injected at instantiation.
+ *
+ * This method MUST NOT update the related Cookie header of the request
+ * instance, nor related values in the server params.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * updated cookie values.
+ *
+ * @param array $cookies Array of key/value pairs representing cookies.
+ * @return static
+ */
+ public function withCookieParams(array $cookies);
+
+ /**
+ * Retrieve query string arguments.
+ *
+ * Retrieves the deserialized query string arguments, if any.
+ *
+ * Note: the query params might not be in sync with the URI or server
+ * params. If you need to ensure you are only getting the original
+ * values, you may need to parse the query string from `getUri()->getQuery()`
+ * or from the `QUERY_STRING` server param.
+ *
+ * @return array
+ */
+ public function getQueryParams();
+
+ /**
+ * Return an instance with the specified query string arguments.
+ *
+ * These values SHOULD remain immutable over the course of the incoming
+ * request. They MAY be injected during instantiation, such as from PHP's
+ * $_GET superglobal, or MAY be derived from some other value such as the
+ * URI. In cases where the arguments are parsed from the URI, the data
+ * MUST be compatible with what PHP's parse_str() would return for
+ * purposes of how duplicate query parameters are handled, and how nested
+ * sets are handled.
+ *
+ * Setting query string arguments MUST NOT change the URI stored by the
+ * request, nor the values in the server params.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * updated query string arguments.
+ *
+ * @param array $query Array of query string arguments, typically from
+ * $_GET.
+ * @return static
+ */
+ public function withQueryParams(array $query);
+
+ /**
+ * Retrieve normalized file upload data.
+ *
+ * This method returns upload metadata in a normalized tree, with each leaf
+ * an instance of Psr\Http\Message\UploadedFileInterface.
+ *
+ * These values MAY be prepared from $_FILES or the message body during
+ * instantiation, or MAY be injected via withUploadedFiles().
+ *
+ * @return array An array tree of UploadedFileInterface instances; an empty
+ * array MUST be returned if no data is present.
+ */
+ public function getUploadedFiles();
+
+ /**
+ * Create a new instance with the specified uploaded files.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * updated body parameters.
+ *
+ * @param array $uploadedFiles An array tree of UploadedFileInterface instances.
+ * @return static
+ * @throws \InvalidArgumentException if an invalid structure is provided.
+ */
+ public function withUploadedFiles(array $uploadedFiles);
+
+ /**
+ * Retrieve any parameters provided in the request body.
+ *
+ * If the request Content-Type is either application/x-www-form-urlencoded
+ * or multipart/form-data, and the request method is POST, this method MUST
+ * return the contents of $_POST.
+ *
+ * Otherwise, this method may return any results of deserializing
+ * the request body content; as parsing returns structured content, the
+ * potential types MUST be arrays or objects only. A null value indicates
+ * the absence of body content.
+ *
+ * @return null|array|object The deserialized body parameters, if any.
+ * These will typically be an array or object.
+ */
+ public function getParsedBody();
+
+ /**
+ * Return an instance with the specified body parameters.
+ *
+ * These MAY be injected during instantiation.
+ *
+ * If the request Content-Type is either application/x-www-form-urlencoded
+ * or multipart/form-data, and the request method is POST, use this method
+ * ONLY to inject the contents of $_POST.
+ *
+ * The data IS NOT REQUIRED to come from $_POST, but MUST be the results of
+ * deserializing the request body content. Deserialization/parsing returns
+ * structured data, and, as such, this method ONLY accepts arrays or objects,
+ * or a null value if nothing was available to parse.
+ *
+ * As an example, if content negotiation determines that the request data
+ * is a JSON payload, this method could be used to create a request
+ * instance with the deserialized parameters.
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * updated body parameters.
+ *
+ * @param null|array|object $data The deserialized body data. This will
+ * typically be in an array or object.
+ * @return static
+ * @throws \InvalidArgumentException if an unsupported argument type is
+ * provided.
+ */
+ public function withParsedBody($data);
+
+ /**
+ * Retrieve attributes derived from the request.
+ *
+ * The request "attributes" may be used to allow injection of any
+ * parameters derived from the request: e.g., the results of path
+ * match operations; the results of decrypting cookies; the results of
+ * deserializing non-form-encoded message bodies; etc. Attributes
+ * will be application and request specific, and CAN be mutable.
+ *
+ * @return array Attributes derived from the request.
+ */
+ public function getAttributes();
+
+ /**
+ * Retrieve a single derived request attribute.
+ *
+ * Retrieves a single derived request attribute as described in
+ * getAttributes(). If the attribute has not been previously set, returns
+ * the default value as provided.
+ *
+ * This method obviates the need for a hasAttribute() method, as it allows
+ * specifying a default value to return if the attribute is not found.
+ *
+ * @see getAttributes()
+ * @param string $name The attribute name.
+ * @param mixed $default Default value to return if the attribute does not exist.
+ * @return mixed
+ */
+ public function getAttribute($name, $default = null);
+
+ /**
+ * Return an instance with the specified derived request attribute.
+ *
+ * This method allows setting a single derived request attribute as
+ * described in getAttributes().
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that has the
+ * updated attribute.
+ *
+ * @see getAttributes()
+ * @param string $name The attribute name.
+ * @param mixed $value The value of the attribute.
+ * @return static
+ */
+ public function withAttribute($name, $value);
+
+ /**
+ * Return an instance that removes the specified derived request attribute.
+ *
+ * This method allows removing a single derived request attribute as
+ * described in getAttributes().
+ *
+ * This method MUST be implemented in such a way as to retain the
+ * immutability of the message, and MUST return an instance that removes
+ * the attribute.
+ *
+ * @see getAttributes()
+ * @param string $name The attribute name.
+ * @return static
+ */
+ public function withoutAttribute($name);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/StreamInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/StreamInterface.php
new file mode 100644
index 0000000..f68f391
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/StreamInterface.php
@@ -0,0 +1,158 @@
+<?php
+
+namespace Psr\Http\Message;
+
+/**
+ * Describes a data stream.
+ *
+ * Typically, an instance will wrap a PHP stream; this interface provides
+ * a wrapper around the most common operations, including serialization of
+ * the entire stream to a string.
+ */
+interface StreamInterface
+{
+ /**
+ * Reads all data from the stream into a string, from the beginning to end.
+ *
+ * This method MUST attempt to seek to the beginning of the stream before
+ * reading data and read the stream until the end is reached.
+ *
+ * Warning: This could attempt to load a large amount of data into memory.
+ *
+ * This method MUST NOT raise an exception in order to conform with PHP's
+ * string casting operations.
+ *
+ * @see http://php.net/manual/en/language.oop5.magic.php#object.tostring
+ * @return string
+ */
+ public function __toString();
+
+ /**
+ * Closes the stream and any underlying resources.
+ *
+ * @return void
+ */
+ public function close();
+
+ /**
+ * Separates any underlying resources from the stream.
+ *
+ * After the stream has been detached, the stream is in an unusable state.
+ *
+ * @return resource|null Underlying PHP stream, if any
+ */
+ public function detach();
+
+ /**
+ * Get the size of the stream if known.
+ *
+ * @return int|null Returns the size in bytes if known, or null if unknown.
+ */
+ public function getSize();
+
+ /**
+ * Returns the current position of the file read/write pointer
+ *
+ * @return int Position of the file pointer
+ * @throws \RuntimeException on error.
+ */
+ public function tell();
+
+ /**
+ * Returns true if the stream is at the end of the stream.
+ *
+ * @return bool
+ */
+ public function eof();
+
+ /**
+ * Returns whether or not the stream is seekable.
+ *
+ * @return bool
+ */
+ public function isSeekable();
+
+ /**
+ * Seek to a position in the stream.
+ *
+ * @link http://www.php.net/manual/en/function.fseek.php
+ * @param int $offset Stream offset
+ * @param int $whence Specifies how the cursor position will be calculated
+ * based on the seek offset. Valid values are identical to the built-in
+ * PHP $whence values for `fseek()`. SEEK_SET: Set position equal to
+ * offset bytes SEEK_CUR: Set position to current location plus offset
+ * SEEK_END: Set position to end-of-stream plus offset.
+ * @throws \RuntimeException on failure.
+ */
+ public function seek($offset, $whence = SEEK_SET);
+
+ /**
+ * Seek to the beginning of the stream.
+ *
+ * If the stream is not seekable, this method will raise an exception;
+ * otherwise, it will perform a seek(0).
+ *
+ * @see seek()
+ * @link http://www.php.net/manual/en/function.fseek.php
+ * @throws \RuntimeException on failure.
+ */
+ public function rewind();
+
+ /**
+ * Returns whether or not the stream is writable.
+ *
+ * @return bool
+ */
+ public function isWritable();
+
+ /**
+ * Write data to the stream.
+ *
+ * @param string $string The string that is to be written.
+ * @return int Returns the number of bytes written to the stream.
+ * @throws \RuntimeException on failure.
+ */
+ public function write($string);
+
+ /**
+ * Returns whether or not the stream is readable.
+ *
+ * @return bool
+ */
+ public function isReadable();
+
+ /**
+ * Read data from the stream.
+ *
+ * @param int $length Read up to $length bytes from the object and return
+ * them. Fewer than $length bytes may be returned if underlying stream
+ * call returns fewer bytes.
+ * @return string Returns the data read from the stream, or an empty string
+ * if no bytes are available.
+ * @throws \RuntimeException if an error occurs.
+ */
+ public function read($length);
+
+ /**
+ * Returns the remaining contents in a string
+ *
+ * @return string
+ * @throws \RuntimeException if unable to read or an error occurs while
+ * reading.
+ */
+ public function getContents();
+
+ /**
+ * Get stream metadata as an associative array or retrieve a specific key.
+ *
+ * The keys returned are identical to the keys returned from PHP's
+ * stream_get_meta_data() function.
+ *
+ * @link http://php.net/manual/en/function.stream-get-meta-data.php
+ * @param string $key Specific metadata to retrieve.
+ * @return array|mixed|null Returns an associative array if no key is
+ * provided. Returns a specific key value if a key is provided and the
+ * value is found, or null if the key is not found.
+ */
+ public function getMetadata($key = null);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/UploadedFileInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/UploadedFileInterface.php
new file mode 100644
index 0000000..f8a6901
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/UploadedFileInterface.php
@@ -0,0 +1,123 @@
+<?php
+
+namespace Psr\Http\Message;
+
+/**
+ * Value object representing a file uploaded through an HTTP request.
+ *
+ * Instances of this interface are considered immutable; all methods that
+ * might change state MUST be implemented such that they retain the internal
+ * state of the current instance and return an instance that contains the
+ * changed state.
+ */
+interface UploadedFileInterface
+{
+ /**
+ * Retrieve a stream representing the uploaded file.
+ *
+ * This method MUST return a StreamInterface instance, representing the
+ * uploaded file. The purpose of this method is to allow utilizing native PHP
+ * stream functionality to manipulate the file upload, such as
+ * stream_copy_to_stream() (though the result will need to be decorated in a
+ * native PHP stream wrapper to work with such functions).
+ *
+ * If the moveTo() method has been called previously, this method MUST raise
+ * an exception.
+ *
+ * @return StreamInterface Stream representation of the uploaded file.
+ * @throws \RuntimeException in cases when no stream is available or can be
+ * created.
+ */
+ public function getStream();
+
+ /**
+ * Move the uploaded file to a new location.
+ *
+ * Use this method as an alternative to move_uploaded_file(). This method is
+ * guaranteed to work in both SAPI and non-SAPI environments.
+ * Implementations must determine which environment they are in, and use the
+ * appropriate method (move_uploaded_file(), rename(), or a stream
+ * operation) to perform the operation.
+ *
+ * $targetPath may be an absolute path, or a relative path. If it is a
+ * relative path, resolution should be the same as used by PHP's rename()
+ * function.
+ *
+ * The original file or stream MUST be removed on completion.
+ *
+ * If this method is called more than once, any subsequent calls MUST raise
+ * an exception.
+ *
+ * When used in an SAPI environment where $_FILES is populated, when writing
+ * files via moveTo(), is_uploaded_file() and move_uploaded_file() SHOULD be
+ * used to ensure permissions and upload status are verified correctly.
+ *
+ * If you wish to move to a stream, use getStream(), as SAPI operations
+ * cannot guarantee writing to stream destinations.
+ *
+ * @see http://php.net/is_uploaded_file
+ * @see http://php.net/move_uploaded_file
+ * @param string $targetPath Path to which to move the uploaded file.
+ * @throws \InvalidArgumentException if the $targetPath specified is invalid.
+ * @throws \RuntimeException on any error during the move operation, or on
+ * the second or subsequent call to the method.
+ */
+ public function moveTo($targetPath);
+
+ /**
+ * Retrieve the file size.
+ *
+ * Implementations SHOULD return the value stored in the "size" key of
+ * the file in the $_FILES array if available, as PHP calculates this based
+ * on the actual size transmitted.
+ *
+ * @return int|null The file size in bytes or null if unknown.
+ */
+ public function getSize();
+
+ /**
+ * Retrieve the error associated with the uploaded file.
+ *
+ * The return value MUST be one of PHP's UPLOAD_ERR_XXX constants.
+ *
+ * If the file was uploaded successfully, this method MUST return
+ * UPLOAD_ERR_OK.
+ *
+ * Implementations SHOULD return the value stored in the "error" key of
+ * the file in the $_FILES array.
+ *
+ * @see http://php.net/manual/en/features.file-upload.errors.php
+ * @return int One of PHP's UPLOAD_ERR_XXX constants.
+ */
+ public function getError();
+
+ /**
+ * Retrieve the filename sent by the client.
+ *
+ * Do not trust the value returned by this method. A client could send
+ * a malicious filename with the intention to corrupt or hack your
+ * application.
+ *
+ * Implementations SHOULD return the value stored in the "name" key of
+ * the file in the $_FILES array.
+ *
+ * @return string|null The filename sent by the client or null if none
+ * was provided.
+ */
+ public function getClientFilename();
+
+ /**
+ * Retrieve the media type sent by the client.
+ *
+ * Do not trust the value returned by this method. A client could send
+ * a malicious media type with the intention to corrupt or hack your
+ * application.
+ *
+ * Implementations SHOULD return the value stored in the "type" key of
+ * the file in the $_FILES array.
+ *
+ * @return string|null The media type sent by the client or null if none
+ * was provided.
+ */
+ public function getClientMediaType();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/UriInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/UriInterface.php
new file mode 100644
index 0000000..9d7ab9e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/psr/http-message/src/UriInterface.php
@@ -0,0 +1,323 @@
+<?php
+namespace Psr\Http\Message;
+
+/**
+ * Value object representing a URI.
+ *
+ * This interface is meant to represent URIs according to RFC 3986 and to
+ * provide methods for most common operations. Additional functionality for
+ * working with URIs can be provided on top of the interface or externally.
+ * Its primary use is for HTTP requests, but may also be used in other
+ * contexts.
+ *
+ * Instances of this interface are considered immutable; all methods that
+ * might change state MUST be implemented such that they retain the internal
+ * state of the current instance and return an instance that contains the
+ * changed state.
+ *
+ * Typically the Host header will be also be present in the request message.
+ * For server-side requests, the scheme will typically be discoverable in the
+ * server parameters.
+ *
+ * @link http://tools.ietf.org/html/rfc3986 (the URI specification)
+ */
+interface UriInterface
+{
+ /**
+ * Retrieve the scheme component of the URI.
+ *
+ * If no scheme is present, this method MUST return an empty string.
+ *
+ * The value returned MUST be normalized to lowercase, per RFC 3986
+ * Section 3.1.
+ *
+ * The trailing ":" character is not part of the scheme and MUST NOT be
+ * added.
+ *
+ * @see https://tools.ietf.org/html/rfc3986#section-3.1
+ * @return string The URI scheme.
+ */
+ public function getScheme();
+
+ /**
+ * Retrieve the authority component of the URI.
+ *
+ * If no authority information is present, this method MUST return an empty
+ * string.
+ *
+ * The authority syntax of the URI is:
+ *
+ * <pre>
+ * [user-info@]host[:port]
+ * </pre>
+ *
+ * If the port component is not set or is the standard port for the current
+ * scheme, it SHOULD NOT be included.
+ *
+ * @see https://tools.ietf.org/html/rfc3986#section-3.2
+ * @return string The URI authority, in "[user-info@]host[:port]" format.
+ */
+ public function getAuthority();
+
+ /**
+ * Retrieve the user information component of the URI.
+ *
+ * If no user information is present, this method MUST return an empty
+ * string.
+ *
+ * If a user is present in the URI, this will return that value;
+ * additionally, if the password is also present, it will be appended to the
+ * user value, with a colon (":") separating the values.
+ *
+ * The trailing "@" character is not part of the user information and MUST
+ * NOT be added.
+ *
+ * @return string The URI user information, in "username[:password]" format.
+ */
+ public function getUserInfo();
+
+ /**
+ * Retrieve the host component of the URI.
+ *
+ * If no host is present, this method MUST return an empty string.
+ *
+ * The value returned MUST be normalized to lowercase, per RFC 3986
+ * Section 3.2.2.
+ *
+ * @see http://tools.ietf.org/html/rfc3986#section-3.2.2
+ * @return string The URI host.
+ */
+ public function getHost();
+
+ /**
+ * Retrieve the port component of the URI.
+ *
+ * If a port is present, and it is non-standard for the current scheme,
+ * this method MUST return it as an integer. If the port is the standard port
+ * used with the current scheme, this method SHOULD return null.
+ *
+ * If no port is present, and no scheme is present, this method MUST return
+ * a null value.
+ *
+ * If no port is present, but a scheme is present, this method MAY return
+ * the standard port for that scheme, but SHOULD return null.
+ *
+ * @return null|int The URI port.
+ */
+ public function getPort();
+
+ /**
+ * Retrieve the path component of the URI.
+ *
+ * The path can either be empty or absolute (starting with a slash) or
+ * rootless (not starting with a slash). Implementations MUST support all
+ * three syntaxes.
+ *
+ * Normally, the empty path "" and absolute path "/" are considered equal as
+ * defined in RFC 7230 Section 2.7.3. But this method MUST NOT automatically
+ * do this normalization because in contexts with a trimmed base path, e.g.
+ * the front controller, this difference becomes significant. It's the task
+ * of the user to handle both "" and "/".
+ *
+ * The value returned MUST be percent-encoded, but MUST NOT double-encode
+ * any characters. To determine what characters to encode, please refer to
+ * RFC 3986, Sections 2 and 3.3.
+ *
+ * As an example, if the value should include a slash ("/") not intended as
+ * delimiter between path segments, that value MUST be passed in encoded
+ * form (e.g., "%2F") to the instance.
+ *
+ * @see https://tools.ietf.org/html/rfc3986#section-2
+ * @see https://tools.ietf.org/html/rfc3986#section-3.3
+ * @return string The URI path.
+ */
+ public function getPath();
+
+ /**
+ * Retrieve the query string of the URI.
+ *
+ * If no query string is present, this method MUST return an empty string.
+ *
+ * The leading "?" character is not part of the query and MUST NOT be
+ * added.
+ *
+ * The value returned MUST be percent-encoded, but MUST NOT double-encode
+ * any characters. To determine what characters to encode, please refer to
+ * RFC 3986, Sections 2 and 3.4.
+ *
+ * As an example, if a value in a key/value pair of the query string should
+ * include an ampersand ("&") not intended as a delimiter between values,
+ * that value MUST be passed in encoded form (e.g., "%26") to the instance.
+ *
+ * @see https://tools.ietf.org/html/rfc3986#section-2
+ * @see https://tools.ietf.org/html/rfc3986#section-3.4
+ * @return string The URI query string.
+ */
+ public function getQuery();
+
+ /**
+ * Retrieve the fragment component of the URI.
+ *
+ * If no fragment is present, this method MUST return an empty string.
+ *
+ * The leading "#" character is not part of the fragment and MUST NOT be
+ * added.
+ *
+ * The value returned MUST be percent-encoded, but MUST NOT double-encode
+ * any characters. To determine what characters to encode, please refer to
+ * RFC 3986, Sections 2 and 3.5.
+ *
+ * @see https://tools.ietf.org/html/rfc3986#section-2
+ * @see https://tools.ietf.org/html/rfc3986#section-3.5
+ * @return string The URI fragment.
+ */
+ public function getFragment();
+
+ /**
+ * Return an instance with the specified scheme.
+ *
+ * This method MUST retain the state of the current instance, and return
+ * an instance that contains the specified scheme.
+ *
+ * Implementations MUST support the schemes "http" and "https" case
+ * insensitively, and MAY accommodate other schemes if required.
+ *
+ * An empty scheme is equivalent to removing the scheme.
+ *
+ * @param string $scheme The scheme to use with the new instance.
+ * @return static A new instance with the specified scheme.
+ * @throws \InvalidArgumentException for invalid or unsupported schemes.
+ */
+ public function withScheme($scheme);
+
+ /**
+ * Return an instance with the specified user information.
+ *
+ * This method MUST retain the state of the current instance, and return
+ * an instance that contains the specified user information.
+ *
+ * Password is optional, but the user information MUST include the
+ * user; an empty string for the user is equivalent to removing user
+ * information.
+ *
+ * @param string $user The user name to use for authority.
+ * @param null|string $password The password associated with $user.
+ * @return static A new instance with the specified user information.
+ */
+ public function withUserInfo($user, $password = null);
+
+ /**
+ * Return an instance with the specified host.
+ *
+ * This method MUST retain the state of the current instance, and return
+ * an instance that contains the specified host.
+ *
+ * An empty host value is equivalent to removing the host.
+ *
+ * @param string $host The hostname to use with the new instance.
+ * @return static A new instance with the specified host.
+ * @throws \InvalidArgumentException for invalid hostnames.
+ */
+ public function withHost($host);
+
+ /**
+ * Return an instance with the specified port.
+ *
+ * This method MUST retain the state of the current instance, and return
+ * an instance that contains the specified port.
+ *
+ * Implementations MUST raise an exception for ports outside the
+ * established TCP and UDP port ranges.
+ *
+ * A null value provided for the port is equivalent to removing the port
+ * information.
+ *
+ * @param null|int $port The port to use with the new instance; a null value
+ * removes the port information.
+ * @return static A new instance with the specified port.
+ * @throws \InvalidArgumentException for invalid ports.
+ */
+ public function withPort($port);
+
+ /**
+ * Return an instance with the specified path.
+ *
+ * This method MUST retain the state of the current instance, and return
+ * an instance that contains the specified path.
+ *
+ * The path can either be empty or absolute (starting with a slash) or
+ * rootless (not starting with a slash). Implementations MUST support all
+ * three syntaxes.
+ *
+ * If the path is intended to be domain-relative rather than path relative then
+ * it must begin with a slash ("/"). Paths not starting with a slash ("/")
+ * are assumed to be relative to some base path known to the application or
+ * consumer.
+ *
+ * Users can provide both encoded and decoded path characters.
+ * Implementations ensure the correct encoding as outlined in getPath().
+ *
+ * @param string $path The path to use with the new instance.
+ * @return static A new instance with the specified path.
+ * @throws \InvalidArgumentException for invalid paths.
+ */
+ public function withPath($path);
+
+ /**
+ * Return an instance with the specified query string.
+ *
+ * This method MUST retain the state of the current instance, and return
+ * an instance that contains the specified query string.
+ *
+ * Users can provide both encoded and decoded query characters.
+ * Implementations ensure the correct encoding as outlined in getQuery().
+ *
+ * An empty query string value is equivalent to removing the query string.
+ *
+ * @param string $query The query string to use with the new instance.
+ * @return static A new instance with the specified query string.
+ * @throws \InvalidArgumentException for invalid query strings.
+ */
+ public function withQuery($query);
+
+ /**
+ * Return an instance with the specified URI fragment.
+ *
+ * This method MUST retain the state of the current instance, and return
+ * an instance that contains the specified URI fragment.
+ *
+ * Users can provide both encoded and decoded fragment characters.
+ * Implementations ensure the correct encoding as outlined in getFragment().
+ *
+ * An empty fragment value is equivalent to removing the fragment.
+ *
+ * @param string $fragment The fragment to use with the new instance.
+ * @return static A new instance with the specified fragment.
+ */
+ public function withFragment($fragment);
+
+ /**
+ * Return the string representation as a URI reference.
+ *
+ * Depending on which components of the URI are present, the resulting
+ * string is either a full URI or relative reference according to RFC 3986,
+ * Section 4.1. The method concatenates the various components of the URI,
+ * using the appropriate delimiters:
+ *
+ * - If a scheme is present, it MUST be suffixed by ":".
+ * - If an authority is present, it MUST be prefixed by "//".
+ * - The path can be concatenated without delimiters. But there are two
+ * cases where the path has to be adjusted to make the URI reference
+ * valid as PHP does not allow to throw an exception in __toString():
+ * - If the path is rootless and an authority is present, the path MUST
+ * be prefixed by "/".
+ * - If the path is starting with more than one "/" and no authority is
+ * present, the starting slashes MUST be reduced to one.
+ * - If a query is present, it MUST be prefixed by "?".
+ * - If a fragment is present, it MUST be prefixed by "#".
+ *
+ * @see http://tools.ietf.org/html/rfc3986#section-4.1
+ * @return string
+ */
+ public function __toString();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/LICENSE
new file mode 100644
index 0000000..be5540c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014 Ralph Khattar
+
+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/ralouphie/getallheaders/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/README.md
new file mode 100644
index 0000000..9430d76
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/README.md
@@ -0,0 +1,27 @@
+getallheaders
+=============
+
+PHP `getallheaders()` polyfill. Compatible with PHP >= 5.3.
+
+[](https://travis-ci.org/ralouphie/getallheaders)
+[](https://coveralls.io/r/ralouphie/getallheaders?branch=master)
+[](https://packagist.org/packages/ralouphie/getallheaders)
+[](https://packagist.org/packages/ralouphie/getallheaders)
+[](https://packagist.org/packages/ralouphie/getallheaders)
+
+
+This is a simple polyfill for [`getallheaders()`](http://www.php.net/manual/en/function.getallheaders.php).
+
+## Install
+
+For PHP version **`>= 5.6`**:
+
+```
+composer require ralouphie/getallheaders
+```
+
+For PHP version **`< 5.6`**:
+
+```
+composer require ralouphie/getallheaders "^2"
+```
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/composer.json
new file mode 100644
index 0000000..de8ce62
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/composer.json
@@ -0,0 +1,26 @@
+{
+ "name": "ralouphie/getallheaders",
+ "description": "A polyfill for getallheaders.",
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "Ralph Khattar",
+ "email": "ralph.khattar@gmail.com"
+ }
+ ],
+ "require": {
+ "php": ">=5.6"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^5 || ^6.5",
+ "php-coveralls/php-coveralls": "^2.1"
+ },
+ "autoload": {
+ "files": ["src/getallheaders.php"]
+ },
+ "autoload-dev": {
+ "psr-4": {
+ "getallheaders\\Tests\\": "tests/"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/src/getallheaders.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/src/getallheaders.php
new file mode 100644
index 0000000..c7285a5
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/ralouphie/getallheaders/src/getallheaders.php
@@ -0,0 +1,46 @@
+<?php
+
+if (!function_exists('getallheaders')) {
+
+ /**
+ * Get all HTTP header key/values as an associative array for the current request.
+ *
+ * @return string[string] The HTTP header key/value pairs.
+ */
+ function getallheaders()
+ {
+ $headers = array();
+
+ $copy_server = array(
+ 'CONTENT_TYPE' => 'Content-Type',
+ 'CONTENT_LENGTH' => 'Content-Length',
+ 'CONTENT_MD5' => 'Content-Md5',
+ );
+
+ foreach ($_SERVER as $key => $value) {
+ if (substr($key, 0, 5) === 'HTTP_') {
+ $key = substr($key, 5);
+ if (!isset($copy_server[$key]) || !isset($_SERVER[$key])) {
+ $key = str_replace(' ', '-', ucwords(strtolower(str_replace('_', ' ', $key))));
+ $headers[$key] = $value;
+ }
+ } elseif (isset($copy_server[$key])) {
+ $headers[$copy_server[$key]] = $value;
+ }
+ }
+
+ if (!isset($headers['Authorization'])) {
+ if (isset($_SERVER['REDIRECT_HTTP_AUTHORIZATION'])) {
+ $headers['Authorization'] = $_SERVER['REDIRECT_HTTP_AUTHORIZATION'];
+ } elseif (isset($_SERVER['PHP_AUTH_USER'])) {
+ $basic_pass = isset($_SERVER['PHP_AUTH_PW']) ? $_SERVER['PHP_AUTH_PW'] : '';
+ $headers['Authorization'] = 'Basic ' . base64_encode($_SERVER['PHP_AUTH_USER'] . ':' . $basic_pass);
+ } elseif (isset($_SERVER['PHP_AUTH_DIGEST'])) {
+ $headers['Authorization'] = $_SERVER['PHP_AUTH_DIGEST'];
+ }
+ }
+
+ return $headers;
+ }
+
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.gitignore b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.gitignore
new file mode 100644
index 0000000..e8c7cb6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.gitignore
@@ -0,0 +1,4 @@
+/build
+/vendor
+composer.phar
+composer.lock
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.scrutinizer.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.scrutinizer.yml
new file mode 100644
index 0000000..1f831e8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.scrutinizer.yml
@@ -0,0 +1,35 @@
+filter:
+ excluded_paths: [test/*]
+checks:
+ php:
+ code_rating: true
+ remove_extra_empty_lines: true
+ remove_php_closing_tag: true
+ remove_trailing_whitespace: true
+ fix_use_statements:
+ remove_unused: true
+ preserve_multiple: false
+ preserve_blanklines: true
+ order_alphabetically: true
+ fix_php_opening_tag: true
+ fix_linefeed: true
+ fix_line_ending: true
+ fix_identation_4spaces: true
+ fix_doc_comments: true
+tools:
+ external_code_coverage:
+ timeout: 600
+ runs: 2
+ php_analyzer: true
+ php_code_coverage: false
+ php_code_sniffer:
+ config:
+ standard: PSR2
+ filter:
+ paths: ['src']
+ php_loc:
+ enabled: true
+ excluded_dirs: [examples, vendor, test]
+ php_cpd:
+ enabled: true
+ excluded_dirs: [examples, vendor, test]
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.travis.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.travis.yml
new file mode 100644
index 0000000..c5f3825
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/.travis.yml
@@ -0,0 +1,29 @@
+language: php
+
+sudo: false
+
+php:
+ - 7.2
+ - 7.3
+ - 7.4
+ - 8.0
+ - 8.1
+ - 8.2
+
+matrix:
+ include:
+ - php: 5.6
+ env: 'COMPOSER_FLAGS="--prefer-stable --prefer-lowest"'
+
+before_script:
+ - travis_retry composer self-update
+ - travis_retry composer install --no-interaction --prefer-source --dev
+ - travis_retry phpenv rehash
+
+script:
+ - ./vendor/bin/phpcs --standard=psr2 src/
+ - ./vendor/bin/phpunit --coverage-text --coverage-clover=coverage.clover
+
+after_script:
+ - wget https://scrutinizer-ci.com/ocular.phar
+ - php ocular.phar code-coverage:upload --format=php-clover coverage.clover
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/CHANGELOG.md
new file mode 100644
index 0000000..e1990de
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/CHANGELOG.md
@@ -0,0 +1,74 @@
+# Changelog
+All Notable changes to `oauth2-keycloak` will be documented in this file
+
+## 2.1.0 - 2018-03-12
+
+### Added
+- Introduce `getLogoutUrl` method on provider to build and return and authorized logout url - thanks @FlxPeters
+
+### Deprecated
+- Nothing
+
+### Fixed
+- Nothing
+
+### Removed
+- Nothing
+
+### Security
+- Nothing
+
+## 2.0.0 - 2017-01-25
+
+### Added
+- PHP 7.1 Support
+
+### Deprecated
+- Nothing
+
+### Fixed
+- Nothing
+
+### Removed
+- PHP 5.5 Support
+
+### Security
+- Nothing
+
+## 1.0.0 - 2017-01-25
+
+Bump for base package parity
+
+## 0.2.0 - 2016-12-07
+
+### Added
+- JSON Web Token decryption support
+
+### Deprecated
+- Nothing
+
+### Fixed
+- Nothing
+
+### Removed
+- Nothing
+
+### Security
+- Nothing
+
+## 0.1.0 - 2015-08-31
+
+### Added
+- Initial release!
+
+### Deprecated
+- Nothing
+
+### Fixed
+- Nothing
+
+### Removed
+- Nothing
+
+### Security
+- Nothing
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/CONTRIBUTING.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/CONTRIBUTING.md
new file mode 100644
index 0000000..e1e0781
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/CONTRIBUTING.md
@@ -0,0 +1,42 @@
+# Contributing
+
+Contributions are **welcome** and will be fully **credited**.
+
+We accept contributions via Pull Requests on [Github](https://github.com/stevenmaguire/oauth2-keycloak).
+
+
+## Pull Requests
+
+- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](http://pear.php.net/package/PHP_CodeSniffer).
+
+- **Add tests!** - Your patch won't be accepted if it doesn't have tests.
+
+- **Document any change in behaviour** - Make sure the README and any other relevant documentation are kept up-to-date.
+
+- **Consider our release cycle** - We try to follow SemVer. Randomly breaking public APIs is not an option.
+
+- **Create topic branches** - Don't ask us to pull from your master branch.
+
+- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests.
+
+- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please squash them before submitting.
+
+- **Ensure tests pass!** - Please run the tests (see below) before submitting your pull request, and make sure they pass. We won't accept a patch until all tests pass.
+
+- **Ensure no coding standards violations** - Please run PHP Code Sniffer using the PSR-2 standard (see below) before submitting your pull request. A violation will cause the build to fail, so please make sure there are no violations. We can't accept a patch if the build fails.
+
+
+## Running Tests
+
+``` bash
+$ ./vendor/bin/phpunit
+```
+
+
+## Running PHP Code Sniffer
+
+``` bash
+$ ./vendor/bin/phpcs src --standard=psr2 -sp
+```
+
+**Happy coding**!
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/LICENSE
new file mode 100644
index 0000000..51455e2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2015 Steven Maguire
+
+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/stevenmaguire/oauth2-keycloak/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/README.md
new file mode 100644
index 0000000..d0b1aca
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/README.md
@@ -0,0 +1,176 @@
+# Keycloak Provider for OAuth 2.0 Client
+[](https://github.com/stevenmaguire/oauth2-keycloak/releases)
+[](LICENSE.md)
+[](https://travis-ci.org/stevenmaguire/oauth2-keycloak)
+[](https://scrutinizer-ci.com/g/stevenmaguire/oauth2-keycloak/code-structure)
+[](https://scrutinizer-ci.com/g/stevenmaguire/oauth2-keycloak)
+[](https://packagist.org/packages/stevenmaguire/oauth2-keycloak)
+
+This package provides Keycloak OAuth 2.0 support for the PHP League's [OAuth 2.0 Client](https://github.com/thephpleague/oauth2-client).
+
+## Installation
+
+To install, use composer:
+
+```
+composer require stevenmaguire/oauth2-keycloak
+```
+
+## Usage
+
+Usage is the same as The League's OAuth client, using `\Stevenmaguire\OAuth2\Client\Provider\Keycloak` as the provider.
+
+Use `authServerUrl` to specify the Keycloak server URL. You can lookup the correct value from the Keycloak client installer JSON under `auth-server-url`, eg. `http://localhost:8080/auth`.
+
+Use `realm` to specify the Keycloak realm name. You can lookup the correct value from the Keycloak client installer JSON under `resource`, eg. `master`.
+
+### Authorization Code Flow
+
+```php
+$provider = new Stevenmaguire\OAuth2\Client\Provider\Keycloak([
+ 'authServerUrl' => '{keycloak-server-url}',
+ 'realm' => '{keycloak-realm}',
+ 'clientId' => '{keycloak-client-id}',
+ 'clientSecret' => '{keycloak-client-secret}',
+ 'redirectUri' => 'https://example.com/callback-url',
+ 'encryptionAlgorithm' => 'RS256', // optional
+ 'encryptionKeyPath' => '../key.pem' // optional
+ 'encryptionKey' => 'contents_of_key_or_certificate' // optional
+ 'version' => '20.0.1', // optional
+]);
+
+if (!isset($_GET['code'])) {
+
+ // If we don't have an authorization code then get one
+ $authUrl = $provider->getAuthorizationUrl();
+ $_SESSION['oauth2state'] = $provider->getState();
+ header('Location: '.$authUrl);
+ exit;
+
+// Check given state against previously stored one to mitigate CSRF attack
+} elseif (empty($_GET['state']) || ($_GET['state'] !== $_SESSION['oauth2state'])) {
+
+ unset($_SESSION['oauth2state']);
+ exit('Invalid state, make sure HTTP sessions are enabled.');
+
+} else {
+
+ // Try to get an access token (using the authorization coe grant)
+ try {
+ $token = $provider->getAccessToken('authorization_code', [
+ 'code' => $_GET['code']
+ ]);
+ } catch (Exception $e) {
+ exit('Failed to get access token: '.$e->getMessage());
+ }
+
+ // Optional: Now you have a token you can look up a users profile data
+ try {
+
+ // We got an access token, let's now get the user's details
+ $user = $provider->getResourceOwner($token);
+
+ // Use these details to create a new profile
+ printf('Hello %s!', $user->getName());
+
+ } catch (Exception $e) {
+ exit('Failed to get resource owner: '.$e->getMessage());
+ }
+
+ // Use this to interact with an API on the users behalf
+ echo $token->getToken();
+}
+```
+
+### Refreshing a Token
+
+```php
+$provider = new Stevenmaguire\OAuth2\Client\Provider\Keycloak([
+ 'authServerUrl' => '{keycloak-server-url}',
+ 'realm' => '{keycloak-realm}',
+ 'clientId' => '{keycloak-client-id}',
+ 'clientSecret' => '{keycloak-client-secret}',
+ 'redirectUri' => 'https://example.com/callback-url',
+]);
+
+$token = $provider->getAccessToken('refresh_token', ['refresh_token' => $token->getRefreshToken()]);
+```
+
+### Handling encryption
+
+If you've configured your Keycloak instance to use encryption, there are some advanced options available to you.
+
+#### Configure the provider to use the same encryption algorithm
+
+```php
+$provider = new Stevenmaguire\OAuth2\Client\Provider\Keycloak([
+ // ...
+ 'encryptionAlgorithm' => 'RS256',
+]);
+```
+
+or
+
+```php
+$provider->setEncryptionAlgorithm('RS256');
+```
+
+#### Configure the provider to use the expected decryption public key or certificate
+
+##### By key value
+
+```php
+$key = "-----BEGIN PUBLIC KEY-----\n....\n-----END PUBLIC KEY-----";
+// or
+// $key = "-----BEGIN CERTIFICATE-----\n....\n-----END CERTIFICATE-----";
+
+$provider = new Stevenmaguire\OAuth2\Client\Provider\Keycloak([
+ // ...
+ 'encryptionKey' => $key,
+]);
+```
+
+or
+
+```php
+$provider->setEncryptionKey($key);
+```
+
+##### By key path
+
+```php
+$keyPath = '../key.pem';
+
+$provider = new Stevenmaguire\OAuth2\Client\Provider\Keycloak([
+ // ...
+ 'encryptionKeyPath' => $keyPath,
+]);
+```
+
+or
+
+```php
+$provider->setEncryptionKeyPath($keyPath);
+```
+
+## Testing
+
+``` bash
+$ ./vendor/bin/phpunit
+```
+
+## Contributing
+
+Please see [CONTRIBUTING](https://github.com/stevenmaguire/oauth2-keycloak/blob/master/CONTRIBUTING.md) for details.
+
+
+## Credits
+
+- [Steven Maguire](https://github.com/stevenmaguire)
+- [Martin Stefan](https://github.com/mstefan21)
+- [All Contributors](https://github.com/stevenmaguire/oauth2-keycloak/contributors)
+
+
+## License
+
+The MIT License (MIT). Please see [License File](https://github.com/stevenmaguire/oauth2-keycloak/blob/master/LICENSE) for more information.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/composer.json
new file mode 100644
index 0000000..b6a5447
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/composer.json
@@ -0,0 +1,51 @@
+{
+ "name": "stevenmaguire/oauth2-keycloak",
+ "description": "Keycloak OAuth 2.0 Client Provider for The PHP League OAuth2-Client",
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "Steven Maguire",
+ "email": "stevenmaguire@gmail.com",
+ "homepage": "https://github.com/stevenmaguire"
+ }
+ ],
+ "keywords": [
+ "oauth",
+ "oauth2",
+ "client",
+ "authorization",
+ "authorisation",
+ "keycloak"
+ ],
+ "require": {
+ "php": "~7.2 || ~8.0",
+ "league/oauth2-client": "^2.0",
+ "firebase/php-jwt": "^4.0 || ^5.0 || ^6.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "~9.6.4",
+ "mockery/mockery": "~1.5.0",
+ "squizlabs/php_codesniffer": "~3.7.0"
+ },
+ "autoload": {
+ "psr-4": {
+ "Stevenmaguire\\OAuth2\\Client\\": "src/"
+ }
+ },
+ "autoload-dev": {
+ "psr-4": {
+ "Stevenmaguire\\OAuth2\\Client\\Test\\": "test/src/"
+ }
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.0.x-dev"
+ }
+ },
+ "scripts": {
+ "test": [
+ "@putenv XDEBUG_MODE=coverage",
+ "phpunit --colors=always"
+ ]
+ }
+}
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/examples/index.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/examples/index.php
new file mode 100644
index 0000000..398333f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/examples/index.php
@@ -0,0 +1,53 @@
+<?php
+
+require 'vendor/autoload.php';
+
+session_start();
+
+$provider = new Stevenmaguire\OAuth2\Client\Provider\Keycloak([
+ 'authServerUrl' => '',
+ 'realm' => '',
+ 'clientId' => '',
+ 'clientSecret' => '',
+ 'redirectUri' => '',
+ 'encryptionAlgorithm' => null,
+ 'encryptionKey' => null,
+ 'encryptionKeyPath' => null
+]);
+
+if (!isset($_GET['code'])) {
+ // If we don't have an authorization code then get one
+ $authUrl = $provider->getAuthorizationUrl();
+ $_SESSION['oauth2state'] = $provider->getState();
+ header('Location: '.$authUrl);
+ exit;
+
+// Check given state against previously stored one to mitigate CSRF attack
+} elseif (empty($_GET['state']) || ($_GET['state'] !== $_SESSION['oauth2state'])) {
+ unset($_SESSION['oauth2state']);
+ exit('Invalid state, make sure HTTP sessions are enabled.');
+} else {
+ // Try to get an access token (using the authorization coe grant)
+ try {
+ $token = $provider->getAccessToken('authorization_code', [
+ 'code' => $_GET['code']
+ ]);
+ } catch (Exception $e) {
+ exit('Failed to get access token: '.$e->getMessage());
+ }
+
+ // Optional: Now you have a token you can look up a users profile data
+ try {
+
+ // We got an access token, let's now get the user's details
+ $user = $provider->getResourceOwner($token);
+ // Use these details to create a new profile
+ printf('Hello %s!\n<br>', $user->getName());
+
+ } catch (Exception $e) {
+ exit('Failed to get resource owner: '.$e->getMessage());
+ }
+
+ // Use this to interact with an API on the users behalf
+ echo $token->getToken();
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/phpunit.xml.dist b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/phpunit.xml.dist
new file mode 100644
index 0000000..b915f93
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/phpunit.xml.dist
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<phpunit backupGlobals="false"
+ bootstrap="vendor/autoload.php"
+ colors="true"
+ processIsolation="false"
+ stopOnFailure="false"
+ failOnRisky="true"
+ failOnWarning="true"
+>
+ <coverage includeUncoveredFiles="true"
+ pathCoverage="false"
+ ignoreDeprecatedCodeUnits="true"
+ disableCodeCoverageIgnore="true">
+ <include>
+ <directory suffix=".php">src</directory>
+ </include>
+ <exclude>
+ <directory suffix=".php">vendor</directory>
+ <file>src/autoload.php</file>
+ </exclude>
+ <report>
+ <html outputDirectory="./build/coverage/html"
+ lowUpperBound="35"
+ highLowerBound="70"/>
+ <clover outputFile="./build/coverage/log/coverage.xml"/>
+ </report>
+ </coverage>
+ <testsuites>
+ <testsuite name="Package Test Suite">
+ <directory suffix=".php">./test/</directory>
+ </testsuite>
+ </testsuites>
+</phpunit>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/Exception/EncryptionConfigurationException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/Exception/EncryptionConfigurationException.php
new file mode 100644
index 0000000..546d2de
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/Exception/EncryptionConfigurationException.php
@@ -0,0 +1,22 @@
+<?php
+
+namespace Stevenmaguire\OAuth2\Client\Provider\Exception;
+
+use Exception;
+
+class EncryptionConfigurationException extends Exception
+{
+ /**
+ * Returns properly formatted exception when response decryption fails.
+ *
+ * @return \Stevenmaguire\OAuth2\Client\Provider\Exception\EncryptionConfigurationException
+ */
+ public static function undeterminedEncryption()
+ {
+ return new static(
+ 'The given response may be encrypted and sufficient '.
+ 'encryption configuration has not been provided.',
+ 400
+ );
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/Keycloak.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/Keycloak.php
new file mode 100644
index 0000000..bc41a71
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/Keycloak.php
@@ -0,0 +1,387 @@
+<?php
+
+namespace Stevenmaguire\OAuth2\Client\Provider;
+
+use Exception;
+use Firebase\JWT\JWT;
+use League\OAuth2\Client\Provider\AbstractProvider;
+use League\OAuth2\Client\Provider\Exception\IdentityProviderException;
+use League\OAuth2\Client\Token\AccessToken;
+use League\OAuth2\Client\Tool\BearerAuthorizationTrait;
+use Psr\Http\Message\ResponseInterface;
+use Stevenmaguire\OAuth2\Client\Provider\Exception\EncryptionConfigurationException;
+use UnexpectedValueException;
+
+class Keycloak extends AbstractProvider
+{
+ use BearerAuthorizationTrait;
+
+ /**
+ * Keycloak URL, eg. http://localhost:8080/auth.
+ *
+ * @var string
+ */
+ public $authServerUrl = null;
+
+ /**
+ * Realm name, eg. demo.
+ *
+ * @var string
+ */
+ public $realm = null;
+
+ /**
+ * Encryption algorithm.
+ *
+ * You must specify supported algorithms for your application. See
+ * https://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms-40
+ * for a list of spec-compliant algorithms.
+ *
+ * @var string
+ */
+ public $encryptionAlgorithm = null;
+
+ /**
+ * Encryption key.
+ *
+ * @var string
+ */
+ public $encryptionKey = null;
+
+ /**
+ * Keycloak version.
+ *
+ * @var string
+ */
+ public $version = null;
+
+ /**
+ * Constructs an OAuth 2.0 service provider.
+ *
+ * @param array $options An array of options to set on this provider.
+ * Options include `clientId`, `clientSecret`, `redirectUri`, and `state`.
+ * Individual providers may introduce more options, as needed.
+ * @param array $collaborators An array of collaborators that may be used to
+ * override this provider's default behavior. Collaborators include
+ * `grantFactory`, `requestFactory`, `httpClient`, and `randomFactory`.
+ * Individual providers may introduce more collaborators, as needed.
+ */
+ public function __construct(array $options = [], array $collaborators = [])
+ {
+ if (isset($options['encryptionKeyPath'])) {
+ $this->setEncryptionKeyPath($options['encryptionKeyPath']);
+ unset($options['encryptionKeyPath']);
+ }
+
+ if (isset($options['version'])) {
+ $this->setVersion($options['version']);
+ }
+
+ parent::__construct($options, $collaborators);
+ }
+
+ /**
+ * Attempts to decrypt the given response.
+ *
+ * @param string|array|null $response
+ *
+ * @return string|array|null
+ */
+ public function decryptResponse($response)
+ {
+ if (!is_string($response)) {
+ return $response;
+ }
+
+ if ($this->usesEncryption()) {
+ return json_decode(
+ json_encode(
+ JWT::decode(
+ $response,
+ $this->encryptionKey,
+ array($this->encryptionAlgorithm)
+ )
+ ),
+ true
+ );
+ }
+
+ throw EncryptionConfigurationException::undeterminedEncryption();
+ }
+
+ /**
+ * Get authorization url to begin OAuth flow
+ *
+ * @return string
+ */
+ public function getBaseAuthorizationUrl()
+ {
+ return $this->getBaseUrlWithRealm().'/protocol/openid-connect/auth';
+ }
+
+ /**
+ * Get access token url to retrieve token
+ *
+ * @param array $params
+ *
+ * @return string
+ */
+ public function getBaseAccessTokenUrl(array $params)
+ {
+ return $this->getBaseUrlWithRealm().'/protocol/openid-connect/token';
+ }
+
+ /**
+ * Get provider url to fetch user details
+ *
+ * @param AccessToken $token
+ *
+ * @return string
+ */
+ public function getResourceOwnerDetailsUrl(AccessToken $token)
+ {
+ return $this->getBaseUrlWithRealm().'/protocol/openid-connect/userinfo';
+ }
+
+ /**
+ * Builds the logout URL.
+ *
+ * @param array $options
+ * @return string Authorization URL
+ */
+ public function getLogoutUrl(array $options = [])
+ {
+ $base = $this->getBaseLogoutUrl();
+ $params = $this->getAuthorizationParameters($options);
+
+ // Starting with keycloak 18.0.0, the parameter redirect_uri is no longer supported on logout.
+ // As of this version the parameter is called post_logout_redirect_uri. In addition to this
+ // a parameter id_token_hint has to be provided.
+ if ($this->validateGteVersion('18.0.0')) {
+ if (isset($options['access_token']) === true) {
+ $accessToken = $options['access_token'];
+
+ $params['id_token_hint'] = $accessToken->getValues()['id_token'];
+ $params['post_logout_redirect_uri'] = $params['redirect_uri'];
+ }
+
+ unset($params['redirect_uri']);
+ }
+
+ $query = $this->getAuthorizationQuery($params);
+ return $this->appendQuery($base, $query);
+ }
+
+ /**
+ * Get logout url to logout of session token
+ *
+ * @return string
+ */
+ private function getBaseLogoutUrl()
+ {
+ return $this->getBaseUrlWithRealm() . '/protocol/openid-connect/logout';
+ }
+
+ /**
+ * Creates base url from provider configuration.
+ *
+ * @return string
+ */
+ protected function getBaseUrlWithRealm()
+ {
+ return $this->authServerUrl.'/realms/'.$this->realm;
+ }
+
+ /**
+ * Get the default scopes used by this provider.
+ *
+ * This should not be a complete list of all scopes, but the minimum
+ * required for the provider user interface!
+ *
+ * @return string[]
+ */
+ protected function getDefaultScopes()
+ {
+ $scopes = [
+ 'profile',
+ 'email'
+ ];
+ if ($this->validateGteVersion('20.0.0')) {
+ $scopes[] = 'openid';
+ }
+ return $scopes;
+ }
+
+ /**
+ * Returns the string that should be used to separate scopes when building
+ * the URL for requesting an access token.
+ *
+ * @return string Scope separator, defaults to ','
+ */
+ protected function getScopeSeparator()
+ {
+ return ' ';
+ }
+
+
+ /**
+ * Check a provider response for errors.
+ *
+ * @throws IdentityProviderException
+ * @param ResponseInterface $response
+ * @param string $data Parsed response data
+ * @return void
+ */
+ protected function checkResponse(ResponseInterface $response, $data)
+ {
+ if (!empty($data['error'])) {
+ $error = $data['error'];
+ if (isset($data['error_description'])) {
+ $error.=': '.$data['error_description'];
+ }
+ throw new IdentityProviderException($error, 0, $data);
+ }
+ }
+
+ /**
+ * Generate a user object from a successful user details request.
+ *
+ * @param array $response
+ * @param AccessToken $token
+ * @return KeycloakResourceOwner
+ */
+ protected function createResourceOwner(array $response, AccessToken $token)
+ {
+ return new KeycloakResourceOwner($response);
+ }
+
+ /**
+ * Requests and returns the resource owner of given access token.
+ *
+ * @param AccessToken $token
+ * @return KeycloakResourceOwner
+ * @throws EncryptionConfigurationException
+ */
+ public function getResourceOwner(AccessToken $token)
+ {
+ $response = $this->fetchResourceOwnerDetails($token);
+
+ // We are always getting an array. We have to check if it is
+ // the array we created
+ if (array_key_exists('jwt', $response)) {
+ $response = $response['jwt'];
+ }
+
+ $response = $this->decryptResponse($response);
+
+ return $this->createResourceOwner($response, $token);
+ }
+
+ /**
+ * Updates expected encryption algorithm of Keycloak instance.
+ *
+ * @param string $encryptionAlgorithm
+ *
+ * @return Keycloak
+ */
+ public function setEncryptionAlgorithm($encryptionAlgorithm)
+ {
+ $this->encryptionAlgorithm = $encryptionAlgorithm;
+
+ return $this;
+ }
+
+ /**
+ * Updates expected encryption key of Keycloak instance.
+ *
+ * @param string $encryptionKey
+ *
+ * @return Keycloak
+ */
+ public function setEncryptionKey($encryptionKey)
+ {
+ $this->encryptionKey = $encryptionKey;
+
+ return $this;
+ }
+
+ /**
+ * Updates expected encryption key of Keycloak instance to content of given
+ * file path.
+ *
+ * @param string $encryptionKeyPath
+ *
+ * @return Keycloak
+ */
+ public function setEncryptionKeyPath($encryptionKeyPath)
+ {
+ try {
+ $this->encryptionKey = file_get_contents($encryptionKeyPath);
+ } catch (Exception $e) {
+ // Not sure how to handle this yet.
+ }
+
+ return $this;
+ }
+
+ /**
+ * Updates the keycloak version.
+ *
+ * @param string $version
+ *
+ * @return Keycloak
+ */
+ public function setVersion($version)
+ {
+ $this->version = $version;
+
+ return $this;
+ }
+
+ /**
+ * Checks if provider is configured to use encryption.
+ *
+ * @return bool
+ */
+ public function usesEncryption()
+ {
+ return (bool) $this->encryptionAlgorithm && $this->encryptionKey;
+ }
+
+ /**
+ * Parses the response according to its content-type header.
+ *
+ * @throws UnexpectedValueException
+ * @param ResponseInterface $response
+ * @return array
+ */
+ protected function parseResponse(ResponseInterface $response)
+ {
+ // We have a problem with keycloak when the userinfo responses
+ // with a jwt token
+ // Because it just return a jwt as string with the header
+ // application/jwt
+ // This can't be parsed to a array
+ // Dont know why this function only allow an array as return value...
+ $content = (string) $response->getBody();
+ $type = $this->getContentType($response);
+
+ if (strpos($type, 'jwt') !== false) {
+ // Here we make the temporary array
+ return ['jwt' => $content];
+ }
+
+ return parent::parseResponse($response);
+ }
+
+ /**
+ * Validate if version is greater or equal
+ *
+ * @param string $version
+ * @return bool
+ */
+ private function validateGteVersion($version)
+ {
+ return (isset($this->version) && version_compare($this->version, $version, '>='));
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/KeycloakResourceOwner.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/KeycloakResourceOwner.php
new file mode 100644
index 0000000..7587af7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/src/Provider/KeycloakResourceOwner.php
@@ -0,0 +1,65 @@
+<?php
+
+namespace Stevenmaguire\OAuth2\Client\Provider;
+
+use League\OAuth2\Client\Provider\ResourceOwnerInterface;
+
+class KeycloakResourceOwner implements ResourceOwnerInterface
+{
+ /**
+ * Raw response
+ *
+ * @var array
+ */
+ protected $response;
+
+ /**
+ * Creates new resource owner.
+ *
+ * @param array $response
+ */
+ public function __construct(array $response = array())
+ {
+ $this->response = $response;
+ }
+
+ /**
+ * Get resource owner id
+ *
+ * @return string|null
+ */
+ public function getId()
+ {
+ return \array_key_exists('sub', $this->response) ? $this->response['sub'] : null;
+ }
+
+ /**
+ * Get resource owner email
+ *
+ * @return string|null
+ */
+ public function getEmail()
+ {
+ return \array_key_exists('email', $this->response) ? $this->response['email'] : null;
+ }
+
+ /**
+ * Get resource owner name
+ *
+ * @return string|null
+ */
+ public function getName()
+ {
+ return \array_key_exists('name', $this->response) ? $this->response['name'] : null;
+ }
+
+ /**
+ * Return all of the owner details available as an array.
+ *
+ * @return array
+ */
+ public function toArray()
+ {
+ return $this->response;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/test/src/Provider/KeycloakTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/test/src/Provider/KeycloakTest.php
new file mode 100644
index 0000000..a5c1da1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/stevenmaguire/oauth2-keycloak/test/src/Provider/KeycloakTest.php
@@ -0,0 +1,342 @@
+<?php
+
+namespace
+{
+ $mockFileGetContents = null;
+}
+
+namespace Stevenmaguire\OAuth2\Client\Provider
+{
+ function file_get_contents()
+ {
+ global $mockFileGetContents;
+ if (isset($mockFileGetContents) && ! is_null($mockFileGetContents)) {
+ if (is_a($mockFileGetContents, 'Exception')) {
+ throw $mockFileGetContents;
+ }
+ return $mockFileGetContents;
+ } else {
+ return call_user_func_array('\file_get_contents', func_get_args());
+ }
+ }
+}
+
+namespace Stevenmaguire\OAuth2\Client\Test\Provider
+{
+ use League\OAuth2\Client\Provider\Exception\IdentityProviderException;
+ use League\OAuth2\Client\Tool\QueryBuilderTrait;
+ use Mockery as m;
+ use PHPUnit\Framework\TestCase;
+ use Stevenmaguire\OAuth2\Client\Provider\Exception\EncryptionConfigurationException;
+ use Stevenmaguire\OAuth2\Client\Provider\Keycloak;
+
+ class KeycloakTest extends TestCase
+ {
+ use QueryBuilderTrait;
+
+ protected $provider;
+
+ protected function setUp(): void
+ {
+ $this->provider = new Keycloak([
+ 'authServerUrl' => 'http://mock.url/auth',
+ 'realm' => 'mock_realm',
+ 'clientId' => 'mock_client_id',
+ 'clientSecret' => 'mock_secret',
+ 'redirectUri' => 'none',
+ ]);
+ }
+
+ public function tearDown(): void
+ {
+ m::close();
+ parent::tearDown();
+ }
+
+ public function testAuthorizationUrl()
+ {
+ $url = $this->provider->getAuthorizationUrl();
+ $uri = parse_url($url);
+ parse_str($uri['query'], $query);
+
+ $this->assertArrayHasKey('client_id', $query);
+ $this->assertArrayHasKey('redirect_uri', $query);
+ $this->assertArrayHasKey('state', $query);
+ $this->assertArrayHasKey('scope', $query);
+ $this->assertArrayHasKey('response_type', $query);
+ $this->assertArrayHasKey('approval_prompt', $query);
+ $this->assertNotNull($this->provider->getState());
+ }
+
+ public function testEncryptionAlgorithm()
+ {
+ $algorithm = uniqid();
+ $provider = new Keycloak([
+ 'encryptionAlgorithm' => $algorithm,
+ ]);
+
+ $this->assertEquals($algorithm, $provider->encryptionAlgorithm);
+
+ $algorithm = uniqid();
+ $provider->setEncryptionAlgorithm($algorithm);
+
+ $this->assertEquals($algorithm, $provider->encryptionAlgorithm);
+ }
+
+ public function testEncryptionKey()
+ {
+ $key = uniqid();
+ $provider = new Keycloak([
+ 'encryptionKey' => $key,
+ ]);
+
+ $this->assertEquals($key, $provider->encryptionKey);
+
+ $key = uniqid();
+ $provider->setEncryptionKey($key);
+
+ $this->assertEquals($key, $provider->encryptionKey);
+ }
+
+ public function testEncryptionKeyPath()
+ {
+ global $mockFileGetContents;
+ $path = uniqid();
+ $key = uniqid();
+ $mockFileGetContents = $key;
+
+ $provider = new Keycloak([
+ 'encryptionKeyPath' => $path,
+ ]);
+
+ $this->assertEquals($key, $provider->encryptionKey);
+
+ $path = uniqid();
+ $key = uniqid();
+ $mockFileGetContents = $key;
+
+ $provider->setEncryptionKeyPath($path);
+
+ $this->assertEquals($key, $provider->encryptionKey);
+ }
+
+ public function testEncryptionKeyPathFails()
+ {
+ $this->markTestIncomplete('Need to assess the test to see what is required to be checked.');
+
+ global $mockFileGetContents;
+ $path = uniqid();
+ $key = uniqid();
+ $mockFileGetContents = new \Exception();
+
+ $provider = new Keycloak([
+ 'encryptionKeyPath' => $path,
+ ]);
+
+ $provider->setEncryptionKeyPath($path);
+ }
+
+ public function testScopes()
+ {
+ $scopeSeparator = ' ';
+ $options = ['scope' => [uniqid(), uniqid()]];
+ $query = ['scope' => implode($scopeSeparator, $options['scope'])];
+ $url = $this->provider->getAuthorizationUrl($options);
+ $encodedScope = $this->buildQueryString($query);
+ $this->assertStringContainsString($encodedScope, $url);
+ }
+
+ public function testGetAuthorizationUrl()
+ {
+ $url = $this->provider->getAuthorizationUrl();
+ $uri = parse_url($url);
+
+ $this->assertEquals('/auth/realms/mock_realm/protocol/openid-connect/auth', $uri['path']);
+ }
+
+ public function testGetLogoutUrl()
+ {
+ $url = $this->provider->getLogoutUrl();
+ $uri = parse_url($url);
+
+ $this->assertEquals('/auth/realms/mock_realm/protocol/openid-connect/logout', $uri['path']);
+ }
+
+ public function testGetBaseAccessTokenUrl()
+ {
+ $params = [];
+
+ $url = $this->provider->getBaseAccessTokenUrl($params);
+ $uri = parse_url($url);
+
+ $this->assertEquals('/auth/realms/mock_realm/protocol/openid-connect/token', $uri['path']);
+ }
+
+ public function testGetAccessToken()
+ {
+ $response = m::mock('Psr\Http\Message\ResponseInterface');
+ $response->shouldReceive('getBody')
+ ->andReturn('{"access_token":"mock_access_token", "scope":"email", "token_type":"bearer"}');
+ $response->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'json']);
+
+ $client = m::mock('GuzzleHttp\ClientInterface');
+ $client->shouldReceive('send')
+ ->times(1)
+ ->andReturn($response);
+ $this->provider->setHttpClient($client);
+
+ $token = $this->provider->getAccessToken('authorization_code', ['code' => 'mock_authorization_code']);
+
+ $this->assertEquals('mock_access_token', $token->getToken());
+ $this->assertNull($token->getExpires());
+ $this->assertNull($token->getRefreshToken());
+ $this->assertNull($token->getResourceOwnerId());
+ }
+
+ public function testUserData()
+ {
+ $userId = rand(1000, 9999);
+ $name = uniqid();
+ $nickname = uniqid();
+ $email = uniqid();
+
+ $postResponse = m::mock('Psr\Http\Message\ResponseInterface');
+ $postResponse->shouldReceive('getBody')
+ ->andReturn(
+ 'access_token=mock_access_token&expires=3600&refresh_token=mock_refresh_token&otherKey={1234}'
+ );
+ $postResponse->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'application/x-www-form-urlencoded']);
+
+ $userResponse = m::mock('Psr\Http\Message\ResponseInterface');
+ $userResponse->shouldReceive('getBody')
+ ->andReturn('{"sub": '.$userId.', "name": "'.$name.'", "email": "'.$email.'"}');
+ $userResponse->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'json']);
+
+ $client = m::mock('GuzzleHttp\ClientInterface');
+ $client->shouldReceive('send')
+ ->times(2)
+ ->andReturn($postResponse, $userResponse);
+ $this->provider->setHttpClient($client);
+
+ $token = $this->provider->getAccessToken('authorization_code', ['code' => 'mock_authorization_code']);
+ $user = $this->provider->getResourceOwner($token);
+
+ $this->assertEquals($userId, $user->getId());
+ $this->assertEquals($userId, $user->toArray()['sub']);
+ $this->assertEquals($name, $user->getName());
+ $this->assertEquals($name, $user->toArray()['name']);
+ $this->assertEquals($email, $user->getEmail());
+ $this->assertEquals($email, $user->toArray()['email']);
+ }
+
+ public function testUserDataWithEncryption()
+ {
+ $userId = rand(1000, 9999);
+ $name = uniqid();
+ $nickname = uniqid();
+ $email = uniqid();
+ $jwt = uniqid();
+ $algorithm = uniqid();
+ $key = uniqid();
+
+ $postResponse = m::mock('Psr\Http\Message\ResponseInterface');
+ $postResponse->shouldReceive('getBody')
+ ->andReturn(
+ 'access_token=mock_access_token&expires=3600&refresh_token=mock_refresh_token&otherKey={1234}'
+ );
+ $postResponse->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'application/x-www-form-urlencoded']);
+ $postResponse->shouldReceive('getStatusCode')
+ ->andReturn(200);
+
+ $userResponse = m::mock('Psr\Http\Message\ResponseInterface');
+ $userResponse->shouldReceive('getBody')
+ ->andReturn($jwt);
+ $userResponse->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'application/jwt']);
+ $userResponse->shouldReceive('getStatusCode')
+ ->andReturn(200);
+
+ $decoder = \Mockery::mock('overload:Firebase\JWT\JWT');
+ $decoder->shouldReceive('decode')
+ ->with($jwt, $key, [$algorithm])
+ ->andReturn([
+ 'sub' => $userId,
+ 'email' => $email,
+ 'name' => $name,
+ ]);
+
+ $client = m::mock('GuzzleHttp\ClientInterface');
+ $client->shouldReceive('send')
+ ->times(2)
+ ->andReturn($postResponse, $userResponse);
+ $this->provider->setHttpClient($client);
+
+ $token = $this->provider->setEncryptionAlgorithm($algorithm)
+ ->setEncryptionKey($key)
+ ->getAccessToken('authorization_code', ['code' => 'mock_authorization_code']);
+ $user = $this->provider->getResourceOwner($token);
+
+ $this->assertEquals($userId, $user->getId());
+ $this->assertEquals($userId, $user->toArray()['sub']);
+ $this->assertEquals($name, $user->getName());
+ $this->assertEquals($name, $user->toArray()['name']);
+ $this->assertEquals($email, $user->getEmail());
+ $this->assertEquals($email, $user->toArray()['email']);
+ }
+
+ public function testUserDataFailsWhenEncryptionEncounteredAndNotConfigured()
+ {
+ $this->expectException(EncryptionConfigurationException::class);
+
+ $postResponse = m::mock('Psr\Http\Message\ResponseInterface');
+ $postResponse->shouldReceive('getBody')
+ ->andReturn(
+ 'access_token=mock_access_token&expires=3600&refresh_token=mock_refresh_token&otherKey={1234}'
+ );
+ $postResponse->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'application/x-www-form-urlencoded']);
+ $postResponse->shouldReceive('getStatusCode')
+ ->andReturn(200);
+
+ $userResponse = m::mock('Psr\Http\Message\ResponseInterface');
+ $userResponse->shouldReceive('getBody')
+ ->andReturn(uniqid());
+ $userResponse->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'application/jwt']);
+ $userResponse->shouldReceive('getStatusCode')
+ ->andReturn(200);
+
+ $client = m::mock('GuzzleHttp\ClientInterface');
+ $client->shouldReceive('send')
+ ->times(2)
+ ->andReturn($postResponse, $userResponse);
+ $this->provider->setHttpClient($client);
+
+ $token = $this->provider->getAccessToken('authorization_code', ['code' => 'mock_authorization_code']);
+ $user = $this->provider->getResourceOwner($token);
+ }
+
+ public function testErrorResponse()
+ {
+ $this->expectException(IdentityProviderException::class);
+
+ $response = m::mock('Psr\Http\Message\ResponseInterface');
+ $response->shouldReceive('getBody')
+ ->andReturn('{"error": "invalid_grant", "error_description": "Code not found"}');
+ $response->shouldReceive('getHeader')
+ ->andReturn(['content-type' => 'json']);
+
+ $client = m::mock('GuzzleHttp\ClientInterface');
+ $client->shouldReceive('send')
+ ->times(1)
+ ->andReturn($response);
+ $this->provider->setHttpClient($client);
+
+ $token = $this->provider->getAccessToken('authorization_code', ['code' => 'mock_authorization_code']);
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/CHANGELOG.md
new file mode 100644
index 0000000..7932e26
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/CHANGELOG.md
@@ -0,0 +1,5 @@
+CHANGELOG
+=========
+
+The changelog is maintained for all Symfony contracts at the following URL:
+https://github.com/symfony/contracts/blob/main/CHANGELOG.md
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/LICENSE
new file mode 100644
index 0000000..0ed3a24
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2020-present 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/deprecation-contracts/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/README.md
new file mode 100644
index 0000000..9814864
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/README.md
@@ -0,0 +1,26 @@
+Symfony Deprecation Contracts
+=============================
+
+A generic function and convention to trigger deprecation notices.
+
+This package provides a single global function named `trigger_deprecation()` that triggers silenced deprecation notices.
+
+By using a custom PHP error handler such as the one provided by the Symfony ErrorHandler component,
+the triggered deprecations can be caught and logged for later discovery, both on dev and prod environments.
+
+The function requires at least 3 arguments:
+ - the name of the Composer package that is triggering the deprecation
+ - the version of the package that introduced the deprecation
+ - the message of the deprecation
+ - more arguments can be provided: they will be inserted in the message using `printf()` formatting
+
+Example:
+```php
+trigger_deprecation('symfony/blockchain', '8.9', 'Using "%s" is deprecated, use "%s" instead.', 'bitcoin', 'fabcoin');
+```
+
+This will generate the following message:
+`Since symfony/blockchain 8.9: Using "bitcoin" is deprecated, use "fabcoin" instead.`
+
+While not recommended, the deprecation notices can be completely ignored by declaring an empty
+`function trigger_deprecation() {}` in your application.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/composer.json
new file mode 100644
index 0000000..ceb6c07
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/composer.json
@@ -0,0 +1,35 @@
+{
+ "name": "symfony/deprecation-contracts",
+ "type": "library",
+ "description": "A generic function and convention to trigger deprecation notices",
+ "homepage": "https://symfony.com",
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "Nicolas Grekas",
+ "email": "p@tchwork.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "require": {
+ "php": ">=8.1"
+ },
+ "autoload": {
+ "files": [
+ "function.php"
+ ]
+ },
+ "minimum-stability": "dev",
+ "extra": {
+ "branch-alias": {
+ "dev-main": "3.5-dev"
+ },
+ "thanks": {
+ "name": "symfony/contracts",
+ "url": "https://github.com/symfony/contracts"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/function.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/function.php
new file mode 100644
index 0000000..2d56512
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/deprecation-contracts/function.php
@@ -0,0 +1,27 @@
+<?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.
+ */
+
+if (!function_exists('trigger_deprecation')) {
+ /**
+ * Triggers a silenced deprecation notice.
+ *
+ * @param string $package The name of the Composer package that is triggering the deprecation
+ * @param string $version The version of the package that introduced the deprecation
+ * @param string $message The message of the deprecation
+ * @param mixed ...$args Values to insert in the message using printf() formatting
+ *
+ * @author Nicolas Grekas <p@tchwork.com>
+ */
+ function trigger_deprecation(string $package, string $version, string $message, mixed ...$args): void
+ {
+ @trigger_error(($package || $version ? "Since $package $version: " : '').($args ? vsprintf($message, $args) : $message), \E_USER_DEPRECATED);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/LICENSE
index 4cd8bdd..6e3afce 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/LICENSE
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2015-2019 Fabien Potencier
+Copyright (c) 2015-present 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
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/Mbstring.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/Mbstring.php
index b65c54a..2e0b969 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/Mbstring.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/Mbstring.php
@@ -69,7 +69,7 @@
{
public const MB_CASE_FOLD = \PHP_INT_MAX;
- private const CASE_FOLD = [
+ private const SIMPLE_CASE_FOLD = [
['µ', 'ſ', "\xCD\x85", 'ς', "\xCF\x90", "\xCF\x91", "\xCF\x95", "\xCF\x96", "\xCF\xB0", "\xCF\xB1", "\xCF\xB5", "\xE1\xBA\x9B", "\xE1\xBE\xBE"],
['μ', 's', 'ι', 'σ', 'β', 'θ', 'φ', 'π', 'κ', 'ρ', 'ε', "\xE1\xB9\xA1", 'ι'],
];
@@ -80,7 +80,7 @@
public static function mb_convert_encoding($s, $toEncoding, $fromEncoding = null)
{
- if (\is_array($fromEncoding) || ($fromEncoding !== null && false !== strpos($fromEncoding, ','))) {
+ if (\is_array($fromEncoding) || (null !== $fromEncoding && false !== strpos($fromEncoding, ','))) {
$fromEncoding = self::mb_detect_encoding($s, $fromEncoding);
} else {
$fromEncoding = self::getEncoding($fromEncoding);
@@ -102,7 +102,7 @@
$fromEncoding = 'Windows-1252';
}
if ('UTF-8' !== $fromEncoding) {
- $s = \iconv($fromEncoding, 'UTF-8//IGNORE', $s);
+ $s = iconv($fromEncoding, 'UTF-8//IGNORE', $s);
}
return preg_replace_callback('/[\x80-\xFF]+/', [__CLASS__, 'html_encoding_callback'], $s);
@@ -113,7 +113,7 @@
$fromEncoding = 'UTF-8';
}
- return \iconv($fromEncoding, $toEncoding.'//IGNORE', $s);
+ return iconv($fromEncoding, $toEncoding.'//IGNORE', $s);
}
public static function mb_convert_variables($toEncoding, $fromEncoding, &...$vars)
@@ -130,7 +130,7 @@
public static function mb_decode_mimeheader($s)
{
- return \iconv_mime_decode($s, 2, self::$internalEncoding);
+ return iconv_mime_decode($s, 2, self::$internalEncoding);
}
public static function mb_encode_mimeheader($s, $charset = null, $transferEncoding = null, $linefeed = null, $indent = null)
@@ -140,7 +140,7 @@
public static function mb_decode_numericentity($s, $convmap, $encoding = null)
{
- if (null !== $s && !is_scalar($s) && !(\is_object($s) && method_exists($s, '__toString'))) {
+ if (null !== $s && !\is_scalar($s) && !(\is_object($s) && method_exists($s, '__toString'))) {
trigger_error('mb_decode_numericentity() expects parameter 1 to be string, '.\gettype($s).' given', \E_USER_WARNING);
return null;
@@ -150,7 +150,7 @@
return false;
}
- if (null !== $encoding && !is_scalar($encoding)) {
+ if (null !== $encoding && !\is_scalar($encoding)) {
trigger_error('mb_decode_numericentity() expects parameter 3 to be string, '.\gettype($s).' given', \E_USER_WARNING);
return ''; // Instead of null (cf. mb_encode_numericentity).
@@ -166,10 +166,10 @@
if ('UTF-8' === $encoding) {
$encoding = null;
if (!preg_match('//u', $s)) {
- $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s);
+ $s = @iconv('UTF-8', 'UTF-8//IGNORE', $s);
}
} else {
- $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
+ $s = iconv($encoding, 'UTF-8//IGNORE', $s);
}
$cnt = floor(\count($convmap) / 4) * 4;
@@ -195,12 +195,12 @@
return $s;
}
- return \iconv('UTF-8', $encoding.'//IGNORE', $s);
+ return iconv('UTF-8', $encoding.'//IGNORE', $s);
}
public static function mb_encode_numericentity($s, $convmap, $encoding = null, $is_hex = false)
{
- if (null !== $s && !is_scalar($s) && !(\is_object($s) && method_exists($s, '__toString'))) {
+ if (null !== $s && !\is_scalar($s) && !(\is_object($s) && method_exists($s, '__toString'))) {
trigger_error('mb_encode_numericentity() expects parameter 1 to be string, '.\gettype($s).' given', \E_USER_WARNING);
return null;
@@ -210,13 +210,13 @@
return false;
}
- if (null !== $encoding && !is_scalar($encoding)) {
+ if (null !== $encoding && !\is_scalar($encoding)) {
trigger_error('mb_encode_numericentity() expects parameter 3 to be string, '.\gettype($s).' given', \E_USER_WARNING);
return null; // Instead of '' (cf. mb_decode_numericentity).
}
- if (null !== $is_hex && !is_scalar($is_hex)) {
+ if (null !== $is_hex && !\is_scalar($is_hex)) {
trigger_error('mb_encode_numericentity() expects parameter 4 to be boolean, '.\gettype($s).' given', \E_USER_WARNING);
return null;
@@ -232,10 +232,10 @@
if ('UTF-8' === $encoding) {
$encoding = null;
if (!preg_match('//u', $s)) {
- $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s);
+ $s = @iconv('UTF-8', 'UTF-8//IGNORE', $s);
}
} else {
- $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
+ $s = iconv($encoding, 'UTF-8//IGNORE', $s);
}
static $ulenMask = ["\xC0" => 2, "\xD0" => 2, "\xE0" => 3, "\xF0" => 4];
@@ -265,7 +265,7 @@
return $result;
}
- return \iconv('UTF-8', $encoding.'//IGNORE', $result);
+ return iconv('UTF-8', $encoding.'//IGNORE', $result);
}
public static function mb_convert_case($s, $mode, $encoding = null)
@@ -280,10 +280,10 @@
if ('UTF-8' === $encoding) {
$encoding = null;
if (!preg_match('//u', $s)) {
- $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s);
+ $s = @iconv('UTF-8', 'UTF-8//IGNORE', $s);
}
} else {
- $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
+ $s = iconv($encoding, 'UTF-8//IGNORE', $s);
}
if (\MB_CASE_TITLE == $mode) {
@@ -301,7 +301,11 @@
$map = $upper;
} else {
if (self::MB_CASE_FOLD === $mode) {
- $s = str_replace(self::CASE_FOLD[0], self::CASE_FOLD[1], $s);
+ static $caseFolding = null;
+ if (null === $caseFolding) {
+ $caseFolding = self::getData('caseFolding');
+ }
+ $s = strtr($s, $caseFolding);
}
static $lower = null;
@@ -343,7 +347,7 @@
return $s;
}
- return \iconv('UTF-8', $encoding.'//IGNORE', $s);
+ return iconv('UTF-8', $encoding.'//IGNORE', $s);
}
public static function mb_internal_encoding($encoding = null)
@@ -354,7 +358,7 @@
$normalizedEncoding = self::getEncoding($encoding);
- if ('UTF-8' === $normalizedEncoding || false !== @\iconv($normalizedEncoding, $normalizedEncoding, ' ')) {
+ if ('UTF-8' === $normalizedEncoding || false !== @iconv($normalizedEncoding, $normalizedEncoding, ' ')) {
self::$internalEncoding = $normalizedEncoding;
return true;
@@ -406,6 +410,12 @@
public static function mb_check_encoding($var = null, $encoding = null)
{
+ if (PHP_VERSION_ID < 70200 && \is_array($var)) {
+ trigger_error('mb_check_encoding() expects parameter 1 to be string, array given', \E_USER_WARNING);
+
+ return null;
+ }
+
if (null === $encoding) {
if (null === $var) {
return false;
@@ -413,7 +423,21 @@
$encoding = self::$internalEncoding;
}
- return self::mb_detect_encoding($var, [$encoding]) || false !== @\iconv($encoding, $encoding, $var);
+ if (!\is_array($var)) {
+ return self::mb_detect_encoding($var, [$encoding]) || false !== @iconv($encoding, $encoding, $var);
+ }
+
+ foreach ($var as $key => $value) {
+ if (!self::mb_check_encoding($key, $encoding)) {
+ return false;
+ }
+ if (!self::mb_check_encoding($value, $encoding)) {
+ return false;
+ }
+ }
+
+ return true;
+
}
public static function mb_detect_encoding($str, $encodingList = null, $strict = false)
@@ -488,7 +512,7 @@
return \strlen($s);
}
- return @\iconv_strlen($s, $encoding);
+ return @iconv_strlen($s, $encoding);
}
public static function mb_strpos($haystack, $needle, $offset = 0, $encoding = null)
@@ -509,7 +533,7 @@
return 0;
}
- return \iconv_strpos($haystack, $needle, $offset, $encoding);
+ return iconv_strpos($haystack, $needle, $offset, $encoding);
}
public static function mb_strrpos($haystack, $needle, $offset = 0, $encoding = null)
@@ -533,7 +557,7 @@
}
$pos = '' !== $needle || 80000 > \PHP_VERSION_ID
- ? \iconv_strrpos($haystack, $needle, $encoding)
+ ? iconv_strrpos($haystack, $needle, $encoding)
: self::mb_strlen($haystack, $encoding);
return false !== $pos ? $offset + $pos : false;
@@ -541,7 +565,7 @@
public static function mb_str_split($string, $split_length = 1, $encoding = null)
{
- if (null !== $string && !is_scalar($string) && !(\is_object($string) && method_exists($string, '__toString'))) {
+ if (null !== $string && !\is_scalar($string) && !(\is_object($string) && method_exists($string, '__toString'))) {
trigger_error('mb_str_split() expects parameter 1 to be string, '.\gettype($string).' given', \E_USER_WARNING);
return null;
@@ -550,6 +574,7 @@
if (1 > $split_length = (int) $split_length) {
if (80000 > \PHP_VERSION_ID) {
trigger_error('The length of each segment must be greater than zero', \E_USER_WARNING);
+
return false;
}
@@ -568,7 +593,7 @@
}
$rx .= '.{'.$split_length.'})/us';
- return preg_split($rx, $string, null, \PREG_SPLIT_DELIM_CAPTURE | \PREG_SPLIT_NO_EMPTY);
+ return preg_split($rx, $string, -1, \PREG_SPLIT_DELIM_CAPTURE | \PREG_SPLIT_NO_EMPTY);
}
$result = [];
@@ -617,7 +642,7 @@
}
if ($start < 0) {
- $start = \iconv_strlen($s, $encoding) + $start;
+ $start = iconv_strlen($s, $encoding) + $start;
if ($start < 0) {
$start = 0;
}
@@ -626,19 +651,21 @@
if (null === $length) {
$length = 2147483647;
} elseif ($length < 0) {
- $length = \iconv_strlen($s, $encoding) + $length - $start;
+ $length = iconv_strlen($s, $encoding) + $length - $start;
if ($length < 0) {
return '';
}
}
- return (string) \iconv_substr($s, $start, $length, $encoding);
+ return (string) iconv_substr($s, $start, $length, $encoding);
}
public static function mb_stripos($haystack, $needle, $offset = 0, $encoding = null)
{
- $haystack = self::mb_convert_case($haystack, self::MB_CASE_FOLD, $encoding);
- $needle = self::mb_convert_case($needle, self::MB_CASE_FOLD, $encoding);
+ [$haystack, $needle] = str_replace(self::SIMPLE_CASE_FOLD[0], self::SIMPLE_CASE_FOLD[1], [
+ self::mb_convert_case($haystack, \MB_CASE_LOWER, $encoding),
+ self::mb_convert_case($needle, \MB_CASE_LOWER, $encoding),
+ ]);
return self::mb_strpos($haystack, $needle, $offset, $encoding);
}
@@ -657,7 +684,7 @@
$pos = strrpos($haystack, $needle);
} else {
$needle = self::mb_substr($needle, 0, 1, $encoding);
- $pos = \iconv_strrpos($haystack, $needle, $encoding);
+ $pos = iconv_strrpos($haystack, $needle, $encoding);
}
return self::getSubpart($pos, $part, $haystack, $encoding);
@@ -673,8 +700,11 @@
public static function mb_strripos($haystack, $needle, $offset = 0, $encoding = null)
{
- $haystack = self::mb_convert_case($haystack, self::MB_CASE_FOLD, $encoding);
- $needle = self::mb_convert_case($needle, self::MB_CASE_FOLD, $encoding);
+ $haystack = self::mb_convert_case($haystack, \MB_CASE_LOWER, $encoding);
+ $needle = self::mb_convert_case($needle, \MB_CASE_LOWER, $encoding);
+
+ $haystack = str_replace(self::SIMPLE_CASE_FOLD[0], self::SIMPLE_CASE_FOLD[1], $haystack);
+ $needle = str_replace(self::SIMPLE_CASE_FOLD[0], self::SIMPLE_CASE_FOLD[1], $needle);
return self::mb_strrpos($haystack, $needle, $offset, $encoding);
}
@@ -736,12 +766,12 @@
$encoding = self::getEncoding($encoding);
if ('UTF-8' !== $encoding) {
- $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
+ $s = iconv($encoding, 'UTF-8//IGNORE', $s);
}
$s = preg_replace('/[\x{1100}-\x{115F}\x{2329}\x{232A}\x{2E80}-\x{303E}\x{3040}-\x{A4CF}\x{AC00}-\x{D7A3}\x{F900}-\x{FAFF}\x{FE10}-\x{FE19}\x{FE30}-\x{FE6F}\x{FF00}-\x{FF60}\x{FFE0}-\x{FFE6}\x{20000}-\x{2FFFD}\x{30000}-\x{3FFFD}]/u', '', $s, -1, $wide);
- return ($wide << 1) + \iconv_strlen($s, 'UTF-8');
+ return ($wide << 1) + iconv_strlen($s, 'UTF-8');
}
public static function mb_substr_count($haystack, $needle, $encoding = null)
@@ -797,6 +827,50 @@
return $code;
}
+ public static function mb_str_pad(string $string, int $length, string $pad_string = ' ', int $pad_type = \STR_PAD_RIGHT, string $encoding = null): string
+ {
+ if (!\in_array($pad_type, [\STR_PAD_RIGHT, \STR_PAD_LEFT, \STR_PAD_BOTH], true)) {
+ throw new \ValueError('mb_str_pad(): Argument #4 ($pad_type) must be STR_PAD_LEFT, STR_PAD_RIGHT, or STR_PAD_BOTH');
+ }
+
+ if (null === $encoding) {
+ $encoding = self::mb_internal_encoding();
+ }
+
+ try {
+ $validEncoding = @self::mb_check_encoding('', $encoding);
+ } catch (\ValueError $e) {
+ throw new \ValueError(sprintf('mb_str_pad(): Argument #5 ($encoding) must be a valid encoding, "%s" given', $encoding));
+ }
+
+ // BC for PHP 7.3 and lower
+ if (!$validEncoding) {
+ throw new \ValueError(sprintf('mb_str_pad(): Argument #5 ($encoding) must be a valid encoding, "%s" given', $encoding));
+ }
+
+ if (self::mb_strlen($pad_string, $encoding) <= 0) {
+ throw new \ValueError('mb_str_pad(): Argument #3 ($pad_string) must be a non-empty string');
+ }
+
+ $paddingRequired = $length - self::mb_strlen($string, $encoding);
+
+ if ($paddingRequired < 1) {
+ return $string;
+ }
+
+ switch ($pad_type) {
+ case \STR_PAD_LEFT:
+ return self::mb_substr(str_repeat($pad_string, $paddingRequired), 0, $paddingRequired, $encoding).$string;
+ case \STR_PAD_RIGHT:
+ return $string.self::mb_substr(str_repeat($pad_string, $paddingRequired), 0, $paddingRequired, $encoding);
+ default:
+ $leftPaddingLength = floor($paddingRequired / 2);
+ $rightPaddingLength = $paddingRequired - $leftPaddingLength;
+
+ return self::mb_substr(str_repeat($pad_string, $leftPaddingLength), 0, $leftPaddingLength, $encoding).$string.self::mb_substr(str_repeat($pad_string, $rightPaddingLength), 0, $rightPaddingLength, $encoding);
+ }
+ }
+
private static function getSubpart($pos, $part, $haystack, $encoding)
{
if (false === $pos) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/README.md
index 4efb599..478b40d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/README.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/README.md
@@ -5,7 +5,7 @@
[Mbstring](https://php.net/mbstring) extension.
More information can be found in the
-[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md).
+[main Polyfill README](https://github.com/symfony/polyfill/blob/main/README.md).
License
=======
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/Resources/unidata/caseFolding.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/Resources/unidata/caseFolding.php
new file mode 100644
index 0000000..512bba0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/Resources/unidata/caseFolding.php
@@ -0,0 +1,119 @@
+<?php
+
+return [
+ 'İ' => 'i̇',
+ 'µ' => 'μ',
+ 'ſ' => 's',
+ 'ͅ' => 'ι',
+ 'ς' => 'σ',
+ 'ϐ' => 'β',
+ 'ϑ' => 'θ',
+ 'ϕ' => 'φ',
+ 'ϖ' => 'π',
+ 'ϰ' => 'κ',
+ 'ϱ' => 'ρ',
+ 'ϵ' => 'ε',
+ 'ẛ' => 'ṡ',
+ 'ι' => 'ι',
+ 'ß' => 'ss',
+ 'ʼn' => 'ʼn',
+ 'ǰ' => 'ǰ',
+ 'ΐ' => 'ΐ',
+ 'ΰ' => 'ΰ',
+ 'և' => 'եւ',
+ 'ẖ' => 'ẖ',
+ 'ẗ' => 'ẗ',
+ 'ẘ' => 'ẘ',
+ 'ẙ' => 'ẙ',
+ 'ẚ' => 'aʾ',
+ 'ẞ' => 'ss',
+ 'ὐ' => 'ὐ',
+ 'ὒ' => 'ὒ',
+ 'ὔ' => 'ὔ',
+ 'ὖ' => 'ὖ',
+ 'ᾀ' => 'ἀι',
+ 'ᾁ' => 'ἁι',
+ 'ᾂ' => 'ἂι',
+ 'ᾃ' => 'ἃι',
+ 'ᾄ' => 'ἄι',
+ 'ᾅ' => 'ἅι',
+ 'ᾆ' => 'ἆι',
+ 'ᾇ' => 'ἇι',
+ 'ᾈ' => 'ἀι',
+ 'ᾉ' => 'ἁι',
+ 'ᾊ' => 'ἂι',
+ 'ᾋ' => 'ἃι',
+ 'ᾌ' => 'ἄι',
+ 'ᾍ' => 'ἅι',
+ 'ᾎ' => 'ἆι',
+ 'ᾏ' => 'ἇι',
+ 'ᾐ' => 'ἠι',
+ 'ᾑ' => 'ἡι',
+ 'ᾒ' => 'ἢι',
+ 'ᾓ' => 'ἣι',
+ 'ᾔ' => 'ἤι',
+ 'ᾕ' => 'ἥι',
+ 'ᾖ' => 'ἦι',
+ 'ᾗ' => 'ἧι',
+ 'ᾘ' => 'ἠι',
+ 'ᾙ' => 'ἡι',
+ 'ᾚ' => 'ἢι',
+ 'ᾛ' => 'ἣι',
+ 'ᾜ' => 'ἤι',
+ 'ᾝ' => 'ἥι',
+ 'ᾞ' => 'ἦι',
+ 'ᾟ' => 'ἧι',
+ 'ᾠ' => 'ὠι',
+ 'ᾡ' => 'ὡι',
+ 'ᾢ' => 'ὢι',
+ 'ᾣ' => 'ὣι',
+ 'ᾤ' => 'ὤι',
+ 'ᾥ' => 'ὥι',
+ 'ᾦ' => 'ὦι',
+ 'ᾧ' => 'ὧι',
+ 'ᾨ' => 'ὠι',
+ 'ᾩ' => 'ὡι',
+ 'ᾪ' => 'ὢι',
+ 'ᾫ' => 'ὣι',
+ 'ᾬ' => 'ὤι',
+ 'ᾭ' => 'ὥι',
+ 'ᾮ' => 'ὦι',
+ 'ᾯ' => 'ὧι',
+ 'ᾲ' => 'ὰι',
+ 'ᾳ' => 'αι',
+ 'ᾴ' => 'άι',
+ 'ᾶ' => 'ᾶ',
+ 'ᾷ' => 'ᾶι',
+ 'ᾼ' => 'αι',
+ 'ῂ' => 'ὴι',
+ 'ῃ' => 'ηι',
+ 'ῄ' => 'ήι',
+ 'ῆ' => 'ῆ',
+ 'ῇ' => 'ῆι',
+ 'ῌ' => 'ηι',
+ 'ῒ' => 'ῒ',
+ 'ῖ' => 'ῖ',
+ 'ῗ' => 'ῗ',
+ 'ῢ' => 'ῢ',
+ 'ῤ' => 'ῤ',
+ 'ῦ' => 'ῦ',
+ 'ῧ' => 'ῧ',
+ 'ῲ' => 'ὼι',
+ 'ῳ' => 'ωι',
+ 'ῴ' => 'ώι',
+ 'ῶ' => 'ῶ',
+ 'ῷ' => 'ῶι',
+ 'ῼ' => 'ωι',
+ 'ff' => 'ff',
+ 'fi' => 'fi',
+ 'fl' => 'fl',
+ 'ffi' => 'ffi',
+ 'ffl' => 'ffl',
+ 'ſt' => 'st',
+ 'st' => 'st',
+ 'ﬓ' => 'մն',
+ 'ﬔ' => 'մե',
+ 'ﬕ' => 'մի',
+ 'ﬖ' => 'վն',
+ 'ﬗ' => 'մխ',
+];
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap.php
index 1fedd1f..ecf1a03 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap.php
@@ -132,6 +132,10 @@
function mb_str_split($string, $length = 1, $encoding = null) { return p\Mbstring::mb_str_split($string, $length, $encoding); }
}
+if (!function_exists('mb_str_pad')) {
+ function mb_str_pad(string $string, int $length, string $pad_string = ' ', int $pad_type = STR_PAD_RIGHT, ?string $encoding = null): string { return p\Mbstring::mb_str_pad($string, $length, $pad_string, $pad_type, $encoding); }
+}
+
if (extension_loaded('mbstring')) {
return;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap80.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap80.php
index 82f5ac4..2f9fb5b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap80.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/bootstrap80.php
@@ -128,6 +128,10 @@
function mb_str_split(?string $string, ?int $length = 1, ?string $encoding = null): array { return p\Mbstring::mb_str_split((string) $string, (int) $length, $encoding); }
}
+if (!function_exists('mb_str_pad')) {
+ function mb_str_pad(string $string, int $length, string $pad_string = ' ', int $pad_type = STR_PAD_RIGHT, ?string $encoding = null): string { return p\Mbstring::mb_str_pad($string, $length, $pad_string, $pad_type, $encoding); }
+}
+
if (extension_loaded('mbstring')) {
return;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/composer.json
index 1fa21ca..bd99d4b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-mbstring/composer.json
@@ -30,9 +30,6 @@
},
"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/symfony/polyfill-php80/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/LICENSE
index 5593b1d..0ed3a24 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/LICENSE
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2020 Fabien Potencier
+Copyright (c) 2020-present 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
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Php80.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Php80.php
index 5fef511..362dd1a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Php80.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Php80.php
@@ -100,6 +100,16 @@
public static function str_ends_with(string $haystack, string $needle): bool
{
- return '' === $needle || ('' !== $haystack && 0 === substr_compare($haystack, $needle, -\strlen($needle)));
+ if ('' === $needle || $needle === $haystack) {
+ return true;
+ }
+
+ if ('' === $haystack) {
+ return false;
+ }
+
+ $needleLength = \strlen($needle);
+
+ return $needleLength <= \strlen($haystack) && 0 === substr_compare($haystack, $needle, -$needleLength);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/PhpToken.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/PhpToken.php
new file mode 100644
index 0000000..fe6e691
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/PhpToken.php
@@ -0,0 +1,103 @@
+<?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\Php80;
+
+/**
+ * @author Fedonyuk Anton <info@ensostudio.ru>
+ *
+ * @internal
+ */
+class PhpToken implements \Stringable
+{
+ /**
+ * @var int
+ */
+ public $id;
+
+ /**
+ * @var string
+ */
+ public $text;
+
+ /**
+ * @var int
+ */
+ public $line;
+
+ /**
+ * @var int
+ */
+ public $pos;
+
+ public function __construct(int $id, string $text, int $line = -1, int $position = -1)
+ {
+ $this->id = $id;
+ $this->text = $text;
+ $this->line = $line;
+ $this->pos = $position;
+ }
+
+ public function getTokenName(): ?string
+ {
+ if ('UNKNOWN' === $name = token_name($this->id)) {
+ $name = \strlen($this->text) > 1 || \ord($this->text) < 32 ? null : $this->text;
+ }
+
+ return $name;
+ }
+
+ /**
+ * @param int|string|array $kind
+ */
+ public function is($kind): bool
+ {
+ foreach ((array) $kind as $value) {
+ if (\in_array($value, [$this->id, $this->text], true)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ public function isIgnorable(): bool
+ {
+ return \in_array($this->id, [\T_WHITESPACE, \T_COMMENT, \T_DOC_COMMENT, \T_OPEN_TAG], true);
+ }
+
+ public function __toString(): string
+ {
+ return (string) $this->text;
+ }
+
+ /**
+ * @return static[]
+ */
+ public static function tokenize(string $code, int $flags = 0): array
+ {
+ $line = 1;
+ $position = 0;
+ $tokens = token_get_all($code, $flags);
+ foreach ($tokens as $index => $token) {
+ if (\is_string($token)) {
+ $id = \ord($token);
+ $text = $token;
+ } else {
+ [$id, $text, $line] = $token;
+ }
+ $tokens[$index] = new static($id, $text, $line, $position);
+ $position += \strlen($text);
+ }
+
+ return $tokens;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/README.md
index 10b8ee4..3816c55 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/README.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/README.md
@@ -3,12 +3,13 @@
This component provides features added to PHP 8.0 core:
-- `Stringable` interface
+- [`Stringable`](https://php.net/stringable) interface
- [`fdiv`](https://php.net/fdiv)
-- `ValueError` class
-- `UnhandledMatchError` class
+- [`ValueError`](https://php.net/valueerror) class
+- [`UnhandledMatchError`](https://php.net/unhandledmatcherror) class
- `FILTER_VALIDATE_BOOL` constant
- [`get_debug_type`](https://php.net/get_debug_type)
+- [`PhpToken`](https://php.net/phptoken) class
- [`preg_last_error_msg`](https://php.net/preg_last_error_msg)
- [`str_contains`](https://php.net/str_contains)
- [`str_starts_with`](https://php.net/str_starts_with)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Attribute.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Attribute.php
index 7ea6d27..2b95542 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Attribute.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Attribute.php
@@ -1,5 +1,14 @@
<?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.
+ */
+
#[Attribute(Attribute::TARGET_CLASS)]
final class Attribute
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/PhpToken.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/PhpToken.php
new file mode 100644
index 0000000..bd1212f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/PhpToken.php
@@ -0,0 +1,16 @@
+<?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.
+ */
+
+if (\PHP_VERSION_ID < 80000 && extension_loaded('tokenizer')) {
+ class PhpToken extends Symfony\Polyfill\Php80\PhpToken
+ {
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Stringable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Stringable.php
index 77e037c..7c62d75 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Stringable.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/Stringable.php
@@ -1,5 +1,14 @@
<?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.
+ */
+
if (\PHP_VERSION_ID < 80000) {
interface Stringable
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php
index 37937cb..01c6c6c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php
@@ -1,5 +1,14 @@
<?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.
+ */
+
if (\PHP_VERSION_ID < 80000) {
class UnhandledMatchError extends Error
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/ValueError.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/ValueError.php
index a3a9b88..783dbc2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/ValueError.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/Resources/stubs/ValueError.php
@@ -1,5 +1,14 @@
<?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.
+ */
+
if (\PHP_VERSION_ID < 80000) {
class ValueError extends Error
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/composer.json
index 5fe679d..46ccde2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php80/composer.json
@@ -29,9 +29,6 @@
},
"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/symfony/polyfill-php81/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/LICENSE
new file mode 100644
index 0000000..99c6bdf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2021-present 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-php81/Php81.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/Php81.php
new file mode 100644
index 0000000..f0507b7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/Php81.php
@@ -0,0 +1,37 @@
+<?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\Php81;
+
+/**
+ * @author Nicolas Grekas <p@tchwork.com>
+ *
+ * @internal
+ */
+final class Php81
+{
+ public static function array_is_list(array $array): bool
+ {
+ if ([] === $array || $array === array_values($array)) {
+ return true;
+ }
+
+ $nextKey = -1;
+
+ foreach ($array as $k => $v) {
+ if ($k !== ++$nextKey) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/README.md
new file mode 100644
index 0000000..c07ef78
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/README.md
@@ -0,0 +1,18 @@
+Symfony Polyfill / Php81
+========================
+
+This component provides features added to PHP 8.1 core:
+
+- [`array_is_list`](https://php.net/array_is_list)
+- [`enum_exists`](https://php.net/enum-exists)
+- [`MYSQLI_REFRESH_REPLICA`](https://php.net/mysqli.constants#constantmysqli-refresh-replica) constant
+- [`ReturnTypeWillChange`](https://wiki.php.net/rfc/internal_method_return_types)
+- [`CURLStringFile`](https://php.net/CURLStringFile) (but only if PHP >= 7.4 is used)
+
+More information can be found in the
+[main Polyfill README](https://github.com/symfony/polyfill/blob/main/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-php81/Resources/stubs/CURLStringFile.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/Resources/stubs/CURLStringFile.php
new file mode 100644
index 0000000..5ff93fc
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/Resources/stubs/CURLStringFile.php
@@ -0,0 +1,51 @@
+<?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.
+ */
+
+if (\PHP_VERSION_ID >= 70400 && extension_loaded('curl')) {
+ /**
+ * @property string $data
+ */
+ class CURLStringFile extends CURLFile
+ {
+ private $data;
+
+ public function __construct(string $data, string $postname, string $mime = 'application/octet-stream')
+ {
+ $this->data = $data;
+ parent::__construct('data://application/octet-stream;base64,'.base64_encode($data), $mime, $postname);
+ }
+
+ public function __set(string $name, $value): void
+ {
+ if ('data' !== $name) {
+ $this->$name = $value;
+
+ return;
+ }
+
+ if (is_object($value) ? !method_exists($value, '__toString') : !is_scalar($value)) {
+ throw new TypeError('Cannot assign '.gettype($value).' to property CURLStringFile::$data of type string');
+ }
+
+ $this->name = 'data://application/octet-stream;base64,'.base64_encode($value);
+ }
+
+ public function __isset(string $name): bool
+ {
+ return isset($this->$name);
+ }
+
+ public function &__get(string $name)
+ {
+ return $this->$name;
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/Resources/stubs/ReturnTypeWillChange.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/Resources/stubs/ReturnTypeWillChange.php
new file mode 100644
index 0000000..cb7720a
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/Resources/stubs/ReturnTypeWillChange.php
@@ -0,0 +1,20 @@
+<?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.
+ */
+
+if (\PHP_VERSION_ID < 80100) {
+ #[Attribute(Attribute::TARGET_METHOD)]
+ final class ReturnTypeWillChange
+ {
+ public function __construct()
+ {
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/bootstrap.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/bootstrap.php
new file mode 100644
index 0000000..9f872e0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/bootstrap.php
@@ -0,0 +1,28 @@
+<?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\Php81 as p;
+
+if (\PHP_VERSION_ID >= 80100) {
+ return;
+}
+
+if (defined('MYSQLI_REFRESH_SLAVE') && !defined('MYSQLI_REFRESH_REPLICA')) {
+ define('MYSQLI_REFRESH_REPLICA', 64);
+}
+
+if (!function_exists('array_is_list')) {
+ function array_is_list(array $array): bool { return p\Php81::array_is_list($array); }
+}
+
+if (!function_exists('enum_exists')) {
+ function enum_exists(string $enum, bool $autoload = true): bool { return $autoload && class_exists($enum) && false; }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/composer.json
new file mode 100644
index 0000000..28b6408
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/polyfill-php81/composer.json
@@ -0,0 +1,33 @@
+{
+ "name": "symfony/polyfill-php81",
+ "type": "library",
+ "description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions",
+ "keywords": ["polyfill", "shim", "compatibility", "portable"],
+ "homepage": "https://symfony.com",
+ "license": "MIT",
+ "authors": [
+ {
+ "name": "Nicolas Grekas",
+ "email": "p@tchwork.com"
+ },
+ {
+ "name": "Symfony Community",
+ "homepage": "https://symfony.com/contributors"
+ }
+ ],
+ "require": {
+ "php": ">=7.2"
+ },
+ "autoload": {
+ "psr-4": { "Symfony\\Polyfill\\Php81\\": "" },
+ "files": [ "bootstrap.php" ],
+ "classmap": [ "Resources/stubs" ]
+ },
+ "minimum-stability": "dev",
+ "extra": {
+ "thanks": {
+ "name": "symfony/polyfill",
+ "url": "https://github.com/symfony/polyfill"
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/.gitignore b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/.gitignore
deleted file mode 100644
index c49a5d8..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/.gitignore
+++ /dev/null
@@ -1,3 +0,0 @@
-vendor/
-composer.lock
-phpunit.xml
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LICENSE
index 2358414..7536cae 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LICENSE
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2018-2021 Fabien Potencier
+Copyright (c) 2018-present 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
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LocaleAwareInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LocaleAwareInterface.php
index 6923b97..db40ba1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LocaleAwareInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/LocaleAwareInterface.php
@@ -16,6 +16,8 @@
/**
* Sets the current locale.
*
+ * @return void
+ *
* @throws \InvalidArgumentException If the locale contains invalid characters
*/
public function setLocale(string $locale);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/README.md
index 42e5c51..b211d58 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/README.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/README.md
@@ -3,7 +3,7 @@
A set of abstractions extracted out of the Symfony components.
-Can be used to build on semantics that the Symfony components proved useful - and
+Can be used to build on semantics that the Symfony components proved useful and
that already have battle tested implementations.
See https://github.com/symfony/contracts/blob/main/README.md for more information.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/Test/TranslatorTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/Test/TranslatorTest.php
index c2c30a9..756228a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/Test/TranslatorTest.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/Test/TranslatorTest.php
@@ -30,7 +30,7 @@
*/
class TranslatorTest extends TestCase
{
- private $defaultLocale;
+ private string $defaultLocale;
protected function setUp(): void
{
@@ -114,7 +114,7 @@
$this->assertEquals('en', $translator->getLocale());
}
- public function getTransTests()
+ public static function getTransTests()
{
return [
['Symfony is great!', 'Symfony is great!', []],
@@ -122,7 +122,7 @@
];
}
- public function getTransChoiceTests()
+ public static function getTransChoiceTests()
{
return [
['There are no apples', '{0} There are no apples|{1} There is one apple|]1,Inf] There are %count% apples', 0],
@@ -137,7 +137,7 @@
}
/**
- * @dataProvider getInternal
+ * @dataProvider getInterval
*/
public function testInterval($expected, $number, $interval)
{
@@ -146,7 +146,7 @@
$this->assertEquals($expected, $translator->trans($interval.' foo|[1,Inf[ bar', ['%count%' => $number]));
}
- public function getInternal()
+ public static function getInterval()
{
return [
['foo', 3, '{1,2, 3 ,4}'],
@@ -183,13 +183,14 @@
*/
public function testThrowExceptionIfMatchingMessageCannotBeFound($id, $number)
{
- $this->expectException(\InvalidArgumentException::class);
$translator = $this->getTranslator();
+ $this->expectException(\InvalidArgumentException::class);
+
$translator->trans($id, ['%count%' => $number]);
}
- public function getNonMatchingMessages()
+ public static function getNonMatchingMessages()
{
return [
['{0} There are no apples|{1} There is one apple', 2],
@@ -199,7 +200,7 @@
];
}
- public function getChooseTests()
+ public static function getChooseTests()
{
return [
['There are no apples', '{0} There are no apples|{1} There is one apple|]1,Inf] There are %count% apples', 0],
@@ -255,13 +256,13 @@
new-line in it. Selector = 0.|{1}This is a text with a
new-line in it. Selector = 1.|[1,Inf]This is a text with a
new-line in it. Selector > 1.', 5],
- // with double-quotes and id split accros lines
+ // with double-quotes and id split across lines
['This is a text with a
new-line in it. Selector = 1.', '{0}This is a text with a
new-line in it. Selector = 0.|{1}This is a text with a
new-line in it. Selector = 1.|[1,Inf]This is a text with a
new-line in it. Selector > 1.', 1],
- // with single-quotes and id split accros lines
+ // with single-quotes and id split across lines
['This is a text with a
new-line in it. Selector > 1.', '{0}This is a text with a
new-line in it. Selector = 0.|{1}This is a text with a
@@ -269,9 +270,9 @@
new-line in it. Selector > 1.', 5],
// with single-quotes and \n in text
['This is a text with a\nnew-line in it. Selector = 0.', '{0}This is a text with a\nnew-line in it. Selector = 0.|{1}This is a text with a\nnew-line in it. Selector = 1.|[1,Inf]This is a text with a\nnew-line in it. Selector > 1.', 0],
- // with double-quotes and id split accros lines
+ // with double-quotes and id split across lines
["This is a text with a\nnew-line in it. Selector = 1.", "{0}This is a text with a\nnew-line in it. Selector = 0.|{1}This is a text with a\nnew-line in it. Selector = 1.|[1,Inf]This is a text with a\nnew-line in it. Selector > 1.", 1],
- // esacape pipe
+ // escape pipe
['This is a text with | in it. Selector = 0.', '{0}This is a text with || in it. Selector = 0.|{1}This is a text with || in it. Selector = 1.', 0],
// Empty plural set (2 plural forms) from a .PO file
['', '|', 1],
@@ -315,7 +316,7 @@
*
* As it is impossible to have this ever complete we should try as hard as possible to have it almost complete.
*/
- public function successLangcodes(): array
+ public static function successLangcodes(): array
{
return [
['1', ['ay', 'bo', 'cgg', 'dz', 'id', 'ja', 'jbo', 'ka', 'kk', 'km', 'ko', 'ky']],
@@ -334,7 +335,7 @@
*
* @return array with nplural together with langcodes
*/
- public function failingLangcodes(): array
+ public static function failingLangcodes(): array
{
return [
['1', ['fa']],
@@ -356,7 +357,7 @@
foreach ($matrix as $langCode => $data) {
$indexes = array_flip($data);
if ($expectSuccess) {
- $this->assertEquals($nplural, \count($indexes), "Langcode '$langCode' has '$nplural' plural forms.");
+ $this->assertCount($nplural, $indexes, "Langcode '$langCode' has '$nplural' plural forms.");
} else {
$this->assertNotEquals((int) $nplural, \count($indexes), "Langcode '$langCode' has '$nplural' plural forms.");
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/TranslatorTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/TranslatorTrait.php
index 9c264bd..e3b0adf 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/TranslatorTrait.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/TranslatorTrait.php
@@ -23,24 +23,18 @@
private ?string $locale = null;
/**
- * {@inheritdoc}
+ * @return void
*/
public function setLocale(string $locale)
{
$this->locale = $locale;
}
- /**
- * {@inheritdoc}
- */
public function getLocale(): string
{
return $this->locale ?: (class_exists(\Locale::class) ? \Locale::getDefault() : 'en');
}
- /**
- * {@inheritdoc}
- */
public function trans(?string $id, array $parameters = [], string $domain = null, string $locale = null): string
{
if (null === $id || '' === $id) {
@@ -140,121 +134,92 @@
{
$number = abs($number);
- switch ('pt_BR' !== $locale && 'en_US_POSIX' !== $locale && \strlen($locale) > 3 ? substr($locale, 0, strrpos($locale, '_')) : $locale) {
- case 'af':
- case 'bn':
- case 'bg':
- case 'ca':
- case 'da':
- case 'de':
- case 'el':
- case 'en':
- case 'en_US_POSIX':
- case 'eo':
- case 'es':
- case 'et':
- case 'eu':
- case 'fa':
- case 'fi':
- case 'fo':
- case 'fur':
- case 'fy':
- case 'gl':
- case 'gu':
- case 'ha':
- case 'he':
- case 'hu':
- case 'is':
- case 'it':
- case 'ku':
- case 'lb':
- case 'ml':
- case 'mn':
- case 'mr':
- case 'nah':
- case 'nb':
- case 'ne':
- case 'nl':
- case 'nn':
- case 'no':
- case 'oc':
- case 'om':
- case 'or':
- case 'pa':
- case 'pap':
- case 'ps':
- case 'pt':
- case 'so':
- case 'sq':
- case 'sv':
- case 'sw':
- case 'ta':
- case 'te':
- case 'tk':
- case 'ur':
- case 'zu':
- return (1 == $number) ? 0 : 1;
-
- case 'am':
- case 'bh':
- case 'fil':
- case 'fr':
- case 'gun':
- case 'hi':
- case 'hy':
- case 'ln':
- case 'mg':
- case 'nso':
- case 'pt_BR':
- case 'ti':
- case 'wa':
- return ($number < 2) ? 0 : 1;
-
- case 'be':
- case 'bs':
- case 'hr':
- case 'ru':
- case 'sh':
- case 'sr':
- case 'uk':
- return ((1 == $number % 10) && (11 != $number % 100)) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2);
-
- case 'cs':
- case 'sk':
- return (1 == $number) ? 0 : ((($number >= 2) && ($number <= 4)) ? 1 : 2);
-
- case 'ga':
- return (1 == $number) ? 0 : ((2 == $number) ? 1 : 2);
-
- case 'lt':
- return ((1 == $number % 10) && (11 != $number % 100)) ? 0 : ((($number % 10 >= 2) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2);
-
- case 'sl':
- return (1 == $number % 100) ? 0 : ((2 == $number % 100) ? 1 : (((3 == $number % 100) || (4 == $number % 100)) ? 2 : 3));
-
- case 'mk':
- return (1 == $number % 10) ? 0 : 1;
-
- case 'mt':
- return (1 == $number) ? 0 : (((0 == $number) || (($number % 100 > 1) && ($number % 100 < 11))) ? 1 : ((($number % 100 > 10) && ($number % 100 < 20)) ? 2 : 3));
-
- case 'lv':
- return (0 == $number) ? 0 : (((1 == $number % 10) && (11 != $number % 100)) ? 1 : 2);
-
- case 'pl':
- return (1 == $number) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 12) || ($number % 100 > 14))) ? 1 : 2);
-
- case 'cy':
- return (1 == $number) ? 0 : ((2 == $number) ? 1 : (((8 == $number) || (11 == $number)) ? 2 : 3));
-
- case 'ro':
- return (1 == $number) ? 0 : (((0 == $number) || (($number % 100 > 0) && ($number % 100 < 20))) ? 1 : 2);
-
- case 'ar':
- return (0 == $number) ? 0 : ((1 == $number) ? 1 : ((2 == $number) ? 2 : ((($number % 100 >= 3) && ($number % 100 <= 10)) ? 3 : ((($number % 100 >= 11) && ($number % 100 <= 99)) ? 4 : 5))));
-
- default:
- return 0;
- }
+ return match ('pt_BR' !== $locale && 'en_US_POSIX' !== $locale && \strlen($locale) > 3 ? substr($locale, 0, strrpos($locale, '_')) : $locale) {
+ 'af',
+ 'bn',
+ 'bg',
+ 'ca',
+ 'da',
+ 'de',
+ 'el',
+ 'en',
+ 'en_US_POSIX',
+ 'eo',
+ 'es',
+ 'et',
+ 'eu',
+ 'fa',
+ 'fi',
+ 'fo',
+ 'fur',
+ 'fy',
+ 'gl',
+ 'gu',
+ 'ha',
+ 'he',
+ 'hu',
+ 'is',
+ 'it',
+ 'ku',
+ 'lb',
+ 'ml',
+ 'mn',
+ 'mr',
+ 'nah',
+ 'nb',
+ 'ne',
+ 'nl',
+ 'nn',
+ 'no',
+ 'oc',
+ 'om',
+ 'or',
+ 'pa',
+ 'pap',
+ 'ps',
+ 'pt',
+ 'so',
+ 'sq',
+ 'sv',
+ 'sw',
+ 'ta',
+ 'te',
+ 'tk',
+ 'ur',
+ 'zu' => (1 == $number) ? 0 : 1,
+ 'am',
+ 'bh',
+ 'fil',
+ 'fr',
+ 'gun',
+ 'hi',
+ 'hy',
+ 'ln',
+ 'mg',
+ 'nso',
+ 'pt_BR',
+ 'ti',
+ 'wa' => ($number < 2) ? 0 : 1,
+ 'be',
+ 'bs',
+ 'hr',
+ 'ru',
+ 'sh',
+ 'sr',
+ 'uk' => ((1 == $number % 10) && (11 != $number % 100)) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2),
+ 'cs',
+ 'sk' => (1 == $number) ? 0 : ((($number >= 2) && ($number <= 4)) ? 1 : 2),
+ 'ga' => (1 == $number) ? 0 : ((2 == $number) ? 1 : 2),
+ 'lt' => ((1 == $number % 10) && (11 != $number % 100)) ? 0 : ((($number % 10 >= 2) && (($number % 100 < 10) || ($number % 100 >= 20))) ? 1 : 2),
+ 'sl' => (1 == $number % 100) ? 0 : ((2 == $number % 100) ? 1 : (((3 == $number % 100) || (4 == $number % 100)) ? 2 : 3)),
+ 'mk' => (1 == $number % 10) ? 0 : 1,
+ 'mt' => (1 == $number) ? 0 : (((0 == $number) || (($number % 100 > 1) && ($number % 100 < 11))) ? 1 : ((($number % 100 > 10) && ($number % 100 < 20)) ? 2 : 3)),
+ 'lv' => (0 == $number) ? 0 : (((1 == $number % 10) && (11 != $number % 100)) ? 1 : 2),
+ 'pl' => (1 == $number) ? 0 : ((($number % 10 >= 2) && ($number % 10 <= 4) && (($number % 100 < 12) || ($number % 100 > 14))) ? 1 : 2),
+ 'cy' => (1 == $number) ? 0 : ((2 == $number) ? 1 : (((8 == $number) || (11 == $number)) ? 2 : 3)),
+ 'ro' => (1 == $number) ? 0 : (((0 == $number) || (($number % 100 > 0) && ($number % 100 < 20))) ? 1 : 2),
+ 'ar' => (0 == $number) ? 0 : ((1 == $number) ? 1 : ((2 == $number) ? 2 : ((($number % 100 >= 3) && ($number % 100 <= 10)) ? 3 : ((($number % 100 >= 11) && ($number % 100 <= 99)) ? 4 : 5)))),
+ default => 0,
+ };
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/composer.json
index 875242f..213b5cd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation-contracts/composer.json
@@ -16,18 +16,18 @@
}
],
"require": {
- "php": ">=8.0.2"
- },
- "suggest": {
- "symfony/translation-implementation": ""
+ "php": ">=8.1"
},
"autoload": {
- "psr-4": { "Symfony\\Contracts\\Translation\\": "" }
+ "psr-4": { "Symfony\\Contracts\\Translation\\": "" },
+ "exclude-from-classmap": [
+ "/Test/"
+ ]
},
"minimum-stability": "dev",
"extra": {
"branch-alias": {
- "dev-main": "3.0-dev"
+ "dev-main": "3.4-dev"
},
"thanks": {
"name": "symfony/contracts",
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/CHANGELOG.md
index 160b5e6..5f9098c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/CHANGELOG.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/CHANGELOG.md
@@ -1,6 +1,35 @@
CHANGELOG
=========
+6.4
+---
+
+ * Give current locale to `LocaleSwitcher::runWithLocale()`'s callback
+ * Add `--as-tree` option to `translation:pull` command to write YAML messages as a tree-like structure
+ * [BC BREAK] Add argument `$buildDir` to `DataCollectorTranslator::warmUp()`
+ * Add `DataCollectorTranslatorPass` and `LoggingTranslatorPass` (moved from `FrameworkBundle`)
+ * Add `PhraseTranslationProvider`
+
+6.2.7
+-----
+
+ * [BC BREAK] The following data providers for `ProviderFactoryTestCase` are now static:
+ `supportsProvider()`, `createProvider()`, `unsupportedSchemeProvider()`and `incompleteDsnProvider()`
+ * [BC BREAK] `ProviderTestCase::toStringProvider()` is now static
+
+6.2
+---
+
+ * Deprecate `PhpStringTokenParser`
+ * Deprecate `PhpExtractor` in favor of `PhpAstExtractor`
+ * Add `PhpAstExtractor` (requires [nikic/php-parser](https://github.com/nikic/php-parser) to be installed)
+
+6.1
+---
+
+ * Parameters implementing `TranslatableInterface` are processed
+ * Add the file extension to the `XliffFileDumper` constructor
+
5.4
---
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/AbstractOperation.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/AbstractOperation.php
index 43a52fa..7dff58f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/AbstractOperation.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/AbstractOperation.php
@@ -35,11 +35,6 @@
protected $result;
/**
- * @var array|null The domains affected by this operation
- */
- private $domains;
-
- /**
* This array stores 'all', 'new' and 'obsolete' messages for all valid domains.
*
* The data structure of this array is as follows:
@@ -62,6 +57,8 @@
*/
protected $messages;
+ private array $domains;
+
/**
* @throws LogicException
*/
@@ -77,12 +74,9 @@
$this->messages = [];
}
- /**
- * {@inheritdoc}
- */
public function getDomains(): array
{
- if (null === $this->domains) {
+ if (!isset($this->domains)) {
$domains = [];
foreach ([$this->source, $this->target] as $catalogue) {
foreach ($catalogue->getDomains() as $domain) {
@@ -100,9 +94,6 @@
return $this->domains;
}
- /**
- * {@inheritdoc}
- */
public function getMessages(string $domain): array
{
if (!\in_array($domain, $this->getDomains())) {
@@ -116,9 +107,6 @@
return $this->messages[$domain][self::ALL_BATCH];
}
- /**
- * {@inheritdoc}
- */
public function getNewMessages(string $domain): array
{
if (!\in_array($domain, $this->getDomains())) {
@@ -132,9 +120,6 @@
return $this->messages[$domain][self::NEW_BATCH];
}
- /**
- * {@inheritdoc}
- */
public function getObsoleteMessages(string $domain): array
{
if (!\in_array($domain, $this->getDomains())) {
@@ -148,9 +133,6 @@
return $this->messages[$domain][self::OBSOLETE_BATCH];
}
- /**
- * {@inheritdoc}
- */
public function getResult(): MessageCatalogueInterface
{
foreach ($this->getDomains() as $domain) {
@@ -174,12 +156,12 @@
foreach ($this->getDomains() as $domain) {
$intlDomain = $domain.MessageCatalogueInterface::INTL_DOMAIN_SUFFIX;
- switch ($batch) {
- case self::OBSOLETE_BATCH: $messages = $this->getObsoleteMessages($domain); break;
- case self::NEW_BATCH: $messages = $this->getNewMessages($domain); break;
- case self::ALL_BATCH: $messages = $this->getMessages($domain); break;
- default: throw new \InvalidArgumentException(sprintf('$batch argument must be one of ["%s", "%s", "%s"].', self::ALL_BATCH, self::NEW_BATCH, self::OBSOLETE_BATCH));
- }
+ $messages = match ($batch) {
+ self::OBSOLETE_BATCH => $this->getObsoleteMessages($domain),
+ self::NEW_BATCH => $this->getNewMessages($domain),
+ self::ALL_BATCH => $this->getMessages($domain),
+ default => throw new \InvalidArgumentException(sprintf('$batch argument must be one of ["%s", "%s", "%s"].', self::ALL_BATCH, self::NEW_BATCH, self::OBSOLETE_BATCH)),
+ };
if (!$messages || (!$this->source->all($intlDomain) && $this->source->all($domain))) {
continue;
@@ -198,6 +180,8 @@
* stores the results.
*
* @param string $domain The domain which the operation will be performed for
+ *
+ * @return void
*/
abstract protected function processDomain(string $domain);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/MergeOperation.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/MergeOperation.php
index 87db2fb..1b777a8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/MergeOperation.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/MergeOperation.php
@@ -25,7 +25,7 @@
class MergeOperation extends AbstractOperation
{
/**
- * {@inheritdoc}
+ * @return void
*/
protected function processDomain(string $domain)
{
@@ -36,6 +36,18 @@
];
$intlDomain = $domain.MessageCatalogueInterface::INTL_DOMAIN_SUFFIX;
+ foreach ($this->target->getCatalogueMetadata('', $domain) ?? [] as $key => $value) {
+ if (null === $this->result->getCatalogueMetadata($key, $domain)) {
+ $this->result->setCatalogueMetadata($key, $value, $domain);
+ }
+ }
+
+ foreach ($this->target->getCatalogueMetadata('', $intlDomain) ?? [] as $key => $value) {
+ if (null === $this->result->getCatalogueMetadata($key, $intlDomain)) {
+ $this->result->setCatalogueMetadata($key, $value, $intlDomain);
+ }
+ }
+
foreach ($this->source->all($domain) as $id => $message) {
$this->messages[$domain]['all'][$id] = $message;
$d = $this->source->defines($id, $intlDomain) ? $intlDomain : $domain;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/TargetOperation.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/TargetOperation.php
index 682b575..2c0ec72 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/TargetOperation.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Catalogue/TargetOperation.php
@@ -26,7 +26,7 @@
class TargetOperation extends AbstractOperation
{
/**
- * {@inheritdoc}
+ * @return void
*/
protected function processDomain(string $domain)
{
@@ -37,6 +37,18 @@
];
$intlDomain = $domain.MessageCatalogueInterface::INTL_DOMAIN_SUFFIX;
+ foreach ($this->target->getCatalogueMetadata('', $domain) ?? [] as $key => $value) {
+ if (null === $this->result->getCatalogueMetadata($key, $domain)) {
+ $this->result->setCatalogueMetadata($key, $value, $domain);
+ }
+ }
+
+ foreach ($this->target->getCatalogueMetadata('', $intlDomain) ?? [] as $key => $value) {
+ if (null === $this->result->getCatalogueMetadata($key, $intlDomain)) {
+ $this->result->setCatalogueMetadata($key, $value, $intlDomain);
+ }
+ }
+
// For 'all' messages, the code can't be simplified as ``$this->messages[$domain]['all'] = $target->all($domain);``,
// because doing so will drop messages like {x: x ∈ source ∧ x ∉ target.all ∧ x ∈ target.fallback}
//
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/CatalogueMetadataAwareInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/CatalogueMetadataAwareInterface.php
new file mode 100644
index 0000000..c845959
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/CatalogueMetadataAwareInterface.php
@@ -0,0 +1,48 @@
+<?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\Component\Translation;
+
+/**
+ * This interface is used to get, set, and delete metadata about the Catalogue.
+ *
+ * @author Hugo Alliaume <hugo@alliau.me>
+ */
+interface CatalogueMetadataAwareInterface
+{
+ /**
+ * Gets catalogue metadata for the given domain and key.
+ *
+ * Passing an empty domain will return an array with all catalogue metadata indexed by
+ * domain and then by key. Passing an empty key will return an array with all
+ * catalogue metadata for the given domain.
+ *
+ * @return mixed The value that was set or an array with the domains/keys or null
+ */
+ public function getCatalogueMetadata(string $key = '', string $domain = 'messages'): mixed;
+
+ /**
+ * Adds catalogue metadata to a message domain.
+ *
+ * @return void
+ */
+ public function setCatalogueMetadata(string $key, mixed $value, string $domain = 'messages');
+
+ /**
+ * Deletes catalogue metadata for the given key and domain.
+ *
+ * Passing an empty domain will delete all catalogue metadata. Passing an empty key will
+ * delete all metadata for the given domain.
+ *
+ * @return void
+ */
+ public function deleteCatalogueMetadata(string $key = '', string $domain = 'messages');
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPullCommand.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPullCommand.php
index 42513a8..5d9c092 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPullCommand.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPullCommand.php
@@ -34,9 +34,9 @@
{
use TranslationTrait;
- private $providerCollection;
- private $writer;
- private $reader;
+ private TranslationProviderCollection $providerCollection;
+ private TranslationWriterInterface $writer;
+ private TranslationReaderInterface $reader;
private string $defaultLocale;
private array $transPaths;
private array $enabledLocales;
@@ -64,9 +64,8 @@
if ($input->mustSuggestOptionValuesFor('domains')) {
$provider = $this->providerCollection->get($input->getArgument('provider'));
- if ($provider && method_exists($provider, 'getDomains')) {
- $domains = $provider->getDomains();
- $suggestions->suggestValues($domains);
+ if (method_exists($provider, 'getDomains')) {
+ $suggestions->suggestValues($provider->getDomains());
}
return;
@@ -83,10 +82,7 @@
}
}
- /**
- * {@inheritdoc}
- */
- protected function configure()
+ protected function configure(): void
{
$keys = $this->providerCollection->keys();
$defaultProvider = 1 === \count($keys) ? $keys[0] : null;
@@ -99,6 +95,7 @@
new InputOption('domains', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY, 'Specify the domains to pull.'),
new InputOption('locales', null, InputOption::VALUE_OPTIONAL | InputOption::VALUE_IS_ARRAY, 'Specify the locales to pull.'),
new InputOption('format', null, InputOption::VALUE_OPTIONAL, 'Override the default output format.', 'xlf12'),
+ new InputOption('as-tree', null, InputOption::VALUE_OPTIONAL, 'Write messages as a tree-like structure. Needs --format=yaml. The given value defines the level where to switch to inline YAML'),
])
->setHelp(<<<'EOF'
The <info>%command.name%</> command pulls translations from the given provider. Only
@@ -120,9 +117,6 @@
;
}
- /**
- * {@inheritdoc}
- */
protected function execute(InputInterface $input, OutputInterface $output): int
{
$io = new SymfonyStyle($input, $output);
@@ -133,6 +127,7 @@
$locales = $input->getOption('locales') ?: $this->enabledLocales;
$domains = $input->getOption('domains');
$format = $input->getOption('format');
+ $asTree = (int) $input->getOption('as-tree');
$xliffVersion = '1.2';
if ($intlIcu && !$force) {
@@ -141,7 +136,7 @@
switch ($format) {
case 'xlf20': $xliffVersion = '2.0';
- // no break
+ // no break
case 'xlf12': $format = 'xlf';
}
@@ -149,6 +144,8 @@
'path' => end($this->transPaths),
'xliff_version' => $xliffVersion,
'default_locale' => $this->defaultLocale,
+ 'as_tree' => (bool) $asTree,
+ 'inline' => $asTree,
];
if (!$domains) {
@@ -159,7 +156,7 @@
if ($force) {
foreach ($providerTranslations->getCatalogues() as $catalogue) {
- $operation = new TargetOperation((new MessageCatalogue($catalogue->getLocale())), $catalogue);
+ $operation = new TargetOperation(new MessageCatalogue($catalogue->getLocale()), $catalogue);
if ($intlIcu) {
$operation->moveMessagesToIntlDomainsIfPossible();
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPushCommand.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPushCommand.php
index dba2164..1d04adb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPushCommand.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/TranslationPushCommand.php
@@ -21,6 +21,7 @@
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Console\Style\SymfonyStyle;
+use Symfony\Component\Translation\Provider\FilteringProvider;
use Symfony\Component\Translation\Provider\TranslationProviderCollection;
use Symfony\Component\Translation\Reader\TranslationReaderInterface;
use Symfony\Component\Translation\TranslatorBag;
@@ -33,8 +34,8 @@
{
use TranslationTrait;
- private $providers;
- private $reader;
+ private TranslationProviderCollection $providers;
+ private TranslationReaderInterface $reader;
private array $transPaths;
private array $enabledLocales;
@@ -72,10 +73,7 @@
}
}
- /**
- * {@inheritdoc}
- */
- protected function configure()
+ protected function configure(): void
{
$keys = $this->providers->keys();
$defaultProvider = 1 === \count($keys) ? $keys[0] : null;
@@ -112,15 +110,12 @@
;
}
- /**
- * {@inheritdoc}
- */
protected function execute(InputInterface $input, OutputInterface $output): int
{
$provider = $this->providers->get($input->getArgument('provider'));
if (!$this->enabledLocales) {
- throw new InvalidArgumentException(sprintf('You must define "framework.translator.enabled_locales" or "framework.translator.providers.%s.locales" config key in order to work with translation providers.', parse_url($provider, \PHP_URL_SCHEME)));
+ throw new InvalidArgumentException(sprintf('You must define "framework.enabled_locales" or "framework.translator.providers.%s.locales" config key in order to work with translation providers.', parse_url($provider, \PHP_URL_SCHEME)));
}
$io = new SymfonyStyle($input, $output);
@@ -129,6 +124,12 @@
$force = $input->getOption('force');
$deleteMissing = $input->getOption('delete-missing');
+ if (!$domains && $provider instanceof FilteringProvider) {
+ $domains = $provider->getDomains();
+ }
+
+ // Reading local translations must be done after retrieving the domains from the provider
+ // in order to manage only translations from configured domains
$localTranslations = $this->readLocalTranslations($locales, $domains, $this->transPaths);
if (!$domains) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/XliffLintCommand.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/XliffLintCommand.php
index f062fb7..ba94638 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/XliffLintCommand.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Command/XliffLintCommand.php
@@ -41,23 +41,23 @@
private ?\Closure $isReadableProvider;
private bool $requireStrictFileNames;
- public function __construct(string $name = null, callable $directoryIteratorProvider = null, callable $isReadableProvider = null, bool $requireStrictFileNames = true)
+ public function __construct(?string $name = null, ?callable $directoryIteratorProvider = null, ?callable $isReadableProvider = null, bool $requireStrictFileNames = true)
{
parent::__construct($name);
- $this->directoryIteratorProvider = null === $directoryIteratorProvider || $directoryIteratorProvider instanceof \Closure ? $directoryIteratorProvider : \Closure::fromCallable($directoryIteratorProvider);
- $this->isReadableProvider = null === $isReadableProvider || $isReadableProvider instanceof \Closure ? $isReadableProvider : \Closure::fromCallable($isReadableProvider);
+ $this->directoryIteratorProvider = null === $directoryIteratorProvider ? null : $directoryIteratorProvider(...);
+ $this->isReadableProvider = null === $isReadableProvider ? null : $isReadableProvider(...);
$this->requireStrictFileNames = $requireStrictFileNames;
}
/**
- * {@inheritdoc}
+ * @return void
*/
protected function configure()
{
$this
->addArgument('filename', InputArgument::IS_ARRAY, 'A file, a directory or "-" for reading from STDIN')
- ->addOption('format', null, InputOption::VALUE_REQUIRED, 'The output format')
+ ->addOption('format', null, InputOption::VALUE_REQUIRED, sprintf('The output format ("%s")', implode('", "', $this->getAvailableFormatOptions())))
->setHelp(<<<EOF
The <info>%command.name%</info> command lints an XLIFF file and outputs to STDOUT
the first encountered syntax error.
@@ -109,7 +109,7 @@
return $this->display($io, $filesInfo);
}
- private function validate(string $content, string $file = null): array
+ private function validate(string $content, ?string $file = null): array
{
$errors = [];
@@ -154,21 +154,17 @@
return ['file' => $file, 'valid' => 0 === \count($errors), 'messages' => $errors];
}
- private function display(SymfonyStyle $io, array $files)
+ private function display(SymfonyStyle $io, array $files): int
{
- switch ($this->format) {
- case 'txt':
- return $this->displayTxt($io, $files);
- case 'json':
- return $this->displayJson($io, $files);
- case 'github':
- return $this->displayTxt($io, $files, true);
- default:
- throw new InvalidArgumentException(sprintf('The format "%s" is not supported.', $this->format));
- }
+ return match ($this->format) {
+ 'txt' => $this->displayTxt($io, $files),
+ 'json' => $this->displayJson($io, $files),
+ 'github' => $this->displayTxt($io, $files, true),
+ default => throw new InvalidArgumentException(sprintf('Supported formats are "%s".', implode('", "', $this->getAvailableFormatOptions()))),
+ };
}
- private function displayTxt(SymfonyStyle $io, array $filesInfo, bool $errorAsGithubAnnotations = false)
+ private function displayTxt(SymfonyStyle $io, array $filesInfo, bool $errorAsGithubAnnotations = false): int
{
$countFiles = \count($filesInfo);
$erroredFiles = 0;
@@ -184,9 +180,7 @@
// general document errors have a '-1' line number
$line = -1 === $error['line'] ? null : $error['line'];
- if ($githubReporter) {
- $githubReporter->error($error['message'], $info['file'], $line, null !== $line ? $error['column'] : null);
- }
+ $githubReporter?->error($error['message'], $info['file'], $line, null !== $line ? $error['column'] : null);
return null === $line ? $error['message'] : sprintf('Line %d, Column %d: %s', $line, $error['column'], $error['message']);
}, $info['messages']));
@@ -202,7 +196,7 @@
return min($erroredFiles, 1);
}
- private function displayJson(SymfonyStyle $io, array $filesInfo)
+ private function displayJson(SymfonyStyle $io, array $filesInfo): int
{
$errors = 0;
@@ -218,7 +212,10 @@
return min($errors, 1);
}
- private function getFiles(string $fileOrDirectory)
+ /**
+ * @return iterable<\SplFileInfo>
+ */
+ private function getFiles(string $fileOrDirectory): iterable
{
if (is_file($fileOrDirectory)) {
yield new \SplFileInfo($fileOrDirectory);
@@ -235,14 +232,15 @@
}
}
- private function getDirectoryIterator(string $directory)
+ /**
+ * @return iterable<\SplFileInfo>
+ */
+ private function getDirectoryIterator(string $directory): iterable
{
- $default = function ($directory) {
- return new \RecursiveIteratorIterator(
- new \RecursiveDirectoryIterator($directory, \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS),
- \RecursiveIteratorIterator::LEAVES_ONLY
- );
- };
+ $default = fn ($directory) => new \RecursiveIteratorIterator(
+ new \RecursiveDirectoryIterator($directory, \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS),
+ \RecursiveIteratorIterator::LEAVES_ONLY
+ );
if (null !== $this->directoryIteratorProvider) {
return ($this->directoryIteratorProvider)($directory, $default);
@@ -251,11 +249,9 @@
return $default($directory);
}
- private function isReadable(string $fileOrDirectory)
+ private function isReadable(string $fileOrDirectory): bool
{
- $default = function ($fileOrDirectory) {
- return is_readable($fileOrDirectory);
- };
+ $default = fn ($fileOrDirectory) => is_readable($fileOrDirectory);
if (null !== $this->isReadableProvider) {
return ($this->isReadableProvider)($fileOrDirectory, $default);
@@ -278,7 +274,12 @@
public function complete(CompletionInput $input, CompletionSuggestions $suggestions): void
{
if ($input->mustSuggestOptionValuesFor('format')) {
- $suggestions->suggestValues(['txt', 'json', 'github']);
+ $suggestions->suggestValues($this->getAvailableFormatOptions());
}
}
+
+ private function getAvailableFormatOptions(): array
+ {
+ return ['txt', 'json', 'github'];
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollector/TranslationDataCollector.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollector/TranslationDataCollector.php
index 0f7901d..d4f49cc 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollector/TranslationDataCollector.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollector/TranslationDataCollector.php
@@ -25,17 +25,14 @@
*/
class TranslationDataCollector extends DataCollector implements LateDataCollectorInterface
{
- private $translator;
+ private DataCollectorTranslator $translator;
public function __construct(DataCollectorTranslator $translator)
{
$this->translator = $translator;
}
- /**
- * {@inheritdoc}
- */
- public function lateCollect()
+ public function lateCollect(): void
{
$messages = $this->sanitizeCollectedMessages($this->translator->getCollectedMessages());
@@ -45,19 +42,13 @@
$this->data = $this->cloneVar($this->data);
}
- /**
- * {@inheritdoc}
- */
- public function collect(Request $request, Response $response, \Throwable $exception = null)
+ public function collect(Request $request, Response $response, ?\Throwable $exception = null): void
{
$this->data['locale'] = $this->translator->getLocale();
$this->data['fallback_locales'] = $this->translator->getFallbackLocales();
}
- /**
- * {@inheritdoc}
- */
- public function reset()
+ public function reset(): void
{
$this->data = [];
}
@@ -82,7 +73,7 @@
return $this->data[DataCollectorTranslator::MESSAGE_DEFINED] ?? 0;
}
- public function getLocale()
+ public function getLocale(): ?string
{
return !empty($this->data['locale']) ? $this->data['locale'] : null;
}
@@ -90,20 +81,17 @@
/**
* @internal
*/
- public function getFallbackLocales()
+ public function getFallbackLocales(): Data|array
{
return (isset($this->data['fallback_locales']) && \count($this->data['fallback_locales']) > 0) ? $this->data['fallback_locales'] : [];
}
- /**
- * {@inheritdoc}
- */
public function getName(): string
{
return 'translation';
}
- private function sanitizeCollectedMessages(array $messages)
+ private function sanitizeCollectedMessages(array $messages): array
{
$result = [];
foreach ($messages as $key => $message) {
@@ -128,7 +116,7 @@
return $result;
}
- private function computeCount(array $messages)
+ private function computeCount(array $messages): array
{
$count = [
DataCollectorTranslator::MESSAGE_DEFINED => 0,
@@ -143,7 +131,7 @@
return $count;
}
- private function sanitizeString(string $string, int $length = 80)
+ private function sanitizeString(string $string, int $length = 80): string
{
$string = trim(preg_replace('/\s+/', ' ', $string));
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollectorTranslator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollectorTranslator.php
index 2a08b09..a2832ee 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollectorTranslator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DataCollectorTranslator.php
@@ -25,7 +25,7 @@
public const MESSAGE_MISSING = 1;
public const MESSAGE_EQUALS_FALLBACK = 2;
- private $translator;
+ private TranslatorInterface $translator;
private array $messages = [];
/**
@@ -40,10 +40,7 @@
$this->translator = $translator;
}
- /**
- * {@inheritdoc}
- */
- public function trans(?string $id, array $parameters = [], string $domain = null, string $locale = null): string
+ public function trans(?string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string
{
$trans = $this->translator->trans($id = (string) $id, $parameters, $domain, $locale);
$this->collectMessage($locale, $domain, $id, $trans, $parameters);
@@ -52,46 +49,32 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function setLocale(string $locale)
{
$this->translator->setLocale($locale);
}
- /**
- * {@inheritdoc}
- */
public function getLocale(): string
{
return $this->translator->getLocale();
}
- /**
- * {@inheritdoc}
- */
- public function getCatalogue(string $locale = null): MessageCatalogueInterface
+ public function getCatalogue(?string $locale = null): MessageCatalogueInterface
{
return $this->translator->getCatalogue($locale);
}
- /**
- * {@inheritdoc}
- */
public function getCatalogues(): array
{
return $this->translator->getCatalogues();
}
- /**
- * {@inheritdoc}
- *
- * @return string[]
- */
- public function warmUp(string $cacheDir): array
+ public function warmUp(string $cacheDir, ?string $buildDir = null): array
{
if ($this->translator instanceof WarmableInterface) {
- return (array) $this->translator->warmUp($cacheDir);
+ return (array) $this->translator->warmUp($cacheDir, $buildDir);
}
return [];
@@ -110,7 +93,7 @@
}
/**
- * Passes through all unknown calls onto the translator object.
+ * @return mixed
*/
public function __call(string $method, array $args)
{
@@ -122,11 +105,9 @@
return $this->messages;
}
- private function collectMessage(?string $locale, ?string $domain, string $id, string $translation, ?array $parameters = [])
+ private function collectMessage(?string $locale, ?string $domain, string $id, string $translation, ?array $parameters = []): void
{
- if (null === $domain) {
- $domain = 'messages';
- }
+ $domain ??= 'messages';
$catalogue = $this->translator->getCatalogue($locale);
$locale = $catalogue->getLocale();
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/DataCollectorTranslatorPass.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/DataCollectorTranslatorPass.php
new file mode 100644
index 0000000..cdf63be
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/DataCollectorTranslatorPass.php
@@ -0,0 +1,36 @@
+<?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\Component\Translation\DependencyInjection;
+
+use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
+use Symfony\Component\DependencyInjection\ContainerBuilder;
+use Symfony\Component\Translation\TranslatorBagInterface;
+
+/**
+ * @author Christian Flothmann <christian.flothmann@sensiolabs.de>
+ */
+class DataCollectorTranslatorPass implements CompilerPassInterface
+{
+ public function process(ContainerBuilder $container): void
+ {
+ if (!$container->has('translator')) {
+ return;
+ }
+
+ $translatorClass = $container->getParameterBag()->resolveValue($container->findDefinition('translator')->getClass());
+
+ if (!is_subclass_of($translatorClass, TranslatorBagInterface::class)) {
+ $container->removeDefinition('translator.data_collector');
+ $container->removeDefinition('data_collector.translation');
+ }
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/LoggingTranslatorPass.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/LoggingTranslatorPass.php
new file mode 100644
index 0000000..c21552f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/LoggingTranslatorPass.php
@@ -0,0 +1,59 @@
+<?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\Component\Translation\DependencyInjection;
+
+use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
+use Symfony\Component\DependencyInjection\ContainerBuilder;
+use Symfony\Component\DependencyInjection\Exception\InvalidArgumentException;
+use Symfony\Component\Translation\TranslatorBagInterface;
+use Symfony\Contracts\Translation\TranslatorInterface;
+
+/**
+ * @author Abdellatif Ait boudad <a.aitboudad@gmail.com>
+ */
+class LoggingTranslatorPass implements CompilerPassInterface
+{
+ public function process(ContainerBuilder $container): void
+ {
+ if (!$container->hasAlias('logger') || !$container->hasAlias('translator')) {
+ return;
+ }
+
+ if (!$container->hasParameter('translator.logging') || !$container->getParameter('translator.logging')) {
+ return;
+ }
+
+ $translatorAlias = $container->getAlias('translator');
+ $definition = $container->getDefinition((string) $translatorAlias);
+ $class = $container->getParameterBag()->resolveValue($definition->getClass());
+
+ if (!$r = $container->getReflectionClass($class)) {
+ throw new InvalidArgumentException(sprintf('Class "%s" used for service "%s" cannot be found.', $class, $translatorAlias));
+ }
+
+ if (!$r->isSubclassOf(TranslatorInterface::class) || !$r->isSubclassOf(TranslatorBagInterface::class)) {
+ return;
+ }
+
+ $container->getDefinition('translator.logging')->setDecoratedService('translator');
+ $warmer = $container->getDefinition('translation.warmer');
+ $subscriberAttributes = $warmer->getTag('container.service_subscriber');
+ $warmer->clearTag('container.service_subscriber');
+
+ foreach ($subscriberAttributes as $k => $v) {
+ if ((!isset($v['id']) || 'translator' !== $v['id']) && (!isset($v['key']) || 'translator' !== $v['key'])) {
+ $warmer->addTag('container.service_subscriber', $v);
+ }
+ }
+ $warmer->addTag('container.service_subscriber', ['key' => 'translator', 'id' => 'translator.logging.inner']);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationDumperPass.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationDumperPass.php
index 4020a07..2ece6ac 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationDumperPass.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationDumperPass.php
@@ -20,6 +20,9 @@
*/
class TranslationDumperPass implements CompilerPassInterface
{
+ /**
+ * @return void
+ */
public function process(ContainerBuilder $container)
{
if (!$container->hasDefinition('translation.writer')) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationExtractorPass.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationExtractorPass.php
index ee7c47a..1baf934 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationExtractorPass.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslationExtractorPass.php
@@ -21,6 +21,9 @@
*/
class TranslationExtractorPass implements CompilerPassInterface
{
+ /**
+ * @return void
+ */
public function process(ContainerBuilder $container)
{
if (!$container->hasDefinition('translation.extractor')) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPass.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPass.php
index be79cda..dd6ea3c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPass.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPass.php
@@ -18,6 +18,9 @@
class TranslatorPass implements CompilerPassInterface
{
+ /**
+ * @return void
+ */
public function process(ContainerBuilder $container)
{
if (!$container->hasDefinition('translator.default')) {
@@ -49,6 +52,23 @@
->replaceArgument(3, $loaders)
;
+ if ($container->hasDefinition('validator') && $container->hasDefinition('translation.extractor.visitor.constraint')) {
+ $constraintVisitorDefinition = $container->getDefinition('translation.extractor.visitor.constraint');
+ $constraintClassNames = [];
+
+ foreach ($container->getDefinitions() as $definition) {
+ if (!$definition->hasTag('validator.constraint_validator')) {
+ continue;
+ }
+ // Resolve constraint validator FQCN even if defined as %foo.validator.class% parameter
+ $className = $container->getParameterBag()->resolveValue($definition->getClass());
+ // Extraction of the constraint class name from the Constraint Validator FQCN
+ $constraintClassNames[] = str_replace('Validator', '', substr(strrchr($className, '\\'), 1));
+ }
+
+ $constraintVisitorDefinition->setArgument(0, $constraintClassNames);
+ }
+
if (!$container->hasParameter('twig.default_path')) {
return;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPathsPass.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPathsPass.php
index b85c066..1756e3c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPathsPass.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/DependencyInjection/TranslatorPathsPass.php
@@ -16,12 +16,15 @@
use Symfony\Component\DependencyInjection\Definition;
use Symfony\Component\DependencyInjection\Reference;
use Symfony\Component\DependencyInjection\ServiceLocator;
+use Symfony\Component\HttpKernel\Controller\ArgumentResolver\TraceableValueResolver;
/**
* @author Yonel Ceruto <yonelceruto@gmail.com>
*/
class TranslatorPathsPass extends AbstractRecursivePass
{
+ protected bool $skipScalars = true;
+
private int $level = 0;
/**
@@ -39,6 +42,9 @@
*/
private array $controllers = [];
+ /**
+ * @return void
+ */
public function process(ContainerBuilder $container)
{
if (!$container->hasDefinition('translator')) {
@@ -120,28 +126,20 @@
private function findControllerArguments(ContainerBuilder $container): array
{
- if ($container->hasDefinition('argument_resolver.service')) {
- $argument = $container->getDefinition('argument_resolver.service')->getArgument(0);
- if ($argument instanceof Reference) {
- $argument = $container->getDefinition($argument);
- }
+ if (!$container->has('argument_resolver.service')) {
+ return [];
+ }
+ $resolverDef = $container->findDefinition('argument_resolver.service');
- return $argument->getArgument(0);
+ if (TraceableValueResolver::class === $resolverDef->getClass()) {
+ $resolverDef = $container->getDefinition($resolverDef->getArgument(0));
}
- if ($container->hasDefinition('debug.'.'argument_resolver.service')) {
- $argument = $container->getDefinition('debug.'.'argument_resolver.service')->getArgument(0);
- if ($argument instanceof Reference) {
- $argument = $container->getDefinition($argument);
- }
- $argument = $argument->getArgument(0);
- if ($argument instanceof Reference) {
- $argument = $container->getDefinition($argument);
- }
-
- return $argument->getArgument(0);
+ $argument = $resolverDef->getArgument(0);
+ if ($argument instanceof Reference) {
+ $argument = $container->getDefinition($argument);
}
- return [];
+ return $argument->getArgument(0);
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/CsvFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/CsvFileDumper.php
index 0bd3f5e..8f54752 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/CsvFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/CsvFileDumper.php
@@ -23,9 +23,6 @@
private string $delimiter = ';';
private string $enclosure = '"';
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$handle = fopen('php://memory', 'r+');
@@ -43,6 +40,8 @@
/**
* Sets the delimiter and escape character for CSV.
+ *
+ * @return void
*/
public function setCsvControl(string $delimiter = ';', string $enclosure = '"')
{
@@ -50,9 +49,6 @@
$this->enclosure = $enclosure;
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'csv';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/DumperInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/DumperInterface.php
index 7cdaef5..6bf4293 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/DumperInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/DumperInterface.php
@@ -25,6 +25,8 @@
* Dumps the message catalogue.
*
* @param array $options Options that are used by the dumper
+ *
+ * @return void
*/
public function dump(MessageCatalogue $messages, array $options = []);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/FileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/FileDumper.php
index 6bad4ff..e30d477 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/FileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/FileDumper.php
@@ -35,7 +35,7 @@
/**
* Sets the template for the relative paths to files.
*
- * @param string $relativePathTemplate A template for the relative paths to files
+ * @return void
*/
public function setRelativePathTemplate(string $relativePathTemplate)
{
@@ -43,7 +43,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function dump(MessageCatalogue $messages, array $options = [])
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IcuResFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IcuResFileDumper.php
index b62ea15..72c1ec0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IcuResFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IcuResFileDumper.php
@@ -20,14 +20,8 @@
*/
class IcuResFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
protected $relativePathTemplate = '%domain%/%locale%.%extension%';
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$data = $indexes = $resources = '';
@@ -47,7 +41,7 @@
$data .= pack('V', \strlen($target))
.mb_convert_encoding($target."\0", 'UTF-16LE', 'UTF-8')
.$this->writePadding($data)
- ;
+ ;
}
$resOffset = $this->getPosition($data);
@@ -56,7 +50,7 @@
.$indexes
.$this->writePadding($data)
.$resources
- ;
+ ;
$bundleTop = $this->getPosition($data);
@@ -89,14 +83,11 @@
return $padding ? str_repeat("\xAA", 4 - $padding) : null;
}
- private function getPosition(string $data)
+ private function getPosition(string $data): float|int
{
return (\strlen($data) + 28) / 4;
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'res';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IniFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IniFileDumper.php
index 75032be..6cbdef6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IniFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/IniFileDumper.php
@@ -20,9 +20,6 @@
*/
class IniFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$output = '';
@@ -35,9 +32,6 @@
return $output;
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'ini';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/JsonFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/JsonFileDumper.php
index 1102730..e503539 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/JsonFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/JsonFileDumper.php
@@ -20,9 +20,6 @@
*/
class JsonFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$flags = $options['json_encoding'] ?? \JSON_PRETTY_PRINT;
@@ -30,9 +27,6 @@
return json_encode($messages->all($domain), $flags);
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'json';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/MoFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/MoFileDumper.php
index 08c8f89..9ded5f4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/MoFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/MoFileDumper.php
@@ -21,9 +21,6 @@
*/
class MoFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$sources = $targets = $sourceOffsets = $targetOffsets = '';
@@ -57,19 +54,16 @@
.$this->writeLong($offset[2] + $sourcesStart + $sourcesSize);
}
- $output = implode('', array_map([$this, 'writeLong'], $header))
+ $output = implode('', array_map($this->writeLong(...), $header))
.$sourceOffsets
.$targetOffsets
.$sources
.$targets
- ;
+ ;
return $output;
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'mo';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PhpFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PhpFileDumper.php
index 565d893..51e9066 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PhpFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PhpFileDumper.php
@@ -20,17 +20,11 @@
*/
class PhpFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
return "<?php\n\nreturn ".var_export($messages->all($domain), true).";\n";
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PoFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PoFileDumper.php
index 313e504..a2d0deb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PoFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/PoFileDumper.php
@@ -20,9 +20,6 @@
*/
class PoFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$output = 'msgid ""'."\n";
@@ -68,7 +65,7 @@
return $output;
}
- private function getStandardRules(string $id)
+ private function getStandardRules(string $id): array
{
// Partly copied from TranslatorTrait::trans.
$parts = [];
@@ -111,9 +108,6 @@
return $standardRules;
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'po';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/QtFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/QtFileDumper.php
index 819409f..0373e9c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/QtFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/QtFileDumper.php
@@ -20,9 +20,6 @@
*/
class QtFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$dom = new \DOMDocument('1.0', 'utf-8');
@@ -51,9 +48,6 @@
return $dom->saveXML();
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return 'ts';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/XliffFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/XliffFileDumper.php
index b8a109a..d0f016b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/XliffFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/XliffFileDumper.php
@@ -21,9 +21,11 @@
*/
class XliffFileDumper extends FileDumper
{
- /**
- * {@inheritdoc}
- */
+ public function __construct(
+ private string $extension = 'xlf',
+ ) {
+ }
+
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
$xliffVersion = '1.2';
@@ -47,15 +49,12 @@
throw new InvalidArgumentException(sprintf('No support implemented for dumping XLIFF version "%s".', $xliffVersion));
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
- return 'xlf';
+ return $this->extension;
}
- private function dumpXliff1(string $defaultLocale, MessageCatalogue $messages, ?string $domain, array $options = [])
+ private function dumpXliff1(string $defaultLocale, MessageCatalogue $messages, ?string $domain, array $options = []): string
{
$toolInfo = ['tool-id' => 'symfony', 'tool-name' => 'Symfony'];
if (\array_key_exists('tool_info', $options)) {
@@ -81,6 +80,15 @@
$xliffTool->setAttribute($id, $value);
}
+ if ($catalogueMetadata = $messages->getCatalogueMetadata('', $domain) ?? []) {
+ $xliffPropGroup = $xliffHead->appendChild($dom->createElement('prop-group'));
+ foreach ($catalogueMetadata as $key => $value) {
+ $xliffProp = $xliffPropGroup->appendChild($dom->createElement('prop'));
+ $xliffProp->setAttribute('prop-type', $key);
+ $xliffProp->appendChild($dom->createTextNode($value));
+ }
+ }
+
$xliffBody = $xliffFile->appendChild($dom->createElement('body'));
foreach ($messages->all($domain) as $source => $target) {
$translation = $dom->createElement('trans-unit');
@@ -129,7 +137,7 @@
return $dom->saveXML();
}
- private function dumpXliff2(string $defaultLocale, MessageCatalogue $messages, ?string $domain)
+ private function dumpXliff2(string $defaultLocale, MessageCatalogue $messages, ?string $domain): string
{
$dom = new \DOMDocument('1.0', 'utf-8');
$dom->formatOutput = true;
@@ -147,6 +155,16 @@
$xliffFile->setAttribute('id', $domain.'.'.$messages->getLocale());
}
+ if ($catalogueMetadata = $messages->getCatalogueMetadata('', $domain) ?? []) {
+ $xliff->setAttribute('xmlns:m', 'urn:oasis:names:tc:xliff:metadata:2.0');
+ $xliffMetadata = $xliffFile->appendChild($dom->createElement('m:metadata'));
+ foreach ($catalogueMetadata as $key => $value) {
+ $xliffMeta = $xliffMetadata->appendChild($dom->createElement('prop'));
+ $xliffMeta->setAttribute('type', $key);
+ $xliffMeta->appendChild($dom->createTextNode($value));
+ }
+ }
+
foreach ($messages->all($domain) as $source => $target) {
$translation = $dom->createElement('unit');
$translation->setAttribute('id', strtr(substr(base64_encode(hash('sha256', $source, true)), 0, 7), '/+', '._'));
@@ -196,7 +214,7 @@
return $dom->saveXML();
}
- private function hasMetadataArrayInfo(string $key, array $metadata = null): bool
+ private function hasMetadataArrayInfo(string $key, ?array $metadata = null): bool
{
return is_iterable($metadata[$key] ?? null);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/YamlFileDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/YamlFileDumper.php
index d0cfbef..d267033 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/YamlFileDumper.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Dumper/YamlFileDumper.php
@@ -30,9 +30,6 @@
$this->extension = $extension;
}
- /**
- * {@inheritdoc}
- */
public function formatCatalogue(MessageCatalogue $messages, string $domain, array $options = []): string
{
if (!class_exists(Yaml::class)) {
@@ -52,9 +49,6 @@
return Yaml::dump($data);
}
- /**
- * {@inheritdoc}
- */
protected function getExtension(): string
{
return $this->extension;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/IncompleteDsnException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/IncompleteDsnException.php
index cb0ce02..b304bde 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/IncompleteDsnException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/IncompleteDsnException.php
@@ -13,7 +13,7 @@
class IncompleteDsnException extends InvalidArgumentException
{
- public function __construct(string $message, string $dsn = null, \Throwable $previous = null)
+ public function __construct(string $message, ?string $dsn = null, ?\Throwable $previous = null)
{
if ($dsn) {
$message = sprintf('Invalid "%s" provider DSN: ', $dsn).$message;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/MissingRequiredOptionException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/MissingRequiredOptionException.php
index 2b5f808..46152e2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/MissingRequiredOptionException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/MissingRequiredOptionException.php
@@ -16,7 +16,7 @@
*/
class MissingRequiredOptionException extends IncompleteDsnException
{
- public function __construct(string $option, string $dsn = null, \Throwable $previous = null)
+ public function __construct(string $option, ?string $dsn = null, ?\Throwable $previous = null)
{
$message = sprintf('The option "%s" is required but missing.', $option);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/ProviderException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/ProviderException.php
index 331ff75..f2981f5 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/ProviderException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/ProviderException.php
@@ -18,10 +18,10 @@
*/
class ProviderException extends RuntimeException implements ProviderExceptionInterface
{
- private $response;
+ private ResponseInterface $response;
private string $debug;
- public function __construct(string $message, ResponseInterface $response, int $code = 0, \Exception $previous = null)
+ public function __construct(string $message, ResponseInterface $response, int $code = 0, ?\Exception $previous = null)
{
$this->response = $response;
$this->debug = $response->getInfo('debug') ?? '';
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/UnsupportedSchemeException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/UnsupportedSchemeException.php
index 7fbaa8f..8d32951 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/UnsupportedSchemeException.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Exception/UnsupportedSchemeException.php
@@ -29,9 +29,13 @@
'class' => Bridge\Lokalise\LokaliseProviderFactory::class,
'package' => 'symfony/lokalise-translation-provider',
],
+ 'phrase' => [
+ 'class' => Bridge\Phrase\PhraseProviderFactory::class,
+ 'package' => 'symfony/phrase-translation-provider',
+ ],
];
- public function __construct(Dsn $dsn, string $name = null, array $supported = [])
+ public function __construct(Dsn $dsn, ?string $name = null, array $supported = [])
{
$provider = $dsn->getScheme();
if (false !== $pos = strpos($provider, '+')) {
@@ -39,7 +43,7 @@
}
$package = self::SCHEME_TO_PACKAGE_MAP[$provider] ?? null;
if ($package && !class_exists($package['class'])) {
- parent::__construct(sprintf('Unable to synchronize translations via "%s" as the provider is not installed; try running "composer require %s".', $provider, $package['package']));
+ parent::__construct(sprintf('Unable to synchronize translations via "%s" as the provider is not installed. Try running "composer require %s".', $provider, $package['package']));
return;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ChainExtractor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ChainExtractor.php
index e58e82f..d36f7f3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ChainExtractor.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ChainExtractor.php
@@ -29,6 +29,8 @@
/**
* Adds a loader to the translation extractor.
+ *
+ * @return void
*/
public function addExtractor(string $format, ExtractorInterface $extractor)
{
@@ -36,7 +38,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function setPrefix(string $prefix)
{
@@ -46,7 +48,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function extract(string|iterable $directory, MessageCatalogue $catalogue)
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ExtractorInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ExtractorInterface.php
index b76a7f2..642130a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ExtractorInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/ExtractorInterface.php
@@ -25,11 +25,15 @@
* Extracts translation messages from files, a file or a directory to the catalogue.
*
* @param string|iterable<string> $resource Files, a file or a directory
+ *
+ * @return void
*/
public function extract(string|iterable $resource, MessageCatalogue $catalogue);
/**
* Sets the prefix that should be used for new found messages.
+ *
+ * @return void
*/
public function setPrefix(string $prefix);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpAstExtractor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpAstExtractor.php
new file mode 100644
index 0000000..06fc77d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpAstExtractor.php
@@ -0,0 +1,85 @@
+<?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\Component\Translation\Extractor;
+
+use PhpParser\NodeTraverser;
+use PhpParser\NodeVisitor;
+use PhpParser\Parser;
+use PhpParser\ParserFactory;
+use Symfony\Component\Finder\Finder;
+use Symfony\Component\Translation\Extractor\Visitor\AbstractVisitor;
+use Symfony\Component\Translation\MessageCatalogue;
+
+/**
+ * PhpAstExtractor extracts translation messages from a PHP AST.
+ *
+ * @author Mathieu Santostefano <msantostefano@protonmail.com>
+ */
+final class PhpAstExtractor extends AbstractFileExtractor implements ExtractorInterface
+{
+ private Parser $parser;
+
+ public function __construct(
+ /**
+ * @param iterable<AbstractVisitor&NodeVisitor> $visitors
+ */
+ private readonly iterable $visitors,
+ private string $prefix = '',
+ ) {
+ if (!class_exists(ParserFactory::class)) {
+ throw new \LogicException(sprintf('You cannot use "%s" as the "nikic/php-parser" package is not installed. Try running "composer require nikic/php-parser".', static::class));
+ }
+
+ $this->parser = (new ParserFactory())->createForHostVersion();
+ }
+
+ public function extract(iterable|string $resource, MessageCatalogue $catalogue): void
+ {
+ foreach ($this->extractFiles($resource) as $file) {
+ $traverser = new NodeTraverser();
+
+ // This is needed to resolve namespaces in class methods/constants.
+ $nameResolver = new NodeVisitor\NameResolver();
+ $traverser->addVisitor($nameResolver);
+
+ /** @var AbstractVisitor&NodeVisitor $visitor */
+ foreach ($this->visitors as $visitor) {
+ $visitor->initialize($catalogue, $file, $this->prefix);
+ $traverser->addVisitor($visitor);
+ }
+
+ $nodes = $this->parser->parse(file_get_contents($file));
+ $traverser->traverse($nodes);
+ }
+ }
+
+ public function setPrefix(string $prefix): void
+ {
+ $this->prefix = $prefix;
+ }
+
+ protected function canBeExtracted(string $file): bool
+ {
+ return 'php' === pathinfo($file, \PATHINFO_EXTENSION)
+ && $this->isFile($file)
+ && preg_match('/\bt\(|->trans\(|TranslatableMessage|Symfony\\\\Component\\\\Validator\\\\Constraints/i', file_get_contents($file));
+ }
+
+ protected function extractFromDirectory(array|string $resource): iterable|Finder
+ {
+ if (!class_exists(Finder::class)) {
+ throw new \LogicException(sprintf('You cannot use "%s" as the "symfony/finder" package is not installed. Try running "composer require symfony/finder".', static::class));
+ }
+
+ return (new Finder())->files()->name('*.php')->in($resource);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpExtractor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpExtractor.php
index 1b86cc5..7ff27f7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpExtractor.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpExtractor.php
@@ -11,6 +11,8 @@
namespace Symfony\Component\Translation\Extractor;
+trigger_deprecation('symfony/translation', '6.2', '"%s" is deprecated, use "%s" instead.', PhpExtractor::class, PhpAstExtractor::class);
+
use Symfony\Component\Finder\Finder;
use Symfony\Component\Translation\MessageCatalogue;
@@ -18,6 +20,8 @@
* PhpExtractor extracts translation messages from a PHP template.
*
* @author Michel Salib <michelsalib@hotmail.com>
+ *
+ * @deprecated since Symfony 6.2, use the PhpAstExtractor instead
*/
class PhpExtractor extends AbstractFileExtractor implements ExtractorInterface
{
@@ -129,7 +133,7 @@
];
/**
- * {@inheritdoc}
+ * @return void
*/
public function extract(string|iterable $resource, MessageCatalogue $catalog)
{
@@ -142,7 +146,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function setPrefix(string $prefix)
{
@@ -164,7 +168,7 @@
/**
* Seeks to a non-whitespace token.
*/
- private function seekToNextRelevantToken(\Iterator $tokenIterator)
+ private function seekToNextRelevantToken(\Iterator $tokenIterator): void
{
for (; $tokenIterator->valid(); $tokenIterator->next()) {
$t = $tokenIterator->current();
@@ -174,7 +178,7 @@
}
}
- private function skipMethodArgument(\Iterator $tokenIterator)
+ private function skipMethodArgument(\Iterator $tokenIterator): void
{
$openBraces = 0;
@@ -199,7 +203,7 @@
* Extracts the message from the iterator while the tokens
* match allowed message tokens.
*/
- private function getValue(\Iterator $tokenIterator)
+ private function getValue(\Iterator $tokenIterator): string
{
$message = '';
$docToken = '';
@@ -257,6 +261,8 @@
/**
* Extracts trans message from PHP tokens.
+ *
+ * @return void
*/
protected function parseTokens(array $tokens, MessageCatalogue $catalog, string $filename)
{
@@ -314,9 +320,6 @@
return $this->isFile($file) && 'php' === pathinfo($file, \PATHINFO_EXTENSION);
}
- /**
- * {@inheritdoc}
- */
protected function extractFromDirectory(string|array $directory): iterable
{
if (!class_exists(Finder::class)) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpStringTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpStringTokenParser.php
index 7fbd37c..2dfc1e3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpStringTokenParser.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/PhpStringTokenParser.php
@@ -11,6 +11,8 @@
namespace Symfony\Component\Translation\Extractor;
+trigger_deprecation('symfony/translation', '6.2', '"%s" is deprecated.', PhpStringTokenParser::class);
+
/*
* The following is derived from code at http://github.com/nikic/PHP-Parser
*
@@ -47,6 +49,9 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+/**
+ * @deprecated since Symfony 6.2
+ */
class PhpStringTokenParser
{
protected static $replacements = [
@@ -89,7 +94,7 @@
* @param string $str String without quotes
* @param string|null $quote Quote type
*/
- public static function parseEscapeSequences(string $str, string $quote = null): string
+ public static function parseEscapeSequences(string $str, ?string $quote = null): string
{
if (null !== $quote) {
$str = str_replace('\\'.$quote, $quote, $str);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/AbstractVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/AbstractVisitor.php
new file mode 100644
index 0000000..c336896
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/AbstractVisitor.php
@@ -0,0 +1,135 @@
+<?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\Component\Translation\Extractor\Visitor;
+
+use PhpParser\Node;
+use Symfony\Component\Translation\MessageCatalogue;
+
+/**
+ * @author Mathieu Santostefano <msantostefano@protonmail.com>
+ */
+abstract class AbstractVisitor
+{
+ private MessageCatalogue $catalogue;
+ private \SplFileInfo $file;
+ private string $messagePrefix;
+
+ public function initialize(MessageCatalogue $catalogue, \SplFileInfo $file, string $messagePrefix): void
+ {
+ $this->catalogue = $catalogue;
+ $this->file = $file;
+ $this->messagePrefix = $messagePrefix;
+ }
+
+ protected function addMessageToCatalogue(string $message, ?string $domain, int $line): void
+ {
+ $domain ??= 'messages';
+ $this->catalogue->set($message, $this->messagePrefix.$message, $domain);
+ $metadata = $this->catalogue->getMetadata($message, $domain) ?? [];
+ $normalizedFilename = preg_replace('{[\\\\/]+}', '/', $this->file);
+ $metadata['sources'][] = $normalizedFilename.':'.$line;
+ $this->catalogue->setMetadata($message, $metadata, $domain);
+ }
+
+ protected function getStringArguments(Node\Expr\CallLike|Node\Attribute|Node\Expr\New_ $node, int|string $index, bool $indexIsRegex = false): array
+ {
+ if (\is_string($index)) {
+ return $this->getStringNamedArguments($node, $index, $indexIsRegex);
+ }
+
+ $args = $node instanceof Node\Expr\CallLike ? $node->getRawArgs() : $node->args;
+
+ if (!($arg = $args[$index] ?? null) instanceof Node\Arg) {
+ return [];
+ }
+
+ return (array) $this->getStringValue($arg->value);
+ }
+
+ protected function hasNodeNamedArguments(Node\Expr\CallLike|Node\Attribute|Node\Expr\New_ $node): bool
+ {
+ $args = $node instanceof Node\Expr\CallLike ? $node->getRawArgs() : $node->args;
+
+ foreach ($args as $arg) {
+ if ($arg instanceof Node\Arg && null !== $arg->name) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ protected function nodeFirstNamedArgumentIndex(Node\Expr\CallLike|Node\Attribute|Node\Expr\New_ $node): int
+ {
+ $args = $node instanceof Node\Expr\CallLike ? $node->getRawArgs() : $node->args;
+
+ foreach ($args as $i => $arg) {
+ if ($arg instanceof Node\Arg && null !== $arg->name) {
+ return $i;
+ }
+ }
+
+ return \PHP_INT_MAX;
+ }
+
+ private function getStringNamedArguments(Node\Expr\CallLike|Node\Attribute $node, ?string $argumentName = null, bool $isArgumentNamePattern = false): array
+ {
+ $args = $node instanceof Node\Expr\CallLike ? $node->getArgs() : $node->args;
+ $argumentValues = [];
+
+ foreach ($args as $arg) {
+ if (!$isArgumentNamePattern && $arg->name?->toString() === $argumentName) {
+ $argumentValues[] = $this->getStringValue($arg->value);
+ } elseif ($isArgumentNamePattern && preg_match($argumentName, $arg->name?->toString() ?? '') > 0) {
+ $argumentValues[] = $this->getStringValue($arg->value);
+ }
+ }
+
+ return array_filter($argumentValues);
+ }
+
+ private function getStringValue(Node $node): ?string
+ {
+ if ($node instanceof Node\Scalar\String_) {
+ return $node->value;
+ }
+
+ if ($node instanceof Node\Expr\BinaryOp\Concat) {
+ if (null === $left = $this->getStringValue($node->left)) {
+ return null;
+ }
+
+ if (null === $right = $this->getStringValue($node->right)) {
+ return null;
+ }
+
+ return $left.$right;
+ }
+
+ if ($node instanceof Node\Expr\Assign && $node->expr instanceof Node\Scalar\String_) {
+ return $node->expr->value;
+ }
+
+ if ($node instanceof Node\Expr\ClassConstFetch) {
+ try {
+ $reflection = new \ReflectionClass($node->class->toString());
+ $constant = $reflection->getReflectionConstant($node->name->toString());
+ if (false !== $constant && \is_string($constant->getValue())) {
+ return $constant->getValue();
+ }
+ } catch (\ReflectionException) {
+ }
+ }
+
+ return null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/ConstraintVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/ConstraintVisitor.php
new file mode 100644
index 0000000..00fb9ee
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/ConstraintVisitor.php
@@ -0,0 +1,112 @@
+<?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\Component\Translation\Extractor\Visitor;
+
+use PhpParser\Node;
+use PhpParser\NodeVisitor;
+
+/**
+ * @author Mathieu Santostefano <msantostefano@protonmail.com>
+ *
+ * Code mostly comes from https://github.com/php-translation/extractor/blob/master/src/Visitor/Php/Symfony/Constraint.php
+ */
+final class ConstraintVisitor extends AbstractVisitor implements NodeVisitor
+{
+ public function __construct(
+ private readonly array $constraintClassNames = []
+ ) {
+ }
+
+ public function beforeTraverse(array $nodes): ?Node
+ {
+ return null;
+ }
+
+ public function enterNode(Node $node): ?Node
+ {
+ return null;
+ }
+
+ public function leaveNode(Node $node): ?Node
+ {
+ if (!$node instanceof Node\Expr\New_ && !$node instanceof Node\Attribute) {
+ return null;
+ }
+
+ $className = $node instanceof Node\Attribute ? $node->name : $node->class;
+ if (!$className instanceof Node\Name) {
+ return null;
+ }
+
+ $parts = $className->getParts();
+ $isConstraintClass = false;
+
+ foreach ($parts as $part) {
+ if (\in_array($part, $this->constraintClassNames, true)) {
+ $isConstraintClass = true;
+
+ break;
+ }
+ }
+
+ if (!$isConstraintClass) {
+ return null;
+ }
+
+ $arg = $node->args[0] ?? null;
+ if (!$arg instanceof Node\Arg) {
+ return null;
+ }
+
+ if ($this->hasNodeNamedArguments($node)) {
+ $messages = $this->getStringArguments($node, '/message/i', true);
+ } else {
+ if (!$arg->value instanceof Node\Expr\Array_) {
+ // There is no way to guess which argument is a message to be translated.
+ return null;
+ }
+
+ $messages = [];
+ $options = $arg->value;
+
+ /** @var Node\Expr\ArrayItem $item */
+ foreach ($options->items as $item) {
+ if (!$item->key instanceof Node\Scalar\String_) {
+ continue;
+ }
+
+ if (false === stripos($item->key->value ?? '', 'message')) {
+ continue;
+ }
+
+ if (!$item->value instanceof Node\Scalar\String_) {
+ continue;
+ }
+
+ $messages[] = $item->value->value;
+
+ break;
+ }
+ }
+
+ foreach ($messages as $message) {
+ $this->addMessageToCatalogue($message, 'validators', $node->getStartLine());
+ }
+
+ return null;
+ }
+
+ public function afterTraverse(array $nodes): ?Node
+ {
+ return null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/TransMethodVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/TransMethodVisitor.php
new file mode 100644
index 0000000..53a6981
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/TransMethodVisitor.php
@@ -0,0 +1,65 @@
+<?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\Component\Translation\Extractor\Visitor;
+
+use PhpParser\Node;
+use PhpParser\NodeVisitor;
+
+/**
+ * @author Mathieu Santostefano <msantostefano@protonmail.com>
+ */
+final class TransMethodVisitor extends AbstractVisitor implements NodeVisitor
+{
+ public function beforeTraverse(array $nodes): ?Node
+ {
+ return null;
+ }
+
+ public function enterNode(Node $node): ?Node
+ {
+ return null;
+ }
+
+ public function leaveNode(Node $node): ?Node
+ {
+ if (!$node instanceof Node\Expr\MethodCall && !$node instanceof Node\Expr\FuncCall) {
+ return null;
+ }
+
+ if (!\is_string($node->name) && !$node->name instanceof Node\Identifier && !$node->name instanceof Node\Name) {
+ return null;
+ }
+
+ $name = (string) $node->name;
+
+ if ('trans' === $name || 't' === $name) {
+ $firstNamedArgumentIndex = $this->nodeFirstNamedArgumentIndex($node);
+
+ if (!$messages = $this->getStringArguments($node, 0 < $firstNamedArgumentIndex ? 0 : 'message')) {
+ return null;
+ }
+
+ $domain = $this->getStringArguments($node, 2 < $firstNamedArgumentIndex ? 2 : 'domain')[0] ?? null;
+
+ foreach ($messages as $message) {
+ $this->addMessageToCatalogue($message, $domain, $node->getStartLine());
+ }
+ }
+
+ return null;
+ }
+
+ public function afterTraverse(array $nodes): ?Node
+ {
+ return null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/TranslatableMessageVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/TranslatableMessageVisitor.php
new file mode 100644
index 0000000..6bd8bb0
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Extractor/Visitor/TranslatableMessageVisitor.php
@@ -0,0 +1,65 @@
+<?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\Component\Translation\Extractor\Visitor;
+
+use PhpParser\Node;
+use PhpParser\NodeVisitor;
+
+/**
+ * @author Mathieu Santostefano <msantostefano@protonmail.com>
+ */
+final class TranslatableMessageVisitor extends AbstractVisitor implements NodeVisitor
+{
+ public function beforeTraverse(array $nodes): ?Node
+ {
+ return null;
+ }
+
+ public function enterNode(Node $node): ?Node
+ {
+ return null;
+ }
+
+ public function leaveNode(Node $node): ?Node
+ {
+ if (!$node instanceof Node\Expr\New_) {
+ return null;
+ }
+
+ if (!($className = $node->class) instanceof Node\Name) {
+ return null;
+ }
+
+ if (!\in_array('TranslatableMessage', $className->getParts(), true)) {
+ return null;
+ }
+
+ $firstNamedArgumentIndex = $this->nodeFirstNamedArgumentIndex($node);
+
+ if (!$messages = $this->getStringArguments($node, 0 < $firstNamedArgumentIndex ? 0 : 'message')) {
+ return null;
+ }
+
+ $domain = $this->getStringArguments($node, 2 < $firstNamedArgumentIndex ? 2 : 'domain')[0] ?? null;
+
+ foreach ($messages as $message) {
+ $this->addMessageToCatalogue($message, $domain, $node->getStartLine());
+ }
+
+ return null;
+ }
+
+ public function afterTraverse(array $nodes): ?Node
+ {
+ return null;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/IntlFormatter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/IntlFormatter.php
index f7f1c36..e62de25 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/IntlFormatter.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/IntlFormatter.php
@@ -20,12 +20,9 @@
*/
class IntlFormatter implements IntlFormatterInterface
{
- private $hasMessageFormatter;
- private $cache = [];
+ private bool $hasMessageFormatter;
+ private array $cache = [];
- /**
- * {@inheritdoc}
- */
public function formatIntl(string $message, string $locale, array $parameters = []): string
{
// MessageFormatter constructor throws an exception if the message is empty
@@ -34,7 +31,7 @@
}
if (!$formatter = $this->cache[$locale][$message] ?? null) {
- if (!($this->hasMessageFormatter ?? $this->hasMessageFormatter = class_exists(\MessageFormatter::class))) {
+ if (!$this->hasMessageFormatter ??= class_exists(\MessageFormatter::class)) {
throw new LogicException('Cannot parse message translation: please install the "intl" PHP extension or the "symfony/polyfill-intl-messageformatter" package.');
}
try {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/MessageFormatter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/MessageFormatter.php
index 68821b1..d5255bd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/MessageFormatter.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Formatter/MessageFormatter.php
@@ -22,33 +22,23 @@
*/
class MessageFormatter implements MessageFormatterInterface, IntlFormatterInterface
{
- private $translator;
- private $intlFormatter;
+ private TranslatorInterface $translator;
+ private IntlFormatterInterface $intlFormatter;
/**
* @param TranslatorInterface|null $translator An identity translator to use as selector for pluralization
*/
- public function __construct(TranslatorInterface $translator = null, IntlFormatterInterface $intlFormatter = null)
+ public function __construct(?TranslatorInterface $translator = null, ?IntlFormatterInterface $intlFormatter = null)
{
$this->translator = $translator ?? new IdentityTranslator();
$this->intlFormatter = $intlFormatter ?? new IntlFormatter();
}
- /**
- * {@inheritdoc}
- */
public function format(string $message, string $locale, array $parameters = []): string
{
- if ($this->translator instanceof TranslatorInterface) {
- return $this->translator->trans($message, $parameters, null, $locale);
- }
-
- return strtr($message, $parameters);
+ return $this->translator->trans($message, $parameters, null, $locale);
}
- /**
- * {@inheritdoc}
- */
public function formatIntl(string $message, string $locale, array $parameters = []): string
{
return $this->intlFormatter->formatIntl($message, $locale, $parameters);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LICENSE
index 88bf75b..0138f8f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LICENSE
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2004-2022 Fabien Potencier
+Copyright (c) 2004-present 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
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/ArrayLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/ArrayLoader.php
index 35de9ef..e63a7d0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/ArrayLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/ArrayLoader.php
@@ -20,9 +20,6 @@
*/
class ArrayLoader implements LoaderInterface
{
- /**
- * {@inheritdoc}
- */
public function load(mixed $resource, string $locale, string $domain = 'messages'): MessageCatalogue
{
$resource = $this->flatten($resource);
@@ -46,9 +43,11 @@
foreach ($messages as $key => $value) {
if (\is_array($value)) {
foreach ($this->flatten($value) as $k => $v) {
- $result[$key.'.'.$k] = $v;
+ if (null !== $v) {
+ $result[$key.'.'.$k] = $v;
+ }
}
- } else {
+ } elseif (null !== $value) {
$result[$key] = $value;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/CsvFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/CsvFileLoader.php
index 76b00b1..7f2f96b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/CsvFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/CsvFileLoader.php
@@ -24,9 +24,6 @@
private string $enclosure = '"';
private string $escape = '\\';
- /**
- * {@inheritdoc}
- */
protected function loadResource(string $resource): array
{
$messages = [];
@@ -45,7 +42,7 @@
continue;
}
- if ('#' !== substr($data[0], 0, 1) && isset($data[1]) && 2 === \count($data)) {
+ if (!str_starts_with($data[0], '#') && isset($data[1]) && 2 === \count($data)) {
$messages[$data[0]] = $data[1];
}
}
@@ -55,6 +52,8 @@
/**
* Sets the delimiter, enclosure, and escape character for CSV.
+ *
+ * @return void
*/
public function setCsvControl(string $delimiter = ';', string $enclosure = '"', string $escape = '\\')
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/FileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/FileLoader.php
index e170d76..877c3bb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/FileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/FileLoader.php
@@ -21,9 +21,6 @@
*/
abstract class FileLoader extends ArrayLoader
{
- /**
- * {@inheritdoc}
- */
public function load(mixed $resource, string $locale, string $domain = 'messages'): MessageCatalogue
{
if (!stream_is_local($resource)) {
@@ -37,9 +34,7 @@
$messages = $this->loadResource($resource);
// empty resource
- if (null === $messages) {
- $messages = [];
- }
+ $messages ??= [];
// not an array
if (!\is_array($messages)) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuDatFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuDatFileLoader.php
index c3ca5fd..76e4e7f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuDatFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuDatFileLoader.php
@@ -23,9 +23,6 @@
*/
class IcuDatFileLoader extends IcuResFileLoader
{
- /**
- * {@inheritdoc}
- */
public function load(mixed $resource, string $locale, string $domain = 'messages'): MessageCatalogue
{
if (!stream_is_local($resource.'.dat')) {
@@ -38,7 +35,7 @@
try {
$rb = new \ResourceBundle($locale, $resource);
- } catch (\Exception $e) {
+ } catch (\Exception) {
$rb = null;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuResFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuResFileLoader.php
index 54c48f8..949dd97 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuResFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IcuResFileLoader.php
@@ -23,9 +23,6 @@
*/
class IcuResFileLoader implements LoaderInterface
{
- /**
- * {@inheritdoc}
- */
public function load(mixed $resource, string $locale, string $domain = 'messages'): MessageCatalogue
{
if (!stream_is_local($resource)) {
@@ -38,7 +35,7 @@
try {
$rb = new \ResourceBundle($locale, $resource);
- } catch (\Exception $e) {
+ } catch (\Exception) {
$rb = null;
}
@@ -71,9 +68,9 @@
*
* @param \ResourceBundle $rb The ResourceBundle that will be flattened
* @param array $messages Used internally for recursive calls
- * @param string $path Current path being parsed, used internally for recursive calls
+ * @param string|null $path Current path being parsed, used internally for recursive calls
*/
- protected function flatten(\ResourceBundle $rb, array &$messages = [], string $path = null): array
+ protected function flatten(\ResourceBundle $rb, array &$messages = [], ?string $path = null): array
{
foreach ($rb as $key => $value) {
$nodePath = $path ? $path.'.'.$key : $key;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IniFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IniFileLoader.php
index 04e294d..3126896 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IniFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/IniFileLoader.php
@@ -18,9 +18,6 @@
*/
class IniFileLoader extends FileLoader
{
- /**
- * {@inheritdoc}
- */
protected function loadResource(string $resource): array
{
return parse_ini_file($resource, true);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/JsonFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/JsonFileLoader.php
index 67a8d58..385553e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/JsonFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/JsonFileLoader.php
@@ -20,9 +20,6 @@
*/
class JsonFileLoader extends FileLoader
{
- /**
- * {@inheritdoc}
- */
protected function loadResource(string $resource): array
{
$messages = [];
@@ -42,19 +39,13 @@
*/
private function getJSONErrorMessage(int $errorCode): string
{
- switch ($errorCode) {
- case \JSON_ERROR_DEPTH:
- return 'Maximum stack depth exceeded';
- case \JSON_ERROR_STATE_MISMATCH:
- return 'Underflow or the modes mismatch';
- case \JSON_ERROR_CTRL_CHAR:
- return 'Unexpected control character found';
- case \JSON_ERROR_SYNTAX:
- return 'Syntax error, malformed JSON';
- case \JSON_ERROR_UTF8:
- return 'Malformed UTF-8 characters, possibly incorrectly encoded';
- default:
- return 'Unknown error';
- }
+ return match ($errorCode) {
+ \JSON_ERROR_DEPTH => 'Maximum stack depth exceeded',
+ \JSON_ERROR_STATE_MISMATCH => 'Underflow or the modes mismatch',
+ \JSON_ERROR_CTRL_CHAR => 'Unexpected control character found',
+ \JSON_ERROR_SYNTAX => 'Syntax error, malformed JSON',
+ \JSON_ERROR_UTF8 => 'Malformed UTF-8 characters, possibly incorrectly encoded',
+ default => 'Unknown error',
+ };
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/MoFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/MoFileLoader.php
index b0c8913..8427c39 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/MoFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/MoFileLoader.php
@@ -38,8 +38,6 @@
/**
* Parses machine object (MO) format, independent of the machine's endian it
* was created on. Both 32bit and 64bit systems are supported.
- *
- * {@inheritdoc}
*/
protected function loadResource(string $resource): array
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PhpFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PhpFileLoader.php
index 6bc2a05..541b6c8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PhpFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PhpFileLoader.php
@@ -20,12 +20,9 @@
{
private static ?array $cache = [];
- /**
- * {@inheritdoc}
- */
protected function loadResource(string $resource): array
{
- if ([] === self::$cache && \function_exists('opcache_invalidate') && filter_var(ini_get('opcache.enable'), \FILTER_VALIDATE_BOOLEAN) && (!\in_array(\PHP_SAPI, ['cli', 'phpdbg'], true) || filter_var(ini_get('opcache.enable_cli'), \FILTER_VALIDATE_BOOLEAN))) {
+ if ([] === self::$cache && \function_exists('opcache_invalidate') && filter_var(\ini_get('opcache.enable'), \FILTER_VALIDATE_BOOL) && (!\in_array(\PHP_SAPI, ['cli', 'phpdbg', 'embed'], true) || filter_var(\ini_get('opcache.enable_cli'), \FILTER_VALIDATE_BOOL))) {
self::$cache = null;
}
@@ -33,10 +30,6 @@
return require $resource;
}
- if (isset(self::$cache[$resource])) {
- return self::$cache[$resource];
- }
-
- return self::$cache[$resource] = require $resource;
+ return self::$cache[$resource] ??= require $resource;
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PoFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PoFileLoader.php
index 6df1614..620d973 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PoFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/PoFileLoader.php
@@ -57,8 +57,6 @@
* - Message IDs are allowed to have other encodings as just US-ASCII.
*
* Items with an empty id are ignored.
- *
- * {@inheritdoc}
*/
protected function loadResource(string $resource): array
{
@@ -83,15 +81,15 @@
}
$item = $defaults;
$flags = [];
- } elseif ('#,' === substr($line, 0, 2)) {
+ } elseif (str_starts_with($line, '#,')) {
$flags = array_map('trim', explode(',', substr($line, 2)));
- } elseif ('msgid "' === substr($line, 0, 7)) {
+ } elseif (str_starts_with($line, 'msgid "')) {
// We start a new msg so save previous
// TODO: this fails when comments or contexts are added
$this->addMessage($messages, $item);
$item = $defaults;
$item['ids']['singular'] = substr($line, 7, -1);
- } elseif ('msgstr "' === substr($line, 0, 8)) {
+ } elseif (str_starts_with($line, 'msgstr "')) {
$item['translated'] = substr($line, 8, -1);
} elseif ('"' === $line[0]) {
$continues = isset($item['translated']) ? 'translated' : 'ids';
@@ -102,9 +100,9 @@
} else {
$item[$continues] .= substr($line, 1, -1);
}
- } elseif ('msgid_plural "' === substr($line, 0, 14)) {
+ } elseif (str_starts_with($line, 'msgid_plural "')) {
$item['ids']['plural'] = substr($line, 14, -1);
- } elseif ('msgstr[' === substr($line, 0, 7)) {
+ } elseif (str_starts_with($line, 'msgstr[')) {
$size = strpos($line, ']');
$item['translated'][(int) substr($line, 7, 1)] = substr($line, $size + 3, -1);
}
@@ -124,7 +122,7 @@
* A .po file could contain by error missing plural indexes. We need to
* fix these before saving them.
*/
- private function addMessage(array &$messages, array $item)
+ private function addMessage(array &$messages, array $item): void
{
if (!empty($item['ids']['singular'])) {
$id = stripcslashes($item['ids']['singular']);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/QtFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/QtFileLoader.php
index 6d5582d..235f85e 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/QtFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/QtFileLoader.php
@@ -25,9 +25,6 @@
*/
class QtFileLoader implements LoaderInterface
{
- /**
- * {@inheritdoc}
- */
public function load(mixed $resource, string $locale, string $domain = 'messages'): MessageCatalogue
{
if (!class_exists(XmlUtils::class)) {
@@ -67,7 +64,6 @@
$domain
);
}
- $translation = $translation->nextSibling;
}
if (class_exists(FileResource::class)) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/XliffFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/XliffFileLoader.php
index 670e199..31b3251 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/XliffFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/XliffFileLoader.php
@@ -28,9 +28,6 @@
*/
class XliffFileLoader implements LoaderInterface
{
- /**
- * {@inheritdoc}
- */
public function load(mixed $resource, string $locale, string $domain = 'messages'): MessageCatalogue
{
if (!class_exists(XmlUtils::class)) {
@@ -75,7 +72,7 @@
return $catalogue;
}
- private function extract(\DOMDocument $dom, MessageCatalogue $catalogue, string $domain)
+ private function extract(\DOMDocument $dom, MessageCatalogue $catalogue, string $domain): void
{
$xliffVersion = XliffUtils::getVersionNumber($dom);
@@ -91,7 +88,7 @@
/**
* Extract messages and metadata from DOMDocument into a MessageCatalogue.
*/
- private function extractXliff1(\DOMDocument $dom, MessageCatalogue $catalogue, string $domain)
+ private function extractXliff1(\DOMDocument $dom, MessageCatalogue $catalogue, string $domain): void
{
$xml = simplexml_import_dom($dom);
$encoding = $dom->encoding ? strtoupper($dom->encoding) : null;
@@ -104,6 +101,10 @@
$file->registerXPathNamespace('xliff', $namespace);
+ foreach ($file->xpath('.//xliff:prop') as $prop) {
+ $catalogue->setCatalogueMetadata($prop->attributes()['prop-type'], (string) $prop, $domain);
+ }
+
foreach ($file->xpath('.//xliff:trans-unit') as $translation) {
$attributes = $translation->attributes();
@@ -111,6 +112,10 @@
continue;
}
+ if (isset($translation->target) && 'needs-translation' === (string) $translation->target->attributes()['state']) {
+ continue;
+ }
+
$source = isset($attributes['resname']) && $attributes['resname'] ? $attributes['resname'] : $translation->source;
// If the xlf file has another encoding specified, try to convert it because
// simple_xml will always return utf-8 encoded values
@@ -144,7 +149,7 @@
}
}
- private function extractXliff2(\DOMDocument $dom, MessageCatalogue $catalogue, string $domain)
+ private function extractXliff2(\DOMDocument $dom, MessageCatalogue $catalogue, string $domain): void
{
$xml = simplexml_import_dom($dom);
$encoding = $dom->encoding ? strtoupper($dom->encoding) : null;
@@ -190,7 +195,7 @@
/**
* Convert a UTF8 string to the specified encoding.
*/
- private function utf8ToCharset(string $content, string $encoding = null): string
+ private function utf8ToCharset(string $content, ?string $encoding = null): string
{
if ('UTF-8' !== $encoding && !empty($encoding)) {
return mb_convert_encoding($content, $encoding, 'UTF-8');
@@ -199,7 +204,7 @@
return $content;
}
- private function parseNotesMetadata(\SimpleXMLElement $noteElement = null, string $encoding = null): array
+ private function parseNotesMetadata(?\SimpleXMLElement $noteElement = null, ?string $encoding = null): array
{
$notes = [];
@@ -227,6 +232,6 @@
private function isXmlString(string $resource): bool
{
- return 0 === strpos($resource, '<?xml');
+ return str_starts_with($resource, '<?xml');
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/YamlFileLoader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/YamlFileLoader.php
index 5eccf99..48e735d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/YamlFileLoader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Loader/YamlFileLoader.php
@@ -24,14 +24,11 @@
*/
class YamlFileLoader extends FileLoader
{
- private $yamlParser;
+ private YamlParser $yamlParser;
- /**
- * {@inheritdoc}
- */
protected function loadResource(string $resource): array
{
- if (null === $this->yamlParser) {
+ if (!isset($this->yamlParser)) {
if (!class_exists(\Symfony\Component\Yaml\Parser::class)) {
throw new LogicException('Loading translations from the YAML format requires the Symfony Yaml component.');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LocaleSwitcher.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LocaleSwitcher.php
new file mode 100644
index 0000000..c07809c
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LocaleSwitcher.php
@@ -0,0 +1,78 @@
+<?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\Component\Translation;
+
+use Symfony\Component\Routing\RequestContext;
+use Symfony\Contracts\Translation\LocaleAwareInterface;
+
+/**
+ * @author Kevin Bond <kevinbond@gmail.com>
+ */
+class LocaleSwitcher implements LocaleAwareInterface
+{
+ private string $defaultLocale;
+
+ /**
+ * @param LocaleAwareInterface[] $localeAwareServices
+ */
+ public function __construct(
+ private string $locale,
+ private iterable $localeAwareServices,
+ private ?RequestContext $requestContext = null,
+ ) {
+ $this->defaultLocale = $locale;
+ }
+
+ public function setLocale(string $locale): void
+ {
+ if (class_exists(\Locale::class)) {
+ \Locale::setDefault($locale);
+ }
+ $this->locale = $locale;
+ $this->requestContext?->setParameter('_locale', $locale);
+
+ foreach ($this->localeAwareServices as $service) {
+ $service->setLocale($locale);
+ }
+ }
+
+ public function getLocale(): string
+ {
+ return $this->locale;
+ }
+
+ /**
+ * Switch to a new locale, execute a callback, then switch back to the original.
+ *
+ * @template T
+ *
+ * @param callable(string $locale):T $callback
+ *
+ * @return T
+ */
+ public function runWithLocale(string $locale, callable $callback): mixed
+ {
+ $original = $this->getLocale();
+ $this->setLocale($locale);
+
+ try {
+ return $callback($locale);
+ } finally {
+ $this->setLocale($original);
+ }
+ }
+
+ public function reset(): void
+ {
+ $this->setLocale($this->defaultLocale);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LoggingTranslator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LoggingTranslator.php
index 8c8441c..4a560bd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LoggingTranslator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/LoggingTranslator.php
@@ -21,8 +21,8 @@
*/
class LoggingTranslator implements TranslatorInterface, TranslatorBagInterface, LocaleAwareInterface
{
- private $translator;
- private $logger;
+ private TranslatorInterface $translator;
+ private LoggerInterface $logger;
/**
* @param TranslatorInterface&TranslatorBagInterface&LocaleAwareInterface $translator The translator must implement TranslatorBagInterface
@@ -37,10 +37,7 @@
$this->logger = $logger;
}
- /**
- * {@inheritdoc}
- */
- public function trans(?string $id, array $parameters = [], string $domain = null, string $locale = null): string
+ public function trans(?string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string
{
$trans = $this->translator->trans($id = (string) $id, $parameters, $domain, $locale);
$this->log($id, $domain, $locale);
@@ -49,7 +46,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function setLocale(string $locale)
{
@@ -62,25 +59,16 @@
$this->logger->debug(sprintf('The locale of the translator has changed from "%s" to "%s".', $prev, $locale));
}
- /**
- * {@inheritdoc}
- */
public function getLocale(): string
{
return $this->translator->getLocale();
}
- /**
- * {@inheritdoc}
- */
- public function getCatalogue(string $locale = null): MessageCatalogueInterface
+ public function getCatalogue(?string $locale = null): MessageCatalogueInterface
{
return $this->translator->getCatalogue($locale);
}
- /**
- * {@inheritdoc}
- */
public function getCatalogues(): array
{
return $this->translator->getCatalogues();
@@ -99,7 +87,7 @@
}
/**
- * Passes through all unknown calls onto the translator object.
+ * @return mixed
*/
public function __call(string $method, array $args)
{
@@ -109,11 +97,9 @@
/**
* Logs for missing translations.
*/
- private function log(string $id, ?string $domain, ?string $locale)
+ private function log(string $id, ?string $domain, ?string $locale): void
{
- if (null === $domain) {
- $domain = 'messages';
- }
+ $domain ??= 'messages';
$catalogue = $this->translator->getCatalogue($locale);
if ($catalogue->defines($id, $domain)) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogue.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogue.php
index 7aa27ef..d56f043 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogue.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogue.php
@@ -17,13 +17,14 @@
/**
* @author Fabien Potencier <fabien@symfony.com>
*/
-class MessageCatalogue implements MessageCatalogueInterface, MetadataAwareInterface
+class MessageCatalogue implements MessageCatalogueInterface, MetadataAwareInterface, CatalogueMetadataAwareInterface
{
private array $messages = [];
private array $metadata = [];
+ private array $catalogueMetadata = [];
private array $resources = [];
private string $locale;
- private $fallbackCatalogue = null;
+ private ?MessageCatalogueInterface $fallbackCatalogue = null;
private ?self $parent = null;
/**
@@ -35,17 +36,11 @@
$this->messages = $messages;
}
- /**
- * {@inheritdoc}
- */
public function getLocale(): string
{
return $this->locale;
}
- /**
- * {@inheritdoc}
- */
public function getDomains(): array
{
$domains = [];
@@ -60,10 +55,7 @@
return array_values($domains);
}
- /**
- * {@inheritdoc}
- */
- public function all(string $domain = null): array
+ public function all(?string $domain = null): array
{
if (null !== $domain) {
// skip messages merge if intl-icu requested explicitly
@@ -89,16 +81,13 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function set(string $id, string $translation, string $domain = 'messages')
{
$this->add([$id => $translation], $domain);
}
- /**
- * {@inheritdoc}
- */
public function has(string $id, string $domain = 'messages'): bool
{
if (isset($this->messages[$domain][$id]) || isset($this->messages[$domain.self::INTL_DOMAIN_SUFFIX][$id])) {
@@ -112,17 +101,11 @@
return false;
}
- /**
- * {@inheritdoc}
- */
public function defines(string $id, string $domain = 'messages'): bool
{
return isset($this->messages[$domain][$id]) || isset($this->messages[$domain.self::INTL_DOMAIN_SUFFIX][$id]);
}
- /**
- * {@inheritdoc}
- */
public function get(string $id, string $domain = 'messages'): string
{
if (isset($this->messages[$domain.self::INTL_DOMAIN_SUFFIX][$id])) {
@@ -141,7 +124,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function replace(array $messages, string $domain = 'messages')
{
@@ -151,28 +134,23 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function add(array $messages, string $domain = 'messages')
{
- if (!isset($this->messages[$domain])) {
- $this->messages[$domain] = [];
- }
- $intlDomain = $domain;
- if (!str_ends_with($domain, self::INTL_DOMAIN_SUFFIX)) {
- $intlDomain .= self::INTL_DOMAIN_SUFFIX;
- }
+ $altDomain = str_ends_with($domain, self::INTL_DOMAIN_SUFFIX) ? substr($domain, 0, -\strlen(self::INTL_DOMAIN_SUFFIX)) : $domain.self::INTL_DOMAIN_SUFFIX;
foreach ($messages as $id => $message) {
- if (isset($this->messages[$intlDomain]) && \array_key_exists($id, $this->messages[$intlDomain])) {
- $this->messages[$intlDomain][$id] = $message;
- } else {
- $this->messages[$domain][$id] = $message;
- }
+ unset($this->messages[$altDomain][$id]);
+ $this->messages[$domain][$id] = $message;
+ }
+
+ if ([] === ($this->messages[$altDomain] ?? null)) {
+ unset($this->messages[$altDomain]);
}
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function addCatalogue(MessageCatalogueInterface $catalogue)
{
@@ -196,10 +174,15 @@
$metadata = $catalogue->getMetadata('', '');
$this->addMetadata($metadata);
}
+
+ if ($catalogue instanceof CatalogueMetadataAwareInterface) {
+ $catalogueMetadata = $catalogue->getCatalogueMetadata('', '');
+ $this->addCatalogueMetadata($catalogueMetadata);
+ }
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function addFallbackCatalogue(MessageCatalogueInterface $catalogue)
{
@@ -230,33 +213,24 @@
}
}
- /**
- * {@inheritdoc}
- */
public function getFallbackCatalogue(): ?MessageCatalogueInterface
{
return $this->fallbackCatalogue;
}
- /**
- * {@inheritdoc}
- */
public function getResources(): array
{
return array_values($this->resources);
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function addResource(ResourceInterface $resource)
{
$this->resources[$resource->__toString()] = $resource;
}
- /**
- * {@inheritdoc}
- */
public function getMetadata(string $key = '', string $domain = 'messages'): mixed
{
if ('' == $domain) {
@@ -277,7 +251,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function setMetadata(string $key, mixed $value, string $domain = 'messages')
{
@@ -285,7 +259,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function deleteMetadata(string $key = '', string $domain = 'messages')
{
@@ -298,12 +272,53 @@
}
}
+ public function getCatalogueMetadata(string $key = '', string $domain = 'messages'): mixed
+ {
+ if (!$domain) {
+ return $this->catalogueMetadata;
+ }
+
+ if (isset($this->catalogueMetadata[$domain])) {
+ if (!$key) {
+ return $this->catalogueMetadata[$domain];
+ }
+
+ if (isset($this->catalogueMetadata[$domain][$key])) {
+ return $this->catalogueMetadata[$domain][$key];
+ }
+ }
+
+ return null;
+ }
+
+ /**
+ * @return void
+ */
+ public function setCatalogueMetadata(string $key, mixed $value, string $domain = 'messages')
+ {
+ $this->catalogueMetadata[$domain][$key] = $value;
+ }
+
+ /**
+ * @return void
+ */
+ public function deleteCatalogueMetadata(string $key = '', string $domain = 'messages')
+ {
+ if (!$domain) {
+ $this->catalogueMetadata = [];
+ } elseif (!$key) {
+ unset($this->catalogueMetadata[$domain]);
+ } else {
+ unset($this->catalogueMetadata[$domain][$key]);
+ }
+ }
+
/**
* Adds current values with the new values.
*
* @param array $values Values to add
*/
- private function addMetadata(array $values)
+ private function addMetadata(array $values): void
{
foreach ($values as $domain => $keys) {
foreach ($keys as $key => $value) {
@@ -311,4 +326,13 @@
}
}
}
+
+ private function addCatalogueMetadata(array $values): void
+ {
+ foreach ($values as $domain => $keys) {
+ foreach ($keys as $key => $value) {
+ $this->setCatalogueMetadata($key, $value, $domain);
+ }
+ }
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogueInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogueInterface.php
index 75e3a2f..fd0d26d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogueInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MessageCatalogueInterface.php
@@ -36,10 +36,8 @@
* Gets the messages within a given domain.
*
* If $domain is null, it returns all messages.
- *
- * @param string $domain The domain name
*/
- public function all(string $domain = null): array;
+ public function all(?string $domain = null): array;
/**
* Sets a message translation.
@@ -47,6 +45,8 @@
* @param string $id The message id
* @param string $translation The messages translation
* @param string $domain The domain name
+ *
+ * @return void
*/
public function set(string $id, string $translation, string $domain = 'messages');
@@ -79,6 +79,8 @@
*
* @param array $messages An array of translations
* @param string $domain The domain name
+ *
+ * @return void
*/
public function replace(array $messages, string $domain = 'messages');
@@ -87,6 +89,8 @@
*
* @param array $messages An array of translations
* @param string $domain The domain name
+ *
+ * @return void
*/
public function add(array $messages, string $domain = 'messages');
@@ -94,6 +98,8 @@
* Merges translations from the given Catalogue into the current one.
*
* The two catalogues must have the same locale.
+ *
+ * @return void
*/
public function addCatalogue(self $catalogue);
@@ -102,6 +108,8 @@
* only when the translation does not exist.
*
* This is used to provide default translations when they do not exist for the current locale.
+ *
+ * @return void
*/
public function addFallbackCatalogue(self $catalogue);
@@ -119,6 +127,8 @@
/**
* Adds a resource for this collection.
+ *
+ * @return void
*/
public function addResource(ResourceInterface $resource);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MetadataAwareInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MetadataAwareInterface.php
index 2eaaceb..39e5326 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MetadataAwareInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/MetadataAwareInterface.php
@@ -12,7 +12,7 @@
namespace Symfony\Component\Translation;
/**
- * MetadataAwareInterface.
+ * This interface is used to get, set, and delete metadata about the translation messages.
*
* @author Fabien Potencier <fabien@symfony.com>
*/
@@ -31,6 +31,8 @@
/**
* Adds metadata to a message domain.
+ *
+ * @return void
*/
public function setMetadata(string $key, mixed $value, string $domain = 'messages');
@@ -39,6 +41,8 @@
*
* Passing an empty domain will delete all metadata. Passing an empty key will
* delete all metadata for the given domain.
+ *
+ * @return void
*/
public function deleteMetadata(string $key = '', string $domain = 'messages');
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/AbstractProviderFactory.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/AbstractProviderFactory.php
index 17442fd..f0c11d8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/AbstractProviderFactory.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/AbstractProviderFactory.php
@@ -27,19 +27,11 @@
protected function getUser(Dsn $dsn): string
{
- if (null === $user = $dsn->getUser()) {
- throw new IncompleteDsnException('User is not set.', $dsn->getOriginalDsn());
- }
-
- return $user;
+ return $dsn->getUser() ?? throw new IncompleteDsnException('User is not set.', $dsn->getScheme().'://'.$dsn->getHost());
}
protected function getPassword(Dsn $dsn): string
{
- if (null === $password = $dsn->getPassword()) {
- throw new IncompleteDsnException('Password is not set.', $dsn->getOriginalDsn());
- }
-
- return $password;
+ return $dsn->getPassword() ?? throw new IncompleteDsnException('Password is not set.', $dsn->getOriginalDsn());
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/Dsn.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/Dsn.php
index 0f74d17..1d90e27 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/Dsn.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/Dsn.php
@@ -29,29 +29,29 @@
private array $options = [];
private string $originalDsn;
- public function __construct(string $dsn)
+ public function __construct(#[\SensitiveParameter] string $dsn)
{
$this->originalDsn = $dsn;
- if (false === $parsedDsn = parse_url($dsn)) {
- throw new InvalidArgumentException(sprintf('The "%s" translation provider DSN is invalid.', $dsn));
+ if (false === $params = parse_url($dsn)) {
+ throw new InvalidArgumentException('The translation provider DSN is invalid.');
}
- if (!isset($parsedDsn['scheme'])) {
- throw new InvalidArgumentException(sprintf('The "%s" translation provider DSN must contain a scheme.', $dsn));
+ if (!isset($params['scheme'])) {
+ throw new InvalidArgumentException('The translation provider DSN must contain a scheme.');
}
- $this->scheme = $parsedDsn['scheme'];
+ $this->scheme = $params['scheme'];
- if (!isset($parsedDsn['host'])) {
- throw new InvalidArgumentException(sprintf('The "%s" translation provider DSN must contain a host (use "default" by default).', $dsn));
+ if (!isset($params['host'])) {
+ throw new InvalidArgumentException('The translation provider DSN must contain a host (use "default" by default).');
}
- $this->host = $parsedDsn['host'];
+ $this->host = $params['host'];
- $this->user = '' !== ($parsedDsn['user'] ?? '') ? urldecode($parsedDsn['user']) : null;
- $this->password = '' !== ($parsedDsn['pass'] ?? '') ? urldecode($parsedDsn['pass']) : null;
- $this->port = $parsedDsn['port'] ?? null;
- $this->path = $parsedDsn['path'] ?? null;
- parse_str($parsedDsn['query'] ?? '', $this->options);
+ $this->user = '' !== ($params['user'] ?? '') ? rawurldecode($params['user']) : null;
+ $this->password = '' !== ($params['pass'] ?? '') ? rawurldecode($params['pass']) : null;
+ $this->port = $params['port'] ?? null;
+ $this->path = $params['path'] ?? null;
+ parse_str($params['query'] ?? '', $this->options);
}
public function getScheme(): string
@@ -74,17 +74,17 @@
return $this->password;
}
- public function getPort(int $default = null): ?int
+ public function getPort(?int $default = null): ?int
{
return $this->port ?? $default;
}
- public function getOption(string $key, mixed $default = null)
+ public function getOption(string $key, mixed $default = null): mixed
{
return $this->options[$key] ?? $default;
}
- public function getRequiredOption(string $key)
+ public function getRequiredOption(string $key): mixed
{
if (!\array_key_exists($key, $this->options) || '' === trim($this->options[$key])) {
throw new MissingRequiredOptionException($key);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/FilteringProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/FilteringProvider.php
index a43fedc..d4465b9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/FilteringProvider.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/FilteringProvider.php
@@ -21,7 +21,7 @@
*/
class FilteringProvider implements ProviderInterface
{
- private $provider;
+ private ProviderInterface $provider;
private array $locales;
private array $domains;
@@ -37,9 +37,6 @@
return (string) $this->provider;
}
- /**
- * {@inheritdoc}
- */
public function write(TranslatorBagInterface $translatorBag): void
{
$this->provider->write($translatorBag);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/ProviderInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/ProviderInterface.php
index a32193f..0e47083 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/ProviderInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/ProviderInterface.php
@@ -14,10 +14,8 @@
use Symfony\Component\Translation\TranslatorBag;
use Symfony\Component\Translation\TranslatorBagInterface;
-interface ProviderInterface
+interface ProviderInterface extends \Stringable
{
- public function __toString(): string;
-
/**
* Translations available in the TranslatorBag only must be created.
* Translations available in both the TranslatorBag and on the provider
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/TranslationProviderCollection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/TranslationProviderCollection.php
index 61ac641..b917415 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/TranslationProviderCollection.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Provider/TranslationProviderCollection.php
@@ -21,7 +21,7 @@
/**
* @var array<string, ProviderInterface>
*/
- private $providers;
+ private array $providers;
/**
* @param array<string, ProviderInterface> $providers
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/PseudoLocalizationTranslator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/PseudoLocalizationTranslator.php
index 1d10e0c..f26909f 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/PseudoLocalizationTranslator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/PseudoLocalizationTranslator.php
@@ -20,7 +20,7 @@
{
private const EXPANSION_CHARACTER = '~';
- private $translator;
+ private TranslatorInterface $translator;
private bool $accents;
private float $expansionFactor;
private bool $brackets;
@@ -83,10 +83,7 @@
$this->localizableHTMLAttributes = $options['localizable_html_attributes'] ?? [];
}
- /**
- * {@inheritdoc}
- */
- public function trans(string $id, array $parameters = [], string $domain = null, string $locale = null): string
+ public function trans(string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string
{
$trans = '';
$visibleText = '';
@@ -123,7 +120,7 @@
return [[true, true, $originalTrans]];
}
- $html = mb_convert_encoding($originalTrans, 'HTML-ENTITIES', mb_detect_encoding($originalTrans, null, true) ?: 'UTF-8');
+ $html = mb_encode_numericentity($originalTrans, [0x80, 0x10FFFF, 0, 0x1FFFFF], mb_detect_encoding($originalTrans, null, true) ?: 'UTF-8');
$useInternalErrors = libxml_use_internal_errors(true);
@@ -283,7 +280,7 @@
}
$visibleLength = $this->strlen($visibleText);
- $missingLength = (int) (ceil($visibleLength * $this->expansionFactor)) - $visibleLength;
+ $missingLength = (int) ceil($visibleLength * $this->expansionFactor) - $visibleLength;
if ($this->brackets) {
$missingLength -= 2;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/README.md
index adda9a5..32e4017 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/README.md
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/README.md
@@ -26,12 +26,7 @@
Sponsor
-------
-The Translation component for Symfony 5.4/6.0 is [backed][1] by:
-
- * [Crowdin][2], a cloud-based localization management software helping teams to go global and stay agile.
- * [Lokalise][3], a continuous localization and translation management platform that integrates into your development workflow so you can ship localized products, faster.
-
-Help Symfony by [sponsoring][4] its development!
+Help Symfony by [sponsoring][1] its development!
Resources
---------
@@ -42,7 +37,4 @@
[send Pull Requests](https://github.com/symfony/symfony/pulls)
in the [main Symfony repository](https://github.com/symfony/symfony)
-[1]: https://symfony.com/backers
-[2]: https://crowdin.com
-[3]: https://lokalise.com
-[4]: https://symfony.com/sponsor
+[1]: https://symfony.com/sponsor
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReader.php
index bbc687e..01408d4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReader.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReader.php
@@ -33,6 +33,8 @@
* Adds a loader to the translation extractor.
*
* @param string $format The format of the loader
+ *
+ * @return void
*/
public function addLoader(string $format, LoaderInterface $loader)
{
@@ -40,7 +42,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function read(string $directory, MessageCatalogue $catalogue)
{
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReaderInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReaderInterface.php
index bc37204..ea74dc2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReaderInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Reader/TranslationReaderInterface.php
@@ -22,6 +22,8 @@
{
/**
* Reads translation messages from a directory to the catalogue.
+ *
+ * @return void
*/
public function read(string $directory, MessageCatalogue $catalogue);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/bin/translation-status.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/bin/translation-status.php
index a769164..8064190 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/bin/translation-status.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/bin/translation-status.php
@@ -9,6 +9,10 @@
* file that was distributed with this source code.
*/
+if ('cli' !== \PHP_SAPI) {
+ throw new Exception('This script must be run from the command line.');
+}
+
$usageInstructions = <<<END
Usage instructions
@@ -83,19 +87,15 @@
$translationFilePaths = findTranslationFiles($originalFilePath, $config['locale_to_analyze']);
$translationStatus = calculateTranslationStatus($originalFilePath, $translationFilePaths);
- $totalMissingTranslations += array_sum(array_map(function ($translation) {
- return count($translation['missingKeys']);
- }, array_values($translationStatus)));
- $totalTranslationMismatches += array_sum(array_map(function ($translation) {
- return count($translation['mismatches']);
- }, array_values($translationStatus)));
+ $totalMissingTranslations += array_sum(array_map(fn ($translation) => count($translation['missingKeys']), array_values($translationStatus)));
+ $totalTranslationMismatches += array_sum(array_map(fn ($translation) => count($translation['mismatches']), array_values($translationStatus)));
printTranslationStatus($originalFilePath, $translationStatus, $config['verbose_output'], $config['include_completed_languages']);
}
exit($totalTranslationMismatches > 0 ? 1 : 0);
-function findTranslationFiles($originalFilePath, $localeToAnalyze)
+function findTranslationFiles($originalFilePath, $localeToAnalyze): array
{
$translations = [];
@@ -118,7 +118,7 @@
return $translations;
}
-function calculateTranslationStatus($originalFilePath, $translationFilePaths)
+function calculateTranslationStatus($originalFilePath, $translationFilePaths): array
{
$translationStatus = [];
$allTranslationKeys = extractTranslationKeys($originalFilePath);
@@ -159,7 +159,7 @@
return $parts[count($parts) - 2];
}
-function extractTranslationKeys($filePath)
+function extractTranslationKeys($filePath): array
{
$translationKeys = [];
$contents = new \SimpleXMLElement(file_get_contents($filePath));
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/data/parents.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/data/parents.json
index 288f163..24d4d11 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/data/parents.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/data/parents.json
@@ -35,6 +35,7 @@
"en_GM": "en_001",
"en_GY": "en_001",
"en_HK": "en_001",
+ "en_ID": "en_001",
"en_IE": "en_001",
"en_IL": "en_001",
"en_IM": "en_001",
@@ -54,6 +55,7 @@
"en_MS": "en_001",
"en_MT": "en_001",
"en_MU": "en_001",
+ "en_MV": "en_001",
"en_MW": "en_001",
"en_MY": "en_001",
"en_NA": "en_001",
@@ -116,6 +118,8 @@
"es_UY": "es_419",
"es_VE": "es_419",
"ff_Adlm": "root",
+ "hi_Latn": "en_IN",
+ "ks_Deva": "root",
"nb": "no",
"nn": "no",
"pa_Arab": "root",
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/functions.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/functions.php
index 901d2f8..0d2a037 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/functions.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/functions.php
@@ -15,7 +15,7 @@
/**
* @author Nate Wiebe <nate@northern.co>
*/
- function t(string $message, array $parameters = [], string $domain = null): TranslatableMessage
+ function t(string $message, array $parameters = [], ?string $domain = null): TranslatableMessage
{
return new TranslatableMessage($message, $parameters, $domain);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/schemas/xliff-core-1.2-strict.xsd b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/schemas/xliff-core-1.2-strict.xsd
deleted file mode 100644
index dface62..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/schemas/xliff-core-1.2-strict.xsd
+++ /dev/null
@@ -1,2223 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-
-May-19-2004:
-- Changed the <choice> for ElemType_header, moving minOccurs="0" maxOccurs="unbounded" from its elements
-to <choice> itself.
-- Added <choice> for ElemType_trans-unit to allow "any order" for <context-group>, <count-group>, <prop-group>, <note>, and
-<alt-trans>.
-
-Oct-2005
-- updated version info to 1.2
-- equiv-trans attribute to <trans-unit> element
-- merged-trans attribute for <group> element
-- Add the <seg-source> element as optional in the <trans-unit> and <alt-trans> content models, at the same level as <source>
-- Create a new value "seg" for the mtype attribute of the <mrk> element
-- Add mid as an optional attribute for the <alt-trans> element
-
-Nov-14-2005
-- Changed name attribute for <context-group> from required to optional
-- Added extension point at <xliff>
-
-Jan-9-2006
-- Added alttranstype type attribute to <alt-trans>, and values
-
-Jan-10-2006
-- Corrected error with overwritten purposeValueList
-- Corrected name="AttrType_Version", attribute should have been "name"
-
--->
-<xsd:schema xmlns:xlf="urn:oasis:names:tc:xliff:document:1.2" xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="urn:oasis:names:tc:xliff:document:1.2" xml:lang="en">
- <!-- Import for xml:lang and xml:space -->
- <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
- <!-- Attributes Lists -->
- <xsd:simpleType name="XTend">
- <xsd:restriction base="xsd:string">
- <xsd:pattern value="x-[^\s]+"/>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="context-typeValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'context-type'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:string">
- <xsd:enumeration value="database">
- <xsd:annotation>
- <xsd:documentation>Indicates a database content.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="element">
- <xsd:annotation>
- <xsd:documentation>Indicates the content of an element within an XML document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="elementtitle">
- <xsd:annotation>
- <xsd:documentation>Indicates the name of an element within an XML document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="linenumber">
- <xsd:annotation>
- <xsd:documentation>Indicates the line number from the sourcefile (see context-type="sourcefile") where the <source> is found.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="numparams">
- <xsd:annotation>
- <xsd:documentation>Indicates a the number of parameters contained within the <source>.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="paramnotes">
- <xsd:annotation>
- <xsd:documentation>Indicates notes pertaining to the parameters in the <source>.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="record">
- <xsd:annotation>
- <xsd:documentation>Indicates the content of a record within a database.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="recordtitle">
- <xsd:annotation>
- <xsd:documentation>Indicates the name of a record within a database.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="sourcefile">
- <xsd:annotation>
- <xsd:documentation>Indicates the original source file in the case that multiple files are merged to form the original file from which the XLIFF file is created. This differs from the original <file> attribute in that this sourcefile is one of many that make up that file.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="count-typeValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'count-type'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="num-usages">
- <xsd:annotation>
- <xsd:documentation>Indicates the count units are items that are used X times in a certain context; example: this is a reusable text unit which is used 42 times in other texts.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="repetition">
- <xsd:annotation>
- <xsd:documentation>Indicates the count units are translation units existing already in the same document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="total">
- <xsd:annotation>
- <xsd:documentation>Indicates a total count.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="InlineDelimitersValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'ctype' when used other elements than <ph> or <x>.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="bold">
- <xsd:annotation>
- <xsd:documentation>Indicates a run of bolded text.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="italic">
- <xsd:annotation>
- <xsd:documentation>Indicates a run of text in italics.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="underlined">
- <xsd:annotation>
- <xsd:documentation>Indicates a run of underlined text.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="link">
- <xsd:annotation>
- <xsd:documentation>Indicates a run of hyper-text.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="InlinePlaceholdersValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'ctype' when used with <ph> or <x>.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="image">
- <xsd:annotation>
- <xsd:documentation>Indicates a inline image.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="pb">
- <xsd:annotation>
- <xsd:documentation>Indicates a page break.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="lb">
- <xsd:annotation>
- <xsd:documentation>Indicates a line break.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="mime-typeValueList">
- <xsd:restriction base="xsd:string">
- <xsd:pattern value="(text|multipart|message|application|image|audio|video|model)(/.+)*"/>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="datatypeValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'datatype'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="asp">
- <xsd:annotation>
- <xsd:documentation>Indicates Active Server Page data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="c">
- <xsd:annotation>
- <xsd:documentation>Indicates C source file data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="cdf">
- <xsd:annotation>
- <xsd:documentation>Indicates Channel Definition Format (CDF) data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="cfm">
- <xsd:annotation>
- <xsd:documentation>Indicates ColdFusion data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="cpp">
- <xsd:annotation>
- <xsd:documentation>Indicates C++ source file data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="csharp">
- <xsd:annotation>
- <xsd:documentation>Indicates C-Sharp data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="cstring">
- <xsd:annotation>
- <xsd:documentation>Indicates strings from C, ASM, and driver files data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="csv">
- <xsd:annotation>
- <xsd:documentation>Indicates comma-separated values data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="database">
- <xsd:annotation>
- <xsd:documentation>Indicates database data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="documentfooter">
- <xsd:annotation>
- <xsd:documentation>Indicates portions of document that follows data and contains metadata.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="documentheader">
- <xsd:annotation>
- <xsd:documentation>Indicates portions of document that precedes data and contains metadata.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="filedialog">
- <xsd:annotation>
- <xsd:documentation>Indicates data from standard UI file operations dialogs (e.g., Open, Save, Save As, Export, Import).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="form">
- <xsd:annotation>
- <xsd:documentation>Indicates standard user input screen data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="html">
- <xsd:annotation>
- <xsd:documentation>Indicates HyperText Markup Language (HTML) data - document instance.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="htmlbody">
- <xsd:annotation>
- <xsd:documentation>Indicates content within an HTML document’s <body> element.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="ini">
- <xsd:annotation>
- <xsd:documentation>Indicates Windows INI file data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="interleaf">
- <xsd:annotation>
- <xsd:documentation>Indicates Interleaf data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="javaclass">
- <xsd:annotation>
- <xsd:documentation>Indicates Java source file data (extension '.java').</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="javapropertyresourcebundle">
- <xsd:annotation>
- <xsd:documentation>Indicates Java property resource bundle data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="javalistresourcebundle">
- <xsd:annotation>
- <xsd:documentation>Indicates Java list resource bundle data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="javascript">
- <xsd:annotation>
- <xsd:documentation>Indicates JavaScript source file data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="jscript">
- <xsd:annotation>
- <xsd:documentation>Indicates JScript source file data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="layout">
- <xsd:annotation>
- <xsd:documentation>Indicates information relating to formatting.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="lisp">
- <xsd:annotation>
- <xsd:documentation>Indicates LISP source file data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="margin">
- <xsd:annotation>
- <xsd:documentation>Indicates information relating to margin formats.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="menufile">
- <xsd:annotation>
- <xsd:documentation>Indicates a file containing menu.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="messagefile">
- <xsd:annotation>
- <xsd:documentation>Indicates numerically identified string table.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="mif">
- <xsd:annotation>
- <xsd:documentation>Indicates Maker Interchange Format (MIF) data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="mimetype">
- <xsd:annotation>
- <xsd:documentation>Indicates that the datatype attribute value is a MIME Type value and is defined in the mime-type attribute.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="mo">
- <xsd:annotation>
- <xsd:documentation>Indicates GNU Machine Object data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="msglib">
- <xsd:annotation>
- <xsd:documentation>Indicates Message Librarian strings created by Novell's Message Librarian Tool.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="pagefooter">
- <xsd:annotation>
- <xsd:documentation>Indicates information to be displayed at the bottom of each page of a document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="pageheader">
- <xsd:annotation>
- <xsd:documentation>Indicates information to be displayed at the top of each page of a document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="parameters">
- <xsd:annotation>
- <xsd:documentation>Indicates a list of property values (e.g., settings within INI files or preferences dialog).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="pascal">
- <xsd:annotation>
- <xsd:documentation>Indicates Pascal source file data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="php">
- <xsd:annotation>
- <xsd:documentation>Indicates Hypertext Preprocessor data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="plaintext">
- <xsd:annotation>
- <xsd:documentation>Indicates plain text file (no formatting other than, possibly, wrapping).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="po">
- <xsd:annotation>
- <xsd:documentation>Indicates GNU Portable Object file.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="report">
- <xsd:annotation>
- <xsd:documentation>Indicates dynamically generated user defined document. e.g. Oracle Report, Crystal Report, etc.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="resources">
- <xsd:annotation>
- <xsd:documentation>Indicates Windows .NET binary resources.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="resx">
- <xsd:annotation>
- <xsd:documentation>Indicates Windows .NET Resources.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rtf">
- <xsd:annotation>
- <xsd:documentation>Indicates Rich Text Format (RTF) data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="sgml">
- <xsd:annotation>
- <xsd:documentation>Indicates Standard Generalized Markup Language (SGML) data - document instance.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="sgmldtd">
- <xsd:annotation>
- <xsd:documentation>Indicates Standard Generalized Markup Language (SGML) data - Document Type Definition (DTD).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="svg">
- <xsd:annotation>
- <xsd:documentation>Indicates Scalable Vector Graphic (SVG) data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="vbscript">
- <xsd:annotation>
- <xsd:documentation>Indicates VisualBasic Script source file.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="warning">
- <xsd:annotation>
- <xsd:documentation>Indicates warning message.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="winres">
- <xsd:annotation>
- <xsd:documentation>Indicates Windows (Win32) resources (i.e. resources extracted from an RC script, a message file, or a compiled file).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="xhtml">
- <xsd:annotation>
- <xsd:documentation>Indicates Extensible HyperText Markup Language (XHTML) data - document instance.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="xml">
- <xsd:annotation>
- <xsd:documentation>Indicates Extensible Markup Language (XML) data - document instance.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="xmldtd">
- <xsd:annotation>
- <xsd:documentation>Indicates Extensible Markup Language (XML) data - Document Type Definition (DTD).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="xsl">
- <xsd:annotation>
- <xsd:documentation>Indicates Extensible Stylesheet Language (XSL) data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="xul">
- <xsd:annotation>
- <xsd:documentation>Indicates XUL elements.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="mtypeValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'mtype'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="abbrev">
- <xsd:annotation>
- <xsd:documentation>Indicates the marked text is an abbreviation.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="abbreviated-form">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.8: A term resulting from the omission of any part of the full term while designating the same concept.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="abbreviation">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.8.1: An abbreviated form of a simple term resulting from the omission of some of its letters (e.g. 'adj.' for 'adjective').</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="acronym">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.8.4: An abbreviated form of a term made up of letters from the full form of a multiword term strung together into a sequence pronounced only syllabically (e.g. 'radar' for 'radio detecting and ranging').</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="appellation">
- <xsd:annotation>
- <xsd:documentation>ISO-12620: A proper-name term, such as the name of an agency or other proper entity.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="collocation">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.18.1: A recurrent word combination characterized by cohesion in that the components of the collocation must co-occur within an utterance or series of utterances, even though they do not necessarily have to maintain immediate proximity to one another.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="common-name">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.5: A synonym for an international scientific term that is used in general discourse in a given language.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="datetime">
- <xsd:annotation>
- <xsd:documentation>Indicates the marked text is a date and/or time.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="equation">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.15: An expression used to represent a concept based on a statement that two mathematical expressions are, for instance, equal as identified by the equal sign (=), or assigned to one another by a similar sign.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="expanded-form">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.7: The complete representation of a term for which there is an abbreviated form.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="formula">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.14: Figures, symbols or the like used to express a concept briefly, such as a mathematical or chemical formula.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="head-term">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.1: The concept designation that has been chosen to head a terminological record.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="initialism">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.8.3: An abbreviated form of a term consisting of some of the initial letters of the words making up a multiword term or the term elements making up a compound term when these letters are pronounced individually (e.g. 'BSE' for 'bovine spongiform encephalopathy').</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="international-scientific-term">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.4: A term that is part of an international scientific nomenclature as adopted by an appropriate scientific body.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="internationalism">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.6: A term that has the same or nearly identical orthographic or phonemic form in many languages.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="logical-expression">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.16: An expression used to represent a concept based on mathematical or logical relations, such as statements of inequality, set relationships, Boolean operations, and the like.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="materials-management-unit">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.17: A unit to track object.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="name">
- <xsd:annotation>
- <xsd:documentation>Indicates the marked text is a name.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="near-synonym">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.3: A term that represents the same or a very similar concept as another term in the same language, but for which interchangeability is limited to some contexts and inapplicable in others.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="part-number">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.17.2: A unique alphanumeric designation assigned to an object in a manufacturing system.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="phrase">
- <xsd:annotation>
- <xsd:documentation>Indicates the marked text is a phrase.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="phraseological-unit">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.18: Any group of two or more words that form a unit, the meaning of which frequently cannot be deduced based on the combined sense of the words making up the phrase.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="protected">
- <xsd:annotation>
- <xsd:documentation>Indicates the marked text should not be translated.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="romanized-form">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.12: A form of a term resulting from an operation whereby non-Latin writing systems are converted to the Latin alphabet.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="seg">
- <xsd:annotation>
- <xsd:documentation>Indicates that the marked text represents a segment.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="set-phrase">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.18.2: A fixed, lexicalized phrase.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="short-form">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.8.2: A variant of a multiword term that includes fewer words than the full form of the term (e.g. 'Group of Twenty-four' for 'Intergovernmental Group of Twenty-four on International Monetary Affairs').</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="sku">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.17.1: Stock keeping unit, an inventory item identified by a unique alphanumeric designation assigned to an object in an inventory control system.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="standard-text">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.19: A fixed chunk of recurring text.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="symbol">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.13: A designation of a concept by letters, numerals, pictograms or any combination thereof.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="synonym">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.2: Any term that represents the same or a very similar concept as the main entry term in a term entry.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="synonymous-phrase">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.18.3: Phraseological unit in a language that expresses the same semantic content as another phrase in that same language.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="term">
- <xsd:annotation>
- <xsd:documentation>Indicates the marked text is a term.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="transcribed-form">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.11: A form of a term resulting from an operation whereby the characters of one writing system are represented by characters from another writing system, taking into account the pronunciation of the characters converted.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="transliterated-form">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.10: A form of a term resulting from an operation whereby the characters of an alphabetic writing system are represented by characters from another alphabetic writing system.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="truncated-term">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.8.5: An abbreviated form of a term resulting from the omission of one or more term elements or syllables (e.g. 'flu' for 'influenza').</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="variant">
- <xsd:annotation>
- <xsd:documentation>ISO-12620 2.1.9: One of the alternate forms of a term.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="restypeValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'restype'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="auto3state">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC AUTO3STATE control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="autocheckbox">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC AUTOCHECKBOX control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="autoradiobutton">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC AUTORADIOBUTTON control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="bedit">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC BEDIT control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="bitmap">
- <xsd:annotation>
- <xsd:documentation>Indicates a bitmap, for example a BITMAP resource in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="button">
- <xsd:annotation>
- <xsd:documentation>Indicates a button object, for example a BUTTON control Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="caption">
- <xsd:annotation>
- <xsd:documentation>Indicates a caption, such as the caption of a dialog box.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="cell">
- <xsd:annotation>
- <xsd:documentation>Indicates the cell in a table, for example the content of the <td> element in HTML.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="checkbox">
- <xsd:annotation>
- <xsd:documentation>Indicates check box object, for example a CHECKBOX control in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="checkboxmenuitem">
- <xsd:annotation>
- <xsd:documentation>Indicates a menu item with an associated checkbox.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="checkedlistbox">
- <xsd:annotation>
- <xsd:documentation>Indicates a list box, but with a check-box for each item.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="colorchooser">
- <xsd:annotation>
- <xsd:documentation>Indicates a color selection dialog.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="combobox">
- <xsd:annotation>
- <xsd:documentation>Indicates a combination of edit box and listbox object, for example a COMBOBOX control in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="comboboxexitem">
- <xsd:annotation>
- <xsd:documentation>Indicates an initialization entry of an extended combobox DLGINIT resource block. (code 0x1234).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="comboboxitem">
- <xsd:annotation>
- <xsd:documentation>Indicates an initialization entry of a combobox DLGINIT resource block (code 0x0403).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="component">
- <xsd:annotation>
- <xsd:documentation>Indicates a UI base class element that cannot be represented by any other element.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="contextmenu">
- <xsd:annotation>
- <xsd:documentation>Indicates a context menu.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="ctext">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC CTEXT control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="cursor">
- <xsd:annotation>
- <xsd:documentation>Indicates a cursor, for example a CURSOR resource in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="datetimepicker">
- <xsd:annotation>
- <xsd:documentation>Indicates a date/time picker.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="defpushbutton">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC DEFPUSHBUTTON control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="dialog">
- <xsd:annotation>
- <xsd:documentation>Indicates a dialog box.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="dlginit">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC DLGINIT resource block.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="edit">
- <xsd:annotation>
- <xsd:documentation>Indicates an edit box object, for example an EDIT control in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="file">
- <xsd:annotation>
- <xsd:documentation>Indicates a filename.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="filechooser">
- <xsd:annotation>
- <xsd:documentation>Indicates a file dialog.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="fn">
- <xsd:annotation>
- <xsd:documentation>Indicates a footnote.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="font">
- <xsd:annotation>
- <xsd:documentation>Indicates a font name.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="footer">
- <xsd:annotation>
- <xsd:documentation>Indicates a footer.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="frame">
- <xsd:annotation>
- <xsd:documentation>Indicates a frame object.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="grid">
- <xsd:annotation>
- <xsd:documentation>Indicates a XUL grid element.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="groupbox">
- <xsd:annotation>
- <xsd:documentation>Indicates a groupbox object, for example a GROUPBOX control in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="header">
- <xsd:annotation>
- <xsd:documentation>Indicates a header item.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="heading">
- <xsd:annotation>
- <xsd:documentation>Indicates a heading, such has the content of <h1>, <h2>, etc. in HTML.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="hedit">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC HEDIT control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="hscrollbar">
- <xsd:annotation>
- <xsd:documentation>Indicates a horizontal scrollbar.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="icon">
- <xsd:annotation>
- <xsd:documentation>Indicates an icon, for example an ICON resource in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="iedit">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC IEDIT control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="keywords">
- <xsd:annotation>
- <xsd:documentation>Indicates keyword list, such as the content of the Keywords meta-data in HTML, or a K footnote in WinHelp RTF.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="label">
- <xsd:annotation>
- <xsd:documentation>Indicates a label object.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="linklabel">
- <xsd:annotation>
- <xsd:documentation>Indicates a label that is also a HTML link (not necessarily a URL).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="list">
- <xsd:annotation>
- <xsd:documentation>Indicates a list (a group of list-items, for example an <ol> or <ul> element in HTML).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="listbox">
- <xsd:annotation>
- <xsd:documentation>Indicates a listbox object, for example an LISTBOX control in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="listitem">
- <xsd:annotation>
- <xsd:documentation>Indicates an list item (an entry in a list).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="ltext">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC LTEXT control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="menu">
- <xsd:annotation>
- <xsd:documentation>Indicates a menu (a group of menu-items).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="menubar">
- <xsd:annotation>
- <xsd:documentation>Indicates a toolbar containing one or more tope level menus.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="menuitem">
- <xsd:annotation>
- <xsd:documentation>Indicates a menu item (an entry in a menu).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="menuseparator">
- <xsd:annotation>
- <xsd:documentation>Indicates a XUL menuseparator element.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="message">
- <xsd:annotation>
- <xsd:documentation>Indicates a message, for example an entry in a MESSAGETABLE resource in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="monthcalendar">
- <xsd:annotation>
- <xsd:documentation>Indicates a calendar control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="numericupdown">
- <xsd:annotation>
- <xsd:documentation>Indicates an edit box beside a spin control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="panel">
- <xsd:annotation>
- <xsd:documentation>Indicates a catch all for rectangular areas.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="popupmenu">
- <xsd:annotation>
- <xsd:documentation>Indicates a standalone menu not necessarily associated with a menubar.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="pushbox">
- <xsd:annotation>
- <xsd:documentation>Indicates a pushbox object, for example a PUSHBOX control in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="pushbutton">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC PUSHBUTTON control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="radio">
- <xsd:annotation>
- <xsd:documentation>Indicates a radio button object.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="radiobuttonmenuitem">
- <xsd:annotation>
- <xsd:documentation>Indicates a menuitem with associated radio button.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rcdata">
- <xsd:annotation>
- <xsd:documentation>Indicates raw data resources for an application.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="row">
- <xsd:annotation>
- <xsd:documentation>Indicates a row in a table.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rtext">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC RTEXT control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="scrollpane">
- <xsd:annotation>
- <xsd:documentation>Indicates a user navigable container used to show a portion of a document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="separator">
- <xsd:annotation>
- <xsd:documentation>Indicates a generic divider object (e.g. menu group separator).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="shortcut">
- <xsd:annotation>
- <xsd:documentation>Windows accelerators, shortcuts in resource or property files.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="spinner">
- <xsd:annotation>
- <xsd:documentation>Indicates a UI control to indicate process activity but not progress.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="splitter">
- <xsd:annotation>
- <xsd:documentation>Indicates a splitter bar.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="state3">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC STATE3 control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="statusbar">
- <xsd:annotation>
- <xsd:documentation>Indicates a window for providing feedback to the users, like 'read-only', etc.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="string">
- <xsd:annotation>
- <xsd:documentation>Indicates a string, for example an entry in a STRINGTABLE resource in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="tabcontrol">
- <xsd:annotation>
- <xsd:documentation>Indicates a layers of controls with a tab to select layers.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="table">
- <xsd:annotation>
- <xsd:documentation>Indicates a display and edits regular two-dimensional tables of cells.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="textbox">
- <xsd:annotation>
- <xsd:documentation>Indicates a XUL textbox element.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="togglebutton">
- <xsd:annotation>
- <xsd:documentation>Indicates a UI button that can be toggled to on or off state.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="toolbar">
- <xsd:annotation>
- <xsd:documentation>Indicates an array of controls, usually buttons.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="tooltip">
- <xsd:annotation>
- <xsd:documentation>Indicates a pop up tool tip text.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="trackbar">
- <xsd:annotation>
- <xsd:documentation>Indicates a bar with a pointer indicating a position within a certain range.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="tree">
- <xsd:annotation>
- <xsd:documentation>Indicates a control that displays a set of hierarchical data.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="uri">
- <xsd:annotation>
- <xsd:documentation>Indicates a URI (URN or URL).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="userbutton">
- <xsd:annotation>
- <xsd:documentation>Indicates a Windows RC USERBUTTON control.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="usercontrol">
- <xsd:annotation>
- <xsd:documentation>Indicates a user-defined control like CONTROL control in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="var">
- <xsd:annotation>
- <xsd:documentation>Indicates the text of a variable.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="versioninfo">
- <xsd:annotation>
- <xsd:documentation>Indicates version information about a resource like VERSIONINFO in Windows.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="vscrollbar">
- <xsd:annotation>
- <xsd:documentation>Indicates a vertical scrollbar.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="window">
- <xsd:annotation>
- <xsd:documentation>Indicates a graphical window.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="size-unitValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'size-unit'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="byte">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in 8-bit bytes.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="char">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in Unicode characters.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="col">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in columns. Used for HTML text area.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="cm">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in centimeters.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="dlgunit">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in dialog units, as defined in Windows resources.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="em">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in 'font-size' units (as defined in CSS).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="ex">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in 'x-height' units (as defined in CSS).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="glyph">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in glyphs. A glyph is considered to be one or more combined Unicode characters that represent a single displayable text character. Sometimes referred to as a 'grapheme cluster'</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="in">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in inches.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="mm">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in millimeters.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="percent">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in percentage.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="pixel">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in pixels.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="point">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in point.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="row">
- <xsd:annotation>
- <xsd:documentation>Indicates a size in rows. Used for HTML text area.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="stateValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'state'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="final">
- <xsd:annotation>
- <xsd:documentation>Indicates the terminating state.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="needs-adaptation">
- <xsd:annotation>
- <xsd:documentation>Indicates only non-textual information needs adaptation.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="needs-l10n">
- <xsd:annotation>
- <xsd:documentation>Indicates both text and non-textual information needs adaptation.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="needs-review-adaptation">
- <xsd:annotation>
- <xsd:documentation>Indicates only non-textual information needs review.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="needs-review-l10n">
- <xsd:annotation>
- <xsd:documentation>Indicates both text and non-textual information needs review.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="needs-review-translation">
- <xsd:annotation>
- <xsd:documentation>Indicates that only the text of the item needs to be reviewed.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="needs-translation">
- <xsd:annotation>
- <xsd:documentation>Indicates that the item needs to be translated.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="new">
- <xsd:annotation>
- <xsd:documentation>Indicates that the item is new. For example, translation units that were not in a previous version of the document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="signed-off">
- <xsd:annotation>
- <xsd:documentation>Indicates that changes are reviewed and approved.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="translated">
- <xsd:annotation>
- <xsd:documentation>Indicates that the item has been translated.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="state-qualifierValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'state-qualifier'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="exact-match">
- <xsd:annotation>
- <xsd:documentation>Indicates an exact match. An exact match occurs when a source text of a segment is exactly the same as the source text of a segment that was translated previously.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="fuzzy-match">
- <xsd:annotation>
- <xsd:documentation>Indicates a fuzzy match. A fuzzy match occurs when a source text of a segment is very similar to the source text of a segment that was translated previously (e.g. when the difference is casing, a few changed words, white-space discripancy, etc.).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="id-match">
- <xsd:annotation>
- <xsd:documentation>Indicates a match based on matching IDs (in addition to matching text).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="leveraged-glossary">
- <xsd:annotation>
- <xsd:documentation>Indicates a translation derived from a glossary.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="leveraged-inherited">
- <xsd:annotation>
- <xsd:documentation>Indicates a translation derived from existing translation.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="leveraged-mt">
- <xsd:annotation>
- <xsd:documentation>Indicates a translation derived from machine translation.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="leveraged-repository">
- <xsd:annotation>
- <xsd:documentation>Indicates a translation derived from a translation repository.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="leveraged-tm">
- <xsd:annotation>
- <xsd:documentation>Indicates a translation derived from a translation memory.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="mt-suggestion">
- <xsd:annotation>
- <xsd:documentation>Indicates the translation is suggested by machine translation.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rejected-grammar">
- <xsd:annotation>
- <xsd:documentation>Indicates that the item has been rejected because of incorrect grammar.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rejected-inaccurate">
- <xsd:annotation>
- <xsd:documentation>Indicates that the item has been rejected because it is incorrect.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rejected-length">
- <xsd:annotation>
- <xsd:documentation>Indicates that the item has been rejected because it is too long or too short.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rejected-spelling">
- <xsd:annotation>
- <xsd:documentation>Indicates that the item has been rejected because of incorrect spelling.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="tm-suggestion">
- <xsd:annotation>
- <xsd:documentation>Indicates the translation is suggested by translation memory.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="unitValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'unit'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="word">
- <xsd:annotation>
- <xsd:documentation>Refers to words.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="page">
- <xsd:annotation>
- <xsd:documentation>Refers to pages.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="trans-unit">
- <xsd:annotation>
- <xsd:documentation>Refers to <trans-unit> elements.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="bin-unit">
- <xsd:annotation>
- <xsd:documentation>Refers to <bin-unit> elements.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="glyph">
- <xsd:annotation>
- <xsd:documentation>Refers to glyphs.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="item">
- <xsd:annotation>
- <xsd:documentation>Refers to <trans-unit> and/or <bin-unit> elements.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="instance">
- <xsd:annotation>
- <xsd:documentation>Refers to the occurrences of instances defined by the count-type value.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="character">
- <xsd:annotation>
- <xsd:documentation>Refers to characters.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="line">
- <xsd:annotation>
- <xsd:documentation>Refers to lines.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="sentence">
- <xsd:annotation>
- <xsd:documentation>Refers to sentences.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="paragraph">
- <xsd:annotation>
- <xsd:documentation>Refers to paragraphs.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="segment">
- <xsd:annotation>
- <xsd:documentation>Refers to segments.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="placeable">
- <xsd:annotation>
- <xsd:documentation>Refers to placeables (inline elements).</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="priorityValueList">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'priority'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:positiveInteger">
- <xsd:enumeration value="1">
- <xsd:annotation>
- <xsd:documentation>Highest priority.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="2">
- <xsd:annotation>
- <xsd:documentation>High priority.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="3">
- <xsd:annotation>
- <xsd:documentation>High priority, but not as important as 2.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="4">
- <xsd:annotation>
- <xsd:documentation>High priority, but not as important as 3.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="5">
- <xsd:annotation>
- <xsd:documentation>Medium priority, but more important than 6.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="6">
- <xsd:annotation>
- <xsd:documentation>Medium priority, but less important than 5.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="7">
- <xsd:annotation>
- <xsd:documentation>Low priority, but more important than 8.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="8">
- <xsd:annotation>
- <xsd:documentation>Low priority, but more important than 9.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="9">
- <xsd:annotation>
- <xsd:documentation>Low priority.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="10">
- <xsd:annotation>
- <xsd:documentation>Lowest priority.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="reformatValueYesNo">
- <xsd:restriction base="xsd:string">
- <xsd:enumeration value="yes">
- <xsd:annotation>
- <xsd:documentation>This value indicates that all properties can be reformatted. This value must be used alone.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="no">
- <xsd:annotation>
- <xsd:documentation>This value indicates that no properties should be reformatted. This value must be used alone.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="reformatValueList">
- <xsd:list>
- <xsd:simpleType>
- <xsd:union memberTypes="xlf:XTend">
- <xsd:simpleType>
- <xsd:restriction base="xsd:string">
- <xsd:enumeration value="coord">
- <xsd:annotation>
- <xsd:documentation>This value indicates that all information in the coord attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="coord-x">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the x information in the coord attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="coord-y">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the y information in the coord attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="coord-cx">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the cx information in the coord attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="coord-cy">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the cy information in the coord attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="font">
- <xsd:annotation>
- <xsd:documentation>This value indicates that all the information in the font attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="font-name">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the name information in the font attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="font-size">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the size information in the font attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="font-weight">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the weight information in the font attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="css-style">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the information in the css-style attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="style">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the information in the style attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="ex-style">
- <xsd:annotation>
- <xsd:documentation>This value indicates that the information in the exstyle attribute can be modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- </xsd:union>
- </xsd:simpleType>
- </xsd:list>
- </xsd:simpleType>
- <xsd:simpleType name="purposeValueList">
- <xsd:restriction base="xsd:string">
- <xsd:enumeration value="information">
- <xsd:annotation>
- <xsd:documentation>Indicates that the context is informational in nature, specifying for example, how a term should be translated. Thus, should be displayed to anyone editing the XLIFF document.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="location">
- <xsd:annotation>
- <xsd:documentation>Indicates that the context-group is used to specify where the term was found in the translatable source. Thus, it is not displayed.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="match">
- <xsd:annotation>
- <xsd:documentation>Indicates that the context information should be used during translation memory lookups. Thus, it is not displayed.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="alttranstypeValueList">
- <xsd:restriction base="xsd:string">
- <xsd:enumeration value="proposal">
- <xsd:annotation>
- <xsd:documentation>Represents a translation proposal from a translation memory or other resource.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="previous-version">
- <xsd:annotation>
- <xsd:documentation>Represents a previous version of the target element.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="rejected">
- <xsd:annotation>
- <xsd:documentation>Represents a rejected version of the target element.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="reference">
- <xsd:annotation>
- <xsd:documentation>Represents a translation to be used for reference purposes only, for example from a related product or a different language.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- <xsd:enumeration value="accepted">
- <xsd:annotation>
- <xsd:documentation>Represents a proposed translation that was used for the translation of the trans-unit, possibly modified.</xsd:documentation>
- </xsd:annotation>
- </xsd:enumeration>
- </xsd:restriction>
- </xsd:simpleType>
- <!-- Other Types -->
- <xsd:complexType name="ElemType_ExternalReference">
- <xsd:choice>
- <xsd:element ref="xlf:internal-file"/>
- <xsd:element ref="xlf:external-file"/>
- </xsd:choice>
- </xsd:complexType>
- <xsd:simpleType name="AttrType_purpose">
- <xsd:list>
- <xsd:simpleType>
- <xsd:union memberTypes="xlf:purposeValueList xlf:XTend"/>
- </xsd:simpleType>
- </xsd:list>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_datatype">
- <xsd:union memberTypes="xlf:datatypeValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_restype">
- <xsd:union memberTypes="xlf:restypeValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_alttranstype">
- <xsd:union memberTypes="xlf:alttranstypeValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_context-type">
- <xsd:union memberTypes="xlf:context-typeValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_state">
- <xsd:union memberTypes="xlf:stateValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_state-qualifier">
- <xsd:union memberTypes="xlf:state-qualifierValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_count-type">
- <xsd:union memberTypes="xlf:restypeValueList xlf:count-typeValueList xlf:datatypeValueList xlf:stateValueList xlf:state-qualifierValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_InlineDelimiters">
- <xsd:union memberTypes="xlf:InlineDelimitersValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_InlinePlaceholders">
- <xsd:union memberTypes="xlf:InlinePlaceholdersValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_size-unit">
- <xsd:union memberTypes="xlf:size-unitValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_mtype">
- <xsd:union memberTypes="xlf:mtypeValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_unit">
- <xsd:union memberTypes="xlf:unitValueList xlf:XTend"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_priority">
- <xsd:union memberTypes="xlf:priorityValueList"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_reformat">
- <xsd:union memberTypes="xlf:reformatValueYesNo xlf:reformatValueList"/>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_YesNo">
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="yes"/>
- <xsd:enumeration value="no"/>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_Position">
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="open"/>
- <xsd:enumeration value="close"/>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_assoc">
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="preceding"/>
- <xsd:enumeration value="following"/>
- <xsd:enumeration value="both"/>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_annotates">
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="source"/>
- <xsd:enumeration value="target"/>
- <xsd:enumeration value="general"/>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_Coordinates">
- <xsd:annotation>
- <xsd:documentation>Values for the attribute 'coord'.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:string">
- <xsd:pattern value="(-?\d+|#);(-?\d+|#);(-?\d+|#);(-?\d+|#)"/>
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType name="AttrType_Version">
- <xsd:annotation>
- <xsd:documentation>Version values: 1.0 and 1.1 are allowed for backward compatibility.</xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:string">
- <xsd:enumeration value="1.2"/>
- <xsd:enumeration value="1.1"/>
- <xsd:enumeration value="1.0"/>
- </xsd:restriction>
- </xsd:simpleType>
- <!-- Groups -->
- <xsd:group name="ElemGroup_TextContent">
- <xsd:choice>
- <xsd:element ref="xlf:g"/>
- <xsd:element ref="xlf:bpt"/>
- <xsd:element ref="xlf:ept"/>
- <xsd:element ref="xlf:ph"/>
- <xsd:element ref="xlf:it"/>
- <xsd:element ref="xlf:mrk"/>
- <xsd:element ref="xlf:x"/>
- <xsd:element ref="xlf:bx"/>
- <xsd:element ref="xlf:ex"/>
- </xsd:choice>
- </xsd:group>
- <xsd:attributeGroup name="AttrGroup_TextContent">
- <xsd:attribute name="id" type="xsd:string" use="required"/>
- <xsd:attribute name="xid" type="xsd:string" use="optional"/>
- <xsd:attribute name="equiv-text" type="xsd:string" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:attributeGroup>
- <!-- XLIFF Structure -->
- <xsd:element name="xliff">
- <xsd:complexType>
- <xsd:sequence maxOccurs="unbounded">
- <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="strict"/>
- <xsd:element ref="xlf:file"/>
- </xsd:sequence>
- <xsd:attribute name="version" type="xlf:AttrType_Version" use="required"/>
- <xsd:attribute ref="xml:lang" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="file">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element minOccurs="0" ref="xlf:header"/>
- <xsd:element ref="xlf:body"/>
- </xsd:sequence>
- <xsd:attribute name="original" type="xsd:string" use="required"/>
- <xsd:attribute name="source-language" type="xsd:language" use="required"/>
- <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="required"/>
- <xsd:attribute name="tool-id" type="xsd:string" use="optional"/>
- <xsd:attribute name="date" type="xsd:dateTime" use="optional"/>
- <xsd:attribute ref="xml:space" use="optional"/>
- <xsd:attribute name="category" type="xsd:string" use="optional"/>
- <xsd:attribute name="target-language" type="xsd:language" use="optional"/>
- <xsd:attribute name="product-name" type="xsd:string" use="optional"/>
- <xsd:attribute name="product-version" type="xsd:string" use="optional"/>
- <xsd:attribute name="build-num" type="xsd:string" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- <xsd:unique name="U_group_id">
- <xsd:selector xpath=".//xlf:group"/>
- <xsd:field xpath="@id"/>
- </xsd:unique>
- <xsd:key name="K_unit_id">
- <xsd:selector xpath=".//xlf:trans-unit|.//xlf:bin-unit"/>
- <xsd:field xpath="@id"/>
- </xsd:key>
- <xsd:keyref name="KR_unit_id" refer="xlf:K_unit_id">
- <xsd:selector xpath=".//bpt|.//ept|.//it|.//ph|.//g|.//x|.//bx|.//ex|.//sub"/>
- <xsd:field xpath="@xid"/>
- </xsd:keyref>
- <xsd:key name="K_tool-id">
- <xsd:selector xpath="xlf:header/xlf:tool"/>
- <xsd:field xpath="@tool-id"/>
- </xsd:key>
- <xsd:keyref name="KR_file_tool-id" refer="xlf:K_tool-id">
- <xsd:selector xpath="."/>
- <xsd:field xpath="@tool-id"/>
- </xsd:keyref>
- <xsd:keyref name="KR_phase_tool-id" refer="xlf:K_tool-id">
- <xsd:selector xpath="xlf:header/xlf:phase-group/xlf:phase"/>
- <xsd:field xpath="@tool-id"/>
- </xsd:keyref>
- <xsd:keyref name="KR_alt-trans_tool-id" refer="xlf:K_tool-id">
- <xsd:selector xpath=".//xlf:trans-unit/xlf:alt-trans"/>
- <xsd:field xpath="@tool-id"/>
- </xsd:keyref>
- <xsd:key name="K_count-group_name">
- <xsd:selector xpath=".//xlf:count-group"/>
- <xsd:field xpath="@name"/>
- </xsd:key>
- <xsd:unique name="U_context-group_name">
- <xsd:selector xpath=".//xlf:context-group"/>
- <xsd:field xpath="@name"/>
- </xsd:unique>
- <xsd:key name="K_phase-name">
- <xsd:selector xpath="xlf:header/xlf:phase-group/xlf:phase"/>
- <xsd:field xpath="@phase-name"/>
- </xsd:key>
- <xsd:keyref name="KR_phase-name" refer="xlf:K_phase-name">
- <xsd:selector xpath=".//xlf:count|.//xlf:trans-unit|.//xlf:target|.//bin-unit|.//bin-target"/>
- <xsd:field xpath="@phase-name"/>
- </xsd:keyref>
- <xsd:unique name="U_uid">
- <xsd:selector xpath=".//xlf:external-file"/>
- <xsd:field xpath="@uid"/>
- </xsd:unique>
- </xsd:element>
- <xsd:element name="header">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element minOccurs="0" name="skl" type="xlf:ElemType_ExternalReference"/>
- <xsd:element minOccurs="0" ref="xlf:phase-group"/>
- <xsd:choice maxOccurs="unbounded" minOccurs="0">
- <xsd:element name="glossary" type="xlf:ElemType_ExternalReference"/>
- <xsd:element name="reference" type="xlf:ElemType_ExternalReference"/>
- <xsd:element ref="xlf:count-group"/>
- <xsd:element ref="xlf:note"/>
- <xsd:element ref="xlf:tool"/>
- </xsd:choice>
- <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="strict"/>
- </xsd:sequence>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="internal-file">
- <xsd:complexType>
- <xsd:simpleContent>
- <xsd:extension base="xsd:string">
- <xsd:attribute name="form" type="xsd:string"/>
- <xsd:attribute name="crc" type="xsd:NMTOKEN"/>
- </xsd:extension>
- </xsd:simpleContent>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="external-file">
- <xsd:complexType>
- <xsd:attribute name="href" type="xsd:string" use="required"/>
- <xsd:attribute name="crc" type="xsd:NMTOKEN"/>
- <xsd:attribute name="uid" type="xsd:NMTOKEN"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="note">
- <xsd:complexType>
- <xsd:simpleContent>
- <xsd:extension base="xsd:string">
- <xsd:attribute ref="xml:lang" use="optional"/>
- <xsd:attribute default="1" name="priority" type="xlf:AttrType_priority" use="optional"/>
- <xsd:attribute name="from" type="xsd:string" use="optional"/>
- <xsd:attribute default="general" name="annotates" type="xlf:AttrType_annotates" use="optional"/>
- </xsd:extension>
- </xsd:simpleContent>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="phase-group">
- <xsd:complexType>
- <xsd:sequence maxOccurs="unbounded">
- <xsd:element ref="xlf:phase"/>
- </xsd:sequence>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="phase">
- <xsd:complexType>
- <xsd:sequence maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:note"/>
- </xsd:sequence>
- <xsd:attribute name="phase-name" type="xsd:string" use="required"/>
- <xsd:attribute name="process-name" type="xsd:string" use="required"/>
- <xsd:attribute name="company-name" type="xsd:string" use="optional"/>
- <xsd:attribute name="tool-id" type="xsd:string" use="optional"/>
- <xsd:attribute name="date" type="xsd:dateTime" use="optional"/>
- <xsd:attribute name="job-id" type="xsd:string" use="optional"/>
- <xsd:attribute name="contact-name" type="xsd:string" use="optional"/>
- <xsd:attribute name="contact-email" type="xsd:string" use="optional"/>
- <xsd:attribute name="contact-phone" type="xsd:string" use="optional"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="count-group">
- <xsd:complexType>
- <xsd:sequence maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:count"/>
- </xsd:sequence>
- <xsd:attribute name="name" type="xsd:string" use="required"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="count">
- <xsd:complexType>
- <xsd:simpleContent>
- <xsd:extension base="xsd:string">
- <xsd:attribute name="count-type" type="xlf:AttrType_count-type" use="optional"/>
- <xsd:attribute name="phase-name" type="xsd:string" use="optional"/>
- <xsd:attribute default="word" name="unit" type="xlf:AttrType_unit" use="optional"/>
- </xsd:extension>
- </xsd:simpleContent>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="context-group">
- <xsd:complexType>
- <xsd:sequence maxOccurs="unbounded">
- <xsd:element ref="xlf:context"/>
- </xsd:sequence>
- <xsd:attribute name="name" type="xsd:string" use="optional"/>
- <xsd:attribute name="crc" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="purpose" type="xlf:AttrType_purpose" use="optional"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="context">
- <xsd:complexType>
- <xsd:simpleContent>
- <xsd:extension base="xsd:string">
- <xsd:attribute name="context-type" type="xlf:AttrType_context-type" use="required"/>
- <xsd:attribute default="no" name="match-mandatory" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attribute name="crc" type="xsd:NMTOKEN" use="optional"/>
- </xsd:extension>
- </xsd:simpleContent>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="tool">
- <xsd:complexType mixed="true">
- <xsd:sequence>
- <xsd:any namespace="##any" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
- </xsd:sequence>
- <xsd:attribute name="tool-id" type="xsd:string" use="required"/>
- <xsd:attribute name="tool-name" type="xsd:string" use="required"/>
- <xsd:attribute name="tool-version" type="xsd:string" use="optional"/>
- <xsd:attribute name="tool-company" type="xsd:string" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="body">
- <xsd:complexType>
- <xsd:choice maxOccurs="unbounded" minOccurs="0">
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:group"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:trans-unit"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:bin-unit"/>
- </xsd:choice>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="group">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:sequence>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:context-group"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:count-group"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:note"/>
- <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="strict"/>
- </xsd:sequence>
- <xsd:choice maxOccurs="unbounded">
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:group"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:trans-unit"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:bin-unit"/>
- </xsd:choice>
- </xsd:sequence>
- <xsd:attribute name="id" type="xsd:string" use="optional"/>
- <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
- <xsd:attribute default="default" ref="xml:space" use="optional"/>
- <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
- <xsd:attribute name="resname" type="xsd:string" use="optional"/>
- <xsd:attribute name="extradata" type="xsd:string" use="optional"/>
- <xsd:attribute name="extype" type="xsd:string" use="optional"/>
- <xsd:attribute name="help-id" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="menu" type="xsd:string" use="optional"/>
- <xsd:attribute name="menu-option" type="xsd:string" use="optional"/>
- <xsd:attribute name="menu-name" type="xsd:string" use="optional"/>
- <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
- <xsd:attribute name="font" type="xsd:string" use="optional"/>
- <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
- <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute default="yes" name="translate" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attribute default="yes" name="reformat" type="xlf:AttrType_reformat" use="optional"/>
- <xsd:attribute default="pixel" name="size-unit" type="xlf:AttrType_size-unit" use="optional"/>
- <xsd:attribute name="maxwidth" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="minwidth" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="maxheight" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="minheight" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="maxbytes" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="minbytes" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="charclass" type="xsd:string" use="optional"/>
- <xsd:attribute default="no" name="merged-trans" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="trans-unit">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element ref="xlf:source"/>
- <xsd:element minOccurs="0" ref="xlf:seg-source"/>
- <xsd:element minOccurs="0" ref="xlf:target"/>
- <xsd:choice maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:context-group"/>
- <xsd:element ref="xlf:count-group"/>
- <xsd:element ref="xlf:note"/>
- <xsd:element ref="xlf:alt-trans"/>
- </xsd:choice>
- <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="strict"/>
- </xsd:sequence>
- <xsd:attribute name="id" type="xsd:string" use="required"/>
- <xsd:attribute name="approved" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attribute default="yes" name="translate" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attribute default="yes" name="reformat" type="xlf:AttrType_reformat" use="optional"/>
- <xsd:attribute default="default" ref="xml:space" use="optional"/>
- <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
- <xsd:attribute name="phase-name" type="xsd:string" use="optional"/>
- <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
- <xsd:attribute name="resname" type="xsd:string" use="optional"/>
- <xsd:attribute name="extradata" type="xsd:string" use="optional"/>
- <xsd:attribute name="extype" type="xsd:string" use="optional"/>
- <xsd:attribute name="help-id" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="menu" type="xsd:string" use="optional"/>
- <xsd:attribute name="menu-option" type="xsd:string" use="optional"/>
- <xsd:attribute name="menu-name" type="xsd:string" use="optional"/>
- <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
- <xsd:attribute name="font" type="xsd:string" use="optional"/>
- <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
- <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute default="pixel" name="size-unit" type="xlf:AttrType_size-unit" use="optional"/>
- <xsd:attribute name="maxwidth" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="minwidth" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="maxheight" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="minheight" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="maxbytes" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="minbytes" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="charclass" type="xsd:string" use="optional"/>
- <xsd:attribute default="yes" name="merged-trans" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- <xsd:unique name="U_tu_segsrc_mid">
- <xsd:selector xpath="./xlf:seg-source/xlf:mrk"/>
- <xsd:field xpath="@mid"/>
- </xsd:unique>
- <xsd:keyref name="KR_tu_segsrc_mid" refer="xlf:U_tu_segsrc_mid">
- <xsd:selector xpath="./xlf:target/xlf:mrk|./xlf:alt-trans"/>
- <xsd:field xpath="@mid"/>
- </xsd:keyref>
- </xsd:element>
- <xsd:element name="source">
- <xsd:complexType mixed="true">
- <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
- <xsd:attribute ref="xml:lang" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- <xsd:unique name="U_source_bpt_rid">
- <xsd:selector xpath=".//xlf:bpt"/>
- <xsd:field xpath="@rid"/>
- </xsd:unique>
- <xsd:keyref name="KR_source_ept_rid" refer="xlf:U_source_bpt_rid">
- <xsd:selector xpath=".//xlf:ept"/>
- <xsd:field xpath="@rid"/>
- </xsd:keyref>
- <xsd:unique name="U_source_bx_rid">
- <xsd:selector xpath=".//xlf:bx"/>
- <xsd:field xpath="@rid"/>
- </xsd:unique>
- <xsd:keyref name="KR_source_ex_rid" refer="xlf:U_source_bx_rid">
- <xsd:selector xpath=".//xlf:ex"/>
- <xsd:field xpath="@rid"/>
- </xsd:keyref>
- </xsd:element>
- <xsd:element name="seg-source">
- <xsd:complexType mixed="true">
- <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
- <xsd:attribute ref="xml:lang" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- <xsd:unique name="U_segsrc_bpt_rid">
- <xsd:selector xpath=".//xlf:bpt"/>
- <xsd:field xpath="@rid"/>
- </xsd:unique>
- <xsd:keyref name="KR_segsrc_ept_rid" refer="xlf:U_segsrc_bpt_rid">
- <xsd:selector xpath=".//xlf:ept"/>
- <xsd:field xpath="@rid"/>
- </xsd:keyref>
- <xsd:unique name="U_segsrc_bx_rid">
- <xsd:selector xpath=".//xlf:bx"/>
- <xsd:field xpath="@rid"/>
- </xsd:unique>
- <xsd:keyref name="KR_segsrc_ex_rid" refer="xlf:U_segsrc_bx_rid">
- <xsd:selector xpath=".//xlf:ex"/>
- <xsd:field xpath="@rid"/>
- </xsd:keyref>
- </xsd:element>
- <xsd:element name="target">
- <xsd:complexType mixed="true">
- <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
- <xsd:attribute name="state" type="xlf:AttrType_state" use="optional"/>
- <xsd:attribute name="state-qualifier" type="xlf:AttrType_state-qualifier" use="optional"/>
- <xsd:attribute name="phase-name" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute ref="xml:lang" use="optional"/>
- <xsd:attribute name="resname" type="xsd:string" use="optional"/>
- <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
- <xsd:attribute name="font" type="xsd:string" use="optional"/>
- <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
- <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute default="yes" name="equiv-trans" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- <xsd:unique name="U_target_bpt_rid">
- <xsd:selector xpath=".//xlf:bpt"/>
- <xsd:field xpath="@rid"/>
- </xsd:unique>
- <xsd:keyref name="KR_target_ept_rid" refer="xlf:U_target_bpt_rid">
- <xsd:selector xpath=".//xlf:ept"/>
- <xsd:field xpath="@rid"/>
- </xsd:keyref>
- <xsd:unique name="U_target_bx_rid">
- <xsd:selector xpath=".//xlf:bx"/>
- <xsd:field xpath="@rid"/>
- </xsd:unique>
- <xsd:keyref name="KR_target_ex_rid" refer="xlf:U_target_bx_rid">
- <xsd:selector xpath=".//xlf:ex"/>
- <xsd:field xpath="@rid"/>
- </xsd:keyref>
- </xsd:element>
- <xsd:element name="alt-trans">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element minOccurs="0" ref="xlf:source"/>
- <xsd:element minOccurs="0" ref="xlf:seg-source"/>
- <xsd:element maxOccurs="1" ref="xlf:target"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:context-group"/>
- <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:note"/>
- <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="strict"/>
- </xsd:sequence>
- <xsd:attribute name="match-quality" type="xsd:string" use="optional"/>
- <xsd:attribute name="tool-id" type="xsd:string" use="optional"/>
- <xsd:attribute name="crc" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute ref="xml:lang" use="optional"/>
- <xsd:attribute name="origin" type="xsd:string" use="optional"/>
- <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
- <xsd:attribute default="default" ref="xml:space" use="optional"/>
- <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
- <xsd:attribute name="resname" type="xsd:string" use="optional"/>
- <xsd:attribute name="extradata" type="xsd:string" use="optional"/>
- <xsd:attribute name="extype" type="xsd:string" use="optional"/>
- <xsd:attribute name="help-id" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="menu" type="xsd:string" use="optional"/>
- <xsd:attribute name="menu-option" type="xsd:string" use="optional"/>
- <xsd:attribute name="menu-name" type="xsd:string" use="optional"/>
- <xsd:attribute name="mid" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
- <xsd:attribute name="font" type="xsd:string" use="optional"/>
- <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
- <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="phase-name" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute default="proposal" name="alttranstype" type="xlf:AttrType_alttranstype" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- <xsd:unique name="U_at_segsrc_mid">
- <xsd:selector xpath="./xlf:seg-source/xlf:mrk"/>
- <xsd:field xpath="@mid"/>
- </xsd:unique>
- <xsd:keyref name="KR_at_segsrc_mid" refer="xlf:U_at_segsrc_mid">
- <xsd:selector xpath="./xlf:target/xlf:mrk"/>
- <xsd:field xpath="@mid"/>
- </xsd:keyref>
- </xsd:element>
- <xsd:element name="bin-unit">
- <xsd:complexType>
- <xsd:sequence>
- <xsd:element ref="xlf:bin-source"/>
- <xsd:element minOccurs="0" ref="xlf:bin-target"/>
- <xsd:choice maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:context-group"/>
- <xsd:element ref="xlf:count-group"/>
- <xsd:element ref="xlf:note"/>
- <xsd:element ref="xlf:trans-unit"/>
- </xsd:choice>
- <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="strict"/>
- </xsd:sequence>
- <xsd:attribute name="id" type="xsd:string" use="required"/>
- <xsd:attribute name="mime-type" type="xlf:mime-typeValueList" use="required"/>
- <xsd:attribute name="approved" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attribute default="yes" name="translate" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attribute default="yes" name="reformat" type="xlf:AttrType_reformat" use="optional"/>
- <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
- <xsd:attribute name="resname" type="xsd:string" use="optional"/>
- <xsd:attribute name="phase-name" type="xsd:string" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="bin-source">
- <xsd:complexType>
- <xsd:choice>
- <xsd:element ref="xlf:internal-file"/>
- <xsd:element ref="xlf:external-file"/>
- </xsd:choice>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="bin-target">
- <xsd:complexType>
- <xsd:choice>
- <xsd:element ref="xlf:internal-file"/>
- <xsd:element ref="xlf:external-file"/>
- </xsd:choice>
- <xsd:attribute name="mime-type" type="xlf:mime-typeValueList" use="optional"/>
- <xsd:attribute name="state" type="xlf:AttrType_state" use="optional"/>
- <xsd:attribute name="state-qualifier" type="xlf:AttrType_state-qualifier" use="optional"/>
- <xsd:attribute name="phase-name" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
- <xsd:attribute name="resname" type="xsd:string" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- </xsd:element>
- <!-- Element for inline codes -->
- <xsd:element name="g">
- <xsd:complexType mixed="true">
- <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
- <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
- <xsd:attribute default="yes" name="clone" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="x">
- <xsd:complexType>
- <xsd:attribute name="ctype" type="xlf:AttrType_InlinePlaceholders" use="optional"/>
- <xsd:attribute default="yes" name="clone" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="bx">
- <xsd:complexType>
- <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
- <xsd:attribute default="yes" name="clone" type="xlf:AttrType_YesNo" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="ex">
- <xsd:complexType>
- <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="ph">
- <xsd:complexType mixed="true">
- <xsd:sequence maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:sub"/>
- </xsd:sequence>
- <xsd:attribute name="ctype" type="xlf:AttrType_InlinePlaceholders" use="optional"/>
- <xsd:attribute name="crc" type="xsd:string" use="optional"/>
- <xsd:attribute name="assoc" type="xlf:AttrType_assoc" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="bpt">
- <xsd:complexType mixed="true">
- <xsd:sequence maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:sub"/>
- </xsd:sequence>
- <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
- <xsd:attribute name="crc" type="xsd:string" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="ept">
- <xsd:complexType mixed="true">
- <xsd:sequence maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:sub"/>
- </xsd:sequence>
- <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="crc" type="xsd:string" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="it">
- <xsd:complexType mixed="true">
- <xsd:sequence maxOccurs="unbounded" minOccurs="0">
- <xsd:element ref="xlf:sub"/>
- </xsd:sequence>
- <xsd:attribute name="pos" type="xlf:AttrType_Position" use="required"/>
- <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
- <xsd:attribute name="crc" type="xsd:string" use="optional"/>
- <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="sub">
- <xsd:complexType mixed="true">
- <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
- <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
- <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
- <xsd:attribute name="xid" type="xsd:string" use="optional"/>
- </xsd:complexType>
- </xsd:element>
- <xsd:element name="mrk">
- <xsd:complexType mixed="true">
- <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
- <xsd:attribute name="mtype" type="xlf:AttrType_mtype" use="required"/>
- <xsd:attribute name="mid" type="xsd:NMTOKEN" use="optional"/>
- <xsd:attribute name="comment" type="xsd:string" use="optional"/>
- <xsd:anyAttribute namespace="##other" processContents="strict"/>
- </xsd:complexType>
- </xsd:element>
-</xsd:schema>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/schemas/xliff-core-1.2-transitional.xsd b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/schemas/xliff-core-1.2-transitional.xsd
new file mode 100644
index 0000000..1f38de7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Resources/schemas/xliff-core-1.2-transitional.xsd
@@ -0,0 +1,2261 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+May-19-2004:
+- Changed the <choice> for ElemType_header, moving minOccurs="0" maxOccurs="unbounded" from its elements
+to <choice> itself.
+- Added <choice> for ElemType_trans-unit to allow "any order" for <context-group>, <count-group>, <prop-group>, <note>, and
+<alt-trans>.
+
+Oct-2005
+- updated version info to 1.2
+- equiv-trans attribute to <trans-unit> element
+- merged-trans attribute for <group> element
+- Add the <seg-source> element as optional in the <trans-unit> and <alt-trans> content models, at the same level as <source>
+- Create a new value "seg" for the mtype attribute of the <mrk> element
+- Add mid as an optional attribute for the <alt-trans> element
+
+Nov-14-2005
+- Changed name attribute for <context-group> from required to optional
+- Added extension point at <xliff>
+
+Jan-9-2006
+- Added alttranstype type attribute to <alt-trans>, and values
+
+Jan-10-2006
+- Corrected error with overwritten purposeValueList
+- Corrected name="AttrType_Version", attribute should have been "name"
+
+-->
+<xsd:schema xmlns:xlf="urn:oasis:names:tc:xliff:document:1.2" xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="urn:oasis:names:tc:xliff:document:1.2" xml:lang="en">
+ <!-- Import for xml:lang and xml:space -->
+ <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/>
+ <!-- Attributes Lists -->
+ <xsd:simpleType name="XTend">
+ <xsd:restriction base="xsd:string">
+ <xsd:pattern value="x-[^\s]+"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="context-typeValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'context-type'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="database">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a database content.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="element">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the content of an element within an XML document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="elementtitle">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the name of an element within an XML document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="linenumber">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the line number from the sourcefile (see context-type="sourcefile") where the <source> is found.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="numparams">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a the number of parameters contained within the <source>.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="paramnotes">
+ <xsd:annotation>
+ <xsd:documentation>Indicates notes pertaining to the parameters in the <source>.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="record">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the content of a record within a database.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="recordtitle">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the name of a record within a database.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="sourcefile">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the original source file in the case that multiple files are merged to form the original file from which the XLIFF file is created. This differs from the original <file> attribute in that this sourcefile is one of many that make up that file.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="count-typeValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'count-type'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="num-usages">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the count units are items that are used X times in a certain context; example: this is a reusable text unit which is used 42 times in other texts.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="repetition">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the count units are translation units existing already in the same document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="total">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a total count.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="InlineDelimitersValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'ctype' when used other elements than <ph> or <x>.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="bold">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a run of bolded text.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="italic">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a run of text in italics.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="underlined">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a run of underlined text.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="link">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a run of hyper-text.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="InlinePlaceholdersValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'ctype' when used with <ph> or <x>.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="image">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a inline image.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="pb">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a page break.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="lb">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a line break.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="mime-typeValueList">
+ <xsd:restriction base="xsd:string">
+ <xsd:pattern value="(text|multipart|message|application|image|audio|video|model)(/.+)*"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="datatypeValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'datatype'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="asp">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Active Server Page data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="c">
+ <xsd:annotation>
+ <xsd:documentation>Indicates C source file data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="cdf">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Channel Definition Format (CDF) data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="cfm">
+ <xsd:annotation>
+ <xsd:documentation>Indicates ColdFusion data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="cpp">
+ <xsd:annotation>
+ <xsd:documentation>Indicates C++ source file data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="csharp">
+ <xsd:annotation>
+ <xsd:documentation>Indicates C-Sharp data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="cstring">
+ <xsd:annotation>
+ <xsd:documentation>Indicates strings from C, ASM, and driver files data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="csv">
+ <xsd:annotation>
+ <xsd:documentation>Indicates comma-separated values data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="database">
+ <xsd:annotation>
+ <xsd:documentation>Indicates database data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="documentfooter">
+ <xsd:annotation>
+ <xsd:documentation>Indicates portions of document that follows data and contains metadata.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="documentheader">
+ <xsd:annotation>
+ <xsd:documentation>Indicates portions of document that precedes data and contains metadata.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="filedialog">
+ <xsd:annotation>
+ <xsd:documentation>Indicates data from standard UI file operations dialogs (e.g., Open, Save, Save As, Export, Import).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="form">
+ <xsd:annotation>
+ <xsd:documentation>Indicates standard user input screen data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="html">
+ <xsd:annotation>
+ <xsd:documentation>Indicates HyperText Markup Language (HTML) data - document instance.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="htmlbody">
+ <xsd:annotation>
+ <xsd:documentation>Indicates content within an HTML document’s <body> element.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="ini">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Windows INI file data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="interleaf">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Interleaf data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="javaclass">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Java source file data (extension '.java').</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="javapropertyresourcebundle">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Java property resource bundle data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="javalistresourcebundle">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Java list resource bundle data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="javascript">
+ <xsd:annotation>
+ <xsd:documentation>Indicates JavaScript source file data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="jscript">
+ <xsd:annotation>
+ <xsd:documentation>Indicates JScript source file data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="layout">
+ <xsd:annotation>
+ <xsd:documentation>Indicates information relating to formatting.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="lisp">
+ <xsd:annotation>
+ <xsd:documentation>Indicates LISP source file data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="margin">
+ <xsd:annotation>
+ <xsd:documentation>Indicates information relating to margin formats.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="menufile">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a file containing menu.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="messagefile">
+ <xsd:annotation>
+ <xsd:documentation>Indicates numerically identified string table.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="mif">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Maker Interchange Format (MIF) data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="mimetype">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the datatype attribute value is a MIME Type value and is defined in the mime-type attribute.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="mo">
+ <xsd:annotation>
+ <xsd:documentation>Indicates GNU Machine Object data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="msglib">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Message Librarian strings created by Novell's Message Librarian Tool.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="pagefooter">
+ <xsd:annotation>
+ <xsd:documentation>Indicates information to be displayed at the bottom of each page of a document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="pageheader">
+ <xsd:annotation>
+ <xsd:documentation>Indicates information to be displayed at the top of each page of a document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="parameters">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a list of property values (e.g., settings within INI files or preferences dialog).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="pascal">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Pascal source file data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="php">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Hypertext Preprocessor data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="plaintext">
+ <xsd:annotation>
+ <xsd:documentation>Indicates plain text file (no formatting other than, possibly, wrapping).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="po">
+ <xsd:annotation>
+ <xsd:documentation>Indicates GNU Portable Object file.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="report">
+ <xsd:annotation>
+ <xsd:documentation>Indicates dynamically generated user defined document. e.g. Oracle Report, Crystal Report, etc.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="resources">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Windows .NET binary resources.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="resx">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Windows .NET Resources.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rtf">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Rich Text Format (RTF) data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="sgml">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Standard Generalized Markup Language (SGML) data - document instance.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="sgmldtd">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Standard Generalized Markup Language (SGML) data - Document Type Definition (DTD).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="svg">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Scalable Vector Graphic (SVG) data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="vbscript">
+ <xsd:annotation>
+ <xsd:documentation>Indicates VisualBasic Script source file.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="warning">
+ <xsd:annotation>
+ <xsd:documentation>Indicates warning message.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="winres">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Windows (Win32) resources (i.e. resources extracted from an RC script, a message file, or a compiled file).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="xhtml">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Extensible HyperText Markup Language (XHTML) data - document instance.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="xml">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Extensible Markup Language (XML) data - document instance.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="xmldtd">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Extensible Markup Language (XML) data - Document Type Definition (DTD).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="xsl">
+ <xsd:annotation>
+ <xsd:documentation>Indicates Extensible Stylesheet Language (XSL) data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="xul">
+ <xsd:annotation>
+ <xsd:documentation>Indicates XUL elements.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="mtypeValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'mtype'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="abbrev">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the marked text is an abbreviation.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="abbreviated-form">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.8: A term resulting from the omission of any part of the full term while designating the same concept.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="abbreviation">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.8.1: An abbreviated form of a simple term resulting from the omission of some of its letters (e.g. 'adj.' for 'adjective').</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="acronym">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.8.4: An abbreviated form of a term made up of letters from the full form of a multiword term strung together into a sequence pronounced only syllabically (e.g. 'radar' for 'radio detecting and ranging').</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="appellation">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620: A proper-name term, such as the name of an agency or other proper entity.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="collocation">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.18.1: A recurrent word combination characterized by cohesion in that the components of the collocation must co-occur within an utterance or series of utterances, even though they do not necessarily have to maintain immediate proximity to one another.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="common-name">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.5: A synonym for an international scientific term that is used in general discourse in a given language.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="datetime">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the marked text is a date and/or time.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="equation">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.15: An expression used to represent a concept based on a statement that two mathematical expressions are, for instance, equal as identified by the equal sign (=), or assigned to one another by a similar sign.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="expanded-form">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.7: The complete representation of a term for which there is an abbreviated form.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="formula">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.14: Figures, symbols or the like used to express a concept briefly, such as a mathematical or chemical formula.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="head-term">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.1: The concept designation that has been chosen to head a terminological record.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="initialism">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.8.3: An abbreviated form of a term consisting of some of the initial letters of the words making up a multiword term or the term elements making up a compound term when these letters are pronounced individually (e.g. 'BSE' for 'bovine spongiform encephalopathy').</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="international-scientific-term">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.4: A term that is part of an international scientific nomenclature as adopted by an appropriate scientific body.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="internationalism">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.6: A term that has the same or nearly identical orthographic or phonemic form in many languages.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="logical-expression">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.16: An expression used to represent a concept based on mathematical or logical relations, such as statements of inequality, set relationships, Boolean operations, and the like.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="materials-management-unit">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.17: A unit to track object.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="name">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the marked text is a name.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="near-synonym">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.3: A term that represents the same or a very similar concept as another term in the same language, but for which interchangeability is limited to some contexts and inapplicable in others.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="part-number">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.17.2: A unique alphanumeric designation assigned to an object in a manufacturing system.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="phrase">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the marked text is a phrase.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="phraseological-unit">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.18: Any group of two or more words that form a unit, the meaning of which frequently cannot be deduced based on the combined sense of the words making up the phrase.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="protected">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the marked text should not be translated.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="romanized-form">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.12: A form of a term resulting from an operation whereby non-Latin writing systems are converted to the Latin alphabet.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="seg">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the marked text represents a segment.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="set-phrase">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.18.2: A fixed, lexicalized phrase.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="short-form">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.8.2: A variant of a multiword term that includes fewer words than the full form of the term (e.g. 'Group of Twenty-four' for 'Intergovernmental Group of Twenty-four on International Monetary Affairs').</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="sku">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.17.1: Stock keeping unit, an inventory item identified by a unique alphanumeric designation assigned to an object in an inventory control system.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="standard-text">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.19: A fixed chunk of recurring text.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="symbol">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.13: A designation of a concept by letters, numerals, pictograms or any combination thereof.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="synonym">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.2: Any term that represents the same or a very similar concept as the main entry term in a term entry.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="synonymous-phrase">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.18.3: Phraseological unit in a language that expresses the same semantic content as another phrase in that same language.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="term">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the marked text is a term.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="transcribed-form">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.11: A form of a term resulting from an operation whereby the characters of one writing system are represented by characters from another writing system, taking into account the pronunciation of the characters converted.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="transliterated-form">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.10: A form of a term resulting from an operation whereby the characters of an alphabetic writing system are represented by characters from another alphabetic writing system.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="truncated-term">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.8.5: An abbreviated form of a term resulting from the omission of one or more term elements or syllables (e.g. 'flu' for 'influenza').</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="variant">
+ <xsd:annotation>
+ <xsd:documentation>ISO-12620 2.1.9: One of the alternate forms of a term.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="restypeValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'restype'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="auto3state">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC AUTO3STATE control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="autocheckbox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC AUTOCHECKBOX control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="autoradiobutton">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC AUTORADIOBUTTON control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="bedit">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC BEDIT control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="bitmap">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a bitmap, for example a BITMAP resource in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="button">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a button object, for example a BUTTON control Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="caption">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a caption, such as the caption of a dialog box.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="cell">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the cell in a table, for example the content of the <td> element in HTML.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="checkbox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates check box object, for example a CHECKBOX control in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="checkboxmenuitem">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a menu item with an associated checkbox.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="checkedlistbox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a list box, but with a check-box for each item.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="colorchooser">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a color selection dialog.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="combobox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a combination of edit box and listbox object, for example a COMBOBOX control in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="comboboxexitem">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an initialization entry of an extended combobox DLGINIT resource block. (code 0x1234).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="comboboxitem">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an initialization entry of a combobox DLGINIT resource block (code 0x0403).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="component">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a UI base class element that cannot be represented by any other element.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="contextmenu">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a context menu.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="ctext">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC CTEXT control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="cursor">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a cursor, for example a CURSOR resource in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="datetimepicker">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a date/time picker.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="defpushbutton">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC DEFPUSHBUTTON control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="dialog">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a dialog box.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="dlginit">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC DLGINIT resource block.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="edit">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an edit box object, for example an EDIT control in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="file">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a filename.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="filechooser">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a file dialog.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="fn">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a footnote.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="font">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a font name.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="footer">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a footer.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="frame">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a frame object.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="grid">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a XUL grid element.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="groupbox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a groupbox object, for example a GROUPBOX control in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="header">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a header item.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="heading">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a heading, such has the content of <h1>, <h2>, etc. in HTML.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="hedit">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC HEDIT control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="hscrollbar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a horizontal scrollbar.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="icon">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an icon, for example an ICON resource in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="iedit">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC IEDIT control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="keywords">
+ <xsd:annotation>
+ <xsd:documentation>Indicates keyword list, such as the content of the Keywords meta-data in HTML, or a K footnote in WinHelp RTF.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="label">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a label object.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="linklabel">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a label that is also a HTML link (not necessarily a URL).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="list">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a list (a group of list-items, for example an <ol> or <ul> element in HTML).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="listbox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a listbox object, for example an LISTBOX control in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="listitem">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an list item (an entry in a list).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="ltext">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC LTEXT control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="menu">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a menu (a group of menu-items).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="menubar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a toolbar containing one or more tope level menus.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="menuitem">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a menu item (an entry in a menu).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="menuseparator">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a XUL menuseparator element.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="message">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a message, for example an entry in a MESSAGETABLE resource in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="monthcalendar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a calendar control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="numericupdown">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an edit box beside a spin control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="panel">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a catch all for rectangular areas.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="popupmenu">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a standalone menu not necessarily associated with a menubar.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="pushbox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a pushbox object, for example a PUSHBOX control in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="pushbutton">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC PUSHBUTTON control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="radio">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a radio button object.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="radiobuttonmenuitem">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a menuitem with associated radio button.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rcdata">
+ <xsd:annotation>
+ <xsd:documentation>Indicates raw data resources for an application.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="row">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a row in a table.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rtext">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC RTEXT control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="scrollpane">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a user navigable container used to show a portion of a document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="separator">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a generic divider object (e.g. menu group separator).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="shortcut">
+ <xsd:annotation>
+ <xsd:documentation>Windows accelerators, shortcuts in resource or property files.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="spinner">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a UI control to indicate process activity but not progress.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="splitter">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a splitter bar.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="state3">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC STATE3 control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="statusbar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a window for providing feedback to the users, like 'read-only', etc.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="string">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a string, for example an entry in a STRINGTABLE resource in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="tabcontrol">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a layers of controls with a tab to select layers.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="table">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a display and edits regular two-dimensional tables of cells.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="textbox">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a XUL textbox element.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="togglebutton">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a UI button that can be toggled to on or off state.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="toolbar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an array of controls, usually buttons.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="tooltip">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a pop up tool tip text.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="trackbar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a bar with a pointer indicating a position within a certain range.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="tree">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a control that displays a set of hierarchical data.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="uri">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a URI (URN or URL).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="userbutton">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a Windows RC USERBUTTON control.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="usercontrol">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a user-defined control like CONTROL control in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="var">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the text of a variable.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="versioninfo">
+ <xsd:annotation>
+ <xsd:documentation>Indicates version information about a resource like VERSIONINFO in Windows.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="vscrollbar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a vertical scrollbar.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="window">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a graphical window.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="size-unitValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'size-unit'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="byte">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in 8-bit bytes.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="char">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in Unicode characters.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="col">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in columns. Used for HTML text area.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="cm">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in centimeters.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="dlgunit">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in dialog units, as defined in Windows resources.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="em">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in 'font-size' units (as defined in CSS).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="ex">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in 'x-height' units (as defined in CSS).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="glyph">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in glyphs. A glyph is considered to be one or more combined Unicode characters that represent a single displayable text character. Sometimes referred to as a 'grapheme cluster'</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="in">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in inches.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="mm">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in millimeters.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="percent">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in percentage.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="pixel">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in pixels.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="point">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in point.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="row">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a size in rows. Used for HTML text area.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="stateValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'state'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="final">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the terminating state.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="needs-adaptation">
+ <xsd:annotation>
+ <xsd:documentation>Indicates only non-textual information needs adaptation.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="needs-l10n">
+ <xsd:annotation>
+ <xsd:documentation>Indicates both text and non-textual information needs adaptation.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="needs-review-adaptation">
+ <xsd:annotation>
+ <xsd:documentation>Indicates only non-textual information needs review.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="needs-review-l10n">
+ <xsd:annotation>
+ <xsd:documentation>Indicates both text and non-textual information needs review.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="needs-review-translation">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that only the text of the item needs to be reviewed.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="needs-translation">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the item needs to be translated.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="new">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the item is new. For example, translation units that were not in a previous version of the document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="signed-off">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that changes are reviewed and approved.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="translated">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the item has been translated.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="state-qualifierValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'state-qualifier'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="exact-match">
+ <xsd:annotation>
+ <xsd:documentation>Indicates an exact match. An exact match occurs when a source text of a segment is exactly the same as the source text of a segment that was translated previously.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="fuzzy-match">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a fuzzy match. A fuzzy match occurs when a source text of a segment is very similar to the source text of a segment that was translated previously (e.g. when the difference is casing, a few changed words, white-space discripancy, etc.).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="id-match">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a match based on matching IDs (in addition to matching text).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="leveraged-glossary">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a translation derived from a glossary.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="leveraged-inherited">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a translation derived from existing translation.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="leveraged-mt">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a translation derived from machine translation.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="leveraged-repository">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a translation derived from a translation repository.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="leveraged-tm">
+ <xsd:annotation>
+ <xsd:documentation>Indicates a translation derived from a translation memory.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="mt-suggestion">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the translation is suggested by machine translation.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rejected-grammar">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the item has been rejected because of incorrect grammar.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rejected-inaccurate">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the item has been rejected because it is incorrect.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rejected-length">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the item has been rejected because it is too long or too short.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rejected-spelling">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the item has been rejected because of incorrect spelling.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="tm-suggestion">
+ <xsd:annotation>
+ <xsd:documentation>Indicates the translation is suggested by translation memory.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="unitValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'unit'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="word">
+ <xsd:annotation>
+ <xsd:documentation>Refers to words.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="page">
+ <xsd:annotation>
+ <xsd:documentation>Refers to pages.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="trans-unit">
+ <xsd:annotation>
+ <xsd:documentation>Refers to <trans-unit> elements.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="bin-unit">
+ <xsd:annotation>
+ <xsd:documentation>Refers to <bin-unit> elements.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="glyph">
+ <xsd:annotation>
+ <xsd:documentation>Refers to glyphs.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="item">
+ <xsd:annotation>
+ <xsd:documentation>Refers to <trans-unit> and/or <bin-unit> elements.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="instance">
+ <xsd:annotation>
+ <xsd:documentation>Refers to the occurrences of instances defined by the count-type value.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="character">
+ <xsd:annotation>
+ <xsd:documentation>Refers to characters.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="line">
+ <xsd:annotation>
+ <xsd:documentation>Refers to lines.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="sentence">
+ <xsd:annotation>
+ <xsd:documentation>Refers to sentences.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="paragraph">
+ <xsd:annotation>
+ <xsd:documentation>Refers to paragraphs.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="segment">
+ <xsd:annotation>
+ <xsd:documentation>Refers to segments.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="placeable">
+ <xsd:annotation>
+ <xsd:documentation>Refers to placeables (inline elements).</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="priorityValueList">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'priority'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:positiveInteger">
+ <xsd:enumeration value="1">
+ <xsd:annotation>
+ <xsd:documentation>Highest priority.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="2">
+ <xsd:annotation>
+ <xsd:documentation>High priority.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="3">
+ <xsd:annotation>
+ <xsd:documentation>High priority, but not as important as 2.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="4">
+ <xsd:annotation>
+ <xsd:documentation>High priority, but not as important as 3.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="5">
+ <xsd:annotation>
+ <xsd:documentation>Medium priority, but more important than 6.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="6">
+ <xsd:annotation>
+ <xsd:documentation>Medium priority, but less important than 5.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="7">
+ <xsd:annotation>
+ <xsd:documentation>Low priority, but more important than 8.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="8">
+ <xsd:annotation>
+ <xsd:documentation>Low priority, but more important than 9.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="9">
+ <xsd:annotation>
+ <xsd:documentation>Low priority.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="10">
+ <xsd:annotation>
+ <xsd:documentation>Lowest priority.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="reformatValueYesNo">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="yes">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that all properties can be reformatted. This value must be used alone.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="no">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that no properties should be reformatted. This value must be used alone.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="reformatValueList">
+ <xsd:list>
+ <xsd:simpleType>
+ <xsd:union memberTypes="xlf:XTend">
+ <xsd:simpleType>
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="coord">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that all information in the coord attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="coord-x">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the x information in the coord attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="coord-y">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the y information in the coord attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="coord-cx">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the cx information in the coord attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="coord-cy">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the cy information in the coord attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="font">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that all the information in the font attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="font-name">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the name information in the font attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="font-size">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the size information in the font attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="font-weight">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the weight information in the font attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="css-style">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the information in the css-style attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="style">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the information in the style attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="ex-style">
+ <xsd:annotation>
+ <xsd:documentation>This value indicates that the information in the exstyle attribute can be modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ </xsd:union>
+ </xsd:simpleType>
+ </xsd:list>
+ </xsd:simpleType>
+ <xsd:simpleType name="purposeValueList">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="information">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the context is informational in nature, specifying for example, how a term should be translated. Thus, should be displayed to anyone editing the XLIFF document.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="location">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the context-group is used to specify where the term was found in the translatable source. Thus, it is not displayed.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="match">
+ <xsd:annotation>
+ <xsd:documentation>Indicates that the context information should be used during translation memory lookups. Thus, it is not displayed.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="alttranstypeValueList">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="proposal">
+ <xsd:annotation>
+ <xsd:documentation>Represents a translation proposal from a translation memory or other resource.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="previous-version">
+ <xsd:annotation>
+ <xsd:documentation>Represents a previous version of the target element.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="rejected">
+ <xsd:annotation>
+ <xsd:documentation>Represents a rejected version of the target element.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="reference">
+ <xsd:annotation>
+ <xsd:documentation>Represents a translation to be used for reference purposes only, for example from a related product or a different language.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ <xsd:enumeration value="accepted">
+ <xsd:annotation>
+ <xsd:documentation>Represents a proposed translation that was used for the translation of the trans-unit, possibly modified.</xsd:documentation>
+ </xsd:annotation>
+ </xsd:enumeration>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <!-- Other Types -->
+ <xsd:complexType name="ElemType_ExternalReference">
+ <xsd:choice>
+ <xsd:element ref="xlf:internal-file"/>
+ <xsd:element ref="xlf:external-file"/>
+ </xsd:choice>
+ </xsd:complexType>
+ <xsd:simpleType name="AttrType_purpose">
+ <xsd:list>
+ <xsd:simpleType>
+ <xsd:union memberTypes="xlf:purposeValueList xlf:XTend"/>
+ </xsd:simpleType>
+ </xsd:list>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_datatype">
+ <xsd:union memberTypes="xlf:datatypeValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_restype">
+ <xsd:union memberTypes="xlf:restypeValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_alttranstype">
+ <xsd:union memberTypes="xlf:alttranstypeValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_context-type">
+ <xsd:union memberTypes="xlf:context-typeValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_state">
+ <xsd:union memberTypes="xlf:stateValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_state-qualifier">
+ <xsd:union memberTypes="xlf:state-qualifierValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_count-type">
+ <xsd:union memberTypes="xlf:restypeValueList xlf:count-typeValueList xlf:datatypeValueList xlf:stateValueList xlf:state-qualifierValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_InlineDelimiters">
+ <xsd:union memberTypes="xlf:InlineDelimitersValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_InlinePlaceholders">
+ <xsd:union memberTypes="xlf:InlinePlaceholdersValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_size-unit">
+ <xsd:union memberTypes="xlf:size-unitValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_mtype">
+ <xsd:union memberTypes="xlf:mtypeValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_unit">
+ <xsd:union memberTypes="xlf:unitValueList xlf:XTend"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_priority">
+ <xsd:union memberTypes="xlf:priorityValueList"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_reformat">
+ <xsd:union memberTypes="xlf:reformatValueYesNo xlf:reformatValueList"/>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_YesNo">
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="yes"/>
+ <xsd:enumeration value="no"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_Position">
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="open"/>
+ <xsd:enumeration value="close"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_assoc">
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="preceding"/>
+ <xsd:enumeration value="following"/>
+ <xsd:enumeration value="both"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_annotates">
+ <xsd:restriction base="xsd:NMTOKEN">
+ <xsd:enumeration value="source"/>
+ <xsd:enumeration value="target"/>
+ <xsd:enumeration value="general"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_Coordinates">
+ <xsd:annotation>
+ <xsd:documentation>Values for the attribute 'coord'.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:string">
+ <xsd:pattern value="(-?\d+|#);(-?\d+|#);(-?\d+|#);(-?\d+|#)"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <xsd:simpleType name="AttrType_Version">
+ <xsd:annotation>
+ <xsd:documentation>Version values: 1.0 and 1.1 are allowed for backward compatibility.</xsd:documentation>
+ </xsd:annotation>
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="1.2"/>
+ <xsd:enumeration value="1.1"/>
+ <xsd:enumeration value="1.0"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+ <!-- Groups -->
+ <xsd:group name="ElemGroup_TextContent">
+ <xsd:choice>
+ <xsd:element ref="xlf:g"/>
+ <xsd:element ref="xlf:bpt"/>
+ <xsd:element ref="xlf:ept"/>
+ <xsd:element ref="xlf:ph"/>
+ <xsd:element ref="xlf:it"/>
+ <xsd:element ref="xlf:mrk"/>
+ <xsd:element ref="xlf:x"/>
+ <xsd:element ref="xlf:bx"/>
+ <xsd:element ref="xlf:ex"/>
+ </xsd:choice>
+ </xsd:group>
+ <xsd:attributeGroup name="AttrGroup_TextContent">
+ <xsd:attribute name="id" type="xsd:string" use="required"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="xid" type="xsd:string" use="optional"/>
+ <xsd:attribute name="equiv-text" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:attributeGroup>
+ <!-- XLIFF Structure -->
+ <xsd:element name="xliff">
+ <xsd:complexType>
+ <xsd:sequence maxOccurs="unbounded">
+ <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="skip"/>
+ <xsd:element ref="xlf:file"/>
+ </xsd:sequence>
+ <xsd:attribute name="version" type="xlf:AttrType_Version" use="required"/>
+ <xsd:attribute ref="xml:lang" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="file">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element minOccurs="0" ref="xlf:header"/>
+ <xsd:element ref="xlf:body"/>
+ </xsd:sequence>
+ <xsd:attribute name="original" type="xsd:string" use="required"/>
+ <xsd:attribute name="source-language" type="xsd:language" use="required"/>
+ <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="required"/>
+ <xsd:attribute name="tool-id" type="xsd:string" use="optional"/>
+ <xsd:attribute default="manual" name="tool" type="xsd:string" use="optional"/>
+ <xsd:attribute name="date" type="xsd:dateTime" use="optional"/>
+ <xsd:attribute ref="xml:space" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="category" type="xsd:string" use="optional"/>
+ <xsd:attribute name="target-language" type="xsd:language" use="optional"/>
+ <xsd:attribute name="product-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="product-version" type="xsd:string" use="optional"/>
+ <xsd:attribute name="build-num" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ <xsd:unique name="U_group_id">
+ <xsd:selector xpath=".//xlf:group"/>
+ <xsd:field xpath="@id"/>
+ </xsd:unique>
+ <xsd:key name="K_unit_id">
+ <xsd:selector xpath=".//xlf:trans-unit|.//xlf:bin-unit"/>
+ <xsd:field xpath="@id"/>
+ </xsd:key>
+ <xsd:keyref name="KR_unit_id" refer="xlf:K_unit_id">
+ <xsd:selector xpath=".//bpt|.//ept|.//it|.//ph|.//g|.//x|.//bx|.//ex|.//sub"/>
+ <xsd:field xpath="@xid"/>
+ </xsd:keyref>
+ <xsd:key name="K_tool-id">
+ <xsd:selector xpath="xlf:header/xlf:tool"/>
+ <xsd:field xpath="@tool-id"/>
+ </xsd:key>
+ <xsd:keyref name="KR_file_tool-id" refer="xlf:K_tool-id">
+ <xsd:selector xpath="."/>
+ <xsd:field xpath="@tool-id"/>
+ </xsd:keyref>
+ <xsd:keyref name="KR_phase_tool-id" refer="xlf:K_tool-id">
+ <xsd:selector xpath="xlf:header/xlf:phase-group/xlf:phase"/>
+ <xsd:field xpath="@tool-id"/>
+ </xsd:keyref>
+ <xsd:keyref name="KR_alt-trans_tool-id" refer="xlf:K_tool-id">
+ <xsd:selector xpath=".//xlf:trans-unit/xlf:alt-trans"/>
+ <xsd:field xpath="@tool-id"/>
+ </xsd:keyref>
+ <xsd:key name="K_count-group_name">
+ <xsd:selector xpath=".//xlf:count-group"/>
+ <xsd:field xpath="@name"/>
+ </xsd:key>
+ <xsd:unique name="U_context-group_name">
+ <xsd:selector xpath=".//xlf:context-group"/>
+ <xsd:field xpath="@name"/>
+ </xsd:unique>
+ <xsd:key name="K_phase-name">
+ <xsd:selector xpath="xlf:header/xlf:phase-group/xlf:phase"/>
+ <xsd:field xpath="@phase-name"/>
+ </xsd:key>
+ <xsd:keyref name="KR_phase-name" refer="xlf:K_phase-name">
+ <xsd:selector xpath=".//xlf:count|.//xlf:trans-unit|.//xlf:target|.//bin-unit|.//bin-target"/>
+ <xsd:field xpath="@phase-name"/>
+ </xsd:keyref>
+ <xsd:unique name="U_uid">
+ <xsd:selector xpath=".//xlf:external-file"/>
+ <xsd:field xpath="@uid"/>
+ </xsd:unique>
+ </xsd:element>
+ <xsd:element name="header">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element minOccurs="0" name="skl" type="xlf:ElemType_ExternalReference"/>
+ <xsd:element minOccurs="0" ref="xlf:phase-group"/>
+ <xsd:choice maxOccurs="unbounded" minOccurs="0">
+ <xsd:element name="glossary" type="xlf:ElemType_ExternalReference"/>
+ <xsd:element name="reference" type="xlf:ElemType_ExternalReference"/>
+ <xsd:element ref="xlf:count-group"/>
+ <xsd:element ref="xlf:prop-group"/>
+ <xsd:element ref="xlf:note"/>
+ <xsd:element ref="xlf:tool"/>
+ </xsd:choice>
+ <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="skip"/>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="internal-file">
+ <xsd:complexType>
+ <xsd:simpleContent>
+ <xsd:extension base="xsd:string">
+ <xsd:attribute name="form" type="xsd:string"/>
+ <xsd:attribute name="crc" type="xsd:NMTOKEN"/>
+ </xsd:extension>
+ </xsd:simpleContent>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="external-file">
+ <xsd:complexType>
+ <xsd:attribute name="href" type="xsd:string" use="required"/>
+ <xsd:attribute name="crc" type="xsd:NMTOKEN"/>
+ <xsd:attribute name="uid" type="xsd:NMTOKEN"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="note">
+ <xsd:complexType>
+ <xsd:simpleContent>
+ <xsd:extension base="xsd:string">
+ <xsd:attribute ref="xml:lang" use="optional"/>
+ <xsd:attribute default="1" name="priority" type="xlf:AttrType_priority" use="optional"/>
+ <xsd:attribute name="from" type="xsd:string" use="optional"/>
+ <xsd:attribute default="general" name="annotates" type="xlf:AttrType_annotates" use="optional"/>
+ </xsd:extension>
+ </xsd:simpleContent>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="phase-group">
+ <xsd:complexType>
+ <xsd:sequence maxOccurs="unbounded">
+ <xsd:element ref="xlf:phase"/>
+ </xsd:sequence>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="phase">
+ <xsd:complexType>
+ <xsd:sequence maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:note"/>
+ </xsd:sequence>
+ <xsd:attribute name="phase-name" type="xsd:string" use="required"/>
+ <xsd:attribute name="process-name" type="xsd:string" use="required"/>
+ <xsd:attribute name="company-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="tool-id" type="xsd:string" use="optional"/>
+ <xsd:attribute name="tool" type="xsd:string" use="optional"/>
+ <xsd:attribute name="date" type="xsd:dateTime" use="optional"/>
+ <xsd:attribute name="job-id" type="xsd:string" use="optional"/>
+ <xsd:attribute name="contact-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="contact-email" type="xsd:string" use="optional"/>
+ <xsd:attribute name="contact-phone" type="xsd:string" use="optional"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="count-group">
+ <xsd:complexType>
+ <xsd:sequence maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:count"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="required"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="count">
+ <xsd:complexType>
+ <xsd:simpleContent>
+ <xsd:extension base="xsd:string">
+ <xsd:attribute name="count-type" type="xlf:AttrType_count-type" use="optional"/>
+ <xsd:attribute name="phase-name" type="xsd:string" use="optional"/>
+ <xsd:attribute default="word" name="unit" type="xlf:AttrType_unit" use="optional"/>
+ </xsd:extension>
+ </xsd:simpleContent>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="context-group">
+ <xsd:complexType>
+ <xsd:sequence maxOccurs="unbounded">
+ <xsd:element ref="xlf:context"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="crc" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="purpose" type="xlf:AttrType_purpose" use="optional"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="context">
+ <xsd:complexType>
+ <xsd:simpleContent>
+ <xsd:extension base="xsd:string">
+ <xsd:attribute name="context-type" type="xlf:AttrType_context-type" use="required"/>
+ <xsd:attribute default="no" name="match-mandatory" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attribute name="crc" type="xsd:NMTOKEN" use="optional"/>
+ </xsd:extension>
+ </xsd:simpleContent>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="prop-group">
+ <xsd:complexType>
+ <xsd:sequence maxOccurs="unbounded">
+ <xsd:element ref="xlf:prop"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="optional"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="prop">
+ <xsd:complexType>
+ <xsd:simpleContent>
+ <xsd:extension base="xsd:string">
+ <xsd:attribute name="prop-type" type="xsd:string" use="required"/>
+ <xsd:attribute ref="xml:lang" use="optional"/>
+ </xsd:extension>
+ </xsd:simpleContent>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="tool">
+ <xsd:complexType mixed="true">
+ <xsd:sequence>
+ <xsd:any namespace="##any" processContents="skip" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="tool-id" type="xsd:string" use="required"/>
+ <xsd:attribute name="tool-name" type="xsd:string" use="required"/>
+ <xsd:attribute name="tool-version" type="xsd:string" use="optional"/>
+ <xsd:attribute name="tool-company" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="body">
+ <xsd:complexType>
+ <xsd:choice maxOccurs="unbounded" minOccurs="0">
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:group"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:trans-unit"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:bin-unit"/>
+ </xsd:choice>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="group">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:sequence>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:context-group"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:count-group"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:prop-group"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:note"/>
+ <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="skip"/>
+ </xsd:sequence>
+ <xsd:choice maxOccurs="unbounded">
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:group"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:trans-unit"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:bin-unit"/>
+ </xsd:choice>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:string" use="optional"/>
+ <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
+ <xsd:attribute default="default" ref="xml:space" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
+ <xsd:attribute name="resname" type="xsd:string" use="optional"/>
+ <xsd:attribute name="extradata" type="xsd:string" use="optional"/>
+ <xsd:attribute name="extype" type="xsd:string" use="optional"/>
+ <xsd:attribute name="help-id" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="menu" type="xsd:string" use="optional"/>
+ <xsd:attribute name="menu-option" type="xsd:string" use="optional"/>
+ <xsd:attribute name="menu-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
+ <xsd:attribute name="font" type="xsd:string" use="optional"/>
+ <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
+ <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute default="yes" name="translate" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attribute default="yes" name="reformat" type="xlf:AttrType_reformat" use="optional"/>
+ <xsd:attribute default="pixel" name="size-unit" type="xlf:AttrType_size-unit" use="optional"/>
+ <xsd:attribute name="maxwidth" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="minwidth" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="maxheight" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="minheight" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="maxbytes" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="minbytes" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="charclass" type="xsd:string" use="optional"/>
+ <xsd:attribute default="no" name="merged-trans" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="trans-unit">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element ref="xlf:source"/>
+ <xsd:element minOccurs="0" ref="xlf:seg-source"/>
+ <xsd:element minOccurs="0" ref="xlf:target"/>
+ <xsd:choice maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:context-group"/>
+ <xsd:element ref="xlf:count-group"/>
+ <xsd:element ref="xlf:prop-group"/>
+ <xsd:element ref="xlf:note"/>
+ <xsd:element ref="xlf:alt-trans"/>
+ </xsd:choice>
+ <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="skip"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:string" use="required"/>
+ <xsd:attribute name="approved" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attribute default="yes" name="translate" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attribute default="yes" name="reformat" type="xlf:AttrType_reformat" use="optional"/>
+ <xsd:attribute default="default" ref="xml:space" use="optional"/>
+ <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="phase-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
+ <xsd:attribute name="resname" type="xsd:string" use="optional"/>
+ <xsd:attribute name="extradata" type="xsd:string" use="optional"/>
+ <xsd:attribute name="extype" type="xsd:string" use="optional"/>
+ <xsd:attribute name="help-id" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="menu" type="xsd:string" use="optional"/>
+ <xsd:attribute name="menu-option" type="xsd:string" use="optional"/>
+ <xsd:attribute name="menu-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
+ <xsd:attribute name="font" type="xsd:string" use="optional"/>
+ <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
+ <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute default="pixel" name="size-unit" type="xlf:AttrType_size-unit" use="optional"/>
+ <xsd:attribute name="maxwidth" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="minwidth" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="maxheight" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="minheight" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="maxbytes" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="minbytes" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="charclass" type="xsd:string" use="optional"/>
+ <xsd:attribute default="yes" name="merged-trans" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ <xsd:unique name="U_tu_segsrc_mid">
+ <xsd:selector xpath="./xlf:seg-source/xlf:mrk"/>
+ <xsd:field xpath="@mid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_tu_segsrc_mid" refer="xlf:U_tu_segsrc_mid">
+ <xsd:selector xpath="./xlf:target/xlf:mrk|./xlf:alt-trans"/>
+ <xsd:field xpath="@mid"/>
+ </xsd:keyref>
+ </xsd:element>
+ <xsd:element name="source">
+ <xsd:complexType mixed="true">
+ <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
+ <xsd:attribute ref="xml:lang" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ <xsd:unique name="U_source_bpt_rid">
+ <xsd:selector xpath=".//xlf:bpt"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_source_ept_rid" refer="xlf:U_source_bpt_rid">
+ <xsd:selector xpath=".//xlf:ept"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:keyref>
+ <xsd:unique name="U_source_bx_rid">
+ <xsd:selector xpath=".//xlf:bx"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_source_ex_rid" refer="xlf:U_source_bx_rid">
+ <xsd:selector xpath=".//xlf:ex"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:keyref>
+ </xsd:element>
+ <xsd:element name="seg-source">
+ <xsd:complexType mixed="true">
+ <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
+ <xsd:attribute ref="xml:lang" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ <xsd:unique name="U_segsrc_bpt_rid">
+ <xsd:selector xpath=".//xlf:bpt"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_segsrc_ept_rid" refer="xlf:U_segsrc_bpt_rid">
+ <xsd:selector xpath=".//xlf:ept"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:keyref>
+ <xsd:unique name="U_segsrc_bx_rid">
+ <xsd:selector xpath=".//xlf:bx"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_segsrc_ex_rid" refer="xlf:U_segsrc_bx_rid">
+ <xsd:selector xpath=".//xlf:ex"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:keyref>
+ </xsd:element>
+ <xsd:element name="target">
+ <xsd:complexType mixed="true">
+ <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
+ <xsd:attribute name="state" type="xlf:AttrType_state" use="optional"/>
+ <xsd:attribute name="state-qualifier" type="xlf:AttrType_state-qualifier" use="optional"/>
+ <xsd:attribute name="phase-name" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute ref="xml:lang" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
+ <xsd:attribute name="resname" type="xsd:string" use="optional"/>
+ <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
+ <xsd:attribute name="font" type="xsd:string" use="optional"/>
+ <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
+ <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute default="yes" name="equiv-trans" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ <xsd:unique name="U_target_bpt_rid">
+ <xsd:selector xpath=".//xlf:bpt"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_target_ept_rid" refer="xlf:U_target_bpt_rid">
+ <xsd:selector xpath=".//xlf:ept"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:keyref>
+ <xsd:unique name="U_target_bx_rid">
+ <xsd:selector xpath=".//xlf:bx"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_target_ex_rid" refer="xlf:U_target_bx_rid">
+ <xsd:selector xpath=".//xlf:ex"/>
+ <xsd:field xpath="@rid"/>
+ </xsd:keyref>
+ </xsd:element>
+ <xsd:element name="alt-trans">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element minOccurs="0" ref="xlf:source"/>
+ <xsd:element minOccurs="0" ref="xlf:seg-source"/>
+ <xsd:element maxOccurs="unbounded" ref="xlf:target"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:context-group"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:prop-group"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="xlf:note"/>
+ <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="skip"/>
+ </xsd:sequence>
+ <xsd:attribute name="match-quality" type="xsd:string" use="optional"/>
+ <xsd:attribute name="tool-id" type="xsd:string" use="optional"/>
+ <xsd:attribute name="tool" type="xsd:string" use="optional"/>
+ <xsd:attribute name="crc" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute ref="xml:lang" use="optional"/>
+ <xsd:attribute name="origin" type="xsd:string" use="optional"/>
+ <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
+ <xsd:attribute default="default" ref="xml:space" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
+ <xsd:attribute name="resname" type="xsd:string" use="optional"/>
+ <xsd:attribute name="extradata" type="xsd:string" use="optional"/>
+ <xsd:attribute name="extype" type="xsd:string" use="optional"/>
+ <xsd:attribute name="help-id" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="menu" type="xsd:string" use="optional"/>
+ <xsd:attribute name="menu-option" type="xsd:string" use="optional"/>
+ <xsd:attribute name="menu-name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="mid" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="coord" type="xlf:AttrType_Coordinates" use="optional"/>
+ <xsd:attribute name="font" type="xsd:string" use="optional"/>
+ <xsd:attribute name="css-style" type="xsd:string" use="optional"/>
+ <xsd:attribute name="style" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="exstyle" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="phase-name" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute default="proposal" name="alttranstype" type="xlf:AttrType_alttranstype" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ <xsd:unique name="U_at_segsrc_mid">
+ <xsd:selector xpath="./xlf:seg-source/xlf:mrk"/>
+ <xsd:field xpath="@mid"/>
+ </xsd:unique>
+ <xsd:keyref name="KR_at_segsrc_mid" refer="xlf:U_at_segsrc_mid">
+ <xsd:selector xpath="./xlf:target/xlf:mrk"/>
+ <xsd:field xpath="@mid"/>
+ </xsd:keyref>
+ </xsd:element>
+ <xsd:element name="bin-unit">
+ <xsd:complexType>
+ <xsd:sequence>
+ <xsd:element ref="xlf:bin-source"/>
+ <xsd:element minOccurs="0" ref="xlf:bin-target"/>
+ <xsd:choice maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:context-group"/>
+ <xsd:element ref="xlf:count-group"/>
+ <xsd:element ref="xlf:prop-group"/>
+ <xsd:element ref="xlf:note"/>
+ <xsd:element ref="xlf:trans-unit"/>
+ </xsd:choice>
+ <xsd:any maxOccurs="unbounded" minOccurs="0" namespace="##other" processContents="skip"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:string" use="required"/>
+ <xsd:attribute name="mime-type" type="xlf:mime-typeValueList" use="required"/>
+ <xsd:attribute name="approved" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attribute default="yes" name="translate" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attribute default="yes" name="reformat" type="xlf:AttrType_reformat" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
+ <xsd:attribute name="resname" type="xsd:string" use="optional"/>
+ <xsd:attribute name="phase-name" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="bin-source">
+ <xsd:complexType>
+ <xsd:choice>
+ <xsd:element ref="xlf:internal-file"/>
+ <xsd:element ref="xlf:external-file"/>
+ </xsd:choice>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="bin-target">
+ <xsd:complexType>
+ <xsd:choice>
+ <xsd:element ref="xlf:internal-file"/>
+ <xsd:element ref="xlf:external-file"/>
+ </xsd:choice>
+ <xsd:attribute name="mime-type" type="xlf:mime-typeValueList" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:attribute name="state" type="xlf:AttrType_state" use="optional"/>
+ <xsd:attribute name="state-qualifier" type="xlf:AttrType_state-qualifier" use="optional"/>
+ <xsd:attribute name="phase-name" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="restype" type="xlf:AttrType_restype" use="optional"/>
+ <xsd:attribute name="resname" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ </xsd:element>
+ <!-- Element for inline codes -->
+ <xsd:element name="g">
+ <xsd:complexType mixed="true">
+ <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
+ <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
+ <xsd:attribute default="yes" name="clone" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="x">
+ <xsd:complexType>
+ <xsd:attribute name="ctype" type="xlf:AttrType_InlinePlaceholders" use="optional"/>
+ <xsd:attribute default="yes" name="clone" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="bx">
+ <xsd:complexType>
+ <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
+ <xsd:attribute default="yes" name="clone" type="xlf:AttrType_YesNo" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="ex">
+ <xsd:complexType>
+ <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="ph">
+ <xsd:complexType mixed="true">
+ <xsd:sequence maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:sub"/>
+ </xsd:sequence>
+ <xsd:attribute name="ctype" type="xlf:AttrType_InlinePlaceholders" use="optional"/>
+ <xsd:attribute name="crc" type="xsd:string" use="optional"/>
+ <xsd:attribute name="assoc" type="xlf:AttrType_assoc" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="bpt">
+ <xsd:complexType mixed="true">
+ <xsd:sequence maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:sub"/>
+ </xsd:sequence>
+ <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
+ <xsd:attribute name="crc" type="xsd:string" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="ept">
+ <xsd:complexType mixed="true">
+ <xsd:sequence maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:sub"/>
+ </xsd:sequence>
+ <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="crc" type="xsd:string" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="it">
+ <xsd:complexType mixed="true">
+ <xsd:sequence maxOccurs="unbounded" minOccurs="0">
+ <xsd:element ref="xlf:sub"/>
+ </xsd:sequence>
+ <xsd:attribute name="pos" type="xlf:AttrType_Position" use="required"/>
+ <xsd:attribute name="rid" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
+ <xsd:attribute name="crc" type="xsd:string" use="optional"/>
+ <xsd:attributeGroup ref="xlf:AttrGroup_TextContent"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="sub">
+ <xsd:complexType mixed="true">
+ <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
+ <xsd:attribute name="datatype" type="xlf:AttrType_datatype" use="optional"/>
+ <xsd:attribute name="ctype" type="xlf:AttrType_InlineDelimiters" use="optional"/>
+ <xsd:attribute name="xid" type="xsd:string" use="optional"/>
+ </xsd:complexType>
+ </xsd:element>
+ <xsd:element name="mrk">
+ <xsd:complexType mixed="true">
+ <xsd:group maxOccurs="unbounded" minOccurs="0" ref="xlf:ElemGroup_TextContent"/>
+ <xsd:attribute name="mtype" type="xlf:AttrType_mtype" use="required"/>
+ <xsd:attribute name="mid" type="xsd:NMTOKEN" use="optional"/>
+ <xsd:attribute name="comment" type="xsd:string" use="optional"/>
+ <xsd:attribute name="ts" type="xsd:string" use="optional"/>
+ <xsd:anyAttribute namespace="##any" processContents="skip"/>
+ </xsd:complexType>
+ </xsd:element>
+</xsd:schema>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderFactoryTestCase.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderFactoryTestCase.php
index d6510e0..95ffcb1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderFactoryTestCase.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderFactoryTestCase.php
@@ -11,6 +11,7 @@
namespace Symfony\Component\Translation\Test;
+use PHPUnit\Framework\MockObject\MockObject;
use PHPUnit\Framework\TestCase;
use Psr\Log\LoggerInterface;
use Symfony\Component\HttpClient\MockHttpClient;
@@ -20,39 +21,39 @@
use Symfony\Component\Translation\Loader\LoaderInterface;
use Symfony\Component\Translation\Provider\Dsn;
use Symfony\Component\Translation\Provider\ProviderFactoryInterface;
+use Symfony\Component\Translation\TranslatorBagInterface;
use Symfony\Contracts\HttpClient\HttpClientInterface;
/**
* A test case to ease testing a translation provider factory.
*
* @author Mathieu Santostefano <msantostefano@protonmail.com>
- *
- * @internal
*/
abstract class ProviderFactoryTestCase extends TestCase
{
- protected $client;
- protected $logger;
+ protected HttpClientInterface $client;
+ protected LoggerInterface|MockObject $logger;
protected string $defaultLocale;
- protected $loader;
- protected $xliffFileDumper;
+ protected LoaderInterface|MockObject $loader;
+ protected XliffFileDumper|MockObject $xliffFileDumper;
+ protected TranslatorBagInterface|MockObject $translatorBag;
abstract public function createFactory(): ProviderFactoryInterface;
/**
* @return iterable<array{0: bool, 1: string}>
*/
- abstract public function supportsProvider(): iterable;
+ abstract public static function supportsProvider(): iterable;
/**
- * @return iterable<array{0: string, 1: string, 2: TransportInterface}>
+ * @return iterable<array{0: string, 1: string}>
*/
- abstract public function createProvider(): iterable;
+ abstract public static function createProvider(): iterable;
/**
* @return iterable<array{0: string, 1: string|null}>
*/
- public function unsupportedSchemeProvider(): iterable
+ public static function unsupportedSchemeProvider(): iterable
{
return [];
}
@@ -60,7 +61,7 @@
/**
* @return iterable<array{0: string, 1: string|null}>
*/
- public function incompleteDsnProvider(): iterable
+ public static function incompleteDsnProvider(): iterable
{
return [];
}
@@ -89,7 +90,7 @@
/**
* @dataProvider unsupportedSchemeProvider
*/
- public function testUnsupportedSchemeException(string $dsn, string $message = null)
+ public function testUnsupportedSchemeException(string $dsn, ?string $message = null)
{
$factory = $this->createFactory();
@@ -106,7 +107,7 @@
/**
* @dataProvider incompleteDsnProvider
*/
- public function testIncompleteDsnException(string $dsn, string $message = null)
+ public function testIncompleteDsnException(string $dsn, ?string $message = null)
{
$factory = $this->createFactory();
@@ -144,4 +145,9 @@
{
return $this->xliffFileDumper ??= $this->createMock(XliffFileDumper::class);
}
+
+ protected function getTranslatorBag(): TranslatorBagInterface
+ {
+ return $this->translatorBag ??= $this->createMock(TranslatorBagInterface::class);
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderTestCase.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderTestCase.php
index 5ae2682..a8fa0b8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderTestCase.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Test/ProviderTestCase.php
@@ -11,35 +11,36 @@
namespace Symfony\Component\Translation\Test;
+use PHPUnit\Framework\MockObject\MockObject;
use PHPUnit\Framework\TestCase;
use Psr\Log\LoggerInterface;
use Symfony\Component\HttpClient\MockHttpClient;
use Symfony\Component\Translation\Dumper\XliffFileDumper;
use Symfony\Component\Translation\Loader\LoaderInterface;
use Symfony\Component\Translation\Provider\ProviderInterface;
+use Symfony\Component\Translation\TranslatorBagInterface;
use Symfony\Contracts\HttpClient\HttpClientInterface;
/**
* A test case to ease testing a translation provider.
*
* @author Mathieu Santostefano <msantostefano@protonmail.com>
- *
- * @internal
*/
abstract class ProviderTestCase extends TestCase
{
- protected $client;
- protected $logger;
+ protected HttpClientInterface $client;
+ protected LoggerInterface|MockObject $logger;
protected string $defaultLocale;
- protected $loader;
- protected $xliffFileDumper;
+ protected LoaderInterface|MockObject $loader;
+ protected XliffFileDumper|MockObject $xliffFileDumper;
+ protected TranslatorBagInterface|MockObject $translatorBag;
- abstract public function createProvider(HttpClientInterface $client, LoaderInterface $loader, LoggerInterface $logger, string $defaultLocale, string $endpoint): ProviderInterface;
+ abstract public static function createProvider(HttpClientInterface $client, LoaderInterface $loader, LoggerInterface $logger, string $defaultLocale, string $endpoint): ProviderInterface;
/**
- * @return iterable<array{0: string, 1: ProviderInterface}>
+ * @return iterable<array{0: ProviderInterface, 1: string}>
*/
- abstract public function toStringProvider(): iterable;
+ abstract public static function toStringProvider(): iterable;
/**
* @dataProvider toStringProvider
@@ -73,4 +74,9 @@
{
return $this->xliffFileDumper ??= $this->createMock(XliffFileDumper::class);
}
+
+ protected function getTranslatorBag(): TranslatorBagInterface
+ {
+ return $this->translatorBag ??= $this->createMock(TranslatorBagInterface::class);
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatableMessage.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatableMessage.php
index b1a3b6b..c591e68 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatableMessage.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatableMessage.php
@@ -23,7 +23,7 @@
private array $parameters;
private ?string $domain;
- public function __construct(string $message, array $parameters = [], string $domain = null)
+ public function __construct(string $message, array $parameters = [], ?string $domain = null)
{
$this->message = $message;
$this->parameters = $parameters;
@@ -50,12 +50,10 @@
return $this->domain;
}
- public function trans(TranslatorInterface $translator, string $locale = null): string
+ public function trans(TranslatorInterface $translator, ?string $locale = null): string
{
return $translator->trans($this->getMessage(), array_map(
- static function ($parameter) use ($translator, $locale) {
- return $parameter instanceof TranslatableInterface ? $parameter->trans($translator, $locale) : $parameter;
- },
+ static fn ($parameter) => $parameter instanceof TranslatableInterface ? $parameter->trans($translator, $locale) : $parameter,
$this->getParameters()
), $this->getDomain(), $locale);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Translator.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Translator.php
index 05e84d0..1973d07 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Translator.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Translator.php
@@ -22,6 +22,7 @@
use Symfony\Component\Translation\Formatter\MessageFormatterInterface;
use Symfony\Component\Translation\Loader\LoaderInterface;
use Symfony\Contracts\Translation\LocaleAwareInterface;
+use Symfony\Contracts\Translation\TranslatableInterface;
use Symfony\Contracts\Translation\TranslatorInterface;
// Help opcache.preload discover always-needed symbols
@@ -51,7 +52,7 @@
private array $resources = [];
- private $formatter;
+ private MessageFormatterInterface $formatter;
private ?string $cacheDir;
@@ -59,7 +60,7 @@
private array $cacheVary;
- private $configCacheFactory;
+ private ?ConfigCacheFactoryInterface $configCacheFactory;
private array $parentLocales;
@@ -68,21 +69,20 @@
/**
* @throws InvalidArgumentException If a locale contains invalid characters
*/
- public function __construct(string $locale, MessageFormatterInterface $formatter = null, string $cacheDir = null, bool $debug = false, array $cacheVary = [])
+ public function __construct(string $locale, ?MessageFormatterInterface $formatter = null, ?string $cacheDir = null, bool $debug = false, array $cacheVary = [])
{
$this->setLocale($locale);
- if (null === $formatter) {
- $formatter = new MessageFormatter();
- }
-
- $this->formatter = $formatter;
+ $this->formatter = $formatter ??= new MessageFormatter();
$this->cacheDir = $cacheDir;
$this->debug = $debug;
$this->cacheVary = $cacheVary;
$this->hasIntlFormatter = $formatter instanceof IntlFormatterInterface;
}
+ /**
+ * @return void
+ */
public function setConfigCacheFactory(ConfigCacheFactoryInterface $configCacheFactory)
{
$this->configCacheFactory = $configCacheFactory;
@@ -92,6 +92,8 @@
* Adds a Loader.
*
* @param string $format The name of the loader (@see addResource())
+ *
+ * @return void
*/
public function addLoader(string $format, LoaderInterface $loader)
{
@@ -104,13 +106,13 @@
* @param string $format The name of the loader (@see addLoader())
* @param mixed $resource The resource name
*
+ * @return void
+ *
* @throws InvalidArgumentException If the locale contains invalid characters
*/
- public function addResource(string $format, mixed $resource, string $locale, string $domain = null)
+ public function addResource(string $format, mixed $resource, string $locale, ?string $domain = null)
{
- if (null === $domain) {
- $domain = 'messages';
- }
+ $domain ??= 'messages';
$this->assertValidLocale($locale);
$locale ?: $locale = class_exists(\Locale::class) ? \Locale::getDefault() : 'en';
@@ -125,7 +127,7 @@
}
/**
- * {@inheritdoc}
+ * @return void
*/
public function setLocale(string $locale)
{
@@ -133,9 +135,6 @@
$this->locale = $locale;
}
- /**
- * {@inheritdoc}
- */
public function getLocale(): string
{
return $this->locale ?: (class_exists(\Locale::class) ? \Locale::getDefault() : 'en');
@@ -146,6 +145,8 @@
*
* @param string[] $locales
*
+ * @return void
+ *
* @throws InvalidArgumentException If a locale contains invalid characters
*/
public function setFallbackLocales(array $locales)
@@ -170,18 +171,13 @@
return $this->fallbackLocales;
}
- /**
- * {@inheritdoc}
- */
- public function trans(?string $id, array $parameters = [], string $domain = null, string $locale = null): string
+ public function trans(?string $id, array $parameters = [], ?string $domain = null, ?string $locale = null): string
{
if (null === $id || '' === $id) {
return '';
}
- if (null === $domain) {
- $domain = 'messages';
- }
+ $domain ??= 'messages';
$catalogue = $this->getCatalogue($locale);
$locale = $catalogue->getLocale();
@@ -194,6 +190,8 @@
}
}
+ $parameters = array_map(fn ($parameter) => $parameter instanceof TranslatableInterface ? $parameter->trans($this, $locale) : $parameter, $parameters);
+
$len = \strlen(MessageCatalogue::INTL_DOMAIN_SUFFIX);
if ($this->hasIntlFormatter
&& ($catalogue->defines($id, $domain.MessageCatalogue::INTL_DOMAIN_SUFFIX)
@@ -205,10 +203,7 @@
return $this->formatter->format($catalogue->get($id, $domain), $locale, $parameters);
}
- /**
- * {@inheritdoc}
- */
- public function getCatalogue(string $locale = null): MessageCatalogueInterface
+ public function getCatalogue(?string $locale = null): MessageCatalogueInterface
{
if (!$locale) {
$locale = $this->getLocale();
@@ -223,9 +218,6 @@
return $this->catalogues[$locale];
}
- /**
- * {@inheritdoc}
- */
public function getCatalogues(): array
{
return array_values($this->catalogues);
@@ -241,6 +233,9 @@
return $this->loaders;
}
+ /**
+ * @return void
+ */
protected function loadCatalogue(string $locale)
{
if (null === $this->cacheDir) {
@@ -250,6 +245,9 @@
}
}
+ /**
+ * @return void
+ */
protected function initializeCatalogue(string $locale)
{
$this->assertValidLocale($locale);
@@ -386,6 +384,9 @@
}
}
+ /**
+ * @return array
+ */
protected function computeFallbackLocales(string $locale)
{
$this->parentLocales ??= json_decode(file_get_contents(__DIR__.'/Resources/data/parents.json'), true);
@@ -430,6 +431,8 @@
/**
* Asserts that the locale is valid, throws an Exception if not.
*
+ * @return void
+ *
* @throws InvalidArgumentException If the locale contains invalid characters
*/
protected function assertValidLocale(string $locale)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBag.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBag.php
index ffd109f..3b47aec 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBag.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBag.php
@@ -35,10 +35,7 @@
}
}
- /**
- * {@inheritdoc}
- */
- public function getCatalogue(string $locale = null): MessageCatalogueInterface
+ public function getCatalogue(?string $locale = null): MessageCatalogueInterface
{
if (null === $locale || !isset($this->catalogues[$locale])) {
$this->catalogues[$locale] = new MessageCatalogue($locale);
@@ -47,9 +44,6 @@
return $this->catalogues[$locale];
}
- /**
- * {@inheritdoc}
- */
public function getCatalogues(): array
{
return array_values($this->catalogues);
@@ -70,7 +64,7 @@
$operation->moveMessagesToIntlDomainsIfPossible(AbstractOperation::NEW_BATCH);
$newCatalogue = new MessageCatalogue($locale);
- foreach ($operation->getDomains() as $domain) {
+ foreach ($catalogue->getDomains() as $domain) {
$newCatalogue->add($operation->getNewMessages($domain), $domain);
}
@@ -94,7 +88,10 @@
$obsoleteCatalogue = new MessageCatalogue($locale);
foreach ($operation->getDomains() as $domain) {
- $obsoleteCatalogue->add($operation->getObsoleteMessages($domain), $domain);
+ $obsoleteCatalogue->add(
+ array_diff($operation->getMessages($domain), $operation->getNewMessages($domain)),
+ $domain
+ );
}
$diff->addCatalogue($obsoleteCatalogue);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBagInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBagInterface.php
index a787acf..365d1f1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBagInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/TranslatorBagInterface.php
@@ -25,7 +25,7 @@
*
* @throws InvalidArgumentException If the locale contains invalid characters
*/
- public function getCatalogue(string $locale = null): MessageCatalogueInterface;
+ public function getCatalogue(?string $locale = null): MessageCatalogueInterface;
/**
* Returns all catalogues of the instance.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/ArrayConverter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/ArrayConverter.php
index 60b8be6..64e15b4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/ArrayConverter.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/ArrayConverter.php
@@ -36,7 +36,7 @@
$tree = [];
foreach ($messages as $id => $value) {
- $referenceToElement = &self::getElementByPath($tree, explode('.', $id));
+ $referenceToElement = &self::getElementByPath($tree, self::getKeyParts($id));
$referenceToElement = $value;
@@ -46,7 +46,7 @@
return $tree;
}
- private static function &getElementByPath(array &$tree, array $parts)
+ private static function &getElementByPath(array &$tree, array $parts): mixed
{
$elem = &$tree;
$parentOfElem = null;
@@ -63,6 +63,7 @@
$elem = &$elem[implode('.', \array_slice($parts, $i))];
break;
}
+
$parentOfElem = &$elem;
$elem = &$elem[$part];
}
@@ -82,7 +83,7 @@
return $elem;
}
- private static function cancelExpand(array &$tree, string $prefix, array $node)
+ private static function cancelExpand(array &$tree, string $prefix, array $node): void
{
$prefix .= '.';
@@ -94,4 +95,48 @@
}
}
}
+
+ /**
+ * @return string[]
+ */
+ private static function getKeyParts(string $key): array
+ {
+ $parts = explode('.', $key);
+ $partsCount = \count($parts);
+
+ $result = [];
+ $buffer = '';
+
+ foreach ($parts as $index => $part) {
+ if (0 === $index && '' === $part) {
+ $buffer = '.';
+
+ continue;
+ }
+
+ if ($index === $partsCount - 1 && '' === $part) {
+ $buffer .= '.';
+ $result[] = $buffer;
+
+ continue;
+ }
+
+ if (isset($parts[$index + 1]) && '' === $parts[$index + 1]) {
+ $buffer .= $part;
+
+ continue;
+ }
+
+ if ($buffer) {
+ $result[] = $buffer.$part;
+ $buffer = '';
+
+ continue;
+ }
+
+ $result[] = $part;
+ }
+
+ return $result;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/XliffUtils.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/XliffUtils.php
index 85ecc85..335c34b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/XliffUtils.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Util/XliffUtils.php
@@ -129,7 +129,7 @@
private static function getSchema(string $xliffVersion): string
{
if ('1.2' === $xliffVersion) {
- $schemaSource = file_get_contents(__DIR__.'/../Resources/schemas/xliff-core-1.2-strict.xsd');
+ $schemaSource = file_get_contents(__DIR__.'/../Resources/schemas/xliff-core-1.2-transitional.xsd');
$xmlUri = 'http://www.w3.org/2001/xml.xsd';
} elseif ('2.0' === $xliffVersion) {
$schemaSource = file_get_contents(__DIR__.'/../Resources/schemas/xliff-core-2.0.xsd');
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriter.php
index 5dd3a5c..61e03cb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriter.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriter.php
@@ -30,6 +30,8 @@
/**
* Adds a dumper to the writer.
+ *
+ * @return void
*/
public function addDumper(string $format, DumperInterface $dumper)
{
@@ -50,6 +52,8 @@
* @param string $format The format to use to dump the messages
* @param array $options Options that are passed to the dumper
*
+ * @return void
+ *
* @throws InvalidArgumentException
*/
public function write(MessageCatalogue $catalogue, string $format, array $options = [])
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriterInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriterInterface.php
index 4321309..5ebb979 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriterInterface.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/Writer/TranslationWriterInterface.php
@@ -27,6 +27,8 @@
* @param string $format The format to use to dump the messages
* @param array $options Options that are passed to the dumper
*
+ * @return void
+ *
* @throws InvalidArgumentException
*/
public function write(MessageCatalogue $catalogue, string $format, array $options = []);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/composer.json
index abe8b97..af6f7a3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/composer.json
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/translation/composer.json
@@ -16,27 +16,32 @@
}
],
"require": {
- "php": ">=8.0.2",
+ "php": ">=8.1",
+ "symfony/deprecation-contracts": "^2.5|^3",
"symfony/polyfill-mbstring": "~1.0",
- "symfony/translation-contracts": "^2.3|^3.0"
+ "symfony/translation-contracts": "^2.5|^3.0"
},
"require-dev": {
- "symfony/config": "^5.4|^6.0",
- "symfony/console": "^5.4|^6.0",
- "symfony/dependency-injection": "^5.4|^6.0",
- "symfony/http-client-contracts": "^1.1|^2.0|^3.0",
- "symfony/http-kernel": "^5.4|^6.0",
- "symfony/intl": "^5.4|^6.0",
+ "nikic/php-parser": "^4.18|^5.0",
+ "symfony/config": "^5.4|^6.0|^7.0",
+ "symfony/console": "^5.4|^6.0|^7.0",
+ "symfony/dependency-injection": "^5.4|^6.0|^7.0",
+ "symfony/http-client-contracts": "^2.5|^3.0",
+ "symfony/http-kernel": "^5.4|^6.0|^7.0",
+ "symfony/intl": "^5.4|^6.0|^7.0",
"symfony/polyfill-intl-icu": "^1.21",
- "symfony/service-contracts": "^1.1.2|^2|^3",
- "symfony/yaml": "^5.4|^6.0",
- "symfony/finder": "^5.4|^6.0",
+ "symfony/routing": "^5.4|^6.0|^7.0",
+ "symfony/service-contracts": "^2.5|^3",
+ "symfony/yaml": "^5.4|^6.0|^7.0",
+ "symfony/finder": "^5.4|^6.0|^7.0",
"psr/log": "^1|^2|^3"
},
"conflict": {
"symfony/config": "<5.4",
"symfony/dependency-injection": "<5.4",
+ "symfony/http-client-contracts": "<2.5",
"symfony/http-kernel": "<5.4",
+ "symfony/service-contracts": "<2.5",
"symfony/twig-bundle": "<5.4",
"symfony/yaml": "<5.4",
"symfony/console": "<5.4"
@@ -44,11 +49,6 @@
"provide": {
"symfony/translation-implementation": "2.3|3.0"
},
- "suggest": {
- "symfony/config": "",
- "symfony/yaml": "",
- "psr/log-implementation": "To use logging capability in translator"
- },
"autoload": {
"files": [ "Resources/functions.php" ],
"psr-4": { "Symfony\\Component\\Translation\\": "" },
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/CHANGELOG.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/CHANGELOG.md
deleted file mode 100644
index f58ed31..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/CHANGELOG.md
+++ /dev/null
@@ -1,72 +0,0 @@
-CHANGELOG
-=========
-
-5.4
----
-
- * Add ability to style integer and double values independently
- * Add casters for Symfony's UUIDs and ULIDs
- * Add support for `Fiber`
-
-5.2.0
------
-
- * added support for PHPUnit `--colors` option
- * added `VAR_DUMPER_FORMAT=server` env var value support
- * prevent replacing the handler when the `VAR_DUMPER_FORMAT` env var is set
-
-5.1.0
------
-
- * added `RdKafka` support
-
-4.4.0
------
-
- * added `VarDumperTestTrait::setUpVarDumper()` and `VarDumperTestTrait::tearDownVarDumper()`
- to configure casters & flags to use in tests
- * added `ImagineCaster` and infrastructure to dump images
- * added the stamps of a message after it is dispatched in `TraceableMessageBus` and `MessengerDataCollector` collected data
- * added `UuidCaster`
- * made all casters final
- * added support for the `NO_COLOR` env var (https://no-color.org/)
-
-4.3.0
------
-
- * added `DsCaster` to support dumping the contents of data structures from the Ds extension
-
-4.2.0
------
-
- * support selecting the format to use by setting the environment variable `VAR_DUMPER_FORMAT` to `html` or `cli`
-
-4.1.0
------
-
- * added a `ServerDumper` to send serialized Data clones to a server
- * added a `ServerDumpCommand` and `DumpServer` to run a server collecting
- and displaying dumps on a single place with multiple formats support
- * added `CliDescriptor` and `HtmlDescriptor` descriptors for `server:dump` CLI and HTML formats support
-
-4.0.0
------
-
- * support for passing `\ReflectionClass` instances to the `Caster::castObject()`
- method has been dropped, pass class names as strings instead
- * the `Data::getRawData()` method has been removed
- * the `VarDumperTestTrait::assertDumpEquals()` method expects a 3rd `$filter = 0`
- argument and moves `$message = ''` argument at 4th position.
- * the `VarDumperTestTrait::assertDumpMatchesFormat()` method expects a 3rd `$filter = 0`
- argument and moves `$message = ''` argument at 4th position.
-
-3.4.0
------
-
- * added `AbstractCloner::setMinDepth()` function to ensure minimum tree depth
- * deprecated `MongoCaster`
-
-2.7.0
------
-
- * deprecated `Cloner\Data::getLimitedClone()`. Use `withMaxDepth`, `withMaxItemsPerDepth` or `withRefHandles` instead.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/AmqpCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/AmqpCaster.php
deleted file mode 100644
index dc3b621..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/AmqpCaster.php
+++ /dev/null
@@ -1,212 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts Amqp related classes to array representation.
- *
- * @author Grégoire Pineau <lyrixx@lyrixx.info>
- *
- * @final
- */
-class AmqpCaster
-{
- private const FLAGS = [
- \AMQP_DURABLE => 'AMQP_DURABLE',
- \AMQP_PASSIVE => 'AMQP_PASSIVE',
- \AMQP_EXCLUSIVE => 'AMQP_EXCLUSIVE',
- \AMQP_AUTODELETE => 'AMQP_AUTODELETE',
- \AMQP_INTERNAL => 'AMQP_INTERNAL',
- \AMQP_NOLOCAL => 'AMQP_NOLOCAL',
- \AMQP_AUTOACK => 'AMQP_AUTOACK',
- \AMQP_IFEMPTY => 'AMQP_IFEMPTY',
- \AMQP_IFUNUSED => 'AMQP_IFUNUSED',
- \AMQP_MANDATORY => 'AMQP_MANDATORY',
- \AMQP_IMMEDIATE => 'AMQP_IMMEDIATE',
- \AMQP_MULTIPLE => 'AMQP_MULTIPLE',
- \AMQP_NOWAIT => 'AMQP_NOWAIT',
- \AMQP_REQUEUE => 'AMQP_REQUEUE',
- ];
-
- private const EXCHANGE_TYPES = [
- \AMQP_EX_TYPE_DIRECT => 'AMQP_EX_TYPE_DIRECT',
- \AMQP_EX_TYPE_FANOUT => 'AMQP_EX_TYPE_FANOUT',
- \AMQP_EX_TYPE_TOPIC => 'AMQP_EX_TYPE_TOPIC',
- \AMQP_EX_TYPE_HEADERS => 'AMQP_EX_TYPE_HEADERS',
- ];
-
- public static function castConnection(\AMQPConnection $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'is_connected' => $c->isConnected(),
- ];
-
- // Recent version of the extension already expose private properties
- if (isset($a["\x00AMQPConnection\x00login"])) {
- return $a;
- }
-
- // BC layer in the amqp lib
- if (method_exists($c, 'getReadTimeout')) {
- $timeout = $c->getReadTimeout();
- } else {
- $timeout = $c->getTimeout();
- }
-
- $a += [
- $prefix.'is_connected' => $c->isConnected(),
- $prefix.'login' => $c->getLogin(),
- $prefix.'password' => $c->getPassword(),
- $prefix.'host' => $c->getHost(),
- $prefix.'vhost' => $c->getVhost(),
- $prefix.'port' => $c->getPort(),
- $prefix.'read_timeout' => $timeout,
- ];
-
- return $a;
- }
-
- public static function castChannel(\AMQPChannel $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'is_connected' => $c->isConnected(),
- $prefix.'channel_id' => $c->getChannelId(),
- ];
-
- // Recent version of the extension already expose private properties
- if (isset($a["\x00AMQPChannel\x00connection"])) {
- return $a;
- }
-
- $a += [
- $prefix.'connection' => $c->getConnection(),
- $prefix.'prefetch_size' => $c->getPrefetchSize(),
- $prefix.'prefetch_count' => $c->getPrefetchCount(),
- ];
-
- return $a;
- }
-
- public static function castQueue(\AMQPQueue $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'flags' => self::extractFlags($c->getFlags()),
- ];
-
- // Recent version of the extension already expose private properties
- if (isset($a["\x00AMQPQueue\x00name"])) {
- return $a;
- }
-
- $a += [
- $prefix.'connection' => $c->getConnection(),
- $prefix.'channel' => $c->getChannel(),
- $prefix.'name' => $c->getName(),
- $prefix.'arguments' => $c->getArguments(),
- ];
-
- return $a;
- }
-
- public static function castExchange(\AMQPExchange $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'flags' => self::extractFlags($c->getFlags()),
- ];
-
- $type = isset(self::EXCHANGE_TYPES[$c->getType()]) ? new ConstStub(self::EXCHANGE_TYPES[$c->getType()], $c->getType()) : $c->getType();
-
- // Recent version of the extension already expose private properties
- if (isset($a["\x00AMQPExchange\x00name"])) {
- $a["\x00AMQPExchange\x00type"] = $type;
-
- return $a;
- }
-
- $a += [
- $prefix.'connection' => $c->getConnection(),
- $prefix.'channel' => $c->getChannel(),
- $prefix.'name' => $c->getName(),
- $prefix.'type' => $type,
- $prefix.'arguments' => $c->getArguments(),
- ];
-
- return $a;
- }
-
- public static function castEnvelope(\AMQPEnvelope $c, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $deliveryMode = new ConstStub($c->getDeliveryMode().(2 === $c->getDeliveryMode() ? ' (persistent)' : ' (non-persistent)'), $c->getDeliveryMode());
-
- // Recent version of the extension already expose private properties
- if (isset($a["\x00AMQPEnvelope\x00body"])) {
- $a["\0AMQPEnvelope\0delivery_mode"] = $deliveryMode;
-
- return $a;
- }
-
- if (!($filter & Caster::EXCLUDE_VERBOSE)) {
- $a += [$prefix.'body' => $c->getBody()];
- }
-
- $a += [
- $prefix.'delivery_tag' => $c->getDeliveryTag(),
- $prefix.'is_redelivery' => $c->isRedelivery(),
- $prefix.'exchange_name' => $c->getExchangeName(),
- $prefix.'routing_key' => $c->getRoutingKey(),
- $prefix.'content_type' => $c->getContentType(),
- $prefix.'content_encoding' => $c->getContentEncoding(),
- $prefix.'headers' => $c->getHeaders(),
- $prefix.'delivery_mode' => $deliveryMode,
- $prefix.'priority' => $c->getPriority(),
- $prefix.'correlation_id' => $c->getCorrelationId(),
- $prefix.'reply_to' => $c->getReplyTo(),
- $prefix.'expiration' => $c->getExpiration(),
- $prefix.'message_id' => $c->getMessageId(),
- $prefix.'timestamp' => $c->getTimeStamp(),
- $prefix.'type' => $c->getType(),
- $prefix.'user_id' => $c->getUserId(),
- $prefix.'app_id' => $c->getAppId(),
- ];
-
- return $a;
- }
-
- private static function extractFlags(int $flags): ConstStub
- {
- $flagsArray = [];
-
- foreach (self::FLAGS as $value => $name) {
- if ($flags & $value) {
- $flagsArray[] = $name;
- }
- }
-
- if (!$flagsArray) {
- $flagsArray = ['AMQP_NOPARAM'];
- }
-
- return new ConstStub(implode('|', $flagsArray), $flags);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ArgsStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ArgsStub.php
deleted file mode 100644
index a89a71b..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ArgsStub.php
+++ /dev/null
@@ -1,80 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Represents a list of function arguments.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class ArgsStub extends EnumStub
-{
- private static array $parameters = [];
-
- public function __construct(array $args, string $function, ?string $class)
- {
- [$variadic, $params] = self::getParameters($function, $class);
-
- $values = [];
- foreach ($args as $k => $v) {
- $values[$k] = !is_scalar($v) && !$v instanceof Stub ? new CutStub($v) : $v;
- }
- if (null === $params) {
- parent::__construct($values, false);
-
- return;
- }
- if (\count($values) < \count($params)) {
- $params = \array_slice($params, 0, \count($values));
- } elseif (\count($values) > \count($params)) {
- $values[] = new EnumStub(array_splice($values, \count($params)), false);
- $params[] = $variadic;
- }
- if (['...'] === $params) {
- $this->dumpKeys = false;
- $this->value = $values[0]->value;
- } else {
- $this->value = array_combine($params, $values);
- }
- }
-
- private static function getParameters(string $function, ?string $class): array
- {
- if (isset(self::$parameters[$k = $class.'::'.$function])) {
- return self::$parameters[$k];
- }
-
- try {
- $r = null !== $class ? new \ReflectionMethod($class, $function) : new \ReflectionFunction($function);
- } catch (\ReflectionException $e) {
- return [null, null];
- }
-
- $variadic = '...';
- $params = [];
- foreach ($r->getParameters() as $v) {
- $k = '$'.$v->name;
- if ($v->isPassedByReference()) {
- $k = '&'.$k;
- }
- if ($v->isVariadic()) {
- $variadic .= $k;
- } else {
- $params[] = $k;
- }
- }
-
- return self::$parameters[$k] = [$variadic, $params];
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/Caster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/Caster.php
deleted file mode 100644
index 53f4461..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/Caster.php
+++ /dev/null
@@ -1,170 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Helper for filtering out properties in casters.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class Caster
-{
- public const EXCLUDE_VERBOSE = 1;
- public const EXCLUDE_VIRTUAL = 2;
- public const EXCLUDE_DYNAMIC = 4;
- public const EXCLUDE_PUBLIC = 8;
- public const EXCLUDE_PROTECTED = 16;
- public const EXCLUDE_PRIVATE = 32;
- public const EXCLUDE_NULL = 64;
- public const EXCLUDE_EMPTY = 128;
- public const EXCLUDE_NOT_IMPORTANT = 256;
- public const EXCLUDE_STRICT = 512;
-
- public const PREFIX_VIRTUAL = "\0~\0";
- public const PREFIX_DYNAMIC = "\0+\0";
- public const PREFIX_PROTECTED = "\0*\0";
-
- /**
- * Casts objects to arrays and adds the dynamic property prefix.
- *
- * @param bool $hasDebugInfo Whether the __debugInfo method exists on $obj or not
- */
- public static function castObject(object $obj, string $class, bool $hasDebugInfo = false, string $debugClass = null): array
- {
- if ($hasDebugInfo) {
- try {
- $debugInfo = $obj->__debugInfo();
- } catch (\Exception $e) {
- // ignore failing __debugInfo()
- $hasDebugInfo = false;
- }
- }
-
- $a = $obj instanceof \Closure ? [] : (array) $obj;
-
- if ($obj instanceof \__PHP_Incomplete_Class) {
- return $a;
- }
-
- if ($a) {
- static $publicProperties = [];
- $debugClass = $debugClass ?? get_debug_type($obj);
-
- $i = 0;
- $prefixedKeys = [];
- foreach ($a as $k => $v) {
- if ("\0" !== ($k[0] ?? '')) {
- if (!isset($publicProperties[$class])) {
- foreach ((new \ReflectionClass($class))->getProperties(\ReflectionProperty::IS_PUBLIC) as $prop) {
- $publicProperties[$class][$prop->name] = true;
- }
- }
- if (!isset($publicProperties[$class][$k])) {
- $prefixedKeys[$i] = self::PREFIX_DYNAMIC.$k;
- }
- } elseif ($debugClass !== $class && 1 === strpos($k, $class)) {
- $prefixedKeys[$i] = "\0".$debugClass.strrchr($k, "\0");
- }
- ++$i;
- }
- if ($prefixedKeys) {
- $keys = array_keys($a);
- foreach ($prefixedKeys as $i => $k) {
- $keys[$i] = $k;
- }
- $a = array_combine($keys, $a);
- }
- }
-
- if ($hasDebugInfo && \is_array($debugInfo)) {
- foreach ($debugInfo as $k => $v) {
- if (!isset($k[0]) || "\0" !== $k[0]) {
- if (\array_key_exists(self::PREFIX_DYNAMIC.$k, $a)) {
- continue;
- }
- $k = self::PREFIX_VIRTUAL.$k;
- }
-
- unset($a[$k]);
- $a[$k] = $v;
- }
- }
-
- return $a;
- }
-
- /**
- * Filters out the specified properties.
- *
- * By default, a single match in the $filter bit field filters properties out, following an "or" logic.
- * When EXCLUDE_STRICT is set, an "and" logic is applied: all bits must match for a property to be removed.
- *
- * @param array $a The array containing the properties to filter
- * @param int $filter A bit field of Caster::EXCLUDE_* constants specifying which properties to filter out
- * @param string[] $listedProperties List of properties to exclude when Caster::EXCLUDE_VERBOSE is set, and to preserve when Caster::EXCLUDE_NOT_IMPORTANT is set
- * @param int &$count Set to the number of removed properties
- */
- public static function filter(array $a, int $filter, array $listedProperties = [], ?int &$count = 0): array
- {
- $count = 0;
-
- foreach ($a as $k => $v) {
- $type = self::EXCLUDE_STRICT & $filter;
-
- if (null === $v) {
- $type |= self::EXCLUDE_NULL & $filter;
- $type |= self::EXCLUDE_EMPTY & $filter;
- } elseif (false === $v || '' === $v || '0' === $v || 0 === $v || 0.0 === $v || [] === $v) {
- $type |= self::EXCLUDE_EMPTY & $filter;
- }
- if ((self::EXCLUDE_NOT_IMPORTANT & $filter) && !\in_array($k, $listedProperties, true)) {
- $type |= self::EXCLUDE_NOT_IMPORTANT;
- }
- if ((self::EXCLUDE_VERBOSE & $filter) && \in_array($k, $listedProperties, true)) {
- $type |= self::EXCLUDE_VERBOSE;
- }
-
- if (!isset($k[1]) || "\0" !== $k[0]) {
- $type |= self::EXCLUDE_PUBLIC & $filter;
- } elseif ('~' === $k[1]) {
- $type |= self::EXCLUDE_VIRTUAL & $filter;
- } elseif ('+' === $k[1]) {
- $type |= self::EXCLUDE_DYNAMIC & $filter;
- } elseif ('*' === $k[1]) {
- $type |= self::EXCLUDE_PROTECTED & $filter;
- } else {
- $type |= self::EXCLUDE_PRIVATE & $filter;
- }
-
- if ((self::EXCLUDE_STRICT & $filter) ? $type === $filter : $type) {
- unset($a[$k]);
- ++$count;
- }
- }
-
- return $a;
- }
-
- public static function castPhpIncompleteClass(\__PHP_Incomplete_Class $c, array $a, Stub $stub, bool $isNested): array
- {
- if (isset($a['__PHP_Incomplete_Class_Name'])) {
- $stub->class .= '('.$a['__PHP_Incomplete_Class_Name'].')';
- unset($a['__PHP_Incomplete_Class_Name']);
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ClassStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ClassStub.php
deleted file mode 100644
index 1ac6d0a..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ClassStub.php
+++ /dev/null
@@ -1,106 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Represents a PHP class identifier.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class ClassStub extends ConstStub
-{
- /**
- * @param string $identifier A PHP identifier, e.g. a class, method, interface, etc. name
- * @param callable $callable The callable targeted by the identifier when it is ambiguous or not a real PHP identifier
- */
- public function __construct(string $identifier, callable|array|string $callable = null)
- {
- $this->value = $identifier;
-
- try {
- if (null !== $callable) {
- if ($callable instanceof \Closure) {
- $r = new \ReflectionFunction($callable);
- } elseif (\is_object($callable)) {
- $r = [$callable, '__invoke'];
- } elseif (\is_array($callable)) {
- $r = $callable;
- } elseif (false !== $i = strpos($callable, '::')) {
- $r = [substr($callable, 0, $i), substr($callable, 2 + $i)];
- } else {
- $r = new \ReflectionFunction($callable);
- }
- } elseif (0 < $i = strpos($identifier, '::') ?: strpos($identifier, '->')) {
- $r = [substr($identifier, 0, $i), substr($identifier, 2 + $i)];
- } else {
- $r = new \ReflectionClass($identifier);
- }
-
- if (\is_array($r)) {
- try {
- $r = new \ReflectionMethod($r[0], $r[1]);
- } catch (\ReflectionException $e) {
- $r = new \ReflectionClass($r[0]);
- }
- }
-
- if (str_contains($identifier, "@anonymous\0")) {
- $this->value = $identifier = preg_replace_callback('/[a-zA-Z_\x7f-\xff][\\\\a-zA-Z0-9_\x7f-\xff]*+@anonymous\x00.*?\.php(?:0x?|:[0-9]++\$)[0-9a-fA-F]++/', function ($m) {
- return class_exists($m[0], false) ? (get_parent_class($m[0]) ?: key(class_implements($m[0])) ?: 'class').'@anonymous' : $m[0];
- }, $identifier);
- }
-
- if (null !== $callable && $r instanceof \ReflectionFunctionAbstract) {
- $s = ReflectionCaster::castFunctionAbstract($r, [], new Stub(), true, Caster::EXCLUDE_VERBOSE);
- $s = ReflectionCaster::getSignature($s);
-
- if (str_ends_with($identifier, '()')) {
- $this->value = substr_replace($identifier, $s, -2);
- } else {
- $this->value .= $s;
- }
- }
- } catch (\ReflectionException $e) {
- return;
- } finally {
- if (0 < $i = strrpos($this->value, '\\')) {
- $this->attr['ellipsis'] = \strlen($this->value) - $i;
- $this->attr['ellipsis-type'] = 'class';
- $this->attr['ellipsis-tail'] = 1;
- }
- }
-
- if ($f = $r->getFileName()) {
- $this->attr['file'] = $f;
- $this->attr['line'] = $r->getStartLine();
- }
- }
-
- public static function wrapCallable(mixed $callable)
- {
- if (\is_object($callable) || !\is_callable($callable)) {
- return $callable;
- }
-
- if (!\is_array($callable)) {
- $callable = new static($callable, $callable);
- } elseif (\is_string($callable[0])) {
- $callable[0] = new static($callable[0], $callable);
- } else {
- $callable[1] = new static($callable[1], $callable);
- }
-
- return $callable;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ConstStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ConstStub.php
deleted file mode 100644
index d7d1812..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ConstStub.php
+++ /dev/null
@@ -1,33 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Represents a PHP constant and its value.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class ConstStub extends Stub
-{
- public function __construct(string $name, string|int|float $value = null)
- {
- $this->class = $name;
- $this->value = 1 < \func_num_args() ? $value : $name;
- }
-
- public function __toString(): string
- {
- return (string) $this->value;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/CutArrayStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/CutArrayStub.php
deleted file mode 100644
index 0e4fb36..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/CutArrayStub.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-/**
- * Represents a cut array.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class CutArrayStub extends CutStub
-{
- public $preservedSubset;
-
- public function __construct(array $value, array $preservedKeys)
- {
- parent::__construct($value);
-
- $this->preservedSubset = array_intersect_key($value, array_flip($preservedKeys));
- $this->cut -= \count($this->preservedSubset);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/CutStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/CutStub.php
deleted file mode 100644
index b5a96a0..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/CutStub.php
+++ /dev/null
@@ -1,64 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Represents the main properties of a PHP variable, pre-casted by a caster.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class CutStub extends Stub
-{
- public function __construct(mixed $value)
- {
- $this->value = $value;
-
- switch (\gettype($value)) {
- case 'object':
- $this->type = self::TYPE_OBJECT;
- $this->class = \get_class($value);
-
- if ($value instanceof \Closure) {
- ReflectionCaster::castClosure($value, [], $this, true, Caster::EXCLUDE_VERBOSE);
- }
-
- $this->cut = -1;
- break;
-
- case 'array':
- $this->type = self::TYPE_ARRAY;
- $this->class = self::ARRAY_ASSOC;
- $this->cut = $this->value = \count($value);
- break;
-
- case 'resource':
- case 'unknown type':
- case 'resource (closed)':
- $this->type = self::TYPE_RESOURCE;
- $this->handle = (int) $value;
- if ('Unknown' === $this->class = @get_resource_type($value)) {
- $this->class = 'Closed';
- }
- $this->cut = -1;
- break;
-
- case 'string':
- $this->type = self::TYPE_STRING;
- $this->class = preg_match('//u', $value) ? self::STRING_UTF8 : self::STRING_BINARY;
- $this->cut = self::STRING_BINARY === $this->class ? \strlen($value) : mb_strlen($value, 'UTF-8');
- $this->value = '';
- break;
- }
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DOMCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DOMCaster.php
deleted file mode 100644
index 4dd16e0..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DOMCaster.php
+++ /dev/null
@@ -1,304 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts DOM related classes to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class DOMCaster
-{
- private const ERROR_CODES = [
- \DOM_PHP_ERR => 'DOM_PHP_ERR',
- \DOM_INDEX_SIZE_ERR => 'DOM_INDEX_SIZE_ERR',
- \DOMSTRING_SIZE_ERR => 'DOMSTRING_SIZE_ERR',
- \DOM_HIERARCHY_REQUEST_ERR => 'DOM_HIERARCHY_REQUEST_ERR',
- \DOM_WRONG_DOCUMENT_ERR => 'DOM_WRONG_DOCUMENT_ERR',
- \DOM_INVALID_CHARACTER_ERR => 'DOM_INVALID_CHARACTER_ERR',
- \DOM_NO_DATA_ALLOWED_ERR => 'DOM_NO_DATA_ALLOWED_ERR',
- \DOM_NO_MODIFICATION_ALLOWED_ERR => 'DOM_NO_MODIFICATION_ALLOWED_ERR',
- \DOM_NOT_FOUND_ERR => 'DOM_NOT_FOUND_ERR',
- \DOM_NOT_SUPPORTED_ERR => 'DOM_NOT_SUPPORTED_ERR',
- \DOM_INUSE_ATTRIBUTE_ERR => 'DOM_INUSE_ATTRIBUTE_ERR',
- \DOM_INVALID_STATE_ERR => 'DOM_INVALID_STATE_ERR',
- \DOM_SYNTAX_ERR => 'DOM_SYNTAX_ERR',
- \DOM_INVALID_MODIFICATION_ERR => 'DOM_INVALID_MODIFICATION_ERR',
- \DOM_NAMESPACE_ERR => 'DOM_NAMESPACE_ERR',
- \DOM_INVALID_ACCESS_ERR => 'DOM_INVALID_ACCESS_ERR',
- \DOM_VALIDATION_ERR => 'DOM_VALIDATION_ERR',
- ];
-
- private const NODE_TYPES = [
- \XML_ELEMENT_NODE => 'XML_ELEMENT_NODE',
- \XML_ATTRIBUTE_NODE => 'XML_ATTRIBUTE_NODE',
- \XML_TEXT_NODE => 'XML_TEXT_NODE',
- \XML_CDATA_SECTION_NODE => 'XML_CDATA_SECTION_NODE',
- \XML_ENTITY_REF_NODE => 'XML_ENTITY_REF_NODE',
- \XML_ENTITY_NODE => 'XML_ENTITY_NODE',
- \XML_PI_NODE => 'XML_PI_NODE',
- \XML_COMMENT_NODE => 'XML_COMMENT_NODE',
- \XML_DOCUMENT_NODE => 'XML_DOCUMENT_NODE',
- \XML_DOCUMENT_TYPE_NODE => 'XML_DOCUMENT_TYPE_NODE',
- \XML_DOCUMENT_FRAG_NODE => 'XML_DOCUMENT_FRAG_NODE',
- \XML_NOTATION_NODE => 'XML_NOTATION_NODE',
- \XML_HTML_DOCUMENT_NODE => 'XML_HTML_DOCUMENT_NODE',
- \XML_DTD_NODE => 'XML_DTD_NODE',
- \XML_ELEMENT_DECL_NODE => 'XML_ELEMENT_DECL_NODE',
- \XML_ATTRIBUTE_DECL_NODE => 'XML_ATTRIBUTE_DECL_NODE',
- \XML_ENTITY_DECL_NODE => 'XML_ENTITY_DECL_NODE',
- \XML_NAMESPACE_DECL_NODE => 'XML_NAMESPACE_DECL_NODE',
- ];
-
- public static function castException(\DOMException $e, array $a, Stub $stub, bool $isNested)
- {
- $k = Caster::PREFIX_PROTECTED.'code';
- if (isset($a[$k], self::ERROR_CODES[$a[$k]])) {
- $a[$k] = new ConstStub(self::ERROR_CODES[$a[$k]], $a[$k]);
- }
-
- return $a;
- }
-
- public static function castLength($dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'length' => $dom->length,
- ];
-
- return $a;
- }
-
- public static function castImplementation(\DOMImplementation $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'Core' => '1.0',
- Caster::PREFIX_VIRTUAL.'XML' => '2.0',
- ];
-
- return $a;
- }
-
- public static function castNode(\DOMNode $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'nodeName' => $dom->nodeName,
- 'nodeValue' => new CutStub($dom->nodeValue),
- 'nodeType' => new ConstStub(self::NODE_TYPES[$dom->nodeType], $dom->nodeType),
- 'parentNode' => new CutStub($dom->parentNode),
- 'childNodes' => $dom->childNodes,
- 'firstChild' => new CutStub($dom->firstChild),
- 'lastChild' => new CutStub($dom->lastChild),
- 'previousSibling' => new CutStub($dom->previousSibling),
- 'nextSibling' => new CutStub($dom->nextSibling),
- 'attributes' => $dom->attributes,
- 'ownerDocument' => new CutStub($dom->ownerDocument),
- 'namespaceURI' => $dom->namespaceURI,
- 'prefix' => $dom->prefix,
- 'localName' => $dom->localName,
- 'baseURI' => $dom->baseURI ? new LinkStub($dom->baseURI) : $dom->baseURI,
- 'textContent' => new CutStub($dom->textContent),
- ];
-
- return $a;
- }
-
- public static function castNameSpaceNode(\DOMNameSpaceNode $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'nodeName' => $dom->nodeName,
- 'nodeValue' => new CutStub($dom->nodeValue),
- 'nodeType' => new ConstStub(self::NODE_TYPES[$dom->nodeType], $dom->nodeType),
- 'prefix' => $dom->prefix,
- 'localName' => $dom->localName,
- 'namespaceURI' => $dom->namespaceURI,
- 'ownerDocument' => new CutStub($dom->ownerDocument),
- 'parentNode' => new CutStub($dom->parentNode),
- ];
-
- return $a;
- }
-
- public static function castDocument(\DOMDocument $dom, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $a += [
- 'doctype' => $dom->doctype,
- 'implementation' => $dom->implementation,
- 'documentElement' => new CutStub($dom->documentElement),
- 'actualEncoding' => $dom->actualEncoding,
- 'encoding' => $dom->encoding,
- 'xmlEncoding' => $dom->xmlEncoding,
- 'standalone' => $dom->standalone,
- 'xmlStandalone' => $dom->xmlStandalone,
- 'version' => $dom->version,
- 'xmlVersion' => $dom->xmlVersion,
- 'strictErrorChecking' => $dom->strictErrorChecking,
- 'documentURI' => $dom->documentURI ? new LinkStub($dom->documentURI) : $dom->documentURI,
- 'config' => $dom->config,
- 'formatOutput' => $dom->formatOutput,
- 'validateOnParse' => $dom->validateOnParse,
- 'resolveExternals' => $dom->resolveExternals,
- 'preserveWhiteSpace' => $dom->preserveWhiteSpace,
- 'recover' => $dom->recover,
- 'substituteEntities' => $dom->substituteEntities,
- ];
-
- if (!($filter & Caster::EXCLUDE_VERBOSE)) {
- $formatOutput = $dom->formatOutput;
- $dom->formatOutput = true;
- $a += [Caster::PREFIX_VIRTUAL.'xml' => $dom->saveXML()];
- $dom->formatOutput = $formatOutput;
- }
-
- return $a;
- }
-
- public static function castCharacterData(\DOMCharacterData $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'data' => $dom->data,
- 'length' => $dom->length,
- ];
-
- return $a;
- }
-
- public static function castAttr(\DOMAttr $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'name' => $dom->name,
- 'specified' => $dom->specified,
- 'value' => $dom->value,
- 'ownerElement' => $dom->ownerElement,
- 'schemaTypeInfo' => $dom->schemaTypeInfo,
- ];
-
- return $a;
- }
-
- public static function castElement(\DOMElement $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'tagName' => $dom->tagName,
- 'schemaTypeInfo' => $dom->schemaTypeInfo,
- ];
-
- return $a;
- }
-
- public static function castText(\DOMText $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'wholeText' => $dom->wholeText,
- ];
-
- return $a;
- }
-
- public static function castTypeinfo(\DOMTypeinfo $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'typeName' => $dom->typeName,
- 'typeNamespace' => $dom->typeNamespace,
- ];
-
- return $a;
- }
-
- public static function castDomError(\DOMDomError $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'severity' => $dom->severity,
- 'message' => $dom->message,
- 'type' => $dom->type,
- 'relatedException' => $dom->relatedException,
- 'related_data' => $dom->related_data,
- 'location' => $dom->location,
- ];
-
- return $a;
- }
-
- public static function castLocator(\DOMLocator $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'lineNumber' => $dom->lineNumber,
- 'columnNumber' => $dom->columnNumber,
- 'offset' => $dom->offset,
- 'relatedNode' => $dom->relatedNode,
- 'uri' => $dom->uri ? new LinkStub($dom->uri, $dom->lineNumber) : $dom->uri,
- ];
-
- return $a;
- }
-
- public static function castDocumentType(\DOMDocumentType $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'name' => $dom->name,
- 'entities' => $dom->entities,
- 'notations' => $dom->notations,
- 'publicId' => $dom->publicId,
- 'systemId' => $dom->systemId,
- 'internalSubset' => $dom->internalSubset,
- ];
-
- return $a;
- }
-
- public static function castNotation(\DOMNotation $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'publicId' => $dom->publicId,
- 'systemId' => $dom->systemId,
- ];
-
- return $a;
- }
-
- public static function castEntity(\DOMEntity $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'publicId' => $dom->publicId,
- 'systemId' => $dom->systemId,
- 'notationName' => $dom->notationName,
- 'actualEncoding' => $dom->actualEncoding,
- 'encoding' => $dom->encoding,
- 'version' => $dom->version,
- ];
-
- return $a;
- }
-
- public static function castProcessingInstruction(\DOMProcessingInstruction $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'target' => $dom->target,
- 'data' => $dom->data,
- ];
-
- return $a;
- }
-
- public static function castXPath(\DOMXPath $dom, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- 'document' => $dom->document,
- ];
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DateCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DateCaster.php
deleted file mode 100644
index 99f5384..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DateCaster.php
+++ /dev/null
@@ -1,127 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts DateTimeInterface related classes to array representation.
- *
- * @author Dany Maillard <danymaillard93b@gmail.com>
- *
- * @final
- */
-class DateCaster
-{
- private const PERIOD_LIMIT = 3;
-
- public static function castDateTime(\DateTimeInterface $d, array $a, Stub $stub, bool $isNested, int $filter)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
- $location = $d->getTimezone()->getLocation();
- $fromNow = (new \DateTime())->diff($d);
-
- $title = $d->format('l, F j, Y')
- ."\n".self::formatInterval($fromNow).' from now'
- .($location ? ($d->format('I') ? "\nDST On" : "\nDST Off") : '')
- ;
-
- unset(
- $a[Caster::PREFIX_DYNAMIC.'date'],
- $a[Caster::PREFIX_DYNAMIC.'timezone'],
- $a[Caster::PREFIX_DYNAMIC.'timezone_type']
- );
- $a[$prefix.'date'] = new ConstStub(self::formatDateTime($d, $location ? ' e (P)' : ' P'), $title);
-
- $stub->class .= $d->format(' @U');
-
- return $a;
- }
-
- public static function castInterval(\DateInterval $interval, array $a, Stub $stub, bool $isNested, int $filter)
- {
- $now = new \DateTimeImmutable('@0', new \DateTimeZone('UTC'));
- $numberOfSeconds = $now->add($interval)->getTimestamp() - $now->getTimestamp();
- $title = number_format($numberOfSeconds, 0, '.', ' ').'s';
-
- $i = [Caster::PREFIX_VIRTUAL.'interval' => new ConstStub(self::formatInterval($interval), $title)];
-
- return $filter & Caster::EXCLUDE_VERBOSE ? $i : $i + $a;
- }
-
- private static function formatInterval(\DateInterval $i): string
- {
- $format = '%R ';
-
- if (0 === $i->y && 0 === $i->m && ($i->h >= 24 || $i->i >= 60 || $i->s >= 60)) {
- $d = new \DateTimeImmutable('@0', new \DateTimeZone('UTC'));
- $i = $d->diff($d->add($i)); // recalculate carry over points
- $format .= 0 < $i->days ? '%ad ' : '';
- } else {
- $format .= ($i->y ? '%yy ' : '').($i->m ? '%mm ' : '').($i->d ? '%dd ' : '');
- }
-
- $format .= $i->h || $i->i || $i->s || $i->f ? '%H:%I:'.self::formatSeconds($i->s, substr($i->f, 2)) : '';
- $format = '%R ' === $format ? '0s' : $format;
-
- return $i->format(rtrim($format));
- }
-
- public static function castTimeZone(\DateTimeZone $timeZone, array $a, Stub $stub, bool $isNested, int $filter)
- {
- $location = $timeZone->getLocation();
- $formatted = (new \DateTime('now', $timeZone))->format($location ? 'e (P)' : 'P');
- $title = $location && \extension_loaded('intl') ? \Locale::getDisplayRegion('-'.$location['country_code']) : '';
-
- $z = [Caster::PREFIX_VIRTUAL.'timezone' => new ConstStub($formatted, $title)];
-
- return $filter & Caster::EXCLUDE_VERBOSE ? $z : $z + $a;
- }
-
- public static function castPeriod(\DatePeriod $p, array $a, Stub $stub, bool $isNested, int $filter)
- {
- $dates = [];
- foreach (clone $p as $i => $d) {
- if (self::PERIOD_LIMIT === $i) {
- $now = new \DateTimeImmutable('now', new \DateTimeZone('UTC'));
- $dates[] = sprintf('%s more', ($end = $p->getEndDate())
- ? ceil(($end->format('U.u') - $d->format('U.u')) / ((int) $now->add($p->getDateInterval())->format('U.u') - (int) $now->format('U.u')))
- : $p->recurrences - $i
- );
- break;
- }
- $dates[] = sprintf('%s) %s', $i + 1, self::formatDateTime($d));
- }
-
- $period = sprintf(
- 'every %s, from %s (%s) %s',
- self::formatInterval($p->getDateInterval()),
- self::formatDateTime($p->getStartDate()),
- $p->include_start_date ? 'included' : 'excluded',
- ($end = $p->getEndDate()) ? 'to '.self::formatDateTime($end) : 'recurring '.$p->recurrences.' time/s'
- );
-
- $p = [Caster::PREFIX_VIRTUAL.'period' => new ConstStub($period, implode("\n", $dates))];
-
- return $filter & Caster::EXCLUDE_VERBOSE ? $p : $p + $a;
- }
-
- private static function formatDateTime(\DateTimeInterface $d, string $extra = ''): string
- {
- return $d->format('Y-m-d H:i:'.self::formatSeconds($d->format('s'), $d->format('u')).$extra);
- }
-
- private static function formatSeconds(string $s, string $us): string
- {
- return sprintf('%02d.%s', $s, 0 === ($len = \strlen($t = rtrim($us, '0'))) ? '0' : ($len <= 3 ? str_pad($t, 3, '0') : $us));
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DoctrineCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DoctrineCaster.php
deleted file mode 100644
index 129b2cb..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DoctrineCaster.php
+++ /dev/null
@@ -1,62 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Doctrine\Common\Proxy\Proxy as CommonProxy;
-use Doctrine\ORM\PersistentCollection;
-use Doctrine\ORM\Proxy\Proxy as OrmProxy;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts Doctrine related classes to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class DoctrineCaster
-{
- public static function castCommonProxy(CommonProxy $proxy, array $a, Stub $stub, bool $isNested)
- {
- foreach (['__cloner__', '__initializer__'] as $k) {
- if (\array_key_exists($k, $a)) {
- unset($a[$k]);
- ++$stub->cut;
- }
- }
-
- return $a;
- }
-
- public static function castOrmProxy(OrmProxy $proxy, array $a, Stub $stub, bool $isNested)
- {
- foreach (['_entityPersister', '_identifier'] as $k) {
- if (\array_key_exists($k = "\0Doctrine\\ORM\\Proxy\\Proxy\0".$k, $a)) {
- unset($a[$k]);
- ++$stub->cut;
- }
- }
-
- return $a;
- }
-
- public static function castPersistentCollection(PersistentCollection $coll, array $a, Stub $stub, bool $isNested)
- {
- foreach (['snapshot', 'association', 'typeClass'] as $k) {
- if (\array_key_exists($k = "\0Doctrine\\ORM\\PersistentCollection\0".$k, $a)) {
- $a[$k] = new CutStub($a[$k]);
- }
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DsCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DsCaster.php
deleted file mode 100644
index b34b670..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DsCaster.php
+++ /dev/null
@@ -1,70 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Ds\Collection;
-use Ds\Map;
-use Ds\Pair;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts Ds extension classes to array representation.
- *
- * @author Jáchym Toušek <enumag@gmail.com>
- *
- * @final
- */
-class DsCaster
-{
- public static function castCollection(Collection $c, array $a, Stub $stub, bool $isNested): array
- {
- $a[Caster::PREFIX_VIRTUAL.'count'] = $c->count();
- $a[Caster::PREFIX_VIRTUAL.'capacity'] = $c->capacity();
-
- if (!$c instanceof Map) {
- $a += $c->toArray();
- }
-
- return $a;
- }
-
- public static function castMap(Map $c, array $a, Stub $stub, bool $isNested): array
- {
- foreach ($c as $k => $v) {
- $a[] = new DsPairStub($k, $v);
- }
-
- return $a;
- }
-
- public static function castPair(Pair $c, array $a, Stub $stub, bool $isNested): array
- {
- foreach ($c->toArray() as $k => $v) {
- $a[Caster::PREFIX_VIRTUAL.$k] = $v;
- }
-
- return $a;
- }
-
- public static function castPairStub(DsPairStub $c, array $a, Stub $stub, bool $isNested): array
- {
- if ($isNested) {
- $stub->class = Pair::class;
- $stub->value = null;
- $stub->handle = 0;
-
- $a = $c->value;
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DsPairStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DsPairStub.php
deleted file mode 100644
index 22112af..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/DsPairStub.php
+++ /dev/null
@@ -1,28 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class DsPairStub extends Stub
-{
- public function __construct(string|int $key, mixed $value)
- {
- $this->value = [
- Caster::PREFIX_VIRTUAL.'key' => $key,
- Caster::PREFIX_VIRTUAL.'value' => $value,
- ];
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/EnumStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/EnumStub.php
deleted file mode 100644
index 7a4e98a..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/EnumStub.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Represents an enumeration of values.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class EnumStub extends Stub
-{
- public $dumpKeys = true;
-
- public function __construct(array $values, bool $dumpKeys = true)
- {
- $this->value = $values;
- $this->dumpKeys = $dumpKeys;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ExceptionCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ExceptionCaster.php
deleted file mode 100644
index 8e517e0..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ExceptionCaster.php
+++ /dev/null
@@ -1,388 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\ErrorHandler\Exception\SilencedErrorContext;
-use Symfony\Component\VarDumper\Cloner\Stub;
-use Symfony\Component\VarDumper\Exception\ThrowingCasterException;
-
-/**
- * Casts common Exception classes to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class ExceptionCaster
-{
- public static int $srcContext = 1;
- public static bool $traceArgs = true;
- public static array $errorTypes = [
- \E_DEPRECATED => 'E_DEPRECATED',
- \E_USER_DEPRECATED => 'E_USER_DEPRECATED',
- \E_RECOVERABLE_ERROR => 'E_RECOVERABLE_ERROR',
- \E_ERROR => 'E_ERROR',
- \E_WARNING => 'E_WARNING',
- \E_PARSE => 'E_PARSE',
- \E_NOTICE => 'E_NOTICE',
- \E_CORE_ERROR => 'E_CORE_ERROR',
- \E_CORE_WARNING => 'E_CORE_WARNING',
- \E_COMPILE_ERROR => 'E_COMPILE_ERROR',
- \E_COMPILE_WARNING => 'E_COMPILE_WARNING',
- \E_USER_ERROR => 'E_USER_ERROR',
- \E_USER_WARNING => 'E_USER_WARNING',
- \E_USER_NOTICE => 'E_USER_NOTICE',
- \E_STRICT => 'E_STRICT',
- ];
-
- private static array $framesCache = [];
-
- public static function castError(\Error $e, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- return self::filterExceptionArray($stub->class, $a, "\0Error\0", $filter);
- }
-
- public static function castException(\Exception $e, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- return self::filterExceptionArray($stub->class, $a, "\0Exception\0", $filter);
- }
-
- public static function castErrorException(\ErrorException $e, array $a, Stub $stub, bool $isNested)
- {
- if (isset($a[$s = Caster::PREFIX_PROTECTED.'severity'], self::$errorTypes[$a[$s]])) {
- $a[$s] = new ConstStub(self::$errorTypes[$a[$s]], $a[$s]);
- }
-
- return $a;
- }
-
- public static function castThrowingCasterException(ThrowingCasterException $e, array $a, Stub $stub, bool $isNested)
- {
- $trace = Caster::PREFIX_VIRTUAL.'trace';
- $prefix = Caster::PREFIX_PROTECTED;
- $xPrefix = "\0Exception\0";
-
- if (isset($a[$xPrefix.'previous'], $a[$trace]) && $a[$xPrefix.'previous'] instanceof \Exception) {
- $b = (array) $a[$xPrefix.'previous'];
- $class = get_debug_type($a[$xPrefix.'previous']);
- self::traceUnshift($b[$xPrefix.'trace'], $class, $b[$prefix.'file'], $b[$prefix.'line']);
- $a[$trace] = new TraceStub($b[$xPrefix.'trace'], false, 0, -\count($a[$trace]->value));
- }
-
- unset($a[$xPrefix.'previous'], $a[$prefix.'code'], $a[$prefix.'file'], $a[$prefix.'line']);
-
- return $a;
- }
-
- public static function castSilencedErrorContext(SilencedErrorContext $e, array $a, Stub $stub, bool $isNested)
- {
- $sPrefix = "\0".SilencedErrorContext::class."\0";
-
- if (!isset($a[$s = $sPrefix.'severity'])) {
- return $a;
- }
-
- if (isset(self::$errorTypes[$a[$s]])) {
- $a[$s] = new ConstStub(self::$errorTypes[$a[$s]], $a[$s]);
- }
-
- $trace = [[
- 'file' => $a[$sPrefix.'file'],
- 'line' => $a[$sPrefix.'line'],
- ]];
-
- if (isset($a[$sPrefix.'trace'])) {
- $trace = array_merge($trace, $a[$sPrefix.'trace']);
- }
-
- unset($a[$sPrefix.'file'], $a[$sPrefix.'line'], $a[$sPrefix.'trace']);
- $a[Caster::PREFIX_VIRTUAL.'trace'] = new TraceStub($trace, self::$traceArgs);
-
- return $a;
- }
-
- public static function castTraceStub(TraceStub $trace, array $a, Stub $stub, bool $isNested)
- {
- if (!$isNested) {
- return $a;
- }
- $stub->class = '';
- $stub->handle = 0;
- $frames = $trace->value;
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a = [];
- $j = \count($frames);
- if (0 > $i = $trace->sliceOffset) {
- $i = max(0, $j + $i);
- }
- if (!isset($trace->value[$i])) {
- return [];
- }
- $lastCall = isset($frames[$i]['function']) ? (isset($frames[$i]['class']) ? $frames[0]['class'].$frames[$i]['type'] : '').$frames[$i]['function'].'()' : '';
- $frames[] = ['function' => ''];
- $collapse = false;
-
- for ($j += $trace->numberingOffset - $i++; isset($frames[$i]); ++$i, --$j) {
- $f = $frames[$i];
- $call = isset($f['function']) ? (isset($f['class']) ? $f['class'].$f['type'] : '').$f['function'] : '???';
-
- $frame = new FrameStub(
- [
- 'object' => $f['object'] ?? null,
- 'class' => $f['class'] ?? null,
- 'type' => $f['type'] ?? null,
- 'function' => $f['function'] ?? null,
- ] + $frames[$i - 1],
- false,
- true
- );
- $f = self::castFrameStub($frame, [], $frame, true);
- if (isset($f[$prefix.'src'])) {
- foreach ($f[$prefix.'src']->value as $label => $frame) {
- if (str_starts_with($label, "\0~collapse=0")) {
- if ($collapse) {
- $label = substr_replace($label, '1', 11, 1);
- } else {
- $collapse = true;
- }
- }
- $label = substr_replace($label, "title=Stack level $j.&", 2, 0);
- }
- $f = $frames[$i - 1];
- if ($trace->keepArgs && !empty($f['args']) && $frame instanceof EnumStub) {
- $frame->value['arguments'] = new ArgsStub($f['args'], $f['function'] ?? null, $f['class'] ?? null);
- }
- } elseif ('???' !== $lastCall) {
- $label = new ClassStub($lastCall);
- if (isset($label->attr['ellipsis'])) {
- $label->attr['ellipsis'] += 2;
- $label = substr_replace($prefix, "ellipsis-type=class&ellipsis={$label->attr['ellipsis']}&ellipsis-tail=1&title=Stack level $j.", 2, 0).$label->value.'()';
- } else {
- $label = substr_replace($prefix, "title=Stack level $j.", 2, 0).$label->value.'()';
- }
- } else {
- $label = substr_replace($prefix, "title=Stack level $j.", 2, 0).$lastCall;
- }
- $a[substr_replace($label, sprintf('separator=%s&', $frame instanceof EnumStub ? ' ' : ':'), 2, 0)] = $frame;
-
- $lastCall = $call;
- }
- if (null !== $trace->sliceLength) {
- $a = \array_slice($a, 0, $trace->sliceLength, true);
- }
-
- return $a;
- }
-
- public static function castFrameStub(FrameStub $frame, array $a, Stub $stub, bool $isNested)
- {
- if (!$isNested) {
- return $a;
- }
- $f = $frame->value;
- $prefix = Caster::PREFIX_VIRTUAL;
-
- if (isset($f['file'], $f['line'])) {
- $cacheKey = $f;
- unset($cacheKey['object'], $cacheKey['args']);
- $cacheKey[] = self::$srcContext;
- $cacheKey = implode('-', $cacheKey);
-
- if (isset(self::$framesCache[$cacheKey])) {
- $a[$prefix.'src'] = self::$framesCache[$cacheKey];
- } else {
- if (preg_match('/\((\d+)\)(?:\([\da-f]{32}\))? : (?:eval\(\)\'d code|runtime-created function)$/', $f['file'], $match)) {
- $f['file'] = substr($f['file'], 0, -\strlen($match[0]));
- $f['line'] = (int) $match[1];
- }
- $src = $f['line'];
- $srcKey = $f['file'];
- $ellipsis = new LinkStub($srcKey, 0);
- $srcAttr = 'collapse='.(int) $ellipsis->inVendor;
- $ellipsisTail = $ellipsis->attr['ellipsis-tail'] ?? 0;
- $ellipsis = $ellipsis->attr['ellipsis'] ?? 0;
-
- if (is_file($f['file']) && 0 <= self::$srcContext) {
- if (!empty($f['class']) && (is_subclass_of($f['class'], 'Twig\Template') || is_subclass_of($f['class'], 'Twig_Template')) && method_exists($f['class'], 'getDebugInfo')) {
- $template = null;
- if (isset($f['object'])) {
- $template = $f['object'];
- } elseif ((new \ReflectionClass($f['class']))->isInstantiable()) {
- $template = unserialize(sprintf('O:%d:"%s":0:{}', \strlen($f['class']), $f['class']));
- }
- if (null !== $template) {
- $ellipsis = 0;
- $templateSrc = method_exists($template, 'getSourceContext') ? $template->getSourceContext()->getCode() : (method_exists($template, 'getSource') ? $template->getSource() : '');
- $templateInfo = $template->getDebugInfo();
- if (isset($templateInfo[$f['line']])) {
- if (!method_exists($template, 'getSourceContext') || !is_file($templatePath = $template->getSourceContext()->getPath())) {
- $templatePath = null;
- }
- if ($templateSrc) {
- $src = self::extractSource($templateSrc, $templateInfo[$f['line']], self::$srcContext, 'twig', $templatePath, $f);
- $srcKey = ($templatePath ?: $template->getTemplateName()).':'.$templateInfo[$f['line']];
- }
- }
- }
- }
- if ($srcKey == $f['file']) {
- $src = self::extractSource(file_get_contents($f['file']), $f['line'], self::$srcContext, 'php', $f['file'], $f);
- $srcKey .= ':'.$f['line'];
- if ($ellipsis) {
- $ellipsis += 1 + \strlen($f['line']);
- }
- }
- $srcAttr .= sprintf('&separator= &file=%s&line=%d', rawurlencode($f['file']), $f['line']);
- } else {
- $srcAttr .= '&separator=:';
- }
- $srcAttr .= $ellipsis ? '&ellipsis-type=path&ellipsis='.$ellipsis.'&ellipsis-tail='.$ellipsisTail : '';
- self::$framesCache[$cacheKey] = $a[$prefix.'src'] = new EnumStub(["\0~$srcAttr\0$srcKey" => $src]);
- }
- }
-
- unset($a[$prefix.'args'], $a[$prefix.'line'], $a[$prefix.'file']);
- if ($frame->inTraceStub) {
- unset($a[$prefix.'class'], $a[$prefix.'type'], $a[$prefix.'function']);
- }
- foreach ($a as $k => $v) {
- if (!$v) {
- unset($a[$k]);
- }
- }
- if ($frame->keepArgs && !empty($f['args'])) {
- $a[$prefix.'arguments'] = new ArgsStub($f['args'], $f['function'], $f['class']);
- }
-
- return $a;
- }
-
- private static function filterExceptionArray(string $xClass, array $a, string $xPrefix, int $filter): array
- {
- if (isset($a[$xPrefix.'trace'])) {
- $trace = $a[$xPrefix.'trace'];
- unset($a[$xPrefix.'trace']); // Ensures the trace is always last
- } else {
- $trace = [];
- }
-
- if (!($filter & Caster::EXCLUDE_VERBOSE) && $trace) {
- if (isset($a[Caster::PREFIX_PROTECTED.'file'], $a[Caster::PREFIX_PROTECTED.'line'])) {
- self::traceUnshift($trace, $xClass, $a[Caster::PREFIX_PROTECTED.'file'], $a[Caster::PREFIX_PROTECTED.'line']);
- }
- $a[Caster::PREFIX_VIRTUAL.'trace'] = new TraceStub($trace, self::$traceArgs);
- }
- if (empty($a[$xPrefix.'previous'])) {
- unset($a[$xPrefix.'previous']);
- }
- unset($a[$xPrefix.'string'], $a[Caster::PREFIX_DYNAMIC.'xdebug_message'], $a[Caster::PREFIX_DYNAMIC.'__destructorException']);
-
- if (isset($a[Caster::PREFIX_PROTECTED.'message']) && str_contains($a[Caster::PREFIX_PROTECTED.'message'], "@anonymous\0")) {
- $a[Caster::PREFIX_PROTECTED.'message'] = preg_replace_callback('/[a-zA-Z_\x7f-\xff][\\\\a-zA-Z0-9_\x7f-\xff]*+@anonymous\x00.*?\.php(?:0x?|:[0-9]++\$)[0-9a-fA-F]++/', function ($m) {
- return class_exists($m[0], false) ? (get_parent_class($m[0]) ?: key(class_implements($m[0])) ?: 'class').'@anonymous' : $m[0];
- }, $a[Caster::PREFIX_PROTECTED.'message']);
- }
-
- if (isset($a[Caster::PREFIX_PROTECTED.'file'], $a[Caster::PREFIX_PROTECTED.'line'])) {
- $a[Caster::PREFIX_PROTECTED.'file'] = new LinkStub($a[Caster::PREFIX_PROTECTED.'file'], $a[Caster::PREFIX_PROTECTED.'line']);
- }
-
- return $a;
- }
-
- private static function traceUnshift(array &$trace, ?string $class, string $file, int $line): void
- {
- if (isset($trace[0]['file'], $trace[0]['line']) && $trace[0]['file'] === $file && $trace[0]['line'] === $line) {
- return;
- }
- array_unshift($trace, [
- 'function' => $class ? 'new '.$class : null,
- 'file' => $file,
- 'line' => $line,
- ]);
- }
-
- private static function extractSource(string $srcLines, int $line, int $srcContext, string $lang, ?string $file, array $frame): EnumStub
- {
- $srcLines = explode("\n", $srcLines);
- $src = [];
-
- for ($i = $line - 1 - $srcContext; $i <= $line - 1 + $srcContext; ++$i) {
- $src[] = ($srcLines[$i] ?? '')."\n";
- }
-
- if ($frame['function'] ?? false) {
- $stub = new CutStub(new \stdClass());
- $stub->class = (isset($frame['class']) ? $frame['class'].$frame['type'] : '').$frame['function'];
- $stub->type = Stub::TYPE_OBJECT;
- $stub->attr['cut_hash'] = true;
- $stub->attr['file'] = $frame['file'];
- $stub->attr['line'] = $frame['line'];
-
- try {
- $caller = isset($frame['class']) ? new \ReflectionMethod($frame['class'], $frame['function']) : new \ReflectionFunction($frame['function']);
- $stub->class .= ReflectionCaster::getSignature(ReflectionCaster::castFunctionAbstract($caller, [], $stub, true, Caster::EXCLUDE_VERBOSE));
-
- if ($f = $caller->getFileName()) {
- $stub->attr['file'] = $f;
- $stub->attr['line'] = $caller->getStartLine();
- }
- } catch (\ReflectionException $e) {
- // ignore fake class/function
- }
-
- $srcLines = ["\0~separator=\0" => $stub];
- } else {
- $stub = null;
- $srcLines = [];
- }
-
- $ltrim = 0;
- do {
- $pad = null;
- for ($i = $srcContext << 1; $i >= 0; --$i) {
- if (isset($src[$i][$ltrim]) && "\r" !== ($c = $src[$i][$ltrim]) && "\n" !== $c) {
- if (null === $pad) {
- $pad = $c;
- }
- if ((' ' !== $c && "\t" !== $c) || $pad !== $c) {
- break;
- }
- }
- }
- ++$ltrim;
- } while (0 > $i && null !== $pad);
-
- --$ltrim;
-
- foreach ($src as $i => $c) {
- if ($ltrim) {
- $c = isset($c[$ltrim]) && "\r" !== $c[$ltrim] ? substr($c, $ltrim) : ltrim($c, " \t");
- }
- $c = substr($c, 0, -1);
- if ($i !== $srcContext) {
- $c = new ConstStub('default', $c);
- } else {
- $c = new ConstStub($c, $stub ? 'in '.$stub->class : '');
- if (null !== $file) {
- $c->attr['file'] = $file;
- $c->attr['line'] = $line;
- }
- }
- $c->attr['lang'] = $lang;
- $srcLines[sprintf("\0~separator=› &%d\0", $i + $line - $srcContext)] = $c;
- }
-
- return new EnumStub($srcLines);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/FiberCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/FiberCaster.php
deleted file mode 100644
index c74a9e5..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/FiberCaster.php
+++ /dev/null
@@ -1,43 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts Fiber related classes to array representation.
- *
- * @author Grégoire Pineau <lyrixx@lyrixx.info>
- */
-final class FiberCaster
-{
- public static function castFiber(\Fiber $fiber, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- if ($fiber->isTerminated()) {
- $status = 'terminated';
- } elseif ($fiber->isRunning()) {
- $status = 'running';
- } elseif ($fiber->isSuspended()) {
- $status = 'suspended';
- } elseif ($fiber->isStarted()) {
- $status = 'started';
- } else {
- $status = 'not started';
- }
-
- $a[$prefix.'status'] = $status;
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/FrameStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/FrameStub.php
deleted file mode 100644
index 8786755..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/FrameStub.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-/**
- * Represents a single backtrace frame as returned by debug_backtrace() or Exception->getTrace().
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class FrameStub extends EnumStub
-{
- public $keepArgs;
- public $inTraceStub;
-
- public function __construct(array $frame, bool $keepArgs = true, bool $inTraceStub = false)
- {
- $this->value = $frame;
- $this->keepArgs = $keepArgs;
- $this->inTraceStub = $inTraceStub;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/GmpCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/GmpCaster.php
deleted file mode 100644
index b018cc7..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/GmpCaster.php
+++ /dev/null
@@ -1,32 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts GMP objects to array representation.
- *
- * @author Hamza Amrouche <hamza.simperfit@gmail.com>
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class GmpCaster
-{
- public static function castGmp(\GMP $gmp, array $a, Stub $stub, bool $isNested, int $filter): array
- {
- $a[Caster::PREFIX_VIRTUAL.'value'] = new ConstStub(gmp_strval($gmp), gmp_strval($gmp));
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ImagineCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ImagineCaster.php
deleted file mode 100644
index d1289da..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ImagineCaster.php
+++ /dev/null
@@ -1,37 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Imagine\Image\ImageInterface;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @author Grégoire Pineau <lyrixx@lyrixx.info>
- */
-final class ImagineCaster
-{
- public static function castImage(ImageInterface $c, array $a, Stub $stub, bool $isNested): array
- {
- $imgData = $c->get('png');
- if (\strlen($imgData) > 1 * 1000 * 1000) {
- $a += [
- Caster::PREFIX_VIRTUAL.'image' => new ConstStub($c->getSize()),
- ];
- } else {
- $a += [
- Caster::PREFIX_VIRTUAL.'image' => new ImgStub($imgData, 'image/png', $c->getSize()),
- ];
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ImgStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ImgStub.php
deleted file mode 100644
index a16681f..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ImgStub.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-/**
- * @author Grégoire Pineau <lyrixx@lyrixx.info>
- */
-class ImgStub extends ConstStub
-{
- public function __construct(string $data, string $contentType, string $size = '')
- {
- $this->value = '';
- $this->attr['img-data'] = $data;
- $this->attr['img-size'] = $size;
- $this->attr['content-type'] = $contentType;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/IntlCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/IntlCaster.php
deleted file mode 100644
index 23b9d5d..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/IntlCaster.php
+++ /dev/null
@@ -1,172 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- * @author Jan Schädlich <jan.schaedlich@sensiolabs.de>
- *
- * @final
- */
-class IntlCaster
-{
- public static function castMessageFormatter(\MessageFormatter $c, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'locale' => $c->getLocale(),
- Caster::PREFIX_VIRTUAL.'pattern' => $c->getPattern(),
- ];
-
- return self::castError($c, $a);
- }
-
- public static function castNumberFormatter(\NumberFormatter $c, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'locale' => $c->getLocale(),
- Caster::PREFIX_VIRTUAL.'pattern' => $c->getPattern(),
- ];
-
- if ($filter & Caster::EXCLUDE_VERBOSE) {
- $stub->cut += 3;
-
- return self::castError($c, $a);
- }
-
- $a += [
- Caster::PREFIX_VIRTUAL.'attributes' => new EnumStub(
- [
- 'PARSE_INT_ONLY' => $c->getAttribute(\NumberFormatter::PARSE_INT_ONLY),
- 'GROUPING_USED' => $c->getAttribute(\NumberFormatter::GROUPING_USED),
- 'DECIMAL_ALWAYS_SHOWN' => $c->getAttribute(\NumberFormatter::DECIMAL_ALWAYS_SHOWN),
- 'MAX_INTEGER_DIGITS' => $c->getAttribute(\NumberFormatter::MAX_INTEGER_DIGITS),
- 'MIN_INTEGER_DIGITS' => $c->getAttribute(\NumberFormatter::MIN_INTEGER_DIGITS),
- 'INTEGER_DIGITS' => $c->getAttribute(\NumberFormatter::INTEGER_DIGITS),
- 'MAX_FRACTION_DIGITS' => $c->getAttribute(\NumberFormatter::MAX_FRACTION_DIGITS),
- 'MIN_FRACTION_DIGITS' => $c->getAttribute(\NumberFormatter::MIN_FRACTION_DIGITS),
- 'FRACTION_DIGITS' => $c->getAttribute(\NumberFormatter::FRACTION_DIGITS),
- 'MULTIPLIER' => $c->getAttribute(\NumberFormatter::MULTIPLIER),
- 'GROUPING_SIZE' => $c->getAttribute(\NumberFormatter::GROUPING_SIZE),
- 'ROUNDING_MODE' => $c->getAttribute(\NumberFormatter::ROUNDING_MODE),
- 'ROUNDING_INCREMENT' => $c->getAttribute(\NumberFormatter::ROUNDING_INCREMENT),
- 'FORMAT_WIDTH' => $c->getAttribute(\NumberFormatter::FORMAT_WIDTH),
- 'PADDING_POSITION' => $c->getAttribute(\NumberFormatter::PADDING_POSITION),
- 'SECONDARY_GROUPING_SIZE' => $c->getAttribute(\NumberFormatter::SECONDARY_GROUPING_SIZE),
- 'SIGNIFICANT_DIGITS_USED' => $c->getAttribute(\NumberFormatter::SIGNIFICANT_DIGITS_USED),
- 'MIN_SIGNIFICANT_DIGITS' => $c->getAttribute(\NumberFormatter::MIN_SIGNIFICANT_DIGITS),
- 'MAX_SIGNIFICANT_DIGITS' => $c->getAttribute(\NumberFormatter::MAX_SIGNIFICANT_DIGITS),
- 'LENIENT_PARSE' => $c->getAttribute(\NumberFormatter::LENIENT_PARSE),
- ]
- ),
- Caster::PREFIX_VIRTUAL.'text_attributes' => new EnumStub(
- [
- 'POSITIVE_PREFIX' => $c->getTextAttribute(\NumberFormatter::POSITIVE_PREFIX),
- 'POSITIVE_SUFFIX' => $c->getTextAttribute(\NumberFormatter::POSITIVE_SUFFIX),
- 'NEGATIVE_PREFIX' => $c->getTextAttribute(\NumberFormatter::NEGATIVE_PREFIX),
- 'NEGATIVE_SUFFIX' => $c->getTextAttribute(\NumberFormatter::NEGATIVE_SUFFIX),
- 'PADDING_CHARACTER' => $c->getTextAttribute(\NumberFormatter::PADDING_CHARACTER),
- 'CURRENCY_CODE' => $c->getTextAttribute(\NumberFormatter::CURRENCY_CODE),
- 'DEFAULT_RULESET' => $c->getTextAttribute(\NumberFormatter::DEFAULT_RULESET),
- 'PUBLIC_RULESETS' => $c->getTextAttribute(\NumberFormatter::PUBLIC_RULESETS),
- ]
- ),
- Caster::PREFIX_VIRTUAL.'symbols' => new EnumStub(
- [
- 'DECIMAL_SEPARATOR_SYMBOL' => $c->getSymbol(\NumberFormatter::DECIMAL_SEPARATOR_SYMBOL),
- 'GROUPING_SEPARATOR_SYMBOL' => $c->getSymbol(\NumberFormatter::GROUPING_SEPARATOR_SYMBOL),
- 'PATTERN_SEPARATOR_SYMBOL' => $c->getSymbol(\NumberFormatter::PATTERN_SEPARATOR_SYMBOL),
- 'PERCENT_SYMBOL' => $c->getSymbol(\NumberFormatter::PERCENT_SYMBOL),
- 'ZERO_DIGIT_SYMBOL' => $c->getSymbol(\NumberFormatter::ZERO_DIGIT_SYMBOL),
- 'DIGIT_SYMBOL' => $c->getSymbol(\NumberFormatter::DIGIT_SYMBOL),
- 'MINUS_SIGN_SYMBOL' => $c->getSymbol(\NumberFormatter::MINUS_SIGN_SYMBOL),
- 'PLUS_SIGN_SYMBOL' => $c->getSymbol(\NumberFormatter::PLUS_SIGN_SYMBOL),
- 'CURRENCY_SYMBOL' => $c->getSymbol(\NumberFormatter::CURRENCY_SYMBOL),
- 'INTL_CURRENCY_SYMBOL' => $c->getSymbol(\NumberFormatter::INTL_CURRENCY_SYMBOL),
- 'MONETARY_SEPARATOR_SYMBOL' => $c->getSymbol(\NumberFormatter::MONETARY_SEPARATOR_SYMBOL),
- 'EXPONENTIAL_SYMBOL' => $c->getSymbol(\NumberFormatter::EXPONENTIAL_SYMBOL),
- 'PERMILL_SYMBOL' => $c->getSymbol(\NumberFormatter::PERMILL_SYMBOL),
- 'PAD_ESCAPE_SYMBOL' => $c->getSymbol(\NumberFormatter::PAD_ESCAPE_SYMBOL),
- 'INFINITY_SYMBOL' => $c->getSymbol(\NumberFormatter::INFINITY_SYMBOL),
- 'NAN_SYMBOL' => $c->getSymbol(\NumberFormatter::NAN_SYMBOL),
- 'SIGNIFICANT_DIGIT_SYMBOL' => $c->getSymbol(\NumberFormatter::SIGNIFICANT_DIGIT_SYMBOL),
- 'MONETARY_GROUPING_SEPARATOR_SYMBOL' => $c->getSymbol(\NumberFormatter::MONETARY_GROUPING_SEPARATOR_SYMBOL),
- ]
- ),
- ];
-
- return self::castError($c, $a);
- }
-
- public static function castIntlTimeZone(\IntlTimeZone $c, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'display_name' => $c->getDisplayName(),
- Caster::PREFIX_VIRTUAL.'id' => $c->getID(),
- Caster::PREFIX_VIRTUAL.'raw_offset' => $c->getRawOffset(),
- ];
-
- if ($c->useDaylightTime()) {
- $a += [
- Caster::PREFIX_VIRTUAL.'dst_savings' => $c->getDSTSavings(),
- ];
- }
-
- return self::castError($c, $a);
- }
-
- public static function castIntlCalendar(\IntlCalendar $c, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'type' => $c->getType(),
- Caster::PREFIX_VIRTUAL.'first_day_of_week' => $c->getFirstDayOfWeek(),
- Caster::PREFIX_VIRTUAL.'minimal_days_in_first_week' => $c->getMinimalDaysInFirstWeek(),
- Caster::PREFIX_VIRTUAL.'repeated_wall_time_option' => $c->getRepeatedWallTimeOption(),
- Caster::PREFIX_VIRTUAL.'skipped_wall_time_option' => $c->getSkippedWallTimeOption(),
- Caster::PREFIX_VIRTUAL.'time' => $c->getTime(),
- Caster::PREFIX_VIRTUAL.'in_daylight_time' => $c->inDaylightTime(),
- Caster::PREFIX_VIRTUAL.'is_lenient' => $c->isLenient(),
- Caster::PREFIX_VIRTUAL.'time_zone' => ($filter & Caster::EXCLUDE_VERBOSE) ? new CutStub($c->getTimeZone()) : $c->getTimeZone(),
- ];
-
- return self::castError($c, $a);
- }
-
- public static function castIntlDateFormatter(\IntlDateFormatter $c, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'locale' => $c->getLocale(),
- Caster::PREFIX_VIRTUAL.'pattern' => $c->getPattern(),
- Caster::PREFIX_VIRTUAL.'calendar' => $c->getCalendar(),
- Caster::PREFIX_VIRTUAL.'time_zone_id' => $c->getTimeZoneId(),
- Caster::PREFIX_VIRTUAL.'time_type' => $c->getTimeType(),
- Caster::PREFIX_VIRTUAL.'date_type' => $c->getDateType(),
- Caster::PREFIX_VIRTUAL.'calendar_object' => ($filter & Caster::EXCLUDE_VERBOSE) ? new CutStub($c->getCalendarObject()) : $c->getCalendarObject(),
- Caster::PREFIX_VIRTUAL.'time_zone' => ($filter & Caster::EXCLUDE_VERBOSE) ? new CutStub($c->getTimeZone()) : $c->getTimeZone(),
- ];
-
- return self::castError($c, $a);
- }
-
- private static function castError(object $c, array $a): array
- {
- if ($errorCode = $c->getErrorCode()) {
- $a += [
- Caster::PREFIX_VIRTUAL.'error_code' => $errorCode,
- Caster::PREFIX_VIRTUAL.'error_message' => $c->getErrorMessage(),
- ];
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/LinkStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/LinkStub.php
deleted file mode 100644
index 36e0d3c..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/LinkStub.php
+++ /dev/null
@@ -1,108 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-/**
- * Represents a file or a URL.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class LinkStub extends ConstStub
-{
- public $inVendor = false;
-
- private static array $vendorRoots;
- private static array $composerRoots = [];
-
- public function __construct(string $label, int $line = 0, string $href = null)
- {
- $this->value = $label;
-
- if (null === $href) {
- $href = $label;
- }
- if (!\is_string($href)) {
- return;
- }
- if (str_starts_with($href, 'file://')) {
- if ($href === $label) {
- $label = substr($label, 7);
- }
- $href = substr($href, 7);
- } elseif (str_contains($href, '://')) {
- $this->attr['href'] = $href;
-
- return;
- }
- if (!is_file($href)) {
- return;
- }
- if ($line) {
- $this->attr['line'] = $line;
- }
- if ($label !== $this->attr['file'] = realpath($href) ?: $href) {
- return;
- }
- if ($composerRoot = $this->getComposerRoot($href, $this->inVendor)) {
- $this->attr['ellipsis'] = \strlen($href) - \strlen($composerRoot) + 1;
- $this->attr['ellipsis-type'] = 'path';
- $this->attr['ellipsis-tail'] = 1 + ($this->inVendor ? 2 + \strlen(implode('', \array_slice(explode(\DIRECTORY_SEPARATOR, substr($href, 1 - $this->attr['ellipsis'])), 0, 2))) : 0);
- } elseif (3 < \count($ellipsis = explode(\DIRECTORY_SEPARATOR, $href))) {
- $this->attr['ellipsis'] = 2 + \strlen(implode('', \array_slice($ellipsis, -2)));
- $this->attr['ellipsis-type'] = 'path';
- $this->attr['ellipsis-tail'] = 1;
- }
- }
-
- private function getComposerRoot(string $file, bool &$inVendor)
- {
- if (!isset(self::$vendorRoots)) {
- self::$vendorRoots = [];
-
- foreach (get_declared_classes() as $class) {
- if ('C' === $class[0] && str_starts_with($class, 'ComposerAutoloaderInit')) {
- $r = new \ReflectionClass($class);
- $v = \dirname($r->getFileName(), 2);
- if (is_file($v.'/composer/installed.json')) {
- self::$vendorRoots[] = $v.\DIRECTORY_SEPARATOR;
- }
- }
- }
- }
- $inVendor = false;
-
- if (isset(self::$composerRoots[$dir = \dirname($file)])) {
- return self::$composerRoots[$dir];
- }
-
- foreach (self::$vendorRoots as $root) {
- if ($inVendor = str_starts_with($file, $root)) {
- return $root;
- }
- }
-
- $parent = $dir;
- while (!@is_file($parent.'/composer.json')) {
- if (!@file_exists($parent)) {
- // open_basedir restriction in effect
- break;
- }
- if ($parent === \dirname($parent)) {
- return self::$composerRoots[$dir] = false;
- }
-
- $parent = \dirname($parent);
- }
-
- return self::$composerRoots[$dir] = $parent.\DIRECTORY_SEPARATOR;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/MemcachedCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/MemcachedCaster.php
deleted file mode 100644
index d6baa25..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/MemcachedCaster.php
+++ /dev/null
@@ -1,81 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @author Jan Schädlich <jan.schaedlich@sensiolabs.de>
- *
- * @final
- */
-class MemcachedCaster
-{
- private static array $optionConstants;
- private static array $defaultOptions;
-
- public static function castMemcached(\Memcached $c, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'servers' => $c->getServerList(),
- Caster::PREFIX_VIRTUAL.'options' => new EnumStub(
- self::getNonDefaultOptions($c)
- ),
- ];
-
- return $a;
- }
-
- private static function getNonDefaultOptions(\Memcached $c): array
- {
- self::$defaultOptions = self::$defaultOptions ?? self::discoverDefaultOptions();
- self::$optionConstants = self::$optionConstants ?? self::getOptionConstants();
-
- $nonDefaultOptions = [];
- foreach (self::$optionConstants as $constantKey => $value) {
- if (self::$defaultOptions[$constantKey] !== $option = $c->getOption($value)) {
- $nonDefaultOptions[$constantKey] = $option;
- }
- }
-
- return $nonDefaultOptions;
- }
-
- private static function discoverDefaultOptions(): array
- {
- $defaultMemcached = new \Memcached();
- $defaultMemcached->addServer('127.0.0.1', 11211);
-
- $defaultOptions = [];
- self::$optionConstants = self::$optionConstants ?? self::getOptionConstants();
-
- foreach (self::$optionConstants as $constantKey => $value) {
- $defaultOptions[$constantKey] = $defaultMemcached->getOption($value);
- }
-
- return $defaultOptions;
- }
-
- private static function getOptionConstants(): array
- {
- $reflectedMemcached = new \ReflectionClass(\Memcached::class);
-
- $optionConstants = [];
- foreach ($reflectedMemcached->getConstants() as $constantKey => $value) {
- if (str_starts_with($constantKey, 'OPT_')) {
- $optionConstants[$constantKey] = $value;
- }
- }
-
- return $optionConstants;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/MysqliCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/MysqliCaster.php
deleted file mode 100644
index bfe6f08..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/MysqliCaster.php
+++ /dev/null
@@ -1,33 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @internal
- */
-final class MysqliCaster
-{
- public static function castMysqliDriver(\mysqli_driver $c, array $a, Stub $stub, bool $isNested): array
- {
- foreach ($a as $k => $v) {
- if (isset($c->$k)) {
- $a[$k] = $c->$k;
- }
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/PdoCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/PdoCaster.php
deleted file mode 100644
index 140473b..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/PdoCaster.php
+++ /dev/null
@@ -1,122 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts PDO related classes to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class PdoCaster
-{
- private const PDO_ATTRIBUTES = [
- 'CASE' => [
- \PDO::CASE_LOWER => 'LOWER',
- \PDO::CASE_NATURAL => 'NATURAL',
- \PDO::CASE_UPPER => 'UPPER',
- ],
- 'ERRMODE' => [
- \PDO::ERRMODE_SILENT => 'SILENT',
- \PDO::ERRMODE_WARNING => 'WARNING',
- \PDO::ERRMODE_EXCEPTION => 'EXCEPTION',
- ],
- 'TIMEOUT',
- 'PREFETCH',
- 'AUTOCOMMIT',
- 'PERSISTENT',
- 'DRIVER_NAME',
- 'SERVER_INFO',
- 'ORACLE_NULLS' => [
- \PDO::NULL_NATURAL => 'NATURAL',
- \PDO::NULL_EMPTY_STRING => 'EMPTY_STRING',
- \PDO::NULL_TO_STRING => 'TO_STRING',
- ],
- 'CLIENT_VERSION',
- 'SERVER_VERSION',
- 'STATEMENT_CLASS',
- 'EMULATE_PREPARES',
- 'CONNECTION_STATUS',
- 'STRINGIFY_FETCHES',
- 'DEFAULT_FETCH_MODE' => [
- \PDO::FETCH_ASSOC => 'ASSOC',
- \PDO::FETCH_BOTH => 'BOTH',
- \PDO::FETCH_LAZY => 'LAZY',
- \PDO::FETCH_NUM => 'NUM',
- \PDO::FETCH_OBJ => 'OBJ',
- ],
- ];
-
- public static function castPdo(\PDO $c, array $a, Stub $stub, bool $isNested)
- {
- $attr = [];
- $errmode = $c->getAttribute(\PDO::ATTR_ERRMODE);
- $c->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION);
-
- foreach (self::PDO_ATTRIBUTES as $k => $v) {
- if (!isset($k[0])) {
- $k = $v;
- $v = [];
- }
-
- try {
- $attr[$k] = 'ERRMODE' === $k ? $errmode : $c->getAttribute(\constant('PDO::ATTR_'.$k));
- if ($v && isset($v[$attr[$k]])) {
- $attr[$k] = new ConstStub($v[$attr[$k]], $attr[$k]);
- }
- } catch (\Exception $e) {
- }
- }
- if (isset($attr[$k = 'STATEMENT_CLASS'][1])) {
- if ($attr[$k][1]) {
- $attr[$k][1] = new ArgsStub($attr[$k][1], '__construct', $attr[$k][0]);
- }
- $attr[$k][0] = new ClassStub($attr[$k][0]);
- }
-
- $prefix = Caster::PREFIX_VIRTUAL;
- $a += [
- $prefix.'inTransaction' => method_exists($c, 'inTransaction'),
- $prefix.'errorInfo' => $c->errorInfo(),
- $prefix.'attributes' => new EnumStub($attr),
- ];
-
- if ($a[$prefix.'inTransaction']) {
- $a[$prefix.'inTransaction'] = $c->inTransaction();
- } else {
- unset($a[$prefix.'inTransaction']);
- }
-
- if (!isset($a[$prefix.'errorInfo'][1], $a[$prefix.'errorInfo'][2])) {
- unset($a[$prefix.'errorInfo']);
- }
-
- $c->setAttribute(\PDO::ATTR_ERRMODE, $errmode);
-
- return $a;
- }
-
- public static function castPdoStatement(\PDOStatement $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
- $a[$prefix.'errorInfo'] = $c->errorInfo();
-
- if (!isset($a[$prefix.'errorInfo'][1], $a[$prefix.'errorInfo'][2])) {
- unset($a[$prefix.'errorInfo']);
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/PgSqlCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/PgSqlCaster.php
deleted file mode 100644
index d8e5b52..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/PgSqlCaster.php
+++ /dev/null
@@ -1,156 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts pqsql resources to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class PgSqlCaster
-{
- private const PARAM_CODES = [
- 'server_encoding',
- 'client_encoding',
- 'is_superuser',
- 'session_authorization',
- 'DateStyle',
- 'TimeZone',
- 'IntervalStyle',
- 'integer_datetimes',
- 'application_name',
- 'standard_conforming_strings',
- ];
-
- private const TRANSACTION_STATUS = [
- \PGSQL_TRANSACTION_IDLE => 'PGSQL_TRANSACTION_IDLE',
- \PGSQL_TRANSACTION_ACTIVE => 'PGSQL_TRANSACTION_ACTIVE',
- \PGSQL_TRANSACTION_INTRANS => 'PGSQL_TRANSACTION_INTRANS',
- \PGSQL_TRANSACTION_INERROR => 'PGSQL_TRANSACTION_INERROR',
- \PGSQL_TRANSACTION_UNKNOWN => 'PGSQL_TRANSACTION_UNKNOWN',
- ];
-
- private const RESULT_STATUS = [
- \PGSQL_EMPTY_QUERY => 'PGSQL_EMPTY_QUERY',
- \PGSQL_COMMAND_OK => 'PGSQL_COMMAND_OK',
- \PGSQL_TUPLES_OK => 'PGSQL_TUPLES_OK',
- \PGSQL_COPY_OUT => 'PGSQL_COPY_OUT',
- \PGSQL_COPY_IN => 'PGSQL_COPY_IN',
- \PGSQL_BAD_RESPONSE => 'PGSQL_BAD_RESPONSE',
- \PGSQL_NONFATAL_ERROR => 'PGSQL_NONFATAL_ERROR',
- \PGSQL_FATAL_ERROR => 'PGSQL_FATAL_ERROR',
- ];
-
- private const DIAG_CODES = [
- 'severity' => \PGSQL_DIAG_SEVERITY,
- 'sqlstate' => \PGSQL_DIAG_SQLSTATE,
- 'message' => \PGSQL_DIAG_MESSAGE_PRIMARY,
- 'detail' => \PGSQL_DIAG_MESSAGE_DETAIL,
- 'hint' => \PGSQL_DIAG_MESSAGE_HINT,
- 'statement position' => \PGSQL_DIAG_STATEMENT_POSITION,
- 'internal position' => \PGSQL_DIAG_INTERNAL_POSITION,
- 'internal query' => \PGSQL_DIAG_INTERNAL_QUERY,
- 'context' => \PGSQL_DIAG_CONTEXT,
- 'file' => \PGSQL_DIAG_SOURCE_FILE,
- 'line' => \PGSQL_DIAG_SOURCE_LINE,
- 'function' => \PGSQL_DIAG_SOURCE_FUNCTION,
- ];
-
- public static function castLargeObject($lo, array $a, Stub $stub, bool $isNested)
- {
- $a['seek position'] = pg_lo_tell($lo);
-
- return $a;
- }
-
- public static function castLink($link, array $a, Stub $stub, bool $isNested)
- {
- $a['status'] = pg_connection_status($link);
- $a['status'] = new ConstStub(\PGSQL_CONNECTION_OK === $a['status'] ? 'PGSQL_CONNECTION_OK' : 'PGSQL_CONNECTION_BAD', $a['status']);
- $a['busy'] = pg_connection_busy($link);
-
- $a['transaction'] = pg_transaction_status($link);
- if (isset(self::TRANSACTION_STATUS[$a['transaction']])) {
- $a['transaction'] = new ConstStub(self::TRANSACTION_STATUS[$a['transaction']], $a['transaction']);
- }
-
- $a['pid'] = pg_get_pid($link);
- $a['last error'] = pg_last_error($link);
- $a['last notice'] = pg_last_notice($link);
- $a['host'] = pg_host($link);
- $a['port'] = pg_port($link);
- $a['dbname'] = pg_dbname($link);
- $a['options'] = pg_options($link);
- $a['version'] = pg_version($link);
-
- foreach (self::PARAM_CODES as $v) {
- if (false !== $s = pg_parameter_status($link, $v)) {
- $a['param'][$v] = $s;
- }
- }
-
- $a['param']['client_encoding'] = pg_client_encoding($link);
- $a['param'] = new EnumStub($a['param']);
-
- return $a;
- }
-
- public static function castResult($result, array $a, Stub $stub, bool $isNested)
- {
- $a['num rows'] = pg_num_rows($result);
- $a['status'] = pg_result_status($result);
- if (isset(self::RESULT_STATUS[$a['status']])) {
- $a['status'] = new ConstStub(self::RESULT_STATUS[$a['status']], $a['status']);
- }
- $a['command-completion tag'] = pg_result_status($result, \PGSQL_STATUS_STRING);
-
- if (-1 === $a['num rows']) {
- foreach (self::DIAG_CODES as $k => $v) {
- $a['error'][$k] = pg_result_error_field($result, $v);
- }
- }
-
- $a['affected rows'] = pg_affected_rows($result);
- $a['last OID'] = pg_last_oid($result);
-
- $fields = pg_num_fields($result);
-
- for ($i = 0; $i < $fields; ++$i) {
- $field = [
- 'name' => pg_field_name($result, $i),
- 'table' => sprintf('%s (OID: %s)', pg_field_table($result, $i), pg_field_table($result, $i, true)),
- 'type' => sprintf('%s (OID: %s)', pg_field_type($result, $i), pg_field_type_oid($result, $i)),
- 'nullable' => (bool) pg_field_is_null($result, $i),
- 'storage' => pg_field_size($result, $i).' bytes',
- 'display' => pg_field_prtlen($result, $i).' chars',
- ];
- if (' (OID: )' === $field['table']) {
- $field['table'] = null;
- }
- if ('-1 bytes' === $field['storage']) {
- $field['storage'] = 'variable size';
- } elseif ('1 bytes' === $field['storage']) {
- $field['storage'] = '1 byte';
- }
- if ('1 chars' === $field['display']) {
- $field['display'] = '1 char';
- }
- $a['fields'][] = new EnumStub($field);
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ProxyManagerCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ProxyManagerCaster.php
deleted file mode 100644
index e712019..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ProxyManagerCaster.php
+++ /dev/null
@@ -1,33 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use ProxyManager\Proxy\ProxyInterface;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class ProxyManagerCaster
-{
- public static function castProxy(ProxyInterface $c, array $a, Stub $stub, bool $isNested)
- {
- if ($parent = get_parent_class($c)) {
- $stub->class .= ' - '.$parent;
- }
- $stub->class .= '@proxy';
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/RdKafkaCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/RdKafkaCaster.php
deleted file mode 100644
index 8053363..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/RdKafkaCaster.php
+++ /dev/null
@@ -1,186 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use RdKafka\Conf;
-use RdKafka\Exception as RdKafkaException;
-use RdKafka\KafkaConsumer;
-use RdKafka\Message;
-use RdKafka\Metadata\Broker as BrokerMetadata;
-use RdKafka\Metadata\Collection as CollectionMetadata;
-use RdKafka\Metadata\Partition as PartitionMetadata;
-use RdKafka\Metadata\Topic as TopicMetadata;
-use RdKafka\Topic;
-use RdKafka\TopicConf;
-use RdKafka\TopicPartition;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts RdKafka related classes to array representation.
- *
- * @author Romain Neutron <imprec@gmail.com>
- */
-class RdKafkaCaster
-{
- public static function castKafkaConsumer(KafkaConsumer $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- try {
- $assignment = $c->getAssignment();
- } catch (RdKafkaException $e) {
- $assignment = [];
- }
-
- $a += [
- $prefix.'subscription' => $c->getSubscription(),
- $prefix.'assignment' => $assignment,
- ];
-
- $a += self::extractMetadata($c);
-
- return $a;
- }
-
- public static function castTopic(Topic $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'name' => $c->getName(),
- ];
-
- return $a;
- }
-
- public static function castTopicPartition(TopicPartition $c, array $a)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'offset' => $c->getOffset(),
- $prefix.'partition' => $c->getPartition(),
- $prefix.'topic' => $c->getTopic(),
- ];
-
- return $a;
- }
-
- public static function castMessage(Message $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'errstr' => $c->errstr(),
- ];
-
- return $a;
- }
-
- public static function castConf(Conf $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- foreach ($c->dump() as $key => $value) {
- $a[$prefix.$key] = $value;
- }
-
- return $a;
- }
-
- public static function castTopicConf(TopicConf $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- foreach ($c->dump() as $key => $value) {
- $a[$prefix.$key] = $value;
- }
-
- return $a;
- }
-
- public static function castRdKafka(\RdKafka $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'out_q_len' => $c->getOutQLen(),
- ];
-
- $a += self::extractMetadata($c);
-
- return $a;
- }
-
- public static function castCollectionMetadata(CollectionMetadata $c, array $a, Stub $stub, bool $isNested)
- {
- $a += iterator_to_array($c);
-
- return $a;
- }
-
- public static function castTopicMetadata(TopicMetadata $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'name' => $c->getTopic(),
- $prefix.'partitions' => $c->getPartitions(),
- ];
-
- return $a;
- }
-
- public static function castPartitionMetadata(PartitionMetadata $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'id' => $c->getId(),
- $prefix.'err' => $c->getErr(),
- $prefix.'leader' => $c->getLeader(),
- ];
-
- return $a;
- }
-
- public static function castBrokerMetadata(BrokerMetadata $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- $a += [
- $prefix.'id' => $c->getId(),
- $prefix.'host' => $c->getHost(),
- $prefix.'port' => $c->getPort(),
- ];
-
- return $a;
- }
-
- private static function extractMetadata(KafkaConsumer|\RdKafka $c)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- try {
- $m = $c->getMetadata(true, null, 500);
- } catch (RdKafkaException $e) {
- return [];
- }
-
- return [
- $prefix.'orig_broker_id' => $m->getOrigBrokerId(),
- $prefix.'orig_broker_name' => $m->getOrigBrokerName(),
- $prefix.'brokers' => $m->getBrokers(),
- $prefix.'topics' => $m->getTopics(),
- ];
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/RedisCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/RedisCaster.php
deleted file mode 100644
index eac25a1..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/RedisCaster.php
+++ /dev/null
@@ -1,149 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts Redis class from ext-redis to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class RedisCaster
-{
- private const SERIALIZERS = [
- \Redis::SERIALIZER_NONE => 'NONE',
- \Redis::SERIALIZER_PHP => 'PHP',
- 2 => 'IGBINARY', // Optional Redis::SERIALIZER_IGBINARY
- ];
-
- private const MODES = [
- \Redis::ATOMIC => 'ATOMIC',
- \Redis::MULTI => 'MULTI',
- \Redis::PIPELINE => 'PIPELINE',
- ];
-
- private const COMPRESSION_MODES = [
- 0 => 'NONE', // Redis::COMPRESSION_NONE
- 1 => 'LZF', // Redis::COMPRESSION_LZF
- ];
-
- private const FAILOVER_OPTIONS = [
- \RedisCluster::FAILOVER_NONE => 'NONE',
- \RedisCluster::FAILOVER_ERROR => 'ERROR',
- \RedisCluster::FAILOVER_DISTRIBUTE => 'DISTRIBUTE',
- \RedisCluster::FAILOVER_DISTRIBUTE_SLAVES => 'DISTRIBUTE_SLAVES',
- ];
-
- public static function castRedis(\Redis $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- if (!$connected = $c->isConnected()) {
- return $a + [
- $prefix.'isConnected' => $connected,
- ];
- }
-
- $mode = $c->getMode();
-
- return $a + [
- $prefix.'isConnected' => $connected,
- $prefix.'host' => $c->getHost(),
- $prefix.'port' => $c->getPort(),
- $prefix.'auth' => $c->getAuth(),
- $prefix.'mode' => isset(self::MODES[$mode]) ? new ConstStub(self::MODES[$mode], $mode) : $mode,
- $prefix.'dbNum' => $c->getDbNum(),
- $prefix.'timeout' => $c->getTimeout(),
- $prefix.'lastError' => $c->getLastError(),
- $prefix.'persistentId' => $c->getPersistentID(),
- $prefix.'options' => self::getRedisOptions($c),
- ];
- }
-
- public static function castRedisArray(\RedisArray $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- return $a + [
- $prefix.'hosts' => $c->_hosts(),
- $prefix.'function' => ClassStub::wrapCallable($c->_function()),
- $prefix.'lastError' => $c->getLastError(),
- $prefix.'options' => self::getRedisOptions($c),
- ];
- }
-
- public static function castRedisCluster(\RedisCluster $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
- $failover = $c->getOption(\RedisCluster::OPT_SLAVE_FAILOVER);
-
- $a += [
- $prefix.'_masters' => $c->_masters(),
- $prefix.'_redir' => $c->_redir(),
- $prefix.'mode' => new ConstStub($c->getMode() ? 'MULTI' : 'ATOMIC', $c->getMode()),
- $prefix.'lastError' => $c->getLastError(),
- $prefix.'options' => self::getRedisOptions($c, [
- 'SLAVE_FAILOVER' => isset(self::FAILOVER_OPTIONS[$failover]) ? new ConstStub(self::FAILOVER_OPTIONS[$failover], $failover) : $failover,
- ]),
- ];
-
- return $a;
- }
-
- private static function getRedisOptions(\Redis|\RedisArray|\RedisCluster $redis, array $options = []): EnumStub
- {
- $serializer = $redis->getOption(\Redis::OPT_SERIALIZER);
- if (\is_array($serializer)) {
- foreach ($serializer as &$v) {
- if (isset(self::SERIALIZERS[$v])) {
- $v = new ConstStub(self::SERIALIZERS[$v], $v);
- }
- }
- } elseif (isset(self::SERIALIZERS[$serializer])) {
- $serializer = new ConstStub(self::SERIALIZERS[$serializer], $serializer);
- }
-
- $compression = \defined('Redis::OPT_COMPRESSION') ? $redis->getOption(\Redis::OPT_COMPRESSION) : 0;
- if (\is_array($compression)) {
- foreach ($compression as &$v) {
- if (isset(self::COMPRESSION_MODES[$v])) {
- $v = new ConstStub(self::COMPRESSION_MODES[$v], $v);
- }
- }
- } elseif (isset(self::COMPRESSION_MODES[$compression])) {
- $compression = new ConstStub(self::COMPRESSION_MODES[$compression], $compression);
- }
-
- $retry = \defined('Redis::OPT_SCAN') ? $redis->getOption(\Redis::OPT_SCAN) : 0;
- if (\is_array($retry)) {
- foreach ($retry as &$v) {
- $v = new ConstStub($v ? 'RETRY' : 'NORETRY', $v);
- }
- } else {
- $retry = new ConstStub($retry ? 'RETRY' : 'NORETRY', $retry);
- }
-
- $options += [
- 'TCP_KEEPALIVE' => \defined('Redis::OPT_TCP_KEEPALIVE') ? $redis->getOption(\Redis::OPT_TCP_KEEPALIVE) : 0,
- 'READ_TIMEOUT' => $redis->getOption(\Redis::OPT_READ_TIMEOUT),
- 'COMPRESSION' => $compression,
- 'SERIALIZER' => $serializer,
- 'PREFIX' => $redis->getOption(\Redis::OPT_PREFIX),
- 'SCAN' => $retry,
- ];
-
- return new EnumStub($options);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ReflectionCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ReflectionCaster.php
deleted file mode 100644
index 86d439f..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ReflectionCaster.php
+++ /dev/null
@@ -1,440 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts Reflector related classes to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class ReflectionCaster
-{
- public const UNSET_CLOSURE_FILE_INFO = ['Closure' => __CLASS__.'::unsetClosureFileInfo'];
-
- private const EXTRA_MAP = [
- 'docComment' => 'getDocComment',
- 'extension' => 'getExtensionName',
- 'isDisabled' => 'isDisabled',
- 'isDeprecated' => 'isDeprecated',
- 'isInternal' => 'isInternal',
- 'isUserDefined' => 'isUserDefined',
- 'isGenerator' => 'isGenerator',
- 'isVariadic' => 'isVariadic',
- ];
-
- public static function castClosure(\Closure $c, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
- $c = new \ReflectionFunction($c);
-
- $a = static::castFunctionAbstract($c, $a, $stub, $isNested, $filter);
-
- if (!str_contains($c->name, '{closure}')) {
- $stub->class = isset($a[$prefix.'class']) ? $a[$prefix.'class']->value.'::'.$c->name : $c->name;
- unset($a[$prefix.'class']);
- }
- unset($a[$prefix.'extra']);
-
- $stub->class .= self::getSignature($a);
-
- if ($f = $c->getFileName()) {
- $stub->attr['file'] = $f;
- $stub->attr['line'] = $c->getStartLine();
- }
-
- unset($a[$prefix.'parameters']);
-
- if ($filter & Caster::EXCLUDE_VERBOSE) {
- $stub->cut += ($c->getFileName() ? 2 : 0) + \count($a);
-
- return [];
- }
-
- if ($f) {
- $a[$prefix.'file'] = new LinkStub($f, $c->getStartLine());
- $a[$prefix.'line'] = $c->getStartLine().' to '.$c->getEndLine();
- }
-
- return $a;
- }
-
- public static function unsetClosureFileInfo(\Closure $c, array $a)
- {
- unset($a[Caster::PREFIX_VIRTUAL.'file'], $a[Caster::PREFIX_VIRTUAL.'line']);
-
- return $a;
- }
-
- public static function castGenerator(\Generator $c, array $a, Stub $stub, bool $isNested)
- {
- // Cannot create ReflectionGenerator based on a terminated Generator
- try {
- $reflectionGenerator = new \ReflectionGenerator($c);
- } catch (\Exception $e) {
- $a[Caster::PREFIX_VIRTUAL.'closed'] = true;
-
- return $a;
- }
-
- return self::castReflectionGenerator($reflectionGenerator, $a, $stub, $isNested);
- }
-
- public static function castType(\ReflectionType $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- if ($c instanceof \ReflectionNamedType) {
- $a += [
- $prefix.'name' => $c instanceof \ReflectionNamedType ? $c->getName() : (string) $c,
- $prefix.'allowsNull' => $c->allowsNull(),
- $prefix.'isBuiltin' => $c->isBuiltin(),
- ];
- } elseif ($c instanceof \ReflectionUnionType || $c instanceof \ReflectionIntersectionType) {
- $a[$prefix.'allowsNull'] = $c->allowsNull();
- self::addMap($a, $c, [
- 'types' => 'getTypes',
- ]);
- } else {
- $a[$prefix.'allowsNull'] = $c->allowsNull();
- }
-
- return $a;
- }
-
- public static function castAttribute(\ReflectionAttribute $c, array $a, Stub $stub, bool $isNested)
- {
- self::addMap($a, $c, [
- 'name' => 'getName',
- 'arguments' => 'getArguments',
- ]);
-
- return $a;
- }
-
- public static function castReflectionGenerator(\ReflectionGenerator $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- if ($c->getThis()) {
- $a[$prefix.'this'] = new CutStub($c->getThis());
- }
- $function = $c->getFunction();
- $frame = [
- 'class' => $function->class ?? null,
- 'type' => isset($function->class) ? ($function->isStatic() ? '::' : '->') : null,
- 'function' => $function->name,
- 'file' => $c->getExecutingFile(),
- 'line' => $c->getExecutingLine(),
- ];
- if ($trace = $c->getTrace(\DEBUG_BACKTRACE_IGNORE_ARGS)) {
- $function = new \ReflectionGenerator($c->getExecutingGenerator());
- array_unshift($trace, [
- 'function' => 'yield',
- 'file' => $function->getExecutingFile(),
- 'line' => $function->getExecutingLine() - (int) (\PHP_VERSION_ID < 80100),
- ]);
- $trace[] = $frame;
- $a[$prefix.'trace'] = new TraceStub($trace, false, 0, -1, -1);
- } else {
- $function = new FrameStub($frame, false, true);
- $function = ExceptionCaster::castFrameStub($function, [], $function, true);
- $a[$prefix.'executing'] = $function[$prefix.'src'];
- }
-
- $a[Caster::PREFIX_VIRTUAL.'closed'] = false;
-
- return $a;
- }
-
- public static function castClass(\ReflectionClass $c, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- if ($n = \Reflection::getModifierNames($c->getModifiers())) {
- $a[$prefix.'modifiers'] = implode(' ', $n);
- }
-
- self::addMap($a, $c, [
- 'extends' => 'getParentClass',
- 'implements' => 'getInterfaceNames',
- 'constants' => 'getReflectionConstants',
- ]);
-
- foreach ($c->getProperties() as $n) {
- $a[$prefix.'properties'][$n->name] = $n;
- }
-
- foreach ($c->getMethods() as $n) {
- $a[$prefix.'methods'][$n->name] = $n;
- }
-
- self::addAttributes($a, $c, $prefix);
-
- if (!($filter & Caster::EXCLUDE_VERBOSE) && !$isNested) {
- self::addExtra($a, $c);
- }
-
- return $a;
- }
-
- public static function castFunctionAbstract(\ReflectionFunctionAbstract $c, array $a, Stub $stub, bool $isNested, int $filter = 0)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- self::addMap($a, $c, [
- 'returnsReference' => 'returnsReference',
- 'returnType' => 'getReturnType',
- 'class' => 'getClosureScopeClass',
- 'this' => 'getClosureThis',
- ]);
-
- if (isset($a[$prefix.'returnType'])) {
- $v = $a[$prefix.'returnType'];
- $v = $v instanceof \ReflectionNamedType ? $v->getName() : (string) $v;
- $a[$prefix.'returnType'] = new ClassStub($a[$prefix.'returnType'] instanceof \ReflectionNamedType && $a[$prefix.'returnType']->allowsNull() && 'mixed' !== $v ? '?'.$v : $v, [class_exists($v, false) || interface_exists($v, false) || trait_exists($v, false) ? $v : '', '']);
- }
- if (isset($a[$prefix.'class'])) {
- $a[$prefix.'class'] = new ClassStub($a[$prefix.'class']);
- }
- if (isset($a[$prefix.'this'])) {
- $a[$prefix.'this'] = new CutStub($a[$prefix.'this']);
- }
-
- foreach ($c->getParameters() as $v) {
- $k = '$'.$v->name;
- if ($v->isVariadic()) {
- $k = '...'.$k;
- }
- if ($v->isPassedByReference()) {
- $k = '&'.$k;
- }
- $a[$prefix.'parameters'][$k] = $v;
- }
- if (isset($a[$prefix.'parameters'])) {
- $a[$prefix.'parameters'] = new EnumStub($a[$prefix.'parameters']);
- }
-
- self::addAttributes($a, $c, $prefix);
-
- if (!($filter & Caster::EXCLUDE_VERBOSE) && $v = $c->getStaticVariables()) {
- foreach ($v as $k => &$v) {
- if (\is_object($v)) {
- $a[$prefix.'use']['$'.$k] = new CutStub($v);
- } else {
- $a[$prefix.'use']['$'.$k] = &$v;
- }
- }
- unset($v);
- $a[$prefix.'use'] = new EnumStub($a[$prefix.'use']);
- }
-
- if (!($filter & Caster::EXCLUDE_VERBOSE) && !$isNested) {
- self::addExtra($a, $c);
- }
-
- return $a;
- }
-
- public static function castClassConstant(\ReflectionClassConstant $c, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'modifiers'] = implode(' ', \Reflection::getModifierNames($c->getModifiers()));
- $a[Caster::PREFIX_VIRTUAL.'value'] = $c->getValue();
-
- self::addAttributes($a, $c);
-
- return $a;
- }
-
- public static function castMethod(\ReflectionMethod $c, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'modifiers'] = implode(' ', \Reflection::getModifierNames($c->getModifiers()));
-
- return $a;
- }
-
- public static function castParameter(\ReflectionParameter $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
-
- self::addMap($a, $c, [
- 'position' => 'getPosition',
- 'isVariadic' => 'isVariadic',
- 'byReference' => 'isPassedByReference',
- 'allowsNull' => 'allowsNull',
- ]);
-
- self::addAttributes($a, $c, $prefix);
-
- if ($v = $c->getType()) {
- $a[$prefix.'typeHint'] = $v instanceof \ReflectionNamedType ? $v->getName() : (string) $v;
- }
-
- if (isset($a[$prefix.'typeHint'])) {
- $v = $a[$prefix.'typeHint'];
- $a[$prefix.'typeHint'] = new ClassStub($v, [class_exists($v, false) || interface_exists($v, false) || trait_exists($v, false) ? $v : '', '']);
- } else {
- unset($a[$prefix.'allowsNull']);
- }
-
- if ($c->isOptional()) {
- try {
- $a[$prefix.'default'] = $v = $c->getDefaultValue();
- if ($c->isDefaultValueConstant()) {
- $a[$prefix.'default'] = new ConstStub($c->getDefaultValueConstantName(), $v);
- }
- if (null === $v) {
- unset($a[$prefix.'allowsNull']);
- }
- } catch (\ReflectionException $e) {
- }
- }
-
- return $a;
- }
-
- public static function castProperty(\ReflectionProperty $c, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'modifiers'] = implode(' ', \Reflection::getModifierNames($c->getModifiers()));
-
- self::addAttributes($a, $c);
- self::addExtra($a, $c);
-
- return $a;
- }
-
- public static function castReference(\ReflectionReference $c, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'id'] = $c->getId();
-
- return $a;
- }
-
- public static function castExtension(\ReflectionExtension $c, array $a, Stub $stub, bool $isNested)
- {
- self::addMap($a, $c, [
- 'version' => 'getVersion',
- 'dependencies' => 'getDependencies',
- 'iniEntries' => 'getIniEntries',
- 'isPersistent' => 'isPersistent',
- 'isTemporary' => 'isTemporary',
- 'constants' => 'getConstants',
- 'functions' => 'getFunctions',
- 'classes' => 'getClasses',
- ]);
-
- return $a;
- }
-
- public static function castZendExtension(\ReflectionZendExtension $c, array $a, Stub $stub, bool $isNested)
- {
- self::addMap($a, $c, [
- 'version' => 'getVersion',
- 'author' => 'getAuthor',
- 'copyright' => 'getCopyright',
- 'url' => 'getURL',
- ]);
-
- return $a;
- }
-
- public static function getSignature(array $a)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
- $signature = '';
-
- if (isset($a[$prefix.'parameters'])) {
- foreach ($a[$prefix.'parameters']->value as $k => $param) {
- $signature .= ', ';
- if ($type = $param->getType()) {
- if (!$type instanceof \ReflectionNamedType) {
- $signature .= $type.' ';
- } else {
- if (!$param->isOptional() && $param->allowsNull() && 'mixed' !== $type->getName()) {
- $signature .= '?';
- }
- $signature .= substr(strrchr('\\'.$type->getName(), '\\'), 1).' ';
- }
- }
- $signature .= $k;
-
- if (!$param->isDefaultValueAvailable()) {
- continue;
- }
- $v = $param->getDefaultValue();
- $signature .= ' = ';
-
- if ($param->isDefaultValueConstant()) {
- $signature .= substr(strrchr('\\'.$param->getDefaultValueConstantName(), '\\'), 1);
- } elseif (null === $v) {
- $signature .= 'null';
- } elseif (\is_array($v)) {
- $signature .= $v ? '[…'.\count($v).']' : '[]';
- } elseif (\is_string($v)) {
- $signature .= 10 > \strlen($v) && !str_contains($v, '\\') ? "'{$v}'" : "'…".\strlen($v)."'";
- } elseif (\is_bool($v)) {
- $signature .= $v ? 'true' : 'false';
- } elseif (\is_object($v)) {
- $signature .= 'new '.substr(strrchr('\\'.get_debug_type($v), '\\'), 1);
- } else {
- $signature .= $v;
- }
- }
- }
- $signature = (empty($a[$prefix.'returnsReference']) ? '' : '&').'('.substr($signature, 2).')';
-
- if (isset($a[$prefix.'returnType'])) {
- $signature .= ': '.substr(strrchr('\\'.$a[$prefix.'returnType'], '\\'), 1);
- }
-
- return $signature;
- }
-
- private static function addExtra(array &$a, \Reflector $c)
- {
- $x = isset($a[Caster::PREFIX_VIRTUAL.'extra']) ? $a[Caster::PREFIX_VIRTUAL.'extra']->value : [];
-
- if (method_exists($c, 'getFileName') && $m = $c->getFileName()) {
- $x['file'] = new LinkStub($m, $c->getStartLine());
- $x['line'] = $c->getStartLine().' to '.$c->getEndLine();
- }
-
- self::addMap($x, $c, self::EXTRA_MAP, '');
-
- if ($x) {
- $a[Caster::PREFIX_VIRTUAL.'extra'] = new EnumStub($x);
- }
- }
-
- private static function addMap(array &$a, object $c, array $map, string $prefix = Caster::PREFIX_VIRTUAL)
- {
- foreach ($map as $k => $m) {
- if ('isDisabled' === $k) {
- continue;
- }
-
- if (method_exists($c, $m) && false !== ($m = $c->$m()) && null !== $m) {
- $a[$prefix.$k] = $m instanceof \Reflector ? $m->name : $m;
- }
- }
- }
-
- private static function addAttributes(array &$a, \Reflector $c, string $prefix = Caster::PREFIX_VIRTUAL): void
- {
- foreach ($c->getAttributes() as $n) {
- $a[$prefix.'attributes'][] = $n;
- }
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ResourceCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ResourceCaster.php
deleted file mode 100644
index 4e597f8..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/ResourceCaster.php
+++ /dev/null
@@ -1,100 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts common resource types to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class ResourceCaster
-{
- public static function castCurl(\CurlHandle $h, array $a, Stub $stub, bool $isNested): array
- {
- return curl_getinfo($h);
- }
-
- public static function castDba($dba, array $a, Stub $stub, bool $isNested)
- {
- $list = dba_list();
- $a['file'] = $list[(int) $dba];
-
- return $a;
- }
-
- public static function castProcess($process, array $a, Stub $stub, bool $isNested)
- {
- return proc_get_status($process);
- }
-
- public static function castStream($stream, array $a, Stub $stub, bool $isNested)
- {
- $a = stream_get_meta_data($stream) + static::castStreamContext($stream, $a, $stub, $isNested);
- if ($a['uri'] ?? false) {
- $a['uri'] = new LinkStub($a['uri']);
- }
-
- return $a;
- }
-
- public static function castStreamContext($stream, array $a, Stub $stub, bool $isNested)
- {
- return @stream_context_get_params($stream) ?: $a;
- }
-
- public static function castGd($gd, array $a, Stub $stub, bool $isNested)
- {
- $a['size'] = imagesx($gd).'x'.imagesy($gd);
- $a['trueColor'] = imageistruecolor($gd);
-
- return $a;
- }
-
- public static function castMysqlLink($h, array $a, Stub $stub, bool $isNested)
- {
- $a['host'] = mysql_get_host_info($h);
- $a['protocol'] = mysql_get_proto_info($h);
- $a['server'] = mysql_get_server_info($h);
-
- return $a;
- }
-
- public static function castOpensslX509($h, array $a, Stub $stub, bool $isNested)
- {
- $stub->cut = -1;
- $info = openssl_x509_parse($h, false);
-
- $pin = openssl_pkey_get_public($h);
- $pin = openssl_pkey_get_details($pin)['key'];
- $pin = \array_slice(explode("\n", $pin), 1, -2);
- $pin = base64_decode(implode('', $pin));
- $pin = base64_encode(hash('sha256', $pin, true));
-
- $a += [
- 'subject' => new EnumStub(array_intersect_key($info['subject'], ['organizationName' => true, 'commonName' => true])),
- 'issuer' => new EnumStub(array_intersect_key($info['issuer'], ['organizationName' => true, 'commonName' => true])),
- 'expiry' => new ConstStub(date(\DateTime::ISO8601, $info['validTo_time_t']), $info['validTo_time_t']),
- 'fingerprint' => new EnumStub([
- 'md5' => new ConstStub(wordwrap(strtoupper(openssl_x509_fingerprint($h, 'md5')), 2, ':', true)),
- 'sha1' => new ConstStub(wordwrap(strtoupper(openssl_x509_fingerprint($h, 'sha1')), 2, ':', true)),
- 'sha256' => new ConstStub(wordwrap(strtoupper(openssl_x509_fingerprint($h, 'sha256')), 2, ':', true)),
- 'pin-sha256' => new ConstStub($pin),
- ]),
- ];
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/SplCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/SplCaster.php
deleted file mode 100644
index a51cace..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/SplCaster.php
+++ /dev/null
@@ -1,234 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts SPL related classes to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class SplCaster
-{
- private const SPL_FILE_OBJECT_FLAGS = [
- \SplFileObject::DROP_NEW_LINE => 'DROP_NEW_LINE',
- \SplFileObject::READ_AHEAD => 'READ_AHEAD',
- \SplFileObject::SKIP_EMPTY => 'SKIP_EMPTY',
- \SplFileObject::READ_CSV => 'READ_CSV',
- ];
-
- public static function castArrayObject(\ArrayObject $c, array $a, Stub $stub, bool $isNested)
- {
- return self::castSplArray($c, $a, $stub, $isNested);
- }
-
- public static function castArrayIterator(\ArrayIterator $c, array $a, Stub $stub, bool $isNested)
- {
- return self::castSplArray($c, $a, $stub, $isNested);
- }
-
- public static function castHeap(\Iterator $c, array $a, Stub $stub, bool $isNested)
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'heap' => iterator_to_array(clone $c),
- ];
-
- return $a;
- }
-
- public static function castDoublyLinkedList(\SplDoublyLinkedList $c, array $a, Stub $stub, bool $isNested)
- {
- $prefix = Caster::PREFIX_VIRTUAL;
- $mode = $c->getIteratorMode();
- $c->setIteratorMode(\SplDoublyLinkedList::IT_MODE_KEEP | $mode & ~\SplDoublyLinkedList::IT_MODE_DELETE);
-
- $a += [
- $prefix.'mode' => new ConstStub((($mode & \SplDoublyLinkedList::IT_MODE_LIFO) ? 'IT_MODE_LIFO' : 'IT_MODE_FIFO').' | '.(($mode & \SplDoublyLinkedList::IT_MODE_DELETE) ? 'IT_MODE_DELETE' : 'IT_MODE_KEEP'), $mode),
- $prefix.'dllist' => iterator_to_array($c),
- ];
- $c->setIteratorMode($mode);
-
- return $a;
- }
-
- public static function castFileInfo(\SplFileInfo $c, array $a, Stub $stub, bool $isNested)
- {
- static $map = [
- 'path' => 'getPath',
- 'filename' => 'getFilename',
- 'basename' => 'getBasename',
- 'pathname' => 'getPathname',
- 'extension' => 'getExtension',
- 'realPath' => 'getRealPath',
- 'aTime' => 'getATime',
- 'mTime' => 'getMTime',
- 'cTime' => 'getCTime',
- 'inode' => 'getInode',
- 'size' => 'getSize',
- 'perms' => 'getPerms',
- 'owner' => 'getOwner',
- 'group' => 'getGroup',
- 'type' => 'getType',
- 'writable' => 'isWritable',
- 'readable' => 'isReadable',
- 'executable' => 'isExecutable',
- 'file' => 'isFile',
- 'dir' => 'isDir',
- 'link' => 'isLink',
- 'linkTarget' => 'getLinkTarget',
- ];
-
- $prefix = Caster::PREFIX_VIRTUAL;
- unset($a["\0SplFileInfo\0fileName"]);
- unset($a["\0SplFileInfo\0pathName"]);
-
- try {
- $c->isReadable();
- } catch (\RuntimeException $e) {
- if ('Object not initialized' !== $e->getMessage()) {
- throw $e;
- }
-
- $a[$prefix.'⚠'] = 'The parent constructor was not called: the object is in an invalid state';
-
- return $a;
- } catch (\Error $e) {
- if ('Object not initialized' !== $e->getMessage()) {
- throw $e;
- }
-
- $a[$prefix.'⚠'] = 'The parent constructor was not called: the object is in an invalid state';
-
- return $a;
- }
-
- foreach ($map as $key => $accessor) {
- try {
- $a[$prefix.$key] = $c->$accessor();
- } catch (\Exception $e) {
- }
- }
-
- if ($a[$prefix.'realPath'] ?? false) {
- $a[$prefix.'realPath'] = new LinkStub($a[$prefix.'realPath']);
- }
-
- if (isset($a[$prefix.'perms'])) {
- $a[$prefix.'perms'] = new ConstStub(sprintf('0%o', $a[$prefix.'perms']), $a[$prefix.'perms']);
- }
-
- static $mapDate = ['aTime', 'mTime', 'cTime'];
- foreach ($mapDate as $key) {
- if (isset($a[$prefix.$key])) {
- $a[$prefix.$key] = new ConstStub(date('Y-m-d H:i:s', $a[$prefix.$key]), $a[$prefix.$key]);
- }
- }
-
- return $a;
- }
-
- public static function castFileObject(\SplFileObject $c, array $a, Stub $stub, bool $isNested)
- {
- static $map = [
- 'csvControl' => 'getCsvControl',
- 'flags' => 'getFlags',
- 'maxLineLen' => 'getMaxLineLen',
- 'fstat' => 'fstat',
- 'eof' => 'eof',
- 'key' => 'key',
- ];
-
- $prefix = Caster::PREFIX_VIRTUAL;
-
- foreach ($map as $key => $accessor) {
- try {
- $a[$prefix.$key] = $c->$accessor();
- } catch (\Exception $e) {
- }
- }
-
- if (isset($a[$prefix.'flags'])) {
- $flagsArray = [];
- foreach (self::SPL_FILE_OBJECT_FLAGS as $value => $name) {
- if ($a[$prefix.'flags'] & $value) {
- $flagsArray[] = $name;
- }
- }
- $a[$prefix.'flags'] = new ConstStub(implode('|', $flagsArray), $a[$prefix.'flags']);
- }
-
- if (isset($a[$prefix.'fstat'])) {
- $a[$prefix.'fstat'] = new CutArrayStub($a[$prefix.'fstat'], ['dev', 'ino', 'nlink', 'rdev', 'blksize', 'blocks']);
- }
-
- return $a;
- }
-
- public static function castObjectStorage(\SplObjectStorage $c, array $a, Stub $stub, bool $isNested)
- {
- $storage = [];
- unset($a[Caster::PREFIX_DYNAMIC."\0gcdata"]); // Don't hit https://bugs.php.net/65967
- unset($a["\0SplObjectStorage\0storage"]);
-
- $clone = clone $c;
- foreach ($clone as $obj) {
- $storage[] = [
- 'object' => $obj,
- 'info' => $clone->getInfo(),
- ];
- }
-
- $a += [
- Caster::PREFIX_VIRTUAL.'storage' => $storage,
- ];
-
- return $a;
- }
-
- public static function castOuterIterator(\OuterIterator $c, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'innerIterator'] = $c->getInnerIterator();
-
- return $a;
- }
-
- public static function castWeakReference(\WeakReference $c, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'object'] = $c->get();
-
- return $a;
- }
-
- private static function castSplArray(\ArrayObject|\ArrayIterator $c, array $a, Stub $stub, bool $isNested): array
- {
- $prefix = Caster::PREFIX_VIRTUAL;
- $flags = $c->getFlags();
-
- if (!($flags & \ArrayObject::STD_PROP_LIST)) {
- $c->setFlags(\ArrayObject::STD_PROP_LIST);
- $a = Caster::castObject($c, \get_class($c), method_exists($c, '__debugInfo'), $stub->class);
- $c->setFlags($flags);
- }
- $a += [
- $prefix.'flag::STD_PROP_LIST' => (bool) ($flags & \ArrayObject::STD_PROP_LIST),
- $prefix.'flag::ARRAY_AS_PROPS' => (bool) ($flags & \ArrayObject::ARRAY_AS_PROPS),
- ];
- if ($c instanceof \ArrayObject) {
- $a[$prefix.'iteratorClass'] = new ClassStub($c->getIteratorClass());
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/StubCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/StubCaster.php
deleted file mode 100644
index 32ead7c..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/StubCaster.php
+++ /dev/null
@@ -1,84 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts a caster's Stub.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class StubCaster
-{
- public static function castStub(Stub $c, array $a, Stub $stub, bool $isNested)
- {
- if ($isNested) {
- $stub->type = $c->type;
- $stub->class = $c->class;
- $stub->value = $c->value;
- $stub->handle = $c->handle;
- $stub->cut = $c->cut;
- $stub->attr = $c->attr;
-
- if (Stub::TYPE_REF === $c->type && !$c->class && \is_string($c->value) && !preg_match('//u', $c->value)) {
- $stub->type = Stub::TYPE_STRING;
- $stub->class = Stub::STRING_BINARY;
- }
-
- $a = [];
- }
-
- return $a;
- }
-
- public static function castCutArray(CutArrayStub $c, array $a, Stub $stub, bool $isNested)
- {
- return $isNested ? $c->preservedSubset : $a;
- }
-
- public static function cutInternals($obj, array $a, Stub $stub, bool $isNested)
- {
- if ($isNested) {
- $stub->cut += \count($a);
-
- return [];
- }
-
- return $a;
- }
-
- public static function castEnum(EnumStub $c, array $a, Stub $stub, bool $isNested)
- {
- if ($isNested) {
- $stub->class = $c->dumpKeys ? '' : null;
- $stub->handle = 0;
- $stub->value = null;
- $stub->cut = $c->cut;
- $stub->attr = $c->attr;
-
- $a = [];
-
- if ($c->value) {
- foreach (array_keys($c->value) as $k) {
- $keys[] = !isset($k[0]) || "\0" !== $k[0] ? Caster::PREFIX_VIRTUAL.$k : $k;
- }
- // Preserve references with array_combine()
- $a = array_combine($keys, $c->value);
- }
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/SymfonyCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/SymfonyCaster.php
deleted file mode 100644
index 08428b9..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/SymfonyCaster.php
+++ /dev/null
@@ -1,97 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\HttpFoundation\Request;
-use Symfony\Component\Uid\Ulid;
-use Symfony\Component\Uid\Uuid;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @final
- */
-class SymfonyCaster
-{
- private const REQUEST_GETTERS = [
- 'pathInfo' => 'getPathInfo',
- 'requestUri' => 'getRequestUri',
- 'baseUrl' => 'getBaseUrl',
- 'basePath' => 'getBasePath',
- 'method' => 'getMethod',
- 'format' => 'getRequestFormat',
- ];
-
- public static function castRequest(Request $request, array $a, Stub $stub, bool $isNested)
- {
- $clone = null;
-
- foreach (self::REQUEST_GETTERS as $prop => $getter) {
- $key = Caster::PREFIX_PROTECTED.$prop;
- if (\array_key_exists($key, $a) && null === $a[$key]) {
- if (null === $clone) {
- $clone = clone $request;
- }
- $a[Caster::PREFIX_VIRTUAL.$prop] = $clone->{$getter}();
- }
- }
-
- return $a;
- }
-
- public static function castHttpClient($client, array $a, Stub $stub, bool $isNested)
- {
- $multiKey = sprintf("\0%s\0multi", \get_class($client));
- if (isset($a[$multiKey])) {
- $a[$multiKey] = new CutStub($a[$multiKey]);
- }
-
- return $a;
- }
-
- public static function castHttpClientResponse($response, array $a, Stub $stub, bool $isNested)
- {
- $stub->cut += \count($a);
- $a = [];
-
- foreach ($response->getInfo() as $k => $v) {
- $a[Caster::PREFIX_VIRTUAL.$k] = $v;
- }
-
- return $a;
- }
-
- public static function castUuid(Uuid $uuid, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'toBase58'] = $uuid->toBase58();
- $a[Caster::PREFIX_VIRTUAL.'toBase32'] = $uuid->toBase32();
-
- // symfony/uid >= 5.3
- if (method_exists($uuid, 'getDateTime')) {
- $a[Caster::PREFIX_VIRTUAL.'time'] = $uuid->getDateTime()->format('Y-m-d H:i:s.u \U\T\C');
- }
-
- return $a;
- }
-
- public static function castUlid(Ulid $ulid, array $a, Stub $stub, bool $isNested)
- {
- $a[Caster::PREFIX_VIRTUAL.'toBase58'] = $ulid->toBase58();
- $a[Caster::PREFIX_VIRTUAL.'toRfc4122'] = $ulid->toRfc4122();
-
- // symfony/uid >= 5.3
- if (method_exists($ulid, 'getDateTime')) {
- $a[Caster::PREFIX_VIRTUAL.'time'] = $ulid->getDateTime()->format('Y-m-d H:i:s.v \U\T\C');
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/TraceStub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/TraceStub.php
deleted file mode 100644
index 5eea1c8..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/TraceStub.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Represents a backtrace as returned by debug_backtrace() or Exception->getTrace().
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class TraceStub extends Stub
-{
- public $keepArgs;
- public $sliceOffset;
- public $sliceLength;
- public $numberingOffset;
-
- public function __construct(array $trace, bool $keepArgs = true, int $sliceOffset = 0, int $sliceLength = null, int $numberingOffset = 0)
- {
- $this->value = $trace;
- $this->keepArgs = $keepArgs;
- $this->sliceOffset = $sliceOffset;
- $this->sliceLength = $sliceLength;
- $this->numberingOffset = $numberingOffset;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/UuidCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/UuidCaster.php
deleted file mode 100644
index b102774..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/UuidCaster.php
+++ /dev/null
@@ -1,30 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Ramsey\Uuid\UuidInterface;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * @author Grégoire Pineau <lyrixx@lyrixx.info>
- */
-final class UuidCaster
-{
- public static function castRamseyUuid(UuidInterface $c, array $a, Stub $stub, bool $isNested): array
- {
- $a += [
- Caster::PREFIX_VIRTUAL.'uuid' => (string) $c,
- ];
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/XmlReaderCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/XmlReaderCaster.php
deleted file mode 100644
index 721513c..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/XmlReaderCaster.php
+++ /dev/null
@@ -1,90 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts XmlReader class to array representation.
- *
- * @author Baptiste Clavié <clavie.b@gmail.com>
- *
- * @final
- */
-class XmlReaderCaster
-{
- private const NODE_TYPES = [
- \XMLReader::NONE => 'NONE',
- \XMLReader::ELEMENT => 'ELEMENT',
- \XMLReader::ATTRIBUTE => 'ATTRIBUTE',
- \XMLReader::TEXT => 'TEXT',
- \XMLReader::CDATA => 'CDATA',
- \XMLReader::ENTITY_REF => 'ENTITY_REF',
- \XMLReader::ENTITY => 'ENTITY',
- \XMLReader::PI => 'PI (Processing Instruction)',
- \XMLReader::COMMENT => 'COMMENT',
- \XMLReader::DOC => 'DOC',
- \XMLReader::DOC_TYPE => 'DOC_TYPE',
- \XMLReader::DOC_FRAGMENT => 'DOC_FRAGMENT',
- \XMLReader::NOTATION => 'NOTATION',
- \XMLReader::WHITESPACE => 'WHITESPACE',
- \XMLReader::SIGNIFICANT_WHITESPACE => 'SIGNIFICANT_WHITESPACE',
- \XMLReader::END_ELEMENT => 'END_ELEMENT',
- \XMLReader::END_ENTITY => 'END_ENTITY',
- \XMLReader::XML_DECLARATION => 'XML_DECLARATION',
- ];
-
- public static function castXmlReader(\XMLReader $reader, array $a, Stub $stub, bool $isNested)
- {
- try {
- $properties = [
- 'LOADDTD' => @$reader->getParserProperty(\XMLReader::LOADDTD),
- 'DEFAULTATTRS' => @$reader->getParserProperty(\XMLReader::DEFAULTATTRS),
- 'VALIDATE' => @$reader->getParserProperty(\XMLReader::VALIDATE),
- 'SUBST_ENTITIES' => @$reader->getParserProperty(\XMLReader::SUBST_ENTITIES),
- ];
- } catch (\Error $e) {
- $properties = [
- 'LOADDTD' => false,
- 'DEFAULTATTRS' => false,
- 'VALIDATE' => false,
- 'SUBST_ENTITIES' => false,
- ];
- }
-
- $props = Caster::PREFIX_VIRTUAL.'parserProperties';
- $info = [
- 'localName' => $reader->localName,
- 'prefix' => $reader->prefix,
- 'nodeType' => new ConstStub(self::NODE_TYPES[$reader->nodeType], $reader->nodeType),
- 'depth' => $reader->depth,
- 'isDefault' => $reader->isDefault,
- 'isEmptyElement' => \XMLReader::NONE === $reader->nodeType ? null : $reader->isEmptyElement,
- 'xmlLang' => $reader->xmlLang,
- 'attributeCount' => $reader->attributeCount,
- 'value' => $reader->value,
- 'namespaceURI' => $reader->namespaceURI,
- 'baseURI' => $reader->baseURI ? new LinkStub($reader->baseURI) : $reader->baseURI,
- $props => $properties,
- ];
-
- if ($info[$props] = Caster::filter($info[$props], Caster::EXCLUDE_EMPTY, [], $count)) {
- $info[$props] = new EnumStub($info[$props]);
- $info[$props]->cut = $count;
- }
-
- $info = Caster::filter($info, Caster::EXCLUDE_EMPTY, [], $count);
- // +2 because hasValue and hasAttributes are always filtered
- $stub->cut += $count + 2;
-
- return $a + $info;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/XmlResourceCaster.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/XmlResourceCaster.php
deleted file mode 100644
index ba55fce..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Caster/XmlResourceCaster.php
+++ /dev/null
@@ -1,63 +0,0 @@
-<?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\Component\VarDumper\Caster;
-
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * Casts XML resources to array representation.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- *
- * @final
- */
-class XmlResourceCaster
-{
- private const XML_ERRORS = [
- \XML_ERROR_NONE => 'XML_ERROR_NONE',
- \XML_ERROR_NO_MEMORY => 'XML_ERROR_NO_MEMORY',
- \XML_ERROR_SYNTAX => 'XML_ERROR_SYNTAX',
- \XML_ERROR_NO_ELEMENTS => 'XML_ERROR_NO_ELEMENTS',
- \XML_ERROR_INVALID_TOKEN => 'XML_ERROR_INVALID_TOKEN',
- \XML_ERROR_UNCLOSED_TOKEN => 'XML_ERROR_UNCLOSED_TOKEN',
- \XML_ERROR_PARTIAL_CHAR => 'XML_ERROR_PARTIAL_CHAR',
- \XML_ERROR_TAG_MISMATCH => 'XML_ERROR_TAG_MISMATCH',
- \XML_ERROR_DUPLICATE_ATTRIBUTE => 'XML_ERROR_DUPLICATE_ATTRIBUTE',
- \XML_ERROR_JUNK_AFTER_DOC_ELEMENT => 'XML_ERROR_JUNK_AFTER_DOC_ELEMENT',
- \XML_ERROR_PARAM_ENTITY_REF => 'XML_ERROR_PARAM_ENTITY_REF',
- \XML_ERROR_UNDEFINED_ENTITY => 'XML_ERROR_UNDEFINED_ENTITY',
- \XML_ERROR_RECURSIVE_ENTITY_REF => 'XML_ERROR_RECURSIVE_ENTITY_REF',
- \XML_ERROR_ASYNC_ENTITY => 'XML_ERROR_ASYNC_ENTITY',
- \XML_ERROR_BAD_CHAR_REF => 'XML_ERROR_BAD_CHAR_REF',
- \XML_ERROR_BINARY_ENTITY_REF => 'XML_ERROR_BINARY_ENTITY_REF',
- \XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF => 'XML_ERROR_ATTRIBUTE_EXTERNAL_ENTITY_REF',
- \XML_ERROR_MISPLACED_XML_PI => 'XML_ERROR_MISPLACED_XML_PI',
- \XML_ERROR_UNKNOWN_ENCODING => 'XML_ERROR_UNKNOWN_ENCODING',
- \XML_ERROR_INCORRECT_ENCODING => 'XML_ERROR_INCORRECT_ENCODING',
- \XML_ERROR_UNCLOSED_CDATA_SECTION => 'XML_ERROR_UNCLOSED_CDATA_SECTION',
- \XML_ERROR_EXTERNAL_ENTITY_HANDLING => 'XML_ERROR_EXTERNAL_ENTITY_HANDLING',
- ];
-
- public static function castXml($h, array $a, Stub $stub, bool $isNested)
- {
- $a['current_byte_index'] = xml_get_current_byte_index($h);
- $a['current_column_number'] = xml_get_current_column_number($h);
- $a['current_line_number'] = xml_get_current_line_number($h);
- $a['error_code'] = xml_get_error_code($h);
-
- if (isset(self::XML_ERRORS[$a['error_code']])) {
- $a['error_code'] = new ConstStub(self::XML_ERRORS[$a['error_code']], $a['error_code']);
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/AbstractCloner.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/AbstractCloner.php
deleted file mode 100644
index b835c03..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/AbstractCloner.php
+++ /dev/null
@@ -1,388 +0,0 @@
-<?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\Component\VarDumper\Cloner;
-
-use Symfony\Component\VarDumper\Caster\Caster;
-use Symfony\Component\VarDumper\Exception\ThrowingCasterException;
-
-/**
- * AbstractCloner implements a generic caster mechanism for objects and resources.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-abstract class AbstractCloner implements ClonerInterface
-{
- public static $defaultCasters = [
- '__PHP_Incomplete_Class' => ['Symfony\Component\VarDumper\Caster\Caster', 'castPhpIncompleteClass'],
-
- 'Symfony\Component\VarDumper\Caster\CutStub' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'castStub'],
- 'Symfony\Component\VarDumper\Caster\CutArrayStub' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'castCutArray'],
- 'Symfony\Component\VarDumper\Caster\ConstStub' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'castStub'],
- 'Symfony\Component\VarDumper\Caster\EnumStub' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'castEnum'],
-
- 'Fiber' => ['Symfony\Component\VarDumper\Caster\FiberCaster', 'castFiber'],
-
- 'Closure' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castClosure'],
- 'Generator' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castGenerator'],
- 'ReflectionType' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castType'],
- 'ReflectionAttribute' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castAttribute'],
- 'ReflectionGenerator' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castReflectionGenerator'],
- 'ReflectionClass' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castClass'],
- 'ReflectionClassConstant' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castClassConstant'],
- 'ReflectionFunctionAbstract' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castFunctionAbstract'],
- 'ReflectionMethod' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castMethod'],
- 'ReflectionParameter' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castParameter'],
- 'ReflectionProperty' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castProperty'],
- 'ReflectionReference' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castReference'],
- 'ReflectionExtension' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castExtension'],
- 'ReflectionZendExtension' => ['Symfony\Component\VarDumper\Caster\ReflectionCaster', 'castZendExtension'],
-
- 'Doctrine\Common\Persistence\ObjectManager' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'Doctrine\Common\Proxy\Proxy' => ['Symfony\Component\VarDumper\Caster\DoctrineCaster', 'castCommonProxy'],
- 'Doctrine\ORM\Proxy\Proxy' => ['Symfony\Component\VarDumper\Caster\DoctrineCaster', 'castOrmProxy'],
- 'Doctrine\ORM\PersistentCollection' => ['Symfony\Component\VarDumper\Caster\DoctrineCaster', 'castPersistentCollection'],
- 'Doctrine\Persistence\ObjectManager' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
-
- 'DOMException' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castException'],
- 'DOMStringList' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castLength'],
- 'DOMNameList' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castLength'],
- 'DOMImplementation' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castImplementation'],
- 'DOMImplementationList' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castLength'],
- 'DOMNode' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castNode'],
- 'DOMNameSpaceNode' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castNameSpaceNode'],
- 'DOMDocument' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castDocument'],
- 'DOMNodeList' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castLength'],
- 'DOMNamedNodeMap' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castLength'],
- 'DOMCharacterData' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castCharacterData'],
- 'DOMAttr' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castAttr'],
- 'DOMElement' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castElement'],
- 'DOMText' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castText'],
- 'DOMTypeinfo' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castTypeinfo'],
- 'DOMDomError' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castDomError'],
- 'DOMLocator' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castLocator'],
- 'DOMDocumentType' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castDocumentType'],
- 'DOMNotation' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castNotation'],
- 'DOMEntity' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castEntity'],
- 'DOMProcessingInstruction' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castProcessingInstruction'],
- 'DOMXPath' => ['Symfony\Component\VarDumper\Caster\DOMCaster', 'castXPath'],
-
- 'XMLReader' => ['Symfony\Component\VarDumper\Caster\XmlReaderCaster', 'castXmlReader'],
-
- 'ErrorException' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castErrorException'],
- 'Exception' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castException'],
- 'Error' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castError'],
- 'Symfony\Bridge\Monolog\Logger' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'Symfony\Component\DependencyInjection\ContainerInterface' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'Symfony\Component\EventDispatcher\EventDispatcherInterface' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'Symfony\Component\HttpClient\AmpHttpClient' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castHttpClient'],
- 'Symfony\Component\HttpClient\CurlHttpClient' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castHttpClient'],
- 'Symfony\Component\HttpClient\NativeHttpClient' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castHttpClient'],
- 'Symfony\Component\HttpClient\Response\AmpResponse' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castHttpClientResponse'],
- 'Symfony\Component\HttpClient\Response\CurlResponse' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castHttpClientResponse'],
- 'Symfony\Component\HttpClient\Response\NativeResponse' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castHttpClientResponse'],
- 'Symfony\Component\HttpFoundation\Request' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castRequest'],
- 'Symfony\Component\Uid\Ulid' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castUlid'],
- 'Symfony\Component\Uid\Uuid' => ['Symfony\Component\VarDumper\Caster\SymfonyCaster', 'castUuid'],
- 'Symfony\Component\VarDumper\Exception\ThrowingCasterException' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castThrowingCasterException'],
- 'Symfony\Component\VarDumper\Caster\TraceStub' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castTraceStub'],
- 'Symfony\Component\VarDumper\Caster\FrameStub' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castFrameStub'],
- 'Symfony\Component\VarDumper\Cloner\AbstractCloner' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'Symfony\Component\ErrorHandler\Exception\SilencedErrorContext' => ['Symfony\Component\VarDumper\Caster\ExceptionCaster', 'castSilencedErrorContext'],
-
- 'Imagine\Image\ImageInterface' => ['Symfony\Component\VarDumper\Caster\ImagineCaster', 'castImage'],
-
- 'Ramsey\Uuid\UuidInterface' => ['Symfony\Component\VarDumper\Caster\UuidCaster', 'castRamseyUuid'],
-
- 'ProxyManager\Proxy\ProxyInterface' => ['Symfony\Component\VarDumper\Caster\ProxyManagerCaster', 'castProxy'],
- 'PHPUnit_Framework_MockObject_MockObject' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'PHPUnit\Framework\MockObject\MockObject' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'PHPUnit\Framework\MockObject\Stub' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'Prophecy\Prophecy\ProphecySubjectInterface' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
- 'Mockery\MockInterface' => ['Symfony\Component\VarDumper\Caster\StubCaster', 'cutInternals'],
-
- 'PDO' => ['Symfony\Component\VarDumper\Caster\PdoCaster', 'castPdo'],
- 'PDOStatement' => ['Symfony\Component\VarDumper\Caster\PdoCaster', 'castPdoStatement'],
-
- 'AMQPConnection' => ['Symfony\Component\VarDumper\Caster\AmqpCaster', 'castConnection'],
- 'AMQPChannel' => ['Symfony\Component\VarDumper\Caster\AmqpCaster', 'castChannel'],
- 'AMQPQueue' => ['Symfony\Component\VarDumper\Caster\AmqpCaster', 'castQueue'],
- 'AMQPExchange' => ['Symfony\Component\VarDumper\Caster\AmqpCaster', 'castExchange'],
- 'AMQPEnvelope' => ['Symfony\Component\VarDumper\Caster\AmqpCaster', 'castEnvelope'],
-
- 'ArrayObject' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castArrayObject'],
- 'ArrayIterator' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castArrayIterator'],
- 'SplDoublyLinkedList' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castDoublyLinkedList'],
- 'SplFileInfo' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castFileInfo'],
- 'SplFileObject' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castFileObject'],
- 'SplHeap' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castHeap'],
- 'SplObjectStorage' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castObjectStorage'],
- 'SplPriorityQueue' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castHeap'],
- 'OuterIterator' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castOuterIterator'],
- 'WeakReference' => ['Symfony\Component\VarDumper\Caster\SplCaster', 'castWeakReference'],
-
- 'Redis' => ['Symfony\Component\VarDumper\Caster\RedisCaster', 'castRedis'],
- 'RedisArray' => ['Symfony\Component\VarDumper\Caster\RedisCaster', 'castRedisArray'],
- 'RedisCluster' => ['Symfony\Component\VarDumper\Caster\RedisCaster', 'castRedisCluster'],
-
- 'DateTimeInterface' => ['Symfony\Component\VarDumper\Caster\DateCaster', 'castDateTime'],
- 'DateInterval' => ['Symfony\Component\VarDumper\Caster\DateCaster', 'castInterval'],
- 'DateTimeZone' => ['Symfony\Component\VarDumper\Caster\DateCaster', 'castTimeZone'],
- 'DatePeriod' => ['Symfony\Component\VarDumper\Caster\DateCaster', 'castPeriod'],
-
- 'GMP' => ['Symfony\Component\VarDumper\Caster\GmpCaster', 'castGmp'],
-
- 'MessageFormatter' => ['Symfony\Component\VarDumper\Caster\IntlCaster', 'castMessageFormatter'],
- 'NumberFormatter' => ['Symfony\Component\VarDumper\Caster\IntlCaster', 'castNumberFormatter'],
- 'IntlTimeZone' => ['Symfony\Component\VarDumper\Caster\IntlCaster', 'castIntlTimeZone'],
- 'IntlCalendar' => ['Symfony\Component\VarDumper\Caster\IntlCaster', 'castIntlCalendar'],
- 'IntlDateFormatter' => ['Symfony\Component\VarDumper\Caster\IntlCaster', 'castIntlDateFormatter'],
-
- 'Memcached' => ['Symfony\Component\VarDumper\Caster\MemcachedCaster', 'castMemcached'],
-
- 'Ds\Collection' => ['Symfony\Component\VarDumper\Caster\DsCaster', 'castCollection'],
- 'Ds\Map' => ['Symfony\Component\VarDumper\Caster\DsCaster', 'castMap'],
- 'Ds\Pair' => ['Symfony\Component\VarDumper\Caster\DsCaster', 'castPair'],
- 'Symfony\Component\VarDumper\Caster\DsPairStub' => ['Symfony\Component\VarDumper\Caster\DsCaster', 'castPairStub'],
-
- 'mysqli_driver' => ['Symfony\Component\VarDumper\Caster\MysqliCaster', 'castMysqliDriver'],
-
- 'CurlHandle' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castCurl'],
-
- ':dba' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castDba'],
- ':dba persistent' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castDba'],
-
- 'GdImage' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castGd'],
- ':gd' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castGd'],
-
- ':mysql link' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castMysqlLink'],
- ':pgsql large object' => ['Symfony\Component\VarDumper\Caster\PgSqlCaster', 'castLargeObject'],
- ':pgsql link' => ['Symfony\Component\VarDumper\Caster\PgSqlCaster', 'castLink'],
- ':pgsql link persistent' => ['Symfony\Component\VarDumper\Caster\PgSqlCaster', 'castLink'],
- ':pgsql result' => ['Symfony\Component\VarDumper\Caster\PgSqlCaster', 'castResult'],
- ':process' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castProcess'],
- ':stream' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castStream'],
-
- 'OpenSSLCertificate' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castOpensslX509'],
- ':OpenSSL X.509' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castOpensslX509'],
-
- ':persistent stream' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castStream'],
- ':stream-context' => ['Symfony\Component\VarDumper\Caster\ResourceCaster', 'castStreamContext'],
-
- 'XmlParser' => ['Symfony\Component\VarDumper\Caster\XmlResourceCaster', 'castXml'],
- ':xml' => ['Symfony\Component\VarDumper\Caster\XmlResourceCaster', 'castXml'],
-
- 'RdKafka' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castRdKafka'],
- 'RdKafka\Conf' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castConf'],
- 'RdKafka\KafkaConsumer' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castKafkaConsumer'],
- 'RdKafka\Metadata\Broker' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castBrokerMetadata'],
- 'RdKafka\Metadata\Collection' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castCollectionMetadata'],
- 'RdKafka\Metadata\Partition' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castPartitionMetadata'],
- 'RdKafka\Metadata\Topic' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castTopicMetadata'],
- 'RdKafka\Message' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castMessage'],
- 'RdKafka\Topic' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castTopic'],
- 'RdKafka\TopicPartition' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castTopicPartition'],
- 'RdKafka\TopicConf' => ['Symfony\Component\VarDumper\Caster\RdKafkaCaster', 'castTopicConf'],
- ];
-
- protected $maxItems = 2500;
- protected $maxString = -1;
- protected $minDepth = 1;
-
- /**
- * @var array<string, list<callable>>
- */
- private array $casters = [];
-
- /**
- * @var callable|null
- */
- private $prevErrorHandler;
-
- private array $classInfo = [];
- private int $filter = 0;
-
- /**
- * @param callable[]|null $casters A map of casters
- *
- * @see addCasters
- */
- public function __construct(array $casters = null)
- {
- if (null === $casters) {
- $casters = static::$defaultCasters;
- }
- $this->addCasters($casters);
- }
-
- /**
- * Adds casters for resources and objects.
- *
- * Maps resources or objects types to a callback.
- * Types are in the key, with a callable caster for value.
- * Resource types are to be prefixed with a `:`,
- * see e.g. static::$defaultCasters.
- *
- * @param callable[] $casters A map of casters
- */
- public function addCasters(array $casters)
- {
- foreach ($casters as $type => $callback) {
- $this->casters[$type][] = $callback;
- }
- }
-
- /**
- * Sets the maximum number of items to clone past the minimum depth in nested structures.
- */
- public function setMaxItems(int $maxItems)
- {
- $this->maxItems = $maxItems;
- }
-
- /**
- * Sets the maximum cloned length for strings.
- */
- public function setMaxString(int $maxString)
- {
- $this->maxString = $maxString;
- }
-
- /**
- * Sets the minimum tree depth where we are guaranteed to clone all the items. After this
- * depth is reached, only setMaxItems items will be cloned.
- */
- public function setMinDepth(int $minDepth)
- {
- $this->minDepth = $minDepth;
- }
-
- /**
- * Clones a PHP variable.
- *
- * @param int $filter A bit field of Caster::EXCLUDE_* constants
- */
- public function cloneVar(mixed $var, int $filter = 0): Data
- {
- $this->prevErrorHandler = set_error_handler(function ($type, $msg, $file, $line, $context = []) {
- if (\E_RECOVERABLE_ERROR === $type || \E_USER_ERROR === $type) {
- // Cloner never dies
- throw new \ErrorException($msg, 0, $type, $file, $line);
- }
-
- if ($this->prevErrorHandler) {
- return ($this->prevErrorHandler)($type, $msg, $file, $line, $context);
- }
-
- return false;
- });
- $this->filter = $filter;
-
- if ($gc = gc_enabled()) {
- gc_disable();
- }
- try {
- return new Data($this->doClone($var));
- } finally {
- if ($gc) {
- gc_enable();
- }
- restore_error_handler();
- $this->prevErrorHandler = null;
- }
- }
-
- /**
- * Effectively clones the PHP variable.
- */
- abstract protected function doClone(mixed $var): array;
-
- /**
- * Casts an object to an array representation.
- *
- * @param bool $isNested True if the object is nested in the dumped structure
- */
- protected function castObject(Stub $stub, bool $isNested): array
- {
- $obj = $stub->value;
- $class = $stub->class;
-
- if (str_contains($class, "@anonymous\0")) {
- $stub->class = get_debug_type($obj);
- }
- if (isset($this->classInfo[$class])) {
- [$i, $parents, $hasDebugInfo, $fileInfo] = $this->classInfo[$class];
- } else {
- $i = 2;
- $parents = [$class];
- $hasDebugInfo = method_exists($class, '__debugInfo');
-
- foreach (class_parents($class) as $p) {
- $parents[] = $p;
- ++$i;
- }
- foreach (class_implements($class) as $p) {
- $parents[] = $p;
- ++$i;
- }
- $parents[] = '*';
-
- $r = new \ReflectionClass($class);
- $fileInfo = $r->isInternal() || $r->isSubclassOf(Stub::class) ? [] : [
- 'file' => $r->getFileName(),
- 'line' => $r->getStartLine(),
- ];
-
- $this->classInfo[$class] = [$i, $parents, $hasDebugInfo, $fileInfo];
- }
-
- $stub->attr += $fileInfo;
- $a = Caster::castObject($obj, $class, $hasDebugInfo, $stub->class);
-
- try {
- while ($i--) {
- if (!empty($this->casters[$p = $parents[$i]])) {
- foreach ($this->casters[$p] as $callback) {
- $a = $callback($obj, $a, $stub, $isNested, $this->filter);
- }
- }
- }
- } catch (\Exception $e) {
- $a = [(Stub::TYPE_OBJECT === $stub->type ? Caster::PREFIX_VIRTUAL : '').'⚠' => new ThrowingCasterException($e)] + $a;
- }
-
- return $a;
- }
-
- /**
- * Casts a resource to an array representation.
- *
- * @param bool $isNested True if the object is nested in the dumped structure
- */
- protected function castResource(Stub $stub, bool $isNested): array
- {
- $a = [];
- $res = $stub->value;
- $type = $stub->class;
-
- try {
- if (!empty($this->casters[':'.$type])) {
- foreach ($this->casters[':'.$type] as $callback) {
- $a = $callback($res, $a, $stub, $isNested, $this->filter);
- }
- }
- } catch (\Exception $e) {
- $a = [(Stub::TYPE_OBJECT === $stub->type ? Caster::PREFIX_VIRTUAL : '').'⚠' => new ThrowingCasterException($e)] + $a;
- }
-
- return $a;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/ClonerInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/ClonerInterface.php
deleted file mode 100644
index 5a8e2e4..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/ClonerInterface.php
+++ /dev/null
@@ -1,23 +0,0 @@
-<?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\Component\VarDumper\Cloner;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- */
-interface ClonerInterface
-{
- /**
- * Clones a PHP variable.
- */
- public function cloneVar(mixed $var): Data;
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Cursor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Cursor.php
deleted file mode 100644
index 1fd796d..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Cursor.php
+++ /dev/null
@@ -1,43 +0,0 @@
-<?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\Component\VarDumper\Cloner;
-
-/**
- * Represents the current state of a dumper while dumping.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class Cursor
-{
- public const HASH_INDEXED = Stub::ARRAY_INDEXED;
- public const HASH_ASSOC = Stub::ARRAY_ASSOC;
- public const HASH_OBJECT = Stub::TYPE_OBJECT;
- public const HASH_RESOURCE = Stub::TYPE_RESOURCE;
-
- public $depth = 0;
- public $refIndex = 0;
- public $softRefTo = 0;
- public $softRefCount = 0;
- public $softRefHandle = 0;
- public $hardRefTo = 0;
- public $hardRefCount = 0;
- public $hardRefHandle = 0;
- public $hashType;
- public $hashKey;
- public $hashKeyIsBinary;
- public $hashIndex = 0;
- public $hashLength = 0;
- public $hashCut = 0;
- public $stop = false;
- public $attr = [];
- public $skipChildren = false;
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Data.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Data.php
deleted file mode 100644
index 6ecb883..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Data.php
+++ /dev/null
@@ -1,422 +0,0 @@
-<?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\Component\VarDumper\Cloner;
-
-use Symfony\Component\VarDumper\Caster\Caster;
-use Symfony\Component\VarDumper\Dumper\ContextProvider\SourceContextProvider;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class Data implements \ArrayAccess, \Countable, \IteratorAggregate
-{
- private array $data;
- private int $position = 0;
- private int|string $key = 0;
- private int $maxDepth = 20;
- private int $maxItemsPerDepth = -1;
- private int $useRefHandles = -1;
- private array $context = [];
-
- /**
- * @param array $data An array as returned by ClonerInterface::cloneVar()
- */
- public function __construct(array $data)
- {
- $this->data = $data;
- }
-
- public function getType(): ?string
- {
- $item = $this->data[$this->position][$this->key];
-
- if ($item instanceof Stub && Stub::TYPE_REF === $item->type && !$item->position) {
- $item = $item->value;
- }
- if (!$item instanceof Stub) {
- return \gettype($item);
- }
- if (Stub::TYPE_STRING === $item->type) {
- return 'string';
- }
- if (Stub::TYPE_ARRAY === $item->type) {
- return 'array';
- }
- if (Stub::TYPE_OBJECT === $item->type) {
- return $item->class;
- }
- if (Stub::TYPE_RESOURCE === $item->type) {
- return $item->class.' resource';
- }
-
- return null;
- }
-
- /**
- * Returns a native representation of the original value.
- *
- * @param array|bool $recursive Whether values should be resolved recursively or not
- *
- * @return string|int|float|bool|array|Data[]|null
- */
- public function getValue(array|bool $recursive = false): string|int|float|bool|array|null
- {
- $item = $this->data[$this->position][$this->key];
-
- if ($item instanceof Stub && Stub::TYPE_REF === $item->type && !$item->position) {
- $item = $item->value;
- }
- if (!($item = $this->getStub($item)) instanceof Stub) {
- return $item;
- }
- if (Stub::TYPE_STRING === $item->type) {
- return $item->value;
- }
-
- $children = $item->position ? $this->data[$item->position] : [];
-
- foreach ($children as $k => $v) {
- if ($recursive && !($v = $this->getStub($v)) instanceof Stub) {
- continue;
- }
- $children[$k] = clone $this;
- $children[$k]->key = $k;
- $children[$k]->position = $item->position;
-
- if ($recursive) {
- if (Stub::TYPE_REF === $v->type && ($v = $this->getStub($v->value)) instanceof Stub) {
- $recursive = (array) $recursive;
- if (isset($recursive[$v->position])) {
- continue;
- }
- $recursive[$v->position] = true;
- }
- $children[$k] = $children[$k]->getValue($recursive);
- }
- }
-
- return $children;
- }
-
- public function count(): int
- {
- return \count($this->getValue());
- }
-
- public function getIterator(): \Traversable
- {
- if (!\is_array($value = $this->getValue())) {
- throw new \LogicException(sprintf('"%s" object holds non-iterable type "%s".', self::class, get_debug_type($value)));
- }
-
- yield from $value;
- }
-
- public function __get(string $key)
- {
- if (null !== $data = $this->seek($key)) {
- $item = $this->getStub($data->data[$data->position][$data->key]);
-
- return $item instanceof Stub || [] === $item ? $data : $item;
- }
-
- return null;
- }
-
- public function __isset(string $key): bool
- {
- return null !== $this->seek($key);
- }
-
- public function offsetExists(mixed $key): bool
- {
- return $this->__isset($key);
- }
-
- public function offsetGet(mixed $key): mixed
- {
- return $this->__get($key);
- }
-
- public function offsetSet(mixed $key, mixed $value): void
- {
- throw new \BadMethodCallException(self::class.' objects are immutable.');
- }
-
- public function offsetUnset(mixed $key): void
- {
- throw new \BadMethodCallException(self::class.' objects are immutable.');
- }
-
- public function __toString(): string
- {
- $value = $this->getValue();
-
- if (!\is_array($value)) {
- return (string) $value;
- }
-
- return sprintf('%s (count=%d)', $this->getType(), \count($value));
- }
-
- /**
- * Returns a depth limited clone of $this.
- */
- public function withMaxDepth(int $maxDepth): static
- {
- $data = clone $this;
- $data->maxDepth = $maxDepth;
-
- return $data;
- }
-
- /**
- * Limits the number of elements per depth level.
- */
- public function withMaxItemsPerDepth(int $maxItemsPerDepth): static
- {
- $data = clone $this;
- $data->maxItemsPerDepth = $maxItemsPerDepth;
-
- return $data;
- }
-
- /**
- * Enables/disables objects' identifiers tracking.
- *
- * @param bool $useRefHandles False to hide global ref. handles
- */
- public function withRefHandles(bool $useRefHandles): static
- {
- $data = clone $this;
- $data->useRefHandles = $useRefHandles ? -1 : 0;
-
- return $data;
- }
-
- public function withContext(array $context): static
- {
- $data = clone $this;
- $data->context = $context;
-
- return $data;
- }
-
- /**
- * Seeks to a specific key in nested data structures.
- */
- public function seek(string|int $key): ?static
- {
- $item = $this->data[$this->position][$this->key];
-
- if ($item instanceof Stub && Stub::TYPE_REF === $item->type && !$item->position) {
- $item = $item->value;
- }
- if (!($item = $this->getStub($item)) instanceof Stub || !$item->position) {
- return null;
- }
- $keys = [$key];
-
- switch ($item->type) {
- case Stub::TYPE_OBJECT:
- $keys[] = Caster::PREFIX_DYNAMIC.$key;
- $keys[] = Caster::PREFIX_PROTECTED.$key;
- $keys[] = Caster::PREFIX_VIRTUAL.$key;
- $keys[] = "\0$item->class\0$key";
- // no break
- case Stub::TYPE_ARRAY:
- case Stub::TYPE_RESOURCE:
- break;
- default:
- return null;
- }
-
- $data = null;
- $children = $this->data[$item->position];
-
- foreach ($keys as $key) {
- if (isset($children[$key]) || \array_key_exists($key, $children)) {
- $data = clone $this;
- $data->key = $key;
- $data->position = $item->position;
- break;
- }
- }
-
- return $data;
- }
-
- /**
- * Dumps data with a DumperInterface dumper.
- */
- public function dump(DumperInterface $dumper)
- {
- $refs = [0];
- $cursor = new Cursor();
-
- if ($cursor->attr = $this->context[SourceContextProvider::class] ?? []) {
- $cursor->attr['if_links'] = true;
- $cursor->hashType = -1;
- $dumper->dumpScalar($cursor, 'default', '^');
- $cursor->attr = ['if_links' => true];
- $dumper->dumpScalar($cursor, 'default', ' ');
- $cursor->hashType = 0;
- }
-
- $this->dumpItem($dumper, $cursor, $refs, $this->data[$this->position][$this->key]);
- }
-
- /**
- * Depth-first dumping of items.
- *
- * @param mixed $item A Stub object or the original value being dumped
- */
- private function dumpItem(DumperInterface $dumper, Cursor $cursor, array &$refs, mixed $item)
- {
- $cursor->refIndex = 0;
- $cursor->softRefTo = $cursor->softRefHandle = $cursor->softRefCount = 0;
- $cursor->hardRefTo = $cursor->hardRefHandle = $cursor->hardRefCount = 0;
- $firstSeen = true;
-
- if (!$item instanceof Stub) {
- $cursor->attr = [];
- $type = \gettype($item);
- if ($item && 'array' === $type) {
- $item = $this->getStub($item);
- }
- } elseif (Stub::TYPE_REF === $item->type) {
- if ($item->handle) {
- if (!isset($refs[$r = $item->handle - (\PHP_INT_MAX >> 1)])) {
- $cursor->refIndex = $refs[$r] = $cursor->refIndex ?: ++$refs[0];
- } else {
- $firstSeen = false;
- }
- $cursor->hardRefTo = $refs[$r];
- $cursor->hardRefHandle = $this->useRefHandles & $item->handle;
- $cursor->hardRefCount = 0 < $item->handle ? $item->refCount : 0;
- }
- $cursor->attr = $item->attr;
- $type = $item->class ?: \gettype($item->value);
- $item = $this->getStub($item->value);
- }
- if ($item instanceof Stub) {
- if ($item->refCount) {
- if (!isset($refs[$r = $item->handle])) {
- $cursor->refIndex = $refs[$r] = $cursor->refIndex ?: ++$refs[0];
- } else {
- $firstSeen = false;
- }
- $cursor->softRefTo = $refs[$r];
- }
- $cursor->softRefHandle = $this->useRefHandles & $item->handle;
- $cursor->softRefCount = $item->refCount;
- $cursor->attr = $item->attr;
- $cut = $item->cut;
-
- if ($item->position && $firstSeen) {
- $children = $this->data[$item->position];
-
- if ($cursor->stop) {
- if ($cut >= 0) {
- $cut += \count($children);
- }
- $children = [];
- }
- } else {
- $children = [];
- }
- switch ($item->type) {
- case Stub::TYPE_STRING:
- $dumper->dumpString($cursor, $item->value, Stub::STRING_BINARY === $item->class, $cut);
- break;
-
- case Stub::TYPE_ARRAY:
- $item = clone $item;
- $item->type = $item->class;
- $item->class = $item->value;
- // no break
- case Stub::TYPE_OBJECT:
- case Stub::TYPE_RESOURCE:
- $withChildren = $children && $cursor->depth !== $this->maxDepth && $this->maxItemsPerDepth;
- $dumper->enterHash($cursor, $item->type, $item->class, $withChildren);
- if ($withChildren) {
- if ($cursor->skipChildren) {
- $withChildren = false;
- $cut = -1;
- } else {
- $cut = $this->dumpChildren($dumper, $cursor, $refs, $children, $cut, $item->type, null !== $item->class);
- }
- } elseif ($children && 0 <= $cut) {
- $cut += \count($children);
- }
- $cursor->skipChildren = false;
- $dumper->leaveHash($cursor, $item->type, $item->class, $withChildren, $cut);
- break;
-
- default:
- throw new \RuntimeException(sprintf('Unexpected Stub type: "%s".', $item->type));
- }
- } elseif ('array' === $type) {
- $dumper->enterHash($cursor, Cursor::HASH_INDEXED, 0, false);
- $dumper->leaveHash($cursor, Cursor::HASH_INDEXED, 0, false, 0);
- } elseif ('string' === $type) {
- $dumper->dumpString($cursor, $item, false, 0);
- } else {
- $dumper->dumpScalar($cursor, $type, $item);
- }
- }
-
- /**
- * Dumps children of hash structures.
- *
- * @return int The final number of removed items
- */
- private function dumpChildren(DumperInterface $dumper, Cursor $parentCursor, array &$refs, array $children, int $hashCut, int $hashType, bool $dumpKeys): int
- {
- $cursor = clone $parentCursor;
- ++$cursor->depth;
- $cursor->hashType = $hashType;
- $cursor->hashIndex = 0;
- $cursor->hashLength = \count($children);
- $cursor->hashCut = $hashCut;
- foreach ($children as $key => $child) {
- $cursor->hashKeyIsBinary = isset($key[0]) && !preg_match('//u', $key);
- $cursor->hashKey = $dumpKeys ? $key : null;
- $this->dumpItem($dumper, $cursor, $refs, $child);
- if (++$cursor->hashIndex === $this->maxItemsPerDepth || $cursor->stop) {
- $parentCursor->stop = true;
-
- return $hashCut >= 0 ? $hashCut + $cursor->hashLength - $cursor->hashIndex : $hashCut;
- }
- }
-
- return $hashCut;
- }
-
- private function getStub(mixed $item)
- {
- if (!$item || !\is_array($item)) {
- return $item;
- }
-
- $stub = new Stub();
- $stub->type = Stub::TYPE_ARRAY;
- foreach ($item as $stub->class => $stub->position) {
- }
- if (isset($item[0])) {
- $stub->cut = $item[0];
- }
- $stub->value = $stub->cut + ($stub->position ? \count($this->data[$stub->position]) : 0);
-
- return $stub;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/DumperInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/DumperInterface.php
deleted file mode 100644
index 61d02d2..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/DumperInterface.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?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\Component\VarDumper\Cloner;
-
-/**
- * DumperInterface used by Data objects.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-interface DumperInterface
-{
- /**
- * Dumps a scalar value.
- */
- public function dumpScalar(Cursor $cursor, string $type, string|int|float|bool|null $value);
-
- /**
- * Dumps a string.
- *
- * @param string $str The string being dumped
- * @param bool $bin Whether $str is UTF-8 or binary encoded
- * @param int $cut The number of characters $str has been cut by
- */
- public function dumpString(Cursor $cursor, string $str, bool $bin, int $cut);
-
- /**
- * Dumps while entering an hash.
- *
- * @param int $type A Cursor::HASH_* const for the type of hash
- * @param string|int|null $class The object class, resource type or array count
- * @param bool $hasChild When the dump of the hash has child item
- */
- public function enterHash(Cursor $cursor, int $type, string|int|null $class, bool $hasChild);
-
- /**
- * Dumps while leaving an hash.
- *
- * @param int $type A Cursor::HASH_* const for the type of hash
- * @param string|int|null $class The object class, resource type or array count
- * @param bool $hasChild When the dump of the hash has child item
- * @param int $cut The number of items the hash has been cut by
- */
- public function leaveHash(Cursor $cursor, int $type, string|int|null $class, bool $hasChild, int $cut);
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Stub.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Stub.php
deleted file mode 100644
index 1c5b887..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/Stub.php
+++ /dev/null
@@ -1,67 +0,0 @@
-<?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\Component\VarDumper\Cloner;
-
-/**
- * Represents the main properties of a PHP variable.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class Stub
-{
- public const TYPE_REF = 1;
- public const TYPE_STRING = 2;
- public const TYPE_ARRAY = 3;
- public const TYPE_OBJECT = 4;
- public const TYPE_RESOURCE = 5;
-
- public const STRING_BINARY = 1;
- public const STRING_UTF8 = 2;
-
- public const ARRAY_ASSOC = 1;
- public const ARRAY_INDEXED = 2;
-
- public $type = self::TYPE_REF;
- public $class = '';
- public $value;
- public $cut = 0;
- public $handle = 0;
- public $refCount = 0;
- public $position = 0;
- public $attr = [];
-
- private static array $defaultProperties = [];
-
- /**
- * @internal
- */
- public function __sleep(): array
- {
- $properties = [];
-
- if (!isset(self::$defaultProperties[$c = static::class])) {
- self::$defaultProperties[$c] = get_class_vars($c);
-
- foreach ((new \ReflectionClass($c))->getStaticProperties() as $k => $v) {
- unset(self::$defaultProperties[$c][$k]);
- }
- }
-
- foreach (self::$defaultProperties[$c] as $k => $v) {
- if ($this->$k !== $v) {
- $properties[] = $k;
- }
- }
-
- return $properties;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/VarCloner.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/VarCloner.php
deleted file mode 100644
index 9afcc34..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Cloner/VarCloner.php
+++ /dev/null
@@ -1,286 +0,0 @@
-<?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\Component\VarDumper\Cloner;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class VarCloner extends AbstractCloner
-{
- private static string $gid;
- private static array $arrayCache = [];
-
- /**
- * {@inheritdoc}
- */
- protected function doClone(mixed $var): array
- {
- $len = 1; // Length of $queue
- $pos = 0; // Number of cloned items past the minimum depth
- $refsCounter = 0; // Hard references counter
- $queue = [[$var]]; // This breadth-first queue is the return value
- $hardRefs = []; // Map of original zval ids to stub objects
- $objRefs = []; // Map of original object handles to their stub object counterpart
- $objects = []; // Keep a ref to objects to ensure their handle cannot be reused while cloning
- $resRefs = []; // Map of original resource handles to their stub object counterpart
- $values = []; // Map of stub objects' ids to original values
- $maxItems = $this->maxItems;
- $maxString = $this->maxString;
- $minDepth = $this->minDepth;
- $currentDepth = 0; // Current tree depth
- $currentDepthFinalIndex = 0; // Final $queue index for current tree depth
- $minimumDepthReached = 0 === $minDepth; // Becomes true when minimum tree depth has been reached
- $cookie = (object) []; // Unique object used to detect hard references
- $a = null; // Array cast for nested structures
- $stub = null; // Stub capturing the main properties of an original item value
- // or null if the original value is used directly
-
- $gid = self::$gid ??= md5(random_bytes(6)); // Unique string used to detect the special $GLOBALS variable
- $arrayStub = new Stub();
- $arrayStub->type = Stub::TYPE_ARRAY;
- $fromObjCast = false;
-
- for ($i = 0; $i < $len; ++$i) {
- // Detect when we move on to the next tree depth
- if ($i > $currentDepthFinalIndex) {
- ++$currentDepth;
- $currentDepthFinalIndex = $len - 1;
- if ($currentDepth >= $minDepth) {
- $minimumDepthReached = true;
- }
- }
-
- $refs = $vals = $queue[$i];
- foreach ($vals as $k => $v) {
- // $v is the original value or a stub object in case of hard references
-
- $zvalRef = ($r = \ReflectionReference::fromArrayElement($vals, $k)) ? $r->getId() : null;
-
- if ($zvalRef) {
- $vals[$k] = &$stub; // Break hard references to make $queue completely
- unset($stub); // independent from the original structure
- if (null !== $vals[$k] = $hardRefs[$zvalRef] ?? null) {
- $v = $vals[$k];
- if ($v->value instanceof Stub && (Stub::TYPE_OBJECT === $v->value->type || Stub::TYPE_RESOURCE === $v->value->type)) {
- ++$v->value->refCount;
- }
- ++$v->refCount;
- continue;
- }
- $vals[$k] = new Stub();
- $vals[$k]->value = $v;
- $vals[$k]->handle = ++$refsCounter;
- $hardRefs[$zvalRef] = $vals[$k];
- }
- // Create $stub when the original value $v cannot be used directly
- // If $v is a nested structure, put that structure in array $a
- switch (true) {
- case null === $v:
- case \is_bool($v):
- case \is_int($v):
- case \is_float($v):
- continue 2;
- case \is_string($v):
- if ('' === $v) {
- continue 2;
- }
- if (!preg_match('//u', $v)) {
- $stub = new Stub();
- $stub->type = Stub::TYPE_STRING;
- $stub->class = Stub::STRING_BINARY;
- if (0 <= $maxString && 0 < $cut = \strlen($v) - $maxString) {
- $stub->cut = $cut;
- $stub->value = substr($v, 0, -$cut);
- } else {
- $stub->value = $v;
- }
- } elseif (0 <= $maxString && isset($v[1 + ($maxString >> 2)]) && 0 < $cut = mb_strlen($v, 'UTF-8') - $maxString) {
- $stub = new Stub();
- $stub->type = Stub::TYPE_STRING;
- $stub->class = Stub::STRING_UTF8;
- $stub->cut = $cut;
- $stub->value = mb_substr($v, 0, $maxString, 'UTF-8');
- } else {
- continue 2;
- }
- $a = null;
- break;
-
- case \is_array($v):
- if (!$v) {
- continue 2;
- }
- $stub = $arrayStub;
-
- if (\PHP_VERSION_ID >= 80100) {
- $stub->class = array_is_list($v) ? Stub::ARRAY_INDEXED : Stub::ARRAY_ASSOC;
- $a = $v;
- break;
- }
-
- $stub->class = Stub::ARRAY_INDEXED;
-
- $j = -1;
- foreach ($v as $gk => $gv) {
- if ($gk !== ++$j) {
- $stub->class = Stub::ARRAY_ASSOC;
- $a = $v;
- $a[$gid] = true;
- break;
- }
- }
-
- // Copies of $GLOBALS have very strange behavior,
- // let's detect them with some black magic
- if (isset($v[$gid])) {
- unset($v[$gid]);
- $a = [];
- foreach ($v as $gk => &$gv) {
- if ($v === $gv && !isset($hardRefs[\ReflectionReference::fromArrayElement($v, $gk)->getId()])) {
- unset($v);
- $v = new Stub();
- $v->value = [$v->cut = \count($gv), Stub::TYPE_ARRAY => 0];
- $v->handle = -1;
- $gv = &$a[$gk];
- $hardRefs[\ReflectionReference::fromArrayElement($a, $gk)->getId()] = &$gv;
- $gv = $v;
- }
-
- $a[$gk] = &$gv;
- }
- unset($gv);
- } else {
- $a = $v;
- }
- break;
-
- case \is_object($v):
- if (empty($objRefs[$h = spl_object_id($v)])) {
- $stub = new Stub();
- $stub->type = Stub::TYPE_OBJECT;
- $stub->class = \get_class($v);
- $stub->value = $v;
- $stub->handle = $h;
- $a = $this->castObject($stub, 0 < $i);
- if ($v !== $stub->value) {
- if (Stub::TYPE_OBJECT !== $stub->type || null === $stub->value) {
- break;
- }
- $stub->handle = $h = spl_object_id($stub->value);
- }
- $stub->value = null;
- if (0 <= $maxItems && $maxItems <= $pos && $minimumDepthReached) {
- $stub->cut = \count($a);
- $a = null;
- }
- }
- if (empty($objRefs[$h])) {
- $objRefs[$h] = $stub;
- $objects[] = $v;
- } else {
- $stub = $objRefs[$h];
- ++$stub->refCount;
- $a = null;
- }
- break;
-
- default: // resource
- if (empty($resRefs[$h = (int) $v])) {
- $stub = new Stub();
- $stub->type = Stub::TYPE_RESOURCE;
- if ('Unknown' === $stub->class = @get_resource_type($v)) {
- $stub->class = 'Closed';
- }
- $stub->value = $v;
- $stub->handle = $h;
- $a = $this->castResource($stub, 0 < $i);
- $stub->value = null;
- if (0 <= $maxItems && $maxItems <= $pos && $minimumDepthReached) {
- $stub->cut = \count($a);
- $a = null;
- }
- }
- if (empty($resRefs[$h])) {
- $resRefs[$h] = $stub;
- } else {
- $stub = $resRefs[$h];
- ++$stub->refCount;
- $a = null;
- }
- break;
- }
-
- if ($a) {
- if (!$minimumDepthReached || 0 > $maxItems) {
- $queue[$len] = $a;
- $stub->position = $len++;
- } elseif ($pos < $maxItems) {
- if ($maxItems < $pos += \count($a)) {
- $a = \array_slice($a, 0, $maxItems - $pos, true);
- if ($stub->cut >= 0) {
- $stub->cut += $pos - $maxItems;
- }
- }
- $queue[$len] = $a;
- $stub->position = $len++;
- } elseif ($stub->cut >= 0) {
- $stub->cut += \count($a);
- $stub->position = 0;
- }
- }
-
- if ($arrayStub === $stub) {
- if ($arrayStub->cut) {
- $stub = [$arrayStub->cut, $arrayStub->class => $arrayStub->position];
- $arrayStub->cut = 0;
- } elseif (isset(self::$arrayCache[$arrayStub->class][$arrayStub->position])) {
- $stub = self::$arrayCache[$arrayStub->class][$arrayStub->position];
- } else {
- self::$arrayCache[$arrayStub->class][$arrayStub->position] = $stub = [$arrayStub->class => $arrayStub->position];
- }
- }
-
- if (!$zvalRef) {
- $vals[$k] = $stub;
- } else {
- $hardRefs[$zvalRef]->value = $stub;
- }
- }
-
- if ($fromObjCast) {
- $fromObjCast = false;
- $refs = $vals;
- $vals = [];
- $j = -1;
- foreach ($queue[$i] as $k => $v) {
- foreach ([$k => true] as $gk => $gv) {
- }
- if ($gk !== $k) {
- $vals = (object) $vals;
- $vals->{$k} = $refs[++$j];
- $vals = (array) $vals;
- } else {
- $vals[$k] = $refs[++$j];
- }
- }
- }
-
- $queue[$i] = $vals;
- }
-
- foreach ($values as $h => $v) {
- $hardRefs[$h] = $v;
- }
-
- return $queue;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/CliDescriptor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/CliDescriptor.php
deleted file mode 100644
index e3d5f1d..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/CliDescriptor.php
+++ /dev/null
@@ -1,79 +0,0 @@
-<?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\Component\VarDumper\Command\Descriptor;
-
-use Symfony\Component\Console\Input\ArrayInput;
-use Symfony\Component\Console\Output\OutputInterface;
-use Symfony\Component\Console\Style\SymfonyStyle;
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Dumper\CliDumper;
-
-/**
- * Describe collected data clones for cli output.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- *
- * @final
- */
-class CliDescriptor implements DumpDescriptorInterface
-{
- private $dumper;
- private mixed $lastIdentifier = null;
-
- public function __construct(CliDumper $dumper)
- {
- $this->dumper = $dumper;
- }
-
- public function describe(OutputInterface $output, Data $data, array $context, int $clientId): void
- {
- $io = $output instanceof SymfonyStyle ? $output : new SymfonyStyle(new ArrayInput([]), $output);
- $this->dumper->setColors($output->isDecorated());
-
- $rows = [['date', date('r', (int) $context['timestamp'])]];
- $lastIdentifier = $this->lastIdentifier;
- $this->lastIdentifier = $clientId;
-
- $section = "Received from client #$clientId";
- if (isset($context['request'])) {
- $request = $context['request'];
- $this->lastIdentifier = $request['identifier'];
- $section = sprintf('%s %s', $request['method'], $request['uri']);
- if ($controller = $request['controller']) {
- $rows[] = ['controller', rtrim($this->dumper->dump($controller, true), "\n")];
- }
- } elseif (isset($context['cli'])) {
- $this->lastIdentifier = $context['cli']['identifier'];
- $section = '$ '.$context['cli']['command_line'];
- }
-
- if ($this->lastIdentifier !== $lastIdentifier) {
- $io->section($section);
- }
-
- if (isset($context['source'])) {
- $source = $context['source'];
- $sourceInfo = sprintf('%s on line %d', $source['name'], $source['line']);
- if ($fileLink = $source['file_link'] ?? null) {
- $sourceInfo = sprintf('<href=%s>%s</>', $fileLink, $sourceInfo);
- }
- $rows[] = ['source', $sourceInfo];
- $file = $source['file_relative'] ?? $source['file'];
- $rows[] = ['file', $file];
- }
-
- $io->table([], $rows);
-
- $this->dumper->dump($data);
- $io->newLine();
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/DumpDescriptorInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/DumpDescriptorInterface.php
deleted file mode 100644
index 267d27b..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/DumpDescriptorInterface.php
+++ /dev/null
@@ -1,23 +0,0 @@
-<?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\Component\VarDumper\Command\Descriptor;
-
-use Symfony\Component\Console\Output\OutputInterface;
-use Symfony\Component\VarDumper\Cloner\Data;
-
-/**
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-interface DumpDescriptorInterface
-{
- public function describe(OutputInterface $output, Data $data, array $context, int $clientId): void;
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/HtmlDescriptor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/HtmlDescriptor.php
deleted file mode 100644
index 1c0d80a..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/Descriptor/HtmlDescriptor.php
+++ /dev/null
@@ -1,119 +0,0 @@
-<?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\Component\VarDumper\Command\Descriptor;
-
-use Symfony\Component\Console\Output\OutputInterface;
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Dumper\HtmlDumper;
-
-/**
- * Describe collected data clones for html output.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- *
- * @final
- */
-class HtmlDescriptor implements DumpDescriptorInterface
-{
- private $dumper;
- private bool $initialized = false;
-
- public function __construct(HtmlDumper $dumper)
- {
- $this->dumper = $dumper;
- }
-
- public function describe(OutputInterface $output, Data $data, array $context, int $clientId): void
- {
- if (!$this->initialized) {
- $styles = file_get_contents(__DIR__.'/../../Resources/css/htmlDescriptor.css');
- $scripts = file_get_contents(__DIR__.'/../../Resources/js/htmlDescriptor.js');
- $output->writeln("<style>$styles</style><script>$scripts</script>");
- $this->initialized = true;
- }
-
- $title = '-';
- if (isset($context['request'])) {
- $request = $context['request'];
- $controller = "<span class='dumped-tag'>{$this->dumper->dump($request['controller'], true, ['maxDepth' => 0])}</span>";
- $title = sprintf('<code>%s</code> <a href="%s">%s</a>', $request['method'], $uri = $request['uri'], $uri);
- $dedupIdentifier = $request['identifier'];
- } elseif (isset($context['cli'])) {
- $title = '<code>$ </code>'.$context['cli']['command_line'];
- $dedupIdentifier = $context['cli']['identifier'];
- } else {
- $dedupIdentifier = uniqid('', true);
- }
-
- $sourceDescription = '';
- if (isset($context['source'])) {
- $source = $context['source'];
- $projectDir = $source['project_dir'] ?? null;
- $sourceDescription = sprintf('%s on line %d', $source['name'], $source['line']);
- if (isset($source['file_link'])) {
- $sourceDescription = sprintf('<a href="%s">%s</a>', $source['file_link'], $sourceDescription);
- }
- }
-
- $isoDate = $this->extractDate($context, 'c');
- $tags = array_filter([
- 'controller' => $controller ?? null,
- 'project dir' => $projectDir ?? null,
- ]);
-
- $output->writeln(<<<HTML
-<article data-dedup-id="$dedupIdentifier">
- <header>
- <div class="row">
- <h2 class="col">$title</h2>
- <time class="col text-small" title="$isoDate" datetime="$isoDate">
- {$this->extractDate($context)}
- </time>
- </div>
- {$this->renderTags($tags)}
- </header>
- <section class="body">
- <p class="text-small">
- $sourceDescription
- </p>
- {$this->dumper->dump($data, true)}
- </section>
-</article>
-HTML
- );
- }
-
- private function extractDate(array $context, string $format = 'r'): string
- {
- return date($format, (int) $context['timestamp']);
- }
-
- private function renderTags(array $tags): string
- {
- if (!$tags) {
- return '';
- }
-
- $renderedTags = '';
- foreach ($tags as $key => $value) {
- $renderedTags .= sprintf('<li><span class="badge">%s</span>%s</li>', $key, $value);
- }
-
- return <<<HTML
-<div class="row">
- <ul class="tags">
- $renderedTags
- </ul>
-</div>
-HTML;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/ServerDumpCommand.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/ServerDumpCommand.php
deleted file mode 100644
index 13dd475..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Command/ServerDumpCommand.php
+++ /dev/null
@@ -1,112 +0,0 @@
-<?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\Component\VarDumper\Command;
-
-use Symfony\Component\Console\Attribute\AsCommand;
-use Symfony\Component\Console\Command\Command;
-use Symfony\Component\Console\Completion\CompletionInput;
-use Symfony\Component\Console\Completion\CompletionSuggestions;
-use Symfony\Component\Console\Exception\InvalidArgumentException;
-use Symfony\Component\Console\Input\InputInterface;
-use Symfony\Component\Console\Input\InputOption;
-use Symfony\Component\Console\Output\OutputInterface;
-use Symfony\Component\Console\Style\SymfonyStyle;
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Command\Descriptor\CliDescriptor;
-use Symfony\Component\VarDumper\Command\Descriptor\DumpDescriptorInterface;
-use Symfony\Component\VarDumper\Command\Descriptor\HtmlDescriptor;
-use Symfony\Component\VarDumper\Dumper\CliDumper;
-use Symfony\Component\VarDumper\Dumper\HtmlDumper;
-use Symfony\Component\VarDumper\Server\DumpServer;
-
-/**
- * Starts a dump server to collect and output dumps on a single place with multiple formats support.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- *
- * @final
- */
-#[AsCommand(name: 'server:dump', description: 'Start a dump server that collects and displays dumps in a single place')]
-class ServerDumpCommand extends Command
-{
- private $server;
-
- /** @var DumpDescriptorInterface[] */
- private array $descriptors;
-
- public function __construct(DumpServer $server, array $descriptors = [])
- {
- $this->server = $server;
- $this->descriptors = $descriptors + [
- 'cli' => new CliDescriptor(new CliDumper()),
- 'html' => new HtmlDescriptor(new HtmlDumper()),
- ];
-
- parent::__construct();
- }
-
- protected function configure()
- {
- $this
- ->addOption('format', null, InputOption::VALUE_REQUIRED, sprintf('The output format (%s)', implode(', ', $this->getAvailableFormats())), 'cli')
- ->setHelp(<<<'EOF'
-<info>%command.name%</info> starts a dump server that collects and displays
-dumps in a single place for debugging you application:
-
- <info>php %command.full_name%</info>
-
-You can consult dumped data in HTML format in your browser by providing the <comment>--format=html</comment> option
-and redirecting the output to a file:
-
- <info>php %command.full_name% --format="html" > dump.html</info>
-
-EOF
- )
- ;
- }
-
- protected function execute(InputInterface $input, OutputInterface $output): int
- {
- $io = new SymfonyStyle($input, $output);
- $format = $input->getOption('format');
-
- if (!$descriptor = $this->descriptors[$format] ?? null) {
- throw new InvalidArgumentException(sprintf('Unsupported format "%s".', $format));
- }
-
- $errorIo = $io->getErrorStyle();
- $errorIo->title('Symfony Var Dumper Server');
-
- $this->server->start();
-
- $errorIo->success(sprintf('Server listening on %s', $this->server->getHost()));
- $errorIo->comment('Quit the server with CONTROL-C.');
-
- $this->server->listen(function (Data $data, array $context, int $clientId) use ($descriptor, $io) {
- $descriptor->describe($io, $data, $context, $clientId);
- });
-
- return 0;
- }
-
- public function complete(CompletionInput $input, CompletionSuggestions $suggestions): void
- {
- if ($input->mustSuggestOptionValuesFor('format')) {
- $suggestions->suggestValues($this->getAvailableFormats());
- }
- }
-
- private function getAvailableFormats(): array
- {
- return array_keys($this->descriptors);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/AbstractDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/AbstractDumper.php
deleted file mode 100644
index 6ac3808..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/AbstractDumper.php
+++ /dev/null
@@ -1,202 +0,0 @@
-<?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\Component\VarDumper\Dumper;
-
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Cloner\DumperInterface;
-
-/**
- * Abstract mechanism for dumping a Data object.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-abstract class AbstractDumper implements DataDumperInterface, DumperInterface
-{
- public const DUMP_LIGHT_ARRAY = 1;
- public const DUMP_STRING_LENGTH = 2;
- public const DUMP_COMMA_SEPARATOR = 4;
- public const DUMP_TRAILING_COMMA = 8;
-
- public static $defaultOutput = 'php://output';
-
- protected $line = '';
- protected $lineDumper;
- protected $outputStream;
- protected $decimalPoint; // This is locale dependent
- protected $indentPad = ' ';
- protected $flags;
-
- private string $charset = '';
-
- /**
- * @param callable|resource|string|null $output A line dumper callable, an opened stream or an output path, defaults to static::$defaultOutput
- * @param string|null $charset The default character encoding to use for non-UTF8 strings
- * @param int $flags A bit field of static::DUMP_* constants to fine tune dumps representation
- */
- public function __construct($output = null, string $charset = null, int $flags = 0)
- {
- $this->flags = $flags;
- $this->setCharset($charset ?: ini_get('php.output_encoding') ?: ini_get('default_charset') ?: 'UTF-8');
- $this->decimalPoint = localeconv();
- $this->decimalPoint = $this->decimalPoint['decimal_point'];
- $this->setOutput($output ?: static::$defaultOutput);
- if (!$output && \is_string(static::$defaultOutput)) {
- static::$defaultOutput = $this->outputStream;
- }
- }
-
- /**
- * Sets the output destination of the dumps.
- *
- * @param callable|resource|string $output A line dumper callable, an opened stream or an output path
- *
- * @return callable|resource|string The previous output destination
- */
- public function setOutput($output)
- {
- $prev = $this->outputStream ?? $this->lineDumper;
-
- if (\is_callable($output)) {
- $this->outputStream = null;
- $this->lineDumper = $output;
- } else {
- if (\is_string($output)) {
- $output = fopen($output, 'w');
- }
- $this->outputStream = $output;
- $this->lineDumper = [$this, 'echoLine'];
- }
-
- return $prev;
- }
-
- /**
- * Sets the default character encoding to use for non-UTF8 strings.
- *
- * @return string The previous charset
- */
- public function setCharset(string $charset): string
- {
- $prev = $this->charset;
-
- $charset = strtoupper($charset);
- $charset = null === $charset || 'UTF-8' === $charset || 'UTF8' === $charset ? 'CP1252' : $charset;
-
- $this->charset = $charset;
-
- return $prev;
- }
-
- /**
- * Sets the indentation pad string.
- *
- * @param string $pad A string that will be prepended to dumped lines, repeated by nesting level
- *
- * @return string The previous indent pad
- */
- public function setIndentPad(string $pad): string
- {
- $prev = $this->indentPad;
- $this->indentPad = $pad;
-
- return $prev;
- }
-
- /**
- * Dumps a Data object.
- *
- * @param callable|resource|string|true|null $output A line dumper callable, an opened stream, an output path or true to return the dump
- *
- * @return string|null The dump as string when $output is true
- */
- public function dump(Data $data, $output = null): ?string
- {
- $this->decimalPoint = localeconv();
- $this->decimalPoint = $this->decimalPoint['decimal_point'];
-
- if ($locale = $this->flags & (self::DUMP_COMMA_SEPARATOR | self::DUMP_TRAILING_COMMA) ? setlocale(\LC_NUMERIC, 0) : null) {
- setlocale(\LC_NUMERIC, 'C');
- }
-
- if ($returnDump = true === $output) {
- $output = fopen('php://memory', 'r+');
- }
- if ($output) {
- $prevOutput = $this->setOutput($output);
- }
- try {
- $data->dump($this);
- $this->dumpLine(-1);
-
- if ($returnDump) {
- $result = stream_get_contents($output, -1, 0);
- fclose($output);
-
- return $result;
- }
- } finally {
- if ($output) {
- $this->setOutput($prevOutput);
- }
- if ($locale) {
- setlocale(\LC_NUMERIC, $locale);
- }
- }
-
- return null;
- }
-
- /**
- * Dumps the current line.
- *
- * @param int $depth The recursive depth in the dumped structure for the line being dumped,
- * or -1 to signal the end-of-dump to the line dumper callable
- */
- protected function dumpLine(int $depth)
- {
- ($this->lineDumper)($this->line, $depth, $this->indentPad);
- $this->line = '';
- }
-
- /**
- * Generic line dumper callback.
- */
- protected function echoLine(string $line, int $depth, string $indentPad)
- {
- if (-1 !== $depth) {
- fwrite($this->outputStream, str_repeat($indentPad, $depth).$line."\n");
- }
- }
-
- /**
- * Converts a non-UTF-8 string to UTF-8.
- */
- protected function utf8Encode(?string $s): ?string
- {
- if (null === $s || preg_match('//u', $s)) {
- return $s;
- }
-
- if (!\function_exists('iconv')) {
- throw new \RuntimeException('Unable to convert a non-UTF-8 string to UTF-8: required function iconv() does not exist. You should install ext-iconv or symfony/polyfill-iconv.');
- }
-
- if (false !== $c = @iconv($this->charset, 'UTF-8', $s)) {
- return $c;
- }
- if ('CP1252' !== $this->charset && false !== $c = @iconv('CP1252', 'UTF-8', $s)) {
- return $c;
- }
-
- return iconv('CP850', 'UTF-8', $s);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/CliDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/CliDumper.php
deleted file mode 100644
index f6e290c..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/CliDumper.php
+++ /dev/null
@@ -1,643 +0,0 @@
-<?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\Component\VarDumper\Dumper;
-
-use Symfony\Component\VarDumper\Cloner\Cursor;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * CliDumper dumps variables for command line output.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class CliDumper extends AbstractDumper
-{
- public static $defaultColors;
- public static $defaultOutput = 'php://stdout';
-
- protected $colors;
- protected $maxStringWidth = 0;
- protected $styles = [
- // See http://en.wikipedia.org/wiki/ANSI_escape_code#graphics
- 'default' => '0;38;5;208',
- 'num' => '1;38;5;38',
- 'const' => '1;38;5;208',
- 'str' => '1;38;5;113',
- 'note' => '38;5;38',
- 'ref' => '38;5;247',
- 'public' => '',
- 'protected' => '',
- 'private' => '',
- 'meta' => '38;5;170',
- 'key' => '38;5;113',
- 'index' => '38;5;38',
- ];
-
- protected static $controlCharsRx = '/[\x00-\x1F\x7F]+/';
- protected static $controlCharsMap = [
- "\t" => '\t',
- "\n" => '\n',
- "\v" => '\v',
- "\f" => '\f',
- "\r" => '\r',
- "\033" => '\e',
- ];
-
- protected $collapseNextHash = false;
- protected $expandNextHash = false;
-
- private array $displayOptions = [
- 'fileLinkFormat' => null,
- ];
-
- private bool $handlesHrefGracefully;
-
- /**
- * {@inheritdoc}
- */
- public function __construct($output = null, string $charset = null, int $flags = 0)
- {
- parent::__construct($output, $charset, $flags);
-
- if ('\\' === \DIRECTORY_SEPARATOR && !$this->isWindowsTrueColor()) {
- // Use only the base 16 xterm colors when using ANSICON or standard Windows 10 CLI
- $this->setStyles([
- 'default' => '31',
- 'num' => '1;34',
- 'const' => '1;31',
- 'str' => '1;32',
- 'note' => '34',
- 'ref' => '1;30',
- 'meta' => '35',
- 'key' => '32',
- 'index' => '34',
- ]);
- }
-
- $this->displayOptions['fileLinkFormat'] = ini_get('xdebug.file_link_format') ?: get_cfg_var('xdebug.file_link_format') ?: 'file://%f#L%l';
- }
-
- /**
- * Enables/disables colored output.
- */
- public function setColors(bool $colors)
- {
- $this->colors = $colors;
- }
-
- /**
- * Sets the maximum number of characters per line for dumped strings.
- */
- public function setMaxStringWidth(int $maxStringWidth)
- {
- $this->maxStringWidth = $maxStringWidth;
- }
-
- /**
- * Configures styles.
- *
- * @param array $styles A map of style names to style definitions
- */
- public function setStyles(array $styles)
- {
- $this->styles = $styles + $this->styles;
- }
-
- /**
- * Configures display options.
- *
- * @param array $displayOptions A map of display options to customize the behavior
- */
- public function setDisplayOptions(array $displayOptions)
- {
- $this->displayOptions = $displayOptions + $this->displayOptions;
- }
-
- /**
- * {@inheritdoc}
- */
- public function dumpScalar(Cursor $cursor, string $type, string|int|float|bool|null $value)
- {
- $this->dumpKey($cursor);
-
- $style = 'const';
- $attr = $cursor->attr;
-
- switch ($type) {
- case 'default':
- $style = 'default';
- break;
-
- case 'integer':
- $style = 'num';
-
- if (isset($this->styles['integer'])) {
- $style = 'integer';
- }
-
- break;
-
- case 'double':
- $style = 'num';
-
- if (isset($this->styles['float'])) {
- $style = 'float';
- }
-
- switch (true) {
- case \INF === $value: $value = 'INF'; break;
- case -\INF === $value: $value = '-INF'; break;
- case is_nan($value): $value = 'NAN'; break;
- default:
- $value = (string) $value;
- if (!str_contains($value, $this->decimalPoint)) {
- $value .= $this->decimalPoint.'0';
- }
- break;
- }
- break;
-
- case 'NULL':
- $value = 'null';
- break;
-
- case 'boolean':
- $value = $value ? 'true' : 'false';
- break;
-
- default:
- $attr += ['value' => $this->utf8Encode($value)];
- $value = $this->utf8Encode($type);
- break;
- }
-
- $this->line .= $this->style($style, $value, $attr);
-
- $this->endValue($cursor);
- }
-
- /**
- * {@inheritdoc}
- */
- public function dumpString(Cursor $cursor, string $str, bool $bin, int $cut)
- {
- $this->dumpKey($cursor);
- $attr = $cursor->attr;
-
- if ($bin) {
- $str = $this->utf8Encode($str);
- }
- if ('' === $str) {
- $this->line .= '""';
- $this->endValue($cursor);
- } else {
- $attr += [
- 'length' => 0 <= $cut ? mb_strlen($str, 'UTF-8') + $cut : 0,
- 'binary' => $bin,
- ];
- $str = $bin && false !== strpos($str, "\0") ? [$str] : explode("\n", $str);
- if (isset($str[1]) && !isset($str[2]) && !isset($str[1][0])) {
- unset($str[1]);
- $str[0] .= "\n";
- }
- $m = \count($str) - 1;
- $i = $lineCut = 0;
-
- if (self::DUMP_STRING_LENGTH & $this->flags) {
- $this->line .= '('.$attr['length'].') ';
- }
- if ($bin) {
- $this->line .= 'b';
- }
-
- if ($m) {
- $this->line .= '"""';
- $this->dumpLine($cursor->depth);
- } else {
- $this->line .= '"';
- }
-
- foreach ($str as $str) {
- if ($i < $m) {
- $str .= "\n";
- }
- if (0 < $this->maxStringWidth && $this->maxStringWidth < $len = mb_strlen($str, 'UTF-8')) {
- $str = mb_substr($str, 0, $this->maxStringWidth, 'UTF-8');
- $lineCut = $len - $this->maxStringWidth;
- }
- if ($m && 0 < $cursor->depth) {
- $this->line .= $this->indentPad;
- }
- if ('' !== $str) {
- $this->line .= $this->style('str', $str, $attr);
- }
- if ($i++ == $m) {
- if ($m) {
- if ('' !== $str) {
- $this->dumpLine($cursor->depth);
- if (0 < $cursor->depth) {
- $this->line .= $this->indentPad;
- }
- }
- $this->line .= '"""';
- } else {
- $this->line .= '"';
- }
- if ($cut < 0) {
- $this->line .= '…';
- $lineCut = 0;
- } elseif ($cut) {
- $lineCut += $cut;
- }
- }
- if ($lineCut) {
- $this->line .= '…'.$lineCut;
- $lineCut = 0;
- }
-
- if ($i > $m) {
- $this->endValue($cursor);
- } else {
- $this->dumpLine($cursor->depth);
- }
- }
- }
- }
-
- /**
- * {@inheritdoc}
- */
- public function enterHash(Cursor $cursor, int $type, string|int|null $class, bool $hasChild)
- {
- if (null === $this->colors) {
- $this->colors = $this->supportsColors();
- }
-
- $this->dumpKey($cursor);
- $attr = $cursor->attr;
-
- if ($this->collapseNextHash) {
- $cursor->skipChildren = true;
- $this->collapseNextHash = $hasChild = false;
- }
-
- $class = $this->utf8Encode($class);
- if (Cursor::HASH_OBJECT === $type) {
- $prefix = $class && 'stdClass' !== $class ? $this->style('note', $class, $attr).(empty($attr['cut_hash']) ? ' {' : '') : '{';
- } elseif (Cursor::HASH_RESOURCE === $type) {
- $prefix = $this->style('note', $class.' resource', $attr).($hasChild ? ' {' : ' ');
- } else {
- $prefix = $class && !(self::DUMP_LIGHT_ARRAY & $this->flags) ? $this->style('note', 'array:'.$class).' [' : '[';
- }
-
- if (($cursor->softRefCount || 0 < $cursor->softRefHandle) && empty($attr['cut_hash'])) {
- $prefix .= $this->style('ref', (Cursor::HASH_RESOURCE === $type ? '@' : '#').(0 < $cursor->softRefHandle ? $cursor->softRefHandle : $cursor->softRefTo), ['count' => $cursor->softRefCount]);
- } elseif ($cursor->hardRefTo && !$cursor->refIndex && $class) {
- $prefix .= $this->style('ref', '&'.$cursor->hardRefTo, ['count' => $cursor->hardRefCount]);
- } elseif (!$hasChild && Cursor::HASH_RESOURCE === $type) {
- $prefix = substr($prefix, 0, -1);
- }
-
- $this->line .= $prefix;
-
- if ($hasChild) {
- $this->dumpLine($cursor->depth);
- }
- }
-
- /**
- * {@inheritdoc}
- */
- public function leaveHash(Cursor $cursor, int $type, string|int|null $class, bool $hasChild, int $cut)
- {
- if (empty($cursor->attr['cut_hash'])) {
- $this->dumpEllipsis($cursor, $hasChild, $cut);
- $this->line .= Cursor::HASH_OBJECT === $type ? '}' : (Cursor::HASH_RESOURCE !== $type ? ']' : ($hasChild ? '}' : ''));
- }
-
- $this->endValue($cursor);
- }
-
- /**
- * Dumps an ellipsis for cut children.
- *
- * @param bool $hasChild When the dump of the hash has child item
- * @param int $cut The number of items the hash has been cut by
- */
- protected function dumpEllipsis(Cursor $cursor, bool $hasChild, int $cut)
- {
- if ($cut) {
- $this->line .= ' …';
- if (0 < $cut) {
- $this->line .= $cut;
- }
- if ($hasChild) {
- $this->dumpLine($cursor->depth + 1);
- }
- }
- }
-
- /**
- * Dumps a key in a hash structure.
- */
- protected function dumpKey(Cursor $cursor)
- {
- if (null !== $key = $cursor->hashKey) {
- if ($cursor->hashKeyIsBinary) {
- $key = $this->utf8Encode($key);
- }
- $attr = ['binary' => $cursor->hashKeyIsBinary];
- $bin = $cursor->hashKeyIsBinary ? 'b' : '';
- $style = 'key';
- switch ($cursor->hashType) {
- default:
- case Cursor::HASH_INDEXED:
- if (self::DUMP_LIGHT_ARRAY & $this->flags) {
- break;
- }
- $style = 'index';
- // no break
- case Cursor::HASH_ASSOC:
- if (\is_int($key)) {
- $this->line .= $this->style($style, $key).' => ';
- } else {
- $this->line .= $bin.'"'.$this->style($style, $key).'" => ';
- }
- break;
-
- case Cursor::HASH_RESOURCE:
- $key = "\0~\0".$key;
- // no break
- case Cursor::HASH_OBJECT:
- if (!isset($key[0]) || "\0" !== $key[0]) {
- $this->line .= '+'.$bin.$this->style('public', $key).': ';
- } elseif (0 < strpos($key, "\0", 1)) {
- $key = explode("\0", substr($key, 1), 2);
-
- switch ($key[0][0]) {
- case '+': // User inserted keys
- $attr['dynamic'] = true;
- $this->line .= '+'.$bin.'"'.$this->style('public', $key[1], $attr).'": ';
- break 2;
- case '~':
- $style = 'meta';
- if (isset($key[0][1])) {
- parse_str(substr($key[0], 1), $attr);
- $attr += ['binary' => $cursor->hashKeyIsBinary];
- }
- break;
- case '*':
- $style = 'protected';
- $bin = '#'.$bin;
- break;
- default:
- $attr['class'] = $key[0];
- $style = 'private';
- $bin = '-'.$bin;
- break;
- }
-
- if (isset($attr['collapse'])) {
- if ($attr['collapse']) {
- $this->collapseNextHash = true;
- } else {
- $this->expandNextHash = true;
- }
- }
-
- $this->line .= $bin.$this->style($style, $key[1], $attr).($attr['separator'] ?? ': ');
- } else {
- // This case should not happen
- $this->line .= '-'.$bin.'"'.$this->style('private', $key, ['class' => '']).'": ';
- }
- break;
- }
-
- if ($cursor->hardRefTo) {
- $this->line .= $this->style('ref', '&'.($cursor->hardRefCount ? $cursor->hardRefTo : ''), ['count' => $cursor->hardRefCount]).' ';
- }
- }
- }
-
- /**
- * Decorates a value with some style.
- *
- * @param string $style The type of style being applied
- * @param string $value The value being styled
- * @param array $attr Optional context information
- */
- protected function style(string $style, string $value, array $attr = []): string
- {
- if (null === $this->colors) {
- $this->colors = $this->supportsColors();
- }
-
- $this->handlesHrefGracefully ??= 'JetBrains-JediTerm' !== getenv('TERMINAL_EMULATOR')
- && (!getenv('KONSOLE_VERSION') || (int) getenv('KONSOLE_VERSION') > 201100);
-
- if (isset($attr['ellipsis'], $attr['ellipsis-type'])) {
- $prefix = substr($value, 0, -$attr['ellipsis']);
- if ('cli' === \PHP_SAPI && 'path' === $attr['ellipsis-type'] && isset($_SERVER[$pwd = '\\' === \DIRECTORY_SEPARATOR ? 'CD' : 'PWD']) && str_starts_with($prefix, $_SERVER[$pwd])) {
- $prefix = '.'.substr($prefix, \strlen($_SERVER[$pwd]));
- }
- if (!empty($attr['ellipsis-tail'])) {
- $prefix .= substr($value, -$attr['ellipsis'], $attr['ellipsis-tail']);
- $value = substr($value, -$attr['ellipsis'] + $attr['ellipsis-tail']);
- } else {
- $value = substr($value, -$attr['ellipsis']);
- }
-
- $value = $this->style('default', $prefix).$this->style($style, $value);
-
- goto href;
- }
-
- $map = static::$controlCharsMap;
- $startCchr = $this->colors ? "\033[m\033[{$this->styles['default']}m" : '';
- $endCchr = $this->colors ? "\033[m\033[{$this->styles[$style]}m" : '';
- $value = preg_replace_callback(static::$controlCharsRx, function ($c) use ($map, $startCchr, $endCchr) {
- $s = $startCchr;
- $c = $c[$i = 0];
- do {
- $s .= $map[$c[$i]] ?? sprintf('\x%02X', \ord($c[$i]));
- } while (isset($c[++$i]));
-
- return $s.$endCchr;
- }, $value, -1, $cchrCount);
-
- if ($this->colors) {
- if ($cchrCount && "\033" === $value[0]) {
- $value = substr($value, \strlen($startCchr));
- } else {
- $value = "\033[{$this->styles[$style]}m".$value;
- }
- if ($cchrCount && str_ends_with($value, $endCchr)) {
- $value = substr($value, 0, -\strlen($endCchr));
- } else {
- $value .= "\033[{$this->styles['default']}m";
- }
- }
-
- href:
- if ($this->colors && $this->handlesHrefGracefully) {
- if (isset($attr['file']) && $href = $this->getSourceLink($attr['file'], $attr['line'] ?? 0)) {
- if ('note' === $style) {
- $value .= "\033]8;;{$href}\033\\^\033]8;;\033\\";
- } else {
- $attr['href'] = $href;
- }
- }
- if (isset($attr['href'])) {
- $value = "\033]8;;{$attr['href']}\033\\{$value}\033]8;;\033\\";
- }
- } elseif ($attr['if_links'] ?? false) {
- return '';
- }
-
- return $value;
- }
-
- protected function supportsColors(): bool
- {
- if ($this->outputStream !== static::$defaultOutput) {
- return $this->hasColorSupport($this->outputStream);
- }
- if (null !== static::$defaultColors) {
- return static::$defaultColors;
- }
- if (isset($_SERVER['argv'][1])) {
- $colors = $_SERVER['argv'];
- $i = \count($colors);
- while (--$i > 0) {
- if (isset($colors[$i][5])) {
- switch ($colors[$i]) {
- case '--ansi':
- case '--color':
- case '--color=yes':
- case '--color=force':
- case '--color=always':
- case '--colors=always':
- return static::$defaultColors = true;
-
- case '--no-ansi':
- case '--color=no':
- case '--color=none':
- case '--color=never':
- case '--colors=never':
- return static::$defaultColors = false;
- }
- }
- }
- }
-
- $h = stream_get_meta_data($this->outputStream) + ['wrapper_type' => null];
- $h = 'Output' === $h['stream_type'] && 'PHP' === $h['wrapper_type'] ? fopen('php://stdout', 'w') : $this->outputStream;
-
- return static::$defaultColors = $this->hasColorSupport($h);
- }
-
- /**
- * {@inheritdoc}
- */
- protected function dumpLine(int $depth, bool $endOfValue = false)
- {
- if ($this->colors) {
- $this->line = sprintf("\033[%sm%s\033[m", $this->styles['default'], $this->line);
- }
- parent::dumpLine($depth);
- }
-
- protected function endValue(Cursor $cursor)
- {
- if (-1 === $cursor->hashType) {
- return;
- }
-
- if (Stub::ARRAY_INDEXED === $cursor->hashType || Stub::ARRAY_ASSOC === $cursor->hashType) {
- if (self::DUMP_TRAILING_COMMA & $this->flags && 0 < $cursor->depth) {
- $this->line .= ',';
- } elseif (self::DUMP_COMMA_SEPARATOR & $this->flags && 1 < $cursor->hashLength - $cursor->hashIndex) {
- $this->line .= ',';
- }
- }
-
- $this->dumpLine($cursor->depth, true);
- }
-
- /**
- * Returns true if the stream supports colorization.
- *
- * Reference: Composer\XdebugHandler\Process::supportsColor
- * https://github.com/composer/xdebug-handler
- */
- private function hasColorSupport(mixed $stream): bool
- {
- if (!\is_resource($stream) || 'stream' !== get_resource_type($stream)) {
- return false;
- }
-
- // Follow https://no-color.org/
- if (isset($_SERVER['NO_COLOR']) || false !== getenv('NO_COLOR')) {
- return false;
- }
-
- if ('Hyper' === getenv('TERM_PROGRAM')) {
- return true;
- }
-
- if (\DIRECTORY_SEPARATOR === '\\') {
- return (\function_exists('sapi_windows_vt100_support')
- && @sapi_windows_vt100_support($stream))
- || false !== getenv('ANSICON')
- || 'ON' === getenv('ConEmuANSI')
- || 'xterm' === getenv('TERM');
- }
-
- return stream_isatty($stream);
- }
-
- /**
- * Returns true if the Windows terminal supports true color.
- *
- * Note that this does not check an output stream, but relies on environment
- * variables from known implementations, or a PHP and Windows version that
- * supports true color.
- */
- private function isWindowsTrueColor(): bool
- {
- $result = 183 <= getenv('ANSICON_VER')
- || 'ON' === getenv('ConEmuANSI')
- || 'xterm' === getenv('TERM')
- || 'Hyper' === getenv('TERM_PROGRAM');
-
- if (!$result) {
- $version = sprintf(
- '%s.%s.%s',
- PHP_WINDOWS_VERSION_MAJOR,
- PHP_WINDOWS_VERSION_MINOR,
- PHP_WINDOWS_VERSION_BUILD
- );
- $result = $version >= '10.0.15063';
- }
-
- return $result;
- }
-
- private function getSourceLink(string $file, int $line)
- {
- if ($fmt = $this->displayOptions['fileLinkFormat']) {
- return \is_string($fmt) ? strtr($fmt, ['%f' => $file, '%l' => $line]) : ($fmt->format($file, $line) ?: 'file://'.$file.'#L'.$line);
- }
-
- return false;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/CliContextProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/CliContextProvider.php
deleted file mode 100644
index 38f8789..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/CliContextProvider.php
+++ /dev/null
@@ -1,32 +0,0 @@
-<?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\Component\VarDumper\Dumper\ContextProvider;
-
-/**
- * Tries to provide context on CLI.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-final class CliContextProvider implements ContextProviderInterface
-{
- public function getContext(): ?array
- {
- if ('cli' !== \PHP_SAPI) {
- return null;
- }
-
- return [
- 'command_line' => $commandLine = implode(' ', $_SERVER['argv'] ?? []),
- 'identifier' => hash('crc32b', $commandLine.$_SERVER['REQUEST_TIME_FLOAT']),
- ];
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/ContextProviderInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/ContextProviderInterface.php
deleted file mode 100644
index 532aa0f..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/ContextProviderInterface.php
+++ /dev/null
@@ -1,22 +0,0 @@
-<?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\Component\VarDumper\Dumper\ContextProvider;
-
-/**
- * Interface to provide contextual data about dump data clones sent to a server.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-interface ContextProviderInterface
-{
- public function getContext(): ?array;
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/RequestContextProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/RequestContextProvider.php
deleted file mode 100644
index 3684a47..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/RequestContextProvider.php
+++ /dev/null
@@ -1,51 +0,0 @@
-<?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\Component\VarDumper\Dumper\ContextProvider;
-
-use Symfony\Component\HttpFoundation\RequestStack;
-use Symfony\Component\VarDumper\Caster\ReflectionCaster;
-use Symfony\Component\VarDumper\Cloner\VarCloner;
-
-/**
- * Tries to provide context from a request.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-final class RequestContextProvider implements ContextProviderInterface
-{
- private $requestStack;
- private $cloner;
-
- public function __construct(RequestStack $requestStack)
- {
- $this->requestStack = $requestStack;
- $this->cloner = new VarCloner();
- $this->cloner->setMaxItems(0);
- $this->cloner->addCasters(ReflectionCaster::UNSET_CLOSURE_FILE_INFO);
- }
-
- public function getContext(): ?array
- {
- if (null === $request = $this->requestStack->getCurrentRequest()) {
- return null;
- }
-
- $controller = $request->attributes->get('_controller');
-
- return [
- 'uri' => $request->getUri(),
- 'method' => $request->getMethod(),
- 'controller' => $controller ? $this->cloner->cloneVar($controller) : $controller,
- 'identifier' => spl_object_hash($request),
- ];
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/SourceContextProvider.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/SourceContextProvider.php
deleted file mode 100644
index 8ef6e36..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextProvider/SourceContextProvider.php
+++ /dev/null
@@ -1,126 +0,0 @@
-<?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\Component\VarDumper\Dumper\ContextProvider;
-
-use Symfony\Component\HttpKernel\Debug\FileLinkFormatter;
-use Symfony\Component\VarDumper\Cloner\VarCloner;
-use Symfony\Component\VarDumper\Dumper\HtmlDumper;
-use Symfony\Component\VarDumper\VarDumper;
-use Twig\Template;
-
-/**
- * Tries to provide context from sources (class name, file, line, code excerpt, ...).
- *
- * @author Nicolas Grekas <p@tchwork.com>
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-final class SourceContextProvider implements ContextProviderInterface
-{
- private int $limit;
- private ?string $charset;
- private ?string $projectDir;
- private $fileLinkFormatter;
-
- public function __construct(string $charset = null, string $projectDir = null, FileLinkFormatter $fileLinkFormatter = null, int $limit = 9)
- {
- $this->charset = $charset;
- $this->projectDir = $projectDir;
- $this->fileLinkFormatter = $fileLinkFormatter;
- $this->limit = $limit;
- }
-
- public function getContext(): ?array
- {
- $trace = debug_backtrace(\DEBUG_BACKTRACE_PROVIDE_OBJECT | \DEBUG_BACKTRACE_IGNORE_ARGS, $this->limit);
-
- $file = $trace[1]['file'];
- $line = $trace[1]['line'];
- $name = false;
- $fileExcerpt = false;
-
- for ($i = 2; $i < $this->limit; ++$i) {
- if (isset($trace[$i]['class'], $trace[$i]['function'])
- && 'dump' === $trace[$i]['function']
- && VarDumper::class === $trace[$i]['class']
- ) {
- $file = $trace[$i]['file'] ?? $file;
- $line = $trace[$i]['line'] ?? $line;
-
- while (++$i < $this->limit) {
- if (isset($trace[$i]['function'], $trace[$i]['file']) && empty($trace[$i]['class']) && !str_starts_with($trace[$i]['function'], 'call_user_func')) {
- $file = $trace[$i]['file'];
- $line = $trace[$i]['line'];
-
- break;
- } elseif (isset($trace[$i]['object']) && $trace[$i]['object'] instanceof Template) {
- $template = $trace[$i]['object'];
- $name = $template->getTemplateName();
- $src = method_exists($template, 'getSourceContext') ? $template->getSourceContext()->getCode() : (method_exists($template, 'getSource') ? $template->getSource() : false);
- $info = $template->getDebugInfo();
- if (isset($info[$trace[$i - 1]['line']])) {
- $line = $info[$trace[$i - 1]['line']];
- $file = method_exists($template, 'getSourceContext') ? $template->getSourceContext()->getPath() : null;
-
- if ($src) {
- $src = explode("\n", $src);
- $fileExcerpt = [];
-
- for ($i = max($line - 3, 1), $max = min($line + 3, \count($src)); $i <= $max; ++$i) {
- $fileExcerpt[] = '<li'.($i === $line ? ' class="selected"' : '').'><code>'.$this->htmlEncode($src[$i - 1]).'</code></li>';
- }
-
- $fileExcerpt = '<ol start="'.max($line - 3, 1).'">'.implode("\n", $fileExcerpt).'</ol>';
- }
- }
- break;
- }
- }
- break;
- }
- }
-
- if (false === $name) {
- $name = str_replace('\\', '/', $file);
- $name = substr($name, strrpos($name, '/') + 1);
- }
-
- $context = ['name' => $name, 'file' => $file, 'line' => $line];
- $context['file_excerpt'] = $fileExcerpt;
-
- if (null !== $this->projectDir) {
- $context['project_dir'] = $this->projectDir;
- if (str_starts_with($file, $this->projectDir)) {
- $context['file_relative'] = ltrim(substr($file, \strlen($this->projectDir)), \DIRECTORY_SEPARATOR);
- }
- }
-
- if ($this->fileLinkFormatter && $fileLink = $this->fileLinkFormatter->format($context['file'], $context['line'])) {
- $context['file_link'] = $fileLink;
- }
-
- return $context;
- }
-
- private function htmlEncode(string $s): string
- {
- $html = '';
-
- $dumper = new HtmlDumper(function ($line) use (&$html) { $html .= $line; }, $this->charset);
- $dumper->setDumpHeader('');
- $dumper->setDumpBoundaries('', '');
-
- $cloner = new VarCloner();
- $dumper->dump($cloner->cloneVar($s));
-
- return substr(strip_tags($html), 1, -1);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextualizedDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextualizedDumper.php
deleted file mode 100644
index 18ab56e..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ContextualizedDumper.php
+++ /dev/null
@@ -1,43 +0,0 @@
-<?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\Component\VarDumper\Dumper;
-
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Dumper\ContextProvider\ContextProviderInterface;
-
-/**
- * @author Kévin Thérage <therage.kevin@gmail.com>
- */
-class ContextualizedDumper implements DataDumperInterface
-{
- private $wrappedDumper;
- private array $contextProviders;
-
- /**
- * @param ContextProviderInterface[] $contextProviders
- */
- public function __construct(DataDumperInterface $wrappedDumper, array $contextProviders)
- {
- $this->wrappedDumper = $wrappedDumper;
- $this->contextProviders = $contextProviders;
- }
-
- public function dump(Data $data)
- {
- $context = [];
- foreach ($this->contextProviders as $contextProvider) {
- $context[\get_class($contextProvider)] = $contextProvider->getContext();
- }
-
- $this->wrappedDumper->dump($data->withContext($context));
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/DataDumperInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/DataDumperInterface.php
deleted file mode 100644
index b173bcc..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/DataDumperInterface.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?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\Component\VarDumper\Dumper;
-
-use Symfony\Component\VarDumper\Cloner\Data;
-
-/**
- * DataDumperInterface for dumping Data objects.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-interface DataDumperInterface
-{
- public function dump(Data $data);
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/HtmlDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/HtmlDumper.php
deleted file mode 100644
index 40e97a5..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/HtmlDumper.php
+++ /dev/null
@@ -1,986 +0,0 @@
-<?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\Component\VarDumper\Dumper;
-
-use Symfony\Component\VarDumper\Cloner\Cursor;
-use Symfony\Component\VarDumper\Cloner\Data;
-
-/**
- * HtmlDumper dumps variables as HTML.
- *
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class HtmlDumper extends CliDumper
-{
- public static $defaultOutput = 'php://output';
-
- protected static $themes = [
- 'dark' => [
- 'default' => 'background-color:#18171B; color:#FF8400; line-height:1.2em; font:12px Menlo, Monaco, Consolas, monospace; word-wrap: break-word; white-space: pre-wrap; position:relative; z-index:99999; word-break: break-all',
- 'num' => 'font-weight:bold; color:#1299DA',
- 'const' => 'font-weight:bold',
- 'str' => 'font-weight:bold; color:#56DB3A',
- 'note' => 'color:#1299DA',
- 'ref' => 'color:#A0A0A0',
- 'public' => 'color:#FFFFFF',
- 'protected' => 'color:#FFFFFF',
- 'private' => 'color:#FFFFFF',
- 'meta' => 'color:#B729D9',
- 'key' => 'color:#56DB3A',
- 'index' => 'color:#1299DA',
- 'ellipsis' => 'color:#FF8400',
- 'ns' => 'user-select:none;',
- ],
- 'light' => [
- 'default' => 'background:none; color:#CC7832; line-height:1.2em; font:12px Menlo, Monaco, Consolas, monospace; word-wrap: break-word; white-space: pre-wrap; position:relative; z-index:99999; word-break: break-all',
- 'num' => 'font-weight:bold; color:#1299DA',
- 'const' => 'font-weight:bold',
- 'str' => 'font-weight:bold; color:#629755;',
- 'note' => 'color:#6897BB',
- 'ref' => 'color:#6E6E6E',
- 'public' => 'color:#262626',
- 'protected' => 'color:#262626',
- 'private' => 'color:#262626',
- 'meta' => 'color:#B729D9',
- 'key' => 'color:#789339',
- 'index' => 'color:#1299DA',
- 'ellipsis' => 'color:#CC7832',
- 'ns' => 'user-select:none;',
- ],
- ];
-
- protected $dumpHeader;
- protected $dumpPrefix = '<pre class=sf-dump id=%s data-indent-pad="%s">';
- protected $dumpSuffix = '</pre><script>Sfdump(%s)</script>';
- protected $dumpId = 'sf-dump';
- protected $colors = true;
- protected $headerIsDumped = false;
- protected $lastDepth = -1;
- protected $styles;
-
- private array $displayOptions = [
- 'maxDepth' => 1,
- 'maxStringLength' => 160,
- 'fileLinkFormat' => null,
- ];
- private array $extraDisplayOptions = [];
-
- /**
- * {@inheritdoc}
- */
- public function __construct($output = null, string $charset = null, int $flags = 0)
- {
- AbstractDumper::__construct($output, $charset, $flags);
- $this->dumpId = 'sf-dump-'.mt_rand();
- $this->displayOptions['fileLinkFormat'] = ini_get('xdebug.file_link_format') ?: get_cfg_var('xdebug.file_link_format');
- $this->styles = static::$themes['dark'] ?? self::$themes['dark'];
- }
-
- /**
- * {@inheritdoc}
- */
- public function setStyles(array $styles)
- {
- $this->headerIsDumped = false;
- $this->styles = $styles + $this->styles;
- }
-
- public function setTheme(string $themeName)
- {
- if (!isset(static::$themes[$themeName])) {
- throw new \InvalidArgumentException(sprintf('Theme "%s" does not exist in class "%s".', $themeName, static::class));
- }
-
- $this->setStyles(static::$themes[$themeName]);
- }
-
- /**
- * Configures display options.
- *
- * @param array $displayOptions A map of display options to customize the behavior
- */
- public function setDisplayOptions(array $displayOptions)
- {
- $this->headerIsDumped = false;
- $this->displayOptions = $displayOptions + $this->displayOptions;
- }
-
- /**
- * Sets an HTML header that will be dumped once in the output stream.
- */
- public function setDumpHeader(?string $header)
- {
- $this->dumpHeader = $header;
- }
-
- /**
- * Sets an HTML prefix and suffix that will encapse every single dump.
- */
- public function setDumpBoundaries(string $prefix, string $suffix)
- {
- $this->dumpPrefix = $prefix;
- $this->dumpSuffix = $suffix;
- }
-
- /**
- * {@inheritdoc}
- */
- public function dump(Data $data, $output = null, array $extraDisplayOptions = []): ?string
- {
- $this->extraDisplayOptions = $extraDisplayOptions;
- $result = parent::dump($data, $output);
- $this->dumpId = 'sf-dump-'.mt_rand();
-
- return $result;
- }
-
- /**
- * Dumps the HTML header.
- */
- protected function getDumpHeader()
- {
- $this->headerIsDumped = $this->outputStream ?? $this->lineDumper;
-
- if (null !== $this->dumpHeader) {
- return $this->dumpHeader;
- }
-
- $line = str_replace('{$options}', json_encode($this->displayOptions, \JSON_FORCE_OBJECT), <<<'EOHTML'
-<script>
-Sfdump = window.Sfdump || (function (doc) {
-
-var refStyle = doc.createElement('style'),
- rxEsc = /([.*+?^${}()|\[\]\/\\])/g,
- idRx = /\bsf-dump-\d+-ref[012]\w+\b/,
- keyHint = 0 <= navigator.platform.toUpperCase().indexOf('MAC') ? 'Cmd' : 'Ctrl',
- addEventListener = function (e, n, cb) {
- e.addEventListener(n, cb, false);
- };
-
-refStyle.innerHTML = 'pre.sf-dump .sf-dump-compact, .sf-dump-str-collapse .sf-dump-str-collapse, .sf-dump-str-expand .sf-dump-str-expand { display: none; }';
-(doc.documentElement.firstElementChild || doc.documentElement.children[0]).appendChild(refStyle);
-refStyle = doc.createElement('style');
-(doc.documentElement.firstElementChild || doc.documentElement.children[0]).appendChild(refStyle);
-
-if (!doc.addEventListener) {
- addEventListener = function (element, eventName, callback) {
- element.attachEvent('on' + eventName, function (e) {
- e.preventDefault = function () {e.returnValue = false;};
- e.target = e.srcElement;
- callback(e);
- });
- };
-}
-
-function toggle(a, recursive) {
- var s = a.nextSibling || {}, oldClass = s.className, arrow, newClass;
-
- if (/\bsf-dump-compact\b/.test(oldClass)) {
- arrow = '▼';
- newClass = 'sf-dump-expanded';
- } else if (/\bsf-dump-expanded\b/.test(oldClass)) {
- arrow = '▶';
- newClass = 'sf-dump-compact';
- } else {
- return false;
- }
-
- if (doc.createEvent && s.dispatchEvent) {
- var event = doc.createEvent('Event');
- event.initEvent('sf-dump-expanded' === newClass ? 'sfbeforedumpexpand' : 'sfbeforedumpcollapse', true, false);
-
- s.dispatchEvent(event);
- }
-
- a.lastChild.innerHTML = arrow;
- s.className = s.className.replace(/\bsf-dump-(compact|expanded)\b/, newClass);
-
- if (recursive) {
- try {
- a = s.querySelectorAll('.'+oldClass);
- for (s = 0; s < a.length; ++s) {
- if (-1 == a[s].className.indexOf(newClass)) {
- a[s].className = newClass;
- a[s].previousSibling.lastChild.innerHTML = arrow;
- }
- }
- } catch (e) {
- }
- }
-
- return true;
-};
-
-function collapse(a, recursive) {
- var s = a.nextSibling || {}, oldClass = s.className;
-
- if (/\bsf-dump-expanded\b/.test(oldClass)) {
- toggle(a, recursive);
-
- return true;
- }
-
- return false;
-};
-
-function expand(a, recursive) {
- var s = a.nextSibling || {}, oldClass = s.className;
-
- if (/\bsf-dump-compact\b/.test(oldClass)) {
- toggle(a, recursive);
-
- return true;
- }
-
- return false;
-};
-
-function collapseAll(root) {
- var a = root.querySelector('a.sf-dump-toggle');
- if (a) {
- collapse(a, true);
- expand(a);
-
- return true;
- }
-
- return false;
-}
-
-function reveal(node) {
- var previous, parents = [];
-
- while ((node = node.parentNode || {}) && (previous = node.previousSibling) && 'A' === previous.tagName) {
- parents.push(previous);
- }
-
- if (0 !== parents.length) {
- parents.forEach(function (parent) {
- expand(parent);
- });
-
- return true;
- }
-
- return false;
-}
-
-function highlight(root, activeNode, nodes) {
- resetHighlightedNodes(root);
-
- Array.from(nodes||[]).forEach(function (node) {
- if (!/\bsf-dump-highlight\b/.test(node.className)) {
- node.className = node.className + ' sf-dump-highlight';
- }
- });
-
- if (!/\bsf-dump-highlight-active\b/.test(activeNode.className)) {
- activeNode.className = activeNode.className + ' sf-dump-highlight-active';
- }
-}
-
-function resetHighlightedNodes(root) {
- Array.from(root.querySelectorAll('.sf-dump-str, .sf-dump-key, .sf-dump-public, .sf-dump-protected, .sf-dump-private')).forEach(function (strNode) {
- strNode.className = strNode.className.replace(/\bsf-dump-highlight\b/, '');
- strNode.className = strNode.className.replace(/\bsf-dump-highlight-active\b/, '');
- });
-}
-
-return function (root, x) {
- root = doc.getElementById(root);
-
- var indentRx = new RegExp('^('+(root.getAttribute('data-indent-pad') || ' ').replace(rxEsc, '\\$1')+')+', 'm'),
- options = {$options},
- elt = root.getElementsByTagName('A'),
- len = elt.length,
- i = 0, s, h,
- t = [];
-
- while (i < len) t.push(elt[i++]);
-
- for (i in x) {
- options[i] = x[i];
- }
-
- function a(e, f) {
- addEventListener(root, e, function (e, n) {
- if ('A' == e.target.tagName) {
- f(e.target, e);
- } else if ('A' == e.target.parentNode.tagName) {
- f(e.target.parentNode, e);
- } else {
- n = /\bsf-dump-ellipsis\b/.test(e.target.className) ? e.target.parentNode : e.target;
-
- if ((n = n.nextElementSibling) && 'A' == n.tagName) {
- if (!/\bsf-dump-toggle\b/.test(n.className)) {
- n = n.nextElementSibling || n;
- }
-
- f(n, e, true);
- }
- }
- });
- };
- function isCtrlKey(e) {
- return e.ctrlKey || e.metaKey;
- }
- function xpathString(str) {
- var parts = str.match(/[^'"]+|['"]/g).map(function (part) {
- if ("'" == part) {
- return '"\'"';
- }
- if ('"' == part) {
- return "'\"'";
- }
-
- return "'" + part + "'";
- });
-
- return "concat(" + parts.join(",") + ", '')";
- }
- function xpathHasClass(className) {
- return "contains(concat(' ', normalize-space(@class), ' '), ' " + className +" ')";
- }
- addEventListener(root, 'mouseover', function (e) {
- if ('' != refStyle.innerHTML) {
- refStyle.innerHTML = '';
- }
- });
- a('mouseover', function (a, e, c) {
- if (c) {
- e.target.style.cursor = "pointer";
- } else if (a = idRx.exec(a.className)) {
- try {
- refStyle.innerHTML = 'pre.sf-dump .'+a[0]+'{background-color: #B729D9; color: #FFF !important; border-radius: 2px}';
- } catch (e) {
- }
- }
- });
- a('click', function (a, e, c) {
- if (/\bsf-dump-toggle\b/.test(a.className)) {
- e.preventDefault();
- if (!toggle(a, isCtrlKey(e))) {
- var r = doc.getElementById(a.getAttribute('href').substr(1)),
- s = r.previousSibling,
- f = r.parentNode,
- t = a.parentNode;
- t.replaceChild(r, a);
- f.replaceChild(a, s);
- t.insertBefore(s, r);
- f = f.firstChild.nodeValue.match(indentRx);
- t = t.firstChild.nodeValue.match(indentRx);
- if (f && t && f[0] !== t[0]) {
- r.innerHTML = r.innerHTML.replace(new RegExp('^'+f[0].replace(rxEsc, '\\$1'), 'mg'), t[0]);
- }
- if (/\bsf-dump-compact\b/.test(r.className)) {
- toggle(s, isCtrlKey(e));
- }
- }
-
- if (c) {
- } else if (doc.getSelection) {
- try {
- doc.getSelection().removeAllRanges();
- } catch (e) {
- doc.getSelection().empty();
- }
- } else {
- doc.selection.empty();
- }
- } else if (/\bsf-dump-str-toggle\b/.test(a.className)) {
- e.preventDefault();
- e = a.parentNode.parentNode;
- e.className = e.className.replace(/\bsf-dump-str-(expand|collapse)\b/, a.parentNode.className);
- }
- });
-
- elt = root.getElementsByTagName('SAMP');
- len = elt.length;
- i = 0;
-
- while (i < len) t.push(elt[i++]);
- len = t.length;
-
- for (i = 0; i < len; ++i) {
- elt = t[i];
- if ('SAMP' == elt.tagName) {
- a = elt.previousSibling || {};
- if ('A' != a.tagName) {
- a = doc.createElement('A');
- a.className = 'sf-dump-ref';
- elt.parentNode.insertBefore(a, elt);
- } else {
- a.innerHTML += ' ';
- }
- a.title = (a.title ? a.title+'\n[' : '[')+keyHint+'+click] Expand all children';
- a.innerHTML += elt.className == 'sf-dump-compact' ? '<span>▶</span>' : '<span>▼</span>';
- a.className += ' sf-dump-toggle';
-
- x = 1;
- if ('sf-dump' != elt.parentNode.className) {
- x += elt.parentNode.getAttribute('data-depth')/1;
- }
- } else if (/\bsf-dump-ref\b/.test(elt.className) && (a = elt.getAttribute('href'))) {
- a = a.substr(1);
- elt.className += ' '+a;
-
- if (/[\[{]$/.test(elt.previousSibling.nodeValue)) {
- a = a != elt.nextSibling.id && doc.getElementById(a);
- try {
- s = a.nextSibling;
- elt.appendChild(a);
- s.parentNode.insertBefore(a, s);
- if (/^[@#]/.test(elt.innerHTML)) {
- elt.innerHTML += ' <span>▶</span>';
- } else {
- elt.innerHTML = '<span>▶</span>';
- elt.className = 'sf-dump-ref';
- }
- elt.className += ' sf-dump-toggle';
- } catch (e) {
- if ('&' == elt.innerHTML.charAt(0)) {
- elt.innerHTML = '…';
- elt.className = 'sf-dump-ref';
- }
- }
- }
- }
- }
-
- if (doc.evaluate && Array.from && root.children.length > 1) {
- root.setAttribute('tabindex', 0);
-
- SearchState = function () {
- this.nodes = [];
- this.idx = 0;
- };
- SearchState.prototype = {
- next: function () {
- if (this.isEmpty()) {
- return this.current();
- }
- this.idx = this.idx < (this.nodes.length - 1) ? this.idx + 1 : 0;
-
- return this.current();
- },
- previous: function () {
- if (this.isEmpty()) {
- return this.current();
- }
- this.idx = this.idx > 0 ? this.idx - 1 : (this.nodes.length - 1);
-
- return this.current();
- },
- isEmpty: function () {
- return 0 === this.count();
- },
- current: function () {
- if (this.isEmpty()) {
- return null;
- }
- return this.nodes[this.idx];
- },
- reset: function () {
- this.nodes = [];
- this.idx = 0;
- },
- count: function () {
- return this.nodes.length;
- },
- };
-
- function showCurrent(state)
- {
- var currentNode = state.current(), currentRect, searchRect;
- if (currentNode) {
- reveal(currentNode);
- highlight(root, currentNode, state.nodes);
- if ('scrollIntoView' in currentNode) {
- currentNode.scrollIntoView(true);
- currentRect = currentNode.getBoundingClientRect();
- searchRect = search.getBoundingClientRect();
- if (currentRect.top < (searchRect.top + searchRect.height)) {
- window.scrollBy(0, -(searchRect.top + searchRect.height + 5));
- }
- }
- }
- counter.textContent = (state.isEmpty() ? 0 : state.idx + 1) + ' of ' + state.count();
- }
-
- var search = doc.createElement('div');
- search.className = 'sf-dump-search-wrapper sf-dump-search-hidden';
- search.innerHTML = '
- <input type="text" class="sf-dump-search-input">
- <span class="sf-dump-search-count">0 of 0<\/span>
- <button type="button" class="sf-dump-search-input-previous" tabindex="-1">
- <svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1683 1331l-166 165q-19 19-45 19t-45-19L896 965l-531 531q-19 19-45 19t-45-19l-166-165q-19-19-19-45.5t19-45.5l742-741q19-19 45-19t45 19l742 741q19 19 19 45.5t-19 45.5z"\/><\/svg>
- <\/button>
- <button type="button" class="sf-dump-search-input-next" tabindex="-1">
- <svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1683 808l-742 741q-19 19-45 19t-45-19L109 808q-19-19-19-45.5t19-45.5l166-165q19-19 45-19t45 19l531 531 531-531q19-19 45-19t45 19l166 165q19 19 19 45.5t-19 45.5z"\/><\/svg>
- <\/button>
- ';
- root.insertBefore(search, root.firstChild);
-
- var state = new SearchState();
- var searchInput = search.querySelector('.sf-dump-search-input');
- var counter = search.querySelector('.sf-dump-search-count');
- var searchInputTimer = 0;
- var previousSearchQuery = '';
-
- addEventListener(searchInput, 'keyup', function (e) {
- var searchQuery = e.target.value;
- /* Don't perform anything if the pressed key didn't change the query */
- if (searchQuery === previousSearchQuery) {
- return;
- }
- previousSearchQuery = searchQuery;
- clearTimeout(searchInputTimer);
- searchInputTimer = setTimeout(function () {
- state.reset();
- collapseAll(root);
- resetHighlightedNodes(root);
- if ('' === searchQuery) {
- counter.textContent = '0 of 0';
-
- return;
- }
-
- var classMatches = [
- "sf-dump-str",
- "sf-dump-key",
- "sf-dump-public",
- "sf-dump-protected",
- "sf-dump-private",
- ].map(xpathHasClass).join(' or ');
-
- var xpathResult = doc.evaluate('.//span[' + classMatches + '][contains(translate(child::text(), ' + xpathString(searchQuery.toUpperCase()) + ', ' + xpathString(searchQuery.toLowerCase()) + '), ' + xpathString(searchQuery.toLowerCase()) + ')]', root, null, XPathResult.ORDERED_NODE_ITERATOR_TYPE, null);
-
- while (node = xpathResult.iterateNext()) state.nodes.push(node);
-
- showCurrent(state);
- }, 400);
- });
-
- Array.from(search.querySelectorAll('.sf-dump-search-input-next, .sf-dump-search-input-previous')).forEach(function (btn) {
- addEventListener(btn, 'click', function (e) {
- e.preventDefault();
- -1 !== e.target.className.indexOf('next') ? state.next() : state.previous();
- searchInput.focus();
- collapseAll(root);
- showCurrent(state);
- })
- });
-
- addEventListener(root, 'keydown', function (e) {
- var isSearchActive = !/\bsf-dump-search-hidden\b/.test(search.className);
- if ((114 === e.keyCode && !isSearchActive) || (isCtrlKey(e) && 70 === e.keyCode)) {
- /* F3 or CMD/CTRL + F */
- if (70 === e.keyCode && document.activeElement === searchInput) {
- /*
- * If CMD/CTRL + F is hit while having focus on search input,
- * the user probably meant to trigger browser search instead.
- * Let the browser execute its behavior:
- */
- return;
- }
-
- e.preventDefault();
- search.className = search.className.replace(/\bsf-dump-search-hidden\b/, '');
- searchInput.focus();
- } else if (isSearchActive) {
- if (27 === e.keyCode) {
- /* ESC key */
- search.className += ' sf-dump-search-hidden';
- e.preventDefault();
- resetHighlightedNodes(root);
- searchInput.value = '';
- } else if (
- (isCtrlKey(e) && 71 === e.keyCode) /* CMD/CTRL + G */
- || 13 === e.keyCode /* Enter */
- || 114 === e.keyCode /* F3 */
- ) {
- e.preventDefault();
- e.shiftKey ? state.previous() : state.next();
- collapseAll(root);
- showCurrent(state);
- }
- }
- });
- }
-
- if (0 >= options.maxStringLength) {
- return;
- }
- try {
- elt = root.querySelectorAll('.sf-dump-str');
- len = elt.length;
- i = 0;
- t = [];
-
- while (i < len) t.push(elt[i++]);
- len = t.length;
-
- for (i = 0; i < len; ++i) {
- elt = t[i];
- s = elt.innerText || elt.textContent;
- x = s.length - options.maxStringLength;
- if (0 < x) {
- h = elt.innerHTML;
- elt[elt.innerText ? 'innerText' : 'textContent'] = s.substring(0, options.maxStringLength);
- elt.className += ' sf-dump-str-collapse';
- elt.innerHTML = '<span class=sf-dump-str-collapse>'+h+'<a class="sf-dump-ref sf-dump-str-toggle" title="Collapse"> ◀</a></span>'+
- '<span class=sf-dump-str-expand>'+elt.innerHTML+'<a class="sf-dump-ref sf-dump-str-toggle" title="'+x+' remaining characters"> ▶</a></span>';
- }
- }
- } catch (e) {
- }
-};
-
-})(document);
-</script><style>
-pre.sf-dump {
- display: block;
- white-space: pre;
- padding: 5px;
- overflow: initial !important;
-}
-pre.sf-dump:after {
- content: "";
- visibility: hidden;
- display: block;
- height: 0;
- clear: both;
-}
-pre.sf-dump span {
- display: inline;
-}
-pre.sf-dump a {
- text-decoration: none;
- cursor: pointer;
- border: 0;
- outline: none;
- color: inherit;
-}
-pre.sf-dump img {
- max-width: 50em;
- max-height: 50em;
- margin: .5em 0 0 0;
- padding: 0;
- background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAHUlEQVQY02O8zAABilCaiQEN0EeA8QuUcX9g3QEAAjcC5piyhyEAAAAASUVORK5CYII=) #D3D3D3;
-}
-pre.sf-dump .sf-dump-ellipsis {
- display: inline-block;
- overflow: visible;
- text-overflow: ellipsis;
- max-width: 5em;
- white-space: nowrap;
- overflow: hidden;
- vertical-align: top;
-}
-pre.sf-dump .sf-dump-ellipsis+.sf-dump-ellipsis {
- max-width: none;
-}
-pre.sf-dump code {
- display:inline;
- padding:0;
- background:none;
-}
-.sf-dump-public.sf-dump-highlight,
-.sf-dump-protected.sf-dump-highlight,
-.sf-dump-private.sf-dump-highlight,
-.sf-dump-str.sf-dump-highlight,
-.sf-dump-key.sf-dump-highlight {
- background: rgba(111, 172, 204, 0.3);
- border: 1px solid #7DA0B1;
- border-radius: 3px;
-}
-.sf-dump-public.sf-dump-highlight-active,
-.sf-dump-protected.sf-dump-highlight-active,
-.sf-dump-private.sf-dump-highlight-active,
-.sf-dump-str.sf-dump-highlight-active,
-.sf-dump-key.sf-dump-highlight-active {
- background: rgba(253, 175, 0, 0.4);
- border: 1px solid #ffa500;
- border-radius: 3px;
-}
-pre.sf-dump .sf-dump-search-hidden {
- display: none !important;
-}
-pre.sf-dump .sf-dump-search-wrapper {
- font-size: 0;
- white-space: nowrap;
- margin-bottom: 5px;
- display: flex;
- position: -webkit-sticky;
- position: sticky;
- top: 5px;
-}
-pre.sf-dump .sf-dump-search-wrapper > * {
- vertical-align: top;
- box-sizing: border-box;
- height: 21px;
- font-weight: normal;
- border-radius: 0;
- background: #FFF;
- color: #757575;
- border: 1px solid #BBB;
-}
-pre.sf-dump .sf-dump-search-wrapper > input.sf-dump-search-input {
- padding: 3px;
- height: 21px;
- font-size: 12px;
- border-right: none;
- border-top-left-radius: 3px;
- border-bottom-left-radius: 3px;
- color: #000;
- min-width: 15px;
- width: 100%;
-}
-pre.sf-dump .sf-dump-search-wrapper > .sf-dump-search-input-next,
-pre.sf-dump .sf-dump-search-wrapper > .sf-dump-search-input-previous {
- background: #F2F2F2;
- outline: none;
- border-left: none;
- font-size: 0;
- line-height: 0;
-}
-pre.sf-dump .sf-dump-search-wrapper > .sf-dump-search-input-next {
- border-top-right-radius: 3px;
- border-bottom-right-radius: 3px;
-}
-pre.sf-dump .sf-dump-search-wrapper > .sf-dump-search-input-next > svg,
-pre.sf-dump .sf-dump-search-wrapper > .sf-dump-search-input-previous > svg {
- pointer-events: none;
- width: 12px;
- height: 12px;
-}
-pre.sf-dump .sf-dump-search-wrapper > .sf-dump-search-count {
- display: inline-block;
- padding: 0 5px;
- margin: 0;
- border-left: none;
- line-height: 21px;
- font-size: 12px;
-}
-EOHTML
- );
-
- foreach ($this->styles as $class => $style) {
- $line .= 'pre.sf-dump'.('default' === $class ? ', pre.sf-dump' : '').' .sf-dump-'.$class.'{'.$style.'}';
- }
- $line .= 'pre.sf-dump .sf-dump-ellipsis-note{'.$this->styles['note'].'}';
-
- return $this->dumpHeader = preg_replace('/\s+/', ' ', $line).'</style>'.$this->dumpHeader;
- }
-
- /**
- * {@inheritdoc}
- */
- public function dumpString(Cursor $cursor, string $str, bool $bin, int $cut)
- {
- if ('' === $str && isset($cursor->attr['img-data'], $cursor->attr['content-type'])) {
- $this->dumpKey($cursor);
- $this->line .= $this->style('default', $cursor->attr['img-size'] ?? '', []);
- $this->line .= $cursor->depth >= $this->displayOptions['maxDepth'] ? ' <samp class=sf-dump-compact>' : ' <samp class=sf-dump-expanded>';
- $this->endValue($cursor);
- $this->line .= $this->indentPad;
- $this->line .= sprintf('<img src="data:%s;base64,%s" /></samp>', $cursor->attr['content-type'], base64_encode($cursor->attr['img-data']));
- $this->endValue($cursor);
- } else {
- parent::dumpString($cursor, $str, $bin, $cut);
- }
- }
-
- /**
- * {@inheritdoc}
- */
- public function enterHash(Cursor $cursor, int $type, string|int|null $class, bool $hasChild)
- {
- if (Cursor::HASH_OBJECT === $type) {
- $cursor->attr['depth'] = $cursor->depth;
- }
- parent::enterHash($cursor, $type, $class, false);
-
- if ($cursor->skipChildren || $cursor->depth >= $this->displayOptions['maxDepth']) {
- $cursor->skipChildren = false;
- $eol = ' class=sf-dump-compact>';
- } else {
- $this->expandNextHash = false;
- $eol = ' class=sf-dump-expanded>';
- }
-
- if ($hasChild) {
- $this->line .= '<samp data-depth='.($cursor->depth + 1);
- if ($cursor->refIndex) {
- $r = Cursor::HASH_OBJECT !== $type ? 1 - (Cursor::HASH_RESOURCE !== $type) : 2;
- $r .= $r && 0 < $cursor->softRefHandle ? $cursor->softRefHandle : $cursor->refIndex;
-
- $this->line .= sprintf(' id=%s-ref%s', $this->dumpId, $r);
- }
- $this->line .= $eol;
- $this->dumpLine($cursor->depth);
- }
- }
-
- /**
- * {@inheritdoc}
- */
- public function leaveHash(Cursor $cursor, int $type, string|int|null $class, bool $hasChild, int $cut)
- {
- $this->dumpEllipsis($cursor, $hasChild, $cut);
- if ($hasChild) {
- $this->line .= '</samp>';
- }
- parent::leaveHash($cursor, $type, $class, $hasChild, 0);
- }
-
- /**
- * {@inheritdoc}
- */
- protected function style(string $style, string $value, array $attr = []): string
- {
- if ('' === $value) {
- return '';
- }
-
- $v = esc($value);
-
- if ('ref' === $style) {
- if (empty($attr['count'])) {
- return sprintf('<a class=sf-dump-ref>%s</a>', $v);
- }
- $r = ('#' !== $v[0] ? 1 - ('@' !== $v[0]) : 2).substr($value, 1);
-
- return sprintf('<a class=sf-dump-ref href=#%s-ref%s title="%d occurrences">%s</a>', $this->dumpId, $r, 1 + $attr['count'], $v);
- }
-
- if ('const' === $style && isset($attr['value'])) {
- $style .= sprintf(' title="%s"', esc(is_scalar($attr['value']) ? $attr['value'] : json_encode($attr['value'])));
- } elseif ('public' === $style) {
- $style .= sprintf(' title="%s"', empty($attr['dynamic']) ? 'Public property' : 'Runtime added dynamic property');
- } elseif ('str' === $style && 1 < $attr['length']) {
- $style .= sprintf(' title="%d%s characters"', $attr['length'], $attr['binary'] ? ' binary or non-UTF-8' : '');
- } elseif ('note' === $style && 0 < ($attr['depth'] ?? 0) && false !== $c = strrpos($value, '\\')) {
- $style .= ' title=""';
- $attr += [
- 'ellipsis' => \strlen($value) - $c,
- 'ellipsis-type' => 'note',
- 'ellipsis-tail' => 1,
- ];
- } elseif ('protected' === $style) {
- $style .= ' title="Protected property"';
- } elseif ('meta' === $style && isset($attr['title'])) {
- $style .= sprintf(' title="%s"', esc($this->utf8Encode($attr['title'])));
- } elseif ('private' === $style) {
- $style .= sprintf(' title="Private property defined in class: `%s`"', esc($this->utf8Encode($attr['class'])));
- }
- $map = static::$controlCharsMap;
-
- if (isset($attr['ellipsis'])) {
- $class = 'sf-dump-ellipsis';
- if (isset($attr['ellipsis-type'])) {
- $class = sprintf('"%s sf-dump-ellipsis-%s"', $class, $attr['ellipsis-type']);
- }
- $label = esc(substr($value, -$attr['ellipsis']));
- $style = str_replace(' title="', " title=\"$v\n", $style);
- $v = sprintf('<span class=%s>%s</span>', $class, substr($v, 0, -\strlen($label)));
-
- if (!empty($attr['ellipsis-tail'])) {
- $tail = \strlen(esc(substr($value, -$attr['ellipsis'], $attr['ellipsis-tail'])));
- $v .= sprintf('<span class=%s>%s</span>%s', $class, substr($label, 0, $tail), substr($label, $tail));
- } else {
- $v .= $label;
- }
- }
-
- $v = "<span class=sf-dump-{$style}>".preg_replace_callback(static::$controlCharsRx, function ($c) use ($map) {
- $s = $b = '<span class="sf-dump-default';
- $c = $c[$i = 0];
- if ($ns = "\r" === $c[$i] || "\n" === $c[$i]) {
- $s .= ' sf-dump-ns';
- }
- $s .= '">';
- do {
- if (("\r" === $c[$i] || "\n" === $c[$i]) !== $ns) {
- $s .= '</span>'.$b;
- if ($ns = !$ns) {
- $s .= ' sf-dump-ns';
- }
- $s .= '">';
- }
-
- $s .= $map[$c[$i]] ?? sprintf('\x%02X', \ord($c[$i]));
- } while (isset($c[++$i]));
-
- return $s.'</span>';
- }, $v).'</span>';
-
- if (isset($attr['file']) && $href = $this->getSourceLink($attr['file'], $attr['line'] ?? 0)) {
- $attr['href'] = $href;
- }
- if (isset($attr['href'])) {
- $target = isset($attr['file']) ? '' : ' target="_blank"';
- $v = sprintf('<a href="%s"%s rel="noopener noreferrer">%s</a>', esc($this->utf8Encode($attr['href'])), $target, $v);
- }
- if (isset($attr['lang'])) {
- $v = sprintf('<code class="%s">%s</code>', esc($attr['lang']), $v);
- }
-
- return $v;
- }
-
- /**
- * {@inheritdoc}
- */
- protected function dumpLine(int $depth, bool $endOfValue = false)
- {
- if (-1 === $this->lastDepth) {
- $this->line = sprintf($this->dumpPrefix, $this->dumpId, $this->indentPad).$this->line;
- }
- if ($this->headerIsDumped !== ($this->outputStream ?? $this->lineDumper)) {
- $this->line = $this->getDumpHeader().$this->line;
- }
-
- if (-1 === $depth) {
- $args = ['"'.$this->dumpId.'"'];
- if ($this->extraDisplayOptions) {
- $args[] = json_encode($this->extraDisplayOptions, \JSON_FORCE_OBJECT);
- }
- // Replace is for BC
- $this->line .= sprintf(str_replace('"%s"', '%s', $this->dumpSuffix), implode(', ', $args));
- }
- $this->lastDepth = $depth;
-
- $this->line = mb_convert_encoding($this->line, 'HTML-ENTITIES', 'UTF-8');
-
- if (-1 === $depth) {
- AbstractDumper::dumpLine(0);
- }
- AbstractDumper::dumpLine($depth);
- }
-
- private function getSourceLink(string $file, int $line)
- {
- $options = $this->extraDisplayOptions + $this->displayOptions;
-
- if ($fmt = $options['fileLinkFormat']) {
- return \is_string($fmt) ? strtr($fmt, ['%f' => $file, '%l' => $line]) : $fmt->format($file, $line);
- }
-
- return false;
- }
-}
-
-function esc(string $str)
-{
- return htmlspecialchars($str, \ENT_QUOTES, 'UTF-8');
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ServerDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ServerDumper.php
deleted file mode 100644
index 94795bf..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Dumper/ServerDumper.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?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\Component\VarDumper\Dumper;
-
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Dumper\ContextProvider\ContextProviderInterface;
-use Symfony\Component\VarDumper\Server\Connection;
-
-/**
- * ServerDumper forwards serialized Data clones to a server.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-class ServerDumper implements DataDumperInterface
-{
- private $connection;
- private $wrappedDumper;
-
- /**
- * @param string $host The server host
- * @param DataDumperInterface|null $wrappedDumper A wrapped instance used whenever we failed contacting the server
- * @param ContextProviderInterface[] $contextProviders Context providers indexed by context name
- */
- public function __construct(string $host, DataDumperInterface $wrappedDumper = null, array $contextProviders = [])
- {
- $this->connection = new Connection($host, $contextProviders);
- $this->wrappedDumper = $wrappedDumper;
- }
-
- public function getContextProviders(): array
- {
- return $this->connection->getContextProviders();
- }
-
- /**
- * {@inheritdoc}
- */
- public function dump(Data $data)
- {
- if (!$this->connection->write($data) && $this->wrappedDumper) {
- $this->wrappedDumper->dump($data);
- }
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Exception/ThrowingCasterException.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Exception/ThrowingCasterException.php
deleted file mode 100644
index 122f0d3..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Exception/ThrowingCasterException.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?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\Component\VarDumper\Exception;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class ThrowingCasterException extends \Exception
-{
- /**
- * @param \Throwable $prev The exception thrown from the caster
- */
- public function __construct(\Throwable $prev)
- {
- parent::__construct('Unexpected '.\get_class($prev).' thrown from a caster: '.$prev->getMessage(), 0, $prev);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/LICENSE b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/LICENSE
deleted file mode 100644
index a843ec1..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/LICENSE
+++ /dev/null
@@ -1,19 +0,0 @@
-Copyright (c) 2014-2022 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/var-dumper/README.md b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/README.md
deleted file mode 100644
index a0da8c9..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/README.md
+++ /dev/null
@@ -1,15 +0,0 @@
-VarDumper Component
-===================
-
-The VarDumper component provides mechanisms for walking through any arbitrary
-PHP variable. It provides a better `dump()` function that you can use instead
-of `var_dump()`.
-
-Resources
----------
-
- * [Documentation](https://symfony.com/doc/current/components/var_dumper/introduction.html)
- * [Contributing](https://symfony.com/doc/current/contributing/index.html)
- * [Report issues](https://github.com/symfony/symfony/issues) and
- [send Pull Requests](https://github.com/symfony/symfony/pulls)
- in the [main Symfony repository](https://github.com/symfony/symfony)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/bin/var-dump-server b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/bin/var-dump-server
deleted file mode 100755
index 98c813a..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/bin/var-dump-server
+++ /dev/null
@@ -1,63 +0,0 @@
-#!/usr/bin/env php
-<?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.
- */
-
-/**
- * Starts a dump server to collect and output dumps on a single place with multiple formats support.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-
-use Psr\Log\LoggerInterface;
-use Symfony\Component\Console\Application;
-use Symfony\Component\Console\Input\ArgvInput;
-use Symfony\Component\Console\Input\InputOption;
-use Symfony\Component\Console\Logger\ConsoleLogger;
-use Symfony\Component\Console\Output\ConsoleOutput;
-use Symfony\Component\VarDumper\Command\ServerDumpCommand;
-use Symfony\Component\VarDumper\Server\DumpServer;
-
-function includeIfExists(string $file): bool
-{
- return file_exists($file) && include $file;
-}
-
-if (
- !includeIfExists(__DIR__ . '/../../../../autoload.php') &&
- !includeIfExists(__DIR__ . '/../../vendor/autoload.php') &&
- !includeIfExists(__DIR__ . '/../../../../../../vendor/autoload.php')
-) {
- fwrite(STDERR, 'Install dependencies using Composer.'.PHP_EOL);
- exit(1);
-}
-
-if (!class_exists(Application::class)) {
- fwrite(STDERR, 'You need the "symfony/console" component in order to run the VarDumper server.'.PHP_EOL);
- exit(1);
-}
-
-$input = new ArgvInput();
-$output = new ConsoleOutput();
-$defaultHost = '127.0.0.1:9912';
-$host = $input->getParameterOption(['--host'], $_SERVER['VAR_DUMPER_SERVER'] ?? $defaultHost, true);
-$logger = interface_exists(LoggerInterface::class) ? new ConsoleLogger($output->getErrorOutput()) : null;
-
-$app = new Application();
-
-$app->getDefinition()->addOption(
- new InputOption('--host', null, InputOption::VALUE_REQUIRED, 'The address the server should listen to', $defaultHost)
-);
-
-$app->add($command = new ServerDumpCommand(new DumpServer($host, $logger)))
- ->getApplication()
- ->setDefaultCommand($command->getName(), true)
- ->run($input, $output)
-;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/css/htmlDescriptor.css b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/css/htmlDescriptor.css
deleted file mode 100644
index 8f706d6..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/css/htmlDescriptor.css
+++ /dev/null
@@ -1,130 +0,0 @@
-body {
- display: flex;
- flex-direction: column-reverse;
- justify-content: flex-end;
- max-width: 1140px;
- margin: auto;
- padding: 15px;
- word-wrap: break-word;
- background-color: #F9F9F9;
- color: #222;
- font-family: Helvetica, Arial, sans-serif;
- font-size: 14px;
- line-height: 1.4;
-}
-p {
- margin: 0;
-}
-a {
- color: #218BC3;
- text-decoration: none;
-}
-a:hover {
- text-decoration: underline;
-}
-.text-small {
- font-size: 12px !important;
-}
-article {
- margin: 5px;
- margin-bottom: 10px;
-}
-article > header > .row {
- display: flex;
- flex-direction: row;
- align-items: baseline;
- margin-bottom: 10px;
-}
-article > header > .row > .col {
- flex: 1;
- display: flex;
- align-items: baseline;
-}
-article > header > .row > h2 {
- font-size: 14px;
- color: #222;
- font-weight: normal;
- font-family: "Lucida Console", monospace, sans-serif;
- word-break: break-all;
- margin: 20px 5px 0 0;
- user-select: all;
-}
-article > header > .row > h2 > code {
- white-space: nowrap;
- user-select: none;
- color: #cc2255;
- background-color: #f7f7f9;
- border: 1px solid #e1e1e8;
- border-radius: 3px;
- margin-right: 5px;
- padding: 0 3px;
-}
-article > header > .row > time.col {
- flex: 0;
- text-align: right;
- white-space: nowrap;
- color: #999;
- font-style: italic;
-}
-article > header ul.tags {
- list-style: none;
- padding: 0;
- margin: 0;
- font-size: 12px;
-}
-article > header ul.tags > li {
- user-select: all;
- margin-bottom: 2px;
-}
-article > header ul.tags > li > span.badge {
- display: inline-block;
- padding: .25em .4em;
- margin-right: 5px;
- border-radius: 4px;
- background-color: #6c757d3b;
- color: #524d4d;
- font-size: 12px;
- text-align: center;
- font-weight: 700;
- line-height: 1;
- white-space: nowrap;
- vertical-align: baseline;
- user-select: none;
-}
-article > section.body {
- border: 1px solid #d8d8d8;
- background: #FFF;
- padding: 10px;
- border-radius: 3px;
-}
-pre.sf-dump {
- border-radius: 3px;
- margin-bottom: 0;
-}
-.hidden {
- display: none !important;
-}
-.dumped-tag > .sf-dump {
- display: inline-block;
- margin: 0;
- padding: 1px 5px;
- line-height: 1.4;
- vertical-align: top;
- background-color: transparent;
- user-select: auto;
-}
-.dumped-tag > pre.sf-dump,
-.dumped-tag > .sf-dump-default {
- color: #CC7832;
- background: none;
-}
-.dumped-tag > .sf-dump .sf-dump-str { color: #629755; }
-.dumped-tag > .sf-dump .sf-dump-private,
-.dumped-tag > .sf-dump .sf-dump-protected,
-.dumped-tag > .sf-dump .sf-dump-public { color: #262626; }
-.dumped-tag > .sf-dump .sf-dump-note { color: #6897BB; }
-.dumped-tag > .sf-dump .sf-dump-key { color: #789339; }
-.dumped-tag > .sf-dump .sf-dump-ref { color: #6E6E6E; }
-.dumped-tag > .sf-dump .sf-dump-ellipsis { color: #CC7832; max-width: 100em; }
-.dumped-tag > .sf-dump .sf-dump-ellipsis-path { max-width: 5em; }
-.dumped-tag > .sf-dump .sf-dump-ns { user-select: none; }
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/functions/dump.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/functions/dump.php
deleted file mode 100644
index 6221a4d..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/functions/dump.php
+++ /dev/null
@@ -1,50 +0,0 @@
-<?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\Component\VarDumper\VarDumper;
-
-if (!function_exists('dump')) {
- /**
- * @author Nicolas Grekas <p@tchwork.com>
- */
- function dump(mixed $var, mixed ...$moreVars): mixed
- {
- VarDumper::dump($var);
-
- foreach ($moreVars as $v) {
- VarDumper::dump($v);
- }
-
- if (1 < func_num_args()) {
- return func_get_args();
- }
-
- return $var;
- }
-}
-
-if (!function_exists('dd')) {
- /**
- * @return never
- */
- function dd(...$vars): void
- {
- if (!in_array(\PHP_SAPI, ['cli', 'phpdbg'], true) && !headers_sent()) {
- header('HTTP/1.1 500 Internal Server Error');
- }
-
- foreach ($vars as $v) {
- VarDumper::dump($v);
- }
-
- exit(1);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/js/htmlDescriptor.js b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/js/htmlDescriptor.js
deleted file mode 100644
index 63101e5..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Resources/js/htmlDescriptor.js
+++ /dev/null
@@ -1,10 +0,0 @@
-document.addEventListener('DOMContentLoaded', function() {
- let prev = null;
- Array.from(document.getElementsByTagName('article')).reverse().forEach(function (article) {
- const dedupId = article.dataset.dedupId;
- if (dedupId === prev) {
- article.getElementsByTagName('header')[0].classList.add('hidden');
- }
- prev = dedupId;
- });
-});
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Server/Connection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Server/Connection.php
deleted file mode 100644
index 97b5b94..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Server/Connection.php
+++ /dev/null
@@ -1,99 +0,0 @@
-<?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\Component\VarDumper\Server;
-
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Dumper\ContextProvider\ContextProviderInterface;
-
-/**
- * Forwards serialized Data clones to a server.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- */
-class Connection
-{
- private string $host;
- private array $contextProviders;
-
- /**
- * @var resource|null
- */
- private $socket;
-
- /**
- * @param string $host The server host
- * @param ContextProviderInterface[] $contextProviders Context providers indexed by context name
- */
- public function __construct(string $host, array $contextProviders = [])
- {
- if (!str_contains($host, '://')) {
- $host = 'tcp://'.$host;
- }
-
- $this->host = $host;
- $this->contextProviders = $contextProviders;
- }
-
- public function getContextProviders(): array
- {
- return $this->contextProviders;
- }
-
- public function write(Data $data): bool
- {
- $socketIsFresh = !$this->socket;
- if (!$this->socket = $this->socket ?: $this->createSocket()) {
- return false;
- }
-
- $context = ['timestamp' => microtime(true)];
- foreach ($this->contextProviders as $name => $provider) {
- $context[$name] = $provider->getContext();
- }
- $context = array_filter($context);
- $encodedPayload = base64_encode(serialize([$data, $context]))."\n";
-
- set_error_handler([self::class, 'nullErrorHandler']);
- try {
- if (-1 !== stream_socket_sendto($this->socket, $encodedPayload)) {
- return true;
- }
- if (!$socketIsFresh) {
- stream_socket_shutdown($this->socket, \STREAM_SHUT_RDWR);
- fclose($this->socket);
- $this->socket = $this->createSocket();
- }
- if (-1 !== stream_socket_sendto($this->socket, $encodedPayload)) {
- return true;
- }
- } finally {
- restore_error_handler();
- }
-
- return false;
- }
-
- private static function nullErrorHandler(int $t, string $m)
- {
- // no-op
- }
-
- private function createSocket()
- {
- set_error_handler([self::class, 'nullErrorHandler']);
- try {
- return stream_socket_client($this->host, $errno, $errstr, 3, \STREAM_CLIENT_CONNECT | \STREAM_CLIENT_ASYNC_CONNECT);
- } finally {
- restore_error_handler();
- }
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Server/DumpServer.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Server/DumpServer.php
deleted file mode 100644
index 6a43c12..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Server/DumpServer.php
+++ /dev/null
@@ -1,115 +0,0 @@
-<?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\Component\VarDumper\Server;
-
-use Psr\Log\LoggerInterface;
-use Symfony\Component\VarDumper\Cloner\Data;
-use Symfony\Component\VarDumper\Cloner\Stub;
-
-/**
- * A server collecting Data clones sent by a ServerDumper.
- *
- * @author Maxime Steinhausser <maxime.steinhausser@gmail.com>
- *
- * @final
- */
-class DumpServer
-{
- private string $host;
- private $logger;
-
- /**
- * @var resource|null
- */
- private $socket;
-
- public function __construct(string $host, LoggerInterface $logger = null)
- {
- if (!str_contains($host, '://')) {
- $host = 'tcp://'.$host;
- }
-
- $this->host = $host;
- $this->logger = $logger;
- }
-
- public function start(): void
- {
- if (!$this->socket = stream_socket_server($this->host, $errno, $errstr)) {
- throw new \RuntimeException(sprintf('Server start failed on "%s": ', $this->host).$errstr.' '.$errno);
- }
- }
-
- public function listen(callable $callback): void
- {
- if (null === $this->socket) {
- $this->start();
- }
-
- foreach ($this->getMessages() as $clientId => $message) {
- if ($this->logger) {
- $this->logger->info('Received a payload from client {clientId}', ['clientId' => $clientId]);
- }
-
- $payload = @unserialize(base64_decode($message), ['allowed_classes' => [Data::class, Stub::class]]);
-
- // Impossible to decode the message, give up.
- if (false === $payload) {
- if ($this->logger) {
- $this->logger->warning('Unable to decode a message from {clientId} client.', ['clientId' => $clientId]);
- }
-
- continue;
- }
-
- if (!\is_array($payload) || \count($payload) < 2 || !$payload[0] instanceof Data || !\is_array($payload[1])) {
- if ($this->logger) {
- $this->logger->warning('Invalid payload from {clientId} client. Expected an array of two elements (Data $data, array $context)', ['clientId' => $clientId]);
- }
-
- continue;
- }
-
- [$data, $context] = $payload;
-
- $callback($data, $context, $clientId);
- }
- }
-
- public function getHost(): string
- {
- return $this->host;
- }
-
- private function getMessages(): iterable
- {
- $sockets = [(int) $this->socket => $this->socket];
- $write = [];
-
- while (true) {
- $read = $sockets;
- stream_select($read, $write, $write, null);
-
- foreach ($read as $stream) {
- if ($this->socket === $stream) {
- $stream = stream_socket_accept($this->socket);
- $sockets[(int) $stream] = $stream;
- } elseif (feof($stream)) {
- unset($sockets[(int) $stream]);
- fclose($stream);
- } else {
- yield (int) $stream => fgets($stream);
- }
- }
- }
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Test/VarDumperTestTrait.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Test/VarDumperTestTrait.php
deleted file mode 100644
index a202185..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/Test/VarDumperTestTrait.php
+++ /dev/null
@@ -1,84 +0,0 @@
-<?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\Component\VarDumper\Test;
-
-use Symfony\Component\VarDumper\Cloner\VarCloner;
-use Symfony\Component\VarDumper\Dumper\CliDumper;
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- */
-trait VarDumperTestTrait
-{
- /**
- * @internal
- */
- private array $varDumperConfig = [
- 'casters' => [],
- 'flags' => null,
- ];
-
- protected function setUpVarDumper(array $casters, int $flags = null): void
- {
- $this->varDumperConfig['casters'] = $casters;
- $this->varDumperConfig['flags'] = $flags;
- }
-
- /**
- * @after
- */
- protected function tearDownVarDumper(): void
- {
- $this->varDumperConfig['casters'] = [];
- $this->varDumperConfig['flags'] = null;
- }
-
- public function assertDumpEquals(mixed $expected, mixed $data, int $filter = 0, string $message = '')
- {
- $this->assertSame($this->prepareExpectation($expected, $filter), $this->getDump($data, null, $filter), $message);
- }
-
- public function assertDumpMatchesFormat(mixed $expected, mixed $data, int $filter = 0, string $message = '')
- {
- $this->assertStringMatchesFormat($this->prepareExpectation($expected, $filter), $this->getDump($data, null, $filter), $message);
- }
-
- protected function getDump(mixed $data, string|int $key = null, int $filter = 0): ?string
- {
- if (null === $flags = $this->varDumperConfig['flags']) {
- $flags = getenv('DUMP_LIGHT_ARRAY') ? CliDumper::DUMP_LIGHT_ARRAY : 0;
- $flags |= getenv('DUMP_STRING_LENGTH') ? CliDumper::DUMP_STRING_LENGTH : 0;
- $flags |= getenv('DUMP_COMMA_SEPARATOR') ? CliDumper::DUMP_COMMA_SEPARATOR : 0;
- }
-
- $cloner = new VarCloner();
- $cloner->addCasters($this->varDumperConfig['casters']);
- $cloner->setMaxItems(-1);
- $dumper = new CliDumper(null, null, $flags);
- $dumper->setColors(false);
- $data = $cloner->cloneVar($data, $filter)->withRefHandles(false);
- if (null !== $key && null === $data = $data->seek($key)) {
- return null;
- }
-
- return rtrim($dumper->dump($data, true));
- }
-
- private function prepareExpectation(mixed $expected, int $filter): string
- {
- if (!\is_string($expected)) {
- $expected = $this->getDump($expected, null, $filter);
- }
-
- return rtrim($expected);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/VarDumper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/VarDumper.php
deleted file mode 100644
index dfef9f4..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/VarDumper.php
+++ /dev/null
@@ -1,112 +0,0 @@
-<?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\Component\VarDumper;
-
-use Symfony\Component\HttpFoundation\Request;
-use Symfony\Component\HttpFoundation\RequestStack;
-use Symfony\Component\HttpKernel\Debug\FileLinkFormatter;
-use Symfony\Component\VarDumper\Caster\ReflectionCaster;
-use Symfony\Component\VarDumper\Cloner\VarCloner;
-use Symfony\Component\VarDumper\Dumper\CliDumper;
-use Symfony\Component\VarDumper\Dumper\ContextProvider\CliContextProvider;
-use Symfony\Component\VarDumper\Dumper\ContextProvider\RequestContextProvider;
-use Symfony\Component\VarDumper\Dumper\ContextProvider\SourceContextProvider;
-use Symfony\Component\VarDumper\Dumper\ContextualizedDumper;
-use Symfony\Component\VarDumper\Dumper\HtmlDumper;
-use Symfony\Component\VarDumper\Dumper\ServerDumper;
-
-// Load the global dump() function
-require_once __DIR__.'/Resources/functions/dump.php';
-
-/**
- * @author Nicolas Grekas <p@tchwork.com>
- */
-class VarDumper
-{
- /**
- * @var callable|null
- */
- private static $handler;
-
- public static function dump(mixed $var)
- {
- if (null === self::$handler) {
- self::register();
- }
-
- return (self::$handler)($var);
- }
-
- public static function setHandler(callable $callable = null): ?callable
- {
- $prevHandler = self::$handler;
-
- // Prevent replacing the handler with expected format as soon as the env var was set:
- if (isset($_SERVER['VAR_DUMPER_FORMAT'])) {
- return $prevHandler;
- }
-
- self::$handler = $callable;
-
- return $prevHandler;
- }
-
- private static function register(): void
- {
- $cloner = new VarCloner();
- $cloner->addCasters(ReflectionCaster::UNSET_CLOSURE_FILE_INFO);
-
- $format = $_SERVER['VAR_DUMPER_FORMAT'] ?? null;
- switch (true) {
- case 'html' === $format:
- $dumper = new HtmlDumper();
- break;
- case 'cli' === $format:
- $dumper = new CliDumper();
- break;
- case 'server' === $format:
- case $format && 'tcp' === parse_url($format, \PHP_URL_SCHEME):
- $host = 'server' === $format ? $_SERVER['VAR_DUMPER_SERVER'] ?? '127.0.0.1:9912' : $format;
- $dumper = \in_array(\PHP_SAPI, ['cli', 'phpdbg'], true) ? new CliDumper() : new HtmlDumper();
- $dumper = new ServerDumper($host, $dumper, self::getDefaultContextProviders());
- break;
- default:
- $dumper = \in_array(\PHP_SAPI, ['cli', 'phpdbg'], true) ? new CliDumper() : new HtmlDumper();
- }
-
- if (!$dumper instanceof ServerDumper) {
- $dumper = new ContextualizedDumper($dumper, [new SourceContextProvider()]);
- }
-
- self::$handler = function ($var) use ($cloner, $dumper) {
- $dumper->dump($cloner->cloneVar($var));
- };
- }
-
- private static function getDefaultContextProviders(): array
- {
- $contextProviders = [];
-
- if (!\in_array(\PHP_SAPI, ['cli', 'phpdbg'], true) && (class_exists(Request::class))) {
- $requestStack = new RequestStack();
- $requestStack->push(Request::createFromGlobals());
- $contextProviders['request'] = new RequestContextProvider($requestStack);
- }
-
- $fileLinkFormatter = class_exists(FileLinkFormatter::class) ? new FileLinkFormatter(null, $requestStack ?? null) : null;
-
- return $contextProviders + [
- 'cli' => new CliContextProvider(),
- 'source' => new SourceContextProvider(null, null, $fileLinkFormatter),
- ];
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/composer.json
deleted file mode 100644
index db04f58..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/symfony/var-dumper/composer.json
+++ /dev/null
@@ -1,49 +0,0 @@
-{
- "name": "symfony/var-dumper",
- "type": "library",
- "description": "Provides mechanisms for walking through any arbitrary PHP variable",
- "keywords": ["dump", "debug"],
- "homepage": "https://symfony.com",
- "license": "MIT",
- "authors": [
- {
- "name": "Nicolas Grekas",
- "email": "p@tchwork.com"
- },
- {
- "name": "Symfony Community",
- "homepage": "https://symfony.com/contributors"
- }
- ],
- "require": {
- "php": ">=8.0.2",
- "symfony/polyfill-mbstring": "~1.0"
- },
- "require-dev": {
- "ext-iconv": "*",
- "symfony/console": "^5.4|^6.0",
- "symfony/process": "^5.4|^6.0",
- "symfony/uid": "^5.4|^6.0",
- "twig/twig": "^2.13|^3.0.4"
- },
- "conflict": {
- "phpunit/phpunit": "<5.4.3",
- "symfony/console": "<5.4"
- },
- "suggest": {
- "ext-iconv": "To convert non-UTF-8 strings to UTF-8 (or symfony/polyfill-iconv in case ext-iconv cannot be used).",
- "ext-intl": "To show region name in time zone dump",
- "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script"
- },
- "autoload": {
- "files": [ "Resources/functions/dump.php" ],
- "psr-4": { "Symfony\\Component\\VarDumper\\": "" },
- "exclude-from-classmap": [
- "/Tests/"
- ]
- },
- "bin": [
- "Resources/bin/var-dump-server"
- ],
- "minimum-stability": "dev"
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/.github/workflows/run-tests.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/.github/workflows/run-tests.yml
deleted file mode 100644
index c932521..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/.github/workflows/run-tests.yml
+++ /dev/null
@@ -1,41 +0,0 @@
-name: Run tests
-
-on:
- push:
- branches: [laravel-9-ongoing, laravel-8-ongoing]
- pull_request:
-
-jobs:
- tests:
- strategy:
- matrix:
- os: [Ubuntu, macOS]
- php: [7.3, 7.4, 8.0, 8.1]
-
- include:
- - os: Ubuntu
- os-version: ubuntu-latest
-
- - os: macOS
- os-version: macos-latest
-
- name: ${{ matrix.os }} - PHP ${{ matrix.php }}
-
- runs-on: ${{ matrix.os-version }}
-
- steps:
- - name: Checkout code
- uses: actions/checkout@v4
-
- - name: Setup PHP
- uses: shivammathur/setup-php@v2
- with:
- php-version: ${{ matrix.php }}
- extensions: posix, dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick
- coverage: none
-
- - name: Install dependencies
- run: composer update --prefer-stable --prefer-dist --no-interaction
-
- - name: Run tests
- run: bash upgrade.sh
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/branch-commit-push.sh b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/branch-commit-push.sh
deleted file mode 100755
index 124e583..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/branch-commit-push.sh
+++ /dev/null
@@ -1,67 +0,0 @@
-#!/bin/bash
-
-
-GREEN='\033[0;32m'
-RED='\033[0;31m'
-WHITE='\033[0;37m'
-RESET='\033[0m'
-
-function validateVersion()
-{
- echo ""
- passedVersion=$1
- echo -e "${WHITE}-- Validating tag '$passedVersion'...${RESET}"
-
- # Todo: validate the version here using a regex; if fail, just exit
- # ... expect 8.75.0, with no v in front of it
-
- if [[ $passedVersion == '' ]]; then
- echo -e "\n-- Invalid tag. Tags should be structured without v; e.g. 8.57.0"
- exit
- fi
-
- echo -e "${WHITE}-- Tag valid.${RESET}"
- echo ""
-}
-
-# Exit script if any command fails (e.g. phpunit)
-set -e
-
-
-# Require confirmation it's set up corrctly
-echo
-echo -e "${WHITE}-- This script is meant to be run after running upgrade.sh, BEFORE committing to Git.${RESET}"
-
-while true; do
- echo -e "${GREEN}-- Is that the current state of your local project?${RESET}"
- read -p "-- (y/n) " yn
- case $yn in
- [Yy]* ) break;;
- [Nn]* ) exit;;
- * ) echo "Please answer y or n.";;
- esac
-done
-
-# Get the version and exit if not valid
-validateVersion $1
-
-# Create official v prefaced version
-version="v$1"
-
-# Run tests (and bail if they fail)
-phpunit
-echo -e "\n${WHITE}-- Tests succeeded.${RESET}"
-
-# Branch
-echo -e "\n${WHITE}-- Creating a Git branch '$version-changes'...${RESET}\n"
-git checkout -b $version-changes
-
-# Add and commit, with "v8.57.0 changes" as the commit name
-git add -A
-git commit -m "$version changes"
-
-echo
-echo -e "${WHITE}-- Git committed.${RESET}"
-
-# Push
-git push -u origin $version-changes
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/composer.json
deleted file mode 100644
index 88ebb77..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/composer.json
+++ /dev/null
@@ -1,51 +0,0 @@
-{
- "name": "tightenco/collect",
- "description": "Collect - Illuminate Collections as a separate package.",
- "keywords": ["laravel", "collection"],
- "license": "MIT",
- "authors": [
- {
- "name": "Taylor Otwell",
- "email": "taylorotwell@gmail.com"
- }
- ],
- "require": {
- "php": "^7.3|^8.0",
- "symfony/var-dumper": "^3.4 || ^4.0 || ^5.0 || ^6.0"
- },
- "require-dev": {
- "mockery/mockery": "^1.0",
- "phpunit/phpunit": "^8.3",
- "nesbot/carbon": "^2.23.0"
- },
- "autoload": {
- "files": [
- "src/Collect/Support/helpers.php",
- "src/Collect/Support/alias.php"
- ],
- "psr-4": {
- "Tightenco\\Collect\\": "src/Collect"
- }
- },
- "autoload-dev": {
- "files": [
- "tests/files/Support/Carbon.php",
- "tests/files/Support/HtmlString.php",
- "tests/files/Support/HigherOrderTapProxy.php",
- "tests/files/Support/Str.php",
- "tests/files/Support/Traits/Conditionable.php",
- "tests/files/Support/Stringable.php",
- "tests/files/Support/ItemNotFoundException.php",
- "tests/files/Support/MultipleItemsFoundException.php",
- "tests/Support/Concerns/CountsEnumerations.php"
- ]
- },
- "scripts": {
- "test": [
- "@composer install",
- "phpunit"
- ]
- },
- "minimum-stability": "dev",
- "prefer-stable": true
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Arrayable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Arrayable.php
deleted file mode 100755
index a205804..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Arrayable.php
+++ /dev/null
@@ -1,13 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Contracts\Support;
-
-interface Arrayable
-{
- /**
- * Get the instance as an array.
- *
- * @return array
- */
- public function toArray();
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/CanBeEscapedWhenCastToString.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/CanBeEscapedWhenCastToString.php
deleted file mode 100644
index 6f3ba00..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/CanBeEscapedWhenCastToString.php
+++ /dev/null
@@ -1,14 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Contracts\Support;
-
-interface CanBeEscapedWhenCastToString
-{
- /**
- * Indicate that the object's string representation should be escaped when __toString is invoked.
- *
- * @param bool $escape
- * @return $this
- */
- public function escapeWhenCastingToString($escape = true);
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Htmlable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Htmlable.php
deleted file mode 100644
index aa20e96..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Htmlable.php
+++ /dev/null
@@ -1,13 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Contracts\Support;
-
-interface Htmlable
-{
- /**
- * Get content as a string of HTML.
- *
- * @return string
- */
- public function toHtml();
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Jsonable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Jsonable.php
deleted file mode 100755
index 6b73730..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Contracts/Support/Jsonable.php
+++ /dev/null
@@ -1,14 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Contracts\Support;
-
-interface Jsonable
-{
- /**
- * Convert the object to its JSON representation.
- *
- * @param int $options
- * @return string
- */
- public function toJson($options = 0);
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Arr.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Arr.php
deleted file mode 100644
index 57350cc..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Arr.php
+++ /dev/null
@@ -1,747 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support;
-
-use ArrayAccess;
-use Tightenco\Collect\Support\Traits\Macroable;
-use InvalidArgumentException;
-
-class Arr
-{
- use Macroable;
-
- /**
- * Determine whether the given value is array accessible.
- *
- * @param mixed $value
- * @return bool
- */
- public static function accessible($value)
- {
- return is_array($value) || $value instanceof ArrayAccess;
- }
-
- /**
- * Add an element to an array using "dot" notation if it doesn't exist.
- *
- * @param array $array
- * @param string $key
- * @param mixed $value
- * @return array
- */
- public static function add($array, $key, $value)
- {
- if (is_null(static::get($array, $key))) {
- static::set($array, $key, $value);
- }
-
- return $array;
- }
-
- /**
- * Collapse an array of arrays into a single array.
- *
- * @param iterable $array
- * @return array
- */
- public static function collapse($array)
- {
- $results = [];
-
- foreach ($array as $values) {
- if ($values instanceof Collection) {
- $values = $values->all();
- } elseif (! is_array($values)) {
- continue;
- }
-
- $results[] = $values;
- }
-
- return array_merge([], ...$results);
- }
-
- /**
- * Cross join the given arrays, returning all possible permutations.
- *
- * @param iterable ...$arrays
- * @return array
- */
- public static function crossJoin(...$arrays)
- {
- $results = [[]];
-
- foreach ($arrays as $index => $array) {
- $append = [];
-
- foreach ($results as $product) {
- foreach ($array as $item) {
- $product[$index] = $item;
-
- $append[] = $product;
- }
- }
-
- $results = $append;
- }
-
- return $results;
- }
-
- /**
- * Divide an array into two arrays. One with keys and the other with values.
- *
- * @param array $array
- * @return array
- */
- public static function divide($array)
- {
- return [array_keys($array), array_values($array)];
- }
-
- /**
- * Flatten a multi-dimensional associative array with dots.
- *
- * @param iterable $array
- * @param string $prepend
- * @return array
- */
- public static function dot($array, $prepend = '')
- {
- $results = [];
-
- foreach ($array as $key => $value) {
- if (is_array($value) && ! empty($value)) {
- $results = array_merge($results, static::dot($value, $prepend.$key.'.'));
- } else {
- $results[$prepend.$key] = $value;
- }
- }
-
- return $results;
- }
-
- /**
- * Convert a flatten "dot" notation array into an expanded array.
- *
- * @param iterable $array
- * @return array
- */
- public static function undot($array)
- {
- $results = [];
-
- foreach ($array as $key => $value) {
- static::set($results, $key, $value);
- }
-
- return $results;
- }
-
- /**
- * Get all of the given array except for a specified array of keys.
- *
- * @param array $array
- * @param array|string $keys
- * @return array
- */
- public static function except($array, $keys)
- {
- static::forget($array, $keys);
-
- return $array;
- }
-
- /**
- * Determine if the given key exists in the provided array.
- *
- * @param \ArrayAccess|array $array
- * @param string|int $key
- * @return bool
- */
- public static function exists($array, $key)
- {
- if ($array instanceof Enumerable) {
- return $array->has($key);
- }
-
- if ($array instanceof ArrayAccess) {
- return $array->offsetExists($key);
- }
-
- return array_key_exists($key, $array);
- }
-
- /**
- * Return the first element in an array passing a given truth test.
- *
- * @param iterable $array
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public static function first($array, callable $callback = null, $default = null)
- {
- if (is_null($callback)) {
- if (empty($array)) {
- return value($default);
- }
-
- foreach ($array as $item) {
- return $item;
- }
- }
-
- foreach ($array as $key => $value) {
- if ($callback($value, $key)) {
- return $value;
- }
- }
-
- return value($default);
- }
-
- /**
- * Return the last element in an array passing a given truth test.
- *
- * @param array $array
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public static function last($array, callable $callback = null, $default = null)
- {
- if (is_null($callback)) {
- return empty($array) ? value($default) : end($array);
- }
-
- return static::first(array_reverse($array, true), $callback, $default);
- }
-
- /**
- * Flatten a multi-dimensional array into a single level.
- *
- * @param iterable $array
- * @param int $depth
- * @return array
- */
- public static function flatten($array, $depth = INF)
- {
- $result = [];
-
- foreach ($array as $item) {
- $item = $item instanceof Collection ? $item->all() : $item;
-
- if (! is_array($item)) {
- $result[] = $item;
- } else {
- $values = $depth === 1
- ? array_values($item)
- : static::flatten($item, $depth - 1);
-
- foreach ($values as $value) {
- $result[] = $value;
- }
- }
- }
-
- return $result;
- }
-
- /**
- * Remove one or many array items from a given array using "dot" notation.
- *
- * @param array $array
- * @param array|string $keys
- * @return void
- */
- public static function forget(&$array, $keys)
- {
- $original = &$array;
-
- $keys = (array) $keys;
-
- if (count($keys) === 0) {
- return;
- }
-
- foreach ($keys as $key) {
- // if the exact key exists in the top-level, remove it
- if (static::exists($array, $key)) {
- unset($array[$key]);
-
- continue;
- }
-
- $parts = explode('.', $key);
-
- // clean up before each pass
- $array = &$original;
-
- while (count($parts) > 1) {
- $part = array_shift($parts);
-
- if (isset($array[$part]) && is_array($array[$part])) {
- $array = &$array[$part];
- } else {
- continue 2;
- }
- }
-
- unset($array[array_shift($parts)]);
- }
- }
-
- /**
- * Get an item from an array using "dot" notation.
- *
- * @param \ArrayAccess|array $array
- * @param string|int|null $key
- * @param mixed $default
- * @return mixed
- */
- public static function get($array, $key, $default = null)
- {
- if (! static::accessible($array)) {
- return value($default);
- }
-
- if (is_null($key)) {
- return $array;
- }
-
- if (static::exists($array, $key)) {
- return $array[$key];
- }
-
- if (strpos($key, '.') === false) {
- return $array[$key] ?? value($default);
- }
-
- foreach (explode('.', $key) as $segment) {
- if (static::accessible($array) && static::exists($array, $segment)) {
- $array = $array[$segment];
- } else {
- return value($default);
- }
- }
-
- return $array;
- }
-
- /**
- * Check if an item or items exist in an array using "dot" notation.
- *
- * @param \ArrayAccess|array $array
- * @param string|array $keys
- * @return bool
- */
- public static function has($array, $keys)
- {
- $keys = (array) $keys;
-
- if (! $array || $keys === []) {
- return false;
- }
-
- foreach ($keys as $key) {
- $subKeyArray = $array;
-
- if (static::exists($array, $key)) {
- continue;
- }
-
- foreach (explode('.', $key) as $segment) {
- if (static::accessible($subKeyArray) && static::exists($subKeyArray, $segment)) {
- $subKeyArray = $subKeyArray[$segment];
- } else {
- return false;
- }
- }
- }
-
- return true;
- }
-
- /**
- * Determine if any of the keys exist in an array using "dot" notation.
- *
- * @param \ArrayAccess|array $array
- * @param string|array $keys
- * @return bool
- */
- public static function hasAny($array, $keys)
- {
- if (is_null($keys)) {
- return false;
- }
-
- $keys = (array) $keys;
-
- if (! $array) {
- return false;
- }
-
- if ($keys === []) {
- return false;
- }
-
- foreach ($keys as $key) {
- if (static::has($array, $key)) {
- return true;
- }
- }
-
- return false;
- }
-
- /**
- * Determines if an array is associative.
- *
- * An array is "associative" if it doesn't have sequential numerical keys beginning with zero.
- *
- * @param array $array
- * @return bool
- */
- public static function isAssoc(array $array)
- {
- $keys = array_keys($array);
-
- return array_keys($keys) !== $keys;
- }
-
- /**
- * Determines if an array is a list.
- *
- * An array is a "list" if all array keys are sequential integers starting from 0 with no gaps in between.
- *
- * @param array $array
- * @return bool
- */
- public static function isList($array)
- {
- return ! self::isAssoc($array);
- }
-
- /**
- * Get a subset of the items from the given array.
- *
- * @param array $array
- * @param array|string $keys
- * @return array
- */
- public static function only($array, $keys)
- {
- return array_intersect_key($array, array_flip((array) $keys));
- }
-
- /**
- * Pluck an array of values from an array.
- *
- * @param iterable $array
- * @param string|array|int|null $value
- * @param string|array|null $key
- * @return array
- */
- public static function pluck($array, $value, $key = null)
- {
- $results = [];
-
- [$value, $key] = static::explodePluckParameters($value, $key);
-
- foreach ($array as $item) {
- $itemValue = data_get($item, $value);
-
- // If the key is "null", we will just append the value to the array and keep
- // looping. Otherwise we will key the array using the value of the key we
- // received from the developer. Then we'll return the final array form.
- if (is_null($key)) {
- $results[] = $itemValue;
- } else {
- $itemKey = data_get($item, $key);
-
- if (is_object($itemKey) && method_exists($itemKey, '__toString')) {
- $itemKey = (string) $itemKey;
- }
-
- $results[$itemKey] = $itemValue;
- }
- }
-
- return $results;
- }
-
- /**
- * Explode the "value" and "key" arguments passed to "pluck".
- *
- * @param string|array $value
- * @param string|array|null $key
- * @return array
- */
- protected static function explodePluckParameters($value, $key)
- {
- $value = is_string($value) ? explode('.', $value) : $value;
-
- $key = is_null($key) || is_array($key) ? $key : explode('.', $key);
-
- return [$value, $key];
- }
-
- /**
- * Push an item onto the beginning of an array.
- *
- * @param array $array
- * @param mixed $value
- * @param mixed $key
- * @return array
- */
- public static function prepend($array, $value, $key = null)
- {
- if (func_num_args() == 2) {
- array_unshift($array, $value);
- } else {
- $array = [$key => $value] + $array;
- }
-
- return $array;
- }
-
- /**
- * Get a value from the array, and remove it.
- *
- * @param array $array
- * @param string $key
- * @param mixed $default
- * @return mixed
- */
- public static function pull(&$array, $key, $default = null)
- {
- $value = static::get($array, $key, $default);
-
- static::forget($array, $key);
-
- return $value;
- }
-
- /**
- * Convert the array into a query string.
- *
- * @param array $array
- * @return string
- */
- public static function query($array)
- {
- return http_build_query($array, '', '&', PHP_QUERY_RFC3986);
- }
-
- /**
- * Get one or a specified number of random values from an array.
- *
- * @param array $array
- * @param int|null $number
- * @param bool|false $preserveKeys
- * @return mixed
- *
- * @throws \InvalidArgumentException
- */
- public static function random($array, $number = null, $preserveKeys = false)
- {
- $requested = is_null($number) ? 1 : $number;
-
- $count = count($array);
-
- if ($requested > $count) {
- throw new InvalidArgumentException(
- "You requested {$requested} items, but there are only {$count} items available."
- );
- }
-
- if (is_null($number)) {
- return $array[array_rand($array)];
- }
-
- if ((int) $number === 0) {
- return [];
- }
-
- $keys = array_rand($array, $number);
-
- $results = [];
-
- if ($preserveKeys) {
- foreach ((array) $keys as $key) {
- $results[$key] = $array[$key];
- }
- } else {
- foreach ((array) $keys as $key) {
- $results[] = $array[$key];
- }
- }
-
- return $results;
- }
-
- /**
- * Set an array item to a given value using "dot" notation.
- *
- * If no key is given to the method, the entire array will be replaced.
- *
- * @param array $array
- * @param string|null $key
- * @param mixed $value
- * @return array
- */
- public static function set(&$array, $key, $value)
- {
- if (is_null($key)) {
- return $array = $value;
- }
-
- $keys = explode('.', $key);
-
- foreach ($keys as $i => $key) {
- if (count($keys) === 1) {
- break;
- }
-
- unset($keys[$i]);
-
- // If the key doesn't exist at this depth, we will just create an empty array
- // to hold the next value, allowing us to create the arrays to hold final
- // values at the correct depth. Then we'll keep digging into the array.
- if (! isset($array[$key]) || ! is_array($array[$key])) {
- $array[$key] = [];
- }
-
- $array = &$array[$key];
- }
-
- $array[array_shift($keys)] = $value;
-
- return $array;
- }
-
- /**
- * Shuffle the given array and return the result.
- *
- * @param array $array
- * @param int|null $seed
- * @return array
- */
- public static function shuffle($array, $seed = null)
- {
- if (is_null($seed)) {
- shuffle($array);
- } else {
- mt_srand($seed);
- shuffle($array);
- mt_srand();
- }
-
- return $array;
- }
-
- /**
- * Sort the array using the given callback or "dot" notation.
- *
- * @param array $array
- * @param callable|array|string|null $callback
- * @return array
- */
- public static function sort($array, $callback = null)
- {
- return Collection::make($array)->sortBy($callback)->all();
- }
-
- /**
- * Recursively sort an array by keys and values.
- *
- * @param array $array
- * @param int $options
- * @param bool $descending
- * @return array
- */
- public static function sortRecursive($array, $options = SORT_REGULAR, $descending = false)
- {
- foreach ($array as &$value) {
- if (is_array($value)) {
- $value = static::sortRecursive($value, $options, $descending);
- }
- }
-
- if (static::isAssoc($array)) {
- $descending
- ? krsort($array, $options)
- : ksort($array, $options);
- } else {
- $descending
- ? rsort($array, $options)
- : sort($array, $options);
- }
-
- return $array;
- }
-
- /**
- * Conditionally compile classes from an array into a CSS class list.
- *
- * @param array $array
- * @return string
- */
- public static function toCssClasses($array)
- {
- $classList = static::wrap($array);
-
- $classes = [];
-
- foreach ($classList as $class => $constraint) {
- if (is_numeric($class)) {
- $classes[] = $constraint;
- } elseif ($constraint) {
- $classes[] = $class;
- }
- }
-
- return implode(' ', $classes);
- }
-
- /**
- * Filter the array using the given callback.
- *
- * @param array $array
- * @param callable $callback
- * @return array
- */
- public static function where($array, callable $callback)
- {
- return array_filter($array, $callback, ARRAY_FILTER_USE_BOTH);
- }
-
- /**
- * Filter items where the value is not null.
- *
- * @param array $array
- * @return array
- */
- public static function whereNotNull($array)
- {
- return static::where($array, function ($value) {
- return ! is_null($value);
- });
- }
-
- /**
- * If the given value is not an array and not null, wrap it in one.
- *
- * @param mixed $value
- * @return array
- */
- public static function wrap($value)
- {
- if (is_null($value)) {
- return [];
- }
-
- return is_array($value) ? $value : [$value];
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Collection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Collection.php
deleted file mode 100644
index 577e351..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Collection.php
+++ /dev/null
@@ -1,1672 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support;
-
-use ArrayAccess;
-use ArrayIterator;
-use Tightenco\Collect\Contracts\Support\CanBeEscapedWhenCastToString;
-use Tightenco\Collect\Support\Traits\EnumeratesValues;
-use Tightenco\Collect\Support\Traits\Macroable;
-use stdClass;
-
-class Collection implements ArrayAccess, CanBeEscapedWhenCastToString, Enumerable
-{
- use EnumeratesValues, Macroable;
-
- /**
- * The items contained in the collection.
- *
- * @var array
- */
- protected $items = [];
-
- /**
- * Create a new collection.
- *
- * @param mixed $items
- * @return void
- */
- public function __construct($items = [])
- {
- $this->items = $this->getArrayableItems($items);
- }
-
- /**
- * Create a collection with the given range.
- *
- * @param int $from
- * @param int $to
- * @return static
- */
- public static function range($from, $to)
- {
- return new static(range($from, $to));
- }
-
- /**
- * Get all of the items in the collection.
- *
- * @return array
- */
- public function all()
- {
- return $this->items;
- }
-
- /**
- * Get a lazy collection for the items in this collection.
- *
- * @return \Tightenco\Collect\Support\LazyCollection
- */
- public function lazy()
- {
- return new LazyCollection($this->items);
- }
-
- /**
- * Get the average value of a given key.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function avg($callback = null)
- {
- $callback = $this->valueRetriever($callback);
-
- $items = $this->map(function ($value) use ($callback) {
- return $callback($value);
- })->filter(function ($value) {
- return ! is_null($value);
- });
-
- if ($count = $items->count()) {
- return $items->sum() / $count;
- }
- }
-
- /**
- * Get the median of a given key.
- *
- * @param string|array|null $key
- * @return mixed
- */
- public function median($key = null)
- {
- $values = (isset($key) ? $this->pluck($key) : $this)
- ->filter(function ($item) {
- return ! is_null($item);
- })->sort()->values();
-
- $count = $values->count();
-
- if ($count === 0) {
- return;
- }
-
- $middle = (int) ($count / 2);
-
- if ($count % 2) {
- return $values->get($middle);
- }
-
- return (new static([
- $values->get($middle - 1), $values->get($middle),
- ]))->average();
- }
-
- /**
- * Get the mode of a given key.
- *
- * @param string|array|null $key
- * @return array|null
- */
- public function mode($key = null)
- {
- if ($this->count() === 0) {
- return;
- }
-
- $collection = isset($key) ? $this->pluck($key) : $this;
-
- $counts = new static;
-
- $collection->each(function ($value) use ($counts) {
- $counts[$value] = isset($counts[$value]) ? $counts[$value] + 1 : 1;
- });
-
- $sorted = $counts->sort();
-
- $highestValue = $sorted->last();
-
- return $sorted->filter(function ($value) use ($highestValue) {
- return $value == $highestValue;
- })->sort()->keys()->all();
- }
-
- /**
- * Collapse the collection of items into a single array.
- *
- * @return static
- */
- public function collapse()
- {
- return new static(Arr::collapse($this->items));
- }
-
- /**
- * Determine if an item exists in the collection.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function contains($key, $operator = null, $value = null)
- {
- if (func_num_args() === 1) {
- if ($this->useAsCallable($key)) {
- $placeholder = new stdClass;
-
- return $this->first($key, $placeholder) !== $placeholder;
- }
-
- return in_array($key, $this->items);
- }
-
- return $this->contains($this->operatorForWhere(...func_get_args()));
- }
-
- /**
- * Determine if an item is not contained in the collection.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function doesntContain($key, $operator = null, $value = null)
- {
- return ! $this->contains(...func_get_args());
- }
-
- /**
- * Cross join with the given lists, returning all possible permutations.
- *
- * @param mixed ...$lists
- * @return static
- */
- public function crossJoin(...$lists)
- {
- return new static(Arr::crossJoin(
- $this->items, ...array_map([$this, 'getArrayableItems'], $lists)
- ));
- }
-
- /**
- * Get the items in the collection that are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diff($items)
- {
- return new static(array_diff($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Get the items in the collection that are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffUsing($items, callable $callback)
- {
- return new static(array_udiff($this->items, $this->getArrayableItems($items), $callback));
- }
-
- /**
- * Get the items in the collection whose keys and values are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diffAssoc($items)
- {
- return new static(array_diff_assoc($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Get the items in the collection whose keys and values are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffAssocUsing($items, callable $callback)
- {
- return new static(array_diff_uassoc($this->items, $this->getArrayableItems($items), $callback));
- }
-
- /**
- * Get the items in the collection whose keys are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diffKeys($items)
- {
- return new static(array_diff_key($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Get the items in the collection whose keys are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffKeysUsing($items, callable $callback)
- {
- return new static(array_diff_ukey($this->items, $this->getArrayableItems($items), $callback));
- }
-
- /**
- * Retrieve duplicate items from the collection.
- *
- * @param callable|string|null $callback
- * @param bool $strict
- * @return static
- */
- public function duplicates($callback = null, $strict = false)
- {
- $items = $this->map($this->valueRetriever($callback));
-
- $uniqueItems = $items->unique(null, $strict);
-
- $compare = $this->duplicateComparator($strict);
-
- $duplicates = new static;
-
- foreach ($items as $key => $value) {
- if ($uniqueItems->isNotEmpty() && $compare($value, $uniqueItems->first())) {
- $uniqueItems->shift();
- } else {
- $duplicates[$key] = $value;
- }
- }
-
- return $duplicates;
- }
-
- /**
- * Retrieve duplicate items from the collection using strict comparison.
- *
- * @param callable|string|null $callback
- * @return static
- */
- public function duplicatesStrict($callback = null)
- {
- return $this->duplicates($callback, true);
- }
-
- /**
- * Get the comparison function to detect duplicates.
- *
- * @param bool $strict
- * @return \Closure
- */
- protected function duplicateComparator($strict)
- {
- if ($strict) {
- return function ($a, $b) {
- return $a === $b;
- };
- }
-
- return function ($a, $b) {
- return $a == $b;
- };
- }
-
- /**
- * Get all items except for those with the specified keys.
- *
- * @param \Tightenco\Collect\Support\Collection|mixed $keys
- * @return static
- */
- public function except($keys)
- {
- if ($keys instanceof Enumerable) {
- $keys = $keys->all();
- } elseif (! is_array($keys)) {
- $keys = func_get_args();
- }
-
- return new static(Arr::except($this->items, $keys));
- }
-
- /**
- * Run a filter over each of the items.
- *
- * @param callable|null $callback
- * @return static
- */
- public function filter(callable $callback = null)
- {
- if ($callback) {
- return new static(Arr::where($this->items, $callback));
- }
-
- return new static(array_filter($this->items));
- }
-
- /**
- * Get the first item from the collection passing the given truth test.
- *
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public function first(callable $callback = null, $default = null)
- {
- return Arr::first($this->items, $callback, $default);
- }
-
- /**
- * Get a flattened array of the items in the collection.
- *
- * @param int $depth
- * @return static
- */
- public function flatten($depth = INF)
- {
- return new static(Arr::flatten($this->items, $depth));
- }
-
- /**
- * Flip the items in the collection.
- *
- * @return static
- */
- public function flip()
- {
- return new static(array_flip($this->items));
- }
-
- /**
- * Remove an item from the collection by key.
- *
- * @param string|int|array $keys
- * @return $this
- */
- public function forget($keys)
- {
- foreach ((array) $keys as $key) {
- $this->offsetUnset($key);
- }
-
- return $this;
- }
-
- /**
- * Get an item from the collection by key.
- *
- * @param mixed $key
- * @param mixed $default
- * @return mixed
- */
- public function get($key, $default = null)
- {
- if (array_key_exists($key, $this->items)) {
- return $this->items[$key];
- }
-
- return value($default);
- }
-
- /**
- * Get an item from the collection by key or add it to collection if it does not exist.
- *
- * @param mixed $key
- * @param mixed $value
- * @return mixed
- */
- public function getOrPut($key, $value)
- {
- if (array_key_exists($key, $this->items)) {
- return $this->items[$key];
- }
-
- $this->offsetSet($key, $value = value($value));
-
- return $value;
- }
-
- /**
- * Group an associative array by a field or using a callback.
- *
- * @param array|callable|string $groupBy
- * @param bool $preserveKeys
- * @return static
- */
- public function groupBy($groupBy, $preserveKeys = false)
- {
- if (! $this->useAsCallable($groupBy) && is_array($groupBy)) {
- $nextGroups = $groupBy;
-
- $groupBy = array_shift($nextGroups);
- }
-
- $groupBy = $this->valueRetriever($groupBy);
-
- $results = [];
-
- foreach ($this->items as $key => $value) {
- $groupKeys = $groupBy($value, $key);
-
- if (! is_array($groupKeys)) {
- $groupKeys = [$groupKeys];
- }
-
- foreach ($groupKeys as $groupKey) {
- $groupKey = is_bool($groupKey) ? (int) $groupKey : $groupKey;
-
- if (! array_key_exists($groupKey, $results)) {
- $results[$groupKey] = new static;
- }
-
- $results[$groupKey]->offsetSet($preserveKeys ? $key : null, $value);
- }
- }
-
- $result = new static($results);
-
- if (! empty($nextGroups)) {
- return $result->map->groupBy($nextGroups, $preserveKeys);
- }
-
- return $result;
- }
-
- /**
- * Key an associative array by a field or using a callback.
- *
- * @param callable|string $keyBy
- * @return static
- */
- public function keyBy($keyBy)
- {
- $keyBy = $this->valueRetriever($keyBy);
-
- $results = [];
-
- foreach ($this->items as $key => $item) {
- $resolvedKey = $keyBy($item, $key);
-
- if (is_object($resolvedKey)) {
- $resolvedKey = (string) $resolvedKey;
- }
-
- $results[$resolvedKey] = $item;
- }
-
- return new static($results);
- }
-
- /**
- * Determine if an item exists in the collection by key.
- *
- * @param mixed $key
- * @return bool
- */
- public function has($key)
- {
- $keys = is_array($key) ? $key : func_get_args();
-
- foreach ($keys as $value) {
- if (! array_key_exists($value, $this->items)) {
- return false;
- }
- }
-
- return true;
- }
-
- /**
- * Determine if any of the keys exist in the collection.
- *
- * @param mixed $key
- * @return bool
- */
- public function hasAny($key)
- {
- if ($this->isEmpty()) {
- return false;
- }
-
- $keys = is_array($key) ? $key : func_get_args();
-
- foreach ($keys as $value) {
- if ($this->has($value)) {
- return true;
- }
- }
-
- return false;
- }
-
- /**
- * Concatenate values of a given key as a string.
- *
- * @param string $value
- * @param string|null $glue
- * @return string
- */
- public function implode($value, $glue = null)
- {
- $first = $this->first();
-
- if (is_array($first) || (is_object($first) && ! $first instanceof \Illuminate\Support\Stringable)) {
- return implode($glue ?? '', $this->pluck($value)->all());
- }
-
- return implode($value ?? '', $this->items);
- }
-
- /**
- * Intersect the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function intersect($items)
- {
- return new static(array_intersect($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Intersect the collection with the given items by key.
- *
- * @param mixed $items
- * @return static
- */
- public function intersectByKeys($items)
- {
- return new static(array_intersect_key(
- $this->items, $this->getArrayableItems($items)
- ));
- }
-
- /**
- * Determine if the collection is empty or not.
- *
- * @return bool
- */
- public function isEmpty()
- {
- return empty($this->items);
- }
-
- /**
- * Determine if the collection contains a single item.
- *
- * @return bool
- */
- public function containsOneItem()
- {
- return $this->count() === 1;
- }
-
- /**
- * Join all items from the collection using a string. The final items can use a separate glue string.
- *
- * @param string $glue
- * @param string $finalGlue
- * @return string
- */
- public function join($glue, $finalGlue = '')
- {
- if ($finalGlue === '') {
- return $this->implode($glue);
- }
-
- $count = $this->count();
-
- if ($count === 0) {
- return '';
- }
-
- if ($count === 1) {
- return $this->last();
- }
-
- $collection = new static($this->items);
-
- $finalItem = $collection->pop();
-
- return $collection->implode($glue).$finalGlue.$finalItem;
- }
-
- /**
- * Get the keys of the collection items.
- *
- * @return static
- */
- public function keys()
- {
- return new static(array_keys($this->items));
- }
-
- /**
- * Get the last item from the collection.
- *
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public function last(callable $callback = null, $default = null)
- {
- return Arr::last($this->items, $callback, $default);
- }
-
- /**
- * Get the values of a given key.
- *
- * @param string|array|int|null $value
- * @param string|null $key
- * @return static
- */
- public function pluck($value, $key = null)
- {
- return new static(Arr::pluck($this->items, $value, $key));
- }
-
- /**
- * Run a map over each of the items.
- *
- * @param callable $callback
- * @return static
- */
- public function map(callable $callback)
- {
- $keys = array_keys($this->items);
-
- $items = array_map($callback, $this->items, $keys);
-
- return new static(array_combine($keys, $items));
- }
-
- /**
- * Run a dictionary map over the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapToDictionary(callable $callback)
- {
- $dictionary = [];
-
- foreach ($this->items as $key => $item) {
- $pair = $callback($item, $key);
-
- $key = key($pair);
-
- $value = reset($pair);
-
- if (! isset($dictionary[$key])) {
- $dictionary[$key] = [];
- }
-
- $dictionary[$key][] = $value;
- }
-
- return new static($dictionary);
- }
-
- /**
- * Run an associative map over each of the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapWithKeys(callable $callback)
- {
- $result = [];
-
- foreach ($this->items as $key => $value) {
- $assoc = $callback($value, $key);
-
- foreach ($assoc as $mapKey => $mapValue) {
- $result[$mapKey] = $mapValue;
- }
- }
-
- return new static($result);
- }
-
- /**
- * Merge the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function merge($items)
- {
- return new static(array_merge($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Recursively merge the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function mergeRecursive($items)
- {
- return new static(array_merge_recursive($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Create a collection by using this collection for keys and another for its values.
- *
- * @param mixed $values
- * @return static
- */
- public function combine($values)
- {
- return new static(array_combine($this->all(), $this->getArrayableItems($values)));
- }
-
- /**
- * Union the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function union($items)
- {
- return new static($this->items + $this->getArrayableItems($items));
- }
-
- /**
- * Create a new collection consisting of every n-th element.
- *
- * @param int $step
- * @param int $offset
- * @return static
- */
- public function nth($step, $offset = 0)
- {
- $new = [];
-
- $position = 0;
-
- foreach ($this->items as $item) {
- if ($position % $step === $offset) {
- $new[] = $item;
- }
-
- $position++;
- }
-
- return new static($new);
- }
-
- /**
- * Get the items with the specified keys.
- *
- * @param mixed $keys
- * @return static
- */
- public function only($keys)
- {
- if (is_null($keys)) {
- return new static($this->items);
- }
-
- if ($keys instanceof Enumerable) {
- $keys = $keys->all();
- }
-
- $keys = is_array($keys) ? $keys : func_get_args();
-
- return new static(Arr::only($this->items, $keys));
- }
-
- /**
- * Get and remove the last N items from the collection.
- *
- * @param int $count
- * @return mixed
- */
- public function pop($count = 1)
- {
- if ($count === 1) {
- return array_pop($this->items);
- }
-
- if ($this->isEmpty()) {
- return new static;
- }
-
- $results = [];
-
- $collectionCount = $this->count();
-
- foreach (range(1, min($count, $collectionCount)) as $item) {
- array_push($results, array_pop($this->items));
- }
-
- return new static($results);
- }
-
- /**
- * Push an item onto the beginning of the collection.
- *
- * @param mixed $value
- * @param mixed $key
- * @return $this
- */
- public function prepend($value, $key = null)
- {
- $this->items = Arr::prepend($this->items, ...func_get_args());
-
- return $this;
- }
-
- /**
- * Push one or more items onto the end of the collection.
- *
- * @param mixed $values
- * @return $this
- */
- public function push(...$values)
- {
- foreach ($values as $value) {
- $this->items[] = $value;
- }
-
- return $this;
- }
-
- /**
- * Push all of the given items onto the collection.
- *
- * @param iterable $source
- * @return static
- */
- public function concat($source)
- {
- $result = new static($this);
-
- foreach ($source as $item) {
- $result->push($item);
- }
-
- return $result;
- }
-
- /**
- * Get and remove an item from the collection.
- *
- * @param mixed $key
- * @param mixed $default
- * @return mixed
- */
- public function pull($key, $default = null)
- {
- return Arr::pull($this->items, $key, $default);
- }
-
- /**
- * Put an item in the collection by key.
- *
- * @param mixed $key
- * @param mixed $value
- * @return $this
- */
- public function put($key, $value)
- {
- $this->offsetSet($key, $value);
-
- return $this;
- }
-
- /**
- * Get one or a specified number of items randomly from the collection.
- *
- * @param int|null $number
- * @return static|mixed
- *
- * @throws \InvalidArgumentException
- */
- public function random($number = null)
- {
- if (is_null($number)) {
- return Arr::random($this->items);
- }
-
- return new static(Arr::random($this->items, $number));
- }
-
- /**
- * Replace the collection items with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function replace($items)
- {
- return new static(array_replace($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Recursively replace the collection items with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function replaceRecursive($items)
- {
- return new static(array_replace_recursive($this->items, $this->getArrayableItems($items)));
- }
-
- /**
- * Reverse items order.
- *
- * @return static
- */
- public function reverse()
- {
- return new static(array_reverse($this->items, true));
- }
-
- /**
- * Search the collection for a given value and return the corresponding key if successful.
- *
- * @param mixed $value
- * @param bool $strict
- * @return mixed
- */
- public function search($value, $strict = false)
- {
- if (! $this->useAsCallable($value)) {
- return array_search($value, $this->items, $strict);
- }
-
- foreach ($this->items as $key => $item) {
- if ($value($item, $key)) {
- return $key;
- }
- }
-
- return false;
- }
-
- /**
- * Get and remove the first N items from the collection.
- *
- * @param int $count
- * @return mixed
- */
- public function shift($count = 1)
- {
- if ($count === 1) {
- return array_shift($this->items);
- }
-
- if ($this->isEmpty()) {
- return new static;
- }
-
- $results = [];
-
- $collectionCount = $this->count();
-
- foreach (range(1, min($count, $collectionCount)) as $item) {
- array_push($results, array_shift($this->items));
- }
-
- return new static($results);
- }
-
- /**
- * Shuffle the items in the collection.
- *
- * @param int|null $seed
- * @return static
- */
- public function shuffle($seed = null)
- {
- return new static(Arr::shuffle($this->items, $seed));
- }
-
- /**
- * Create chunks representing a "sliding window" view of the items in the collection.
- *
- * @param int $size
- * @param int $step
- * @return static
- */
- public function sliding($size = 2, $step = 1)
- {
- $chunks = floor(($this->count() - $size) / $step) + 1;
-
- return static::times($chunks, function ($number) use ($size, $step) {
- return $this->slice(($number - 1) * $step, $size);
- });
- }
-
- /**
- * Skip the first {$count} items.
- *
- * @param int $count
- * @return static
- */
- public function skip($count)
- {
- return $this->slice($count);
- }
-
- /**
- * Skip items in the collection until the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function skipUntil($value)
- {
- return new static($this->lazy()->skipUntil($value)->all());
- }
-
- /**
- * Skip items in the collection while the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function skipWhile($value)
- {
- return new static($this->lazy()->skipWhile($value)->all());
- }
-
- /**
- * Slice the underlying collection array.
- *
- * @param int $offset
- * @param int|null $length
- * @return static
- */
- public function slice($offset, $length = null)
- {
- return new static(array_slice($this->items, $offset, $length, true));
- }
-
- /**
- * Split a collection into a certain number of groups.
- *
- * @param int $numberOfGroups
- * @return static
- */
- public function split($numberOfGroups)
- {
- if ($this->isEmpty()) {
- return new static;
- }
-
- $groups = new static;
-
- $groupSize = floor($this->count() / $numberOfGroups);
-
- $remain = $this->count() % $numberOfGroups;
-
- $start = 0;
-
- for ($i = 0; $i < $numberOfGroups; $i++) {
- $size = $groupSize;
-
- if ($i < $remain) {
- $size++;
- }
-
- if ($size) {
- $groups->push(new static(array_slice($this->items, $start, $size)));
-
- $start += $size;
- }
- }
-
- return $groups;
- }
-
- /**
- * Split a collection into a certain number of groups, and fill the first groups completely.
- *
- * @param int $numberOfGroups
- * @return static
- */
- public function splitIn($numberOfGroups)
- {
- return $this->chunk(ceil($this->count() / $numberOfGroups));
- }
-
- /**
- * Get the first item in the collection, but only if exactly one item exists. Otherwise, throw an exception.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return mixed
- *
- * @throws \Tightenco\Collect\Support\ItemNotFoundException
- * @throws \Tightenco\Collect\Support\MultipleItemsFoundException
- */
- public function sole($key = null, $operator = null, $value = null)
- {
- $filter = func_num_args() > 1
- ? $this->operatorForWhere(...func_get_args())
- : $key;
-
- $items = $this->when($filter)->filter($filter);
-
- if ($items->isEmpty()) {
- throw new ItemNotFoundException;
- }
-
- if ($items->count() > 1) {
- throw new MultipleItemsFoundException;
- }
-
- return $items->first();
- }
-
- /**
- * Get the first item in the collection but throw an exception if no matching items exist.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return mixed
- *
- * @throws \Tightenco\Collect\Support\ItemNotFoundException
- */
- public function firstOrFail($key = null, $operator = null, $value = null)
- {
- $filter = func_num_args() > 1
- ? $this->operatorForWhere(...func_get_args())
- : $key;
-
- $placeholder = new stdClass();
-
- $item = $this->first($filter, $placeholder);
-
- if ($item === $placeholder) {
- throw new ItemNotFoundException;
- }
-
- return $item;
- }
-
- /**
- * Chunk the collection into chunks of the given size.
- *
- * @param int $size
- * @return static
- */
- public function chunk($size)
- {
- if ($size <= 0) {
- return new static;
- }
-
- $chunks = [];
-
- foreach (array_chunk($this->items, $size, true) as $chunk) {
- $chunks[] = new static($chunk);
- }
-
- return new static($chunks);
- }
-
- /**
- * Chunk the collection into chunks with a callback.
- *
- * @param callable $callback
- * @return static
- */
- public function chunkWhile(callable $callback)
- {
- return new static(
- $this->lazy()->chunkWhile($callback)->mapInto(static::class)
- );
- }
-
- /**
- * Sort through each item with a callback.
- *
- * @param callable|int|null $callback
- * @return static
- */
- public function sort($callback = null)
- {
- $items = $this->items;
-
- $callback && is_callable($callback)
- ? uasort($items, $callback)
- : asort($items, $callback ?? SORT_REGULAR);
-
- return new static($items);
- }
-
- /**
- * Sort items in descending order.
- *
- * @param int $options
- * @return static
- */
- public function sortDesc($options = SORT_REGULAR)
- {
- $items = $this->items;
-
- arsort($items, $options);
-
- return new static($items);
- }
-
- /**
- * Sort the collection using the given callback.
- *
- * @param callable|array|string $callback
- * @param int $options
- * @param bool $descending
- * @return static
- */
- public function sortBy($callback, $options = SORT_REGULAR, $descending = false)
- {
- if (is_array($callback) && ! is_callable($callback)) {
- return $this->sortByMany($callback);
- }
-
- $results = [];
-
- $callback = $this->valueRetriever($callback);
-
- // First we will loop through the items and get the comparator from a callback
- // function which we were given. Then, we will sort the returned values and
- // grab all the corresponding values for the sorted keys from this array.
- foreach ($this->items as $key => $value) {
- $results[$key] = $callback($value, $key);
- }
-
- $descending ? arsort($results, $options)
- : asort($results, $options);
-
- // Once we have sorted all of the keys in the array, we will loop through them
- // and grab the corresponding model so we can set the underlying items list
- // to the sorted version. Then we'll just return the collection instance.
- foreach (array_keys($results) as $key) {
- $results[$key] = $this->items[$key];
- }
-
- return new static($results);
- }
-
- /**
- * Sort the collection using multiple comparisons.
- *
- * @param array $comparisons
- * @return static
- */
- protected function sortByMany(array $comparisons = [])
- {
- $items = $this->items;
-
- usort($items, function ($a, $b) use ($comparisons) {
- foreach ($comparisons as $comparison) {
- $comparison = Arr::wrap($comparison);
-
- $prop = $comparison[0];
-
- $ascending = Arr::get($comparison, 1, true) === true ||
- Arr::get($comparison, 1, true) === 'asc';
-
- $result = 0;
-
- if (! is_string($prop) && is_callable($prop)) {
- $result = $prop($a, $b);
- } else {
- $values = [data_get($a, $prop), data_get($b, $prop)];
-
- if (! $ascending) {
- $values = array_reverse($values);
- }
-
- $result = $values[0] <=> $values[1];
- }
-
- if ($result === 0) {
- continue;
- }
-
- return $result;
- }
- });
-
- return new static($items);
- }
-
- /**
- * Sort the collection in descending order using the given callback.
- *
- * @param callable|string $callback
- * @param int $options
- * @return static
- */
- public function sortByDesc($callback, $options = SORT_REGULAR)
- {
- return $this->sortBy($callback, $options, true);
- }
-
- /**
- * Sort the collection keys.
- *
- * @param int $options
- * @param bool $descending
- * @return static
- */
- public function sortKeys($options = SORT_REGULAR, $descending = false)
- {
- $items = $this->items;
-
- $descending ? krsort($items, $options) : ksort($items, $options);
-
- return new static($items);
- }
-
- /**
- * Sort the collection keys in descending order.
- *
- * @param int $options
- * @return static
- */
- public function sortKeysDesc($options = SORT_REGULAR)
- {
- return $this->sortKeys($options, true);
- }
-
- /**
- * Sort the collection keys using a callback.
- *
- * @param callable $callback
- * @return static
- */
- public function sortKeysUsing(callable $callback)
- {
- $items = $this->items;
-
- uksort($items, $callback);
-
- return new static($items);
- }
-
- /**
- * Splice a portion of the underlying collection array.
- *
- * @param int $offset
- * @param int|null $length
- * @param mixed $replacement
- * @return static
- */
- public function splice($offset, $length = null, $replacement = [])
- {
- if (func_num_args() === 1) {
- return new static(array_splice($this->items, $offset));
- }
-
- return new static(array_splice($this->items, $offset, $length, $this->getArrayableItems($replacement)));
- }
-
- /**
- * Take the first or last {$limit} items.
- *
- * @param int $limit
- * @return static
- */
- public function take($limit)
- {
- if ($limit < 0) {
- return $this->slice($limit, abs($limit));
- }
-
- return $this->slice(0, $limit);
- }
-
- /**
- * Take items in the collection until the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function takeUntil($value)
- {
- return new static($this->lazy()->takeUntil($value)->all());
- }
-
- /**
- * Take items in the collection while the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function takeWhile($value)
- {
- return new static($this->lazy()->takeWhile($value)->all());
- }
-
- /**
- * Transform each item in the collection using a callback.
- *
- * @param callable $callback
- * @return $this
- */
- public function transform(callable $callback)
- {
- $this->items = $this->map($callback)->all();
-
- return $this;
- }
-
- /**
- * Convert a flatten "dot" notation array into an expanded array.
- *
- * @return static
- */
- public function undot()
- {
- return new static(Arr::undot($this->all()));
- }
-
- /**
- * Return only unique items from the collection array.
- *
- * @param string|callable|null $key
- * @param bool $strict
- * @return static
- */
- public function unique($key = null, $strict = false)
- {
- if (is_null($key) && $strict === false) {
- return new static(array_unique($this->items, SORT_REGULAR));
- }
-
- $callback = $this->valueRetriever($key);
-
- $exists = [];
-
- return $this->reject(function ($item, $key) use ($callback, $strict, &$exists) {
- if (in_array($id = $callback($item, $key), $exists, $strict)) {
- return true;
- }
-
- $exists[] = $id;
- });
- }
-
- /**
- * Reset the keys on the underlying array.
- *
- * @return static
- */
- public function values()
- {
- return new static(array_values($this->items));
- }
-
- /**
- * Zip the collection together with one or more arrays.
- *
- * e.g. new Collection([1, 2, 3])->zip([4, 5, 6]);
- * => [[1, 4], [2, 5], [3, 6]]
- *
- * @param mixed ...$items
- * @return static
- */
- public function zip($items)
- {
- $arrayableItems = array_map(function ($items) {
- return $this->getArrayableItems($items);
- }, func_get_args());
-
- $params = array_merge([function () {
- return new static(func_get_args());
- }, $this->items], $arrayableItems);
-
- return new static(array_map(...$params));
- }
-
- /**
- * Pad collection to the specified length with a value.
- *
- * @param int $size
- * @param mixed $value
- * @return static
- */
- public function pad($size, $value)
- {
- return new static(array_pad($this->items, $size, $value));
- }
-
- /**
- * Get an iterator for the items.
- *
- * @return \ArrayIterator
- */
- #[\ReturnTypeWillChange]
- public function getIterator()
- {
- return new ArrayIterator($this->items);
- }
-
- /**
- * Count the number of items in the collection.
- *
- * @return int
- */
- #[\ReturnTypeWillChange]
- public function count()
- {
- return count($this->items);
- }
-
- /**
- * Count the number of items in the collection by a field or using a callback.
- *
- * @param callable|string $countBy
- * @return static
- */
- public function countBy($countBy = null)
- {
- return new static($this->lazy()->countBy($countBy)->all());
- }
-
- /**
- * Add an item to the collection.
- *
- * @param mixed $item
- * @return $this
- */
- public function add($item)
- {
- $this->items[] = $item;
-
- return $this;
- }
-
- /**
- * Get a base Support collection instance from this collection.
- *
- * @return \Tightenco\Collect\Support\Collection
- */
- public function toBase()
- {
- return new self($this);
- }
-
- /**
- * Determine if an item exists at an offset.
- *
- * @param mixed $key
- * @return bool
- */
- #[\ReturnTypeWillChange]
- public function offsetExists($key)
- {
- return isset($this->items[$key]);
- }
-
- /**
- * Get an item at a given offset.
- *
- * @param mixed $key
- * @return mixed
- */
- #[\ReturnTypeWillChange]
- public function offsetGet($key)
- {
- return $this->items[$key];
- }
-
- /**
- * Set the item at a given offset.
- *
- * @param mixed $key
- * @param mixed $value
- * @return void
- */
- #[\ReturnTypeWillChange]
- public function offsetSet($key, $value)
- {
- if (is_null($key)) {
- $this->items[] = $value;
- } else {
- $this->items[$key] = $value;
- }
- }
-
- /**
- * Unset the item at a given offset.
- *
- * @param mixed $key
- * @return void
- */
- #[\ReturnTypeWillChange]
- public function offsetUnset($key)
- {
- unset($this->items[$key]);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Enumerable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Enumerable.php
deleted file mode 100644
index 60af386..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Enumerable.php
+++ /dev/null
@@ -1,1027 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support;
-
-use Countable;
-use Tightenco\Collect\Contracts\Support\Arrayable;
-use Tightenco\Collect\Contracts\Support\Jsonable;
-use IteratorAggregate;
-use JsonSerializable;
-
-interface Enumerable extends Arrayable, Countable, IteratorAggregate, Jsonable, JsonSerializable
-{
- /**
- * Create a new collection instance if the value isn't one already.
- *
- * @param mixed $items
- * @return static
- */
- public static function make($items = []);
-
- /**
- * Create a new instance by invoking the callback a given amount of times.
- *
- * @param int $number
- * @param callable|null $callback
- * @return static
- */
- public static function times($number, callable $callback = null);
-
- /**
- * Create a collection with the given range.
- *
- * @param int $from
- * @param int $to
- * @return static
- */
- public static function range($from, $to);
-
- /**
- * Wrap the given value in a collection if applicable.
- *
- * @param mixed $value
- * @return static
- */
- public static function wrap($value);
-
- /**
- * Get the underlying items from the given collection if applicable.
- *
- * @param array|static $value
- * @return array
- */
- public static function unwrap($value);
-
- /**
- * Create a new instance with no items.
- *
- * @return static
- */
- public static function empty();
-
- /**
- * Get all items in the enumerable.
- *
- * @return array
- */
- public function all();
-
- /**
- * Alias for the "avg" method.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function average($callback = null);
-
- /**
- * Get the median of a given key.
- *
- * @param string|array|null $key
- * @return mixed
- */
- public function median($key = null);
-
- /**
- * Get the mode of a given key.
- *
- * @param string|array|null $key
- * @return array|null
- */
- public function mode($key = null);
-
- /**
- * Collapse the items into a single enumerable.
- *
- * @return static
- */
- public function collapse();
-
- /**
- * Alias for the "contains" method.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function some($key, $operator = null, $value = null);
-
- /**
- * Determine if an item exists, using strict comparison.
- *
- * @param mixed $key
- * @param mixed $value
- * @return bool
- */
- public function containsStrict($key, $value = null);
-
- /**
- * Get the average value of a given key.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function avg($callback = null);
-
- /**
- * Determine if an item exists in the enumerable.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function contains($key, $operator = null, $value = null);
-
- /**
- * Cross join with the given lists, returning all possible permutations.
- *
- * @param mixed ...$lists
- * @return static
- */
- public function crossJoin(...$lists);
-
- /**
- * Dump the collection and end the script.
- *
- * @param mixed ...$args
- * @return void
- */
- public function dd(...$args);
-
- /**
- * Dump the collection.
- *
- * @return $this
- */
- public function dump();
-
- /**
- * Get the items that are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diff($items);
-
- /**
- * Get the items that are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffUsing($items, callable $callback);
-
- /**
- * Get the items whose keys and values are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diffAssoc($items);
-
- /**
- * Get the items whose keys and values are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffAssocUsing($items, callable $callback);
-
- /**
- * Get the items whose keys are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diffKeys($items);
-
- /**
- * Get the items whose keys are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffKeysUsing($items, callable $callback);
-
- /**
- * Retrieve duplicate items.
- *
- * @param callable|string|null $callback
- * @param bool $strict
- * @return static
- */
- public function duplicates($callback = null, $strict = false);
-
- /**
- * Retrieve duplicate items using strict comparison.
- *
- * @param callable|string|null $callback
- * @return static
- */
- public function duplicatesStrict($callback = null);
-
- /**
- * Execute a callback over each item.
- *
- * @param callable $callback
- * @return $this
- */
- public function each(callable $callback);
-
- /**
- * Execute a callback over each nested chunk of items.
- *
- * @param callable $callback
- * @return static
- */
- public function eachSpread(callable $callback);
-
- /**
- * Determine if all items pass the given truth test.
- *
- * @param string|callable $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function every($key, $operator = null, $value = null);
-
- /**
- * Get all items except for those with the specified keys.
- *
- * @param mixed $keys
- * @return static
- */
- public function except($keys);
-
- /**
- * Run a filter over each of the items.
- *
- * @param callable|null $callback
- * @return static
- */
- public function filter(callable $callback = null);
-
- /**
- * Apply the callback if the value is truthy.
- *
- * @param bool $value
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function when($value, callable $callback, callable $default = null);
-
- /**
- * Apply the callback if the collection is empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function whenEmpty(callable $callback, callable $default = null);
-
- /**
- * Apply the callback if the collection is not empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function whenNotEmpty(callable $callback, callable $default = null);
-
- /**
- * Apply the callback if the value is falsy.
- *
- * @param bool $value
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function unless($value, callable $callback, callable $default = null);
-
- /**
- * Apply the callback unless the collection is empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function unlessEmpty(callable $callback, callable $default = null);
-
- /**
- * Apply the callback unless the collection is not empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function unlessNotEmpty(callable $callback, callable $default = null);
-
- /**
- * Filter items by the given key value pair.
- *
- * @param string $key
- * @param mixed $operator
- * @param mixed $value
- * @return static
- */
- public function where($key, $operator = null, $value = null);
-
- /**
- * Filter items where the value for the given key is null.
- *
- * @param string|null $key
- * @return static
- */
- public function whereNull($key = null);
-
- /**
- * Filter items where the value for the given key is not null.
- *
- * @param string|null $key
- * @return static
- */
- public function whereNotNull($key = null);
-
- /**
- * Filter items by the given key value pair using strict comparison.
- *
- * @param string $key
- * @param mixed $value
- * @return static
- */
- public function whereStrict($key, $value);
-
- /**
- * Filter items by the given key value pair.
- *
- * @param string $key
- * @param mixed $values
- * @param bool $strict
- * @return static
- */
- public function whereIn($key, $values, $strict = false);
-
- /**
- * Filter items by the given key value pair using strict comparison.
- *
- * @param string $key
- * @param mixed $values
- * @return static
- */
- public function whereInStrict($key, $values);
-
- /**
- * Filter items such that the value of the given key is between the given values.
- *
- * @param string $key
- * @param array $values
- * @return static
- */
- public function whereBetween($key, $values);
-
- /**
- * Filter items such that the value of the given key is not between the given values.
- *
- * @param string $key
- * @param array $values
- * @return static
- */
- public function whereNotBetween($key, $values);
-
- /**
- * Filter items by the given key value pair.
- *
- * @param string $key
- * @param mixed $values
- * @param bool $strict
- * @return static
- */
- public function whereNotIn($key, $values, $strict = false);
-
- /**
- * Filter items by the given key value pair using strict comparison.
- *
- * @param string $key
- * @param mixed $values
- * @return static
- */
- public function whereNotInStrict($key, $values);
-
- /**
- * Filter the items, removing any items that don't match the given type(s).
- *
- * @param string|string[] $type
- * @return static
- */
- public function whereInstanceOf($type);
-
- /**
- * Get the first item from the enumerable passing the given truth test.
- *
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public function first(callable $callback = null, $default = null);
-
- /**
- * Get the first item by the given key value pair.
- *
- * @param string $key
- * @param mixed $operator
- * @param mixed $value
- * @return mixed
- */
- public function firstWhere($key, $operator = null, $value = null);
-
- /**
- * Get a flattened array of the items in the collection.
- *
- * @param int $depth
- * @return static
- */
- public function flatten($depth = INF);
-
- /**
- * Flip the values with their keys.
- *
- * @return static
- */
- public function flip();
-
- /**
- * Get an item from the collection by key.
- *
- * @param mixed $key
- * @param mixed $default
- * @return mixed
- */
- public function get($key, $default = null);
-
- /**
- * Group an associative array by a field or using a callback.
- *
- * @param array|callable|string $groupBy
- * @param bool $preserveKeys
- * @return static
- */
- public function groupBy($groupBy, $preserveKeys = false);
-
- /**
- * Key an associative array by a field or using a callback.
- *
- * @param callable|string $keyBy
- * @return static
- */
- public function keyBy($keyBy);
-
- /**
- * Determine if an item exists in the collection by key.
- *
- * @param mixed $key
- * @return bool
- */
- public function has($key);
-
- /**
- * Concatenate values of a given key as a string.
- *
- * @param string $value
- * @param string|null $glue
- * @return string
- */
- public function implode($value, $glue = null);
-
- /**
- * Intersect the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function intersect($items);
-
- /**
- * Intersect the collection with the given items by key.
- *
- * @param mixed $items
- * @return static
- */
- public function intersectByKeys($items);
-
- /**
- * Determine if the collection is empty or not.
- *
- * @return bool
- */
- public function isEmpty();
-
- /**
- * Determine if the collection is not empty.
- *
- * @return bool
- */
- public function isNotEmpty();
-
- /**
- * Join all items from the collection using a string. The final items can use a separate glue string.
- *
- * @param string $glue
- * @param string $finalGlue
- * @return string
- */
- public function join($glue, $finalGlue = '');
-
- /**
- * Get the keys of the collection items.
- *
- * @return static
- */
- public function keys();
-
- /**
- * Get the last item from the collection.
- *
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public function last(callable $callback = null, $default = null);
-
- /**
- * Run a map over each of the items.
- *
- * @param callable $callback
- * @return static
- */
- public function map(callable $callback);
-
- /**
- * Run a map over each nested chunk of items.
- *
- * @param callable $callback
- * @return static
- */
- public function mapSpread(callable $callback);
-
- /**
- * Run a dictionary map over the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapToDictionary(callable $callback);
-
- /**
- * Run a grouping map over the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapToGroups(callable $callback);
-
- /**
- * Run an associative map over each of the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapWithKeys(callable $callback);
-
- /**
- * Map a collection and flatten the result by a single level.
- *
- * @param callable $callback
- * @return static
- */
- public function flatMap(callable $callback);
-
- /**
- * Map the values into a new class.
- *
- * @param string $class
- * @return static
- */
- public function mapInto($class);
-
- /**
- * Merge the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function merge($items);
-
- /**
- * Recursively merge the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function mergeRecursive($items);
-
- /**
- * Create a collection by using this collection for keys and another for its values.
- *
- * @param mixed $values
- * @return static
- */
- public function combine($values);
-
- /**
- * Union the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function union($items);
-
- /**
- * Get the min value of a given key.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function min($callback = null);
-
- /**
- * Get the max value of a given key.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function max($callback = null);
-
- /**
- * Create a new collection consisting of every n-th element.
- *
- * @param int $step
- * @param int $offset
- * @return static
- */
- public function nth($step, $offset = 0);
-
- /**
- * Get the items with the specified keys.
- *
- * @param mixed $keys
- * @return static
- */
- public function only($keys);
-
- /**
- * "Paginate" the collection by slicing it into a smaller collection.
- *
- * @param int $page
- * @param int $perPage
- * @return static
- */
- public function forPage($page, $perPage);
-
- /**
- * Partition the collection into two arrays using the given callback or key.
- *
- * @param callable|string $key
- * @param mixed $operator
- * @param mixed $value
- * @return static
- */
- public function partition($key, $operator = null, $value = null);
-
- /**
- * Push all of the given items onto the collection.
- *
- * @param iterable $source
- * @return static
- */
- public function concat($source);
-
- /**
- * Get one or a specified number of items randomly from the collection.
- *
- * @param int|null $number
- * @return static|mixed
- *
- * @throws \InvalidArgumentException
- */
- public function random($number = null);
-
- /**
- * Reduce the collection to a single value.
- *
- * @param callable $callback
- * @param mixed $initial
- * @return mixed
- */
- public function reduce(callable $callback, $initial = null);
-
- /**
- * Replace the collection items with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function replace($items);
-
- /**
- * Recursively replace the collection items with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function replaceRecursive($items);
-
- /**
- * Reverse items order.
- *
- * @return static
- */
- public function reverse();
-
- /**
- * Search the collection for a given value and return the corresponding key if successful.
- *
- * @param mixed $value
- * @param bool $strict
- * @return mixed
- */
- public function search($value, $strict = false);
-
- /**
- * Shuffle the items in the collection.
- *
- * @param int|null $seed
- * @return static
- */
- public function shuffle($seed = null);
-
- /**
- * Skip the first {$count} items.
- *
- * @param int $count
- * @return static
- */
- public function skip($count);
-
- /**
- * Skip items in the collection until the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function skipUntil($value);
-
- /**
- * Skip items in the collection while the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function skipWhile($value);
-
- /**
- * Get a slice of items from the enumerable.
- *
- * @param int $offset
- * @param int|null $length
- * @return static
- */
- public function slice($offset, $length = null);
-
- /**
- * Split a collection into a certain number of groups.
- *
- * @param int $numberOfGroups
- * @return static
- */
- public function split($numberOfGroups);
-
- /**
- * Chunk the collection into chunks of the given size.
- *
- * @param int $size
- * @return static
- */
- public function chunk($size);
-
- /**
- * Chunk the collection into chunks with a callback.
- *
- * @param callable $callback
- * @return static
- */
- public function chunkWhile(callable $callback);
-
- /**
- * Sort through each item with a callback.
- *
- * @param callable|null|int $callback
- * @return static
- */
- public function sort($callback = null);
-
- /**
- * Sort items in descending order.
- *
- * @param int $options
- * @return static
- */
- public function sortDesc($options = SORT_REGULAR);
-
- /**
- * Sort the collection using the given callback.
- *
- * @param callable|string $callback
- * @param int $options
- * @param bool $descending
- * @return static
- */
- public function sortBy($callback, $options = SORT_REGULAR, $descending = false);
-
- /**
- * Sort the collection in descending order using the given callback.
- *
- * @param callable|string $callback
- * @param int $options
- * @return static
- */
- public function sortByDesc($callback, $options = SORT_REGULAR);
-
- /**
- * Sort the collection keys.
- *
- * @param int $options
- * @param bool $descending
- * @return static
- */
- public function sortKeys($options = SORT_REGULAR, $descending = false);
-
- /**
- * Sort the collection keys in descending order.
- *
- * @param int $options
- * @return static
- */
- public function sortKeysDesc($options = SORT_REGULAR);
-
- /**
- * Get the sum of the given values.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function sum($callback = null);
-
- /**
- * Take the first or last {$limit} items.
- *
- * @param int $limit
- * @return static
- */
- public function take($limit);
-
- /**
- * Take items in the collection until the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function takeUntil($value);
-
- /**
- * Take items in the collection while the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function takeWhile($value);
-
- /**
- * Pass the collection to the given callback and then return it.
- *
- * @param callable $callback
- * @return $this
- */
- public function tap(callable $callback);
-
- /**
- * Pass the enumerable to the given callback and return the result.
- *
- * @param callable $callback
- * @return mixed
- */
- public function pipe(callable $callback);
-
- /**
- * Get the values of a given key.
- *
- * @param string|array $value
- * @param string|null $key
- * @return static
- */
- public function pluck($value, $key = null);
-
- /**
- * Create a collection of all elements that do not pass a given truth test.
- *
- * @param callable|mixed $callback
- * @return static
- */
- public function reject($callback = true);
-
- /**
- * Return only unique items from the collection array.
- *
- * @param string|callable|null $key
- * @param bool $strict
- * @return static
- */
- public function unique($key = null, $strict = false);
-
- /**
- * Return only unique items from the collection array using strict comparison.
- *
- * @param string|callable|null $key
- * @return static
- */
- public function uniqueStrict($key = null);
-
- /**
- * Reset the keys on the underlying array.
- *
- * @return static
- */
- public function values();
-
- /**
- * Pad collection to the specified length with a value.
- *
- * @param int $size
- * @param mixed $value
- * @return static
- */
- public function pad($size, $value);
-
- /**
- * Count the number of items in the collection using a given truth test.
- *
- * @param callable|null $callback
- * @return static
- */
- public function countBy($callback = null);
-
- /**
- * Zip the collection together with one or more arrays.
- *
- * e.g. new Collection([1, 2, 3])->zip([4, 5, 6]);
- * => [[1, 4], [2, 5], [3, 6]]
- *
- * @param mixed ...$items
- * @return static
- */
- public function zip($items);
-
- /**
- * Collect the values into a collection.
- *
- * @return \Tightenco\Collect\Support\Collection
- */
- public function collect();
-
- /**
- * Convert the collection to its string representation.
- *
- * @return string
- */
- public function __toString();
-
- /**
- * Add a method to the list of proxied methods.
- *
- * @param string $method
- * @return void
- */
- public static function proxy($method);
-
- /**
- * Dynamically access collection proxies.
- *
- * @param string $key
- * @return mixed
- *
- * @throws \Exception
- */
- public function __get($key);
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/HigherOrderCollectionProxy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/HigherOrderCollectionProxy.php
deleted file mode 100644
index 01ac43f..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/HigherOrderCollectionProxy.php
+++ /dev/null
@@ -1,63 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support;
-
-/**
- * @mixin \Tightenco\Collect\Support\Enumerable
- */
-class HigherOrderCollectionProxy
-{
- /**
- * The collection being operated on.
- *
- * @var \Tightenco\Collect\Support\Enumerable
- */
- protected $collection;
-
- /**
- * The method being proxied.
- *
- * @var string
- */
- protected $method;
-
- /**
- * Create a new proxy instance.
- *
- * @param \Tightenco\Collect\Support\Enumerable $collection
- * @param string $method
- * @return void
- */
- public function __construct(Enumerable $collection, $method)
- {
- $this->method = $method;
- $this->collection = $collection;
- }
-
- /**
- * Proxy accessing an attribute onto the collection items.
- *
- * @param string $key
- * @return mixed
- */
- public function __get($key)
- {
- return $this->collection->{$this->method}(function ($value) use ($key) {
- return is_array($value) ? $value[$key] : $value->{$key};
- });
- }
-
- /**
- * Proxy a method call onto the collection items.
- *
- * @param string $method
- * @param array $parameters
- * @return mixed
- */
- public function __call($method, $parameters)
- {
- return $this->collection->{$this->method}(function ($value) use ($method, $parameters) {
- return $value->{$method}(...$parameters);
- });
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/HigherOrderWhenProxy.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/HigherOrderWhenProxy.php
deleted file mode 100644
index ea48c7c..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/HigherOrderWhenProxy.php
+++ /dev/null
@@ -1,63 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support;
-
-/**
- * @mixin \Tightenco\Collect\Support\Enumerable
- */
-class HigherOrderWhenProxy
-{
- /**
- * The collection being operated on.
- *
- * @var \Tightenco\Collect\Support\Enumerable
- */
- protected $collection;
-
- /**
- * The condition for proxying.
- *
- * @var bool
- */
- protected $condition;
-
- /**
- * Create a new proxy instance.
- *
- * @param \Tightenco\Collect\Support\Enumerable $collection
- * @param bool $condition
- * @return void
- */
- public function __construct(Enumerable $collection, $condition)
- {
- $this->condition = $condition;
- $this->collection = $collection;
- }
-
- /**
- * Proxy accessing an attribute onto the collection.
- *
- * @param string $key
- * @return mixed
- */
- public function __get($key)
- {
- return $this->condition
- ? $this->collection->{$key}
- : $this->collection;
- }
-
- /**
- * Proxy a method call onto the collection.
- *
- * @param string $method
- * @param array $parameters
- * @return mixed
- */
- public function __call($method, $parameters)
- {
- return $this->condition
- ? $this->collection->{$method}(...$parameters)
- : $this->collection;
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/LazyCollection.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/LazyCollection.php
deleted file mode 100644
index 464cee1..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/LazyCollection.php
+++ /dev/null
@@ -1,1585 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support;
-
-use ArrayIterator;
-use Closure;
-use DateTimeInterface;
-use Tightenco\Collect\Contracts\Support\CanBeEscapedWhenCastToString;
-use Tightenco\Collect\Support\Traits\EnumeratesValues;
-use Tightenco\Collect\Support\Traits\Macroable;
-use IteratorAggregate;
-use stdClass;
-
-class LazyCollection implements CanBeEscapedWhenCastToString, Enumerable
-{
- use EnumeratesValues, Macroable;
-
- /**
- * The source from which to generate items.
- *
- * @var callable|static
- */
- public $source;
-
- /**
- * Create a new lazy collection instance.
- *
- * @param mixed $source
- * @return void
- */
- public function __construct($source = null)
- {
- if ($source instanceof Closure || $source instanceof self) {
- $this->source = $source;
- } elseif (is_null($source)) {
- $this->source = static::empty();
- } else {
- $this->source = $this->getArrayableItems($source);
- }
- }
-
- /**
- * Create a collection with the given range.
- *
- * @param int $from
- * @param int $to
- * @return static
- */
- public static function range($from, $to)
- {
- return new static(function () use ($from, $to) {
- if ($from <= $to) {
- for (; $from <= $to; $from++) {
- yield $from;
- }
- } else {
- for (; $from >= $to; $from--) {
- yield $from;
- }
- }
- });
- }
-
- /**
- * Get all items in the enumerable.
- *
- * @return array
- */
- public function all()
- {
- if (is_array($this->source)) {
- return $this->source;
- }
-
- return iterator_to_array($this->getIterator());
- }
-
- /**
- * Eager load all items into a new lazy collection backed by an array.
- *
- * @return static
- */
- public function eager()
- {
- return new static($this->all());
- }
-
- /**
- * Cache values as they're enumerated.
- *
- * @return static
- */
- public function remember()
- {
- $iterator = $this->getIterator();
-
- $iteratorIndex = 0;
-
- $cache = [];
-
- return new static(function () use ($iterator, &$iteratorIndex, &$cache) {
- for ($index = 0; true; $index++) {
- if (array_key_exists($index, $cache)) {
- yield $cache[$index][0] => $cache[$index][1];
-
- continue;
- }
-
- if ($iteratorIndex < $index) {
- $iterator->next();
-
- $iteratorIndex++;
- }
-
- if (! $iterator->valid()) {
- break;
- }
-
- $cache[$index] = [$iterator->key(), $iterator->current()];
-
- yield $cache[$index][0] => $cache[$index][1];
- }
- });
- }
-
- /**
- * Get the average value of a given key.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function avg($callback = null)
- {
- return $this->collect()->avg($callback);
- }
-
- /**
- * Get the median of a given key.
- *
- * @param string|array|null $key
- * @return mixed
- */
- public function median($key = null)
- {
- return $this->collect()->median($key);
- }
-
- /**
- * Get the mode of a given key.
- *
- * @param string|array|null $key
- * @return array|null
- */
- public function mode($key = null)
- {
- return $this->collect()->mode($key);
- }
-
- /**
- * Collapse the collection of items into a single array.
- *
- * @return static
- */
- public function collapse()
- {
- return new static(function () {
- foreach ($this as $values) {
- if (is_array($values) || $values instanceof Enumerable) {
- foreach ($values as $value) {
- yield $value;
- }
- }
- }
- });
- }
-
- /**
- * Determine if an item exists in the enumerable.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function contains($key, $operator = null, $value = null)
- {
- if (func_num_args() === 1 && $this->useAsCallable($key)) {
- $placeholder = new stdClass;
-
- return $this->first($key, $placeholder) !== $placeholder;
- }
-
- if (func_num_args() === 1) {
- $needle = $key;
-
- foreach ($this as $value) {
- if ($value == $needle) {
- return true;
- }
- }
-
- return false;
- }
-
- return $this->contains($this->operatorForWhere(...func_get_args()));
- }
-
- /**
- * Determine if an item is not contained in the enumerable.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function doesntContain($key, $operator = null, $value = null)
- {
- return ! $this->contains(...func_get_args());
- }
-
- /**
- * Cross join the given iterables, returning all possible permutations.
- *
- * @param array ...$arrays
- * @return static
- */
- public function crossJoin(...$arrays)
- {
- return $this->passthru('crossJoin', func_get_args());
- }
-
- /**
- * Count the number of items in the collection by a field or using a callback.
- *
- * @param callable|string $countBy
- * @return static
- */
- public function countBy($countBy = null)
- {
- $countBy = is_null($countBy)
- ? $this->identity()
- : $this->valueRetriever($countBy);
-
- return new static(function () use ($countBy) {
- $counts = [];
-
- foreach ($this as $key => $value) {
- $group = $countBy($value, $key);
-
- if (empty($counts[$group])) {
- $counts[$group] = 0;
- }
-
- $counts[$group]++;
- }
-
- yield from $counts;
- });
- }
-
- /**
- * Get the items that are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diff($items)
- {
- return $this->passthru('diff', func_get_args());
- }
-
- /**
- * Get the items that are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffUsing($items, callable $callback)
- {
- return $this->passthru('diffUsing', func_get_args());
- }
-
- /**
- * Get the items whose keys and values are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diffAssoc($items)
- {
- return $this->passthru('diffAssoc', func_get_args());
- }
-
- /**
- * Get the items whose keys and values are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffAssocUsing($items, callable $callback)
- {
- return $this->passthru('diffAssocUsing', func_get_args());
- }
-
- /**
- * Get the items whose keys are not present in the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function diffKeys($items)
- {
- return $this->passthru('diffKeys', func_get_args());
- }
-
- /**
- * Get the items whose keys are not present in the given items, using the callback.
- *
- * @param mixed $items
- * @param callable $callback
- * @return static
- */
- public function diffKeysUsing($items, callable $callback)
- {
- return $this->passthru('diffKeysUsing', func_get_args());
- }
-
- /**
- * Retrieve duplicate items.
- *
- * @param callable|string|null $callback
- * @param bool $strict
- * @return static
- */
- public function duplicates($callback = null, $strict = false)
- {
- return $this->passthru('duplicates', func_get_args());
- }
-
- /**
- * Retrieve duplicate items using strict comparison.
- *
- * @param callable|string|null $callback
- * @return static
- */
- public function duplicatesStrict($callback = null)
- {
- return $this->passthru('duplicatesStrict', func_get_args());
- }
-
- /**
- * Get all items except for those with the specified keys.
- *
- * @param mixed $keys
- * @return static
- */
- public function except($keys)
- {
- return $this->passthru('except', func_get_args());
- }
-
- /**
- * Run a filter over each of the items.
- *
- * @param callable|null $callback
- * @return static
- */
- public function filter(callable $callback = null)
- {
- if (is_null($callback)) {
- $callback = function ($value) {
- return (bool) $value;
- };
- }
-
- return new static(function () use ($callback) {
- foreach ($this as $key => $value) {
- if ($callback($value, $key)) {
- yield $key => $value;
- }
- }
- });
- }
-
- /**
- * Get the first item from the enumerable passing the given truth test.
- *
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public function first(callable $callback = null, $default = null)
- {
- $iterator = $this->getIterator();
-
- if (is_null($callback)) {
- if (! $iterator->valid()) {
- return value($default);
- }
-
- return $iterator->current();
- }
-
- foreach ($iterator as $key => $value) {
- if ($callback($value, $key)) {
- return $value;
- }
- }
-
- return value($default);
- }
-
- /**
- * Get a flattened list of the items in the collection.
- *
- * @param int $depth
- * @return static
- */
- public function flatten($depth = INF)
- {
- $instance = new static(function () use ($depth) {
- foreach ($this as $item) {
- if (! is_array($item) && ! $item instanceof Enumerable) {
- yield $item;
- } elseif ($depth === 1) {
- yield from $item;
- } else {
- yield from (new static($item))->flatten($depth - 1);
- }
- }
- });
-
- return $instance->values();
- }
-
- /**
- * Flip the items in the collection.
- *
- * @return static
- */
- public function flip()
- {
- return new static(function () {
- foreach ($this as $key => $value) {
- yield $value => $key;
- }
- });
- }
-
- /**
- * Get an item by key.
- *
- * @param mixed $key
- * @param mixed $default
- * @return mixed
- */
- public function get($key, $default = null)
- {
- if (is_null($key)) {
- return;
- }
-
- foreach ($this as $outerKey => $outerValue) {
- if ($outerKey == $key) {
- return $outerValue;
- }
- }
-
- return value($default);
- }
-
- /**
- * Group an associative array by a field or using a callback.
- *
- * @param array|callable|string $groupBy
- * @param bool $preserveKeys
- * @return static
- */
- public function groupBy($groupBy, $preserveKeys = false)
- {
- return $this->passthru('groupBy', func_get_args());
- }
-
- /**
- * Key an associative array by a field or using a callback.
- *
- * @param callable|string $keyBy
- * @return static
- */
- public function keyBy($keyBy)
- {
- return new static(function () use ($keyBy) {
- $keyBy = $this->valueRetriever($keyBy);
-
- foreach ($this as $key => $item) {
- $resolvedKey = $keyBy($item, $key);
-
- if (is_object($resolvedKey)) {
- $resolvedKey = (string) $resolvedKey;
- }
-
- yield $resolvedKey => $item;
- }
- });
- }
-
- /**
- * Determine if an item exists in the collection by key.
- *
- * @param mixed $key
- * @return bool
- */
- public function has($key)
- {
- $keys = array_flip(is_array($key) ? $key : func_get_args());
- $count = count($keys);
-
- foreach ($this as $key => $value) {
- if (array_key_exists($key, $keys) && --$count == 0) {
- return true;
- }
- }
-
- return false;
- }
-
- /**
- * Determine if any of the keys exist in the collection.
- *
- * @param mixed $key
- * @return bool
- */
- public function hasAny($key)
- {
- $keys = array_flip(is_array($key) ? $key : func_get_args());
-
- foreach ($this as $key => $value) {
- if (array_key_exists($key, $keys)) {
- return true;
- }
- }
-
- return false;
- }
-
- /**
- * Concatenate values of a given key as a string.
- *
- * @param string $value
- * @param string|null $glue
- * @return string
- */
- public function implode($value, $glue = null)
- {
- return $this->collect()->implode(...func_get_args());
- }
-
- /**
- * Intersect the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function intersect($items)
- {
- return $this->passthru('intersect', func_get_args());
- }
-
- /**
- * Intersect the collection with the given items by key.
- *
- * @param mixed $items
- * @return static
- */
- public function intersectByKeys($items)
- {
- return $this->passthru('intersectByKeys', func_get_args());
- }
-
- /**
- * Determine if the items are empty or not.
- *
- * @return bool
- */
- public function isEmpty()
- {
- return ! $this->getIterator()->valid();
- }
-
- /**
- * Determine if the collection contains a single item.
- *
- * @return bool
- */
- public function containsOneItem()
- {
- return $this->take(2)->count() === 1;
- }
-
- /**
- * Join all items from the collection using a string. The final items can use a separate glue string.
- *
- * @param string $glue
- * @param string $finalGlue
- * @return string
- */
- public function join($glue, $finalGlue = '')
- {
- return $this->collect()->join(...func_get_args());
- }
-
- /**
- * Get the keys of the collection items.
- *
- * @return static
- */
- public function keys()
- {
- return new static(function () {
- foreach ($this as $key => $value) {
- yield $key;
- }
- });
- }
-
- /**
- * Get the last item from the collection.
- *
- * @param callable|null $callback
- * @param mixed $default
- * @return mixed
- */
- public function last(callable $callback = null, $default = null)
- {
- $needle = $placeholder = new stdClass;
-
- foreach ($this as $key => $value) {
- if (is_null($callback) || $callback($value, $key)) {
- $needle = $value;
- }
- }
-
- return $needle === $placeholder ? value($default) : $needle;
- }
-
- /**
- * Get the values of a given key.
- *
- * @param string|array $value
- * @param string|null $key
- * @return static
- */
- public function pluck($value, $key = null)
- {
- return new static(function () use ($value, $key) {
- [$value, $key] = $this->explodePluckParameters($value, $key);
-
- foreach ($this as $item) {
- $itemValue = data_get($item, $value);
-
- if (is_null($key)) {
- yield $itemValue;
- } else {
- $itemKey = data_get($item, $key);
-
- if (is_object($itemKey) && method_exists($itemKey, '__toString')) {
- $itemKey = (string) $itemKey;
- }
-
- yield $itemKey => $itemValue;
- }
- }
- });
- }
-
- /**
- * Run a map over each of the items.
- *
- * @param callable $callback
- * @return static
- */
- public function map(callable $callback)
- {
- return new static(function () use ($callback) {
- foreach ($this as $key => $value) {
- yield $key => $callback($value, $key);
- }
- });
- }
-
- /**
- * Run a dictionary map over the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapToDictionary(callable $callback)
- {
- return $this->passthru('mapToDictionary', func_get_args());
- }
-
- /**
- * Run an associative map over each of the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapWithKeys(callable $callback)
- {
- return new static(function () use ($callback) {
- foreach ($this as $key => $value) {
- yield from $callback($value, $key);
- }
- });
- }
-
- /**
- * Merge the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function merge($items)
- {
- return $this->passthru('merge', func_get_args());
- }
-
- /**
- * Recursively merge the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function mergeRecursive($items)
- {
- return $this->passthru('mergeRecursive', func_get_args());
- }
-
- /**
- * Create a collection by using this collection for keys and another for its values.
- *
- * @param mixed $values
- * @return static
- */
- public function combine($values)
- {
- return new static(function () use ($values) {
- $values = $this->makeIterator($values);
-
- $errorMessage = 'Both parameters should have an equal number of elements';
-
- foreach ($this as $key) {
- if (! $values->valid()) {
- trigger_error($errorMessage, E_USER_WARNING);
-
- break;
- }
-
- yield $key => $values->current();
-
- $values->next();
- }
-
- if ($values->valid()) {
- trigger_error($errorMessage, E_USER_WARNING);
- }
- });
- }
-
- /**
- * Union the collection with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function union($items)
- {
- return $this->passthru('union', func_get_args());
- }
-
- /**
- * Create a new collection consisting of every n-th element.
- *
- * @param int $step
- * @param int $offset
- * @return static
- */
- public function nth($step, $offset = 0)
- {
- return new static(function () use ($step, $offset) {
- $position = 0;
-
- foreach ($this as $item) {
- if ($position % $step === $offset) {
- yield $item;
- }
-
- $position++;
- }
- });
- }
-
- /**
- * Get the items with the specified keys.
- *
- * @param mixed $keys
- * @return static
- */
- public function only($keys)
- {
- if ($keys instanceof Enumerable) {
- $keys = $keys->all();
- } elseif (! is_null($keys)) {
- $keys = is_array($keys) ? $keys : func_get_args();
- }
-
- return new static(function () use ($keys) {
- if (is_null($keys)) {
- yield from $this;
- } else {
- $keys = array_flip($keys);
-
- foreach ($this as $key => $value) {
- if (array_key_exists($key, $keys)) {
- yield $key => $value;
-
- unset($keys[$key]);
-
- if (empty($keys)) {
- break;
- }
- }
- }
- }
- });
- }
-
- /**
- * Push all of the given items onto the collection.
- *
- * @param iterable $source
- * @return static
- */
- public function concat($source)
- {
- return (new static(function () use ($source) {
- yield from $this;
- yield from $source;
- }))->values();
- }
-
- /**
- * Get one or a specified number of items randomly from the collection.
- *
- * @param int|null $number
- * @return static|mixed
- *
- * @throws \InvalidArgumentException
- */
- public function random($number = null)
- {
- $result = $this->collect()->random(...func_get_args());
-
- return is_null($number) ? $result : new static($result);
- }
-
- /**
- * Replace the collection items with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function replace($items)
- {
- return new static(function () use ($items) {
- $items = $this->getArrayableItems($items);
-
- foreach ($this as $key => $value) {
- if (array_key_exists($key, $items)) {
- yield $key => $items[$key];
-
- unset($items[$key]);
- } else {
- yield $key => $value;
- }
- }
-
- foreach ($items as $key => $value) {
- yield $key => $value;
- }
- });
- }
-
- /**
- * Recursively replace the collection items with the given items.
- *
- * @param mixed $items
- * @return static
- */
- public function replaceRecursive($items)
- {
- return $this->passthru('replaceRecursive', func_get_args());
- }
-
- /**
- * Reverse items order.
- *
- * @return static
- */
- public function reverse()
- {
- return $this->passthru('reverse', func_get_args());
- }
-
- /**
- * Search the collection for a given value and return the corresponding key if successful.
- *
- * @param mixed $value
- * @param bool $strict
- * @return mixed
- */
- public function search($value, $strict = false)
- {
- $predicate = $this->useAsCallable($value)
- ? $value
- : function ($item) use ($value, $strict) {
- return $strict ? $item === $value : $item == $value;
- };
-
- foreach ($this as $key => $item) {
- if ($predicate($item, $key)) {
- return $key;
- }
- }
-
- return false;
- }
-
- /**
- * Shuffle the items in the collection.
- *
- * @param int|null $seed
- * @return static
- */
- public function shuffle($seed = null)
- {
- return $this->passthru('shuffle', func_get_args());
- }
-
- /**
- * Create chunks representing a "sliding window" view of the items in the collection.
- *
- * @param int $size
- * @param int $step
- * @return static
- */
- public function sliding($size = 2, $step = 1)
- {
- return new static(function () use ($size, $step) {
- $iterator = $this->getIterator();
-
- $chunk = [];
-
- while ($iterator->valid()) {
- $chunk[$iterator->key()] = $iterator->current();
-
- if (count($chunk) == $size) {
- yield tap(new static($chunk), function () use (&$chunk, $step) {
- $chunk = array_slice($chunk, $step, null, true);
- });
-
- // If the $step between chunks is bigger than each chunk's $size
- // we will skip the extra items (which should never be in any
- // chunk) before we continue to the next chunk in the loop.
- if ($step > $size) {
- $skip = $step - $size;
-
- for ($i = 0; $i < $skip && $iterator->valid(); $i++) {
- $iterator->next();
- }
- }
- }
-
- $iterator->next();
- }
- });
- }
-
- /**
- * Skip the first {$count} items.
- *
- * @param int $count
- * @return static
- */
- public function skip($count)
- {
- return new static(function () use ($count) {
- $iterator = $this->getIterator();
-
- while ($iterator->valid() && $count--) {
- $iterator->next();
- }
-
- while ($iterator->valid()) {
- yield $iterator->key() => $iterator->current();
-
- $iterator->next();
- }
- });
- }
-
- /**
- * Skip items in the collection until the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function skipUntil($value)
- {
- $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
-
- return $this->skipWhile($this->negate($callback));
- }
-
- /**
- * Skip items in the collection while the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function skipWhile($value)
- {
- $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
-
- return new static(function () use ($callback) {
- $iterator = $this->getIterator();
-
- while ($iterator->valid() && $callback($iterator->current(), $iterator->key())) {
- $iterator->next();
- }
-
- while ($iterator->valid()) {
- yield $iterator->key() => $iterator->current();
-
- $iterator->next();
- }
- });
- }
-
- /**
- * Get a slice of items from the enumerable.
- *
- * @param int $offset
- * @param int|null $length
- * @return static
- */
- public function slice($offset, $length = null)
- {
- if ($offset < 0 || $length < 0) {
- return $this->passthru('slice', func_get_args());
- }
-
- $instance = $this->skip($offset);
-
- return is_null($length) ? $instance : $instance->take($length);
- }
-
- /**
- * Split a collection into a certain number of groups.
- *
- * @param int $numberOfGroups
- * @return static
- */
- public function split($numberOfGroups)
- {
- return $this->passthru('split', func_get_args());
- }
-
- /**
- * Get the first item in the collection, but only if exactly one item exists. Otherwise, throw an exception.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return mixed
- *
- * @throws \Tightenco\Collect\Support\ItemNotFoundException
- * @throws \Tightenco\Collect\Support\MultipleItemsFoundException
- */
- public function sole($key = null, $operator = null, $value = null)
- {
- $filter = func_num_args() > 1
- ? $this->operatorForWhere(...func_get_args())
- : $key;
-
- return $this
- ->when($filter)
- ->filter($filter)
- ->take(2)
- ->collect()
- ->sole();
- }
-
- /**
- * Get the first item in the collection but throw an exception if no matching items exist.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return mixed
- *
- * @throws \Tightenco\Collect\Support\ItemNotFoundException
- */
- public function firstOrFail($key = null, $operator = null, $value = null)
- {
- $filter = func_num_args() > 1
- ? $this->operatorForWhere(...func_get_args())
- : $key;
-
- return $this
- ->when($filter)
- ->filter($filter)
- ->take(1)
- ->collect()
- ->firstOrFail();
- }
-
- /**
- * Chunk the collection into chunks of the given size.
- *
- * @param int $size
- * @return static
- */
- public function chunk($size)
- {
- if ($size <= 0) {
- return static::empty();
- }
-
- return new static(function () use ($size) {
- $iterator = $this->getIterator();
-
- while ($iterator->valid()) {
- $chunk = [];
-
- while (true) {
- $chunk[$iterator->key()] = $iterator->current();
-
- if (count($chunk) < $size) {
- $iterator->next();
-
- if (! $iterator->valid()) {
- break;
- }
- } else {
- break;
- }
- }
-
- yield new static($chunk);
-
- $iterator->next();
- }
- });
- }
-
- /**
- * Split a collection into a certain number of groups, and fill the first groups completely.
- *
- * @param int $numberOfGroups
- * @return static
- */
- public function splitIn($numberOfGroups)
- {
- return $this->chunk(ceil($this->count() / $numberOfGroups));
- }
-
- /**
- * Chunk the collection into chunks with a callback.
- *
- * @param callable $callback
- * @return static
- */
- public function chunkWhile(callable $callback)
- {
- return new static(function () use ($callback) {
- $iterator = $this->getIterator();
-
- $chunk = new Collection;
-
- if ($iterator->valid()) {
- $chunk[$iterator->key()] = $iterator->current();
-
- $iterator->next();
- }
-
- while ($iterator->valid()) {
- if (! $callback($iterator->current(), $iterator->key(), $chunk)) {
- yield new static($chunk);
-
- $chunk = new Collection;
- }
-
- $chunk[$iterator->key()] = $iterator->current();
-
- $iterator->next();
- }
-
- if ($chunk->isNotEmpty()) {
- yield new static($chunk);
- }
- });
- }
-
- /**
- * Sort through each item with a callback.
- *
- * @param callable|null|int $callback
- * @return static
- */
- public function sort($callback = null)
- {
- return $this->passthru('sort', func_get_args());
- }
-
- /**
- * Sort items in descending order.
- *
- * @param int $options
- * @return static
- */
- public function sortDesc($options = SORT_REGULAR)
- {
- return $this->passthru('sortDesc', func_get_args());
- }
-
- /**
- * Sort the collection using the given callback.
- *
- * @param callable|string $callback
- * @param int $options
- * @param bool $descending
- * @return static
- */
- public function sortBy($callback, $options = SORT_REGULAR, $descending = false)
- {
- return $this->passthru('sortBy', func_get_args());
- }
-
- /**
- * Sort the collection in descending order using the given callback.
- *
- * @param callable|string $callback
- * @param int $options
- * @return static
- */
- public function sortByDesc($callback, $options = SORT_REGULAR)
- {
- return $this->passthru('sortByDesc', func_get_args());
- }
-
- /**
- * Sort the collection keys.
- *
- * @param int $options
- * @param bool $descending
- * @return static
- */
- public function sortKeys($options = SORT_REGULAR, $descending = false)
- {
- return $this->passthru('sortKeys', func_get_args());
- }
-
- /**
- * Sort the collection keys in descending order.
- *
- * @param int $options
- * @return static
- */
- public function sortKeysDesc($options = SORT_REGULAR)
- {
- return $this->passthru('sortKeysDesc', func_get_args());
- }
-
- /**
- * Sort the collection keys using a callback.
- *
- * @param callable $callback
- * @return static
- */
- public function sortKeysUsing(callable $callback)
- {
- return $this->passthru('sortKeysUsing', func_get_args());
- }
-
- /**
- * Take the first or last {$limit} items.
- *
- * @param int $limit
- * @return static
- */
- public function take($limit)
- {
- if ($limit < 0) {
- return $this->passthru('take', func_get_args());
- }
-
- return new static(function () use ($limit) {
- $iterator = $this->getIterator();
-
- while ($limit--) {
- if (! $iterator->valid()) {
- break;
- }
-
- yield $iterator->key() => $iterator->current();
-
- if ($limit) {
- $iterator->next();
- }
- }
- });
- }
-
- /**
- * Take items in the collection until the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function takeUntil($value)
- {
- $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
-
- return new static(function () use ($callback) {
- foreach ($this as $key => $item) {
- if ($callback($item, $key)) {
- break;
- }
-
- yield $key => $item;
- }
- });
- }
-
- /**
- * Take items in the collection until a given point in time.
- *
- * @param \DateTimeInterface $timeout
- * @return static
- */
- public function takeUntilTimeout(DateTimeInterface $timeout)
- {
- $timeout = $timeout->getTimestamp();
-
- return $this->takeWhile(function () use ($timeout) {
- return $this->now() < $timeout;
- });
- }
-
- /**
- * Take items in the collection while the given condition is met.
- *
- * @param mixed $value
- * @return static
- */
- public function takeWhile($value)
- {
- $callback = $this->useAsCallable($value) ? $value : $this->equality($value);
-
- return $this->takeUntil(function ($item, $key) use ($callback) {
- return ! $callback($item, $key);
- });
- }
-
- /**
- * Pass each item in the collection to the given callback, lazily.
- *
- * @param callable $callback
- * @return static
- */
- public function tapEach(callable $callback)
- {
- return new static(function () use ($callback) {
- foreach ($this as $key => $value) {
- $callback($value, $key);
-
- yield $key => $value;
- }
- });
- }
-
- /**
- * Convert a flatten "dot" notation array into an expanded array.
- *
- * @return static
- */
- public function undot()
- {
- return $this->passthru('undot', []);
- }
-
- /**
- * Return only unique items from the collection array.
- *
- * @param string|callable|null $key
- * @param bool $strict
- * @return static
- */
- public function unique($key = null, $strict = false)
- {
- $callback = $this->valueRetriever($key);
-
- return new static(function () use ($callback, $strict) {
- $exists = [];
-
- foreach ($this as $key => $item) {
- if (! in_array($id = $callback($item, $key), $exists, $strict)) {
- yield $key => $item;
-
- $exists[] = $id;
- }
- }
- });
- }
-
- /**
- * Reset the keys on the underlying array.
- *
- * @return static
- */
- public function values()
- {
- return new static(function () {
- foreach ($this as $item) {
- yield $item;
- }
- });
- }
-
- /**
- * Zip the collection together with one or more arrays.
- *
- * e.g. new LazyCollection([1, 2, 3])->zip([4, 5, 6]);
- * => [[1, 4], [2, 5], [3, 6]]
- *
- * @param mixed ...$items
- * @return static
- */
- public function zip($items)
- {
- $iterables = func_get_args();
-
- return new static(function () use ($iterables) {
- $iterators = Collection::make($iterables)->map(function ($iterable) {
- return $this->makeIterator($iterable);
- })->prepend($this->getIterator());
-
- while ($iterators->contains->valid()) {
- yield new static($iterators->map->current());
-
- $iterators->each->next();
- }
- });
- }
-
- /**
- * Pad collection to the specified length with a value.
- *
- * @param int $size
- * @param mixed $value
- * @return static
- */
- public function pad($size, $value)
- {
- if ($size < 0) {
- return $this->passthru('pad', func_get_args());
- }
-
- return new static(function () use ($size, $value) {
- $yielded = 0;
-
- foreach ($this as $index => $item) {
- yield $index => $item;
-
- $yielded++;
- }
-
- while ($yielded++ < $size) {
- yield $value;
- }
- });
- }
-
- /**
- * Get the values iterator.
- *
- * @return \Traversable
- */
- #[\ReturnTypeWillChange]
- public function getIterator()
- {
- return $this->makeIterator($this->source);
- }
-
- /**
- * Count the number of items in the collection.
- *
- * @return int
- */
- #[\ReturnTypeWillChange]
- public function count()
- {
- if (is_array($this->source)) {
- return count($this->source);
- }
-
- return iterator_count($this->getIterator());
- }
-
- /**
- * Make an iterator from the given source.
- *
- * @param mixed $source
- * @return \Traversable
- */
- protected function makeIterator($source)
- {
- if ($source instanceof IteratorAggregate) {
- return $source->getIterator();
- }
-
- if (is_array($source)) {
- return new ArrayIterator($source);
- }
-
- return $source();
- }
-
- /**
- * Explode the "value" and "key" arguments passed to "pluck".
- *
- * @param string|array $value
- * @param string|array|null $key
- * @return array
- */
- protected function explodePluckParameters($value, $key)
- {
- $value = is_string($value) ? explode('.', $value) : $value;
-
- $key = is_null($key) || is_array($key) ? $key : explode('.', $key);
-
- return [$value, $key];
- }
-
- /**
- * Pass this lazy collection through a method on the collection class.
- *
- * @param string $method
- * @param array $params
- * @return static
- */
- protected function passthru($method, array $params)
- {
- return new static(function () use ($method, $params) {
- yield from $this->collect()->$method(...$params);
- });
- }
-
- /**
- * Get the current time.
- *
- * @return int
- */
- protected function now()
- {
- return time();
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/EnumeratesValues.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/EnumeratesValues.php
deleted file mode 100644
index 2600a22..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/EnumeratesValues.php
+++ /dev/null
@@ -1,1113 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support\Traits;
-
-use CachingIterator;
-use Closure;
-use Exception;
-use Tightenco\Collect\Contracts\Support\Arrayable;
-use Tightenco\Collect\Contracts\Support\Jsonable;
-use Tightenco\Collect\Support\Arr;
-use Tightenco\Collect\Support\Collection;
-use Tightenco\Collect\Support\Enumerable;
-use Tightenco\Collect\Support\HigherOrderCollectionProxy;
-use Tightenco\Collect\Support\HigherOrderWhenProxy;
-use JsonSerializable;
-use Symfony\Component\VarDumper\VarDumper;
-use Traversable;
-use UnexpectedValueException;
-
-/**
- * @property-read HigherOrderCollectionProxy $average
- * @property-read HigherOrderCollectionProxy $avg
- * @property-read HigherOrderCollectionProxy $contains
- * @property-read HigherOrderCollectionProxy $doesntContain
- * @property-read HigherOrderCollectionProxy $each
- * @property-read HigherOrderCollectionProxy $every
- * @property-read HigherOrderCollectionProxy $filter
- * @property-read HigherOrderCollectionProxy $first
- * @property-read HigherOrderCollectionProxy $flatMap
- * @property-read HigherOrderCollectionProxy $groupBy
- * @property-read HigherOrderCollectionProxy $keyBy
- * @property-read HigherOrderCollectionProxy $map
- * @property-read HigherOrderCollectionProxy $max
- * @property-read HigherOrderCollectionProxy $min
- * @property-read HigherOrderCollectionProxy $partition
- * @property-read HigherOrderCollectionProxy $reject
- * @property-read HigherOrderCollectionProxy $some
- * @property-read HigherOrderCollectionProxy $sortBy
- * @property-read HigherOrderCollectionProxy $sortByDesc
- * @property-read HigherOrderCollectionProxy $skipUntil
- * @property-read HigherOrderCollectionProxy $skipWhile
- * @property-read HigherOrderCollectionProxy $sum
- * @property-read HigherOrderCollectionProxy $takeUntil
- * @property-read HigherOrderCollectionProxy $takeWhile
- * @property-read HigherOrderCollectionProxy $unique
- * @property-read HigherOrderCollectionProxy $until
- */
-trait EnumeratesValues
-{
- /**
- * Indicates that the object's string representation should be escaped when __toString is invoked.
- *
- * @var bool
- */
- protected $escapeWhenCastingToString = false;
-
- /**
- * The methods that can be proxied.
- *
- * @var string[]
- */
- protected static $proxies = [
- 'average',
- 'avg',
- 'contains',
- 'doesntContain',
- 'each',
- 'every',
- 'filter',
- 'first',
- 'flatMap',
- 'groupBy',
- 'keyBy',
- 'map',
- 'max',
- 'min',
- 'partition',
- 'reject',
- 'skipUntil',
- 'skipWhile',
- 'some',
- 'sortBy',
- 'sortByDesc',
- 'sum',
- 'takeUntil',
- 'takeWhile',
- 'unique',
- 'until',
- ];
-
- /**
- * Create a new collection instance if the value isn't one already.
- *
- * @param mixed $items
- * @return static
- */
- public static function make($items = [])
- {
- return new static($items);
- }
-
- /**
- * Wrap the given value in a collection if applicable.
- *
- * @param mixed $value
- * @return static
- */
- public static function wrap($value)
- {
- return $value instanceof Enumerable
- ? new static($value)
- : new static(Arr::wrap($value));
- }
-
- /**
- * Get the underlying items from the given collection if applicable.
- *
- * @param array|static $value
- * @return array
- */
- public static function unwrap($value)
- {
- return $value instanceof Enumerable ? $value->all() : $value;
- }
-
- /**
- * Create a new instance with no items.
- *
- * @return static
- */
- public static function empty()
- {
- return new static([]);
- }
-
- /**
- * Create a new collection by invoking the callback a given amount of times.
- *
- * @param int $number
- * @param callable|null $callback
- * @return static
- */
- public static function times($number, callable $callback = null)
- {
- if ($number < 1) {
- return new static;
- }
-
- return static::range(1, $number)
- ->when($callback)
- ->map($callback);
- }
-
- /**
- * Alias for the "avg" method.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function average($callback = null)
- {
- return $this->avg($callback);
- }
-
- /**
- * Alias for the "contains" method.
- *
- * @param mixed $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function some($key, $operator = null, $value = null)
- {
- return $this->contains(...func_get_args());
- }
-
- /**
- * Determine if an item exists, using strict comparison.
- *
- * @param mixed $key
- * @param mixed $value
- * @return bool
- */
- public function containsStrict($key, $value = null)
- {
- if (func_num_args() === 2) {
- return $this->contains(function ($item) use ($key, $value) {
- return data_get($item, $key) === $value;
- });
- }
-
- if ($this->useAsCallable($key)) {
- return ! is_null($this->first($key));
- }
-
- foreach ($this as $item) {
- if ($item === $key) {
- return true;
- }
- }
-
- return false;
- }
-
- /**
- * Dump the items and end the script.
- *
- * @param mixed ...$args
- * @return void
- */
- public function dd(...$args)
- {
- $this->dump(...$args);
-
- exit(1);
- }
-
- /**
- * Dump the items.
- *
- * @return $this
- */
- public function dump()
- {
- (new Collection(func_get_args()))
- ->push($this->all())
- ->each(function ($item) {
- VarDumper::dump($item);
- });
-
- return $this;
- }
-
- /**
- * Execute a callback over each item.
- *
- * @param callable $callback
- * @return $this
- */
- public function each(callable $callback)
- {
- foreach ($this as $key => $item) {
- if ($callback($item, $key) === false) {
- break;
- }
- }
-
- return $this;
- }
-
- /**
- * Execute a callback over each nested chunk of items.
- *
- * @param callable $callback
- * @return static
- */
- public function eachSpread(callable $callback)
- {
- return $this->each(function ($chunk, $key) use ($callback) {
- $chunk[] = $key;
-
- return $callback(...$chunk);
- });
- }
-
- /**
- * Determine if all items pass the given truth test.
- *
- * @param string|callable $key
- * @param mixed $operator
- * @param mixed $value
- * @return bool
- */
- public function every($key, $operator = null, $value = null)
- {
- if (func_num_args() === 1) {
- $callback = $this->valueRetriever($key);
-
- foreach ($this as $k => $v) {
- if (! $callback($v, $k)) {
- return false;
- }
- }
-
- return true;
- }
-
- return $this->every($this->operatorForWhere(...func_get_args()));
- }
-
- /**
- * Get the first item by the given key value pair.
- *
- * @param string $key
- * @param mixed $operator
- * @param mixed $value
- * @return mixed
- */
- public function firstWhere($key, $operator = null, $value = null)
- {
- return $this->first($this->operatorForWhere(...func_get_args()));
- }
-
- /**
- * Determine if the collection is not empty.
- *
- * @return bool
- */
- public function isNotEmpty()
- {
- return ! $this->isEmpty();
- }
-
- /**
- * Run a map over each nested chunk of items.
- *
- * @param callable $callback
- * @return static
- */
- public function mapSpread(callable $callback)
- {
- return $this->map(function ($chunk, $key) use ($callback) {
- $chunk[] = $key;
-
- return $callback(...$chunk);
- });
- }
-
- /**
- * Run a grouping map over the items.
- *
- * The callback should return an associative array with a single key/value pair.
- *
- * @param callable $callback
- * @return static
- */
- public function mapToGroups(callable $callback)
- {
- $groups = $this->mapToDictionary($callback);
-
- return $groups->map([$this, 'make']);
- }
-
- /**
- * Map a collection and flatten the result by a single level.
- *
- * @param callable $callback
- * @return static
- */
- public function flatMap(callable $callback)
- {
- return $this->map($callback)->collapse();
- }
-
- /**
- * Map the values into a new class.
- *
- * @param string $class
- * @return static
- */
- public function mapInto($class)
- {
- return $this->map(function ($value, $key) use ($class) {
- return new $class($value, $key);
- });
- }
-
- /**
- * Get the min value of a given key.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function min($callback = null)
- {
- $callback = $this->valueRetriever($callback);
-
- return $this->map(function ($value) use ($callback) {
- return $callback($value);
- })->filter(function ($value) {
- return ! is_null($value);
- })->reduce(function ($result, $value) {
- return is_null($result) || $value < $result ? $value : $result;
- });
- }
-
- /**
- * Get the max value of a given key.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function max($callback = null)
- {
- $callback = $this->valueRetriever($callback);
-
- return $this->filter(function ($value) {
- return ! is_null($value);
- })->reduce(function ($result, $item) use ($callback) {
- $value = $callback($item);
-
- return is_null($result) || $value > $result ? $value : $result;
- });
- }
-
- /**
- * "Paginate" the collection by slicing it into a smaller collection.
- *
- * @param int $page
- * @param int $perPage
- * @return static
- */
- public function forPage($page, $perPage)
- {
- $offset = max(0, ($page - 1) * $perPage);
-
- return $this->slice($offset, $perPage);
- }
-
- /**
- * Partition the collection into two arrays using the given callback or key.
- *
- * @param callable|string $key
- * @param mixed $operator
- * @param mixed $value
- * @return static
- */
- public function partition($key, $operator = null, $value = null)
- {
- $passed = [];
- $failed = [];
-
- $callback = func_num_args() === 1
- ? $this->valueRetriever($key)
- : $this->operatorForWhere(...func_get_args());
-
- foreach ($this as $key => $item) {
- if ($callback($item, $key)) {
- $passed[$key] = $item;
- } else {
- $failed[$key] = $item;
- }
- }
-
- return new static([new static($passed), new static($failed)]);
- }
-
- /**
- * Get the sum of the given values.
- *
- * @param callable|string|null $callback
- * @return mixed
- */
- public function sum($callback = null)
- {
- $callback = is_null($callback)
- ? $this->identity()
- : $this->valueRetriever($callback);
-
- return $this->reduce(function ($result, $item) use ($callback) {
- return $result + $callback($item);
- }, 0);
- }
-
- /**
- * Apply the callback if the value is truthy.
- *
- * @param bool|mixed $value
- * @param callable|null $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function when($value, callable $callback = null, callable $default = null)
- {
- if (! $callback) {
- return new HigherOrderWhenProxy($this, $value);
- }
-
- if ($value) {
- return $callback($this, $value);
- } elseif ($default) {
- return $default($this, $value);
- }
-
- return $this;
- }
-
- /**
- * Apply the callback if the collection is empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function whenEmpty(callable $callback, callable $default = null)
- {
- return $this->when($this->isEmpty(), $callback, $default);
- }
-
- /**
- * Apply the callback if the collection is not empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function whenNotEmpty(callable $callback, callable $default = null)
- {
- return $this->when($this->isNotEmpty(), $callback, $default);
- }
-
- /**
- * Apply the callback if the value is falsy.
- *
- * @param bool $value
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function unless($value, callable $callback, callable $default = null)
- {
- return $this->when(! $value, $callback, $default);
- }
-
- /**
- * Apply the callback unless the collection is empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function unlessEmpty(callable $callback, callable $default = null)
- {
- return $this->whenNotEmpty($callback, $default);
- }
-
- /**
- * Apply the callback unless the collection is not empty.
- *
- * @param callable $callback
- * @param callable|null $default
- * @return static|mixed
- */
- public function unlessNotEmpty(callable $callback, callable $default = null)
- {
- return $this->whenEmpty($callback, $default);
- }
-
- /**
- * Filter items by the given key value pair.
- *
- * @param string $key
- * @param mixed $operator
- * @param mixed $value
- * @return static
- */
- public function where($key, $operator = null, $value = null)
- {
- return $this->filter($this->operatorForWhere(...func_get_args()));
- }
-
- /**
- * Filter items where the value for the given key is null.
- *
- * @param string|null $key
- * @return static
- */
- public function whereNull($key = null)
- {
- return $this->whereStrict($key, null);
- }
-
- /**
- * Filter items where the value for the given key is not null.
- *
- * @param string|null $key
- * @return static
- */
- public function whereNotNull($key = null)
- {
- return $this->where($key, '!==', null);
- }
-
- /**
- * Filter items by the given key value pair using strict comparison.
- *
- * @param string $key
- * @param mixed $value
- * @return static
- */
- public function whereStrict($key, $value)
- {
- return $this->where($key, '===', $value);
- }
-
- /**
- * Filter items by the given key value pair.
- *
- * @param string $key
- * @param mixed $values
- * @param bool $strict
- * @return static
- */
- public function whereIn($key, $values, $strict = false)
- {
- $values = $this->getArrayableItems($values);
-
- return $this->filter(function ($item) use ($key, $values, $strict) {
- return in_array(data_get($item, $key), $values, $strict);
- });
- }
-
- /**
- * Filter items by the given key value pair using strict comparison.
- *
- * @param string $key
- * @param mixed $values
- * @return static
- */
- public function whereInStrict($key, $values)
- {
- return $this->whereIn($key, $values, true);
- }
-
- /**
- * Filter items such that the value of the given key is between the given values.
- *
- * @param string $key
- * @param array $values
- * @return static
- */
- public function whereBetween($key, $values)
- {
- return $this->where($key, '>=', reset($values))->where($key, '<=', end($values));
- }
-
- /**
- * Filter items such that the value of the given key is not between the given values.
- *
- * @param string $key
- * @param array $values
- * @return static
- */
- public function whereNotBetween($key, $values)
- {
- return $this->filter(function ($item) use ($key, $values) {
- return data_get($item, $key) < reset($values) || data_get($item, $key) > end($values);
- });
- }
-
- /**
- * Filter items by the given key value pair.
- *
- * @param string $key
- * @param mixed $values
- * @param bool $strict
- * @return static
- */
- public function whereNotIn($key, $values, $strict = false)
- {
- $values = $this->getArrayableItems($values);
-
- return $this->reject(function ($item) use ($key, $values, $strict) {
- return in_array(data_get($item, $key), $values, $strict);
- });
- }
-
- /**
- * Filter items by the given key value pair using strict comparison.
- *
- * @param string $key
- * @param mixed $values
- * @return static
- */
- public function whereNotInStrict($key, $values)
- {
- return $this->whereNotIn($key, $values, true);
- }
-
- /**
- * Filter the items, removing any items that don't match the given type(s).
- *
- * @param string|string[] $type
- * @return static
- */
- public function whereInstanceOf($type)
- {
- return $this->filter(function ($value) use ($type) {
- if (is_array($type)) {
- foreach ($type as $classType) {
- if ($value instanceof $classType) {
- return true;
- }
- }
-
- return false;
- }
-
- return $value instanceof $type;
- });
- }
-
- /**
- * Pass the collection to the given callback and return the result.
- *
- * @param callable $callback
- * @return mixed
- */
- public function pipe(callable $callback)
- {
- return $callback($this);
- }
-
- /**
- * Pass the collection into a new class.
- *
- * @param string $class
- * @return mixed
- */
- public function pipeInto($class)
- {
- return new $class($this);
- }
-
- /**
- * Pass the collection through a series of callable pipes and return the result.
- *
- * @param array<callable> $pipes
- * @return mixed
- */
- public function pipeThrough($pipes)
- {
- return static::make($pipes)->reduce(
- function ($carry, $pipe) {
- return $pipe($carry);
- },
- $this,
- );
- }
-
- /**
- * Pass the collection to the given callback and then return it.
- *
- * @param callable $callback
- * @return $this
- */
- public function tap(callable $callback)
- {
- $callback(clone $this);
-
- return $this;
- }
-
- /**
- * Reduce the collection to a single value.
- *
- * @param callable $callback
- * @param mixed $initial
- * @return mixed
- */
- public function reduce(callable $callback, $initial = null)
- {
- $result = $initial;
-
- foreach ($this as $key => $value) {
- $result = $callback($result, $value, $key);
- }
-
- return $result;
- }
-
- /**
- * Reduce the collection to multiple aggregate values.
- *
- * @param callable $callback
- * @param mixed ...$initial
- * @return array
- *
- * @deprecated Use "reduceSpread" instead
- *
- * @throws \UnexpectedValueException
- */
- public function reduceMany(callable $callback, ...$initial)
- {
- return $this->reduceSpread($callback, ...$initial);
- }
-
- /**
- * Reduce the collection to multiple aggregate values.
- *
- * @param callable $callback
- * @param mixed ...$initial
- * @return array
- *
- * @throws \UnexpectedValueException
- */
- public function reduceSpread(callable $callback, ...$initial)
- {
- $result = $initial;
-
- foreach ($this as $key => $value) {
- $result = call_user_func_array($callback, array_merge($result, [$value, $key]));
-
- if (! is_array($result)) {
- throw new UnexpectedValueException(sprintf(
- "%s::reduceMany expects reducer to return an array, but got a '%s' instead.",
- class_basename(static::class), gettype($result)
- ));
- }
- }
-
- return $result;
- }
-
- /**
- * Reduce an associative collection to a single value.
- *
- * @param callable $callback
- * @param mixed $initial
- * @return mixed
- */
- public function reduceWithKeys(callable $callback, $initial = null)
- {
- return $this->reduce($callback, $initial);
- }
-
- /**
- * Create a collection of all elements that do not pass a given truth test.
- *
- * @param callable|mixed $callback
- * @return static
- */
- public function reject($callback = true)
- {
- $useAsCallable = $this->useAsCallable($callback);
-
- return $this->filter(function ($value, $key) use ($callback, $useAsCallable) {
- return $useAsCallable
- ? ! $callback($value, $key)
- : $value != $callback;
- });
- }
-
- /**
- * Return only unique items from the collection array using strict comparison.
- *
- * @param string|callable|null $key
- * @return static
- */
- public function uniqueStrict($key = null)
- {
- return $this->unique($key, true);
- }
-
- /**
- * Collect the values into a collection.
- *
- * @return \Tightenco\Collect\Support\Collection
- */
- public function collect()
- {
- return new Collection($this->all());
- }
-
- /**
- * Get the collection of items as a plain array.
- *
- * @return array
- */
- public function toArray()
- {
- return $this->map(function ($value) {
- return $value instanceof Arrayable ? $value->toArray() : $value;
- })->all();
- }
-
- /**
- * Convert the object into something JSON serializable.
- *
- * @return array
- */
- #[\ReturnTypeWillChange]
- public function jsonSerialize()
- {
- return array_map(function ($value) {
- if ($value instanceof JsonSerializable) {
- return $value->jsonSerialize();
- } elseif ($value instanceof Jsonable) {
- return json_decode($value->toJson(), true);
- } elseif ($value instanceof Arrayable) {
- return $value->toArray();
- }
-
- return $value;
- }, $this->all());
- }
-
- /**
- * Get the collection of items as JSON.
- *
- * @param int $options
- * @return string
- */
- public function toJson($options = 0)
- {
- return json_encode($this->jsonSerialize(), $options);
- }
-
- /**
- * Get a CachingIterator instance.
- *
- * @param int $flags
- * @return \CachingIterator
- */
- public function getCachingIterator($flags = CachingIterator::CALL_TOSTRING)
- {
- return new CachingIterator($this->getIterator(), $flags);
- }
-
- /**
- * Convert the collection to its string representation.
- *
- * @return string
- */
- public function __toString()
- {
- return $this->escapeWhenCastingToString
- ? e($this->toJson())
- : $this->toJson();
- }
-
- /**
- * Indicate that the model's string representation should be escaped when __toString is invoked.
- *
- * @param bool $escape
- * @return $this
- */
- public function escapeWhenCastingToString($escape = true)
- {
- $this->escapeWhenCastingToString = $escape;
-
- return $this;
- }
-
- /**
- * Add a method to the list of proxied methods.
- *
- * @param string $method
- * @return void
- */
- public static function proxy($method)
- {
- static::$proxies[] = $method;
- }
-
- /**
- * Dynamically access collection proxies.
- *
- * @param string $key
- * @return mixed
- *
- * @throws \Exception
- */
- public function __get($key)
- {
- if (! in_array($key, static::$proxies)) {
- throw new Exception("Property [{$key}] does not exist on this collection instance.");
- }
-
- return new HigherOrderCollectionProxy($this, $key);
- }
-
- /**
- * Results array of items from Collection or Arrayable.
- *
- * @param mixed $items
- * @return array
- */
- protected function getArrayableItems($items)
- {
- if (is_array($items)) {
- return $items;
- } elseif ($items instanceof Enumerable) {
- return $items->all();
- } elseif ($items instanceof Arrayable) {
- return $items->toArray();
- } elseif ($items instanceof Jsonable) {
- return json_decode($items->toJson(), true);
- } elseif ($items instanceof JsonSerializable) {
- return (array) $items->jsonSerialize();
- } elseif ($items instanceof Traversable) {
- return iterator_to_array($items);
- }
-
- return (array) $items;
- }
-
- /**
- * Get an operator checker callback.
- *
- * @param string $key
- * @param string|null $operator
- * @param mixed $value
- * @return \Closure
- */
- protected function operatorForWhere($key, $operator = null, $value = null)
- {
- if (func_num_args() === 1) {
- $value = true;
-
- $operator = '=';
- }
-
- if (func_num_args() === 2) {
- $value = $operator;
-
- $operator = '=';
- }
-
- return function ($item) use ($key, $operator, $value) {
- $retrieved = data_get($item, $key);
-
- $strings = array_filter([$retrieved, $value], function ($value) {
- return is_string($value) || (is_object($value) && method_exists($value, '__toString'));
- });
-
- if (count($strings) < 2 && count(array_filter([$retrieved, $value], 'is_object')) == 1) {
- return in_array($operator, ['!=', '<>', '!==']);
- }
-
- switch ($operator) {
- default:
- case '=':
- case '==': return $retrieved == $value;
- case '!=':
- case '<>': return $retrieved != $value;
- case '<': return $retrieved < $value;
- case '>': return $retrieved > $value;
- case '<=': return $retrieved <= $value;
- case '>=': return $retrieved >= $value;
- case '===': return $retrieved === $value;
- case '!==': return $retrieved !== $value;
- }
- };
- }
-
- /**
- * Determine if the given value is callable, but not a string.
- *
- * @param mixed $value
- * @return bool
- */
- protected function useAsCallable($value)
- {
- return ! is_string($value) && is_callable($value);
- }
-
- /**
- * Get a value retrieving callback.
- *
- * @param callable|string|null $value
- * @return callable
- */
- protected function valueRetriever($value)
- {
- if ($this->useAsCallable($value)) {
- return $value;
- }
-
- return function ($item) use ($value) {
- return data_get($item, $value);
- };
- }
-
- /**
- * Make a function to check an item's equality.
- *
- * @param mixed $value
- * @return \Closure
- */
- protected function equality($value)
- {
- return function ($item) use ($value) {
- return $item === $value;
- };
- }
-
- /**
- * Make a function using another function, by negating its result.
- *
- * @param \Closure $callback
- * @return \Closure
- */
- protected function negate(Closure $callback)
- {
- return function (...$params) use ($callback) {
- return ! $callback(...$params);
- };
- }
-
- /**
- * Make a function that returns what's passed to it.
- *
- * @return \Closure
- */
- protected function identity()
- {
- return function ($value) {
- return $value;
- };
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/Macroable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/Macroable.php
deleted file mode 100644
index 7e9fbd5..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/Macroable.php
+++ /dev/null
@@ -1,126 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support\Traits;
-
-use BadMethodCallException;
-use Closure;
-use ReflectionClass;
-use ReflectionMethod;
-
-trait Macroable
-{
- /**
- * The registered string macros.
- *
- * @var array
- */
- protected static $macros = [];
-
- /**
- * Register a custom macro.
- *
- * @param string $name
- * @param object|callable $macro
- * @return void
- */
- public static function macro($name, $macro)
- {
- static::$macros[$name] = $macro;
- }
-
- /**
- * Mix another object into the class.
- *
- * @param object $mixin
- * @param bool $replace
- * @return void
- *
- * @throws \ReflectionException
- */
- public static function mixin($mixin, $replace = true)
- {
- $methods = (new ReflectionClass($mixin))->getMethods(
- ReflectionMethod::IS_PUBLIC | ReflectionMethod::IS_PROTECTED
- );
-
- foreach ($methods as $method) {
- if ($replace || ! static::hasMacro($method->name)) {
- $method->setAccessible(true);
- static::macro($method->name, $method->invoke($mixin));
- }
- }
- }
-
- /**
- * Checks if macro is registered.
- *
- * @param string $name
- * @return bool
- */
- public static function hasMacro($name)
- {
- return isset(static::$macros[$name]);
- }
-
- /**
- * Flush the existing macros.
- *
- * @return void
- */
- public static function flushMacros()
- {
- static::$macros = [];
- }
-
- /**
- * Dynamically handle calls to the class.
- *
- * @param string $method
- * @param array $parameters
- * @return mixed
- *
- * @throws \BadMethodCallException
- */
- public static function __callStatic($method, $parameters)
- {
- if (! static::hasMacro($method)) {
- throw new BadMethodCallException(sprintf(
- 'Method %s::%s does not exist.', static::class, $method
- ));
- }
-
- $macro = static::$macros[$method];
-
- if ($macro instanceof Closure) {
- $macro = $macro->bindTo(null, static::class);
- }
-
- return $macro(...$parameters);
- }
-
- /**
- * Dynamically handle calls to the class.
- *
- * @param string $method
- * @param array $parameters
- * @return mixed
- *
- * @throws \BadMethodCallException
- */
- public function __call($method, $parameters)
- {
- if (! static::hasMacro($method)) {
- throw new BadMethodCallException(sprintf(
- 'Method %s::%s does not exist.', static::class, $method
- ));
- }
-
- $macro = static::$macros[$method];
-
- if ($macro instanceof Closure) {
- $macro = $macro->bindTo($this, static::class);
- }
-
- return $macro(...$parameters);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/Tappable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/Tappable.php
deleted file mode 100644
index 9d75d26..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/Traits/Tappable.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace Tightenco\Collect\Support\Traits;
-
-trait Tappable
-{
- /**
- * Call the given Closure with this instance then return the instance.
- *
- * @param callable|null $callback
- * @return $this|\Tightenco\Collect\Support\HigherOrderTapProxy
- */
- public function tap($callback = null)
- {
- return tap($this, $callback);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/alias.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/alias.php
deleted file mode 100644
index a9c0406..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/alias.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-
-$aliases = [
- Tightenco\Collect\Contracts\Support\Arrayable::class => Illuminate\Contracts\Support\Arrayable::class,
- Tightenco\Collect\Contracts\Support\Jsonable::class => Illuminate\Contracts\Support\Jsonable::class,
- Tightenco\Collect\Contracts\Support\Htmlable::class => Illuminate\Contracts\Support\Htmlable::class,
- Tightenco\Collect\Contracts\Support\CanBeEscapedWhenCastToString::class => Illuminate\Contracts\Support\CanBeEscapedWhenCastToString::class,
- Tightenco\Collect\Support\Arr::class => Illuminate\Support\Arr::class,
- Tightenco\Collect\Support\Collection::class => Illuminate\Support\Collection::class,
- Tightenco\Collect\Support\Enumerable::class => Illuminate\Support\Enumerable::class,
- Tightenco\Collect\Support\HigherOrderCollectionProxy::class => Illuminate\Support\HigherOrderCollectionProxy::class,
- Tightenco\Collect\Support\HigherOrderWhenProxy::class => Illuminate\Support\HigherOrderWhenProxy::class,
- Tightenco\Collect\Support\LazyCollection::class => Illuminate\Support\LazyCollection::class,
- Tightenco\Collect\Support\Traits\EnumeratesValues::class => Illuminate\Support\Traits\EnumeratesValues::class,
-];
-
-# echo "\n\n-- Aliasing....\n---------------------------------------------\n\n";
-
-foreach ($aliases as $tighten => $illuminate) {
- if (! class_exists($illuminate) && ! interface_exists($illuminate) && ! trait_exists($illuminate)) {
- # echo "Aliasing {$tighten} to {$illuminate}.\n";
- class_alias($tighten, $illuminate);
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/helpers.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/helpers.php
deleted file mode 100644
index 886a141..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/tightenco/collect/src/Collect/Support/helpers.php
+++ /dev/null
@@ -1,122 +0,0 @@
-<?php
-
-use Tightenco\Collect\Support\Arr;
-use Tightenco\Collect\Support\Collection;
-use Tightenco\Collect\Support\HigherOrderTapProxy;
-use Symfony\Component\VarDumper\VarDumper;
-
-if (! class_exists(Illuminate\Support\Collection::class)) {
- if (! function_exists('collect')) {
- /**
- * Create a collection from the given value.
- *
- * @param mixed $value
- * @return \Tightenco\Collect\Support\Collection
- */
- function collect($value = null)
- {
- return new Collection($value);
- }
- }
-
- if (! function_exists('value')) {
- /**
- * Return the default value of the given value.
- *
- * @param mixed $value
- * @return mixed
- */
- function value($value, ...$args)
- {
- return $value instanceof Closure ? $value(...$args) : $value;
- }
- }
-
- if (! function_exists('data_get')) {
- /**
- * Get an item from an array or object using "dot" notation.
- *
- * @param mixed $target
- * @param string|array|int|null $key
- * @param mixed $default
- * @return mixed
- */
- function data_get($target, $key, $default = null)
- {
- if (is_null($key)) {
- return $target;
- }
-
- $key = is_array($key) ? $key : explode('.', $key);
-
- foreach ($key as $i => $segment) {
- unset($key[$i]);
-
- if (is_null($segment)) {
- return $target;
- }
-
- if ($segment === '*') {
- if ($target instanceof Collection) {
- $target = $target->all();
- } elseif (! is_array($target)) {
- return value($default);
- }
-
- $result = [];
-
- foreach ($target as $item) {
- $result[] = data_get($item, $key);
- }
-
- return in_array('*', $key) ? Arr::collapse($result) : $result;
- }
-
- if (Arr::accessible($target) && Arr::exists($target, $segment)) {
- $target = $target[$segment];
- } elseif (is_object($target) && isset($target->{$segment})) {
- $target = $target->{$segment};
- } else {
- return value($default);
- }
- }
-
- return $target;
- }
- }
-
- if (! function_exists('tap')) {
- /**
- * Call the given Closure with the given value then return the value.
- *
- * @param mixed $value
- * @param callable|null $callback
- * @return mixed
- */
- function tap($value, $callback = null)
- {
- if (is_null($callback)) {
- return new HigherOrderTapProxy($value);
- }
-
- $callback($value);
-
- return $value;
- }
- }
-
- if (! function_exists('class_basename')) {
- /**
- * Get the class "basename" of the given object / class.
- *
- * @param string|object $class
- * @return string
- */
- function class_basename($class)
- {
- $class = is_object($class) ? get_class($class) : $class;
-
- return basename(str_replace('\\', '/', $class));
- }
- }
-}
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
deleted file mode 100644
index 270f1d1..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.editorconfig
+++ /dev/null
@@ -1,18 +0,0 @@
-; 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
deleted file mode 100644
index 06bc367..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitattributes
+++ /dev/null
@@ -1,4 +0,0 @@
-/doc/ export-ignore
-/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
deleted file mode 100644
index 65c2c40..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/ci.yml
+++ /dev/null
@@ -1,149 +0,0 @@
-name: "CI"
-
-on:
- pull_request:
- push:
- branches:
- - '3.x'
-
-env:
- SYMFONY_PHPUNIT_DISABLE_RESULT_CACHE: 1
-
-permissions:
- contents: read
-
-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'
- - '8.1'
- experimental: [false]
-
- steps:
- - name: "Checkout code"
- uses: actions/checkout@v4
-
- - name: "Install PHP with extensions"
- uses: shivammathur/setup-php@v2
- with:
- coverage: "none"
- php-version: ${{ matrix.php-version }}
- ini-values: memory_limit=-1
-
- - name: "Add PHPUnit matcher"
- run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
-
- - run: composer install
-
- - 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'
- - '8.1'
- 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'
- experimental: [false]
-
- steps:
- - name: "Checkout code"
- uses: actions/checkout@v4
-
- - name: "Install PHP with extensions"
- uses: shivammathur/setup-php@v2
- with:
- coverage: "none"
- php-version: ${{ matrix.php-version }}
- ini-values: memory_limit=-1
-
- - name: "Add PHPUnit matcher"
- run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
-
- - run: composer install
-
- - name: "Install PHPUnit"
- run: vendor/bin/simple-phpunit install
-
- - name: "PHPUnit version"
- run: vendor/bin/simple-phpunit --version
-
- - 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
-#
-# - name: "Install PHP with extensions"
-# uses: shivammathur/setup-php@2
-# with:
-# coverage: "none"
-# extensions: "gd, pdo_sqlite"
-# php-version: ${{ matrix.php-version }}
-# ini-values: memory_limit=-1
-# tools: composer:v2
-#
-# - run: bash ./tests/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
deleted file mode 100644
index 5caa8a3..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.github/workflows/documentation.yml
+++ /dev/null
@@ -1,64 +0,0 @@
-name: "Documentation"
-
-on:
- pull_request:
- push:
- branches:
- - '2.x'
- - '3.x'
-
-permissions:
- contents: read
-
-jobs:
- build:
- name: "Build"
-
- runs-on: ubuntu-latest
-
- steps:
- - name: "Checkout code"
- uses: actions/checkout@v4
-
- - name: "Set-up PHP"
- uses: shivammathur/setup-php@v2
- with:
- php-version: 8.1
- coverage: none
- tools: "composer:v2"
-
- - name: Get composer cache directory
- id: composercache
- working-directory: doc/_build
- run: echo "::set-output name=dir::$(composer config cache-files-dir)"
-
- - name: Cache dependencies
- uses: actions/cache@v3
- with:
- path: ${{ steps.composercache.outputs.dir }}
- key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
- restore-keys: ${{ runner.os }}-composer-
-
- - name: "Install dependencies"
- working-directory: doc/_build
- run: composer install --prefer-dist --no-progress
-
- - name: "Build the docs"
- working-directory: doc/_build
- run: php build.php --disable-cache
-
- doctor-rst:
- name: "DOCtor-RST"
-
- runs-on: ubuntu-latest
-
- steps:
- - name: "Checkout code"
- uses: actions/checkout@v4
-
- - 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
deleted file mode 100644
index b197246..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.gitignore
+++ /dev/null
@@ -1,6 +0,0 @@
-/doc/_build/vendor
-/doc/_build/output
-/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
deleted file mode 100644
index b07ac7f..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/.php-cs-fixer.dist.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?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
index 3793876..44c79b1 100644
--- 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
@@ -1,3 +1,178 @@
+# 3.14.0 (2024-09-09)
+
+ * Fix a security issue when an included sandboxed template has been loaded before without the sandbox context
+ * Add the possibility to reset globals via `Environment::resetGlobals()`
+ * Deprecate `Environment::mergeGlobals()`
+
+# 3.13.0 (2024-09-07)
+
+ * Add the `types` tag (experimental)
+ * Deprecate the `Twig\Test\NodeTestCase::getTests()` data provider, override `provideTests()` instead.
+ * Mark `Twig\Test\NodeTestCase::getEnvironment()` as final, override `createEnvironment()` instead.
+ * Deprecate `Twig\Test\NodeTestCase::getVariableGetter()`, call `createVariableGetter()` instead.
+ * Deprecate `Twig\Test\NodeTestCase::getAttributeGetter()`, call `createAttributeGetter()` instead.
+ * Deprecate not overriding `Twig\Test\IntegrationTestCase::getFixturesDirectory()`, this method will be abstract in 4.0
+ * Marked `Twig\Test\IntegrationTestCase::getTests()` and `getLegacyTests()` as final
+
+# 3.12.0 (2024-08-29)
+
+ * Deprecate the fact that the `extends` and `use` tags are always allowed in a sandboxed template.
+ This behavior will change in 4.0 where these tags will need to be explicitly allowed like any other tag.
+ * Deprecate the "tag" constructor argument of the "Twig\Node\Node" class as the tag is now automatically set by the Parser when needed
+ * Fix precedence of two-word tests when the first word is a valid test
+ * Deprecate the `spaceless` filter
+ * Deprecate some internal methods from `Parser`: `getBlockStack()`, `hasBlock()`, `getBlock()`, `hasMacro()`, `hasTraits()`, `getParent()`
+ * Deprecate passing `null` to `Twig\Parser::setParent()`
+ * Update `Node::__toString()` to include the node tag if set
+ * Add support for integers in methods of `Twig\Node\Node` that take a Node name
+ * Deprecate not passing a `BodyNode` instance as the body of a `ModuleNode` or `MacroNode` constructor
+ * Deprecate returning "null" from "TokenParserInterface::parse()".
+ * Deprecate `OptimizerNodeVisitor::OPTIMIZE_TEXT_NODES`
+ * Fix performance regression when `use_yield` is `false` (which is the default)
+ * Improve compatibility when `use_yield` is `false` (as extensions still using `echo` will work as is)
+ * Accept colons (`:`) in addition to equals (`=`) to separate argument names and values in named arguments
+ * Add the `html_cva` function (in the HTML extra package)
+ * Add support for named arguments to the `block` and `attribute` functions
+ * Throw a SyntaxError exception at compile time when a Twig callable has not the minimum number of required arguments
+ * Add a `CallableArgumentsExtractor` class
+ * Deprecate passing a name to `FunctionExpression`, `FilterExpression`, and `TestExpression`;
+ pass a `TwigFunction`, `TwigFilter`, or `TestFilter` instead
+ * Deprecate all Twig callable attributes on `FunctionExpression`, `FilterExpression`, and `TestExpression`
+ * Deprecate the `filter` node of `FilterExpression`
+ * Add the notion of Twig callables (functions, filters, and tests)
+ * Bump minimum PHP version to 8.0
+ * Fix integration tests when a test has more than one data/expect section and deprecations
+ * Add the `enum_cases` function
+
+# 3.11.0 (2024-08-08)
+
+ * Deprecate `OptimizerNodeVisitor::OPTIMIZE_RAW_FILTER`
+ * Add `Twig\Cache\ChainCache` and `Twig\Cache\ReadOnlyFilesystemCache`
+ * Add the possibility to deprecate attributes and nodes on `Node`
+ * Add the possibility to add a package and a version to the `deprecated` tag
+ * Add the possibility to add a package for filter/function/test deprecations
+ * Mark `ConstantExpression` as being `@final`
+ * Add the `find` filter
+ * Fix optimizer mode validation in `OptimizerNodeVisitor`
+ * Add the possibility to yield from a generator in `PrintNode`
+ * Add the `shuffle` filter
+ * Add the `singular` and `plural` filters in `StringExtension`
+ * Deprecate the second argument of `Twig\Node\Expression\CallExpression::compileArguments()`
+ * Deprecate `Twig\ExpressionParser\parseHashExpression()` in favor of
+ `Twig\ExpressionParser::parseMappingExpression()`
+ * Deprecate `Twig\ExpressionParser\parseArrayExpression()` in favor of
+ `Twig\ExpressionParser::parseSequenceExpression()`
+ * Add `sequence` and `mapping` tests
+ * Deprecate `Twig\Node\Expression\NameExpression::isSimple()` and
+ `Twig\Node\Expression\NameExpression::isSpecial()`
+
+# 3.10.3 (2024-05-16)
+
+ * Fix missing ; in generated code
+
+# 3.10.2 (2024-05-14)
+
+ * Fix support for the deprecated escaper signature
+
+# 3.10.1 (2024-05-12)
+
+ * Fix BC break on escaper extension
+ * Fix constant return type
+
+# 3.10.0 (2024-05-11)
+
+ * Make `CoreExtension::formatDate`, `CoreExtension::convertDate`, and
+ `CoreExtension::formatNumber` part of the public API
+ * Add `needs_charset` option for filters and functions
+ * Extract the escaping logic from the `EscaperExtension` class to a new
+ `EscaperRuntime` class.
+
+ The following methods from ``Twig\\Extension\\EscaperExtension`` are
+ deprecated: ``setEscaper()``, ``getEscapers()``, ``setSafeClasses``,
+ ``addSafeClasses()``. Use the same methods on the
+ ``Twig\\Runtime\\EscaperRuntime`` class instead.
+ * Fix capturing output from extensions that still use echo
+ * Fix a PHP warning in the Lexer on malformed templates
+ * Fix blocks not available under some circumstances
+ * Synchronize source context in templates when setting a Node on a Node
+
+# 3.9.3 (2024-04-18)
+
+ * Add missing `twig_escape_filter_is_safe` deprecated function
+ * Fix yield usage with CaptureNode
+ * Add missing unwrap call when using a TemplateWrapper instance internally
+ * Ensure Lexer is initialized early on
+
+# 3.9.2 (2024-04-17)
+
+ * Fix usage of display_end hook
+
+# 3.9.1 (2024-04-17)
+
+ * Fix missing `$blocks` variable in `CaptureNode`
+
+# 3.9.0 (2024-04-16)
+
+ * Add support for PHP 8.4
+ * Deprecate AbstractNodeVisitor
+ * Deprecate passing Template to Environment::resolveTemplate(), Environment::load(), and Template::loadTemplate()
+ * Add a new "yield" mode for output generation;
+ Node implementations that use "echo" or "print" should use "yield" instead;
+ all Node implementations should be flagged with `#[YieldReady]` once they've been made ready for "yield";
+ the "use_yield" Environment option can be turned on when all nodes have been made `#[YieldReady]`;
+ "yield" will be the only strategy supported in the next major version
+ * Add return type for Symfony 7 compatibility
+ * Fix premature loop exit in Security Policy lookup of allowed methods/properties
+ * Deprecate all internal extension functions in favor of methods on the extension classes
+ * Mark all extension functions as @internal
+ * Add SourcePolicyInterface to selectively enable the Sandbox based on a template's Source
+ * Throw a proper Twig exception when using cycle on an empty array
+
+# 3.8.0 (2023-11-21)
+
+ * Catch errors thrown during template rendering
+ * Fix IntlExtension::formatDateTime use of date formatter prototype
+ * Fix premature loop exit in Security Policy lookup of allowed methods/properties
+ * Remove NumberFormatter::TYPE_CURRENCY (deprecated in PHP 8.3)
+ * Restore return type annotations
+ * Allow Symfony 7 packages to be installed
+ * Deprecate `twig_test_iterable` function. Use the native `is_iterable` instead.
+
+# 3.7.1 (2023-08-28)
+
+ * Fix some phpdocs
+
+# 3.7.0 (2023-07-26)
+
+ * Add support for the ...spread operator on arrays and hashes
+
+# 3.6.1 (2023-06-08)
+
+ * Suppress some native return type deprecation messages
+
+# 3.6.0 (2023-05-03)
+
+ * Allow psr/container 2.0
+ * Add the new PHP 8.0 IntlDateFormatter::RELATIVE_* constants for date formatting
+ * Make the Lexer initialize itself lazily
+
+# 3.5.1 (2023-02-08)
+
+ * Arrow functions passed to the "reduce" filter now accept the current key as a third argument
+ * Restores the leniency of the matches twig comparison
+ * Fix error messages in sandboxed mode for "has some" and "has every"
+
+# 3.5.0 (2022-12-27)
+
+ * Make Twig\ExpressionParser non-internal
+ * Add "has some" and "has every" operators
+ * Add Compile::reset()
+ * Throw a better runtime error when the "matches" regexp is not valid
+ * Add "twig *_names" intl functions
+ * Fix optimizing closures callbacks
+ * Add a better exception when getting an undefined constant via `constant`
+ * Fix `if` nodes when outside of a block and with an empty body
+
# 3.4.3 (2022-09-28)
* Fix a security issue on filesystem loader (possibility to load a template outside a configured directory)
@@ -141,7 +316,7 @@
* removed Parser::isReservedMacroName()
* removed SanboxedPrintNode
* removed Node::setTemplateName()
- * made classes maked as "@final" final
+ * made classes marked as "@final" final
* removed InitRuntimeInterface, ExistsLoaderInterface, and SourceContextLoaderInterface
* removed the "spaceless" tag
* removed Twig\Environment::getBaseTemplateClass() and Twig\Environment::setBaseTemplateClass()
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
index 8711927..fd8234e 100644
--- 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
@@ -1,4 +1,4 @@
-Copyright (c) 2009-2022 by the Twig Team.
+Copyright (c) 2009-present by the Twig Team.
All rights reserved.
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
index fbe7e9a..7bf8c67 100644
--- 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
@@ -11,7 +11,7 @@
.. raw:: html
- <a href="https://blackfire.io/docs/introduction?utm_source=twig&utm_medium=github_readme&utm_campaign=logo">
+ <a href="https://docs.blackfire.io/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>
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
index 33e4640..e0c3e6c 100644
--- 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
@@ -24,15 +24,23 @@
}
],
"require": {
- "php": ">=7.2.5",
+ "php": ">=8.0.2",
+ "symfony/deprecation-contracts": "^2.5|^3",
"symfony/polyfill-mbstring": "^1.3",
- "symfony/polyfill-ctype": "^1.8"
+ "symfony/polyfill-ctype": "^1.8",
+ "symfony/polyfill-php81": "^1.29"
},
"require-dev": {
- "symfony/phpunit-bridge": "^4.4.9|^5.0.9|^6.0",
- "psr/container": "^1.0"
+ "symfony/phpunit-bridge": "^5.4.9|^6.4|^7.0",
+ "psr/container": "^1.0|^2.0"
},
"autoload": {
+ "files": [
+ "src/Resources/core.php",
+ "src/Resources/debug.php",
+ "src/Resources/escaper.php",
+ "src/Resources/string_loader.php"
+ ],
"psr-4" : {
"Twig\\" : "src/"
}
@@ -41,10 +49,5 @@
"psr-4" : {
"Twig\\Tests\\" : "tests/"
}
- },
- "extra": {
- "branch-alias": {
- "dev-master": "3.4-dev"
- }
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/AbstractTwigCallable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/AbstractTwigCallable.php
new file mode 100644
index 0000000..f671843
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/AbstractTwigCallable.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;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+abstract class AbstractTwigCallable implements TwigCallableInterface
+{
+ protected $options;
+
+ private $name;
+ private $dynamicName;
+ private $callable;
+ private $arguments;
+
+ public function __construct(string $name, $callable = null, array $options = [])
+ {
+ $this->name = $this->dynamicName = $name;
+ $this->callable = $callable;
+ $this->arguments = [];
+ $this->options = array_merge([
+ 'needs_environment' => false,
+ 'needs_context' => false,
+ 'needs_charset' => false,
+ 'is_variadic' => false,
+ 'deprecated' => false,
+ 'deprecating_package' => '',
+ 'alternative' => null,
+ ], $options);
+ }
+
+ public function __toString(): string
+ {
+ return \sprintf('%s(%s)', static::class, $this->name);
+ }
+
+ public function getName(): string
+ {
+ return $this->name;
+ }
+
+ public function getDynamicName(): string
+ {
+ return $this->dynamicName;
+ }
+
+ public function getCallable()
+ {
+ return $this->callable;
+ }
+
+ public function getNodeClass(): string
+ {
+ return $this->options['node_class'];
+ }
+
+ public function needsCharset(): bool
+ {
+ return $this->options['needs_charset'];
+ }
+
+ public function needsEnvironment(): bool
+ {
+ return $this->options['needs_environment'];
+ }
+
+ public function needsContext(): bool
+ {
+ return $this->options['needs_context'];
+ }
+
+ public function withDynamicArguments(string $name, string $dynamicName, array $arguments): self
+ {
+ $new = clone $this;
+ $new->name = $name;
+ $new->dynamicName = $dynamicName;
+ $new->arguments = $arguments;
+
+ return $new;
+ }
+
+ /**
+ * @deprecated since Twig 3.12, use withDynamicArguments() instead
+ */
+ public function setArguments(array $arguments): void
+ {
+ trigger_deprecation('twig/twig', '3.12', 'The "%s::setArguments()" method is deprecated, use "%s::withDynamicArguments()" instead.', static::class, static::class);
+
+ $this->arguments = $arguments;
+ }
+
+ public function getArguments(): array
+ {
+ return $this->arguments;
+ }
+
+ public function isVariadic(): bool
+ {
+ return $this->options['is_variadic'];
+ }
+
+ public function isDeprecated(): bool
+ {
+ return (bool) $this->options['deprecated'];
+ }
+
+ public function getDeprecatingPackage(): string
+ {
+ return $this->options['deprecating_package'];
+ }
+
+ public function getDeprecatedVersion(): string
+ {
+ return \is_bool($this->options['deprecated']) ? '' : $this->options['deprecated'];
+ }
+
+ public function getAlternative(): ?string
+ {
+ return $this->options['alternative'];
+ }
+
+ public function getMinimalNumberOfRequiredArguments(): int
+ {
+ return ($this->options['needs_charset'] ? 1 : 0) + ($this->options['needs_environment'] ? 1 : 0) + ($this->options['needs_context'] ? 1 : 0) + \count($this->arguments);
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Attribute/FirstClassTwigCallableReady.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Attribute/FirstClassTwigCallableReady.php
new file mode 100644
index 0000000..ffd8cff
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Attribute/FirstClassTwigCallableReady.php
@@ -0,0 +1,20 @@
+<?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\Attribute;
+
+/**
+ * Marks nodes that are ready to accept a TwigCallable instead of its name.
+ */
+#[\Attribute(\Attribute::TARGET_METHOD)]
+final class FirstClassTwigCallableReady
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Attribute/YieldReady.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Attribute/YieldReady.php
new file mode 100644
index 0000000..335c435
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Attribute/YieldReady.php
@@ -0,0 +1,20 @@
+<?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\Attribute;
+
+/**
+ * Marks nodes that are ready for using "yield" instead of "echo" or "print()" for rendering.
+ */
+#[\Attribute(\Attribute::TARGET_CLASS)]
+final class YieldReady
+{
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/ChainCache.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/ChainCache.php
new file mode 100644
index 0000000..c94afdb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/ChainCache.php
@@ -0,0 +1,79 @@
+<?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;
+
+/**
+ * Chains several caches together.
+ *
+ * Cached items are fetched from the first cache having them in its data store.
+ * They are saved and deleted in all adapters at once.
+ *
+ * @author Quentin Devos <quentin@devos.pm>
+ */
+final class ChainCache implements CacheInterface
+{
+ /**
+ * @param iterable<CacheInterface> $caches The ordered list of caches used to store and fetch cached items
+ */
+ public function __construct(
+ private iterable $caches,
+ ) {
+ }
+
+ public function generateKey(string $name, string $className): string
+ {
+ return $className.'#'.$name;
+ }
+
+ public function write(string $key, string $content): void
+ {
+ $splitKey = $this->splitKey($key);
+
+ foreach ($this->caches as $cache) {
+ $cache->write($cache->generateKey(...$splitKey), $content);
+ }
+ }
+
+ public function load(string $key): void
+ {
+ [$name, $className] = $this->splitKey($key);
+
+ foreach ($this->caches as $cache) {
+ $cache->load($cache->generateKey($name, $className));
+
+ if (class_exists($className, false)) {
+ break;
+ }
+ }
+ }
+
+ public function getTimestamp(string $key): int
+ {
+ $splitKey = $this->splitKey($key);
+
+ foreach ($this->caches as $cache) {
+ if (0 < $timestamp = $cache->getTimestamp($cache->generateKey(...$splitKey))) {
+ return $timestamp;
+ }
+ }
+
+ return 0;
+ }
+
+ /**
+ * @return string[]
+ */
+ private function splitKey(string $key): array
+ {
+ return array_reverse(explode('#', $key, 2));
+ }
+}
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
index e075563..2e79fac 100644
--- 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
@@ -50,11 +50,11 @@
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));
+ 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));
+ throw new \RuntimeException(\sprintf('Unable to write in the cache directory (%s).', $dir));
}
$tmpFile = tempnam($dir, basename($key));
@@ -63,7 +63,7 @@
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)) {
+ 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);
@@ -73,7 +73,7 @@
return;
}
- throw new \RuntimeException(sprintf('Failed to write cache file "%s".', $key));
+ throw new \RuntimeException(\sprintf('Failed to write cache file "%s".', $key));
}
public function getTimestamp(string $key): int
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/ReadOnlyFilesystemCache.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/ReadOnlyFilesystemCache.php
new file mode 100644
index 0000000..3ba6514
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Cache/ReadOnlyFilesystemCache.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\Cache;
+
+/**
+ * Implements a cache on the filesystem that can only be read, not written to.
+ *
+ * @author Quentin Devos <quentin@devos.pm>
+ */
+class ReadOnlyFilesystemCache extends FilesystemCache
+{
+ public function write(string $key, string $content): void
+ {
+ // Do nothing with the content, it's a read-only filesystem.
+ }
+}
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
index 95e1f18..1a43aa7 100644
--- 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
@@ -22,15 +22,16 @@
private $lastLine;
private $source;
private $indentation;
- private $env;
private $debugInfo = [];
private $sourceOffset;
private $sourceLine;
private $varNameSalt = 0;
+ private $didUseEcho = false;
+ private $didUseEchoStack = [];
- public function __construct(Environment $env)
- {
- $this->env = $env;
+ public function __construct(
+ private Environment $env,
+ ) {
}
public function getEnvironment(): Environment
@@ -46,7 +47,7 @@
/**
* @return $this
*/
- public function compile(Node $node, int $indentation = 0)
+ public function reset(int $indentation = 0)
{
$this->lastLine = null;
$this->source = '';
@@ -57,23 +58,54 @@
$this->indentation = $indentation;
$this->varNameSalt = 0;
- $node->compile($this);
-
return $this;
}
/**
* @return $this
*/
+ public function compile(Node $node, int $indentation = 0)
+ {
+ $this->reset($indentation);
+ $this->didUseEchoStack[] = $this->didUseEcho;
+
+ try {
+ $this->didUseEcho = false;
+ $node->compile($this);
+
+ if ($this->didUseEcho) {
+ trigger_deprecation('twig/twig', '3.9', 'Using "%s" is deprecated, use "yield" instead in "%s", then flag the class with #[YieldReady].', $this->didUseEcho, \get_class($node));
+ }
+
+ return $this;
+ } finally {
+ $this->didUseEcho = array_pop($this->didUseEchoStack);
+ }
+ }
+
+ /**
+ * @return $this
+ */
public function subcompile(Node $node, bool $raw = true)
{
- if (false === $raw) {
+ if (!$raw) {
$this->source .= str_repeat(' ', $this->indentation * 4);
}
- $node->compile($this);
+ $this->didUseEchoStack[] = $this->didUseEcho;
- return $this;
+ try {
+ $this->didUseEcho = false;
+ $node->compile($this);
+
+ if ($this->didUseEcho) {
+ trigger_deprecation('twig/twig', '3.9', 'Using "%s" is deprecated, use "yield" instead in "%s", then flag the class with #[YieldReady].', $this->didUseEcho, \get_class($node));
+ }
+
+ return $this;
+ } finally {
+ $this->didUseEcho = array_pop($this->didUseEchoStack);
+ }
}
/**
@@ -83,6 +115,7 @@
*/
public function raw(string $string)
{
+ $this->checkForEcho($string);
$this->source .= $string;
return $this;
@@ -96,6 +129,7 @@
public function write(...$strings)
{
foreach ($strings as $string) {
+ $this->checkForEcho($string);
$this->source .= str_repeat(' ', $this->indentation * 4).$string;
}
@@ -109,7 +143,7 @@
*/
public function string(string $value)
{
- $this->source .= sprintf('"%s"', addcslashes($value, "\0\t\"\$\\"));
+ $this->source .= \sprintf('"%s"', addcslashes($value, "\0\t\"\$\\"));
return $this;
}
@@ -161,7 +195,7 @@
public function addDebugInfo(Node $node)
{
if ($node->getTemplateLine() != $this->lastLine) {
- $this->write(sprintf("// line %d\n", $node->getTemplateLine()));
+ $this->write(\sprintf("// line %d\n", $node->getTemplateLine()));
$this->sourceLine += substr_count($this->source, "\n", $this->sourceOffset);
$this->sourceOffset = \strlen($this->source);
@@ -209,6 +243,15 @@
public function getVarName(): string
{
- return sprintf('__internal_compile_%d', $this->varNameSalt++);
+ return \sprintf('__internal_compile_%d', $this->varNameSalt++);
+ }
+
+ private function checkForEcho(string $string): void
+ {
+ if ($this->didUseEcho) {
+ return;
+ }
+
+ $this->didUseEcho = preg_match('/^\s*+(echo|print)\b/', $string, $m) ? $m[1] : false;
}
}
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
index 85aaab9..24e55e9 100644
--- 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
@@ -22,12 +22,17 @@
use Twig\Extension\EscaperExtension;
use Twig\Extension\ExtensionInterface;
use Twig\Extension\OptimizerExtension;
+use Twig\Extension\YieldNotReadyExtension;
use Twig\Loader\ArrayLoader;
use Twig\Loader\ChainLoader;
use Twig\Loader\LoaderInterface;
+use Twig\Node\Expression\Binary\AbstractBinary;
+use Twig\Node\Expression\Unary\AbstractUnary;
use Twig\Node\ModuleNode;
use Twig\Node\Node;
use Twig\NodeVisitor\NodeVisitorInterface;
+use Twig\Runtime\EscaperRuntime;
+use Twig\RuntimeLoader\FactoryRuntimeLoader;
use Twig\RuntimeLoader\RuntimeLoaderInterface;
use Twig\TokenParser\TokenParserInterface;
@@ -38,11 +43,11 @@
*/
class Environment
{
- public const VERSION = '3.4.3';
- public const VERSION_ID = 30403;
+ public const VERSION = '3.14.0';
+ public const VERSION_ID = 31400;
public const MAJOR_VERSION = 3;
- public const MINOR_VERSION = 4;
- public const RELEASE_VERSION = 3;
+ public const MINOR_VERSION = 14;
+ public const RELEASE_VERSION = 0;
public const EXTRA_VERSION = '';
private $charset;
@@ -53,16 +58,19 @@
private $lexer;
private $parser;
private $compiler;
+ /** @var array<string, mixed> */
private $globals = [];
private $resolvedGlobals;
private $loadedTemplates;
private $strictVariables;
- private $templateClassPrefix = '__TwigTemplate_';
private $originalCache;
private $extensionSet;
private $runtimeLoaders = [];
private $runtimes = [];
private $optionsHash;
+ /** @var bool */
+ private $useYield;
+ private $defaultRuntimeLoader;
/**
* Constructor.
@@ -94,8 +102,12 @@
* * 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).
+ *
+ * * use_yield: true: forces templates to exclusively use "yield" instead of "echo" (all extensions must be yield ready)
+ * false (default): allows templates to use a mix of "yield" and "echo" calls to allow for a progressive migration
+ * Switch to "true" when possible as this will be the only supported mode in Twig 4.0
*/
- public function __construct(LoaderInterface $loader, $options = [])
+ public function __construct(LoaderInterface $loader, array $options = [])
{
$this->setLoader($loader);
@@ -107,21 +119,39 @@
'cache' => false,
'auto_reload' => null,
'optimizations' => -1,
+ 'use_yield' => false,
], $options);
+ $this->useYield = (bool) $options['use_yield'];
$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->defaultRuntimeLoader = new FactoryRuntimeLoader([
+ EscaperRuntime::class => function () { return new EscaperRuntime($this->charset); },
+ ]);
$this->addExtension(new CoreExtension());
- $this->addExtension(new EscaperExtension($options['autoescape']));
+ $escaperExt = new EscaperExtension($options['autoescape']);
+ $escaperExt->setEnvironment($this, false);
+ $this->addExtension($escaperExt);
+ if (\PHP_VERSION_ID >= 80000) {
+ $this->addExtension(new YieldNotReadyExtension($this->useYield));
+ }
$this->addExtension(new OptimizerExtension($options['optimizations']));
}
/**
+ * @internal
+ */
+ public function useYield(): bool
+ {
+ return $this->useYield;
+ }
+
+ /**
* Enables debugging mode.
*/
public function enableDebug()
@@ -246,7 +276,6 @@
*
* * 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.
@@ -256,11 +285,11 @@
*
* @internal
*/
- public function getTemplateClass(string $name, int $index = null): string
+ public function getTemplateClass(string $name, ?int $index = null): string
{
$key = $this->getLoader()->getCacheKey($name).$this->optionsHash;
- return $this->templateClassPrefix.hash(\PHP_VERSION_ID < 80100 ? 'sha256' : 'xxh128', $key).(null === $index ? '' : '___'.$index);
+ return '__TwigTemplate_'.hash(\PHP_VERSION_ID < 80100 ? 'sha256' : 'xxh128', $key).(null === $index ? '' : '___'.$index);
}
/**
@@ -305,6 +334,11 @@
if ($name instanceof TemplateWrapper) {
return $name;
}
+ if ($name instanceof Template) {
+ trigger_deprecation('twig/twig', '3.9', 'Passing a "%s" instance to "%s" is deprecated.', self::class, __METHOD__);
+
+ return $name;
+ }
return new TemplateWrapper($this, $this->loadTemplate($this->getTemplateClass($name), $name));
}
@@ -315,8 +349,8 @@
* 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
+ * @param string $name The template name
+ * @param int|null $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
@@ -324,7 +358,7 @@
*
* @internal
*/
- public function loadTemplate(string $cls, string $name, int $index = null): Template
+ public function loadTemplate(string $cls, string $name, ?int $index = null): Template
{
$mainCls = $cls;
if (null !== $index) {
@@ -342,7 +376,6 @@
$this->cache->load($key);
}
- $source = null;
if (!class_exists($cls, false)) {
$source = $this->getLoader()->getSourceContext($name);
$content = $this->compileSource($source);
@@ -359,7 +392,7 @@
}
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);
+ throw new RuntimeError(\sprintf('Failed to load Twig template "%s", index "%s": cache might be corrupted.', $name, $index), -1, $source);
}
}
}
@@ -374,19 +407,19 @@
*
* 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
+ * @param string $template The template source
+ * @param string|null $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
+ public function createTemplate(string $template, ?string $name = null): TemplateWrapper
{
$hash = hash(\PHP_VERSION_ID < 80100 ? 'sha256' : 'xxh128', $template, false);
if (null !== $name) {
- $name = sprintf('%s (string template %s)', $name, $hash);
+ $name = \sprintf('%s (string template %s)', $name, $hash);
} else {
- $name = sprintf('__string_template__%s', $hash);
+ $name = \sprintf('__string_template__%s', $hash);
}
$loader = new ChainLoader([
@@ -419,10 +452,10 @@
/**
* 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.
+ * Similar to load() but it also accepts instances of \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
+ * @param string|TemplateWrapper|array<string|TemplateWrapper> $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
@@ -436,7 +469,9 @@
$count = \count($names);
foreach ($names as $name) {
if ($name instanceof Template) {
- return $name;
+ trigger_deprecation('twig/twig', '3.9', 'Passing a "%s" instance to "%s" is deprecated.', Template::class, __METHOD__);
+
+ return new TemplateWrapper($this, $name);
}
if ($name instanceof TemplateWrapper) {
return $name;
@@ -449,7 +484,7 @@
return $this->load($name);
}
- throw new LoaderError(sprintf('Unable to find one of the following templates: "%s".', implode('", "', $names)));
+ throw new LoaderError(\sprintf('Unable to find one of the following templates: "%s".', implode('", "', $names)));
}
public function setLexer(Lexer $lexer)
@@ -518,7 +553,7 @@
$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);
+ throw new SyntaxError(\sprintf('An exception has been thrown during the compilation of a template ("%s").', $e->getMessage()), -1, $source, $e);
}
}
@@ -534,7 +569,7 @@
public function setCharset(string $charset)
{
- if ('UTF8' === $charset = null === $charset ? null : strtoupper($charset)) {
+ if ('UTF8' === $charset = strtoupper($charset ?: '')) {
// iconv on Windows requires "UTF-8" instead of "UTF8"
$charset = 'UTF-8';
}
@@ -592,7 +627,11 @@
}
}
- throw new RuntimeError(sprintf('Unable to load the "%s" runtime.', $class));
+ if (null !== $runtime = $this->defaultRuntimeLoader->load($class)) {
+ return $this->runtimes[$class] = $runtime;
+ }
+
+ throw new RuntimeError(\sprintf('Unable to load the "%s" runtime.', $class));
}
public function addExtension(ExtensionInterface $extension)
@@ -763,7 +802,7 @@
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));
+ throw new \LogicException(\sprintf('Unable to add global "%s" as the runtime or the extensions have already been initialized.', $name));
}
if (null !== $this->resolvedGlobals) {
@@ -775,6 +814,8 @@
/**
* @internal
+ *
+ * @return array<string, mixed>
*/
public function getGlobals(): array
{
@@ -789,21 +830,26 @@
return array_merge($this->extensionSet->getGlobals(), $this->globals);
}
+ public function resetGlobals(): void
+ {
+ $this->resolvedGlobals = null;
+ $this->extensionSet->resetGlobals();
+ }
+
+ /**
+ * @deprecated since Twig 3.14
+ */
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;
- }
- }
+ trigger_deprecation('twig/twig', '3.14', 'The "%s" method is deprecated.', __METHOD__);
- return $context;
+ return $context + $this->getGlobals();
}
/**
* @internal
+ *
+ * @return array<string, array{precedence: int, class: class-string<AbstractUnary>}>
*/
public function getUnaryOperators(): array
{
@@ -812,6 +858,8 @@
/**
* @internal
+ *
+ * @return array<string, array{precedence: int, class: class-string<AbstractBinary>, associativity: ExpressionParser::OPERATOR_*}>
*/
public function getBinaryOperators(): array
{
@@ -827,6 +875,7 @@
self::VERSION,
(int) $this->debug,
(int) $this->strictVariables,
+ $this->useYield ? '1' : '0',
]);
}
}
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
index a68be65..61c309f 100644
--- 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
@@ -53,7 +53,7 @@
* @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)
+ public function __construct(string $message, int $lineno = -1, ?Source $source = null, ?\Throwable $previous = null)
{
parent::__construct('', 0, $previous);
@@ -93,7 +93,7 @@
return $this->name ? new Source($this->sourceCode, $this->name, $this->sourcePath) : null;
}
- public function setSourceContext(Source $source = null): void
+ public function setSourceContext(?Source $source = null): void
{
if (null === $source) {
$this->sourceCode = $this->name = $this->sourcePath = null;
@@ -130,28 +130,28 @@
}
$dot = false;
- if ('.' === substr($this->message, -1)) {
+ if (str_ends_with($this->message, '.')) {
$this->message = substr($this->message, 0, -1);
$dot = true;
}
$questionMark = false;
- if ('?' === substr($this->message, -1)) {
+ if (str_ends_with($this->message, '?')) {
$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);
+ if (\is_string($this->name) || $this->name instanceof \Stringable) {
+ $name = \sprintf('"%s"', $this->name);
} else {
$name = json_encode($this->name);
}
- $this->message .= sprintf(' in %s', $name);
+ $this->message .= \sprintf(' in %s', $name);
}
if ($this->lineno && $this->lineno >= 0) {
- $this->message .= sprintf(' at line %d', $this->lineno);
+ $this->message .= \sprintf(' at line %d', $this->lineno);
}
if ($dot) {
@@ -172,7 +172,7 @@
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);
+ $isEmbedContainer = null === $templateClass ? false : str_starts_with($templateClass, $currentClass);
if (null === $this->name || ($this->name == $trace['object']->getTemplateName() && !$isEmbedContainer)) {
$template = $trace['object'];
$templateClass = \get_class($trace['object']);
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
index 726b330..841b653 100644
--- 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
@@ -30,7 +30,7 @@
$alternatives = [];
foreach ($items as $item) {
$lev = levenshtein($name, $item);
- if ($lev <= \strlen($name) / 3 || false !== strpos($item, $name)) {
+ if ($lev <= \strlen($name) / 3 || str_contains($item, $name)) {
$alternatives[$item] = $lev;
}
}
@@ -41,6 +41,6 @@
asort($alternatives);
- $this->appendMessage(sprintf(' Did you mean "%s"?', implode('", "', array_keys($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
index 70b6eb0..dc4a601 100644
--- 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
@@ -12,20 +12,21 @@
namespace Twig;
+use Twig\Attribute\FirstClassTwigCallableReady;
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\AbstractBinary;
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\AbstractUnary;
use Twig\Node\Expression\Unary\NegUnary;
use Twig\Node\Expression\Unary\NotUnary;
use Twig\Node\Expression\Unary\PosUnary;
@@ -40,23 +41,22 @@
* @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;
+ /** @var array<string, array{precedence: int, class: class-string<AbstractUnary>}> */
private $unaryOperators;
+ /** @var array<string, array{precedence: int, class: class-string<AbstractBinary>, associativity: self::OPERATOR_*}> */
private $binaryOperators;
+ private $readyNodes = [];
- public function __construct(Parser $parser, Environment $env)
- {
- $this->parser = $parser;
- $this->env = $env;
+ public function __construct(
+ private Parser $parser,
+ private Environment $env,
+ ) {
$this->unaryOperators = $env->getUnaryOperators();
$this->binaryOperators = $env->getBinaryOperators();
}
@@ -80,7 +80,7 @@
} elseif (isset($op['callable'])) {
$expr = $op['callable']($this->parser, $expr);
} else {
- $expr1 = $this->parseExpression(self::OPERATOR_LEFT === $op['associativity'] ? $op['precedence'] + 1 : $op['precedence']);
+ $expr1 = $this->parseExpression(self::OPERATOR_LEFT === $op['associativity'] ? $op['precedence'] + 1 : $op['precedence'], true);
$class = $op['class'];
$expr = new $class($expr, $expr1, $token->getLine());
}
@@ -103,52 +103,52 @@
$stream = $this->parser->getStream();
// short array syntax (one argument, no parentheses)?
- if ($stream->look(1)->test(/* Token::ARROW_TYPE */ 12)) {
+ if ($stream->look(1)->test(Token::ARROW_TYPE)) {
$line = $stream->getCurrent()->getLine();
- $token = $stream->expect(/* Token::NAME_TYPE */ 5);
+ $token = $stream->expect(Token::NAME_TYPE);
$names = [new AssignNameExpression($token->getValue(), $token->getLine())];
- $stream->expect(/* Token::ARROW_TYPE */ 12);
+ $stream->expect(Token::ARROW_TYPE);
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, '(')) {
+ if (!$stream->look($i)->test(Token::PUNCTUATION_TYPE, '(')) {
return null;
}
++$i;
while (true) {
// variable name
++$i;
- if (!$stream->look($i)->test(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+ if (!$stream->look($i)->test(Token::PUNCTUATION_TYPE, ',')) {
break;
}
++$i;
}
- if (!$stream->look($i)->test(/* Token::PUNCTUATION_TYPE */ 9, ')')) {
+ if (!$stream->look($i)->test(Token::PUNCTUATION_TYPE, ')')) {
return null;
}
++$i;
- if (!$stream->look($i)->test(/* Token::ARROW_TYPE */ 12)) {
+ if (!$stream->look($i)->test(Token::ARROW_TYPE)) {
return null;
}
// yes, let's parse it properly
- $token = $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '(');
+ $token = $stream->expect(Token::PUNCTUATION_TYPE, '(');
$line = $token->getLine();
$names = [];
while (true) {
- $token = $stream->expect(/* Token::NAME_TYPE */ 5);
+ $token = $stream->expect(Token::NAME_TYPE);
$names[] = new AssignNameExpression($token->getValue(), $token->getLine());
- if (!$stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+ if (!$stream->nextIf(Token::PUNCTUATION_TYPE, ',')) {
break;
}
}
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ')');
- $stream->expect(/* Token::ARROW_TYPE */ 12);
+ $stream->expect(Token::PUNCTUATION_TYPE, ')');
+ $stream->expect(Token::ARROW_TYPE);
return new ArrowFunctionExpression($this->parseExpression(0), new Node($names), $line);
}
@@ -164,10 +164,10 @@
$class = $operator['class'];
return $this->parsePostfixExpression(new $class($expr, $token->getLine()));
- } elseif ($token->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+ } elseif ($token->test(Token::PUNCTUATION_TYPE, '(')) {
$this->parser->getStream()->next();
$expr = $this->parseExpression();
- $this->parser->getStream()->expect(/* Token::PUNCTUATION_TYPE */ 9, ')', 'An opened parenthesis is not properly closed');
+ $this->parser->getStream()->expect(Token::PUNCTUATION_TYPE, ')', 'An opened parenthesis is not properly closed');
return $this->parsePostfixExpression($expr);
}
@@ -177,15 +177,18 @@
private function parseConditionalExpression($expr): AbstractExpression
{
- while ($this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, '?')) {
- if (!$this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+ while ($this->parser->getStream()->nextIf(Token::PUNCTUATION_TYPE, '?')) {
+ if (!$this->parser->getStream()->nextIf(Token::PUNCTUATION_TYPE, ':')) {
$expr2 = $this->parseExpression();
- if ($this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+ if ($this->parser->getStream()->nextIf(Token::PUNCTUATION_TYPE, ':')) {
+ // Ternary operator (expr ? expr2 : expr3)
$expr3 = $this->parseExpression();
} else {
+ // Ternary without else (expr ? expr2)
$expr3 = new ConstantExpression('', $this->parser->getCurrentToken()->getLine());
}
} else {
+ // Ternary without then (expr ?: expr3)
$expr2 = $expr;
$expr3 = $this->parseExpression();
}
@@ -198,19 +201,19 @@
private function isUnary(Token $token): bool
{
- return $token->test(/* Token::OPERATOR_TYPE */ 8) && isset($this->unaryOperators[$token->getValue()]);
+ return $token->test(Token::OPERATOR_TYPE) && isset($this->unaryOperators[$token->getValue()]);
}
private function isBinary(Token $token): bool
{
- return $token->test(/* Token::OPERATOR_TYPE */ 8) && isset($this->binaryOperators[$token->getValue()]);
+ return $token->test(Token::OPERATOR_TYPE) && isset($this->binaryOperators[$token->getValue()]);
}
public function parsePrimaryExpression()
{
$token = $this->parser->getCurrentToken();
switch ($token->getType()) {
- case /* Token::NAME_TYPE */ 5:
+ case Token::NAME_TYPE:
$this->parser->getStream()->next();
switch ($token->getValue()) {
case 'true':
@@ -239,17 +242,17 @@
}
break;
- case /* Token::NUMBER_TYPE */ 6:
+ case Token::NUMBER_TYPE:
$this->parser->getStream()->next();
$node = new ConstantExpression($token->getValue(), $token->getLine());
break;
- case /* Token::STRING_TYPE */ 7:
- case /* Token::INTERPOLATION_START_TYPE */ 10:
+ case Token::STRING_TYPE:
+ case Token::INTERPOLATION_START_TYPE:
$node = $this->parseStringExpression();
break;
- case /* Token::OPERATOR_TYPE */ 8:
+ case Token::OPERATOR_TYPE:
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();
@@ -260,7 +263,7 @@
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());
+ throw new SyntaxError(\sprintf('Unexpected unary operator "%s".', $token->getValue()), $token->getLine(), $this->parser->getStream()->getSourceContext());
}
$this->parser->getStream()->next();
@@ -272,14 +275,14 @@
// 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());
+ if ($token->test(Token::PUNCTUATION_TYPE, '[')) {
+ $node = $this->parseSequenceExpression();
+ } elseif ($token->test(Token::PUNCTUATION_TYPE, '{')) {
+ $node = $this->parseMappingExpression();
+ } elseif ($token->test(Token::OPERATOR_TYPE, '=') && ('==' === $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());
+ throw new SyntaxError(\sprintf('Unexpected token "%s" of value "%s".', Token::typeToEnglish($token->getType()), $token->getValue()), $token->getLine(), $this->parser->getStream()->getSourceContext());
}
}
@@ -294,12 +297,12 @@
// 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)) {
+ if ($nextCanBeString && $token = $stream->nextIf(Token::STRING_TYPE)) {
$nodes[] = new ConstantExpression($token->getValue(), $token->getLine());
$nextCanBeString = false;
- } elseif ($stream->nextIf(/* Token::INTERPOLATION_START_TYPE */ 10)) {
+ } elseif ($stream->nextIf(Token::INTERPOLATION_START_TYPE)) {
$nodes[] = $this->parseExpression();
- $stream->expect(/* Token::INTERPOLATION_END_TYPE */ 11);
+ $stream->expect(Token::INTERPOLATION_END_TYPE);
$nextCanBeString = true;
} else {
break;
@@ -314,56 +317,91 @@
return $expr;
}
+ /**
+ * @deprecated since 3.11, use parseSequenceExpression() instead
+ */
public function parseArrayExpression()
{
+ trigger_deprecation('twig/twig', '3.11', 'Calling "%s()" is deprecated, use "parseSequenceExpression()" instead.', __METHOD__);
+
+ return $this->parseSequenceExpression();
+ }
+
+ public function parseSequenceExpression()
+ {
$stream = $this->parser->getStream();
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '[', 'An array element was expected');
+ $stream->expect(Token::PUNCTUATION_TYPE, '[', 'A sequence element was expected');
$node = new ArrayExpression([], $stream->getCurrent()->getLine());
$first = true;
- while (!$stream->test(/* Token::PUNCTUATION_TYPE */ 9, ']')) {
+ while (!$stream->test(Token::PUNCTUATION_TYPE, ']')) {
if (!$first) {
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ',', 'An array element must be followed by a comma');
+ $stream->expect(Token::PUNCTUATION_TYPE, ',', 'A sequence element must be followed by a comma');
// trailing ,?
- if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, ']')) {
+ if ($stream->test(Token::PUNCTUATION_TYPE, ']')) {
break;
}
}
$first = false;
- $node->addElement($this->parseExpression());
+ if ($stream->test(Token::SPREAD_TYPE)) {
+ $stream->next();
+ $expr = $this->parseExpression();
+ $expr->setAttribute('spread', true);
+ $node->addElement($expr);
+ } else {
+ $node->addElement($this->parseExpression());
+ }
}
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ']', 'An opened array is not properly closed');
+ $stream->expect(Token::PUNCTUATION_TYPE, ']', 'An opened sequence is not properly closed');
return $node;
}
+ /**
+ * @deprecated since 3.11, use parseMappingExpression() instead
+ */
public function parseHashExpression()
{
+ trigger_deprecation('twig/twig', '3.11', 'Calling "%s()" is deprecated, use "parseMappingExpression()" instead.', __METHOD__);
+
+ return $this->parseMappingExpression();
+ }
+
+ public function parseMappingExpression()
+ {
$stream = $this->parser->getStream();
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, '{', 'A hash element was expected');
+ $stream->expect(Token::PUNCTUATION_TYPE, '{', 'A mapping element was expected');
$node = new ArrayExpression([], $stream->getCurrent()->getLine());
$first = true;
- while (!$stream->test(/* Token::PUNCTUATION_TYPE */ 9, '}')) {
+ while (!$stream->test(Token::PUNCTUATION_TYPE, '}')) {
if (!$first) {
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ',', 'A hash value must be followed by a comma');
+ $stream->expect(Token::PUNCTUATION_TYPE, ',', 'A mapping value must be followed by a comma');
// trailing ,?
- if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '}')) {
+ if ($stream->test(Token::PUNCTUATION_TYPE, '}')) {
break;
}
}
$first = false;
- // a hash key can be:
+ if ($stream->test(Token::SPREAD_TYPE)) {
+ $stream->next();
+ $value = $this->parseExpression();
+ $value->setAttribute('spread', true);
+ $node->addElement($value);
+ continue;
+ }
+
+ // a mapping 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)) {
+ if ($token = $stream->nextIf(Token::NAME_TYPE)) {
$key = new ConstantExpression($token->getValue(), $token->getLine());
// {a} is a shortcut for {a:a}
@@ -372,22 +410,22 @@
$node->addElement($value, $key);
continue;
}
- } elseif (($token = $stream->nextIf(/* Token::STRING_TYPE */ 7)) || $token = $stream->nextIf(/* Token::NUMBER_TYPE */ 6)) {
+ } elseif (($token = $stream->nextIf(Token::STRING_TYPE)) || $token = $stream->nextIf(Token::NUMBER_TYPE)) {
$key = new ConstantExpression($token->getValue(), $token->getLine());
- } elseif ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+ } elseif ($stream->test(Token::PUNCTUATION_TYPE, '(')) {
$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());
+ throw new SyntaxError(\sprintf('A mapping 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 (:)');
+ $stream->expect(Token::PUNCTUATION_TYPE, ':', 'A mapping 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');
+ $stream->expect(Token::PUNCTUATION_TYPE, '}', 'An opened mapping is not properly closed');
return $node;
}
@@ -396,7 +434,7 @@
{
while (true) {
$token = $this->parser->getCurrentToken();
- if (/* Token::PUNCTUATION_TYPE */ 9 == $token->getType()) {
+ if (Token::PUNCTUATION_TYPE == $token->getType()) {
if ('.' == $token->getValue() || '[' == $token->getValue()) {
$node = $this->parseSubscriptExpression($node);
} elseif ('|' == $token->getValue()) {
@@ -414,50 +452,37 @@
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 (null !== $alias = $this->parser->getImportedSymbol('function', $name)) {
+ $arguments = new ArrayExpression([], $line);
+ foreach ($this->parseArguments() as $n) {
+ $arguments->addElement($n);
+ }
- 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());
- }
+ $node = new MethodCallExpression($alias['node'], $alias['name'], $arguments, $line);
+ $node->setAttribute('safe', true);
- 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);
+ return $node;
}
+
+ $args = $this->parseArguments(true);
+ $function = $this->getFunction($name, $line);
+
+ if ($function->getParserCallable()) {
+ $fakeNode = new Node(lineno: $line);
+ $fakeNode->setSourceContext($this->parser->getStream()->getSourceContext());
+
+ return ($function->getParserCallable())($this->parser, $fakeNode, $args, $line);
+ }
+
+ if (!isset($this->readyNodes[$class = $function->getNodeClass()])) {
+ $this->readyNodes[$class] = (bool) (new \ReflectionClass($class))->getConstructor()->getAttributes(FirstClassTwigCallableReady::class);
+ }
+
+ if (!$ready = $this->readyNodes[$class]) {
+ trigger_deprecation('twig/twig', '3.12', 'Twig node "%s" is not marked as ready for passing a "TwigFunction" in the constructor instead of its name; please update your code and then add #[FirstClassTwigCallableReady] attribute to the constructor.', $class);
+ }
+
+ return new $class($ready ? $function : $function->getName(), $args, $line);
}
public function parseSubscriptExpression($node)
@@ -470,29 +495,25 @@
if ('.' == $token->getValue()) {
$token = $stream->next();
if (
- /* Token::NAME_TYPE */ 5 == $token->getType()
+ Token::NAME_TYPE == $token->getType()
||
- /* Token::NUMBER_TYPE */ 6 == $token->getType()
+ Token::NUMBER_TYPE == $token->getType()
||
- (/* Token::OPERATOR_TYPE */ 8 == $token->getType() && preg_match(Lexer::REGEX_NAME, $token->getValue()))
+ (Token::OPERATOR_TYPE == $token->getType() && preg_match(Lexer::REGEX_NAME, $token->getValue()))
) {
$arg = new ConstantExpression($token->getValue(), $lineno);
- if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+ if ($stream->test(Token::PUNCTUATION_TYPE, '(')) {
$type = Template::METHOD_CALL;
foreach ($this->parseArguments() as $n) {
$arguments->addElement($n);
}
}
} else {
- throw new SyntaxError(sprintf('Expected name or number, got value "%s" of type %s.', $token->getValue(), Token::typeToEnglish($token->getType())), $lineno, $stream->getSourceContext());
+ throw new SyntaxError(\sprintf('Expected name or number, got value "%s" of type %s.', $token->getValue(), Token::typeToEnglish($token->getType())), $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);
@@ -505,34 +526,34 @@
// slice?
$slice = false;
- if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+ if ($stream->test(Token::PUNCTUATION_TYPE, ':')) {
$slice = true;
$arg = new ConstantExpression(0, $token->getLine());
} else {
$arg = $this->parseExpression();
}
- if ($stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ':')) {
+ if ($stream->nextIf(Token::PUNCTUATION_TYPE, ':')) {
$slice = true;
}
if ($slice) {
- if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, ']')) {
+ if ($stream->test(Token::PUNCTUATION_TYPE, ']')) {
$length = new ConstantExpression(null, $token->getLine());
} else {
$length = $this->parseExpression();
}
- $class = $this->getFilterNodeClass('slice', $token->getLine());
+ $filter = $this->getFilter('slice', $token->getLine());
$arguments = new Node([$arg, $length]);
- $filter = new $class($node, new ConstantExpression('slice', $token->getLine()), $arguments, $token->getLine());
+ $filter = new ($filter->getNodeClass())($node, $filter, $arguments, $token->getLine());
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ']');
+ $stream->expect(Token::PUNCTUATION_TYPE, ']');
return $filter;
}
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ']');
+ $stream->expect(Token::PUNCTUATION_TYPE, ']');
}
return new GetAttrExpression($node, $arg, $arguments, $type, $lineno);
@@ -545,23 +566,35 @@
return $this->parseFilterExpressionRaw($node);
}
- public function parseFilterExpressionRaw($node, $tag = null)
+ public function parseFilterExpressionRaw($node)
{
- while (true) {
- $token = $this->parser->getStream()->expect(/* Token::NAME_TYPE */ 5);
+ if (\func_num_args() > 1) {
+ trigger_deprecation('twig/twig', '3.12', 'Passing a second argument to "%s()" is deprecated.', __METHOD__);
+ }
- $name = new ConstantExpression($token->getValue(), $token->getLine());
- if (!$this->parser->getStream()->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+ while (true) {
+ $token = $this->parser->getStream()->expect(Token::NAME_TYPE);
+
+ if (!$this->parser->getStream()->test(Token::PUNCTUATION_TYPE, '(')) {
$arguments = new Node();
} else {
$arguments = $this->parseArguments(true, false, true);
}
- $class = $this->getFilterNodeClass($name->getAttribute('value'), $token->getLine());
+ $filter = $this->getFilter($token->getValue(), $token->getLine());
- $node = new $class($node, $name, $arguments, $token->getLine(), $tag);
+ $ready = true;
+ if (!isset($this->readyNodes[$class = $filter->getNodeClass()])) {
+ $this->readyNodes[$class] = (bool) (new \ReflectionClass($class))->getConstructor()->getAttributes(FirstClassTwigCallableReady::class);
+ }
- if (!$this->parser->getStream()->test(/* Token::PUNCTUATION_TYPE */ 9, '|')) {
+ if (!$ready = $this->readyNodes[$class]) {
+ trigger_deprecation('twig/twig', '3.12', 'Twig node "%s" is not marked as ready for passing a "TwigFilter" in the constructor instead of its name; please update your code and then add #[FirstClassTwigCallableReady] attribute to the constructor.', $class);
+ }
+
+ $node = new $class($node, $ready ? $filter : new ConstantExpression($filter->getName(), $token->getLine()), $arguments, $token->getLine());
+
+ if (!$this->parser->getStream()->test(Token::PUNCTUATION_TYPE, '|')) {
break;
}
@@ -575,7 +608,7 @@
* Parses arguments.
*
* @param bool $namedArguments Whether to allow named arguments or not
- * @param bool $definition Whether we are parsing arguments for a function definition
+ * @param bool $definition Whether we are parsing arguments for a function (or macro) definition
*
* @return Node
*
@@ -586,28 +619,28 @@
$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, ')')) {
+ $stream->expect(Token::PUNCTUATION_TYPE, '(', 'A list of arguments must begin with an opening parenthesis');
+ while (!$stream->test(Token::PUNCTUATION_TYPE, ')')) {
if (!empty($args)) {
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ',', 'Arguments must be separated by a comma');
+ $stream->expect(Token::PUNCTUATION_TYPE, ',', '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, ')')) {
+ if ($stream->test(Token::PUNCTUATION_TYPE, ')')) {
break;
}
}
if ($definition) {
- $token = $stream->expect(/* Token::NAME_TYPE */ 5, null, 'An argument must be a name');
+ $token = $stream->expect(Token::NAME_TYPE, 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 ($namedArguments && (($token = $stream->nextIf(Token::OPERATOR_TYPE, '=')) || ($token = $stream->nextIf(Token::PUNCTUATION_TYPE, ':')))) {
if (!$value instanceof NameExpression) {
- throw new SyntaxError(sprintf('A parameter name must be a string, "%s" given.', \get_class($value)), $token->getLine(), $stream->getSourceContext());
+ throw new SyntaxError(\sprintf('A parameter name must be a string, "%s" given.', \get_class($value)), $token->getLine(), $stream->getSourceContext());
}
$name = $value->getAttribute('name');
@@ -615,7 +648,7 @@
$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());
+ throw new SyntaxError('A default value for an argument must be a constant (a boolean, a string, a number, a sequence, or a mapping).', $token->getLine(), $stream->getSourceContext());
}
} else {
$value = $this->parseExpression(0, $allowArrow);
@@ -626,6 +659,7 @@
if (null === $name) {
$name = $value->getAttribute('name');
$value = new ConstantExpression(null, $this->parser->getCurrentToken()->getLine());
+ $value->setAttribute('is_implicit', true);
}
$args[$name] = $value;
} else {
@@ -636,7 +670,7 @@
}
}
}
- $stream->expect(/* Token::PUNCTUATION_TYPE */ 9, ')', 'A list of arguments must be closed by a parenthesis');
+ $stream->expect(Token::PUNCTUATION_TYPE, ')', 'A list of arguments must be closed by a parenthesis');
return new Node($args);
}
@@ -647,19 +681,19 @@
$targets = [];
while (true) {
$token = $this->parser->getCurrentToken();
- if ($stream->test(/* Token::OPERATOR_TYPE */ 8) && preg_match(Lexer::REGEX_NAME, $token->getValue())) {
+ if ($stream->test(Token::OPERATOR_TYPE) && 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');
+ $stream->expect(Token::NAME_TYPE, 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());
+ 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, ',')) {
+ if (!$stream->nextIf(Token::PUNCTUATION_TYPE, ',')) {
break;
}
}
@@ -672,7 +706,7 @@
$targets = [];
while (true) {
$targets[] = $this->parseExpression();
- if (!$this->parser->getStream()->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+ if (!$this->parser->getStream()->nextIf(Token::PUNCTUATION_TYPE, ',')) {
break;
}
}
@@ -688,121 +722,115 @@
private function parseTestExpression(Node $node): TestExpression
{
$stream = $this->parser->getStream();
- list($name, $test) = $this->getTest($node->getTemplateLine());
+ $test = $this->getTest($node->getTemplateLine());
- $class = $this->getTestNodeClass($test);
$arguments = null;
- if ($stream->test(/* Token::PUNCTUATION_TYPE */ 9, '(')) {
+ if ($stream->test(Token::PUNCTUATION_TYPE, '(')) {
$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'))) {
+ if ('defined' === $test->getName() && $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];
+ $ready = $test instanceof TwigTest;
+ if (!isset($this->readyNodes[$class = $test->getNodeClass()])) {
+ $this->readyNodes[$class] = (bool) (new \ReflectionClass($class))->getConstructor()->getAttributes(FirstClassTwigCallableReady::class);
}
- if ($stream->test(/* Token::NAME_TYPE */ 5)) {
+ if (!$ready = $this->readyNodes[$class]) {
+ trigger_deprecation('twig/twig', '3.12', 'Twig node "%s" is not marked as ready for passing a "TwigTest" in the constructor instead of its name; please update your code and then add #[FirstClassTwigCallableReady] attribute to the constructor.', $class);
+ }
+
+ return new $class($node, $ready ? $test : $test->getName(), $arguments, $this->parser->getCurrentToken()->getLine());
+ }
+
+ private function getTest(int $line): TwigTest
+ {
+ $stream = $this->parser->getStream();
+ $name = $stream->expect(Token::NAME_TYPE)->getValue();
+
+ if ($stream->test(Token::NAME_TYPE)) {
// try 2-words tests
$name = $name.' '.$this->parser->getCurrentToken()->getValue();
if ($test = $this->env->getTest($name)) {
$stream->next();
-
- return [$name, $test];
}
+ } else {
+ $test = $this->env->getTest($name);
}
- $e = new SyntaxError(sprintf('Unknown "%s" test.', $name), $line, $stream->getSourceContext());
- $e->addSuggestions($name, array_keys($this->env->getTests()));
+ if (!$test) {
+ $e = new SyntaxError(\sprintf('Unknown "%s" test.', $name), $line, $stream->getSourceContext());
+ $e->addSuggestions($name, array_keys($this->env->getTests()));
- throw $e;
- }
+ throw $e;
+ }
- private function getTestNodeClass(TwigTest $test): string
- {
if ($test->isDeprecated()) {
$stream = $this->parser->getStream();
- $message = sprintf('Twig Test "%s" is deprecated', $test->getName());
+ $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());
+ $message .= \sprintf('. Use "%s" instead', $test->getAlternative());
}
$src = $stream->getSourceContext();
- $message .= sprintf(' in %s at line %d.', $src->getPath() ?: $src->getName(), $stream->getCurrent()->getLine());
+ $message .= \sprintf(' in %s at line %d.', $src->getPath() ?: $src->getName(), $stream->getCurrent()->getLine());
- @trigger_error($message, \E_USER_DEPRECATED);
+ trigger_deprecation($test->getDeprecatingPackage(), $test->getDeprecatedVersion(), $message);
}
- return $test->getNodeClass();
+ return $test;
}
- private function getFunctionNodeClass(string $name, int $line): string
+ private function getFunction(string $name, int $line): TwigFunction
{
if (!$function = $this->env->getFunction($name)) {
- $e = new SyntaxError(sprintf('Unknown "%s" function.', $name), $line, $this->parser->getStream()->getSourceContext());
+ $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());
- }
+ $message = \sprintf('Twig Function "%s" is deprecated', $function->getName());
if ($function->getAlternative()) {
- $message .= sprintf('. Use "%s" instead', $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);
+ $message .= \sprintf(' in %s at line %d.', $src->getPath() ?: $src->getName(), $line);
- @trigger_error($message, \E_USER_DEPRECATED);
+ trigger_deprecation($function->getDeprecatingPackage(), $function->getDeprecatedVersion(), $message);
}
- return $function->getNodeClass();
+ return $function;
}
- private function getFilterNodeClass(string $name, int $line): string
+ private function getFilter(string $name, int $line): TwigFilter
{
if (!$filter = $this->env->getFilter($name)) {
- $e = new SyntaxError(sprintf('Unknown "%s" filter.', $name), $line, $this->parser->getStream()->getSourceContext());
+ $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());
- }
+ $message = \sprintf('Twig Filter "%s" is deprecated', $filter->getName());
if ($filter->getAlternative()) {
- $message .= sprintf('. Use "%s" instead', $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);
+ $message .= \sprintf(' in %s at line %d.', $src->getPath() ?: $src->getName(), $line);
- @trigger_error($message, \E_USER_DEPRECATED);
+ trigger_deprecation($filter->getDeprecatingPackage(), $filter->getDeprecatedVersion(), $message);
}
- return $filter->getNodeClass();
+ return $filter;
}
// checks that the node only contains "constant" elements
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
index 422925f..a1b083b 100644
--- 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
@@ -40,6 +40,6 @@
public function getOperators()
{
- return [];
+ 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
index b779858..3ed27a3 100644
--- 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
@@ -9,8 +9,15 @@
* file that was distributed with this source code.
*/
-namespace Twig\Extension {
+namespace Twig\Extension;
+
+use Twig\Environment;
+use Twig\Error\LoaderError;
+use Twig\Error\RuntimeError;
+use Twig\Error\SyntaxError;
use Twig\ExpressionParser;
+use Twig\Markup;
+use Twig\Node\Expression\AbstractExpression;
use Twig\Node\Expression\Binary\AddBinary;
use Twig\Node\Expression\Binary\AndBinary;
use Twig\Node\Expression\Binary\BitwiseAndBinary;
@@ -23,6 +30,8 @@
use Twig\Node\Expression\Binary\FloorDivBinary;
use Twig\Node\Expression\Binary\GreaterBinary;
use Twig\Node\Expression\Binary\GreaterEqualBinary;
+use Twig\Node\Expression\Binary\HasEveryBinary;
+use Twig\Node\Expression\Binary\HasSomeBinary;
use Twig\Node\Expression\Binary\InBinary;
use Twig\Node\Expression\Binary\LessBinary;
use Twig\Node\Expression\Binary\LessEqualBinary;
@@ -37,8 +46,12 @@
use Twig\Node\Expression\Binary\SpaceshipBinary;
use Twig\Node\Expression\Binary\StartsWithBinary;
use Twig\Node\Expression\Binary\SubBinary;
+use Twig\Node\Expression\BlockReferenceExpression;
use Twig\Node\Expression\Filter\DefaultFilter;
+use Twig\Node\Expression\FunctionNode\EnumCasesFunction;
+use Twig\Node\Expression\GetAttrExpression;
use Twig\Node\Expression\NullCoalesceExpression;
+use Twig\Node\Expression\ParentExpression;
use Twig\Node\Expression\Test\ConstantTest;
use Twig\Node\Expression\Test\DefinedTest;
use Twig\Node\Expression\Test\DivisiblebyTest;
@@ -49,7 +62,12 @@
use Twig\Node\Expression\Unary\NegUnary;
use Twig\Node\Expression\Unary\NotUnary;
use Twig\Node\Expression\Unary\PosUnary;
+use Twig\Node\Node;
use Twig\NodeVisitor\MacroAutoImportNodeVisitor;
+use Twig\Parser;
+use Twig\Source;
+use Twig\Template;
+use Twig\TemplateWrapper;
use Twig\TokenParser\ApplyTokenParser;
use Twig\TokenParser\BlockTokenParser;
use Twig\TokenParser\DeprecatedTokenParser;
@@ -64,11 +82,13 @@
use Twig\TokenParser\IncludeTokenParser;
use Twig\TokenParser\MacroTokenParser;
use Twig\TokenParser\SetTokenParser;
+use Twig\TokenParser\TypesTokenParser;
use Twig\TokenParser\UseTokenParser;
use Twig\TokenParser\WithTokenParser;
use Twig\TwigFilter;
use Twig\TwigFunction;
use Twig\TwigTest;
+use Twig\Util\CallableArgumentsExtractor;
final class CoreExtension extends AbstractExtension
{
@@ -79,8 +99,8 @@
/**
* 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
+ * @param string|null $format The default date format string
+ * @param string|null $dateIntervalFormat The default date interval format string
*/
public function setDateFormat($format = null, $dateIntervalFormat = null)
{
@@ -163,6 +183,7 @@
new ImportTokenParser(),
new FromTokenParser(),
new SetTokenParser(),
+ new TypesTokenParser(),
new FlushTokenParser(),
new DoTokenParser(),
new EmbedTokenParser(),
@@ -175,65 +196,71 @@
{
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', 'twig_sprintf'),
- new TwigFilter('replace', 'twig_replace_filter'),
- new TwigFilter('number_format', 'twig_number_format_filter', ['needs_environment' => true]),
+ new TwigFilter('date', [$this, 'formatDate']),
+ new TwigFilter('date_modify', [$this, 'modifyDate']),
+ new TwigFilter('format', [self::class, 'sprintf']),
+ new TwigFilter('replace', [self::class, 'replace']),
+ new TwigFilter('number_format', [$this, 'formatNumber']),
new TwigFilter('abs', 'abs'),
- new TwigFilter('round', 'twig_round'),
+ new TwigFilter('round', [self::class, 'round']),
// encoding
- new TwigFilter('url_encode', 'twig_urlencode_filter'),
+ new TwigFilter('url_encode', [self::class, 'urlencode']),
new TwigFilter('json_encode', 'json_encode'),
- new TwigFilter('convert_encoding', 'twig_convert_encoding'),
+ new TwigFilter('convert_encoding', [self::class, 'convertEncoding']),
// 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', 'twig_striptags'),
- new TwigFilter('trim', 'twig_trim_filter'),
- new TwigFilter('nl2br', 'twig_nl2br', ['pre_escape' => 'html', 'is_safe' => ['html']]),
- new TwigFilter('spaceless', 'twig_spaceless', ['is_safe' => ['html']]),
+ new TwigFilter('title', [self::class, 'titleCase'], ['needs_charset' => true]),
+ new TwigFilter('capitalize', [self::class, 'capitalize'], ['needs_charset' => true]),
+ new TwigFilter('upper', [self::class, 'upper'], ['needs_charset' => true]),
+ new TwigFilter('lower', [self::class, 'lower'], ['needs_charset' => true]),
+ new TwigFilter('striptags', [self::class, 'striptags']),
+ new TwigFilter('trim', [self::class, 'trim']),
+ new TwigFilter('nl2br', [self::class, 'nl2br'], ['pre_escape' => 'html', 'is_safe' => ['html']]),
+ new TwigFilter('spaceless', [self::class, 'spaceless'], ['is_safe' => ['html'], 'deprecated' => '3.12', 'deprecating_package' => 'twig/twig']),
// array helpers
- new TwigFilter('join', 'twig_join_filter'),
- new TwigFilter('split', 'twig_split_filter', ['needs_environment' => true]),
- new TwigFilter('sort', 'twig_sort_filter', ['needs_environment' => true]),
- 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]),
+ new TwigFilter('join', [self::class, 'join']),
+ new TwigFilter('split', [self::class, 'split'], ['needs_charset' => true]),
+ new TwigFilter('sort', [self::class, 'sort'], ['needs_environment' => true]),
+ new TwigFilter('merge', [self::class, 'merge']),
+ new TwigFilter('batch', [self::class, 'batch']),
+ new TwigFilter('column', [self::class, 'column']),
+ new TwigFilter('filter', [self::class, 'filter'], ['needs_environment' => true]),
+ new TwigFilter('map', [self::class, 'map'], ['needs_environment' => true]),
+ new TwigFilter('reduce', [self::class, 'reduce'], ['needs_environment' => true]),
+ new TwigFilter('find', [self::class, 'find'], ['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]),
+ new TwigFilter('reverse', [self::class, 'reverse'], ['needs_charset' => true]),
+ new TwigFilter('shuffle', [self::class, 'shuffle'], ['needs_charset' => true]),
+ new TwigFilter('length', [self::class, 'length'], ['needs_charset' => true]),
+ new TwigFilter('slice', [self::class, 'slice'], ['needs_charset' => true]),
+ new TwigFilter('first', [self::class, 'first'], ['needs_charset' => true]),
+ new TwigFilter('last', [self::class, 'last'], ['needs_charset' => true]),
// iteration and runtime
- new TwigFilter('default', '_twig_default_filter', ['node_class' => DefaultFilter::class]),
- new TwigFilter('keys', 'twig_get_array_keys_filter'),
+ new TwigFilter('default', [self::class, 'default'], ['node_class' => DefaultFilter::class]),
+ new TwigFilter('keys', [self::class, 'keys']),
];
}
public function getFunctions(): array
{
return [
+ new TwigFunction('parent', null, ['parser_callable' => [self::class, 'parseParentFunction']]),
+ new TwigFunction('block', null, ['parser_callable' => [self::class, 'parseBlockFunction']]),
+ new TwigFunction('attribute', null, ['parser_callable' => [self::class, 'parseAttributeFunction']]),
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']]),
+ new TwigFunction('constant', [self::class, 'constant']),
+ new TwigFunction('cycle', [self::class, 'cycle']),
+ new TwigFunction('random', [self::class, 'random'], ['needs_charset' => true]),
+ new TwigFunction('date', [$this, 'convertDate']),
+ new TwigFunction('include', [self::class, 'include'], ['needs_environment' => true, 'needs_context' => true, 'is_safe' => ['all']]),
+ new TwigFunction('source', [self::class, 'source'], ['needs_environment' => true, 'is_safe' => ['all']]),
+ new TwigFunction('enum_cases', [self::class, 'enumCases'], ['node_class' => EnumCasesFunction::class]),
];
}
@@ -248,8 +275,10 @@
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'),
+ new TwigTest('empty', [self::class, 'testEmpty']),
+ new TwigTest('iterable', 'is_iterable'),
+ new TwigTest('sequence', [self::class, 'testSequence']),
+ new TwigTest('mapping', [self::class, 'testMapping']),
];
}
@@ -284,6 +313,8 @@
'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],
+ 'has some' => ['precedence' => 20, 'class' => HasSomeBinary::class, 'associativity' => ExpressionParser::OPERATOR_LEFT],
+ 'has every' => ['precedence' => 20, 'class' => HasEveryBinary::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],
@@ -299,193 +330,226 @@
],
];
}
-}
-}
-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 sequence.
+ *
+ * @param array|\ArrayAccess $values A non-empty sequence of values
+ * @param positive-int $position The position of the value to return in the cycle
+ *
+ * @return mixed The value at the given position in the sequence, wrapping around as needed
+ *
+ * @internal
+ */
+ public static function cycle($values, $position): mixed
+ {
+ if (!\is_array($values)) {
+ if (!$values instanceof \ArrayAccess) {
+ throw new RuntimeError('The "cycle" function expects an array or "ArrayAccess" as first argument.');
+ }
-/**
- * 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;
+ if (!is_countable($values)) {
+ // To be uncommented in 4.0
+ // throw new RuntimeError('The "cycle" function expects a countable sequence as first argument.');
+
+ trigger_deprecation('twig/twig', '3.12', 'Passing a non-countable sequence of values to "%s()" is deprecated.', __METHOD__);
+
+ return $values;
+ }
+
+ $values = self::toArray($values, false);
+ }
+
+ if (!$count = \count($values)) {
+ throw new RuntimeError('The "cycle" function does not work on empty sequences.');
+ }
+
+ return $values[$position % $count];
}
- 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
+ *
+ * @return mixed A random value from the given sequence
+ *
+ * @throws RuntimeError when $values is an empty array (does not apply to an empty string which is returned as is)
+ *
+ * @internal
+ */
+ public static function random(string $charset, $values = null, $max = null)
+ {
+ if (null === $values) {
+ return null === $max ? mt_rand() : mt_rand(0, (int) $max);
+ }
-/**
- * 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, (int) $max);
- }
-
- if (\is_int($values) || \is_float($values)) {
- if (null === $max) {
- if ($values < 0) {
- $max = 0;
- $min = $values;
+ if (\is_int($values) || \is_float($values)) {
+ if (null === $max) {
+ if ($values < 0) {
+ $max = 0;
+ $min = $values;
+ } else {
+ $max = $values;
+ $min = 0;
+ }
} else {
- $max = $values;
- $min = 0;
+ $min = $values;
}
+
+ return mt_rand((int) $min, (int) $max);
+ }
+
+ if (\is_string($values)) {
+ if ('' === $values) {
+ return '';
+ }
+
+ if ('UTF-8' !== $charset) {
+ $values = self::convertEncoding($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] = self::convertEncoding($value, $charset, 'UTF-8');
+ }
+ }
+ }
+
+ if (!is_iterable($values)) {
+ return $values;
+ }
+
+ $values = self::toArray($values);
+
+ if (0 === \count($values)) {
+ throw new RuntimeError('The random function cannot pick from an empty sequence/mapping.');
+ }
+
+ return $values[array_rand($values, 1)];
+ }
+
+ /**
+ * Formats a date.
+ *
+ * {{ 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
+ */
+ public function formatDate($date, $format = null, $timezone = null): string
+ {
+ if (null === $format) {
+ $formats = $this->getDateFormat();
+ $format = $date instanceof \DateInterval ? $formats[1] : $formats[0];
+ }
+
+ if ($date instanceof \DateInterval) {
+ return $date->format($format);
+ }
+
+ return $this->convertDate($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 \DateTime|\DateTimeImmutable
+ *
+ * @internal
+ */
+ public function modifyDate($date, $modifier)
+ {
+ return $this->convertDate($date, false)->modify($modifier);
+ }
+
+ /**
+ * Returns a formatted string.
+ *
+ * @param string|null $format
+ * @param ...$values
+ *
+ * @internal
+ */
+ public static function sprintf($format, ...$values): string
+ {
+ return \sprintf($format ?? '', ...$values);
+ }
+
+ /**
+ * @internal
+ */
+ public static function dateConverter(Environment $env, $date, $format = null, $timezone = null): string
+ {
+ return $env->getExtension(self::class)->formatDate($date, $format, $timezone);
+ }
+
+ /**
+ * 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 \DateTime|\DateTimeImmutable
+ */
+ public function convertDate($date = null, $timezone = null)
+ {
+ // determine the timezone
+ if (false !== $timezone) {
+ if (null === $timezone) {
+ $timezone = $this->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 \DateTime) {
+ $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 : $this->getTimezone());
+ }
+
+ $asString = (string) $date;
+ if (ctype_digit($asString) || (!empty($asString) && '-' === $asString[0] && ctype_digit(substr($asString, 1)))) {
+ $date = new \DateTime('@'.$date);
} else {
- $min = $values;
- $max = $max;
+ $date = new \DateTime($date, $this->getTimezone());
}
- return mt_rand((int) $min, (int) $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);
-}
-
-/**
- * Returns a formatted string.
- *
- * @param string|null $format
- * @param ...$values
- *
- * @return string
- */
-function twig_sprintf($format, ...$values)
-{
- return sprintf($format ?? '', ...$values);
-}
-
-/**
- * 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);
}
@@ -493,968 +557,1086 @@
return $date;
}
- if (null === $date || 'now' === $date) {
- if (null === $date) {
- $date = 'now';
+ /**
+ * Replaces strings within a string.
+ *
+ * @param string|null $str String to replace in
+ * @param array|\Traversable $from Replace values
+ *
+ * @internal
+ */
+ public static function replace($str, $from): string
+ {
+ if (!is_iterable($from)) {
+ throw new RuntimeError(\sprintf('The "replace" filter expects a sequence/mapping or "Traversable" as replace values, got "%s".', \is_object($from) ? \get_class($from) : \gettype($from)));
}
- return new \DateTime($date, false !== $timezone ? $timezone : $env->getExtension(CoreExtension::class)->getTimezone());
+ return strtr($str ?? '', self::toArray($from));
}
- $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());
- }
+ /**
+ * Rounds a number.
+ *
+ * @param int|float|string|null $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
+ *
+ * @internal
+ */
+ public static function round($value, $precision = 0, $method = 'common')
+ {
+ $value = (float) $value;
- if (false !== $timezone) {
- $date->setTimezone($timezone);
- }
-
- return $date;
-}
-
-/**
- * Replaces strings within a string.
- *
- * @param string|null $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|string|null $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')
-{
- $value = (float) $value;
-
- 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|null $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 ('common' === $method) {
+ return round($value, $precision);
}
- 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 [];
+ 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;
+ }
+
+ /**
+ * Formats a number.
+ *
+ * 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|null $decimal the number of decimal points to display
+ * @param string|null $decimalPoint the character(s) to use for the decimal point
+ * @param string|null $thousandSep the character(s) to use for the thousands separator
+ */
+ public function formatNumber($number, $decimal = null, $decimalPoint = null, $thousandSep = null): string
+ {
+ $defaults = $this->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|null $url A URL or an array of query parameters
+ *
+ * @internal
+ */
+ public static function urlencode($url): string
+ {
+ if (\is_array($url)) {
+ return http_build_query($url, '', '&', \PHP_QUERY_RFC3986);
+ }
+
+ return rawurlencode($url ?? '');
+ }
+
+ /**
+ * Merges any number of arrays or Traversable objects.
+ *
+ * {% set items = { 'apple': 'fruit', 'orange': 'fruit' } %}
+ *
+ * {% set items = items|merge({ 'peugeot': 'car' }, { 'banana': 'fruit' }) %}
+ *
+ * {# items now contains { 'apple': 'fruit', 'orange': 'fruit', 'peugeot': 'car', 'banana': 'fruit' } #}
+ *
+ * @param array|\Traversable ...$arrays Any number of arrays or Traversable objects to merge
+ *
+ * @internal
+ */
+ public static function merge(...$arrays): array
+ {
+ $result = [];
+
+ foreach ($arrays as $argNumber => $array) {
+ if (!is_iterable($array)) {
+ throw new RuntimeError(\sprintf('The merge filter only works with sequences/mappings or "Traversable", got "%s" for argument %d.', \gettype($array), $argNumber + 1));
}
+
+ $result = array_merge($result, self::toArray($array));
}
- $item = iterator_to_array($item, $preserveKeys);
+ return $result;
}
- if (\is_array($item)) {
- return \array_slice($item, $start, $length, $preserveKeys);
- }
+ /**
+ * 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
+ *
+ * @internal
+ */
+ public static function slice(string $charset, $item, $start, $length = null, $preserveKeys = false)
+ {
+ if ($item instanceof \Traversable) {
+ while ($item instanceof \IteratorAggregate) {
+ $item = $item->getIterator();
+ }
- return (string) mb_substr((string) $item, $start, $length, $env->getCharset());
-}
+ if ($start >= 0 && $length >= 0 && $item instanceof \Iterator) {
+ try {
+ return iterator_to_array(new \LimitIterator($item, $start, $length ?? -1), $preserveKeys);
+ } catch (\OutOfBoundsException $e) {
+ return [];
+ }
+ }
-/**
- * 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|null $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)
-{
- $value = $value ?? '';
-
- 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();
+ $item = iterator_to_array($item, $preserveKeys);
}
- $keys = [];
- if ($array instanceof \Iterator) {
- $array->rewind();
- while ($array->valid()) {
- $keys[] = $array->key();
- $array->next();
+ if (\is_array($item)) {
+ return \array_slice($item, $start, $length, $preserveKeys);
+ }
+
+ return mb_substr((string) $item, $start, $length, $charset);
+ }
+
+ /**
+ * Returns the first element of the item.
+ *
+ * @param mixed $item A variable
+ *
+ * @return mixed The first element of the item
+ *
+ * @internal
+ */
+ public static function first(string $charset, $item)
+ {
+ $elements = self::slice($charset, $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
+ *
+ * @internal
+ */
+ public static function last(string $charset, $item)
+ {
+ $elements = self::slice($charset, $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
+ *
+ * @internal
+ */
+ public static function join($value, $glue = '', $and = null): string
+ {
+ if (!is_iterable($value)) {
+ $value = (array) $value;
+ }
+
+ $value = self::toArray($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|null $value A string
+ * @param string $delimiter The delimiter
+ * @param int|null $limit The limit
+ *
+ * @internal
+ */
+ public static function split(string $charset, $value, $delimiter, $limit = null): array
+ {
+ $value = $value ?? '';
+
+ if ('' !== $delimiter) {
+ return null === $limit ? explode($delimiter, $value) : explode($delimiter, $value, $limit);
+ }
+
+ if ($limit <= 1) {
+ return preg_split('/(?<!^)(?!$)/u', $value);
+ }
+
+ $length = mb_strlen($value, $charset);
+ if ($length < $limit) {
+ return [$value];
+ }
+
+ $r = [];
+ for ($i = 0; $i < $length; $i += $limit) {
+ $r[] = mb_substr($value, $i, $limit, $charset);
+ }
+
+ return $r;
+ }
+
+ /**
+ * @internal
+ */
+ public static function default($value, $default = '')
+ {
+ if (self::testEmpty($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 %}
+ *
+ * @internal
+ */
+ public static function keys($array): 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;
}
- foreach ($array as $key => $item) {
- $keys[] = $key;
+ if (!\is_array($array)) {
+ return [];
}
- return $keys;
+ return array_keys($array);
}
- if (!\is_array($array)) {
- return [];
- }
-
- return array_keys($array);
-}
-
-/**
- * Reverses a variable.
- *
- * @param array|\Traversable|string|null $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) {
- $string = twig_convert_encoding($string, 'UTF-8', $charset);
- }
-
- preg_match_all('/./us', $string, $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(Environment $env, $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) {
- twig_check_arrow_in_sandbox($env, $arrow, 'sort', 'filter');
-
- 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);
+ /**
+ * Reverses a variable.
+ *
+ * @param array|\Traversable|string|null $item An array, a \Traversable instance, or a string
+ * @param bool $preserveKeys Whether to preserve key or not
+ *
+ * @return mixed The reversed input
+ *
+ * @internal
+ */
+ public static function reverse(string $charset, $item, $preserveKeys = false)
+ {
+ if ($item instanceof \Traversable) {
+ return array_reverse(iterator_to_array($item), $preserveKeys);
}
- return false;
+ if (\is_array($item)) {
+ return array_reverse($item, $preserveKeys);
+ }
+
+ $string = (string) $item;
+
+ if ('UTF-8' !== $charset) {
+ $string = self::convertEncoding($string, 'UTF-8', $charset);
+ }
+
+ preg_match_all('/./us', $string, $matches);
+
+ $string = implode('', array_reverse($matches[0]));
+
+ if ('UTF-8' !== $charset) {
+ $string = self::convertEncoding($string, $charset, 'UTF-8');
+ }
+
+ return $string;
}
- if (!is_iterable($compare)) {
- return false;
+ /**
+ * Shuffles an array, a \Traversable instance, or a string.
+ * The function does not preserve keys.
+ *
+ * @param array|\Traversable|string|null $item
+ *
+ * @return mixed
+ *
+ * @internal
+ */
+ public static function shuffle(string $charset, $item)
+ {
+ if (\is_string($item)) {
+ if ('UTF-8' !== $charset) {
+ $item = self::convertEncoding($item, 'UTF-8', $charset);
+ }
+
+ $item = preg_split('/(?<!^)(?!$)/u', $item, -1);
+ shuffle($item);
+ $item = implode('', $item);
+
+ if ('UTF-8' !== $charset) {
+ $item = self::convertEncoding($item, $charset, 'UTF-8');
+ }
+
+ return $item;
+ }
+
+ if (is_iterable($item)) {
+ $item = self::toArray($item, false);
+ shuffle($item);
+ }
+
+ return $item;
}
- if (\is_object($value) || \is_resource($value)) {
- if (!\is_array($compare)) {
- foreach ($compare as $item) {
- if ($item === $value) {
- return true;
- }
+ /**
+ * Sorts an array.
+ *
+ * @param array|\Traversable $array
+ *
+ * @internal
+ */
+ public static function sort(Environment $env, $array, $arrow = null): array
+ {
+ if ($array instanceof \Traversable) {
+ $array = iterator_to_array($array);
+ } elseif (!\is_array($array)) {
+ throw new RuntimeError(\sprintf('The sort filter only works with sequences/mappings or "Traversable", got "%s".', \gettype($array)));
+ }
+
+ if (null !== $arrow) {
+ self::checkArrowInSandbox($env, $arrow, 'sort', 'filter');
+
+ uasort($array, $arrow);
+ } else {
+ asort($array);
+ }
+
+ return $array;
+ }
+
+ /**
+ * @internal
+ */
+ public static function inFilter($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 || str_contains($compare, (string) $value);
}
return false;
}
- return \in_array($value, $compare, true);
+ 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 === self::compare($value, $item)) {
+ return true;
+ }
+ }
+
+ return false;
}
- foreach ($compare as $item) {
- if (0 === twig_compare($value, $item)) {
- return true;
+ /**
+ * 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
+ */
+ public static function 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;
+ }
+
+ /**
+ * @throws RuntimeError When an invalid pattern is used
+ *
+ * @internal
+ */
+ public static function matches(string $regexp, ?string $str): int
+ {
+ set_error_handler(function ($t, $m) use ($regexp) {
+ throw new RuntimeError(\sprintf('Regexp "%s" passed to "matches" is not valid', $regexp).substr($m, 12));
+ });
+ try {
+ return preg_match($regexp, $str ?? '');
+ } finally {
+ restore_error_handler();
}
}
- return false;
-}
+ /**
+ * Returns a trimmed string.
+ *
+ * @param string|null $string
+ * @param string|null $characterMask
+ * @param string $side
+ *
+ * @throws RuntimeError When an invalid trimming side is used (not a string or not 'left', 'right', or 'both')
+ *
+ * @internal
+ */
+ public static function trim($string, $characterMask = null, $side = 'both'): string
+ {
+ if (null === $characterMask) {
+ $characterMask = " \t\n\r\0\x0B";
+ }
-/**
- * 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;
+ 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".');
}
}
- // 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;
+ /**
+ * Inserts HTML line breaks before all newlines in a string.
+ *
+ * @param string|null $string
+ *
+ * @internal
+ */
+ public static function nl2br($string): string
+ {
+ return nl2br($string ?? '');
+ }
+
+ /**
+ * Removes whitespaces between HTML tags.
+ *
+ * @param string|null $content
+ *
+ * @internal
+ */
+ public static function spaceless($content): string
+ {
+ return trim(preg_replace('/>\s+</', '><', $content ?? ''));
+ }
+
+ /**
+ * @param string|null $string
+ * @param string $to
+ * @param string $from
+ *
+ * @internal
+ */
+ public static function convertEncoding($string, $to, $from): string
+ {
+ 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 $a <=> (float) $bTrim;
+ return iconv($from, $to, $string ?? '');
}
- 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;
+
+ /**
+ * Returns the length of a variable.
+ *
+ * @param mixed $thing A variable
+ *
+ * @internal
+ */
+ public static function length(string $charset, $thing): int
+ {
+ if (null === $thing) {
+ return 0;
}
- return (float) $aTrim <=> $b;
+ if (\is_scalar($thing)) {
+ return mb_strlen($thing, $charset);
+ }
+
+ if ($thing instanceof \Countable || \is_array($thing) || $thing instanceof \SimpleXMLElement) {
+ return \count($thing);
+ }
+
+ if ($thing instanceof \Traversable) {
+ return iterator_count($thing);
+ }
+
+ if ($thing instanceof \Stringable) {
+ return mb_strlen((string) $thing, $charset);
+ }
+
+ return 1;
}
- // fallback to <=>
- return $a <=> $b;
-}
-
-/**
- * Returns a trimmed string.
- *
- * @param string|null $string
- * @param string|null $characterMask
- * @param string $side
- *
- * @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";
+ /**
+ * Converts a string to uppercase.
+ *
+ * @param string|null $string A string
+ *
+ * @internal
+ */
+ public static function upper(string $charset, $string): string
+ {
+ return mb_strtoupper($string ?? '', $charset);
}
- 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".');
- }
-}
-
-/**
- * Inserts HTML line breaks before all newlines in a string.
- *
- * @param string|null $string
- *
- * @return string
- */
-function twig_nl2br($string)
-{
- return nl2br($string ?? '');
-}
-
-/**
- * Removes whitespaces between HTML tags.
- *
- * @param string|null $string
- *
- * @return string
- */
-function twig_spaceless($content)
-{
- return trim(preg_replace('/>\s+</', '><', $content ?? ''));
-}
-
-/**
- * @param string|null $string
- * @param string $to
- * @param string $from
- *
- * @return string
- */
-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.');
+ /**
+ * Converts a string to lowercase.
+ *
+ * @param string|null $string A string
+ *
+ * @internal
+ */
+ public static function lower(string $charset, $string): string
+ {
+ return mb_strtolower($string ?? '', $charset);
}
- 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;
+ /**
+ * Strips HTML and PHP tags from a string.
+ *
+ * @param string|null $string
+ * @param string[]|string|null $allowable_tags
+ *
+ * @internal
+ */
+ public static function striptags($string, $allowable_tags = null): string
+ {
+ return strip_tags($string ?? '', $allowable_tags);
}
- 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|null $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|null $string A string
- *
- * @return string The lowercased string
- */
-function twig_lower_filter(Environment $env, $string)
-{
- return mb_strtolower($string ?? '', $env->getCharset());
-}
-
-/**
- * Strips HTML and PHP tags from a string.
- *
- * @param string|null $string
- * @param string[]|string|null $string
- *
- * @return string
- */
-function twig_striptags($string, $allowable_tags = null)
-{
- return strip_tags($string ?? '', $allowable_tags);
-}
-
-/**
- * Returns a titlecased string.
- *
- * @param string|null $string A string
- *
- * @return string The titlecased string
- */
-function twig_title_string_filter(Environment $env, $string)
-{
- if (null !== $charset = $env->getCharset()) {
+ /**
+ * Returns a titlecased string.
+ *
+ * @param string|null $string A string
+ *
+ * @internal
+ */
+ public static function titleCase(string $charset, $string): string
+ {
return mb_convert_case($string ?? '', \MB_CASE_TITLE, $charset);
}
- return ucwords(strtolower($string ?? ''));
-}
+ /**
+ * Returns a capitalized string.
+ *
+ * @param string|null $string A string
+ *
+ * @internal
+ */
+ public static function capitalize(string $charset, $string): string
+ {
+ return mb_strtoupper(mb_substr($string ?? '', 0, 1, $charset), $charset).mb_strtolower(mb_substr($string ?? '', 1, null, $charset), $charset);
+ }
-/**
- * Returns a capitalized string.
- *
- * @param string|null $string A string
- *
- * @return string The capitalized string
- */
-function twig_capitalize_string_filter(Environment $env, $string)
-{
- $charset = $env->getCharset();
+ /**
+ * @internal
+ */
+ public static function callMacro(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);
+ }
+ }
- return mb_strtoupper(mb_substr($string ?? '', 0, 1, $charset), $charset).mb_strtolower(mb_substr($string ?? '', 1, null, $charset), $charset);
-}
+ throw new RuntimeError(\sprintf('Macro "%s" is not defined in template "%s".', substr($method, \strlen('macro_')), $template->getTemplateName()), $lineno, $source);
+ }
-/**
- * @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);
+ return $template->$method(...$args);
+ }
+
+ /**
+ * @template TSequence
+ *
+ * @param TSequence $seq
+ *
+ * @return ($seq is iterable ? TSequence : array{})
+ *
+ * @internal
+ */
+ public static function ensureTraversable($seq)
+ {
+ if (is_iterable($seq)) {
+ return $seq;
+ }
+
+ return [];
+ }
+
+ /**
+ * @internal
+ */
+ public static function toArray($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
+ *
+ * @internal
+ */
+ public static function testEmpty($value): bool
+ {
+ if ($value instanceof \Countable) {
+ return 0 === \count($value);
+ }
+
+ if ($value instanceof \Traversable) {
+ return !iterator_count($value);
+ }
+
+ if ($value instanceof \Stringable) {
+ return '' === (string) $value;
+ }
+
+ return '' === $value || false === $value || null === $value || [] === $value;
+ }
+
+ /**
+ * Checks if a variable is a sequence.
+ *
+ * {# evaluates to true if the foo variable is a sequence #}
+ * {% if foo is sequence %}
+ * {# ... #}
+ * {% endif %}
+ *
+ * @param mixed $value
+ *
+ * @internal
+ */
+ public static function testSequence($value): bool
+ {
+ if ($value instanceof \ArrayObject) {
+ $value = $value->getArrayCopy();
+ }
+
+ if ($value instanceof \Traversable) {
+ $value = iterator_to_array($value);
+ }
+
+ return \is_array($value) && array_is_list($value);
+ }
+
+ /**
+ * Checks if a variable is a mapping.
+ *
+ * {# evaluates to true if the foo variable is a mapping #}
+ * {% if foo is mapping %}
+ * {# ... #}
+ * {% endif %}
+ *
+ * @param mixed $value
+ *
+ * @internal
+ */
+ public static function testMapping($value): bool
+ {
+ if ($value instanceof \ArrayObject) {
+ $value = $value->getArrayCopy();
+ }
+
+ if ($value instanceof \Traversable) {
+ $value = iterator_to_array($value);
+ }
+
+ return (\is_array($value) && !array_is_list($value)) || \is_object($value);
+ }
+
+ /**
+ * Renders a template.
+ *
+ * @param array $context
+ * @param string|array|TemplateWrapper $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
+ *
+ * @internal
+ */
+ public static function include(Environment $env, $context, $template, $variables = [], $withContext = true, $ignoreMissing = false, $sandboxed = false): string
+ {
+ $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();
}
}
- 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);
+ $loaded = null;
+ try {
+ $loaded = $env->resolveTemplate($template);
+ } catch (LoaderError $e) {
+ if (!$ignoreMissing) {
+ throw $e;
+ }
+
+ return '';
+ }
+
+ if ($isSandboxed) {
+ $loaded->unwrap()->checkSecurity();
+ }
+
+ return $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
+ *
+ * @internal
+ */
+ public static function source(Environment $env, $name, $ignoreMissing = false): string
+ {
+ $loader = $env->getLoader();
+ try {
+ return $loader->getSourceContext($name)->getCode();
} 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) {
- if ('class' === $constant) {
- return \get_class($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) {
- if ('class' === $constant) {
- return true;
- }
-
- $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 '';
}
}
- return $result;
-}
+ /**
+ * Returns the list of cases of the enum.
+ *
+ * @template T of \UnitEnum
+ *
+ * @param class-string<T> $enum
+ *
+ * @return list<T>
+ *
+ * @internal
+ */
+ public static function enumCases(string $enum): array
+ {
+ if (!enum_exists($enum)) {
+ throw new RuntimeError(\sprintf('Enum "%s" does not exist.', $enum));
+ }
-/**
- * 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;
+ return $enum::cases();
+ }
- 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;
+ /**
+ * 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
+ * @param bool $checkDefined Whether to check if the constant is defined or not
+ *
+ * @return mixed Class constants can return many types like scalars, arrays, and
+ * objects depending on the PHP version (\BackedEnum, \UnitEnum, etc.)
+ * When $checkDefined is true, returns true when the constant is defined, false otherwise
+ *
+ * @internal
+ */
+ public static function constant($constant, $object = null, bool $checkDefined = false)
+ {
+ if (null !== $object) {
+ if ('class' === $constant) {
+ return $checkDefined ? true : \get_class($object);
}
- return $object[$arrayItem];
+ $constant = \get_class($object).'::'.$constant;
}
- if (/* Template::ARRAY_CALL */ 'array' === $type || !\is_object($object)) {
+ if (!\defined($constant)) {
+ if ($checkDefined) {
+ return false;
+ }
+
+ if ('::class' === strtolower(substr($constant, -7))) {
+ throw new RuntimeError(\sprintf('You cannot use the Twig function "constant()" to access "%s". You could provide an object and call constant("class", $object) or use the class name directly as a string.', $constant));
+ }
+
+ throw new RuntimeError(\sprintf('Constant "%s" is undefined.', $constant));
+ }
+
+ return $checkDefined ? true : \constant($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
+ *
+ * @internal
+ */
+ public static function batch($items, $size, $fill = null, $preserveKeys = true): array
+ {
+ if (!is_iterable($items)) {
+ throw new RuntimeError(\sprintf('The "batch" filter expects a sequence/mapping or "Traversable", got "%s".', \is_object($items) ? \get_class($items) : \gettype($items)));
+ }
+
+ $size = (int) ceil($size);
+
+ $result = array_chunk(self::toArray($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
+ */
+ public static function getAttribute(Environment $env, Source $source, $object, $item, array $arguments = [], $type = Template::ANY_CALL, $isDefinedTest = false, $ignoreStrictCheck = false, $sandboxed = false, int $lineno = -1)
+ {
+ // array
+ if (Template::METHOD_CALL !== $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 === $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 sequence/mapping is empty.', $arrayItem);
+ } else {
+ $message = \sprintf('Key "%s" for sequence/mapping with keys "%s" does not exist.', $arrayItem, implode(', ', array_keys($object)));
+ }
+ } elseif (Template::ARRAY_CALL === $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;
}
@@ -1463,233 +1645,326 @@
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));
+ if (null === $object) {
+ $message = \sprintf('Impossible to invoke a method ("%s") on a null variable.', $item);
} 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);
+ $message = \sprintf('Impossible to invoke a method ("%s") on a sequence/mapping.', $item);
} else {
- $message = sprintf('Impossible to access an attribute ("%s") on a %s variable ("%s").', $item, \gettype($object), $object);
+ $message = \sprintf('Impossible to invoke a method ("%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 ($object instanceof Template) {
+ throw new RuntimeError('Accessing \Twig\Template attributes is forbidden.', $lineno, $source);
}
- if ($ignoreStrictCheck || !$env->isStrictVariables()) {
- return;
- }
+ // object property
+ if (Template::METHOD_CALL !== $type) {
+ if (isset($object->$item) || \array_key_exists((string) $item, (array) $object)) {
+ if ($isDefinedTest) {
+ return true;
+ }
- 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);
- }
+ if ($sandboxed) {
+ $env->getExtension(SandboxExtension::class)->checkPropertyAllowed($object, $item, $lineno, $source);
+ }
- 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;
+ return $object->$item;
}
-
- if ($sandboxed) {
- $env->getExtension(SandboxExtension::class)->checkPropertyAllowed($object, $item, $lineno, $source);
- }
-
- return $object->$item;
}
- }
- static $cache = [];
+ static $cache = [];
- $class = \get_class($object);
+ $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;
+ // 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)) {
+ if ('g' === $lcName[0] && str_starts_with($lcName, 'get')) {
+ $name = substr($method, 3);
+ $lcName = substr($lcName, 3);
+ } elseif ('i' === $lcName[0] && str_starts_with($lcName, 'is')) {
+ $name = substr($method, 2);
+ $lcName = substr($lcName, 2);
+ } elseif ('h' === $lcName[0] && str_starts_with($lcName, 'has')) {
+ $name = substr($method, 3);
+ $lcName = substr($lcName, 3);
+ if (\in_array('is'.$lcName, $lcMethods)) {
+ continue;
+ }
+ } else {
continue;
}
- } else {
- continue;
- }
- // skip get() and is() methods (in which case, $name is empty)
- if ($name) {
- if (!isset($classCache[$name])) {
- $classCache[$name] = $method;
- }
+ // 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;
+ if (!isset($classCache[$lcName])) {
+ $classCache[$lcName] = $method;
+ }
}
}
+ $cache[$class] = $classCache;
}
- $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 {
+ $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 false;
+ return true;
}
- if ($ignoreStrictCheck || !$env->isStrictVariables()) {
- return;
+ if ($sandboxed) {
+ $env->getExtension(SandboxExtension::class)->checkMethodAllowed($object, $method, $lineno, $source);
}
- 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);
+ // 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;
}
- if ($isDefinedTest) {
+ /**
+ * 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 int|string $name The column name
+ * @param int|string|null $index The column to use as the index/keys for the returned array
+ *
+ * @return array The array of values
+ *
+ * @internal
+ */
+ public static function 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 sequences/mappings or "Traversable", got "%s" as first argument.', \gettype($array)));
+ }
+
+ return array_column($array, $name, $index);
+ }
+
+ /**
+ * @internal
+ */
+ public static function filter(Environment $env, $array, $arrow)
+ {
+ if (!is_iterable($array)) {
+ throw new RuntimeError(\sprintf('The "filter" filter expects a sequence/mapping or "Traversable", got "%s".', \is_object($array) ? \get_class($array) : \gettype($array)));
+ }
+
+ self::checkArrowInSandbox($env, $arrow, 'filter', 'filter');
+
+ 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);
+ }
+
+ /**
+ * @internal
+ */
+ public static function find(Environment $env, $array, $arrow)
+ {
+ self::checkArrowInSandbox($env, $arrow, 'find', 'filter');
+
+ foreach ($array as $k => $v) {
+ if ($arrow($v, $k)) {
+ return $v;
+ }
+ }
+
+ return null;
+ }
+
+ /**
+ * @internal
+ */
+ public static function map(Environment $env, $array, $arrow)
+ {
+ if (!is_iterable($array)) {
+ throw new RuntimeError(\sprintf('The "map" filter expects a sequence/mapping or "Traversable", got "%s".', get_debug_type($array)));
+ }
+
+ self::checkArrowInSandbox($env, $arrow, 'map', 'filter');
+
+ $r = [];
+ foreach ($array as $k => $v) {
+ $r[$k] = $arrow($v, $k);
+ }
+
+ return $r;
+ }
+
+ /**
+ * @internal
+ */
+ public static function reduce(Environment $env, $array, $arrow, $initial = null)
+ {
+ self::checkArrowInSandbox($env, $arrow, 'reduce', 'filter');
+
+ if (!\is_array($array) && !$array instanceof \Traversable) {
+ throw new RuntimeError(\sprintf('The "reduce" filter only works with sequences/mappings or "Traversable", got "%s" as first argument.', \gettype($array)));
+ }
+
+ $accumulator = $initial;
+ foreach ($array as $key => $value) {
+ $accumulator = $arrow($accumulator, $value, $key);
+ }
+
+ return $accumulator;
+ }
+
+ /**
+ * @internal
+ */
+ public static function arraySome(Environment $env, $array, $arrow)
+ {
+ self::checkArrowInSandbox($env, $arrow, 'has some', 'operator');
+
+ foreach ($array as $k => $v) {
+ if ($arrow($v, $k)) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * @internal
+ */
+ public static function arrayEvery(Environment $env, $array, $arrow)
+ {
+ self::checkArrowInSandbox($env, $arrow, 'has every', 'operator');
+
+ foreach ($array as $k => $v) {
+ if (!$arrow($v, $k)) {
+ return false;
+ }
+ }
+
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;
+ /**
+ * @internal
+ */
+ public static function checkArrowInSandbox(Environment $env, $arrow, $thing, $type)
+ {
+ if (!$arrow instanceof \Closure && $env->hasExtension(SandboxExtension::class) && $env->getExtension(SandboxExtension::class)->isSandboxed()) {
+ throw new RuntimeError(\sprintf('The callable passed to the "%s" %s must be a Closure in sandbox mode.', $thing, $type));
}
- throw $e;
}
- return $ret;
-}
+ /**
+ * @internal to be removed in Twig 4
+ */
+ public static function captureOutput(iterable $body): string
+ {
+ $level = ob_get_level();
+ ob_start();
-/**
- * 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)));
- }
+ try {
+ foreach ($body as $data) {
+ echo $data;
+ }
+ } catch (\Throwable $e) {
+ while (ob_get_level() > $level) {
+ ob_end_clean();
+ }
- 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)));
- }
-
- twig_check_arrow_in_sandbox($env, $arrow, 'filter', 'filter');
-
- 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)
-{
- twig_check_arrow_in_sandbox($env, $arrow, 'map', 'filter');
-
- $r = [];
- foreach ($array as $k => $v) {
- $r[$k] = $arrow($v, $k);
- }
-
- return $r;
-}
-
-function twig_array_reduce(Environment $env, $array, $arrow, $initial = null)
-{
- twig_check_arrow_in_sandbox($env, $arrow, 'reduce', 'filter');
-
- 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)));
+ throw $e;
}
- $array = iterator_to_array($array);
+ return ob_get_clean();
}
- return array_reduce($array, $arrow, $initial);
-}
+ /**
+ * @internal
+ */
+ public static function parseParentFunction(Parser $parser, Node $fakeNode, $args, int $line): AbstractExpression
+ {
+ if (!$blockName = $parser->peekBlockStack()) {
+ throw new SyntaxError('Calling the "parent" function outside of a block is forbidden.', $line, $parser->getStream()->getSourceContext());
+ }
-function twig_check_arrow_in_sandbox(Environment $env, $arrow, $thing, $type)
-{
- if (!$arrow instanceof Closure && $env->hasExtension('\Twig\Extension\SandboxExtension') && $env->getExtension('\Twig\Extension\SandboxExtension')->isSandboxed()) {
- throw new RuntimeError(sprintf('The callable passed to the "%s" %s must be a Closure in sandbox mode.', $thing, $type));
+ if (!$parser->hasInheritance()) {
+ throw new SyntaxError('Calling the "parent" function on a template that does not call "extends" or "use" is forbidden.', $line, $parser->getStream()->getSourceContext());
+ }
+
+ return new ParentExpression($blockName, $line);
}
-}
+
+ /**
+ * @internal
+ */
+ public static function parseBlockFunction(Parser $parser, Node $fakeNode, $args, int $line): AbstractExpression
+ {
+ $fakeFunction = new TwigFunction('block', fn ($name, $template = null) => null);
+ $args = (new CallableArgumentsExtractor($fakeNode, $fakeFunction))->extractArguments($args);
+
+ return new BlockReferenceExpression($args[0], $args[1] ?? null, $line);
+ }
+
+ /**
+ * @internal
+ */
+ public static function parseAttributeFunction(Parser $parser, Node $fakeNode, $args, int $line): AbstractExpression
+ {
+ $fakeFunction = new TwigFunction('attribute', fn ($variable, $attribute, $arguments = null) => null);
+ $args = (new CallableArgumentsExtractor($fakeNode, $fakeFunction))->extractArguments($args);
+
+ return new GetAttrExpression($args[0], $args[1], $args[2] ?? null, Template::ANY_CALL, $line);
+ }
}
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
index bfb23d7..dac21c3 100644
--- 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
@@ -9,7 +9,11 @@
* file that was distributed with this source code.
*/
-namespace Twig\Extension {
+namespace Twig\Extension;
+
+use Twig\Environment;
+use Twig\Template;
+use Twig\TemplateWrapper;
use Twig\TwigFunction;
final class DebugExtension extends AbstractExtension
@@ -18,47 +22,41 @@
{
// 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'))
+ // Xdebug overloads var_dump in develop mode when html_errors is enabled
+ && str_contains(\ini_get('xdebug.mode'), 'develop')
+ && (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]),
+ new TwigFunction('dump', [self::class, '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;
- }
+ /**
+ * @internal
+ */
+ public static function dump(Environment $env, $context, ...$vars)
+ {
+ if (!$env->isDebug()) {
+ return;
}
- var_dump($vars);
- } else {
- var_dump(...$vars);
- }
+ ob_start();
- return ob_get_clean();
-}
+ 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
index 9d2251d..52531c4 100644
--- 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
@@ -9,22 +9,24 @@
* file that was distributed with this source code.
*/
-namespace Twig\Extension {
+namespace Twig\Extension;
+
+use Twig\Environment;
use Twig\FileExtensionEscapingStrategy;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\Filter\RawFilter;
+use Twig\Node\Node;
use Twig\NodeVisitor\EscaperNodeVisitor;
+use Twig\Runtime\EscaperRuntime;
use Twig\TokenParser\AutoEscapeTokenParser;
use Twig\TwigFilter;
final class EscaperExtension extends AbstractExtension
{
- private $defaultStrategy;
+ private $environment;
private $escapers = [];
-
- /** @internal */
- public $safeClasses = [];
-
- /** @internal */
- public $safeLookup = [];
+ private $escaper;
+ private $defaultStrategy;
/**
* @param string|false|callable $defaultStrategy An escaping strategy
@@ -49,19 +51,43 @@
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']]),
+ new TwigFilter('escape', [EscaperRuntime::class, 'escape'], ['is_safe_callback' => [self::class, 'escapeFilterIsSafe']]),
+ new TwigFilter('e', [EscaperRuntime::class, 'escape'], ['is_safe_callback' => [self::class, 'escapeFilterIsSafe']]),
+ new TwigFilter('raw', null, ['is_safe' => ['all'], 'node_class' => RawFilter::class]),
];
}
/**
+ * @deprecated since Twig 3.10
+ */
+ public function setEnvironment(Environment $environment): void
+ {
+ $triggerDeprecation = \func_num_args() > 1 ? func_get_arg(1) : true;
+ if ($triggerDeprecation) {
+ trigger_deprecation('twig/twig', '3.10', 'The "%s()" method is deprecated and not needed if you are using methods from "Twig\Runtime\EscaperRuntime".', __METHOD__);
+ }
+
+ $this->environment = $environment;
+ $this->escaper = $environment->getRuntime(EscaperRuntime::class);
+ }
+
+ /**
+ * @deprecated since Twig 3.10
+ */
+ public function setEscaperRuntime(EscaperRuntime $escaper)
+ {
+ trigger_deprecation('twig/twig', '3.10', 'The "%s()" method is deprecated and not needed if you are using methods from "Twig\Runtime\EscaperRuntime".', __METHOD__);
+
+ $this->escaper = $escaper;
+ }
+
+ /**
* 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
+ * @param string|false|callable(string $templateName): string $defaultStrategy An escaping strategy
*/
public function setDefaultStrategy($defaultStrategy): void
{
@@ -93,324 +119,82 @@
/**
* 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
+ * @param string $strategy The strategy name that should be used as a strategy in the escape call
+ * @param callable(Environment, string, string): string $callable A valid PHP callable
+ *
+ * @deprecated since Twig 3.10
*/
public function setEscaper($strategy, callable $callable)
{
+ trigger_deprecation('twig/twig', '3.10', 'The "%s()" method is deprecated, use the "Twig\Runtime\EscaperRuntime::setEscaper()" method instead (be warned that Environment is not passed anymore to the callable).', __METHOD__);
+
+ if (!isset($this->environment)) {
+ throw new \LogicException(\sprintf('You must call "setEnvironment()" before calling "%s()".', __METHOD__));
+ }
+
$this->escapers[$strategy] = $callable;
+ $callable = function ($string, $charset) use ($callable) {
+ return $callable($this->environment, $string, $charset);
+ };
+
+ $this->escaper->setEscaper($strategy, $callable);
}
/**
* Gets all defined escapers.
*
- * @return callable[] An array of escapers
+ * @return array<string, callable(Environment, string, string): string> An array of escapers
+ *
+ * @deprecated since Twig 3.10
*/
public function getEscapers()
{
+ trigger_deprecation('twig/twig', '3.10', 'The "%s()" method is deprecated, use the "Twig\Runtime\EscaperRuntime::getEscaper()" method instead.', __METHOD__);
+
return $this->escapers;
}
+ /**
+ * @deprecated since Twig 3.10
+ */
public function setSafeClasses(array $safeClasses = [])
{
- $this->safeClasses = [];
- $this->safeLookup = [];
- foreach ($safeClasses as $class => $strategies) {
- $this->addSafeClass($class, $strategies);
+ trigger_deprecation('twig/twig', '3.10', 'The "%s()" method is deprecated, use the "Twig\Runtime\EscaperRuntime::setSafeClasses()" method instead.', __METHOD__);
+
+ if (!isset($this->escaper)) {
+ throw new \LogicException(\sprintf('You must call "setEnvironment()" before calling "%s()".', __METHOD__));
}
+
+ $this->escaper->setSafeClasses($safeClasses);
}
+ /**
+ * @deprecated since Twig 3.10
+ */
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);
+ trigger_deprecation('twig/twig', '3.10', 'The "%s()" method is deprecated, use the "Twig\Runtime\EscaperRuntime::addSafeClass()" method instead.', __METHOD__);
- 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://www.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, 'UTF-8');
- 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 '�';
- }
-
- /*
- * 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 => '"', /* quotation mark */
- 38 => '&', /* ampersand */
- 60 => '<', /* less-than sign */
- 62 => '>', /* 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:
- $escapers = $env->getExtension(EscaperExtension::class)->getEscapers();
- if (array_key_exists($strategy, $escapers)) {
- 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')];
+ if (!isset($this->escaper)) {
+ throw new \LogicException(\sprintf('You must call "setEnvironment()" before calling "%s()".', __METHOD__));
}
- return [];
+ $this->escaper->addSafeClass($class, $strategies);
}
- return ['html'];
-}
+ /**
+ * @internal
+ */
+ public static function escapeFilterIsSafe(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
index 75fa237..10a42b6 100644
--- 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
@@ -11,6 +11,8 @@
namespace Twig\Extension;
+use Twig\ExpressionParser;
+use Twig\Node\Expression\AbstractExpression;
use Twig\NodeVisitor\NodeVisitorInterface;
use Twig\TokenParser\TokenParserInterface;
use Twig\TwigFilter;
@@ -63,6 +65,11 @@
* Returns a list of operators to add to the existing list.
*
* @return array<array> First array of unary operators, second array of binary operators
+ *
+ * @psalm-return array{
+ * array<string, array{precedence: int, class: class-string<AbstractExpression>}>,
+ * array<string, array{precedence: int, class?: class-string<AbstractExpression>, associativity: ExpressionParser::OPERATOR_*}>
+ * }
*/
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
index ec0c682..d52cd10 100644
--- 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
@@ -12,14 +12,14 @@
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.
+ * Allows Twig extensions to add globals to the context.
*
* @author Fabien Potencier <fabien@symfony.com>
*/
interface GlobalsInterface
{
+ /**
+ * @return array<string, mixed>
+ */
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
index 965bfdb..d3fe46a 100644
--- 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
@@ -15,11 +15,9 @@
final class OptimizerExtension extends AbstractExtension
{
- private $optimizers;
-
- public function __construct(int $optimizers = -1)
- {
- $this->optimizers = $optimizers;
+ public function __construct(
+ private int $optimizers = -1,
+ ) {
}
public function getNodeVisitors(): array
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
index c861159..4e96760 100644
--- 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
@@ -15,6 +15,7 @@
use Twig\Sandbox\SecurityNotAllowedMethodError;
use Twig\Sandbox\SecurityNotAllowedPropertyError;
use Twig\Sandbox\SecurityPolicyInterface;
+use Twig\Sandbox\SourcePolicyInterface;
use Twig\Source;
use Twig\TokenParser\SandboxTokenParser;
@@ -23,11 +24,13 @@
private $sandboxedGlobally;
private $sandboxed;
private $policy;
+ private $sourcePolicy;
- public function __construct(SecurityPolicyInterface $policy, $sandboxed = false)
+ public function __construct(SecurityPolicyInterface $policy, $sandboxed = false, ?SourcePolicyInterface $sourcePolicy = null)
{
$this->policy = $policy;
$this->sandboxedGlobally = $sandboxed;
+ $this->sourcePolicy = $sourcePolicy;
}
public function getTokenParsers(): array
@@ -50,9 +53,9 @@
$this->sandboxed = false;
}
- public function isSandboxed(): bool
+ public function isSandboxed(?Source $source = null): bool
{
- return $this->sandboxedGlobally || $this->sandboxed;
+ return $this->sandboxedGlobally || $this->sandboxed || $this->isSourceSandboxed($source);
}
public function isSandboxedGlobally(): bool
@@ -60,6 +63,15 @@
return $this->sandboxedGlobally;
}
+ private function isSourceSandboxed(?Source $source): bool
+ {
+ if (null === $source || null === $this->sourcePolicy) {
+ return false;
+ }
+
+ return $this->sourcePolicy->enableSandbox($source);
+ }
+
public function setSecurityPolicy(SecurityPolicyInterface $policy)
{
$this->policy = $policy;
@@ -70,16 +82,16 @@
return $this->policy;
}
- public function checkSecurity($tags, $filters, $functions): void
+ public function checkSecurity($tags, $filters, $functions, ?Source $source = null): void
{
- if ($this->isSandboxed()) {
+ if ($this->isSandboxed($source)) {
$this->policy->checkSecurity($tags, $filters, $functions);
}
}
- public function checkMethodAllowed($obj, $method, int $lineno = -1, Source $source = null): void
+ public function checkMethodAllowed($obj, $method, int $lineno = -1, ?Source $source = null): void
{
- if ($this->isSandboxed()) {
+ if ($this->isSandboxed($source)) {
try {
$this->policy->checkMethodAllowed($obj, $method);
} catch (SecurityNotAllowedMethodError $e) {
@@ -91,9 +103,9 @@
}
}
- public function checkPropertyAllowed($obj, $property, int $lineno = -1, Source $source = null): void
+ public function checkPropertyAllowed($obj, $property, int $lineno = -1, ?Source $source = null): void
{
- if ($this->isSandboxed()) {
+ if ($this->isSandboxed($source)) {
try {
$this->policy->checkPropertyAllowed($obj, $property);
} catch (SecurityNotAllowedPropertyError $e) {
@@ -105,9 +117,9 @@
}
}
- public function ensureToStringAllowed($obj, int $lineno = -1, Source $source = null)
+ public function ensureToStringAllowed($obj, int $lineno = -1, ?Source $source = null)
{
- if ($this->isSandboxed() && \is_object($obj) && method_exists($obj, '__toString')) {
+ if ($this->isSandboxed($source) && $obj instanceof \Stringable) {
try {
$this->policy->checkMethodAllowed($obj, '__toString');
} catch (SecurityNotAllowedMethodError $e) {
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
index 0ea47f9..59db2ca 100644
--- 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
@@ -35,7 +35,7 @@
public function addFunction(TwigFunction $function): void
{
if (isset($this->functions[$function->getName()])) {
- throw new \LogicException(sprintf('Function "%s" is already registered.', $function->getName()));
+ throw new \LogicException(\sprintf('Function "%s" is already registered.', $function->getName()));
}
$this->functions[$function->getName()] = $function;
@@ -49,7 +49,7 @@
public function addFilter(TwigFilter $filter): void
{
if (isset($this->filters[$filter->getName()])) {
- throw new \LogicException(sprintf('Filter "%s" is already registered.', $filter->getName()));
+ throw new \LogicException(\sprintf('Filter "%s" is already registered.', $filter->getName()));
}
$this->filters[$filter->getName()] = $filter;
@@ -73,7 +73,7 @@
public function addTokenParser(TokenParserInterface $parser): void
{
if (isset($this->tokenParsers[$parser->getTag()])) {
- throw new \LogicException(sprintf('Tag "%s" is already registered.', $parser->getTag()));
+ throw new \LogicException(\sprintf('Tag "%s" is already registered.', $parser->getTag()));
}
$this->tokenParsers[$parser->getTag()] = $parser;
@@ -87,7 +87,7 @@
public function addTest(TwigTest $test): void
{
if (isset($this->tests[$test->getName()])) {
- throw new \LogicException(sprintf('Test "%s" is already registered.', $test->getName()));
+ throw new \LogicException(\sprintf('Test "%s" is already registered.', $test->getName()));
}
$this->tests[$test->getName()] = $test;
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
index 7b45147..698d181 100644
--- 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
@@ -9,7 +9,10 @@
* file that was distributed with this source code.
*/
-namespace Twig\Extension {
+namespace Twig\Extension;
+
+use Twig\Environment;
+use Twig\TemplateWrapper;
use Twig\TwigFunction;
final class StringLoaderExtension extends AbstractExtension
@@ -17,26 +20,21 @@
public function getFunctions(): array
{
return [
- new TwigFunction('template_from_string', 'twig_template_from_string', ['needs_environment' => true]),
+ new TwigFunction('template_from_string', [self::class, 'templateFromString'], ['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);
-}
+ /**
+ * Loads a template from a string.
+ *
+ * {{ include(template_from_string("Hello {{ name }}")) }}
+ *
+ * @param string|null $name An optional name of the template to be used in error messages
+ *
+ * @internal
+ */
+ public static function templateFromString(Environment $env, string|\Stringable $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/Extension/YieldNotReadyExtension.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/YieldNotReadyExtension.php
new file mode 100644
index 0000000..49dfb80
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Extension/YieldNotReadyExtension.php
@@ -0,0 +1,30 @@
+<?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\YieldNotReadyNodeVisitor;
+
+/**
+ * @internal to be removed in Twig 4
+ */
+final class YieldNotReadyExtension extends AbstractExtension
+{
+ public function __construct(
+ private bool $useYield,
+ ) {
+ }
+
+ public function getNodeVisitors(): array
+ {
+ return [new YieldNotReadyNodeVisitor($this->useYield)];
+ }
+}
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
index 36e5bbc..28d57a4 100644
--- 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
@@ -15,6 +15,9 @@
use Twig\Extension\ExtensionInterface;
use Twig\Extension\GlobalsInterface;
use Twig\Extension\StagingExtension;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Expression\Binary\AbstractBinary;
+use Twig\Node\Expression\Unary\AbstractUnary;
use Twig\NodeVisitor\NodeVisitorInterface;
use Twig\TokenParser\TokenParserInterface;
@@ -31,11 +34,23 @@
private $staging;
private $parsers;
private $visitors;
+ /** @var array<string, TwigFilter> */
private $filters;
+ /** @var array<string, TwigFilter> */
+ private $dynamicFilters;
+ /** @var array<string, TwigTest> */
private $tests;
+ /** @var array<string, TwigTest> */
+ private $dynamicTests;
+ /** @var array<string, TwigFunction> */
private $functions;
+ /** @var array<string, TwigFunction> */
+ private $dynamicFunctions;
+ /** @var array<string, array{precedence: int, class: class-string<AbstractExpression>}> */
private $unaryOperators;
+ /** @var array<string, array{precedence: int, class?: class-string<AbstractExpression>, associativity: ExpressionParser::OPERATOR_*}> */
private $binaryOperators;
+ /** @var array<string, mixed> */
private $globals;
private $functionCallbacks = [];
private $filterCallbacks = [];
@@ -62,7 +77,7 @@
$class = ltrim($class, '\\');
if (!isset($this->extensions[$class])) {
- throw new RuntimeError(sprintf('The "%s" extension is not enabled.', $class));
+ throw new RuntimeError(\sprintf('The "%s" extension is not enabled.', $class));
}
return $this->extensions[$class];
@@ -117,11 +132,11 @@
$class = \get_class($extension);
if ($this->initialized) {
- throw new \LogicException(sprintf('Unable to register extension "%s" as extensions have already been initialized.', $class));
+ 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));
+ throw new \LogicException(\sprintf('Unable to register extension "%s" as it is already registered.', $class));
}
$this->extensions[$class] = $extension;
@@ -130,7 +145,7 @@
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()));
+ throw new \LogicException(\sprintf('Unable to add function "%s" as extensions have already been initialized.', $function->getName()));
}
$this->staging->addFunction($function);
@@ -158,14 +173,11 @@
return $this->functions[$name];
}
- foreach ($this->functions as $pattern => $function) {
- $pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
-
- if ($count && preg_match('#^'.$pattern.'$#', $name, $matches)) {
+ foreach ($this->dynamicFunctions as $pattern => $function) {
+ if (preg_match($pattern, $name, $matches)) {
array_shift($matches);
- $function->setArguments($matches);
- return $function;
+ return $function->withDynamicArguments($name, $function->getName(), $matches);
}
}
@@ -186,7 +198,7 @@
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()));
+ throw new \LogicException(\sprintf('Unable to add filter "%s" as extensions have already been initialized.', $filter->getName()));
}
$this->staging->addFilter($filter);
@@ -214,14 +226,11 @@
return $this->filters[$name];
}
- foreach ($this->filters as $pattern => $filter) {
- $pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
-
- if ($count && preg_match('#^'.$pattern.'$#', $name, $matches)) {
+ foreach ($this->dynamicFilters as $pattern => $filter) {
+ if (preg_match($pattern, $name, $matches)) {
array_shift($matches);
- $filter->setArguments($matches);
- return $filter;
+ return $filter->withDynamicArguments($name, $filter->getName(), $matches);
}
}
@@ -305,6 +314,9 @@
$this->parserCallbacks[] = $callable;
}
+ /**
+ * @return array<string, mixed>
+ */
public function getGlobals(): array
{
if (null !== $this->globals) {
@@ -317,12 +329,7 @@
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);
+ $globals = array_merge($globals, $extension->getGlobals());
}
if ($this->initialized) {
@@ -332,10 +339,15 @@
return $globals;
}
+ public function resetGlobals(): void
+ {
+ $this->globals = null;
+ }
+
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()));
+ throw new \LogicException(\sprintf('Unable to add test "%s" as extensions have already been initialized.', $test->getName()));
}
$this->staging->addTest($test);
@@ -363,22 +375,20 @@
return $this->tests[$name];
}
- foreach ($this->tests as $pattern => $test) {
- $pattern = str_replace('\\*', '(.*?)', preg_quote($pattern, '#'), $count);
+ foreach ($this->dynamicTests as $pattern => $test) {
+ if (preg_match($pattern, $name, $matches)) {
+ array_shift($matches);
- if ($count) {
- if (preg_match('#^'.$pattern.'$#', $name, $matches)) {
- array_shift($matches);
- $test->setArguments($matches);
-
- return $test;
- }
+ return $test->withDynamicArguments($name, $test->getName(), $matches);
}
}
return null;
}
+ /**
+ * @return array<string, array{precedence: int, class: class-string<AbstractExpression>}>
+ */
public function getUnaryOperators(): array
{
if (!$this->initialized) {
@@ -388,6 +398,9 @@
return $this->unaryOperators;
}
+ /**
+ * @return array<string, array{precedence: int, class?: class-string<AbstractExpression>, associativity: ExpressionParser::OPERATOR_*}>
+ */
public function getBinaryOperators(): array
{
if (!$this->initialized) {
@@ -403,6 +416,9 @@
$this->filters = [];
$this->functions = [];
$this->tests = [];
+ $this->dynamicFilters = [];
+ $this->dynamicFunctions = [];
+ $this->dynamicTests = [];
$this->visitors = [];
$this->unaryOperators = [];
$this->binaryOperators = [];
@@ -419,17 +435,26 @@
{
// filters
foreach ($extension->getFilters() as $filter) {
- $this->filters[$filter->getName()] = $filter;
+ $this->filters[$name = $filter->getName()] = $filter;
+ if (str_contains($name, '*')) {
+ $this->dynamicFilters['#^'.str_replace('\\*', '(.*?)', preg_quote($name, '#')).'$#'] = $filter;
+ }
}
// functions
foreach ($extension->getFunctions() as $function) {
- $this->functions[$function->getName()] = $function;
+ $this->functions[$name = $function->getName()] = $function;
+ if (str_contains($name, '*')) {
+ $this->dynamicFunctions['#^'.str_replace('\\*', '(.*?)', preg_quote($name, '#')).'$#'] = $function;
+ }
}
// tests
foreach ($extension->getTests() as $test) {
- $this->tests[$test->getName()] = $test;
+ $this->tests[$name = $test->getName()] = $test;
+ if (str_contains($name, '*')) {
+ $this->dynamicTests['#^'.str_replace('\\*', '(.*?)', preg_quote($name, '#')).'$#'] = $test;
+ }
}
// token parsers
@@ -449,11 +474,11 @@
// 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)));
+ 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)));
+ 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]);
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
index 65198bb..812071b 100644
--- 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
@@ -37,7 +37,7 @@
return 'html'; // return html for directories
}
- if ('.twig' === substr($name, -5)) {
+ if (str_ends_with($name, '.twig')) {
$name = substr($name, 0, -5);
}
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
index 9ff028c..28feaa2 100644
--- 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
@@ -19,6 +19,8 @@
*/
class Lexer
{
+ private $isInitialized = false;
+
private $tokens;
private $code;
private $cursor;
@@ -48,6 +50,14 @@
public const REGEX_DQ_STRING_PART = '/[^#"\\\\]*(?:(?:\\\\.|#(?!\{))[^#"\\\\]*)*/As';
public const PUNCTUATION = '()[]{}?:.,|';
+ private const SPECIAL_CHARS = [
+ 'f' => "\f",
+ 'n' => "\n",
+ 'r' => "\r",
+ 't' => "\t",
+ 'v' => "\v",
+ ];
+
public function __construct(Environment $env, array $options = [])
{
$this->env = $env;
@@ -61,6 +71,13 @@
'whitespace_line_chars' => ' \t\0\x0B',
'interpolation' => ['#{', '}'],
], $options);
+ }
+
+ private function initialize()
+ {
+ if ($this->isInitialized) {
+ return;
+ }
// 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 = [
@@ -149,10 +166,14 @@
'interpolation_start' => '{'.preg_quote($this->options['interpolation'][0], '#').'\s*}A',
'interpolation_end' => '{\s*'.preg_quote($this->options['interpolation'][1], '#').'}A',
];
+
+ $this->isInitialized = true;
}
public function tokenize(Source $source): TokenStream
{
+ $this->initialize();
+
$this->source = $source;
$this->code = str_replace(["\r\n", "\r"], "\n", $source->getCode());
$this->cursor = 0;
@@ -194,11 +215,11 @@
}
}
- $this->pushToken(/* Token::EOF_TYPE */ -1);
+ $this->pushToken(Token::EOF_TYPE);
if (!empty($this->brackets)) {
- list($expect, $lineno) = array_pop($this->brackets);
- throw new SyntaxError(sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
+ [$expect, $lineno] = array_pop($this->brackets);
+ throw new SyntaxError(\sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
}
return new TokenStream($this->tokens, $this->source);
@@ -208,7 +229,7 @@
{
// 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->pushToken(Token::TEXT_TYPE, substr($this->code, $this->cursor));
$this->cursor = $this->end;
return;
@@ -237,7 +258,7 @@
$text = rtrim($text, " \t\0\x0B");
}
}
- $this->pushToken(/* Token::TEXT_TYPE */ 0, $text);
+ $this->pushToken(Token::TEXT_TYPE, $text);
$this->moveCursor($textContent.$position[0]);
switch ($this->positions[1][$this->position][0]) {
@@ -255,14 +276,14 @@
$this->moveCursor($match[0]);
$this->lineno = (int) $match[1];
} else {
- $this->pushToken(/* Token::BLOCK_START_TYPE */ 1);
+ $this->pushToken(Token::BLOCK_START_TYPE);
$this->pushState(self::STATE_BLOCK);
$this->currentVarBlockLine = $this->lineno;
}
break;
case $this->options['tag_variable'][0]:
- $this->pushToken(/* Token::VAR_START_TYPE */ 2);
+ $this->pushToken(Token::VAR_START_TYPE);
$this->pushState(self::STATE_VAR);
$this->currentVarBlockLine = $this->lineno;
break;
@@ -272,7 +293,7 @@
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->pushToken(Token::BLOCK_END_TYPE);
$this->moveCursor($match[0]);
$this->popState();
} else {
@@ -283,7 +304,7 @@
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->pushToken(Token::VAR_END_TYPE);
$this->moveCursor($match[0]);
$this->popState();
} else {
@@ -298,23 +319,28 @@
$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);
+ throw new SyntaxError(\sprintf('Unclosed "%s".', self::STATE_BLOCK === $this->state ? 'block' : 'variable'), $this->currentVarBlockLine, $this->source);
}
}
+ // spread operator
+ if ('.' === $this->code[$this->cursor] && ($this->cursor + 2 < $this->end) && '.' === $this->code[$this->cursor + 1] && '.' === $this->code[$this->cursor + 2]) {
+ $this->pushToken(Token::SPREAD_TYPE, '...');
+ $this->moveCursor('...');
+ }
// arrow function
- if ('=' === $this->code[$this->cursor] && '>' === $this->code[$this->cursor + 1]) {
+ elseif ('=' === $this->code[$this->cursor] && ($this->cursor + 1 < $this->end) && '>' === $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->pushToken(Token::OPERATOR_TYPE, 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->pushToken(Token::NAME_TYPE, $match[0]);
$this->moveCursor($match[0]);
}
// numbers
@@ -323,33 +349,33 @@
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->pushToken(Token::NUMBER_TYPE, $number);
$this->moveCursor($match[0]);
}
// punctuation
- elseif (false !== strpos(self::PUNCTUATION, $this->code[$this->cursor])) {
+ elseif (str_contains(self::PUNCTUATION, $this->code[$this->cursor])) {
// opening bracket
- if (false !== strpos('([{', $this->code[$this->cursor])) {
+ if (str_contains('([{', $this->code[$this->cursor])) {
$this->brackets[] = [$this->code[$this->cursor], $this->lineno];
}
// closing bracket
- elseif (false !== strpos(')]}', $this->code[$this->cursor])) {
+ elseif (str_contains(')]}', $this->code[$this->cursor])) {
if (empty($this->brackets)) {
- throw new SyntaxError(sprintf('Unexpected "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
+ throw new SyntaxError(\sprintf('Unexpected "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
}
- list($expect, $lineno) = array_pop($this->brackets);
+ [$expect, $lineno] = array_pop($this->brackets);
if ($this->code[$this->cursor] != strtr($expect, '([{', ')]}')) {
- throw new SyntaxError(sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
+ throw new SyntaxError(\sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
}
}
- $this->pushToken(/* Token::PUNCTUATION_TYPE */ 9, $this->code[$this->cursor]);
+ $this->pushToken(Token::PUNCTUATION_TYPE, $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->pushToken(Token::STRING_TYPE, $this->stripcslashes(substr($match[0], 1, -1), substr($match[0], 0, 1)));
$this->moveCursor($match[0]);
}
// opening double quoted string
@@ -360,10 +386,67 @@
}
// unlexable
else {
- throw new SyntaxError(sprintf('Unexpected character "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
+ throw new SyntaxError(\sprintf('Unexpected character "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
}
}
+ private function stripcslashes(string $str, string $quoteType): string
+ {
+ $result = '';
+ $length = \strlen($str);
+
+ $i = 0;
+ while ($i < $length) {
+ if (false === $pos = strpos($str, '\\', $i)) {
+ $result .= substr($str, $i);
+ break;
+ }
+
+ $result .= substr($str, $i, $pos - $i);
+ $i = $pos + 1;
+
+ if ($i >= $length) {
+ $result .= '\\';
+ break;
+ }
+
+ $nextChar = $str[$i];
+
+ if (isset(self::SPECIAL_CHARS[$nextChar])) {
+ $result .= self::SPECIAL_CHARS[$nextChar];
+ } elseif ('\\' === $nextChar) {
+ $result .= $nextChar;
+ } elseif ("'" === $nextChar || '"' === $nextChar) {
+ if ($nextChar !== $quoteType) {
+ trigger_deprecation('twig/twig', '3.12', 'Character "%s" at position %d should not be escaped; the "\" character is ignored in Twig v3 but will not be in v4. Please remove the extra "\" character.', $nextChar, $i + 1);
+ }
+ $result .= $nextChar;
+ } elseif ('#' === $nextChar && $i + 1 < $length && '{' === $str[$i + 1]) {
+ $result .= '#{';
+ ++$i;
+ } elseif ('x' === $nextChar && $i + 1 < $length && ctype_xdigit($str[$i + 1])) {
+ $hex = $str[++$i];
+ if ($i + 1 < $length && ctype_xdigit($str[$i + 1])) {
+ $hex .= $str[++$i];
+ }
+ $result .= \chr(hexdec($hex));
+ } elseif (ctype_digit($nextChar) && $nextChar < '8') {
+ $octal = $nextChar;
+ while ($i + 1 < $length && ctype_digit($str[$i + 1]) && $str[$i + 1] < '8' && \strlen($octal) < 3) {
+ $octal .= $str[++$i];
+ }
+ $result .= \chr(octdec($octal));
+ } else {
+ trigger_deprecation('twig/twig', '3.12', 'Character "%s" at position %d should not be escaped; the "\" character is ignored in Twig v3 but will not be in v4. Please remove the extra "\" character.', $nextChar, $i + 1);
+ $result .= $nextChar;
+ }
+
+ ++$i;
+ }
+
+ return $result;
+ }
+
private function lexRawData(): void
{
if (!preg_match($this->regexes['lex_raw_data'], $this->code, $match, \PREG_OFFSET_CAPTURE, $this->cursor)) {
@@ -385,7 +468,7 @@
}
}
- $this->pushToken(/* Token::TEXT_TYPE */ 0, $text);
+ $this->pushToken(Token::TEXT_TYPE, $text);
}
private function lexComment(): void
@@ -401,23 +484,23 @@
{
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->pushToken(Token::INTERPOLATION_START_TYPE);
$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]));
+ } elseif (preg_match(self::REGEX_DQ_STRING_PART, $this->code, $match, 0, $this->cursor) && '' !== $match[0]) {
+ $this->pushToken(Token::STRING_TYPE, $this->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);
+ [$expect, $lineno] = array_pop($this->brackets);
if ('"' != $this->code[$this->cursor]) {
- throw new SyntaxError(sprintf('Unclosed "%s".', $expect), $lineno, $this->source);
+ 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);
+ throw new SyntaxError(\sprintf('Unexpected character "%s".', $this->code[$this->cursor]), $this->lineno, $this->source);
}
}
@@ -426,7 +509,7 @@
$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->pushToken(Token::INTERPOLATION_END_TYPE);
$this->moveCursor($match[0]);
$this->popState();
} else {
@@ -437,7 +520,7 @@
private function pushToken($type, $value = ''): void
{
// do not push empty text tokens
- if (/* Token::TEXT_TYPE */ 0 === $type && '' === $value) {
+ if (Token::TEXT_TYPE === $type && '' === $value) {
return;
}
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
index 5d726c3..2bb54b7 100644
--- 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
@@ -28,14 +28,12 @@
*/
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 __construct(
+ private array $templates = [],
+ ) {
}
public function setTemplate(string $name, string $template): void
@@ -46,7 +44,7 @@
public function getSourceContext(string $name): Source
{
if (!isset($this->templates[$name])) {
- throw new LoaderError(sprintf('Template "%s" is not defined.', $name));
+ throw new LoaderError(\sprintf('Template "%s" is not defined.', $name));
}
return new Source($this->templates[$name], $name);
@@ -60,7 +58,7 @@
public function getCacheKey(string $name): string
{
if (!isset($this->templates[$name])) {
- throw new LoaderError(sprintf('Template "%s" is not defined.', $name));
+ throw new LoaderError(\sprintf('Template "%s" is not defined.', $name));
}
return $name.':'.$this->templates[$name];
@@ -69,7 +67,7 @@
public function isFresh(string $name, int $time): bool
{
if (!isset($this->templates[$name])) {
- throw new LoaderError(sprintf('Template "%s" is not defined.', $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
index fbf4f3a..6e4f951 100644
--- 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
@@ -21,22 +21,28 @@
*/
final class ChainLoader implements LoaderInterface
{
+ /**
+ * @var array<string, bool>
+ */
private $hasSourceCache = [];
- private $loaders = [];
/**
- * @param LoaderInterface[] $loaders
+ * @param iterable<LoaderInterface> $loaders
*/
- public function __construct(array $loaders = [])
- {
- foreach ($loaders as $loader) {
- $this->addLoader($loader);
- }
+ public function __construct(
+ private iterable $loaders = [],
+ ) {
}
public function addLoader(LoaderInterface $loader): void
{
- $this->loaders[] = $loader;
+ $current = $this->loaders;
+
+ $this->loaders = (static function () use ($current, $loader): \Generator {
+ yield from $current;
+ yield $loader;
+ })();
+
$this->hasSourceCache = [];
}
@@ -45,13 +51,18 @@
*/
public function getLoaders(): array
{
+ if (!\is_array($this->loaders)) {
+ $this->loaders = iterator_to_array($this->loaders, false);
+ }
+
return $this->loaders;
}
public function getSourceContext(string $name): Source
{
$exceptions = [];
- foreach ($this->loaders as $loader) {
+
+ foreach ($this->getLoaders() as $loader) {
if (!$loader->exists($name)) {
continue;
}
@@ -63,7 +74,7 @@
}
}
- throw new LoaderError(sprintf('Template "%s" is not defined%s.', $name, $exceptions ? ' ('.implode(', ', $exceptions).')' : ''));
+ throw new LoaderError(\sprintf('Template "%s" is not defined%s.', $name, $exceptions ? ' ('.implode(', ', $exceptions).')' : ''));
}
public function exists(string $name): bool
@@ -72,7 +83,7 @@
return $this->hasSourceCache[$name];
}
- foreach ($this->loaders as $loader) {
+ foreach ($this->getLoaders() as $loader) {
if ($loader->exists($name)) {
return $this->hasSourceCache[$name] = true;
}
@@ -84,7 +95,8 @@
public function getCacheKey(string $name): string
{
$exceptions = [];
- foreach ($this->loaders as $loader) {
+
+ foreach ($this->getLoaders() as $loader) {
if (!$loader->exists($name)) {
continue;
}
@@ -96,13 +108,14 @@
}
}
- throw new LoaderError(sprintf('Template "%s" is not defined%s.', $name, $exceptions ? ' ('.implode(', ', $exceptions).')' : ''));
+ 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) {
+
+ foreach ($this->getLoaders() as $loader) {
if (!$loader->exists($name)) {
continue;
}
@@ -114,6 +127,6 @@
}
}
- throw new LoaderError(sprintf('Template "%s" is not defined%s.', $name, $exceptions ? ' ('.implode(', ', $exceptions).')' : ''));
+ 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
index 62267a1..c60964f 100644
--- 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
@@ -34,9 +34,9 @@
* @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)
+ public function __construct($paths = [], ?string $rootPath = null)
{
- $this->rootPath = (null === $rootPath ? getcwd() : $rootPath).\DIRECTORY_SEPARATOR;
+ $this->rootPath = ($rootPath ?? getcwd()).\DIRECTORY_SEPARATOR;
if (null !== $rootPath && false !== ($realPath = realpath($rootPath))) {
$this->rootPath = $realPath.\DIRECTORY_SEPARATOR;
}
@@ -89,7 +89,7 @@
$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));
+ throw new LoaderError(\sprintf('The "%s" directory does not exist ("%s").', $path, $checkPath));
}
$this->paths[$namespace][] = rtrim($path, '/\\');
@@ -105,7 +105,7 @@
$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));
+ throw new LoaderError(\sprintf('The "%s" directory does not exist ("%s").', $path, $checkPath));
}
$path = rtrim($path, '/\\');
@@ -183,7 +183,7 @@
}
try {
- list($namespace, $shortname) = $this->parseName($name);
+ [$namespace, $shortname] = $this->parseName($name);
$this->validateName($shortname);
} catch (LoaderError $e) {
@@ -195,7 +195,7 @@
}
if (!isset($this->paths[$namespace])) {
- $this->errorCache[$name] = sprintf('There are no registered paths for namespace "%s".', $namespace);
+ $this->errorCache[$name] = \sprintf('There are no registered paths for namespace "%s".', $namespace);
if (!$throw) {
return null;
@@ -218,7 +218,7 @@
}
}
- $this->errorCache[$name] = sprintf('Unable to find template "%s" (looked into: %s).', $name, implode(', ', $this->paths[$namespace]));
+ $this->errorCache[$name] = \sprintf('Unable to find template "%s" (looked into: %s).', $name, implode(', ', $this->paths[$namespace]));
if (!$throw) {
return null;
@@ -236,7 +236,7 @@
{
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));
+ throw new LoaderError(\sprintf('Malformed namespaced template name "%s" (expecting "@namespace/template_name").', $name));
}
$namespace = substr($name, 1, $pos - 1);
@@ -250,7 +250,7 @@
private function validateName(string $name): void
{
- if (false !== strpos($name, "\0")) {
+ if (str_contains($name, "\0")) {
throw new LoaderError('A template name cannot contain NUL bytes.');
}
@@ -265,7 +265,7 @@
}
if ($level < 0) {
- throw new LoaderError(sprintf('Looks like you try to load a template outside configured directories (%s).', $name));
+ throw new LoaderError(\sprintf('Looks like you try to load a template outside configured directories (%s).', $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
index 1788acc..4fae779 100644
--- 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
@@ -16,10 +16,10 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
-class Markup implements \Countable, \JsonSerializable
+class Markup implements \Countable, \JsonSerializable, \Stringable
{
private $content;
- private $charset;
+ private ?string $charset;
public function __construct($content, $charset)
{
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
index cd97041..ee80639 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -24,11 +25,12 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class AutoEscapeNode extends Node
{
- public function __construct($value, Node $body, int $lineno, string $tag = 'autoescape')
+ public function __construct($value, Node $body, int $lineno)
{
- parent::__construct(['body' => $body], ['value' => $value], $lineno, $tag);
+ parent::__construct(['body' => $body], ['value' => $value], $lineno);
}
public function compile(Compiler $compiler): void
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
index 0632ba7..b4f939c 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -19,24 +20,29 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class BlockNode extends Node
{
- public function __construct(string $name, Node $body, int $lineno, string $tag = null)
+ public function __construct(string $name, Node $body, int $lineno)
{
- parent::__construct(['body' => $body], ['name' => $name], $lineno, $tag);
+ parent::__construct(['body' => $body], ['name' => $name], $lineno);
}
public function compile(Compiler $compiler): void
{
$compiler
->addDebugInfo($this)
- ->write(sprintf("public function block_%s(\$context, array \$blocks = [])\n", $this->getAttribute('name')), "{\n")
+ ->write("/**\n")
+ ->write(" * @return iterable<null|scalar|\Stringable>\n")
+ ->write(" */\n")
+ ->write(\sprintf("public function block_%s(array \$context, array \$blocks = []): iterable\n", $this->getAttribute('name')), "{\n")
->indent()
->write("\$macros = \$this->macros;\n")
;
$compiler
->subcompile($this->getNode('body'))
+ ->write("yield from [];\n")
->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
index cc8af5b..7c313a0 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -19,18 +20,19 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class BlockReferenceNode extends Node implements NodeOutputInterface
{
- public function __construct(string $name, int $lineno, string $tag = null)
+ public function __construct(string $name, int $lineno)
{
- parent::__construct([], ['name' => $name], $lineno, $tag);
+ parent::__construct([], ['name' => $name], $lineno);
}
public function compile(Compiler $compiler): void
{
$compiler
->addDebugInfo($this)
- ->write(sprintf("\$this->displayBlock('%s', \$context, \$blocks);\n", $this->getAttribute('name')))
+ ->write(\sprintf("yield from \$this->unwrap()->yieldBlock('%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
index 041cbf6..08115b3 100644
--- 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
@@ -11,11 +11,14 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
+
/**
* Represents a body node.
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class BodyNode extends Node
{
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CaptureNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CaptureNode.php
new file mode 100644
index 0000000..3b7f0b6
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/CaptureNode.php
@@ -0,0 +1,57 @@
+<?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\Attribute\YieldReady;
+use Twig\Compiler;
+
+/**
+ * Represents a node for which we need to capture the output.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+#[YieldReady]
+class CaptureNode extends Node
+{
+ public function __construct(Node $body, int $lineno)
+ {
+ parent::__construct(['body' => $body], ['raw' => false], $lineno);
+ }
+
+ public function compile(Compiler $compiler): void
+ {
+ $useYield = $compiler->getEnvironment()->useYield();
+
+ if (!$this->getAttribute('raw')) {
+ $compiler->raw("('' === \$tmp = ");
+ }
+ $compiler
+ ->raw($useYield ? "implode('', iterator_to_array(" : '\\Twig\\Extension\\CoreExtension::captureOutput(')
+ ->raw("(function () use (&\$context, \$macros, \$blocks) {\n")
+ ->indent()
+ ->subcompile($this->getNode('body'))
+ ->write("yield from [];\n")
+ ->outdent()
+ ->write('})()')
+ ;
+ if ($useYield) {
+ $compiler->raw(', false))');
+ } else {
+ $compiler->raw(')');
+ }
+ if (!$this->getAttribute('raw')) {
+ $compiler->raw(") ? '' : new Markup(\$tmp, \$this->env->getCharset());");
+ } else {
+ $compiler->raw(';');
+ }
+ }
+}
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
index a78a38d..9c162d1 100644
--- 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
@@ -11,17 +11,19 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class CheckSecurityCallNode extends Node
{
public function compile(Compiler $compiler)
{
$compiler
- ->write("\$this->sandbox = \$this->env->getExtension('\Twig\Extension\SandboxExtension');\n")
+ ->write("\$this->sandbox = \$this->extensions[SandboxExtension::class];\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
index 4727327..6e591aa 100644
--- 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
@@ -11,17 +11,24 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class CheckSecurityNode extends Node
{
private $usedFilters;
private $usedTags;
private $usedFunctions;
+ /**
+ * @param array<string, int> $usedFilters
+ * @param array<string, int> $usedTags
+ * @param array<string, int> $usedFunctions
+ */
public function __construct(array $usedFilters, array $usedTags, array $usedFunctions)
{
$this->usedFilters = $usedFilters;
@@ -33,32 +40,22 @@
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('static $tags = ')->repr(array_filter($this->usedTags))->raw(";\n")
+ ->write('static $filters = ')->repr(array_filter($this->usedFilters))->raw(";\n")
+ ->write('static $functions = ')->repr(array_filter($this->usedFunctions))->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")
+ ->write(!$this->usedTags ? "[],\n" : "['".implode("', '", array_keys($this->usedTags))."'],\n")
+ ->write(!$this->usedFilters ? "[],\n" : "['".implode("', '", array_keys($this->usedFilters))."'],\n")
+ ->write(!$this->usedFunctions ? "[],\n" : "['".implode("', '", array_keys($this->usedFunctions))."'],\n")
+ ->write("\$this->source\n")
->outdent()
->write(");\n")
->outdent()
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
index c7a9d69..937240c 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
@@ -24,11 +25,12 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class CheckToStringNode extends AbstractExpression
{
public function __construct(AbstractExpression $expr)
{
- parent::__construct(['expr' => $expr], [], $expr->getTemplateLine(), $expr->getNodeTag());
+ parent::__construct(['expr' => $expr], [], $expr->getTemplateLine());
}
public function compile(Compiler $compiler): void
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
index 5ff4430..0772adf 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
use Twig\Node\Expression\ConstantExpression;
@@ -20,11 +21,12 @@
*
* @author Yonel Ceruto <yonelceruto@gmail.com>
*/
+#[YieldReady]
class DeprecatedNode extends Node
{
- public function __construct(AbstractExpression $expr, int $lineno, string $tag = null)
+ public function __construct(AbstractExpression $expr, int $lineno)
{
- parent::__construct(['expr' => $expr], [], $lineno, $tag);
+ parent::__construct(['expr' => $expr], [], $lineno);
}
public function compile(Compiler $compiler): void
@@ -33,21 +35,39 @@
$expr = $this->getNode('expr');
- if ($expr instanceof ConstantExpression) {
- $compiler->write('@trigger_error(')
- ->subcompile($expr);
- } else {
+ if (!$expr instanceof ConstantExpression) {
$varName = $compiler->getVarName();
- $compiler->write(sprintf('$%s = ', $varName))
+ $compiler
+ ->write(\sprintf('$%s = ', $varName))
->subcompile($expr)
->raw(";\n")
- ->write(sprintf('@trigger_error($%s', $varName));
+ ;
+ }
+
+ $compiler->write('trigger_deprecation(');
+ if ($this->hasNode('package')) {
+ $compiler->subcompile($this->getNode('package'));
+ } else {
+ $compiler->raw("''");
+ }
+ $compiler->raw(', ');
+ if ($this->hasNode('version')) {
+ $compiler->subcompile($this->getNode('version'));
+ } else {
+ $compiler->raw("''");
+ }
+ $compiler->raw(', ');
+
+ if ($expr instanceof ConstantExpression) {
+ $compiler->subcompile($expr);
+ } else {
+ $compiler->write(\sprintf('$%s', $varName));
}
$compiler
->raw('.')
- ->string(sprintf(' ("%s" at line %d).', $this->getTemplateName(), $this->getTemplateLine()))
- ->raw(", E_USER_DEPRECATED);\n")
+ ->string(\sprintf(' in "%s" at line %d.', $this->getTemplateName(), $this->getTemplateLine()))
+ ->raw(");\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
index f7783d1..1593fd0 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
@@ -19,11 +20,12 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class DoNode extends Node
{
- public function __construct(AbstractExpression $expr, int $lineno, string $tag = null)
+ public function __construct(AbstractExpression $expr, int $lineno)
{
- parent::__construct(['expr' => $expr], [], $lineno, $tag);
+ parent::__construct(['expr' => $expr], [], $lineno);
}
public function compile(Compiler $compiler): void
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
index 903c3f6..4cd3b38 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
use Twig\Node\Expression\ConstantExpression;
@@ -20,12 +21,13 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
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)
+ public function __construct(string $name, int $index, ?AbstractExpression $variables, bool $only, bool $ignoreMissing, int $lineno)
{
- parent::__construct(new ConstantExpression('not_used', $lineno), $variables, $only, $ignoreMissing, $lineno, $tag);
+ parent::__construct(new ConstantExpression('not_used', $lineno), $variables, $only, $ignoreMissing, $lineno);
$this->setAttribute('name', $name);
$this->setAttribute('index', $index);
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
index 42da055..1692f56 100644
--- 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
@@ -21,4 +21,8 @@
*/
abstract class AbstractExpression extends Node
{
+ public function isGenerator(): bool
+ {
+ return $this->hasAttribute('is_generator') && $this->getAttribute('is_generator');
+ }
}
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
index 0e25fe4..5f8b0f6 100644
--- 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
@@ -55,7 +55,7 @@
return false;
}
- public function addElement(AbstractExpression $value, AbstractExpression $key = null): void
+ public function addElement(AbstractExpression $value, ?AbstractExpression $key = null): void
{
if (null === $key) {
$key = new ConstantExpression(++$this->index, $value->getTemplateLine());
@@ -66,20 +66,70 @@
public function compile(Compiler $compiler): void
{
+ $keyValuePairs = $this->getKeyValuePairs();
+ $needsArrayMergeSpread = \PHP_VERSION_ID < 80100 && $this->hasSpreadItem($keyValuePairs);
+
+ if ($needsArrayMergeSpread) {
+ $compiler->raw('CoreExtension::merge(');
+ }
$compiler->raw('[');
$first = true;
- foreach ($this->getKeyValuePairs() as $pair) {
+ $reopenAfterMergeSpread = false;
+ $nextIndex = 0;
+ foreach ($keyValuePairs as $pair) {
+ if ($reopenAfterMergeSpread) {
+ $compiler->raw(', [');
+ $reopenAfterMergeSpread = false;
+ }
+
+ if ($needsArrayMergeSpread && $pair['value']->hasAttribute('spread')) {
+ $compiler->raw('], ')->subcompile($pair['value']);
+ $first = true;
+ $reopenAfterMergeSpread = true;
+ continue;
+ }
if (!$first) {
$compiler->raw(', ');
}
$first = false;
- $compiler
- ->subcompile($pair['key'])
- ->raw(' => ')
- ->subcompile($pair['value'])
- ;
+ if ($pair['value']->hasAttribute('spread') && !$needsArrayMergeSpread) {
+ $compiler->raw('...')->subcompile($pair['value']);
+ ++$nextIndex;
+ } else {
+ $key = $pair['key'] instanceof ConstantExpression ? $pair['key']->getAttribute('value') : null;
+
+ if ($nextIndex !== $key) {
+ if (\is_int($key)) {
+ $nextIndex = $key + 1;
+ }
+ $compiler
+ ->subcompile($pair['key'])
+ ->raw(' => ')
+ ;
+ } else {
+ ++$nextIndex;
+ }
+
+ $compiler->subcompile($pair['value']);
+ }
}
- $compiler->raw(']');
+ if (!$reopenAfterMergeSpread) {
+ $compiler->raw(']');
+ }
+ if ($needsArrayMergeSpread) {
+ $compiler->raw(')');
+ }
+ }
+
+ private function hasSpreadItem(array $pairs): bool
+ {
+ foreach ($pairs as $pair) {
+ if ($pair['value']->hasAttribute('spread')) {
+ return true;
+ }
+ }
+
+ return false;
}
}
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
index eaad03c..2bae4ed 100644
--- 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
@@ -21,9 +21,9 @@
*/
class ArrowFunctionExpression extends AbstractExpression
{
- public function __construct(AbstractExpression $expr, Node $names, $lineno, $tag = null)
+ public function __construct(AbstractExpression $expr, Node $names, $lineno)
{
- parent::__construct(['expr' => $expr, 'names' => $names], [], $lineno, $tag);
+ parent::__construct(['expr' => $expr, 'names' => $names], [], $lineno);
}
public function compile(Compiler $compiler): void
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
index c3516b8..a73a560 100644
--- 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
@@ -20,11 +20,11 @@
$left = $compiler->getVarName();
$right = $compiler->getVarName();
$compiler
- ->raw(sprintf('(is_string($%s = ', $left))
+ ->raw(\sprintf('(is_string($%s = ', $left))
->subcompile($this->getNode('left'))
- ->raw(sprintf(') && is_string($%s = ', $right))
+ ->raw(\sprintf(') && is_string($%s = ', $right))
->subcompile($this->getNode('right'))
- ->raw(sprintf(') && (\'\' === $%2$s || $%2$s === substr($%1$s, -strlen($%2$s))))', $left, $right))
+ ->raw(\sprintf(') && str_ends_with($%1$s, $%2$s))', $left, $right))
;
}
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
index 6b48549..5f42319 100644
--- 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
@@ -24,7 +24,7 @@
}
$compiler
- ->raw('(0 === twig_compare(')
+ ->raw('(0 === CoreExtension::compare(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
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
index e1dd067..f42de3f 100644
--- 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
@@ -24,7 +24,7 @@
}
$compiler
- ->raw('(1 === twig_compare(')
+ ->raw('(1 === CoreExtension::compare(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
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
index df9bfcf..0c4f43f 100644
--- 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
@@ -24,7 +24,7 @@
}
$compiler
- ->raw('(0 <= twig_compare(')
+ ->raw('(0 <= CoreExtension::compare(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/HasEveryBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/HasEveryBinary.php
new file mode 100644
index 0000000..c57bb20
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/HasEveryBinary.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 HasEveryBinary extends AbstractBinary
+{
+ public function compile(Compiler $compiler): void
+ {
+ $compiler
+ ->raw('CoreExtension::arrayEvery($this->env, ')
+ ->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/HasSomeBinary.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/HasSomeBinary.php
new file mode 100644
index 0000000..12293f8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Binary/HasSomeBinary.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 HasSomeBinary extends AbstractBinary
+{
+ public function compile(Compiler $compiler): void
+ {
+ $compiler
+ ->raw('CoreExtension::arraySome($this->env, ')
+ ->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
index 6dbfa97..68a98fe 100644
--- 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
@@ -18,7 +18,7 @@
public function compile(Compiler $compiler): void
{
$compiler
- ->raw('twig_in_filter(')
+ ->raw('CoreExtension::inFilter(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
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
index 598e629..fb3264a 100644
--- 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
@@ -24,7 +24,7 @@
}
$compiler
- ->raw('(-1 === twig_compare(')
+ ->raw('(-1 === CoreExtension::compare(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
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
index e3c4af5..8f36538 100644
--- 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
@@ -24,7 +24,7 @@
}
$compiler
- ->raw('(0 >= twig_compare(')
+ ->raw('(0 >= CoreExtension::compare(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
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
index bc97292..4669044 100644
--- 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
@@ -18,7 +18,7 @@
public function compile(Compiler $compiler): void
{
$compiler
- ->raw('preg_match(')
+ ->raw('CoreExtension::matches(')
->subcompile($this->getNode('right'))
->raw(', ')
->subcompile($this->getNode('left'))
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
index db47a28..d137ef6 100644
--- 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
@@ -24,7 +24,7 @@
}
$compiler
- ->raw('(0 !== twig_compare(')
+ ->raw('(0 !== CoreExtension::compare(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
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
index fcba6cc..80c8755 100644
--- 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
@@ -18,7 +18,7 @@
public function compile(Compiler $compiler): void
{
$compiler
- ->raw('!twig_in_filter(')
+ ->raw('!CoreExtension::inFilter(')
->subcompile($this->getNode('left'))
->raw(', ')
->subcompile($this->getNode('right'))
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
index d0df1c4..4519f30 100644
--- 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
@@ -20,11 +20,11 @@
$left = $compiler->getVarName();
$right = $compiler->getVarName();
$compiler
- ->raw(sprintf('(is_string($%s = ', $left))
+ ->raw(\sprintf('(is_string($%s = ', $left))
->subcompile($this->getNode('left'))
- ->raw(sprintf(') && is_string($%s = ', $right))
+ ->raw(\sprintf(') && is_string($%s = ', $right))
->subcompile($this->getNode('right'))
- ->raw(sprintf(') && (\'\' === $%2$s || 0 === strpos($%1$s, $%2$s)))', $left, $right))
+ ->raw(\sprintf(') && str_starts_with($%1$s, $%2$s))', $left, $right))
;
}
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
index b1e2a8f..acd231e 100644
--- 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
@@ -22,14 +22,14 @@
*/
class BlockReferenceExpression extends AbstractExpression
{
- public function __construct(Node $name, ?Node $template, int $lineno, string $tag = null)
+ public function __construct(Node $name, ?Node $template, int $lineno)
{
$nodes = ['name' => $name];
if (null !== $template) {
$nodes['template'] = $template;
}
- parent::__construct($nodes, ['is_defined_test' => false, 'output' => false], $lineno, $tag);
+ parent::__construct($nodes, ['is_defined_test' => false, 'output' => false], $lineno);
}
public function compile(Compiler $compiler): void
@@ -40,8 +40,9 @@
if ($this->getAttribute('output')) {
$compiler->addDebugInfo($this);
+ $compiler->write('yield from ');
$this
- ->compileTemplateCall($compiler, 'displayBlock')
+ ->compileTemplateCall($compiler, 'yieldBlock')
->raw(";\n");
} else {
$this->compileTemplateCall($compiler, 'renderBlock');
@@ -65,7 +66,7 @@
;
}
- $compiler->raw(sprintf('->%s', $method));
+ $compiler->raw(\sprintf('->unwrap()->%s', $method));
return $this->compileBlockArguments($compiler);
}
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
index 2888106..6fc6f66 100644
--- 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
@@ -15,40 +15,49 @@
use Twig\Error\SyntaxError;
use Twig\Extension\ExtensionInterface;
use Twig\Node\Node;
+use Twig\TwigCallableInterface;
+use Twig\TwigFilter;
+use Twig\TwigFunction;
+use Twig\TwigTest;
+use Twig\Util\CallableArgumentsExtractor;
+use Twig\Util\ReflectionCallable;
abstract class CallExpression extends AbstractExpression
{
- private $reflector;
+ private $reflector = null;
protected function compileCallable(Compiler $compiler)
{
- $callable = $this->getAttribute('callable');
+ $twigCallable = $this->getTwigCallable();
+ $callable = $twigCallable->getCallable();
- if (\is_string($callable) && false === strpos($callable, '::')) {
+ if (\is_string($callable) && !str_contains($callable, '::')) {
$compiler->raw($callable);
} else {
- [$r, $callable] = $this->reflectCallable($callable);
+ $rc = $this->reflectCallable($twigCallable);
+ $r = $rc->getReflector();
+ $callable = $rc->getCallable();
if (\is_string($callable)) {
$compiler->raw($callable);
} elseif (\is_array($callable) && \is_string($callable[0])) {
if (!$r instanceof \ReflectionMethod || $r->isStatic()) {
- $compiler->raw(sprintf('%s::%s', $callable[0], $callable[1]));
+ $compiler->raw(\sprintf('%s::%s', $callable[0], $callable[1]));
} else {
- $compiler->raw(sprintf('$this->env->getRuntime(\'%s\')->%s', $callable[0], $callable[1]));
+ $compiler->raw(\sprintf('$this->env->getRuntime(\'%s\')->%s', $callable[0], $callable[1]));
}
} elseif (\is_array($callable) && $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));
+ $compiler->raw(\sprintf('$this->env->getExtension(\'%s\')', $class));
} else {
- $compiler->raw(sprintf('$this->extensions[\'%s\']', ltrim($class, '\\')));
+ $compiler->raw(\sprintf('$this->extensions[\'%s\']', ltrim($class, '\\')));
}
- $compiler->raw(sprintf('->%s', $callable[1]));
+ $compiler->raw(\sprintf('->%s', $callable[1]));
} else {
- $compiler->raw(sprintf('$this->env->get%s(\'%s\')->getCallable()', ucfirst($this->getAttribute('type')), $this->getAttribute('name')));
+ $compiler->raw(\sprintf('$this->env->get%s(\'%s\')->getCallable()', ucfirst($this->getAttribute('type')), $twigCallable->getDynamicName()));
}
}
@@ -57,16 +66,30 @@
protected function compileArguments(Compiler $compiler, $isArray = false): void
{
+ if (\func_num_args() >= 2) {
+ trigger_deprecation('twig/twig', '3.11', 'Passing a second argument to "%s()" is deprecated.', __METHOD__);
+ }
+
$compiler->raw($isArray ? '[' : '(');
$first = true;
- if ($this->hasAttribute('needs_environment') && $this->getAttribute('needs_environment')) {
+ $twigCallable = $this->getAttribute('twig_callable');
+
+ if ($twigCallable->needsCharset()) {
+ $compiler->raw('$this->env->getCharset()');
+ $first = false;
+ }
+
+ if ($twigCallable->needsEnvironment()) {
+ if (!$first) {
+ $compiler->raw(', ');
+ }
$compiler->raw('$this->env');
$first = false;
}
- if ($this->hasAttribute('needs_context') && $this->getAttribute('needs_context')) {
+ if ($twigCallable->needsContext()) {
if (!$first) {
$compiler->raw(', ');
}
@@ -74,14 +97,12 @@
$first = false;
}
- if ($this->hasAttribute('arguments')) {
- foreach ($this->getAttribute('arguments') as $argument) {
- if (!$first) {
- $compiler->raw(', ');
- }
- $compiler->string($argument);
- $first = false;
+ foreach ($twigCallable->getArguments() as $argument) {
+ if (!$first) {
+ $compiler->raw(', ');
}
+ $compiler->string($argument);
+ $first = false;
}
if ($this->hasNode('node')) {
@@ -93,8 +114,7 @@
}
if ($this->hasNode('arguments')) {
- $callable = $this->getAttribute('callable');
- $arguments = $this->getArguments($callable, $this->getNode('arguments'));
+ $arguments = (new CallableArgumentsExtractor($this, $this->getTwigCallable()))->extractArguments($this->getNode('arguments'));
foreach ($arguments as $node) {
if (!$first) {
$compiler->raw(', ');
@@ -107,8 +127,13 @@
$compiler->raw($isArray ? ']' : ')');
}
+ /**
+ * @deprecated since 3.12, use Twig\Util\CallableArgumentsExtractor::getArguments() instead
+ */
protected function getArguments($callable, $arguments)
{
+ trigger_deprecation('twig/twig', '3.12', 'The "%s()" method is deprecated, use Twig\Util\CallableArgumentsExtractor::getArguments() instead.', __METHOD__);
+
$callType = $this->getAttribute('type');
$callName = $this->getAttribute('name');
@@ -119,28 +144,28 @@
$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());
+ 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');
+ $isVariadic = $this->getAttribute('twig_callable')->isVariadic();
if (!$named && !$isVariadic) {
return $parameters;
}
if (!$callable) {
if ($named) {
- $message = sprintf('Named arguments are not supported for %s "%s".', $callType, $callName);
+ $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);
+ $message = \sprintf('Arbitrary positional arguments are not supported for %s "%s".', $callType, $callName);
}
throw new \LogicException($message);
}
- list($callableParameters, $isPhpVariadic) = $this->getCallableParameters($callable, $isVariadic);
+ [$callableParameters, $isPhpVariadic] = $this->getCallableParameters($callable, $isVariadic);
$arguments = [];
$names = [];
$missingArguments = [];
@@ -160,11 +185,11 @@
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());
+ 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(
+ 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());
@@ -189,7 +214,7 @@
$missingArguments[] = $name;
}
} else {
- throw new SyntaxError(sprintf('Value for argument "%s" is required for %s "%s".', $name, $callType, $callName), $this->getTemplateLine(), $this->getSourceContext());
+ throw new SyntaxError(\sprintf('Value for argument "%s" is required for %s "%s".', $name, $callType, $callName), $this->getTemplateLine(), $this->getSourceContext());
}
}
@@ -220,7 +245,7 @@
}
throw new SyntaxError(
- sprintf(
+ \sprintf(
'Unknown argument%s "%s" for %s "%s(%s)".',
\count($parameters) > 1 ? 's' : '', implode('", "', array_keys($parameters)), $callType, $callName, implode(', ', $names)
),
@@ -232,88 +257,106 @@
return $arguments;
}
+ /**
+ * @deprecated since 3.12
+ */
protected function normalizeName(string $name): string
{
+ trigger_deprecation('twig/twig', '3.12', 'The "%s()" method is deprecated.', __METHOD__);
+
return strtolower(preg_replace(['/([A-Z]+)([A-Z][a-z])/', '/([a-z\d])([A-Z])/'], ['\\1_\\2', '\\1_\\2'], $name));
}
+ // To be removed in 4.0
private function getCallableParameters($callable, bool $isVariadic): array
{
- [$r, , $callableName] = $this->reflectCallable($callable);
+ $twigCallable = $this->getAttribute('twig_callable');
+ $rc = $this->reflectCallable($twigCallable);
+ $r = $rc->getReflector();
+ $callableName = $rc->getName();
$parameters = $r->getParameters();
if ($this->hasNode('node')) {
array_shift($parameters);
}
- if ($this->hasAttribute('needs_environment') && $this->getAttribute('needs_environment')) {
+ if ($twigCallable->needsCharset()) {
array_shift($parameters);
}
- if ($this->hasAttribute('needs_context') && $this->getAttribute('needs_context')) {
+ if ($twigCallable->needsEnvironment()) {
array_shift($parameters);
}
- if ($this->hasAttribute('arguments') && null !== $this->getAttribute('arguments')) {
- foreach ($this->getAttribute('arguments') as $argument) {
- array_shift($parameters);
- }
+ if ($twigCallable->needsContext()) {
+ array_shift($parameters);
}
+ foreach ($twigCallable->getArguments() as $argument) {
+ array_shift($parameters);
+ }
+
$isPhpVariadic = false;
if ($isVariadic) {
$argument = end($parameters);
- $isArray = $argument && $argument->hasType() && 'array' === $argument->getType()->getName();
+ $isArray = $argument && $argument->hasType() && $argument->getType() instanceof \ReflectionNamedType && 'array' === $argument->getType()->getName();
if ($isArray && $argument->isDefaultValueAvailable() && [] === $argument->getDefaultValue()) {
array_pop($parameters);
} elseif ($argument && $argument->isVariadic()) {
array_pop($parameters);
$isPhpVariadic = true;
} else {
- 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')));
+ 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'), $twigCallable->getName()));
}
}
return [$parameters, $isPhpVariadic];
}
- private function reflectCallable($callable)
+ private function reflectCallable(TwigCallableInterface $callable): ReflectionCallable
{
- if (null !== $this->reflector) {
- return $this->reflector;
+ if (!$this->reflector) {
+ $this->reflector = new ReflectionCallable($callable);
}
- if (\is_string($callable) && false !== $pos = strpos($callable, '::')) {
- $callable = [substr($callable, 0, $pos), substr($callable, 2 + $pos)];
- }
+ return $this->reflector;
+ }
- if (\is_array($callable) && method_exists($callable[0], $callable[1])) {
- $r = new \ReflectionMethod($callable[0], $callable[1]);
+ /**
+ * Overrides the Twig callable based on attributes (as potentially, attributes changed between the creation and the compilation of the node).
+ *
+ * To be removed in 4.0 and replace by $this->getAttribute('twig_callable').
+ */
+ private function getTwigCallable(): TwigCallableInterface
+ {
+ $current = $this->getAttribute('twig_callable');
- return $this->reflector = [$r, $callable, $r->class.'::'.$r->name];
- }
+ $this->setAttribute('twig_callable', match ($this->getAttribute('type')) {
+ 'test' => (new TwigTest(
+ $this->getAttribute('name'),
+ $this->hasAttribute('callable') ? $this->getAttribute('callable') : $current->getCallable(),
+ [
+ 'is_variadic' => $this->hasAttribute('is_variadic') ? $this->getAttribute('is_variadic') : $current->isVariadic(),
+ ],
+ ))->withDynamicArguments($this->getAttribute('name'), $this->hasAttribute('dynamic_name') ? $this->getAttribute('dynamic_name') : $current->getDynamicName(), $this->hasAttribute('arguments') ?: $current->getArguments()),
+ 'function' => (new TwigFunction(
+ $this->hasAttribute('name') ? $this->getAttribute('name') : $current->getName(),
+ $this->hasAttribute('callable') ? $this->getAttribute('callable') : $current->getCallable(),
+ [
+ 'needs_environment' => $this->hasAttribute('needs_environment') ? $this->getAttribute('needs_environment') : $current->needsEnvironment(),
+ 'needs_context' => $this->hasAttribute('needs_context') ? $this->getAttribute('needs_context') : $current->needsContext(),
+ 'needs_charset' => $this->hasAttribute('needs_charset') ? $this->getAttribute('needs_charset') : $current->needsCharset(),
+ 'is_variadic' => $this->hasAttribute('is_variadic') ? $this->getAttribute('is_variadic') : $current->isVariadic(),
+ ],
+ ))->withDynamicArguments($this->getAttribute('name'), $this->hasAttribute('dynamic_name') ? $this->getAttribute('dynamic_name') : $current->getDynamicName(), $this->hasAttribute('arguments') ?: $current->getArguments()),
+ 'filter' => (new TwigFilter(
+ $this->getAttribute('name'),
+ $this->hasAttribute('callable') ? $this->getAttribute('callable') : $current->getCallable(),
+ [
+ 'needs_environment' => $this->hasAttribute('needs_environment') ? $this->getAttribute('needs_environment') : $current->needsEnvironment(),
+ 'needs_context' => $this->hasAttribute('needs_context') ? $this->getAttribute('needs_context') : $current->needsContext(),
+ 'needs_charset' => $this->hasAttribute('needs_charset') ? $this->getAttribute('needs_charset') : $current->needsCharset(),
+ 'is_variadic' => $this->hasAttribute('is_variadic') ? $this->getAttribute('is_variadic') : $current->isVariadic(),
+ ],
+ ))->withDynamicArguments($this->getAttribute('name'), $this->hasAttribute('dynamic_name') ? $this->getAttribute('dynamic_name') : $current->getDynamicName(), $this->hasAttribute('arguments') ?: $current->getArguments()),
+ });
- $checkVisibility = $callable instanceof \Closure;
- try {
- $closure = \Closure::fromCallable($callable);
- } catch (\TypeError $e) {
- throw new \LogicException(sprintf('Callback for %s "%s" is not callable in the current scope.', $this->getAttribute('type'), $this->getAttribute('name')), 0, $e);
- }
- $r = new \ReflectionFunction($closure);
-
- if (false !== strpos($r->name, '{closure}')) {
- return $this->reflector = [$r, $callable, 'Closure'];
- }
-
- if ($object = $r->getClosureThis()) {
- $callable = [$object, $r->name];
- $callableName = (\function_exists('get_debug_type') ? get_debug_type($object) : \get_class($object)).'::'.$r->name;
- } elseif ($class = $r->getClosureScopeClass()) {
- $callableName = (\is_array($callable) ? $callable[0] : $class->name).'::'.$r->name;
- } else {
- $callable = $callableName = $r->name;
- }
-
- if ($checkVisibility && \is_array($callable) && method_exists(...$callable) && !(new \ReflectionMethod(...$callable))->isPublic()) {
- $callable = $r->getClosure();
- }
-
- return $this->reflector = [$r, $callable, $callableName];
+ return $this->getAttribute('twig_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
index 2c7bd0a..d7db993 100644
--- 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
@@ -23,14 +23,23 @@
public function compile(Compiler $compiler): void
{
- $compiler
- ->raw('((')
- ->subcompile($this->getNode('expr1'))
- ->raw(') ? (')
- ->subcompile($this->getNode('expr2'))
- ->raw(') : (')
- ->subcompile($this->getNode('expr3'))
- ->raw('))')
- ;
+ // Ternary with no then uses Elvis operator
+ if ($this->getNode('expr1') === $this->getNode('expr2')) {
+ $compiler
+ ->raw('((')
+ ->subcompile($this->getNode('expr1'))
+ ->raw(') ?: (')
+ ->subcompile($this->getNode('expr3'))
+ ->raw('))');
+ } else {
+ $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
index 7ddbcc6..2a8909d 100644
--- 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
@@ -14,6 +14,9 @@
use Twig\Compiler;
+/**
+ * @final
+ */
class ConstantExpression extends AbstractExpression
{
public function __construct($value, int $lineno)
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
index 6a572d4..75b6d18 100644
--- 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
@@ -11,7 +11,9 @@
namespace Twig\Node\Expression\Filter;
+use Twig\Attribute\FirstClassTwigCallableReady;
use Twig\Compiler;
+use Twig\Extension\CoreExtension;
use Twig\Node\Expression\ConditionalExpression;
use Twig\Node\Expression\ConstantExpression;
use Twig\Node\Expression\FilterExpression;
@@ -19,6 +21,8 @@
use Twig\Node\Expression\NameExpression;
use Twig\Node\Expression\Test\DefinedTest;
use Twig\Node\Node;
+use Twig\TwigFilter;
+use Twig\TwigTest;
/**
* Returns the value or the default value when it is undefined or empty.
@@ -29,20 +33,27 @@
*/
class DefaultFilter extends FilterExpression
{
- public function __construct(Node $node, ConstantExpression $filterName, Node $arguments, int $lineno, string $tag = null)
+ #[FirstClassTwigCallableReady]
+ public function __construct(Node $node, TwigFilter|ConstantExpression $filter, Node $arguments, int $lineno)
{
- $default = new FilterExpression($node, new ConstantExpression('default', $node->getTemplateLine()), $arguments, $node->getTemplateLine());
+ if ($filter instanceof TwigFilter) {
+ $name = $filter->getName();
+ $default = new FilterExpression($node, $filter, $arguments, $node->getTemplateLine());
+ } else {
+ $name = $filter->getAttribute('value');
+ $default = new FilterExpression($node, new TwigFilter('default', [CoreExtension::class, 'default']), $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());
+ if ('default' === $name && ($node instanceof NameExpression || $node instanceof GetAttrExpression)) {
+ $test = new DefinedTest(clone $node, new TwigTest('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);
+ parent::__construct($node, $filter, $arguments, $lineno);
}
public function compile(Compiler $compiler): void
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Filter/RawFilter.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Filter/RawFilter.php
new file mode 100644
index 0000000..e115ab1
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Filter/RawFilter.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\Filter;
+
+use Twig\Attribute\FirstClassTwigCallableReady;
+use Twig\Compiler;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\FilterExpression;
+use Twig\Node\Node;
+use Twig\TwigFilter;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class RawFilter extends FilterExpression
+{
+ #[FirstClassTwigCallableReady]
+ public function __construct(Node $node, TwigFilter|ConstantExpression|null $filter = null, ?Node $arguments = null, int $lineno = 0)
+ {
+ parent::__construct($node, $filter ?: new TwigFilter('raw', null, ['is_safe' => ['all']]), $arguments ?: new Node(), $lineno ?: $node->getTemplateLine());
+ }
+
+ 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
index 0fc1588..efc9119 100644
--- 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
@@ -12,28 +12,61 @@
namespace Twig\Node\Expression;
+use Twig\Attribute\FirstClassTwigCallableReady;
use Twig\Compiler;
+use Twig\Node\NameDeprecation;
use Twig\Node\Node;
+use Twig\TwigFilter;
class FilterExpression extends CallExpression
{
- public function __construct(Node $node, ConstantExpression $filterName, Node $arguments, int $lineno, string $tag = null)
+ #[FirstClassTwigCallableReady]
+ public function __construct(Node $node, TwigFilter|ConstantExpression $filter, Node $arguments, int $lineno)
{
- parent::__construct(['node' => $node, 'filter' => $filterName, 'arguments' => $arguments], [], $lineno, $tag);
+ if ($filter instanceof TwigFilter) {
+ $name = $filter->getName();
+ $filterName = new ConstantExpression($name, $lineno);
+ } else {
+ $name = $filter->getAttribute('value');
+ $filterName = $filter;
+ trigger_deprecation('twig/twig', '3.12', 'Not passing an instance of "TwigFilter" when creating a "%s" filter of type "%s" is deprecated.', $name, static::class);
+ }
+
+ parent::__construct(['node' => $node, 'filter' => $filterName, 'arguments' => $arguments], ['name' => $name, 'type' => 'filter'], $lineno);
+
+ if ($filter instanceof TwigFilter) {
+ $this->setAttribute('twig_callable', $filter);
+ }
+
+ $this->deprecateNode('filter', new NameDeprecation('twig/twig', '3.12'));
+
+ $this->deprecateAttribute('needs_charset', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('needs_environment', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('needs_context', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('arguments', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('callable', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('is_variadic', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('dynamic_name', new NameDeprecation('twig/twig', '3.12'));
}
public function compile(Compiler $compiler): void
{
- $name = $this->getNode('filter')->getAttribute('value');
- $filter = $compiler->getEnvironment()->getFilter($name);
+ $name = $this->getNode('filter', false)->getAttribute('value');
+ if ($name !== $this->getAttribute('name')) {
+ trigger_deprecation('twig/twig', '3.11', 'Changing the value of a "filter" node in a NodeVisitor class is not supported anymore.');
+ $this->removeAttribute('twig_callable');
+ }
+ if ('raw' === $name) {
+ trigger_deprecation('twig/twig', '3.11', 'Creating the "raw" filter via "FilterExpression" is deprecated; use "RawFilter" instead.');
- $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());
+ $compiler->subcompile($this->getNode('node'));
+
+ return;
+ }
+
+ if (!$this->hasAttribute('twig_callable')) {
+ $this->setAttribute('twig_callable', $compiler->getEnvironment()->getFilter($name));
+ }
$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
index 7126977..6215c6a 100644
--- 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
@@ -11,32 +11,57 @@
namespace Twig\Node\Expression;
+use Twig\Attribute\FirstClassTwigCallableReady;
use Twig\Compiler;
+use Twig\Node\NameDeprecation;
use Twig\Node\Node;
+use Twig\TwigFunction;
class FunctionExpression extends CallExpression
{
- public function __construct(string $name, Node $arguments, int $lineno)
+ #[FirstClassTwigCallableReady]
+ public function __construct(TwigFunction|string $function, Node $arguments, int $lineno)
{
- parent::__construct(['arguments' => $arguments], ['name' => $name, 'is_defined_test' => false], $lineno);
+ if ($function instanceof TwigFunction) {
+ $name = $function->getName();
+ } else {
+ $name = $function;
+ trigger_deprecation('twig/twig', '3.12', 'Not passing an instance of "TwigFunction" when creating a "%s" function of type "%s" is deprecated.', $name, static::class);
+ }
+
+ parent::__construct(['arguments' => $arguments], ['name' => $name, 'type' => 'function', 'is_defined_test' => false], $lineno);
+
+ if ($function instanceof TwigFunction) {
+ $this->setAttribute('twig_callable', $function);
+ }
+
+ $this->deprecateAttribute('needs_charset', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('needs_environment', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('needs_context', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('arguments', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('callable', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('is_variadic', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('dynamic_name', new NameDeprecation('twig/twig', '3.12'));
}
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';
+ if ($this->hasAttribute('twig_callable')) {
+ $name = $this->getAttribute('twig_callable')->getName();
+ if ($name !== $this->getAttribute('name')) {
+ trigger_deprecation('twig/twig', '3.12', 'Changing the value of a "function" node in a NodeVisitor class is not supported anymore.');
+ $this->removeAttribute('twig_callable');
+ }
}
- $this->setAttribute('callable', $callable);
- $this->setAttribute('is_variadic', $function->isVariadic());
+
+ if (!$this->hasAttribute('twig_callable')) {
+ $this->setAttribute('twig_callable', $compiler->getEnvironment()->getFunction($name));
+ }
+
+ if ('constant' === $name && $this->getAttribute('is_defined_test')) {
+ $this->getNode('arguments')->setNode('checkDefined', new ConstantExpression(true, $this->getTemplateLine()));
+ }
$this->compileCallable($compiler);
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FunctionNode/EnumCasesFunction.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FunctionNode/EnumCasesFunction.php
new file mode 100644
index 0000000..7e5c25f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/FunctionNode/EnumCasesFunction.php
@@ -0,0 +1,41 @@
+<?php
+
+namespace Twig\Node\Expression\FunctionNode;
+
+use Twig\Compiler;
+use Twig\Error\SyntaxError;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\FunctionExpression;
+
+class EnumCasesFunction extends FunctionExpression
+{
+ public function compile(Compiler $compiler): void
+ {
+ $arguments = $this->getNode('arguments');
+ if ($arguments->hasNode('enum')) {
+ $firstArgument = $arguments->getNode('enum');
+ } elseif ($arguments->hasNode('0')) {
+ $firstArgument = $arguments->getNode('0');
+ } else {
+ $firstArgument = null;
+ }
+
+ if (!$firstArgument instanceof ConstantExpression || 1 !== \count($arguments)) {
+ parent::compile($compiler);
+
+ return;
+ }
+
+ $value = $firstArgument->getAttribute('value');
+
+ if (!\is_string($value)) {
+ throw new SyntaxError('The first argument of the "enum_cases" function must be a string.', $this->getTemplateLine(), $this->getSourceContext());
+ }
+
+ if (!enum_exists($value)) {
+ throw new SyntaxError(\sprintf('The first argument of the "enum_cases" function must be the name of an enum, "%s" given.', $value), $this->getTemplateLine(), $this->getSourceContext());
+ }
+
+ $compiler->raw(\sprintf('%s::cases()', $value));
+ }
+}
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
index e6a75ce..29a446b 100644
--- 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
@@ -57,7 +57,7 @@
return;
}
- $compiler->raw('twig_get_attribute($this->env, $this->source, ');
+ $compiler->raw('CoreExtension::getAttribute($this->env, $this->source, ');
if ($this->getAttribute('ignore_strict_check')) {
$this->getNode('node')->setAttribute('ignore_strict_check', true);
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
index 1ad4751..0a3c2e4 100644
--- 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
@@ -27,9 +27,8 @@
public function compile(Compiler $compiler): void
{
$compiler
- ->raw('print (')
+ ->raw('yield ')
->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
index d5ec0b6..01806f9 100644
--- 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
@@ -39,14 +39,16 @@
}
$compiler
- ->raw('twig_call_macro($macros[')
+ ->raw('CoreExtension::callMacro($macros[')
->repr($this->getNode('node')->getAttribute('name'))
->raw('], ')
->repr($this->getAttribute('method'))
->raw(', [')
;
$first = true;
- foreach ($this->getNode('arguments')->getKeyValuePairs() as $pair) {
+ /** @var ArrayExpression */
+ $args = $this->getNode('arguments');
+ foreach ($args->getKeyValuePairs() as $pair) {
if (!$first) {
$compiler->raw(', ');
}
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
index c3563f0..286aa5a 100644
--- 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
@@ -34,7 +34,7 @@
$compiler->addDebugInfo($this);
if ($this->getAttribute('is_defined_test')) {
- if ($this->isSpecial()) {
+ if (isset($this->specialVars[$name])) {
$compiler->repr(true);
} elseif (\PHP_VERSION_ID >= 70400) {
$compiler
@@ -51,7 +51,7 @@
->raw(', $context))')
;
}
- } elseif ($this->isSpecial()) {
+ } elseif (isset($this->specialVars[$name])) {
$compiler->raw($this->specialVars[$name]);
} elseif ($this->getAttribute('always_defined')) {
$compiler
@@ -85,13 +85,23 @@
}
}
+ /**
+ * @deprecated since Twig 3.11 (to be removed in 4.0)
+ */
public function isSpecial()
{
+ trigger_deprecation('twig/twig', '3.11', 'The "%s()" method is deprecated and will be removed in Twig 4.0.', __METHOD__);
+
return isset($this->specialVars[$this->getAttribute('name')]);
}
+ /**
+ * @deprecated since Twig 3.11 (to be removed in 4.0)
+ */
public function isSimple()
{
+ trigger_deprecation('twig/twig', '3.11', 'The "%s()" method is deprecated and will be removed in Twig 4.0.', __METHOD__);
+
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
index a72bc4f..98630f7 100644
--- 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
@@ -17,17 +17,18 @@
use Twig\Node\Expression\Test\NullTest;
use Twig\Node\Expression\Unary\NotUnary;
use Twig\Node\Node;
+use Twig\TwigTest;
class NullCoalesceExpression extends ConditionalExpression
{
public function __construct(Node $left, Node $right, int $lineno)
{
- $test = new DefinedTest(clone $left, 'defined', new Node(), $left->getTemplateLine());
+ $test = new DefinedTest(clone $left, new TwigTest('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()),
+ new NotUnary(new NullTest($left, new TwigTest('null'), new Node(), $left->getTemplateLine()), $left->getTemplateLine()),
$left->getTemplateLine()
);
}
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
index 2549197..22fe38f 100644
--- 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
@@ -21,9 +21,9 @@
*/
class ParentExpression extends AbstractExpression
{
- public function __construct(string $name, int $lineno, string $tag = null)
+ public function __construct(string $name, int $lineno)
{
- parent::__construct([], ['output' => false, 'name' => $name], $lineno, $tag);
+ parent::__construct([], ['output' => false, 'name' => $name], $lineno);
}
public function compile(Compiler $compiler): void
@@ -31,7 +31,7 @@
if ($this->getAttribute('output')) {
$compiler
->addDebugInfo($this)
- ->write('$this->displayParentBlock(')
+ ->write('yield from $this->yieldParentBlock(')
->string($this->getAttribute('name'))
->raw(", \$context, \$blocks);\n")
;
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
index 57e9319..867fd09 100644
--- 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
@@ -33,16 +33,16 @@
->raw(' === constant(')
;
- if ($this->getNode('arguments')->hasNode(1)) {
+ if ($this->getNode('arguments')->hasNode('1')) {
$compiler
->raw('get_class(')
- ->subcompile($this->getNode('arguments')->getNode(1))
+ ->subcompile($this->getNode('arguments')->getNode('1'))
->raw(')."::".')
;
}
$compiler
- ->subcompile($this->getNode('arguments')->getNode(0))
+ ->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
index 3953bbb..24d3ee8 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node\Expression\Test;
+use Twig\Attribute\FirstClassTwigCallableReady;
use Twig\Compiler;
use Twig\Error\SyntaxError;
use Twig\Node\Expression\ArrayExpression;
@@ -22,6 +23,7 @@
use Twig\Node\Expression\NameExpression;
use Twig\Node\Expression\TestExpression;
use Twig\Node\Node;
+use Twig\TwigTest;
/**
* Checks if a variable is defined in the current context.
@@ -35,7 +37,8 @@
*/
class DefinedTest extends TestExpression
{
- public function __construct(Node $node, string $name, ?Node $arguments, int $lineno)
+ #[FirstClassTwigCallableReady]
+ public function __construct(Node $node, TwigTest|string $name, ?Node $arguments, int $lineno)
{
if ($node instanceof NameExpression) {
$node->setAttribute('is_defined_test', true);
@@ -54,6 +57,10 @@
throw new SyntaxError('The "defined" test only works with simple variables.', $lineno);
}
+ if (\is_string($name) && 'defined' !== $name) {
+ trigger_deprecation('twig/twig', '3.12', 'Creating a "DefinedTest" instance with a test name that is not "defined" is deprecated.');
+ }
+
parent::__construct($node, $name, $arguments, $lineno);
}
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
index 4cb3ee0..90d58a4 100644
--- 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
@@ -29,7 +29,7 @@
->raw('(0 == ')
->subcompile($this->getNode('node'))
->raw(' % ')
- ->subcompile($this->getNode('arguments')->getNode(0))
+ ->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/SameasTest.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/Expression/Test/SameasTest.php
index c96d2bc..f1e24db 100644
--- 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
@@ -27,7 +27,7 @@
->raw('(')
->subcompile($this->getNode('node'))
->raw(' === ')
- ->subcompile($this->getNode('arguments')->getNode(0))
+ ->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
index e518bd8..080d85a 100644
--- 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
@@ -11,31 +11,55 @@
namespace Twig\Node\Expression;
+use Twig\Attribute\FirstClassTwigCallableReady;
use Twig\Compiler;
+use Twig\Node\NameDeprecation;
use Twig\Node\Node;
+use Twig\TwigTest;
class TestExpression extends CallExpression
{
- public function __construct(Node $node, string $name, ?Node $arguments, int $lineno)
+ #[FirstClassTwigCallableReady]
+ public function __construct(Node $node, string|TwigTest $test, ?Node $arguments, int $lineno)
{
$nodes = ['node' => $node];
if (null !== $arguments) {
$nodes['arguments'] = $arguments;
}
- parent::__construct($nodes, ['name' => $name], $lineno);
+ if ($test instanceof TwigTest) {
+ $name = $test->getName();
+ } else {
+ $name = $test;
+ trigger_deprecation('twig/twig', '3.12', 'Not passing an instance of "TwigTest" when creating a "%s" test of type "%s" is deprecated.', $name, static::class);
+ }
+
+ parent::__construct($nodes, ['name' => $name, 'type' => 'test'], $lineno);
+
+ if ($test instanceof TwigTest) {
+ $this->setAttribute('twig_callable', $test);
+ }
+
+ $this->deprecateAttribute('arguments', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('callable', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('is_variadic', new NameDeprecation('twig/twig', '3.12'));
+ $this->deprecateAttribute('dynamic_name', new NameDeprecation('twig/twig', '3.12'));
}
public function compile(Compiler $compiler): void
{
$name = $this->getAttribute('name');
- $test = $compiler->getEnvironment()->getTest($name);
+ if ($this->hasAttribute('twig_callable')) {
+ $name = $this->getAttribute('twig_callable')->getName();
+ if ($name !== $this->getAttribute('name')) {
+ trigger_deprecation('twig/twig', '3.12', 'Changing the value of a "test" node in a NodeVisitor class is not supported anymore.');
+ $this->removeAttribute('twig_callable');
+ }
+ }
- $this->setAttribute('name', $name);
- $this->setAttribute('type', 'test');
- $this->setAttribute('arguments', $test->getArguments());
- $this->setAttribute('callable', $test->getCallable());
- $this->setAttribute('is_variadic', $test->isVariadic());
+ if (!$this->hasAttribute('twig_callable')) {
+ $this->setAttribute('twig_callable', $compiler->getEnvironment()->getTest($this->getAttribute('name')));
+ }
$this->compileCallable($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
index fa50a88..ff3bd1c 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -18,18 +19,22 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class FlushNode extends Node
{
- public function __construct(int $lineno, string $tag)
+ public function __construct(int $lineno)
{
- parent::__construct([], [], $lineno, $tag);
+ parent::__construct([], [], $lineno);
}
public function compile(Compiler $compiler): void
{
- $compiler
- ->addDebugInfo($this)
- ->write("flush();\n")
- ;
+ $compiler->addDebugInfo($this);
+
+ if ($compiler->getEnvironment()->useYield()) {
+ $compiler->write("yield '';\n");
+ }
+
+ $compiler->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
index d5ce845..1f0a4f3 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -18,11 +19,12 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class ForLoopNode extends Node
{
- public function __construct(int $lineno, string $tag = null)
+ public function __construct(int $lineno)
{
- parent::__construct([], ['with_loop' => false, 'ifexpr' => false, 'else' => false], $lineno, $tag);
+ parent::__construct([], ['with_loop' => false, 'ifexpr' => false, 'else' => false], $lineno);
}
public function compile(Compiler $compiler): void
@@ -36,7 +38,7 @@
->write("++\$context['loop']['index0'];\n")
->write("++\$context['loop']['index'];\n")
->write("\$context['loop']['first'] = false;\n")
- ->write("if (isset(\$context['loop']['length'])) {\n")
+ ->write("if (isset(\$context['loop']['revindex0'], \$context['loop']['revindex'])) {\n")
->indent()
->write("--\$context['loop']['revindex0'];\n")
->write("--\$context['loop']['revindex'];\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
index 04addfb..2fc0147 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
use Twig\Node\Expression\AssignNameExpression;
@@ -21,20 +22,21 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
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)
+ public function __construct(AssignNameExpression $keyTarget, AssignNameExpression $valueTarget, AbstractExpression $seq, ?Node $ifexpr, Node $body, ?Node $else, int $lineno)
{
- $body = new Node([$body, $this->loop = new ForLoopNode($lineno, $tag)]);
+ $body = new Node([$body, $this->loop = new ForLoopNode($lineno)]);
$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);
+ parent::__construct($nodes, ['with_loop' => true], $lineno);
}
public function compile(Compiler $compiler): void
@@ -42,7 +44,7 @@
$compiler
->addDebugInfo($this)
->write("\$context['_parent'] = \$context;\n")
- ->write("\$context['_seq'] = twig_ensure_traversable(")
+ ->write("\$context['_seq'] = CoreExtension::ensureTraversable(")
->subcompile($this->getNode('seq'))
->raw(");\n")
;
@@ -99,7 +101,14 @@
$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");
+ $compiler->write('unset($context[\'_seq\'], $context[\''.$this->getNode('key_target')->getAttribute('name').'\'], $context[\''.$this->getNode('value_target')->getAttribute('name').'\'], $context[\'_parent\']');
+ if ($this->hasNode('else')) {
+ $compiler->raw(', $context[\'_iterated\']');
+ }
+ if ($this->getAttribute('with_loop')) {
+ $compiler->raw(', $context[\'loop\']');
+ }
+ $compiler->raw(");\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
index 5fa2008..2af48fa 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -19,16 +20,17 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class IfNode extends Node
{
- public function __construct(Node $tests, ?Node $else, int $lineno, string $tag = null)
+ public function __construct(Node $tests, ?Node $else, int $lineno)
{
$nodes = ['tests' => $tests];
if (null !== $else) {
$nodes['else'] = $else;
}
- parent::__construct($nodes, [], $lineno, $tag);
+ parent::__construct($nodes, [], $lineno);
}
public function compile(Compiler $compiler): void
@@ -47,11 +49,14 @@
}
$compiler
- ->subcompile($this->getNode('tests')->getNode($i))
+ ->subcompile($this->getNode('tests')->getNode((string) $i))
->raw(") {\n")
->indent()
- ->subcompile($this->getNode('tests')->getNode($i + 1))
;
+ // The node might not exists if the content is empty
+ if ($this->getNode('tests')->hasNode((string) ($i + 1))) {
+ $compiler->subcompile($this->getNode('tests')->getNode((string) ($i + 1)));
+ }
}
if ($this->hasNode('else')) {
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
index 5378d79..9a6033f 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
use Twig\Node\Expression\NameExpression;
@@ -20,11 +21,22 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class ImportNode extends Node
{
- public function __construct(AbstractExpression $expr, AbstractExpression $var, int $lineno, string $tag = null, bool $global = true)
+ /**
+ * @param bool $global
+ */
+ public function __construct(AbstractExpression $expr, AbstractExpression $var, int $lineno, $global = true)
{
- parent::__construct(['expr' => $expr, 'var' => $var], ['global' => $global], $lineno, $tag);
+ if (null === $global || \is_string($global)) {
+ trigger_deprecation('twig/twig', '3.12', 'Passing a tag to %s() is deprecated.', __METHOD__);
+ $global = \func_num_args() > 4 ? func_get_arg(4) : true;
+ } elseif (!\is_bool($global)) {
+ throw new \TypeError(\sprintf('Argument 4 passed to "%s()" must be a boolean, "%s" given.', __METHOD__, get_debug_type($global)));
+ }
+
+ parent::__construct(['expr' => $expr, 'var' => $var], ['global' => $global], $lineno);
}
public function compile(Compiler $compiler): void
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
index d540d6b..1c18292 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
@@ -20,16 +21,17 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class IncludeNode extends Node implements NodeOutputInterface
{
- public function __construct(AbstractExpression $expr, ?AbstractExpression $variables, bool $only, bool $ignoreMissing, int $lineno, string $tag = null)
+ public function __construct(AbstractExpression $expr, ?AbstractExpression $variables, bool $only, bool $ignoreMissing, int $lineno)
{
$nodes = ['expr' => $expr];
if (null !== $variables) {
$nodes['variables'] = $variables;
}
- parent::__construct($nodes, ['only' => $only, 'ignore_missing' => $ignoreMissing], $lineno, $tag);
+ parent::__construct($nodes, ['only' => $only, 'ignore_missing' => $ignoreMissing], $lineno);
}
public function compile(Compiler $compiler): void
@@ -40,10 +42,10 @@
$template = $compiler->getVarName();
$compiler
- ->write(sprintf("$%s = null;\n", $template))
+ ->write(\sprintf("$%s = null;\n", $template))
->write("try {\n")
->indent()
- ->write(sprintf('$%s = ', $template))
+ ->write(\sprintf('$%s = ', $template))
;
$this->addGetTemplate($compiler);
@@ -56,10 +58,11 @@
->write("// ignore missing template\n")
->outdent()
->write("}\n")
- ->write(sprintf("if ($%s) {\n", $template))
+ ->write(\sprintf("if ($%s) {\n", $template))
->indent()
- ->write(sprintf('$%s->display(', $template))
+ ->write(\sprintf('yield from $%s->unwrap()->yield(', $template))
;
+
$this->addTemplateArguments($compiler);
$compiler
->raw(");\n")
@@ -67,8 +70,9 @@
->write("}\n")
;
} else {
+ $compiler->write('yield from ');
$this->addGetTemplate($compiler);
- $compiler->raw('->display(');
+ $compiler->raw('->unwrap()->yield(');
$this->addTemplateArguments($compiler);
$compiler->raw(");\n");
}
@@ -93,12 +97,12 @@
$compiler->raw(false === $this->getAttribute('only') ? '$context' : '[]');
} elseif (false === $this->getAttribute('only')) {
$compiler
- ->raw('twig_array_merge($context, ')
+ ->raw('CoreExtension::merge($context, ')
->subcompile($this->getNode('variables'))
->raw(')')
;
} else {
- $compiler->raw('twig_to_array(');
+ $compiler->raw('CoreExtension::toArray(');
$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
index 7f1b24d..5a2543a 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Error\SyntaxError;
@@ -19,26 +20,34 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class MacroNode extends Node
{
public const VARARGS_NAME = 'varargs';
- public function __construct(string $name, Node $body, Node $arguments, int $lineno, string $tag = null)
+ /**
+ * @param BodyNode $body
+ */
+ public function __construct(string $name, Node $body, Node $arguments, int $lineno)
{
+ if (!$body instanceof BodyNode) {
+ trigger_deprecation('twig/twig', '3.12', \sprintf('Not passing a "%s" instance as the "body" argument of the "%s" constructor is deprecated.', BodyNode::class, static::class));
+ }
+
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());
+ 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);
+ parent::__construct(['body' => $body, 'arguments' => $arguments], ['name' => $name], $lineno);
}
public function compile(Compiler $compiler): void
{
$compiler
->addDebugInfo($this)
- ->write(sprintf('public function macro_%s(', $this->getAttribute('name')))
+ ->write(\sprintf('public function macro_%s(', $this->getAttribute('name')))
;
$count = \count($this->getNode('arguments'));
@@ -64,7 +73,7 @@
->write("{\n")
->indent()
->write("\$macros = \$this->macros;\n")
- ->write("\$context = \$this->env->mergeGlobals([\n")
+ ->write("\$context = [\n")
->indent()
;
@@ -77,35 +86,19 @@
;
}
+ $node = new CaptureNode($this->getNode('body'), $this->getNode('body')->lineno);
+
$compiler
->write('')
->string(self::VARARGS_NAME)
->raw(' => ')
- ;
-
- $compiler
->raw("\$__varargs__,\n")
->outdent()
- ->write("]);\n\n")
+ ->write("] + \$this->env->getGlobals();\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'))
+ ->write('return ')
+ ->subcompile($node)
->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
index e972b6b..d2fb216 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
use Twig\Node\Expression\ConstantExpression;
@@ -20,16 +21,24 @@
/**
* 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.
+ * If you need to customize the behavior of the generated class, add nodes to
+ * the following nodes: display_start, display_end, constructor_start,
+ * constructor_end, and class_end.
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
final class ModuleNode extends Node
{
+ /**
+ * @param BodyNode $body
+ */
public function __construct(Node $body, ?AbstractExpression $parent, Node $blocks, Node $macros, Node $traits, $embeddedTemplates, Source $source)
{
+ if (!$body instanceof BodyNode) {
+ trigger_deprecation('twig/twig', '3.12', \sprintf('Not passing a "%s" instance as the "body" argument of the "%s" constructor is deprecated.', BodyNode::class, static::class));
+ }
+
$nodes = [
'body' => $body,
'blocks' => $blocks,
@@ -106,7 +115,7 @@
$parent = $this->getNode('parent');
$compiler
- ->write("protected function doGetParent(array \$context)\n", "{\n")
+ ->write("protected function doGetParent(array \$context): bool|string|Template|TemplateWrapper\n", "{\n")
->indent()
->addDebugInfo($parent)
->write('return ')
@@ -143,6 +152,7 @@
->write("use Twig\Environment;\n")
->write("use Twig\Error\LoaderError;\n")
->write("use Twig\Error\RuntimeError;\n")
+ ->write("use Twig\Extension\CoreExtension;\n")
->write("use Twig\Extension\SandboxExtension;\n")
->write("use Twig\Markup;\n")
->write("use Twig\Sandbox\SecurityError;\n")
@@ -150,7 +160,9 @@
->write("use Twig\Sandbox\SecurityNotAllowedFilterError;\n")
->write("use Twig\Sandbox\SecurityNotAllowedFunctionError;\n")
->write("use Twig\Source;\n")
- ->write("use Twig\Template;\n\n")
+ ->write("use Twig\Template;\n")
+ ->write("use Twig\TemplateWrapper;\n")
+ ->write("\n")
;
}
$compiler
@@ -160,8 +172,11 @@
->raw(" extends Template\n")
->write("{\n")
->indent()
- ->write("private \$source;\n")
- ->write("private \$macros = [];\n\n")
+ ->write("private Source \$source;\n")
+ ->write("/**\n")
+ ->write(" * @var array<string, Template>\n")
+ ->write(" */\n")
+ ->write("private array \$macros = [];\n\n")
;
}
@@ -188,14 +203,14 @@
$compiler
->addDebugInfo($node)
- ->write(sprintf('$_trait_%s = $this->loadTemplate(', $i))
+ ->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))
+ ->write(\sprintf("if (!\$_trait_%s->unwrap()->isTraitable()) {\n", $i))
->indent()
->write("throw new RuntimeError('Template \"'.")
->subcompile($trait->getNode('template'))
@@ -204,12 +219,12 @@
->raw(", \$this->source);\n")
->outdent()
->write("}\n")
- ->write(sprintf("\$_trait_%s_blocks = \$_trait_%s->getBlocks();\n\n", $i, $i))
+ ->write(\sprintf("\$_trait_%s_blocks = \$_trait_%s->unwrap()->getBlocks();\n\n", $i, $i))
;
foreach ($trait->getNode('targets') as $key => $value) {
$compiler
- ->write(sprintf('if (!isset($_trait_%s_blocks[', $i))
+ ->write(\sprintf('if (!isset($_trait_%s_blocks[', $i))
->string($key)
->raw("])) {\n")
->indent()
@@ -223,11 +238,11 @@
->outdent()
->write("}\n\n")
- ->write(sprintf('$_trait_%s_blocks[', $i))
+ ->write(\sprintf('$_trait_%s_blocks[', $i))
->subcompile($value)
- ->raw(sprintf('] = $_trait_%s_blocks[', $i))
+ ->raw(\sprintf('] = $_trait_%s_blocks[', $i))
->string($key)
- ->raw(sprintf(']; unset($_trait_%s_blocks[', $i))
+ ->raw(\sprintf(']; unset($_trait_%s_blocks[', $i))
->string($key)
->raw("]);\n\n")
;
@@ -242,7 +257,7 @@
for ($i = 0; $i < $countTraits; ++$i) {
$compiler
- ->write(sprintf('$_trait_%s_blocks'.($i == $countTraits - 1 ? '' : ',')."\n", $i))
+ ->write(\sprintf('$_trait_%s_blocks'.($i == $countTraits - 1 ? '' : ',')."\n", $i))
;
}
@@ -275,7 +290,7 @@
foreach ($this->getNode('blocks') as $name => $node) {
$compiler
- ->write(sprintf("'%s' => [\$this, 'block_%s'],\n", $name, $name))
+ ->write(\sprintf("'%s' => [\$this, 'block_%s'],\n", $name, $name))
;
}
@@ -303,7 +318,7 @@
protected function compileDisplay(Compiler $compiler)
{
$compiler
- ->write("protected function doDisplay(array \$context, array \$blocks = [])\n", "{\n")
+ ->write("protected function doDisplay(array \$context, array \$blocks = []): iterable\n", "{\n")
->indent()
->write("\$macros = \$this->macros;\n")
->subcompile($this->getNode('display_start'))
@@ -324,15 +339,24 @@
->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->write('yield from ');
+
+ if ($parent instanceof ConstantExpression) {
+ $compiler->raw('$this->parent');
+ } else {
+ $compiler->raw('$this->getParent($context)');
+ }
+ $compiler->raw("->unwrap()->yield(\$context, array_merge(\$this->blocks, \$blocks));\n");
+ }
+
+ $compiler->subcompile($this->getNode('display_end'));
+
+ if (!$this->hasNode('parent')) {
+ $compiler->write("yield from [];\n");
}
$compiler
- ->subcompile($this->getNode('display_end'))
->outdent()
->write("}\n\n")
;
@@ -355,7 +379,10 @@
protected function compileGetTemplateName(Compiler $compiler)
{
$compiler
- ->write("public function getTemplateName()\n", "{\n")
+ ->write("/**\n")
+ ->write(" * @codeCoverageIgnore\n")
+ ->write(" */\n")
+ ->write("public function getTemplateName(): string\n", "{\n")
->indent()
->write('return ')
->repr($this->getSourceContext()->getName())
@@ -377,7 +404,7 @@
$traitable = !$this->hasNode('parent') && 0 === \count($this->getNode('macros'));
if ($traitable) {
if ($this->getNode('body') instanceof BodyNode) {
- $nodes = $this->getNode('body')->getNode(0);
+ $nodes = $this->getNode('body')->getNode('0');
} else {
$nodes = $this->getNode('body');
}
@@ -391,14 +418,6 @@
continue;
}
- if ($node instanceof TextNode && ctype_space($node->getAttribute('data'))) {
- continue;
- }
-
- if ($node instanceof BlockReferenceNode) {
- continue;
- }
-
$traitable = false;
break;
}
@@ -409,9 +428,12 @@
}
$compiler
- ->write("public function isTraitable()\n", "{\n")
+ ->write("/**\n")
+ ->write(" * @codeCoverageIgnore\n")
+ ->write(" */\n")
+ ->write("public function isTraitable(): bool\n", "{\n")
->indent()
- ->write(sprintf("return %s;\n", $traitable ? 'true' : 'false'))
+ ->write("return false;\n")
->outdent()
->write("}\n\n")
;
@@ -420,9 +442,12 @@
protected function compileDebugInfo(Compiler $compiler)
{
$compiler
- ->write("public function getDebugInfo()\n", "{\n")
+ ->write("/**\n")
+ ->write(" * @codeCoverageIgnore\n")
+ ->write(" */\n")
+ ->write("public function getDebugInfo(): array\n", "{\n")
->indent()
- ->write(sprintf("return %s;\n", str_replace("\n", '', var_export(array_reverse($compiler->getDebugInfo(), true), true))))
+ ->write(\sprintf("return %s;\n", str_replace("\n", '', var_export(array_reverse($compiler->getDebugInfo(), true), true))))
->outdent()
->write("}\n\n")
;
@@ -431,7 +456,7 @@
protected function compileGetSourceContext(Compiler $compiler)
{
$compiler
- ->write("public function getSourceContext()\n", "{\n")
+ ->write("public function getSourceContext(): Source\n", "{\n")
->indent()
->write('return new Source(')
->string($compiler->getEnvironment()->isDebug() ? $this->getSourceContext()->getCode() : '')
@@ -449,7 +474,7 @@
{
if ($node instanceof ConstantExpression) {
$compiler
- ->write(sprintf('%s = $this->loadTemplate(', $var))
+ ->write(\sprintf('%s = $this->loadTemplate(', $var))
->subcompile($node)
->raw(', ')
->repr($node->getTemplateName())
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NameDeprecation.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NameDeprecation.php
new file mode 100644
index 0000000..63ab285
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/NameDeprecation.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\Node;
+
+/**
+ * Represents a deprecation for a named node or attribute on a Node.
+ *
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+class NameDeprecation
+{
+ private $package;
+ private $version;
+ private $newName;
+
+ public function __construct(string $package = '', string $version = '', string $newName = '')
+ {
+ $this->package = $package;
+ $this->version = $version;
+ $this->newName = $newName;
+ }
+
+ public function getPackage(): string
+ {
+ return $this->package;
+ }
+
+ public function getVersion(): string
+ {
+ return $this->version;
+ }
+
+ public function getNewName(): string
+ {
+ return $this->newName;
+ }
+}
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
index c0558b9..2ccbcf6 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Source;
@@ -20,61 +21,82 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class Node implements \Countable, \IteratorAggregate
{
+ /**
+ * @var array<string|int, Node>
+ */
protected $nodes;
protected $attributes;
protected $lineno;
protected $tag;
- private $name;
private $sourceContext;
+ /** @var array<string, NameDeprecation> */
+ private $nodeNameDeprecations = [];
+ /** @var array<string, NameDeprecation> */
+ private $attributeNameDeprecations = [];
/**
- * @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
+ * @param array<string|int, Node> $nodes An array of named nodes
+ * @param array $attributes An array of attributes (should not be nodes)
+ * @param int $lineno The line number
*/
- public function __construct(array $nodes = [], array $attributes = [], int $lineno = 0, string $tag = null)
+ public function __construct(array $nodes = [], array $attributes = [], int $lineno = 0)
{
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));
+ 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) ? $node::class : (null === $node ? 'null' : \gettype($node)), $name, static::class));
}
}
$this->nodes = $nodes;
$this->attributes = $attributes;
$this->lineno = $lineno;
- $this->tag = $tag;
+
+ if (\func_num_args() > 3) {
+ trigger_deprecation('twig/twig', '3.12', \sprintf('The "tag" constructor argument of the "%s" class is deprecated and ignored (check which TokenParser class set it to "%s"), the tag is now automatically set by the Parser when needed.', static::class, func_get_arg(3) ?: 'null'));
+ }
}
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;
+
+ if ($this->tag) {
+ $repr .= \sprintf("\n tag: %s", $this->tag);
}
- $repr = [static::class.'('.implode(', ', $attributes)];
+ $attributes = [];
+ foreach ($this->attributes as $name => $value) {
+ if (\is_callable($value)) {
+ $v = '\Closure';
+ } elseif ($value instanceof \Stringable) {
+ $v = (string) $value;
+ } else {
+ $v = str_replace("\n", '', var_export($value, true));
+ }
+ $attributes[] = \sprintf('%s: %s', $name, $v);
+ }
+
+ if ($attributes) {
+ $repr .= \sprintf("\n attributes:\n %s", implode("\n ", $attributes));
+ }
if (\count($this->nodes)) {
+ $repr .= "\n nodes:";
foreach ($this->nodes as $name => $node) {
- $len = \strlen($name) + 4;
+ $len = \strlen($name) + 6;
$noderepr = [];
foreach (explode("\n", (string) $node) as $line) {
$noderepr[] = str_repeat(' ', $len).$line;
}
- $repr[] = sprintf(' %s: %s', $name, ltrim(implode("\n", $noderepr)));
+ $repr .= \sprintf("\n %s: %s", $name, ltrim(implode("\n", $noderepr)));
}
-
- $repr[] = ')';
- } else {
- $repr[0] .= ')';
}
- return implode("\n", $repr);
+ return $repr;
}
/**
@@ -83,7 +105,7 @@
public function compile(Compiler $compiler)
{
foreach ($this->nodes as $node) {
- $node->compile($compiler);
+ $compiler->subcompile($node);
}
}
@@ -97,6 +119,18 @@
return $this->tag;
}
+ /**
+ * @internal
+ */
+ public function setNodeTag(string $tag): void
+ {
+ if ($this->tag) {
+ throw new \LogicException('The tag of a node can only be set once.');
+ }
+
+ $this->tag = $tag;
+ }
+
public function hasAttribute(string $name): bool
{
return \array_key_exists($name, $this->attributes);
@@ -105,7 +139,17 @@
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));
+ throw new \LogicException(\sprintf('Attribute "%s" does not exist for Node "%s".', $name, static::class));
+ }
+
+ $triggerDeprecation = \func_num_args() > 1 ? func_get_arg(1) : true;
+ if ($triggerDeprecation && isset($this->attributeNameDeprecations[$name])) {
+ $dep = $this->attributeNameDeprecations[$name];
+ if ($dep->getNewName()) {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Getting attribute "%s" on a "%s" class is deprecated, get the "%s" attribute instead.', $name, static::class, $dep->getNewName());
+ } else {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Getting attribute "%s" on a "%s" class is deprecated.', $name, static::class);
+ }
}
return $this->attributes[$name];
@@ -113,39 +157,97 @@
public function setAttribute(string $name, $value): void
{
+ $triggerDeprecation = \func_num_args() > 2 ? func_get_arg(2) : true;
+ if ($triggerDeprecation && isset($this->attributeNameDeprecations[$name])) {
+ $dep = $this->attributeNameDeprecations[$name];
+ if ($dep->getNewName()) {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Setting attribute "%s" on a "%s" class is deprecated, set the "%s" attribute instead.', $name, static::class, $dep->getNewName());
+ } else {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Setting attribute "%s" on a "%s" class is deprecated.', $name, static::class);
+ }
+ }
+
$this->attributes[$name] = $value;
}
+ public function deprecateAttribute(string $name, NameDeprecation $dep): void
+ {
+ $this->attributeNameDeprecations[$name] = $dep;
+ }
+
public function removeAttribute(string $name): void
{
unset($this->attributes[$name]);
}
+ /**
+ * @param string|int $name
+ */
public function hasNode(string $name): bool
{
return isset($this->nodes[$name]);
}
+ /**
+ * @param string|int $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));
+ throw new \LogicException(\sprintf('Node "%s" does not exist for Node "%s".', $name, static::class));
+ }
+
+ $triggerDeprecation = \func_num_args() > 1 ? func_get_arg(1) : true;
+ if ($triggerDeprecation && isset($this->nodeNameDeprecations[$name])) {
+ $dep = $this->nodeNameDeprecations[$name];
+ if ($dep->getNewName()) {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Getting node "%s" on a "%s" class is deprecated, get the "%s" node instead.', $name, static::class, $dep->getNewName());
+ } else {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Getting node "%s" on a "%s" class is deprecated.', $name, static::class);
+ }
}
return $this->nodes[$name];
}
+ /**
+ * @param string|int $name
+ */
public function setNode(string $name, self $node): void
{
+ $triggerDeprecation = \func_num_args() > 2 ? func_get_arg(2) : true;
+ if ($triggerDeprecation && isset($this->nodeNameDeprecations[$name])) {
+ $dep = $this->nodeNameDeprecations[$name];
+ if ($dep->getNewName()) {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Setting node "%s" on a "%s" class is deprecated, set the "%s" node instead.', $name, static::class, $dep->getNewName());
+ } else {
+ trigger_deprecation($dep->getPackage(), $dep->getVersion(), 'Setting node "%s" on a "%s" class is deprecated.', $name, static::class);
+ }
+ }
+
+ if (null !== $this->sourceContext) {
+ $node->setSourceContext($this->sourceContext);
+ }
$this->nodes[$name] = $node;
}
+ /**
+ * @param string|int $name
+ */
public function removeNode(string $name): void
{
unset($this->nodes[$name]);
}
/**
+ * @param string|int $name
+ */
+ public function deprecateNode(string $name, NameDeprecation $dep): void
+ {
+ $this->nodeNameDeprecations[$name] = $dep;
+ }
+
+ /**
* @return int
*/
#[\ReturnTypeWillChange]
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
index 60386d2..e3c23bb 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\AbstractExpression;
@@ -20,19 +21,23 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class PrintNode extends Node implements NodeOutputInterface
{
- public function __construct(AbstractExpression $expr, int $lineno, string $tag = null)
+ public function __construct(AbstractExpression $expr, int $lineno)
{
- parent::__construct(['expr' => $expr], [], $lineno, $tag);
+ parent::__construct(['expr' => $expr], [], $lineno);
}
public function compile(Compiler $compiler): void
{
+ /** @var AbstractExpression */
+ $expr = $this->getNode('expr');
+
$compiler
->addDebugInfo($this)
- ->write('echo ')
- ->subcompile($this->getNode('expr'))
+ ->write($expr->isGenerator() ? 'yield from ' : 'yield ')
+ ->subcompile($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
index 4d5666b..d51cea4 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -18,11 +19,12 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class SandboxNode extends Node
{
- public function __construct(Node $body, int $lineno, string $tag = null)
+ public function __construct(Node $body, int $lineno)
{
- parent::__construct(['body' => $body], [], $lineno, $tag);
+ parent::__construct(['body' => $body], [], $lineno);
}
public function compile(Compiler $compiler): void
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
index 96b6bd8..6772510 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Expression\ConstantExpression;
@@ -19,26 +20,28 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class SetNode extends Node implements NodeCaptureInterface
{
- public function __construct(bool $capture, Node $names, Node $values, int $lineno, string $tag = null)
+ public function __construct(bool $capture, Node $names, Node $values, int $lineno)
{
- 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');
+ $safe = false;
+ if ($capture) {
+ $safe = true;
if ($values instanceof TextNode) {
- $this->setNode('values', new ConstantExpression($values->getAttribute('data'), $values->getTemplateLine()));
- $this->setAttribute('capture', false);
+ $values = new ConstantExpression($values->getAttribute('data'), $values->getTemplateLine());
+ $capture = false;
+ } else {
+ $values = new CaptureNode($values, $values->getTemplateLine());
}
}
+
+ parent::__construct(['names' => $names, 'values' => $values], ['capture' => $capture, 'safe' => $safe], $lineno);
}
public function compile(Compiler $compiler): void
@@ -46,7 +49,7 @@
$compiler->addDebugInfo($this);
if (\count($this->getNode('names')) > 1) {
- $compiler->write('list(');
+ $compiler->write('[');
foreach ($this->getNode('names') as $idx => $node) {
if ($idx) {
$compiler->raw(', ');
@@ -54,29 +57,15 @@
$compiler->subcompile($node);
}
- $compiler->raw(')');
+ $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())");
- }
}
+ $compiler->raw(' = ');
- if (!$this->getAttribute('capture')) {
- $compiler->raw(' = ');
-
+ if ($this->getAttribute('capture')) {
+ $compiler->subcompile($this->getNode('values'));
+ } else {
if (\count($this->getNode('names')) > 1) {
$compiler->write('[');
foreach ($this->getNode('values') as $idx => $value) {
@@ -98,8 +87,10 @@
$compiler->subcompile($this->getNode('values'));
}
}
+
+ $compiler->raw(';');
}
- $compiler->raw(";\n");
+ $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
index d74ebe6..fae65fb 100644
--- 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
@@ -12,6 +12,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -19,6 +20,7 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class TextNode extends Node implements NodeOutputInterface
{
public function __construct(string $data, int $lineno)
@@ -28,9 +30,10 @@
public function compile(Compiler $compiler): void
{
+ $compiler->addDebugInfo($this);
+
$compiler
- ->addDebugInfo($this)
- ->write('echo ')
+ ->write('yield ')
->string($this->getAttribute('data'))
->raw(";\n")
;
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/TypesNode.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/TypesNode.php
new file mode 100644
index 0000000..ebb304d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Node/TypesNode.php
@@ -0,0 +1,28 @@
+<?php
+
+namespace Twig\Node;
+
+use Twig\Attribute\YieldReady;
+use Twig\Compiler;
+
+/**
+ * Represents a types node.
+ *
+ * @author Jeroen Versteeg <jeroen@alisqi.com>
+ */
+#[YieldReady]
+class TypesNode extends Node
+{
+ /**
+ * @param array<string, array{type: string, optional: bool}> $types
+ */
+ public function __construct(array $types, int $lineno)
+ {
+ parent::__construct([], ['mapping' => $types], $lineno);
+ }
+
+ public function compile(Compiler $compiler)
+ {
+ // Don't compile anything.
+ }
+}
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
index 56a3344..487e280 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
/**
@@ -18,16 +19,17 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class WithNode extends Node
{
- public function __construct(Node $body, ?Node $variables, bool $only, int $lineno, string $tag = null)
+ public function __construct(Node $body, ?Node $variables, bool $only, int $lineno)
{
$nodes = ['body' => $body];
if (null !== $variables) {
$nodes['variables'] = $variables;
}
- parent::__construct($nodes, ['only' => $only], $lineno, $tag);
+ parent::__construct($nodes, ['only' => $only], $lineno);
}
public function compile(Compiler $compiler): void
@@ -36,35 +38,35 @@
$parentContextName = $compiler->getVarName();
- $compiler->write(sprintf("\$%s = \$context;\n", $parentContextName));
+ $compiler->write(\sprintf("\$%s = \$context;\n", $parentContextName));
if ($this->hasNode('variables')) {
$node = $this->getNode('variables');
$varsName = $compiler->getVarName();
$compiler
- ->write(sprintf('$%s = ', $varsName))
+ ->write(\sprintf('$%s = ', $varsName))
->subcompile($node)
->raw(";\n")
- ->write(sprintf("if (!twig_test_iterable(\$%s)) {\n", $varsName))
+ ->write(\sprintf("if (!is_iterable(\$%s)) {\n", $varsName))
->indent()
- ->write("throw new RuntimeError('Variables passed to the \"with\" tag must be a hash.', ")
+ ->write("throw new RuntimeError('Variables passed to the \"with\" tag must be a mapping.', ")
->repr($node->getTemplateLine())
->raw(", \$this->getSourceContext());\n")
->outdent()
->write("}\n")
- ->write(sprintf("\$%s = twig_to_array(\$%s);\n", $varsName, $varsName))
+ ->write(\sprintf("\$%s = CoreExtension::toArray(\$%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->write(\sprintf("\$context = \$%s + \$context + \$this->env->getGlobals();\n", $varsName));
}
$compiler
->subcompile($this->getNode('body'))
- ->write(sprintf("\$context = \$%s;\n", $parentContextName))
+ ->write(\sprintf("\$context = \$%s;\n", $parentContextName))
;
}
}
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
index d7036ae..5de35fd 100644
--- 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
@@ -17,9 +17,9 @@
/**
* 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>
+ *
+ * @deprecated since 3.9 (to be removed in 4.0)
*/
abstract class AbstractNodeVisitor implements NodeVisitorInterface
{
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
index fe56ea3..32f49ab 100644
--- 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
@@ -57,7 +57,7 @@
} 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);
+ $this->statusStack[] = $this->blocks[$node->getAttribute('name')] ?? $this->needEscaping();
} elseif ($node instanceof ImportNode) {
$this->safeVars[] = $node->getNode('var')->getAttribute('name');
}
@@ -73,7 +73,7 @@
$this->blocks = [];
} elseif ($node instanceof FilterExpression) {
return $this->preEscapeFilterNode($node, $env);
- } elseif ($node instanceof PrintNode && false !== $type = $this->needEscaping($env)) {
+ } elseif ($node instanceof PrintNode && false !== $type = $this->needEscaping()) {
$expression = $node->getNode('expr');
if ($expression instanceof ConditionalExpression && $this->shouldUnwrapConditional($expression, $env, $type)) {
return new DoNode($this->unwrapConditional($expression, $env, $type), $expression->getTemplateLine());
@@ -85,7 +85,7 @@
if ($node instanceof AutoEscapeNode || $node instanceof BlockNode) {
array_pop($this->statusStack);
} elseif ($node instanceof BlockReferenceNode) {
- $this->blocks[$node->getAttribute('name')] = $this->needEscaping($env);
+ $this->blocks[$node->getAttribute('name')] = $this->needEscaping();
}
return $node;
@@ -126,15 +126,11 @@
return $node;
}
- return new InlinePrint($this->getEscaperFilter($type, $expression), $node->getTemplateLine());
+ return new InlinePrint($this->getEscaperFilter($env, $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)) {
@@ -143,14 +139,19 @@
$class = \get_class($node);
- return new $class($this->getEscaperFilter($type, $expression), $node->getTemplateLine());
+ return new $class($this->getEscaperFilter($env, $type, $expression), $node->getTemplateLine());
}
private function preEscapeFilterNode(FilterExpression $filter, Environment $env): FilterExpression
{
- $name = $filter->getNode('filter')->getAttribute('value');
+ if ($filter->hasAttribute('twig_callable')) {
+ $type = $filter->getAttribute('twig_callable')->getPreEscape();
+ } else {
+ // legacy
+ $name = $filter->getNode('filter', false)->getAttribute('value');
+ $type = $env->getFilter($name)->getPreEscape();
+ }
- $type = $env->getFilter($name)->getPreEscape();
if (null === $type) {
return $filter;
}
@@ -160,7 +161,7 @@
return $filter;
}
- $filter->setNode('node', $this->getEscaperFilter($type, $node));
+ $filter->setNode('node', $this->getEscaperFilter($env, $type, $node));
return $filter;
}
@@ -183,22 +184,22 @@
return \in_array($type, $safe) || \in_array('all', $safe);
}
- private function needEscaping(Environment $env)
+ private function needEscaping()
{
if (\count($this->statusStack)) {
return $this->statusStack[\count($this->statusStack) - 1];
}
- return $this->defaultStrategy ? $this->defaultStrategy : false;
+ return $this->defaultStrategy ?: false;
}
- private function getEscaperFilter(string $type, Node $node): FilterExpression
+ private function getEscaperFilter(Environment $env, string $type, Node $node): FilterExpression
{
$line = $node->getTemplateLine();
- $name = new ConstantExpression('escape', $line);
+ $filter = $env->getFilter('escape');
$args = new Node([new ConstantExpression($type, $line), new ConstantExpression(null, $line), new ConstantExpression(true, $line)]);
- return new FilterExpression($node, $name, $args, $line);
+ return new FilterExpression($node, $filter, $args, $line);
}
public function getPriority(): int
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
index af477e6..01d5a99 100644
--- 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
@@ -46,14 +46,14 @@
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));
+ $node->getNode('constructor_end')->setNode('_auto_macro_import', new ImportNode(new NameExpression('_self', 0), new AssignNameExpression('_self', 0), 0, true));
}
} elseif ($this->inAModule) {
if (
- $node instanceof GetAttrExpression &&
- $node->getNode('node') instanceof NameExpression &&
- '_self' === $node->getNode('node')->getAttribute('name') &&
- $node->getNode('attribute') instanceof ConstantExpression
+ $node instanceof GetAttrExpression
+ && $node->getNode('node') instanceof NameExpression
+ && '_self' === $node->getNode('node')->getAttribute('name')
+ && $node->getNode('attribute') instanceof ConstantExpression
) {
$this->hasMacroCalls = true;
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
index 7ac75e4..a943f45 100644
--- 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
@@ -15,7 +15,6 @@
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;
@@ -24,6 +23,7 @@
use Twig\Node\IncludeNode;
use Twig\Node\Node;
use Twig\Node\PrintNode;
+use Twig\Node\TextNode;
/**
* Tries to optimize the AST.
@@ -43,27 +43,34 @@
public const OPTIMIZE_NONE = 0;
public const OPTIMIZE_FOR = 2;
public const OPTIMIZE_RAW_FILTER = 4;
+ public const OPTIMIZE_TEXT_NODES = 8;
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));
+ public function __construct(
+ private int $optimizers = -1,
+ ) {
+ if ($optimizers > (self::OPTIMIZE_FOR | self::OPTIMIZE_RAW_FILTER | self::OPTIMIZE_TEXT_NODES)) {
+ throw new \InvalidArgumentException(\sprintf('Optimizer mode "%s" is not valid.', $optimizers));
}
- $this->optimizers = $optimizers;
+ if (-1 !== $optimizers && self::OPTIMIZE_RAW_FILTER === (self::OPTIMIZE_RAW_FILTER & $optimizers)) {
+ trigger_deprecation('twig/twig', '3.11', 'The "Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_RAW_FILTER" option is deprecated and does nothing.');
+ }
+
+ if (-1 !== $optimizers && self::OPTIMIZE_TEXT_NODES === (self::OPTIMIZE_TEXT_NODES & $optimizers)) {
+ trigger_deprecation('twig/twig', '3.12', 'The "Twig\NodeVisitor\OptimizerNodeVisitor::OPTIMIZE_TEXT_NODES" option is deprecated and does nothing.');
+ }
}
public function enterNode(Node $node, Environment $env): Node
{
if (self::OPTIMIZE_FOR === (self::OPTIMIZE_FOR & $this->optimizers)) {
- $this->enterOptimizeFor($node, $env);
+ $this->enterOptimizeFor($node);
}
return $node;
@@ -72,14 +79,10 @@
public function leaveNode(Node $node, Environment $env): ?Node
{
if (self::OPTIMIZE_FOR === (self::OPTIMIZE_FOR & $this->optimizers)) {
- $this->leaveOptimizeFor($node, $env);
+ $this->leaveOptimizeFor($node);
}
- if (self::OPTIMIZE_RAW_FILTER === (self::OPTIMIZE_RAW_FILTER & $this->optimizers)) {
- $node = $this->optimizeRawFilter($node, $env);
- }
-
- $node = $this->optimizePrintNode($node, $env);
+ $node = $this->optimizePrintNode($node);
return $node;
}
@@ -91,16 +94,21 @@
*
* * "echo $this->render(Parent)Block()" with "$this->display(Parent)Block()"
*/
- private function optimizePrintNode(Node $node, Environment $env): Node
+ private function optimizePrintNode(Node $node): Node
{
if (!$node instanceof PrintNode) {
return $node;
}
$exprNode = $node->getNode('expr');
+
+ if ($exprNode instanceof ConstantExpression && \is_string($exprNode->getAttribute('value'))) {
+ return new TextNode($exprNode->getAttribute('value'), $exprNode->getTemplateLine());
+ }
+
if (
- $exprNode instanceof BlockReferenceExpression ||
- $exprNode instanceof ParentExpression
+ $exprNode instanceof BlockReferenceExpression
+ || $exprNode instanceof ParentExpression
) {
$exprNode->setAttribute('output', true);
@@ -111,21 +119,9 @@
}
/**
- * 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
+ private function enterOptimizeFor(Node $node): void
{
if ($node instanceof ForNode) {
// disable the loop variable by default
@@ -166,7 +162,7 @@
&& 'include' === $node->getAttribute('name')
&& (!$node->getNode('arguments')->hasNode('with_context')
|| false !== $node->getNode('arguments')->getNode('with_context')->getAttribute('value')
- )
+ )
) {
$this->addLoopToAll();
}
@@ -175,12 +171,12 @@
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')
- )
- )
+ || ($node->getNode('node') instanceof NameExpression
+ && 'loop' === $node->getNode('node')->getAttribute('name')
+ )
+ )
) {
$this->addLoopToAll();
}
@@ -189,7 +185,7 @@
/**
* Optimizes "for" tag by removing the "loop" variable creation whenever possible.
*/
- private function leaveOptimizeFor(Node $node, Environment $env): void
+ private function leaveOptimizeFor(Node $node): void
{
if ($node instanceof ForNode) {
array_shift($this->loops);
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
index 90d6f2e..0767216 100644
--- 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
@@ -96,10 +96,15 @@
$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 ($node->hasAttribute('twig_callable')) {
+ $filter = $node->getAttribute('twig_callable');
+ } else {
+ // legacy
+ $filter = $env->getFilter($node->getAttribute('name'));
+ }
+
+ if ($filter) {
+ $safe = $filter->getSafe($node->getNode('arguments'));
if (null === $safe) {
$safe = $this->intersectSafe($this->getSafe($node->getNode('node')), $filter->getPreservesSafety());
}
@@ -109,10 +114,15 @@
}
} 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));
+ if ($node->hasAttribute('twig_callable')) {
+ $function = $node->getAttribute('twig_callable');
+ } else {
+ // legacy
+ $function = $env->getFunction($node->getAttribute('name'));
+ }
+
+ if ($function) {
+ $this->setSafe($node, $function->getSafe($node->getNode('arguments')));
} else {
$this->setSafe($node, []);
}
@@ -136,7 +146,7 @@
return $node;
}
- private function intersectSafe(array $a = null, array $b = null): array
+ private function intersectSafe(?array $a = null, ?array $b = null): array
{
if (null === $a || null === $b) {
return [];
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
index 1446cee..37e184a 100644
--- 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
@@ -34,8 +34,11 @@
final class SandboxNodeVisitor implements NodeVisitorInterface
{
private $inAModule = false;
+ /** @var array<string, int> */
private $tags;
+ /** @var array<string, int> */
private $filters;
+ /** @var array<string, int> */
private $functions;
private $needsToStringWrap = false;
@@ -51,22 +54,22 @@
} elseif ($this->inAModule) {
// look for tags
if ($node->getNodeTag() && !isset($this->tags[$node->getNodeTag()])) {
- $this->tags[$node->getNodeTag()] = $node;
+ $this->tags[$node->getNodeTag()] = $node->getTemplateLine();
}
// look for filters
- if ($node instanceof FilterExpression && !isset($this->filters[$node->getNode('filter')->getAttribute('value')])) {
- $this->filters[$node->getNode('filter')->getAttribute('value')] = $node;
+ if ($node instanceof FilterExpression && !isset($this->filters[$node->getAttribute('name')])) {
+ $this->filters[$node->getAttribute('name')] = $node->getTemplateLine();
}
// look for functions
if ($node instanceof FunctionExpression && !isset($this->functions[$node->getAttribute('name')])) {
- $this->functions[$node->getAttribute('name')] = $node;
+ $this->functions[$node->getAttribute('name')] = $node->getTemplateLine();
}
// the .. operator is equivalent to the range() function
if ($node instanceof RangeBinary && !isset($this->functions['range'])) {
- $this->functions['range'] = $node;
+ $this->functions['range'] = $node->getTemplateLine();
}
if ($node instanceof PrintNode) {
@@ -116,7 +119,7 @@
private function wrapNode(Node $node, string $name): void
{
$expr = $node->getNode($name);
- if ($expr instanceof NameExpression || $expr instanceof GetAttrExpression) {
+ if (($expr instanceof NameExpression || $expr instanceof GetAttrExpression) && !$expr->isGenerator()) {
$node->setNode($name, new CheckToStringNode($expr));
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/YieldNotReadyNodeVisitor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/YieldNotReadyNodeVisitor.php
new file mode 100644
index 0000000..4b190b4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/NodeVisitor/YieldNotReadyNodeVisitor.php
@@ -0,0 +1,59 @@
+<?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\Attribute\YieldReady;
+use Twig\Environment;
+use Twig\Node\Expression\AbstractExpression;
+use Twig\Node\Node;
+
+/**
+ * @internal to be removed in Twig 4
+ */
+final class YieldNotReadyNodeVisitor implements NodeVisitorInterface
+{
+ private $yieldReadyNodes = [];
+
+ public function __construct(
+ private bool $useYield,
+ ) {
+ }
+
+ public function enterNode(Node $node, Environment $env): Node
+ {
+ $class = \get_class($node);
+
+ if ($node instanceof AbstractExpression || isset($this->yieldReadyNodes[$class])) {
+ return $node;
+ }
+
+ if (!$this->yieldReadyNodes[$class] = (bool) (new \ReflectionClass($class))->getAttributes(YieldReady::class)) {
+ if ($this->useYield) {
+ throw new \LogicException(\sprintf('You cannot enable the "use_yield" option of Twig as node "%s" is not marked as ready for it; please make it ready and then flag it with the #[YieldReady] attribute.', $class));
+ }
+
+ trigger_deprecation('twig/twig', '3.9', 'Twig node "%s" is not marked as ready for using "yield" instead of "echo"; please make it ready and then flag it with the #[YieldReady] attribute.', $class);
+ }
+
+ return $node;
+ }
+
+ public function leaveNode(Node $node, Environment $env): ?Node
+ {
+ return $node;
+ }
+
+ public function getPriority(): int
+ {
+ return 255;
+ }
+}
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
index 4428208..40370bb 100644
--- 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
@@ -25,6 +25,7 @@
use Twig\Node\PrintNode;
use Twig\Node\TextNode;
use Twig\TokenParser\TokenParserInterface;
+use Twig\Util\ReflectionCallable;
/**
* @author Fabien Potencier <fabien@symfony.com>
@@ -39,20 +40,19 @@
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 __construct(
+ private Environment $env,
+ ) {
}
public function getVarName(): string
{
- return sprintf('__internal_parse_%d', $this->varNameSalt++);
+ return \sprintf('__internal_parse_%d', $this->varNameSalt++);
}
public function parse(TokenStream $stream, $test = null, bool $dropNeedle = false): ModuleNode
@@ -91,7 +91,7 @@
}
if (!$e->getTemplateLine()) {
- $e->setTemplateLine($this->stream->getCurrent()->getLine());
+ $e->setTemplateLine($this->getCurrentToken()->getLine());
}
throw $e;
@@ -101,6 +101,9 @@
$traverser = new NodeTraverser($this->env, $this->visitors);
+ /**
+ * @var ModuleNode $node
+ */
$node = $traverser->traverse($node);
// restore previous stack so previous parse() call can resume working
@@ -117,23 +120,23 @@
$rv = [];
while (!$this->stream->isEOF()) {
switch ($this->getCurrentToken()->getType()) {
- case /* Token::TEXT_TYPE */ 0:
+ case Token::TEXT_TYPE:
$token = $this->stream->next();
$rv[] = new TextNode($token->getValue(), $token->getLine());
break;
- case /* Token::VAR_START_TYPE */ 2:
+ case Token::VAR_START_TYPE:
$token = $this->stream->next();
$expr = $this->expressionParser->parseExpression();
- $this->stream->expect(/* Token::VAR_END_TYPE */ 4);
+ $this->stream->expect(Token::VAR_END_TYPE);
$rv[] = new PrintNode($expr, $token->getLine());
break;
- case /* Token::BLOCK_START_TYPE */ 1:
+ case Token::BLOCK_START_TYPE:
$this->stream->next();
$token = $this->getCurrentToken();
- if (/* Token::NAME_TYPE */ 5 !== $token->getType()) {
+ if (Token::NAME_TYPE !== $token->getType()) {
throw new SyntaxError('A block must start with a tag name.', $token->getLine(), $this->stream->getSourceContext());
}
@@ -151,13 +154,14 @@
if (!$subparser = $this->env->getTokenParser($token->getValue())) {
if (null !== $test) {
- $e = new SyntaxError(sprintf('Unexpected "%s" tag', $token->getValue()), $token->getLine(), $this->stream->getSourceContext());
+ $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));
+ $callable = (new ReflectionCallable(new TwigTest('decision', $test)))->getCallable();
+ if (\is_array($callable) && $callable[0] instanceof TokenParserInterface) {
+ $e->appendMessage(\sprintf(' (expecting closing tag for the "%s" tag defined near line %s).', $callable[0]->getTag(), $lineno));
}
} else {
- $e = new SyntaxError(sprintf('Unknown "%s" tag.', $token->getValue()), $token->getLine(), $this->stream->getSourceContext());
+ $e = new SyntaxError(\sprintf('Unknown "%s" tag.', $token->getValue()), $token->getLine(), $this->stream->getSourceContext());
$e->addSuggestions($token->getValue(), array_keys($this->env->getTokenParsers()));
}
@@ -168,13 +172,16 @@
$subparser->setParser($this);
$node = $subparser->parse($token);
- if (null !== $node) {
+ if (!$node) {
+ trigger_deprecation('twig/twig', '3.12', 'Returning "null" from "%s" is deprecated and forbidden by "TokenParserInterface".', $subparser::class);
+ } else {
+ $node->setNodeTag($subparser->getTag());
$rv[] = $node;
}
break;
default:
- throw new SyntaxError('Lexer or parser ended up in unsupported state.', $this->getCurrentToken()->getLine(), $this->stream->getSourceContext());
+ throw new SyntaxError('The lexer or the parser ended up in an unsupported state.', $this->getCurrentToken()->getLine(), $this->stream->getSourceContext());
}
}
@@ -187,6 +194,8 @@
public function getBlockStack(): array
{
+ trigger_deprecation('twig/twig', '3.12', 'Method "%s()" is deprecated.', __METHOD__);
+
return $this->blockStack;
}
@@ -207,21 +216,31 @@
public function hasBlock(string $name): bool
{
+ trigger_deprecation('twig/twig', '3.12', 'Method "%s()" is deprecated.', __METHOD__);
+
return isset($this->blocks[$name]);
}
public function getBlock(string $name): Node
{
+ trigger_deprecation('twig/twig', '3.12', 'Method "%s()" is deprecated.', __METHOD__);
+
return $this->blocks[$name];
}
public function setBlock(string $name, BlockNode $value): void
{
+ if (isset($this->blocks[$name])) {
+ throw new SyntaxError(\sprintf("The block '%s' has already been defined line %d.", $name, $this->blocks[$name]->getTemplateLine()), $this->getCurrentToken()->getLine(), $this->blocks[$name]->getSourceContext());
+ }
+
$this->blocks[$name] = new BodyNode([$value], [], $value->getTemplateLine());
}
public function hasMacro(string $name): bool
{
+ trigger_deprecation('twig/twig', '3.12', 'Method "%s()" is deprecated.', __METHOD__);
+
return isset($this->macros[$name]);
}
@@ -237,6 +256,8 @@
public function hasTraits(): bool
{
+ trigger_deprecation('twig/twig', '3.12', 'Method "%s()" is deprecated.', __METHOD__);
+
return \count($this->traits) > 0;
}
@@ -247,7 +268,7 @@
$this->embeddedTemplates[] = $template;
}
- public function addImportedSymbol(string $type, string $alias, string $name = null, AbstractExpression $node = null): void
+ public function addImportedSymbol(string $type, string $alias, ?string $name = null, ?AbstractExpression $node = null): void
{
$this->importedSymbols[0][$type][$alias] = ['name' => $name, 'node' => $node];
}
@@ -280,11 +301,26 @@
public function getParent(): ?Node
{
+ trigger_deprecation('twig/twig', '3.12', 'Method "%s()" is deprecated.', __METHOD__);
+
return $this->parent;
}
+ public function hasInheritance()
+ {
+ return $this->parent || 0 < \count($this->traits);
+ }
+
public function setParent(?Node $parent): void
{
+ if (null === $parent) {
+ trigger_deprecation('twig/twig', '3.12', 'Passing "null" to "%s()" is deprecated.', __METHOD__);
+ }
+
+ if (null !== $this->parent) {
+ throw new SyntaxError('Multiple extends tags are forbidden.', $parent->getTemplateLine(), $parent->getSourceContext());
+ }
+
$this->parent = $parent;
}
@@ -303,10 +339,9 @@
// 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)
+ || (!$node instanceof TextNode && !$node instanceof BlockReferenceNode && $node instanceof NodeOutputInterface)
) {
- if (false !== strpos((string) $node, \chr(0xEF).\chr(0xBB).\chr(0xBF))) {
+ if (str_contains((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
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
index 4da43e4..267718c 100644
--- 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
@@ -50,7 +50,7 @@
if ($profile->getDuration() * 1000 < 1) {
$str = $start."\n";
} else {
- $str = sprintf("%s %s\n", $start, $this->formatTime($profile, $percent));
+ $str = \sprintf("%s %s\n", $start, $this->formatTime($profile, $percent));
}
$nCount = \count($profile->getProfiles());
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
index 03abe0f..bb3fbb5 100644
--- 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
@@ -24,7 +24,7 @@
$this->dumpProfile('main()', $profile, $data);
$this->dumpChildren('main()', $profile, $data);
- $start = sprintf('%f', microtime(true));
+ $start = \sprintf('%f', microtime(true));
$str = <<<EOF
file-format: BlackfireProbe
cost-dimensions: wt mu pmu
@@ -46,9 +46,9 @@
if ($p->isTemplate()) {
$name = $p->getTemplate();
} else {
- $name = sprintf('%s::%s(%s)', $p->getTemplate(), $p->getType(), $p->getName());
+ $name = \sprintf('%s::%s(%s)', $p->getTemplate(), $p->getType(), $p->getName());
}
- $this->dumpProfile(sprintf('%s==>%s', $parent, $name), $p, $data);
+ $this->dumpProfile(\sprintf('%s==>%s', $parent, $name), $p, $data);
$this->dumpChildren($name, $p, $data);
}
}
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
index 1f2433b..cdab2de 100644
--- 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
@@ -32,16 +32,16 @@
protected function formatTemplate(Profile $profile, $prefix): string
{
- return sprintf('%s└ <span style="background-color: %s">%s</span>', $prefix, self::$colors['template'], $profile->getTemplate());
+ 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());
+ return \sprintf('%s└ %s::%s(<span style="background-color: %s">%s</span>)', $prefix, $profile->getTemplate(), $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);
+ 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
index 31561c4..1c1f77e 100644
--- 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
@@ -20,16 +20,16 @@
{
protected function formatTemplate(Profile $profile, $prefix): string
{
- return sprintf('%s└ %s', $prefix, $profile->getTemplate());
+ 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());
+ 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);
+ 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
index 1494baf..4d8e504 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Profiler\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Node;
@@ -19,6 +20,7 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class EnterProfileNode extends Node
{
public function __construct(string $extensionName, string $type, string $name, string $varName)
@@ -29,10 +31,10 @@
public function compile(Compiler $compiler): void
{
$compiler
- ->write(sprintf('$%s = $this->extensions[', $this->getAttribute('var_name')))
+ ->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'))
+ ->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'))
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
index 94cebba..bd9227e 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\Profiler\Node;
+use Twig\Attribute\YieldReady;
use Twig\Compiler;
use Twig\Node\Node;
@@ -19,6 +20,7 @@
*
* @author Fabien Potencier <fabien@symfony.com>
*/
+#[YieldReady]
class LeaveProfileNode extends Node
{
public function __construct(string $varName)
@@ -30,7 +32,7 @@
{
$compiler
->write("\n")
- ->write(sprintf("\$%s->leave(\$%s);\n\n", $this->getAttribute('var_name'), $this->getAttribute('var_name').'_prof'))
+ ->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
index 91abee8..1458bc5 100644
--- 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
@@ -27,13 +27,12 @@
*/
final class ProfilerNodeVisitor implements NodeVisitorInterface
{
- private $extensionName;
private $varName;
- public function __construct(string $extensionName)
- {
- $this->extensionName = $extensionName;
- $this->varName = sprintf('__internal_%s', hash(\PHP_VERSION_ID < 80100 ? 'sha256' : 'xxh128', $extensionName));
+ public function __construct(
+ private string $extensionName,
+ ) {
+ $this->varName = \sprintf('__internal_%s', hash(\PHP_VERSION_ID < 80100 ? 'sha256' : 'xxh128', $extensionName));
}
public function enterNode(Node $node, Environment $env): Node
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
index 252ca9b..2928e16 100644
--- 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
@@ -20,19 +20,16 @@
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;
+ public function __construct(
+ private string $template = 'main',
+ private string $type = self::ROOT,
+ private string $name = 'main',
+ ) {
+ $this->name = str_starts_with($name, '__internal_') ? 'INTERNAL' : $name;
$this->enter();
}
@@ -176,6 +173,6 @@
*/
public function __unserialize(array $data): void
{
- list($this->template, $this->name, $this->type, $this->starts, $this->ends, $this->profiles) = $data;
+ [$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/Resources/core.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/core.php
new file mode 100644
index 0000000..6e2fcfb
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/core.php
@@ -0,0 +1,541 @@
+<?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.
+ */
+
+use Twig\Environment;
+use Twig\Extension\CoreExtension;
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_cycle($values, $position)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::cycle($values, $position);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_random(Environment $env, $values = null, $max = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::random($env->getCharset(), $values, $max);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_date_format_filter(Environment $env, $date, $format = null, $timezone = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return $env->getExtension(CoreExtension::class)->formatDate($date, $format, $timezone);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_date_modify_filter(Environment $env, $date, $modifier)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return $env->getExtension(CoreExtension::class)->modifyDate($date, $modifier);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_sprintf($format, ...$values)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::sprintf($format, ...$values);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_date_converter(Environment $env, $date = null, $timezone = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return $env->getExtension(CoreExtension::class)->convertDate($date, $timezone);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_replace_filter($str, $from)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::replace($str, $from);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_round($value, $precision = 0, $method = 'common')
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::round($value, $precision, $method);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_number_format_filter(Environment $env, $number, $decimal = null, $decimalPoint = null, $thousandSep = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return $env->getExtension(CoreExtension::class)->formatNumber($number, $decimal, $decimalPoint, $thousandSep);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_urlencode_filter($url)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::urlencode($url);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_merge(...$arrays)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::merge(...$arrays);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_slice(Environment $env, $item, $start, $length = null, $preserveKeys = false)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::slice($env->getCharset(), $item, $start, $length, $preserveKeys);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_first(Environment $env, $item)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::first($env->getCharset(), $item);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_last(Environment $env, $item)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::last($env->getCharset(), $item);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_join_filter($value, $glue = '', $and = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::join($value, $glue, $and);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_split_filter(Environment $env, $value, $delimiter, $limit = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::split($env->getCharset(), $value, $delimiter, $limit);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_get_array_keys_filter($array)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::keys($array);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_reverse_filter(Environment $env, $item, $preserveKeys = false)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::reverse($env->getCharset(), $item, $preserveKeys);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_sort_filter(Environment $env, $array, $arrow = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::sort($env, $array, $arrow);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_matches(string $regexp, ?string $str)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::matches($regexp, $str);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_trim_filter($string, $characterMask = null, $side = 'both')
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::trim($string, $characterMask, $side);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_nl2br($string)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::nl2br($string);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_spaceless($content)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::spaceless($content);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_convert_encoding($string, $to, $from)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::convertEncoding($string, $to, $from);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_length_filter(Environment $env, $thing)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::length($env->getCharset(), $thing);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_upper_filter(Environment $env, $string)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::upper($env->getCharset(), $string);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_lower_filter(Environment $env, $string)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::lower($env->getCharset(), $string);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_striptags($string, $allowable_tags = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::striptags($string, $allowable_tags);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_title_string_filter(Environment $env, $string)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::titleCase($env->getCharset(), $string);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_capitalize_string_filter(Environment $env, $string)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::capitalize($env->getCharset(), $string);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_test_empty($value)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::testEmpty($value);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_test_iterable($value)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return is_iterable($value);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_include(Environment $env, $context, $template, $variables = [], $withContext = true, $ignoreMissing = false, $sandboxed = false)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::include($env, $context, $template, $variables, $withContext, $ignoreMissing, $sandboxed);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_source(Environment $env, $name, $ignoreMissing = false)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::source($env, $name, $ignoreMissing);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_constant($constant, $object = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::constant($constant, $object);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_constant_is_defined($constant, $object = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::constant($constant, $object, true);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_batch($items, $size, $fill = null, $preserveKeys = true)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::batch($items, $size, $fill, $preserveKeys);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_column($array, $name, $index = null): array
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::column($array, $name, $index);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_filter(Environment $env, $array, $arrow)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::filter($env, $array, $arrow);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_map(Environment $env, $array, $arrow)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::map($env, $array, $arrow);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_reduce(Environment $env, $array, $arrow, $initial = null)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::reduce($env, $array, $arrow, $initial);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_some(Environment $env, $array, $arrow)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::arraySome($env, $array, $arrow);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_array_every(Environment $env, $array, $arrow)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::arrayEvery($env, $array, $arrow);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_check_arrow_in_sandbox(Environment $env, $arrow, $thing, $type)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return CoreExtension::checkArrowInSandbox($env, $arrow, $thing, $type);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/debug.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/debug.php
new file mode 100644
index 0000000..104b4f4
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/debug.php
@@ -0,0 +1,25 @@
+<?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 Twig\Environment;
+use Twig\Extension\DebugExtension;
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_var_dump(Environment $env, $context, ...$vars)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ DebugExtension::dump($env, $context, ...$vars);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/escaper.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/escaper.php
new file mode 100644
index 0000000..a2ee8e7
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/escaper.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.
+ */
+
+use Twig\Environment;
+use Twig\Extension\EscaperExtension;
+use Twig\Node\Node;
+use Twig\Runtime\EscaperRuntime;
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_raw_filter($string)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return $string;
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_escape_filter(Environment $env, $string, $strategy = 'html', $charset = null, $autoescape = false)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return $env->getRuntime(EscaperRuntime::class)->escape($string, $strategy, $charset, $autoescape);
+}
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_escape_filter_is_safe(Node $filterArgs)
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return EscaperExtension::escapeFilterIsSafe($filterArgs);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/string_loader.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/string_loader.php
new file mode 100644
index 0000000..8f0e649
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Resources/string_loader.php
@@ -0,0 +1,26 @@
+<?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 Twig\Environment;
+use Twig\Extension\StringLoaderExtension;
+use Twig\TemplateWrapper;
+
+/**
+ * @internal
+ *
+ * @deprecated since Twig 3.9
+ */
+function twig_template_from_string(Environment $env, $template, ?string $name = null): TemplateWrapper
+{
+ trigger_deprecation('twig/twig', '3.9', 'Using the internal "%s" function is deprecated.', __FUNCTION__);
+
+ return StringLoaderExtension::templateFromString($env, $template, $name);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Runtime/EscaperRuntime.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Runtime/EscaperRuntime.php
new file mode 100644
index 0000000..a3ce171
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Runtime/EscaperRuntime.php
@@ -0,0 +1,327 @@
+<?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\Runtime;
+
+use Twig\Error\RuntimeError;
+use Twig\Extension\RuntimeExtensionInterface;
+use Twig\Markup;
+
+final class EscaperRuntime implements RuntimeExtensionInterface
+{
+ /** @var array<string, callable(string $string, string $charset): string> */
+ private $escapers = [];
+
+ /** @internal */
+ public $safeClasses = [];
+
+ /** @internal */
+ public $safeLookup = [];
+
+ public function __construct(
+ private $charset = 'UTF-8',
+ ) {
+ }
+
+ /**
+ * 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(string $string, string $charset): string $callable A valid PHP callable
+ */
+ public function setEscaper($strategy, callable $callable)
+ {
+ $this->escapers[$strategy] = $callable;
+ }
+
+ /**
+ * Gets all defined escapers.
+ *
+ * @return array<string, callable(string $string, string $charset): string> 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;
+ }
+ }
+
+ /**
+ * Escapes a string.
+ *
+ * @param mixed $string The value to be escaped
+ * @param string $strategy The escaping strategy
+ * @param string|null $charset The charset
+ * @param bool $autoescape Whether the function is called by the auto-escaping feature (true) or by the developer (false)
+ *
+ * @throws RuntimeError
+ */
+ public function escape($string, string $strategy = 'html', ?string $charset = null, bool $autoescape = false)
+ {
+ if ($autoescape && $string instanceof Markup) {
+ return $string;
+ }
+
+ if (!\is_string($string)) {
+ if ($string instanceof \Stringable) {
+ if ($autoescape) {
+ $c = \get_class($string);
+ if (!isset($this->safeClasses[$c])) {
+ $this->safeClasses[$c] = [];
+ foreach (class_parents($string) + class_implements($string) as $class) {
+ if (isset($this->safeClasses[$class])) {
+ $this->safeClasses[$c] = array_unique(array_merge($this->safeClasses[$c], $this->safeClasses[$class]));
+ foreach ($this->safeClasses[$class] as $s) {
+ $this->safeLookup[$s][$c] = true;
+ }
+ }
+ }
+ }
+ if (isset($this->safeLookup[$strategy][$c]) || isset($this->safeLookup['all'][$c])) {
+ return (string) $string;
+ }
+ }
+
+ $string = (string) $string;
+ } elseif (\in_array($strategy, ['html', 'js', 'css', 'html_attr', 'url'])) {
+ // we return the input as is (which can be of any type)
+ return $string;
+ }
+ }
+
+ if ('' === $string) {
+ return '';
+ }
+
+ $charset = $charset ?: $this->charset;
+
+ switch ($strategy) {
+ case 'html':
+ // see https://www.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 = $this->convertEncoding($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 = $this->convertEncoding($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, 'UTF-8');
+ 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 = $this->convertEncoding($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 = $this->convertEncoding($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 '�';
+ }
+
+ /*
+ * 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 => '"', /* quotation mark */
+ 38 => '&', /* ampersand */
+ 60 => '<', /* less-than sign */
+ 62 => '>', /* 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:
+ if (\array_key_exists($strategy, $this->escapers)) {
+ return $this->escapers[$strategy]($string, $charset);
+ }
+
+ $validStrategies = implode('", "', array_merge(['html', 'js', 'url', 'css', 'html_attr'], array_keys($this->escapers)));
+
+ throw new RuntimeError(\sprintf('Invalid escaping strategy "%s" (valid ones: "%s").', $strategy, $validStrategies));
+ }
+ }
+
+ private function convertEncoding(string $string, string $to, string $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);
+ }
+}
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
index b360d7b..0510668 100644
--- 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
@@ -23,11 +23,9 @@
*/
class ContainerRuntimeLoader implements RuntimeLoaderInterface
{
- private $container;
-
- public function __construct(ContainerInterface $container)
- {
- $this->container = $container;
+ public function __construct(
+ private ContainerInterface $container,
+ ) {
}
public function load(string $class)
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
index 1306483..5d4e70b 100644
--- 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
@@ -18,14 +18,12 @@
*/
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 __construct(
+ private array $map = [],
+ ) {
}
public function load(string $class)
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
index 2fc0d01..988e372 100644
--- 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
@@ -68,19 +68,25 @@
{
foreach ($tags as $tag) {
if (!\in_array($tag, $this->allowedTags)) {
- throw new SecurityNotAllowedTagError(sprintf('Tag "%s" is not allowed.', $tag), $tag);
+ if ('extends' === $tag) {
+ trigger_deprecation('twig/twig', '3.12', 'The "extends" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitly in your sandbox policy if needed.');
+ } elseif ('use' === $tag) {
+ trigger_deprecation('twig/twig', '3.12', 'The "use" tag is always allowed in sandboxes, but won\'t be in 4.0, please enable it explicitly in your sandbox policy if needed.');
+ } else {
+ 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);
+ 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);
+ throw new SecurityNotAllowedFunctionError(\sprintf('Function "%s" is not allowed.', $function), $function);
}
}
}
@@ -94,16 +100,15 @@
$allowed = false;
$method = strtr($method, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz');
foreach ($this->allowedMethods as $class => $methods) {
- if ($obj instanceof $class) {
- $allowed = \in_array($method, $methods);
-
+ if ($obj instanceof $class && \in_array($method, $methods)) {
+ $allowed = true;
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);
+ throw new SecurityNotAllowedMethodError(\sprintf('Calling "%s" method on a "%s" object is not allowed.', $method, $class), $class, $method);
}
}
@@ -111,16 +116,15 @@
{
$allowed = false;
foreach ($this->allowedProperties as $class => $properties) {
- if ($obj instanceof $class) {
- $allowed = \in_array($property, \is_array($properties) ? $properties : [$properties]);
-
+ if ($obj instanceof $class && \in_array($property, \is_array($properties) ? $properties : [$properties])) {
+ $allowed = true;
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);
+ 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/SourcePolicyInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SourcePolicyInterface.php
new file mode 100644
index 0000000..b952f1e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Sandbox/SourcePolicyInterface.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\Sandbox;
+
+use Twig\Source;
+
+/**
+ * Interface for a class that can optionally enable the sandbox mode based on a template's Twig\Source.
+ *
+ * @author Yaakov Saxon
+ */
+interface SourcePolicyInterface
+{
+ public function enableSandbox(Source $source): bool;
+}
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
index 3cb0240..0f626b6 100644
--- 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
@@ -18,20 +18,16 @@
*/
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 __construct(
+ private string $code,
+ private string $name,
+ private string $path = '',
+ ) {
}
public function getCode(): string
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
index e04bd04..7b3ce81 100644
--- 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
@@ -35,38 +35,36 @@
protected $parent;
protected $parents = [];
- protected $env;
protected $blocks = [];
protected $traits = [];
protected $extensions = [];
protected $sandbox;
- public function __construct(Environment $env)
- {
- $this->env = $env;
+ private $useYield;
+
+ public function __construct(
+ protected Environment $env,
+ ) {
+ $this->useYield = $env->useYield();
$this->extensions = $env->getExtensions();
}
/**
* Returns the template name.
- *
- * @return string The template name
*/
- abstract public function getTemplateName();
+ abstract public function getTemplateName(): string;
/**
* Returns debug information about the template.
*
- * @return array Debug information
+ * @return array<int, int> Debug information
*/
- abstract public function getDebugInfo();
+ abstract public function getDebugInfo(): array;
/**
* Returns information about the original template source code.
- *
- * @return Source
*/
- abstract public function getSourceContext();
+ abstract public function getSourceContext(): Source;
/**
* Returns the parent template.
@@ -74,18 +72,16 @@
* 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
+ * @return self|TemplateWrapper|false The parent template or false if there is no parent
*/
- public function getParent(array $context)
+ public function getParent(array $context): self|TemplateWrapper|false
{
if (null !== $this->parent) {
return $this->parent;
}
try {
- $parent = $this->doGetParent($context);
-
- if (false === $parent) {
+ if (!$parent = $this->doGetParent($context)) {
return false;
}
@@ -106,12 +102,12 @@
return $this->parents[$parent];
}
- protected function doGetParent(array $context)
+ protected function doGetParent(array $context): bool|string|self|TemplateWrapper
{
return false;
}
- public function isTraitable()
+ public function isTraitable(): bool
{
return true;
}
@@ -126,14 +122,10 @@
* @param array $context The context
* @param array $blocks The current set of blocks
*/
- public function displayParentBlock($name, array $context, array $blocks = [])
+ public function displayParentBlock($name, array $context, array $blocks = []): void
{
- 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());
+ foreach ($this->yieldParentBlock($name, $context, $blocks) as $data) {
+ echo $data;
}
}
@@ -148,51 +140,10 @@
* @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)
+ public function displayBlock($name, array $context, array $blocks = [], $useBlocks = true, ?self $templateContext = null): void
{
- 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());
+ foreach ($this->yieldBlock($name, $context, $blocks, $useBlocks, $templateContext) as $data) {
+ echo $data;
}
}
@@ -208,16 +159,25 @@
*
* @return string The rendered block
*/
- public function renderParentBlock($name, array $context, array $blocks = [])
+ public function renderParentBlock($name, array $context, array $blocks = []): string
{
- if ($this->env->isDebug()) {
- ob_start();
- } else {
- ob_start(function () { return ''; });
- }
- $this->displayParentBlock($name, $context, $blocks);
+ if (!$this->useYield) {
+ if ($this->env->isDebug()) {
+ ob_start();
+ } else {
+ ob_start(function () { return ''; });
+ }
+ $this->displayParentBlock($name, $context, $blocks);
- return ob_get_clean();
+ return ob_get_clean();
+ }
+
+ $content = '';
+ foreach ($this->yieldParentBlock($name, $context, $blocks) as $data) {
+ $content .= $data;
+ }
+
+ return $content;
}
/**
@@ -233,16 +193,34 @@
*
* @return string The rendered block
*/
- public function renderBlock($name, array $context, array $blocks = [], $useBlocks = true)
+ public function renderBlock($name, array $context, array $blocks = [], $useBlocks = true): string
{
- if ($this->env->isDebug()) {
- ob_start();
- } else {
- ob_start(function () { return ''; });
- }
- $this->displayBlock($name, $context, $blocks, $useBlocks);
+ if (!$this->useYield) {
+ $level = ob_get_level();
+ if ($this->env->isDebug()) {
+ ob_start();
+ } else {
+ ob_start(function () { return ''; });
+ }
+ try {
+ $this->displayBlock($name, $context, $blocks, $useBlocks);
+ } catch (\Throwable $e) {
+ while (ob_get_level() > $level) {
+ ob_end_clean();
+ }
- return ob_get_clean();
+ throw $e;
+ }
+
+ return ob_get_clean();
+ }
+
+ $content = '';
+ foreach ($this->yieldBlock($name, $context, $blocks, $useBlocks) as $data) {
+ $content .= $data;
+ }
+
+ return $content;
}
/**
@@ -257,7 +235,7 @@
*
* @return bool true if the block exists, false otherwise
*/
- public function hasBlock($name, array $context, array $blocks = [])
+ public function hasBlock($name, array $context, array $blocks = []): bool
{
if (isset($blocks[$name])) {
return $blocks[$name][0] instanceof self;
@@ -267,7 +245,7 @@
return true;
}
- if (false !== $parent = $this->getParent($context)) {
+ if ($parent = $this->getParent($context)) {
return $parent->hasBlock($name, $context);
}
@@ -283,13 +261,13 @@
* @param array $context The context
* @param array $blocks The current set of blocks
*
- * @return array An array of block names
+ * @return array<string> An array of block names
*/
- public function getBlockNames(array $context, array $blocks = [])
+ public function getBlockNames(array $context, array $blocks = []): array
{
$names = array_merge(array_keys($blocks), array_keys($this->blocks));
- if (false !== $parent = $this->getParent($context)) {
+ if ($parent = $this->getParent($context)) {
$names = array_merge($names, $parent->getBlockNames($context));
}
@@ -297,16 +275,22 @@
}
/**
- * @return Template|TemplateWrapper
+ * @param string|TemplateWrapper|array<string|TemplateWrapper> $template
*/
- protected function loadTemplate($template, $templateName = null, $line = null, $index = null)
+ protected function loadTemplate($template, $templateName = null, $line = null, $index = null): self|TemplateWrapper
{
try {
if (\is_array($template)) {
return $this->env->resolveTemplate($template);
}
- if ($template instanceof self || $template instanceof TemplateWrapper) {
+ if ($template instanceof TemplateWrapper) {
+ return $template;
+ }
+
+ if ($template instanceof self) {
+ trigger_deprecation('twig/twig', '3.9', 'Passing a "%s" instance to "%s" is deprecated.', self::class, __METHOD__);
+
return $template;
}
@@ -341,10 +325,8 @@
/**
* @internal
- *
- * @return Template
*/
- public function unwrap()
+ public function unwrap(): self
{
return $this;
}
@@ -357,41 +339,58 @@
*
* @return array An array of blocks
*/
- public function getBlocks()
+ public function getBlocks(): array
{
return $this->blocks;
}
- public function display(array $context, array $blocks = [])
+ public function display(array $context, array $blocks = []): void
{
- $this->displayWithErrorHandling($this->env->mergeGlobals($context), array_merge($this->blocks, $blocks));
+ foreach ($this->yield($context, $blocks) as $data) {
+ echo $data;
+ }
}
- public function render(array $context)
+ public function render(array $context): string
{
- $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();
+ if (!$this->useYield) {
+ $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;
}
- throw $e;
+ return ob_get_clean();
}
- return ob_get_clean();
+ $content = '';
+ foreach ($this->yield($context) as $data) {
+ $content .= $data;
+ }
+
+ return $content;
}
- protected function displayWithErrorHandling(array $context, array $blocks = [])
+ /**
+ * @return iterable<scalar|\Stringable|null>
+ */
+ public function yield(array $context, array $blocks = []): iterable
{
+ $context += $this->env->getGlobals();
+ $blocks = array_merge($this->blocks, $blocks);
+
try {
- $this->doDisplay($context, $blocks);
+ yield from $this->doDisplay($context, $blocks);
} catch (Error $e) {
if (!$e->getSourceContext()) {
$e->setSourceContext($this->getSourceContext());
@@ -404,8 +403,8 @@
}
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);
+ } catch (\Throwable $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;
@@ -413,10 +412,86 @@
}
/**
+ * @return iterable<scalar|\Stringable|null>
+ */
+ public function yieldBlock($name, array $context, array $blocks = [], $useBlocks = true, ?self $templateContext = null): iterable
+ {
+ 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 {
+ yield from $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 (\Throwable $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 ($parent = $this->getParent($context)) {
+ yield from $parent->unwrap()->yieldBlock($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());
+ }
+ }
+
+ /**
+ * Yields 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
+ *
+ * @return iterable<scalar|\Stringable|null>
+ */
+ public function yieldParentBlock($name, array $context, array $blocks = []): iterable
+ {
+ if (isset($this->traits[$name])) {
+ yield from $this->traits[$name][0]->yieldBlock($name, $context, $blocks, false);
+ } elseif ($parent = $this->getParent($context)) {
+ yield from $parent->unwrap()->yieldBlock($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());
+ }
+ }
+
+ /**
* 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
+ *
+ * @return iterable<scalar|\Stringable|null>
*/
- abstract protected function doDisplay(array $context, array $blocks = []);
+ abstract protected function doDisplay(array $context, array $blocks = []): iterable;
}
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
index c9c6b07..135c591 100644
--- 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
@@ -18,26 +18,21 @@
*/
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 __construct(
+ private Environment $env,
+ private 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] ?? []);
+ return $this->template->render($context);
}
public function display(array $context = [])
@@ -62,29 +57,15 @@
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();
+ return $this->template->renderBlock($name, $context + $this->env->getGlobals());
}
public function displayBlock(string $name, array $context = [])
{
- $this->template->displayBlock($name, $this->env->mergeGlobals($context));
+ $context += $this->env->getGlobals();
+ foreach ($this->template->yieldBlock($name, $context) as $data) {
+ echo $data;
+ }
}
public function getSourceContext(): Source
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
index 307302b..8690a80 100644
--- 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
@@ -30,9 +30,19 @@
abstract class IntegrationTestCase extends TestCase
{
/**
+ * @deprecated since Twig 3.13, use getFixturesDirectory() instead.
+ *
* @return string
*/
- abstract protected function getFixturesDir();
+ protected function getFixturesDir()
+ {
+ throw new \BadMethodCallException('Not implemented.');
+ }
+
+ protected static function getFixturesDirectory(): string
+ {
+ throw new \BadMethodCallException('Not implemented.');
+ }
/**
* @return RuntimeLoaderInterface[]
@@ -84,6 +94,7 @@
/**
* @dataProvider getLegacyTests
+ *
* @group legacy
*/
public function testLegacyIntegration($file, $message, $condition, $templates, $exception, $outputs, $deprecation = '')
@@ -91,9 +102,19 @@
$this->doIntegrationTest($file, $message, $condition, $templates, $exception, $outputs, $deprecation);
}
+ /**
+ * @final since Twig 3.13
+ */
public function getTests($name, $legacyTests = false)
{
- $fixturesDir = realpath($this->getFixturesDir());
+ try {
+ $fixturesDir = static::getFixturesDirectory();
+ } catch (\BadMethodCallException) {
+ trigger_deprecation('twig/twig', '3.13', 'Not overriding "%s::getFixturesDirectory()" in "%s" is deprecated. This method will be abstract in 4.0.', self::class, static::class);
+ $fixturesDir = $this->getFixturesDir();
+ }
+
+ $fixturesDir = realpath($fixturesDir);
$tests = [];
foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($fixturesDir), \RecursiveIteratorIterator::LEAVES_ONLY) as $file) {
@@ -101,7 +122,7 @@
continue;
}
- if ($legacyTests xor false !== strpos($file->getRealpath(), '.legacy.test')) {
+ if ($legacyTests xor str_contains($file->getRealpath(), '.legacy.test')) {
continue;
}
@@ -122,7 +143,7 @@
$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)));
+ throw new \InvalidArgumentException(\sprintf('Test "%s" is not valid.', str_replace($fixturesDir.'/', '', $file)));
}
$tests[] = [str_replace($fixturesDir.'/', '', $file), $message, $condition, $templates, $exception, $outputs, $deprecation];
@@ -136,6 +157,9 @@
return $tests;
}
+ /**
+ * @final since Twig 3.13
+ */
public function getLegacyTests()
{
return $this->getTests('testLegacyIntegration', true);
@@ -148,19 +172,23 @@
}
if ($condition) {
+ $ret = '';
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].';') : []);
+ // make sure that template are always compiled even if they are the same (useful when testing with more than one data/expect sections)
+ foreach ($templates as $j => $template) {
+ $templates[$j] = $template.str_repeat(' ', $i);
+ }
+ $loader = new ArrayLoader($templates);
$twig = new Environment($loader, $config);
$twig->addGlobal('global', 'global');
foreach ($this->getRuntimeLoaders() as $runtimeLoader) {
@@ -183,11 +211,6 @@
$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(\PHP_VERSION_ID < 80100 ? 'sha256' : 'xxh128', uniqid(mt_rand(), true), false).'_');
-
$deprecations = [];
try {
$prevHandler = set_error_handler(function ($type, $msg, $file, $line, $context = []) use (&$deprecations, &$prevHandler) {
@@ -204,14 +227,14 @@
} catch (\Exception $e) {
if (false !== $exception) {
$message = $e->getMessage();
- $this->assertSame(trim($exception), trim(sprintf('%s: %s', \get_class($e), $message)));
+ $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);
+ throw new Error(\sprintf('%s: %s', \get_class($e), $e->getMessage()), -1, null, $e);
} finally {
restore_error_handler();
}
@@ -222,18 +245,18 @@
$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())));
+ $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);
+ $e = new Error(\sprintf('%s: %s', \get_class($e), $e->getMessage()), -1, null, $e);
- $output = trim(sprintf('%s: %s', \get_class($e), $e->getMessage()));
+ $output = trim(\sprintf('%s: %s', \get_class($e), $e->getMessage()));
}
if (false !== $exception) {
- list($class) = explode(':', $exception);
+ [$class] = explode(':', $exception);
$constraintClass = class_exists('PHPUnit\Framework\Constraint\Exception') ? 'PHPUnit\Framework\Constraint\Exception' : 'PHPUnit_Framework_Constraint_Exception';
$this->assertThat(null, new $constraintClass($class));
}
@@ -257,7 +280,7 @@
$templates = [];
preg_match_all('/--TEMPLATE(?:\((.*?)\))?--(.*?)(?=\-\-TEMPLATE|$)/s', $test, $matches, \PREG_SET_ORDER);
foreach ($matches as $match) {
- $templates[($match[1] ?: 'index.twig')] = $match[2];
+ $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
index 3b8b2c8..bac0ea6 100644
--- 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
@@ -11,6 +11,8 @@
namespace Twig\Test;
+use PHPUnit\Framework\Attributes\BeforeClass;
+use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\TestCase;
use Twig\Compiler;
use Twig\Environment;
@@ -19,17 +21,37 @@
abstract class NodeTestCase extends TestCase
{
- abstract public function getTests();
+ /**
+ * @var Environment
+ */
+ private $currentEnv;
+
+ public function getTests()
+ {
+ return [];
+ }
+
+ /**
+ * @return iterable<array{0: Node, 1: string, 2?: Environment|null, 3?: bool}>
+ */
+ public static function provideTests(): iterable
+ {
+ trigger_deprecation('twig/twig', '3.13', 'Not implementing "%s()" in "%s" is deprecated. This method will be abstract in 4.0.', __METHOD__, static::class);
+
+ return [];
+ }
/**
* @dataProvider getTests
+ * @dataProvider provideTests
*/
+ #[DataProvider('getTests'), DataProvider('provideTests')]
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)
+ public function assertNodeCompilation($source, Node $node, ?Environment $environment = null, $isPattern = false)
{
$compiler = $this->getCompiler($environment);
$compiler->compile($node);
@@ -41,25 +63,63 @@
}
}
- protected function getCompiler(Environment $environment = null)
+ protected function getCompiler(?Environment $environment = null)
{
- return new Compiler(null === $environment ? $this->getEnvironment() : $environment);
+ return new Compiler($environment ?? $this->getEnvironment());
}
+ /**
+ * @final since Twig 3.13
+ */
protected function getEnvironment()
{
- return new Environment(new ArrayLoader([]));
+ return $this->currentEnv ??= static::createEnvironment();
}
+ protected static function createEnvironment(): Environment
+ {
+ return new Environment(new ArrayLoader());
+ }
+
+ /**
+ * @deprecated since Twig 3.13, use createVariableGetter() instead.
+ */
protected function getVariableGetter($name, $line = false)
{
+ trigger_deprecation('twig/twig', '3.13', 'Method "%s()" is deprecated, use "createVariableGetter()" instead.', __METHOD__);
+
+ return self::createVariableGetter($name, $line);
+ }
+
+ final protected static function createVariableGetter(string $name, bool $line = false): string
+ {
$line = $line > 0 ? "// line $line\n" : '';
- return sprintf('%s($context["%s"] ?? null)', $line, $name);
+ return \sprintf('%s($context["%s"] ?? null)', $line, $name);
}
+ /**
+ * @deprecated since Twig 3.13, use createAttributeGetter() instead.
+ */
protected function getAttributeGetter()
{
- return 'twig_get_attribute($this->env, $this->source, ';
+ trigger_deprecation('twig/twig', '3.13', 'Method "%s()" is deprecated, use "createAttributeGetter()" instead.', __METHOD__);
+
+ return self::createAttributeGetter();
+ }
+
+ final protected static function createAttributeGetter(): string
+ {
+ return 'CoreExtension::getAttribute($this->env, $this->source, ';
+ }
+
+ /** @beforeClass */
+ #[BeforeClass]
+ final public static function checkDataProvider(): void
+ {
+ $r = new \ReflectionMethod(static::class, 'getTests');
+ if (self::class !== $r->getDeclaringClass()->getName()) {
+ trigger_deprecation('twig/twig', '3.13', 'Implementing "%s::getTests()" in "%s" is deprecated, implement "provideTests()" instead.', self::class, static::class);
+ }
}
}
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
index 53a6caf..237634a 100644
--- 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
@@ -17,10 +17,6 @@
*/
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;
@@ -35,17 +31,18 @@
public const INTERPOLATION_START_TYPE = 10;
public const INTERPOLATION_END_TYPE = 11;
public const ARROW_TYPE = 12;
+ public const SPREAD_TYPE = 13;
- public function __construct(int $type, $value, int $lineno)
- {
- $this->type = $type;
- $this->value = $value;
- $this->lineno = $lineno;
+ public function __construct(
+ private int $type,
+ private $value,
+ private int $lineno,
+ ) {
}
public function __toString()
{
- return sprintf('%s(%s)', self::typeToString($this->type, true), $this->value);
+ return \sprintf('%s(%s)', self::typeToString($this->type, true), $this->value);
}
/**
@@ -67,9 +64,9 @@
}
return ($this->type === $type) && (
- null === $values ||
- (\is_array($values) && \in_array($this->value, $values)) ||
- $this->value == $values
+ null === $values
+ || (\is_array($values) && \in_array($this->value, $values))
+ || $this->value == $values
);
}
@@ -133,8 +130,11 @@
case self::ARROW_TYPE:
$name = 'ARROW_TYPE';
break;
+ case self::SPREAD_TYPE:
+ $name = 'SPREAD_TYPE';
+ break;
default:
- throw new \LogicException(sprintf('Token of type "%s" does not exist.', $type));
+ throw new \LogicException(\sprintf('Token of type "%s" does not exist.', $type));
}
return $short ? $name : 'Twig\Token::'.$name;
@@ -171,8 +171,10 @@
return 'end of string interpolation';
case self::ARROW_TYPE:
return 'arrow function';
+ case self::SPREAD_TYPE:
+ return 'spread operator';
default:
- throw new \LogicException(sprintf('Token of type "%s" does not exist.', $type));
+ 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/ApplyTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/ApplyTokenParser.php
index 4dbf304..0a6c1af 100644
--- 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
@@ -36,16 +36,16 @@
$ref = new TempNameExpression($name, $lineno);
$ref->setAttribute('always_defined', true);
- $filter = $this->parser->getExpressionParser()->parseFilterExpressionRaw($ref, $this->getTag());
+ $filter = $this->parser->getExpressionParser()->parseFilterExpressionRaw($ref);
$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()),
- ]);
+ new SetNode(true, $ref, $body, $lineno),
+ new PrintNode($filter, $lineno),
+ ], [], $lineno);
}
public function decideApplyEnd(Token $token): bool
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
index b674bea..b50b29e 100644
--- 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
@@ -29,7 +29,7 @@
$lineno = $token->getLine();
$stream = $this->parser->getStream();
- if ($stream->test(/* Token::BLOCK_END_TYPE */ 3)) {
+ if ($stream->test(Token::BLOCK_END_TYPE)) {
$value = 'html';
} else {
$expr = $this->parser->getExpressionParser()->parseExpression();
@@ -39,11 +39,11 @@
$value = $expr->getAttribute('value');
}
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
- return new AutoEscapeNode($value, $body, $lineno, $this->getTag());
+ return new AutoEscapeNode($value, $body, $lineno);
}
public function decideBlockEnd(Token $token): bool
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
index 5878131..81d675d 100644
--- 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
@@ -35,21 +35,18 @@
{
$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());
- }
+ $name = $stream->expect(Token::NAME_TYPE)->getValue();
$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)) {
+ if ($stream->nextIf(Token::BLOCK_END_TYPE)) {
$body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
- if ($token = $stream->nextIf(/* Token::NAME_TYPE */ 5)) {
+ if ($token = $stream->nextIf(Token::NAME_TYPE)) {
$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());
+ throw new SyntaxError(\sprintf('Expected endblock for block "%s" (but "%s" given).', $name, $value), $stream->getCurrent()->getLine(), $stream->getSourceContext());
}
}
} else {
@@ -57,13 +54,13 @@
new PrintNode($this->parser->getExpressionParser()->parseExpression(), $lineno),
]);
}
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$block->setNode('body', $body);
$this->parser->popBlockStack();
$this->parser->popLocalScope();
- return new BlockReferenceNode($name, $lineno, $this->getTag());
+ return new BlockReferenceNode($name, $lineno);
}
public function decideBlockEnd(Token $token): bool
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
index 31416c7..164ef26 100644
--- 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
@@ -11,6 +11,7 @@
namespace Twig\TokenParser;
+use Twig\Error\SyntaxError;
use Twig\Node\DeprecatedNode;
use Twig\Node\Node;
use Twig\Token;
@@ -21,6 +22,8 @@
* {% deprecated 'The "base.twig" template is deprecated, use "layout.twig" instead.' %}
* {% extends 'layout.html.twig' %}
*
+ * {% deprecated 'The "base.twig" template is deprecated, use "layout.twig" instead.' package="foo/bar" version="1.1" %}
+ *
* @author Yonel Ceruto <yonelceruto@gmail.com>
*
* @internal
@@ -29,11 +32,31 @@
{
public function parse(Token $token): Node
{
- $expr = $this->parser->getExpressionParser()->parseExpression();
+ $stream = $this->parser->getStream();
+ $expressionParser = $this->parser->getExpressionParser();
+ $expr = $expressionParser->parseExpression();
+ $node = new DeprecatedNode($expr, $token->getLine());
- $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
+ while ($stream->test(Token::NAME_TYPE)) {
+ $k = $stream->getCurrent()->getValue();
+ $stream->next();
+ $stream->expect(Token::OPERATOR_TYPE, '=');
- return new DeprecatedNode($expr, $token->getLine(), $this->getTag());
+ switch ($k) {
+ case 'package':
+ $node->setNode('package', $expressionParser->parseExpression());
+ break;
+ case 'version':
+ $node->setNode('version', $expressionParser->parseExpression());
+ break;
+ default:
+ throw new SyntaxError(\sprintf('Unknown "%s" option.', $k), $stream->getCurrent()->getLine(), $stream->getSourceContext());
+ }
+ }
+
+ $stream->expect(Token::BLOCK_END_TYPE);
+
+ return $node;
}
public function getTag(): string
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
index 32c8f12..8afd485 100644
--- 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
@@ -26,9 +26,9 @@
{
$expr = $this->parser->getExpressionParser()->parseExpression();
- $this->parser->getStream()->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
- return new DoNode($expr, $token->getLine(), $this->getTag());
+ return new DoNode($expr, $token->getLine());
}
public function getTag(): string
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
index 64b4f29..7bf3233 100644
--- 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
@@ -30,21 +30,21 @@
$parent = $this->parser->getExpressionParser()->parseExpression();
- list($variables, $only, $ignoreMissing) = $this->parseArguments();
+ [$variables, $only, $ignoreMissing] = $this->parseArguments();
- $parentToken = $fakeParentToken = new Token(/* Token::STRING_TYPE */ 7, '__parent__', $token->getLine());
+ $parentToken = $fakeParentToken = new Token(Token::STRING_TYPE, '__parent__', $token->getLine());
if ($parent instanceof ConstantExpression) {
- $parentToken = new Token(/* Token::STRING_TYPE */ 7, $parent->getAttribute('value'), $token->getLine());
+ $parentToken = new Token(Token::STRING_TYPE, $parent->getAttribute('value'), $token->getLine());
} elseif ($parent instanceof NameExpression) {
- $parentToken = new Token(/* Token::NAME_TYPE */ 5, $parent->getAttribute('name'), $token->getLine());
+ $parentToken = new Token(Token::NAME_TYPE, $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()),
+ new Token(Token::BLOCK_START_TYPE, '', $token->getLine()),
+ new Token(Token::NAME_TYPE, 'extends', $token->getLine()),
$parentToken,
- new Token(/* Token::BLOCK_END_TYPE */ 3, '', $token->getLine()),
+ new Token(Token::BLOCK_END_TYPE, '', $token->getLine()),
]);
$module = $this->parser->parse($stream, [$this, 'decideBlockEnd'], true);
@@ -56,9 +56,9 @@
$this->parser->embedTemplate($module);
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
- return new EmbedNode($module->getTemplateName(), $module->getAttribute('index'), $variables, $only, $ignoreMissing, $token->getLine(), $this->getTag());
+ return new EmbedNode($module->getTemplateName(), $module->getAttribute('index'), $variables, $only, $ignoreMissing, $token->getLine());
}
public function decideBlockEnd(Token $token): bool
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
index 0ca46dd..86ddfdf 100644
--- 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
@@ -35,14 +35,11 @@
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);
+ $stream->expect(Token::BLOCK_END_TYPE);
- return new Node();
+ return new Node([], [], $token->getLine());
}
public function getTag(): string
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
index 02c74aa..0d23887 100644
--- 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
@@ -26,9 +26,9 @@
{
public function parse(Token $token): Node
{
- $this->parser->getStream()->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
- return new FlushNode($token->getLine(), $this->getTag());
+ return new FlushNode($token->getLine());
}
public function getTag(): string
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
index bac8ba2..cf655f8 100644
--- 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
@@ -35,30 +35,30 @@
$lineno = $token->getLine();
$stream = $this->parser->getStream();
$targets = $this->parser->getExpressionParser()->parseAssignmentExpression();
- $stream->expect(/* Token::OPERATOR_TYPE */ 8, 'in');
+ $stream->expect(Token::OPERATOR_TYPE, 'in');
$seq = $this->parser->getExpressionParser()->parseExpression();
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$body = $this->parser->subparse([$this, 'decideForFork']);
if ('else' == $stream->next()->getValue()) {
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$else = $this->parser->subparse([$this, 'decideForEnd'], true);
} else {
$else = null;
}
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
if (\count($targets) > 1) {
- $keyTarget = $targets->getNode(0);
+ $keyTarget = $targets->getNode('0');
$keyTarget = new AssignNameExpression($keyTarget->getAttribute('name'), $keyTarget->getTemplateLine());
- $valueTarget = $targets->getNode(1);
+ $valueTarget = $targets->getNode('1');
} else {
$keyTarget = new AssignNameExpression('_key', $lineno);
- $valueTarget = $targets->getNode(0);
+ $valueTarget = $targets->getNode('0');
}
$valueTarget = new AssignNameExpression($valueTarget->getAttribute('name'), $valueTarget->getTemplateLine());
- return new ForNode($keyTarget, $valueTarget, $seq, null, $body, $else, $lineno, $this->getTag());
+ return new ForNode($keyTarget, $valueTarget, $seq, null, $body, $else, $lineno);
}
public function decideForFork(Token $token): bool
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
index 35098c2..2ccff5f 100644
--- 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
@@ -29,28 +29,28 @@
{
$macro = $this->parser->getExpressionParser()->parseExpression();
$stream = $this->parser->getStream();
- $stream->expect(/* Token::NAME_TYPE */ 5, 'import');
+ $stream->expect(Token::NAME_TYPE, 'import');
$targets = [];
- do {
- $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+ while (true) {
+ $name = $stream->expect(Token::NAME_TYPE)->getValue();
$alias = $name;
if ($stream->nextIf('as')) {
- $alias = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+ $alias = $stream->expect(Token::NAME_TYPE)->getValue();
}
$targets[$name] = $alias;
- if (!$stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+ if (!$stream->nextIf(Token::PUNCTUATION_TYPE, ',')) {
break;
}
- } while (true);
+ }
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$var = new AssignNameExpression($this->parser->getVarName(), $token->getLine());
- $node = new ImportNode($macro, $var, $token->getLine(), $this->getTag(), $this->parser->isMainScope());
+ $node = new ImportNode($macro, $var, $token->getLine(), $this->parser->isMainScope());
foreach ($targets as $name => $alias) {
$this->parser->addImportedSymbol('function', $alias, 'macro_'.$name, $var);
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
index c0fe6df..4ea6f3d 100644
--- 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
@@ -37,7 +37,7 @@
$lineno = $token->getLine();
$expr = $this->parser->getExpressionParser()->parseExpression();
$stream = $this->parser->getStream();
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$body = $this->parser->subparse([$this, 'decideIfFork']);
$tests = [$expr, $body];
$else = null;
@@ -46,13 +46,13 @@
while (!$end) {
switch ($stream->next()->getValue()) {
case 'else':
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$else = $this->parser->subparse([$this, 'decideIfEnd']);
break;
case 'elseif':
$expr = $this->parser->getExpressionParser()->parseExpression();
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$body = $this->parser->subparse([$this, 'decideIfFork']);
$tests[] = $expr;
$tests[] = $body;
@@ -63,13 +63,13 @@
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());
+ 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);
+ $stream->expect(Token::BLOCK_END_TYPE);
- return new IfNode(new Node($tests), $else, $lineno, $this->getTag());
+ return new IfNode(new Node($tests), $else, $lineno);
}
public function decideIfFork(Token $token): bool
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
index 44cb4da..f20f35a 100644
--- 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
@@ -28,13 +28,13 @@
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->getStream()->expect(Token::NAME_TYPE, 'as');
+ $var = new AssignNameExpression($this->parser->getStream()->expect(Token::NAME_TYPE)->getValue(), $token->getLine());
+ $this->parser->getStream()->expect(Token::BLOCK_END_TYPE);
$this->parser->addImportedSymbol('template', $var->getAttribute('name'));
- return new ImportNode($macro, $var, $token->getLine(), $this->getTag(), $this->parser->isMainScope());
+ return new ImportNode($macro, $var, $token->getLine(), $this->parser->isMainScope());
}
public function getTag(): string
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
index 28beb8a..466f228 100644
--- 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
@@ -31,9 +31,9 @@
{
$expr = $this->parser->getExpressionParser()->parseExpression();
- list($variables, $only, $ignoreMissing) = $this->parseArguments();
+ [$variables, $only, $ignoreMissing] = $this->parseArguments();
- return new IncludeNode($expr, $variables, $only, $ignoreMissing, $token->getLine(), $this->getTag());
+ return new IncludeNode($expr, $variables, $only, $ignoreMissing, $token->getLine());
}
protected function parseArguments()
@@ -41,23 +41,23 @@
$stream = $this->parser->getStream();
$ignoreMissing = false;
- if ($stream->nextIf(/* Token::NAME_TYPE */ 5, 'ignore')) {
- $stream->expect(/* Token::NAME_TYPE */ 5, 'missing');
+ if ($stream->nextIf(Token::NAME_TYPE, 'ignore')) {
+ $stream->expect(Token::NAME_TYPE, 'missing');
$ignoreMissing = true;
}
$variables = null;
- if ($stream->nextIf(/* Token::NAME_TYPE */ 5, 'with')) {
+ if ($stream->nextIf(Token::NAME_TYPE, 'with')) {
$variables = $this->parser->getExpressionParser()->parseExpression();
}
$only = false;
- if ($stream->nextIf(/* Token::NAME_TYPE */ 5, 'only')) {
+ if ($stream->nextIf(Token::NAME_TYPE, 'only')) {
$only = true;
}
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
return [$variables, $only, $ignoreMissing];
}
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
index f584927..c776207 100644
--- 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
@@ -32,26 +32,26 @@
{
$lineno = $token->getLine();
$stream = $this->parser->getStream();
- $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+ $name = $stream->expect(Token::NAME_TYPE)->getValue();
$arguments = $this->parser->getExpressionParser()->parseArguments(true, true);
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$this->parser->pushLocalScope();
$body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
- if ($token = $stream->nextIf(/* Token::NAME_TYPE */ 5)) {
+ if ($token = $stream->nextIf(Token::NAME_TYPE)) {
$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());
+ 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);
+ $stream->expect(Token::BLOCK_END_TYPE);
- $this->parser->setMacro($name, new MacroNode($name, new BodyNode([$body]), $arguments, $lineno, $this->getTag()));
+ $this->parser->setMacro($name, new MacroNode($name, new BodyNode([$body]), $arguments, $lineno));
- return new Node();
+ return new Node([], [], $lineno);
}
public function decideBlockEnd(Token $token): bool
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
index c919556..70869fb 100644
--- 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
@@ -34,9 +34,9 @@
public function parse(Token $token): Node
{
$stream = $this->parser->getStream();
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$body = $this->parser->subparse([$this, 'decideBlockEnd'], true);
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
// in a sandbox tag, only include tags are allowed
if (!$body instanceof IncludeNode) {
@@ -51,7 +51,7 @@
}
}
- return new SandboxNode($body, $token->getLine(), $this->getTag());
+ return new SandboxNode($body, $token->getLine());
}
public function decideBlockEnd(Token $token): bool
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
index 2fbdfe0..bb43907 100644
--- 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
@@ -37,10 +37,10 @@
$names = $this->parser->getExpressionParser()->parseAssignmentExpression();
$capture = false;
- if ($stream->nextIf(/* Token::OPERATOR_TYPE */ 8, '=')) {
+ if ($stream->nextIf(Token::OPERATOR_TYPE, '=')) {
$values = $this->parser->getExpressionParser()->parseMultitargetExpression();
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
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());
@@ -52,13 +52,13 @@
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);
+ $stream->expect(Token::BLOCK_END_TYPE);
$values = $this->parser->subparse([$this, 'decideBlockEnd'], true);
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
}
- return new SetNode($capture, $names, $values, $lineno, $this->getTag());
+ return new SetNode($capture, $names, $values, $lineno);
}
public function decideBlockEnd(Token $token): bool
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/TypesTokenParser.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/TypesTokenParser.php
new file mode 100644
index 0000000..2e0850e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TokenParser/TypesTokenParser.php
@@ -0,0 +1,86 @@
+<?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\TypesNode;
+use Twig\Token;
+use Twig\TokenStream;
+
+/**
+ * Declare variable types.
+ *
+ * {% types {foo: 'int', bar?: 'string'} %}
+ *
+ * @author Jeroen Versteeg <jeroen@alisqi.com>
+ *
+ * @internal
+ */
+final class TypesTokenParser extends AbstractTokenParser
+{
+ public function parse(Token $token): Node
+ {
+ $stream = $this->parser->getStream();
+
+ $types = $this->parseSimpleMappingExpression($stream);
+
+ $stream->expect(Token::BLOCK_END_TYPE);
+
+ return new TypesNode($types, $token->getLine());
+ }
+
+ /**
+ * @return array<string, array{type: string, optional: bool}>
+ *
+ * @throws SyntaxError
+ */
+ private function parseSimpleMappingExpression(TokenStream $stream): array
+ {
+ $stream->expect(Token::PUNCTUATION_TYPE, '{', 'A mapping element was expected');
+
+ $types = [];
+
+ $first = true;
+ while (!$stream->test(Token::PUNCTUATION_TYPE, '}')) {
+ if (!$first) {
+ $stream->expect(Token::PUNCTUATION_TYPE, ',', 'A type string must be followed by a comma');
+
+ // trailing ,?
+ if ($stream->test(Token::PUNCTUATION_TYPE, '}')) {
+ break;
+ }
+ }
+ $first = false;
+
+ $nameToken = $stream->expect(Token::NAME_TYPE);
+ $isOptional = null !== $stream->nextIf(Token::PUNCTUATION_TYPE, '?');
+
+ $stream->expect(Token::PUNCTUATION_TYPE, ':', 'A type name must be followed by a colon (:)');
+
+ $valueToken = $stream->expect(Token::STRING_TYPE);
+
+ $types[$nameToken->getValue()] = [
+ 'type' => $valueToken->getValue(),
+ 'optional' => $isOptional,
+ ];
+ }
+ $stream->expect(Token::PUNCTUATION_TYPE, '}', 'An opened mapping is not properly closed');
+
+ return $types;
+ }
+
+ public function getTag(): string
+ {
+ return 'types';
+ }
+}
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
index d0a2de4..1b96b40 100644
--- 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
@@ -43,27 +43,27 @@
$targets = [];
if ($stream->nextIf('with')) {
- do {
- $name = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+ while (true) {
+ $name = $stream->expect(Token::NAME_TYPE)->getValue();
$alias = $name;
if ($stream->nextIf('as')) {
- $alias = $stream->expect(/* Token::NAME_TYPE */ 5)->getValue();
+ $alias = $stream->expect(Token::NAME_TYPE)->getValue();
}
$targets[$name] = new ConstantExpression($alias, -1);
- if (!$stream->nextIf(/* Token::PUNCTUATION_TYPE */ 9, ',')) {
+ if (!$stream->nextIf(Token::PUNCTUATION_TYPE, ',')) {
break;
}
- } while (true);
+ }
}
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$this->parser->addTrait(new Node(['template' => $template, 'targets' => new Node($targets)]));
- return new Node();
+ return new Node([], [], $token->getLine());
}
public function getTag(): string
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
index 7d8cbe2..8ce4f02 100644
--- 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
@@ -30,18 +30,18 @@
$variables = null;
$only = false;
- if (!$stream->test(/* Token::BLOCK_END_TYPE */ 3)) {
+ if (!$stream->test(Token::BLOCK_END_TYPE)) {
$variables = $this->parser->getExpressionParser()->parseExpression();
- $only = (bool) $stream->nextIf(/* Token::NAME_TYPE */ 5, 'only');
+ $only = (bool) $stream->nextIf(Token::NAME_TYPE, 'only');
}
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
$body = $this->parser->subparse([$this, 'decideWithEnd'], true);
- $stream->expect(/* Token::BLOCK_END_TYPE */ 3);
+ $stream->expect(Token::BLOCK_END_TYPE);
- return new WithNode($body, $variables, $only, $token->getLine(), $this->getTag());
+ return new WithNode($body, $variables, $only, $token->getLine());
}
public function decideWithEnd(Token $token): bool
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
index 1eac11a..c91701b 100644
--- 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
@@ -21,13 +21,12 @@
*/
final class TokenStream
{
- private $tokens;
private $current = 0;
- private $source;
- public function __construct(array $tokens, Source $source = null)
- {
- $this->tokens = $tokens;
+ public function __construct(
+ private array $tokens,
+ private ?Source $source = null,
+ ) {
$this->source = $source ?: new Source('', '');
}
@@ -60,24 +59,22 @@
*/
public function nextIf($primary, $secondary = null)
{
- if ($this->tokens[$this->current]->test($primary, $secondary)) {
- return $this->next();
- }
+ return $this->tokens[$this->current]->test($primary, $secondary) ? $this->next() : null;
}
/**
* Tests a token and returns it or throws a syntax error.
*/
- public function expect($type, $value = null, string $message = null): Token
+ 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).',
+ 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) : ''),
+ $token->getValue() ? \sprintf(' of value "%s"', $token->getValue()) : '',
+ Token::typeToEnglish($type), $value ? \sprintf(' with value "%s"', $value) : ''),
$line,
$this->source
);
@@ -112,7 +109,7 @@
*/
public function isEOF(): bool
{
- return /* Token::EOF_TYPE */ -1 === $this->tokens[$this->current]->getType();
+ return Token::EOF_TYPE === $this->tokens[$this->current]->getType();
}
public function getCurrent(): Token
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigCallableInterface.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigCallableInterface.php
new file mode 100644
index 0000000..2a8ff61
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/TwigCallableInterface.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;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ */
+interface TwigCallableInterface extends \Stringable
+{
+ public function getName(): string;
+
+ public function getType(): string;
+
+ public function getDynamicName(): string;
+
+ /**
+ * @return callable|array{class-string, string}|null
+ */
+ public function getCallable();
+
+ public function getNodeClass(): string;
+
+ public function needsCharset(): bool;
+
+ public function needsEnvironment(): bool;
+
+ public function needsContext(): bool;
+
+ public function withDynamicArguments(string $name, string $dynamicName, array $arguments): self;
+
+ public function getArguments(): array;
+
+ public function isVariadic(): bool;
+
+ public function isDeprecated(): bool;
+
+ public function getDeprecatingPackage(): string;
+
+ public function getDeprecatedVersion(): string;
+
+ public function getAlternative(): ?string;
+
+ public function getMinimalNumberOfRequiredArguments(): int;
+}
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
index 94e5f9b..70b1f8f 100644
--- 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
@@ -21,72 +21,27 @@
*
* @see https://twig.symfony.com/doc/templates.html#filters
*/
-final class TwigFilter
+final class TwigFilter extends AbstractTwigCallable
{
- 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.
+ * @param callable|array{class-string, string}|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;
+ parent::__construct($name, $callable, $options);
+
$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);
+ ], $this->options);
}
- public function getName(): string
+ public function getType(): 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'];
+ return 'filter';
}
public function getSafe(Node $filterArgs): ?array
@@ -112,23 +67,8 @@
return $this->options['pre_escape'];
}
- public function isVariadic(): bool
+ public function getMinimalNumberOfRequiredArguments(): int
{
- 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'];
+ return parent::getMinimalNumberOfRequiredArguments() + 1;
}
}
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
index 494d45b..4a10df9 100644
--- 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
@@ -21,70 +21,31 @@
*
* @see https://twig.symfony.com/doc/templates.html#functions
*/
-final class TwigFunction
+final class TwigFunction extends AbstractTwigCallable
{
- 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.
+ * @param callable|array{class-string, string}|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;
+ parent::__construct($name, $callable, $options);
+
$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);
+ 'parser_callable' => null,
+ ], $this->options);
}
- public function getName(): string
+ public function getType(): string
{
- return $this->name;
+ return 'function';
}
- /**
- * Returns the callable to execute for this function.
- *
- * @return callable|null
- */
- public function getCallable()
+ public function getParserCallable(): ?callable
{
- 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'];
+ return $this->options['parser_callable'];
}
public function getSafe(Node $functionArgs): ?array
@@ -99,24 +60,4 @@
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
index 4c18632..5e58ad8 100644
--- 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
@@ -20,81 +20,48 @@
*
* @see https://twig.symfony.com/doc/templates.html#test-operator
*/
-final class TwigTest
+final class TwigTest extends AbstractTwigCallable
{
- 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.
+ * @param callable|array{class-string, string}|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;
+ parent::__construct($name, $callable, $options);
+
$this->options = array_merge([
- 'is_variadic' => false,
'node_class' => TestExpression::class,
- 'deprecated' => false,
- 'alternative' => null,
'one_mandatory_argument' => false,
- ], $options);
+ ], $this->options);
}
- public function getName(): string
+ public function getType(): string
{
- return $this->name;
+ return 'test';
}
- /**
- * Returns the callable to execute for this test.
- *
- * @return callable|null
- */
- public function getCallable()
+ public function needsCharset(): bool
{
- return $this->callable;
+ return false;
}
- public function getNodeClass(): string
+ public function needsEnvironment(): bool
{
- return $this->options['node_class'];
+ return false;
}
- public function setArguments(array $arguments): void
+ public function needsContext(): bool
{
- $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'];
+ return false;
}
public function hasOneMandatoryArgument(): bool
{
return (bool) $this->options['one_mandatory_argument'];
}
+
+ public function getMinimalNumberOfRequiredArguments(): int
+ {
+ return parent::getMinimalNumberOfRequiredArguments() + 1;
+ }
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/CallableArgumentsExtractor.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/CallableArgumentsExtractor.php
new file mode 100644
index 0000000..8811ca9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/CallableArgumentsExtractor.php
@@ -0,0 +1,204 @@
+<?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\Error\SyntaxError;
+use Twig\Node\Expression\ArrayExpression;
+use Twig\Node\Expression\ConstantExpression;
+use Twig\Node\Expression\VariadicExpression;
+use Twig\Node\Node;
+use Twig\TwigCallableInterface;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class CallableArgumentsExtractor
+{
+ private ReflectionCallable $rc;
+
+ public function __construct(
+ private Node $node,
+ private TwigCallableInterface $twigCallable,
+ ) {
+ $this->rc = new ReflectionCallable($twigCallable);
+ }
+
+ /**
+ * @return array<Node>
+ */
+ public function extractArguments(Node $arguments): array
+ {
+ $extractedArguments = [];
+ $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".', $this->twigCallable->getType(), $this->twigCallable->getName()), $this->node->getTemplateLine(), $this->node->getSourceContext());
+ }
+
+ $extractedArguments[$name] = $node;
+ }
+
+ if (!$named && !$this->twigCallable->isVariadic()) {
+ $min = $this->twigCallable->getMinimalNumberOfRequiredArguments();
+ if (\count($extractedArguments) < $this->rc->getReflector()->getNumberOfRequiredParameters() - $min) {
+ throw new SyntaxError(\sprintf('Value for argument "%s" is required for %s "%s".', $this->rc->getReflector()->getParameters()[$min + \count($extractedArguments)]->getName(), $this->twigCallable->getType(), $this->twigCallable->getName()), $this->node->getTemplateLine(), $this->node->getSourceContext());
+ }
+
+ return $extractedArguments;
+ }
+
+ if (!$callable = $this->twigCallable->getCallable()) {
+ if ($named) {
+ throw new SyntaxError(\sprintf('Named arguments are not supported for %s "%s".', $this->twigCallable->getType(), $this->twigCallable->getName()));
+ }
+
+ throw new SyntaxError(\sprintf('Arbitrary positional arguments are not supported for %s "%s".', $this->twigCallable->getType(), $this->twigCallable->getName()));
+ }
+
+ [$callableParameters, $isPhpVariadic] = $this->getCallableParameters();
+ $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, $extractedArguments)) {
+ if (\array_key_exists($pos, $extractedArguments)) {
+ throw new SyntaxError(\sprintf('Argument "%s" is defined twice for %s "%s".', $name, $this->twigCallable->getType(), $this->twigCallable->getName()), $this->node->getTemplateLine(), $this->node->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, $this->twigCallable->getType(), $this->twigCallable->getName(), implode(', ', $names), \count($missingArguments) > 1 ? 's' : '', implode('", "', $missingArguments)
+ ), $this->node->getTemplateLine(), $this->node->getSourceContext());
+ }
+
+ $arguments = array_merge($arguments, $optionalArguments);
+ $arguments[] = $extractedArguments[$name];
+ unset($extractedArguments[$name]);
+ $optionalArguments = [];
+ } elseif (\array_key_exists($pos, $extractedArguments)) {
+ $arguments = array_merge($arguments, $optionalArguments);
+ $arguments[] = $extractedArguments[$pos];
+ unset($extractedArguments[$pos]);
+ $optionalArguments = [];
+ ++$pos;
+ } elseif ($callableParameter->isDefaultValueAvailable()) {
+ $optionalArguments[] = new ConstantExpression($callableParameter->getDefaultValue(), $this->node->getTemplateLine());
+ } elseif ($callableParameter->isOptional()) {
+ if (!$extractedArguments) {
+ break;
+ }
+
+ $missingArguments[] = $name;
+ } else {
+ throw new SyntaxError(\sprintf('Value for argument "%s" is required for %s "%s".', $name, $this->twigCallable->getType(), $this->twigCallable->getName()), $this->node->getTemplateLine(), $this->node->getSourceContext());
+ }
+ }
+
+ if ($this->twigCallable->isVariadic()) {
+ $arbitraryArguments = $isPhpVariadic ? new VariadicExpression([], $this->node->getTemplateLine()) : new ArrayExpression([], $this->node->getTemplateLine());
+ foreach ($extractedArguments as $key => $value) {
+ if (\is_int($key)) {
+ $arbitraryArguments->addElement($value);
+ } else {
+ $arbitraryArguments->addElement($value, new ConstantExpression($key, $this->node->getTemplateLine()));
+ }
+ unset($extractedArguments[$key]);
+ }
+
+ if ($arbitraryArguments->count()) {
+ $arguments = array_merge($arguments, $optionalArguments);
+ $arguments[] = $arbitraryArguments;
+ }
+ }
+
+ if ($extractedArguments) {
+ $unknownArgument = null;
+ foreach ($extractedArguments as $extractedArgument) {
+ if ($extractedArgument instanceof Node) {
+ $unknownArgument = $extractedArgument;
+ break;
+ }
+ }
+
+ throw new SyntaxError(
+ \sprintf(
+ 'Unknown argument%s "%s" for %s "%s(%s)".',
+ \count($extractedArguments) > 1 ? 's' : '', implode('", "', array_keys($extractedArguments)), $this->twigCallable->getType(), $this->twigCallable->getName(), implode(', ', $names)
+ ),
+ $unknownArgument ? $unknownArgument->getTemplateLine() : $this->node->getTemplateLine(),
+ $unknownArgument ? $unknownArgument->getSourceContext() : $this->node->getSourceContext()
+ );
+ }
+
+ return $arguments;
+ }
+
+ private 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(): array
+ {
+ $parameters = $this->rc->getReflector()->getParameters();
+ if ($this->node->hasNode('node')) {
+ array_shift($parameters);
+ }
+ if ($this->twigCallable->needsCharset()) {
+ array_shift($parameters);
+ }
+ if ($this->twigCallable->needsEnvironment()) {
+ array_shift($parameters);
+ }
+ if ($this->twigCallable->needsContext()) {
+ array_shift($parameters);
+ }
+ foreach ($this->twigCallable->getArguments() as $argument) {
+ array_shift($parameters);
+ }
+
+ $isPhpVariadic = false;
+ if ($this->twigCallable->isVariadic()) {
+ $argument = end($parameters);
+ $isArray = $argument && $argument->hasType() && $argument->getType() instanceof \ReflectionNamedType && 'array' === $argument->getType()->getName();
+ if ($isArray && $argument->isDefaultValueAvailable() && [] === $argument->getDefaultValue()) {
+ array_pop($parameters);
+ } elseif ($argument && $argument->isVariadic()) {
+ array_pop($parameters);
+ $isPhpVariadic = true;
+ } else {
+ throw new SyntaxError(\sprintf('The last parameter of "%s" for %s "%s" must be an array with default value, eg. "array $arg = []".', $this->rc->getName(), $this->twigCallable->getType(), $this->twigCallable->getName()));
+ }
+ }
+
+ return [$parameters, $isPhpVariadic];
+ }
+}
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
index 378b666..0ea26ed 100644
--- 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
@@ -20,11 +20,9 @@
*/
final class DeprecationCollector
{
- private $twig;
-
- public function __construct(Environment $twig)
- {
- $this->twig = $twig;
+ public function __construct(
+ private Environment $twig,
+ ) {
}
/**
@@ -60,6 +58,8 @@
if (\E_USER_DEPRECATED === $type) {
$deprecations[] = $msg;
}
+
+ return false;
});
foreach ($iterator as $name => $contents) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/ReflectionCallable.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/ReflectionCallable.php
new file mode 100644
index 0000000..16734d9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/twig/twig/src/Util/ReflectionCallable.php
@@ -0,0 +1,92 @@
+<?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\TwigCallableInterface;
+
+/**
+ * @author Fabien Potencier <fabien@symfony.com>
+ *
+ * @internal
+ */
+final class ReflectionCallable
+{
+ private $reflector;
+ private $callable;
+ private $name;
+
+ public function __construct(
+ TwigCallableInterface $twigCallable,
+ ) {
+ $callable = $twigCallable->getCallable();
+ if (\is_string($callable) && false !== $pos = strpos($callable, '::')) {
+ $callable = [substr($callable, 0, $pos), substr($callable, 2 + $pos)];
+ }
+
+ if (\is_array($callable) && method_exists($callable[0], $callable[1])) {
+ $this->reflector = $r = new \ReflectionMethod($callable[0], $callable[1]);
+ $this->callable = $callable;
+ $this->name = $r->class.'::'.$r->name;
+
+ return;
+ }
+
+ $checkVisibility = $callable instanceof \Closure;
+ try {
+ $closure = \Closure::fromCallable($callable);
+ } catch (\TypeError $e) {
+ throw new \LogicException(\sprintf('Callback for %s "%s" is not callable in the current scope.', $twigCallable->getType(), $twigCallable->getName()), 0, $e);
+ }
+ $this->reflector = $r = new \ReflectionFunction($closure);
+
+ if (str_contains($r->name, '{closure')) {
+ $this->callable = $callable;
+ $this->name = 'Closure';
+
+ return;
+ }
+
+ if ($object = $r->getClosureThis()) {
+ $callable = [$object, $r->name];
+ $this->name = get_debug_type($object).'::'.$r->name;
+ } elseif (\PHP_VERSION_ID >= 80111 && $class = $r->getClosureCalledClass()) {
+ $callable = [$class->name, $r->name];
+ $this->name = $class->name.'::'.$r->name;
+ } elseif (\PHP_VERSION_ID < 80111 && $class = $r->getClosureScopeClass()) {
+ $callable = [\is_array($callable) ? $callable[0] : $class->name, $r->name];
+ $this->name = (\is_array($callable) ? $callable[0] : $class->name).'::'.$r->name;
+ } else {
+ $callable = $this->name = $r->name;
+ }
+
+ if ($checkVisibility && \is_array($callable) && method_exists(...$callable) && !(new \ReflectionMethod(...$callable))->isPublic()) {
+ $callable = $r->getClosure();
+ }
+
+ $this->callable = $callable;
+ }
+
+ public function getReflector(): \ReflectionFunctionAbstract
+ {
+ return $this->reflector;
+ }
+
+ public function getCallable()
+ {
+ return $this->callable;
+ }
+
+ public function getName(): string
+ {
+ return $this->name;
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/.gitignore b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/.gitignore
deleted file mode 100644
index 0d968f1..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/.gitignore
+++ /dev/null
@@ -1,7 +0,0 @@
-composer.lock
-vendor/
-.*.swp
-php-u2flib-server-*.tar.gz
-php-u2flib-server-*.tar.gz.sig
-apidocs/
-build/
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/.travis.yml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/.travis.yml
deleted file mode 100644
index beade3b..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/.travis.yml
+++ /dev/null
@@ -1,23 +0,0 @@
-language: php
-sudo: false
-php:
- - 7.0
- - 7.1
- - 7.2
- - hhvm
-matrix:
- include:
- - php: 5.6
- env: COVERALLS=true
- allow_failures:
- - php: hhvm
-
-before_script:
- - composer install
-
-script:
- - ./vendor/bin/psalm
- - ./vendor/phpunit/phpunit/phpunit -c phpunit.xml
-
-after_success:
- - test -z $COVERALLS || (composer require satooshi/php-coveralls && vendor/bin/coveralls -v)
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/BLURB b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/BLURB
deleted file mode 100644
index c579742..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/BLURB
+++ /dev/null
@@ -1,9 +0,0 @@
-Author: Yubico
-Basename: php-u2flib-server
-Homepage: https://developers.yubico.com/php-u2flib-server
-License: BSD-2-Clause
-Name: Native U2F library in PHP
-Project: php-u2flib-server
-Summary: Native U2F library in PHP
-Yubico-Category: U2F projects
-Travis: https://travis-ci.org/Yubico/php-u2flib-server
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/COPYING b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/COPYING
deleted file mode 100644
index 427c917..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/COPYING
+++ /dev/null
@@ -1,26 +0,0 @@
-Copyright (c) 2014 Yubico AB
-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.
-
-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/yubico/u2flib-server/NEWS b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/NEWS
deleted file mode 100644
index 496175e..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/NEWS
+++ /dev/null
@@ -1,34 +0,0 @@
-php-u2flib-server NEWS -- History of user-visible changes.
-
-* Version 1.0.2 (released 2018-09-07)
- ** Additional error checks.
- ** Add user presence check.
- ** Support single files for attestation root.
- ** Type safety, CSPRNG, avoid chr().
-
-* Version 1.0.1 (released 2017-05-09)
- ** Move examples to phps so they don't execute by default
- ** Use common challenge for multiple registrations
-
-* Version 1.0.0 (released 2016-02-19)
- ** Give an early error on openssl < 1.0
- ** Support devices with initial counter 0
- ** Fixes to examples
- ** Handle errorCode: 0 correctly
-
-* Version 0.1.0 (released 2015-03-03)
- ** Use openssl for all crypto instead of third party extensions.
- ** Properly check the request challenge on authenticate.
- ** Switch from returning error codes to throwing exceptions.
- ** Stop recommending composer for installation.
-
-* Version 0.0.2 (released 2014-10-24)
- ** Refactor the API to return objects instead of encoded objects.
- ** Add a second example that uses PDO to store registrations.
- ** Add documentation to the API.
- ** Check that randomness returned is good.
- ** Drop the unneeded mcrypt extension.
- ** More tests.
-
-* Version 0.0.1 (released 2014-10-16)
- ** Initial release.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/README b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/README
deleted file mode 100644
index 0116a27..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/README
+++ /dev/null
@@ -1,34 +0,0 @@
-php-u2flib-server
------------------
-
-image:https://travis-ci.org/Yubico/php-u2flib-server.svg?branch=master["Build Status", link="https://travis-ci.org/Yubico/php-u2flib-server"]
-image:https://coveralls.io/repos/Yubico/php-u2flib-server/badge.svg?branch=master&service=github["Coverage", link="https://coveralls.io/github/Yubico/php-u2flib-server?branch=master"]
-image:https://scrutinizer-ci.com/g/Yubico/php-u2flib-server/badges/quality-score.png?b=master["Scrutinizer Code Quality", link="https://scrutinizer-ci.com/g/Yubico/php-u2flib-server/?branch=master"]
-
-=== Introduction ===
-
-Serverside U2F library for PHP. Provides functionality for registering
-tokens and authentication with said tokens.
-
-To read more about U2F and how to use a U2F library, visit
-link:http://developers.yubico.com/U2F[developers.yubico.com/U2F].
-
-=== License ===
-
-The project is licensed under a BSD license. See the file COPYING for
-exact wording. For any copyright year range specified as YYYY-ZZZZ in
-this package note that the range specifies every single year in that
-closed interval.
-
-=== Dependencies ===
-
-The only dependency is the openssl extension to PHP that has to be enabled.
-
-A composer.json is included in the distribution to make things simpler for
-other project using composer.
-
-=== Tests ===
-
-To run the test suite link:https://phpunit.de[PHPUnit] is required. To run it, type:
-
- $ phpunit
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/README.adoc b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/README.adoc
deleted file mode 120000
index 100b938..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/README.adoc
+++ /dev/null
@@ -1 +0,0 @@
-README
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/apigen.neon b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/apigen.neon
deleted file mode 100644
index bbb7071..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/apigen.neon
+++ /dev/null
@@ -1,13 +0,0 @@
-destination: apidocs
-
-source:
- - src/u2flib_server
-
-exclude:
- - "*/tests/*"
-
-groups: none
-
-tree: false
-
-title: php-u2flib-server API
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/composer.json b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/composer.json
deleted file mode 100644
index 3f2d9ea..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/composer.json
+++ /dev/null
@@ -1,18 +0,0 @@
-{
- "name":"yubico/u2flib-server",
- "description":"Library for U2F implementation",
- "homepage":"https://developers.yubico.com/php-u2flib-server",
- "license":"BSD-2-Clause",
- "require": {
- "ext-openssl":"*",
- "paragonie/random_compat": ">= 1",
- "php": ">=5.6"
- },
- "autoload": {
- "classmap": ["src/"]
- },
- "require-dev": {
- "phpunit/phpunit": "~5.7",
- "vimeo/psalm": "^0|^1|^2"
- }
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/do-source-release.sh b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/do-source-release.sh
deleted file mode 100755
index 7e50173..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/do-source-release.sh
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/bin/sh
-
-set -e
-
-VERSION=$1
-PGP_KEYID=$2
-
-if [ "x$PGP_KEYID" = "x" ]; then
- echo "try with $0 VERSION PGP_KEYID"
- echo "example: $0 0.0.1 B2168C0A"
- exit
-fi
-
-if ! head -3 NEWS | grep -q "Version $VERSION .released `date -I`"; then
- echo "You need to update date/version in NEWS"
- exit
-fi
-
-if [ "x$YUBICO_GITHUB_REPO" = "x" ]; then
- echo "you need to define YUBICO_GITHUB_REPO"
- exit
-fi
-
-releasename=php-u2flib-server-${VERSION}
-
-git push
-git tag -u ${PGP_KEYID} -m $VERSION $VERSION
-git push --tags
-tmpdir=`mktemp -d /tmp/release.XXXXXX`
-releasedir=${tmpdir}/${releasename}
-mkdir -p $releasedir
-git archive $VERSION --format=tar | tar -xC $releasedir
-git2cl > $releasedir/ChangeLog
-cd $releasedir
-apigen generate
-cd -
-tar -cz --directory=$tmpdir --file=${releasename}.tar.gz $releasename
-gpg --detach-sign --default-key $PGP_KEYID ${releasename}.tar.gz
-$YUBICO_GITHUB_REPO/publish php-u2flib-server $VERSION ${releasename}.tar.gz*
-rm -rf $tmpdir
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/assets/u2f-api.js b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/assets/u2f-api.js
deleted file mode 100644
index 0f06f50..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/assets/u2f-api.js
+++ /dev/null
@@ -1,651 +0,0 @@
-// Copyright 2014-2015 Google Inc. All rights reserved.
-//
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file or at
-// https://developers.google.com/open-source/licenses/bsd
-
-/**
- * @fileoverview The U2F api.
- */
-
-'use strict';
-
-/** Namespace for the U2F api.
- * @type {Object}
- */
-var u2f = u2f || {};
-
-/**
- * The U2F extension id
- * @type {string}
- * @const
- */
-u2f.EXTENSION_ID = 'kmendfapggjehodndflmmgagdbamhnfd';
-
-/**
- * Message types for messsages to/from the extension
- * @const
- * @enum {string}
- */
-u2f.MessageTypes = {
- 'U2F_REGISTER_REQUEST': 'u2f_register_request',
- 'U2F_SIGN_REQUEST': 'u2f_sign_request',
- 'U2F_REGISTER_RESPONSE': 'u2f_register_response',
- 'U2F_SIGN_RESPONSE': 'u2f_sign_response'
-};
-
-/**
- * Response status codes
- * @const
- * @enum {number}
- */
-u2f.ErrorCodes = {
- 'OK': 0,
- 'OTHER_ERROR': 1,
- 'BAD_REQUEST': 2,
- 'CONFIGURATION_UNSUPPORTED': 3,
- 'DEVICE_INELIGIBLE': 4,
- 'TIMEOUT': 5
-};
-
-/**
- * A message type for registration requests
- * @typedef {{
- * type: u2f.MessageTypes,
- * signRequests: Array<u2f.SignRequest>,
- * registerRequests: ?Array<u2f.RegisterRequest>,
- * timeoutSeconds: ?number,
- * requestId: ?number
- * }}
- */
-u2f.Request;
-
-/**
- * A message for registration responses
- * @typedef {{
- * type: u2f.MessageTypes,
- * responseData: (u2f.Error | u2f.RegisterResponse | u2f.SignResponse),
- * requestId: ?number
- * }}
- */
-u2f.Response;
-
-/**
- * An error object for responses
- * @typedef {{
- * errorCode: u2f.ErrorCodes,
- * errorMessage: ?string
- * }}
- */
-u2f.Error;
-
-/**
- * Data object for a single sign request.
- * @typedef {{
- * version: string,
- * challenge: string,
- * keyHandle: string,
- * appId: string
- * }}
- */
-u2f.SignRequest;
-
-/**
- * Data object for a sign response.
- * @typedef {{
- * keyHandle: string,
- * signatureData: string,
- * clientData: string
- * }}
- */
-u2f.SignResponse;
-
-/**
- * Data object for a registration request.
- * @typedef {{
- * version: string,
- * challenge: string,
- * appId: string
- * }}
- */
-u2f.RegisterRequest;
-
-/**
- * Data object for a registration response.
- * @typedef {{
- * registrationData: string,
- * clientData: string
- * }}
- */
-u2f.RegisterResponse;
-
-
-// Low level MessagePort API support
-
-/**
- * Sets up a MessagePort to the U2F extension using the
- * available mechanisms.
- * @param {function((MessagePort|u2f.WrappedChromeRuntimePort_))} callback
- */
-u2f.getMessagePort = function(callback) {
- if (typeof chrome != 'undefined' && chrome.runtime) {
- // The actual message here does not matter, but we need to get a reply
- // for the callback to run. Thus, send an empty signature request
- // in order to get a failure response.
- var msg = {
- type: u2f.MessageTypes.U2F_SIGN_REQUEST,
- signRequests: []
- };
- chrome.runtime.sendMessage(u2f.EXTENSION_ID, msg, function() {
- if (!chrome.runtime.lastError) {
- // We are on a whitelisted origin and can talk directly
- // with the extension.
- u2f.getChromeRuntimePort_(callback);
- } else {
- // chrome.runtime was available, but we couldn't message
- // the extension directly, use iframe
- u2f.getIframePort_(callback);
- }
- });
- } else if (u2f.isAndroidChrome_()) {
- u2f.getAuthenticatorPort_(callback);
- } else {
- // chrome.runtime was not available at all, which is normal
- // when this origin doesn't have access to any extensions.
- u2f.getIframePort_(callback);
- }
-};
-
-/**
- * Detect chrome running on android based on the browser's useragent.
- * @private
- */
-u2f.isAndroidChrome_ = function() {
- var userAgent = navigator.userAgent;
- return userAgent.indexOf('Chrome') != -1 &&
- userAgent.indexOf('Android') != -1;
-};
-
-/**
- * Connects directly to the extension via chrome.runtime.connect
- * @param {function(u2f.WrappedChromeRuntimePort_)} callback
- * @private
- */
-u2f.getChromeRuntimePort_ = function(callback) {
- var port = chrome.runtime.connect(u2f.EXTENSION_ID,
- {'includeTlsChannelId': true});
- setTimeout(function() {
- callback(new u2f.WrappedChromeRuntimePort_(port));
- }, 0);
-};
-
-/**
- * Return a 'port' abstraction to the Authenticator app.
- * @param {function(u2f.WrappedAuthenticatorPort_)} callback
- * @private
- */
-u2f.getAuthenticatorPort_ = function(callback) {
- setTimeout(function() {
- callback(new u2f.WrappedAuthenticatorPort_());
- }, 0);
-};
-
-/**
- * A wrapper for chrome.runtime.Port that is compatible with MessagePort.
- * @param {Port} port
- * @constructor
- * @private
- */
-u2f.WrappedChromeRuntimePort_ = function(port) {
- this.port_ = port;
-};
-
-/**
- * Format a return a sign request.
- * @param {Array<u2f.SignRequest>} signRequests
- * @param {number} timeoutSeconds
- * @param {number} reqId
- * @return {Object}
- */
-u2f.WrappedChromeRuntimePort_.prototype.formatSignRequest_ =
- function(signRequests, timeoutSeconds, reqId) {
- return {
- type: u2f.MessageTypes.U2F_SIGN_REQUEST,
- signRequests: signRequests,
- timeoutSeconds: timeoutSeconds,
- requestId: reqId
- };
- };
-
-/**
- * Format a return a register request.
- * @param {Array<u2f.SignRequest>} signRequests
- * @param {Array<u2f.RegisterRequest>} signRequests
- * @param {number} timeoutSeconds
- * @param {number} reqId
- * @return {Object}
- */
-u2f.WrappedChromeRuntimePort_.prototype.formatRegisterRequest_ =
- function(signRequests, registerRequests, timeoutSeconds, reqId) {
- return {
- type: u2f.MessageTypes.U2F_REGISTER_REQUEST,
- signRequests: signRequests,
- registerRequests: registerRequests,
- timeoutSeconds: timeoutSeconds,
- requestId: reqId
- };
- };
-
-/**
- * Posts a message on the underlying channel.
- * @param {Object} message
- */
-u2f.WrappedChromeRuntimePort_.prototype.postMessage = function(message) {
- this.port_.postMessage(message);
-};
-
-/**
- * Emulates the HTML 5 addEventListener interface. Works only for the
- * onmessage event, which is hooked up to the chrome.runtime.Port.onMessage.
- * @param {string} eventName
- * @param {function({data: Object})} handler
- */
-u2f.WrappedChromeRuntimePort_.prototype.addEventListener =
- function(eventName, handler) {
- var name = eventName.toLowerCase();
- if (name == 'message' || name == 'onmessage') {
- this.port_.onMessage.addListener(function(message) {
- // Emulate a minimal MessageEvent object
- handler({'data': message});
- });
- } else {
- console.error('WrappedChromeRuntimePort only supports onMessage');
- }
- };
-
-/**
- * Wrap the Authenticator app with a MessagePort interface.
- * @constructor
- * @private
- */
-u2f.WrappedAuthenticatorPort_ = function() {
- this.requestId_ = -1;
- this.requestObject_ = null;
-}
-
-/**
- * Launch the Authenticator intent.
- * @param {Object} message
- */
-u2f.WrappedAuthenticatorPort_.prototype.postMessage = function(message) {
- var intentLocation = /** @type {string} */ (message);
- document.location = intentLocation;
-};
-
-/**
- * Emulates the HTML 5 addEventListener interface.
- * @param {string} eventName
- * @param {function({data: Object})} handler
- */
-u2f.WrappedAuthenticatorPort_.prototype.addEventListener =
- function(eventName, handler) {
- var name = eventName.toLowerCase();
- if (name == 'message') {
- var self = this;
- /* Register a callback to that executes when
- * chrome injects the response. */
- window.addEventListener(
- 'message', self.onRequestUpdate_.bind(self, handler), false);
- } else {
- console.error('WrappedAuthenticatorPort only supports message');
- }
- };
-
-/**
- * Callback invoked when a response is received from the Authenticator.
- * @param function({data: Object}) callback
- * @param {Object} message message Object
- */
-u2f.WrappedAuthenticatorPort_.prototype.onRequestUpdate_ =
- function(callback, message) {
- var messageObject = JSON.parse(message.data);
- var intentUrl = messageObject['intentURL'];
-
- var errorCode = messageObject['errorCode'];
- var responseObject = null;
- if (messageObject.hasOwnProperty('data')) {
- responseObject = /** @type {Object} */ (
- JSON.parse(messageObject['data']));
- responseObject['requestId'] = this.requestId_;
- }
-
- /* Sign responses from the authenticator do not conform to U2F,
- * convert to U2F here. */
- responseObject = this.doResponseFixups_(responseObject);
- callback({'data': responseObject});
- };
-
-/**
- * Fixup the response provided by the Authenticator to conform with
- * the U2F spec.
- * @param {Object} responseData
- * @return {Object} the U2F compliant response object
- */
-u2f.WrappedAuthenticatorPort_.prototype.doResponseFixups_ =
- function(responseObject) {
- if (responseObject.hasOwnProperty('responseData')) {
- return responseObject;
- } else if (this.requestObject_['type'] != u2f.MessageTypes.U2F_SIGN_REQUEST) {
- // Only sign responses require fixups. If this is not a response
- // to a sign request, then an internal error has occurred.
- return {
- 'type': u2f.MessageTypes.U2F_REGISTER_RESPONSE,
- 'responseData': {
- 'errorCode': u2f.ErrorCodes.OTHER_ERROR,
- 'errorMessage': 'Internal error: invalid response from Authenticator'
- }
- };
- }
-
- /* Non-conformant sign response, do fixups. */
- var encodedChallengeObject = responseObject['challenge'];
- if (typeof encodedChallengeObject !== 'undefined') {
- var challengeObject = JSON.parse(atob(encodedChallengeObject));
- var serverChallenge = challengeObject['challenge'];
- var challengesList = this.requestObject_['signData'];
- var requestChallengeObject = null;
- for (var i = 0; i < challengesList.length; i++) {
- var challengeObject = challengesList[i];
- if (challengeObject['keyHandle'] == responseObject['keyHandle']) {
- requestChallengeObject = challengeObject;
- break;
- }
- }
- }
- var responseData = {
- 'errorCode': responseObject['resultCode'],
- 'keyHandle': responseObject['keyHandle'],
- 'signatureData': responseObject['signature'],
- 'clientData': encodedChallengeObject
- };
- return {
- 'type': u2f.MessageTypes.U2F_SIGN_RESPONSE,
- 'responseData': responseData,
- 'requestId': responseObject['requestId']
- }
- };
-
-/**
- * Base URL for intents to Authenticator.
- * @const
- * @private
- */
-u2f.WrappedAuthenticatorPort_.INTENT_URL_BASE_ =
- 'intent:#Intent;action=com.google.android.apps.authenticator.AUTHENTICATE';
-
-/**
- * Format a return a sign request.
- * @param {Array<u2f.SignRequest>} signRequests
- * @param {number} timeoutSeconds (ignored for now)
- * @param {number} reqId
- * @return {string}
- */
-u2f.WrappedAuthenticatorPort_.prototype.formatSignRequest_ =
- function(signRequests, timeoutSeconds, reqId) {
- if (!signRequests || signRequests.length == 0) {
- return null;
- }
- /* TODO(fixme): stash away requestId, as the authenticator app does
- * not return it for sign responses. */
- this.requestId_ = reqId;
- /* TODO(fixme): stash away the signRequests, to deal with the legacy
- * response format returned by the Authenticator app. */
- this.requestObject_ = {
- 'type': u2f.MessageTypes.U2F_SIGN_REQUEST,
- 'signData': signRequests,
- 'requestId': reqId,
- 'timeout': timeoutSeconds
- };
-
- var appId = signRequests[0]['appId'];
- var intentUrl =
- u2f.WrappedAuthenticatorPort_.INTENT_URL_BASE_ +
- ';S.appId=' + encodeURIComponent(appId) +
- ';S.eventId=' + reqId +
- ';S.challenges=' +
- encodeURIComponent(
- JSON.stringify(this.getBrowserDataList_(signRequests))) + ';end';
- return intentUrl;
- };
-
-/**
- * Get the browser data objects from the challenge list
- * @param {Array} challenges list of challenges
- * @return {Array} list of browser data objects
- * @private
- */
-u2f.WrappedAuthenticatorPort_
- .prototype.getBrowserDataList_ = function(challenges) {
- return challenges
- .map(function(challenge) {
- var browserData = {
- 'typ': 'navigator.id.getAssertion',
- 'challenge': challenge['challenge']
- };
- var challengeObject = {
- 'challenge' : browserData,
- 'keyHandle' : challenge['keyHandle']
- };
- return challengeObject;
- });
-};
-
-/**
- * Format a return a register request.
- * @param {Array<u2f.SignRequest>} signRequests
- * @param {Array<u2f.RegisterRequest>} enrollChallenges
- * @param {number} timeoutSeconds (ignored for now)
- * @param {number} reqId
- * @return {Object}
- */
-u2f.WrappedAuthenticatorPort_.prototype.formatRegisterRequest_ =
- function(signRequests, enrollChallenges, timeoutSeconds, reqId) {
- if (!enrollChallenges || enrollChallenges.length == 0) {
- return null;
- }
- // Assume the appId is the same for all enroll challenges.
- var appId = enrollChallenges[0]['appId'];
- var registerRequests = [];
- for (var i = 0; i < enrollChallenges.length; i++) {
- var registerRequest = {
- 'challenge': enrollChallenges[i]['challenge'],
- 'version': enrollChallenges[i]['version']
- };
- if (enrollChallenges[i]['appId'] != appId) {
- // Only include the appId when it differs from the first appId.
- registerRequest['appId'] = enrollChallenges[i]['appId'];
- }
- registerRequests.push(registerRequest);
- }
- var registeredKeys = [];
- if (signRequests) {
- for (i = 0; i < signRequests.length; i++) {
- var key = {
- 'keyHandle': signRequests[i]['keyHandle'],
- 'version': signRequests[i]['version']
- };
- // Only include the appId when it differs from the appId that's
- // being registered now.
- if (signRequests[i]['appId'] != appId) {
- key['appId'] = signRequests[i]['appId'];
- }
- registeredKeys.push(key);
- }
- }
- var request = {
- 'type': u2f.MessageTypes.U2F_REGISTER_REQUEST,
- 'appId': appId,
- 'registerRequests': registerRequests,
- 'registeredKeys': registeredKeys,
- 'requestId': reqId,
- 'timeoutSeconds': timeoutSeconds
- };
- var intentUrl =
- u2f.WrappedAuthenticatorPort_.INTENT_URL_BASE_ +
- ';S.request=' + encodeURIComponent(JSON.stringify(request)) +
- ';end';
- /* TODO(fixme): stash away requestId, this is is not necessary for
- * register requests, but here to keep parity with sign.
- */
- this.requestId_ = reqId;
- return intentUrl;
- };
-
-
-/**
- * Sets up an embedded trampoline iframe, sourced from the extension.
- * @param {function(MessagePort)} callback
- * @private
- */
-u2f.getIframePort_ = function(callback) {
- // Create the iframe
- var iframeOrigin = 'chrome-extension://' + u2f.EXTENSION_ID;
- var iframe = document.createElement('iframe');
- iframe.src = iframeOrigin + '/u2f-comms.html';
- iframe.setAttribute('style', 'display:none');
- document.body.appendChild(iframe);
-
- var channel = new MessageChannel();
- var ready = function(message) {
- if (message.data == 'ready') {
- channel.port1.removeEventListener('message', ready);
- callback(channel.port1);
- } else {
- console.error('First event on iframe port was not "ready"');
- }
- };
- channel.port1.addEventListener('message', ready);
- channel.port1.start();
-
- iframe.addEventListener('load', function() {
- // Deliver the port to the iframe and initialize
- iframe.contentWindow.postMessage('init', iframeOrigin, [channel.port2]);
- });
-};
-
-
-// High-level JS API
-
-/**
- * Default extension response timeout in seconds.
- * @const
- */
-u2f.EXTENSION_TIMEOUT_SEC = 30;
-
-/**
- * A singleton instance for a MessagePort to the extension.
- * @type {MessagePort|u2f.WrappedChromeRuntimePort_}
- * @private
- */
-u2f.port_ = null;
-
-/**
- * Callbacks waiting for a port
- * @type {Array<function((MessagePort|u2f.WrappedChromeRuntimePort_))>}
- * @private
- */
-u2f.waitingForPort_ = [];
-
-/**
- * A counter for requestIds.
- * @type {number}
- * @private
- */
-u2f.reqCounter_ = 0;
-
-/**
- * A map from requestIds to client callbacks
- * @type {Object.<number,(function((u2f.Error|u2f.RegisterResponse))
- * |function((u2f.Error|u2f.SignResponse)))>}
- * @private
- */
-u2f.callbackMap_ = {};
-
-/**
- * Creates or retrieves the MessagePort singleton to use.
- * @param {function((MessagePort|u2f.WrappedChromeRuntimePort_))} callback
- * @private
- */
-u2f.getPortSingleton_ = function(callback) {
- if (u2f.port_) {
- callback(u2f.port_);
- } else {
- if (u2f.waitingForPort_.length == 0) {
- u2f.getMessagePort(function(port) {
- u2f.port_ = port;
- u2f.port_.addEventListener('message',
- /** @type {function(Event)} */ (u2f.responseHandler_));
-
- // Careful, here be async callbacks. Maybe.
- while (u2f.waitingForPort_.length)
- u2f.waitingForPort_.shift()(u2f.port_);
- });
- }
- u2f.waitingForPort_.push(callback);
- }
-};
-
-/**
- * Handles response messages from the extension.
- * @param {MessageEvent.<u2f.Response>} message
- * @private
- */
-u2f.responseHandler_ = function(message) {
- var response = message.data;
- var reqId = response['requestId'];
- if (!reqId || !u2f.callbackMap_[reqId]) {
- console.error('Unknown or missing requestId in response.');
- return;
- }
- var cb = u2f.callbackMap_[reqId];
- delete u2f.callbackMap_[reqId];
- cb(response['responseData']);
-};
-
-/**
- * Dispatches an array of sign requests to available U2F tokens.
- * @param {Array<u2f.SignRequest>} signRequests
- * @param {function((u2f.Error|u2f.SignResponse))} callback
- * @param {number=} opt_timeoutSeconds
- */
-u2f.sign = function(signRequests, callback, opt_timeoutSeconds) {
- u2f.getPortSingleton_(function(port) {
- var reqId = ++u2f.reqCounter_;
- u2f.callbackMap_[reqId] = callback;
- var timeoutSeconds = (typeof opt_timeoutSeconds !== 'undefined' ?
- opt_timeoutSeconds : u2f.EXTENSION_TIMEOUT_SEC);
- var req = port.formatSignRequest_(signRequests, timeoutSeconds, reqId);
- port.postMessage(req);
- });
-};
-
-/**
- * Dispatches register requests to available U2F tokens. An array of sign
- * requests identifies already registered tokens.
- * @param {Array<u2f.RegisterRequest>} registerRequests
- * @param {Array<u2f.SignRequest>} signRequests
- * @param {function((u2f.Error|u2f.RegisterResponse))} callback
- * @param {number=} opt_timeoutSeconds
- */
-u2f.register = function(registerRequests, signRequests,
- callback, opt_timeoutSeconds) {
- u2f.getPortSingleton_(function(port) {
- var reqId = ++u2f.reqCounter_;
- u2f.callbackMap_[reqId] = callback;
- var timeoutSeconds = (typeof opt_timeoutSeconds !== 'undefined' ?
- opt_timeoutSeconds : u2f.EXTENSION_TIMEOUT_SEC);
- var req = port.formatRegisterRequest_(
- signRequests, registerRequests, timeoutSeconds, reqId);
- port.postMessage(req);
- });
-};
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/cli/u2f-server.phps b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/cli/u2f-server.phps
deleted file mode 100755
index 8acb66a..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/cli/u2f-server.phps
+++ /dev/null
@@ -1,83 +0,0 @@
-#!/usr/bin/php
-<?php
-
- /* Copyright (c) 2015 Yubico AB
- * 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.
- *
- * 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.
- */
-
-/**
- * This is a basic example of a u2f-server command line that can be used
- * with the u2f-host binary to perform regitrations and authentications.
- */
-
-require_once('../../src/u2flib_server/U2F.php');
-
-$options = getopt("rao:R:");
-$mode;
-$challenge;
-$response;
-$result;
-$regs;
-
-if(array_key_exists('r', $options)) {
- $mode = "register";
-} elseif(array_key_exists('a', $options)) {
- if(!array_key_exists('R', $options)) {
- print "a registration must be supplied with -R";
- exit(1);
- }
- $regs = json_decode('[' . $options['R'] . ']');
- $mode = "authenticate";
-} else {
- print "-r or -a must be used\n";
- exit(1);
-}
-if(!array_key_exists('o', $options)) {
- print "origin must be supplied with -o\n";
- exit(1);
-}
-
-$u2f = new u2flib_server\U2F($options['o']);
-
-if($mode === "register") {
- $challenge = $u2f->getRegisterData();
-} elseif($mode === "authenticate") {
- $challenge = $u2f->getAuthenticateData($regs);
-}
-
-print json_encode($challenge[0]) . "\n";
-$response = fgets(STDIN);
-
-if($mode === "register") {
- $result = $u2f->doRegister($challenge[0], json_decode($response));
-} elseif($mode === "authenticate") {
- $result = $u2f->doAuthenticate($challenge, $regs, json_decode($response));
-}
-
-print json_encode($result) . "\n";
-
-?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/localstorage/index.phps b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/localstorage/index.phps
deleted file mode 100644
index d840dd3..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/localstorage/index.phps
+++ /dev/null
@@ -1,186 +0,0 @@
-<?php
-/**
- * Copyright (c) 2014 Yubico AB
- * 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.
- *
- * 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.
- */
-
-/**
- * This is a minimal example of U2F registration and authentication.
- * The data that has to be stored between registration and authentication
- * is stored in browser localStorage, so there's nothing real-world
- * about this.
- */
-require_once('../../src/u2flib_server/U2F.php');
-$scheme = isset($_SERVER['HTTPS']) ? "https://" : "http://";
-$u2f = new u2flib_server\U2F($scheme . $_SERVER['HTTP_HOST']);
-?>
-<html>
-<head>
- <title>PHP U2F Demo</title>
-
- <script src="../assets/u2f-api.js"></script>
-
- <script>
- function addRegistration(reg) {
- var existing = localStorage.getItem('u2fregistration');
- var regobj = JSON.parse(reg);
- var data = null;
- if(existing) {
- data = JSON.parse(existing);
- if(Array.isArray(data)) {
- for (var i = 0; i < data.length; i++) {
- if(data[i].keyHandle === regobj.keyHandle) {
- data.splice(i,1);
- break;
- }
- }
- data.push(regobj);
- } else {
- data = null;
- }
- }
- if(data == null) {
- data = [regobj];
- }
- localStorage.setItem('u2fregistration', JSON.stringify(data));
- }
- <?php
- function fixupArray($data) {
- $ret = array();
- $decoded = json_decode($data);
- foreach ($decoded as $d) {
- $ret[] = json_encode($d);
- }
- return $ret;
- }
- if($_SERVER['REQUEST_METHOD'] === 'POST') {
- if(isset($_POST['startRegister'])) {
- $regs = json_decode($_POST['registrations']) ? : array();
- list($data, $reqs) = $u2f->getRegisterData($regs);
- echo "var request = " . json_encode($data) . ";\n";
- echo "var signs = " . json_encode($reqs) . ";\n";
- ?>
- setTimeout(function() {
- console.log("Register: ", request);
- u2f.register([request], signs, function(data) {
- var form = document.getElementById('form');
- var reg = document.getElementById('doRegister');
- var req = document.getElementById('request');
- console.log("Register callback", data);
- if(data.errorCode && data.errorCode != 0) {
- alert("registration failed with errror: " + data.errorCode);
- return;
- }
- reg.value=JSON.stringify(data);
- req.value=JSON.stringify(request);
- form.submit();
- });
- }, 1000);
- <?php
- } else if($_POST['doRegister']) {
- try {
- $data = $u2f->doRegister(json_decode($_POST['request']), json_decode($_POST['doRegister']));
- echo "var registration = '" . json_encode($data) . "';\n";
- ?>
- addRegistration(registration);
- alert("registration successful!");
- <?php
- } catch(u2flib_server\Error $e) {
- echo "alert('error:" . $e->getMessage() . "');\n";
- }
- } else if(isset($_POST['startAuthenticate'])) {
- $regs = json_decode($_POST['registrations']);
- $data = $u2f->getAuthenticateData($regs);
- echo "var registrations = " . $_POST['registrations'] . ";\n";
- echo "var request = " . json_encode($data) . ";\n";
- ?>
- setTimeout(function() {
- console.log("sign: ", request);
- u2f.sign(request, function(data) {
- var form = document.getElementById('form');
- var reg = document.getElementById('doAuthenticate');
- var req = document.getElementById('request');
- var regs = document.getElementById('registrations');
- console.log("Authenticate callback", data);
- reg.value=JSON.stringify(data);
- req.value=JSON.stringify(request);
- regs.value=JSON.stringify(registrations);
- form.submit();
- });
- }, 1000);
- <?php
- } else if($_POST['doAuthenticate']) {
- $reqs = json_decode($_POST['request']);
- $regs = json_decode($_POST['registrations']);
- try {
- $data = $u2f->doAuthenticate($reqs, $regs, json_decode($_POST['doAuthenticate']));
- echo "var registration = '" . json_encode($data) . "';\n";
- echo "addRegistration(registration);\n";
- echo "alert('Authentication successful, counter:" . $data->counter . "');\n";
- } catch(u2flib_server\Error $e) {
- echo "alert('error:" . $e->getMessage() . "');\n";
- }
- }
- }
- ?>
- </script>
-
-</head>
-<body>
-<form method="POST" id="form">
- <button name="startRegister" type="submit">Register</button>
- <input type="hidden" name="doRegister" id="doRegister"/>
- <button name="startAuthenticate" type="submit" id="startAuthenticate">Authenticate</button>
- <input type="hidden" name="doAuthenticate" id="doAuthenticate"/>
- <input type="hidden" name="request" id="request"/>
- <input type="hidden" name="registrations" id="registrations"/>
-</form>
-
-<p>
- <span id="registered">0</span> Authenticators currently registered.
-</p>
-
-<script>
- var reg = localStorage.getItem('u2fregistration');
- var auth = document.getElementById('startAuthenticate');
- if(reg == null) {
- auth.disabled = true;
- } else {
- var regs = document.getElementById('registrations');
- decoded = JSON.parse(reg);
- if(!Array.isArray(decoded)) {
- auth.disabled = true;
- } else {
- regs.value = reg;
- console.log("set the registrations to : ", reg);
- var regged = document.getElementById('registered');
- regged.innerHTML = decoded.length;
- }
- }
-</script>
-</body>
-</html>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/pdo/index.phps b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/pdo/index.phps
deleted file mode 100644
index c04d63e..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/examples/pdo/index.phps
+++ /dev/null
@@ -1,204 +0,0 @@
-<?php
-/**
- * Copyright (c) 2014 Yubico AB
- * 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.
- *
- * 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.
- */
-
-/**
- * This is a simple example using PDO and a sqlite database for storing
- * registrations. It supports multiple registrations associated with each user.
- */
-
-require_once('../../src/u2flib_server/U2F.php');
-
-$dbfile = '/var/tmp/u2f-pdo.sqlite';
-
-$pdo = new PDO("sqlite:$dbfile");
-$pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
-$pdo->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_OBJ);
-
-$pdo->exec("create table if not exists users (id integer primary key, name varchar(255))");
-$pdo->exec("create table if not exists registrations (id integer primary key, user_id integer, keyHandle varchar(255), publicKey varchar(255), certificate text, counter integer)");
-
-$scheme = isset($_SERVER['HTTPS']) ? "https://" : "http://";
-$u2f = new u2flib_server\U2F($scheme . $_SERVER['HTTP_HOST']);
-
-session_start();
-
-function createAndGetUser($name) {
- global $pdo;
- $sel = $pdo->prepare("select * from users where name = ?");
- $sel->execute(array($name));
- $user = $sel->fetch();
- if(!$user) {
- $ins = $pdo->prepare("insert into users (name) values(?)");
- $ins->execute(array($name));
- $sel->execute(array($name));
- $user = $sel->fetch();
- }
- return $user;
-}
-
-function getRegs($user_id) {
- global $pdo;
- $sel = $pdo->prepare("select * from registrations where user_id = ?");
- $sel->execute(array($user_id));
- return $sel->fetchAll();
-}
-
-function addReg($user_id, $reg) {
- global $pdo;
- $ins = $pdo->prepare("insert into registrations (user_id, keyHandle, publicKey, certificate, counter) values (?, ?, ?, ?, ?)");
- $ins->execute(array($user_id, $reg->keyHandle, $reg->publicKey, $reg->certificate, $reg->counter));
-}
-
-function updateReg($reg) {
- global $pdo;
- $upd = $pdo->prepare("update registrations set counter = ? where id = ?");
- $upd->execute(array($reg->counter, $reg->id));
-}
-
-?>
-
-<html>
-<head>
- <title>PHP U2F example</title>
-
- <script src="../assets/u2f-api.js"></script>
-
- <script>
- <?php
-
- if($_SERVER['REQUEST_METHOD'] === 'POST') {
- if(!$_POST['username']) {
- echo "alert('no username provided!');";
- } else if(!isset($_POST['action']) && !isset($_POST['register2']) && !isset($_POST['authenticate2'])) {
- echo "alert('no action provided!');";
- } else {
- $user = createAndGetUser($_POST['username']);
-
- if(isset($_POST['action'])) {
- switch($_POST['action']):
- case 'register':
- try {
- $data = $u2f->getRegisterData(getRegs($user->id));
-
- list($req,$sigs) = $data;
- $_SESSION['regReq'] = json_encode($req);
- echo "var req = " . json_encode($req) . ";";
- echo "var sigs = " . json_encode($sigs) . ";";
- echo "var username = '" . $user->name . "';";
- ?>
- setTimeout(function() {
- console.log("Register: ", req);
- u2f.register([req], sigs, function(data) {
- var form = document.getElementById('form');
- var reg = document.getElementById('register2');
- var user = document.getElementById('username');
- console.log("Register callback", data);
- if(data.errorCode && errorCode != 0) {
- alert("registration failed with errror: " + data.errorCode);
- return;
- }
- reg.value = JSON.stringify(data);
- user.value = username;
- form.submit();
- });
- }, 1000);
- <?php
- } catch( Exception $e ) {
- echo "alert('error: " . $e->getMessage() . "');";
- }
-
- break;
-
- case 'authenticate':
- try {
- $reqs = json_encode($u2f->getAuthenticateData(getRegs($user->id)));
-
- $_SESSION['authReq'] = $reqs;
- echo "var req = $reqs;";
- echo "var username = '" . $user->name . "';";
- ?>
- setTimeout(function() {
- console.log("sign: ", req);
- u2f.sign(req, function(data) {
- var form = document.getElementById('form');
- var auth = document.getElementById('authenticate2');
- var user = document.getElementById('username');
- console.log("Authenticate callback", data);
- auth.value=JSON.stringify(data);
- user.value = username;
- form.submit();
- });
- }, 1000);
- <?php
- } catch( Exception $e ) {
- echo "alert('error: " . $e->getMessage() . "');";
- }
-
- break;
-
- endswitch;
- } else if($_POST['register2']) {
- try {
- $reg = $u2f->doRegister(json_decode($_SESSION['regReq']), json_decode($_POST['register2']));
- addReg($user->id, $reg);
- } catch( Exception $e ) {
- echo "alert('error: " . $e->getMessage() . "');";
- } finally {
- $_SESSION['regReq'] = null;
- }
- } else if($_POST['authenticate2']) {
- try {
- $reg = $u2f->doAuthenticate(json_decode($_SESSION['authReq']), getRegs($user->id), json_decode($_POST['authenticate2']));
- updateReg($reg);
- echo "alert('success: " . $reg->counter . "');";
- } catch( Exception $e ) {
- echo "alert('error: " . $e->getMessage() . "');";
- } finally {
- $_SESSION['authReq'] = null;
- }
- }
- }
- }
- ?>
- </script>
-</head>
-<body>
-
-<form method="POST" id="form">
- username: <input name="username" id="username"/><br/>
- register: <input value="register" name="action" type="radio"/><br/>
- authenticate: <input value="authenticate" name="action" type="radio"/><br/>
- <input type="hidden" name="register2" id="register2"/>
- <input type="hidden" name="authenticate2" id="authenticate2"/>
- <button type="submit">Submit!</button>
-</form>
-
-</body>
-</html>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/phpunit.xml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/phpunit.xml
deleted file mode 100644
index fa6f08e..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/phpunit.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-<phpunit
- colors="true">
- <testsuite name="tests">
- <directory suffix="test.php">tests</directory>
- </testsuite>
- <logging>
- <log type="coverage-clover" target="build/logs/clover.xml"/>
- </logging>
-</phpunit>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/psalm.xml b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/psalm.xml
deleted file mode 100644
index 6b6234c..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/psalm.xml
+++ /dev/null
@@ -1,48 +0,0 @@
-<?xml version="1.0"?>
-<psalm
- totallyTyped="false"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns="https://getpsalm.org/schema/config"
- xsi:schemaLocation="https://getpsalm.org/schema/config file:///mnt/share/php-u2flib-server/vendor/vimeo/psalm/config.xsd"
->
- <projectFiles>
- <directory name="src" />
- <ignoreFiles>
- <directory name="vendor" />
- </ignoreFiles>
- </projectFiles>
-
- <issueHandlers>
- <LessSpecificReturnType errorLevel="info" />
-
- <!-- level 3 issues - slightly lazy code writing, but provably low false-negatives -->
-
- <DeprecatedMethod errorLevel="info" />
- <DeprecatedProperty errorLevel="info" />
- <DeprecatedClass errorLevel="info" />
- <DeprecatedInterface errorLevel="info" />
-
- <MissingClosureReturnType errorLevel="info" />
- <MissingReturnType errorLevel="info" />
- <MissingPropertyType errorLevel="info" />
- <InvalidDocblock errorLevel="info" />
- <MisplacedRequiredParam errorLevel="info" />
-
- <PropertyNotSetInConstructor errorLevel="info" />
- <MissingConstructor errorLevel="info" />
- <MissingClosureParamType errorLevel="info" />
- <MissingParamType errorLevel="info" />
-
- <RedundantCondition errorLevel="info" />
-
- <DocblockTypeContradiction errorLevel="suppress" />
- <RedundantConditionGivenDocblockType errorLevel="suppress" />
-
- <UnresolvableInclude errorLevel="info" />
-
- <RawObjectIteration errorLevel="info" />
-
- <!-- psalm seems to wrongly complain about this, set the errorLevel to info for now -->
- <UndefinedConstant errorLevel="info" />
- </issueHandlers>
-</psalm>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/src/u2flib_server/U2F.php b/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/src/u2flib_server/U2F.php
deleted file mode 100644
index 8583fff..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/lib/vendor/yubico/u2flib-server/src/u2flib_server/U2F.php
+++ /dev/null
@@ -1,563 +0,0 @@
-<?php
-/* Copyright (c) 2014 Yubico AB
- * 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.
- *
- * 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.
- */
-
-namespace u2flib_server;
-
-/** Constant for the version of the u2f protocol */
-const U2F_VERSION = "U2F_V2";
-
-/** Constant for the type value in registration clientData */
-const REQUEST_TYPE_REGISTER = "navigator.id.finishEnrollment";
-
-/** Constant for the type value in authentication clientData */
-const REQUEST_TYPE_AUTHENTICATE = "navigator.id.getAssertion";
-
-/** Error for the authentication message not matching any outstanding
- * authentication request */
-const ERR_NO_MATCHING_REQUEST = 1;
-
-/** Error for the authentication message not matching any registration */
-const ERR_NO_MATCHING_REGISTRATION = 2;
-
-/** Error for the signature on the authentication message not verifying with
- * the correct key */
-const ERR_AUTHENTICATION_FAILURE = 3;
-
-/** Error for the challenge in the registration message not matching the
- * registration challenge */
-const ERR_UNMATCHED_CHALLENGE = 4;
-
-/** Error for the attestation signature on the registration message not
- * verifying */
-const ERR_ATTESTATION_SIGNATURE = 5;
-
-/** Error for the attestation verification not verifying */
-const ERR_ATTESTATION_VERIFICATION = 6;
-
-/** Error for not getting good random from the system */
-const ERR_BAD_RANDOM = 7;
-
-/** Error when the counter is lower than expected */
-const ERR_COUNTER_TOO_LOW = 8;
-
-/** Error decoding public key */
-const ERR_PUBKEY_DECODE = 9;
-
-/** Error user-agent returned error */
-const ERR_BAD_UA_RETURNING = 10;
-
-/** Error old OpenSSL version */
-const ERR_OLD_OPENSSL = 11;
-
-/** Error for the origin not matching the appId */
-const ERR_NO_MATCHING_ORIGIN = 12;
-
-/** Error for the type in clientData being invalid */
-const ERR_BAD_TYPE = 13;
-
-/** Error for bad user presence byte value */
-const ERR_BAD_USER_PRESENCE = 14;
-
-/** @internal */
-const PUBKEY_LEN = 65;
-
-class U2F
-{
- /** @var string */
- private $appId;
-
- /** @var null|string */
- private $attestDir;
-
- /** @internal */
- private $FIXCERTS = array(
- '349bca1031f8c82c4ceca38b9cebf1a69df9fb3b94eed99eb3fb9aa3822d26e8',
- 'dd574527df608e47ae45fbba75a2afdd5c20fd94a02419381813cd55a2a3398f',
- '1d8764f0f7cd1352df6150045c8f638e517270e8b5dda1c63ade9c2280240cae',
- 'd0edc9a91a1677435a953390865d208c55b3183c6759c9b5a7ff494c322558eb',
- '6073c436dcd064a48127ddbf6032ac1a66fd59a0c24434f070d4e564c124c897',
- 'ca993121846c464d666096d35f13bf44c1b05af205f9b4a1e00cf6cc10c5e511'
- );
-
- /**
- * @param string $appId Application id for the running application
- * @param string|null $attestDir Directory where trusted attestation roots may be found
- * @throws Error If OpenSSL older than 1.0.0 is used
- */
- public function __construct($appId, $attestDir = null)
- {
- if(OPENSSL_VERSION_NUMBER < 0x10000000) {
- throw new Error('OpenSSL has to be at least version 1.0.0, this is ' . OPENSSL_VERSION_TEXT, ERR_OLD_OPENSSL);
- }
- $this->appId = $appId;
- $this->attestDir = $attestDir;
- }
-
- /**
- * Called to get a registration request to send to a user.
- * Returns an array of one registration request and a array of sign requests.
- *
- * @param array $registrations List of current registrations for this
- * user, to prevent the user from registering the same authenticator several
- * times.
- * @return array An array of two elements, the first containing a
- * RegisterRequest the second being an array of SignRequest
- * @throws Error
- */
- public function getRegisterData(array $registrations = array())
- {
- $challenge = $this->createChallenge();
- $request = new RegisterRequest($challenge, $this->appId);
- $signs = $this->getAuthenticateData($registrations);
- return array($request, $signs);
- }
-
- /**
- * Called to verify and unpack a registration message.
- *
- * @param RegisterRequest $request this is a reply to
- * @param object $response response from a user
- * @param bool $includeCert set to true if the attestation certificate should be
- * included in the returned Registration object
- * @return Registration
- * @throws Error
- */
- public function doRegister($request, $response, $includeCert = true)
- {
- if( !is_object( $request ) ) {
- throw new \InvalidArgumentException('$request of doRegister() method only accepts object.');
- }
-
- if( !is_object( $response ) ) {
- throw new \InvalidArgumentException('$response of doRegister() method only accepts object.');
- }
-
- if( property_exists( $response, 'errorCode') && $response->errorCode !== 0 ) {
- throw new Error('User-agent returned error. Error code: ' . $response->errorCode, ERR_BAD_UA_RETURNING );
- }
-
- if( !is_bool( $includeCert ) ) {
- throw new \InvalidArgumentException('$include_cert of doRegister() method only accepts boolean.');
- }
-
- $rawReg = $this->base64u_decode($response->registrationData);
- $regData = array_values(unpack('C*', $rawReg));
- $clientData = $this->base64u_decode($response->clientData);
- $cli = json_decode($clientData);
-
- if($cli->challenge !== $request->challenge) {
- throw new Error('Registration challenge does not match', ERR_UNMATCHED_CHALLENGE );
- }
-
- if(isset($cli->typ) && $cli->typ !== REQUEST_TYPE_REGISTER) {
- throw new Error('ClientData type is invalid', ERR_BAD_TYPE);
- }
-
- if(isset($cli->origin) && $cli->origin !== $request->appId) {
- throw new Error('App ID does not match the origin', ERR_NO_MATCHING_ORIGIN);
- }
-
- $registration = new Registration();
- $offs = 1;
- $pubKey = substr($rawReg, $offs, PUBKEY_LEN);
- $offs += PUBKEY_LEN;
- // decode the pubKey to make sure it's good
- $tmpKey = $this->pubkey_to_pem($pubKey);
- if($tmpKey === null) {
- throw new Error('Decoding of public key failed', ERR_PUBKEY_DECODE );
- }
- $registration->publicKey = base64_encode($pubKey);
- $khLen = $regData[$offs++];
- $kh = substr($rawReg, $offs, $khLen);
- $offs += $khLen;
- $registration->keyHandle = $this->base64u_encode($kh);
-
- // length of certificate is stored in byte 3 and 4 (excluding the first 4 bytes)
- $certLen = 4;
- $certLen += ($regData[$offs + 2] << 8);
- $certLen += $regData[$offs + 3];
-
- $rawCert = $this->fixSignatureUnusedBits(substr($rawReg, $offs, $certLen));
- $offs += $certLen;
- $pemCert = "-----BEGIN CERTIFICATE-----\r\n";
- $pemCert .= chunk_split(base64_encode($rawCert), 64);
- $pemCert .= "-----END CERTIFICATE-----";
- if($includeCert) {
- $registration->certificate = base64_encode($rawCert);
- }
- if($this->attestDir) {
- if(openssl_x509_checkpurpose($pemCert, -1, $this->get_certs()) !== true) {
- throw new Error('Attestation certificate can not be validated', ERR_ATTESTATION_VERIFICATION );
- }
- }
-
- if(!openssl_pkey_get_public($pemCert)) {
- throw new Error('Decoding of public key failed', ERR_PUBKEY_DECODE );
- }
- $signature = substr($rawReg, $offs);
-
- $dataToVerify = pack('C', 0);
- $dataToVerify .= hash('sha256', $request->appId, true);
- $dataToVerify .= hash('sha256', $clientData, true);
- $dataToVerify .= $kh;
- $dataToVerify .= $pubKey;
-
- if(openssl_verify($dataToVerify, $signature, $pemCert, 'sha256') === 1) {
- return $registration;
- } else {
- throw new Error('Attestation signature does not match', ERR_ATTESTATION_SIGNATURE );
- }
- }
-
- /**
- * Called to get an authentication request.
- *
- * @param array $registrations An array of the registrations to create authentication requests for.
- * @return array An array of SignRequest
- * @throws Error
- */
- public function getAuthenticateData(array $registrations)
- {
- $sigs = array();
- $challenge = $this->createChallenge();
- foreach ($registrations as $reg) {
- if( !is_object( $reg ) ) {
- throw new \InvalidArgumentException('$registrations of getAuthenticateData() method only accepts array of object.');
- }
- /** @var Registration $reg */
-
- $sig = new SignRequest();
- $sig->appId = $this->appId;
- $sig->keyHandle = $reg->keyHandle;
- $sig->challenge = $challenge;
- $sigs[] = $sig;
- }
- return $sigs;
- }
-
- /**
- * Called to verify an authentication response
- *
- * @param array $requests An array of outstanding authentication requests
- * @param array $registrations An array of current registrations
- * @param object $response A response from the authenticator
- * @return Registration
- * @throws Error
- *
- * The Registration object returned on success contains an updated counter
- * that should be saved for future authentications.
- * If the Error returned is ERR_COUNTER_TOO_LOW this is an indication of
- * token cloning or similar and appropriate action should be taken.
- */
- public function doAuthenticate(array $requests, array $registrations, $response)
- {
- if( !is_object( $response ) ) {
- throw new \InvalidArgumentException('$response of doAuthenticate() method only accepts object.');
- }
-
- if( property_exists( $response, 'errorCode') && $response->errorCode !== 0 ) {
- throw new Error('User-agent returned error. Error code: ' . $response->errorCode, ERR_BAD_UA_RETURNING );
- }
-
- /** @var object|null $req */
- $req = null;
-
- /** @var object|null $reg */
- $reg = null;
-
- $clientData = $this->base64u_decode($response->clientData);
- $decodedClient = json_decode($clientData);
-
- if(isset($decodedClient->typ) && $decodedClient->typ !== REQUEST_TYPE_AUTHENTICATE) {
- throw new Error('ClientData type is invalid', ERR_BAD_TYPE);
- }
-
- foreach ($requests as $req) {
- if( !is_object( $req ) ) {
- throw new \InvalidArgumentException('$requests of doAuthenticate() method only accepts array of object.');
- }
-
- if($req->keyHandle === $response->keyHandle && $req->challenge === $decodedClient->challenge) {
- break;
- }
-
- $req = null;
- }
- if($req === null) {
- throw new Error('No matching request found', ERR_NO_MATCHING_REQUEST );
- }
- if(isset($decodedClient->origin) && $decodedClient->origin !== $req->appId) {
- throw new Error('App ID does not match the origin', ERR_NO_MATCHING_ORIGIN);
- }
- foreach ($registrations as $reg) {
- if( !is_object( $reg ) ) {
- throw new \InvalidArgumentException('$registrations of doAuthenticate() method only accepts array of object.');
- }
-
- if($reg->keyHandle === $response->keyHandle) {
- break;
- }
- $reg = null;
- }
- if($reg === null) {
- throw new Error('No matching registration found', ERR_NO_MATCHING_REGISTRATION );
- }
- $pemKey = $this->pubkey_to_pem($this->base64u_decode($reg->publicKey));
- if($pemKey === null) {
- throw new Error('Decoding of public key failed', ERR_PUBKEY_DECODE );
- }
-
- $signData = $this->base64u_decode($response->signatureData);
- $dataToVerify = hash('sha256', $req->appId, true);
- $dataToVerify .= substr($signData, 0, 5);
- $dataToVerify .= hash('sha256', $clientData, true);
- $signature = substr($signData, 5);
-
- if(openssl_verify($dataToVerify, $signature, $pemKey, 'sha256') === 1) {
- $upb = unpack("Cupb", substr($signData, 0, 1));
- if($upb['upb'] !== 1) {
- throw new Error('User presence byte value is invalid', ERR_BAD_USER_PRESENCE );
- }
- $ctr = unpack("Nctr", substr($signData, 1, 4));
- $counter = $ctr['ctr'];
- /* TODO: wrap-around should be handled somehow.. */
- if($counter > $reg->counter) {
- $reg->counter = $counter;
- return self::castObjectToRegistration($reg);
- } else {
- throw new Error('Counter too low.', ERR_COUNTER_TOO_LOW );
- }
- } else {
- throw new Error('Authentication failed', ERR_AUTHENTICATION_FAILURE );
- }
- }
-
- /**
- * @param object $object
- * @return Registration
- */
- protected static function castObjectToRegistration($object)
- {
- $reg = new Registration();
- if (property_exists($object, 'publicKey')) {
- $reg->publicKey = $object->publicKey;
- }
- if (property_exists($object, 'certificate')) {
- $reg->certificate = $object->certificate;
- }
- if (property_exists($object, 'counter')) {
- $reg->counter = $object->counter;
- }
- if (property_exists($object, 'keyHandle')) {
- $reg->keyHandle = $object->keyHandle;
- }
- return $reg;
- }
-
- /**
- * @return array
- */
- private function get_certs()
- {
- $files = array();
- $dir = $this->attestDir;
- if($dir !== null && is_dir($dir) && $handle = opendir($dir)) {
- while(false !== ($entry = readdir($handle))) {
- if(is_file("$dir/$entry")) {
- $files[] = "$dir/$entry";
- }
- }
- closedir($handle);
- } elseif (is_file("$dir")) {
- $files[] = "$dir";
- }
- return $files;
- }
-
- /**
- * @param string $data
- * @return string
- */
- private function base64u_encode($data)
- {
- return trim(strtr(base64_encode($data), '+/', '-_'), '=');
- }
-
- /**
- * @param string $data
- * @return string
- */
- private function base64u_decode($data)
- {
- return base64_decode(strtr($data, '-_', '+/'));
- }
-
- /**
- * @param string $key
- * @return null|string
- */
- private function pubkey_to_pem($key)
- {
- if(strlen($key) !== PUBKEY_LEN || $key[0] !== "\x04") {
- return null;
- }
-
- /*
- * Convert the public key to binary DER format first
- * Using the ECC SubjectPublicKeyInfo OIDs from RFC 5480
- *
- * SEQUENCE(2 elem) 30 59
- * SEQUENCE(2 elem) 30 13
- * OID1.2.840.10045.2.1 (id-ecPublicKey) 06 07 2a 86 48 ce 3d 02 01
- * OID1.2.840.10045.3.1.7 (secp256r1) 06 08 2a 86 48 ce 3d 03 01 07
- * BIT STRING(520 bit) 03 42 ..key..
- */
- $der = "\x30\x59\x30\x13\x06\x07\x2a\x86\x48\xce\x3d\x02\x01";
- $der .= "\x06\x08\x2a\x86\x48\xce\x3d\x03\x01\x07\x03\x42";
- $der .= "\0".$key;
-
- $pem = "-----BEGIN PUBLIC KEY-----\r\n";
- $pem .= chunk_split(base64_encode($der), 64);
- $pem .= "-----END PUBLIC KEY-----";
-
- return $pem;
- }
-
- /**
- * @return string
- * @throws Error
- */
- private function createChallenge()
- {
- $challenge = random_bytes(32);
- $challenge = $this->base64u_encode( $challenge );
-
- return $challenge;
- }
-
- /**
- * Fixes a certificate where the signature contains unused bits.
- *
- * @param string $cert
- * @return mixed
- */
- private function fixSignatureUnusedBits($cert)
- {
- if(in_array(hash('sha256', $cert), $this->FIXCERTS, true)) {
- $cert[strlen($cert) - 257] = "\0";
- }
- return $cert;
- }
-}
-
-/**
- * Class for building a registration request
- *
- * @package u2flib_server
- */
-class RegisterRequest
-{
- /** @var string Protocol version */
- public $version = U2F_VERSION;
-
- /** @var string Registration challenge */
- public $challenge;
-
- /** @var string Application id */
- public $appId;
-
- /**
- * @param string $challenge
- * @param string $appId
- * @internal
- */
- public function __construct($challenge, $appId)
- {
- $this->challenge = $challenge;
- $this->appId = $appId;
- }
-}
-
-/**
- * Class for building up an authentication request
- *
- * @package u2flib_server
- */
-class SignRequest
-{
- /** @var string Protocol version */
- public $version = U2F_VERSION;
-
- /** @var string Authentication challenge */
- public $challenge = '';
-
- /** @var string Key handle of a registered authenticator */
- public $keyHandle = '';
-
- /** @var string Application id */
- public $appId = '';
-}
-
-/**
- * Class returned for successful registrations
- *
- * @package u2flib_server
- */
-class Registration
-{
- /** @var string The key handle of the registered authenticator */
- public $keyHandle = '';
-
- /** @var string The public key of the registered authenticator */
- public $publicKey = '';
-
- /** @var string The attestation certificate of the registered authenticator */
- public $certificate = '';
-
- /** @var int The counter associated with this registration */
- public $counter = -1;
-}
-
-/**
- * Error class, returned on errors
- *
- * @package u2flib_server
- */
-class Error extends \Exception
-{
- /**
- * Override constructor and make message and code mandatory
- * @param string $message
- * @param int $code
- * @param \Exception|null $previous
- */
- public function __construct($message, $code, \Exception $previous = null) {
- parent::__construct($message, $code, $previous);
- }
-}
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 9c5203e..b7ba156 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/prerequisites.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/prerequisites.inc.php
@@ -46,10 +46,8 @@
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/lib/array_merge_real.php';
-// U2F API + T/HOTP API
-// u2f - deprecated, should be removed
-$u2f = new u2flib_server\U2F('https://' . $_SERVER['HTTP_HOST']);
-$qrprovider = new RobThree\Auth\Providers\Qr\QRServerProvider();
+// T/HOTP API
+$qrprovider = new RobThree\Auth\Providers\Qr\BaconQrCodeProvider();
$tfa = new RobThree\Auth\TwoFactorAuth($OTP_LABEL, 6, 30, 'sha1', $qrprovider);
// FIDO2
@@ -68,6 +66,7 @@
else {
$redis->connect('redis-mailcow', 6379);
}
+ $redis->auth(getenv("REDISPASS"));
}
catch (Exception $e) {
// Stop when redis is not available
@@ -122,7 +121,7 @@
$this->config['user_table'] = 'mailbox';
}
public function checkUserCredentials($username, $password) {
- if (check_login($username, $password) == 'user') {
+ if (check_login($username, $password, array("role" => "user", "service" => "NONE")) == 'user') {
return true;
}
return false;
@@ -177,8 +176,13 @@
// Load core functions first
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.auth.inc.php';
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/sessions.inc.php';
+// Init Identity Provider
+$iam_provider = identity_provider('init');
+$iam_settings = identity_provider('get');
+
// IMAP lib
// use Ddeboer\Imap\Server;
// $imap_server = new Server('dovecot', 143, '/imap/tls/novalidate-cert');
@@ -293,7 +297,7 @@
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/functions.tls_policy_maps.inc.php';
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/triggers.global.inc.php';
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/twig.inc.php';
init_db_schema();
if (isset($_SESSION['mailcow_cc_role'])) {
@@ -315,13 +319,19 @@
$css_dir = array_diff(scandir('/web/css/build'), array('..', '.'));
// get customized ui data
$UI_TEXTS = customize('get', 'ui_texts');
+// theme selected in admin UI overrides $UI_THEME
+if ($ui_theme_selected = customize('get', 'ui_theme')) {
+ $UI_THEME = $ui_theme_selected;
+}
// minify bootstrap theme
-if (file_exists('/web/css/themes/'.$UI_THEME.'-bootstrap.css'))
+if (file_exists('/web/css/themes/'.$UI_THEME.'/bootstrap.css'))
+ $css_minifier->add('/web/css/themes/'.$UI_THEME.'/bootstrap.css');
+elseif (file_exists('/web/css/themes/'.$UI_THEME.'-bootstrap.css'))
$css_minifier->add('/web/css/themes/'.$UI_THEME.'-bootstrap.css');
else
- $css_minifier->add('/web/css/themes/lumen-bootstrap.css');
+ $css_minifier->add('/web/css/themes/lumen-bootstrap.css');
// minify css build files
foreach ($css_dir as $css_file) {
$css_minifier->add('/web/css/build/' . $css_file);
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/presets/sieve/sieve_1.yml b/mailcow/src/mailcow-dockerized/data/web/inc/presets/sieve/sieve_1.yml
index e7fa8c8..45e0eb4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/presets/sieve/sieve_1.yml
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/presets/sieve/sieve_1.yml
@@ -1,7 +1,7 @@
headline: lang.sieve_preset_1
content: |
require ["reject","body","regex"];
- if anyof (body :raw :regex ["filename=.*\.doc","filename=.*\.exe","filename=.*\.moo"]) {
+ if anyof (body :raw :regex ["filename=\".*\\.(doc|exe|moo)\""]) {
reject text:
doc, exe and moo are dangerous file extensions.
Why would you do that? I am a sad cow.
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/sessions.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/sessions.inc.php
index 1a33e76..ac308b6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/sessions.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/sessions.inc.php
@@ -1,10 +1,14 @@
<?php
// Start session
if (session_status() !== PHP_SESSION_ACTIVE) {
+ session_name($SESSION_NAME);
ini_set("session.cookie_httponly", 1);
+ ini_set("session.cookie_samesite", $SESSION_SAMESITE_POLICY);
ini_set('session.gc_maxlifetime', $SESSION_LIFETIME);
}
+$_SESSION['access_all_exception'] = '0';
+
if (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) &&
strtolower($_SERVER['HTTP_X_FORWARDED_PROTO']) == "https") {
if (session_status() !== PHP_SESSION_ACTIVE) {
@@ -94,16 +98,33 @@
if (isset($_SESSION["dual-login"])) {
$_SESSION["mailcow_cc_username"] = $_SESSION["dual-login"]["username"];
$_SESSION["mailcow_cc_role"] = $_SESSION["dual-login"]["role"];
+ unset($_SESSION['sogo-sso-user-allowed']);
+ unset($_SESSION['sogo-sso-pass']);
unset($_SESSION["dual-login"]);
- header("Location: /mailbox");
+ if ($_SESSION["mailcow_cc_role"] == "admin"){
+ header("Location: /admin/mailbox");
+ } elseif ($_SESSION["mailcow_cc_role"] == "domainadmin") {
+ header("Location: /domainadmin/mailbox");
+ } else {
+ header("Location: /");
+ }
exit();
}
else {
+ $role = $_SESSION["mailcow_cc_role"];
session_regenerate_id(true);
session_unset();
session_destroy();
session_write_close();
- header("Location: /");
+ if ($role == "admin") {
+ header("Location: /admin");
+ }
+ elseif ($role == "domainadmin") {
+ header("Location: /domainadmin");
+ }
+ else {
+ header("Location: /");
+ }
}
}
@@ -119,17 +140,32 @@
);
return false;
}
- if (!empty($_POST)) {
- if ($_SESSION['CSRF']['TOKEN'] != $_POST['csrf_token']) {
- $_SESSION['return'][] = array(
- 'type' => 'warning',
- 'msg' => 'session_token'
- );
- return false;
+ // Check if this is a POST request (form-encoded or JSON)
+ $is_post_request = !empty($_POST) || (
+ isset($_SERVER['CONTENT_TYPE']) &&
+ strpos($_SERVER['CONTENT_TYPE'], 'application/json') !== false
+ );
+
+ if ($is_post_request) {
+ // Skip CSRF check for DataTables server-side processing endpoints
+ // These are read-only operations (equivalent to GET) authenticated by session
+ $is_search_endpoint = (
+ isset($_GET['query']) &&
+ preg_match('#^search/(domain|mailbox)$#', $_GET['query'])
+ );
+
+ if (!$is_search_endpoint && !empty($_POST)) {
+ if ($_SESSION['CSRF']['TOKEN'] != $_POST['csrf_token']) {
+ $_SESSION['return'][] = array(
+ 'type' => 'warning',
+ 'msg' => 'session_token'
+ );
+ return false;
+ }
+ unset($_POST['csrf_token']);
+ $_SESSION['CSRF']['TOKEN'] = bin2hex(random_bytes(32));
+ $_SESSION['CSRF']['TIME'] = time();
}
- unset($_POST['csrf_token']);
- $_SESSION['CSRF']['TOKEN'] = bin2hex(random_bytes(32));
- $_SESSION['CSRF']['TIME'] = time();
}
return true;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/triggers.admin.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.admin.inc.php
new file mode 100644
index 0000000..9204319
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.admin.inc.php
@@ -0,0 +1,125 @@
+<?php
+
+if (isset($_POST["verify_tfa_login"])) {
+ if (verify_tfa_login($_SESSION['pending_mailcow_cc_username'], $_POST)) {
+ if ($_SESSION['pending_mailcow_cc_role'] == "admin") {
+ $_SESSION['mailcow_cc_username'] = $_SESSION['pending_mailcow_cc_username'];
+ $_SESSION['mailcow_cc_role'] = "admin";
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+
+ // If pending actions exist, redirect to /admin to show modal
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ header("Location: /admin");
+ die();
+ }
+ header("Location: /admin/dashboard");
+ die();
+ }
+ }
+
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+}
+if (isset($_POST["verify_fido2_login"])) {
+ $res = fido2(array(
+ "action" => "verify",
+ "token" => $_POST["token"],
+ "user" => "admin"
+ ));
+ if (is_array($res) && $res['role'] == "admin" && !empty($res['username'])){
+ $_SESSION["mailcow_cc_username"] = $res['username'];
+ $_SESSION["mailcow_cc_role"] = $res['role'];
+ $_SESSION["fido2_cid"] = $res['cid'];
+ }
+ exit;
+}
+
+if (isset($_GET["cancel_tfa_login"])) {
+ unset($_SESSION['pending_pw_reset_token']);
+ unset($_SESSION['pending_pw_new_password']);
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+
+ header("Location: /admin");
+}
+
+if (isset($_GET["cancel_tfa_setup"])) {
+ session_regenerate_id(true);
+ session_unset();
+ session_destroy();
+ session_write_close();
+ header("Location: /admin");
+ exit();
+}
+
+if (isset($_POST["login_user"]) && isset($_POST["pass_user"])) {
+ $login_user = strtolower(trim($_POST["login_user"]));
+ $as = check_login($login_user, $_POST["pass_user"], array("role" => "admin", "service" => "MAILCOWUI"));
+
+ if ($as == "admin") {
+ session_regenerate_id(true);
+ $_SESSION['mailcow_cc_username'] = $login_user;
+ $_SESSION['mailcow_cc_role'] = "admin";
+ // If pending actions exist, redirect to /admin to show modal
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ header("Location: /admin");
+ die();
+ }
+ header("Location: /admin/dashboard");
+ die();
+ }
+ elseif ($as != "pending") {
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+ unset($_SESSION['mailcow_cc_username']);
+ unset($_SESSION['mailcow_cc_role']);
+ }
+}
+
+if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == "admin" && !isset($_SESSION['mailcow_cc_api'])) {
+ // TODO: Move file upload to API?
+ if (isset($_POST["submit_main_logo"])) {
+ if ($_FILES['main_logo']['error'] == 0) {
+ customize('add', 'main_logo', $_FILES);
+ }
+ if ($_FILES['main_logo_dark']['error'] == 0) {
+ customize('add', 'main_logo_dark', $_FILES);
+ }
+ }
+ if (isset($_POST["reset_main_logo"])) {
+ customize('delete', 'main_logo');
+ customize('delete', 'main_logo_dark');
+ }
+ // Some actions will not be available via API
+ if (isset($_POST["license_validate_now"])) {
+ license('verify');
+ }
+ if (isset($_POST["admin_api"])) {
+ if (isset($_POST["admin_api"]["ro"])) {
+ admin_api('ro', 'edit', $_POST);
+ }
+ elseif (isset($_POST["admin_api"]["rw"])) {
+ admin_api('rw', 'edit', $_POST);
+ }
+ }
+ if (isset($_POST["admin_api_regen_key"])) {
+ if (isset($_POST["admin_api_regen_key"]["ro"])) {
+ admin_api('ro', 'regen_key', $_POST);
+ }
+ elseif (isset($_POST["admin_api_regen_key"]["rw"])) {
+ admin_api('rw', 'regen_key', $_POST);
+ }
+ }
+ if (isset($_POST["rspamd_ui"])) {
+ rspamd_ui('edit', $_POST);
+ }
+ if (isset($_POST["mass_send"])) {
+ sys_mail($_POST);
+ }
+}
+?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/triggers.domainadmin.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.domainadmin.inc.php
new file mode 100644
index 0000000..2eee8b9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.domainadmin.inc.php
@@ -0,0 +1,94 @@
+<?php
+// SSO Domain Admin
+if (!empty($_GET['sso_token'])) {
+ $username = domain_admin_sso('check', $_GET['sso_token']);
+
+ if ($username !== false) {
+ session_regenerate_id(true);
+ $_SESSION['mailcow_cc_username'] = $username;
+ $_SESSION['mailcow_cc_role'] = 'domainadmin';
+ header('Location: /domainadmin/mailbox');
+ }
+}
+
+if (isset($_POST["verify_tfa_login"])) {
+ if (verify_tfa_login($_SESSION['pending_mailcow_cc_username'], $_POST)) {
+ if ($_SESSION['pending_mailcow_cc_role'] == "domainadmin") {
+ $_SESSION['mailcow_cc_username'] = $_SESSION['pending_mailcow_cc_username'];
+ $_SESSION['mailcow_cc_role'] = "domainadmin";
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+
+ // If pending actions exist, redirect to /domainadmin to show modal
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ header("Location: /domainadmin");
+ die();
+ }
+ header("Location: /domainadmin/mailbox");
+ die();
+ }
+ }
+
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+}
+if (isset($_POST["verify_fido2_login"])) {
+ $res = fido2(array(
+ "action" => "verify",
+ "token" => $_POST["token"],
+ "user" => "domainadmin"
+ ));
+ if (is_array($res) && $res['role'] == "domainadmin" && !empty($res['username'])){
+ $_SESSION["mailcow_cc_username"] = $res['username'];
+ $_SESSION["mailcow_cc_role"] = $res['role'];
+ $_SESSION["fido2_cid"] = $res['cid'];
+ }
+ exit;
+}
+
+if (isset($_GET["cancel_tfa_login"])) {
+ unset($_SESSION['pending_pw_reset_token']);
+ unset($_SESSION['pending_pw_new_password']);
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+
+ header("Location: /domainadmin");
+}
+
+if (isset($_GET["cancel_tfa_setup"])) {
+ session_regenerate_id(true);
+ session_unset();
+ session_destroy();
+ session_write_close();
+ header("Location: /domainadmin");
+ exit();
+}
+
+if (isset($_POST["login_user"]) && isset($_POST["pass_user"])) {
+ $login_user = strtolower(trim($_POST["login_user"]));
+ $as = check_login($login_user, $_POST["pass_user"], array("role" => "domain_admin", "service" => "MAILCOWUI"));
+
+ if ($as == "domainadmin") {
+ session_regenerate_id(true);
+ $_SESSION['mailcow_cc_username'] = $login_user;
+ $_SESSION['mailcow_cc_role'] = "domainadmin";
+ // If pending actions exist, redirect to /domainadmin to show modal
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ header("Location: /domainadmin");
+ die();
+ }
+ header("Location: /domainadmin/mailbox");
+ die();
+ }
+ elseif ($as != "pending") {
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+ unset($_SESSION['mailcow_cc_username']);
+ unset($_SESSION['mailcow_cc_role']);
+ }
+}
+?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/triggers.global.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.global.inc.php
new file mode 100644
index 0000000..1f8f920
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.global.inc.php
@@ -0,0 +1,67 @@
+<?php
+if (isset($_POST["quick_release"])) {
+ quarantine('quick_release', $_POST["quick_release"]);
+}
+
+if (isset($_POST["quick_delete"])) {
+ quarantine('quick_delete', $_POST["quick_delete"]);
+}
+
+if (isset($_SESSION['mailcow_cc_role']) && (isset($_SESSION['acl']['login_as']) && $_SESSION['acl']['login_as'] == "1")) {
+ if (isset($_GET["duallogin"])) {
+ $is_dual = (!empty($_SESSION["dual-login"]["username"])) ? true : false;
+ if (!$is_dual) {
+ $duallogin = html_entity_decode(rawurldecode($_GET["duallogin"]));
+ if (filter_var($duallogin, FILTER_VALIDATE_EMAIL)) {
+ if (!empty(mailbox('get', 'mailbox_details', $duallogin))) {
+ $_SESSION["dual-login"]["username"] = $_SESSION['mailcow_cc_username'];
+ $_SESSION["dual-login"]["role"] = $_SESSION['mailcow_cc_role'];
+ $_SESSION['mailcow_cc_username'] = $duallogin;
+ $_SESSION['mailcow_cc_role'] = "user";
+ header("Location: /user");
+ }
+ }
+ else {
+ if (!empty(domain_admin('details', $duallogin))) {
+ $_SESSION["dual-login"]["username"] = $_SESSION['mailcow_cc_username'];
+ $_SESSION["dual-login"]["role"] = $_SESSION['mailcow_cc_role'];
+ $_SESSION['mailcow_cc_username'] = $duallogin;
+ $_SESSION['mailcow_cc_role'] = "domainadmin";
+ header("Location: /user");
+ }
+ }
+ }
+ }
+}
+
+if (isset($_SESSION['mailcow_cc_role'])) {
+ if (isset($_POST["set_tfa"])) {
+ $had_pending_tfa_setup = !empty($_SESSION['pending_tfa_setup']);
+ set_tfa($_POST);
+ // After TFA setup during forced enrollment
+ if ($had_pending_tfa_setup && empty($_SESSION['pending_tfa_setup'])) {
+ if ($_SESSION['mailcow_cc_role'] === 'admin') {
+ header("Location: /admin/dashboard");
+ } elseif ($_SESSION['mailcow_cc_role'] === 'domainadmin') {
+ header("Location: /domainadmin/mailbox");
+ } elseif ($_SESSION['mailcow_cc_role'] === 'user') {
+ // Check if user should go to SOGo or /user
+ $user_details = mailbox("get", "mailbox_details", $_SESSION['mailcow_cc_username']);
+ $is_dual = (!empty($_SESSION["dual-login"]["username"])) ? true : false;
+ if (intval($user_details['attributes']['sogo_access']) == 1 && !$is_dual && getenv('SKIP_SOGO') != "y") {
+ header("Location: /SOGo/so/");
+ } else {
+ header("Location: /user");
+ }
+ }
+ exit();
+ }
+ }
+ if (isset($_POST["unset_tfa_key"])) {
+ unset_tfa_key($_POST);
+ }
+ if (isset($_POST["unset_fido2_key"])) {
+ fido2(array("action" => "unset_fido2_key", "post_data" => $_POST));
+ }
+}
+?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/triggers.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.inc.php
deleted file mode 100644
index 6922429..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/inc/triggers.inc.php
+++ /dev/null
@@ -1,159 +0,0 @@
-<?php
-// SSO Domain Admin
-if (!empty($_GET['sso_token'])) {
- $username = domain_admin_sso('check', $_GET['sso_token']);
-
- if ($username !== false) {
- $_SESSION['mailcow_cc_username'] = $username;
- $_SESSION['mailcow_cc_role'] = 'domainadmin';
- header('Location: /mailbox');
- }
-}
-
-if (isset($_POST["verify_tfa_login"])) {
- if (verify_tfa_login($_SESSION['pending_mailcow_cc_username'], $_POST)) {
- $_SESSION['mailcow_cc_username'] = $_SESSION['pending_mailcow_cc_username'];
- $_SESSION['mailcow_cc_role'] = $_SESSION['pending_mailcow_cc_role'];
- unset($_SESSION['pending_mailcow_cc_username']);
- unset($_SESSION['pending_mailcow_cc_role']);
- unset($_SESSION['pending_tfa_methods']);
-
- header("Location: /user");
- } else {
- unset($_SESSION['pending_mailcow_cc_username']);
- unset($_SESSION['pending_mailcow_cc_role']);
- unset($_SESSION['pending_tfa_methods']);
- }
-}
-
-if (isset($_GET["cancel_tfa_login"])) {
- unset($_SESSION['pending_mailcow_cc_username']);
- unset($_SESSION['pending_mailcow_cc_role']);
- unset($_SESSION['pending_tfa_methods']);
-
- header("Location: /");
-}
-
-if (isset($_POST["quick_release"])) {
- quarantine('quick_release', $_POST["quick_release"]);
-}
-
-if (isset($_POST["quick_delete"])) {
- quarantine('quick_delete', $_POST["quick_delete"]);
-}
-
-if (isset($_POST["login_user"]) && isset($_POST["pass_user"])) {
- $login_user = strtolower(trim($_POST["login_user"]));
- $as = check_login($login_user, $_POST["pass_user"]);
-
- if ($as == "admin") {
- $_SESSION['mailcow_cc_username'] = $login_user;
- $_SESSION['mailcow_cc_role'] = "admin";
- header("Location: /admin");
- }
- elseif ($as == "domainadmin") {
- $_SESSION['mailcow_cc_username'] = $login_user;
- $_SESSION['mailcow_cc_role'] = "domainadmin";
- header("Location: /mailbox");
- }
- elseif ($as == "user") {
- $_SESSION['mailcow_cc_username'] = $login_user;
- $_SESSION['mailcow_cc_role'] = "user";
- $http_parameters = explode('&', $_SESSION['index_query_string']);
- unset($_SESSION['index_query_string']);
- if (in_array('mobileconfig', $http_parameters)) {
- if (in_array('only_email', $http_parameters)) {
- header("Location: /mobileconfig.php?only_email");
- die();
- }
- header("Location: /mobileconfig.php");
- die();
- }
- header("Location: /user");
- }
- elseif ($as != "pending") {
- unset($_SESSION['pending_mailcow_cc_username']);
- unset($_SESSION['pending_mailcow_cc_role']);
- unset($_SESSION['pending_tfa_methods']);
- unset($_SESSION['mailcow_cc_username']);
- unset($_SESSION['mailcow_cc_role']);
- }
-}
-
-if (isset($_SESSION['mailcow_cc_role']) && (isset($_SESSION['acl']['login_as']) && $_SESSION['acl']['login_as'] == "1")) {
- if (isset($_GET["duallogin"])) {
- $duallogin = html_entity_decode(rawurldecode($_GET["duallogin"]));
- if (filter_var($duallogin, FILTER_VALIDATE_EMAIL)) {
- if (!empty(mailbox('get', 'mailbox_details', $duallogin))) {
- $_SESSION["dual-login"]["username"] = $_SESSION['mailcow_cc_username'];
- $_SESSION["dual-login"]["role"] = $_SESSION['mailcow_cc_role'];
- $_SESSION['mailcow_cc_username'] = $duallogin;
- $_SESSION['mailcow_cc_role'] = "user";
- header("Location: /user");
- }
- }
- else {
- if (!empty(domain_admin('details', $duallogin))) {
- $_SESSION["dual-login"]["username"] = $_SESSION['mailcow_cc_username'];
- $_SESSION["dual-login"]["role"] = $_SESSION['mailcow_cc_role'];
- $_SESSION['mailcow_cc_username'] = $duallogin;
- $_SESSION['mailcow_cc_role'] = "domainadmin";
- header("Location: /user");
- }
- }
- }
-}
-
-if (isset($_SESSION['mailcow_cc_role'])) {
- if (isset($_POST["set_tfa"])) {
- set_tfa($_POST);
- }
- if (isset($_POST["unset_tfa_key"])) {
- unset_tfa_key($_POST);
- }
- if (isset($_POST["unset_fido2_key"])) {
- fido2(array("action" => "unset_fido2_key", "post_data" => $_POST));
- }
-}
-if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == "admin" && !isset($_SESSION['mailcow_cc_api'])) {
- // TODO: Move file upload to API?
- if (isset($_POST["submit_main_logo"])) {
- if ($_FILES['main_logo']['error'] == 0) {
- customize('add', 'main_logo', $_FILES);
- }
- if ($_FILES['main_logo_dark']['error'] == 0) {
- customize('add', 'main_logo_dark', $_FILES);
- }
- }
- if (isset($_POST["reset_main_logo"])) {
- customize('delete', 'main_logo');
- customize('delete', 'main_logo_dark');
- }
- // Some actions will not be available via API
- if (isset($_POST["license_validate_now"])) {
- license('verify');
- }
- if (isset($_POST["admin_api"])) {
- if (isset($_POST["admin_api"]["ro"])) {
- admin_api('ro', 'edit', $_POST);
- }
- elseif (isset($_POST["admin_api"]["rw"])) {
- admin_api('rw', 'edit', $_POST);
- }
- }
- if (isset($_POST["admin_api_regen_key"])) {
- if (isset($_POST["admin_api_regen_key"]["ro"])) {
- admin_api('ro', 'regen_key', $_POST);
- }
- elseif (isset($_POST["admin_api_regen_key"]["rw"])) {
- admin_api('rw', 'regen_key', $_POST);
- }
- }
- if (isset($_POST["rspamd_ui"])) {
- rspamd_ui('edit', $_POST);
- }
- if (isset($_POST["mass_send"])) {
- sys_mail($_POST);
- }
-}
-?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/triggers.user.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.user.inc.php
new file mode 100644
index 0000000..5dcde0b
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/triggers.user.inc.php
@@ -0,0 +1,183 @@
+<?php
+// handle iam authentication
+if ($iam_provider){
+ if (isset($_GET['iam_sso'])){
+ // redirect for sso
+ $redirect_uri = identity_provider('get-redirect');
+ $redirect_uri = !empty($redirect_uri) ? $redirect_uri : '/';
+ header('Location: ' . $redirect_uri);
+ die();
+ }
+ if ($_SESSION['iam_token'] && $_SESSION['iam_refresh_token']) {
+ // Session found, try to refresh
+ $isRefreshed = identity_provider('refresh-token');
+
+ if (!$isRefreshed){
+ // Session could not be refreshed, redirect to provider
+ $redirect_uri = identity_provider('get-redirect');
+ $redirect_uri = !empty($redirect_uri) ? $redirect_uri : '/';
+ header('Location: ' . $redirect_uri);
+ die();
+ }
+ } elseif ($_GET['code'] && $_GET['state'] === $_SESSION['oauth2state']) {
+ // Check given state against previously stored one to mitigate CSRF attack
+ // Received access token in $_GET['code']
+ // extract info and verify user
+ identity_provider('verify-sso');
+ }
+}
+
+if (isset($_POST["pw_reset_request"]) && !empty($_POST['username'])) {
+ reset_password("issue", $_POST['username']);
+ header("Location: /");
+ exit;
+}
+if (isset($_POST["pw_reset"])) {
+ $username = reset_password("check", $_POST['token']);
+ $reset_result = reset_password("reset", array(
+ 'new_password' => $_POST['new_password'],
+ 'new_password2' => $_POST['new_password2'],
+ 'token' => $_POST['token'],
+ 'username' => $username,
+ 'check_tfa' => True
+ ));
+
+ if ($reset_result){
+ header("Location: /");
+ exit;
+ }
+}
+if (isset($_POST["verify_tfa_login"])) {
+ if (verify_tfa_login($_SESSION['pending_mailcow_cc_username'], $_POST)) {
+ if ($_SESSION['pending_mailcow_cc_role'] == "user") {
+ if (isset($_SESSION['pending_pw_reset_token']) && isset($_SESSION['pending_pw_new_password'])) {
+ reset_password("reset", array(
+ 'new_password' => $_SESSION['pending_pw_new_password'],
+ 'new_password2' => $_SESSION['pending_pw_new_password'],
+ 'token' => $_SESSION['pending_pw_reset_token'],
+ 'username' => $_SESSION['pending_mailcow_cc_username']
+ ));
+ unset($_SESSION['pending_pw_reset_token']);
+ unset($_SESSION['pending_pw_new_password']);
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_tfa_methods']);
+
+ header("Location: /");
+ die();
+ } else {
+ set_user_loggedin_session($_SESSION['pending_mailcow_cc_username']);
+
+ if (isset($_SESSION['oauth2_request'])) {
+ $oauth2_request = $_SESSION['oauth2_request'];
+ unset($_SESSION['oauth2_request']);
+ header('Location: ' . $oauth2_request);
+ die();
+ }
+
+ $user_details = mailbox("get", "mailbox_details", $_SESSION['mailcow_cc_username']);
+ $is_dual = (!empty($_SESSION["dual-login"]["username"])) ? true : false;
+ // If pending actions exist, redirect to / to show modal
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ header("Location: /");
+ die();
+ }
+ if (intval($user_details['attributes']['sogo_access']) == 1 &&
+ intval($user_details['attributes']['force_pw_update']) != 1 &&
+ getenv('SKIP_SOGO') != "y" &&
+ !$is_dual) {
+ header("Location: /SOGo/so/");
+ die();
+ } else {
+ header("Location: /user");
+ die();
+ }
+ }
+ }
+ }
+
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+}
+if (isset($_POST["verify_fido2_login"])) {
+ $res = fido2(array(
+ "action" => "verify",
+ "token" => $_POST["token"],
+ "user" => "user"
+ ));
+ if (is_array($res) && $res['role'] == "user" && !empty($res['username'])){
+ set_user_loggedin_session($res['username']);
+ $_SESSION["fido2_cid"] = $res['cid'];
+ }
+ exit;
+}
+
+if (isset($_GET["cancel_tfa_login"])) {
+ unset($_SESSION['pending_pw_reset_token']);
+ unset($_SESSION['pending_pw_new_password']);
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+
+ header("Location: /");
+}
+
+if (isset($_GET["cancel_tfa_setup"])) {
+ session_regenerate_id(true);
+ session_unset();
+ session_destroy();
+ session_write_close();
+ header("Location: /");
+ exit();
+}
+
+if (isset($_POST["login_user"]) && isset($_POST["pass_user"])) {
+ $login_user = strtolower(trim($_POST["login_user"]));
+ $as = check_login($login_user, $_POST["pass_user"], array("role" => "user", "service" => "MAILCOWUI"));
+
+ if ($as == "user") {
+ set_user_loggedin_session($login_user);
+ $http_parameters = explode('&', $_SESSION['index_query_string']);
+ unset($_SESSION['index_query_string']);
+ if (in_array('mobileconfig', $http_parameters)) {
+ if (in_array('only_email', $http_parameters)) {
+ header("Location: /mobileconfig.php?only_email");
+ die();
+ }
+ header("Location: /mobileconfig.php");
+ die();
+ }
+ if (isset($_SESSION['oauth2_request'])) {
+ $oauth2_request = $_SESSION['oauth2_request'];
+ unset($_SESSION['oauth2_request']);
+ header('Location: ' . $oauth2_request);
+ die();
+ }
+
+ $user_details = mailbox("get", "mailbox_details", $login_user);
+ $is_dual = (!empty($_SESSION["dual-login"]["username"])) ? true : false;
+ // If pending actions exist, redirect to / to show modal
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ header("Location: /");
+ die();
+ }
+ if (intval($user_details['attributes']['sogo_access']) == 1 &&
+ intval($user_details['attributes']['force_pw_update']) != 1 &&
+ getenv('SKIP_SOGO') != "y" &&
+ !$is_dual) {
+ header("Location: /SOGo/so/");
+ die();
+ } else {
+ header("Location: /user");
+ die();
+ }
+ }
+ elseif ($as != "pending") {
+ unset($_SESSION['pending_mailcow_cc_username']);
+ unset($_SESSION['pending_mailcow_cc_role']);
+ unset($_SESSION['pending_tfa_methods']);
+ unset($_SESSION['mailcow_cc_username']);
+ unset($_SESSION['mailcow_cc_role']);
+ }
+}
+?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/twig.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/twig.inc.php
index a3bc02d..c4d0669 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/twig.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/twig.inc.php
@@ -13,7 +13,9 @@
// functions
$twig->addFunction(new TwigFunction('query_string', function (array $params = []) {
- return http_build_query(array_merge($_GET, $params));
+ $allowed = ['lang', 'mobileconfig'];
+ $filtered = array_intersect_key($_GET, array_flip($allowed));
+ return http_build_query(array_merge($filtered, $params));
}));
$twig->addFunction(new TwigFunction('is_uri', function (string $uri, string $where = null) {
diff --git a/mailcow/src/mailcow-dockerized/data/web/inc/vars.inc.php b/mailcow/src/mailcow-dockerized/data/web/inc/vars.inc.php
index 8cfafa2..72c5da6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/inc/vars.inc.php
+++ b/mailcow/src/mailcow-dockerized/data/web/inc/vars.inc.php
@@ -33,6 +33,8 @@
//$https_port = 1234;
// Other settings =>
$autodiscover_config = array(
+ 'displayName' => 'A mailcow mail server',
+ 'displayShortName' => 'mail server',
// General autodiscover service type: "activesync" or "imap"
// emClient uses autodiscover, but does not support ActiveSync. mailcow excludes emClient from ActiveSync.
// With SOGo disabled, the type will always fallback to imap. CalDAV and CardDAV will be excluded, too.
@@ -83,8 +85,9 @@
// https://en.wikipedia.org/wiki/IETF_language_tag
$AVAILABLE_LANGUAGES = array(
// 'ca-es' => 'Català (Catalan)',
+ 'bg-bg' => 'Български (Bulgarian)',
'cs-cz' => 'Čeština (Czech)',
- 'da-dk' => 'Danish (Dansk)',
+ 'da-dk' => 'Dansk (Danish)',
'de-de' => 'Deutsch (German)',
'en-gb' => 'English',
'es-es' => 'Español (Spanish)',
@@ -93,8 +96,10 @@
'gr-gr' => 'Ελληνικά (Greek)',
'hu-hu' => 'Magyar (Hungarian)',
'it-it' => 'Italiano (Italian)',
+ 'ja-jp' => '日本語 (Japanese)',
'ko-kr' => '한국어 (Korean)',
'lv-lv' => 'latviešu (Latvian)',
+ 'lt-lt' => 'Lietuvių (Lithuanian)',
'nb-no' => 'Norsk (Norwegian)',
'nl-nl' => 'Nederlands (Dutch)',
'pl-pl' => 'Język Polski (Polish)',
@@ -107,6 +112,8 @@
'sv-se' => 'Svenska (Swedish)',
'tr-tr' => 'Türkçe (Turkish)',
'uk-ua' => 'Українська (Ukrainian)',
+ 'uz-uz' => 'Oʻzbekcha (Uzbek)',
+ 'vi-vn' => 'Tiếng Việt (Vietnamese)',
'zh-cn' => '简体中文 (Simplified Chinese)',
'zh-tw' => '繁體中文 (Traditional Chinese)',
);
@@ -114,6 +121,8 @@
// default theme is lumen
// additional themes can be found here: https://bootswatch.com/
// copy them to data/web/css/themes/{THEME-NAME}-bootstrap.css
+// or use a theme folder data/web/css/themes/{THEME-NAME}/ (theme.css, optional dark.css, bootstrap.css, theme.json)
+// theme folders can be selected in System > Configuration > Customize, which overrides $UI_THEME
$UI_THEME = "lumen";
// Show DKIM private keys - false by default
@@ -123,7 +132,9 @@
$MAILCOW_APPS = array(
array(
'name' => 'Webmail',
- 'link' => '/SOGo/',
+ 'link' => '/SOGo/so',
+ 'user_link' => '/SOGo/so',
+ 'hide' => true
)
);
@@ -148,6 +159,13 @@
// Session lifetime in seconds
$SESSION_LIFETIME = 10800;
+// Session SameSite Policy
+// Use "None", "Lax" or "Strict"
+$SESSION_SAMESITE_POLICY = "Lax";
+
+// Name of the session cookie
+$SESSION_NAME = "MCSESSID";
+
// Label for OTP devices
$OTP_LABEL = "mailcow UI";
@@ -178,9 +196,18 @@
// Force password change on next login (only allows login to mailcow UI)
$MAILBOX_DEFAULT_ATTRIBUTES['force_pw_update'] = false;
-// Enable SOGo access (set to false to disable access by default)
+// Force 2FA enrollment at next login
+$MAILBOX_DEFAULT_ATTRIBUTES['force_tfa'] = false;
+
+// Enable SOGo access - Users will be redirected to SOGo after login (set to false to disable redirect by default)
$MAILBOX_DEFAULT_ATTRIBUTES['sogo_access'] = true;
+// How to handle tagged emails
+// none - No special handling
+// subfolder - Create subfolder under INBOX (e.g. "INBOX/Facebook")
+// subject - Add tag to subject (e.g. "[Facebook] Subject")
+$MAILBOX_DEFAULT_ATTRIBUTES['tagged_mail_handler'] = "none";
+
// Send notification when quarantine is not empty (never, hourly, daily, weekly)
$MAILBOX_DEFAULT_ATTRIBUTES['quarantine_notification'] = 'hourly';
@@ -196,6 +223,12 @@
// Mailbox has sieve access by default
$MAILBOX_DEFAULT_ATTRIBUTES['sieve_access'] = true;
+// Mailbox has ActiveSync/EAS access by default
+$MAILBOX_DEFAULT_ATTRIBUTES['eas_access'] = true;
+
+// Mailbox has CalDAV/CardDAV (DAV) access by default
+$MAILBOX_DEFAULT_ATTRIBUTES['dav_access'] = true;
+
// Mailbox receives notifications about...
// "add_header" - mail that was put into the Junk folder
// "reject" - mail that was rejected
@@ -209,6 +242,16 @@
// Show last IMAP and POP3 logins
$SHOW_LAST_LOGIN = true;
+// Maximum number of password reset tokens that can be generated at once per user
+$PW_RESET_TOKEN_LIMIT = 3;
+
+// Maximum time in minutes a password reset token is valid
+$PW_RESET_TOKEN_LIFETIME = 15;
+
+// Globally forbid aliases with external (non-local) goto domains for ALL roles (incl. admins),
+// overriding the per-domain-admin da_acl. false = defer to da_acl.
+$ALIAS_DISABLE_EXTERNAL_DOMAINS = false;
+
// UV flag handling in FIDO2/WebAuthn - defaults to false to allow iOS logins
// true = required
// false = preferred
@@ -227,12 +270,12 @@
// Set visible Rspamd maps in mailcow UI, do not change unless you know what you are doing
$RSPAMD_MAPS = array(
'regex' => array(
- 'Header-From: Blacklist' => 'global_mime_from_blacklist.map',
- 'Header-From: Whitelist' => 'global_mime_from_whitelist.map',
- 'Envelope Sender Blacklist' => 'global_smtp_from_blacklist.map',
- 'Envelope Sender Whitelist' => 'global_smtp_from_whitelist.map',
- 'Recipient Blacklist' => 'global_rcpt_blacklist.map',
- 'Recipient Whitelist' => 'global_rcpt_whitelist.map',
+ 'Header-From: Denylist' => 'global_mime_from_blacklist.map',
+ 'Header-From: Allowlist' => 'global_mime_from_whitelist.map',
+ 'Envelope Sender Denylist' => 'global_smtp_from_blacklist.map',
+ 'Envelope Sender Allowlist' => 'global_smtp_from_whitelist.map',
+ 'Recipient Denylist' => 'global_rcpt_blacklist.map',
+ 'Recipient Allowlist' => 'global_rcpt_whitelist.map',
'Fishy TLDS (only fired in combination with bad words)' => 'fishy_tlds.map',
'Bad Words (only fired in combination with fishy TLDs)' => 'bad_words.map',
'Bad Words DE (only fired in combination with fishy TLDs)' => 'bad_words_de.map',
@@ -246,57 +289,57 @@
$IMAPSYNC_OPTIONS = array(
'whitelist' => array(
- 'abort',
- 'authmd51',
- 'authmd52',
+ 'abort',
+ 'authmd51',
+ 'authmd52',
'authmech1',
'authmech2',
- 'authuser1',
- 'authuser2',
- 'debug',
- 'debugcontent',
- 'debugcrossduplicates',
- 'debugflags',
- 'debugfolders',
- 'debugimap',
- 'debugimap1',
- 'debugimap2',
- 'debugmemory',
- 'debugssl',
+ 'authuser1',
+ 'authuser2',
+ 'debug',
+ 'debugcontent',
+ 'debugcrossduplicates',
+ 'debugflags',
+ 'debugfolders',
+ 'debugimap',
+ 'debugimap1',
+ 'debugimap2',
+ 'debugmemory',
+ 'debugssl',
'delete1emptyfolders',
- 'delete2folders',
- 'disarmreadreceipts',
+ 'delete2folders',
+ 'disarmreadreceipts',
'domain1',
'domain2',
- 'domino1',
- 'domino2',
+ 'domino1',
+ 'domino2',
'dry',
'errorsmax',
- 'exchange1',
- 'exchange2',
+ 'exchange1',
+ 'exchange2',
'exitwhenover',
'expunge1',
- 'f1f2',
- 'filterbuggyflags',
+ 'f1f2',
+ 'filterbuggyflags',
'folder',
'folderfirst',
'folderlast',
'folderrec',
- 'gmail1',
- 'gmail2',
- 'idatefromheader',
+ 'gmail1',
+ 'gmail2',
+ 'idatefromheader',
'include',
'inet4',
'inet6',
- 'justconnect',
- 'justfolders',
- 'justfoldersizes',
- 'justlogin',
- 'keepalive1',
- 'keepalive2',
+ 'justconnect',
+ 'justfolders',
+ 'justfoldersizes',
+ 'justlogin',
+ 'keepalive1',
+ 'keepalive2',
'log',
'logdir',
- 'logfile',
+ 'logfile',
'maxbytesafter',
'maxlinelength',
'maxmessagespersecond',
@@ -304,62 +347,62 @@
'maxsleep',
'minage',
'minsize',
- 'noabletosearch',
- 'noabletosearch1',
- 'noabletosearch2',
- 'noexpunge1',
- 'noexpunge2',
+ 'noabletosearch',
+ 'noabletosearch1',
+ 'noabletosearch2',
+ 'noexpunge1',
+ 'noexpunge2',
'nofoldersizesatend',
- 'noid',
- 'nolog',
- 'nomixfolders',
- 'noresyncflags',
- 'nossl1',
- 'nossl2',
- 'nosyncacls',
- 'notls1',
- 'notls2',
- 'nouidexpunge2',
- 'nousecache',
+ 'noid',
+ 'nolog',
+ 'nomixfolders',
+ 'noresyncflags',
+ 'nossl1',
+ 'nossl2',
+ 'nosyncacls',
+ 'notls1',
+ 'notls2',
+ 'nouidexpunge2',
+ 'nousecache',
'oauthaccesstoken1',
'oauthaccesstoken2',
'oauthdirect1',
'oauthdirect2',
- 'office1',
- 'office2',
- 'pidfile',
- 'pidfilelocking',
+ 'office1',
+ 'office2',
+ 'pidfile',
+ 'pidfilelocking',
'prefix1',
'prefix2',
- 'proxyauth1',
- 'proxyauth2',
- 'resyncflags',
- 'resynclabels',
- 'search',
+ 'proxyauth1',
+ 'proxyauth2',
+ 'resyncflags',
+ 'resynclabels',
+ 'search',
'search1',
- 'search2',
+ 'search2',
'sep1',
'sep2',
'showpasswords',
'skipemptyfolders',
- 'ssl2',
+ 'ssl2',
'sslargs1',
- 'sslargs2',
+ 'sslargs2',
'subfolder1',
- 'subscribe',
+ 'subscribe',
'subscribed',
'syncacls',
'syncduplicates',
'syncinternaldates',
- 'synclabels',
- 'tests',
- 'testslive',
- 'testslive6',
- 'tls2',
- 'truncmess',
- 'usecache',
- 'useheader',
- 'useuid'
+ 'synclabels',
+ 'tests',
+ 'testslive',
+ 'testslive6',
+ 'tls2',
+ 'truncmess',
+ 'usecache',
+ 'useheader',
+ 'useuid'
),
'blacklist' => array(
'skipmess',
diff --git a/mailcow/src/mailcow-dockerized/data/web/index.php b/mailcow/src/mailcow-dockerized/data/web/index.php
index 05b3a7f..b037c14 100644
--- a/mailcow/src/mailcow-dockerized/data/web/index.php
+++ b/mailcow/src/mailcow-dockerized/data/web/index.php
@@ -1,5 +1,6 @@
<?php
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.user.inc.php';
if (isset($_SESSION['mailcow_cc_role']) && isset($_SESSION['oauth2_request'])) {
$oauth2_request = $_SESSION['oauth2_request'];
@@ -7,16 +8,34 @@
header('Location: ' . $oauth2_request);
exit();
}
+elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'user') {
+ if (empty($_SESSION['pending_tfa_setup']) && empty($_SESSION['pending_pw_update'])) {
+ $user_details = mailbox("get", "mailbox_details", $_SESSION['mailcow_cc_username']);
+ $is_dual = (!empty($_SESSION["dual-login"]["username"])) ? true : false;
+ if (intval($user_details['attributes']['sogo_access']) == 1 && !$is_dual && getenv('SKIP_SOGO') != "y") {
+ header("Location: /SOGo/so/");
+ } else {
+ header("Location: /user");
+ }
+ exit();
+ }
+}
elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'admin') {
- header('Location: /debug');
- exit();
+ if (empty($_SESSION['pending_tfa_setup']) && empty($_SESSION['pending_pw_update'])) {
+ header('Location: /admin/dashboard');
+ exit();
+ }
}
elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'domainadmin') {
- header('Location: /mailbox');
- exit();
+ if (empty($_SESSION['pending_tfa_setup']) && empty($_SESSION['pending_pw_update'])) {
+ header('Location: /domainadmin/mailbox');
+ exit();
+ }
}
-elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'user') {
- header('Location: /user');
+
+$host = strtolower($_SERVER['HTTP_HOST'] ?? '');
+if (str_starts_with($host, 'autodiscover.') || str_starts_with($host, 'autoconfig.')) {
+ http_response_code(404);
exit();
}
@@ -24,11 +43,20 @@
$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
$_SESSION['index_query_string'] = $_SERVER['QUERY_STRING'];
-$template = 'index.twig';
+$has_iam_sso = false;
+if ($iam_provider){
+ $iam_redirect_url = identity_provider("get-redirect");
+ $has_iam_sso = $iam_redirect_url ? true : false;
+}
+$custom_login = customize('get', 'custom_login');
+
+$template = 'user_index.twig';
$template_data = [
'oauth2_request' => @$_SESSION['oauth2_request'],
'is_mobileconfig' => str_contains($_SESSION['index_query_string'], 'mobileconfig'),
'login_delay' => @$_SESSION['ldelay'],
+ 'has_iam_sso' => $has_iam_sso,
+ 'custom_login' => $custom_login,
];
$js_minifier->add('/web/js/site/index.js');
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/build/001-bootstrap.bundle.min.js b/mailcow/src/mailcow-dockerized/data/web/js/build/001-bootstrap.bundle.min.js
index cc0a255..0b87369 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/build/001-bootstrap.bundle.min.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/build/001-bootstrap.bundle.min.js
@@ -1,7 +1,7 @@
/*!
- * Bootstrap v5.1.3 (https://getbootstrap.com/)
- * Copyright 2011-2021 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
+ * Bootstrap v5.3.8 (https://getbootstrap.com/)
+ * Copyright 2011-2025 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
-!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).bootstrap=e()}(this,(function(){"use strict";const t="transitionend",e=t=>{let e=t.getAttribute("data-bs-target");if(!e||"#"===e){let i=t.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i=`#${i.split("#")[1]}`),e=i&&"#"!==i?i.trim():null}return e},i=t=>{const i=e(t);return i&&document.querySelector(i)?i:null},n=t=>{const i=e(t);return i?document.querySelector(i):null},s=e=>{e.dispatchEvent(new Event(t))},o=t=>!(!t||"object"!=typeof t)&&(void 0!==t.jquery&&(t=t[0]),void 0!==t.nodeType),r=t=>o(t)?t.jquery?t[0]:t:"string"==typeof t&&t.length>0?document.querySelector(t):null,a=(t,e,i)=>{Object.keys(i).forEach((n=>{const s=i[n],r=e[n],a=r&&o(r)?"element":null==(l=r)?`${l}`:{}.toString.call(l).match(/\s([a-z]+)/i)[1].toLowerCase();var l;if(!new RegExp(s).test(a))throw new TypeError(`${t.toUpperCase()}: Option "${n}" provided type "${a}" but expected type "${s}".`)}))},l=t=>!(!o(t)||0===t.getClientRects().length)&&"visible"===getComputedStyle(t).getPropertyValue("visibility"),c=t=>!t||t.nodeType!==Node.ELEMENT_NODE||!!t.classList.contains("disabled")||(void 0!==t.disabled?t.disabled:t.hasAttribute("disabled")&&"false"!==t.getAttribute("disabled")),h=t=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof t.getRootNode){const e=t.getRootNode();return e instanceof ShadowRoot?e:null}return t instanceof ShadowRoot?t:t.parentNode?h(t.parentNode):null},d=()=>{},u=t=>{t.offsetHeight},f=()=>{const{jQuery:t}=window;return t&&!document.body.hasAttribute("data-bs-no-jquery")?t:null},p=[],m=()=>"rtl"===document.documentElement.dir,g=t=>{var e;e=()=>{const e=f();if(e){const i=t.NAME,n=e.fn[i];e.fn[i]=t.jQueryInterface,e.fn[i].Constructor=t,e.fn[i].noConflict=()=>(e.fn[i]=n,t.jQueryInterface)}},"loading"===document.readyState?(p.length||document.addEventListener("DOMContentLoaded",(()=>{p.forEach((t=>t()))})),p.push(e)):e()},_=t=>{"function"==typeof t&&t()},b=(e,i,n=!0)=>{if(!n)return void _(e);const o=(t=>{if(!t)return 0;let{transitionDuration:e,transitionDelay:i}=window.getComputedStyle(t);const n=Number.parseFloat(e),s=Number.parseFloat(i);return n||s?(e=e.split(",")[0],i=i.split(",")[0],1e3*(Number.parseFloat(e)+Number.parseFloat(i))):0})(i)+5;let r=!1;const a=({target:n})=>{n===i&&(r=!0,i.removeEventListener(t,a),_(e))};i.addEventListener(t,a),setTimeout((()=>{r||s(i)}),o)},v=(t,e,i,n)=>{let s=t.indexOf(e);if(-1===s)return t[!i&&n?t.length-1:0];const o=t.length;return s+=i?1:-1,n&&(s=(s+o)%o),t[Math.max(0,Math.min(s,o-1))]},y=/[^.]*(?=\..*)\.|.*/,w=/\..*/,E=/::\d+$/,A={};let T=1;const O={mouseenter:"mouseover",mouseleave:"mouseout"},C=/^(mouseenter|mouseleave)/i,k=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function L(t,e){return e&&`${e}::${T++}`||t.uidEvent||T++}function x(t){const e=L(t);return t.uidEvent=e,A[e]=A[e]||{},A[e]}function D(t,e,i=null){const n=Object.keys(t);for(let s=0,o=n.length;s<o;s++){const o=t[n[s]];if(o.originalHandler===e&&o.delegationSelector===i)return o}return null}function S(t,e,i){const n="string"==typeof e,s=n?i:e;let o=P(t);return k.has(o)||(o=t),[n,s,o]}function N(t,e,i,n,s){if("string"!=typeof e||!t)return;if(i||(i=n,n=null),C.test(e)){const t=t=>function(e){if(!e.relatedTarget||e.relatedTarget!==e.delegateTarget&&!e.delegateTarget.contains(e.relatedTarget))return t.call(this,e)};n?n=t(n):i=t(i)}const[o,r,a]=S(e,i,n),l=x(t),c=l[a]||(l[a]={}),h=D(c,r,o?i:null);if(h)return void(h.oneOff=h.oneOff&&s);const d=L(r,e.replace(y,"")),u=o?function(t,e,i){return function n(s){const o=t.querySelectorAll(e);for(let{target:r}=s;r&&r!==this;r=r.parentNode)for(let a=o.length;a--;)if(o[a]===r)return s.delegateTarget=r,n.oneOff&&j.off(t,s.type,e,i),i.apply(r,[s]);return null}}(t,i,n):function(t,e){return function i(n){return n.delegateTarget=t,i.oneOff&&j.off(t,n.type,e),e.apply(t,[n])}}(t,i);u.delegationSelector=o?i:null,u.originalHandler=r,u.oneOff=s,u.uidEvent=d,c[d]=u,t.addEventListener(a,u,o)}function I(t,e,i,n,s){const o=D(e[i],n,s);o&&(t.removeEventListener(i,o,Boolean(s)),delete e[i][o.uidEvent])}function P(t){return t=t.replace(w,""),O[t]||t}const j={on(t,e,i,n){N(t,e,i,n,!1)},one(t,e,i,n){N(t,e,i,n,!0)},off(t,e,i,n){if("string"!=typeof e||!t)return;const[s,o,r]=S(e,i,n),a=r!==e,l=x(t),c=e.startsWith(".");if(void 0!==o){if(!l||!l[r])return;return void I(t,l,r,o,s?i:null)}c&&Object.keys(l).forEach((i=>{!function(t,e,i,n){const s=e[i]||{};Object.keys(s).forEach((o=>{if(o.includes(n)){const n=s[o];I(t,e,i,n.originalHandler,n.delegationSelector)}}))}(t,l,i,e.slice(1))}));const h=l[r]||{};Object.keys(h).forEach((i=>{const n=i.replace(E,"");if(!a||e.includes(n)){const e=h[i];I(t,l,r,e.originalHandler,e.delegationSelector)}}))},trigger(t,e,i){if("string"!=typeof e||!t)return null;const n=f(),s=P(e),o=e!==s,r=k.has(s);let a,l=!0,c=!0,h=!1,d=null;return o&&n&&(a=n.Event(e,i),n(t).trigger(a),l=!a.isPropagationStopped(),c=!a.isImmediatePropagationStopped(),h=a.isDefaultPrevented()),r?(d=document.createEvent("HTMLEvents"),d.initEvent(s,l,!0)):d=new CustomEvent(e,{bubbles:l,cancelable:!0}),void 0!==i&&Object.keys(i).forEach((t=>{Object.defineProperty(d,t,{get:()=>i[t]})})),h&&d.preventDefault(),c&&t.dispatchEvent(d),d.defaultPrevented&&void 0!==a&&a.preventDefault(),d}},M=new Map,H={set(t,e,i){M.has(t)||M.set(t,new Map);const n=M.get(t);n.has(e)||0===n.size?n.set(e,i):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(n.keys())[0]}.`)},get:(t,e)=>M.has(t)&&M.get(t).get(e)||null,remove(t,e){if(!M.has(t))return;const i=M.get(t);i.delete(e),0===i.size&&M.delete(t)}};class B{constructor(t){(t=r(t))&&(this._element=t,H.set(this._element,this.constructor.DATA_KEY,this))}dispose(){H.remove(this._element,this.constructor.DATA_KEY),j.off(this._element,this.constructor.EVENT_KEY),Object.getOwnPropertyNames(this).forEach((t=>{this[t]=null}))}_queueCallback(t,e,i=!0){b(t,e,i)}static getInstance(t){return H.get(r(t),this.DATA_KEY)}static getOrCreateInstance(t,e={}){return this.getInstance(t)||new this(t,"object"==typeof e?e:null)}static get VERSION(){return"5.1.3"}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}}const R=(t,e="hide")=>{const i=`click.dismiss${t.EVENT_KEY}`,s=t.NAME;j.on(document,i,`[data-bs-dismiss="${s}"]`,(function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),c(this))return;const o=n(this)||this.closest(`.${s}`);t.getOrCreateInstance(o)[e]()}))};class W extends B{static get NAME(){return"alert"}close(){if(j.trigger(this._element,"close.bs.alert").defaultPrevented)return;this._element.classList.remove("show");const t=this._element.classList.contains("fade");this._queueCallback((()=>this._destroyElement()),this._element,t)}_destroyElement(){this._element.remove(),j.trigger(this._element,"closed.bs.alert"),this.dispose()}static jQueryInterface(t){return this.each((function(){const e=W.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}R(W,"close"),g(W);const $='[data-bs-toggle="button"]';class z extends B{static get NAME(){return"button"}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(t){return this.each((function(){const e=z.getOrCreateInstance(this);"toggle"===t&&e[t]()}))}}function q(t){return"true"===t||"false"!==t&&(t===Number(t).toString()?Number(t):""===t||"null"===t?null:t)}function F(t){return t.replace(/[A-Z]/g,(t=>`-${t.toLowerCase()}`))}j.on(document,"click.bs.button.data-api",$,(t=>{t.preventDefault();const e=t.target.closest($);z.getOrCreateInstance(e).toggle()})),g(z);const U={setDataAttribute(t,e,i){t.setAttribute(`data-bs-${F(e)}`,i)},removeDataAttribute(t,e){t.removeAttribute(`data-bs-${F(e)}`)},getDataAttributes(t){if(!t)return{};const e={};return Object.keys(t.dataset).filter((t=>t.startsWith("bs"))).forEach((i=>{let n=i.replace(/^bs/,"");n=n.charAt(0).toLowerCase()+n.slice(1,n.length),e[n]=q(t.dataset[i])})),e},getDataAttribute:(t,e)=>q(t.getAttribute(`data-bs-${F(e)}`)),offset(t){const e=t.getBoundingClientRect();return{top:e.top+window.pageYOffset,left:e.left+window.pageXOffset}},position:t=>({top:t.offsetTop,left:t.offsetLeft})},V={find:(t,e=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(e,t)),findOne:(t,e=document.documentElement)=>Element.prototype.querySelector.call(e,t),children:(t,e)=>[].concat(...t.children).filter((t=>t.matches(e))),parents(t,e){const i=[];let n=t.parentNode;for(;n&&n.nodeType===Node.ELEMENT_NODE&&3!==n.nodeType;)n.matches(e)&&i.push(n),n=n.parentNode;return i},prev(t,e){let i=t.previousElementSibling;for(;i;){if(i.matches(e))return[i];i=i.previousElementSibling}return[]},next(t,e){let i=t.nextElementSibling;for(;i;){if(i.matches(e))return[i];i=i.nextElementSibling}return[]},focusableChildren(t){const e=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((t=>`${t}:not([tabindex^="-"])`)).join(", ");return this.find(e,t).filter((t=>!c(t)&&l(t)))}},K="carousel",X={interval:5e3,keyboard:!0,slide:!1,pause:"hover",wrap:!0,touch:!0},Y={interval:"(number|boolean)",keyboard:"boolean",slide:"(boolean|string)",pause:"(string|boolean)",wrap:"boolean",touch:"boolean"},Q="next",G="prev",Z="left",J="right",tt={ArrowLeft:J,ArrowRight:Z},et="slid.bs.carousel",it="active",nt=".active.carousel-item";class st extends B{constructor(t,e){super(t),this._items=null,this._interval=null,this._activeElement=null,this._isPaused=!1,this._isSliding=!1,this.touchTimeout=null,this.touchStartX=0,this.touchDeltaX=0,this._config=this._getConfig(e),this._indicatorsElement=V.findOne(".carousel-indicators",this._element),this._touchSupported="ontouchstart"in document.documentElement||navigator.maxTouchPoints>0,this._pointerEvent=Boolean(window.PointerEvent),this._addEventListeners()}static get Default(){return X}static get NAME(){return K}next(){this._slide(Q)}nextWhenVisible(){!document.hidden&&l(this._element)&&this.next()}prev(){this._slide(G)}pause(t){t||(this._isPaused=!0),V.findOne(".carousel-item-next, .carousel-item-prev",this._element)&&(s(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null}cycle(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config&&this._config.interval&&!this._isPaused&&(this._updateInterval(),this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))}to(t){this._activeElement=V.findOne(nt,this._element);const e=this._getItemIndex(this._activeElement);if(t>this._items.length-1||t<0)return;if(this._isSliding)return void j.one(this._element,et,(()=>this.to(t)));if(e===t)return this.pause(),void this.cycle();const i=t>e?Q:G;this._slide(i,this._items[t])}_getConfig(t){return t={...X,...U.getDataAttributes(this._element),..."object"==typeof t?t:{}},a(K,t,Y),t}_handleSwipe(){const t=Math.abs(this.touchDeltaX);if(t<=40)return;const e=t/this.touchDeltaX;this.touchDeltaX=0,e&&this._slide(e>0?J:Z)}_addEventListeners(){this._config.keyboard&&j.on(this._element,"keydown.bs.carousel",(t=>this._keydown(t))),"hover"===this._config.pause&&(j.on(this._element,"mouseenter.bs.carousel",(t=>this.pause(t))),j.on(this._element,"mouseleave.bs.carousel",(t=>this.cycle(t)))),this._config.touch&&this._touchSupported&&this._addTouchEventListeners()}_addTouchEventListeners(){const t=t=>this._pointerEvent&&("pen"===t.pointerType||"touch"===t.pointerType),e=e=>{t(e)?this.touchStartX=e.clientX:this._pointerEvent||(this.touchStartX=e.touches[0].clientX)},i=t=>{this.touchDeltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this.touchStartX},n=e=>{t(e)&&(this.touchDeltaX=e.clientX-this.touchStartX),this._handleSwipe(),"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((t=>this.cycle(t)),500+this._config.interval))};V.find(".carousel-item img",this._element).forEach((t=>{j.on(t,"dragstart.bs.carousel",(t=>t.preventDefault()))})),this._pointerEvent?(j.on(this._element,"pointerdown.bs.carousel",(t=>e(t))),j.on(this._element,"pointerup.bs.carousel",(t=>n(t))),this._element.classList.add("pointer-event")):(j.on(this._element,"touchstart.bs.carousel",(t=>e(t))),j.on(this._element,"touchmove.bs.carousel",(t=>i(t))),j.on(this._element,"touchend.bs.carousel",(t=>n(t))))}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;const e=tt[t.key];e&&(t.preventDefault(),this._slide(e))}_getItemIndex(t){return this._items=t&&t.parentNode?V.find(".carousel-item",t.parentNode):[],this._items.indexOf(t)}_getItemByOrder(t,e){const i=t===Q;return v(this._items,e,i,this._config.wrap)}_triggerSlideEvent(t,e){const i=this._getItemIndex(t),n=this._getItemIndex(V.findOne(nt,this._element));return j.trigger(this._element,"slide.bs.carousel",{relatedTarget:t,direction:e,from:n,to:i})}_setActiveIndicatorElement(t){if(this._indicatorsElement){const e=V.findOne(".active",this._indicatorsElement);e.classList.remove(it),e.removeAttribute("aria-current");const i=V.find("[data-bs-target]",this._indicatorsElement);for(let e=0;e<i.length;e++)if(Number.parseInt(i[e].getAttribute("data-bs-slide-to"),10)===this._getItemIndex(t)){i[e].classList.add(it),i[e].setAttribute("aria-current","true");break}}}_updateInterval(){const t=this._activeElement||V.findOne(nt,this._element);if(!t)return;const e=Number.parseInt(t.getAttribute("data-bs-interval"),10);e?(this._config.defaultInterval=this._config.defaultInterval||this._config.interval,this._config.interval=e):this._config.interval=this._config.defaultInterval||this._config.interval}_slide(t,e){const i=this._directionToOrder(t),n=V.findOne(nt,this._element),s=this._getItemIndex(n),o=e||this._getItemByOrder(i,n),r=this._getItemIndex(o),a=Boolean(this._interval),l=i===Q,c=l?"carousel-item-start":"carousel-item-end",h=l?"carousel-item-next":"carousel-item-prev",d=this._orderToDirection(i);if(o&&o.classList.contains(it))return void(this._isSliding=!1);if(this._isSliding)return;if(this._triggerSlideEvent(o,d).defaultPrevented)return;if(!n||!o)return;this._isSliding=!0,a&&this.pause(),this._setActiveIndicatorElement(o),this._activeElement=o;const f=()=>{j.trigger(this._element,et,{relatedTarget:o,direction:d,from:s,to:r})};if(this._element.classList.contains("slide")){o.classList.add(h),u(o),n.classList.add(c),o.classList.add(c);const t=()=>{o.classList.remove(c,h),o.classList.add(it),n.classList.remove(it,h,c),this._isSliding=!1,setTimeout(f,0)};this._queueCallback(t,n,!0)}else n.classList.remove(it),o.classList.add(it),this._isSliding=!1,f();a&&this.cycle()}_directionToOrder(t){return[J,Z].includes(t)?m()?t===Z?G:Q:t===Z?Q:G:t}_orderToDirection(t){return[Q,G].includes(t)?m()?t===G?Z:J:t===G?J:Z:t}static carouselInterface(t,e){const i=st.getOrCreateInstance(t,e);let{_config:n}=i;"object"==typeof e&&(n={...n,...e});const s="string"==typeof e?e:n.slide;if("number"==typeof e)i.to(e);else if("string"==typeof s){if(void 0===i[s])throw new TypeError(`No method named "${s}"`);i[s]()}else n.interval&&n.ride&&(i.pause(),i.cycle())}static jQueryInterface(t){return this.each((function(){st.carouselInterface(this,t)}))}static dataApiClickHandler(t){const e=n(this);if(!e||!e.classList.contains("carousel"))return;const i={...U.getDataAttributes(e),...U.getDataAttributes(this)},s=this.getAttribute("data-bs-slide-to");s&&(i.interval=!1),st.carouselInterface(e,i),s&&st.getInstance(e).to(s),t.preventDefault()}}j.on(document,"click.bs.carousel.data-api","[data-bs-slide], [data-bs-slide-to]",st.dataApiClickHandler),j.on(window,"load.bs.carousel.data-api",(()=>{const t=V.find('[data-bs-ride="carousel"]');for(let e=0,i=t.length;e<i;e++)st.carouselInterface(t[e],st.getInstance(t[e]))})),g(st);const ot="collapse",rt={toggle:!0,parent:null},at={toggle:"boolean",parent:"(null|element)"},lt="show",ct="collapse",ht="collapsing",dt="collapsed",ut=":scope .collapse .collapse",ft='[data-bs-toggle="collapse"]';class pt extends B{constructor(t,e){super(t),this._isTransitioning=!1,this._config=this._getConfig(e),this._triggerArray=[];const n=V.find(ft);for(let t=0,e=n.length;t<e;t++){const e=n[t],s=i(e),o=V.find(s).filter((t=>t===this._element));null!==s&&o.length&&(this._selector=s,this._triggerArray.push(e))}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return rt}static get NAME(){return ot}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t,e=[];if(this._config.parent){const t=V.find(ut,this._config.parent);e=V.find(".collapse.show, .collapse.collapsing",this._config.parent).filter((e=>!t.includes(e)))}const i=V.findOne(this._selector);if(e.length){const n=e.find((t=>i!==t));if(t=n?pt.getInstance(n):null,t&&t._isTransitioning)return}if(j.trigger(this._element,"show.bs.collapse").defaultPrevented)return;e.forEach((e=>{i!==e&&pt.getOrCreateInstance(e,{toggle:!1}).hide(),t||H.set(e,"bs.collapse",null)}));const n=this._getDimension();this._element.classList.remove(ct),this._element.classList.add(ht),this._element.style[n]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const s=`scroll${n[0].toUpperCase()+n.slice(1)}`;this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(ht),this._element.classList.add(ct,lt),this._element.style[n]="",j.trigger(this._element,"shown.bs.collapse")}),this._element,!0),this._element.style[n]=`${this._element[s]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(j.trigger(this._element,"hide.bs.collapse").defaultPrevented)return;const t=this._getDimension();this._element.style[t]=`${this._element.getBoundingClientRect()[t]}px`,u(this._element),this._element.classList.add(ht),this._element.classList.remove(ct,lt);const e=this._triggerArray.length;for(let t=0;t<e;t++){const e=this._triggerArray[t],i=n(e);i&&!this._isShown(i)&&this._addAriaAndCollapsedClass([e],!1)}this._isTransitioning=!0,this._element.style[t]="",this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(ht),this._element.classList.add(ct),j.trigger(this._element,"hidden.bs.collapse")}),this._element,!0)}_isShown(t=this._element){return t.classList.contains(lt)}_getConfig(t){return(t={...rt,...U.getDataAttributes(this._element),...t}).toggle=Boolean(t.toggle),t.parent=r(t.parent),a(ot,t,at),t}_getDimension(){return this._element.classList.contains("collapse-horizontal")?"width":"height"}_initializeChildren(){if(!this._config.parent)return;const t=V.find(ut,this._config.parent);V.find(ft,this._config.parent).filter((e=>!t.includes(e))).forEach((t=>{const e=n(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))}))}_addAriaAndCollapsedClass(t,e){t.length&&t.forEach((t=>{e?t.classList.remove(dt):t.classList.add(dt),t.setAttribute("aria-expanded",e)}))}static jQueryInterface(t){return this.each((function(){const e={};"string"==typeof t&&/show|hide/.test(t)&&(e.toggle=!1);const i=pt.getOrCreateInstance(this,e);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}))}}j.on(document,"click.bs.collapse.data-api",ft,(function(t){("A"===t.target.tagName||t.delegateTarget&&"A"===t.delegateTarget.tagName)&&t.preventDefault();const e=i(this);V.find(e).forEach((t=>{pt.getOrCreateInstance(t,{toggle:!1}).toggle()}))})),g(pt);var mt="top",gt="bottom",_t="right",bt="left",vt="auto",yt=[mt,gt,_t,bt],wt="start",Et="end",At="clippingParents",Tt="viewport",Ot="popper",Ct="reference",kt=yt.reduce((function(t,e){return t.concat([e+"-"+wt,e+"-"+Et])}),[]),Lt=[].concat(yt,[vt]).reduce((function(t,e){return t.concat([e,e+"-"+wt,e+"-"+Et])}),[]),xt="beforeRead",Dt="read",St="afterRead",Nt="beforeMain",It="main",Pt="afterMain",jt="beforeWrite",Mt="write",Ht="afterWrite",Bt=[xt,Dt,St,Nt,It,Pt,jt,Mt,Ht];function Rt(t){return t?(t.nodeName||"").toLowerCase():null}function Wt(t){if(null==t)return window;if("[object Window]"!==t.toString()){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function $t(t){return t instanceof Wt(t).Element||t instanceof Element}function zt(t){return t instanceof Wt(t).HTMLElement||t instanceof HTMLElement}function qt(t){return"undefined"!=typeof ShadowRoot&&(t instanceof Wt(t).ShadowRoot||t instanceof ShadowRoot)}const Ft={name:"applyStyles",enabled:!0,phase:"write",fn:function(t){var e=t.state;Object.keys(e.elements).forEach((function(t){var i=e.styles[t]||{},n=e.attributes[t]||{},s=e.elements[t];zt(s)&&Rt(s)&&(Object.assign(s.style,i),Object.keys(n).forEach((function(t){var e=n[t];!1===e?s.removeAttribute(t):s.setAttribute(t,!0===e?"":e)})))}))},effect:function(t){var e=t.state,i={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,i.popper),e.styles=i,e.elements.arrow&&Object.assign(e.elements.arrow.style,i.arrow),function(){Object.keys(e.elements).forEach((function(t){var n=e.elements[t],s=e.attributes[t]||{},o=Object.keys(e.styles.hasOwnProperty(t)?e.styles[t]:i[t]).reduce((function(t,e){return t[e]="",t}),{});zt(n)&&Rt(n)&&(Object.assign(n.style,o),Object.keys(s).forEach((function(t){n.removeAttribute(t)})))}))}},requires:["computeStyles"]};function Ut(t){return t.split("-")[0]}function Vt(t,e){var i=t.getBoundingClientRect();return{width:i.width/1,height:i.height/1,top:i.top/1,right:i.right/1,bottom:i.bottom/1,left:i.left/1,x:i.left/1,y:i.top/1}}function Kt(t){var e=Vt(t),i=t.offsetWidth,n=t.offsetHeight;return Math.abs(e.width-i)<=1&&(i=e.width),Math.abs(e.height-n)<=1&&(n=e.height),{x:t.offsetLeft,y:t.offsetTop,width:i,height:n}}function Xt(t,e){var i=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(i&&qt(i)){var n=e;do{if(n&&t.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Yt(t){return Wt(t).getComputedStyle(t)}function Qt(t){return["table","td","th"].indexOf(Rt(t))>=0}function Gt(t){return(($t(t)?t.ownerDocument:t.document)||window.document).documentElement}function Zt(t){return"html"===Rt(t)?t:t.assignedSlot||t.parentNode||(qt(t)?t.host:null)||Gt(t)}function Jt(t){return zt(t)&&"fixed"!==Yt(t).position?t.offsetParent:null}function te(t){for(var e=Wt(t),i=Jt(t);i&&Qt(i)&&"static"===Yt(i).position;)i=Jt(i);return i&&("html"===Rt(i)||"body"===Rt(i)&&"static"===Yt(i).position)?e:i||function(t){var e=-1!==navigator.userAgent.toLowerCase().indexOf("firefox");if(-1!==navigator.userAgent.indexOf("Trident")&&zt(t)&&"fixed"===Yt(t).position)return null;for(var i=Zt(t);zt(i)&&["html","body"].indexOf(Rt(i))<0;){var n=Yt(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||e&&"filter"===n.willChange||e&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}(t)||e}function ee(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}var ie=Math.max,ne=Math.min,se=Math.round;function oe(t,e,i){return ie(t,ne(e,i))}function re(t){return Object.assign({},{top:0,right:0,bottom:0,left:0},t)}function ae(t,e){return e.reduce((function(e,i){return e[i]=t,e}),{})}const le={name:"arrow",enabled:!0,phase:"main",fn:function(t){var e,i=t.state,n=t.name,s=t.options,o=i.elements.arrow,r=i.modifiersData.popperOffsets,a=Ut(i.placement),l=ee(a),c=[bt,_t].indexOf(a)>=0?"height":"width";if(o&&r){var h=function(t,e){return re("number"!=typeof(t="function"==typeof t?t(Object.assign({},e.rects,{placement:e.placement})):t)?t:ae(t,yt))}(s.padding,i),d=Kt(o),u="y"===l?mt:bt,f="y"===l?gt:_t,p=i.rects.reference[c]+i.rects.reference[l]-r[l]-i.rects.popper[c],m=r[l]-i.rects.reference[l],g=te(o),_=g?"y"===l?g.clientHeight||0:g.clientWidth||0:0,b=p/2-m/2,v=h[u],y=_-d[c]-h[f],w=_/2-d[c]/2+b,E=oe(v,w,y),A=l;i.modifiersData[n]=((e={})[A]=E,e.centerOffset=E-w,e)}},effect:function(t){var e=t.state,i=t.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=e.elements.popper.querySelector(n)))&&Xt(e.elements.popper,n)&&(e.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ce(t){return t.split("-")[1]}var he={top:"auto",right:"auto",bottom:"auto",left:"auto"};function de(t){var e,i=t.popper,n=t.popperRect,s=t.placement,o=t.variation,r=t.offsets,a=t.position,l=t.gpuAcceleration,c=t.adaptive,h=t.roundOffsets,d=!0===h?function(t){var e=t.x,i=t.y,n=window.devicePixelRatio||1;return{x:se(se(e*n)/n)||0,y:se(se(i*n)/n)||0}}(r):"function"==typeof h?h(r):r,u=d.x,f=void 0===u?0:u,p=d.y,m=void 0===p?0:p,g=r.hasOwnProperty("x"),_=r.hasOwnProperty("y"),b=bt,v=mt,y=window;if(c){var w=te(i),E="clientHeight",A="clientWidth";w===Wt(i)&&"static"!==Yt(w=Gt(i)).position&&"absolute"===a&&(E="scrollHeight",A="scrollWidth"),w=w,s!==mt&&(s!==bt&&s!==_t||o!==Et)||(v=gt,m-=w[E]-n.height,m*=l?1:-1),s!==bt&&(s!==mt&&s!==gt||o!==Et)||(b=_t,f-=w[A]-n.width,f*=l?1:-1)}var T,O=Object.assign({position:a},c&&he);return l?Object.assign({},O,((T={})[v]=_?"0":"",T[b]=g?"0":"",T.transform=(y.devicePixelRatio||1)<=1?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",T)):Object.assign({},O,((e={})[v]=_?m+"px":"",e[b]=g?f+"px":"",e.transform="",e))}const ue={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(t){var e=t.state,i=t.options,n=i.gpuAcceleration,s=void 0===n||n,o=i.adaptive,r=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:Ut(e.placement),variation:ce(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:s};null!=e.modifiersData.popperOffsets&&(e.styles.popper=Object.assign({},e.styles.popper,de(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:r,roundOffsets:l})))),null!=e.modifiersData.arrow&&(e.styles.arrow=Object.assign({},e.styles.arrow,de(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})},data:{}};var fe={passive:!0};const pe={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(t){var e=t.state,i=t.instance,n=t.options,s=n.scroll,o=void 0===s||s,r=n.resize,a=void 0===r||r,l=Wt(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return o&&c.forEach((function(t){t.addEventListener("scroll",i.update,fe)})),a&&l.addEventListener("resize",i.update,fe),function(){o&&c.forEach((function(t){t.removeEventListener("scroll",i.update,fe)})),a&&l.removeEventListener("resize",i.update,fe)}},data:{}};var me={left:"right",right:"left",bottom:"top",top:"bottom"};function ge(t){return t.replace(/left|right|bottom|top/g,(function(t){return me[t]}))}var _e={start:"end",end:"start"};function be(t){return t.replace(/start|end/g,(function(t){return _e[t]}))}function ve(t){var e=Wt(t);return{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function ye(t){return Vt(Gt(t)).left+ve(t).scrollLeft}function we(t){var e=Yt(t),i=e.overflow,n=e.overflowX,s=e.overflowY;return/auto|scroll|overlay|hidden/.test(i+s+n)}function Ee(t){return["html","body","#document"].indexOf(Rt(t))>=0?t.ownerDocument.body:zt(t)&&we(t)?t:Ee(Zt(t))}function Ae(t,e){var i;void 0===e&&(e=[]);var n=Ee(t),s=n===(null==(i=t.ownerDocument)?void 0:i.body),o=Wt(n),r=s?[o].concat(o.visualViewport||[],we(n)?n:[]):n,a=e.concat(r);return s?a:a.concat(Ae(Zt(r)))}function Te(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function Oe(t,e){return e===Tt?Te(function(t){var e=Wt(t),i=Gt(t),n=e.visualViewport,s=i.clientWidth,o=i.clientHeight,r=0,a=0;return n&&(s=n.width,o=n.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(r=n.offsetLeft,a=n.offsetTop)),{width:s,height:o,x:r+ye(t),y:a}}(t)):zt(e)?function(t){var e=Vt(t);return e.top=e.top+t.clientTop,e.left=e.left+t.clientLeft,e.bottom=e.top+t.clientHeight,e.right=e.left+t.clientWidth,e.width=t.clientWidth,e.height=t.clientHeight,e.x=e.left,e.y=e.top,e}(e):Te(function(t){var e,i=Gt(t),n=ve(t),s=null==(e=t.ownerDocument)?void 0:e.body,o=ie(i.scrollWidth,i.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),r=ie(i.scrollHeight,i.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),a=-n.scrollLeft+ye(t),l=-n.scrollTop;return"rtl"===Yt(s||i).direction&&(a+=ie(i.clientWidth,s?s.clientWidth:0)-o),{width:o,height:r,x:a,y:l}}(Gt(t)))}function Ce(t){var e,i=t.reference,n=t.element,s=t.placement,o=s?Ut(s):null,r=s?ce(s):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case mt:e={x:a,y:i.y-n.height};break;case gt:e={x:a,y:i.y+i.height};break;case _t:e={x:i.x+i.width,y:l};break;case bt:e={x:i.x-n.width,y:l};break;default:e={x:i.x,y:i.y}}var c=o?ee(o):null;if(null!=c){var h="y"===c?"height":"width";switch(r){case wt:e[c]=e[c]-(i[h]/2-n[h]/2);break;case Et:e[c]=e[c]+(i[h]/2-n[h]/2)}}return e}function ke(t,e){void 0===e&&(e={});var i=e,n=i.placement,s=void 0===n?t.placement:n,o=i.boundary,r=void 0===o?At:o,a=i.rootBoundary,l=void 0===a?Tt:a,c=i.elementContext,h=void 0===c?Ot:c,d=i.altBoundary,u=void 0!==d&&d,f=i.padding,p=void 0===f?0:f,m=re("number"!=typeof p?p:ae(p,yt)),g=h===Ot?Ct:Ot,_=t.rects.popper,b=t.elements[u?g:h],v=function(t,e,i){var n="clippingParents"===e?function(t){var e=Ae(Zt(t)),i=["absolute","fixed"].indexOf(Yt(t).position)>=0&&zt(t)?te(t):t;return $t(i)?e.filter((function(t){return $t(t)&&Xt(t,i)&&"body"!==Rt(t)})):[]}(t):[].concat(e),s=[].concat(n,[i]),o=s[0],r=s.reduce((function(e,i){var n=Oe(t,i);return e.top=ie(n.top,e.top),e.right=ne(n.right,e.right),e.bottom=ne(n.bottom,e.bottom),e.left=ie(n.left,e.left),e}),Oe(t,o));return r.width=r.right-r.left,r.height=r.bottom-r.top,r.x=r.left,r.y=r.top,r}($t(b)?b:b.contextElement||Gt(t.elements.popper),r,l),y=Vt(t.elements.reference),w=Ce({reference:y,element:_,strategy:"absolute",placement:s}),E=Te(Object.assign({},_,w)),A=h===Ot?E:y,T={top:v.top-A.top+m.top,bottom:A.bottom-v.bottom+m.bottom,left:v.left-A.left+m.left,right:A.right-v.right+m.right},O=t.modifiersData.offset;if(h===Ot&&O){var C=O[s];Object.keys(T).forEach((function(t){var e=[_t,gt].indexOf(t)>=0?1:-1,i=[mt,gt].indexOf(t)>=0?"y":"x";T[t]+=C[i]*e}))}return T}function Le(t,e){void 0===e&&(e={});var i=e,n=i.placement,s=i.boundary,o=i.rootBoundary,r=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?Lt:l,h=ce(n),d=h?a?kt:kt.filter((function(t){return ce(t)===h})):yt,u=d.filter((function(t){return c.indexOf(t)>=0}));0===u.length&&(u=d);var f=u.reduce((function(e,i){return e[i]=ke(t,{placement:i,boundary:s,rootBoundary:o,padding:r})[Ut(i)],e}),{});return Object.keys(f).sort((function(t,e){return f[t]-f[e]}))}const xe={name:"flip",enabled:!0,phase:"main",fn:function(t){var e=t.state,i=t.options,n=t.name;if(!e.modifiersData[n]._skip){for(var s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0===r||r,l=i.fallbackPlacements,c=i.padding,h=i.boundary,d=i.rootBoundary,u=i.altBoundary,f=i.flipVariations,p=void 0===f||f,m=i.allowedAutoPlacements,g=e.options.placement,_=Ut(g),b=l||(_!==g&&p?function(t){if(Ut(t)===vt)return[];var e=ge(t);return[be(t),e,be(e)]}(g):[ge(g)]),v=[g].concat(b).reduce((function(t,i){return t.concat(Ut(i)===vt?Le(e,{placement:i,boundary:h,rootBoundary:d,padding:c,flipVariations:p,allowedAutoPlacements:m}):i)}),[]),y=e.rects.reference,w=e.rects.popper,E=new Map,A=!0,T=v[0],O=0;O<v.length;O++){var C=v[O],k=Ut(C),L=ce(C)===wt,x=[mt,gt].indexOf(k)>=0,D=x?"width":"height",S=ke(e,{placement:C,boundary:h,rootBoundary:d,altBoundary:u,padding:c}),N=x?L?_t:bt:L?gt:mt;y[D]>w[D]&&(N=ge(N));var I=ge(N),P=[];if(o&&P.push(S[k]<=0),a&&P.push(S[N]<=0,S[I]<=0),P.every((function(t){return t}))){T=C,A=!1;break}E.set(C,P)}if(A)for(var j=function(t){var e=v.find((function(e){var i=E.get(e);if(i)return i.slice(0,t).every((function(t){return t}))}));if(e)return T=e,"break"},M=p?3:1;M>0&&"break"!==j(M);M--);e.placement!==T&&(e.modifiersData[n]._skip=!0,e.placement=T,e.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function De(t,e,i){return void 0===i&&(i={x:0,y:0}),{top:t.top-e.height-i.y,right:t.right-e.width+i.x,bottom:t.bottom-e.height+i.y,left:t.left-e.width-i.x}}function Se(t){return[mt,_t,gt,bt].some((function(e){return t[e]>=0}))}const Ne={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(t){var e=t.state,i=t.name,n=e.rects.reference,s=e.rects.popper,o=e.modifiersData.preventOverflow,r=ke(e,{elementContext:"reference"}),a=ke(e,{altBoundary:!0}),l=De(r,n),c=De(a,s,o),h=Se(l),d=Se(c);e.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:h,hasPopperEscaped:d},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":h,"data-popper-escaped":d})}},Ie={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(t){var e=t.state,i=t.options,n=t.name,s=i.offset,o=void 0===s?[0,0]:s,r=Lt.reduce((function(t,i){return t[i]=function(t,e,i){var n=Ut(t),s=[bt,mt].indexOf(n)>=0?-1:1,o="function"==typeof i?i(Object.assign({},e,{placement:t})):i,r=o[0],a=o[1];return r=r||0,a=(a||0)*s,[bt,_t].indexOf(n)>=0?{x:a,y:r}:{x:r,y:a}}(i,e.rects,o),t}),{}),a=r[e.placement],l=a.x,c=a.y;null!=e.modifiersData.popperOffsets&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=c),e.modifiersData[n]=r}},Pe={name:"popperOffsets",enabled:!0,phase:"read",fn:function(t){var e=t.state,i=t.name;e.modifiersData[i]=Ce({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})},data:{}},je={name:"preventOverflow",enabled:!0,phase:"main",fn:function(t){var e=t.state,i=t.options,n=t.name,s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0!==r&&r,l=i.boundary,c=i.rootBoundary,h=i.altBoundary,d=i.padding,u=i.tether,f=void 0===u||u,p=i.tetherOffset,m=void 0===p?0:p,g=ke(e,{boundary:l,rootBoundary:c,padding:d,altBoundary:h}),_=Ut(e.placement),b=ce(e.placement),v=!b,y=ee(_),w="x"===y?"y":"x",E=e.modifiersData.popperOffsets,A=e.rects.reference,T=e.rects.popper,O="function"==typeof m?m(Object.assign({},e.rects,{placement:e.placement})):m,C={x:0,y:0};if(E){if(o||a){var k="y"===y?mt:bt,L="y"===y?gt:_t,x="y"===y?"height":"width",D=E[y],S=E[y]+g[k],N=E[y]-g[L],I=f?-T[x]/2:0,P=b===wt?A[x]:T[x],j=b===wt?-T[x]:-A[x],M=e.elements.arrow,H=f&&M?Kt(M):{width:0,height:0},B=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},R=B[k],W=B[L],$=oe(0,A[x],H[x]),z=v?A[x]/2-I-$-R-O:P-$-R-O,q=v?-A[x]/2+I+$+W+O:j+$+W+O,F=e.elements.arrow&&te(e.elements.arrow),U=F?"y"===y?F.clientTop||0:F.clientLeft||0:0,V=e.modifiersData.offset?e.modifiersData.offset[e.placement][y]:0,K=E[y]+z-V-U,X=E[y]+q-V;if(o){var Y=oe(f?ne(S,K):S,D,f?ie(N,X):N);E[y]=Y,C[y]=Y-D}if(a){var Q="x"===y?mt:bt,G="x"===y?gt:_t,Z=E[w],J=Z+g[Q],tt=Z-g[G],et=oe(f?ne(J,K):J,Z,f?ie(tt,X):tt);E[w]=et,C[w]=et-Z}}e.modifiersData[n]=C}},requiresIfExists:["offset"]};function Me(t,e,i){void 0===i&&(i=!1);var n=zt(e);zt(e)&&function(t){var e=t.getBoundingClientRect();e.width,t.offsetWidth,e.height,t.offsetHeight}(e);var s,o,r=Gt(e),a=Vt(t),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(n||!n&&!i)&&(("body"!==Rt(e)||we(r))&&(l=(s=e)!==Wt(s)&&zt(s)?{scrollLeft:(o=s).scrollLeft,scrollTop:o.scrollTop}:ve(s)),zt(e)?((c=Vt(e)).x+=e.clientLeft,c.y+=e.clientTop):r&&(c.x=ye(r))),{x:a.left+l.scrollLeft-c.x,y:a.top+l.scrollTop-c.y,width:a.width,height:a.height}}function He(t){var e=new Map,i=new Set,n=[];function s(t){i.add(t.name),[].concat(t.requires||[],t.requiresIfExists||[]).forEach((function(t){if(!i.has(t)){var n=e.get(t);n&&s(n)}})),n.push(t)}return t.forEach((function(t){e.set(t.name,t)})),t.forEach((function(t){i.has(t.name)||s(t)})),n}var Be={placement:"bottom",modifiers:[],strategy:"absolute"};function Re(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return!e.some((function(t){return!(t&&"function"==typeof t.getBoundingClientRect)}))}function We(t){void 0===t&&(t={});var e=t,i=e.defaultModifiers,n=void 0===i?[]:i,s=e.defaultOptions,o=void 0===s?Be:s;return function(t,e,i){void 0===i&&(i=o);var s,r,a={placement:"bottom",orderedModifiers:[],options:Object.assign({},Be,o),modifiersData:{},elements:{reference:t,popper:e},attributes:{},styles:{}},l=[],c=!1,h={state:a,setOptions:function(i){var s="function"==typeof i?i(a.options):i;d(),a.options=Object.assign({},o,a.options,s),a.scrollParents={reference:$t(t)?Ae(t):t.contextElement?Ae(t.contextElement):[],popper:Ae(e)};var r,c,u=function(t){var e=He(t);return Bt.reduce((function(t,i){return t.concat(e.filter((function(t){return t.phase===i})))}),[])}((r=[].concat(n,a.options.modifiers),c=r.reduce((function(t,e){var i=t[e.name];return t[e.name]=i?Object.assign({},i,e,{options:Object.assign({},i.options,e.options),data:Object.assign({},i.data,e.data)}):e,t}),{}),Object.keys(c).map((function(t){return c[t]}))));return a.orderedModifiers=u.filter((function(t){return t.enabled})),a.orderedModifiers.forEach((function(t){var e=t.name,i=t.options,n=void 0===i?{}:i,s=t.effect;if("function"==typeof s){var o=s({state:a,name:e,instance:h,options:n});l.push(o||function(){})}})),h.update()},forceUpdate:function(){if(!c){var t=a.elements,e=t.reference,i=t.popper;if(Re(e,i)){a.rects={reference:Me(e,te(i),"fixed"===a.options.strategy),popper:Kt(i)},a.reset=!1,a.placement=a.options.placement,a.orderedModifiers.forEach((function(t){return a.modifiersData[t.name]=Object.assign({},t.data)}));for(var n=0;n<a.orderedModifiers.length;n++)if(!0!==a.reset){var s=a.orderedModifiers[n],o=s.fn,r=s.options,l=void 0===r?{}:r,d=s.name;"function"==typeof o&&(a=o({state:a,options:l,name:d,instance:h})||a)}else a.reset=!1,n=-1}}},update:(s=function(){return new Promise((function(t){h.forceUpdate(),t(a)}))},function(){return r||(r=new Promise((function(t){Promise.resolve().then((function(){r=void 0,t(s())}))}))),r}),destroy:function(){d(),c=!0}};if(!Re(t,e))return h;function d(){l.forEach((function(t){return t()})),l=[]}return h.setOptions(i).then((function(t){!c&&i.onFirstUpdate&&i.onFirstUpdate(t)})),h}}var $e=We(),ze=We({defaultModifiers:[pe,Pe,ue,Ft]}),qe=We({defaultModifiers:[pe,Pe,ue,Ft,Ie,xe,je,le,Ne]});const Fe=Object.freeze({__proto__:null,popperGenerator:We,detectOverflow:ke,createPopperBase:$e,createPopper:qe,createPopperLite:ze,top:mt,bottom:gt,right:_t,left:bt,auto:vt,basePlacements:yt,start:wt,end:Et,clippingParents:At,viewport:Tt,popper:Ot,reference:Ct,variationPlacements:kt,placements:Lt,beforeRead:xt,read:Dt,afterRead:St,beforeMain:Nt,main:It,afterMain:Pt,beforeWrite:jt,write:Mt,afterWrite:Ht,modifierPhases:Bt,applyStyles:Ft,arrow:le,computeStyles:ue,eventListeners:pe,flip:xe,hide:Ne,offset:Ie,popperOffsets:Pe,preventOverflow:je}),Ue="dropdown",Ve="Escape",Ke="Space",Xe="ArrowUp",Ye="ArrowDown",Qe=new RegExp("ArrowUp|ArrowDown|Escape"),Ge="click.bs.dropdown.data-api",Ze="keydown.bs.dropdown.data-api",Je="show",ti='[data-bs-toggle="dropdown"]',ei=".dropdown-menu",ii=m()?"top-end":"top-start",ni=m()?"top-start":"top-end",si=m()?"bottom-end":"bottom-start",oi=m()?"bottom-start":"bottom-end",ri=m()?"left-start":"right-start",ai=m()?"right-start":"left-start",li={offset:[0,2],boundary:"clippingParents",reference:"toggle",display:"dynamic",popperConfig:null,autoClose:!0},ci={offset:"(array|string|function)",boundary:"(string|element)",reference:"(string|element|object)",display:"string",popperConfig:"(null|object|function)",autoClose:"(boolean|string)"};class hi extends B{constructor(t,e){super(t),this._popper=null,this._config=this._getConfig(e),this._menu=this._getMenuElement(),this._inNavbar=this._detectNavbar()}static get Default(){return li}static get DefaultType(){return ci}static get NAME(){return Ue}toggle(){return this._isShown()?this.hide():this.show()}show(){if(c(this._element)||this._isShown(this._menu))return;const t={relatedTarget:this._element};if(j.trigger(this._element,"show.bs.dropdown",t).defaultPrevented)return;const e=hi.getParentFromElement(this._element);this._inNavbar?U.setDataAttribute(this._menu,"popper","none"):this._createPopper(e),"ontouchstart"in document.documentElement&&!e.closest(".navbar-nav")&&[].concat(...document.body.children).forEach((t=>j.on(t,"mouseover",d))),this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(Je),this._element.classList.add(Je),j.trigger(this._element,"shown.bs.dropdown",t)}hide(){if(c(this._element)||!this._isShown(this._menu))return;const t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){j.trigger(this._element,"hide.bs.dropdown",t).defaultPrevented||("ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach((t=>j.off(t,"mouseover",d))),this._popper&&this._popper.destroy(),this._menu.classList.remove(Je),this._element.classList.remove(Je),this._element.setAttribute("aria-expanded","false"),U.removeDataAttribute(this._menu,"popper"),j.trigger(this._element,"hidden.bs.dropdown",t))}_getConfig(t){if(t={...this.constructor.Default,...U.getDataAttributes(this._element),...t},a(Ue,t,this.constructor.DefaultType),"object"==typeof t.reference&&!o(t.reference)&&"function"!=typeof t.reference.getBoundingClientRect)throw new TypeError(`${Ue.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return t}_createPopper(t){if(void 0===Fe)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let e=this._element;"parent"===this._config.reference?e=t:o(this._config.reference)?e=r(this._config.reference):"object"==typeof this._config.reference&&(e=this._config.reference);const i=this._getPopperConfig(),n=i.modifiers.find((t=>"applyStyles"===t.name&&!1===t.enabled));this._popper=qe(e,this._menu,i),n&&U.setDataAttribute(this._menu,"popper","static")}_isShown(t=this._element){return t.classList.contains(Je)}_getMenuElement(){return V.next(this._element,ei)[0]}_getPlacement(){const t=this._element.parentNode;if(t.classList.contains("dropend"))return ri;if(t.classList.contains("dropstart"))return ai;const e="end"===getComputedStyle(this._menu).getPropertyValue("--bs-position").trim();return t.classList.contains("dropup")?e?ni:ii:e?oi:si}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map((t=>Number.parseInt(t,10))):"function"==typeof t?e=>t(e,this._element):t}_getPopperConfig(){const t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return"static"===this._config.display&&(t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,..."function"==typeof this._config.popperConfig?this._config.popperConfig(t):this._config.popperConfig}}_selectMenuItem({key:t,target:e}){const i=V.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",this._menu).filter(l);i.length&&v(i,e,t===Ye,!i.includes(e)).focus()}static jQueryInterface(t){return this.each((function(){const e=hi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}static clearMenus(t){if(t&&(2===t.button||"keyup"===t.type&&"Tab"!==t.key))return;const e=V.find(ti);for(let i=0,n=e.length;i<n;i++){const n=hi.getInstance(e[i]);if(!n||!1===n._config.autoClose)continue;if(!n._isShown())continue;const s={relatedTarget:n._element};if(t){const e=t.composedPath(),i=e.includes(n._menu);if(e.includes(n._element)||"inside"===n._config.autoClose&&!i||"outside"===n._config.autoClose&&i)continue;if(n._menu.contains(t.target)&&("keyup"===t.type&&"Tab"===t.key||/input|select|option|textarea|form/i.test(t.target.tagName)))continue;"click"===t.type&&(s.clickEvent=t)}n._completeHide(s)}}static getParentFromElement(t){return n(t)||t.parentNode}static dataApiKeydownHandler(t){if(/input|textarea/i.test(t.target.tagName)?t.key===Ke||t.key!==Ve&&(t.key!==Ye&&t.key!==Xe||t.target.closest(ei)):!Qe.test(t.key))return;const e=this.classList.contains(Je);if(!e&&t.key===Ve)return;if(t.preventDefault(),t.stopPropagation(),c(this))return;const i=this.matches(ti)?this:V.prev(this,ti)[0],n=hi.getOrCreateInstance(i);if(t.key!==Ve)return t.key===Xe||t.key===Ye?(e||n.show(),void n._selectMenuItem(t)):void(e&&t.key!==Ke||hi.clearMenus());n.hide()}}j.on(document,Ze,ti,hi.dataApiKeydownHandler),j.on(document,Ze,ei,hi.dataApiKeydownHandler),j.on(document,Ge,hi.clearMenus),j.on(document,"keyup.bs.dropdown.data-api",hi.clearMenus),j.on(document,Ge,ti,(function(t){t.preventDefault(),hi.getOrCreateInstance(this).toggle()})),g(hi);const di=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",ui=".sticky-top";class fi{constructor(){this._element=document.body}getWidth(){const t=document.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}hide(){const t=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,"paddingRight",(e=>e+t)),this._setElementAttributes(di,"paddingRight",(e=>e+t)),this._setElementAttributes(ui,"marginRight",(e=>e-t))}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,e,i){const n=this.getWidth();this._applyManipulationCallback(t,(t=>{if(t!==this._element&&window.innerWidth>t.clientWidth+n)return;this._saveInitialAttribute(t,e);const s=window.getComputedStyle(t)[e];t.style[e]=`${i(Number.parseFloat(s))}px`}))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,"paddingRight"),this._resetElementAttributes(di,"paddingRight"),this._resetElementAttributes(ui,"marginRight")}_saveInitialAttribute(t,e){const i=t.style[e];i&&U.setDataAttribute(t,e,i)}_resetElementAttributes(t,e){this._applyManipulationCallback(t,(t=>{const i=U.getDataAttribute(t,e);void 0===i?t.style.removeProperty(e):(U.removeDataAttribute(t,e),t.style[e]=i)}))}_applyManipulationCallback(t,e){o(t)?e(t):V.find(t,this._element).forEach(e)}isOverflowing(){return this.getWidth()>0}}const pi={className:"modal-backdrop",isVisible:!0,isAnimated:!1,rootElement:"body",clickCallback:null},mi={className:"string",isVisible:"boolean",isAnimated:"boolean",rootElement:"(element|string)",clickCallback:"(function|null)"},gi="show",_i="mousedown.bs.backdrop";class bi{constructor(t){this._config=this._getConfig(t),this._isAppended=!1,this._element=null}show(t){this._config.isVisible?(this._append(),this._config.isAnimated&&u(this._getElement()),this._getElement().classList.add(gi),this._emulateAnimation((()=>{_(t)}))):_(t)}hide(t){this._config.isVisible?(this._getElement().classList.remove(gi),this._emulateAnimation((()=>{this.dispose(),_(t)}))):_(t)}_getElement(){if(!this._element){const t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add("fade"),this._element=t}return this._element}_getConfig(t){return(t={...pi,..."object"==typeof t?t:{}}).rootElement=r(t.rootElement),a("backdrop",t,mi),t}_append(){this._isAppended||(this._config.rootElement.append(this._getElement()),j.on(this._getElement(),_i,(()=>{_(this._config.clickCallback)})),this._isAppended=!0)}dispose(){this._isAppended&&(j.off(this._element,_i),this._element.remove(),this._isAppended=!1)}_emulateAnimation(t){b(t,this._getElement(),this._config.isAnimated)}}const vi={trapElement:null,autofocus:!0},yi={trapElement:"element",autofocus:"boolean"},wi=".bs.focustrap",Ei="backward";class Ai{constructor(t){this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}activate(){const{trapElement:t,autofocus:e}=this._config;this._isActive||(e&&t.focus(),j.off(document,wi),j.on(document,"focusin.bs.focustrap",(t=>this._handleFocusin(t))),j.on(document,"keydown.tab.bs.focustrap",(t=>this._handleKeydown(t))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,j.off(document,wi))}_handleFocusin(t){const{target:e}=t,{trapElement:i}=this._config;if(e===document||e===i||i.contains(e))return;const n=V.focusableChildren(i);0===n.length?i.focus():this._lastTabNavDirection===Ei?n[n.length-1].focus():n[0].focus()}_handleKeydown(t){"Tab"===t.key&&(this._lastTabNavDirection=t.shiftKey?Ei:"forward")}_getConfig(t){return t={...vi,..."object"==typeof t?t:{}},a("focustrap",t,yi),t}}const Ti="modal",Oi="Escape",Ci={backdrop:!0,keyboard:!0,focus:!0},ki={backdrop:"(boolean|string)",keyboard:"boolean",focus:"boolean"},Li="hidden.bs.modal",xi="show.bs.modal",Di="resize.bs.modal",Si="click.dismiss.bs.modal",Ni="keydown.dismiss.bs.modal",Ii="mousedown.dismiss.bs.modal",Pi="modal-open",ji="show",Mi="modal-static";class Hi extends B{constructor(t,e){super(t),this._config=this._getConfig(e),this._dialog=V.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._ignoreBackdropClick=!1,this._isTransitioning=!1,this._scrollBar=new fi}static get Default(){return Ci}static get NAME(){return Ti}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||j.trigger(this._element,xi,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isAnimated()&&(this._isTransitioning=!0),this._scrollBar.hide(),document.body.classList.add(Pi),this._adjustDialog(),this._setEscapeEvent(),this._setResizeEvent(),j.on(this._dialog,Ii,(()=>{j.one(this._element,"mouseup.dismiss.bs.modal",(t=>{t.target===this._element&&(this._ignoreBackdropClick=!0)}))})),this._showBackdrop((()=>this._showElement(t))))}hide(){if(!this._isShown||this._isTransitioning)return;if(j.trigger(this._element,"hide.bs.modal").defaultPrevented)return;this._isShown=!1;const t=this._isAnimated();t&&(this._isTransitioning=!0),this._setEscapeEvent(),this._setResizeEvent(),this._focustrap.deactivate(),this._element.classList.remove(ji),j.off(this._element,Si),j.off(this._dialog,Ii),this._queueCallback((()=>this._hideModal()),this._element,t)}dispose(){[window,this._dialog].forEach((t=>j.off(t,".bs.modal"))),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new bi({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new Ai({trapElement:this._element})}_getConfig(t){return t={...Ci,...U.getDataAttributes(this._element),..."object"==typeof t?t:{}},a(Ti,t,ki),t}_showElement(t){const e=this._isAnimated(),i=V.findOne(".modal-body",this._dialog);this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0,i&&(i.scrollTop=0),e&&u(this._element),this._element.classList.add(ji),this._queueCallback((()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,j.trigger(this._element,"shown.bs.modal",{relatedTarget:t})}),this._dialog,e)}_setEscapeEvent(){this._isShown?j.on(this._element,Ni,(t=>{this._config.keyboard&&t.key===Oi?(t.preventDefault(),this.hide()):this._config.keyboard||t.key!==Oi||this._triggerBackdropTransition()})):j.off(this._element,Ni)}_setResizeEvent(){this._isShown?j.on(window,Di,(()=>this._adjustDialog())):j.off(window,Di)}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide((()=>{document.body.classList.remove(Pi),this._resetAdjustments(),this._scrollBar.reset(),j.trigger(this._element,Li)}))}_showBackdrop(t){j.on(this._element,Si,(t=>{this._ignoreBackdropClick?this._ignoreBackdropClick=!1:t.target===t.currentTarget&&(!0===this._config.backdrop?this.hide():"static"===this._config.backdrop&&this._triggerBackdropTransition())})),this._backdrop.show(t)}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(j.trigger(this._element,"hidePrevented.bs.modal").defaultPrevented)return;const{classList:t,scrollHeight:e,style:i}=this._element,n=e>document.documentElement.clientHeight;!n&&"hidden"===i.overflowY||t.contains(Mi)||(n||(i.overflowY="hidden"),t.add(Mi),this._queueCallback((()=>{t.remove(Mi),n||this._queueCallback((()=>{i.overflowY=""}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._scrollBar.getWidth(),i=e>0;(!i&&t&&!m()||i&&!t&&m())&&(this._element.style.paddingLeft=`${e}px`),(i&&!t&&!m()||!i&&t&&m())&&(this._element.style.paddingRight=`${e}px`)}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,e){return this.each((function(){const i=Hi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t](e)}}))}}j.on(document,"click.bs.modal.data-api",'[data-bs-toggle="modal"]',(function(t){const e=n(this);["A","AREA"].includes(this.tagName)&&t.preventDefault(),j.one(e,xi,(t=>{t.defaultPrevented||j.one(e,Li,(()=>{l(this)&&this.focus()}))}));const i=V.findOne(".modal.show");i&&Hi.getInstance(i).hide(),Hi.getOrCreateInstance(e).toggle(this)})),R(Hi),g(Hi);const Bi="offcanvas",Ri={backdrop:!0,keyboard:!0,scroll:!1},Wi={backdrop:"boolean",keyboard:"boolean",scroll:"boolean"},$i="show",zi=".offcanvas.show",qi="hidden.bs.offcanvas";class Fi extends B{constructor(t,e){super(t),this._config=this._getConfig(e),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get NAME(){return Bi}static get Default(){return Ri}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||j.trigger(this._element,"show.bs.offcanvas",{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._element.style.visibility="visible",this._backdrop.show(),this._config.scroll||(new fi).hide(),this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add($i),this._queueCallback((()=>{this._config.scroll||this._focustrap.activate(),j.trigger(this._element,"shown.bs.offcanvas",{relatedTarget:t})}),this._element,!0))}hide(){this._isShown&&(j.trigger(this._element,"hide.bs.offcanvas").defaultPrevented||(this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.remove($i),this._backdrop.hide(),this._queueCallback((()=>{this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._element.style.visibility="hidden",this._config.scroll||(new fi).reset(),j.trigger(this._element,qi)}),this._element,!0)))}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_getConfig(t){return t={...Ri,...U.getDataAttributes(this._element),..."object"==typeof t?t:{}},a(Bi,t,Wi),t}_initializeBackDrop(){return new bi({className:"offcanvas-backdrop",isVisible:this._config.backdrop,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:()=>this.hide()})}_initializeFocusTrap(){return new Ai({trapElement:this._element})}_addEventListeners(){j.on(this._element,"keydown.dismiss.bs.offcanvas",(t=>{this._config.keyboard&&"Escape"===t.key&&this.hide()}))}static jQueryInterface(t){return this.each((function(){const e=Fi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}j.on(document,"click.bs.offcanvas.data-api",'[data-bs-toggle="offcanvas"]',(function(t){const e=n(this);if(["A","AREA"].includes(this.tagName)&&t.preventDefault(),c(this))return;j.one(e,qi,(()=>{l(this)&&this.focus()}));const i=V.findOne(zi);i&&i!==e&&Fi.getInstance(i).hide(),Fi.getOrCreateInstance(e).toggle(this)})),j.on(window,"load.bs.offcanvas.data-api",(()=>V.find(zi).forEach((t=>Fi.getOrCreateInstance(t).show())))),R(Fi),g(Fi);const Ui=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Vi=/^(?:(?:https?|mailto|ftp|tel|file|sms):|[^#&/:?]*(?:[#/?]|$))/i,Ki=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i,Xi=(t,e)=>{const i=t.nodeName.toLowerCase();if(e.includes(i))return!Ui.has(i)||Boolean(Vi.test(t.nodeValue)||Ki.test(t.nodeValue));const n=e.filter((t=>t instanceof RegExp));for(let t=0,e=n.length;t<e;t++)if(n[t].test(i))return!0;return!1};function Yi(t,e,i){if(!t.length)return t;if(i&&"function"==typeof i)return i(t);const n=(new window.DOMParser).parseFromString(t,"text/html"),s=[].concat(...n.body.querySelectorAll("*"));for(let t=0,i=s.length;t<i;t++){const i=s[t],n=i.nodeName.toLowerCase();if(!Object.keys(e).includes(n)){i.remove();continue}const o=[].concat(...i.attributes),r=[].concat(e["*"]||[],e[n]||[]);o.forEach((t=>{Xi(t,r)||i.removeAttribute(t.nodeName)}))}return n.body.innerHTML}const Qi="tooltip",Gi=new Set(["sanitize","allowList","sanitizeFn"]),Zi={animation:"boolean",template:"string",title:"(string|element|function)",trigger:"string",delay:"(number|object)",html:"boolean",selector:"(string|boolean)",placement:"(string|function)",offset:"(array|string|function)",container:"(string|element|boolean)",fallbackPlacements:"array",boundary:"(string|element)",customClass:"(string|function)",sanitize:"boolean",sanitizeFn:"(null|function)",allowList:"object",popperConfig:"(null|object|function)"},Ji={AUTO:"auto",TOP:"top",RIGHT:m()?"left":"right",BOTTOM:"bottom",LEFT:m()?"right":"left"},tn={animation:!0,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:[0,0],container:!1,fallbackPlacements:["top","right","bottom","left"],boundary:"clippingParents",customClass:"",sanitize:!0,sanitizeFn:null,allowList:{"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},popperConfig:null},en={HIDE:"hide.bs.tooltip",HIDDEN:"hidden.bs.tooltip",SHOW:"show.bs.tooltip",SHOWN:"shown.bs.tooltip",INSERTED:"inserted.bs.tooltip",CLICK:"click.bs.tooltip",FOCUSIN:"focusin.bs.tooltip",FOCUSOUT:"focusout.bs.tooltip",MOUSEENTER:"mouseenter.bs.tooltip",MOUSELEAVE:"mouseleave.bs.tooltip"},nn="fade",sn="show",on="show",rn="out",an=".tooltip-inner",ln=".modal",cn="hide.bs.modal",hn="hover",dn="focus";class un extends B{constructor(t,e){if(void 0===Fe)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(t),this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._popper=null,this._config=this._getConfig(e),this.tip=null,this._setListeners()}static get Default(){return tn}static get NAME(){return Qi}static get Event(){return en}static get DefaultType(){return Zi}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(t){if(this._isEnabled)if(t){const e=this._initializeOnDelegatedTarget(t);e._activeTrigger.click=!e._activeTrigger.click,e._isWithActiveTrigger()?e._enter(null,e):e._leave(null,e)}else{if(this.getTipElement().classList.contains(sn))return void this._leave(null,this);this._enter(null,this)}}dispose(){clearTimeout(this._timeout),j.off(this._element.closest(ln),cn,this._hideModalHandler),this.tip&&this.tip.remove(),this._disposePopper(),super.dispose()}show(){if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this.isWithContent()||!this._isEnabled)return;const t=j.trigger(this._element,this.constructor.Event.SHOW),e=h(this._element),i=null===e?this._element.ownerDocument.documentElement.contains(this._element):e.contains(this._element);if(t.defaultPrevented||!i)return;"tooltip"===this.constructor.NAME&&this.tip&&this.getTitle()!==this.tip.querySelector(an).innerHTML&&(this._disposePopper(),this.tip.remove(),this.tip=null);const n=this.getTipElement(),s=(t=>{do{t+=Math.floor(1e6*Math.random())}while(document.getElementById(t));return t})(this.constructor.NAME);n.setAttribute("id",s),this._element.setAttribute("aria-describedby",s),this._config.animation&&n.classList.add(nn);const o="function"==typeof this._config.placement?this._config.placement.call(this,n,this._element):this._config.placement,r=this._getAttachment(o);this._addAttachmentClass(r);const{container:a}=this._config;H.set(n,this.constructor.DATA_KEY,this),this._element.ownerDocument.documentElement.contains(this.tip)||(a.append(n),j.trigger(this._element,this.constructor.Event.INSERTED)),this._popper?this._popper.update():this._popper=qe(this._element,n,this._getPopperConfig(r)),n.classList.add(sn);const l=this._resolvePossibleFunction(this._config.customClass);l&&n.classList.add(...l.split(" ")),"ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach((t=>{j.on(t,"mouseover",d)}));const c=this.tip.classList.contains(nn);this._queueCallback((()=>{const t=this._hoverState;this._hoverState=null,j.trigger(this._element,this.constructor.Event.SHOWN),t===rn&&this._leave(null,this)}),this.tip,c)}hide(){if(!this._popper)return;const t=this.getTipElement();if(j.trigger(this._element,this.constructor.Event.HIDE).defaultPrevented)return;t.classList.remove(sn),"ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach((t=>j.off(t,"mouseover",d))),this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1;const e=this.tip.classList.contains(nn);this._queueCallback((()=>{this._isWithActiveTrigger()||(this._hoverState!==on&&t.remove(),this._cleanTipClass(),this._element.removeAttribute("aria-describedby"),j.trigger(this._element,this.constructor.Event.HIDDEN),this._disposePopper())}),this.tip,e),this._hoverState=""}update(){null!==this._popper&&this._popper.update()}isWithContent(){return Boolean(this.getTitle())}getTipElement(){if(this.tip)return this.tip;const t=document.createElement("div");t.innerHTML=this._config.template;const e=t.children[0];return this.setContent(e),e.classList.remove(nn,sn),this.tip=e,this.tip}setContent(t){this._sanitizeAndSetContent(t,this.getTitle(),an)}_sanitizeAndSetContent(t,e,i){const n=V.findOne(i,t);e||!n?this.setElementContent(n,e):n.remove()}setElementContent(t,e){if(null!==t)return o(e)?(e=r(e),void(this._config.html?e.parentNode!==t&&(t.innerHTML="",t.append(e)):t.textContent=e.textContent)):void(this._config.html?(this._config.sanitize&&(e=Yi(e,this._config.allowList,this._config.sanitizeFn)),t.innerHTML=e):t.textContent=e)}getTitle(){const t=this._element.getAttribute("data-bs-original-title")||this._config.title;return this._resolvePossibleFunction(t)}updateAttachment(t){return"right"===t?"end":"left"===t?"start":t}_initializeOnDelegatedTarget(t,e){return e||this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map((t=>Number.parseInt(t,10))):"function"==typeof t?e=>t(e,this._element):t}_resolvePossibleFunction(t){return"function"==typeof t?t.call(this._element):t}_getPopperConfig(t){const e={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"onChange",enabled:!0,phase:"afterWrite",fn:t=>this._handlePopperPlacementChange(t)}],onFirstUpdate:t=>{t.options.placement!==t.placement&&this._handlePopperPlacementChange(t)}};return{...e,..."function"==typeof this._config.popperConfig?this._config.popperConfig(e):this._config.popperConfig}}_addAttachmentClass(t){this.getTipElement().classList.add(`${this._getBasicClassPrefix()}-${this.updateAttachment(t)}`)}_getAttachment(t){return Ji[t.toUpperCase()]}_setListeners(){this._config.trigger.split(" ").forEach((t=>{if("click"===t)j.on(this._element,this.constructor.Event.CLICK,this._config.selector,(t=>this.toggle(t)));else if("manual"!==t){const e=t===hn?this.constructor.Event.MOUSEENTER:this.constructor.Event.FOCUSIN,i=t===hn?this.constructor.Event.MOUSELEAVE:this.constructor.Event.FOCUSOUT;j.on(this._element,e,this._config.selector,(t=>this._enter(t))),j.on(this._element,i,this._config.selector,(t=>this._leave(t)))}})),this._hideModalHandler=()=>{this._element&&this.hide()},j.on(this._element.closest(ln),cn,this._hideModalHandler),this._config.selector?this._config={...this._config,trigger:"manual",selector:""}:this._fixTitle()}_fixTitle(){const t=this._element.getAttribute("title"),e=typeof this._element.getAttribute("data-bs-original-title");(t||"string"!==e)&&(this._element.setAttribute("data-bs-original-title",t||""),!t||this._element.getAttribute("aria-label")||this._element.textContent||this._element.setAttribute("aria-label",t),this._element.setAttribute("title",""))}_enter(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusin"===t.type?dn:hn]=!0),e.getTipElement().classList.contains(sn)||e._hoverState===on?e._hoverState=on:(clearTimeout(e._timeout),e._hoverState=on,e._config.delay&&e._config.delay.show?e._timeout=setTimeout((()=>{e._hoverState===on&&e.show()}),e._config.delay.show):e.show())}_leave(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusout"===t.type?dn:hn]=e._element.contains(t.relatedTarget)),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState=rn,e._config.delay&&e._config.delay.hide?e._timeout=setTimeout((()=>{e._hoverState===rn&&e.hide()}),e._config.delay.hide):e.hide())}_isWithActiveTrigger(){for(const t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1}_getConfig(t){const e=U.getDataAttributes(this._element);return Object.keys(e).forEach((t=>{Gi.has(t)&&delete e[t]})),(t={...this.constructor.Default,...e,..."object"==typeof t&&t?t:{}}).container=!1===t.container?document.body:r(t.container),"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),a(Qi,t,this.constructor.DefaultType),t.sanitize&&(t.template=Yi(t.template,t.allowList,t.sanitizeFn)),t}_getDelegateConfig(){const t={};for(const e in this._config)this.constructor.Default[e]!==this._config[e]&&(t[e]=this._config[e]);return t}_cleanTipClass(){const t=this.getTipElement(),e=new RegExp(`(^|\\s)${this._getBasicClassPrefix()}\\S+`,"g"),i=t.getAttribute("class").match(e);null!==i&&i.length>0&&i.map((t=>t.trim())).forEach((e=>t.classList.remove(e)))}_getBasicClassPrefix(){return"bs-tooltip"}_handlePopperPlacementChange(t){const{state:e}=t;e&&(this.tip=e.elements.popper,this._cleanTipClass(),this._addAttachmentClass(this._getAttachment(e.placement)))}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null)}static jQueryInterface(t){return this.each((function(){const e=un.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}g(un);const fn={...un.Default,placement:"right",offset:[0,8],trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>'},pn={...un.DefaultType,content:"(string|element|function)"},mn={HIDE:"hide.bs.popover",HIDDEN:"hidden.bs.popover",SHOW:"show.bs.popover",SHOWN:"shown.bs.popover",INSERTED:"inserted.bs.popover",CLICK:"click.bs.popover",FOCUSIN:"focusin.bs.popover",FOCUSOUT:"focusout.bs.popover",MOUSEENTER:"mouseenter.bs.popover",MOUSELEAVE:"mouseleave.bs.popover"};class gn extends un{static get Default(){return fn}static get NAME(){return"popover"}static get Event(){return mn}static get DefaultType(){return pn}isWithContent(){return this.getTitle()||this._getContent()}setContent(t){this._sanitizeAndSetContent(t,this.getTitle(),".popover-header"),this._sanitizeAndSetContent(t,this._getContent(),".popover-body")}_getContent(){return this._resolvePossibleFunction(this._config.content)}_getBasicClassPrefix(){return"bs-popover"}static jQueryInterface(t){return this.each((function(){const e=gn.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}g(gn);const _n="scrollspy",bn={offset:10,method:"auto",target:""},vn={offset:"number",method:"string",target:"(string|element)"},yn="active",wn=".nav-link, .list-group-item, .dropdown-item",En="position";class An extends B{constructor(t,e){super(t),this._scrollElement="BODY"===this._element.tagName?window:this._element,this._config=this._getConfig(e),this._offsets=[],this._targets=[],this._activeTarget=null,this._scrollHeight=0,j.on(this._scrollElement,"scroll.bs.scrollspy",(()=>this._process())),this.refresh(),this._process()}static get Default(){return bn}static get NAME(){return _n}refresh(){const t=this._scrollElement===this._scrollElement.window?"offset":En,e="auto"===this._config.method?t:this._config.method,n=e===En?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),V.find(wn,this._config.target).map((t=>{const s=i(t),o=s?V.findOne(s):null;if(o){const t=o.getBoundingClientRect();if(t.width||t.height)return[U[e](o).top+n,s]}return null})).filter((t=>t)).sort(((t,e)=>t[0]-e[0])).forEach((t=>{this._offsets.push(t[0]),this._targets.push(t[1])}))}dispose(){j.off(this._scrollElement,".bs.scrollspy"),super.dispose()}_getConfig(t){return(t={...bn,...U.getDataAttributes(this._element),..."object"==typeof t&&t?t:{}}).target=r(t.target)||document.documentElement,a(_n,t,vn),t}_getScrollTop(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop}_getScrollHeight(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)}_getOffsetHeight(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height}_process(){const t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),i=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),t>=i){const t=this._targets[this._targets.length-1];this._activeTarget!==t&&this._activate(t)}else{if(this._activeTarget&&t<this._offsets[0]&&this._offsets[0]>0)return this._activeTarget=null,void this._clear();for(let e=this._offsets.length;e--;)this._activeTarget!==this._targets[e]&&t>=this._offsets[e]&&(void 0===this._offsets[e+1]||t<this._offsets[e+1])&&this._activate(this._targets[e])}}_activate(t){this._activeTarget=t,this._clear();const e=wn.split(",").map((e=>`${e}[data-bs-target="${t}"],${e}[href="${t}"]`)),i=V.findOne(e.join(","),this._config.target);i.classList.add(yn),i.classList.contains("dropdown-item")?V.findOne(".dropdown-toggle",i.closest(".dropdown")).classList.add(yn):V.parents(i,".nav, .list-group").forEach((t=>{V.prev(t,".nav-link, .list-group-item").forEach((t=>t.classList.add(yn))),V.prev(t,".nav-item").forEach((t=>{V.children(t,".nav-link").forEach((t=>t.classList.add(yn)))}))})),j.trigger(this._scrollElement,"activate.bs.scrollspy",{relatedTarget:t})}_clear(){V.find(wn,this._config.target).filter((t=>t.classList.contains(yn))).forEach((t=>t.classList.remove(yn)))}static jQueryInterface(t){return this.each((function(){const e=An.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}j.on(window,"load.bs.scrollspy.data-api",(()=>{V.find('[data-bs-spy="scroll"]').forEach((t=>new An(t)))})),g(An);const Tn="active",On="fade",Cn="show",kn=".active",Ln=":scope > li > .active";class xn extends B{static get NAME(){return"tab"}show(){if(this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE&&this._element.classList.contains(Tn))return;let t;const e=n(this._element),i=this._element.closest(".nav, .list-group");if(i){const e="UL"===i.nodeName||"OL"===i.nodeName?Ln:kn;t=V.find(e,i),t=t[t.length-1]}const s=t?j.trigger(t,"hide.bs.tab",{relatedTarget:this._element}):null;if(j.trigger(this._element,"show.bs.tab",{relatedTarget:t}).defaultPrevented||null!==s&&s.defaultPrevented)return;this._activate(this._element,i);const o=()=>{j.trigger(t,"hidden.bs.tab",{relatedTarget:this._element}),j.trigger(this._element,"shown.bs.tab",{relatedTarget:t})};e?this._activate(e,e.parentNode,o):o()}_activate(t,e,i){const n=(!e||"UL"!==e.nodeName&&"OL"!==e.nodeName?V.children(e,kn):V.find(Ln,e))[0],s=i&&n&&n.classList.contains(On),o=()=>this._transitionComplete(t,n,i);n&&s?(n.classList.remove(Cn),this._queueCallback(o,t,!0)):o()}_transitionComplete(t,e,i){if(e){e.classList.remove(Tn);const t=V.findOne(":scope > .dropdown-menu .active",e.parentNode);t&&t.classList.remove(Tn),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!1)}t.classList.add(Tn),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),u(t),t.classList.contains(On)&&t.classList.add(Cn);let n=t.parentNode;if(n&&"LI"===n.nodeName&&(n=n.parentNode),n&&n.classList.contains("dropdown-menu")){const e=t.closest(".dropdown");e&&V.find(".dropdown-toggle",e).forEach((t=>t.classList.add(Tn))),t.setAttribute("aria-expanded",!0)}i&&i()}static jQueryInterface(t){return this.each((function(){const e=xn.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}j.on(document,"click.bs.tab.data-api",'[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',(function(t){["A","AREA"].includes(this.tagName)&&t.preventDefault(),c(this)||xn.getOrCreateInstance(this).show()})),g(xn);const Dn="toast",Sn="hide",Nn="show",In="showing",Pn={animation:"boolean",autohide:"boolean",delay:"number"},jn={animation:!0,autohide:!0,delay:5e3};class Mn extends B{constructor(t,e){super(t),this._config=this._getConfig(e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get DefaultType(){return Pn}static get Default(){return jn}static get NAME(){return Dn}show(){j.trigger(this._element,"show.bs.toast").defaultPrevented||(this._clearTimeout(),this._config.animation&&this._element.classList.add("fade"),this._element.classList.remove(Sn),u(this._element),this._element.classList.add(Nn),this._element.classList.add(In),this._queueCallback((()=>{this._element.classList.remove(In),j.trigger(this._element,"shown.bs.toast"),this._maybeScheduleHide()}),this._element,this._config.animation))}hide(){this._element.classList.contains(Nn)&&(j.trigger(this._element,"hide.bs.toast").defaultPrevented||(this._element.classList.add(In),this._queueCallback((()=>{this._element.classList.add(Sn),this._element.classList.remove(In),this._element.classList.remove(Nn),j.trigger(this._element,"hidden.bs.toast")}),this._element,this._config.animation)))}dispose(){this._clearTimeout(),this._element.classList.contains(Nn)&&this._element.classList.remove(Nn),super.dispose()}_getConfig(t){return t={...jn,...U.getDataAttributes(this._element),..."object"==typeof t&&t?t:{}},a(Dn,t,this.constructor.DefaultType),t}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":this._hasMouseInteraction=e;break;case"focusin":case"focusout":this._hasKeyboardInteraction=e}if(e)return void this._clearTimeout();const i=t.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){j.on(this._element,"mouseover.bs.toast",(t=>this._onInteraction(t,!0))),j.on(this._element,"mouseout.bs.toast",(t=>this._onInteraction(t,!1))),j.on(this._element,"focusin.bs.toast",(t=>this._onInteraction(t,!0))),j.on(this._element,"focusout.bs.toast",(t=>this._onInteraction(t,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each((function(){const e=Mn.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}return R(Mn),g(Mn),{Alert:W,Button:z,Carousel:st,Collapse:pt,Dropdown:hi,Modal:Hi,Offcanvas:Fi,Popover:gn,ScrollSpy:An,Tab:xn,Toast:Mn,Tooltip:un}}));
+!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).bootstrap=e()}(this,function(){"use strict";const t=new Map,e={set(e,i,n){t.has(e)||t.set(e,new Map);const s=t.get(e);s.has(i)||0===s.size?s.set(i,n):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`)},get:(e,i)=>t.has(e)&&t.get(e).get(i)||null,remove(e,i){if(!t.has(e))return;const n=t.get(e);n.delete(i),0===n.size&&t.delete(e)}},i="transitionend",n=t=>(t&&window.CSS&&window.CSS.escape&&(t=t.replace(/#([^\s"#']+)/g,(t,e)=>`#${CSS.escape(e)}`)),t),s=t=>null==t?`${t}`:Object.prototype.toString.call(t).match(/\s([a-z]+)/i)[1].toLowerCase(),o=t=>{t.dispatchEvent(new Event(i))},r=t=>!(!t||"object"!=typeof t)&&(void 0!==t.jquery&&(t=t[0]),void 0!==t.nodeType),a=t=>r(t)?t.jquery?t[0]:t:"string"==typeof t&&t.length>0?document.querySelector(n(t)):null,l=t=>{if(!r(t)||0===t.getClientRects().length)return!1;const e="visible"===getComputedStyle(t).getPropertyValue("visibility"),i=t.closest("details:not([open])");if(!i)return e;if(i!==t){const e=t.closest("summary");if(e&&e.parentNode!==i)return!1;if(null===e)return!1}return e},c=t=>!t||t.nodeType!==Node.ELEMENT_NODE||!!t.classList.contains("disabled")||(void 0!==t.disabled?t.disabled:t.hasAttribute("disabled")&&"false"!==t.getAttribute("disabled")),h=t=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof t.getRootNode){const e=t.getRootNode();return e instanceof ShadowRoot?e:null}return t instanceof ShadowRoot?t:t.parentNode?h(t.parentNode):null},d=()=>{},u=t=>{t.offsetHeight},f=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,p=[],m=()=>"rtl"===document.documentElement.dir,g=t=>{var e;e=()=>{const e=f();if(e){const i=t.NAME,n=e.fn[i];e.fn[i]=t.jQueryInterface,e.fn[i].Constructor=t,e.fn[i].noConflict=()=>(e.fn[i]=n,t.jQueryInterface)}},"loading"===document.readyState?(p.length||document.addEventListener("DOMContentLoaded",()=>{for(const t of p)t()}),p.push(e)):e()},_=(t,e=[],i=t)=>"function"==typeof t?t.call(...e):i,b=(t,e,n=!0)=>{if(!n)return void _(t);const s=(t=>{if(!t)return 0;let{transitionDuration:e,transitionDelay:i}=window.getComputedStyle(t);const n=Number.parseFloat(e),s=Number.parseFloat(i);return n||s?(e=e.split(",")[0],i=i.split(",")[0],1e3*(Number.parseFloat(e)+Number.parseFloat(i))):0})(e)+5;let r=!1;const a=({target:n})=>{n===e&&(r=!0,e.removeEventListener(i,a),_(t))};e.addEventListener(i,a),setTimeout(()=>{r||o(e)},s)},v=(t,e,i,n)=>{const s=t.length;let o=t.indexOf(e);return-1===o?!i&&n?t[s-1]:t[0]:(o+=i?1:-1,n&&(o=(o+s)%s),t[Math.max(0,Math.min(o,s-1))])},y=/[^.]*(?=\..*)\.|.*/,w=/\..*/,A=/::\d+$/,E={};let T=1;const C={mouseenter:"mouseover",mouseleave:"mouseout"},O=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function x(t,e){return e&&`${e}::${T++}`||t.uidEvent||T++}function k(t){const e=x(t);return t.uidEvent=e,E[e]=E[e]||{},E[e]}function L(t,e,i=null){return Object.values(t).find(t=>t.callable===e&&t.delegationSelector===i)}function S(t,e,i){const n="string"==typeof e,s=n?i:e||i;let o=N(t);return O.has(o)||(o=t),[n,s,o]}function D(t,e,i,n,s){if("string"!=typeof e||!t)return;let[o,r,a]=S(e,i,n);if(e in C){const t=t=>function(e){if(!e.relatedTarget||e.relatedTarget!==e.delegateTarget&&!e.delegateTarget.contains(e.relatedTarget))return t.call(this,e)};r=t(r)}const l=k(t),c=l[a]||(l[a]={}),h=L(c,r,o?i:null);if(h)return void(h.oneOff=h.oneOff&&s);const d=x(r,e.replace(y,"")),u=o?function(t,e,i){return function n(s){const o=t.querySelectorAll(e);for(let{target:r}=s;r&&r!==this;r=r.parentNode)for(const a of o)if(a===r)return j(s,{delegateTarget:r}),n.oneOff&&P.off(t,s.type,e,i),i.apply(r,[s])}}(t,i,r):function(t,e){return function i(n){return j(n,{delegateTarget:t}),i.oneOff&&P.off(t,n.type,e),e.apply(t,[n])}}(t,r);u.delegationSelector=o?i:null,u.callable=r,u.oneOff=s,u.uidEvent=d,c[d]=u,t.addEventListener(a,u,o)}function $(t,e,i,n,s){const o=L(e[i],n,s);o&&(t.removeEventListener(i,o,Boolean(s)),delete e[i][o.uidEvent])}function I(t,e,i,n){const s=e[i]||{};for(const[o,r]of Object.entries(s))o.includes(n)&&$(t,e,i,r.callable,r.delegationSelector)}function N(t){return t=t.replace(w,""),C[t]||t}const P={on(t,e,i,n){D(t,e,i,n,!1)},one(t,e,i,n){D(t,e,i,n,!0)},off(t,e,i,n){if("string"!=typeof e||!t)return;const[s,o,r]=S(e,i,n),a=r!==e,l=k(t),c=l[r]||{},h=e.startsWith(".");if(void 0===o){if(h)for(const i of Object.keys(l))I(t,l,i,e.slice(1));for(const[i,n]of Object.entries(c)){const s=i.replace(A,"");a&&!e.includes(s)||$(t,l,r,n.callable,n.delegationSelector)}}else{if(!Object.keys(c).length)return;$(t,l,r,o,s?i:null)}},trigger(t,e,i){if("string"!=typeof e||!t)return null;const n=f();let s=null,o=!0,r=!0,a=!1;e!==N(e)&&n&&(s=n.Event(e,i),n(t).trigger(s),o=!s.isPropagationStopped(),r=!s.isImmediatePropagationStopped(),a=s.isDefaultPrevented());const l=j(new Event(e,{bubbles:o,cancelable:!0}),i);return a&&l.preventDefault(),r&&t.dispatchEvent(l),l.defaultPrevented&&s&&s.preventDefault(),l}};function j(t,e={}){for(const[i,n]of Object.entries(e))try{t[i]=n}catch(e){Object.defineProperty(t,i,{configurable:!0,get:()=>n})}return t}function M(t){if("true"===t)return!0;if("false"===t)return!1;if(t===Number(t).toString())return Number(t);if(""===t||"null"===t)return null;if("string"!=typeof t)return t;try{return JSON.parse(decodeURIComponent(t))}catch(e){return t}}function F(t){return t.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`)}const H={setDataAttribute(t,e,i){t.setAttribute(`data-bs-${F(e)}`,i)},removeDataAttribute(t,e){t.removeAttribute(`data-bs-${F(e)}`)},getDataAttributes(t){if(!t)return{};const e={},i=Object.keys(t.dataset).filter(t=>t.startsWith("bs")&&!t.startsWith("bsConfig"));for(const n of i){let i=n.replace(/^bs/,"");i=i.charAt(0).toLowerCase()+i.slice(1),e[i]=M(t.dataset[n])}return e},getDataAttribute:(t,e)=>M(t.getAttribute(`data-bs-${F(e)}`))};class W{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(t){return t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t}_mergeConfigObj(t,e){const i=r(e)?H.getDataAttribute(e,"config"):{};return{...this.constructor.Default,..."object"==typeof i?i:{},...r(e)?H.getDataAttributes(e):{},..."object"==typeof t?t:{}}}_typeCheckConfig(t,e=this.constructor.DefaultType){for(const[i,n]of Object.entries(e)){const e=t[i],o=r(e)?"element":s(e);if(!new RegExp(n).test(o))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${i}" provided type "${o}" but expected type "${n}".`)}}}class B extends W{constructor(t,i){super(),(t=a(t))&&(this._element=t,this._config=this._getConfig(i),e.set(this._element,this.constructor.DATA_KEY,this))}dispose(){e.remove(this._element,this.constructor.DATA_KEY),P.off(this._element,this.constructor.EVENT_KEY);for(const t of Object.getOwnPropertyNames(this))this[t]=null}_queueCallback(t,e,i=!0){b(t,e,i)}_getConfig(t){return t=this._mergeConfigObj(t,this._element),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}static getInstance(t){return e.get(a(t),this.DATA_KEY)}static getOrCreateInstance(t,e={}){return this.getInstance(t)||new this(t,"object"==typeof e?e:null)}static get VERSION(){return"5.3.8"}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(t){return`${t}${this.EVENT_KEY}`}}const z=t=>{let e=t.getAttribute("data-bs-target");if(!e||"#"===e){let i=t.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i=`#${i.split("#")[1]}`),e=i&&"#"!==i?i.trim():null}return e?e.split(",").map(t=>n(t)).join(","):null},R={find:(t,e=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(e,t)),findOne:(t,e=document.documentElement)=>Element.prototype.querySelector.call(e,t),children:(t,e)=>[].concat(...t.children).filter(t=>t.matches(e)),parents(t,e){const i=[];let n=t.parentNode.closest(e);for(;n;)i.push(n),n=n.parentNode.closest(e);return i},prev(t,e){let i=t.previousElementSibling;for(;i;){if(i.matches(e))return[i];i=i.previousElementSibling}return[]},next(t,e){let i=t.nextElementSibling;for(;i;){if(i.matches(e))return[i];i=i.nextElementSibling}return[]},focusableChildren(t){const e=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map(t=>`${t}:not([tabindex^="-"])`).join(",");return this.find(e,t).filter(t=>!c(t)&&l(t))},getSelectorFromElement(t){const e=z(t);return e&&R.findOne(e)?e:null},getElementFromSelector(t){const e=z(t);return e?R.findOne(e):null},getMultipleElementsFromSelector(t){const e=z(t);return e?R.find(e):[]}},q=(t,e="hide")=>{const i=`click.dismiss${t.EVENT_KEY}`,n=t.NAME;P.on(document,i,`[data-bs-dismiss="${n}"]`,function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),c(this))return;const s=R.getElementFromSelector(this)||this.closest(`.${n}`);t.getOrCreateInstance(s)[e]()})},V=".bs.alert",K=`close${V}`,Q=`closed${V}`;class X extends B{static get NAME(){return"alert"}close(){if(P.trigger(this._element,K).defaultPrevented)return;this._element.classList.remove("show");const t=this._element.classList.contains("fade");this._queueCallback(()=>this._destroyElement(),this._element,t)}_destroyElement(){this._element.remove(),P.trigger(this._element,Q),this.dispose()}static jQueryInterface(t){return this.each(function(){const e=X.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}})}}q(X,"close"),g(X);const Y='[data-bs-toggle="button"]';class U extends B{static get NAME(){return"button"}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(t){return this.each(function(){const e=U.getOrCreateInstance(this);"toggle"===t&&e[t]()})}}P.on(document,"click.bs.button.data-api",Y,t=>{t.preventDefault();const e=t.target.closest(Y);U.getOrCreateInstance(e).toggle()}),g(U);const G=".bs.swipe",J=`touchstart${G}`,Z=`touchmove${G}`,tt=`touchend${G}`,et=`pointerdown${G}`,it=`pointerup${G}`,nt={endCallback:null,leftCallback:null,rightCallback:null},st={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class ot extends W{constructor(t,e){super(),this._element=t,t&&ot.isSupported()&&(this._config=this._getConfig(e),this._deltaX=0,this._supportPointerEvents=Boolean(window.PointerEvent),this._initEvents())}static get Default(){return nt}static get DefaultType(){return st}static get NAME(){return"swipe"}dispose(){P.off(this._element,G)}_start(t){this._supportPointerEvents?this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX):this._deltaX=t.touches[0].clientX}_end(t){this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX-this._deltaX),this._handleSwipe(),_(this._config.endCallback)}_move(t){this._deltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this._deltaX}_handleSwipe(){const t=Math.abs(this._deltaX);if(t<=40)return;const e=t/this._deltaX;this._deltaX=0,e&&_(e>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(P.on(this._element,et,t=>this._start(t)),P.on(this._element,it,t=>this._end(t)),this._element.classList.add("pointer-event")):(P.on(this._element,J,t=>this._start(t)),P.on(this._element,Z,t=>this._move(t)),P.on(this._element,tt,t=>this._end(t)))}_eventIsPointerPenTouch(t){return this._supportPointerEvents&&("pen"===t.pointerType||"touch"===t.pointerType)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const rt=".bs.carousel",at=".data-api",lt="ArrowLeft",ct="ArrowRight",ht="next",dt="prev",ut="left",ft="right",pt=`slide${rt}`,mt=`slid${rt}`,gt=`keydown${rt}`,_t=`mouseenter${rt}`,bt=`mouseleave${rt}`,vt=`dragstart${rt}`,yt=`load${rt}${at}`,wt=`click${rt}${at}`,At="carousel",Et="active",Tt=".active",Ct=".carousel-item",Ot=Tt+Ct,xt={[lt]:ft,[ct]:ut},kt={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},Lt={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class St extends B{constructor(t,e){super(t,e),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=R.findOne(".carousel-indicators",this._element),this._addEventListeners(),this._config.ride===At&&this.cycle()}static get Default(){return kt}static get DefaultType(){return Lt}static get NAME(){return"carousel"}next(){this._slide(ht)}nextWhenVisible(){!document.hidden&&l(this._element)&&this.next()}prev(){this._slide(dt)}pause(){this._isSliding&&o(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval(()=>this.nextWhenVisible(),this._config.interval)}_maybeEnableCycle(){this._config.ride&&(this._isSliding?P.one(this._element,mt,()=>this.cycle()):this.cycle())}to(t){const e=this._getItems();if(t>e.length-1||t<0)return;if(this._isSliding)return void P.one(this._element,mt,()=>this.to(t));const i=this._getItemIndex(this._getActive());if(i===t)return;const n=t>i?ht:dt;this._slide(n,e[t])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(t){return t.defaultInterval=t.interval,t}_addEventListeners(){this._config.keyboard&&P.on(this._element,gt,t=>this._keydown(t)),"hover"===this._config.pause&&(P.on(this._element,_t,()=>this.pause()),P.on(this._element,bt,()=>this._maybeEnableCycle())),this._config.touch&&ot.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const t of R.find(".carousel-item img",this._element))P.on(t,vt,t=>t.preventDefault());const t={leftCallback:()=>this._slide(this._directionToOrder(ut)),rightCallback:()=>this._slide(this._directionToOrder(ft)),endCallback:()=>{"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout(()=>this._maybeEnableCycle(),500+this._config.interval))}};this._swipeHelper=new ot(this._element,t)}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;const e=xt[t.key];e&&(t.preventDefault(),this._slide(this._directionToOrder(e)))}_getItemIndex(t){return this._getItems().indexOf(t)}_setActiveIndicatorElement(t){if(!this._indicatorsElement)return;const e=R.findOne(Tt,this._indicatorsElement);e.classList.remove(Et),e.removeAttribute("aria-current");const i=R.findOne(`[data-bs-slide-to="${t}"]`,this._indicatorsElement);i&&(i.classList.add(Et),i.setAttribute("aria-current","true"))}_updateInterval(){const t=this._activeElement||this._getActive();if(!t)return;const e=Number.parseInt(t.getAttribute("data-bs-interval"),10);this._config.interval=e||this._config.defaultInterval}_slide(t,e=null){if(this._isSliding)return;const i=this._getActive(),n=t===ht,s=e||v(this._getItems(),i,n,this._config.wrap);if(s===i)return;const o=this._getItemIndex(s),r=e=>P.trigger(this._element,e,{relatedTarget:s,direction:this._orderToDirection(t),from:this._getItemIndex(i),to:o});if(r(pt).defaultPrevented)return;if(!i||!s)return;const a=Boolean(this._interval);this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(o),this._activeElement=s;const l=n?"carousel-item-start":"carousel-item-end",c=n?"carousel-item-next":"carousel-item-prev";s.classList.add(c),u(s),i.classList.add(l),s.classList.add(l),this._queueCallback(()=>{s.classList.remove(l,c),s.classList.add(Et),i.classList.remove(Et,c,l),this._isSliding=!1,r(mt)},i,this._isAnimated()),a&&this.cycle()}_isAnimated(){return this._element.classList.contains("slide")}_getActive(){return R.findOne(Ot,this._element)}_getItems(){return R.find(Ct,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(t){return m()?t===ut?dt:ht:t===ut?ht:dt}_orderToDirection(t){return m()?t===dt?ut:ft:t===dt?ft:ut}static jQueryInterface(t){return this.each(function(){const e=St.getOrCreateInstance(this,t);if("number"!=typeof t){if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t]()}}else e.to(t)})}}P.on(document,wt,"[data-bs-slide], [data-bs-slide-to]",function(t){const e=R.getElementFromSelector(this);if(!e||!e.classList.contains(At))return;t.preventDefault();const i=St.getOrCreateInstance(e),n=this.getAttribute("data-bs-slide-to");return n?(i.to(n),void i._maybeEnableCycle()):"next"===H.getDataAttribute(this,"slide")?(i.next(),void i._maybeEnableCycle()):(i.prev(),void i._maybeEnableCycle())}),P.on(window,yt,()=>{const t=R.find('[data-bs-ride="carousel"]');for(const e of t)St.getOrCreateInstance(e)}),g(St);const Dt=".bs.collapse",$t=`show${Dt}`,It=`shown${Dt}`,Nt=`hide${Dt}`,Pt=`hidden${Dt}`,jt=`click${Dt}.data-api`,Mt="show",Ft="collapse",Ht="collapsing",Wt=`:scope .${Ft} .${Ft}`,Bt='[data-bs-toggle="collapse"]',zt={parent:null,toggle:!0},Rt={parent:"(null|element)",toggle:"boolean"};class qt extends B{constructor(t,e){super(t,e),this._isTransitioning=!1,this._triggerArray=[];const i=R.find(Bt);for(const t of i){const e=R.getSelectorFromElement(t),i=R.find(e).filter(t=>t===this._element);null!==e&&i.length&&this._triggerArray.push(t)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return zt}static get DefaultType(){return Rt}static get NAME(){return"collapse"}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t=[];if(this._config.parent&&(t=this._getFirstLevelChildren(".collapse.show, .collapse.collapsing").filter(t=>t!==this._element).map(t=>qt.getOrCreateInstance(t,{toggle:!1}))),t.length&&t[0]._isTransitioning)return;if(P.trigger(this._element,$t).defaultPrevented)return;for(const e of t)e.hide();const e=this._getDimension();this._element.classList.remove(Ft),this._element.classList.add(Ht),this._element.style[e]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const i=`scroll${e[0].toUpperCase()+e.slice(1)}`;this._queueCallback(()=>{this._isTransitioning=!1,this._element.classList.remove(Ht),this._element.classList.add(Ft,Mt),this._element.style[e]="",P.trigger(this._element,It)},this._element,!0),this._element.style[e]=`${this._element[i]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(P.trigger(this._element,Nt).defaultPrevented)return;const t=this._getDimension();this._element.style[t]=`${this._element.getBoundingClientRect()[t]}px`,u(this._element),this._element.classList.add(Ht),this._element.classList.remove(Ft,Mt);for(const t of this._triggerArray){const e=R.getElementFromSelector(t);e&&!this._isShown(e)&&this._addAriaAndCollapsedClass([t],!1)}this._isTransitioning=!0,this._element.style[t]="",this._queueCallback(()=>{this._isTransitioning=!1,this._element.classList.remove(Ht),this._element.classList.add(Ft),P.trigger(this._element,Pt)},this._element,!0)}_isShown(t=this._element){return t.classList.contains(Mt)}_configAfterMerge(t){return t.toggle=Boolean(t.toggle),t.parent=a(t.parent),t}_getDimension(){return this._element.classList.contains("collapse-horizontal")?"width":"height"}_initializeChildren(){if(!this._config.parent)return;const t=this._getFirstLevelChildren(Bt);for(const e of t){const t=R.getElementFromSelector(e);t&&this._addAriaAndCollapsedClass([e],this._isShown(t))}}_getFirstLevelChildren(t){const e=R.find(Wt,this._config.parent);return R.find(t,this._config.parent).filter(t=>!e.includes(t))}_addAriaAndCollapsedClass(t,e){if(t.length)for(const i of t)i.classList.toggle("collapsed",!e),i.setAttribute("aria-expanded",e)}static jQueryInterface(t){const e={};return"string"==typeof t&&/show|hide/.test(t)&&(e.toggle=!1),this.each(function(){const i=qt.getOrCreateInstance(this,e);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}})}}P.on(document,jt,Bt,function(t){("A"===t.target.tagName||t.delegateTarget&&"A"===t.delegateTarget.tagName)&&t.preventDefault();for(const t of R.getMultipleElementsFromSelector(this))qt.getOrCreateInstance(t,{toggle:!1}).toggle()}),g(qt);var Vt="top",Kt="bottom",Qt="right",Xt="left",Yt="auto",Ut=[Vt,Kt,Qt,Xt],Gt="start",Jt="end",Zt="clippingParents",te="viewport",ee="popper",ie="reference",ne=Ut.reduce(function(t,e){return t.concat([e+"-"+Gt,e+"-"+Jt])},[]),se=[].concat(Ut,[Yt]).reduce(function(t,e){return t.concat([e,e+"-"+Gt,e+"-"+Jt])},[]),oe="beforeRead",re="read",ae="afterRead",le="beforeMain",ce="main",he="afterMain",de="beforeWrite",ue="write",fe="afterWrite",pe=[oe,re,ae,le,ce,he,de,ue,fe];function me(t){return t?(t.nodeName||"").toLowerCase():null}function ge(t){if(null==t)return window;if("[object Window]"!==t.toString()){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function _e(t){return t instanceof ge(t).Element||t instanceof Element}function be(t){return t instanceof ge(t).HTMLElement||t instanceof HTMLElement}function ve(t){return"undefined"!=typeof ShadowRoot&&(t instanceof ge(t).ShadowRoot||t instanceof ShadowRoot)}const ye={name:"applyStyles",enabled:!0,phase:"write",fn:function(t){var e=t.state;Object.keys(e.elements).forEach(function(t){var i=e.styles[t]||{},n=e.attributes[t]||{},s=e.elements[t];be(s)&&me(s)&&(Object.assign(s.style,i),Object.keys(n).forEach(function(t){var e=n[t];!1===e?s.removeAttribute(t):s.setAttribute(t,!0===e?"":e)}))})},effect:function(t){var e=t.state,i={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,i.popper),e.styles=i,e.elements.arrow&&Object.assign(e.elements.arrow.style,i.arrow),function(){Object.keys(e.elements).forEach(function(t){var n=e.elements[t],s=e.attributes[t]||{},o=Object.keys(e.styles.hasOwnProperty(t)?e.styles[t]:i[t]).reduce(function(t,e){return t[e]="",t},{});be(n)&&me(n)&&(Object.assign(n.style,o),Object.keys(s).forEach(function(t){n.removeAttribute(t)}))})}},requires:["computeStyles"]};function we(t){return t.split("-")[0]}var Ae=Math.max,Ee=Math.min,Te=Math.round;function Ce(){var t=navigator.userAgentData;return null!=t&&t.brands&&Array.isArray(t.brands)?t.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Oe(){return!/^((?!chrome|android).)*safari/i.test(Ce())}function xe(t,e,i){void 0===e&&(e=!1),void 0===i&&(i=!1);var n=t.getBoundingClientRect(),s=1,o=1;e&&be(t)&&(s=t.offsetWidth>0&&Te(n.width)/t.offsetWidth||1,o=t.offsetHeight>0&&Te(n.height)/t.offsetHeight||1);var r=(_e(t)?ge(t):window).visualViewport,a=!Oe()&&i,l=(n.left+(a&&r?r.offsetLeft:0))/s,c=(n.top+(a&&r?r.offsetTop:0))/o,h=n.width/s,d=n.height/o;return{width:h,height:d,top:c,right:l+h,bottom:c+d,left:l,x:l,y:c}}function ke(t){var e=xe(t),i=t.offsetWidth,n=t.offsetHeight;return Math.abs(e.width-i)<=1&&(i=e.width),Math.abs(e.height-n)<=1&&(n=e.height),{x:t.offsetLeft,y:t.offsetTop,width:i,height:n}}function Le(t,e){var i=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(i&&ve(i)){var n=e;do{if(n&&t.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Se(t){return ge(t).getComputedStyle(t)}function De(t){return["table","td","th"].indexOf(me(t))>=0}function $e(t){return((_e(t)?t.ownerDocument:t.document)||window.document).documentElement}function Ie(t){return"html"===me(t)?t:t.assignedSlot||t.parentNode||(ve(t)?t.host:null)||$e(t)}function Ne(t){return be(t)&&"fixed"!==Se(t).position?t.offsetParent:null}function Pe(t){for(var e=ge(t),i=Ne(t);i&&De(i)&&"static"===Se(i).position;)i=Ne(i);return i&&("html"===me(i)||"body"===me(i)&&"static"===Se(i).position)?e:i||function(t){var e=/firefox/i.test(Ce());if(/Trident/i.test(Ce())&&be(t)&&"fixed"===Se(t).position)return null;var i=Ie(t);for(ve(i)&&(i=i.host);be(i)&&["html","body"].indexOf(me(i))<0;){var n=Se(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||e&&"filter"===n.willChange||e&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}(t)||e}function je(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function Me(t,e,i){return Ae(t,Ee(e,i))}function Fe(t){return Object.assign({},{top:0,right:0,bottom:0,left:0},t)}function He(t,e){return e.reduce(function(e,i){return e[i]=t,e},{})}const We={name:"arrow",enabled:!0,phase:"main",fn:function(t){var e,i=t.state,n=t.name,s=t.options,o=i.elements.arrow,r=i.modifiersData.popperOffsets,a=we(i.placement),l=je(a),c=[Xt,Qt].indexOf(a)>=0?"height":"width";if(o&&r){var h=function(t,e){return Fe("number"!=typeof(t="function"==typeof t?t(Object.assign({},e.rects,{placement:e.placement})):t)?t:He(t,Ut))}(s.padding,i),d=ke(o),u="y"===l?Vt:Xt,f="y"===l?Kt:Qt,p=i.rects.reference[c]+i.rects.reference[l]-r[l]-i.rects.popper[c],m=r[l]-i.rects.reference[l],g=Pe(o),_=g?"y"===l?g.clientHeight||0:g.clientWidth||0:0,b=p/2-m/2,v=h[u],y=_-d[c]-h[f],w=_/2-d[c]/2+b,A=Me(v,w,y),E=l;i.modifiersData[n]=((e={})[E]=A,e.centerOffset=A-w,e)}},effect:function(t){var e=t.state,i=t.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=e.elements.popper.querySelector(n)))&&Le(e.elements.popper,n)&&(e.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Be(t){return t.split("-")[1]}var ze={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Re(t){var e,i=t.popper,n=t.popperRect,s=t.placement,o=t.variation,r=t.offsets,a=t.position,l=t.gpuAcceleration,c=t.adaptive,h=t.roundOffsets,d=t.isFixed,u=r.x,f=void 0===u?0:u,p=r.y,m=void 0===p?0:p,g="function"==typeof h?h({x:f,y:m}):{x:f,y:m};f=g.x,m=g.y;var _=r.hasOwnProperty("x"),b=r.hasOwnProperty("y"),v=Xt,y=Vt,w=window;if(c){var A=Pe(i),E="clientHeight",T="clientWidth";A===ge(i)&&"static"!==Se(A=$e(i)).position&&"absolute"===a&&(E="scrollHeight",T="scrollWidth"),(s===Vt||(s===Xt||s===Qt)&&o===Jt)&&(y=Kt,m-=(d&&A===w&&w.visualViewport?w.visualViewport.height:A[E])-n.height,m*=l?1:-1),s!==Xt&&(s!==Vt&&s!==Kt||o!==Jt)||(v=Qt,f-=(d&&A===w&&w.visualViewport?w.visualViewport.width:A[T])-n.width,f*=l?1:-1)}var C,O=Object.assign({position:a},c&&ze),x=!0===h?function(t,e){var i=t.x,n=t.y,s=e.devicePixelRatio||1;return{x:Te(i*s)/s||0,y:Te(n*s)/s||0}}({x:f,y:m},ge(i)):{x:f,y:m};return f=x.x,m=x.y,l?Object.assign({},O,((C={})[y]=b?"0":"",C[v]=_?"0":"",C.transform=(w.devicePixelRatio||1)<=1?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",C)):Object.assign({},O,((e={})[y]=b?m+"px":"",e[v]=_?f+"px":"",e.transform="",e))}const qe={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(t){var e=t.state,i=t.options,n=i.gpuAcceleration,s=void 0===n||n,o=i.adaptive,r=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:we(e.placement),variation:Be(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:s,isFixed:"fixed"===e.options.strategy};null!=e.modifiersData.popperOffsets&&(e.styles.popper=Object.assign({},e.styles.popper,Re(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:r,roundOffsets:l})))),null!=e.modifiersData.arrow&&(e.styles.arrow=Object.assign({},e.styles.arrow,Re(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})},data:{}};var Ve={passive:!0};const Ke={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(t){var e=t.state,i=t.instance,n=t.options,s=n.scroll,o=void 0===s||s,r=n.resize,a=void 0===r||r,l=ge(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return o&&c.forEach(function(t){t.addEventListener("scroll",i.update,Ve)}),a&&l.addEventListener("resize",i.update,Ve),function(){o&&c.forEach(function(t){t.removeEventListener("scroll",i.update,Ve)}),a&&l.removeEventListener("resize",i.update,Ve)}},data:{}};var Qe={left:"right",right:"left",bottom:"top",top:"bottom"};function Xe(t){return t.replace(/left|right|bottom|top/g,function(t){return Qe[t]})}var Ye={start:"end",end:"start"};function Ue(t){return t.replace(/start|end/g,function(t){return Ye[t]})}function Ge(t){var e=ge(t);return{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Je(t){return xe($e(t)).left+Ge(t).scrollLeft}function Ze(t){var e=Se(t),i=e.overflow,n=e.overflowX,s=e.overflowY;return/auto|scroll|overlay|hidden/.test(i+s+n)}function ti(t){return["html","body","#document"].indexOf(me(t))>=0?t.ownerDocument.body:be(t)&&Ze(t)?t:ti(Ie(t))}function ei(t,e){var i;void 0===e&&(e=[]);var n=ti(t),s=n===(null==(i=t.ownerDocument)?void 0:i.body),o=ge(n),r=s?[o].concat(o.visualViewport||[],Ze(n)?n:[]):n,a=e.concat(r);return s?a:a.concat(ei(Ie(r)))}function ii(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function ni(t,e,i){return e===te?ii(function(t,e){var i=ge(t),n=$e(t),s=i.visualViewport,o=n.clientWidth,r=n.clientHeight,a=0,l=0;if(s){o=s.width,r=s.height;var c=Oe();(c||!c&&"fixed"===e)&&(a=s.offsetLeft,l=s.offsetTop)}return{width:o,height:r,x:a+Je(t),y:l}}(t,i)):_e(e)?function(t,e){var i=xe(t,!1,"fixed"===e);return i.top=i.top+t.clientTop,i.left=i.left+t.clientLeft,i.bottom=i.top+t.clientHeight,i.right=i.left+t.clientWidth,i.width=t.clientWidth,i.height=t.clientHeight,i.x=i.left,i.y=i.top,i}(e,i):ii(function(t){var e,i=$e(t),n=Ge(t),s=null==(e=t.ownerDocument)?void 0:e.body,o=Ae(i.scrollWidth,i.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),r=Ae(i.scrollHeight,i.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),a=-n.scrollLeft+Je(t),l=-n.scrollTop;return"rtl"===Se(s||i).direction&&(a+=Ae(i.clientWidth,s?s.clientWidth:0)-o),{width:o,height:r,x:a,y:l}}($e(t)))}function si(t){var e,i=t.reference,n=t.element,s=t.placement,o=s?we(s):null,r=s?Be(s):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case Vt:e={x:a,y:i.y-n.height};break;case Kt:e={x:a,y:i.y+i.height};break;case Qt:e={x:i.x+i.width,y:l};break;case Xt:e={x:i.x-n.width,y:l};break;default:e={x:i.x,y:i.y}}var c=o?je(o):null;if(null!=c){var h="y"===c?"height":"width";switch(r){case Gt:e[c]=e[c]-(i[h]/2-n[h]/2);break;case Jt:e[c]=e[c]+(i[h]/2-n[h]/2)}}return e}function oi(t,e){void 0===e&&(e={});var i=e,n=i.placement,s=void 0===n?t.placement:n,o=i.strategy,r=void 0===o?t.strategy:o,a=i.boundary,l=void 0===a?Zt:a,c=i.rootBoundary,h=void 0===c?te:c,d=i.elementContext,u=void 0===d?ee:d,f=i.altBoundary,p=void 0!==f&&f,m=i.padding,g=void 0===m?0:m,_=Fe("number"!=typeof g?g:He(g,Ut)),b=u===ee?ie:ee,v=t.rects.popper,y=t.elements[p?b:u],w=function(t,e,i,n){var s="clippingParents"===e?function(t){var e=ei(Ie(t)),i=["absolute","fixed"].indexOf(Se(t).position)>=0&&be(t)?Pe(t):t;return _e(i)?e.filter(function(t){return _e(t)&&Le(t,i)&&"body"!==me(t)}):[]}(t):[].concat(e),o=[].concat(s,[i]),r=o[0],a=o.reduce(function(e,i){var s=ni(t,i,n);return e.top=Ae(s.top,e.top),e.right=Ee(s.right,e.right),e.bottom=Ee(s.bottom,e.bottom),e.left=Ae(s.left,e.left),e},ni(t,r,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}(_e(y)?y:y.contextElement||$e(t.elements.popper),l,h,r),A=xe(t.elements.reference),E=si({reference:A,element:v,placement:s}),T=ii(Object.assign({},v,E)),C=u===ee?T:A,O={top:w.top-C.top+_.top,bottom:C.bottom-w.bottom+_.bottom,left:w.left-C.left+_.left,right:C.right-w.right+_.right},x=t.modifiersData.offset;if(u===ee&&x){var k=x[s];Object.keys(O).forEach(function(t){var e=[Qt,Kt].indexOf(t)>=0?1:-1,i=[Vt,Kt].indexOf(t)>=0?"y":"x";O[t]+=k[i]*e})}return O}function ri(t,e){void 0===e&&(e={});var i=e,n=i.placement,s=i.boundary,o=i.rootBoundary,r=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?se:l,h=Be(n),d=h?a?ne:ne.filter(function(t){return Be(t)===h}):Ut,u=d.filter(function(t){return c.indexOf(t)>=0});0===u.length&&(u=d);var f=u.reduce(function(e,i){return e[i]=oi(t,{placement:i,boundary:s,rootBoundary:o,padding:r})[we(i)],e},{});return Object.keys(f).sort(function(t,e){return f[t]-f[e]})}const ai={name:"flip",enabled:!0,phase:"main",fn:function(t){var e=t.state,i=t.options,n=t.name;if(!e.modifiersData[n]._skip){for(var s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0===r||r,l=i.fallbackPlacements,c=i.padding,h=i.boundary,d=i.rootBoundary,u=i.altBoundary,f=i.flipVariations,p=void 0===f||f,m=i.allowedAutoPlacements,g=e.options.placement,_=we(g),b=l||(_!==g&&p?function(t){if(we(t)===Yt)return[];var e=Xe(t);return[Ue(t),e,Ue(e)]}(g):[Xe(g)]),v=[g].concat(b).reduce(function(t,i){return t.concat(we(i)===Yt?ri(e,{placement:i,boundary:h,rootBoundary:d,padding:c,flipVariations:p,allowedAutoPlacements:m}):i)},[]),y=e.rects.reference,w=e.rects.popper,A=new Map,E=!0,T=v[0],C=0;C<v.length;C++){var O=v[C],x=we(O),k=Be(O)===Gt,L=[Vt,Kt].indexOf(x)>=0,S=L?"width":"height",D=oi(e,{placement:O,boundary:h,rootBoundary:d,altBoundary:u,padding:c}),$=L?k?Qt:Xt:k?Kt:Vt;y[S]>w[S]&&($=Xe($));var I=Xe($),N=[];if(o&&N.push(D[x]<=0),a&&N.push(D[$]<=0,D[I]<=0),N.every(function(t){return t})){T=O,E=!1;break}A.set(O,N)}if(E)for(var P=function(t){var e=v.find(function(e){var i=A.get(e);if(i)return i.slice(0,t).every(function(t){return t})});if(e)return T=e,"break"},j=p?3:1;j>0&&"break"!==P(j);j--);e.placement!==T&&(e.modifiersData[n]._skip=!0,e.placement=T,e.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function li(t,e,i){return void 0===i&&(i={x:0,y:0}),{top:t.top-e.height-i.y,right:t.right-e.width+i.x,bottom:t.bottom-e.height+i.y,left:t.left-e.width-i.x}}function ci(t){return[Vt,Qt,Kt,Xt].some(function(e){return t[e]>=0})}const hi={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(t){var e=t.state,i=t.name,n=e.rects.reference,s=e.rects.popper,o=e.modifiersData.preventOverflow,r=oi(e,{elementContext:"reference"}),a=oi(e,{altBoundary:!0}),l=li(r,n),c=li(a,s,o),h=ci(l),d=ci(c);e.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:h,hasPopperEscaped:d},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":h,"data-popper-escaped":d})}},di={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(t){var e=t.state,i=t.options,n=t.name,s=i.offset,o=void 0===s?[0,0]:s,r=se.reduce(function(t,i){return t[i]=function(t,e,i){var n=we(t),s=[Xt,Vt].indexOf(n)>=0?-1:1,o="function"==typeof i?i(Object.assign({},e,{placement:t})):i,r=o[0],a=o[1];return r=r||0,a=(a||0)*s,[Xt,Qt].indexOf(n)>=0?{x:a,y:r}:{x:r,y:a}}(i,e.rects,o),t},{}),a=r[e.placement],l=a.x,c=a.y;null!=e.modifiersData.popperOffsets&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=c),e.modifiersData[n]=r}},ui={name:"popperOffsets",enabled:!0,phase:"read",fn:function(t){var e=t.state,i=t.name;e.modifiersData[i]=si({reference:e.rects.reference,element:e.rects.popper,placement:e.placement})},data:{}},fi={name:"preventOverflow",enabled:!0,phase:"main",fn:function(t){var e=t.state,i=t.options,n=t.name,s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0!==r&&r,l=i.boundary,c=i.rootBoundary,h=i.altBoundary,d=i.padding,u=i.tether,f=void 0===u||u,p=i.tetherOffset,m=void 0===p?0:p,g=oi(e,{boundary:l,rootBoundary:c,padding:d,altBoundary:h}),_=we(e.placement),b=Be(e.placement),v=!b,y=je(_),w="x"===y?"y":"x",A=e.modifiersData.popperOffsets,E=e.rects.reference,T=e.rects.popper,C="function"==typeof m?m(Object.assign({},e.rects,{placement:e.placement})):m,O="number"==typeof C?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),x=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,k={x:0,y:0};if(A){if(o){var L,S="y"===y?Vt:Xt,D="y"===y?Kt:Qt,$="y"===y?"height":"width",I=A[y],N=I+g[S],P=I-g[D],j=f?-T[$]/2:0,M=b===Gt?E[$]:T[$],F=b===Gt?-T[$]:-E[$],H=e.elements.arrow,W=f&&H?ke(H):{width:0,height:0},B=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},z=B[S],R=B[D],q=Me(0,E[$],W[$]),V=v?E[$]/2-j-q-z-O.mainAxis:M-q-z-O.mainAxis,K=v?-E[$]/2+j+q+R+O.mainAxis:F+q+R+O.mainAxis,Q=e.elements.arrow&&Pe(e.elements.arrow),X=Q?"y"===y?Q.clientTop||0:Q.clientLeft||0:0,Y=null!=(L=null==x?void 0:x[y])?L:0,U=I+K-Y,G=Me(f?Ee(N,I+V-Y-X):N,I,f?Ae(P,U):P);A[y]=G,k[y]=G-I}if(a){var J,Z="x"===y?Vt:Xt,tt="x"===y?Kt:Qt,et=A[w],it="y"===w?"height":"width",nt=et+g[Z],st=et-g[tt],ot=-1!==[Vt,Xt].indexOf(_),rt=null!=(J=null==x?void 0:x[w])?J:0,at=ot?nt:et-E[it]-T[it]-rt+O.altAxis,lt=ot?et+E[it]+T[it]-rt-O.altAxis:st,ct=f&&ot?function(t,e,i){var n=Me(t,e,i);return n>i?i:n}(at,et,lt):Me(f?at:nt,et,f?lt:st);A[w]=ct,k[w]=ct-et}e.modifiersData[n]=k}},requiresIfExists:["offset"]};function pi(t,e,i){void 0===i&&(i=!1);var n,s,o=be(e),r=be(e)&&function(t){var e=t.getBoundingClientRect(),i=Te(e.width)/t.offsetWidth||1,n=Te(e.height)/t.offsetHeight||1;return 1!==i||1!==n}(e),a=$e(e),l=xe(t,r,i),c={scrollLeft:0,scrollTop:0},h={x:0,y:0};return(o||!o&&!i)&&(("body"!==me(e)||Ze(a))&&(c=(n=e)!==ge(n)&&be(n)?{scrollLeft:(s=n).scrollLeft,scrollTop:s.scrollTop}:Ge(n)),be(e)?((h=xe(e,!0)).x+=e.clientLeft,h.y+=e.clientTop):a&&(h.x=Je(a))),{x:l.left+c.scrollLeft-h.x,y:l.top+c.scrollTop-h.y,width:l.width,height:l.height}}function mi(t){var e=new Map,i=new Set,n=[];function s(t){i.add(t.name),[].concat(t.requires||[],t.requiresIfExists||[]).forEach(function(t){if(!i.has(t)){var n=e.get(t);n&&s(n)}}),n.push(t)}return t.forEach(function(t){e.set(t.name,t)}),t.forEach(function(t){i.has(t.name)||s(t)}),n}var gi={placement:"bottom",modifiers:[],strategy:"absolute"};function _i(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return!e.some(function(t){return!(t&&"function"==typeof t.getBoundingClientRect)})}function bi(t){void 0===t&&(t={});var e=t,i=e.defaultModifiers,n=void 0===i?[]:i,s=e.defaultOptions,o=void 0===s?gi:s;return function(t,e,i){void 0===i&&(i=o);var s,r,a={placement:"bottom",orderedModifiers:[],options:Object.assign({},gi,o),modifiersData:{},elements:{reference:t,popper:e},attributes:{},styles:{}},l=[],c=!1,h={state:a,setOptions:function(i){var s="function"==typeof i?i(a.options):i;d(),a.options=Object.assign({},o,a.options,s),a.scrollParents={reference:_e(t)?ei(t):t.contextElement?ei(t.contextElement):[],popper:ei(e)};var r,c,u=function(t){var e=mi(t);return pe.reduce(function(t,i){return t.concat(e.filter(function(t){return t.phase===i}))},[])}((r=[].concat(n,a.options.modifiers),c=r.reduce(function(t,e){var i=t[e.name];return t[e.name]=i?Object.assign({},i,e,{options:Object.assign({},i.options,e.options),data:Object.assign({},i.data,e.data)}):e,t},{}),Object.keys(c).map(function(t){return c[t]})));return a.orderedModifiers=u.filter(function(t){return t.enabled}),a.orderedModifiers.forEach(function(t){var e=t.name,i=t.options,n=void 0===i?{}:i,s=t.effect;if("function"==typeof s){var o=s({state:a,name:e,instance:h,options:n});l.push(o||function(){})}}),h.update()},forceUpdate:function(){if(!c){var t=a.elements,e=t.reference,i=t.popper;if(_i(e,i)){a.rects={reference:pi(e,Pe(i),"fixed"===a.options.strategy),popper:ke(i)},a.reset=!1,a.placement=a.options.placement,a.orderedModifiers.forEach(function(t){return a.modifiersData[t.name]=Object.assign({},t.data)});for(var n=0;n<a.orderedModifiers.length;n++)if(!0!==a.reset){var s=a.orderedModifiers[n],o=s.fn,r=s.options,l=void 0===r?{}:r,d=s.name;"function"==typeof o&&(a=o({state:a,options:l,name:d,instance:h})||a)}else a.reset=!1,n=-1}}},update:(s=function(){return new Promise(function(t){h.forceUpdate(),t(a)})},function(){return r||(r=new Promise(function(t){Promise.resolve().then(function(){r=void 0,t(s())})})),r}),destroy:function(){d(),c=!0}};if(!_i(t,e))return h;function d(){l.forEach(function(t){return t()}),l=[]}return h.setOptions(i).then(function(t){!c&&i.onFirstUpdate&&i.onFirstUpdate(t)}),h}}var vi=bi(),yi=bi({defaultModifiers:[Ke,ui,qe,ye]}),wi=bi({defaultModifiers:[Ke,ui,qe,ye,di,ai,fi,We,hi]});const Ai=Object.freeze(Object.defineProperty({__proto__:null,afterMain:he,afterRead:ae,afterWrite:fe,applyStyles:ye,arrow:We,auto:Yt,basePlacements:Ut,beforeMain:le,beforeRead:oe,beforeWrite:de,bottom:Kt,clippingParents:Zt,computeStyles:qe,createPopper:wi,createPopperBase:vi,createPopperLite:yi,detectOverflow:oi,end:Jt,eventListeners:Ke,flip:ai,hide:hi,left:Xt,main:ce,modifierPhases:pe,offset:di,placements:se,popper:ee,popperGenerator:bi,popperOffsets:ui,preventOverflow:fi,read:re,reference:ie,right:Qt,start:Gt,top:Vt,variationPlacements:ne,viewport:te,write:ue},Symbol.toStringTag,{value:"Module"})),Ei="dropdown",Ti=".bs.dropdown",Ci=".data-api",Oi="ArrowUp",xi="ArrowDown",ki=`hide${Ti}`,Li=`hidden${Ti}`,Si=`show${Ti}`,Di=`shown${Ti}`,$i=`click${Ti}${Ci}`,Ii=`keydown${Ti}${Ci}`,Ni=`keyup${Ti}${Ci}`,Pi="show",ji='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',Mi=`${ji}.${Pi}`,Fi=".dropdown-menu",Hi=m()?"top-end":"top-start",Wi=m()?"top-start":"top-end",Bi=m()?"bottom-end":"bottom-start",zi=m()?"bottom-start":"bottom-end",Ri=m()?"left-start":"right-start",qi=m()?"right-start":"left-start",Vi={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},Ki={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"};class Qi extends B{constructor(t,e){super(t,e),this._popper=null,this._parent=this._element.parentNode,this._menu=R.next(this._element,Fi)[0]||R.prev(this._element,Fi)[0]||R.findOne(Fi,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return Vi}static get DefaultType(){return Ki}static get NAME(){return Ei}toggle(){return this._isShown()?this.hide():this.show()}show(){if(c(this._element)||this._isShown())return;const t={relatedTarget:this._element};if(!P.trigger(this._element,Si,t).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(".navbar-nav"))for(const t of[].concat(...document.body.children))P.on(t,"mouseover",d);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(Pi),this._element.classList.add(Pi),P.trigger(this._element,Di,t)}}hide(){if(c(this._element)||!this._isShown())return;const t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){if(!P.trigger(this._element,ki,t).defaultPrevented){if("ontouchstart"in document.documentElement)for(const t of[].concat(...document.body.children))P.off(t,"mouseover",d);this._popper&&this._popper.destroy(),this._menu.classList.remove(Pi),this._element.classList.remove(Pi),this._element.setAttribute("aria-expanded","false"),H.removeDataAttribute(this._menu,"popper"),P.trigger(this._element,Li,t)}}_getConfig(t){if("object"==typeof(t=super._getConfig(t)).reference&&!r(t.reference)&&"function"!=typeof t.reference.getBoundingClientRect)throw new TypeError(`${Ei.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return t}_createPopper(){if(void 0===Ai)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org/docs/v2/)");let t=this._element;"parent"===this._config.reference?t=this._parent:r(this._config.reference)?t=a(this._config.reference):"object"==typeof this._config.reference&&(t=this._config.reference);const e=this._getPopperConfig();this._popper=wi(t,this._menu,e)}_isShown(){return this._menu.classList.contains(Pi)}_getPlacement(){const t=this._parent;if(t.classList.contains("dropend"))return Ri;if(t.classList.contains("dropstart"))return qi;if(t.classList.contains("dropup-center"))return"top";if(t.classList.contains("dropdown-center"))return"bottom";const e="end"===getComputedStyle(this._menu).getPropertyValue("--bs-position").trim();return t.classList.contains("dropup")?e?Wi:Hi:e?zi:Bi}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map(t=>Number.parseInt(t,10)):"function"==typeof t?e=>t(e,this._element):t}_getPopperConfig(){const t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||"static"===this._config.display)&&(H.setDataAttribute(this._menu,"popper","static"),t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,..._(this._config.popperConfig,[void 0,t])}}_selectMenuItem({key:t,target:e}){const i=R.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",this._menu).filter(t=>l(t));i.length&&v(i,e,t===xi,!i.includes(e)).focus()}static jQueryInterface(t){return this.each(function(){const e=Qi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}})}static clearMenus(t){if(2===t.button||"keyup"===t.type&&"Tab"!==t.key)return;const e=R.find(Mi);for(const i of e){const e=Qi.getInstance(i);if(!e||!1===e._config.autoClose)continue;const n=t.composedPath(),s=n.includes(e._menu);if(n.includes(e._element)||"inside"===e._config.autoClose&&!s||"outside"===e._config.autoClose&&s)continue;if(e._menu.contains(t.target)&&("keyup"===t.type&&"Tab"===t.key||/input|select|option|textarea|form/i.test(t.target.tagName)))continue;const o={relatedTarget:e._element};"click"===t.type&&(o.clickEvent=t),e._completeHide(o)}}static dataApiKeydownHandler(t){const e=/input|textarea/i.test(t.target.tagName),i="Escape"===t.key,n=[Oi,xi].includes(t.key);if(!n&&!i)return;if(e&&!i)return;t.preventDefault();const s=this.matches(ji)?this:R.prev(this,ji)[0]||R.next(this,ji)[0]||R.findOne(ji,t.delegateTarget.parentNode),o=Qi.getOrCreateInstance(s);if(n)return t.stopPropagation(),o.show(),void o._selectMenuItem(t);o._isShown()&&(t.stopPropagation(),o.hide(),s.focus())}}P.on(document,Ii,ji,Qi.dataApiKeydownHandler),P.on(document,Ii,Fi,Qi.dataApiKeydownHandler),P.on(document,$i,Qi.clearMenus),P.on(document,Ni,Qi.clearMenus),P.on(document,$i,ji,function(t){t.preventDefault(),Qi.getOrCreateInstance(this).toggle()}),g(Qi);const Xi="backdrop",Yi="show",Ui=`mousedown.bs.${Xi}`,Gi={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},Ji={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class Zi extends W{constructor(t){super(),this._config=this._getConfig(t),this._isAppended=!1,this._element=null}static get Default(){return Gi}static get DefaultType(){return Ji}static get NAME(){return Xi}show(t){if(!this._config.isVisible)return void _(t);this._append();const e=this._getElement();this._config.isAnimated&&u(e),e.classList.add(Yi),this._emulateAnimation(()=>{_(t)})}hide(t){this._config.isVisible?(this._getElement().classList.remove(Yi),this._emulateAnimation(()=>{this.dispose(),_(t)})):_(t)}dispose(){this._isAppended&&(P.off(this._element,Ui),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add("fade"),this._element=t}return this._element}_configAfterMerge(t){return t.rootElement=a(t.rootElement),t}_append(){if(this._isAppended)return;const t=this._getElement();this._config.rootElement.append(t),P.on(t,Ui,()=>{_(this._config.clickCallback)}),this._isAppended=!0}_emulateAnimation(t){b(t,this._getElement(),this._config.isAnimated)}}const tn=".bs.focustrap",en=`focusin${tn}`,nn=`keydown.tab${tn}`,sn="backward",on={autofocus:!0,trapElement:null},rn={autofocus:"boolean",trapElement:"element"};class an extends W{constructor(t){super(),this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return on}static get DefaultType(){return rn}static get NAME(){return"focustrap"}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),P.off(document,tn),P.on(document,en,t=>this._handleFocusin(t)),P.on(document,nn,t=>this._handleKeydown(t)),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,P.off(document,tn))}_handleFocusin(t){const{trapElement:e}=this._config;if(t.target===document||t.target===e||e.contains(t.target))return;const i=R.focusableChildren(e);0===i.length?e.focus():this._lastTabNavDirection===sn?i[i.length-1].focus():i[0].focus()}_handleKeydown(t){"Tab"===t.key&&(this._lastTabNavDirection=t.shiftKey?sn:"forward")}}const ln=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",cn=".sticky-top",hn="padding-right",dn="margin-right";class un{constructor(){this._element=document.body}getWidth(){const t=document.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}hide(){const t=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,hn,e=>e+t),this._setElementAttributes(ln,hn,e=>e+t),this._setElementAttributes(cn,dn,e=>e-t)}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,hn),this._resetElementAttributes(ln,hn),this._resetElementAttributes(cn,dn)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,e,i){const n=this.getWidth();this._applyManipulationCallback(t,t=>{if(t!==this._element&&window.innerWidth>t.clientWidth+n)return;this._saveInitialAttribute(t,e);const s=window.getComputedStyle(t).getPropertyValue(e);t.style.setProperty(e,`${i(Number.parseFloat(s))}px`)})}_saveInitialAttribute(t,e){const i=t.style.getPropertyValue(e);i&&H.setDataAttribute(t,e,i)}_resetElementAttributes(t,e){this._applyManipulationCallback(t,t=>{const i=H.getDataAttribute(t,e);null!==i?(H.removeDataAttribute(t,e),t.style.setProperty(e,i)):t.style.removeProperty(e)})}_applyManipulationCallback(t,e){if(r(t))e(t);else for(const i of R.find(t,this._element))e(i)}}const fn=".bs.modal",pn=`hide${fn}`,mn=`hidePrevented${fn}`,gn=`hidden${fn}`,_n=`show${fn}`,bn=`shown${fn}`,vn=`resize${fn}`,yn=`click.dismiss${fn}`,wn=`mousedown.dismiss${fn}`,An=`keydown.dismiss${fn}`,En=`click${fn}.data-api`,Tn="modal-open",Cn="show",On="modal-static",xn={backdrop:!0,focus:!0,keyboard:!0},kn={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class Ln extends B{constructor(t,e){super(t,e),this._dialog=R.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new un,this._addEventListeners()}static get Default(){return xn}static get DefaultType(){return kn}static get NAME(){return"modal"}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||P.trigger(this._element,_n,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(Tn),this._adjustDialog(),this._backdrop.show(()=>this._showElement(t)))}hide(){this._isShown&&!this._isTransitioning&&(P.trigger(this._element,pn).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(Cn),this._queueCallback(()=>this._hideModal(),this._element,this._isAnimated())))}dispose(){P.off(window,fn),P.off(this._dialog,fn),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Zi({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new an({trapElement:this._element})}_showElement(t){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;const e=R.findOne(".modal-body",this._dialog);e&&(e.scrollTop=0),u(this._element),this._element.classList.add(Cn),this._queueCallback(()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,P.trigger(this._element,bn,{relatedTarget:t})},this._dialog,this._isAnimated())}_addEventListeners(){P.on(this._element,An,t=>{"Escape"===t.key&&(this._config.keyboard?this.hide():this._triggerBackdropTransition())}),P.on(window,vn,()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()}),P.on(this._element,wn,t=>{P.one(this._element,yn,e=>{this._element===t.target&&this._element===e.target&&("static"!==this._config.backdrop?this._config.backdrop&&this.hide():this._triggerBackdropTransition())})})}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide(()=>{document.body.classList.remove(Tn),this._resetAdjustments(),this._scrollBar.reset(),P.trigger(this._element,gn)})}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(P.trigger(this._element,mn).defaultPrevented)return;const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._element.style.overflowY;"hidden"===e||this._element.classList.contains(On)||(t||(this._element.style.overflowY="hidden"),this._element.classList.add(On),this._queueCallback(()=>{this._element.classList.remove(On),this._queueCallback(()=>{this._element.style.overflowY=e},this._dialog)},this._dialog),this._element.focus())}_adjustDialog(){const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._scrollBar.getWidth(),i=e>0;if(i&&!t){const t=m()?"paddingLeft":"paddingRight";this._element.style[t]=`${e}px`}if(!i&&t){const t=m()?"paddingRight":"paddingLeft";this._element.style[t]=`${e}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,e){return this.each(function(){const i=Ln.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t](e)}})}}P.on(document,En,'[data-bs-toggle="modal"]',function(t){const e=R.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&t.preventDefault(),P.one(e,_n,t=>{t.defaultPrevented||P.one(e,gn,()=>{l(this)&&this.focus()})});const i=R.findOne(".modal.show");i&&Ln.getInstance(i).hide(),Ln.getOrCreateInstance(e).toggle(this)}),q(Ln),g(Ln);const Sn=".bs.offcanvas",Dn=".data-api",$n=`load${Sn}${Dn}`,In="show",Nn="showing",Pn="hiding",jn=".offcanvas.show",Mn=`show${Sn}`,Fn=`shown${Sn}`,Hn=`hide${Sn}`,Wn=`hidePrevented${Sn}`,Bn=`hidden${Sn}`,zn=`resize${Sn}`,Rn=`click${Sn}${Dn}`,qn=`keydown.dismiss${Sn}`,Vn={backdrop:!0,keyboard:!0,scroll:!1},Kn={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class Qn extends B{constructor(t,e){super(t,e),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return Vn}static get DefaultType(){return Kn}static get NAME(){return"offcanvas"}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||P.trigger(this._element,Mn,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._backdrop.show(),this._config.scroll||(new un).hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(Nn),this._queueCallback(()=>{this._config.scroll&&!this._config.backdrop||this._focustrap.activate(),this._element.classList.add(In),this._element.classList.remove(Nn),P.trigger(this._element,Fn,{relatedTarget:t})},this._element,!0))}hide(){this._isShown&&(P.trigger(this._element,Hn).defaultPrevented||(this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(Pn),this._backdrop.hide(),this._queueCallback(()=>{this._element.classList.remove(In,Pn),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||(new un).reset(),P.trigger(this._element,Bn)},this._element,!0)))}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const t=Boolean(this._config.backdrop);return new Zi({className:"offcanvas-backdrop",isVisible:t,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:t?()=>{"static"!==this._config.backdrop?this.hide():P.trigger(this._element,Wn)}:null})}_initializeFocusTrap(){return new an({trapElement:this._element})}_addEventListeners(){P.on(this._element,qn,t=>{"Escape"===t.key&&(this._config.keyboard?this.hide():P.trigger(this._element,Wn))})}static jQueryInterface(t){return this.each(function(){const e=Qn.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}})}}P.on(document,Rn,'[data-bs-toggle="offcanvas"]',function(t){const e=R.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&t.preventDefault(),c(this))return;P.one(e,Bn,()=>{l(this)&&this.focus()});const i=R.findOne(jn);i&&i!==e&&Qn.getInstance(i).hide(),Qn.getOrCreateInstance(e).toggle(this)}),P.on(window,$n,()=>{for(const t of R.find(jn))Qn.getOrCreateInstance(t).show()}),P.on(window,zn,()=>{for(const t of R.find("[aria-modal][class*=show][class*=offcanvas-]"))"fixed"!==getComputedStyle(t).position&&Qn.getOrCreateInstance(t).hide()}),q(Qn),g(Qn);const Xn={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],dd:[],div:[],dl:[],dt:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},Yn=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Un=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,Gn=(t,e)=>{const i=t.nodeName.toLowerCase();return e.includes(i)?!Yn.has(i)||Boolean(Un.test(t.nodeValue)):e.filter(t=>t instanceof RegExp).some(t=>t.test(i))},Jn={allowList:Xn,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"<div></div>"},Zn={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},ts={entry:"(string|element|function|null)",selector:"(string|element)"};class es extends W{constructor(t){super(),this._config=this._getConfig(t)}static get Default(){return Jn}static get DefaultType(){return Zn}static get NAME(){return"TemplateFactory"}getContent(){return Object.values(this._config.content).map(t=>this._resolvePossibleFunction(t)).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(t){return this._checkContent(t),this._config.content={...this._config.content,...t},this}toHtml(){const t=document.createElement("div");t.innerHTML=this._maybeSanitize(this._config.template);for(const[e,i]of Object.entries(this._config.content))this._setContent(t,i,e);const e=t.children[0],i=this._resolvePossibleFunction(this._config.extraClass);return i&&e.classList.add(...i.split(" ")),e}_typeCheckConfig(t){super._typeCheckConfig(t),this._checkContent(t.content)}_checkContent(t){for(const[e,i]of Object.entries(t))super._typeCheckConfig({selector:e,entry:i},ts)}_setContent(t,e,i){const n=R.findOne(i,t);n&&((e=this._resolvePossibleFunction(e))?r(e)?this._putElementInTemplate(a(e),n):this._config.html?n.innerHTML=this._maybeSanitize(e):n.textContent=e:n.remove())}_maybeSanitize(t){return this._config.sanitize?function(t,e,i){if(!t.length)return t;if(i&&"function"==typeof i)return i(t);const n=(new window.DOMParser).parseFromString(t,"text/html"),s=[].concat(...n.body.querySelectorAll("*"));for(const t of s){const i=t.nodeName.toLowerCase();if(!Object.keys(e).includes(i)){t.remove();continue}const n=[].concat(...t.attributes),s=[].concat(e["*"]||[],e[i]||[]);for(const e of n)Gn(e,s)||t.removeAttribute(e.nodeName)}return n.body.innerHTML}(t,this._config.allowList,this._config.sanitizeFn):t}_resolvePossibleFunction(t){return _(t,[void 0,this])}_putElementInTemplate(t,e){if(this._config.html)return e.innerHTML="",void e.append(t);e.textContent=t.textContent}}const is=new Set(["sanitize","allowList","sanitizeFn"]),ns="fade",ss="show",os=".tooltip-inner",rs=".modal",as="hide.bs.modal",ls="hover",cs="focus",hs="click",ds={AUTO:"auto",TOP:"top",RIGHT:m()?"left":"right",BOTTOM:"bottom",LEFT:m()?"right":"left"},us={allowList:Xn,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,6],placement:"top",popperConfig:null,sanitize:!0,sanitizeFn:null,selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',title:"",trigger:"hover focus"},fs={allowList:"object",animation:"boolean",boundary:"(string|element)",container:"(string|element|boolean)",customClass:"(string|function)",delay:"(number|object)",fallbackPlacements:"array",html:"boolean",offset:"(array|string|function)",placement:"(string|function)",popperConfig:"(null|object|function)",sanitize:"boolean",sanitizeFn:"(null|function)",selector:"(string|boolean)",template:"string",title:"(string|element|function)",trigger:"string"};class ps extends B{constructor(t,e){if(void 0===Ai)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org/docs/v2/)");super(t,e),this._isEnabled=!0,this._timeout=0,this._isHovered=null,this._activeTrigger={},this._popper=null,this._templateFactory=null,this._newContent=null,this.tip=null,this._setListeners(),this._config.selector||this._fixTitle()}static get Default(){return us}static get DefaultType(){return fs}static get NAME(){return"tooltip"}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){this._isEnabled&&(this._isShown()?this._leave():this._enter())}dispose(){clearTimeout(this._timeout),P.off(this._element.closest(rs),as,this._hideModalHandler),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this._isWithContent()||!this._isEnabled)return;const t=P.trigger(this._element,this.constructor.eventName("show")),e=(h(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(t.defaultPrevented||!e)return;this._disposePopper();const i=this._getTipElement();this._element.setAttribute("aria-describedby",i.getAttribute("id"));const{container:n}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(n.append(i),P.trigger(this._element,this.constructor.eventName("inserted"))),this._popper=this._createPopper(i),i.classList.add(ss),"ontouchstart"in document.documentElement)for(const t of[].concat(...document.body.children))P.on(t,"mouseover",d);this._queueCallback(()=>{P.trigger(this._element,this.constructor.eventName("shown")),!1===this._isHovered&&this._leave(),this._isHovered=!1},this.tip,this._isAnimated())}hide(){if(this._isShown()&&!P.trigger(this._element,this.constructor.eventName("hide")).defaultPrevented){if(this._getTipElement().classList.remove(ss),"ontouchstart"in document.documentElement)for(const t of[].concat(...document.body.children))P.off(t,"mouseover",d);this._activeTrigger[hs]=!1,this._activeTrigger[cs]=!1,this._activeTrigger[ls]=!1,this._isHovered=null,this._queueCallback(()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),P.trigger(this._element,this.constructor.eventName("hidden")))},this.tip,this._isAnimated())}}update(){this._popper&&this._popper.update()}_isWithContent(){return Boolean(this._getTitle())}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(t){const e=this._getTemplateFactory(t).toHtml();if(!e)return null;e.classList.remove(ns,ss),e.classList.add(`bs-${this.constructor.NAME}-auto`);const i=(t=>{do{t+=Math.floor(1e6*Math.random())}while(document.getElementById(t));return t})(this.constructor.NAME).toString();return e.setAttribute("id",i),this._isAnimated()&&e.classList.add(ns),e}setContent(t){this._newContent=t,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(t){return this._templateFactory?this._templateFactory.changeContent(t):this._templateFactory=new es({...this._config,content:t,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{[os]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(t){return this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(ns)}_isShown(){return this.tip&&this.tip.classList.contains(ss)}_createPopper(t){const e=_(this._config.placement,[this,t,this._element]),i=ds[e.toUpperCase()];return wi(this._element,t,this._getPopperConfig(i))}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map(t=>Number.parseInt(t,10)):"function"==typeof t?e=>t(e,this._element):t}_resolvePossibleFunction(t){return _(t,[this._element,this._element])}_getPopperConfig(t){const e={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:t=>{this._getTipElement().setAttribute("data-popper-placement",t.state.placement)}}]};return{...e,..._(this._config.popperConfig,[void 0,e])}}_setListeners(){const t=this._config.trigger.split(" ");for(const e of t)if("click"===e)P.on(this._element,this.constructor.eventName("click"),this._config.selector,t=>{const e=this._initializeOnDelegatedTarget(t);e._activeTrigger[hs]=!(e._isShown()&&e._activeTrigger[hs]),e.toggle()});else if("manual"!==e){const t=e===ls?this.constructor.eventName("mouseenter"):this.constructor.eventName("focusin"),i=e===ls?this.constructor.eventName("mouseleave"):this.constructor.eventName("focusout");P.on(this._element,t,this._config.selector,t=>{const e=this._initializeOnDelegatedTarget(t);e._activeTrigger["focusin"===t.type?cs:ls]=!0,e._enter()}),P.on(this._element,i,this._config.selector,t=>{const e=this._initializeOnDelegatedTarget(t);e._activeTrigger["focusout"===t.type?cs:ls]=e._element.contains(t.relatedTarget),e._leave()})}this._hideModalHandler=()=>{this._element&&this.hide()},P.on(this._element.closest(rs),as,this._hideModalHandler)}_fixTitle(){const t=this._element.getAttribute("title");t&&(this._element.getAttribute("aria-label")||this._element.textContent.trim()||this._element.setAttribute("aria-label",t),this._element.setAttribute("data-bs-original-title",t),this._element.removeAttribute("title"))}_enter(){this._isShown()||this._isHovered?this._isHovered=!0:(this._isHovered=!0,this._setTimeout(()=>{this._isHovered&&this.show()},this._config.delay.show))}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout(()=>{this._isHovered||this.hide()},this._config.delay.hide))}_setTimeout(t,e){clearTimeout(this._timeout),this._timeout=setTimeout(t,e)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(t){const e=H.getDataAttributes(this._element);for(const t of Object.keys(e))is.has(t)&&delete e[t];return t={...e,..."object"==typeof t&&t?t:{}},t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t.container=!1===t.container?document.body:a(t.container),"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),t}_getDelegateConfig(){const t={};for(const[e,i]of Object.entries(this._config))this.constructor.Default[e]!==i&&(t[e]=i);return t.selector=!1,t.trigger="manual",t}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(t){return this.each(function(){const e=ps.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}})}}g(ps);const ms=".popover-header",gs=".popover-body",_s={...ps.Default,content:"",offset:[0,8],placement:"right",template:'<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>',trigger:"click"},bs={...ps.DefaultType,content:"(null|string|element|function)"};class vs extends ps{static get Default(){return _s}static get DefaultType(){return bs}static get NAME(){return"popover"}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[ms]:this._getTitle(),[gs]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(t){return this.each(function(){const e=vs.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}})}}g(vs);const ys=".bs.scrollspy",ws=`activate${ys}`,As=`click${ys}`,Es=`load${ys}.data-api`,Ts="active",Cs="[href]",Os=".nav-link",xs=`${Os}, .nav-item > ${Os}, .list-group-item`,ks={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},Ls={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class Ss extends B{constructor(t,e){super(t,e),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement="visible"===getComputedStyle(this._element).overflowY?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return ks}static get DefaultType(){return Ls}static get NAME(){return"scrollspy"}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const t of this._observableSections.values())this._observer.observe(t)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(t){return t.target=a(t.target)||document.body,t.rootMargin=t.offset?`${t.offset}px 0px -30%`:t.rootMargin,"string"==typeof t.threshold&&(t.threshold=t.threshold.split(",").map(t=>Number.parseFloat(t))),t}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(P.off(this._config.target,As),P.on(this._config.target,As,Cs,t=>{const e=this._observableSections.get(t.target.hash);if(e){t.preventDefault();const i=this._rootElement||window,n=e.offsetTop-this._element.offsetTop;if(i.scrollTo)return void i.scrollTo({top:n,behavior:"smooth"});i.scrollTop=n}}))}_getNewObserver(){const t={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver(t=>this._observerCallback(t),t)}_observerCallback(t){const e=t=>this._targetLinks.get(`#${t.target.id}`),i=t=>{this._previousScrollData.visibleEntryTop=t.target.offsetTop,this._process(e(t))},n=(this._rootElement||document.documentElement).scrollTop,s=n>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=n;for(const o of t){if(!o.isIntersecting){this._activeTarget=null,this._clearActiveClass(e(o));continue}const t=o.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(s&&t){if(i(o),!n)return}else s||t||i(o)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const t=R.find(Cs,this._config.target);for(const e of t){if(!e.hash||c(e))continue;const t=R.findOne(decodeURI(e.hash),this._element);l(t)&&(this._targetLinks.set(decodeURI(e.hash),e),this._observableSections.set(e.hash,t))}}_process(t){this._activeTarget!==t&&(this._clearActiveClass(this._config.target),this._activeTarget=t,t.classList.add(Ts),this._activateParents(t),P.trigger(this._element,ws,{relatedTarget:t}))}_activateParents(t){if(t.classList.contains("dropdown-item"))R.findOne(".dropdown-toggle",t.closest(".dropdown")).classList.add(Ts);else for(const e of R.parents(t,".nav, .list-group"))for(const t of R.prev(e,xs))t.classList.add(Ts)}_clearActiveClass(t){t.classList.remove(Ts);const e=R.find(`${Cs}.${Ts}`,t);for(const t of e)t.classList.remove(Ts)}static jQueryInterface(t){return this.each(function(){const e=Ss.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t]()}})}}P.on(window,Es,()=>{for(const t of R.find('[data-bs-spy="scroll"]'))Ss.getOrCreateInstance(t)}),g(Ss);const Ds=".bs.tab",$s=`hide${Ds}`,Is=`hidden${Ds}`,Ns=`show${Ds}`,Ps=`shown${Ds}`,js=`click${Ds}`,Ms=`keydown${Ds}`,Fs=`load${Ds}`,Hs="ArrowLeft",Ws="ArrowRight",Bs="ArrowUp",zs="ArrowDown",Rs="Home",qs="End",Vs="active",Ks="fade",Qs="show",Xs=".dropdown-toggle",Ys=`:not(${Xs})`,Us='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',Gs=`.nav-link${Ys}, .list-group-item${Ys}, [role="tab"]${Ys}, ${Us}`,Js=`.${Vs}[data-bs-toggle="tab"], .${Vs}[data-bs-toggle="pill"], .${Vs}[data-bs-toggle="list"]`;class Zs extends B{constructor(t){super(t),this._parent=this._element.closest('.list-group, .nav, [role="tablist"]'),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),P.on(this._element,Ms,t=>this._keydown(t)))}static get NAME(){return"tab"}show(){const t=this._element;if(this._elemIsActive(t))return;const e=this._getActiveElem(),i=e?P.trigger(e,$s,{relatedTarget:t}):null;P.trigger(t,Ns,{relatedTarget:e}).defaultPrevented||i&&i.defaultPrevented||(this._deactivate(e,t),this._activate(t,e))}_activate(t,e){t&&(t.classList.add(Vs),this._activate(R.getElementFromSelector(t)),this._queueCallback(()=>{"tab"===t.getAttribute("role")?(t.removeAttribute("tabindex"),t.setAttribute("aria-selected",!0),this._toggleDropDown(t,!0),P.trigger(t,Ps,{relatedTarget:e})):t.classList.add(Qs)},t,t.classList.contains(Ks)))}_deactivate(t,e){t&&(t.classList.remove(Vs),t.blur(),this._deactivate(R.getElementFromSelector(t)),this._queueCallback(()=>{"tab"===t.getAttribute("role")?(t.setAttribute("aria-selected",!1),t.setAttribute("tabindex","-1"),this._toggleDropDown(t,!1),P.trigger(t,Is,{relatedTarget:e})):t.classList.remove(Qs)},t,t.classList.contains(Ks)))}_keydown(t){if(![Hs,Ws,Bs,zs,Rs,qs].includes(t.key))return;t.stopPropagation(),t.preventDefault();const e=this._getChildren().filter(t=>!c(t));let i;if([Rs,qs].includes(t.key))i=e[t.key===Rs?0:e.length-1];else{const n=[Ws,zs].includes(t.key);i=v(e,t.target,n,!0)}i&&(i.focus({preventScroll:!0}),Zs.getOrCreateInstance(i).show())}_getChildren(){return R.find(Gs,this._parent)}_getActiveElem(){return this._getChildren().find(t=>this._elemIsActive(t))||null}_setInitialAttributes(t,e){this._setAttributeIfNotExists(t,"role","tablist");for(const t of e)this._setInitialAttributesOnChild(t)}_setInitialAttributesOnChild(t){t=this._getInnerElement(t);const e=this._elemIsActive(t),i=this._getOuterElement(t);t.setAttribute("aria-selected",e),i!==t&&this._setAttributeIfNotExists(i,"role","presentation"),e||t.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(t,"role","tab"),this._setInitialAttributesOnTargetPanel(t)}_setInitialAttributesOnTargetPanel(t){const e=R.getElementFromSelector(t);e&&(this._setAttributeIfNotExists(e,"role","tabpanel"),t.id&&this._setAttributeIfNotExists(e,"aria-labelledby",`${t.id}`))}_toggleDropDown(t,e){const i=this._getOuterElement(t);if(!i.classList.contains("dropdown"))return;const n=(t,n)=>{const s=R.findOne(t,i);s&&s.classList.toggle(n,e)};n(Xs,Vs),n(".dropdown-menu",Qs),i.setAttribute("aria-expanded",e)}_setAttributeIfNotExists(t,e,i){t.hasAttribute(e)||t.setAttribute(e,i)}_elemIsActive(t){return t.classList.contains(Vs)}_getInnerElement(t){return t.matches(Gs)?t:R.findOne(Gs,t)}_getOuterElement(t){return t.closest(".nav-item, .list-group-item")||t}static jQueryInterface(t){return this.each(function(){const e=Zs.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t]()}})}}P.on(document,js,Us,function(t){["A","AREA"].includes(this.tagName)&&t.preventDefault(),c(this)||Zs.getOrCreateInstance(this).show()}),P.on(window,Fs,()=>{for(const t of R.find(Js))Zs.getOrCreateInstance(t)}),g(Zs);const to=".bs.toast",eo=`mouseover${to}`,io=`mouseout${to}`,no=`focusin${to}`,so=`focusout${to}`,oo=`hide${to}`,ro=`hidden${to}`,ao=`show${to}`,lo=`shown${to}`,co="hide",ho="show",uo="showing",fo={animation:"boolean",autohide:"boolean",delay:"number"},po={animation:!0,autohide:!0,delay:5e3};class mo extends B{constructor(t,e){super(t,e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return po}static get DefaultType(){return fo}static get NAME(){return"toast"}show(){P.trigger(this._element,ao).defaultPrevented||(this._clearTimeout(),this._config.animation&&this._element.classList.add("fade"),this._element.classList.remove(co),u(this._element),this._element.classList.add(ho,uo),this._queueCallback(()=>{this._element.classList.remove(uo),P.trigger(this._element,lo),this._maybeScheduleHide()},this._element,this._config.animation))}hide(){this.isShown()&&(P.trigger(this._element,oo).defaultPrevented||(this._element.classList.add(uo),this._queueCallback(()=>{this._element.classList.add(co),this._element.classList.remove(uo,ho),P.trigger(this._element,ro)},this._element,this._config.animation)))}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(ho),super.dispose()}isShown(){return this._element.classList.contains(ho)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout(()=>{this.hide()},this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":this._hasMouseInteraction=e;break;case"focusin":case"focusout":this._hasKeyboardInteraction=e}if(e)return void this._clearTimeout();const i=t.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){P.on(this._element,eo,t=>this._onInteraction(t,!0)),P.on(this._element,io,t=>this._onInteraction(t,!1)),P.on(this._element,no,t=>this._onInteraction(t,!0)),P.on(this._element,so,t=>this._onInteraction(t,!1))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each(function(){const e=mo.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t](this)}})}}return q(mo),g(mo),{Alert:X,Button:U,Carousel:St,Collapse:qt,Dropdown:Qi,Modal:Ln,Offcanvas:Qn,Popover:vs,ScrollSpy:Ss,Tab:Zs,Toast:mo,Tooltip:ps}});
//# sourceMappingURL=bootstrap.bundle.min.js.map
\ No newline at end of file
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/build/011-api.js b/mailcow/src/mailcow-dockerized/data/web/js/build/011-api.js
index c657c13..1fe595c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/build/011-api.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/build/011-api.js
@@ -158,9 +158,11 @@
var attr_to_merge = $(this).closest("form").serializeObject();
// parse possible JSON Strings
for (var [key, value] of Object.entries(attr_to_merge)) {
- try {
- attr_to_merge[key] = JSON.parse(attr_to_merge[key]);
- } catch {}
+ if (typeof value === "string" && /^[\[\{"].*[\}\]"]$/.test(value.trim())) {
+ try {
+ attr_to_merge[key] = JSON.parse(attr_to_merge[key]);
+ } catch {}
+ }
}
var api_attr = $.extend(api_attr, attr_to_merge)
} else {
@@ -271,9 +273,11 @@
var attr_to_merge = $(this).closest("form").serializeObject();
// parse possible JSON Strings
for (var [key, value] of Object.entries(attr_to_merge)) {
- try {
- attr_to_merge[key] = JSON.parse(attr_to_merge[key]);
- } catch {}
+ if (typeof value === "string" && /^[\[\{"].*[\}\]"]$/.test(value.trim())) {
+ try {
+ attr_to_merge[key] = JSON.parse(attr_to_merge[key]);
+ } catch {}
+ }
}
var api_attr = $.extend(api_attr, attr_to_merge)
} else {
@@ -312,7 +316,7 @@
var key = localStorage.key(i);
if(/formcache/.test(key)) {
localStorage.removeItem(key);
- }
+ }
}
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/build/013-mailcow.js b/mailcow/src/mailcow-dockerized/data/web/js/build/013-mailcow.js
index f3ecbb9..9586af3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/build/013-mailcow.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/build/013-mailcow.js
@@ -22,8 +22,8 @@
$.notify({message: msg},{z_index: 20000, delay: auto_hide, type: type,placement: {from: "bottom",align: "right"},animate: {enter: 'animated fadeInUp',exit: 'animated fadeOutDown'}});
}
- $(".generate_password").click(async function( event ) {
- try {
+ $(".generate_password").click(async function( event ) {
+ try {
var password_policy = await window.fetch("/api/v1/get/passwordpolicy", { method:'GET', cache:'no-cache' });
var password_policy = await password_policy.json();
random_passwd_length = password_policy.length;
@@ -48,7 +48,11 @@
})
}
$(".rot-enc").html(function(){
- return str_rot13($(this).html())
+ footer_html = $(this).html();
+ footer_html = footer_html.replace(/</g, '<').replace(/>/g, '>')
+ .replace(/&/g, '&').replace(/&nzc;/g, '&')
+ .replace(/"/g, '"').replace(/'/g, "'");
+ return str_rot13(footer_html)
});
// https://stackoverflow.com/questions/4399005/implementing-jquerys-shake-effect-with-animate
function shake(div,interval,distance,times) {
@@ -120,12 +124,15 @@
var lastTab = localStorage.getItem(key);
if (lastTab) {
$('[data-bs-target="#' + lastTab + '"]').click();
+ var dropdown = $('[data-bs-target="#' + lastTab + '"]').closest('.dropdown');
+ dropdown.find('.dropdown-menu').removeClass('show');
+ dropdown.find('.dropdown-toggle').attr('aria-expanded', 'false');
var tab = $('[id^="' + lastTab + '"]');
$(tab).find('.card-body.collapse:first').collapse('show');
}
});
})();
-
+
// responsive tabs, scroll to opened tab
$(document).on("shown.bs.collapse shown.bs.tab", function (e) {
var target = $(e.target);
@@ -341,17 +348,28 @@
$('.main-logo-dark').addClass('d-none');
if ($('#rspamd_logo').length) $('#rspamd_logo').attr('src', '/img/rspamd_logo_dark.png');
if ($('#rspamd_logo_sm').length) $('#rspamd_logo_sm').attr('src', '/img/rspamd_logo_dark.png');
- localStorage.setItem('theme', 'light');
+ localStorage.setItem('mailcow_theme', 'light');
}else{
- $('head').append('<link id="dark-mode-theme" rel="stylesheet" type="text/css" href="/css/themes/mailcow-darkmode.css">');
+ $('head').append('<link id="dark-mode-theme" rel="stylesheet" type="text/css" href="' + mailcow_dark_css + '">');
$('#dark-mode-toggle').prop('checked', true);
$('.main-logo').addClass('d-none');
$('.main-logo-dark').removeClass('d-none');
if ($('#rspamd_logo').length) $('#rspamd_logo').attr('src', '/img/rspamd_logo_light.png');
if ($('#rspamd_logo_sm').length) $('#rspamd_logo_sm').attr('src', '/img/rspamd_logo_light.png');
- localStorage.setItem('theme', 'dark');
+ localStorage.setItem('mailcow_theme', 'dark');
}
}
+
+ // Reveal Password Input
+ $(".reveal-password-input").on('click', '.toggle-password', function() {
+ $(this).parent().find('.toggle-password').children().toggleClass("bi-eye bi-eye-slash");
+ var input = $(this).parent().find('.password-field')
+ if (input.attr("type") === "password") {
+ input.attr("type", "text");
+ } else {
+ input.attr("type", "password");
+ }
+ });
});
@@ -398,4 +416,4 @@
// only works with https connections
navigator.clipboard.writeText(copyText.value);
mailcow_alert_box(lang.copy_to_clipboard, "success");
-}
\ No newline at end of file
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/admin.js b/mailcow/src/mailcow-dockerized/data/web/js/site/admin.js
index 80da641..91bb0e4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/admin.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/admin.js
@@ -51,10 +51,19 @@
$('.submit_rspamd_regex').attr({"disabled": true});
});
$("#show_rspamd_global_filters").click(function() {
- $.get("inc/ajax/show_rspamd_global_filters.php");
+ $.get("/inc/ajax/show_rspamd_global_filters.php");
$("#confirm_show_rspamd_global_filters").hide();
$("#rspamd_global_filters").removeClass("d-none");
+ localStorage.setItem('rspamd_global_filters_confirmed', 'true');
});
+
+ $(document).ready(function() {
+ if (localStorage.getItem('rspamd_global_filters_confirmed') === 'true') {
+ $("#confirm_show_rspamd_global_filters").hide();
+ $("#rspamd_global_filters").removeClass("d-none");
+ }
+ });
+
$("#super_delete").click(function() { return confirm(lang.queue_ays); });
$(".refresh_table").on('click', function(e) {
@@ -397,7 +406,10 @@
{
title: lang.host,
data: 'hostname',
- defaultContent: ''
+ defaultContent: '',
+ render: function (data, type) {
+ return escapeHtml(data);
+ }
},
{
title: lang.username,
@@ -555,7 +567,7 @@
} else if (table == 'oauth2clientstable') {
$.each(data, function (i, item) {
item.action = '<div class="btn-group">' +
- '<a href="/edit.php?oauth2client=' + encodeURI(item.id) + '" class="btn btn-xs btn-xs-lg btn-xs-half btn-secondary"><i class="bi bi-pencil-fill"></i> ' + lang.edit + '</a>' +
+ '<a href="/edit/oauth2client/' + encodeURI(item.id) + '" class="btn btn-xs btn-xs-lg btn-xs-half btn-secondary"><i class="bi bi-pencil-fill"></i> ' + lang.edit + '</a>' +
'<a href="#" data-action="delete_selected" data-id="single-oauth2-client" data-api-url="delete/oauth2-client" data-item="' + encodeURI(item.id) + '" class="btn btn-xs btn-xs-lg btn-xs-half btn-danger"><i class="bi bi-trash"></i> ' + lang.remove + '</a>' +
'</div>';
item.scope = "profile";
@@ -570,7 +582,7 @@
item.action = '<div class="btn-group">' +
'<a href="/edit/domainadmin/' + encodeURI(item.username) + '" class="btn btn-xs btn-xs-lg btn-xs-third btn-secondary"><i class="bi bi-pencil-fill"></i> ' + lang.edit + '</a>' +
'<a href="#" data-action="delete_selected" data-id="single-domain-admin" data-api-url="delete/domain-admin" data-item="' + encodeURI(item.username) + '" class="btn btn-xs btn-xs-lg btn-xs-third btn-danger"><i class="bi bi-trash"></i> ' + lang.remove + '</a>' +
- '<a href="/index.php?duallogin=' + encodeURIComponent(item.username) + '" class="btn btn-xs btn-xs-lg btn-xs-third btn-success"><i class="bi bi-person-fill"></i> Login</a>' +
+ '<a href="/domainadmin/?duallogin=' + encodeURIComponent(item.username) + '" class="btn btn-xs btn-xs-lg btn-xs-third btn-success"><i class="bi bi-person-fill"></i> Login</a>' +
'</div>';
});
} else if (table == 'adminstable') {
@@ -652,7 +664,7 @@
$(this).html('<i class="bi bi-arrow-repeat icon-spin"></i> ');
$.ajax({
type: 'GET',
- url: 'inc/ajax/relay_check.php',
+ url: '/inc/ajax/relay_check.php',
dataType: 'text',
data: $('#test_relayhost_form').serialize(),
complete: function (data) {
@@ -678,7 +690,7 @@
$(this).html('<div class="spinner-border" role="status"><span class="visually-hidden">Loading...</span></div> ');
$.ajax({
type: 'GET',
- url: 'inc/ajax/transport_check.php',
+ url: '/inc/ajax/transport_check.php',
dataType: 'text',
data: $('#test_transport_form').serialize(),
complete: function (data) {
@@ -706,19 +718,33 @@
}
})
// App links
+ // setup eventlistener
+ setAppHideEvent();
+ function setAppHideEvent(){
+ $('.app_hide').off('change');
+ $('.app_hide').on('change', function (e) {
+ var value = $(this).is(':checked') ? '1' : '0';
+ $(this).parent().children(':first-child').val(value);
+ })
+ }
function add_table_row(table_id, type) {
var row = $('<tr />');
if (type == "app_link") {
cols = '<td><input class="input-sm input-xs-lg form-control" data-id="app_links" type="text" name="app" required></td>';
cols += '<td><input class="input-sm input-xs-lg form-control" data-id="app_links" type="text" name="href" required></td>';
+ cols += '<td><input class="input-sm input-xs-lg form-control" data-id="app_links" type="text" name="user_href" required></td>';
+ cols += '<td><div class="d-flex align-items-center justify-content-center" style="height: 33.5px"><input data-id="app_links" type="hidden" name="hide" value="0"><input class="form-check-input app_hide" type="checkbox" value="1"></div></td>';
cols += '<td><a href="#" role="button" class="btn btn-sm btn-xs-lg btn-secondary h-100 w-100" type="button">' + lang.remove_row + '</a></td>';
} else if (type == "f2b_regex") {
cols = '<td><input style="text-align:center" class="input-sm input-xs-lg form-control" data-id="f2b_regex" type="text" value="+" disabled></td>';
cols += '<td><input class="input-sm input-xs-lg form-control regex-input" data-id="f2b_regex" type="text" name="regex" required></td>';
cols += '<td><a href="#" role="button" class="btn btn-sm btn-xs-lg btn-secondary h-100 w-100" type="button">' + lang.remove_row + '</a></td>';
}
+
row.append(cols);
table_id.append(row);
+ if (type == "app_link")
+ setAppHideEvent();
}
$('#app_link_table').on('click', 'tr a', function (e) {
e.preventDefault();
@@ -734,4 +760,115 @@
$('#add_f2b_regex_row').click(function() {
add_table_row($('#f2b_regex_table'), "f2b_regex");
});
+ // IAM test connection
+ $('.iam_test_connection').click(async function(e){
+ e.preventDefault();
+ var data = { attr: $('form[data-id="' + $(this).data('id') + '"]').serializeObject() };
+ var res = await fetch("/api/v1/edit/identity-provider-test", {
+ headers: {
+ "Content-Type": "application/json",
+ },
+ method:'POST',
+ cache:'no-cache',
+ body: JSON.stringify(data)
+ });
+ res = await res.json();
+ if (res.type === 'success'){
+ return mailcow_alert_box(lang_success.iam_test_connection, 'success');
+ }
+ return mailcow_alert_box(lang_danger.iam_test_connection, 'danger');
+ });
+
+ $('.iam_rolemap_add_keycloak').click(async function(e){
+ addAttributeMappingRow('#iam_keycloak_mapping_list', '.iam_keycloak_rolemap_del', e);
+ });
+ $('.iam_rolemap_add_generic').click(async function(e){
+ addAttributeMappingRow('#iam_generic_mapping_list', '.iam_generic_rolemap_del', e);
+ });
+ $('.iam_rolemap_add_ldap').click(async function(e){
+ addAttributeMappingRow('#iam_ldap_mapping_list', '.iam_ldap_rolemap_del', e);
+ });
+ $('.iam_keycloak_rolemap_del').click(async function(e){
+ deleteAttributeMappingRow(this, e);
+ });
+ $('.iam_generic_rolemap_del').click(async function(e){
+ deleteAttributeMappingRow(this, e);
+ });
+ $('.iam_ldap_rolemap_del').click(async function(e){
+ deleteAttributeMappingRow(this, e);
+ });
+ $('.iam_redirect_add_keycloak').click(async function(e){
+ addRedirectUrlRow('#iam_keycloak_redirect_list', '.iam_keycloak_redirect_del', e);
+ });
+ $('.iam_redirect_add_generic').click(async function(e){
+ addRedirectUrlRow('#iam_generic_redirect_list', '.iam_generic_redirect_del', e);
+ });
+ $('.iam_keycloak_redirect_del').click(async function(e){
+ deleteRedirectUrlRow(this, e);
+ });
+ $('.iam_generic_redirect_del').click(async function(e){
+ deleteRedirectUrlRow(this, e);
+ });
+ // selecting identity provider
+ $('#iam_provider').on('change', function(){
+ // toggle password fields
+ if (this.value === 'keycloak'){
+ $('#keycloak_settings').removeClass('d-none');
+ $('#generic_oidc_settings').addClass('d-none');
+ $('#ldap_settings').addClass('d-none');
+ } else if (this.value === 'generic-oidc') {
+ $('#generic_oidc_settings').removeClass('d-none');
+ $('#keycloak_settings').addClass('d-none');
+ $('#ldap_settings').addClass('d-none');
+ } else if (this.value === 'ldap') {
+ $('#ldap_settings').removeClass('d-none');
+ $('#generic_oidc_settings').addClass('d-none');
+ $('#keycloak_settings').addClass('d-none');
+ }
+ });
+ function addAttributeMappingRow(list_id, del_class, e) {
+ e.preventDefault();
+
+ var parent = $(list_id)
+ $(parent).children().last().clone().appendTo(parent);
+ var newChild = $(parent).children().last();
+ $(newChild).find('input').val('');
+ $(newChild).find('input').val('').prop('required', true);
+ $(newChild).find('.dropdown-toggle').remove();
+ $(newChild).find('.dropdown-menu').remove();
+ $(newChild).find('.bs-title-option').remove();
+ $(newChild).find('select').selectpicker('destroy');
+ $(newChild).find('select').selectpicker();
+ $(newChild).find('select').selectpicker().prop('required', true);
+
+ $(del_class).off('click');
+ $(del_class).click(async function(e){
+ deleteAttributeMappingRow(this, e);
+ });
+ }
+ function deleteAttributeMappingRow(elem, e) {
+ e.preventDefault();
+ if(!$(elem).parent().parent().parent().find('select').prop('required'))
+ return true;
+ if ($(elem).parent().parent().parent().parent().children().length > 1)
+ $(elem).parent().parent().parent().remove();
+ }
+ function addRedirectUrlRow(list_id, del_class, e) {
+ e.preventDefault();
+
+ var parent = $(list_id)
+ $(parent).children().last().clone().appendTo(parent);
+ var newChild = $(parent).children().last();
+ $(newChild).find('input').val('');
+
+ $(del_class).off('click');
+ $(del_class).click(async function(e){
+ deleteRedirectUrlRow(this, e);
+ });
+ }
+ function deleteRedirectUrlRow(elem, e) {
+ e.preventDefault();
+ if ($(elem).parent().parent().parent().parent().children().length > 2)
+ $(elem).parent().parent().parent().remove();
+ }
});
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/dashboard.js b/mailcow/src/mailcow-dockerized/data/web/js/site/dashboard.js
new file mode 100644
index 0000000..7c077e2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/dashboard.js
@@ -0,0 +1,1764 @@
+$(document).ready(function() {
+ // Parse seconds ago to date
+ // Get "now" timestamp
+ var ts_now = Math.round((new Date()).getTime() / 1000);
+ $('.parse_s_ago').each(function(i, parse_s_ago) {
+ var started_s_ago = parseInt($(this).text(), 10);
+ if (typeof started_s_ago != 'NaN') {
+ var started_date = new Date((ts_now - started_s_ago) * 1000);
+ if (started_date instanceof Date && !isNaN(started_date)) {
+ var started_local_date = started_date.toLocaleDateString(LOCALE, DATETIME_FORMAT);
+ $(this).text(started_local_date);
+ } else {
+ $(this).text('-');
+ }
+ }
+ });
+ // Parse general dates
+ $('.parse_date').each(function(i, parse_date) {
+ var started_date = new Date(Date.parse($(this).text()));
+ if (typeof started_date != 'NaN') {
+ var started_local_date = started_date.toLocaleDateString(LOCALE, DATETIME_FORMAT);
+ $(this).text(started_local_date);
+ }
+ });
+
+ // set update loop container list
+ containersToUpdate = {};
+ // set default ChartJs Font Color
+ Chart.defaults.color = '#999';
+ // create host cpu and mem charts
+ createHostCpuAndMemChart();
+ // check for new version
+ if (mailcow_info.branch === "master" && mailcow_cc_role === "admin"){
+ check_update(mailcow_info.version_tag, mailcow_info.project_url);
+ }
+ $("#mailcow_version").click(function(){
+ if (mailcow_cc_role !== "admin" && mailcow_cc_role !== "domainadmin" || mailcow_info.branch !== "master")
+ return;
+
+ showVersionModal("Version " + mailcow_info.version_tag, mailcow_info.version_tag);
+ })
+ // get public ips
+ $("#host_show_ip").click(function(){
+ $("#host_show_ip").find(".text").addClass("d-none");
+ $("#host_show_ip").find(".spinner-border").removeClass("d-none");
+
+ window.fetch("/api/v1/get/status/host/ip", { method:'GET', cache:'no-cache' }).then(function(response) {
+ return response.json();
+ }).then(function(data) {
+ // display host ips
+ if (data.ipv4)
+ $("#host_ipv4").text(data.ipv4);
+ if (data.ipv6)
+ $("#host_ipv6").text(data.ipv6);
+
+ $("#host_show_ip").addClass("d-none");
+ $("#host_show_ip").find(".text").removeClass("d-none");
+ $("#host_show_ip").find(".spinner-border").addClass("d-none");
+ $("#host_ipv4").removeClass("d-none");
+ $("#host_ipv6").removeClass("d-none");
+ $("#host_ipv6").removeClass("text-danger");
+ $("#host_ipv4").addClass("d-block");
+ $("#host_ipv6").addClass("d-block");
+ }).catch(function(error){
+ console.log(error);
+
+ $("#host_ipv6").removeClass("d-none");
+ $("#host_ipv6").addClass("d-block");
+ $("#host_ipv6").addClass("text-danger");
+ $("#host_ipv6").text(lang_debug.error_show_ip);
+ $("#host_show_ip").find(".text").removeClass("d-none");
+ $("#host_show_ip").find(".spinner-border").addClass("d-none");
+ });
+ });
+ update_container_stats();
+});
+jQuery(function($){
+ if (localStorage.getItem("current_page") === null) {
+ var current_page = {};
+ } else {
+ var current_page = JSON.parse(localStorage.getItem('current_page'));
+ }
+ // http://stackoverflow.com/questions/24816/escaping-html-strings-with-jquery
+ var entityMap={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="};
+ function escapeHtml(n){return String(n).replace(/[&<>"'`=\/]/g,function(n){return entityMap[n]})}
+ function humanFileSize(i){if(Math.abs(i)<1024)return i+" B";var B=["KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],e=-1;do{i/=1024,++e}while(Math.abs(i)>=1024&&e<B.length-1);return i.toFixed(1)+" "+B[e]}
+ function hashCode(t){for(var n=0,r=0;r<t.length;r++)n=t.charCodeAt(r)+((n<<5)-n);return n}
+ function intToRGB(t){var n=(16777215&t).toString(16).toUpperCase();return"00000".substring(0,6-n.length)+n}
+ $(".refresh_table").on('click', function(e) {
+ e.preventDefault();
+ var table_name = $(this).data('table');
+ $('#' + table_name).DataTable().ajax.reload();
+ });
+ function createSortableDate(td, cellData) {
+ $(td).attr({
+ "data-order": cellData,
+ "data-sort": cellData
+ });
+ $(td).html(convertTimestampToLocalFormat(cellData));
+ }
+ function draw_autodiscover_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#autodiscover_log') ) {
+ $('#autodiscover_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#autodiscover_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-autodiscover-logs', '#autodiscover_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/autodiscover/100",
+ dataSrc: function(data){
+ return process_table_data(data, 'autodiscover_log');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ responsivePriority: 1,
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: 'User-Agent',
+ data: 'ua',
+ defaultContent: '',
+ className: 'dtr-col-md',
+ responsivePriority: 5
+ },
+ {
+ title: 'Username',
+ data: 'user',
+ defaultContent: '',
+ responsivePriority: 4
+ },
+ {
+ title: 'IP',
+ data: 'ip',
+ defaultContent: '',
+ responsivePriority: 2
+ },
+ {
+ title: 'Service',
+ data: 'service',
+ defaultContent: '',
+ responsivePriority: 3
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-autodiscover-logs', '#autodiscover_log');
+ });
+ }
+ function draw_postfix_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#postfix_log') ) {
+ $('#postfix_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#postfix_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-postfix-logs', '#postfix_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/postfix",
+ dataSrc: function(data){
+ return process_table_data(data, 'general_syslog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: lang.priority,
+ data: 'priority',
+ defaultContent: ''
+ },
+ {
+ title: lang.message,
+ data: 'message',
+ defaultContent: '',
+ className: 'dtr-col-md text-break'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-postfix-logs', '#postfix_log');
+ });
+ }
+ function draw_watchdog_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#watchdog_log') ) {
+ $('#watchdog_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#watchdog_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-watchdog-logs', '#watchdog_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/watchdog",
+ dataSrc: function(data){
+ return process_table_data(data, 'watchdog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: 'Service',
+ data: 'service',
+ defaultContent: ''
+ },
+ {
+ title: 'Trend',
+ data: 'trend',
+ defaultContent: ''
+ },
+ {
+ title: lang.message,
+ data: 'message',
+ defaultContent: ''
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-watchdog-logs', '#watchdog_log');
+ });
+ }
+ function draw_api_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#api_log') ) {
+ $('#api_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#api_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-api-logs', '#api_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/api",
+ dataSrc: function(data){
+ return process_table_data(data, 'apilog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: 'URI',
+ data: 'uri',
+ defaultContent: '',
+ className: 'dtr-col-md dtr-break-all',
+ render: function (data, type) {
+ return escapeHtml(data);
+ }
+ },
+ {
+ title: 'Method',
+ data: 'method',
+ defaultContent: ''
+ },
+ {
+ title: 'IP',
+ data: 'remote',
+ defaultContent: ''
+ },
+ {
+ title: 'Data',
+ data: 'data',
+ defaultContent: '',
+ className: 'dtr-col-md dtr-break-all'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-api-logs', '#api_log');
+ });
+ }
+ function draw_rl_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#rl_log') ) {
+ $('#rl_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#rl_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-rl-logs', '#rl_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/ratelimited",
+ dataSrc: function(data){
+ return process_table_data(data, 'rllog');
+ }
+ },
+ columns: [
+ {
+ title: ' ',
+ data: 'indicator',
+ defaultContent: ''
+ },
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: lang.rate_name,
+ data: 'rl_name',
+ defaultContent: ''
+ },
+ {
+ title: lang.sender,
+ data: 'from',
+ defaultContent: ''
+ },
+ {
+ title: lang.recipients,
+ data: 'rcpt',
+ defaultContent: ''
+ },
+ {
+ title: lang.authed_user,
+ data: 'user',
+ defaultContent: ''
+ },
+ {
+ title: 'Msg ID',
+ data: 'message_id',
+ defaultContent: ''
+ },
+ {
+ title: 'Header From',
+ data: 'header_from',
+ defaultContent: ''
+ },
+ {
+ title: 'Subject',
+ data: 'header_subject',
+ defaultContent: ''
+ },
+ {
+ title: 'Hash',
+ data: 'rl_hash',
+ defaultContent: ''
+ },
+ {
+ title: 'Rspamd QID',
+ data: 'qid',
+ defaultContent: ''
+ },
+ {
+ title: 'IP',
+ data: 'ip',
+ defaultContent: ''
+ },
+ {
+ title: lang.action,
+ data: 'action',
+ defaultContent: ''
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-rl-logs', '#rl_log');
+ });
+ }
+ function draw_ui_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#ui_logs') ) {
+ $('#ui_logs').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#ui_logs').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-ui-logs', '#ui_logs');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/ui",
+ dataSrc: function(data){
+ return process_table_data(data, 'mailcow_ui');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: 'Type',
+ data: 'type',
+ defaultContent: ''
+ },
+ {
+ title: 'Task',
+ data: 'task',
+ defaultContent: ''
+ },
+ {
+ title: 'User',
+ data: 'user',
+ defaultContent: '',
+ className: 'dtr-col-sm'
+ },
+ {
+ title: 'Role',
+ data: 'role',
+ defaultContent: '',
+ className: 'dtr-col-sm'
+ },
+ {
+ title: 'IP',
+ data: 'remote',
+ defaultContent: '',
+ className: 'dtr-col-md dtr-break-all'
+ },
+ {
+ title: lang.message,
+ data: 'msg',
+ defaultContent: '',
+ className: 'dtr-col-md dtr-break-all'
+ },
+ {
+ title: 'Call',
+ data: 'call',
+ defaultContent: '',
+ className: 'none dtr-col-md dtr-break-all'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-ui-logs', '#ui_log');
+ });
+ }
+ function draw_sasl_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#sasl_logs') ) {
+ $('#sasl_logs').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#sasl_logs').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-sasl-logs', '#sasl_logs');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/sasl",
+ dataSrc: function(data){
+ return process_table_data(data, 'sasl_log_table');
+ }
+ },
+ columns: [
+ {
+ title: lang.username,
+ data: 'username',
+ defaultContent: ''
+ },
+ {
+ title: lang.service,
+ data: 'service',
+ defaultContent: ''
+ },
+ {
+ title: 'IP',
+ data: 'real_rip',
+ defaultContent: '',
+ className: 'dtr-col-md text-break'
+ },
+ {
+ title: lang.login_time,
+ data: 'datetime',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ cellData = Math.floor((new Date(cellData.replace(/-/g, "/"))).getTime() / 1000);
+ createSortableDate(td, cellData)
+ }
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-sasl-logs', '#sasl_logs');
+ });
+ }
+ function draw_acme_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#acme_log') ) {
+ $('#acme_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#acme_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-acme-logs', '#acme_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/acme",
+ dataSrc: function(data){
+ return process_table_data(data, 'general_syslog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: lang.message,
+ data: 'message',
+ defaultContent: '',
+ className: 'dtr-col-md dtr-break-all'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-acme-logs', '#acme_log');
+ });
+ }
+ function draw_netfilter_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#netfilter_log') ) {
+ $('#netfilter_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#netfilter_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-netfilter-logs', '#netfilter_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/netfilter",
+ dataSrc: function(data){
+ return process_table_data(data, 'general_syslog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: lang.priority,
+ data: 'priority',
+ defaultContent: ''
+ },
+ {
+ title: lang.message,
+ data: 'message',
+ defaultContent: '',
+ className: 'dtr-col-md text-break'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-netfilter-logs', '#netfilter_log');
+ });
+ }
+ function draw_sogo_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#sogo_log') ) {
+ $('#sogo_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#sogo_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-sogo-logs', '#sogo_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/sogo",
+ dataSrc: function(data){
+ return process_table_data(data, 'general_syslog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: lang.priority,
+ data: 'priority',
+ defaultContent: ''
+ },
+ {
+ title: lang.message,
+ data: 'message',
+ defaultContent: '',
+ className: 'dtr-col-md text-break'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-sogo-logs', '#sogo_log');
+ });
+ }
+ function draw_dovecot_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#dovecot_log') ) {
+ $('#dovecot_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#dovecot_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-dovecot-logs', '#dovecot_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/dovecot",
+ dataSrc: function(data){
+ return process_table_data(data, 'general_syslog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: lang.priority,
+ data: 'priority',
+ defaultContent: ''
+ },
+ {
+ title: lang.message,
+ data: 'message',
+ defaultContent: '',
+ className: 'dtr-col-md text-break'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-dovecot-logs', '#dovecot_log');
+ });
+ }
+ function draw_cron_logs() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#cron_log') ) {
+ $('#cron_log').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#cron_log').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-cron-logs', '#cron_log');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/cron",
+ dataSrc: function(data){
+ return process_table_data(data, 'general_syslog');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: lang.task,
+ data: 'task',
+ defaultContent: ''
+ },
+ {
+ title: lang.priority,
+ data: 'priority',
+ defaultContent: ''
+ },
+ {
+ title: lang.message,
+ data: 'message',
+ defaultContent: '',
+ className: 'dtr-col-md text-break'
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-cron-logs', '#cron_log');
+ });
+ }
+ function rspamd_pie_graph() {
+ $.ajax({
+ url: '/api/v1/get/rspamd/actions',
+ async: true,
+ success: function(data){
+ var total = 0;
+ $(data).map(function(){total += this[1];});
+ var labels = $.makeArray($(data).map(function(){return this[0] + ' ' + Math.round(this[1]/total * 100) + '%';}));
+ var values = $.makeArray($(data).map(function(){return this[1];}));
+
+ var graphdata = {
+ labels: labels,
+ datasets: [{
+ data: values,
+ backgroundColor: ['#DC3023', '#59ABE3', '#FFA400', '#FFA400', '#26A65B']
+ }]
+ };
+
+ var options = {
+ responsive: true,
+ maintainAspectRatio: false,
+ plugins: {
+ datalabels: {
+ color: '#FFF',
+ font: {
+ weight: 'bold'
+ },
+ display: function(context) {
+ return context.dataset.data[context.dataIndex] !== 0;
+ },
+ formatter: function(value, context) {
+ return Math.round(value/total*100) + '%';
+ }
+ }
+ }
+ };
+ var chartcanvas = document.getElementById('rspamd_donut');
+ Chart.register('ChartDataLabels');
+ if(typeof chart == 'undefined') {
+ chart = new Chart(chartcanvas.getContext("2d"), {
+ plugins: [ChartDataLabels],
+ type: 'doughnut',
+ data: graphdata,
+ options: options
+ });
+ }
+ else {
+ chart.destroy();
+ chart = new Chart(chartcanvas.getContext("2d"), {
+ plugins: [ChartDataLabels],
+ type: 'doughnut',
+ data: graphdata,
+ options: options
+ });
+ }
+ }
+ });
+ }
+ function draw_rspamd_history() {
+ // just recalc width if instance already exists
+ if ($.fn.DataTable.isDataTable('#rspamd_history') ) {
+ $('#rspamd_history').DataTable().columns.adjust().responsive.recalc();
+ return;
+ }
+
+ var table = $('#rspamd_history').DataTable({
+ responsive: true,
+ processing: true,
+ serverSide: false,
+ stateSave: true,
+ pageLength: log_pagination_size,
+ dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
+ "tr" +
+ "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
+ language: lang_datatables,
+ order: [[0, 'desc']],
+ initComplete: function(){
+ hideTableExpandCollapseBtn('#tab-rspamd-logs', '#rspamd_history');
+ },
+ ajax: {
+ type: "GET",
+ url: "/api/v1/get/logs/rspamd-history",
+ dataSrc: function(data){
+ return process_table_data(data, 'rspamd_history');
+ }
+ },
+ columns: [
+ {
+ title: lang.time,
+ data: 'unix_time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ createSortableDate(td, cellData)
+ }
+ },
+ {
+ title: 'IP address',
+ data: 'ip',
+ defaultContent: ''
+ },
+ {
+ title: 'From',
+ data: 'sender_mime',
+ defaultContent: ''
+ },
+ {
+ title: 'To',
+ data: 'rcpt',
+ defaultContent: ''
+ },
+ {
+ title: 'Subject',
+ data: 'subject',
+ defaultContent: ''
+ },
+ {
+ title: 'Action',
+ data: 'action',
+ defaultContent: ''
+ },
+ {
+ title: 'Score',
+ data: 'score',
+ defaultContent: '',
+ class: 'text-nowrap',
+ createdCell: function(td, cellData) {
+ $(td).attr({
+ "data-order": cellData.sortBy,
+ "data-sort": cellData.sortBy
+ });
+ },
+ render: function (data) {
+ return data.value;
+ }
+ },
+ {
+ title: 'Symbols',
+ data: 'symbols',
+ defaultContent: '',
+ className: 'none dtr-col-md'
+ },
+ {
+ title: 'Msg size',
+ data: 'size',
+ defaultContent: ''
+ },
+ {
+ title: 'Scan Time',
+ data: 'scan_time',
+ defaultContent: '',
+ createdCell: function(td, cellData) {
+ $(td).attr({
+ "data-order": cellData.sortBy,
+ "data-sort": cellData.sortBy
+ });
+ },
+ render: function (data) {
+ return data.value;
+ }
+ },
+ {
+ title: 'ID',
+ data: 'message-id',
+ defaultContent: ''
+ },
+ {
+ title: 'Authenticated user',
+ data: 'user',
+ defaultContent: ''
+ }
+ ]
+ });
+
+ table.on('responsive-resize', function (e, datatable, columns){
+ hideTableExpandCollapseBtn('#tab-rspamd-history', '#rspamd_history');
+ });
+ }
+ function process_table_data(data, table) {
+ if (table == 'rspamd_history') {
+ $.each(data, function (i, item) {
+ if (item.rcpt_mime != "") {
+ item.rcpt = escapeHtml(item.rcpt_mime.join(", "));
+ }
+ else {
+ item.rcpt = escapeHtml(item.rcpt_smtp.join(", "));
+ }
+ item.symbols = Object.keys(item.symbols).sort(function (a, b) {
+ if (item.symbols[a].score === 0) return 1;
+ if (item.symbols[b].score === 0) return -1;
+ if (item.symbols[b].score < 0 && item.symbols[a].score < 0) {
+ return item.symbols[a].score - item.symbols[b].score;
+ }
+ if (item.symbols[b].score > 0 && item.symbols[a].score > 0) {
+ return item.symbols[b].score - item.symbols[a].score;
+ }
+ return item.symbols[b].score - item.symbols[a].score;
+ }).map(function(key) {
+ var sym = item.symbols[key];
+ if (sym.score < 0) {
+ sym.score_formatted = '(<span class="text-success"><b>' + sym.score + '</b></span>)';
+ }
+ else if (sym.score === 0) {
+ sym.score_formatted = '(<span><b>' + sym.score + '</b></span>)';
+ }
+ else {
+ sym.score_formatted = '(<span class="text-danger"><b>' + sym.score + '</b></span>)';
+ }
+ var str = '<strong>' + key + '</strong> ' + sym.score_formatted;
+ if (sym.options) {
+ str += ' [' + escapeHtml(sym.options.join(", ")) + "]";
+ }
+ return str;
+ }).join('<br>\n');
+ item.subject = escapeHtml(item.subject);
+ if (item.sender_mime != null) item.sender_mime = escapeHtml(item.sender_mime);
+ if (item['message-id'] != null) item['message-id'] = escapeHtml(item['message-id']);
+ var scan_time = item.time_real.toFixed(3);
+ if (item.time_virtual) {
+ scan_time += ' / ' + item.time_virtual.toFixed(3);
+ }
+ item.scan_time = {
+ "sortBy": item.time_real,
+ "value": scan_time
+ };
+ if (item.action === 'clean' || item.action === 'no action') {
+ item.action = "<div class='badge fs-6 bg-success'>" + item.action + "</div>";
+ } else if (item.action === 'rewrite subject' || item.action === 'add header' || item.action === 'probable spam') {
+ item.action = "<div class='badge fs-6 bg-warning'>" + item.action + "</div>";
+ } else if (item.action === 'spam' || item.action === 'reject') {
+ item.action = "<div class='badge fs-6 bg-danger'>" + item.action + "</div>";
+ } else {
+ item.action = "<div class='badge fs-6 bg-info'>" + item.action + "</div>";
+ }
+ var score_content;
+ if (item.score < item.required_score) {
+ score_content = "[ <span class='text-success'>" + item.score.toFixed(2) + " / " + item.required_score + "</span> ]";
+ } else {
+ score_content = "[ <span class='text-danger'>" + item.score.toFixed(2) + " / " + item.required_score + "</span> ]";
+ }
+ item.score = {
+ "sortBy": item.score,
+ "value": score_content
+ };
+ if (item.user == null) {
+ item.user = "none";
+ }
+ });
+ } else if (table == 'autodiscover_log') {
+ $.each(data, function (i, item) {
+ if (item.ua == null) {
+ item.ua = 'unknown';
+ } else {
+ item.ua = escapeHtml(item.ua);
+ }
+ item.ua = '<span style="font-size:small">' + item.ua + '</span>';
+ if (item.user == null) {
+ item.user = 'unknown';
+ } else {
+ item.user = escapeHtml(item.user);
+ }
+ if (item.service == "activesync") {
+ item.service = '<span class="badge fs-6 bg-info">ActiveSync</span>';
+ }
+ else if (item.service == "imap") {
+ item.service = '<span class="badge fs-6 bg-success">IMAP, SMTP, Cal-/CardDAV</span>';
+ }
+ else {
+ item.service = '<span class="badge fs-6 bg-danger">' + escapeHtml(item.service) + '</span>';
+ }
+ });
+ } else if (table == 'watchdog') {
+ $.each(data, function (i, item) {
+ if (item.message == null) {
+ item.message = 'Health level: ' + item.lvl + '% (' + item.hpnow + '/' + item.hptotal + ')';
+ if (item.hpdiff < 0) {
+ item.trend = '<span class="badge fs-6 bg-danger"><i class="bi bi-caret-down-fill"></i> ' + item.hpdiff + '</span>';
+ }
+ else if (item.hpdiff == 0) {
+ item.trend = '<span class="badge fs-6 bg-info"><i class="bi bi-caret-right-fill"></i> ' + item.hpdiff + '</span>';
+ }
+ else {
+ item.trend = '<span class="badge fs-6 bg-success"><i class="bi bi-caret-up-fill"></i> ' + item.hpdiff + '</span>';
+ }
+ }
+ else {
+ item.trend = '';
+ item.service = '';
+ }
+ });
+ } else if (table == 'mailcow_ui') {
+ $.each(data, function (i, item) {
+ if (item === null) { return true; }
+ item.user = escapeHtml(item.user);
+ item.call = escapeHtml(item.call);
+ if (item.msg) item.msg = escapeHtml(item.msg);
+ item.task = '<code>' + item.task + '</code>';
+ item.type = '<span class="badge fs-6 bg-' + item.type + '">' + item.type + '</span>';
+ });
+ } else if (table == 'sasl_log_table') {
+ $.each(data, function (i, item) {
+ if (item === null) { return true; }
+ item.username = escapeHtml(item.username);
+ item.real_rip = escapeHtml(item.real_rip);
+ item.service = '<div class="badge fs-6 bg-secondary">' + item.service.toUpperCase() + '</div>';
+ });
+ } else if (table == 'general_syslog') {
+ $.each(data, function (i, item) {
+ if (item === null) { return true; }
+ if (item.message.match("^base64,")) {
+ try {
+ item.message = atob(item.message.slice(7)).replace(/\\n/g, "<br />");
+ } catch(e) {
+ item.message = item.message.slice(7);
+ }
+ } else {
+ item.message = escapeHtml(item.message);
+ }
+ item.call = escapeHtml(item.call);
+ var danger_class = ["emerg", "alert", "crit", "err"];
+ var warning_class = ["warning", "warn"];
+ var info_class = ["notice", "info", "debug"];
+ if (jQuery.inArray(item.priority, danger_class) !== -1) {
+ item.priority = '<span class="badge fs-6 bg-danger">' + item.priority + '</span>';
+ } else if (jQuery.inArray(item.priority, warning_class) !== -1) {
+ item.priority = '<span class="badge fs-6 bg-warning">' + item.priority + '</span>';
+ } else if (jQuery.inArray(item.priority, info_class) !== -1) {
+ item.priority = '<span class="badge fs-6 bg-info">' + item.priority + '</span>';
+ }
+ });
+ } else if (table == 'apilog') {
+ $.each(data, function (i, item) {
+ if (item === null) { return true; }
+ if (item.method == 'GET') {
+ item.method = '<span class="badge fs-6 bg-success">' + item.method + '</span>';
+ } else if (item.method == 'POST') {
+ item.method = '<span class="badge fs-6 bg-warning">' + item.method + '</span>';
+ }
+ item.data = escapeHtml(item.data);
+ });
+ } else if (table == 'rllog') {
+ $.each(data, function (i, item) {
+ if (item.header_from != null) item.header_from = escapeHtml(item.header_from);
+ if (item.header_subject != null) item.header_subject = escapeHtml(item.header_subject);
+ if (item.from != null) item.from = escapeHtml(item.from);
+ if (item.rcpt != null) item.rcpt = escapeHtml(item.rcpt);
+ if (item.message_id != null) item.message_id = escapeHtml(item.message_id);
+ if (item.user == null) {
+ item.user = "none";
+ }
+ if (item.rl_hash == null) {
+ item.rl_hash = "err";
+ }
+ item.indicator = '<span style="border-right:6px solid #' + intToRGB(hashCode(item.rl_hash)) + ';padding-left:5px;"> </span>';
+ if (item.rl_hash != 'err') {
+ item.action = '<a href="#" data-action="delete_selected" data-id="single-hash" data-api-url="delete/rlhash" data-item="' + encodeURI(item.rl_hash) + '" class="btn btn-xs btn-danger"><i class="bi bi-trash"></i> ' + lang.reset_limit + '</a>';
+ }
+ });
+ }
+ return data;
+ };
+ $('.add_log_lines').on('click', function (e) {
+ e.preventDefault();
+ var log_table= $(this).data("table");
+ var new_nrows = $(this).data("nrows");
+ var post_process = $(this).data("post-process");
+ var log_url = $(this).data("log-url");
+ if (log_table === undefined || new_nrows === undefined || post_process === undefined || log_url === undefined) {
+ console.log("no data-table or data-nrows or log_url or data-post-process attr found");
+ return;
+ }
+
+ if (table = $('#' + log_table).DataTable()) {
+ var heading = $('#' + log_table).closest('.card').find('.card-header');
+ var load_rows = (table.data().count() + 1) + '-' + (table.data().count() + new_nrows)
+
+ $.get('/api/v1/get/logs/' + log_url + '/' + load_rows).then(function(data){
+ if (data.length === undefined) { mailcow_alert_box(lang.no_new_rows, "info"); return; }
+ var rows = process_table_data(data, post_process);
+ var rows_now = (table.page.len() + data.length);
+ $(heading).children('.table-lines').text(rows_now)
+ mailcow_alert_box(data.length + lang.additional_rows, "success");
+ table.rows.add(rows).draw();
+ });
+ }
+ })
+ function hideTableExpandCollapseBtn(tab, table){
+ if ($(table).hasClass('collapsed'))
+ $(tab).find(".table_collapse_option").show();
+ else
+ $(tab).find(".table_collapse_option").hide();
+ }
+
+ // detect element visibility changes
+ function onVisible(element, callback) {
+ $(document).ready(function() {
+ element_object = document.querySelector(element);
+ if (element_object === null) return;
+
+ new IntersectionObserver((entries, observer) => {
+ entries.forEach(entry => {
+ if(entry.intersectionRatio > 0) {
+ callback(element_object);
+ }
+ });
+ }).observe(element_object);
+ });
+ }
+ // Draw Table if tab is active
+ onVisible("[id^=postfix_log]", () => draw_postfix_logs());
+ onVisible("[id^=dovecot_log]", () => draw_dovecot_logs());
+ onVisible("[id^=sogo_log]", () => draw_sogo_logs());
+ onVisible("[id^=watchdog_log]", () => draw_watchdog_logs());
+ onVisible("[id^=autodiscover_log]", () => draw_autodiscover_logs());
+ onVisible("[id^=acme_log]", () => draw_acme_logs());
+ onVisible("[id^=api_log]", () => draw_api_logs());
+ onVisible("[id^=rl_log]", () => draw_rl_logs());
+ onVisible("[id^=ui_logs]", () => draw_ui_logs());
+ onVisible("[id^=sasl_logs]", () => draw_sasl_logs());
+ onVisible("[id^=netfilter_log]", () => draw_netfilter_logs());
+ onVisible("[id^=cron_log]", () => draw_cron_logs());
+ onVisible("[id^=rspamd_history]", () => draw_rspamd_history());
+ onVisible("[id^=rspamd_donut]", () => rspamd_pie_graph());
+
+
+ // start polling host stats if tab is active
+ onVisible("[id^=tab-containers]", () => update_stats());
+ // start polling container stats if collapse is active
+ var containerElements = document.querySelectorAll(".container-details-collapse");
+ for (let i = 0; i < containerElements.length; i++){
+ new IntersectionObserver((entries, observer) => {
+ entries.forEach(entry => {
+ if(entry.intersectionRatio > 0) {
+
+ if (!containerElements[i].classList.contains("show")){
+ var container = containerElements[i].id.replace("Collapse", "");
+ var container_id = containerElements[i].getAttribute("data-id");
+
+ // check if chart exists or needs to be created
+ if (!Chart.getChart(container + "_DiskIOChart"))
+ createReadWriteChart(container + "_DiskIOChart", "Read", "Write");
+ if (!Chart.getChart(container + "_NetIOChart"))
+ createReadWriteChart(container + "_NetIOChart", "Recv", "Sent");
+
+ // add container to polling list
+ containersToUpdate[container] = {
+ id: container_id,
+ state: "idle"
+ }
+
+ // stop polling if collapse is closed
+ containerElements[i].addEventListener('hidden.bs.collapse', function () {
+ var diskIOCtx = Chart.getChart(container + "_DiskIOChart");
+ var netIOCtx = Chart.getChart(container + "_NetIOChart");
+
+ diskIOCtx.data.datasets[0].data = [];
+ diskIOCtx.data.datasets[1].data = [];
+ diskIOCtx.data.labels = [];
+ netIOCtx.data.datasets[0].data = [];
+ netIOCtx.data.datasets[1].data = [];
+ netIOCtx.data.labels = [];
+
+ diskIOCtx.update();
+ netIOCtx.update();
+
+ delete containersToUpdate[container];
+ });
+ }
+
+ }
+ });
+ }).observe(containerElements[i]);
+ }
+});
+
+
+// update system stats - every 5 seconds if system & container tab is active
+function update_stats(timeout=5){
+ if (!$('#tab-containers').hasClass('active')) {
+ // tab not active - dont fetch stats - run again in n seconds
+ return;
+ }
+
+ window.fetch("/api/v1/get/status/host", {method:'GET',cache:'no-cache'}).then(function(response) {
+ return response.json();
+ }).then(function(data) {
+ if (data){
+ // display table data
+ $("#host_date").text(data.system_time);
+ $("#host_uptime").text(formatUptime(data.uptime));
+ $("#host_cpu_cores").text(data.cpu.cores);
+ $("#host_cpu_usage").text(parseInt(data.cpu.usage).toString() + "%");
+ $("#host_memory_total").text((data.memory.total / (1024 ** 3)).toFixed(2).toString() + "GB");
+ $("#host_memory_usage").text(parseInt(data.memory.usage).toString() + "%");
+ $("#host_architecture").html(data.architecture);
+ // update cpu and mem chart
+ var cpu_chart = Chart.getChart("host_cpu_chart");
+ var mem_chart = Chart.getChart("host_mem_chart");
+
+ cpu_chart.data.labels.push(data.system_time.split(" ")[1]);
+ if (cpu_chart.data.labels.length > 30) cpu_chart.data.labels.shift();
+ mem_chart.data.labels.push(data.system_time.split(" ")[1]);
+ if (mem_chart.data.labels.length > 30) mem_chart.data.labels.shift();
+
+ cpu_chart.data.datasets[0].data.push(data.cpu.usage);
+ if (cpu_chart.data.datasets[0].data.length > 30) cpu_chart.data.datasets[0].data.shift();
+ mem_chart.data.datasets[0].data.push(data.memory.usage);
+ if (mem_chart.data.datasets[0].data.length > 30) mem_chart.data.datasets[0].data.shift();
+
+ cpu_chart.update();
+ mem_chart.update();
+ }
+
+ // run again in n seconds
+ setTimeout(update_stats, timeout * 1000);
+ });
+}
+// update specific container stats - every n (default 5s) seconds
+function update_container_stats(timeout=5){
+
+ if ($('#tab-containers').hasClass('active')) {
+ for (let container in containersToUpdate){
+ container_id = containersToUpdate[container].id;
+ // check if container update stats is already running
+ if (containersToUpdate[container].state == "running")
+ continue;
+ containersToUpdate[container].state = "running";
+
+
+ window.fetch("/api/v1/get/status/container/" + container_id, {method:'GET',cache:'no-cache'}).then(function(response) {
+ return response.json();
+ }).then(function(data) {
+ var diskIOCtx = Chart.getChart(container + "_DiskIOChart");
+ var netIOCtx = Chart.getChart(container + "_NetIOChart");
+
+ prev_stats = null;
+ if (data.length >= 2){
+ prev_stats = data[data.length -2];
+
+ // hide spinners if we collected enough data
+ $('#' + container + "_DiskIOChart").removeClass('d-none');
+ $('#' + container + "_DiskIOChart").prev().addClass('d-none');
+ $('#' + container + "_NetIOChart").removeClass('d-none');
+ $('#' + container + "_NetIOChart").prev().addClass('d-none');
+ }
+
+ data = data[data.length -1];
+
+ if (prev_stats != null){
+ // calc time diff
+ var time_diff = (new Date(data.read) - new Date(prev_stats.read)) / 1000;
+
+ // calc disk io b/s
+ if ('io_service_bytes_recursive' in prev_stats.blkio_stats && prev_stats.blkio_stats.io_service_bytes_recursive !== null){
+ var prev_read_bytes = 0;
+ var prev_write_bytes = 0;
+ for (var i = 0; i < prev_stats.blkio_stats.io_service_bytes_recursive.length; i++){
+ if (prev_stats.blkio_stats.io_service_bytes_recursive[i].op == "read")
+ prev_read_bytes = prev_stats.blkio_stats.io_service_bytes_recursive[i].value;
+ else if (prev_stats.blkio_stats.io_service_bytes_recursive[i].op == "write")
+ prev_write_bytes = prev_stats.blkio_stats.io_service_bytes_recursive[i].value;
+ }
+ var read_bytes = 0;
+ var write_bytes = 0;
+ for (var i = 0; i < data.blkio_stats.io_service_bytes_recursive.length; i++){
+ if (data.blkio_stats.io_service_bytes_recursive[i].op == "read")
+ read_bytes = data.blkio_stats.io_service_bytes_recursive[i].value;
+ else if (data.blkio_stats.io_service_bytes_recursive[i].op == "write")
+ write_bytes = data.blkio_stats.io_service_bytes_recursive[i].value;
+ }
+ var diff_bytes_read = (read_bytes - prev_read_bytes) / time_diff;
+ var diff_bytes_write = (write_bytes - prev_write_bytes) / time_diff;
+ }
+
+ // calc net io b/s
+ if ('networks' in prev_stats){
+ var prev_recv_bytes = 0;
+ var prev_sent_bytes = 0;
+ for (var key in prev_stats.networks){
+ prev_recv_bytes += prev_stats.networks[key].rx_bytes;
+ prev_sent_bytes += prev_stats.networks[key].tx_bytes;
+ }
+ var recv_bytes = 0;
+ var sent_bytes = 0;
+ for (var key in data.networks){
+ recv_bytes += data.networks[key].rx_bytes;
+ sent_bytes += data.networks[key].tx_bytes;
+ }
+ var diff_bytes_recv = (recv_bytes - prev_recv_bytes) / time_diff;
+ var diff_bytes_sent = (sent_bytes - prev_sent_bytes) / time_diff;
+ }
+
+ addReadWriteChart(diskIOCtx, diff_bytes_read, diff_bytes_write, "");
+ addReadWriteChart(netIOCtx, diff_bytes_recv, diff_bytes_sent, "");
+ }
+
+ // run again in n seconds
+ containersToUpdate[container].state = "idle";
+ }).catch(err => {
+ console.log(err);
+ });
+ }
+ }
+
+ // run again in n seconds
+ setTimeout(update_container_stats, timeout * 1000);
+}
+// format hosts uptime seconds to readable string
+function formatUptime(seconds){
+ seconds = Number(seconds);
+ var d = Math.floor(seconds / (3600*24));
+ var h = Math.floor(seconds % (3600*24) / 3600);
+ var m = Math.floor(seconds % 3600 / 60);
+ var s = Math.floor(seconds % 60);
+
+ var dFormat = d > 0 ? d + "D " : "";
+ var hFormat = h > 0 ? h + "H " : "";
+ var mFormat = m > 0 ? m + "M " : "";
+ var sFormat = s > 0 ? s + "S" : "";
+ return dFormat + hFormat + mFormat + sFormat;
+}
+// format bytes to readable string
+function formatBytes(bytes){
+ // b
+ if (bytes < 1000) return bytes.toFixed(2).toString()+' B/s';
+ // b to kb
+ bytes = bytes / 1024;
+ if (bytes < 1000) return bytes.toFixed(2).toString()+' KB/s';
+ // kb to mb
+ bytes = bytes / 1024;
+ if (bytes < 1000) return bytes.toFixed(2).toString()+' MB/s';
+ // final mb to gb
+ return (bytes / 1024).toFixed(2).toString()+' GB/s';
+}
+// create read write line chart
+function createReadWriteChart(chart_id, read_lable, write_lable){
+ var ctx = document.getElementById(chart_id);
+
+ var dataNet = {
+ labels: [],
+ datasets: [{
+ label: read_lable,
+ backgroundColor: "rgba(41, 187, 239, 0.3)",
+ borderColor: "rgba(41, 187, 239, 0.6)",
+ pointRadius: 1,
+ pointHitRadius: 6,
+ borderWidth: 2,
+ fill: true,
+ tension: 0.2,
+ data: []
+ }, {
+ label: write_lable,
+ backgroundColor: "rgba(239, 60, 41, 0.3)",
+ borderColor: "rgba(239, 60, 41, 0.6)",
+ pointRadius: 1,
+ pointHitRadius: 6,
+ borderWidth: 2,
+ fill: true,
+ tension: 0.2,
+ data: []
+ }]
+ };
+ var optionsNet = {
+ interaction: {
+ mode: 'index'
+ },
+ scales: {
+ yAxis: {
+ min: 0,
+ grid: {
+ display: false
+ },
+ ticks: {
+ callback: function(i, index, ticks) {
+ return formatBytes(i);
+ }
+ }
+ },
+ xAxis: {
+ grid: {
+ display: false
+ }
+ }
+ }
+ };
+
+ return new Chart(ctx, {
+ type: 'line',
+ data: dataNet,
+ options: optionsNet
+ });
+}
+// add to read write line chart
+function addReadWriteChart(chart_context, read_point, write_point, time, limit = 30){
+ // push time label for x-axis
+ chart_context.data.labels.push(time);
+ if (chart_context.data.labels.length > limit) chart_context.data.labels.shift();
+
+ // push datapoints
+ chart_context.data.datasets[0].data.push(read_point);
+ chart_context.data.datasets[1].data.push(write_point);
+ // shift data if more than 20 entires exists
+ if (chart_context.data.datasets[0].data.length > limit) chart_context.data.datasets[0].data.shift();
+ if (chart_context.data.datasets[1].data.length > limit) chart_context.data.datasets[1].data.shift();
+
+ chart_context.update();
+}
+// create host cpu and mem chart
+function createHostCpuAndMemChart(){
+ var cpu_ctx = document.getElementById("host_cpu_chart");
+ var mem_ctx = document.getElementById("host_mem_chart");
+
+ var dataCpu = {
+ labels: [],
+ datasets: [{
+ label: "CPU %",
+ backgroundColor: "rgba(41, 187, 239, 0.3)",
+ borderColor: "rgba(41, 187, 239, 0.6)",
+ pointRadius: 1,
+ pointHitRadius: 6,
+ borderWidth: 2,
+ fill: true,
+ tension: 0.2,
+ data: []
+ }]
+ };
+ var optionsCpu = {
+ interaction: {
+ mode: 'index'
+ },
+ scales: {
+ yAxis: {
+ min: 0,
+ grid: {
+ display: false
+ },
+ ticks: {
+ callback: function(i, index, ticks) {
+ return i.toFixed(0).toString() + "%";
+ }
+ }
+ },
+ xAxis: {
+ grid: {
+ display: false
+ }
+ }
+ }
+ };
+
+ var dataMem = {
+ labels: [],
+ datasets: [{
+ label: "MEM %",
+ backgroundColor: "rgba(41, 187, 239, 0.3)",
+ borderColor: "rgba(41, 187, 239, 0.6)",
+ pointRadius: 1,
+ pointHitRadius: 6,
+ borderWidth: 2,
+ fill: true,
+ tension: 0.2,
+ data: []
+ }]
+ };
+ var optionsMem = {
+ interaction: {
+ mode: 'index'
+ },
+ scales: {
+ yAxis: {
+ min: 0,
+ grid: {
+ display: false
+ },
+ ticks: {
+ callback: function(i, index, ticks) {
+ return i.toFixed(0).toString() + "%";
+ }
+ }
+ },
+ xAxis: {
+ grid: {
+ display: false
+ }
+ }
+ }
+ };
+
+
+ var net_io_chart = new Chart(cpu_ctx, {
+ type: 'line',
+ data: dataCpu,
+ options: optionsCpu
+ });
+ var disk_io_chart = new Chart(mem_ctx, {
+ type: 'line',
+ data: dataMem,
+ options: optionsMem
+ });
+}
+// check for mailcow updates
+function check_update(current_version, github_repo_url){
+ if (!current_version || !github_repo_url) return false;
+
+
+ window.fetch("/inc/ajax/update_check.php", {method:'GET',cache:'no-cache'}).then(function(response) {
+ if (!response.ok) throw new Error("update check returned " + response.status);
+ return response.json();
+ }).then(function(data) {
+ if (data.status === "no_update") {
+ $("#mailcow_update").removeClass("text-warning text-danger").addClass("text-success");
+ $("#mailcow_update").html("<b>" + lang_debug.no_update_available + "</b>");
+ } else if (data.status === "update_available") {
+ $("#mailcow_update").removeClass("text-danger text-success").addClass("text-warning");
+ $("#mailcow_update").html(lang_debug.update_available + ` <a href="#" id="mailcow_update_changelog">`+data.latest_tag+`</a>`);
+ $("#mailcow_update_changelog").click(function(){
+ if (mailcow_cc_role !== "admin" && mailcow_cc_role !== "domainadmin")
+ return;
+
+ showVersionModal("New Release " + data.latest_tag, data.latest_tag);
+ })
+ } else {
+ throw new Error(data.message || "update check failed");
+ }
+ }).catch(err => {
+ // err
+ console.log(err);
+ $("#mailcow_update").removeClass("text-success text-warning").addClass("text-danger");
+ $("#mailcow_update").html("<b>"+ lang_debug.update_failed +"</b>");
+ });
+}
+// show version changelog modal
+function showVersionModal(title, version){
+ $.ajax({
+ type: 'GET',
+ url: 'https://api.github.com/repos/' + mailcow_info.project_owner + '/' + mailcow_info.project_repo + '/releases/tags/' + version,
+ dataType: 'json',
+ success: function (data) {
+ var md = window.markdownit();
+ var result = md.render(data.body);
+ result = parseGithubMarkdownLinks(result);
+
+ $('#showVersionModal').find(".modal-title").html(title);
+ $('#showVersionModal').find(".modal-body").html(`
+ <h3>` + data.name + `</h3>
+ <span class="mt-4">` + result + `</span>
+ <span><b>Github Link:</b>
+ <a target="_blank" href="https://github.com/` + mailcow_info.project_owner + `/` + mailcow_info.project_repo + `/releases/tag/` + version + `">` + version + `</a>
+ </span>
+ `);
+
+ new bootstrap.Modal(document.getElementById("showVersionModal"), {
+ backdrop: 'static',
+ keyboard: false
+ }).show();
+ }
+ });
+}
+function parseGithubMarkdownLinks(inputText) {
+ var replacedText, replacePattern1;
+
+ replacePattern1 = /(\b(https?):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])(?![^<]*>)/gim;
+ replacedText = inputText.replace(replacePattern1, (matched, index, original, input_string) => {
+ if (matched.includes('github.com')){
+ // return short link if it's github link
+ last_uri_path = matched.split('/');
+ last_uri_path = last_uri_path[last_uri_path.length - 1];
+
+ // adjust Full Changelog link to match last git version and new git version, if link is a compare link
+ if (matched.includes('/compare/') && mailcow_info.last_version_tag !== ''){
+ matched = matched.replace(last_uri_path, mailcow_info.last_version_tag + '...' + mailcow_info.version_tag);
+ last_uri_path = mailcow_info.last_version_tag + '...' + mailcow_info.version_tag;
+ }
+
+ return '<a href="' + matched + '" target="_blank">' + last_uri_path + '</a><br>';
+ };
+
+ // if it's not a github link, return complete link
+ return '<a href="' + matched + '" target="_blank">' + matched + '</a>';
+ });
+
+ return replacedText;
+}
+
+function convertTimestampToLocalFormat(timestamp) {
+ var date = new Date(timestamp ? timestamp * 1000 : 0);
+ return date.toLocaleDateString(LOCALE, DATETIME_FORMAT);
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/debug.js b/mailcow/src/mailcow-dockerized/data/web/js/site/debug.js
deleted file mode 100644
index 512d955..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/debug.js
+++ /dev/null
@@ -1,1713 +0,0 @@
-$(document).ready(function() {
- // Parse seconds ago to date
- // Get "now" timestamp
- var ts_now = Math.round((new Date()).getTime() / 1000);
- $('.parse_s_ago').each(function(i, parse_s_ago) {
- var started_s_ago = parseInt($(this).text(), 10);
- if (typeof started_s_ago != 'NaN') {
- var started_date = new Date((ts_now - started_s_ago) * 1000);
- if (started_date instanceof Date && !isNaN(started_date)) {
- var started_local_date = started_date.toLocaleDateString(LOCALE, DATETIME_FORMAT);
- $(this).text(started_local_date);
- } else {
- $(this).text('-');
- }
- }
- });
- // Parse general dates
- $('.parse_date').each(function(i, parse_date) {
- var started_date = new Date(Date.parse($(this).text()));
- if (typeof started_date != 'NaN') {
- var started_local_date = started_date.toLocaleDateString(LOCALE, DATETIME_FORMAT);
- $(this).text(started_local_date);
- }
- });
-
- // set update loop container list
- containersToUpdate = {};
- // set default ChartJs Font Color
- Chart.defaults.color = '#999';
- // create host cpu and mem charts
- createHostCpuAndMemChart();
- // check for new version
- if (mailcow_info.branch === "master"){
- check_update(mailcow_info.version_tag, mailcow_info.project_url);
- }
- $("#mailcow_version").click(function(){
- if (mailcow_cc_role !== "admin" && mailcow_cc_role !== "domainadmin" || mailcow_info.branch !== "master")
- return;
-
- showVersionModal("Version " + mailcow_info.version_tag, mailcow_info.version_tag);
- })
- // get public ips
- $("#host_show_ip").click(function(){
- $("#host_show_ip").find(".text").addClass("d-none");
- $("#host_show_ip").find(".spinner-border").removeClass("d-none");
-
- window.fetch("/api/v1/get/status/host/ip", { method:'GET', cache:'no-cache' }).then(function(response) {
- return response.json();
- }).then(function(data) {
- console.log(data);
-
- // display host ips
- if (data.ipv4)
- $("#host_ipv4").text(data.ipv4);
- if (data.ipv6)
- $("#host_ipv6").text(data.ipv6);
-
- $("#host_show_ip").addClass("d-none");
- $("#host_show_ip").find(".text").removeClass("d-none");
- $("#host_show_ip").find(".spinner-border").addClass("d-none");
- $("#host_ipv4").removeClass("d-none");
- $("#host_ipv6").removeClass("d-none");
- $("#host_ipv6").removeClass("text-danger");
- $("#host_ipv4").addClass("d-block");
- $("#host_ipv6").addClass("d-block");
- }).catch(function(error){
- console.log(error);
-
- $("#host_ipv6").removeClass("d-none");
- $("#host_ipv6").addClass("d-block");
- $("#host_ipv6").addClass("text-danger");
- $("#host_ipv6").text(lang_debug.error_show_ip);
- $("#host_show_ip").find(".text").removeClass("d-none");
- $("#host_show_ip").find(".spinner-border").addClass("d-none");
- });
- });
- update_container_stats();
-});
-jQuery(function($){
- if (localStorage.getItem("current_page") === null) {
- var current_page = {};
- } else {
- var current_page = JSON.parse(localStorage.getItem('current_page'));
- }
- // http://stackoverflow.com/questions/24816/escaping-html-strings-with-jquery
- var entityMap={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="};
- function escapeHtml(n){return String(n).replace(/[&<>"'`=\/]/g,function(n){return entityMap[n]})}
- function humanFileSize(i){if(Math.abs(i)<1024)return i+" B";var B=["KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"],e=-1;do{i/=1024,++e}while(Math.abs(i)>=1024&&e<B.length-1);return i.toFixed(1)+" "+B[e]}
- function hashCode(t){for(var n=0,r=0;r<t.length;r++)n=t.charCodeAt(r)+((n<<5)-n);return n}
- function intToRGB(t){var n=(16777215&t).toString(16).toUpperCase();return"00000".substring(0,6-n.length)+n}
- $(".refresh_table").on('click', function(e) {
- e.preventDefault();
- var table_name = $(this).data('table');
- $('#' + table_name).DataTable().ajax.reload();
- });
- function createSortableDate(td, cellData) {
- $(td).attr({
- "data-order": cellData,
- "data-sort": cellData
- });
- $(td).html(convertTimestampToLocalFormat(cellData));
- }
- function draw_autodiscover_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#autodiscover_log') ) {
- $('#autodiscover_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#autodiscover_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-autodiscover-logs', '#autodiscover_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/autodiscover/100",
- dataSrc: function(data){
- return process_table_data(data, 'autodiscover_log');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- responsivePriority: 1,
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: 'User-Agent',
- data: 'ua',
- defaultContent: '',
- className: 'dtr-col-md',
- responsivePriority: 5
- },
- {
- title: 'Username',
- data: 'user',
- defaultContent: '',
- responsivePriority: 4
- },
- {
- title: 'IP',
- data: 'ip',
- defaultContent: '',
- responsivePriority: 2
- },
- {
- title: 'Service',
- data: 'service',
- defaultContent: '',
- responsivePriority: 3
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-autodiscover-logs', '#autodiscover_log');
- });
- }
- function draw_postfix_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#postfix_log') ) {
- $('#postfix_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#postfix_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-postfix-logs', '#postfix_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/postfix",
- dataSrc: function(data){
- return process_table_data(data, 'general_syslog');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: lang.priority,
- data: 'priority',
- defaultContent: ''
- },
- {
- title: lang.message,
- data: 'message',
- defaultContent: '',
- className: 'dtr-col-md text-break'
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-postfix-logs', '#postfix_log');
- });
- }
- function draw_watchdog_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#watchdog_log') ) {
- $('#watchdog_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#watchdog_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-watchdog-logs', '#watchdog_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/watchdog",
- dataSrc: function(data){
- return process_table_data(data, 'watchdog');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: 'Service',
- data: 'service',
- defaultContent: ''
- },
- {
- title: 'Trend',
- data: 'trend',
- defaultContent: ''
- },
- {
- title: lang.message,
- data: 'message',
- defaultContent: ''
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-watchdog-logs', '#watchdog_log');
- });
- }
- function draw_api_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#api_log') ) {
- $('#api_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#api_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-api-logs', '#api_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/api",
- dataSrc: function(data){
- return process_table_data(data, 'apilog');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: 'URI',
- data: 'uri',
- defaultContent: '',
- className: 'dtr-col-md dtr-break-all'
- },
- {
- title: 'Method',
- data: 'method',
- defaultContent: ''
- },
- {
- title: 'IP',
- data: 'remote',
- defaultContent: ''
- },
- {
- title: 'Data',
- data: 'data',
- defaultContent: '',
- className: 'dtr-col-md dtr-break-all'
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-api-logs', '#api_log');
- });
- }
- function draw_rl_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#rl_log') ) {
- $('#rl_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#rl_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-rl-logs', '#rl_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/ratelimited",
- dataSrc: function(data){
- return process_table_data(data, 'rllog');
- }
- },
- columns: [
- {
- title: ' ',
- data: 'indicator',
- defaultContent: ''
- },
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: lang.rate_name,
- data: 'rl_name',
- defaultContent: ''
- },
- {
- title: lang.sender,
- data: 'from',
- defaultContent: ''
- },
- {
- title: lang.recipients,
- data: 'rcpt',
- defaultContent: ''
- },
- {
- title: lang.authed_user,
- data: 'user',
- defaultContent: ''
- },
- {
- title: 'Msg ID',
- data: 'message_id',
- defaultContent: ''
- },
- {
- title: 'Header From',
- data: 'header_from',
- defaultContent: ''
- },
- {
- title: 'Subject',
- data: 'header_subject',
- defaultContent: ''
- },
- {
- title: 'Hash',
- data: 'rl_hash',
- defaultContent: ''
- },
- {
- title: 'Rspamd QID',
- data: 'qid',
- defaultContent: ''
- },
- {
- title: 'IP',
- data: 'ip',
- defaultContent: ''
- },
- {
- title: lang.action,
- data: 'action',
- defaultContent: ''
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-rl-logs', '#rl_log');
- });
- }
- function draw_ui_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#ui_logs') ) {
- $('#ui_logs').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#ui_logs').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-ui-logs', '#ui_logs');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/ui",
- dataSrc: function(data){
- return process_table_data(data, 'mailcow_ui');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: 'Type',
- data: 'type',
- defaultContent: ''
- },
- {
- title: 'Task',
- data: 'task',
- defaultContent: ''
- },
- {
- title: 'User',
- data: 'user',
- defaultContent: '',
- className: 'dtr-col-sm'
- },
- {
- title: 'Role',
- data: 'role',
- defaultContent: '',
- className: 'dtr-col-sm'
- },
- {
- title: 'IP',
- data: 'remote',
- defaultContent: '',
- className: 'dtr-col-md dtr-break-all'
- },
- {
- title: lang.message,
- data: 'msg',
- defaultContent: '',
- className: 'dtr-col-md dtr-break-all'
- },
- {
- title: 'Call',
- data: 'call',
- defaultContent: '',
- className: 'none dtr-col-md dtr-break-all'
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-ui-logs', '#ui_log');
- });
- }
- function draw_sasl_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#sasl_logs') ) {
- $('#sasl_logs').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#sasl_logs').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-sasl-logs', '#sasl_logs');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/sasl",
- dataSrc: function(data){
- return process_table_data(data, 'sasl_log_table');
- }
- },
- columns: [
- {
- title: lang.username,
- data: 'username',
- defaultContent: ''
- },
- {
- title: lang.service,
- data: 'service',
- defaultContent: ''
- },
- {
- title: 'IP',
- data: 'real_rip',
- defaultContent: '',
- className: 'dtr-col-md text-break'
- },
- {
- title: lang.login_time,
- data: 'datetime',
- defaultContent: '',
- createdCell: function(td, cellData) {
- cellData = Math.floor((new Date(cellData.replace(/-/g, "/"))).getTime() / 1000);
- createSortableDate(td, cellData)
- }
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-sasl-logs', '#sasl_logs');
- });
- }
- function draw_acme_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#acme_log') ) {
- $('#acme_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#acme_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-acme-logs', '#acme_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/acme",
- dataSrc: function(data){
- return process_table_data(data, 'general_syslog');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: lang.message,
- data: 'message',
- defaultContent: '',
- className: 'dtr-col-md dtr-break-all'
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-acme-logs', '#acme_log');
- });
- }
- function draw_netfilter_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#netfilter_log') ) {
- $('#netfilter_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#netfilter_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-netfilter-logs', '#netfilter_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/netfilter",
- dataSrc: function(data){
- return process_table_data(data, 'general_syslog');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: lang.priority,
- data: 'priority',
- defaultContent: ''
- },
- {
- title: lang.message,
- data: 'message',
- defaultContent: '',
- className: 'dtr-col-md text-break'
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-netfilter-logs', '#netfilter_log');
- });
- }
- function draw_sogo_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#sogo_log') ) {
- $('#sogo_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#sogo_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-sogo-logs', '#sogo_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/sogo",
- dataSrc: function(data){
- return process_table_data(data, 'general_syslog');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: lang.priority,
- data: 'priority',
- defaultContent: ''
- },
- {
- title: lang.message,
- data: 'message',
- defaultContent: '',
- className: 'dtr-col-md text-break'
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-sogo-logs', '#sogo_log');
- });
- }
- function draw_dovecot_logs() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#dovecot_log') ) {
- $('#dovecot_log').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#dovecot_log').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-dovecot-logs', '#dovecot_log');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/dovecot",
- dataSrc: function(data){
- return process_table_data(data, 'general_syslog');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: lang.priority,
- data: 'priority',
- defaultContent: ''
- },
- {
- title: lang.message,
- data: 'message',
- defaultContent: '',
- className: 'dtr-col-md text-break'
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-dovecot-logs', '#dovecot_log');
- });
- }
- function rspamd_pie_graph() {
- $.ajax({
- url: '/api/v1/get/rspamd/actions',
- async: true,
- success: function(data){
- var total = 0;
- $(data).map(function(){total += this[1];});
- var labels = $.makeArray($(data).map(function(){return this[0] + ' ' + Math.round(this[1]/total * 100) + '%';}));
- var values = $.makeArray($(data).map(function(){return this[1];}));
-
- var graphdata = {
- labels: labels,
- datasets: [{
- data: values,
- backgroundColor: ['#DC3023', '#59ABE3', '#FFA400', '#FFA400', '#26A65B']
- }]
- };
-
- var options = {
- responsive: true,
- maintainAspectRatio: false,
- plugins: {
- datalabels: {
- color: '#FFF',
- font: {
- weight: 'bold'
- },
- display: function(context) {
- return context.dataset.data[context.dataIndex] !== 0;
- },
- formatter: function(value, context) {
- return Math.round(value/total*100) + '%';
- }
- }
- }
- };
- var chartcanvas = document.getElementById('rspamd_donut');
- Chart.register('ChartDataLabels');
- if(typeof chart == 'undefined') {
- chart = new Chart(chartcanvas.getContext("2d"), {
- plugins: [ChartDataLabels],
- type: 'doughnut',
- data: graphdata,
- options: options
- });
- }
- else {
- chart.destroy();
- chart = new Chart(chartcanvas.getContext("2d"), {
- plugins: [ChartDataLabels],
- type: 'doughnut',
- data: graphdata,
- options: options
- });
- }
- }
- });
- }
- function draw_rspamd_history() {
- // just recalc width if instance already exists
- if ($.fn.DataTable.isDataTable('#rspamd_history') ) {
- $('#rspamd_history').DataTable().columns.adjust().responsive.recalc();
- return;
- }
-
- var table = $('#rspamd_history').DataTable({
- responsive: true,
- processing: true,
- serverSide: false,
- stateSave: true,
- pageLength: log_pagination_size,
- dom: "<'row'<'col-sm-12 col-md-6'f><'col-sm-12 col-md-6'l>>" +
- "tr" +
- "<'row'<'col-sm-12 col-md-5'i><'col-sm-12 col-md-7'p>>",
- language: lang_datatables,
- order: [[0, 'desc']],
- initComplete: function(){
- hideTableExpandCollapseBtn('#tab-rspamd-logs', '#rspamd_history');
- },
- ajax: {
- type: "GET",
- url: "/api/v1/get/logs/rspamd-history",
- dataSrc: function(data){
- return process_table_data(data, 'rspamd_history');
- }
- },
- columns: [
- {
- title: lang.time,
- data: 'unix_time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
- },
- {
- title: 'IP address',
- data: 'ip',
- defaultContent: ''
- },
- {
- title: 'From',
- data: 'sender_mime',
- defaultContent: ''
- },
- {
- title: 'To',
- data: 'rcpt',
- defaultContent: ''
- },
- {
- title: 'Subject',
- data: 'subject',
- defaultContent: ''
- },
- {
- title: 'Action',
- data: 'action',
- defaultContent: ''
- },
- {
- title: 'Score',
- data: 'score',
- defaultContent: '',
- class: 'text-nowrap',
- createdCell: function(td, cellData) {
- $(td).attr({
- "data-order": cellData.sortBy,
- "data-sort": cellData.sortBy
- });
- },
- render: function (data) {
- return data.value;
- }
- },
- {
- title: 'Symbols',
- data: 'symbols',
- defaultContent: '',
- className: 'none dtr-col-md'
- },
- {
- title: 'Msg size',
- data: 'size',
- defaultContent: ''
- },
- {
- title: 'Scan Time',
- data: 'scan_time',
- defaultContent: '',
- createdCell: function(td, cellData) {
- $(td).attr({
- "data-order": cellData.sortBy,
- "data-sort": cellData.sortBy
- });
- },
- render: function (data) {
- return data.value;
- }
- },
- {
- title: 'ID',
- data: 'message-id',
- defaultContent: ''
- },
- {
- title: 'Authenticated user',
- data: 'user',
- defaultContent: ''
- }
- ]
- });
-
- table.on('responsive-resize', function (e, datatable, columns){
- hideTableExpandCollapseBtn('#tab-rspamd-history', '#rspamd_history');
- });
- }
- function process_table_data(data, table) {
- if (table == 'rspamd_history') {
- $.each(data, function (i, item) {
- if (item.rcpt_mime != "") {
- item.rcpt = escapeHtml(item.rcpt_mime.join(", "));
- }
- else {
- item.rcpt = escapeHtml(item.rcpt_smtp.join(", "));
- }
- item.symbols = Object.keys(item.symbols).sort(function (a, b) {
- if (item.symbols[a].score === 0) return 1;
- if (item.symbols[b].score === 0) return -1;
- if (item.symbols[b].score < 0 && item.symbols[a].score < 0) {
- return item.symbols[a].score - item.symbols[b].score;
- }
- if (item.symbols[b].score > 0 && item.symbols[a].score > 0) {
- return item.symbols[b].score - item.symbols[a].score;
- }
- return item.symbols[b].score - item.symbols[a].score;
- }).map(function(key) {
- var sym = item.symbols[key];
- if (sym.score < 0) {
- sym.score_formatted = '(<span class="text-success"><b>' + sym.score + '</b></span>)';
- }
- else if (sym.score === 0) {
- sym.score_formatted = '(<span><b>' + sym.score + '</b></span>)';
- }
- else {
- sym.score_formatted = '(<span class="text-danger"><b>' + sym.score + '</b></span>)';
- }
- var str = '<strong>' + key + '</strong> ' + sym.score_formatted;
- if (sym.options) {
- str += ' [' + escapeHtml(sym.options.join(", ")) + "]";
- }
- return str;
- }).join('<br>\n');
- item.subject = escapeHtml(item.subject);
- var scan_time = item.time_real.toFixed(3);
- if (item.time_virtual) {
- scan_time += ' / ' + item.time_virtual.toFixed(3);
- }
- item.scan_time = {
- "sortBy": item.time_real,
- "value": scan_time
- };
- if (item.action === 'clean' || item.action === 'no action') {
- item.action = "<div class='badge fs-6 bg-success'>" + item.action + "</div>";
- } else if (item.action === 'rewrite subject' || item.action === 'add header' || item.action === 'probable spam') {
- item.action = "<div class='badge fs-6 bg-warning'>" + item.action + "</div>";
- } else if (item.action === 'spam' || item.action === 'reject') {
- item.action = "<div class='badge fs-6 bg-danger'>" + item.action + "</div>";
- } else {
- item.action = "<div class='badge fs-6 bg-info'>" + item.action + "</div>";
- }
- var score_content;
- if (item.score < item.required_score) {
- score_content = "[ <span class='text-success'>" + item.score.toFixed(2) + " / " + item.required_score + "</span> ]";
- } else {
- score_content = "[ <span class='text-danger'>" + item.score.toFixed(2) + " / " + item.required_score + "</span> ]";
- }
- item.score = {
- "sortBy": item.score,
- "value": score_content
- };
- if (item.user == null) {
- item.user = "none";
- }
- });
- } else if (table == 'autodiscover_log') {
- $.each(data, function (i, item) {
- if (item.ua == null) {
- item.ua = 'unknown';
- } else {
- item.ua = escapeHtml(item.ua);
- }
- item.ua = '<span style="font-size:small">' + item.ua + '</span>';
- if (item.service == "activesync") {
- item.service = '<span class="badge fs-6 bg-info">ActiveSync</span>';
- }
- else if (item.service == "imap") {
- item.service = '<span class="badge fs-6 bg-success">IMAP, SMTP, Cal-/CardDAV</span>';
- }
- else {
- item.service = '<span class="badge fs-6 bg-danger">' + escapeHtml(item.service) + '</span>';
- }
- });
- } else if (table == 'watchdog') {
- $.each(data, function (i, item) {
- if (item.message == null) {
- item.message = 'Health level: ' + item.lvl + '% (' + item.hpnow + '/' + item.hptotal + ')';
- if (item.hpdiff < 0) {
- item.trend = '<span class="badge fs-6 bg-danger"><i class="bi bi-caret-down-fill"></i> ' + item.hpdiff + '</span>';
- }
- else if (item.hpdiff == 0) {
- item.trend = '<span class="badge fs-6 bg-info"><i class="bi bi-caret-right-fill"></i> ' + item.hpdiff + '</span>';
- }
- else {
- item.trend = '<span class="badge fs-6 bg-success"><i class="bi bi-caret-up-fill"></i> ' + item.hpdiff + '</span>';
- }
- }
- else {
- item.trend = '';
- item.service = '';
- }
- });
- } else if (table == 'mailcow_ui') {
- $.each(data, function (i, item) {
- if (item === null) { return true; }
- item.user = escapeHtml(item.user);
- item.call = escapeHtml(item.call);
- item.task = '<code>' + item.task + '</code>';
- item.type = '<span class="badge fs-6 bg-' + item.type + '">' + item.type + '</span>';
- });
- } else if (table == 'sasl_log_table') {
- $.each(data, function (i, item) {
- if (item === null) { return true; }
- item.username = escapeHtml(item.username);
- item.service = '<div class="badge fs-6 bg-secondary">' + item.service.toUpperCase() + '</div>';
- });
- } else if (table == 'general_syslog') {
- $.each(data, function (i, item) {
- if (item === null) { return true; }
- if (item.message.match("^base64,")) {
- try {
- item.message = atob(item.message.slice(7)).replace(/\\n/g, "<br />");
- } catch(e) {
- item.message = item.message.slice(7);
- }
- } else {
- item.message = escapeHtml(item.message);
- }
- item.call = escapeHtml(item.call);
- var danger_class = ["emerg", "alert", "crit", "err"];
- var warning_class = ["warning", "warn"];
- var info_class = ["notice", "info", "debug"];
- if (jQuery.inArray(item.priority, danger_class) !== -1) {
- item.priority = '<span class="badge fs-6 bg-danger">' + item.priority + '</span>';
- } else if (jQuery.inArray(item.priority, warning_class) !== -1) {
- item.priority = '<span class="badge fs-6 bg-warning">' + item.priority + '</span>';
- } else if (jQuery.inArray(item.priority, info_class) !== -1) {
- item.priority = '<span class="badge fs-6 bg-info">' + item.priority + '</span>';
- }
- });
- } else if (table == 'apilog') {
- $.each(data, function (i, item) {
- if (item === null) { return true; }
- if (item.method == 'GET') {
- item.method = '<span class="badge fs-6 bg-success">' + item.method + '</span>';
- } else if (item.method == 'POST') {
- item.method = '<span class="badge fs-6 bg-warning">' + item.method + '</span>';
- }
- item.data = escapeHtml(item.data);
- });
- } else if (table == 'rllog') {
- $.each(data, function (i, item) {
- if (item.user == null) {
- item.user = "none";
- }
- if (item.rl_hash == null) {
- item.rl_hash = "err";
- }
- item.indicator = '<span style="border-right:6px solid #' + intToRGB(hashCode(item.rl_hash)) + ';padding-left:5px;"> </span>';
- if (item.rl_hash != 'err') {
- item.action = '<a href="#" data-action="delete_selected" data-id="single-hash" data-api-url="delete/rlhash" data-item="' + encodeURI(item.rl_hash) + '" class="btn btn-xs btn-danger"><i class="bi bi-trash"></i> ' + lang.reset_limit + '</a>';
- }
- });
- }
- return data;
- };
- $('.add_log_lines').on('click', function (e) {
- e.preventDefault();
- var log_table= $(this).data("table");
- var new_nrows = $(this).data("nrows");
- var post_process = $(this).data("post-process");
- var log_url = $(this).data("log-url");
- if (log_table === undefined || new_nrows === undefined || post_process === undefined || log_url === undefined) {
- console.log("no data-table or data-nrows or log_url or data-post-process attr found");
- return;
- }
-
- if (table = $('#' + log_table).DataTable()) {
- var heading = $('#' + log_table).closest('.card').find('.card-header');
- var load_rows = (table.data().count() + 1) + '-' + (table.data().count() + new_nrows)
-
- $.get('/api/v1/get/logs/' + log_url + '/' + load_rows).then(function(data){
- if (data.length === undefined) { mailcow_alert_box(lang.no_new_rows, "info"); return; }
- var rows = process_table_data(data, post_process);
- var rows_now = (table.page.len() + data.length);
- $(heading).children('.table-lines').text(rows_now)
- mailcow_alert_box(data.length + lang.additional_rows, "success");
- table.rows.add(rows).draw();
- });
- }
- })
- function hideTableExpandCollapseBtn(tab, table){
- if ($(table).hasClass('collapsed'))
- $(tab).find(".table_collapse_option").show();
- else
- $(tab).find(".table_collapse_option").hide();
- }
-
- // detect element visibility changes
- function onVisible(element, callback) {
- $(document).ready(function() {
- element_object = document.querySelector(element);
- if (element_object === null) return;
-
- new IntersectionObserver((entries, observer) => {
- entries.forEach(entry => {
- if(entry.intersectionRatio > 0) {
- callback(element_object);
- }
- });
- }).observe(element_object);
- });
- }
- // Draw Table if tab is active
- onVisible("[id^=postfix_log]", () => draw_postfix_logs());
- onVisible("[id^=dovecot_log]", () => draw_dovecot_logs());
- onVisible("[id^=sogo_log]", () => draw_sogo_logs());
- onVisible("[id^=watchdog_log]", () => draw_watchdog_logs());
- onVisible("[id^=autodiscover_log]", () => draw_autodiscover_logs());
- onVisible("[id^=acme_log]", () => draw_acme_logs());
- onVisible("[id^=api_log]", () => draw_api_logs());
- onVisible("[id^=rl_log]", () => draw_rl_logs());
- onVisible("[id^=ui_logs]", () => draw_ui_logs());
- onVisible("[id^=sasl_logs]", () => draw_sasl_logs());
- onVisible("[id^=netfilter_log]", () => draw_netfilter_logs());
- onVisible("[id^=rspamd_history]", () => draw_rspamd_history());
- onVisible("[id^=rspamd_donut]", () => rspamd_pie_graph());
-
-
- // start polling host stats if tab is active
- onVisible("[id^=tab-containers]", () => update_stats());
- // start polling container stats if collapse is active
- var containerElements = document.querySelectorAll(".container-details-collapse");
- for (let i = 0; i < containerElements.length; i++){
- new IntersectionObserver((entries, observer) => {
- entries.forEach(entry => {
- if(entry.intersectionRatio > 0) {
-
- if (!containerElements[i].classList.contains("show")){
- var container = containerElements[i].id.replace("Collapse", "");
- var container_id = containerElements[i].getAttribute("data-id");
-
- // check if chart exists or needs to be created
- if (!Chart.getChart(container + "_DiskIOChart"))
- createReadWriteChart(container + "_DiskIOChart", "Read", "Write");
- if (!Chart.getChart(container + "_NetIOChart"))
- createReadWriteChart(container + "_NetIOChart", "Recv", "Sent");
-
- // add container to polling list
- containersToUpdate[container] = {
- id: container_id,
- state: "idle"
- }
-
- // stop polling if collapse is closed
- containerElements[i].addEventListener('hidden.bs.collapse', function () {
- var diskIOCtx = Chart.getChart(container + "_DiskIOChart");
- var netIOCtx = Chart.getChart(container + "_NetIOChart");
-
- diskIOCtx.data.datasets[0].data = [];
- diskIOCtx.data.datasets[1].data = [];
- diskIOCtx.data.labels = [];
- netIOCtx.data.datasets[0].data = [];
- netIOCtx.data.datasets[1].data = [];
- netIOCtx.data.labels = [];
-
- diskIOCtx.update();
- netIOCtx.update();
-
- delete containersToUpdate[container];
- });
- }
-
- }
- });
- }).observe(containerElements[i]);
- }
-});
-
-
-// update system stats - every 5 seconds if system & container tab is active
-function update_stats(timeout=5){
- if (!$('#tab-containers').hasClass('active')) {
- // tab not active - dont fetch stats - run again in n seconds
- return;
- }
-
- window.fetch("/api/v1/get/status/host", {method:'GET',cache:'no-cache'}).then(function(response) {
- return response.json();
- }).then(function(data) {
- console.log(data);
-
- if (data){
- // display table data
- $("#host_date").text(data.system_time);
- $("#host_uptime").text(formatUptime(data.uptime));
- $("#host_cpu_cores").text(data.cpu.cores);
- $("#host_cpu_usage").text(parseInt(data.cpu.usage).toString() + "%");
- $("#host_memory_total").text((data.memory.total / (1024 ** 3)).toFixed(2).toString() + "GB");
- $("#host_memory_usage").text(parseInt(data.memory.usage).toString() + "%");
- if (data.architecture == "aarch64"){
- $("#host_architecture").html('<span data-bs-toggle="tooltip" data-bs-placement="top" title="' + lang_debug.wip +'">' + data.architecture + ' ⚠️</span>');
- }
- else {
- $("#host_architecture").html(data.architecture);
- }
-
- // update cpu and mem chart
- var cpu_chart = Chart.getChart("host_cpu_chart");
- var mem_chart = Chart.getChart("host_mem_chart");
-
- cpu_chart.data.labels.push(data.system_time.split(" ")[1]);
- if (cpu_chart.data.labels.length > 30) cpu_chart.data.labels.shift();
- mem_chart.data.labels.push(data.system_time.split(" ")[1]);
- if (mem_chart.data.labels.length > 30) mem_chart.data.labels.shift();
-
- cpu_chart.data.datasets[0].data.push(data.cpu.usage);
- if (cpu_chart.data.datasets[0].data.length > 30) cpu_chart.data.datasets[0].data.shift();
- mem_chart.data.datasets[0].data.push(data.memory.usage);
- if (mem_chart.data.datasets[0].data.length > 30) mem_chart.data.datasets[0].data.shift();
-
- cpu_chart.update();
- mem_chart.update();
- }
-
- // run again in n seconds
- setTimeout(update_stats, timeout * 1000);
- });
-}
-// update specific container stats - every n (default 5s) seconds
-function update_container_stats(timeout=5){
-
- if ($('#tab-containers').hasClass('active')) {
- for (let container in containersToUpdate){
- container_id = containersToUpdate[container].id;
- // check if container update stats is already running
- if (containersToUpdate[container].state == "running")
- continue;
- containersToUpdate[container].state = "running";
-
-
- window.fetch("/api/v1/get/status/container/" + container_id, {method:'GET',cache:'no-cache'}).then(function(response) {
- return response.json();
- }).then(function(data) {
- var diskIOCtx = Chart.getChart(container + "_DiskIOChart");
- var netIOCtx = Chart.getChart(container + "_NetIOChart");
-
- console.log(container);
- console.log(data);
- prev_stats = null;
- if (data.length >= 2){
- prev_stats = data[data.length -2];
-
- // hide spinners if we collected enough data
- $('#' + container + "_DiskIOChart").removeClass('d-none');
- $('#' + container + "_DiskIOChart").prev().addClass('d-none');
- $('#' + container + "_NetIOChart").removeClass('d-none');
- $('#' + container + "_NetIOChart").prev().addClass('d-none');
- }
-
- data = data[data.length -1];
-
- if (prev_stats != null){
- // calc time diff
- var time_diff = (new Date(data.read) - new Date(prev_stats.read)) / 1000;
-
- // calc disk io b/s
- if ('io_service_bytes_recursive' in prev_stats.blkio_stats && prev_stats.blkio_stats.io_service_bytes_recursive !== null){
- var prev_read_bytes = 0;
- var prev_write_bytes = 0;
- for (var i = 0; i < prev_stats.blkio_stats.io_service_bytes_recursive.length; i++){
- if (prev_stats.blkio_stats.io_service_bytes_recursive[i].op == "read")
- prev_read_bytes = prev_stats.blkio_stats.io_service_bytes_recursive[i].value;
- else if (prev_stats.blkio_stats.io_service_bytes_recursive[i].op == "write")
- prev_write_bytes = prev_stats.blkio_stats.io_service_bytes_recursive[i].value;
- }
- var read_bytes = 0;
- var write_bytes = 0;
- for (var i = 0; i < data.blkio_stats.io_service_bytes_recursive.length; i++){
- if (data.blkio_stats.io_service_bytes_recursive[i].op == "read")
- read_bytes = data.blkio_stats.io_service_bytes_recursive[i].value;
- else if (data.blkio_stats.io_service_bytes_recursive[i].op == "write")
- write_bytes = data.blkio_stats.io_service_bytes_recursive[i].value;
- }
- var diff_bytes_read = (read_bytes - prev_read_bytes) / time_diff;
- var diff_bytes_write = (write_bytes - prev_write_bytes) / time_diff;
- }
-
- // calc net io b/s
- if ('networks' in prev_stats){
- var prev_recv_bytes = 0;
- var prev_sent_bytes = 0;
- for (var key in prev_stats.networks){
- prev_recv_bytes += prev_stats.networks[key].rx_bytes;
- prev_sent_bytes += prev_stats.networks[key].tx_bytes;
- }
- var recv_bytes = 0;
- var sent_bytes = 0;
- for (var key in data.networks){
- recv_bytes += data.networks[key].rx_bytes;
- sent_bytes += data.networks[key].tx_bytes;
- }
- var diff_bytes_recv = (recv_bytes - prev_recv_bytes) / time_diff;
- var diff_bytes_sent = (sent_bytes - prev_sent_bytes) / time_diff;
- }
-
- addReadWriteChart(diskIOCtx, diff_bytes_read, diff_bytes_write, "");
- addReadWriteChart(netIOCtx, diff_bytes_recv, diff_bytes_sent, "");
- }
-
- // run again in n seconds
- containersToUpdate[container].state = "idle";
- }).catch(err => {
- console.log(err);
- });
- }
- }
-
- // run again in n seconds
- setTimeout(update_container_stats, timeout * 1000);
-}
-// format hosts uptime seconds to readable string
-function formatUptime(seconds){
- seconds = Number(seconds);
- var d = Math.floor(seconds / (3600*24));
- var h = Math.floor(seconds % (3600*24) / 3600);
- var m = Math.floor(seconds % 3600 / 60);
- var s = Math.floor(seconds % 60);
-
- var dFormat = d > 0 ? d + "D " : "";
- var hFormat = h > 0 ? h + "H " : "";
- var mFormat = m > 0 ? m + "M " : "";
- var sFormat = s > 0 ? s + "S" : "";
- return dFormat + hFormat + mFormat + sFormat;
-}
-// format bytes to readable string
-function formatBytes(bytes){
- // b
- if (bytes < 1000) return bytes.toFixed(2).toString()+' B/s';
- // b to kb
- bytes = bytes / 1024;
- if (bytes < 1000) return bytes.toFixed(2).toString()+' KB/s';
- // kb to mb
- bytes = bytes / 1024;
- if (bytes < 1000) return bytes.toFixed(2).toString()+' MB/s';
- // final mb to gb
- return (bytes / 1024).toFixed(2).toString()+' GB/s';
-}
-// create read write line chart
-function createReadWriteChart(chart_id, read_lable, write_lable){
- var ctx = document.getElementById(chart_id);
-
- var dataNet = {
- labels: [],
- datasets: [{
- label: read_lable,
- backgroundColor: "rgba(41, 187, 239, 0.3)",
- borderColor: "rgba(41, 187, 239, 0.6)",
- pointRadius: 1,
- pointHitRadius: 6,
- borderWidth: 2,
- fill: true,
- tension: 0.2,
- data: []
- }, {
- label: write_lable,
- backgroundColor: "rgba(239, 60, 41, 0.3)",
- borderColor: "rgba(239, 60, 41, 0.6)",
- pointRadius: 1,
- pointHitRadius: 6,
- borderWidth: 2,
- fill: true,
- tension: 0.2,
- data: []
- }]
- };
- var optionsNet = {
- interaction: {
- mode: 'index'
- },
- scales: {
- yAxis: {
- min: 0,
- grid: {
- display: false
- },
- ticks: {
- callback: function(i, index, ticks) {
- return formatBytes(i);
- }
- }
- },
- xAxis: {
- grid: {
- display: false
- }
- }
- }
- };
-
- return new Chart(ctx, {
- type: 'line',
- data: dataNet,
- options: optionsNet
- });
-}
-// add to read write line chart
-function addReadWriteChart(chart_context, read_point, write_point, time, limit = 30){
- // push time label for x-axis
- chart_context.data.labels.push(time);
- if (chart_context.data.labels.length > limit) chart_context.data.labels.shift();
-
- // push datapoints
- chart_context.data.datasets[0].data.push(read_point);
- chart_context.data.datasets[1].data.push(write_point);
- // shift data if more than 20 entires exists
- if (chart_context.data.datasets[0].data.length > limit) chart_context.data.datasets[0].data.shift();
- if (chart_context.data.datasets[1].data.length > limit) chart_context.data.datasets[1].data.shift();
-
- chart_context.update();
-}
-// create host cpu and mem chart
-function createHostCpuAndMemChart(){
- var cpu_ctx = document.getElementById("host_cpu_chart");
- var mem_ctx = document.getElementById("host_mem_chart");
-
- var dataCpu = {
- labels: [],
- datasets: [{
- label: "CPU %",
- backgroundColor: "rgba(41, 187, 239, 0.3)",
- borderColor: "rgba(41, 187, 239, 0.6)",
- pointRadius: 1,
- pointHitRadius: 6,
- borderWidth: 2,
- fill: true,
- tension: 0.2,
- data: []
- }]
- };
- var optionsCpu = {
- interaction: {
- mode: 'index'
- },
- scales: {
- yAxis: {
- min: 0,
- grid: {
- display: false
- },
- ticks: {
- callback: function(i, index, ticks) {
- return i.toFixed(0).toString() + "%";
- }
- }
- },
- xAxis: {
- grid: {
- display: false
- }
- }
- }
- };
-
- var dataMem = {
- labels: [],
- datasets: [{
- label: "MEM %",
- backgroundColor: "rgba(41, 187, 239, 0.3)",
- borderColor: "rgba(41, 187, 239, 0.6)",
- pointRadius: 1,
- pointHitRadius: 6,
- borderWidth: 2,
- fill: true,
- tension: 0.2,
- data: []
- }]
- };
- var optionsMem = {
- interaction: {
- mode: 'index'
- },
- scales: {
- yAxis: {
- min: 0,
- grid: {
- display: false
- },
- ticks: {
- callback: function(i, index, ticks) {
- return i.toFixed(0).toString() + "%";
- }
- }
- },
- xAxis: {
- grid: {
- display: false
- }
- }
- }
- };
-
-
- var net_io_chart = new Chart(cpu_ctx, {
- type: 'line',
- data: dataCpu,
- options: optionsCpu
- });
- var disk_io_chart = new Chart(mem_ctx, {
- type: 'line',
- data: dataMem,
- options: optionsMem
- });
-}
-// check for mailcow updates
-function check_update(current_version, github_repo_url){
- if (!current_version || !github_repo_url) return false;
-
- var github_account = github_repo_url.split("/")[3];
- var github_repo_name = github_repo_url.split("/")[4];
-
- // get details about latest release
- window.fetch("https://api.github.com/repos/"+github_account+"/"+github_repo_name+"/releases/latest", {method:'GET',cache:'no-cache'}).then(function(response) {
- return response.json();
- }).then(function(latest_data) {
- // get details about current release
- window.fetch("https://api.github.com/repos/"+github_account+"/"+github_repo_name+"/releases/tags/"+current_version, {method:'GET',cache:'no-cache'}).then(function(response) {
- return response.json();
- }).then(function(current_data) {
- // compare releases
- var date_current = new Date(current_data.created_at);
- var date_latest = new Date(latest_data.created_at);
- if (date_latest.getTime() <= date_current.getTime()){
- // no update available
- $("#mailcow_update").removeClass("text-warning text-danger").addClass("text-success");
- $("#mailcow_update").html("<b>" + lang_debug.no_update_available + "</b>");
- } else {
- // update available
- $("#mailcow_update").removeClass("text-danger text-success").addClass("text-warning");
- $("#mailcow_update").html(lang_debug.update_available + ` <a href="#" id="mailcow_update_changelog">`+latest_data.tag_name+`</a>`);
- $("#mailcow_update_changelog").click(function(){
- if (mailcow_cc_role !== "admin" && mailcow_cc_role !== "domainadmin")
- return;
-
- showVersionModal("New Release " + latest_data.tag_name, latest_data.tag_name);
- })
- }
- }).catch(err => {
- // err
- console.log(err);
- $("#mailcow_update").removeClass("text-success text-warning").addClass("text-danger");
- $("#mailcow_update").html("<b>"+ lang_debug.update_failed +"</b>");
- });
- }).catch(err => {
- // err
- console.log(err);
- $("#mailcow_update").removeClass("text-success text-warning").addClass("text-danger");
- $("#mailcow_update").html("<b>"+ lang_debug.update_failed +"</b>");
- });
-}
-// show version changelog modal
-function showVersionModal(title, version){
- $.ajax({
- type: 'GET',
- url: 'https://api.github.com/repos/' + mailcow_info.project_owner + '/' + mailcow_info.project_repo + '/releases/tags/' + version,
- dataType: 'json',
- success: function (data) {
- var md = window.markdownit();
- var result = md.render(data.body);
- result = parseGithubMarkdownLinks(result);
-
- $('#showVersionModal').find(".modal-title").html(title);
- $('#showVersionModal').find(".modal-body").html(`
- <h3>` + data.name + `</h3>
- <span class="mt-4">` + result + `</span>
- <span><b>Github Link:</b>
- <a target="_blank" href="https://github.com/` + mailcow_info.project_owner + `/` + mailcow_info.project_repo + `/releases/tag/` + version + `">` + version + `</a>
- </span>
- `);
-
- new bootstrap.Modal(document.getElementById("showVersionModal"), {
- backdrop: 'static',
- keyboard: false
- }).show();
- }
- });
-}
-function parseGithubMarkdownLinks(inputText) {
- var replacedText, replacePattern1;
-
- replacePattern1 = /(\b(https?):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])(?![^<]*>)/gim;
- replacedText = inputText.replace(replacePattern1, (matched, index, original, input_string) => {
- if (matched.includes('github.com')){
- // return short link if it's github link
- last_uri_path = matched.split('/');
- last_uri_path = last_uri_path[last_uri_path.length - 1];
-
- // adjust Full Changelog link to match last git version and new git version, if link is a compare link
- if (matched.includes('/compare/') && mailcow_info.last_version_tag !== ''){
- matched = matched.replace(last_uri_path, mailcow_info.last_version_tag + '...' + mailcow_info.version_tag);
- last_uri_path = mailcow_info.last_version_tag + '...' + mailcow_info.version_tag;
- }
-
- return '<a href="' + matched + '" target="_blank">' + last_uri_path + '</a><br>';
- };
-
- // if it's not a github link, return complete link
- return '<a href="' + matched + '" target="_blank">' + matched + '</a>';
- });
-
- return replacedText;
-}
-
-function convertTimestampToLocalFormat(timestamp) {
- var date = new Date(timestamp ? timestamp * 1000 : 0);
- return date.toLocaleDateString(LOCALE, DATETIME_FORMAT);
-}
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/edit.js b/mailcow/src/mailcow-dockerized/data/web/js/site/edit.js
index d689549..308ec8c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/edit.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/edit.js
@@ -58,10 +58,14 @@
$('input[name=multiple_bookings]').val($("#multiple_bookings_custom").val());
});
+ $("#show_mailbox_rename_form").click(function() {
+ $("#rename_warning").hide();
+ $("#rename_form").removeClass("d-none");
+ });
+
// load tags
if ($('#tags').length){
var tagsEl = $('#tags').parent().find('.tag-values')[0];
- console.log($(tagsEl).val())
var tags = JSON.parse($(tagsEl).val());
$(tagsEl).val("");
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/index.js b/mailcow/src/mailcow-dockerized/data/web/js/site/index.js
index 4c812a3..29b72f0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/index.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/index.js
@@ -1,5 +1,6 @@
$(document).ready(function() {
- var theme = localStorage.getItem("theme");
- localStorage.clear();
- localStorage.setItem("theme", theme);
+ var theme = localStorage.getItem("mailcow_theme");
+ if (theme !== null) {
+ localStorage.setItem("mailcow_theme", theme);
+ }
});
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/mailbox.js b/mailcow/src/mailcow-dockerized/data/web/js/site/mailbox.js
index e2016e3..5ad5cce 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/mailbox.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/mailbox.js
@@ -179,9 +179,8 @@
// Get script_data textarea content from form the button was clicked in
var script = $('textarea[name="script_data"]', $(this).parents('form:first')).val();
$.ajax({
- dataType: 'json',
url: "/inc/ajax/sieve_validation.php",
- type: "get",
+ type: "post",
data: { script: script },
complete: function(data) {
var response = (data.responseText);
@@ -270,6 +269,24 @@
function setMailboxTemplateData(template){
$("#addInputQuota").val(template.quota / 1048576);
+ if (template.tagged_mail_handler === "subfolder"){
+ $('#tagged_mail_handler_subfolder').prop('checked', true);
+ $('#tagged_mail_handler_subject').prop('checked', false);
+ $('#tagged_mail_handler_none').prop('checked', false);
+ } else if(template.tagged_mail_handler === "subject"){
+ $('#tagged_mail_handler_subfolder').prop('checked', false);
+ $('#tagged_mail_handler_subject').prop('checked', true);
+ $('#tagged_mail_handler_none').prop('checked', false);
+ } else if(template.tagged_mail_handler === "none"){
+ $('#tagged_mail_handler_subfolder').prop('checked', false);
+ $('#tagged_mail_handler_subject').prop('checked', false);
+ $('#tagged_mail_handler_none').prop('checked', true);
+ } else {
+ $('#tagged_mail_handler_subfolder').prop('checked', false);
+ $('#tagged_mail_handler_subject').prop('checked', false);
+ $('#tagged_mail_handler_none').prop('checked', true);
+ }
+
if (template.quarantine_notification === "never"){
$('#quarantine_notification_never').prop('checked', true);
$('#quarantine_notification_hourly').prop('checked', false);
@@ -335,6 +352,12 @@
if (template.sieve_access == 1){
protocol_access.push("sieve");
}
+ if (template.eas_access == 1){
+ protocol_access.push("eas");
+ }
+ if (template.dav_access == 1){
+ protocol_access.push("dav");
+ }
$('#protocol_access').selectpicker('val', protocol_access);
var acl = [];
@@ -380,6 +403,9 @@
if (template.acl_app_passwds == 1){
acl.push("app_passwds");
}
+ if (template.acl_pw_reset == 1){
+ acl.push("pw_reset");
+ }
$('#user_acl').selectpicker('val', acl);
$('#rl_value').val(template.rl_value);
@@ -387,7 +413,6 @@
$('#rl_frame').selectpicker('val', template.rl_frame);
}
- console.log(template.active)
if (template.active){
$('#mbox_active').selectpicker('val', template.active.toString());
} else {
@@ -399,6 +424,11 @@
} else {
$('#force_pw_update').prop('checked', false);
}
+ if (template.force_tfa == 1){
+ $('#force_tfa').prop('checked', true);
+ } else {
+ $('#force_tfa').prop('checked', false);
+ }
if (template.sogo_access == 1){
$('#sogo_access').prop('checked', true);
} else {
@@ -446,8 +476,13 @@
hideTableExpandCollapseBtn('#tab-domains', '#domain_table');
},
ajax: {
- type: "GET",
- url: "/api/v1/get/domain/datatables",
+ type: "POST",
+ url: "/api/v1/search/domain",
+ contentType: "application/json",
+ processData: false,
+ data: function(d) {
+ return JSON.stringify(d);
+ },
dataSrc: function(json){
$.each(json.data, function(i, item) {
item.domain_name = escapeHtml(item.domain_name);
@@ -690,8 +725,8 @@
} else if (item.attributes.rl_frame === "d"){
item.attributes.rl_frame = lang_rl.day;
}
- item.attributes.rl_value = escapeHtml(item.attributes.rl_value);
-
+ item.attributes.rl_value = (!item.attributes.rl_value) ? "∞" : escapeHtml(item.attributes.rl_value);
+ item.attributes.ratelimit = item.attributes.rl_value + " " + item.attributes.rl_frame;
if (item.template.toLowerCase() == "default"){
item.action = '<div class="btn-group">' +
@@ -815,14 +850,8 @@
}
},
{
- title: 'rl_frame',
- data: 'attributes.rl_frame',
- defaultContent: '',
- class: 'none',
- },
- {
- title: 'rl_value',
- data: 'attributes.rl_value',
+ title: lang_edit.ratelimit,
+ data: 'attributes.ratelimit',
defaultContent: '',
class: 'none',
},
@@ -879,8 +908,13 @@
hideTableExpandCollapseBtn('#tab-mailboxes', '#mailbox_table');
},
ajax: {
- type: "GET",
- url: "/api/v1/get/mailbox/datatables",
+ type: "POST",
+ url: "/api/v1/search/mailbox",
+ contentType: "application/json",
+ processData: false,
+ data: function(d) {
+ return JSON.stringify(d);
+ },
dataSrc: function(json){
$.each(json.data, function (i, item) {
item.quota = {
@@ -891,7 +925,10 @@
item.quota.value = humanFileSize(item.quota_used) + "/" + item.quota.value;
item.max_quota_for_mbox = humanFileSize(item.max_quota_for_mbox);
- item.last_mail_login = item.last_imap_login + '/' + item.last_pop3_login + '/' + item.last_smtp_login;
+ item.last_mail_login = (item.attributes.imap_access == 1 ? '<div class="text-start badge bg-info mb-2" style="min-width: 70px;">IMAP @ ' + unix_time_format(Number(item.last_imap_login)) + '</div><br>' : '') +
+ (item.attributes.pop3_access == 1 ? '<div class="text-start badge bg-info mb-2" style="min-width: 70px;">POP3 @ ' + unix_time_format(Number(item.last_pop3_login)) + '</div><br>' : '') +
+ (item.attributes.smtp_access == 1 ? '<div class="text-start badge bg-info mb-2" style="min-width: 70px;">SMTP @ ' + unix_time_format(Number(item.last_smtp_login)) + '</div><br>' : '') +
+ '<div class="text-start badge bg-info" style="min-width: 70px;">SSO @ ' + unix_time_format(Number(item.last_sso_login)) + '</div>';
/*
if (!item.rl) {
item.rl = '∞';
@@ -917,6 +954,8 @@
item.imap_access = '<i class="text-' + (item.attributes.imap_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.imap_access == 1 ? 'check-lg' : 'x-lg') + '"></i>';
item.smtp_access = '<i class="text-' + (item.attributes.smtp_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.smtp_access == 1 ? 'check-lg' : 'x-lg') + '"></i>';
item.sieve_access = '<i class="text-' + (item.attributes.sieve_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.sieve_access == 1 ? 'check-lg' : 'x-lg') + '"></i>';
+ item.eas_access = '<i class="text-' + (item.attributes.eas_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.eas_access == 1 ? 'check-lg' : 'x-lg') + '"></i>';
+ item.dav_access = '<i class="text-' + (item.attributes.dav_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.dav_access == 1 ? 'check-lg' : 'x-lg') + '"></i>';
if (item.attributes.quarantine_notification === 'never') {
item.quarantine_notification = lang.never;
} else if (item.attributes.quarantine_notification === 'hourly') {
@@ -940,7 +979,7 @@
'<a href="#" data-action="delete_selected" data-id="single-mailbox" data-api-url="delete/mailbox" data-item="' + encodeURIComponent(item.username) + '" class="btn btn-sm btn-xs-lg btn-xs-half btn-danger"><i class="bi bi-trash"></i> ' + lang.remove + '</a>' +
'<a href="/index.php?duallogin=' + encodeURIComponent(item.username) + '" class="login_as btn btn-sm btn-xs-lg btn-xs-half btn-success"><i class="bi bi-person-fill"></i> Login</a>';
if (ALLOW_ADMIN_EMAIL_LOGIN) {
- item.action += '<a href="/sogo-auth.php?login=' + encodeURIComponent(item.username) + '" class="login_as btn btn-sm btn-xs-lg btn-xs-half btn-primary" target="_blank"><i class="bi bi-envelope-fill"></i> SOGo</a>';
+ item.action += '<a href="/sogo-auth.php?login=' + encodeURIComponent(item.username) + '" class="login_as btn btn-sm btn-xs-lg btn-xs-half btn-primary"><i class="bi bi-envelope-fill"></i> SOGo</a>';
}
item.action += '</div>';
}
@@ -957,6 +996,7 @@
'style="min-width:2em;width:' + item.percent_in_use + '%">' + item.percent_in_use + '%' + '</div></div>'
};
item.username = escapeHtml(item.username);
+ item.name = escapeHtml(item.name);
if (Array.isArray(item.tags)){
var tags = '';
@@ -1007,13 +1047,7 @@
data: 'last_mail_login',
searchable: false,
defaultContent: '',
- responsivePriority: 7,
- render: function (data, type) {
- res = data.split("/");
- return '<div class="badge bg-info mb-2">IMAP @ ' + unix_time_format(Number(res[0])) + '</div><br>' +
- '<div class="badge bg-info mb-2">POP3 @ ' + unix_time_format(Number(res[1])) + '</div><br>' +
- '<div class="badge bg-info">SMTP @ ' + unix_time_format(Number(res[2])) + '</div>';
- }
+ responsivePriority: 7
},
{
title: lang.last_pw_change,
@@ -1039,7 +1073,16 @@
title: lang.domain,
data: 'domain',
defaultContent: '',
- className: 'none'
+ className: 'none',
+ },
+ {
+ title: lang.iam,
+ data: 'authsource',
+ defaultContent: '',
+ className: 'none',
+ render: function (data, type) {
+ return '<span class="badge bg-primary">' + data + '<i class="ms-2 bi bi-person-circle"></i></i></span>';
+ }
},
{
title: lang.tls_enforce_in,
@@ -1078,6 +1121,18 @@
className: 'none'
},
{
+ title: 'EAS',
+ data: 'eas_access',
+ defaultContent: '',
+ className: 'none'
+ },
+ {
+ title: 'DAV',
+ data: 'dav_access',
+ defaultContent: '',
+ className: 'none'
+ },
+ {
title: lang.quarantine_notification,
data: 'quarantine_notification',
defaultContent: '',
@@ -1179,7 +1234,8 @@
} else if (item.attributes.rl_frame === "d"){
item.attributes.rl_frame = lang_rl.day;
}
- item.attributes.rl_value = escapeHtml(item.attributes.rl_value);
+ item.attributes.rl_value = (!item.attributes.rl_value) ? "∞" : escapeHtml(item.attributes.rl_value);
+ item.attributes.ratelimit = item.attributes.rl_value + " " + item.attributes.rl_frame;
item.attributes.quota = humanFileSize(item.attributes.quota);
@@ -1189,7 +1245,10 @@
item.attributes.imap_access = '<i class="text-' + (item.attributes.imap_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.imap_access == 1 ? 'check-lg' : 'x-lg') + '"><span class="sorting-value">' + (item.attributes.imap_access == 1 ? '1' : '0') + '</span></i>';
item.attributes.smtp_access = '<i class="text-' + (item.attributes.smtp_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.smtp_access == 1 ? 'check-lg' : 'x-lg') + '"><span class="sorting-value">' + (item.attributes.smtp_access == 1 ? '1' : '0') + '</span></i>';
item.attributes.sieve_access = '<i class="text-' + (item.attributes.sieve_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.sieve_access == 1 ? 'check-lg' : 'x-lg') + '"><span class="sorting-value">' + (item.attributes.sieve_access == 1 ? '1' : '0') + '</span></i>';
+ item.attributes.eas_access = '<i class="text-' + (item.attributes.eas_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.eas_access == 1 ? 'check-lg' : 'x-lg') + '"><span class="sorting-value">' + (item.attributes.eas_access == 1 ? '1' : '0') + '</span></i>';
+ item.attributes.dav_access = '<i class="text-' + (item.attributes.dav_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.dav_access == 1 ? 'check-lg' : 'x-lg') + '"><span class="sorting-value">' + (item.attributes.dav_access == 1 ? '1' : '0') + '</span></i>';
item.attributes.sogo_access = '<i class="text-' + (item.attributes.sogo_access == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.sogo_access == 1 ? 'check-lg' : 'x-lg') + '"><span class="sorting-value">' + (item.attributes.sogo_access == 1 ? '1' : '0') + '</span></i>';
+ item.attributes.force_tfa = '<i class="text-' + (item.attributes.force_tfa == 1 ? 'success' : 'danger') + ' bi bi-' + (item.attributes.force_tfa == 1 ? 'check-lg' : 'x-lg') + '"><span class="sorting-value">' + (item.attributes.force_tfa == 1 ? '1' : '0') + '</span></i>';
if (item.attributes.quarantine_notification === 'never') {
item.attributes.quarantine_notification = lang.never;
} else if (item.attributes.quarantine_notification === 'hourly') {
@@ -1298,6 +1357,16 @@
defaultContent: '',
},
{
+ title: 'EAS',
+ data: 'attributes.eas_access',
+ defaultContent: '',
+ },
+ {
+ title: 'DAV',
+ data: 'attributes.dav_access',
+ defaultContent: '',
+ },
+ {
title: 'SOGO',
data: 'attributes.sogo_access',
defaultContent: '',
@@ -1324,14 +1393,13 @@
}
},
{
- title: "rl_frame",
- data: 'attributes.rl_frame',
- defaultContent: '',
- class: 'none',
+ title: lang.force_tfa,
+ data: 'attributes.force_tfa',
+ defaultContent: ''
},
{
- title: 'rl_value',
- data: 'attributes.rl_value',
+ title: lang_edit.ratelimit,
+ data: 'attributes.ratelimit',
defaultContent: '',
class: 'none',
},
@@ -1936,11 +2004,6 @@
responsivePriority: 5,
},
{
- title: lang.bcc_destinations,
- data: 'bcc_dest',
- defaultContent: ''
- },
- {
title: lang.sogo_visible,
data: 'sogo_visible',
defaultContent: '',
@@ -1959,6 +2022,15 @@
defaultContent: ''
},
{
+ title: lang.internal,
+ data: 'internal',
+ defaultContent: '',
+ responsivePriority: 6,
+ render: function (data, type) {
+ return 1==data?'<i class="bi bi-check-lg"><span class="sorting-value">1</span></i>':0==data&&'<i class="bi bi-x-lg"><span class="sorting-value">0</span></i>';
+ }
+ },
+ {
title: lang.active,
data: 'active',
defaultContent: '',
@@ -2351,7 +2423,7 @@
else
$(tab).find(".table_collapse_option").hide();
}
-
+
function filterByDomain(json, column, table){
var tableId = $(table.table().container()).attr('id');
// Create the `select` element
@@ -2374,12 +2446,12 @@
}
});
});
-
+
// get unique domain list
domains = domains.filter(function(value, index, array) {
return array.indexOf(value) === index;
});
-
+
// add domains to select
domains.forEach(function(domain) {
select.append($('<option>' + domain + '</option>'));
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/quarantine.js b/mailcow/src/mailcow-dockerized/data/web/js/site/quarantine.js
index fbf4fe8..a9b7845 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/quarantine.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/quarantine.js
@@ -102,18 +102,21 @@
{
title: 'ID',
data: 'id',
- defaultContent: ''
+ defaultContent: '',
+ render: $.fn.dataTable.render.text()
},
{
title: lang.qid,
data: 'qid',
- defaultContent: ''
+ defaultContent: '',
+ render: $.fn.dataTable.render.text()
},
{
title: lang.sender,
data: 'sender',
className: 'senders-mw220',
- defaultContent: ''
+ defaultContent: '',
+ render: $.fn.dataTable.render.text()
},
{
title: lang.subj,
@@ -128,7 +131,8 @@
{
title: lang.rcpt,
data: 'rcpt',
- defaultContent: ''
+ defaultContent: '',
+ render: $.fn.dataTable.render.text()
},
{
title: lang.danger,
@@ -226,18 +230,18 @@
}
if (typeof data.fuzzy_hashes === 'object' && data.fuzzy_hashes !== null && data.fuzzy_hashes.length !== 0) {
$.each(data.fuzzy_hashes, function (index, value) {
- $('#qid_detail_fuzzy').append('<p style="font-family:monospace">' + value + '</p>');
+ $('#qid_detail_fuzzy').append('<p style="font-family:monospace">' + escapeHtml(value) + '</p>');
});
} else {
$('#qid_detail_fuzzy').append('-');
}
if (typeof data.score !== 'undefined' && typeof data.action !== 'undefined') {
if (data.action == "add header") {
- $('#qid_detail_score').append('<span class="label-rspamd-action badge fs-6 bg-warning"><b>' + data.score + '</b> - ' + lang.junk_folder + '</span>');
+ $('#qid_detail_score').append('<span class="label-rspamd-action badge fs-6 bg-warning"><b>' + escapeHtml(data.score) + '</b> - ' + lang.junk_folder + '</span>');
} else if (data.action == "reject") {
- $('#qid_detail_score').append('<span class="label-rspamd-action badge fs-6 bg-danger"><b>' + data.score + '</b> - ' + lang.rejected + '</span>');
+ $('#qid_detail_score').append('<span class="label-rspamd-action badge fs-6 bg-danger"><b>' + escapeHtml(data.score) + '</b> - ' + lang.rejected + '</span>');
} else if (data.action == "rewrite subject") {
- $('#qid_detail_score').append('<span class="label-rspamd-action badge fs-6 bg-warning"><b>' + data.score + '</b> - ' + lang.rewrite_subject + '</span>');
+ $('#qid_detail_score').append('<span class="label-rspamd-action badge fs-6 bg-warning"><b>' + escapeHtml(data.score) + '</b> - ' + lang.rewrite_subject + '</span>');
}
}
if (typeof data.recipients !== 'undefined') {
@@ -254,8 +258,8 @@
qAtts.text('');
$.each(data.attachments, function(index, value) {
qAtts.append(
- '<p><a href="/inc/ajax/qitem_details.php?id=' + qitem + '&att=' + index + '" target="_blank">' + value[0] + '</a> (' + value[1] + ')' +
- ' - <small><a href="' + value[3] + '" target="_blank">' + lang.check_hash + '</a></small></p>'
+ '<p><a href="/inc/ajax/qitem_details.php?id=' + escapeHtml(qitem) + '&att=' + index + '" target="_blank">' + escapeHtml(value[0]) + '</a> (' + escapeHtml(value[1]) + ')' +
+ ' - <small><a href="' + escapeHtml(value[3]) + '" target="_blank">' + lang.check_hash + '</a></small></p>'
);
});
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/queue.js b/mailcow/src/mailcow-dockerized/data/web/js/site/queue.js
index 26c1509..9adc79b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/queue.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/queue.js
@@ -48,13 +48,13 @@
url: "/api/v1/get/mailq/all",
dataSrc: function(data){
$.each(data, function (i, item) {
- item.chkbox = '<input type="checkbox" class="form-check-input" data-id="mailqitems" name="multi_select" value="' + item.queue_id + '" />';
+ item.chkbox = '<input type="checkbox" class="form-check-input" data-id="mailqitems" name="multi_select" value="' + escapeHtml(item.queue_id) + '" />';
rcpts = $.map(item.recipients, function(i) {
return escapeHtml(i);
});
item.recipients = rcpts.join('<hr style="margin:1px!important">');
item.action = '<div class="btn-group">' +
- '<a href="#" data-bs-toggle="modal" data-bs-target="#showQueuedMsg" data-queue-id="' + encodeURI(item.queue_id) + '" class="btn btn-xs btn-secondary">' + lang.show_message + '</a>' +
+ '<a href="#" data-bs-toggle="modal" data-bs-target="#showQueuedMsg" data-queue-id="' + escapeHtml(item.queue_id) + '" class="btn btn-xs btn-secondary">' + lang.show_message + '</a>' +
'</div>';
});
return data;
@@ -79,12 +79,14 @@
{
title: 'QID',
data: 'queue_id',
- defaultContent: ''
+ defaultContent: '',
+ render: $.fn.dataTable.render.text()
},
{
title: 'Queue',
data: 'queue_name',
- defaultContent: ''
+ defaultContent: '',
+ render: $.fn.dataTable.render.text()
},
{
title: lang_admin.arrival_time,
@@ -106,7 +108,8 @@
{
title: lang_admin.sender,
data: 'sender',
- defaultContent: ''
+ defaultContent: '',
+ render: $.fn.dataTable.render.text()
},
{
title: lang_admin.recipients,
diff --git a/mailcow/src/mailcow-dockerized/data/web/js/site/user.js b/mailcow/src/mailcow-dockerized/data/web/js/site/user.js
index 088321c..288e7ab 100644
--- a/mailcow/src/mailcow-dockerized/data/web/js/site/user.js
+++ b/mailcow/src/mailcow-dockerized/data/web/js/site/user.js
@@ -77,11 +77,11 @@
acl_data = JSON.parse(acl);
$('.clear-last-logins').on('click', function () {if (confirm(lang.delete_ays)) {last_logins('reset');}})
- $(".login-history").on('click', function(e) {e.preventDefault(); last_logins('get', $(this).data('days'));$(this).addClass('active').siblings().removeClass('active');});
+ $(".login-history").on('click', function(e) {e.preventDefault(); last_logins('get', $(this).data('days'));$(this).parent().find('li a').removeClass('active');$(this).children(':first-child').addClass('active')});
function last_logins(action, days = 7) {
if (action == 'get') {
- $('.last-login').html('<i class="bi bi-hourglass"></i>' + lang.waiting);
+ $('#spinner-last-login').removeClass('d-none');
$.ajax({
dataType: 'json',
url: '/api/v1/get/last-login/' + encodeURIComponent(mailcow_cc_username) + '/' + days,
@@ -90,26 +90,31 @@
console.log('error reading last logins');
},
success: function (data) {
- $('.last-login').html();
- if (data.ui.time) {
- $('.last-login').html('<i class="bi bi-person-fill"></i> ' + lang.last_ui_login + ': ' + unix_time_format(data.ui.time));
- } else {
- $('.last-login').text(lang.no_last_login);
- }
+ $('.last-sasl-login').html('');
if (data.sasl) {
- $('.last-login').append('<ul class="list-group">');
+ $('.last-sasl-login').append('<ul class="list-group">');
$.each(data.sasl, function (i, item) {
var datetime = new Date(item.datetime.replace(/-/g, "/"));
var local_datetime = datetime.toLocaleDateString(undefined, {year: "numeric", month: "2-digit", day: "2-digit", hour: "2-digit", minute: "2-digit", second: "2-digit"});
- var service = '<div class="badge fs-6 bg-secondary">' + item.service.toUpperCase() + '</div>';
- var app_password = item.app_password ? ' <a href="/edit/app-passwd/' + item.app_password + '"><i class="bi bi-app-indicator"></i> ' + escapeHtml(item.app_password_name || "App") + '</a>' : '';
- var real_rip = item.real_rip.startsWith("Web") ? item.real_rip : '<a href="https://bgp.he.net/ip/' + item.real_rip + '" target="_blank">' + item.real_rip + "</a>";
- var ip_location = item.location ? ' <span class="flag-icon flag-icon-' + item.location.toLowerCase() + '"></span>' : '';
+ var service = '<div class="badge bg-secondary">' + item.service.toUpperCase() + '</div>';
+ var app_password = item.app_password ? ' <a href="/edit/app-passwd/' + item.app_password + '"><i class="bi bi-key-fill"></i><span class="ms-1">' + escapeHtml(item.app_password_name || "App") + '</span></a>' : '';
+ var real_rip = item.real_rip.startsWith("Web") ? escapeHtml(item.real_rip) : '<a href="https://bgp.tools/prefix/' + escapeHtml(item.real_rip) + '" target="_blank">' + escapeHtml(item.real_rip) + "</a>";
+ var ip_location = item.location ? ' <span class="flag-icon flag-icon-' + escapeHtml(item.location.toLowerCase()) + '"></span>' : '';
var ip_data = real_rip + ip_location + app_password;
- $(".last-login").append('<li class="list-group-item">' + local_datetime + " " + service + " " + lang.from + " " + ip_data + "</li>");
+
+ $(".last-sasl-login").append(`
+ <li class="list-group-item d-flex justify-content-between align-items-start">
+ <div class="ms-2 me-auto d-flex flex-column">
+ <div class="fw-bold">` + ip_location + real_rip + `</div>
+ <small class="fst-italic mt-2">` + service + ` ` + local_datetime + `</small>` + app_password + `
+ </div>
+ </li>
+ `);
})
- $('.last-login').append('</ul>');
+ $('.last-sasl-login').append('</ul>');
}
+
+ $('#spinner-last-login').addClass('d-none');
}
})
} else if (action == 'reset') {
@@ -163,7 +168,6 @@
type: "GET",
url: "/api/v1/get/time_limited_aliases",
dataSrc: function(data){
- console.log(data);
$.each(data, function (i, item) {
if (acl_data.spam_alias === 1) {
item.action = '<div class="btn-group">' +
@@ -171,6 +175,10 @@
'</div>';
item.chkbox = '<input type="checkbox" class="form-check-input" data-id="tla" name="multi_select" value="' + encodeURIComponent(item.address) + '" />';
item.address = escapeHtml(item.address);
+ item.validity = {
+ value: item.validity,
+ permanent: item.permanent
+ };
}
else {
item.chkbox = '<input type="checkbox" class="form-check-input" disabled />';
@@ -203,12 +211,32 @@
defaultContent: ''
},
{
+ title: lang.description,
+ data: 'description',
+ defaultContent: '',
+ render: function (data, type) {
+ return escapeHtml(data);
+ }
+ },
+ {
title: lang.alias_valid_until,
data: 'validity',
defaultContent: '',
- createdCell: function(td, cellData) {
- createSortableDate(td, cellData)
- }
+ render: function (data, type) {
+ var date = new Date(data.value ? data.value * 1000 : 0);
+ switch (type) {
+ case "sort":
+ if (data.permanent) {
+ return 0;
+ }
+ return date.getTime();
+ default:
+ if (data.permanent) {
+ return lang.forever;
+ }
+ return date.toLocaleDateString(LOCALE, DATETIME_FORMAT);
+ }
+ },
},
{
title: lang.created_on,
@@ -248,7 +276,6 @@
type: "GET",
url: '/api/v1/get/syncjobs/' + encodeURIComponent(mailcow_cc_username) + '/no_log',
dataSrc: function(data){
- console.log(data);
$.each(data, function (i, item) {
item.user1 = escapeHtml(item.user1);
item.log = '<a href="#syncjobLogModal" data-bs-toggle="modal" data-syncjob-id="' + item.id + '">' + lang.open_logs + '</a>'
@@ -404,7 +431,6 @@
type: "GET",
url: '/api/v1/get/app-passwd/all',
dataSrc: function(data){
- console.log(data);
$.each(data, function (i, item) {
item.name = escapeHtml(item.name)
item.protocols = []
@@ -500,7 +526,6 @@
type: "GET",
url: '/api/v1/get/policy_wl_mailbox',
dataSrc: function(data){
- console.log(data);
$.each(data, function (i, item) {
if (validateEmail(item.object)) {
item.chkbox = '<input type="checkbox" class="form-check-input" data-id="policy_wl_mailbox" name="multi_select" value="' + item.prefid + '" />';
@@ -571,7 +596,6 @@
type: "GET",
url: '/api/v1/get/policy_bl_mailbox',
dataSrc: function(data){
- console.log(data);
$.each(data, function (i, item) {
if (validateEmail(item.object)) {
item.chkbox = '<input type="checkbox" class="form-check-input" data-id="policy_bl_mailbox" name="multi_select" value="' + item.prefid + '" />';
@@ -676,5 +700,5 @@
onVisible("[id^=wl_policy_mailbox_table]", () => draw_wl_policy_mailbox_table());
onVisible("[id^=sync_job_table]", () => draw_sync_job_table());
onVisible("[id^=app_passwd_table]", () => draw_app_passwd_table());
- last_logins('get');
+ onVisible("[id^=recent-logins]", () => last_logins('get'));
});
diff --git a/mailcow/src/mailcow-dockerized/data/web/json_api.php b/mailcow/src/mailcow-dockerized/data/web/json_api.php
index 28f8cac..fc34b25 100644
--- a/mailcow/src/mailcow-dockerized/data/web/json_api.php
+++ b/mailcow/src/mailcow-dockerized/data/web/json_api.php
@@ -47,6 +47,12 @@
}
}
+// Block requests not intended for direct API use by checking the 'Sec-Fetch-Dest' header.
+if (isset($_SERVER['HTTP_SEC_FETCH_DEST']) && $_SERVER['HTTP_SEC_FETCH_DEST'] !== 'empty') {
+ header('HTTP/1.1 403 Forbidden');
+ exit;
+}
+
if (isset($_GET['query'])) {
$query = explode('/', $_GET['query']);
@@ -85,6 +91,11 @@
if ($action == 'delete') {
$_POST['items'] = $request;
}
+
+ // search
+ if ($action == 'search') {
+ // placeholder for search, as the request body is already decoded and available in $requestDecoded
+ }
}
api_log($_POST);
@@ -163,6 +174,8 @@
exit;
}
fido2(array("action" => "register", "registration" => $data));
+ // Release pending_tfa_setup session hold
+ unset($_SESSION['pending_tfa_setup']);
$return = new stdClass();
$return->success = true;
echo json_encode($return);
@@ -318,6 +331,9 @@
case "app-passwd":
process_add_return(app_passwd('add', $attr));
break;
+ case "mta-sts":
+ process_add_return(mailbox('add', 'mta_sts', $attr));
+ break;
// return no route found if no case is matched
default:
http_response_code(404);
@@ -328,81 +344,6 @@
exit();
}
break;
- case "process":
- // only allow POST requests to process API endpoints
- if ($_SERVER['REQUEST_METHOD'] != 'POST') {
- http_response_code(405);
- echo json_encode(array(
- 'type' => 'error',
- 'msg' => 'only POST method is allowed'
- ));
- exit();
- }
- switch ($category) {
- case "fido2-args":
- header('Content-Type: application/json');
- $post = trim(file_get_contents('php://input'));
- if ($post) {
- $post = json_decode($post);
- }
- $clientDataJSON = base64_decode($post->clientDataJSON);
- $authenticatorData = base64_decode($post->authenticatorData);
- $signature = base64_decode($post->signature);
- $id = base64_decode($post->id);
- $challenge = $_SESSION['challenge'];
- $process_fido2 = fido2(array("action" => "get_by_b64cid", "cid" => $post->id));
- if ($process_fido2['pub_key'] === false) {
- $return = new stdClass();
- $return->success = false;
- echo json_encode($return);
- exit;
- }
- try {
- $WebAuthn->processGet($clientDataJSON, $authenticatorData, $signature, $process_fido2['pub_key'], $challenge, null, $GLOBALS['FIDO2_UV_FLAG_LOGIN'], $GLOBALS['FIDO2_USER_PRESENT_FLAG']);
- }
- catch (Throwable $ex) {
- unset($process_fido2);
- $return = new stdClass();
- $return->success = false;
- echo json_encode($return);
- exit;
- }
- $return = new stdClass();
- $return->success = true;
- $stmt = $pdo->prepare("SELECT `superadmin` FROM `admin` WHERE `username` = :username");
- $stmt->execute(array(':username' => $process_fido2['username']));
- $obj_props = $stmt->fetch(PDO::FETCH_ASSOC);
- if ($obj_props['superadmin'] === 1) {
- $_SESSION["mailcow_cc_role"] = "admin";
- }
- elseif ($obj_props['superadmin'] === 0) {
- $_SESSION["mailcow_cc_role"] = "domainadmin";
- }
- else {
- $stmt = $pdo->prepare("SELECT `username` FROM `mailbox` WHERE `username` = :username");
- $stmt->execute(array(':username' => $process_fido2['username']));
- $row = $stmt->fetch(PDO::FETCH_ASSOC);
- if ($row['username'] == $process_fido2['username']) {
- $_SESSION["mailcow_cc_role"] = "user";
- }
- }
- if (empty($_SESSION["mailcow_cc_role"])) {
- session_unset();
- session_destroy();
- exit;
- }
- $_SESSION["mailcow_cc_username"] = $process_fido2['username'];
- $_SESSION["fido2_cid"] = $process_fido2['cid'];
- unset($_SESSION["challenge"]);
- $_SESSION['return'][] = array(
- 'type' => 'success',
- 'log' => array("fido2_login"),
- 'msg' => array('logged_in_as', $process_fido2['username'])
- );
- echo json_encode($return);
- break;
- }
- break;
case "get":
function process_get_return($data, $object = true) {
if ($object === true) {
@@ -503,16 +444,6 @@
print(json_encode($getArgs));
$_SESSION['challenge'] = $WebAuthn->getChallenge();
return;
- break;
- case "fail2ban":
- if (!isset($_SESSION['mailcow_cc_role'])){
- switch ($object) {
- case 'banlist':
- header('Content-Type: text/plain');
- echo fail2ban('banlist', 'get', $extra);
- break;
- }
- }
break;
}
if (isset($_SESSION['mailcow_cc_role'])) {
@@ -533,47 +464,6 @@
case "domain":
switch ($object) {
- case "datatables":
- $table = ['domain', 'd'];
- $primaryKey = 'domain';
- $columns = [
- ['db' => 'domain', 'dt' => 2],
- ['db' => 'aliases', 'dt' => 3, 'order_subquery' => "SELECT COUNT(*) FROM `alias` WHERE (`domain`= `d`.`domain` OR `domain` IN (SELECT `alias_domain` FROM `alias_domain` WHERE `target_domain` = `d`.`domain`)) AND `address` NOT IN (SELECT `username` FROM `mailbox`)"],
- ['db' => 'mailboxes', 'dt' => 4, 'order_subquery' => "SELECT COUNT(*) FROM `mailbox` WHERE `mailbox`.`domain` = `d`.`domain` AND (`mailbox`.`kind` = '' OR `mailbox`.`kind` = NULL)"],
- ['db' => 'quota', 'dt' => 5, 'order_subquery' => "SELECT COALESCE(SUM(`mailbox`.`quota`), 0) FROM `mailbox` WHERE `mailbox`.`domain` = `d`.`domain` AND (`mailbox`.`kind` = '' OR `mailbox`.`kind` = NULL)"],
- ['db' => 'stats', 'dt' => 6, 'dummy' => true, 'order_subquery' => "SELECT SUM(bytes) FROM `quota2` WHERE `quota2`.`username` IN (SELECT `username` FROM `mailbox` WHERE `domain` = `d`.`domain`)"],
- ['db' => 'defquota', 'dt' => 7],
- ['db' => 'maxquota', 'dt' => 8],
- ['db' => 'backupmx', 'dt' => 10],
- ['db' => 'tags', 'dt' => 14, 'dummy' => true, 'search' => ['join' => 'LEFT JOIN `tags_domain` AS `td` ON `td`.`domain` = `d`.`domain`', 'where_column' => '`td`.`tag_name`']],
- ['db' => 'active', 'dt' => 15],
- ];
-
- require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/lib/ssp.class.php';
- global $pdo;
- if($_SESSION['mailcow_cc_role'] === 'admin') {
- $data = SSP::simple($_GET, $pdo, $table, $primaryKey, $columns);
- } elseif ($_SESSION['mailcow_cc_role'] === 'domainadmin') {
- $data = SSP::complex($_GET, $pdo, $table, $primaryKey, $columns,
- 'INNER JOIN domain_admins as da ON da.domain = d.domain',
- [
- 'condition' => 'da.active = 1 and da.username = :username',
- 'bindings' => ['username' => $_SESSION['mailcow_cc_username']]
- ]);
- }
-
- if (!empty($data['data'])) {
- $domainsData = [];
- foreach ($data['data'] as $domain) {
- if ($details = mailbox('get', 'domain_details', $domain[2])) {
- $domainsData[] = $details;
- }
- }
- $data['data'] = $domainsData;
- }
-
- process_get_return($data);
- break;
case "all":
$tags = null;
if (isset($_GET['tags']) && $_GET['tags'] != '')
@@ -947,6 +837,17 @@
}
echo (isset($logs) && !empty($logs)) ? json_encode($logs, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT) : '{}';
break;
+ case "cron":
+ // 0 is first record, so empty is fine
+ if (isset($extra)) {
+ $extra = preg_replace('/[^\d\-]/i', '', $extra);
+ $logs = get_logs('cron-mailcow', $extra);
+ }
+ else {
+ $logs = get_logs('cron-mailcow');
+ }
+ echo (isset($logs) && !empty($logs)) ? json_encode($logs, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT) : '{}';
+ break;
case "postfix":
// 0 is first record, so empty is fine
if (isset($extra)) {
@@ -1062,45 +963,6 @@
break;
case "mailbox":
switch ($object) {
- case "datatables":
- $table = ['mailbox', 'm'];
- $primaryKey = 'username';
- $columns = [
- ['db' => 'username', 'dt' => 2],
- ['db' => 'quota', 'dt' => 3],
- ['db' => 'last_mail_login', 'dt' => 4, 'dummy' => true, 'order_subquery' => "SELECT MAX(`datetime`) FROM `sasl_log` WHERE `service` != 'SSO' AND `username` = `m`.`username`"],
- ['db' => 'last_pw_change', 'dt' => 5, 'dummy' => true, 'order_subquery' => "JSON_EXTRACT(attributes, '$.passwd_update')"],
- ['db' => 'in_use', 'dt' => 6, 'dummy' => true, 'order_subquery' => "(SELECT SUM(bytes) FROM `quota2` WHERE `quota2`.`username` = `m`.`username`) / `m`.`quota`"],
- ['db' => 'messages', 'dt' => 17, 'dummy' => true, 'order_subquery' => "SELECT SUM(messages) FROM `quota2` WHERE `quota2`.`username` = `m`.`username`"],
- ['db' => 'tags', 'dt' => 20, 'dummy' => true, 'search' => ['join' => 'LEFT JOIN `tags_mailbox` AS `tm` ON `tm`.`username` = `m`.`username`', 'where_column' => '`tm`.`tag_name`']],
- ['db' => 'active', 'dt' => 21]
- ];
-
- require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/lib/ssp.class.php';
- global $pdo;
- if($_SESSION['mailcow_cc_role'] === 'admin') {
- $data = SSP::complex($_GET, $pdo, $table, $primaryKey, $columns, null, "(`m`.`kind` = '' OR `m`.`kind` = NULL)");
- } elseif ($_SESSION['mailcow_cc_role'] === 'domainadmin') {
- $data = SSP::complex($_GET, $pdo, $table, $primaryKey, $columns,
- 'INNER JOIN domain_admins as da ON da.domain = m.domain',
- [
- 'condition' => "(`m`.`kind` = '' OR `m`.`kind` = NULL) AND `da`.`active` = 1 AND `da`.`username` = :username",
- 'bindings' => ['username' => $_SESSION['mailcow_cc_username']]
- ]);
- }
-
- if (!empty($data['data'])) {
- $mailboxData = [];
- foreach ($data['data'] as $mailbox) {
- if ($details = mailbox('get', 'mailbox_details', $mailbox[2])) {
- $mailboxData[] = $details;
- }
- }
- $data['data'] = $mailboxData;
- }
-
- process_get_return($data);
- break;
case "all":
case "reduced":
$tags = null;
@@ -1414,10 +1276,6 @@
break;
case "fail2ban":
switch ($object) {
- case 'banlist':
- header('Content-Type: text/plain');
- echo fail2ban('banlist', 'get', $extra);
- break;
default:
$data = fail2ban('get');
process_get_return($data);
@@ -1635,23 +1493,6 @@
);
echo json_encode($temp, JSON_UNESCAPED_SLASHES);
break;
- case "solr":
- $solr_status = solr_status();
- $solr_size = ($solr_status['status']['dovecot-fts']['index']['size']);
- $solr_documents = ($solr_status['status']['dovecot-fts']['index']['numDocs']);
- if (strtolower(getenv('SKIP_SOLR')) != 'n') {
- $solr_enabled = false;
- }
- else {
- $solr_enabled = true;
- }
- echo json_encode(array(
- 'type' => 'info',
- 'solr_enabled' => $solr_enabled,
- 'solr_size' => $solr_size,
- 'solr_documents' => $solr_documents
- ));
- break;
case "host":
if (!$extra){
$stats = docker("host_stats");
@@ -1691,6 +1532,13 @@
$score = array("score" => preg_replace("/\s+/", "", $score));
process_get_return($score);
break;
+ case "identity-provider":
+ if($_SESSION['mailcow_cc_role'] === 'admin') {
+ process_get_return($iam_settings);
+ } else {
+ process_get_return(null);
+ }
+ break;
break;
// return no route found if no case is matched
default:
@@ -1703,6 +1551,136 @@
}
}
break;
+ case "search":
+ function process_search_return($return) {
+ if ($return === false) {
+ echo json_encode(array(
+ 'type' => 'error',
+ 'msg' => 'Cannot get item'
+ ));
+ }
+ else {
+ echo json_encode($return, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT);
+ }
+ }
+ // only allow POST requests to SEARCH API endpoints
+ if ($_SERVER['REQUEST_METHOD'] != 'POST') {
+ http_response_code(405);
+ echo json_encode(array(
+ 'type' => 'error',
+ 'msg' => 'only POST method is allowed'
+ ));
+ exit();
+ }
+
+ // Load SSP class
+ require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/lib/ssp.class.php';
+ global $pdo;
+
+ switch ($category) {
+ case "domain":
+ $table = ['domain', 'd'];
+ $primaryKey = 'domain';
+ $columns = [
+ ['db' => 'domain', 'dt' => 2],
+ ['db' => 'aliases', 'dt' => 3, 'order_subquery' => "SELECT COUNT(*) FROM `alias` WHERE (`domain`= `d`.`domain` OR `domain` IN (SELECT `alias_domain` FROM `alias_domain` WHERE `target_domain` = `d`.`domain`)) AND `address` NOT IN (SELECT `username` FROM `mailbox`)"],
+ ['db' => 'mailboxes', 'dt' => 4, 'order_subquery' => "SELECT COUNT(*) FROM `mailbox` WHERE `mailbox`.`domain` = `d`.`domain` AND (`mailbox`.`kind` = '' OR `mailbox`.`kind` = NULL)"],
+ ['db' => 'quota', 'dt' => 5, 'order_subquery' => "SELECT COALESCE(SUM(`mailbox`.`quota`), 0) FROM `mailbox` WHERE `mailbox`.`domain` = `d`.`domain` AND (`mailbox`.`kind` = '' OR `mailbox`.`kind` = NULL)"],
+ ['db' => 'stats', 'dt' => 6, 'dummy' => true, 'order_subquery' => "SELECT SUM(bytes) FROM `quota2` WHERE `quota2`.`username` IN (SELECT `username` FROM `mailbox` WHERE `domain` = `d`.`domain`)"],
+ ['db' => 'defquota', 'dt' => 7],
+ ['db' => 'maxquota', 'dt' => 8],
+ ['db' => 'backupmx', 'dt' => 10],
+ ['db' => 'tags', 'dt' => 14, 'dummy' => true, 'search' => ['join' => 'LEFT JOIN `tags_domain` AS `td` ON `td`.`domain` = `d`.`domain`', 'where_column' => '`td`.`tag_name`']],
+ ['db' => 'active', 'dt' => 15],
+ ];
+
+ if($_SESSION['mailcow_cc_role'] === 'admin') {
+ $data = SSP::simple($requestDecoded, $pdo, $table, $primaryKey, $columns);
+ } elseif ($_SESSION['mailcow_cc_role'] === 'domainadmin') {
+ $data = SSP::complex($requestDecoded, $pdo, $table, $primaryKey, $columns,
+ 'INNER JOIN domain_admins as da ON da.domain = d.domain',
+ [
+ 'condition' => 'da.active = 1 and da.username = :username',
+ 'bindings' => ['username' => $_SESSION['mailcow_cc_username']]
+ ]);
+ } else {
+ http_response_code(403);
+ echo json_encode(array(
+ 'type' => 'error',
+ 'msg' => 'Insufficient permissions'
+ ));
+ exit();
+ }
+
+ if (!empty($data['data'])) {
+ $domainsData = [];
+ foreach ($data['data'] as $domain) {
+ if ($details = mailbox('get', 'domain_details', $domain[2])) {
+ $domainsData[] = $details;
+ }
+ }
+ $data['data'] = $domainsData;
+ }
+
+ process_search_return($data);
+ break;
+
+ case "mailbox":
+ $table = ['mailbox', 'm'];
+ $primaryKey = 'username';
+ $columns = [
+ ['db' => 'username', 'dt' => 2],
+ ['db' => 'quota', 'dt' => 3],
+ ['db' => 'last_mail_login', 'dt' => 4, 'dummy' => true, 'order_subquery' => "SELECT MAX(`datetime`) FROM `sasl_log` WHERE `service` != 'SSO' AND `username` = `m`.`username`"],
+ ['db' => 'last_pw_change', 'dt' => 5, 'dummy' => true, 'order_subquery' => "JSON_EXTRACT(attributes, '$.passwd_update')"],
+ ['db' => 'in_use', 'dt' => 6, 'dummy' => true, 'order_subquery' => "(SELECT SUM(bytes) FROM `quota2` WHERE `quota2`.`username` = `m`.`username`) / `m`.`quota`"],
+ ['db' => 'name', 'dt' => 7],
+ ['db' => 'messages', 'dt' => 20, 'dummy' => true, 'order_subquery' => "SELECT SUM(messages) FROM `quota2` WHERE `quota2`.`username` = `m`.`username`"],
+ ['db' => 'tags', 'dt' => 23, 'dummy' => true, 'search' => ['join' => 'LEFT JOIN `tags_mailbox` AS `tm` ON `tm`.`username` = `m`.`username`', 'where_column' => '`tm`.`tag_name`']],
+ ['db' => 'active', 'dt' => 24],
+ ];
+
+ if($_SESSION['mailcow_cc_role'] === 'admin') {
+ $data = SSP::complex($requestDecoded, $pdo, $table, $primaryKey, $columns, null,
+ "(`m`.`kind` = '' OR `m`.`kind` = NULL)");
+ } elseif ($_SESSION['mailcow_cc_role'] === 'domainadmin') {
+ $data = SSP::complex($requestDecoded, $pdo, $table, $primaryKey, $columns,
+ 'INNER JOIN domain_admins as da ON da.domain = m.domain',
+ [
+ 'condition' => "(`m`.`kind` = '' OR `m`.`kind` = NULL) AND `da`.`active` = 1 AND `da`.`username` = :username",
+ 'bindings' => ['username' => $_SESSION['mailcow_cc_username']]
+ ]);
+ } else {
+ http_response_code(403);
+ echo json_encode(array(
+ 'type' => 'error',
+ 'msg' => 'Insufficient permissions'
+ ));
+ exit();
+ }
+
+ if (!empty($data['data'])) {
+ $mailboxData = [];
+ foreach ($data['data'] as $mailbox) {
+ if ($details = mailbox('get', 'mailbox_details', $mailbox[2])) {
+ $mailboxData[] = $details;
+ }
+ }
+ $data['data'] = $mailboxData;
+ }
+
+ process_search_return($data);
+ break;
+
+ default:
+ http_response_code(404);
+ echo json_encode(array(
+ 'type' => 'error',
+ 'msg' => 'Invalid search category'
+ ));
+ break;
+ }
+ break;
case "delete":
if ($_SESSION['mailcow_cc_api_access'] == 'ro' || isset($_SESSION['pending_mailcow_cc_username']) || !isset($_SESSION["mailcow_cc_username"])) {
http_response_code(403);
@@ -1844,6 +1822,9 @@
case "rlhash":
echo ratelimit('delete', null, implode($items));
break;
+ case "identity-provider":
+ process_delete_return(identity_provider('delete'));
+ break;
// return no route found if no case is matched
default:
http_response_code(404);
@@ -1967,7 +1948,6 @@
case "quota_notification_bcc":
process_edit_return(quota_notification_bcc('edit', $attr));
break;
- break;
case "mailq":
process_edit_return(mailq('edit', array_merge(array('qid' => $items), $attr)));
break;
@@ -2015,6 +1995,9 @@
case "rl-mbox":
process_edit_return(ratelimit('edit', 'mailbox', array_merge(array('object' => $items), $attr)));
break;
+ case "rename-mbox":
+ process_edit_return(mailbox('edit', 'mailbox_rename', array_merge(array('mailbox' => $items), $attr)));
+ break;
case "user-acl":
process_edit_return(acl('edit', 'user', array_merge(array('username' => $items), $attr)));
break;
@@ -2052,6 +2035,12 @@
case "ip_check":
process_edit_return(customize('edit', 'ip_check', $attr));
break;
+ case "custom_login":
+ process_edit_return(customize('edit', 'custom_login', $attr));
+ break;
+ case "ui_theme":
+ process_edit_return(customize('edit', 'ui_theme', $attr));
+ break;
case "self":
if ($_SESSION['mailcow_cc_role'] == "domainadmin") {
process_edit_return(domain_admin('edit', $attr));
@@ -2063,6 +2052,21 @@
case "cors":
process_edit_return(cors('edit', $attr));
break;
+ case "identity-provider":
+ process_edit_return(identity_provider('edit', $attr));
+ break;
+ case "identity-provider-test":
+ process_edit_return(identity_provider('test', $attr));
+ break;
+ case "cors":
+ process_edit_return(cors('edit', $attr));
+ break;
+ case "reset-password-notification":
+ process_edit_return(reset_password('edit_notification', $attr));
+ break;
+ case "mta-sts":
+ process_edit_return(mailbox('edit', 'mta_sts', array_merge(array('domains' => $items), $attr)));
+ break;
// return no route found if no case is matched
default:
http_response_code(404);
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.az-az.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.az-az.json
new file mode 100644
index 0000000..958ed8e
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.az-az.json
@@ -0,0 +1,17 @@
+{
+ "acl": {
+ "login_as": "E-poçt qutusu istifadəçisi olaraq daxil ol",
+ "alias_domains": "Alternativ domenlər əlavə et",
+ "app_passwds": "Tətbiq parollarını idarə et",
+ "bcc_maps": "BCC yönləndirmə xəritələri",
+ "delimiter_action": "Ayırıcı əməliyyatı",
+ "domain_desc": "Domen təsvirini dəyiş",
+ "domain_relayhost": "Domen üçün relay serveri dəyiş",
+ "eas_reset": "EAS cihazlarını sıfırla",
+ "extend_sender_acl": "Göndərən ACL-ni xarici ünvanlarla genişləndirməyə icazə ver",
+ "filters": "Filtrlər",
+ "mailbox_relayhost": "E-poçt qutusu üçün relay serveri dəyiş",
+ "prohibited": "ACL tərəfindən məhdudlaşdırılıb",
+ "protocol_access": "Protokol girişini dəyiş"
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.bg-bg.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.bg-bg.json
new file mode 100644
index 0000000..d17c4dd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.bg-bg.json
@@ -0,0 +1,1391 @@
+{
+ "acl": {
+ "alias_domains": "Добавяне на домейни за псевдоними",
+ "app_passwds": "Управление на пароли за приложения",
+ "bcc_maps": "BCC карти",
+ "delimiter_action": "Действие на разделител",
+ "domain_desc": "Промяна на описанието на домейна",
+ "domain_relayhost": "Промяна на релеен хост за домейн",
+ "eas_reset": "Нулиране на устройствата с ActiveSync",
+ "extend_sender_acl": "Разрешаване на разширяване на ACL на изпращащите от външни адреси",
+ "filters": "Филтри",
+ "login_as": "Вход като потребител на пощенска кутия",
+ "mailbox_relayhost": "Промяна на релеен хост за пощенска кутия",
+ "prohibited": "Забранено от ACL",
+ "protocol_access": "Промяна на достъпа до протоколи",
+ "pushover": "Pushover",
+ "pw_reset": "Разрешаване на нулиране на паролата на потребител на mailcow",
+ "quarantine": "Действия с карантина",
+ "quarantine_attachments": "Прикачени файлове в карантина",
+ "quarantine_category": "Промяна на категорията на уведомленията за карантина",
+ "quarantine_notification": "Промяна на уведомленията за карантина",
+ "ratelimit": "Ограничение на скоростта",
+ "recipient_maps": "Карти на получатели",
+ "smtp_ip_access": "Промяна на разрешените хостове за SMTP",
+ "sogo_access": "Разрешаване на управление на достъпа до SOGo",
+ "sogo_profile_reset": "Нулиране на профила на SOGo",
+ "spam_alias": "Временни псевдоними",
+ "spam_policy": "Черен/Бял списък",
+ "spam_score": "Резултат за спам",
+ "syncjobs": "Синхронизиращи задачи",
+ "tls_policy": "Политика за TLS",
+ "unlimited_quota": "Неограничена квота за пощенски кутии"
+ },
+ "add": {
+ "activate_filter_warn": "Всички други филтри ще бъдат деактивирани, когато активното е отбелязано.",
+ "active": "Активен",
+ "add": "Добавяне",
+ "add_domain_only": "Добавяне само на домейн",
+ "add_domain_restart": "Добавяне на домейн и рестартиране на SOGo",
+ "alias_address": "Адрес/и за псевдоним",
+ "alias_address_info": "<small>Пълни имейл адреси или @example.com, за да хванете всички съобщения за домейн (разделени с запетая). <b>само домейни на mailcow</b>.</small>",
+ "alias_domain": "Домейн за псевдоним",
+ "alias_domain_info": "<small>Валидни имена на домейни (разделени с запетая).</small>",
+ "app_name": "Име на приложението",
+ "app_password": "Добавяне на парола за приложение",
+ "app_passwd_protocols": "Разрешени протоколи за паролата на приложението",
+ "automap": "Опит за автоматично картографиране на папки (\"Изпратени\", \"Изпратени\" => \"Изпратени\" и т.н.)",
+ "backup_mx_options": "Опции за реле",
+ "bcc_dest_format": "BCC дестинацията трябва да бъде един валиден имейл адрес.<br>Ако имате нужда да изпратите копие до множество адреси, създайте псевдоним и го използвайте тук.",
+ "comment_info": "Частен коментар не е видим за потребителя, докато публичен коментар се показва като подсказка при преминаване с мишката върху него в прегледа на потребителя",
+ "custom_params": "Персонализирани параметри",
+ "custom_params_hint": "Дясно: --param=xy, грешно: --param xy",
+ "delete1": "Изтриване от източника след завършване",
+ "delete2": "Изтриване на съобщенията в дестинацията, които не са в източника",
+ "delete2duplicates": "Изтриване на дубликати в дестинацията",
+ "description": "Описание",
+ "destination": "Дестинация",
+ "disable_login": "Забраняване на вход (входящите съобщения все още се приемат)",
+ "domain": "Домейн",
+ "domain_matches_hostname": "Домейнът %s съвпада с името на хоста",
+ "domain_quota_m": "Обща квота на домейна (MiB)",
+ "dry": "Симулиране на синхронизация",
+ "enc_method": "Метод на криптиране",
+ "exclude": "Изключване на обекти (regex)",
+ "full_name": "Пълно име",
+ "gal": "Глобален адресен списък",
+ "gal_info": "Глобалният адресен списък съдържа всички обекти на домейна и не може да бъде редактиран от нито един потребител. Липсва информация за заетост/свободно време в SOGo, ако е деактивирано! <b>Рестартирайте SOGo, за да приложите промените.</b>",
+ "generate": "генериране",
+ "goto_ham": "Учен като <span class=\"text-success\"><b>не е спам</b></span>",
+ "goto_null": "Тихо изхвърляне на имейла",
+ "goto_spam": "Учен като <span class=\"text-danger\"><b>спам</b></span>",
+ "hostname": "Хост",
+ "inactive": "Неактивен",
+ "kind": "Вид",
+ "mailbox_quota_def": "Квота по подразбиране за пощенска кутия",
+ "mailbox_quota_m": "Макс. квота за пощенска кутия (MiB)",
+ "mailbox_username": "Потребителско име (лява част на имейл адрес)",
+ "max_aliases": "Макс. възможни псевдоними",
+ "max_mailboxes": "Макс. възможни пощенски кутии",
+ "mins_interval": "Интервал за проверка (минути)",
+ "multiple_bookings": "Множествени резервации",
+ "nexthop": "Следващ хоп",
+ "password": "Парола",
+ "password_repeat": "Потвърждаване на паролата (повторете)",
+ "port": "Порт",
+ "post_domain_add": "След добавянето на нов домейн, контейнерът на SOGo, \"sogo-mailcow\", трябва да бъде рестартиран!<br><br>Освен това, конфигурацията на DNS на домейна трябва да бъде прегледана. След като конфигурацията на DNS бъде одобрена, рестартирайте \"acme-mailcow\", за да генерирате автоматично сертификати за вашия нов домейн (autoconfig.<domain>, autodiscover.<domain>).<br>Тази стъпка е опционална и ще бъде повторена всеки 24 часа.",
+ "private_comment": "Частен коментар",
+ "public_comment": "Публичен коментар",
+ "quota_mb": "Квота (MiB)",
+ "relay_all": "Реле на всички получатели",
+ "relay_all_info": "↪ Ако изберете да <b>не</b> релеирате всички получатели, ще трябва да добавите (\"скрита\") пощенска кутия за всеки отделен получател, който трябва да бъде релеиран.",
+ "relay_domain": "Реле на този домейн",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Инфо</div> Можете да дефинирате транспортни карти за персонализирана дестинация за този домейн. Ако не е зададено, ще бъде направен MX lookup.",
+ "relay_unknown_only": "Реле на несъществуващи пощенски кутии. Съществуващите пощенски кутии ще бъдат доставени локално.",
+ "relayhost_wrapped_tls_info": "Моля, <b>не</b> използвайте TLS-wrapped портове (най-често използвани на порт 465).<br>\r\nИзползвайте всеки не-wrapped порт и издайте STARTTLS. Политика за TLS може да бъде създадена в \"TLS политики\", за да се наложи TLS.",
+ "select": "Моля, изберете...",
+ "select_domain": "Моля, изберете първо домейн",
+ "sieve_desc": "Кратко описание",
+ "sieve_type": "Тип на филтър",
+ "skipcrossduplicates": "Пропускане на дублирани съобщения между папки (първи дошъл, първи обслужен)",
+ "subscribeall": "Абониране за всички папки",
+ "syncjob": "Добавяне на синхронизираща задача",
+ "syncjob_hint": "Имайте предвид, че паролите трябва да бъдат запазени като обикновен текст!",
+ "tags": "Тагове",
+ "target_address": "Адреси за пренасочване",
+ "target_address_info": "<small>Пълни имейл адреси (разделени с запетая).</small>",
+ "target_domain": "Целеви домейн",
+ "timeout1": "Таймаут за връзка с отдалечен хост",
+ "timeout2": "Таймаут за връзка с локален хост",
+ "username": "Потребителско име",
+ "validate": "Валидиране",
+ "validation_success": "Успешно валидиране"
+ },
+ "admin": {
+ "access": "Достъп",
+ "action": "Действие",
+ "activate_api": "Активиране на API",
+ "activate_send": "Активиране на бутона за изпращане",
+ "active": "Активен",
+ "active_rspamd_settings_map": "Активна карта с настройки",
+ "add": "Добавяне",
+ "add_admin": "Добавяне на администратор",
+ "add_domain_admin": "Добавяне на администратор на домейн",
+ "add_forwarding_host": "Добавяне на хост за препращане",
+ "add_relayhost": "Добавяне на транспорт, зависим от изпращач",
+ "add_relayhost_hint": "Имайте предвид, че данните за удостоверяване, ако има такива, ще бъдат запазени като обикновен текст.",
+ "add_row": "Добавяне на ред",
+ "add_settings_rule": "Добавяне на правило за настройки",
+ "add_transport": "Добавяне на транспорт",
+ "add_transports_hint": "Имайте предвид, че данните за удостоверяване, ако има такива, ще бъдат запазени като обикновен текст.",
+ "additional_rows": "добавени допълнителни редове",
+ "admin": "Администратор",
+ "admin_details": "Редактиране на детайлите на администратора",
+ "admin_domains": "Назначения на домейни",
+ "admins": "Администратори",
+ "admins_ldap": "LDAP администратори",
+ "advanced_settings": "Разширени настройки",
+ "allowed_methods": "Access-Control-Allow-Methods",
+ "allowed_origins": "Access-Control-Allow-Origin",
+ "api_allow_from": "Разрешаване на API достъп от тези IP адреси/CIDR мрежови нотации",
+ "api_info": "API е в процес на разработка. Документацията може да бъде намерена на <a href=\"/api\">/api</a>",
+ "api_key": "API ключ",
+ "api_read_only": "Достъп само за четене",
+ "api_read_write": "Достъп за четене и писане",
+ "api_skip_ip_check": "Пропускане на IP проверка за API",
+ "app_hide": "Скриване за вход",
+ "app_links": "Връзки към приложения",
+ "app_name": "Име на приложението",
+ "apps_name": "Име на \"mailcow приложенията\"",
+ "arrival_time": "Време на пристигане (време на сървъра)",
+ "authed_user": "Удостоверен потребител",
+ "ays": "Сигурни ли сте, че искате да продължите?",
+ "ban_list_info": "Вижте списък с блокирани IP адреси по-долу: <b>мрежа (оставащо време за блокиране) - [действия]</b>.<br />IP адресите в опашката за разблокиране ще бъдат премахнати от активния списък с блокирани в рамките на няколко секунди.<br />Червените етикети показват активни постоянни блокирания от черния списък.",
+ "change_logo": "Промяна на логото",
+ "logo_normal_label": "Нормално",
+ "logo_dark_label": "Обърнато за тъмен режим",
+ "configuration": "Конфигурация",
+ "convert_html_to_text": "Конвертиране на HTML в обикновен текст",
+ "copy_to_clipboard": "Текстът е копиран в клипборда!",
+ "cors_settings": "Настройки на CORS",
+ "credentials_transport_warning": "<b>Внимание</b>: Добавянето на нов запис в картата на транспорта ще обнови данните за удостоверяване за всички записи с съвпадаща колона за следващ хоп.",
+ "customer_id": "Идентификатор на клиента",
+ "customize": "Персонализиране",
+ "destination": "Дестинация",
+ "dkim_add_key": "Добавяне на ARC/DKIM ключ",
+ "dkim_domains_selector": "Селектор",
+ "dkim_domains_wo_keys": "Избор на домейни без ключове",
+ "dkim_from": "От",
+ "dkim_from_title": "Източник на домейн за копиране на данни",
+ "dkim_key_length": "Дължина на DKIM ключа (битове)",
+ "dkim_key_missing": "Липсващ ключ",
+ "dkim_key_unused": "Неизползван ключ",
+ "dkim_key_valid": "Валиден ключ",
+ "dkim_keys": "ARC/DKIM ключове",
+ "dkim_overwrite_key": "Презаписване на съществуващ DKIM ключ",
+ "dkim_private_key": "Частен ключ",
+ "dkim_to": "До",
+ "dkim_to_title": "Целеви домейн/и - ще бъде презаписан",
+ "domain": "Домейн",
+ "domain_admin": "Администратор на домейн",
+ "domain_admins": "Администратори на домейн",
+ "domain_s": "Домейн/и",
+ "duplicate": "Дублиране",
+ "duplicate_dkim": "Дублиране на DKIM запис",
+ "edit": "Редактиране",
+ "empty": "Няма резултати",
+ "excludes": "Изключване на тези получатели",
+ "f2b_ban_time": "Време за блокиране (с)",
+ "f2b_ban_time_increment": "Времето за блокиране се увеличава с всяко блокиране",
+ "f2b_blacklist": "Черни списъци/хостове",
+ "f2b_filter": "Филтри с регулярни изрази",
+ "f2b_list_info": "Черният списък на хостове или мрежи винаги ще надделява над белия списък. <b>Актуализациите на списъка отнемат няколко секунди, за да бъдат приложени.</b>",
+ "f2b_manage_external": "Управление на Fail2Ban външно",
+ "f2b_manage_external_info": "Fail2ban все още ще поддържа черния списък, но няма да задава правила за блокиране на трафика. Използвайте генерирания черн списък по-долу, за да блокирате трафика външно.",
+ "f2b_max_attempts": "Макс. опити",
+ "f2b_max_ban_time": "Макс. време за блокиране (с)",
+ "f2b_netban_ipv4": "IPv4 размер на подмрежа за прилагане на блокиране (8-32)",
+ "f2b_netban_ipv6": "IPv6 размер на подмрежа за прилагане на блокиране (8-128)",
+ "f2b_parameters": "Параметри на Fail2ban",
+ "f2b_regex_info": "Логовете, които се вземат предвид: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "f2b_retry_window": "Прозорец за повторен опит (с) за макс. опити",
+ "f2b_whitelist": "Бели списъци/хостове",
+ "filter": "Филтър",
+ "filter_table": "Таблица с филтри",
+ "forwarding_hosts": "Хостове за препращане",
+ "forwarding_hosts_add_hint": "Можете да посочите IPv4/IPv6 адреси, мрежи в CIDR нотация, имена на хостове (които ще бъдат разрешени в IP адреси), или имена на домейни (които ще бъдат разрешени в IP адреси чрез заявки към SPF записи или, при липсата им, MX записи).",
+ "forwarding_hosts_hint": "Входящите съобщения се приемат безрезервно от всички хостове, изброени тук. Тези хостове след това не се проверяват срещу DNSBL или подлагат на сиво списък. Спамът, получен от тях, никога не се отхвърля, но опционално може да бъде поставен във файла за нежелана поща. Най-често използваната употреба за това е да се посочат пощенски сървъри, на които сте настроили правило, което препраща входящите имейли към вашия mailcow сървър.",
+ "from": "От",
+ "generate": "генериране",
+ "guid": "GUID - уникален инстанционен идентификатор",
+ "guid_and_license": "GUID & Лиценз",
+ "hash_remove_info": "Премахването на хеш за ограничение на скоростта (ако все още съществува) ще нулира неговия брояч напълно.<br>\r\nВсеки хеш е показан с индивидуален цвят.",
+ "help_text": "Презаписване на помощния текст под маската за вход (разрешен е HTML)",
+ "host": "Хост",
+ "html": "HTML",
+ "iam": "Доставчик на идентичност",
+ "iam_attribute_field": "Поле за атрибут",
+ "iam_authorize_url": "Крайна точка за удостоверяване",
+ "iam_auth_flow": "Поток за удостоверяване",
+ "iam_auth_flow_info": "Освен стандартния поток за удостоверяване (поток с код за удостоверяване в Keycloak), който се използва за единичен вход, mailcow поддържа и поток за удостоверяване с пряки удостоверения. Потокът за удостоверяване с пароли за поща проверява удостоверенията на потребителя, като използва Keycloak Admin REST API. mailcow извлича хешираната парола от атрибута <code>mailcow_password</code>, който е картиран в Keycloak.",
+ "iam_basedn": "Основен DN",
+ "iam_client_id": "Идентификатор на клиента",
+ "iam_client_secret": "Тайна на клиента",
+ "iam_client_scopes": "Обхват на клиента",
+ "iam_default_template": "Шаблон по подразбиране",
+ "iam_default_template_description": "Ако няма зададен шаблон за потребител, шаблонът по подразбиране ще бъде използван за създаване на пощенската кутия, но не и за актуализиране на пощенската кутия.",
+ "iam_description": "Конфигуриране на външен доставчик за удостоверяване<br>Потребителските пощенски кутии ще бъдат създавани автоматично при първия им вход, при условие че е зададено картиране на атрибути.",
+ "iam_extra_permission": "За да работят следните настройки, клиентът на mailcow в Keycloak трябва да има <code>услуга акаунт</code> и разрешението да <code>вижда потребители</code>.",
+ "iam_host": "Хост",
+ "iam_host_info": "Въведете един или повече LDAP хостове, разделени с запетаи.",
+ "iam_import_users": "Импортиране на потребители",
+ "iam_mapping": "Картиране на атрибути",
+ "iam_bindpass": "Парола за свързване",
+ "iam_periodic_full_sync": "Периодичен пълен синхрон",
+ "iam_port": "Порт",
+ "iam_realm": "Реалм",
+ "iam_redirect_url": "URL за пренасочване",
+ "iam_rest_flow": "Поток за пароли за поща",
+ "iam_server_url": "URL на сървъра",
+ "iam_sso": "Единичен вход",
+ "iam_sync_interval": "Интервал за синхронизиране/импортиране (мин)",
+ "iam_test_connection": "Тест на връзката",
+ "iam_token_url": "Крайна точка за токени",
+ "iam_userinfo_url": "Крайна точка за информация за потребителя",
+ "iam_username_field": "Поле за потребителско име",
+ "iam_binddn": "DN за свързване",
+ "iam_use_ssl": "Използване на SSL",
+ "iam_use_ssl_info": "Ако активирате SSL и портът е зададен на 389, той ще бъде автоматично променен на 636.",
+ "iam_use_tls": "Използване на StartTLS",
+ "iam_use_tls_info": "Ако активирате TLS, трябва да използвате стандартния порт за вашия LDAP сървър (389). SSL портовете не могат да бъдат използвани.",
+ "iam_version": "Версия",
+ "ignore_ssl_error": "Игнориране на SSL грешки",
+ "import": "Импортиране",
+ "import_private_key": "Импортиране на частен ключ",
+ "in_use_by": "Използван от",
+ "inactive": "Неактивен",
+ "include_exclude": "Включване/Изключване",
+ "include_exclude_info": "По подразбиране - без избор - <b>всички пощенски кутии</b> се адресират",
+ "includes": "Включване на тези получатели",
+ "ip_check": "Проверка на IP",
+ "ip_check_disabled": "Проверката на IP е деактивирана. Можете да я активирате в <br> <strong>Система > Конфигурация > Опции > Персонализиране</strong>",
+ "ip_check_opt_in": "Оптиране за използване на услугата на трета страна <strong>ipv4.mailcow.email</strong> и <strong>ipv6.mailcow.email</strong>, за да разрешавате външни IP адреси.",
+ "is_mx_based": "MX базиран",
+ "last_applied": "Последно приложено",
+ "license_info": "Лицензът не е задължителен, но помага за по-нататъшното развитие.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL поръчка\">Регистрирайте вашия GUID тук</a> или <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Поддръжка поръчка\">купете поддръжка за вашата инсталация на mailcow.</a>",
+ "link": "Връзка",
+ "loading": "Моля, изчакайте...",
+ "login_time": "Време за вход",
+ "logo_info": "Вашето изображение ще бъде мащабирано до височина 40 px за горната навигационна лента и макс. ширина 250 px за началната страница. Препоръчва се използването на скалируема графика.",
+ "lookup_mx": "Дестинацията е регулярен израз за съвпадение с MX име (<code>.*\\.google\\.com</code> за пренасочване на всички съобщения, предназначени за MX, завършващ на google.com, през този хоп)",
+ "main_name": "Име на \"mailcow UI\"",
+ "merged_vars_hint": "Редовете в сиво са сляти от <code>vars.(local.)inc.php</code> и не могат да бъдат променени.",
+ "message": "Съобщение",
+ "message_size": "Размер на съобщението",
+ "nexthop": "Следващ хоп",
+ "no": "✕",
+ "no_active_bans": "Няма активни блокирания",
+ "no_new_rows": "Няма допълнителни редове",
+ "no_record": "Няма запис",
+ "oauth2_apps": "OAuth2 приложения",
+ "oauth2_add_client": "Добавяне на OAuth2 клиент",
+ "oauth2_client_id": "Идентификатор на клиента",
+ "oauth2_client_secret": "Тайна на клиента",
+ "oauth2_info": "Реализацията на OAuth2 поддържа типа разрешение \"Код за удостоверяване\" и издава токени за презареждане.<br>\r\nСървърът автоматично издава нови токени за презареждане, след като токен за презареждане е бил използван.<br><br>\r\n• Обхватът по подразбиране е <i>профил</i>. Само потребителите на пощенски кутии могат да бъдат удостоверени срещу OAuth2. Ако параметърът за обхват е пропуснат, той се връща към <i>профил</i>.<br>\r\n• Параметърът <i>state</i> трябва да бъде изпратен от клиента като част от заявката за удостоверяване.<br><br>\r\nПътища за заявки към OAuth2 API: <br>\r\n<ul>\r\n <li>Крайна точка за удостоверяване: <code>/oauth/authorize</code></li>\r\n <li>Крайна точка за токени: <code>/oauth/token</code></li>\r\n <li>Страница с ресурси: <code>/oauth/profile</code></li>\r\n</ul>\r\nГенерирането на нова тайна на клиента няма да анулира съществуващите кодове за удостоверяване, но те няма да могат да подновят своя токен.<br><br>\r\nАнулирането на токените на клиента ще доведе до незабавно прекратяване на всички активни сесии. Всички клиенти ще трябва да се преудостоверят.",
+ "oauth2_redirect_uri": "URI за пренасочване",
+ "oauth2_renew_secret": "Генериране на нова тайна на клиента",
+ "oauth2_revoke_tokens": "Анулиране на всички токени на клиента",
+ "optional": "опционално",
+ "options": "Опции",
+ "password": "Парола",
+ "password_length": "Дължина на паролата",
+ "password_policy": "Политика за пароли",
+ "password_policy_chars": "Трябва да съдържа поне една буквена буква",
+ "password_policy_length": "Минималната дължина на паролата е %d",
+ "password_policy_lowerupper": "Трябва да съдържа малки и главни букви",
+ "password_policy_numbers": "Трябва да съдържа поне една цифра",
+ "password_policy_special_chars": "Трябва да съдържа специални символи",
+ "password_repeat": "Потвърждаване на паролата (повторете)",
+ "password_reset_info": "Ако не е зададен имейл за възстановяване, тази функция не може да бъде използвана.",
+ "password_reset_settings": "Настройки за възстановяване на парола",
+ "password_reset_tmpl_html": "HTML шаблон",
+ "password_reset_tmpl_text": "Текстов шаблон",
+ "password_settings": "Настройки на паролата",
+ "priority": "Приоритет",
+ "private_key": "Частен ключ",
+ "quarantine": "Карантина",
+ "quarantine_bcc": "Изпращане на копие от всички уведомления (BCC) до този получател:<br><small>Оставете празно, за да деактивирате. <b>Неподписано, непроверено имейл. Трябва да бъде доставено само вътрешно.</b></small>",
+ "quarantine_exclude_domains": "Изключване на домейни и домейни на псевдоними",
+ "quarantine_max_age": "Максимална възраст в дни<br><small>Стойността трябва да бъде равна или по-голяма от 1 ден.</small>",
+ "quarantine_max_score": "Изхвърляне на уведомление, ако резултатът за спам на имейла е по-висок от тази стойност:<br><small>По подразбиране е 9999.0</small>",
+ "quarantine_max_size": "Максимален размер в MiB (по-големи елементи се изхвърлят):<br><small>0 не означава неограничен.</small>",
+ "quarantine_notification_html": "Шаблон на имейл за уведомление:<br><small>Оставете празно, за да възстановите шаблона по подразбиране.</small>",
+ "quarantine_notification_sender": "Изпращач на имейл за уведомление",
+ "quarantine_notification_subject": "Тема на имейл за уведомление",
+ "quarantine_redirect": "<b>Пренасочване на всички уведомления</b> към този получател:<br><small>Оставете празно, за да деактивирате. <b>Неподписано, непроверено имейл. Трябва да бъде доставено само вътрешно.</b></small>",
+ "quarantine_release_format": "Формат на освободените елементи",
+ "quarantine_release_format_att": "Като прикачен файл",
+ "quarantine_release_format_raw": "Непроменен оригинал",
+ "quarantine_retention_size": "Задържания за пощенска кутия:<br><small>0 показва <b>неактивен</b>.</small>",
+ "quota_notification_html": "Шаблон на имейл за уведомление:<br><small>Оставете празно, за да възстановите шаблона по подразбиране.</small>",
+ "quota_notification_sender": "Изпращач на имейл за уведомление",
+ "quota_notification_subject": "Тема на имейл за уведомление",
+ "quota_notifications": "Уведомления за квота",
+ "quota_notifications_info": "Уведомленията за квота се изпращат на потребителите веднъж при преминаване на 80% и веднъж при преминаване на 95% използване.",
+ "quota_notifications_vars": "{{percent}} е равно на текущата квота на потребителя<br>{{username}} е името на пощенската кутия",
+ "queue_unban": "разблокиране",
+ "r_active": "Активни ограничения",
+ "r_inactive": "Неактивни ограничения",
+ "r_info": "Елементите в сиво в списъка с активни ограничения не са известни като валидни ограничения за mailcow и не могат да бъдат преместени. Неизвестните ограничения ще бъдат зададени в реда на появяване все пак.<br>Можете да добавяте нови елементи в <code>inc/vars.local.inc.php</code>, за да можете да ги превключвате.",
+ "rate_name": "Име на ограничението",
+ "recipients": "Получатели",
+ "refresh": "Опресняване",
+ "regen_api_key": "Регенериране на API ключ",
+ "regex_maps": "Карти с регулярни изрази",
+ "relay_from": "Адрес \"From:\"",
+ "relay_rcpt": "Адрес \"To:\"",
+ "relay_run": "Изпълнение на тест",
+ "relayhosts": "Транспорти, зависими от изпращач",
+ "relayhosts_hint": "Дефинирайте транспорти, зависими от изпращач, за да можете да ги избирате в диалоговия прозорец за конфигурация на домейн.<br>\r\n Услугата за транспорт винаги е \"smtp:\" и ще се опита да използва TLS, ако бъде предложена. Wrapped TLS (SMTPS) не се поддържа. Политиката за TLS на потребителя ще бъде взета предвид.<br>\r\n Засегнатите домейни, включително домейни на псевдоними.",
+ "remove": "Премахване",
+ "remove_row": "Премахване на ред",
+ "reset_default": "Нулиране до подразбиране",
+ "reset_limit": "Премахване на хеш",
+ "reset_password_vars": "<code>{{link}}</code> Генерираната връзка за нулиране на парола<br><code>{{username}}</code> Името на пощенската кутия на потребителя, който е поискал нулиране на парола<br><code>{{username2}}</code> Името на пощенската кутия за възстановяване<br><code>{{date}}</code> Датата на заявката за нулиране на парола<br><code>{{token_lifetime}}</code> Времетраенето на токена в минути<br><code>{{hostname}}</code> Името на хоста на mailcow",
+ "restore_template": "Оставете празно, за да възстановите шаблона по подразбиране.",
+ "routing": "Маршрутизация",
+ "rsetting_add_rule": "Добавяне на правило",
+ "rsetting_content": "Съдържание на правилото",
+ "rsetting_desc": "Кратко описание",
+ "rsetting_no_selection": "Моля, изберете правило",
+ "rsetting_none": "Няма налични правила",
+ "rsettings_insert_preset": "Вмъкване на примерен предефиниран набор \"%s\"",
+ "rsettings_preset_1": "Деактивиране на всичко, освен DKIM и ограничение на скоростта за удостоверени потребители",
+ "rsettings_preset_2": "Пощенските администратори искат спам",
+ "rsettings_preset_3": "Разрешаване само на определени изпращачи за пощенска кутия (напр. използване като вътрешна пощенска кутия)",
+ "rsettings_preset_4": "Деактивиране на Rspamd за домейн",
+ "rspamd_com_settings": "Името на настройката ще бъде автоматично генерирано, моля, вижте примерните предефинирани набори по-долу. За повече детайли вижте <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">документацията на Rspamd</a>",
+ "rspamd_global_filters": "Глобални карти на филтри",
+ "rspamd_global_filters_agree": "Ще бъда внимателен!",
+ "rspamd_global_filters_info": "Глобалните карти на филтри съдържат различни видове глобални черни и бели списъци.",
+ "rspamd_global_filters_regex": "Имената им обясняват тяхната цел. Всичкото съдържание трябва да съдържа валиден регулярен израз във формат \"/pattern/options\" (напр. <code>/.+@domain\\.tld/i</code>).<br>\r\n Въпреки че се извършват основни проверки за всеки ред с регулярен израз, функционалността на Rspamd може да бъде нарушена, ако не успява да прочете синтаксиса коректно.<br>\r\n Rspamd ще се опита да прочете съдържанието на картата при промяна. Ако срещнете проблеми, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">рестартирайте Rspamd</a>, за да наложите презареждане на картата.<br>Елементите в черния списък са изключени от карантина.",
+ "rspamd_settings_map": "Карта с настройки на Rspamd",
+ "sal_level": "Ниво на Moo",
+ "save": "Запазване на промените",
+ "search_domain_da": "Търсене на домейни",
+ "send": "Изпращане",
+ "sender": "Изпращач",
+ "service": "Услуга",
+ "service_id": "Идентификатор на услугата",
+ "source": "Източник",
+ "spamfilter": "Филтър за спам",
+ "subject": "Тема",
+ "success": "Успех",
+ "sys_mails": "Системни имейли",
+ "task": "Задача",
+ "text": "Текст",
+ "time": "Време",
+ "title": "Заглавие",
+ "title_name": "Име на уеб страницата на \"mailcow UI\"",
+ "to_top": "Обратно нагоре",
+ "transport_dest_format": "Регулярен израз или синтаксис: example.org, .example.org, *, box@example.org (няколко стойности могат да бъдат разделени с запетая)",
+ "transport_maps": "Карти за транспорт",
+ "transport_test_rcpt_info": "• Използвайте null@hosted.mailcow.de, за да тествате препращането към чуждестранна дестинация.",
+ "transports_hint": "• Записът в картата на транспорта <b>пренарежда</b> запис в картата на транспорт, зависим от изпращач</b>.<br>\r\n• Транспортите, базирани на MX, се използват предимно.<br>\r\n• Настройките за политика на TLS на потребителя се игнорират и могат да бъдат приложени само чрез записи в картите на политиката на TLS.<br>\r\n• Услугата за транспорт за дефинираните транспорти винаги е \"smtp:\" и ще се опита да използва TLS, ако бъде предложена. Wrapped TLS (SMTPS) не се поддържа.<br>\r\n• Адресите, съвпадащи с \"/localhost$/\", винаги ще бъдат транспортирани през \"local:\", следователно записът \"*\" няма да се приложи към тези адреси.<br>\r\n• За да определите удостоверения за следващ хоп \"[host]:25\", Postfix <b>винаги</b> заявява за \"host\", преди да търси за \"[host]:25\". Това поведение прави невъзможно да се използват \"host\" и \"[host]:25\" едновременно.",
+ "ui_footer": "Подвал (разрешен е HTML)",
+ "ui_header_announcement": "Обяви",
+ "ui_header_announcement_active": "Задаване на активна обява",
+ "ui_header_announcement_content": "Текст (разрешен е HTML)",
+ "ui_header_announcement_help": "Обявата е видима за всички влезли потребители и на екрана за вход на UI.",
+ "ui_header_announcement_select": "Избор на тип обява",
+ "ui_header_announcement_type": "Тип",
+ "ui_header_announcement_type_danger": "Много важно",
+ "ui_header_announcement_type_info": "Информация",
+ "ui_header_announcement_type_warning": "Важно",
+ "ui_texts": "Етикети и текстове на UI",
+ "unban_pending": "разблокиране в опашката",
+ "unchanged_if_empty": "Ако не е променено, оставете празно",
+ "upload": "Качване",
+ "username": "Потребителско име",
+ "user_link": "Връзка към потребител",
+ "validate_license_now": "Валидиране на GUID срещу лицензен сървър",
+ "verify": "Проверка",
+ "yes": "✓"
+ },
+ "danger": {
+ "access_denied": "Достъпът е отказан или данните от формуляра са невалидни",
+ "alias_domain_invalid": "Домейнът на псевдонима %s е невалиден",
+ "alias_empty": "Адресът на псевдонима не трябва да е празен",
+ "alias_goto_identical": "Адресът на псевдонима и адресът за пренасочване не трябва да са идентични",
+ "alias_invalid": "Адресът на псевдонима %s е невалиден",
+ "aliasd_targetd_identical": "Домейнът на псевдонима не трябва да е равен на целевия домейн: %s",
+ "aliases_in_use": "Макс. псевдоними трябва да бъдат по-големи или равни на %d",
+ "app_name_empty": "Името на приложението не може да бъде празно",
+ "app_passwd_id_invalid": "Идентификаторът на паролата за приложението %s е невалиден",
+ "authsource_in_use": "Доставчикът на идентичност не може да бъде променен или изтрит, тъй като се използва в момента от един или повече потребители.",
+ "bcc_empty": "BCC дестинацията не може да бъде празна",
+ "bcc_exists": "Картата BCC %s съществува за тип %s",
+ "bcc_must_be_email": "BCC дестинацията %s не е валиден имейл адрес",
+ "comment_too_long": "Коментарът е твърде дълъг, разрешени са макс. 160 символа",
+ "cors_invalid_method": "Зададен е невалиден метод за разрешаване",
+ "cors_invalid_origin": "Зададен е невалиден източник за разрешаване",
+ "defquota_empty": "Квотата по подразбиране за пощенска кутия не трябва да бъде 0.",
+ "demo_mode_enabled": "Режимът на демонстрация е активиран",
+ "description_invalid": "Описанието на ресурса за %s е невалидно",
+ "dkim_domain_or_sel_exists": "Съществува DKIM ключ за \"%s\", който няма да бъде презаписан",
+ "dkim_domain_or_sel_invalid": "DKIM домейн или селектор е невалиден: %s",
+ "domain_cannot_match_hostname": "Домейнът не може да съвпада с името на хоста",
+ "domain_exists": "Домейнът %s вече съществува",
+ "domain_invalid": "Името на домейна е празно или невалидно",
+ "domain_not_empty": "Не може да бъде премахнат непразен домейн %s",
+ "domain_not_found": "Домейнът %s не е намерен",
+ "domain_quota_m_in_use": "Квотата на домейна трябва да бъде по-голяма или равна на %s MiB",
+ "extended_sender_acl_denied": "липсва ACL за задаване на външни адреси на изпращач",
+ "extra_acl_invalid": "Външният адрес на изпращач \"%s\" е невалиден",
+ "extra_acl_invalid_domain": "Външният изпращач \"%s\" използва невалиден домейн",
+ "fido2_verification_failed": "Проверката на FIDO2 е неуспешна: %s",
+ "file_open_error": "Файлът не може да бъде отворен за писане",
+ "filter_type": "Грешен тип на филтър",
+ "from_invalid": "Изпращачът не трябва да бъде празен",
+ "generic_server_error": "Възникна неочаквана грешка на сървъра. Моля, свържете се с вашия администратор.",
+ "global_filter_write_error": "Файлът с филтър не може да бъде записан: %s",
+ "global_map_invalid": "Идентификаторът на глобалната карта %s е невалиден",
+ "global_map_write_error": "Глобалният идентификатор на картата %s не може да бъде записан: %s",
+ "goto_empty": "Адресът на псевдоним трябва да съдържа поне един валиден адрес за пренасочване",
+ "goto_invalid": "Адресът за пренасочване %s е невалиден",
+ "ham_learn_error": "Грешка при обучение за не-спам: %s",
+ "iam_test_connection": "Връзката е неуспешна",
+ "imagick_exception": "Грешка: Грешка при четене на изображение с Imagick",
+ "img_dimensions_exceeded": "Изображението надхвърля максималния размер",
+ "img_invalid": "Не може да се валидира файл с изображение",
+ "img_size_exceeded": "Изображението надхвърля максималния размер на файла",
+ "img_tmp_missing": "Не може да се валидира файл с изображение: Липсва временен файл",
+ "invalid_bcc_map_type": "Невалиден тип на картата BCC",
+ "invalid_destination": "Форматът на дестинацията \"%s\" е невалиден",
+ "invalid_filter_type": "Невалиден тип на филтър",
+ "invalid_host": "Зададен е невалиден хост: %s",
+ "invalid_mime_type": "Невалиден MIME тип",
+ "invalid_nexthop": "Форматът на следващия хоп е невалиден",
+ "invalid_nexthop_authenticated": "Следващият хоп съществува с различни удостоверения, моля, актуализирайте съществуващите удостоверения за този следващ хоп първо.",
+ "invalid_recipient_map_new": "Зададен е невалиден нов получател: %s",
+ "invalid_recipient_map_old": "Зададен е невалиден оригинален получател: %s",
+ "invalid_reset_token": "Невалиден токен за нулиране",
+ "ip_list_empty": "Списъкът с разрешени IP адреси не може да бъде празен",
+ "is_alias": "%s вече е известен като адрес на псевдоним",
+ "is_alias_or_mailbox": "%s вече е известен като адрес на псевдоним, пощенска кутия или адрес на псевдоним, разширен от домейн на псевдоним.",
+ "is_spam_alias": "%s вече е известен като временен адрес на псевдоним (спам адрес на псевдоним)",
+ "last_key": "Последното ключове не може да бъде изтрито, моля, деактивирайте TFA вместо това.",
+ "login_failed": "Неуспешен вход",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "Квотата по подразбиране надхвърля лимита на макс. квота",
+ "mailbox_invalid": "Името на пощенската кутия е невалидно",
+ "mailbox_quota_exceeded": "Квотата надхвърля лимита на домейна (макс. %d MiB)",
+ "mailbox_quota_exceeds_domain_quota": "Макс. квотата надхвърля лимита на квотата на домейна",
+ "mailbox_quota_left_exceeded": "Няма достатъчно място (оставащо място: %d MiB)",
+ "mailboxes_in_use": "Макс. пощенски кутии трябва да бъдат по-големи или равни на %d",
+ "malformed_username": "Неправилно формирано потребителско име",
+ "map_content_empty": "Съдържанието на картата не може да бъде празно",
+ "max_alias_exceeded": "Макс. псевдоними са надхвърлени",
+ "max_mailbox_exceeded": "Макс. пощенски кутии са надхвърлени (%d от %d)",
+ "max_quota_in_use": "Квотата на пощенската кутия трябва да бъде по-голяма или равна на %d MiB",
+ "maxquota_empty": "Макс. квотата за пощенска кутия не трябва да бъде 0.",
+ "mysql_error": "Грешка на MySQL: %s",
+ "network_host_invalid": "Невалидна мрежа или хост: %s",
+ "next_hop_interferes": "%s се намесва с nexthop %s",
+ "next_hop_interferes_any": "Съществуващ следващ хоп се намесва с %s",
+ "nginx_reload_failed": "Презареждането на Nginx е неуспешно: %s",
+ "no_user_defined": "Няма зададен потребител",
+ "object_exists": "Обектът %s вече съществува",
+ "object_is_not_numeric": "Стойността %s не е числова",
+ "password_complexity": "Паролата не отговаря на изискванията",
+ "password_empty": "Паролата не трябва да бъде празна",
+ "password_mismatch": "Паролата за потвърждение не съвпада",
+ "password_reset_invalid_user": "Пощенската кутия не е намерена или не е зададен имейл за възстановяване",
+ "password_reset_na": "Възстановяването на парола в момента е недостъпно. Моля, свържете се с вашия администратор.",
+ "policy_list_from_exists": "Съществува запис с даденото име",
+ "policy_list_from_invalid": "Записът има невалиден формат",
+ "private_key_error": "Грешка с частен ключ: %s",
+ "pushover_credentials_missing": "Липсва токен или ключ на Pushover",
+ "pushover_key": "Ключът на Pushover има грешен формат",
+ "pushover_token": "Токенът на Pushover има грешен формат",
+ "quota_not_0_not_numeric": "Квотата трябва да бъде числова и >= 0",
+ "recipient_map_entry_exists": "Съществува запис в картата на получатели \"%s\"",
+ "recovery_email_failed": "Не може да бъде изпратен имейл за възстановяване. Моля, свържете се с вашия администратор.",
+ "redis_error": "Грешка на Redis: %s",
+ "relayhost_invalid": "Записът в картата %s е невалиден",
+ "release_send_failed": "Съобщението не може да бъде освободено: %s",
+ "required_data_missing": "Липсват необходими данни %s",
+ "reset_f2b_regex": "Регулярният филтър не може да бъде нулиран навреме, моля, опитайте отново или изчакайте още няколко секунди и презаредете уеб сайта.",
+ "reset_token_limit_exceeded": "Лимитът на токена за нулиране е надхвърлен. Моля, опитайте по-късно.",
+ "resource_invalid": "Името на ресурса %s е невалидно",
+ "rl_timeframe": "Временният интервал за ограничение на скоростта е некоректен",
+ "rspamd_ui_pw_length": "Паролата на UI на Rspamd трябва да бъде поне 6 символа",
+ "script_empty": "Скриптът не може да бъде празен",
+ "sender_acl_invalid": "Стойността на ACL на изпращач %s е невалидна",
+ "set_acl_failed": "Неуспешно задаване на ACL",
+ "settings_map_invalid": "Идентификаторът на картата с настройки %s е невалиден",
+ "sieve_error": "Грешка при синтаксиса на Sieve: %s",
+ "spam_learn_error": "Грешка при обучение за спам: %s",
+ "subject_empty": "Темата не трябва да бъде празна",
+ "target_domain_invalid": "Целевият домейн %s е невалиден",
+ "targetd_not_found": "Целевият домейн %s не е намерен",
+ "targetd_relay_domain": "Целевият домейн %s е домейн за реле",
+ "template_exists": "Шаблонът %s вече съществува",
+ "template_id_invalid": "Идентификаторът на шаблона %s е невалиден",
+ "template_name_invalid": "Името на шаблона е невалидно",
+ "temp_error": "Временна грешка",
+ "text_empty": "Текстът не трябва да бъде празен",
+ "tfa_token_invalid": "Токенът за TFA е невалиден",
+ "tls_policy_map_dest_invalid": "Дестинацията на политиката е невалидна",
+ "tls_policy_map_entry_exists": "Съществува запис в картата на политиката на TLS \"%s\"",
+ "tls_policy_map_parameter_invalid": "Параметърът на политиката е невалиден",
+ "to_invalid": "Получателят не трябва да бъде празен",
+ "totp_verification_failed": "Проверката на TOTP е неуспешна",
+ "transport_dest_exists": "Дестинацията на транспорта \"%s\" съществува",
+ "webauthn_verification_failed": "Проверката на WebAuthn е неуспешна: %s",
+ "webauthn_authenticator_failed": "Избраният аутентикатор не е намерен",
+ "webauthn_publickey_failed": "Не е запазен публичен ключ за избрания аутентикатор",
+ "webauthn_username_failed": "Избраният аутентикатор принадлежи на друга сметка",
+ "unknown": "Възникна неизвестна грешка",
+ "unknown_tfa_method": "Неизвестен метод за TFA",
+ "unlimited_quota_acl": "Неограничената квота е забранена от ACL",
+ "username_invalid": "Потребителското име %s не може да бъде използвано",
+ "validity_missing": "Моля, задайте период на валидност",
+ "value_missing": "Моля, предоставете всички стойности",
+ "yotp_verification_failed": "Проверката на Yubico OTP е неуспешна: %s"
+ },
+ "datatables": {
+ "collapse_all": "Свиване на всичко",
+ "decimal": ".",
+ "emptyTable": "Няма данни в таблицата",
+ "expand_all": "Разширяване на всичко",
+ "info": "Показване на _START_ до _END_ от _TOTAL_ записа",
+ "infoEmpty": "Показване на 0 до 0 от 0 записа",
+ "infoFiltered": "(филтрирани от общо _MAX_ записа)",
+ "infoPostFix": "",
+ "thousands": ",",
+ "lengthMenu": "Показване на _MENU_ записа",
+ "loadingRecords": "Зареждане...",
+ "processing": "Моля, изчакайте...",
+ "search": "Търсене:",
+ "zeroRecords": "Няма съвпадащи записи",
+ "paginate": {
+ "first": "Първи",
+ "last": "Последен",
+ "next": "Следващ",
+ "previous": "Предишен"
+ },
+ "aria": {
+ "sortAscending": ": активиране за сортиране на колоната във възходящ ред",
+ "sortDescending": ": активиране за сортиране на колоната в низходящ ред"
+ }
+ },
+ "debug": {
+ "architecture": "Архитектура",
+ "chart_this_server": "Графика (този сървър)",
+ "containers_info": "Информация за контейнерите",
+ "container_running": "Изпълнява се",
+ "container_disabled": "Контейнерът е спрян или деактивиран",
+ "container_stopped": "Спрян",
+ "cores": "Ядра",
+ "current_time": "Системно време",
+ "disk_usage": "Използване на диска",
+ "docs": "Документи",
+ "error_show_ip": "Не може да се разреши публичния IP адрес",
+ "external_logs": "Външни логове",
+ "history_all_servers": "История (всички сървъри)",
+ "in_memory_logs": "Логове в паметта",
+ "last_modified": "Последно модифициране",
+ "log_info": "<p>Логовете на mailcow <b>в паметта</b> се събират в списъци на Redis и се подрязват до LOG_LINES (%d) на всяка минута, за да се намали натоварването.<br>Логовете в паметта не са предназначени да бъдат постоянни. Всички приложения, които записват в паметта, също записват в демона на Docker и следователно в основния драйвер за логсване.<br>Логовете в паметта трябва да се използват за отстраняване на леки проблеми с контейнери.</p>\r\n <p><b>Външните логове</b> се събират чрез API на даденото приложение.</p>\r\n <p><b>Статичните логове</b> са най-вече логове на активност, които не се записват в демона на Docker, но все още трябва да бъдат постоянни (с изключение на логовете на API).</p>",
+ "login_time": "Време",
+ "logs": "Логове",
+ "memory": "Памет",
+ "online_users": "Потребители онлайн",
+ "restart_container": "Рестартиране",
+ "service": "Услуга",
+ "show_ip": "Показване на публичен IP",
+ "size": "Размер",
+ "started_at": "Стартирано в",
+ "started_on": "Стартирано на",
+ "static_logs": "Статични логове",
+ "success": "Успех",
+ "system_containers": "Система & Контейнери",
+ "timezone": "Часова зона",
+ "uptime": "Време на работа",
+ "update_available": "Има налична актуализация",
+ "no_update_available": "Системата е на последното издание",
+ "update_failed": "Не може да се провери за актуализация",
+ "username": "Потребителско име",
+ "wip": "В момента се работи"
+ },
+ "diagnostics": {
+ "cname_from_a": "Стойността е извлечена от A/AAAA запис. Това се поддържа, докато записът сочи към правилния ресурс.",
+ "dns_records": "DNS записи",
+ "dns_records_24hours": "Моля, имайте предвид, че промените в DNS може да отнемат до 24 часа, за да имат актуалното си състояние правилно отразено на тази страница. Тя е предназначена да ви позволи лесно да видите как да конфигурирате вашите DNS записи и да проверите дали всичките ви записи са правилно запазени в DNS.",
+ "dns_records_data": "Правилни данни",
+ "dns_records_docs": "Моля, вижте и <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">документацията</a>.",
+ "dns_records_name": "Име",
+ "dns_records_status": "Текущо състояние",
+ "dns_records_type": "Тип",
+ "optional": "Този запис е опционален."
+ },
+ "edit": {
+ "acl": "ACL (Разрешение)",
+ "active": "Активен",
+ "admin": "Редактиране на администратор",
+ "advanced_settings": "Разширени настройки",
+ "alias": "Редактиране на псевдоним",
+ "allow_from_smtp": "Разрешаване само на тези IP адреси да използват <b>SMTP</b>",
+ "allow_from_smtp_info": "Оставете празно, за да разрешите всички изпращачи.<br>IPv4/IPv6 адреси и мрежи.",
+ "allowed_protocols": "Разрешени протоколи за пряк потребителски достъп (не засяга протоколите за пароли на приложения)",
+ "app_name": "Име на приложението",
+ "app_passwd": "Парола за приложение",
+ "app_passwd_protocols": "Разрешени протоколи за паролата на приложението",
+ "automap": "Опит за автоматично картографиране на папки (\"Изпратени\", \"Изпратени\" => \"Изпратени\" и т.н.)",
+ "backup_mx_options": "Опции за реле",
+ "bcc_dest_format": "BCC дестинацията трябва да бъде един валиден имейл адрес.<br>Ако имате нужда да изпратите копие до множество адреси, създайте псевдоним и го използвайте тук.",
+ "client_id": "Идентификатор на клиента",
+ "client_secret": "Тайна на клиента",
+ "comment_info": "Частен коментар не е видим за потребителя, докато публичен коментар се показва като подсказка при преминаване с мишката върху него в прегледа на потребителя",
+ "created_on": "Създаден на",
+ "custom_attributes": "Персонализирани атрибути",
+ "delete1": "Изтриване от източника след завършване",
+ "delete2": "Изтриване на съобщенията в дестинацията, които не са в източника",
+ "delete2duplicates": "Изтриване на дубликати в дестинацията",
+ "delete_ays": "Моля, потвърдете процеса на изтриване.",
+ "description": "Описание",
+ "disable_login": "Забраняване на вход (входящите съобщения все още се приемат)",
+ "domain": "Редактиране на домейн",
+ "domain_admin": "Редактиране на администратор на домейн",
+ "domain_footer": "Подвал за домейн",
+ "domain_footer_html": "HTML подвал",
+ "domain_footer_info": "Подвалите за домейн се добавят към всички изходящи имейли, свързани с адрес в този домейн. Следните променливи могат да бъдат използвани за подвала:",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - Удостоверен потребител, посочен от MTA",
+ "from_user": "{= from_user =} - Потребителска част на обвивката, напр. за \"moo@mailcow.tld\" връща \"moo\"",
+ "from_name": "{= from_name =} - Име на обвивката, напр. за \"Mailcow <moo@mailcow.tld>\" връща \"Mailcow\"",
+ "from_addr": "{= from_addr =} - Адресна част на обвивката",
+ "from_domain": "{= from_domain =} - Домейна част на обвивката",
+ "custom": "{= foo =} - Ако пощенската кутия има персонализиран атрибут \"foo\" със стойност \"bar\", ще върне \"bar\""
+ },
+ "domain_footer_plain": "PLAIN подвал",
+ "domain_footer_skip_replies": "Игнориране на подвал в отговорни имейли",
+ "domain_quota": "Квота на домейна",
+ "domains": "Домейни",
+ "dont_check_sender_acl": "Деактивиране на проверката на изпращач за домейн %s (+ домейни на псевдоними)",
+ "edit_alias_domain": "Редактиране на домейн на псевдоним",
+ "encryption": "Криптиране",
+ "exclude": "Изключване на обекти (regex)",
+ "extended_sender_acl": "Външни адреси на изпращач",
+ "extended_sender_acl_info": "Трябва да бъде импортиран DKIM домейн ключ, ако е наличен.<br>\r\n Помнете да добавите този сървър към съответния SPF TXT запис.<br>\r\n Когато домейн или домейн на псевдоним бъде добавен към този сървър, който се припокрива с външен адрес, външният адрес ще бъде премахнат.<br>\r\n Използвайте @domain.tld, за да разрешите изпращане като *@domain.tld.",
+ "footer_exclude": "Изключване от подвал",
+ "force_pw_update": "Принудително обновяване на парола при следващия вход",
+ "force_pw_update_info": "Този потребител ще може да влезе само в %s. Паролите за приложения остават използваеми.",
+ "full_name": "Пълно име",
+ "gal": "Глобален адресен списък",
+ "gal_info": "Глобалният адресен списък съдържа всички обекти на домейна и не може да бъде редактиран от нито един потребител. Липсва информация за заетост/свободно време в SOGo, ако е деактивирано! <b>Рестартирайте SOGo, за да приложите промените.</b>",
+ "generate": "генериране",
+ "grant_types": "Типове разрешения",
+ "hostname": "Име на хост",
+ "inactive": "Неактивен",
+ "kind": "Вид",
+ "last_modified": "Последно модифициране",
+ "lookup_mx": "Дестинацията е регулярен израз за съвпадение с MX име (<code>.*\\.google\\.com</code> за пренасочване на всички съобщения, предназначени за MX, завършващ на google.com, през този хоп)",
+ "mailbox": "Редактиране на пощенска кутия",
+ "mailbox_quota_def": "Квота по подразбиране за пощенска кутия",
+ "mailbox_relayhost_info": "Прилага се за пощенската кутия и директните псевдоними само, пренарежда запис в картата на транспорта за домейн.",
+ "mailbox_rename": "Преименуване на пощенска кутия",
+ "mailbox_rename_agree": "Създадох резервно копие.",
+ "mailbox_rename_alias": "Автоматично създаване на псевдоним",
+ "mailbox_rename_title": "Ново локално име на пощенска кутия",
+ "mailbox_rename_warning": "ВНИМАНИЕ! Създайте резервно копие преди преименуване на пощенската кутия.",
+ "max_aliases": "Макс. псевдоними",
+ "max_mailboxes": "Макс. възможни пощенски кутии",
+ "max_quota": "Макс. квота за пощенска кутия (MiB)",
+ "maxage": "Максимална възраст на съобщенията в дни, които ще бъдат проверени от отдалечен<br><small>(0 = игнорирай възраст)</small>",
+ "maxbytespersecond": "Макс. байтове за секунда <br><small>(0 = неограничен)</small>",
+ "mbox_rl_info": "Това ограничение на скоростта се прилага върху SASL името за вход, то съвпада с всеки \"от\" адрес, използван от влезлия потребител. Ограничението на скоростта на пощенска кутия пренарежда ограничението на скоростта за домейн.",
+ "mins_interval": "Интервал (мин)",
+ "multiple_bookings": "Множествени резервации",
+ "nexthop": "Следващ хоп",
+ "none_inherit": "Без / Наследяване",
+ "password": "Парола",
+ "password_recovery_email": "Имейл за възстановяване на парола",
+ "password_repeat": "Потвърждаване на паролата (повторете)",
+ "previous": "Предишна страница",
+ "private_comment": "Частен коментар",
+ "public_comment": "Публичен коментар",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Ескалиране на високоприоритетни съобщения [<code>X-Priority: 1</code>]",
+ "pushover_info": "Настройките за известия на Pushover ще се прилагат за всички чисти (не-спам) съобщения, доставени до <b>%s</b>, включително псевдоними (споделени, несподелени, таговани).",
+ "pushover_only_x_prio": "Разглеждане само на високоприоритетни съобщения [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Разглеждане само на следните адреси на изпращач <small>(разделени с запетая)</small>",
+ "pushover_sender_regex": "Разглеждане на следния regex на изпращач",
+ "pushover_sound": "Звук",
+ "pushover_text": "Текст на известието",
+ "pushover_title": "Заглавие на известието",
+ "pushover_vars": "Когато не е зададен филтър на изпращач, всички съобщения ще бъдат разглеждани.<br>Филтрите с регулярен израз, както и точните проверки на изпращач, могат да бъдат дефинирани индивидуално и ще бъдат разглеждани последователно. Те не зависят един от друг.<br>Използвайте следните променливи за текст и заглавие (моля, вземете предвид политиките за поверителност на данните)",
+ "pushover_verify": "Проверка на удостоверения",
+ "quota_mb": "Квота (MiB)",
+ "quota_warning_bcc": "Предупреждения за квота ще бъдат изпращани като отделни копия до следните получатели:",
+ "quota_warning_bcc_info": "Съобщенията ще бъдат изпратени с тема, допълнена с името на потребителя в скоби, например: <code>Предупреждение за квота (user@example.com)</code>.",
+ "ratelimit": "Ограничение на скоростта",
+ "redirect_uri": "URI за пренасочване/обратно извикване",
+ "relay_all": "Реле на всички получатели",
+ "relay_all_info": "↪ Ако изберете да <b>не</b> релеирате всички получатели, ще трябва да добавите (\"скрита\") пощенска кутия за всеки отделен получател, който трябва да бъде релеиран.",
+ "relay_domain": "Реле на този домейн",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Инфо</div> Можете да дефинирате транспортни карти за персонализирана дестинация за този домейн. Ако не е зададено, ще бъде направен MX lookup.",
+ "relay_unknown_only": "Реле на несъществуващи пощенски кутии. Съществуващите пощенски кутии ще бъдат доставени локално.",
+ "relayhost": "Транспорти, зависими от изпращач",
+ "remove": "Премахване",
+ "resource": "Ресурс",
+ "save": "Запазване на промените",
+ "scope": "Обхват",
+ "sender_acl": "Разрешаване на изпращане като",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Проверката на изпращач е деактивирана</span>",
+ "sender_acl_info": "Ако потребителят на пощенска кутия A е разрешен да изпраща като потребителя на пощенска кутия B, адресът на изпращач не се показва автоматично като избираем \"от\" поле в SOGo.<br>\r\n Потребителят на пощенска кутия B трябва да създаде делегация в SOGo, за да разреши на потребителя на пощенска кутия A да избира техния адрес като изпращач. За да делегирате пощенска кутия в SOGo, използвайте менюто (три точки) вдясно от името на пощенската кутия в горния ляв ъгъл, докато сте в режим на поща. Това поведение не се прилага за адреси на псевдоними.",
+ "sieve_desc": "Кратко описание",
+ "sieve_type": "Тип на филтър",
+ "skipcrossduplicates": "Пропускане на дублирани съобщения между папки (първи дошъл, първи обслужен)",
+ "sogo_access": "Директно препращане към SOGo",
+ "sogo_access_info": "След влизане, потребителят се пренасочва автоматично към SOGo.",
+ "sogo_visible": "Псевдонимът е видим в SOGo",
+ "sogo_visible_info": "Тази опция засяга само обекти, които могат да бъдат показани в SOGo (споделени или несподелени адреси на псевдоними, сочещи поне една локална пощенска кутия). Ако е скрит, псевдонимът няма да се появи като избираем адрес на изпращач в SOGo.",
+ "spam_alias": "Създаване или промяна на временни псевдоними",
+ "spam_filter": "Филтър за спам",
+ "spam_policy": "Добавяне или премахване на елементи към черния/бял списък",
+ "spam_score": "Задаване на персонализиран резултат за спам",
+ "subfolder2": "Синхронизиране в подпапка в дестинацията<br><small>(празно = не използвай подпапка)</small>",
+ "syncjob": "Редактиране на синхронизираща задача",
+ "target_address": "Адрес/и за пренасочване <small>(разделени с запетая)</small>",
+ "target_domain": "Целеви домейн",
+ "timeout1": "Таймаут за връзка с отдалечен хост",
+ "timeout2": "Таймаут за връзка с локален хост",
+ "title": "Редактиране на обект",
+ "unchanged_if_empty": "Ако не е променено, оставете празно",
+ "username": "Потребителско име",
+ "validate_save": "Валидиране и запазване"
+ },
+ "fido2": {
+ "confirm": "Потвърждаване",
+ "fido2_auth": "Вход с FIDO2",
+ "fido2_success": "Устройството е регистрирано успешно",
+ "fido2_validation_failed": "Проверката е неуспешна",
+ "fn": "Приятелско име",
+ "known_ids": "Известни идентификатори",
+ "none": "Деактивирано",
+ "register_status": "Състояние на регистрация",
+ "rename": "Преименуване",
+ "set_fido2": "Регистриране на FIDO2 устройство",
+ "set_fido2_touchid": "Регистриране на Touch ID на Apple M1",
+ "set_fn": "Задаване на приятелско име",
+ "start_fido2_validation": "Стартиране на проверка на FIDO2"
+ },
+ "footer": {
+ "cancel": "Отказ",
+ "confirm_delete": "Потвърждаване на изтриването",
+ "delete_now": "Изтриване сега",
+ "delete_these_items": "Моля, потвърдете промените за следния идентификатор на обект",
+ "hibp_check": "Проверка срещу haveibeenpwned.com",
+ "hibp_nok": "Съвпадение! Това е потенциално опасна парола!",
+ "hibp_ok": "Няма съвпадение.",
+ "loading": "Моля, изчакайте...",
+ "nothing_selected": "Няма избрани елементи",
+ "restart_container": "Рестартиране на контейнер",
+ "restart_container_info": "<b>Важно:</b> Грациозното рестартиране може да отнеме известно време за завършване, моля, изчакайте да приключи.",
+ "restart_now": "Рестартиране сега",
+ "restarting_container": "Рестартиране на контейнера, това може да отнеме известно време"
+ },
+ "header": {
+ "administration": "Конфигурация & Детайли",
+ "apps": "Приложения",
+ "debug": "Информация",
+ "email": "Имейл",
+ "mailcow_system": "Система",
+ "mailcow_config": "Конфигурация",
+ "quarantine": "Карантина",
+ "restart_netfilter": "Рестартиране на netfilter",
+ "restart_sogo": "Рестартиране на SOGo",
+ "user_settings": "Настройки на потребителя"
+ },
+ "info": {
+ "awaiting_tfa_confirmation": "Изчакване на потвърждение за TFA",
+ "no_action": "Няма приложимо действие",
+ "session_expires": "Вашата сесия ще изтече след около 15 секунди"
+ },
+ "login": {
+ "back_to_mailcow": "Обратно към mailcow",
+ "delayed": "Входът е забавен с %s секунди.",
+ "fido2_webauthn": "Вход с FIDO2/WebAuthn",
+ "forgot_password": "> Забравена парола?",
+ "invalid_pass_reset_token": "Токенът за нулиране на парола е невалиден или е изтекъл.<br>Моля, заявете нов линк за нулиране на парола.",
+ "login": "Вход",
+ "login_admin": "Вход на администратор",
+ "login_dadmin": "Вход на администратор на домейн",
+ "login_user": "Потребителски вход",
+ "mobileconfig_info": "Моля, влезте като потребител на пощенска кутия, за да изтеглите поискания Apple профил за връзка.",
+ "new_password": "Нова парола",
+ "new_password_confirm": "Потвърждаване на новата парола",
+ "other_logins": "или вход с",
+ "password": "Парола",
+ "request_reset_password": "Заявка за промяна на парола",
+ "reset_password": "Нулиране на парола",
+ "username": "Потребителско име"
+ },
+ "mailbox": {
+ "action": "Действие",
+ "activate": "Активиране",
+ "active": "Активен",
+ "add": "Добавяне",
+ "add_alias": "Добавяне на псевдоним",
+ "add_alias_expand": "Разширяване на псевдоним над домейни на псевдоними",
+ "add_bcc_entry": "Добавяне на запис в картата BCC",
+ "add_domain": "Добавяне на домейн",
+ "add_domain_alias": "Добавяне на псевдоним на домейн",
+ "add_domain_record_first": "Моля, добавете първо домейн",
+ "add_filter": "Добавяне на филтър",
+ "add_mailbox": "Добавяне на пощенска кутия",
+ "add_recipient_map_entry": "Добавяне на запис в картата на получатели",
+ "add_resource": "Добавяне на ресурс",
+ "add_template": "Добавяне на шаблон",
+ "add_tls_policy_map": "Добавяне на карта на политиката на TLS",
+ "address_rewriting": "Презаписване на адрес",
+ "alias": "Псевдоним",
+ "alias_domain_alias_hint": "Псевдонимите <b>не</b> се прилагат автоматично към домейни на псевдоними. Псевдонимът <code>my-alias@domain</code> <b>не</b> покрива адреса <code>my-alias@alias-domain</code> (където \"alias-domain\" е имагинерен псевдоним на домейн).<br>Моля, използвайте филтър на Sieve, за да пренасочите имейл към външна пощенска кутия (вижте раздела \"Филтри\" или SOGo -> Пренасочвач). Използвайте \"Разширяване на псевдоним над домейни на псевдоними\", за да добавите автоматично липсващи псевдоними.",
+ "alias_domain_backupmx": "Псевдонимът на домейн е неактивен за домейн за реле",
+ "aliases": "Псевдоними",
+ "all_domains": "Всички домейни",
+ "allow_from_smtp": "Разрешаване само на тези IP адреси да използват <b>SMTP</b>",
+ "allow_from_smtp_info": "Оставете празно, за да разрешите всички изпращачи.<br>IPv4/IPv6 адреси и мрежи.",
+ "allowed_protocols": "Разрешени протоколи",
+ "backup_mx": "Домейн за реле",
+ "bcc": "BCC",
+ "bcc_destination": "BCC дестинация",
+ "bcc_destinations": "BCC дестинации",
+ "bcc_info": "Картите BCC се използват, за да препращат тихо копия от всички съобщения до друг адрес. Записът от тип получател на карта се използва, когато локалната дестинация действа като получател на имейл. Записът от тип изпращач на карта се използва, когато локалната дестинация действа като изпращач на имейл. Локалната дестинация няма да бъде информирана за неуспешна доставка.",
+ "bcc_local_dest": "Локална дестинация",
+ "bcc_map": "Карта BCC",
+ "bcc_map_type": "Тип BCC",
+ "bcc_maps": "Карти BCC",
+ "bcc_rcpt_map": "Карта на получател",
+ "bcc_sender_map": "Карта на изпращач",
+ "bcc_to_rcpt": "Превключване към карта на получател",
+ "bcc_to_sender": "Превключване към карта на изпращач",
+ "bcc_type": "Тип BCC",
+ "booking_null": "Винаги показване като свободен",
+ "booking_0_short": "Винаги свободен",
+ "booking_custom": "Твърдо ограничение до определен брой резервации",
+ "booking_custom_short": "Твърдо ограничение",
+ "booking_ltnull": "Неограничено, но показване като заето, когато е резервирано",
+ "booking_lt0_short": "Меко ограничение",
+ "catch_all": "Catch-All",
+ "created_on": "Създаден на",
+ "daily": "Ежедневно",
+ "deactivate": "Деактивиране",
+ "description": "Описание",
+ "disable_login": "Забраняване на вход (входящите съобщения все още се приемат)",
+ "disable_x": "Деактивиране",
+ "dkim_domains_selector": "Селектор",
+ "dkim_key_length": "Дължина на DKIM ключа (битове)",
+ "domain": "Домейн",
+ "domain_admins": "Администратори на домейн",
+ "domain_aliases": "Псевдоними на домейн",
+ "domain_templates": "Шаблони за домейн",
+ "domain_quota": "Квота",
+ "domain_quota_total": "Обща квота на домейна",
+ "domains": "Домейни",
+ "edit": "Редактиране",
+ "empty": "Няма резултати",
+ "enable_x": "Активиране",
+ "excludes": "Изключване",
+ "filter_table": "Таблица с филтри",
+ "filters": "Филтри",
+ "fname": "Пълно име",
+ "force_pw_update": "Принудително обновяване на парола при следващия вход",
+ "gal": "Глобален адресен списък",
+ "goto_ham": "Учен като <span class=\"text-success\"><b>не е спам</b></span>",
+ "goto_spam": "Учен като <span class=\"text-danger\"><b>спам</b></span>",
+ "hourly": "Часово",
+ "iam": "Доставчик на идентичност",
+ "in_use": "В употреба (%)",
+ "inactive": "Неактивен",
+ "insert_preset": "Вмъкване на примерен предефиниран набор \"%s\"",
+ "kind": "Вид",
+ "last_mail_login": "Последен вход в пощата",
+ "last_modified": "Последно модифициране",
+ "last_pw_change": "Последна промяна на парола",
+ "last_run": "Последно изпълнение",
+ "last_run_reset": "Задаване на следващо",
+ "mailbox": "Пощенска кутия",
+ "mailbox_defaults": "Настройки по подразбиране",
+ "mailbox_defaults_info": "Дефинирайте настройки по подразбиране за нови пощенски кутии.",
+ "mailbox_defquota": "Размер по подразбиране на пощенска кутия",
+ "mailbox_templates": "Шаблони за пощенска кутия",
+ "mailbox_quota": "Макс. размер на пощенска кутия",
+ "mailboxes": "Пощенски кутии",
+ "max_aliases": "Макс. псевдоними",
+ "max_mailboxes": "Макс. възможни пощенски кутии",
+ "max_quota": "Макс. квота за пощенска кутия",
+ "mins_interval": "Интервал (мин)",
+ "msg_num": "Съобщение №",
+ "multiple_bookings": "Множествени резервации",
+ "never": "Никога",
+ "no": "✕",
+ "no_record": "Няма запис за обект %s",
+ "no_record_single": "Няма запис",
+ "open_logs": "Отваряне на логове",
+ "owner": "Собственик",
+ "private_comment": "Частен коментар",
+ "public_comment": "Публичен коментар",
+ "q_add_header": "при преместване в папката за нежелана поща",
+ "q_all": " при преместване в папката за нежелана поща и при отхвърляне",
+ "q_reject": "при отхвърляне",
+ "quarantine_category": "Категория на уведомленията за карантина",
+ "quarantine_notification": "Уведомления за карантина",
+ "quick_actions": "Действия",
+ "recipient": "Получател",
+ "recipient_map": "Карта на получател",
+ "recipient_map_info": "Картите на получател се използват, за да се замени адресът на дестинация на съобщението, преди да бъде доставено.",
+ "recipient_map_new": "Нов получател",
+ "recipient_map_new_info": "Дестинацията на картата на получател трябва да бъде валиден имейл адрес или име на домейн.",
+ "recipient_map_old": "Оригинален получател",
+ "recipient_map_old_info": "Оригиналната дестинация на картата на получател трябва да бъде валиден имейл адрес или име на домейн.",
+ "recipient_maps": "Карти на получател",
+ "relay_all": "Реле на всички получатели",
+ "relay_unknown": "Реле на несъществуващи пощенски кутии",
+ "remove": "Премахване",
+ "resources": "Ресурси",
+ "running": "Изпълнява се",
+ "sender": "Изпращач",
+ "set_postfilter": "Маркиране като постфилтър",
+ "set_prefilter": "Маркиране като префилтър",
+ "sieve_info": "Можете да запазите множество филтри за всеки потребител, но само един префилтър и един постфилтър могат да бъдат активни едновременно.<br>\r\nВсеки филтър ще бъде обработен в описания ред. Нито един неуспешен скрипт, нито издадена команда \"keep;\" няма да спре обработката на следващите скриптове. Промените в глобалните филтри на sieve ще предизвикат рестартиране на Dovecot.<br><br>Глобален префилтър на sieve • Префилтър • Потребителски скриптове • Постфилтър • Глобален постфилтър на sieve",
+ "sieve_preset_1": "Изтриване на съобщения с потенциално опасни типове файлове",
+ "sieve_preset_2": "Винаги маркиране на имейла на определен изпращач като прочетен",
+ "sieve_preset_3": "Тихо изтриване, спиране на всякаква допълнителна обработка на sieve филтри",
+ "sieve_preset_4": "Архивиране на съобщението във ВХОДНА, пропускане на допълнителна обработка от sieve филтри",
+ "sieve_preset_5": "Автоотговор (ваканция)",
+ "sieve_preset_6": "Отхвърляне на съобщение с отговор",
+ "sieve_preset_7": "Пренасочване и запазване/изтриване",
+ "sieve_preset_8": "Пренасочване на имейл от определен изпращач, маркиране като прочетен и сортиране в подпапка",
+ "sieve_preset_header": "Моля, вижте примерните предефинирани набори по-долу. За повече детайли вижте <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedia</a>.",
+ "sogo_visible": "Псевдонимът е видим в SOGo",
+ "sogo_visible_n": "Скриване на псевдоним в SOGo",
+ "sogo_visible_y": "Показване на псевдоним в SOGo",
+ "spam_aliases": "Времеви псевдоними",
+ "stats": "Статистика",
+ "status": "Статус",
+ "sync_jobs": "Синхронизиращи задачи",
+ "syncjob_check_log": "Проверка на лога",
+ "syncjob_last_run_result": "Резултат от последното изпълнение",
+ "syncjob_EX_OK": "Успех",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Проблем с връзката",
+ "syncjob_EXIT_TLS_FAILURE": "Проблем с криптираната връзка",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Проблем с удостоверяването",
+ "syncjob_EXIT_OVERQUOTA": "Целевата пощенска кутия е над квотата",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Не може да се свърже с отдалечен сървър",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Грешно потребителско име или парола",
+ "table_size": "Размер на таблицата",
+ "table_size_show_n": "Показване на %s елемента",
+ "target_address": "Адрес за пренасочване",
+ "target_domain": "Целеви домейн",
+ "templates": "Шаблони",
+ "template": "Шаблон",
+ "tls_enforce_in": "Принудително използване на TLS за входящи",
+ "tls_enforce_out": "Принудително използване на TLS за изходящи",
+ "tls_map_dest": "Дестинация",
+ "tls_map_dest_info": "Примери: example.org, .example.org, [mail.example.org]:25",
+ "tls_map_parameters": "Параметри",
+ "tls_map_parameters_info": "Празно или параметри, например: protocols=!SSLv2 ciphers=medium exclude=3DES",
+ "tls_map_policy": "Политика",
+ "tls_policy_maps": "Пренареждания на политиката на TLS",
+ "tls_policy_maps_enforced_tls": "Тези политики ще пренареждат и поведението за потребители на пощенски кутии, които принудително използват изходящи TLS връзки. Ако няма политика, съществуваща по-долу, тези потребители ще приложат стойностите по подразбиране, зададени като <code>smtp_tls_mandatory_protocols</code> и <code>smtp_tls_mandatory_ciphers</code>.",
+ "tls_policy_maps_info": "Тази политика за пренареждане на TLS транспортни правила е независима от настройките за политика на TLS на потребителя.<br>\r\n Моля, вижте <a href=\"http://www.postfix.org/postconf.5.html#smtp_tls_policy_maps\" target=\"_blank\">документацията за \"smtp_tls_policy_maps\"</a> за повече информация.",
+ "tls_policy_maps_long": "Пренареждания на политиката на TLS за изходящи",
+ "toggle_all": "Превключване на всички",
+ "username": "Потребителско име",
+ "waiting": "Изчакване",
+ "weekly": "Седмично",
+ "yes": "✓"
+ },
+ "oauth2": {
+ "access_denied": "Моля, влезте като собственик на пощенска кутия, за да удостоверите чрез OAuth2.",
+ "authorize_app": "Удостоверяване на приложение",
+ "deny": "Отказ",
+ "permit": "Удостоверяване на приложение",
+ "profile": "Профил",
+ "profile_desc": "Преглед на лични данни: потребителско име, пълно име, създадено, модифицирано, активно",
+ "scope_ask_permission": "Приложението заявява следните разрешения"
+ },
+ "quarantine": {
+ "action": "Действие",
+ "atts": "Прикачени файлове",
+ "check_hash": "Търсене на файлов хеш в VirusTotal",
+ "confirm": "Потвърждаване",
+ "confirm_delete": "Потвърждаване на изтриването на този елемент.",
+ "danger": "Опасност",
+ "deliver_inbox": "Доставяне в пощенската кутия",
+ "disabled_by_config": "Текущата системна конфигурация деактивира функционалността на карантината. Моля, задайте \"задържания за пощенска кутия\" и \"максимален размер\" за елементите на карантината.",
+ "download_eml": "Изтегляне (.eml)",
+ "empty": "Няма резултати",
+ "high_danger": "Висока",
+ "info": "Информация",
+ "junk_folder": "Папка за нежелана поща",
+ "learn_spam_delete": "Учен като спам и изтриване",
+ "low_danger": "Ниска",
+ "medium_danger": "Средна",
+ "neutral_danger": "Неутрална",
+ "notified": "Уведомен",
+ "qhandler_success": "Заявката е изпратена успешно до системата. Можете да затворите прозореца сега.",
+ "qid": "QID на Rspamd",
+ "qinfo": "Системата за карантина ще запази отхвърлените съобщения в базата данни (изпращачът няма да бъде информиран за доставеното съобщение) както и съобщенията, доставени като копие в папката за нежелана поща на пощенска кутия.<br> <br>\"Учен като спам и изтриване\" ще научи съобщението като спам чрез теоремата на Бейс и също ще изчисли размити хешове, за да отхвърли подобни съобщения в бъдеще.<br> <br>Моля, имайте предвид, че обучаването на множество съобщения може да бъде - в зависимост от вашата система - времеемко.<br>Елементите в черния списък са изключени от карантината.",
+ "qitem": "Елемент в карантина",
+ "quarantine": "Карантина",
+ "quick_actions": "Действия",
+ "quick_delete_link": "Отваряне на бърз линк за изтриване",
+ "quick_info_link": "Отваряне на бърз информационен линк",
+ "quick_release_link": "Отваряне на бърз линк за освобождане",
+ "rcpt": "Получател",
+ "received": "Получено",
+ "recipients": "Получатели",
+ "refresh": "Опресняване",
+ "rejected": "Отхвърлено",
+ "release": "Освобождане",
+ "release_body": "Прикаченото съобщение е добавено към това съобщение.",
+ "release_subject": "Потенциално вреден елемент в карантина %s",
+ "remove": "Премахване",
+ "rewrite_subject": "Презаписване на темата",
+ "rspamd_result": "Резултат от Rspamd",
+ "sender": "Изпращач (SMTP)",
+ "sender_header": "Изпращач (\"From\" заглавие)",
+ "settings_info": "Максимален брой елементи за карантиниране: %s<br>Максимален размер на имейл: %s MiB",
+ "show_item": "Показване на елемент",
+ "spam": "Спам",
+ "spam_score": "Резултат",
+ "subj": "Тема",
+ "table_size": "Размер на таблицата",
+ "table_size_show_n": "Показване на %s елемента",
+ "text_from_html_content": "Съдържание (конвертиран HTML)",
+ "text_plain_content": "Съдържание (обикновен текст)",
+ "toggle_all": "Превключване на всички",
+ "type": "Тип"
+ },
+ "queue": {
+ "delete": "Изтриване на всички",
+ "flush": "Изчистване на опашката",
+ "info": "Опашката на имейлите съдържа всички имейли, които чакат за доставка. Ако имейлът е засечен в опашката за дълго време, той автоматично се изтрива от системата.<br>Съобщението за грешка на съответния имейл дава информация защо имейлът не може да бъде доставен.",
+ "legend": "Функции на действията в опашката на имейлите:",
+ "ays": "Моля, потвърдете, че искате да изтриете всички елементи от текущата опашка.",
+ "deliver_mail": "Доставяне",
+ "deliver_mail_legend": "Опит за повторно доставяне на избраните съобщения.",
+ "hold_mail": "Задържане",
+ "hold_mail_legend": "Задържа избраните съобщения. (Предотвратява допълнителни опити за доставяне)",
+ "queue_manager": "Мениджър на опашката",
+ "show_message": "Показване на съобщение",
+ "unban": "разблокиране на опашката",
+ "unhold_mail": "Освобождаване",
+ "unhold_mail_legend": "Освобождава избраните съобщения за доставка. (Изисква предварително задържане)"
+ },
+ "ratelimit": {
+ "disabled": "Деактивирано",
+ "second": "съобщения/секунда",
+ "minute": "съобщения/минута",
+ "hour": "съобщения/час",
+ "day": "съобщения/ден"
+ },
+ "start": {
+ "help": "Показване/Скриване на панела за помощ",
+ "imap_smtp_server_auth_info": "Моля, използвайте пълния си имейл адрес и механизма за удостоверяване PLAIN.<br>\r\nВашите данни за вход ще бъдат криптирани от сървърната страна чрез задължително сървърно криптиране."
+ },
+ "success": {
+ "acl_saved": "ACL за обект %s е запазен",
+ "admin_added": "Администраторът %s е добавен",
+ "admin_api_modified": "Промените в API са запазени",
+ "admin_modified": "Промените в администратора са запазени",
+ "admin_removed": "Администраторът %s е премахнат",
+ "alias_added": "Адресът на псевдонима %s (%d) е добавен",
+ "alias_domain_removed": "Домейнът на псевдонима %s е премахнат",
+ "alias_modified": "Промените в адреса на псевдонима %s са запазени",
+ "alias_removed": "Псевдонимът %s е премахнат",
+ "aliasd_added": "Добавен домейн на псевдоним %s",
+ "aliasd_modified": "Промените в домейна на псевдоним %s са запазени",
+ "app_links": "Запазени промени в линковете на приложенията",
+ "app_passwd_added": "Добавена нова парола за приложение",
+ "app_passwd_removed": "Премахната парола за приложение с ID %s",
+ "bcc_deleted": "Записи в картата BCC са изтрити: %s",
+ "bcc_edited": "Записът в картата BCC %s е редактиран",
+ "bcc_saved": "Записът в картата BCC е запазен",
+ "cors_headers_edited": "Настройките на CORS са запазени",
+ "db_init_complete": "Инициализацията на базата данни е завършена",
+ "delete_filter": "Изтрити филтри с ID %s",
+ "delete_filters": "Изтрити филтри: %s",
+ "deleted_syncjob": "Изтрита синхронизираща задача с ID %s",
+ "deleted_syncjobs": "Изтрити синхронизиращи задачи: %s",
+ "dkim_added": "Добавен DKIM ключ %s",
+ "dkim_duplicated": "DKIM ключът за домейн %s е копиран в %s",
+ "dkim_removed": "DKIM ключът %s е премахнат",
+ "domain_add_dkim_available": "DKIM ключът вече съществува",
+ "domain_added": "Добавен домейн %s",
+ "domain_admin_added": "Добавен администратор на домейн %s",
+ "domain_admin_modified": "Промените в администратора на домейн %s са запазени",
+ "domain_admin_removed": "Администраторът на домейн %s е премахнат",
+ "domain_footer_modified": "Промените в подвала на домейн %s са запазени",
+ "domain_modified": "Промените в домейн %s са запазени",
+ "domain_removed": "Домейнът %s е премахнат",
+ "dovecot_restart_success": "Dovecot е рестартиран успешно",
+ "eas_reset": "Устройствата с ActiveSync за потребителя %s са нулирани",
+ "f2b_banlist_refreshed": "Списъкът с ID на блокираните е актуализиран успешно.",
+ "f2b_modified": "Промените в параметрите на Fail2ban са запазени",
+ "forwarding_host_added": "Добавен хост за препращане %s",
+ "forwarding_host_removed": "Премахнат хост за препращане %s",
+ "global_filter_written": "Филтърът е записан успешно във файл",
+ "hash_deleted": "Хешът е изтрит",
+ "iam_test_connection": "Връзката е успешна",
+ "ip_check_opt_in_modified": "Проверката на IP беше успешно запазена",
+ "item_deleted": "Елементът %s е изтрит успешно",
+ "item_released": "Елементът %s е освободен",
+ "items_deleted": "Елементът %s е изтрит успешно",
+ "items_released": "Избраните елементи са освободени",
+ "learned_ham": "Успешно научен ID %s като не е спам",
+ "license_modified": "Промените в лиценза са запазени",
+ "logged_in_as": "Вписан като %s",
+ "mailbox_added": "Пощенската кутия %s е добавена",
+ "mailbox_modified": "Промените в пощенската кутия %s са запазени",
+ "mailbox_removed": "Пощенската кутия %s е премахната",
+ "mailbox_renamed": "Пощенската кутия е преименувана от %s на %s",
+ "nginx_reloaded": "Nginx е презареден",
+ "object_modified": "Промените в обект %s са запазени",
+ "password_changed_success": "Паролата е променена успешно",
+ "password_policy_saved": "Политиката за парола е запазена успешно",
+ "pushover_settings_edited": "Настройките на Pushover са запазени успешно, моля, проверете удостоверенията.",
+ "qlearn_spam": "Съобщението с ID %s е научено като спам и изтрито",
+ "queue_command_success": "Командата на опашката е завършена успешно",
+ "recipient_map_entry_deleted": "Записът в картата на получател с ID %s е изтрит",
+ "recipient_map_entry_saved": "Записът в картата на получател \"%s\" е запазен",
+ "recovery_email_sent": "Изпратен имейл за възстановяване до %s",
+ "relayhost_added": "Записът в картата %s е добавен",
+ "relayhost_removed": "Записът в картата %s е премахнат",
+ "reset_main_logo": "Нулиране на логото по подразбиране",
+ "resource_added": "Ресурсът %s е добавен",
+ "resource_modified": "Промените в пощенската кутия %s са запазени",
+ "resource_removed": "Ресурсът %s е премахнат",
+ "rl_saved": "Ограничението на скоростта за обект %s е запазено",
+ "rspamd_ui_pw_set": "Паролата на UI на Rspamd е зададена успешно",
+ "saved_settings": "Запазени настройки",
+ "settings_map_added": "Добавен запис в картата с настройки",
+ "settings_map_removed": "Премахнат запис в картата с настройки с ID %s",
+ "sogo_profile_reset": "Профилът на SOGo за потребителя %s е нулиран",
+ "template_added": "Добавен шаблон %s",
+ "template_modified": "Промените в шаблон %s са запазени",
+ "template_removed": "Шаблонът с ID %s е премахнат",
+ "tls_policy_map_entry_deleted": "Записът в картата на политиката на TLS с ID %s е изтрит",
+ "tls_policy_map_entry_saved": "Записът в картата на политиката на TLS \"%s\" е запазен",
+ "ui_texts": "Запазени промени в текстовете на UI",
+ "upload_success": "Файлът е качен успешно",
+ "verified_fido2_login": "Потвърдено вход с FIDO2",
+ "verified_totp_login": "Потвърдено вход с TOTP",
+ "verified_webauthn_login": "Потвърдено вход с WebAuthn",
+ "verified_yotp_login": "Потвърдено вход с Yubico OTP"
+ },
+ "tfa": {
+ "authenticators": "Аутентикатори",
+ "api_register": "%s използва облачното API на Yubico. Моля, вземете API ключ за вашия ключ <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">тук</a>",
+ "confirm": "Потвърждаване",
+ "confirm_totp_token": "Моля, потвърдете промените, като въведете генерирания токен",
+ "delete_tfa": "Деактивиране на TFA",
+ "disable_tfa": "Деактивиране на TFA до следващия успешен вход",
+ "enter_qr_code": "Вашият TOTP код, ако вашето устройство не може да сканира QR кодове",
+ "error_code": "Код на грешка",
+ "init_webauthn": "Инициализиране, моля, изчакайте...",
+ "key_id": "Идентификатор за вашето устройство",
+ "key_id_totp": "Идентификатор за вашия ключ",
+ "none": "Деактивиране",
+ "reload_retry": "- (презаредете браузъра, ако грешката продължи)",
+ "scan_qr_code": "Моля, сканирайте следния код с вашето приложение за аутентикация или въведете кода ръчно.",
+ "select": "Моля, изберете",
+ "set_tfa": "Задаване на метод за двуфакторно удостоверяване",
+ "start_webauthn_validation": "Стартиране на проверка",
+ "tfa": "Двуфакторно удостоверяване",
+ "tfa_token_invalid": "Невалиден токен за TFA",
+ "totp": "Временен OTP (Google Authenticator, Authy и др.)",
+ "u2f_deprecated": "Изглежда, че вашият ключ е регистриран с депрекирания метод U2F. Ще деактивираме двуфакторното удостоверяване за вас и ще изтрием вашия ключ.",
+ "u2f_deprecated_important": "Моля, регистрирайте вашия ключ в административния панел с новия метод WebAuthn.",
+ "webauthn": "Удостоверяване с WebAuthn",
+ "waiting_usb_auth": "<i>Изчакване на USB устройство...</i><br><br>Моля, докоснете бутона на вашето USB устройство сега.",
+ "waiting_usb_register": "<i>Изчакване на USB устройство...</i><br><br>Моля, въведете паролата си по-горе и потвърдете регистрацията си, като докоснете бутона на вашето USB устройство.",
+ "yubi_otp": "Удостоверяване с Yubico OTP"
+ },
+ "user": {
+ "action": "Действие",
+ "active": "Активен",
+ "active_sieve": "Активен филтър",
+ "advanced_settings": "Разширени настройки",
+ "alias": "Псевдоним",
+ "alias_create_random": "Генериране на случаен псевдоним",
+ "alias_extend_all": "Удължаване на всички псевдоними с 1 час",
+ "alias_full_date": "d.m.Y, H:i:s T",
+ "alias_remove_all": "Премахване на всички псевдоними",
+ "alias_select_validity": "Период на валидност",
+ "alias_time_left": "Оставащо време",
+ "alias_valid_until": "Валиден до",
+ "aliases_also_send_as": "Разрешено да изпраща и като потребител",
+ "aliases_send_as_all": "Не проверявай достъпа на изпращач за следните домейни и техните псевдоними",
+ "allowed_protocols": "Разрешени протоколи",
+ "app_hint": "Паролите за приложения са алтернативни пароли за вашия IMAP, SMTP, CalDAV, CardDAV и EAS вход. Потребителското име остава непроменено. SOGo уеб пощата не е достъпна чрез пароли за приложения.",
+ "app_name": "Име на приложението",
+ "app_passwds": "Пароли за приложения",
+ "apple_connection_profile": "Профил за връзка на Apple",
+ "apple_connection_profile_complete": "Този профил за връзка включва настройки за IMAP и SMTP, както и пътища за CalDAV (календари) и CardDAV (контакти) за устройство на Apple.",
+ "apple_connection_profile_mailonly": "Този профил за връзка включва настройки за IMAP и SMTP за устройство на Apple.",
+ "apple_connection_profile_with_app_password": "Генерирана е нова парола за приложение и е добавена към профила, така че не е необходимо да се въвежда парола при настройката на вашето устройство. Моля, не споделяйте файла, тъй като той предоставя пълен достъп до вашата пощенска кутия.",
+ "attribute": "Атрибут",
+ "authentication": "Удостоверяване",
+ "change_password": "Промяна на парола",
+ "change_password_hint_app_passwords": "Вашият акаунт има %d пароли за приложения, които няма да бъдат променени. За управление на тях, отидете в раздела \"Пароли за приложения\".",
+ "clear_recent_successful_connections": "Изчистване на видимите успешни връзки",
+ "client_configuration": "Показване на ръководства за настройка на пощенски клиенти и смартфони",
+ "create_app_passwd": "Създаване на парола за приложение",
+ "create_syncjob": "Създаване на нова синхронизираща задача",
+ "created_on": "Създаден на",
+ "daily": "Ежедневно",
+ "day": "ден",
+ "delete_ays": "Моля, потвърдете процеса на изтриване.",
+ "description": "Описание",
+ "direct_aliases": "Директни адреси на псевдоними",
+ "direct_aliases_desc": "Директните адреси на псевдоними се засягат от настройките за филтър за спам и политика за TLS.",
+ "direct_protocol_access": "Този потребител на пощенска кутия има <b>директен, външен достъп</b> до следните протоколи и приложения. Тази настройка се контролира от вашия администратор. Паролите за приложения могат да бъдат създадени, за да се предостави достъп до отделни протоколи и приложения.<br>Бутонът \"Уеб поща\" предоставя еднократно удостоверяване към SOGo и винаги е достъпен.",
+ "eas_reset": "Нулиране на кеша на устройствата с ActiveSync",
+ "eas_reset_help": "В много случаи нулирането на кеша на устройството ще помогне за възстановяването на повреден профил на ActiveSync.<br><b>Внимание:</b> Всички елементи ще бъдат презаредени!",
+ "eas_reset_now": "Нулиране сега",
+ "edit": "Редактиране",
+ "email": "Имейл",
+ "email_and_dav": "Имейл, календари и контакти",
+ "empty": "Няма резултати",
+ "encryption": "Криптиране",
+ "excludes": "Изключване",
+ "expire_in": "Изтича след",
+ "fido2_webauthn": "FIDO2/WebAuthn",
+ "force_pw_update": "Трябва да зададете нова парола, за да имате достъп до груповите услуги.",
+ "from": "от",
+ "generate": "генериране",
+ "hour": "час",
+ "hourly": "Часово",
+ "hours": "часа",
+ "in_use": "В употреба",
+ "interval": "Интервал",
+ "is_catch_all": "Catch-all за домейн/и",
+ "last_mail_login": "Последен вход в пощата",
+ "last_pw_change": "Последна промяна на парола",
+ "last_run": "Последно изпълнение",
+ "last_ui_login": "Последен вход в UI",
+ "loading": "Зареждане...",
+ "login_history": "История на входовете",
+ "mailbox": "Пощенска кутия",
+ "mailbox_details": "Детайли",
+ "mailbox_general": "Общи",
+ "mailbox_settings": "Настройки",
+ "messages": "съобщения",
+ "month": "месец",
+ "months": "месеца",
+ "never": "Никога",
+ "new_password": "Нова парола",
+ "new_password_repeat": "Потвърждаване на новата парола",
+ "no_active_filter": "Няма активен филтър",
+ "no_last_login": "Няма информация за последен вход в UI",
+ "no_record": "Няма запис",
+ "open_logs": "Отваряне на логове",
+ "open_webmail_sso": "Уеб поща",
+ "overview": "Преглед",
+ "password": "Парола",
+ "password_now": "Текуща парола (потвърждаване на промените)",
+ "password_repeat": "Парола (повторете)",
+ "password_reset_info": "Ако не е зададен имейл за възстановяване на парола, тази функция не може да бъде използвана.",
+ "protocols": "Протоколи",
+ "pushover_evaluate_x_prio": "Ескалиране на високоприоритетни съобщения [<code>X-Priority: 1</code>]",
+ "pushover_info": "Настройките за известия на Pushover ще се прилагат за всички чисти (не-спам) съобщения, доставени до <b>%s</b>, включително псевдоними (споделени, несподелени, таговани).",
+ "pushover_only_x_prio": "Разглеждане само на високоприоритетни съобщения [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Разглеждане на следните адреси на изпращач <small>(разделени с запетая)</small>",
+ "pushover_sender_regex": "Съвпадение на изпращач с следния regex",
+ "pushover_sound": "Звук",
+ "pushover_text": "Текст на известието",
+ "pushover_title": "Заглавие на известието",
+ "pushover_vars": "Когато не е зададен филтър на изпращач, всички съобщения ще бъдат разглеждани.<br>Филтрите с регулярен израз, както и точните проверки на изпращач, могат да бъдат дефинирани индивидуално и ще бъдат разглеждани последователно. Те не зависят един от друг.<br>Използвайте следните променливи за текст и заглавие (моля, вземете предвид политиките за поверителност на данните)",
+ "pushover_verify": "Проверка на удостоверения",
+ "pw_recovery_email": "Имейл за възстановяване на парола",
+ "q_add_header": "Папка за нежелана поща",
+ "q_all": "Всички категории",
+ "q_reject": "Отхвърлени",
+ "quarantine_category": "Категория на уведомленията за карантина",
+ "quarantine_category_info": "Категорията \"Отхвърлени\" включва съобщения, които са били отхвърлени, докато категорията \"Папка за нежелана поща\" ще уведоми потребителя за съобщения, които са били поставени в папката за нежелана поща.",
+ "quarantine_notification": "Уведомления за карантина",
+ "quarantine_notification_info": "След като уведомлението е изпратено, елементите ще бъдат маркирани като \"уведомени\" и няма да бъдат изпращани допълнителни уведомления за този конкретен елемент.",
+ "recent_successful_connections": "Видими успешни връзки",
+ "remove": "Премахване",
+ "running": "Изпълнява се",
+ "save": "Запазване на промените",
+ "save_changes": "Запазване на промените",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Проверката на изпращач е деактивирана</span>",
+ "shared_aliases": "Споделени адреси на псевдоними",
+ "shared_aliases_desc": "Споделените псевдоними не се засягат от настройките за филтър за спам и политика за TLS на потребителя. Съответните настройки за спам филтър могат да бъдат направени само от администратор като настройка за домейн.",
+ "show_sieve_filters": "Показване на активния потребителски филтър на sieve",
+ "sogo_profile_reset": "Нулиране на профила на SOGo",
+ "sogo_profile_reset_help": "Това ще унищожи профила на SOGo и <b>ще изтрие всички данни за контакти и календар безвъзвратно</b>.",
+ "sogo_profile_reset_now": "Нулиране сега",
+ "spam_aliases": "Временни адреси на псевдоними",
+ "spam_score_reset": "Нулиране до настройките на сървъра по подразбиране",
+ "spamfilter": "Филтър за спам",
+ "spamfilter_behavior": "Рейтинг",
+ "spamfilter_bl": "Черен списък",
+ "spamfilter_bl_desc": "Адресите в черния списък <b>винаги</b> ще бъдат класифицирани като спам и отхвърлени. Отхвърлените съобщения <b>не</b> ще бъдат копирани в карантина. Поддържат се уайлдкардове.<br>Отхвърлените съобщения няма да бъдат доставени до папката за нежелана поща.",
+ "spamfilter_default_score": "Стойности по подразбиране",
+ "spamfilter_green": "Зелено: това съобщение не е спам",
+ "spamfilter_hint": "Първата стойност описва \"нисък резултат за спам\", втората представлява \"висок резултат за спам\".",
+ "spamfilter_red": "Червено: това съобщение е спам и ще бъде отхвърлено от сървъра",
+ "spamfilter_table_action": "Действие",
+ "spamfilter_table_add": "Добавяне на елемент",
+ "spamfilter_table_domain_policy": "политика на домейна",
+ "spamfilter_table_empty": "Няма данни за показване",
+ "spamfilter_table_remove": "премахване",
+ "spamfilter_table_rule": "Правило",
+ "spamfilter_wl": "Бял списък",
+ "spamfilter_wl_desc": "Адресите в белия списък <b>никога</b> ще бъдат класифицирани като спам. Поддържат се уайлдкардове.<br>Съобщенията, които не са класифицирани като спам, ще бъдат доставени в папката за нежелана поща, ако резултатът за спам е над стойността за висок резултат за спам.",
+ "spamfilter_yellow": "Жълто: това съобщение може да е спам, ще бъде маркирано като спам и преместено в папката за нежелана поща",
+ "status": "Статус",
+ "sync_jobs": "Синхронизиращи задачи",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Проблем с удостоверяването",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Грешно потребителско име или парола",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Проблем с връзката",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Не може да се свърже с отдалечен сървър",
+ "syncjob_EXIT_OVERQUOTA": "Целевата пощенска кутия е над квотата",
+ "syncjob_EXIT_TLS_FAILURE": "Проблем с криптираната връзка",
+ "syncjob_EX_OK": "Успех",
+ "syncjob_check_log": "Проверка на лога",
+ "syncjob_last_run_result": "Резултат от последното изпълнение",
+ "tag_handling": "Настройка за тагове",
+ "tag_help_example": "Пример за тагован имейл адрес: me<b>+Facebook</b>@example.org",
+ "tag_help_explain": "В подпапка: ще бъде създадена нова подпапка под INBOX (\"INBOX/Facebook\").<br>\r\nВ тема: първото име на тага ще бъде добавено към темата на съобщението, например: \"[Facebook] Моите новини\".",
+ "tag_in_none": "Не прави нищо",
+ "tag_in_subfolder": "В подпапка",
+ "tag_in_subject": "В тема",
+ "text": "Текст",
+ "tfa_info": "Двуфакторното удостоверяване помага за защита на вашия акаунт. Ако го активирате, ще ви трябват пароли за приложения, за да влезете в приложения или услуги, които не поддържат двуфакторно удостоверяване (напр. пощенски клиенти).",
+ "title": "Заглавие",
+ "tls_enforce_in": "Принудително използване на TLS за входящи",
+ "tls_enforce_out": "Принудително използване на TLS за изходящи",
+ "tls_policy": "Политика за криптиране",
+ "tls_policy_warning": "<strong>Внимание:</strong> Ако решите да принудите преноса на криптирани съобщения, може да загубите съобщения.<br>Съобщенията, които не удовлетворяват политиката, ще бъдат върнати с твърдо отхвърляне от системата за поща.<br>Тази опция засяга вашия основен адрес на пощенска кутия (логин име), всички адреси, произтичащи от домейни на псевдоними, както и адреси на псевдоними, <b>с единствена целева пощенска кутия</b>.",
+ "user_settings": "Настройки на потребителя",
+ "username": "Потребителско име",
+ "value": "Стойност",
+ "verify": "Проверка",
+ "waiting": "Изчакване",
+ "week": "седмица",
+ "weekly": "Weekly",
+ "weeks": "седмици",
+ "with_app_password": "с парола за приложение",
+ "year": "година",
+ "years": "години"
+ },
+ "warning": {
+ "cannot_delete_self": "Не може да изтриете влезлия потребител",
+ "domain_added_sogo_failed": "Добавен домейн, но неуспешно рестартиране на SOGo, моля, проверете системните логове.",
+ "dovecot_restart_failed": "Dovecot не успя да рестартира, моля, проверете логовете",
+ "fuzzy_learn_error": "Грешка при обучение на размит хеш: %s",
+ "hash_not_found": "Хешът не е намерен или вече е изтрит",
+ "ip_invalid": "Пропуснат невалиден IP: %s",
+ "is_not_primary_alias": "Пропуснат неосновен псевдоним %s",
+ "no_active_admin": "Не може да деактивирате последния активен администратор",
+ "quota_exceeded_scope": "Квотата на домейна е надвишена: Само неограничени пощенски кутии могат да бъдат създадени в този домейн.",
+ "session_token": "Невалиден формулярен токен: Несъответствие на токена.",
+ "session_ua": "Невалиден формулярен токен: Грешка при проверка на User-Agent."
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ca-es.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ca-es.json
index 877b46c..5b8e9b6 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ca-es.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ca-es.json
@@ -19,7 +19,16 @@
"spam_alias": "Àlies temporals",
"spam_score": "Puntuació de correu brossa",
"tls_policy": "Política TLS",
- "unlimited_quota": "Quota ilimitada per bústies de correo"
+ "unlimited_quota": "Quota ilimitada per bústies de correo",
+ "delimiter_action": "Acció delimitadora",
+ "domain_relayhost": "Canviar relayhost per un domini",
+ "extend_sender_acl": "Permetre extendre l'ACL del remitent per adreces externes",
+ "mailbox_relayhost": "Canvia el host de reenviament per una bústia",
+ "pushover": "Pushover",
+ "pw_reset": "Permetre el restabliment de la contrasenya de l'usuari mailcow",
+ "ratelimit": "Límit de peticions",
+ "smtp_ip_access": "Canvia hosts permesos per SMTP",
+ "sogo_access": "Permetre la gestió d'accés a SOGo"
},
"add": {
"activate_filter_warn": "All other filters will be deactivated, when active is checked.",
@@ -73,7 +82,25 @@
"validate": "Validar",
"validation_success": "Validated successfully",
"app_name": "Nom de l'aplicació",
- "app_password": "Afegir contrasenya a l'aplicació"
+ "app_password": "Afegir contrasenya a l'aplicació",
+ "app_passwd_protocols": "Protocols autoritzats per la contrasenya de l'aplicació",
+ "bcc_dest_format": "La destinació c/o ha de ser una única adreça de correu vàlida.<br>Si necessiteu enviar una còpia a diverses adreces, creeu un àlies i utilitzeu-lo aquí.",
+ "comment_info": "Els comentaris privats no són visibles per l'usuari, mentre que els comentaris públics apareixen com una descripció emergent a la informació de l'usuari",
+ "custom_params": "Paràmetres personalitzats",
+ "custom_params_hint": "Correcte: --param=xy, incorrecte: --param xy",
+ "destination": "Destí",
+ "disable_login": "No permetre l'inici de sessió (els missatges entrants continuen sent acceptats)",
+ "domain_matches_hostname": "El domini %s coincideix amb el nom del servidor",
+ "dry": "Simular la sincronització",
+ "gal": "Llista d'adreces global",
+ "generate": "genereu",
+ "inactive": "Inactiu",
+ "internal": "Intern",
+ "internal_info": "Els àlies interns són només accessibles des del mateix domini o els àlies de dominis.",
+ "mailbox_quota_def": "Quota per defecte de la bústia",
+ "nexthop": "Següent salt",
+ "private_comment": "Comentari privat",
+ "public_comment": "Comentari púlbic"
},
"admin": {
"access": "Accés",
@@ -414,9 +441,7 @@
"queue_manager": "Queue Manager"
},
"start": {
- "help": "Mostrar/Ocultar panell d'ajuda",
- "mailcow_apps_detail": "Tria una aplicació (de moment només SOGo) per a accedir als teus correus, calendari, contactes i més.",
- "mailcow_panel_detail": "Els <b>administradors del domini</b> poden crear, modificar o esborrar bústies i àlies, configurar i obtenir informació detallada sobre els seus dominis<br>\r\n\tEls <b>usuaris d'e-mail</b> poden crear àlies temporals (spam àlies), canviar la seva contrasenya i la configuració del seu filtre anti-spam."
+ "help": "Mostrar/Ocultar panell d'ajuda"
},
"success": {
"admin_modified": "Els canvis fets a l'administrador s'han desat",
@@ -493,6 +518,7 @@
"client_configuration": "Guies de configuració per als clients de correu més habituals",
"create_syncjob": "Afegir treball de sincronitzaió",
"day": "Dia",
+ "description": "Descripció",
"direct_aliases": "Adreces àlies directes",
"direct_aliases_desc": "Els àlies directes sí que es veuen afectat per la configuració de l'usuari",
"eas_reset": "Fer un reset de la cache d'ActiveSync del dispositiu",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.cs-cz.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.cs-cz.json
index 593f1cd..708de84 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.cs-cz.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.cs-cz.json
@@ -1,7 +1,7 @@
{
"acl": {
"alias_domains": "Doménové aliasy",
- "app_passwds": "Hesla aplikací",
+ "app_passwds": "Správa hesel aplikací",
"bcc_maps": "BCC mapy",
"delimiter_action": "Zacházení s označkovanou poštou",
"domain_desc": "Změnit popis domény",
@@ -24,11 +24,12 @@
"sogo_access": "Správa přístupu do SOGo",
"sogo_profile_reset": "Resetování profilu SOGo",
"spam_alias": "Dočasné aliasy",
- "spam_policy": "Blacklist/Whitelist",
+ "spam_policy": "Denylist/Allowlist",
"spam_score": "Skóre spamu",
"syncjobs": "Synchronizační úlohy",
"tls_policy": "Pravidla TLS",
- "unlimited_quota": "Neomezené kvóty pro mailové schránky"
+ "unlimited_quota": "Neomezené kvóty pro mailové schránky",
+ "pw_reset": "Povolit obnovení hesla uživatele mailcow"
},
"add": {
"activate_filter_warn": "Pokud je zaškrtlá volba \"Aktivní\", budou všechny ostatní filtry deaktivovány.",
@@ -81,12 +82,12 @@
"password": "Heslo",
"password_repeat": "Potvrzení nového hesla (opakujte)",
"port": "Port",
- "post_domain_add": "Po přidání nové domény je nutné restartovat SOGo kontejner!",
+ "post_domain_add": "Po přidání nové domény se musí restartovat kontejner SOGo!<br><br>Je také třeba ověřit nastavení DNS nové domény. Po ověření restartujte kontejner \"acme-mailcow\", aby se vygenerovaly certifikáty domény (autoconfig.<domain>, autodiscover.<domain>).<br>Tento krok je volitelný, a provede se automaticky každých 24 hodin.",
"private_comment": "Soukromý komentář",
"public_comment": "Veřejný komentář",
"quota_mb": "Kvóta (MiB)",
"relay_all": "Předávání všech příjemců",
- "relay_all_info": "<small>Pokud se rozhodnete <b>nepředávat</b> všechny příjemce, musíte přidat prázdnou mailovou schránku pro každého příjemce, který se má předávat.</small>",
+ "relay_all_info": "↪Pokud se rozhodnete <b>nepředávat</b> všechny příjemce, musíte přidat prázdnou mailovou schránku pro každého příjemce, který se má předávat.",
"relay_domain": "Předávání domény",
"relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> U této domény lze pro konkrétní cíl nastavit transportní mapu. Není-li nastavena, použije se MX záznam.",
"relay_unknown_only": "Předávat jen neexistující schránky. Doručení do existujících proběhne lokálně.",
@@ -108,7 +109,10 @@
"validate": "Ověřit",
"validation_success": "Úspěšně ověřeno",
"tags": "Štítky",
- "dry": "Simulovat synchronizaci"
+ "dry": "Simulovat synchronizaci",
+ "internal": "Interní",
+ "internal_info": "Interní aliasy jsou přístupné jen z vlastních domén nebo jejich aliasů.",
+ "sender_allowed": "Povolit jako alias pro odesílání"
},
"admin": {
"access": "Přístupy",
@@ -146,7 +150,7 @@
"arrival_time": "Čas zařazení do fronty (čas na serveru)",
"authed_user": "Přihlášený uživatel",
"ays": "Opravdu chcete pokračovat?",
- "ban_list_info": "Seznam blokovaných IP adres je zobrazen níže: <b>síť (zbývající čas blokování) - [akce]</b>.<br />IP adresy zařazené pro odblokování budou z aktivního seznamu odebrány během několika sekund.<br />Červeně označené položky jsou pernamentní bloky z blacklistu.",
+ "ban_list_info": "Viz seznam zablokovaných IP níže: <b>síť (zbývající doba zablokování) - [akce]</b>.<br />IP adresy zařazené pro odblokování budou z aktivního seznamu odebrány během pár sekund.<br />Červeně označeny jsou položky z trvalých seznamů.",
"change_logo": "Změnit logo",
"logo_normal_label": "Normální",
"logo_dark_label": "Inverzní pro tmavý režim",
@@ -180,16 +184,16 @@
"empty": "Žádné výsledky",
"excludes": "Vyloučit tyto příjemce",
"f2b_ban_time": "Doba blokování (s)",
- "f2b_blacklist": "Sítě/hostitelé na blacklistu",
+ "f2b_blacklist": "Sítě či hostitelé na seznamu zákazů",
"f2b_filter": "Regex filtre",
- "f2b_list_info": "Síť nebo hostitelé na blacklistu mají vždy větší váhu než položky na whitelistu. Blacklist se sestavuje vždy při startu kontejneru.",
+ "f2b_list_info": "Sítě či hostitelé na seznamu zákazů mají vždy větší váhu než položky na seznamu povolení. <b>Každá úprava seznamu trvá pár sekund.</b>",
"f2b_max_attempts": "Max. pokusů",
"f2b_netban_ipv4": "Rozsah IPv4 podsítě k zablokování (8-32)",
"f2b_netban_ipv6": "Rozsah IPv6 podsítě k zablokování (8-128)",
"f2b_parameters": "Parametry automatického firewallu",
"f2b_regex_info": "Záznamy které se berou v úvahu: SOGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Časový horizont pro maximum pokusů (s)",
- "f2b_whitelist": "Sítě/hostitelé na whitelistu",
+ "f2b_whitelist": "Sítě či hostitelé na seznamu povolení",
"filter_table": "Tabulka filtrů",
"forwarding_hosts": "Předávající servery",
"forwarding_hosts_add_hint": "Lze zadat IPv4/IPv6 adresy, sítě ve formátu CIDR, názvy serverů (budou převedeny na IP adresy) nebo názvy domén (budou převedeny na IP pomocí SPF záznamů, příp. MX záznamů).",
@@ -255,7 +259,7 @@
"quarantine_exclude_domains": "Vyloučené domény a doménové aliasy",
"quarantine_max_age": "Maximální stáří ve dnech<br><small>Hodnota musí být rovna nebo větší než 1 den.</small>",
"quarantine_max_score": "Neposílat notifikace pokud je spam skóre větší než hodnota:<br><small>Výchozí je 9999.0</small>",
- "quarantine_max_size": "Maximální velikost v MiB (větší prvky budou smazány)<br />0 <b>neznamená</b> neomezeno.",
+ "quarantine_max_size": "Maximální velikost v MiB (větší prvky budou smazány)<br /><small>0 <b>neznamená</b> neomezeno.</small>",
"quarantine_notification_html": "Šablona upozornění:<br><small>Ponechte prázdné, aby se obnovila výchozí šablona.</small>",
"quarantine_notification_sender": "Odesílatel upozornění",
"quarantine_notification_subject": "Předmět upozornění",
@@ -263,7 +267,7 @@
"quarantine_release_format": "Formát propuštěných položek",
"quarantine_release_format_att": "Jako příloha",
"quarantine_release_format_raw": "Nezměněný originál",
- "quarantine_retention_size": "Počet zadržených zpráv na mailovou schránku<br />0 znamená <b>neaktivní</b>.",
+ "quarantine_retention_size": "Počet zadržených zpráv na mailovou schránku<br /><small>0 znamená <b>neaktivní</b>.</small>",
"quota_notification_html": "Šablona upozornění:<br><small>Ponechte prázdné, aby se obnovila výchozí šablona.</small>",
"quota_notification_sender": "Odesílatel upozornění",
"quota_notification_subject": "Předmět upozornění",
@@ -282,7 +286,7 @@
"relay_rcpt": "\"Komu:\" adresa",
"relay_run": "Provést test",
"relayhosts": "Transporty podle odesílatele",
- "relayhosts_hint": "Zde definujte transporty podle odesílatele, jež pak můžete použít v nastavení domény.<br>\r\nProtokol transportu je vždy \"smtp:\". Bere se v potaz uživatelské nastavení odchozího TLS.",
+ "relayhosts_hint": "Zde definujte transporty podle odesílatele, jež pak můžete použít v nastavení domény.<br>\nProtokol transportu je vždy \"smtp:\" a použije se TLS, je-li nabídnuto. Zabalené TLS (SMTPS) se nepodporuje. Bere se v potaz uživatelské nastavení odchozího TLS.<br>\nTýká se vybraných domén včetně doménových aliasů.",
"remove": "Smazat",
"remove_row": "Smazat řádek",
"reset_default": "Obnovit výchozí nastavení",
@@ -298,11 +302,11 @@
"rsettings_preset_2": "Postmasteři chtějí dostávat spam",
"rsettings_preset_3": "Povolit jen určité odesílatele pro schránku (např. jen interní schránka)",
"rsettings_preset_4": "Deaktivujte Rspamd pro doménu",
- "rspamd_com_settings": "<a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd dokumentace</a>\r\n - Název nastavení bude automaticky vygenerován, viz níže uvedené předvolby.",
+ "rspamd_com_settings": "Název nastavení se vygeneruje automaticky, viz ukázky nastavení níže. Více informací viz <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd dokumentace</a>",
"rspamd_global_filters": "Mapa globálních filtrů",
"rspamd_global_filters_agree": "Budu opatrný!",
- "rspamd_global_filters_info": "Mapa globálních filtrů obsahuje jiné globální black- a whitelisty.",
- "rspamd_global_filters_regex": "Názvy jsou dostatečným vysvětlením. Musí obsahovat jen platné regulární výrazy ve formátu \"/vyraz/parametry\" (e.g. <code>/.+@domena\\.tld/i</code>).<br>\r\n Každý výraz bude podroben základní kontrole, přesto je možné Rspamd 'rozbít', nebude-li syntax zcela korektní.<br>\r\n Rspamd se pokusí načíst mapu po každé změně. V případě potíží, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">restartujte Rspamd</a>, aby se konfigurace načetla explicitně.",
+ "rspamd_global_filters_info": "Mapa globálních filtrů obsahuje různé seznamy povolených a zakázaných serverů.",
+ "rspamd_global_filters_regex": "Názvy stačí k vysvětlení. Položky musejí obsahovat jen platné regulární výrazy ve tvaru \"/vyraz/parametry\" (e.g. <code>/.+@domena\\.tld/i</code>).<br>\n Každý výraz bude podroben základní kontrole, přesto je možné Rspamd 'rozbít', nebude-li syntax zcela korektní.<br>\n Rspamd se pokusí po každé změně načíst mapu znovu. V případě potíží <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">restartujte Rspamd</a>, aby se konfigurace načetla explicitně.",
"rspamd_settings_map": "Nastavení Rspamd",
"sal_level": "Úroveň 'Moo'",
"save": "Uložit změny",
@@ -323,8 +327,8 @@
"to_top": "Zpět na začátek",
"transport_dest_format": "Formát: example.org, .example.org, *, box@example.org (vícero položek lze oddělit čárkou)",
"transport_maps": "Transportní mapy",
- "transport_test_rcpt_info": "• Na otestování odchozí pošty je možné použít null@hosted.mailcow.de jako adresáta",
- "transports_hint": "→ Položka transportní mapy <b>přebíjí</b> transportní mapu podle odesílatele</b>.<br>\r\n→ Uživatelské nastavení odchozího TLS se ignoruje a lze je výhradně vynutit mapováním TLS pravidel.<br>\r\n→ Protokol transportu je vždy \"smtp:\".<br>\r\n→ Adresy, jež odpovídají výrazu \"/localhost$/\", se vždy předají přes \"local:\", takže nejsou zahrnuty do definice cíle \"*\".<br>\r\n→ Pro stanovení přihlašovacích údajů dalšího skoku, např. \"[host]:25\", bude Postfix <b>vždy</b> hledat nejdříve \"host\" a teprve pak \"[host]:25\". Kvůli tomu nelze použít současně \"host\" a \"[host]:25\"",
+ "transport_test_rcpt_info": "• K otestování předávání pošty ven použijte null@hosted.mailcow.de.",
+ "transports_hint": "• Položka transportní mapy <b>přebíjí</b> transportní mapu podle odesílatele</b>.<br>\n• Transporty založené na MX mají přednost.<br>\n• Uživatelské nastavení odchozího TLS se ignoruje a lze je vynutit výhradně mapou TLS pravidel.<br>\n• Transportní služnou pro tyto transporty je vždy \"smtp:\" a použije se TLS, je-li nabídnuto. Zabalené TLS (SMTPS) se nepodporuje.<br>\n• Adresy, jež odpovídají výrazu \"/localhost$/\", se vždy předají přes \"local:\", takže nejsou zahrnuty do definice cíle \"*\".<br>\n• Pro stanovení přihlašovacích údajů dalšího skoku, např. \"[host]:25\", bude Postfix <b>vždy</b> hledat nejdříve \"host\" a teprve pak \"[host]:25\". Kvůli tomu nelze použít současně \"host\" a \"[host]:25\".",
"ui_footer": "Pata stránka (HTML povoleno)",
"ui_header_announcement": "Oznámení",
"ui_header_announcement_active": "Nastavit jako aktivní",
@@ -343,10 +347,72 @@
"validate_license_now": "Ověřit GUID na licenčním serveru",
"verify": "Ověřit",
"yes": "✓",
- "f2b_ban_time_increment": "Délka banu je prodlužována s každým dalším banem",
- "f2b_max_ban_time": "Maximální délka banu (s)",
+ "f2b_ban_time_increment": "Délka bloku se prodlužuje s každým dalším zablokováním",
+ "f2b_max_ban_time": "Maximální délka bloku (s)",
"cors_settings": "Nastavení CORS",
- "queue_unban": "zrušit ban"
+ "queue_unban": "odblokovat",
+ "password_reset_info": "Pokud není zadán žádný e-mail pro obnovení, nelze tuto funkci použít.",
+ "password_reset_settings": "Nastavení obnovení hesla",
+ "password_settings": "Nastavení hesel",
+ "password_reset_tmpl_html": "HTML šablona",
+ "password_reset_tmpl_text": "Textová šablona",
+ "reset_password_vars": "<code>{{link}}</code> Vygenerovaný odkaz pro obnovení hesla<br><code>{{username}}</code> Název mailboxu uživatele, který požádal o resetování hesla.<br><code>{{username2}}</code> Název schránky pro obnovení<br><code>{{date}}</code> Datum podání žádosti o obnovení hesla<br><code>{{token_lifetime}}</code> Délka životnosti tokenu v minutách<br><code>{{hostname}}</code> Název serveru mailcow",
+ "restore_template": "Ponechte prázdné pro obnovení výchozí šablony.",
+ "copy_to_clipboard": "Text zkopírován do schránky!",
+ "iam_login_provisioning": "Automaticky vytvořit uživatele při přihlášení",
+ "user_quicklink": "Skrýt zkratku na přihlášení uživatele",
+ "domainadmin_quicklink": "Skrýt zkratku na přihlášení správce domény",
+ "iam_auth_flow_info": "Kromě metody autorizačního kódu (Authorization Code Flow, výchozího v Keycloaku), jež se používá pro SSO, podporuje mailcow také metody autentizaci přímo pomocí přihlašovacích údajů. The metoda Mailpassword Flow se pokusí ověřit přihlašovací údaje uživatele přímo v Admin REST API Keycloaku. mailcow získá hash hesla z atributu <code>mailcow_password</code> , namapovaného v Keycloaku.",
+ "iam_default_template_description": "Nemá-li uživatel přiřazenu šablonu, použije se výchozí šablona k vytvoření schránky, ale ne k její úpravě či aktualizaci.",
+ "iam_userinfo_url": "Koncový bod pro informace o uživatelích",
+ "iam_redirect_url": "URL přesměrování",
+ "user_link": "Odkaz pro uživatele",
+ "force_sso_text": "Je-li nastaven externí poskytovatel OIDC, zapnutím této volby skryjete výchozí přihlašovací formulář. Zůstane vidět jen tlačítko pro SSO",
+ "iam_mapping": "Mapování atributů",
+ "iam_bindpass": "Heslo pro bind",
+ "iam_periodic_full_sync": "Pravidelná úplná synchronizace",
+ "iam_port": "Port",
+ "iam_realm": "Realm",
+ "iam_rest_flow": "Mailpassword Flow",
+ "iam_server_url": "URL serveru",
+ "iam_sso": "Single Sign-On",
+ "iam_sync_interval": "Interval synchronizace/importu (min)",
+ "iam_test_connection": "Test spojení",
+ "iam_token_url": "Koncový bod pro tokeny",
+ "iam_username_field": "Pole uživatelského jména",
+ "iam_binddn": "Doména pro bind",
+ "iam_use_ssl": "Používat SSL",
+ "iam_use_tls": "Používat StartTLS",
+ "iam_version": "Verze",
+ "quicklink_text": "Zobrazení zkratek k dalším přihlašovacím stránkám",
+ "iam_use_tls_info": "Je-li zapnuto TLS, musí se používat standardní port pro LDAP (389). Port SSL nelze použít.",
+ "ignore_ssl_error": "Ignorovat chyby SSL",
+ "iam_use_ssl_info": "Je-li zapnuto SSL a nastaven port 389, použije se automaticky port 636.",
+ "task": "Úloha",
+ "app_hide": "Skrýt při přihlášení",
+ "admin_quicklink": "Skrýt zkratku na přihlášení správce",
+ "allowed_methods": "Access-Control-Allow-Methods",
+ "allowed_origins": "Access-Control-Allow-Origin",
+ "login_page": "Přihlašovací stránka",
+ "f2b_manage_external": "Spravovat Fail2Ban externě",
+ "f2b_manage_external_info": "Fail2ban bude udržovat seznam zakázaných adres, ale nebude aktivně nastavovat pravidla blokování. Pro blokování použijte seznam adres níže.",
+ "filter": "Filtr",
+ "force_sso": "Vypnout přihlášení mailcow a ponechat jen SSO",
+ "iam": "Poskytovatel identity",
+ "iam_attribute_field": "Pole atributu",
+ "iam_authorize_url": "Autorizační koncový bod",
+ "iam_basedn": "Doména (Base DN)",
+ "iam_client_id": "ID klienta",
+ "iam_client_secret": "Tajný kód klienta",
+ "iam_client_scopes": "Scopes klienta",
+ "iam_default_template": "Výchozí šablona",
+ "iam_description": "Nastavení externího poskytovatele ověření<br>Schránky uživatele se vytvoří po prvním přihlášení automaticky, pokud je tedy nastaveno mapování atributů.",
+ "iam_extra_permission": "Aby vše fungovalo, musí mít mailcow klient v Keycloaku nastavený <code>servisní účet</code> a povolení <code>view-users</code>.",
+ "iam_host": "Hostitel",
+ "iam_host_info": "Zadejte jeden či více hostitelů, oddělte čárkou.",
+ "iam_import_users": "Importovat uživatele",
+ "iam_auth_flow": "Proces autentizace",
+ "needs_restart": "potřebuje restart"
},
"danger": {
"access_denied": "Přístup odepřen nebo jsou neplatná data ve formuláři",
@@ -400,7 +466,7 @@
"is_alias": "%s je již známa jako adresa aliasu",
"is_alias_or_mailbox": "%s je již známa jako adresa aliasu, mailové schránky nebo aliasu rozvedeného z aliasu domény.",
"is_spam_alias": "%s je již známa jako adresa spamového aliasu",
- "last_key": "Nelze smazat poslední klíč",
+ "last_key": "Nelze smazat poslední klíč, vypněte tedy celé TFA.",
"login_failed": "Přihlášení selhalo",
"mailbox_defquota_exceeds_mailbox_maxquota": "Výchozí kvóta překračuje maximální kvótu schránky\"",
"mailbox_invalid": "Název mailové schránky je neplatný",
@@ -475,7 +541,23 @@
"webauthn_publickey_failed": "Pro vybraný ověřovací prostředek nebyl uložen žádný veřejný klíč",
"webauthn_username_failed": "Zvolený ověřovací prostředek patří k jinému účtu",
"extended_sender_acl_denied": "chybějící ACL pro nastavení externích adres odesílatele",
- "demo_mode_enabled": "Demo režim je zapnutý"
+ "demo_mode_enabled": "Demo režim je zapnutý",
+ "recovery_email_failed": "Nepodařilo se odeslat e-mail pro obnovení. Obraťte se prosím na svého správce.",
+ "password_reset_invalid_user": "Mailbox nebyl nalezen nebo není nastaven žádný e-mail pro obnovu",
+ "password_reset_na": "Obnovení hesla není v současné době k dispozici. Obraťte se prosím na svého správce.",
+ "generic_server_error": "Došlo k nečekané chybě. Obraťte se na vašeho správce.",
+ "to_invalid": "Adresát nemůže být prázdný",
+ "authsource_in_use": "Poskytovatele identity nelze změnit nebo odstranit, neboť se právě používá pro jednoho či více uživatelů.",
+ "iam_test_connection": "Spojení selhalo",
+ "img_dimensions_exceeded": "Obrázek je větší než povolené rozměry",
+ "img_size_exceeded": "Obrázek má větší než povolenou velikost souboru",
+ "invalid_reset_token": "Neplatný resetovací token",
+ "required_data_missing": "Chybí potřebný údaj %s",
+ "reset_token_limit_exceeded": "Byl překročen limit na reset tokeny. Zkuste to později.",
+ "max_age_invalid": "Maximální životnost %s není platná",
+ "mode_invalid": "Mód %s není platný",
+ "mx_invalid": "Záznam MX %s není platný",
+ "version_invalid": "Verze %s není platná"
},
"datatables": {
"emptyTable": "Tabulka neobsahuje žádná data",
@@ -510,7 +592,6 @@
"external_logs": "Externí logy",
"history_all_servers": "Záznam (všechny servery)",
"in_memory_logs": "Logy v paměti",
- "jvm_memory_solr": "Spotřeba paměti JVM",
"last_modified": "Naposledy změněn",
"log_info": "<p><b>Logy v paměti</b> jsou shromažďovány v Redis seznamech a jsou oříznuty na LOG_LINES (%d) každou minutu, aby se nepřetěžoval server.\r\n <br>Logy v paměti nemají být trvalé. Všechny aplikace, které logují do paměti, zároveň logují i do Docker služby podle nastavení logging driveru.\r\n <br>Logy v paměti lze použít pro ladění drobných problémů s kontejnery.</p>\r\n <p><b>Externí logy</b> jsou shromažďovány pomocí API dané aplikace.</p>\r\n <p><b>Statické logy</b> jsou většinou logy činností, které nejsou zaznamenávány do Docker služby, ale přesto je dobré je schraňovat (výjimkou jsou logy API).</p>",
"login_time": "Čas",
@@ -519,8 +600,6 @@
"restart_container": "Restartovat",
"service": "Služba",
"size": "Velikost",
- "solr_dead": "Solr se spouští, je vypnutý nebo spadl.",
- "solr_status": "Stav Solr",
"started_at": "Spuštěn",
"started_on": "Spuštěno",
"static_logs": "Statické logy",
@@ -540,7 +619,8 @@
"update_failed": "Nepodařilo se zkontrolovat aktualizace",
"wip": "Nedokončená vývojová verze",
"memory": "Paměť",
- "container_disabled": "Kontejner je zastaven nebo zakázán"
+ "container_disabled": "Kontejner je zastaven nebo zakázán",
+ "cores": "jádra"
},
"diagnostics": {
"cname_from_a": "Hodnota odvozena z A/AAAA záznamu. Lze použít, pokud záznam ukazuje na správný zdroj.",
@@ -561,7 +641,7 @@
"alias": "Upravit alias",
"allow_from_smtp": "Umožnit pouze těmto IP adresám používat <b>SMTP</b>",
"allow_from_smtp_info": "Nechte prázdné pro povolení všech odesílatelů.<br>IPv4/IPv6 adresy a sítě.",
- "allowed_protocols": "Povolené protokoly",
+ "allowed_protocols": "Povolené protokoly pro přímá spojení (netýká se protokolů na změnu hesla)",
"app_name": "Název aplikace",
"app_passwd": "Heslo aplikace",
"app_passwd_protocols": "Povolené protokoly pro hesla aplikací",
@@ -599,7 +679,7 @@
"inactive": "Neaktivní",
"kind": "Druh",
"last_modified": "Naposledy změněn",
- "lookup_mx": "Cíl je regulární výraz který se shoduje s MX záznamem (<code>.*\\.google\\.com</code> směřuje veškerou poštu na MX které jsou cílem pro google.com přes tento skok)",
+ "lookup_mx": "Cíl je regulární výraz, jenž se porovná s MX záznamem (např. <code>.*\\.google\\.com</code> na tento skok nasměruje veškerou poštu s MX, jež končí na *.google.com)",
"mailbox": "Úprava mailové schránky",
"mailbox_quota_def": "Výchozí kvóta schránky",
"mailbox_relayhost_info": "Aplikované jen na uživatelskou schránku a přímé aliasy, přepisuje předávající server domény.",
@@ -633,7 +713,7 @@
"ratelimit": "Omezení přenosu",
"redirect_uri": "URL přesměrování/odvolání",
"relay_all": "Předávání všech příjemců",
- "relay_all_info": "<small>Pokud se rozhodnete <b>nepředávat</b> všechny příjemce, musíte přidat prázdnou mailovou schránku pro každého příjemce, který se má předávat.</small>",
+ "relay_all_info": "↪ Pokud se rozhodnete <b>nepředávat</b> všechny příjemce, musíte přidat prázdnou mailovou schránku pro každého příjemce, který se má předávat.",
"relay_domain": "Předávání domény",
"relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> U této domény lze pro konkrétní cíl nastavit transportní mapu. Není-li nastavena, použije se MX záznam.",
"relay_unknown_only": "Předávat jen neexistující schránky. Doručení do existujících proběhne lokálně.",
@@ -648,17 +728,17 @@
"sieve_desc": "Krátký popis",
"sieve_type": "Typ filtru",
"skipcrossduplicates": "Přeskočit duplicitní zprávy (\"první přijde, první mele\")",
- "sogo_access": "Udělit přímý přihlašovací přístup do služby SOGo",
- "sogo_access_info": "Jednotné přihlášení (SSO) z mail UI zůstává funkční. Toto nastavení neovlivňuje přístup ke všem ostatním službám ani neodstraňuje či nemění stávající profil uživatele SOGo.",
+ "sogo_access": "Přímé předání na SOGo",
+ "sogo_access_info": "Po přihlášení je uživatel automaticky přesměrován do služby SOGo.",
"sogo_visible": "Alias dostupný v SOGo",
"sogo_visible_info": "Tato volba určuje objekty, jež lze zobrazit v SOGo (sdílené nebo nesdílené aliasy, jež ukazuje alespoň na jednu schránku).",
"spam_alias": "Vytvořit nebo změnit dočasné aliasy",
"spam_filter": "Spam filtr",
- "spam_policy": "Přidat nebo odebrat položky whitelistu/blacklistu",
+ "spam_policy": "Přidat nebo odebrat položky seznamu",
"spam_score": "Nastavte vlastní skóre spamu",
"subfolder2": "Synchronizace do podsložky v cílovém umístění<br><small>(prázdné = nepoužívat podsložku)</small>",
"syncjob": "Upravit synchronizační úlohu",
- "target_address": "Cílová adresa/y<br /> <small>(oddělte čárkou)</small>",
+ "target_address": "Cílová adresa/y <small>(oddělte čárkou)</small>",
"target_domain": "Cílová doména",
"timeout1": "Časový limit pro připojení ke vzdálenému serveru",
"timeout2": "Časový limit pro připojení k lokálnímu serveru",
@@ -672,12 +752,38 @@
"auth_user": "{= auth_user =} - Ověřené uživatelské jméno zadané MTA",
"from_user": "{= from_user =} - uživatelská část odesílatele, např. pro \"moo@mailcow.tld\" vrátí \"moo\"",
"from_domain": "{= from_domain =} - Doména odesílatele",
- "from_addr": "{= from_addr =} - E-mailová adresa odesílatele"
+ "from_addr": "{= from_addr =} - E-mailová adresa odesílatele",
+ "custom": "{= foo =} - Pokud má schránka vlastní atribut „foo“ s hodnotou „bar“, vrátí „bar“"
},
"domain_footer": "Patička pro celou doménu",
"domain_footer_html": "HTML text",
"domain_footer_plain": "Prostý text",
- "pushover_sound": "Zvukové upozornění"
+ "pushover_sound": "Zvukové upozornění",
+ "custom_attributes": "Vlastní atributy",
+ "footer_exclude": "Vyloučit ze zápatí",
+ "domain_footer_skip_replies": "Ignorovat patičku u odpovědí na e-maily",
+ "password_recovery_email": "E-mail pro obnovu hesla",
+ "mailbox_rename": "Přejmenovat schránku",
+ "mailbox_rename_agree": "Mám vytvořenou zálohu.",
+ "mailbox_rename_warning": "DŮLEŽITÉ! Vytvořte si zálohu schránky, než ji přejmenujete.",
+ "mailbox_rename_alias": "Automaticky vytvořit alias",
+ "mailbox_rename_title": "Nový název zdejší schránky",
+ "pushover": "Pushover",
+ "internal": "Interní",
+ "internal_info": "Interní aliasy jsou přístupné jen z vlastních domén nebo jejich aliasů.",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> je standard, jenž říká poštovním serverům, aby komunikovaly pomocí TLS s platnými certifikáty. <br>Používá se, pokud není k dispozici <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a>, např. chybí-li či není podporováno DNSSEC.<br><b>Pozn.</b>: Podporuje-li přijímající doména DANE a DNSSEC, bude <b>vždy</b> použito DANE; MTA-STS zůstane jako plán B.",
+ "mta_sts_version": "Verze",
+ "mta_sts_version_info": "Určuje verzi standardu MTA-STS – zatím je podporována jen <code>STSv1</code>.",
+ "mta_sts_mode": "Mód",
+ "mta_sts_mode_info": "K dispozici jsou tři módy:<ul><li><em>testing</em> – pravidlo se jen sleduje, porušení je bez následků.</li><li><em>enforce</em> – pravidlo je důsledně dodržováno, spojení bez platného TLS jsou odmítána.</li><li><em>none</em> – pravidlo je zveřejněno, ale neuplatňuje se.</li></ul>",
+ "mta_sts_max_age": "Maximální životnost",
+ "mta_sts_max_age_info": "Doba v sekundách, po niž poštovní servery mohou toho pravidlo držet v mezipaměti bez nutnosti obnovení.",
+ "mta_sts_mx": "Server MX",
+ "mta_sts_mx_info": "Dovoluje odesílání jen výslovně vypsaným poštovním serverům; odesílající server kontroluje, že server MX určený v DNS odpovídá pravidlu, a povolí doručení jen s platným certifikátem TLS (chrání přes útokem typu MITM).",
+ "mta_sts_mx_notice": "Lze zadat více serverů MX (oddělte čárkou).",
+ "sender_allowed": "Povolit jako alias pro odesílání",
+ "sender_allowed_info": "Není-li povoleno, lze alias použít jen pro příjem pošty. Lze také obejít v Sender ACL a nastavit konkrétní schránky, jež tento alias mohou používat"
},
"fido2": {
"confirm": "Potvrdit",
@@ -698,7 +804,7 @@
"cancel": "Zrušit",
"confirm_delete": "Potvdit smazání",
"delete_now": "Smazat",
- "delete_these_items": "Prosím potvrďte změny objektu id:",
+ "delete_these_items": "Prosím potvrďte změny objektu id",
"hibp_check": "Ověřit heslo v databázi hacknutých hesel haveibeenpwned.com",
"hibp_nok": "Nalezeno! Toto je potenciálně nebezpečné heslo!",
"hibp_ok": "Nebyla nalezena žádná shoda.",
@@ -707,12 +813,12 @@
"restart_container": "Restartovat kontejner",
"restart_container_info": "<b>Důležité:</b> Šetrný restart může chvíli trvat, prosím čekejte...",
"restart_now": "Restartovat nyní",
- "restarting_container": "Restartuje se kontejner, může to chvilku trvat..."
+ "restarting_container": "Restartuje se kontejner, může to chvilku trvat"
},
"header": {
"administration": "Hlavní nastavení",
"apps": "Aplikace",
- "debug": "Systémové informace",
+ "debug": "Informace",
"email": "E-Mail",
"mailcow_system": "Systém",
"mailcow_config": "Nastavení",
@@ -731,9 +837,24 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Přihlásit",
"mobileconfig_info": "Ke stažení profilového souboru se přihlaste jako uživatel schránky.",
- "other_logins": "Přihlášení klíčem",
+ "other_logins": "nebo přihlásit s",
"password": "Heslo",
- "username": "Uživatelské jméno"
+ "username": "Uživatelské jméno",
+ "back_to_mailcow": "Zpět do mailcow",
+ "forgot_password": "> Zapomněli jste heslo?",
+ "invalid_pass_reset_token": "Token pro obnovení hesla je neplatný nebo jeho platnost vypršela.<br>Prosím, vyžádejte si nový odkaz pro obnovení hesla.",
+ "new_password": "Nové heslo",
+ "new_password_confirm": "Ověření nového hesla",
+ "reset_password": "Obnovit heslo",
+ "request_reset_password": "Požádat o změnu hesla",
+ "login_domainadmintext": "Přihlášení správce domény",
+ "login_linkstext": "Hledáte jinou přihlašovací stránku?",
+ "login_usertext": "Přihlášení uživatele",
+ "login_admintext": "Přihlášení správce",
+ "login_user": "Přihlášení uživatele",
+ "login_dadmin": "Přihlášení správce domény",
+ "login_admin": "Přihlášení správce",
+ "email": "Mailová adresa"
},
"mailbox": {
"action": "Akce",
@@ -765,7 +886,7 @@
"bcc": "BCC",
"bcc_destination": "Cíl kopie",
"bcc_destinations": "Cíl kopií",
- "bcc_info": "Skryté kopie (Mapa BCC) se používá pro tiché předávání kopií všech zpráv na jinou adresu. Při použití skryté kopie typu <i>Přijatý e-mail</i> budou přeposlány všechny maily směřující na dotyčnou adresu nebo doménu.\nU typu <i>Odeslaný e-mail</i> budou přeposlány všechny maily odeslané z dotyčné adresy nebo domény.\nPokud selže přeposlání na cílovou adresu, tak odesílatel o tom nebude informován.",
+ "bcc_info": "Skrytá kopie (mapa BCC) se používá pro tiché předávání kopií všech zpráv na jinou adresu. Mapa příjemců se použije, funguje-li je místní cíl jako adresát zprávy. Totéž platí pro mapy odesílatelů.<br/>\n Místní cíl se nedozví, selže-li doručení na cíl BCC.",
"bcc_local_dest": "Týká se",
"bcc_map": "Skrytá kopie",
"bcc_map_type": "Typ skryté kopie",
@@ -820,7 +941,7 @@
"last_run_reset": "Znovu naplánovat",
"mailbox": "Mailová schránka",
"mailbox_defaults": "Výchozí nastavení",
- "mailbox_defaults_info": "Definuje výchozí nastavení pro nové schránky",
+ "mailbox_defaults_info": "Definuje výchozí nastavení pro nové schránky.",
"mailbox_defquota": "Výchozí velikost schránky",
"mailbox_templates": "Šablony schránek",
"mailbox_quota": "Max. velikost schránky",
@@ -840,7 +961,7 @@
"private_comment": "Soukromý komentář",
"public_comment": "Veřejný komentář",
"q_add_header": "Složka nevyžádaná pošta",
- "q_all": "Všechny kategorie",
+ "q_all": " Nevyžádaná pošta a Odmítnuta",
"q_reject": "Odmítnuta",
"quarantine_category": "Kategorie oznámení karantény",
"quarantine_notification": "Upozornění z karantény",
@@ -849,7 +970,7 @@
"recipient_map": "Mapa příjemce",
"recipient_map_info": "Mapy příjemců slouží k nahrazení cílové adresy zprávy před doručením.",
"recipient_map_new": "Nový přijemce",
- "recipient_map_new_info": "Cílová adresa mapy příjemce musí být platná emailová adresa.",
+ "recipient_map_new_info": "Cílovou adresou mapy příjemců musí být emailová adresa nebo název domény.",
"recipient_map_old": "Původní příjemce",
"recipient_map_old_info": "Původní příjemce musí být platná emailová adresa nebo název domény.",
"recipient_maps": "Mapy příjemců",
@@ -868,7 +989,7 @@
"sieve_preset_5": "Automatický odpovídač (dovolená)",
"sieve_preset_6": "Odmítnout zprávu s odpovědí",
"sieve_preset_7": "Přesměrovat a ponechat/zahodit",
- "sieve_preset_8": "Zahodit zprávu poslanou na alias, do něhož patří i odesílatel",
+ "sieve_preset_8": "Zprávu od určitého odesílatele přesměrovat, označit jako přečtenou a uložit do složky",
"sieve_preset_header": "Vizte následující ukázková pravidla. Více informací na <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedii</a>.",
"sogo_visible": "Alias dostupný v SOGo",
"sogo_visible_n": "Skrýt alias v SOGo",
@@ -908,7 +1029,9 @@
"waiting": "Čekání",
"weekly": "Každý týden",
"yes": "✓",
- "relay_unknown": "Předávání neexistujících schránek"
+ "relay_unknown": "Předávání neexistujících schránek",
+ "iam": "Poskytovatel identity",
+ "internal": "Interní"
},
"oauth2": {
"access_denied": "K udělení přístupu se přihlašte jako vlastník mailové schránky.",
@@ -916,7 +1039,7 @@
"deny": "Zamítnout",
"permit": "Ověřit aplikaci",
"profile": "Profil",
- "profile_desc": "Zobrazit osobní údaje: uživ. jméno, jméno, datum vytvoření a úpravy, stav",
+ "profile_desc": "Zobrazit osobní údaje: uživ. jméno, celé jméno, datum vytvoření a úpravy, stav",
"scope_ask_permission": "Aplikace požádala o následující oprávnění"
},
"quarantine": {
@@ -940,7 +1063,7 @@
"notified": "Oznámeno",
"qhandler_success": "Požadavek úspěšně přijat. Můžete nyní zavřít okno.",
"qid": "Rspamd QID",
- "qinfo": "Karanténní systém uloží odmítnutou poštu do databáze (odesílatel se <em>nedozví</em>, že pošta byla doručena) jakož i pošta, která bude jako kopie doručena do složky Nevyžádaná pošta. \r\n<br>\"Naučit jako spam a smazat\" naučí zprávu jako spam přes Bayesian theorem a současně vypočítá fuzzy hashes pro odmítnutí podobných zpráv v budoucnosti. \r\n<br> Prosím, berte na vědomí, že naučení více zpráv může být - záleží na vašem systému - časově náročné . <br> Položky na černé listině jsou z karantény vyloučeny.",
+ "qinfo": "Karanténa uloží do databáze odmítnutou poštu (odesílatel se <em>nedozví</em>, že pošta byla doručena) jakož i poštu, jež se jako kopie doručuje do složky Nevyžádaná pošta.\n <br>\"Naučit jako spam a smazat\" předá zprávu systému k naučení bayesiánskou analýzou jako spam a současně stanoví fuzzy hashe pro odmítání podobných zpráv v budoucnosti.\n <br> Vezměte na vědomí, že učení více zpráv může být podle výkonnosti systému zabrat více času. <br> Položky na seznamu zákazů jsou z karantény vyloučeny.",
"qitem": "Položka v karanténě",
"quarantine": "Karanténa",
"quick_actions": "Akce",
@@ -985,7 +1108,8 @@
"hold_mail_legend": "Podrží vybrané e-maily. (Zabrání dalším pokusům o doručení)",
"show_message": "Zobrazit zprávu",
"unhold_mail": "Uvolnit",
- "unhold_mail_legend": "Uvolnit vybrané e-maily k doručení. (Pouze v případě předchozího podržení)"
+ "unhold_mail_legend": "Uvolnit vybrané e-maily k doručení. (Pouze v případě předchozího podržení)",
+ "unban": "odblokovat"
},
"ratelimit": {
"disabled": "Vypnuto",
@@ -996,9 +1120,7 @@
},
"start": {
"help": "Zobrazit/skrýt panel nápovědy",
- "imap_smtp_server_auth_info": "Použijte celou e-mailovou adresu a zvolte způsob ověření PLAIN.<br>\r\nPřihlašovací údaje budou zašifrovány na straně serveru.",
- "mailcow_apps_detail": "Použijte aplikace pro přístup k e-mailům, kalendáři, kontaktům atd.",
- "mailcow_panel_detail": "<b>Správci domén</b> mohou vytvářet, upravovat nebo mazat schránky a aliasy, upravovat parametry domén a zobrazovat další informace o svých přidělených doménách.<br>\r\n<b>Uživatelé</b> mohou vytvářet dočasné aliasy (spam aliases), měnit svá hesla a nastavovat filtr spamu."
+ "imap_smtp_server_auth_info": "Použijte celou e-mailovou adresu a zvolte způsob ověření PLAIN.<br>\r\nPřihlašovací údaje budou zašifrovány na straně serveru."
},
"success": {
"acl_saved": "ACL pro objekt %s uloženo",
@@ -1048,7 +1170,7 @@
"logged_in_as": "Přihlášen jako %s",
"mailbox_added": "Mailová schránka %s přidána",
"mailbox_modified": "Změny mailové schránky %s uloženy",
- "mailbox_removed": "Mailová schránka %s odebrána",
+ "mailbox_removed": "Mailová schránka %s odstraněna",
"nginx_reloaded": "Nginx reload byl úspěšný",
"object_modified": "Změny objektu %s uloženy",
"password_policy_saved": "Politika hesel byla úspěšně uložena",
@@ -1081,7 +1203,15 @@
"verified_webauthn_login": "WebAuthn přihlášení ověřeno",
"verified_yotp_login": "Yubico OTP přihlášení ověřeno",
"cors_headers_edited": "Nastavení CORS byla uložena",
- "domain_footer_modified": "Změny patičky domény %s byly uloženy"
+ "domain_footer_modified": "Změny patičky domény %s byly uloženy",
+ "recovery_email_sent": "E-mail k obnovení byl odeslán na adresu %s",
+ "custom_login_modified": "Úpravy přihlašování úspěšně uloženy",
+ "domain_add_dkim_available": "Klíč DKIM už existoval",
+ "f2b_banlist_refreshed": "Seznam zákazů úspěšně obnoven.",
+ "iam_test_connection": "Spojení úspěšně navázano",
+ "ip_check_opt_in_modified": "Kontrola IP adresy úspěšně uložena",
+ "mailbox_renamed": "Schránka přejmenována z %s na %s",
+ "password_changed_success": "Heslo úspěšně změněno"
},
"tfa": {
"api_register": "%s používá Yubico Cloud API. Prosím získejte API klíč pro své Yubico <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">ZDE</a>",
@@ -1097,7 +1227,7 @@
"none": "Deaktivovat",
"reload_retry": "- (znovu načtěte stránku, opakuje-li se chyba)",
"scan_qr_code": "Prosím načtěte následující kód svou aplikací na ověření nebo zadejte kód ručně.",
- "select": "Prosím vyberte...",
+ "select": "Vyberte prosím",
"set_tfa": "Nastavení způsobu dvoufaktorového ověření",
"start_webauthn_validation": "Zahájit inicializaci",
"tfa": "Dvoufaktorové ověření (TFA)",
@@ -1106,7 +1236,10 @@
"webauthn": "WebAuthn ověření",
"waiting_usb_auth": "<i>Čeká se na USB zařízení...</i><br><br>Prosím stiskněte tlačítko na svém WebAuthn USB zařízení.",
"waiting_usb_register": "<i>Čeká se na USB zařízení...</i><br><br>Prosím zadejte své heslo výše a potvrďte WebAuthn registraci stiskem tlačítka na svém WebAuthn USB zařízení.",
- "yubi_otp": "Yubico OTP ověření"
+ "yubi_otp": "Yubico OTP ověření",
+ "u2f_deprecated": "Zdá se, že váš klíč byl registrován zastaralou metodou U2F. Dojde k deaktivaci dvoufaktorové autentifikace a smazání klíče.",
+ "authenticators": "Autentifikátory",
+ "u2f_deprecated_important": "Registrujte svůj klíč novou metodou WebAuthn ve správě správců."
},
"user": {
"action": "Akce",
@@ -1122,7 +1255,7 @@
"alias_time_left": "Zbývající čas",
"alias_valid_until": "Platný do",
"aliases_also_send_as": "Smí odesílat také jako uživatel",
- "aliases_send_as_all": "Nekontrolovat přístup odesílatele pro následující doménu(y) a jejich aliasy domény:",
+ "aliases_send_as_all": "Nekontrolovat přístup odesílatele pro následující doménu(y) a jejich aliasy",
"allowed_protocols": "Povolené protokoly",
"app_hint": "Hesla aplikací jsou alternativní heslo pro přihlášení k IMAP, SMTP, CalDAV, CardDAV a EAS. Uživatelské jméno zůstává stejné.<br>SOGo však nelze s heslem aplikace použít.",
"app_name": "Název aplikace",
@@ -1140,10 +1273,11 @@
"created_on": "Vytvoreno",
"daily": "Každý den",
"day": "den",
+ "description": "Popis",
"delete_ays": "Potvrďte odstranění.",
"direct_aliases": "Přímé aliasy",
- "direct_aliases_desc": "Na přímé aliasy se uplatňuje filtr spamu a nastavení pravidel TLS",
- "direct_protocol_access": "Tento uživatel mailové schránky má <b>přímý externí přístup</b> k následujícím protokolům a aplikacím. Toto nastavení je řízeno správcem. Pro udělení přístupu k jednotlivým protokolům a aplikacím lze vytvořit hesla aplikací.<br>Tlačítko \" Přihlaste se do webmailu\" zajišťuje jednotné přihlášení k SOGo a je vždy k dispozici.",
+ "direct_aliases_desc": "Na přímé aliasy se uplatňuje filtr spamu a nastavení pravidel TLS.",
+ "direct_protocol_access": "Tento uživatel mailové schránky má <b>přímý externí přístup</b> k následujícím protokolům a aplikacím. Toto nastavení je řízeno správcem. Pro udělení přístupu k jednotlivým protokolům a aplikacím lze vytvořit hesla aplikací.<br>Tlačítko \"Webmail\" zajišťuje jednotné přihlášení k SOGo a je vždy k dispozici.",
"eas_reset": "Smazat mezipaměť zařízení ActiveSync",
"eas_reset_help": "Obnovení mezipaměti zařízení pomůže zpravidla obnovit poškozený profil služby ActiveSync.<br><b>Upozornění:</b> Všechna data budou opětovně stažena!",
"eas_reset_now": "Smazat",
@@ -1184,7 +1318,7 @@
"no_last_login": "Žádný záznam o přihlášení",
"no_record": "Žádný záznam",
"open_logs": "Otevřít záznam",
- "open_webmail_sso": "Přihlaste se do webmailu",
+ "open_webmail_sso": "Webmail",
"password": "Heslo",
"password_now": "Současné heslo (pro potvrzení změny)",
"password_repeat": "Heslo (znovu)",
@@ -1216,13 +1350,13 @@
"sogo_profile_reset": "Resetovat profil SOGo",
"sogo_profile_reset_help": "Tato volba odstraní uživatelský profil SOGo a <b>nenávratně vymaže všechna data</b>.",
"sogo_profile_reset_now": "Resetovat profil",
- "spam_aliases": "Dočasné e-mailové aliasy",
+ "spam_aliases": "Spam aliasy",
"spam_score_reset": "Obnovit výchozí nastavení serveru",
"spamfilter": "Filtr spamu",
"spamfilter_behavior": "Hodnocení",
- "spamfilter_bl": "Seznam zakázaných adres (blacklist)",
- "spamfilter_bl_desc": "Zakázané emailové adresy <b>budou vždy klasifikovány jako spam a odmítnuty</b>. Lze použít zástupné znaky (*). Filtr se použije pouze na přímé aliasy (s jednou cílovou mailovou schránkou), s výjimkou doménových košů a samotné mailové schránky.",
- "spamfilter_default_score": "Výchozí hodnoty:",
+ "spamfilter_bl": "Seznam zákazů",
+ "spamfilter_bl_desc": "Zakázané emailové adresy budou <b>vždy</b> klasifikovány jako spam a odmítnuty. Odmítnutá pošta <b>se neukládá</b> do karantény. Lze použít zástupné znaky (*). Filtr se použije pouze na přímé aliasy (s jednou cílovou poštovní schránkou), s výjimkou doménových košů a samotné poštovní schránky.",
+ "spamfilter_default_score": "Výchozí hodnoty",
"spamfilter_green": "Zelená: tato zpráva není spam",
"spamfilter_hint": "První hodnota představuje \"nízké spam skóre\" a druhá \"vysoké spam skóre\".",
"spamfilter_red": "Červená: Tato zpráva je spam a server ji odmítne",
@@ -1232,7 +1366,7 @@
"spamfilter_table_empty": "Žádná data k zobrazení",
"spamfilter_table_remove": "smazat",
"spamfilter_table_rule": "Pravidlo",
- "spamfilter_wl": "Seznam povolených adres (whitelist)",
+ "spamfilter_wl": "Seznam povolení",
"spamfilter_wl_desc": "Povolené emailové adresy <b>nebudou nikdy klasifikovány jako spam</b>. Lze použít zástupné znaky (*). Filtr se použije pouze na přímé aliasy (s jednou cílovou mailovou schránkou), s výjimkou doménových košů a samotné mailové schránky.",
"spamfilter_yellow": "Žlutá: tato zpráva může být spam, bude označena jako spam a přesunuta do složky nevyžádané pošty",
"status": "Stav",
@@ -1254,7 +1388,7 @@
"tag_in_subject": "V předmětu",
"text": "Text",
"title": "Předmět",
- "tls_enforce_in": "Vynutit TLS pro příchozí poštu ",
+ "tls_enforce_in": "Vynutit TLS pro příchozí poštu",
"tls_enforce_out": "Vynutit TLS pro odchozí poštu",
"tls_policy": "Politika šifrování",
"tls_policy_warning": "<strong>Varování:</strong> Pokud se rozhodnete vynutit šifrovaný přenos pošty, může dojít ke ztrátě e-mailů.<br>Zprávy, které nesplňují tuto politiku, budou mailovým systémem odmítnuty.<br>Tato volba ovlivňuje primární e-mailovou adresu (přihlašovací jméno), všechny adresy odvozené z doménových aliasů i aliasy, jež mají tuto mailovou schránku jako cíl.",
@@ -1268,7 +1402,18 @@
"with_app_password": "s heslem aplikace",
"year": "rok",
"years": "let",
- "pushover_sound": "Zvukové upozornění"
+ "pushover_sound": "Zvukové upozornění",
+ "password_reset_info": "Pokud není zadán e-mail pro obnovení hesla, nelze tuto funkci použít.",
+ "pw_recovery_email": "E-mail pro obnovení hesla",
+ "tfa_info": "Dvoufaktorová autentizace vám pomáhá chránit svůj účet. Je-li zapnuta, musíte si vytvořit aplikační hesla pro aplikace, jež dvoufaktorovou autentizaci nepodporují (např. poštovní klienti).",
+ "attribute": "Atribut",
+ "authentication": "Autentifikace",
+ "overview": "Přehled",
+ "protocols": "Protokoly",
+ "value": "Hodnota",
+ "expire_never": "Nikdy nevyprší",
+ "forever": "Navždy",
+ "spam_aliases_info": "Spam alias je dočasná adresa, již lze použít k ochraně skutečných adres. <br>Případně lze nastavit také dobu platnosti, po níž je alias automaticky deaktivován, čímž se řeší případy zneužitých či odcizených adres."
},
"warning": {
"cannot_delete_self": "Nelze smazat právě přihlášeného uživatele",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.da-dk.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.da-dk.json
index 95db916..f71fcfe 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.da-dk.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.da-dk.json
@@ -444,12 +444,9 @@
"external_logs": "Eksterne logfiler",
"history_all_servers": "Historie (alle servere)",
"in_memory_logs": "In-memory logs",
- "jvm_memory_solr": "Brug af JVM-hukommelse",
"log_info": "<p>mailcow <b>in-memory logs</b> er samlet i Redis-lister og trimmet til LOG_LINES (%d) hvert minut for at reducere hamring.\r\n <br>Logbøger i hukommelsen er ikke beregnet til at være vedholdende. Alle applikationer, der logger ind i hukommelsen, logger også på Docker-dæmonen og derfor til standardlogdriveren.\r\n <br>Logtypen i hukommelsen skal bruges til fejlfinding af mindre problemer med containere.</p>\r\n <p><b>Eksterne logfiler</b> indsamles via API for den givne applikation.</p>\r\n <p><b>Statiske logfiler</b> er for det meste aktivitetslogfiler, der ikke er logget på Dockerd, men stadig skal være vedholdende (undtagen API-logfiler).</p>",
"logs": "Logs",
"restart_container": "Genstart",
- "solr_dead": "Solr starter, deaktiveres eller døde.",
- "solr_status": "Solr-status",
"started_on": "Startede den",
"static_logs": "Statiske logfiler",
"system_containers": "System og Beholdere",
@@ -604,7 +601,7 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Login",
"mobileconfig_info": "Log ind som postkassebruger for at downloade den anmodede Apple-forbindelsesprofil.",
- "other_logins": "Nøgle login",
+ "other_logins": "eller log ind med",
"password": "Adgangskode",
"username": "Brugernavn"
},
@@ -709,7 +706,7 @@
"recipient_map": "Modtagerkort",
"recipient_map_info": "Modtagerkort bruges til at erstatte destinationsadressen i en meddelelse, før den leveres.",
"recipient_map_new": "Ny modtager",
- "recipient_map_new_info": "Modtagerkortdestination skal være en gyldig e-mail-adresse.",
+ "recipient_map_new_info": "Modtagerkortdestination skal være gyldige e-mail-adresser eller et domænenavn.",
"recipient_map_old": "Original modtager",
"recipient_map_old_info": "En modtager kortlægger den originale destination, skal være gyldige e-mail-adresser eller et domænenavn.",
"recipient_maps": "Modtagerkort",
@@ -825,9 +822,7 @@
},
"start": {
"help": "Vis / skjul hjælpepanel",
- "imap_smtp_server_auth_info": "Brug din fulde e-mail-adresse og PLAIN-godkendelsesmekanismen.<br>\r\nDine login-data bliver krypteret af den obligatoriske kryptering på serversiden.",
- "mailcow_apps_detail": "Brug en mailcow-app til at få adgang til dine mails, kalender, kontakter og mere.",
- "mailcow_panel_detail": "<b>Domæneadministratorer</b> oprette, ændre eller slette postkasser og aliasser, ændre domæner og læse yderligere information om deres tildelte domæner.<br>\r\n<b>Mailbox-brugere</b>er i stand til at oprette tidsbegrænsede aliaser (spamaliaser), ændre deres adgangskode og spamfilterindstillinger."
+ "imap_smtp_server_auth_info": "Brug din fulde e-mail-adresse og PLAIN-godkendelsesmekanismen.<br>\r\nDine login-data bliver krypteret af den obligatoriske kryptering på serversiden."
},
"success": {
"acl_saved": "ACL til objekt %s gemt",
@@ -971,6 +966,7 @@
"create_syncjob": "Opret nyt sync job",
"daily": "Dagligt",
"day": "dag",
+ "description": "Beskrivelse",
"delete_ays": "Bekræft venligst ønsket om sletning.",
"direct_aliases": "Direkte alias addresser",
"direct_aliases_desc": "Direkte alias-adresser påvirkes af spamfilter og TLS-politiske indstillinger.",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.de-de.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.de-de.json
index 2298e1c..67f78e0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.de-de.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.de-de.json
@@ -1,6 +1,7 @@
{
"acl": {
"alias_domains": "Alias-Domains hinzufügen",
+ "alias_external_goto": "Aliase mit externen Ziel-Domains erlauben",
"app_passwds": "App-Passwörter verwalten",
"bcc_maps": "BCC-Maps",
"delimiter_action": "Delimiter-Aktionen (tags)",
@@ -13,7 +14,8 @@
"mailbox_relayhost": "Relayhost für eine Mailbox setzen",
"prohibited": "Untersagt durch Richtlinie",
"protocol_access": "Ändern der erlaubten Protokolle",
- "pushover": "Pushover",
+ "pushover": "Pushover-Berechtigung",
+ "pw_reset": "Verwalten der E-Mail zur Passwortwiederherstellung erlauben",
"quarantine": "Quarantäne-Aktionen",
"quarantine_attachments": "Anhänge aus Quarantäne",
"quarantine_category": "Ändern der Quarantäne-Benachrichtigungskategorie",
@@ -24,7 +26,7 @@
"sogo_access": "Verwalten des SOGo-Zugriffsrechts erlauben",
"sogo_profile_reset": "SOGo-Profil zurücksetzen",
"spam_alias": "Temporäre E-Mail-Aliasse",
- "spam_policy": "Blacklist/Whitelist",
+ "spam_policy": "Deny/Allowlist",
"spam_score": "Spam-Bewertung",
"syncjobs": "Sync Jobs",
"tls_policy": "Verschlüsselungsrichtlinie",
@@ -70,6 +72,9 @@
"goto_spam": "Nachrichten als <span class=\"text-danger\"><b>Spam</b></span> lernen",
"hostname": "Host",
"inactive": "Inaktiv",
+ "internal": "Intern",
+ "internal_info": "Interne Aliasse sind nur von der eigenen Domäne oder Alias-Domänen erreichbar.",
+ "sender_allowed": "Als dieser Alias senden erlauben",
"kind": "Art",
"mailbox_quota_def": "Standard-Quota einer Mailbox",
"mailbox_quota_m": "Max. Speicherplatz pro Mailbox (MiB)",
@@ -92,7 +97,7 @@
"relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> Transport-Maps können erstellt werden, um individuelle Ziele für eine Relay-Domain zu definieren.",
"relay_unknown_only": "Nur nicht-lokale Mailboxen relayen. Existente Mailboxen werden weiterhin lokal zugestellt.",
"relayhost_wrapped_tls_info": "Bitte <b>keine</b> \"TLS-wrapped Ports\" verwenden (etwa SMTPS via Port 465/tcp).<br>\r\nDer Transport wird stattdessen STARTTLS anfordern, um TLS zu verwenden. TLS kann unter \"TLS Policy Maps\" erzwungen werden.",
- "select": "Bitte auswählen",
+ "select": "Bitte auswählen...",
"select_domain": "Bitte zuerst eine Domain auswählen",
"sieve_desc": "Kurze Beschreibung",
"sieve_type": "Filtertyp",
@@ -133,18 +138,20 @@
"admin_domains": "Domain-Zuweisungen",
"admins": "Administratoren",
"admins_ldap": "LDAP-Administratoren",
+ "admin_quicklink": "Quicklink zur Admin-Loginseite ausblenden",
"advanced_settings": "Erweiterte Einstellungen",
"api_allow_from": "IP-Adressen oder Netzwerke (CIDR Notation) für Zugriff auf API",
"api_info": "Die API befindet sich noch in Entwicklung, die Dokumentation kann unter <a href=\"/api\">/api</a> abgerufen werden.",
"api_key": "API-Key",
"api_skip_ip_check": "IP-Check für API nicht ausführen",
+ "app_hide": "Für Login verstecken",
"app_links": "App-Links",
"app_name": "App-Name",
"apps_name": "\"mailcow Apps\" Name",
"arrival_time": "Ankunftszeit (Serverzeit)",
"authed_user": "Auth. Benutzer",
"ays": "Soll der Vorgang wirklich ausgeführt werden?",
- "ban_list_info": "Übersicht ausgesperrter Netzwerke: <b>Netzwerk (verbleibende Bannzeit) - [Aktionen]</b>.<br />IPs, die zum Entsperren eingereiht werden, verlassen die Liste aktiver Banns nach wenigen Sekunden.<br />Rote Labels sind Indikatoren für aktive Blacklist-Einträge.",
+ "ban_list_info": "Übersicht ausgesperrter Netzwerke: <b>Netzwerk (verbleibende Bannzeit) - [Aktionen]</b>.<br />IPs, die zum Entsperren eingereiht werden, verlassen die Liste aktiver Banns nach wenigen Sekunden.<br />Rote Labels kennzeichnen aktive permanente Sperren durch Denylisting.",
"change_logo": "Logo ändern",
"configuration": "Konfiguration",
"convert_html_to_text": "Konvertiere HTML zu reinem Text",
@@ -153,6 +160,7 @@
"credentials_transport_warning": "<b>Warnung</b>: Das Hinzufügen einer neuen Regel bewirkt die Aktualisierung der Authentifizierungsdaten aller vorhandenen Einträge mit identischem Next Hop.",
"customer_id": "Kunde",
"customize": "UI-Anpassung",
+ "login_page": "Login-Seite",
"destination": "Ziel",
"dkim_add_key": "ARC/DKIM-Key hinzufügen",
"dkim_domains_selector": "Selector",
@@ -171,6 +179,7 @@
"domain": "Domain",
"domain_admin": "Administrator hinzufügen",
"domain_admins": "Domain-Administratoren",
+ "domainadmin_quicklink": "Quicklink zur Domainadmin-Loginseite ausblenden",
"domain_s": "Domain(s)",
"duplicate": "Duplizieren",
"duplicate_dkim": "DKIM duplizieren",
@@ -179,9 +188,9 @@
"excludes": "Diese Empfänger ausschließen",
"f2b_ban_time": "Bannzeit in Sekunden",
"f2b_ban_time_increment": "Bannzeit erhöht sich mit jedem Bann",
- "f2b_blacklist": "Blacklist für Netzwerke und Hosts",
+ "f2b_blacklist": "Denyliste für Netzwerke und Hosts",
"f2b_filter": "Regex-Filter",
- "f2b_list_info": "Ein Host oder Netzwerk auf der Blacklist wird immer eine Whitelist-Einheit überwiegen. <b>Die Aktualisierung der Liste dauert einige Sekunden.</b>",
+ "f2b_list_info": "Ein Host oder Netzwerk auf der Denyliste wird immer eine Allowlist-Einheit überwiegen. <b>Die Aktualisierung der Liste dauert einige Sekunden.</b>",
"f2b_manage_external": "Fail2Ban extern verwalten",
"f2b_manage_external_info": "Fail2ban wird die Banlist weiterhin pflegen, jedoch werden keine aktiven Regeln zum blockieren gesetzt. Die unten generierte Banlist, kann verwendet werden, um den Datenverkehr extern zu blockieren.",
"f2b_max_attempts": "Max. Versuche",
@@ -191,8 +200,10 @@
"f2b_parameters": "Fail2ban-Parameter",
"f2b_regex_info": "Berücksichtigte Logs: SOGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Wiederholungen im Zeitraum von (s)",
- "f2b_whitelist": "Whitelist für Netzwerke und Hosts",
+ "f2b_whitelist": "Allowliste für Netzwerke und Hosts",
"filter_table": "Tabelle filtern",
+ "force_sso_text": "Wenn ein externer OIDC-Provider konfiguriert ist, blendet diese Option die mailcow-Loginform aus und zeigt nur den Single-Sign-On-Button an.",
+ "force_sso": "mailcow-Login deaktivieren und nur Single Sign-On anzeigen",
"forwarding_hosts": "Weiterleitungs-Hosts",
"forwarding_hosts_add_hint": "Sie können entweder IPv4-/IPv6-Adressen, Netzwerke in CIDR-Notation, Hostnamen (die zu IP-Adressen aufgelöst werden), oder Domainnamen (die zu IP-Adressen aufgelöst werden, indem ihr SPF-Record abgefragt wird oder, in dessen Abwesenheit, ihre MX-Records) angeben.",
"forwarding_hosts_hint": "Eingehende Nachrichten werden von den hier gelisteten Hosts bedingungslos akzeptiert. Diese Hosts werden dann nicht mit DNSBLs abgeglichen oder Greylisting unterworfen. Von ihnen empfangener Spam wird nie abgelehnt, optional kann er aber in den Spam-Ordner einsortiert werden. Die übliche Verwendung für diese Funktion ist, um Mailserver anzugeben, auf denen eine Weiterleitung zu Ihrem mailcow-Server eingerichtet wurde.",
@@ -204,6 +215,44 @@
"help_text": "Hilfstext unter Login-Maske (HTML ist zulässig)",
"host": "Host",
"html": "HTML",
+ "iam": "Identity Provider",
+ "iam_attribute_field": "Attribut Feld",
+ "iam_authorize_url": "Authorization Endpunkt",
+ "iam_auth_flow": "Authentication Flow",
+ "iam_auth_flow_info": "Zusätzlich zum Authorization Code Flow (dem Standard-Flow in Keycloak), der für Single-Sign-On-Logins verwendet wird, unterstützt mailcow auch den Authentication Flow mit direkten Anmeldeinformationen. Der Mailpassword Flow versucht, die Anmeldedaten des Benutzers über die Keycloak Admin REST API zu validieren. Dabei ruft mailcow das gehashte Passwort aus dem <code>mailcow_password</code> Attribut ab, das in Keycloak zugewiesen ist.",
+ "iam_basedn": "Base DN",
+ "iam_client_id": "Client ID",
+ "iam_client_secret": "Client Secret",
+ "iam_client_scopes": "Client Scopes",
+ "iam_default_template": "Standardvorlage",
+ "iam_default_template_description": "Falls für einen Benutzer kein Template hinterlegt ist, wird die Standardvorlage zum Erstellen der Mailbox verwendet, jedoch nicht zum Aktualisieren der Mailbox.",
+ "iam_description": "Konfiguriere einen externen Identity Provider für die Authentifizierung<br>Die Mailboxen der Benutzer werden bei ihrer ersten Anmeldung automatisch erstellt, vorausgesetzt, dass ein Attribut Mapping festgelegt wurde.",
+ "iam_extra_permission": "Damit die folgenden Einstellungen funktionieren, benötigt der mailcow Client in Keycloak ein <code>Service-Konto</code> und die Berechtigung <code>view-users</code>.",
+ "iam_host": "Host",
+ "iam_host_info": "Gib einen oder mehrere LDAP-Hosts ein, getrennt durch Kommas.",
+ "iam_import_users": "Importiere Benutzer",
+ "iam_login_provisioning": "Benutzer beim Login erstellen",
+ "iam_mapping": "Attribut Mapping",
+ "iam_bindpass": "Bind Passwort",
+ "iam_periodic_full_sync": "Vollsynchronisation",
+ "iam_port": "Port",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "Redirect Url",
+ "iam_rest_flow": "Mailpassword Flow",
+ "iam_server_url": "Server Url",
+ "iam_sso": "Single Sign-On",
+ "iam_sync_interval": "Sync / Import interval (min)",
+ "iam_test_connection": "Verbindung Testen",
+ "iam_token_url": "Token Endpunkt",
+ "iam_userinfo_url": "User info Endpunkt",
+ "iam_username_field": "Username Feld",
+ "iam_binddn": "Bind DN",
+ "iam_use_ssl": "Benutze SSL",
+ "iam_use_ssl_info": "Wenn SSL aktiviert ist und der Port auf 389 gesetzt wurde, wird dieser automatisch auf 636 geändert.",
+ "iam_use_tls": "Benutze StartTLS",
+ "iam_use_tls_info": "Wenn TLS aktiviert wird, muss der Standardport deines LDAP-Servers (389) verwendet werden. SSL-Ports können dabei nicht verwendet werden.",
+ "iam_version": "Version",
+ "ignore_ssl_error": "Ignoriere SSL Fehler",
"import": "Importieren",
"import_private_key": "Private Key importieren",
"in_use_by": "Verwendet von",
@@ -227,6 +276,7 @@
"message": "Nachricht",
"message_size": "Nachrichtengröße",
"nexthop": "Next Hop",
+ "needs_restart": "benötigt Neustart",
"no": "✕",
"no_active_bans": "Keine aktiven Banns",
"no_new_rows": "Keine weiteren Zeilen vorhanden",
@@ -248,6 +298,11 @@
"password_policy_numbers": "Muss eine Ziffer enthalten",
"password_policy_special_chars": "Muss Sonderzeichen enthalten",
"password_repeat": "Passwort wiederholen",
+ "password_reset_info": "Wenn keine E-Mail zur Passwortwiederherstellung hinterlegt ist, kann diese Funktion nicht genutzt werden.",
+ "password_reset_settings": "Einstellungen zur Passwortwiederherstellung",
+ "password_reset_tmpl_html": "HTML Vorlage",
+ "password_reset_tmpl_text": "Text Vorlage",
+ "password_settings": "Passwort Einstellungen",
"priority": "Gewichtung",
"private_key": "Private Key",
"quarantine": "Quarantäne",
@@ -264,6 +319,7 @@
"quarantine_release_format_att": "Als Anhang",
"quarantine_release_format_raw": "Unverändertes Original",
"quarantine_retention_size": "Rückhaltungen pro Mailbox:<br><small>0 bedeutet <b>inaktiv</b>.</small>",
+ "quicklink_text": "Quicklinks zu anderen Login-Seiten unter der Loginform ein- oder ausblenden",
"quota_notification_html": "Benachrichtigungs-E-Mail Inhalt:<br><small>Leer lassen, um Standard-Template wiederherzustellen.</small>",
"quota_notification_sender": "Benachrichtigungs-E-Mail Absender",
"quota_notification_subject": "Benachrichtigungs-E-Mail Betreff",
@@ -287,6 +343,8 @@
"remove_row": "Entfernen",
"reset_default": "Zurücksetzen auf Standard",
"reset_limit": "Hash entfernen",
+ "reset_password_vars": "<code>{{link}}</code> Der generierte Passwort-Reset-Link<br><code>{{username}}</code> Die E-Mail-Adresse des Benutzers, der die Passwortzurücksetzung angefordert hat<br><code>{{username2}}</code> Die E-Mail-Adresse zur Wiederherstellung<br><code>{{date}}</code> Das Datum, an dem die Passwort-Reset-Anfrage gestellt wurde<br><code>{{token_lifetime}}</code> Die Gültigkeitsdauer des Tokens in Minuten<br><code>{{hostname}}</code> Der mailcow Hostname",
+ "restore_template": "Leer lassen, um Standard-Template wiederherzustellen.",
"routing": "Routing",
"rsetting_add_rule": "Regel hinzufügen",
"rsetting_content": "Regelinhalt",
@@ -301,8 +359,8 @@
"rspamd_com_settings": "Ein Name wird automatisch generiert. Beispielinhalte zur Einsicht stehen nachstehend bereit. Siehe auch <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd docs</a>",
"rspamd_global_filters": "Globale Filter-Maps",
"rspamd_global_filters_agree": "Ich werde vorsichtig sein!",
- "rspamd_global_filters_info": "Globale Filter-Maps steuern globales White- und Blacklisting dieses Servers.",
- "rspamd_global_filters_regex": "Die akzeptierte Form für Einträge sind <b>ausschließlich</b> Regular Expressions.\r\n Trotz rudimentärer Überprüfung der Map, kann es zu fehlerhaften Einträgen kommen, die Rspamd im schlechtesten Fall mit unvorhersehbarer Funktionalität bestraft.<br>\r\n Das korrekte Format lautet \"/pattern/options\" (Beispiel: <code>/.+@domain\\.tld/i</code>).<br>\r\n Der Name der Map beschreibt die jeweilige Funktion.<br>\r\n Rspamd versucht die Maps umgehend aufzulösen. Bei Problemen sollte <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">Rspamd manuell neugestartet werden</a>.<br>Elemente auf Blacklists sind von der Quarantäne ausgeschlossen.",
+ "rspamd_global_filters_info": "Globale Filter-Maps steuern globales Allow- und Denylisting dieses Servers.",
+ "rspamd_global_filters_regex": "Die akzeptierte Form für Einträge sind <b>ausschließlich</b> Regular Expressions.\r\n Trotz rudimentärer Überprüfung der Map, kann es zu fehlerhaften Einträgen kommen, die Rspamd im schlechtesten Fall mit unvorhersehbarer Funktionalität bestraft.<br>\r\n Das korrekte Format lautet \"/pattern/options\" (Beispiel: <code>/.+@domain\\.tld/i</code>).<br>\r\n Der Name der Map beschreibt die jeweilige Funktion.<br>\r\n Rspamd versucht die Maps umgehend aufzulösen. Bei Problemen sollte <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">Rspamd manuell neugestartet werden</a>.<br>Elemente auf Denylisten sind von der Quarantäne ausgeschlossen.",
"rspamd_settings_map": "Rspamd-Settings-Map",
"sal_level": "Moo-Level",
"save": "Änderungen speichern",
@@ -316,6 +374,7 @@
"subject": "Betreff",
"success": "Erfolg",
"sys_mails": "System-E-Mails",
+ "task": "Aufgabe",
"text": "Text",
"time": "Zeit",
"title": "Title",
@@ -336,10 +395,16 @@
"ui_header_announcement_type_info": "Info",
"ui_header_announcement_type_warning": "Wichtig",
"ui_texts": "UI-Label und Texte",
+ "ui_theme": "Theme",
+ "ui_theme_dark": "Enthält eine Darkmode-Variante",
+ "ui_theme_default": "Standard",
+ "ui_theme_info": "Themes sind Ordner in <code>data/web/css/themes/<name>/</code> mit folgenden Dateien:<ul class=\"mb-0\"><li><code>theme.css</code> (erforderlich)</li><li><code>dark.css</code> (optional, Darkmode)</li><li><code>bootstrap.css</code> (optional, ersetzt das Bootstrap-Basistheme)</li><li><code>theme.json</code> (optional, <code>name</code> und <code>description</code>)</li></ul>",
+ "ui_theme_none": "Keine Themes gefunden.",
"unban_pending": "ausstehend",
"unchanged_if_empty": "Unverändert, wenn leer",
"upload": "Hochladen",
"username": "Benutzername",
+ "user_quicklink": "Quicklink zur Benutzer-Loginseite ausblenden",
"validate_license_now": "GUID erneut verifizieren",
"verify": "Verifizieren",
"yes": "✓",
@@ -351,7 +416,9 @@
"allowed_methods": "Access-Control-Allow-Methods",
"allowed_origins": "Access-Control-Allow-Origin",
"logo_dark_label": "Invertiert für den Darkmode",
- "logo_normal_label": "Normal"
+ "logo_normal_label": "Normal",
+ "user_link": "Nutzer-Link",
+ "filter": "Filter"
},
"danger": {
"access_denied": "Zugriff verweigert oder unvollständige/ungültige Daten",
@@ -363,13 +430,14 @@
"aliases_in_use": "Maximale Anzahl an Aliassen muss größer oder gleich %d sein",
"app_name_empty": "App-Name darf nicht leer sein",
"app_passwd_id_invalid": "App-Passwort ID %s ist ungültig",
+ "authsource_in_use": "Der Identity Provider kann nicht geändert oder gelöscht werden, da er derzeit von einem oder mehreren Benutzern verwendet wird.",
"bcc_empty": "BCC-Ziel darf nicht leer sein",
"bcc_exists": "Ein BCC-Map-Eintrag %s existiert bereits als Typ %s",
"bcc_must_be_email": "BCC-Ziel %s ist keine gültige E-Mail-Adresse",
"comment_too_long": "Kommentarfeld darf maximal 160 Zeichen enthalten",
"cors_invalid_method": "Allow-Methods enthält eine ungültige Methode",
"cors_invalid_origin": "Allow-Origins enthält eine ungültige Origin",
- "defquota_empty": "Standard-Quota darf nicht 0 sein",
+ "defquota_empty": "Standard-Quota darf nicht 0 sein.",
"demo_mode_enabled": "Demo Mode ist aktiviert",
"description_invalid": "Ressourcenbeschreibung für %s ist ungültig",
"dkim_domain_or_sel_exists": "Ein DKIM-Key für die Domain \"%s\" existiert und wird nicht überschrieben",
@@ -381,23 +449,26 @@
"domain_not_found": "Domain %s nicht gefunden",
"domain_quota_m_in_use": "Domain-Speicherplatzlimit muss größer oder gleich %d MiB sein",
"extended_sender_acl_denied": "Keine Rechte zum Setzen von externen Absenderadressen",
+ "external_goto_denied": "Externe Ziel-Adresse %s ist nicht erlaubt",
"extra_acl_invalid": "Externe Absenderadresse \"%s\" ist ungültig",
"extra_acl_invalid_domain": "Externe Absenderadresse \"%s\" verwendet eine ungültige Domain",
"fido2_verification_failed": "FIDO2-Verifizierung fehlgeschlagen: %s",
"file_open_error": "Datei kann nicht zum Schreiben geöffnet werden",
"filter_type": "Falscher Filtertyp",
"from_invalid": "Die Absenderadresse muss eine gültige E-Mail-Adresse sein",
+ "generic_server_error": "Ein unerwarteter Serverfehler ist aufgetreten. Bitte kontaktieren Sie Ihren Administrator.",
"global_filter_write_error": "Kann Filterdatei nicht schreiben: %s",
"global_map_invalid": "Rspamd-Map %s ist ungültig",
"global_map_write_error": "Kann globale Map ID %s nicht schreiben: %s",
"goto_empty": "Eine Alias-Adresse muss auf mindestens eine gültige Ziel-Adresse zeigen",
"goto_invalid": "Ziel-Adresse %s ist ungültig",
- "ham_learn_error": "Ham Lernfehler: %s",
+ "ham_learn_error": "Ham-Lernfehler: %s",
+ "iam_test_connection": "Verbindung fehlgeschlagen",
"imagick_exception": "Fataler Bildverarbeitungsfehler",
"img_dimensions_exceeded": "Grafik überschreitet die maximale Bildgröße",
"img_invalid": "Grafik konnte nicht validiert werden",
"img_size_exceeded": "Grafik überschreitet die maximale Dateigröße",
- "img_tmp_missing": "Grafik konnte nicht validiert werden: Erstellung temporärer Datei fehlgeschlagen.",
+ "img_tmp_missing": "Grafik konnte nicht validiert werden: Temporärer Datei nicht gefunden.",
"invalid_bcc_map_type": "Ungültiger BCC-Map-Typ",
"invalid_destination": "Ziel-Format \"%s\" ist ungültig",
"invalid_filter_type": "Ungültiger Filtertyp",
@@ -407,9 +478,10 @@
"invalid_nexthop_authenticated": "Dieser Next Hop existiert bereits mit abweichenden Authentifizierungsdaten. Die bestehenden Authentifizierungsdaten dieses \"Next Hops\" müssen vorab angepasst werden.",
"invalid_recipient_map_new": "Neuer Empfänger \"%s\" ist ungültig",
"invalid_recipient_map_old": "Originaler Empfänger \"%s\" ist ungültig",
+ "invalid_reset_token": "Ungültiger Rücksetz-Token",
"ip_list_empty": "Liste erlaubter IPs darf nicht leer sein",
"is_alias": "%s lautet bereits eine Alias-Adresse",
- "is_alias_or_mailbox": "Eine Mailbox, ein Alias oder eine sich aus einer Alias-Domain ergebende Adresse mit dem Namen %s ist bereits vorhanden",
+ "is_alias_or_mailbox": "Eine Mailbox, ein Alias oder eine sich aus einer Alias-Domain ergebende Adresse mit dem Namen %s ist bereits vorhanden.",
"is_spam_alias": "%s lautet bereits eine temporäre Alias-Adresse (Spam-Alias-Adresse)",
"last_key": "Letzter Key kann nicht gelöscht werden, bitte stattdessen die 2FA deaktivieren.",
"login_failed": "Anmeldung fehlgeschlagen",
@@ -421,10 +493,13 @@
"mailboxes_in_use": "Maximale Anzahl an Mailboxen muss größer oder gleich %d sein",
"malformed_username": "Benutzername hat ein falsches Format",
"map_content_empty": "Inhalt darf nicht leer sein",
+ "max_age_invalid": "Maximales Alter %s ist ungültig",
"max_alias_exceeded": "Anzahl an Alias-Adressen überschritten",
"max_mailbox_exceeded": "Anzahl an Mailboxen überschritten (%d von %d)",
"max_quota_in_use": "Mailbox-Speicherplatzlimit muss größer oder gleich %d MiB sein",
"maxquota_empty": "Max. Speicherplatz pro Mailbox darf nicht 0 sein.",
+ "mode_invalid": "Modus %s ist ungültig",
+ "mx_invalid": "MX-Eintrag %s ist ungültig",
"mysql_error": "MySQL-Fehler: %s",
"network_host_invalid": "Netzwerk oder Host ungültig: %s",
"next_hop_interferes": "%s verhindert das Hinzufügen von Next Hop %s",
@@ -436,18 +511,23 @@
"password_complexity": "Passwort entspricht nicht den Richtlinien",
"password_empty": "Passwort darf nicht leer sein",
"password_mismatch": "Passwort-Wiederholung stimmt nicht überein",
+ "password_reset_invalid_user": "Benutzer nicht gefunden oder keine E-Mail-Adresse zur Wiederherstellung eingerichtet",
+ "password_reset_na": "Die Passwortwiederherstellung ist momentan nicht verfügbar. Bitte wenden Sie sich an Ihren Administrator.",
"policy_list_from_exists": "Ein Eintrag mit diesem Wert existiert bereits",
"policy_list_from_invalid": "Eintrag hat ein ungültiges Format",
"private_key_error": "Schlüsselfehler: %s",
"pushover_credentials_missing": "Pushover Token und/oder Key fehlen",
"pushover_key": "Pushover Key hat das falsche Format",
"pushover_token": "Pushover Token hat das falsche Format",
+ "quarantine_category_invalid": "Quarantäne-Kategorie muss eine der folgenden sein: add_header, reject, all",
"quota_not_0_not_numeric": "Speicherplatz muss numerisch und >= 0 sein",
"recipient_map_entry_exists": "Eine Empfängerumschreibung für Objekt \"%s\" existiert bereits",
+ "recovery_email_failed": "E-Mail zur Wiederherstellung konnte nicht gesendet werden. Bitte wenden Sie sich an Ihren Administrator.",
"redis_error": "Redis Fehler: %s",
"relayhost_invalid": "Map-Eintrag %s ist ungültig",
"release_send_failed": "Die Nachricht konnte nicht versendet werden: %s",
"reset_f2b_regex": "Regex-Filter konnten nicht in vorgegebener Zeit zurückgesetzt werden, bitte erneut versuchen oder die Webseite neu laden.",
+ "reset_token_limit_exceeded": "Das Limit für Rücksetz-Tokens wurde überschritten. Bitte versuchen Sie es später erneut.",
"resource_invalid": "Ressourcenname %s ist ungültig",
"rl_timeframe": "Ratelimit-Zeitraum ist inkorrekt",
"rspamd_ui_pw_length": "Rspamd UI-Passwort muss mindestens 6 Zeichen lang sein",
@@ -464,25 +544,30 @@
"temp_error": "Temporärer Fehler",
"text_empty": "Text darf nicht leer sein",
"tfa_token_invalid": "TFA-Token ungültig",
+ "tfa_removal_blocked": "Zwei-Faktor-Authentifizierung kann nicht entfernt werden, da sie für Ihr Konto erforderlich ist.",
"tls_policy_map_dest_invalid": "Ziel ist ungültig",
"tls_policy_map_entry_exists": "Eine TLS-Richtlinie \"%s\" existiert bereits",
"tls_policy_map_parameter_invalid": "Parameter ist ungültig",
+ "to_invalid": "Empfänger darf nicht leer sein",
"totp_verification_failed": "TOTP-Verifizierung fehlgeschlagen",
"transport_dest_exists": "Transport-Maps-Ziel \"%s\" existiert bereits",
"webauthn_verification_failed": "WebAuthn-Verifizierung fehlgeschlagen: %s",
"webauthn_authenticator_failed": "Der ausgewählte Authenticator wurde nicht gefunden",
"webauthn_publickey_failed": "Zu dem ausgewählten Authenticator wurde kein Publickey hinterlegt",
"webauthn_username_failed": "Der ausgewählte Authenticator gehört zu einem anderen Konto",
+ "ui_theme_invalid": "Theme nicht gefunden",
"unknown": "Ein unbekannter Fehler trat auf",
"unknown_tfa_method": "Unbekannte TFA-Methode",
"unlimited_quota_acl": "Unendliche Quota untersagt durch ACL",
"username_invalid": "Benutzername %s kann nicht verwendet werden",
"validity_missing": "Bitte geben Sie eine Gültigkeitsdauer an",
"value_missing": "Bitte alle Felder ausfüllen",
+ "version_invalid": "Version %s ist ungültig",
"yotp_verification_failed": "Yubico OTP-Verifizierung fehlgeschlagen: %s",
"template_exists": "Vorlage %s existiert bereits",
"template_id_invalid": "Vorlagen-ID %s ungültig",
- "template_name_invalid": "Name der Vorlage ungültig"
+ "template_name_invalid": "Name der Vorlage ungültig",
+ "required_data_missing": "Die benötigten Daten: %s fehlen"
},
"datatables": {
"collapse_all": "Alle Einklappen",
@@ -525,7 +610,6 @@
"external_logs": "Externe Logs",
"history_all_servers": "History (alle Server)",
"in_memory_logs": "In-memory Logs",
- "jvm_memory_solr": "JVM-Speicherauslastung",
"last_modified": "Zuletzt geändert",
"log_info": "<p>mailcow <b>in-memory Logs</b> werden in Redis Listen gespeichert, die maximale Anzahl der Einträge pro Anwendung richtet sich nach LOG_LINES (%d).\r\n <br>In-memory Logs sind vergänglich und nicht zur ständigen Aufbewahrung bestimmt. Alle Anwendungen, die in-memory protokollieren, schreiben ebenso in den Docker Daemon.\r\n <br>Das in-memory Protokoll versteht sich als schnelle Übersicht zum Debugging eines Containers, für komplexere Protokolle sollte der Docker Daemon konsultiert werden.</p>\r\n <p><b>Externe Logs</b> werden via API externer Applikationen bezogen.</p>\r\n <p><b>Statische Logs</b> sind weitestgehend Aktivitätsprotokolle, die nicht in den Docker Daemon geschrieben werden, jedoch permanent verfügbar sein müssen (ausgeschlossen API Logs).</p>",
"login_time": "Zeit",
@@ -536,8 +620,6 @@
"service": "Dienst",
"show_ip": "Zeige öffentliche IP",
"size": "Größe",
- "solr_dead": "Solr startet, ist deaktiviert oder temporär nicht erreichbar.",
- "solr_status": "Solr Status",
"started_at": "Gestartet am",
"started_on": "Gestartet am",
"static_logs": "Statische Logs",
@@ -585,7 +667,7 @@
"delete1": "Lösche Nachricht nach Übertragung vom Quell-Server",
"delete2": "Lösche Nachrichten von Ziel-Server, die nicht auf Quell-Server vorhanden sind",
"delete2duplicates": "Lösche Duplikate im Ziel",
- "delete_ays": "Soll der Löschvorgang wirklich ausgeführt werden?",
+ "delete_ays": "Bitte den Löschvorgang bestätigen.",
"description": "Beschreibung",
"disable_login": "Login verbieten (Mails werden weiterhin angenommen)",
"domain": "Domain bearbeiten",
@@ -621,12 +703,21 @@
"grant_types": "Grant-types",
"hostname": "Servername",
"inactive": "Inaktiv",
+ "internal": "Intern",
+ "internal_info": "Interne Aliasse sind nur von der eigenen Domäne oder Alias-Domänen erreichbar.",
+ "sender_allowed": "Als dieser Alias senden erlauben",
+ "sender_allowed_info": "Wenn deaktiviert, kann dieser Alias nur E-Mails empfangen. Verwenden Sie Sender-ACL, um bestimmten Postfächern die Berechtigung zum Senden zu erteilen.",
"kind": "Art",
"last_modified": "Zuletzt geändert",
"lookup_mx": "Ziel mit MX vergleichen (Regex, etwa <code>.*\\.google\\.com</code>, um alle Ziele mit MX *google.com zu routen)",
"mailbox": "Mailbox bearbeiten",
"mailbox_quota_def": "Standard-Quota einer Mailbox",
"mailbox_relayhost_info": "Wird auf eine Mailbox und direkte Alias-Adressen angewendet. Überschreibt die Einstellung einer Domain.",
+ "mailbox_rename": "Mailbox umbenennen",
+ "mailbox_rename_agree": "Ich habe ein Backup erstellt.",
+ "mailbox_rename_warning": "WICHTIG! Vor dem Umbenennen der Mailbox ein Backup erstellen.",
+ "mailbox_rename_alias": "Alias automatisch erstellen",
+ "mailbox_rename_title": "Neuer Lokaler Mailbox Name",
"max_aliases": "Max. Aliasse",
"max_mailboxes": "Max. Mailboxanzahl",
"max_quota": "Max. Größe per Mailbox (MiB)",
@@ -634,10 +725,23 @@
"maxbytespersecond": "Max. Übertragungsrate in Bytes/s (0 für unlimitiert)",
"mbox_rl_info": "Dieses Limit wird auf den SASL Loginnamen angewendet und betrifft daher alle Absenderadressen, die der eingeloggte Benutzer verwendet. Bei Mailbox Ratelimit überwiegt ein Domain-weites Ratelimit.",
"mins_interval": "Intervall (min)",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://de.wikipedia.org/wiki/STARTTLS#MTA-STS' target='_blank'>MTA-STS</a> ist ein Standard, der den E-Mail-Versand zwischen Mailservern zwingt, TLS mit gültigen Zertifikaten zu verwenden. <br>Er wird verwendet, wenn <a target='_blank' href='https://de.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> aufgrund fehlender oder nicht unterstützter DNSSEC nicht möglich ist.<br><b>Hinweis</b>: Wenn die empfangende Domain DANE mit DNSSEC unterstützt, wird DANE <b>immer</b> bevorzugt – MTA-STS fungiert nur als Fallback.",
+ "mta_sts_version": "Version",
+ "mta_sts_version_info": "Definiert die Version des MTA-STS-Standards – derzeit ist nur <code>STSv1</code> gültig.",
+ "mta_sts_mode": "Modus",
+ "mta_sts_mode_info": "Es gibt drei Modi zur Auswahl:<ul><li><em>testing</em> – Die Richtlinie wird nur überwacht, Verstöße haben keine Auswirkungen.</li><li><em>enforce</em> – Die Richtlinie wird strikt durchgesetzt, Verbindungen ohne gültiges TLS werden abgelehnt.</li><li><em>none</em> – Die Richtlinie wird veröffentlicht, aber nicht angewendet.</li></ul>",
+ "mta_sts_max_age": "Maximales Alter",
+ "mta_sts_max_age_info": "Zeit in Sekunden, die empfangende Mailserver diese Richtlinie zwischenspeichern dürfen, bevor sie erneut abgerufen wird.",
+ "mta_sts_mx": "MX-Server",
+ "mta_sts_mx_info": "Erlaubt das Senden nur an explizit aufgeführte Mailserver-Hostnamen; der sendende MTA überprüft, ob der DNS-MX-Hostname mit der Richtlinienliste übereinstimmt, und erlaubt die Zustellung nur mit einem gültigen TLS-Zertifikat (schützt vor MITM).",
+ "mta_sts_mx_notice": "Es können mehrere MX-Server angegeben werden (durch Kommas getrennt).",
+ "mta_sts_active_info": "Wenn nicht angehakt, wird die MTA-STS-Richtlinie nicht veröffentlicht und für die mta-sts-Subdomain kein Zertifikat über ACME angefordert.",
"multiple_bookings": "Mehrfaches Buchen",
"nexthop": "Next Hop",
"none_inherit": "Keine Auswahl / Erben",
"password": "Passwort",
+ "password_recovery_email": "E-Mail zur Passwortwiederherstellung",
"password_repeat": "Passwort wiederholen",
"previous": "Vorherige Seite",
"private_comment": "Privater Kommentar",
@@ -673,17 +777,17 @@
"sieve_desc": "Kurze Beschreibung",
"sieve_type": "Filtertyp",
"skipcrossduplicates": "Duplikate auch über Ordner hinweg überspringen (\"first come, first serve\")",
- "sogo_access": "Direktes Einloggen an SOGo erlauben",
- "sogo_access_info": "Single-Sign-On Zugriff über die UI wird hierdurch NICHT deaktiviert. Diese Einstellung hat weder Einfluss auf den Zugang sonstiger Dienste noch entfernt sie ein vorhandenes SOGo-Benutzerprofil.",
+ "sogo_access": "Direktes weiterleiten an SOGo",
+ "sogo_access_info": "Nach dem Einloggen wird der Benutzer automatisch an SOGo weitergeleitet.",
"sogo_visible": "Alias in SOGo sichtbar",
"sogo_visible_info": "Diese Option hat lediglich Einfluss auf Objekte, die in SOGo darstellbar sind (geteilte oder nicht-geteilte Alias-Adressen mit dem Ziel mindestens einer lokalen Mailbox).",
"spam_alias": "Anpassen temporärer Alias-Adressen",
"spam_filter": "Spamfilter",
- "spam_policy": "Hinzufügen und Entfernen von Einträgen in White- und Blacklists",
+ "spam_policy": "Hinzufügen und Entfernen von Einträgen in Allow- und Denylisten",
"spam_score": "Einen benutzerdefiniterten Spam-Score festlegen",
"subfolder2": "Ziel-Ordner<br><small>(leer = kein Unterordner)</small>",
"syncjob": "Sync-Job bearbeiten",
- "target_address": "Ziel-Adresse(n)",
+ "target_address": "Ziel-Adresse(n)<small>(kommasepariert)</small>",
"target_domain": "Ziel-Domain",
"timeout1": "Timeout für Verbindung zum Remote-Host",
"timeout2": "Timeout für Verbindung zum lokalen Host",
@@ -741,13 +845,28 @@
"session_expires": "Die Sitzung wird in etwa 15 Sekunden beendet."
},
"login": {
+ "back_to_mailcow": "Zurück zu mailcow",
"delayed": "Login wurde zur Sicherheit um %s Sekunde/n verzögert.",
"fido2_webauthn": "FIDO2/WebAuthn Login",
+ "forgot_password": "> Passwort vergessen?",
+ "invalid_pass_reset_token": "Der Rücksetz-Token für das Passwort ist ungültig oder abgelaufen.<br>Bitte fordern Sie einen neuen Link zur Passwortwiederherstellung an.",
"login": "Anmelden",
+ "login_linkstext": "Nicht der richtige Login?",
+ "login_usertext": "Als Benutzer anmelden",
+ "login_domainadmintext": "Als Domainadmin anmelden",
+ "login_admintext": "Als Admin anmelden",
+ "login_user": "Anmeldung als Benutzer",
+ "login_dadmin": "Anmeldung als Domain-Administrator",
+ "login_admin": "Anmeldung als Administrator",
"mobileconfig_info": "Bitte als Mailbox-Benutzer einloggen, um das Verbindungsprofil herunterzuladen.",
- "other_logins": "Key Login",
+ "new_password": "Neues Passwort",
+ "new_password_confirm": "Neues Passwort bestätigen",
+ "other_logins": "oder anmelden mit",
"password": "Passwort",
- "username": "Benutzername"
+ "reset_password": "Passwort zurücksetzen",
+ "request_reset_password": "Passwortänderung anfordern",
+ "username": "Benutzername",
+ "email": "E-Mail-Adresse"
},
"mailbox": {
"action": "Aktion",
@@ -768,7 +887,7 @@
"add_tls_policy_map": "TLS-Richtlinieneintrag hinzufügen",
"address_rewriting": "Adressumschreibung",
"alias": "Alias",
- "alias_domain_alias_hint": "Alias-Adressen werden <b>nicht</b> automatisch auch auf Domain-Alias Adressen angewendet. Eine Alias-Adresse <code>mein-alias@domain</code> bildet demnach <b>nicht</b> die Adresse <code>mein-alias@alias-domain</code> ab.<br>E-Mail-Weiterleitungen an externe Postfächer sollten über Sieve (SOGo Weiterleitung oder im Reiter \"Filter\") angelegt werden. Der Button \"Alias über Alias-Domains expandieren\" erstellt fehlende Alias-Adressen in Alias-Domains.",
+ "alias_domain_alias_hint": "Alias-Adressen werden <b>nicht</b> automatisch auch auf Domain-Alias Adressen angewendet. Eine Alias-Adresse <code>mein-alias@domain</code> bildet demnach <b>nicht</b> die Adresse <code>mein-alias@alias-domain</code> ab.<br>E-Mail-Weiterleitungen an externe Postfächer sollten über Sieve (SOGo Weiterleitung oder im Reiter Filter) angelegt werden. Der Button Alias über Alias-Domains expandieren erstellt fehlende Alias-Adressen in Alias-Domains.",
"alias_domain_backupmx": "Alias-Domain für Relay-Domain inaktiv",
"aliases": "Aliasse",
"allow_from_smtp": "Nur folgende IPs für <b>SMTP</b> erlauben",
@@ -822,6 +941,7 @@
"in_use": "Prozentualer Gebrauch",
"inactive": "Inaktiv",
"insert_preset": "Beispiel \"%s\" laden",
+ "internal": "Intern",
"kind": "Art",
"last_mail_login": "Letzter Mail-Login",
"last_modified": "Zuletzt geändert",
@@ -849,7 +969,7 @@
"private_comment": "Privater Kommentar",
"public_comment": "Öffentlicher Kommentar",
"q_add_header": "bei Mail in Junk-Ordner",
- "q_all": "bei Reject und Mail in Junk-Ordner",
+ "q_all": " bei Reject und Mail in Junk-Ordner",
"q_reject": "bei Reject",
"quarantine_category": "Quarantäne-Benachrichtigungskategorie",
"quarantine_notification": "Quarantäne-Benachrichtigung",
@@ -857,9 +977,9 @@
"recipient_map": "Empfängerumschreibung",
"recipient_map_info": "Empfängerumschreibung ersetzen den Empfänger einer E-Mail vor dem Versand.",
"recipient_map_new": "Neuer Empfänger",
- "recipient_map_new_info": "Der neue Empfänger muss eine E-Mail-Adresse sein.",
+ "recipient_map_new_info": "Der neue Empfänger muss eine E-Mail-Adresse oder ein Domainname sein.",
"recipient_map_old": "Original-Empfänger",
- "recipient_map_old_info": "Der originale Empfänger muss eine E-Mail-Adresse oder ein Domainname sein.",
+ "recipient_map_old_info": "Der originäre Empfänger muss eine E-Mail-Adresse oder ein Domainname sein.",
"recipient_maps": "Empfängerumschreibungen",
"relay_all": "Alle Empfänger-Adressen relayen",
"relay_unknown": "Unbekannte Mailboxen relayen",
@@ -881,7 +1001,7 @@
"sogo_visible": "Alias Sichtbarkeit in SOGo",
"sogo_visible_n": "Alias in SOGo verbergen",
"sogo_visible_y": "Alias in SOGo anzeigen",
- "spam_aliases": "Temp. Alias",
+ "spam_aliases": "Spam-Alias",
"stats": "Statistik",
"status": "Status",
"sync_jobs": "Synchronisationen",
@@ -922,7 +1042,9 @@
"syncjob_EXIT_TLS_FAILURE": "Problem mit verschlüsselter Verbindung",
"syncjob_EXIT_AUTHENTICATION_FAILURE": "Authentifizierungsproblem",
"syncjob_EXIT_OVERQUOTA": "Ziel Mailbox ist über dem Limit",
- "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Kann keine Verbindung zum Zielserver herstellen"
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Kann keine Verbindung zum Zielserver herstellen",
+ "iam": "Identitätsanbieter",
+ "force_tfa": "2-Faktor-Authentifizierung"
},
"oauth2": {
"access_denied": "Bitte als Mailbox-Nutzer einloggen, um den Zugriff via OAuth2 zu erlauben.",
@@ -954,7 +1076,7 @@
"notified": "Benachrichtigt",
"qhandler_success": "Aktion wurde an das System übergeben. Sie dürfen dieses Fenster nun schließen.",
"qid": "Rspamd QID",
- "qinfo": "Das Quarantänesystem speichert abgelehnte Nachrichten in der Datenbank (dem Sender wird <em>nicht</em> signalisiert, dass seine E-Mail zugestellt wurde) als auch diese, die als Kopie in den Junk-Ordner der jeweiligen Mailbox zugestellt wurden.\r\n <br>\"Als Spam lernen und löschen\" lernt Nachrichten nach bayesscher Statistik als Spam und erstellt Fuzzy Hashes ausgehend von der jeweiligen Nachricht, um ähnliche Inhalte zukünftig zu unterbinden.\r\n <br>Der Prozess des Lernens kann abhängig vom System zeitintensiv sein.<br>Auf Blacklists vorkommende Elemente sind von der Quarantäne ausgeschlossen.",
+ "qinfo": "Das Quarantänesystem speichert abgelehnte Nachrichten in der Datenbank (dem Sender wird <em>nicht</em> signalisiert, dass seine E-Mail zugestellt wurde) als auch diese, die als Kopie in den Junk-Ordner der jeweiligen Mailbox zugestellt wurden.\r\n <br>\"Als Spam lernen und löschen\" lernt Nachrichten nach bayesscher Statistik als Spam und erstellt Fuzzy Hashes ausgehend von der jeweiligen Nachricht, um ähnliche Inhalte zukünftig zu unterbinden.\r\n <br>Der Prozess des Lernens kann abhängig vom System zeitintensiv sein.<br>Auf Denylisten vorkommende Elemente sind von der Quarantäne ausgeschlossen.",
"qitem": "Quarantäneeintrag",
"quarantine": "Quarantäne",
"quick_actions": "Aktionen",
@@ -974,7 +1096,7 @@
"rspamd_result": "Rspamd-Ergebnis",
"sender": "Sender (SMTP)",
"sender_header": "Sender (\"From\"-Header)",
- "settings_info": "Maximale Anzahl der zurückgehaltenen E-Mails: %s<br>Maximale Größe einer zu speichernden E-Mail: %s MiB",
+ "settings_info": "Maximale Anzahl der zurückgehaltenen E-Mails (pro Mailbox): %s<br>Maximale Größe einer zu speichernden E-Mail: %s MiB",
"show_item": "Details",
"spam": "Spam",
"spam_score": "Bewertung",
@@ -993,7 +1115,7 @@
"legend": "Funktionen der Mailqueue Aktionen:",
"ays": "Soll die derzeitige Queue wirklich komplett bereinigt werden?",
"deliver_mail": "Ausliefern",
- "deliver_mail_legend": "Versucht eine erneute Zustellung der ausgwählten Mails.",
+ "deliver_mail_legend": "Versucht eine erneute Zustellung der ausgewählten Mails.",
"hold_mail": "Zurückhalten",
"hold_mail_legend": "Hält die ausgewählten Mails zurück. (Verhindert weitere Zustellversuche)",
"queue_manager": "Queue Manager",
@@ -1004,9 +1126,7 @@
},
"start": {
"help": "Hilfe ein-/ausblenden",
- "imap_smtp_server_auth_info": "Bitte verwenden Sie Ihre vollständige E-Mail-Adresse sowie das PLAIN-Authentifizierungsverfahren.<br>\r\nIhre Anmeldedaten werden durch die obligatorische Verschlüsselung entgegen des Begriffes \"PLAIN\" nicht unverschlüsselt übertragen.",
- "mailcow_apps_detail": "Verwenden Sie mailcow-Apps, um E-Mails abzurufen, Kalender und Kontakte zu verwalten und vieles mehr.",
- "mailcow_panel_detail": "<b>Domain-Administratoren</b> erstellen, verändern oder löschen Mailboxen, verwalten die Domäne und sehen sonstige Einstellungen ein.<br>\r\n\tAls <b>Mailbox-Benutzer</b> erstellen Sie hier zeitlich limitierte Aliasse, ändern das Verhalten des Spamfilters, setzen ein neues Passwort und vieles mehr."
+ "imap_smtp_server_auth_info": "Bitte verwenden Sie Ihre vollständige E-Mail-Adresse sowie das PLAIN-Authentifizierungsverfahren.<br>\r\nIhre Anmeldedaten werden durch die obligatorische Verschlüsselung entgegen des Begriffes \"PLAIN\" nicht unverschlüsselt übertragen."
},
"success": {
"acl_saved": "ACL für Objekt %s wurde gesetzt",
@@ -1027,6 +1147,7 @@
"bcc_edited": "BCC-Map-Eintrag %s wurde geändert",
"bcc_saved": "BCC- Map-Eintrag wurde gespeichert",
"cors_headers_edited": "CORS Einstellungen wurden erfolgreich gespeichert",
+ "custom_login_modified": "Login Anpassung wurde erfolgreich gespeichert",
"db_init_complete": "Datenbankinitialisierung abgeschlossen",
"delete_filter": "Filter-ID %s wurde gelöscht",
"delete_filters": "Filter gelöscht: %s",
@@ -1051,6 +1172,7 @@
"forwarding_host_removed": "Weiterleitungs-Host %s wurde entfernt",
"global_filter_written": "Filterdatei wurde erfolgreich geschrieben",
"hash_deleted": "Hash wurde gelöscht",
+ "iam_test_connection": "Verbindung erfolgreich",
"ip_check_opt_in_modified": "IP Check wurde erfolgreich gespeichert",
"item_deleted": "Objekt %s wurde entfernt",
"item_released": "Objekt %s freigegeben",
@@ -1062,14 +1184,17 @@
"mailbox_added": "Mailbox %s wurde angelegt",
"mailbox_modified": "Änderungen an Mailbox %s wurden gespeichert",
"mailbox_removed": "Mailbox %s wurde entfernt",
+ "mailbox_renamed": "Mailbox wurde von %s in %s umbenannt",
"nginx_reloaded": "Nginx wurde neu geladen",
"object_modified": "Änderungen an Objekt %s wurden gespeichert",
"password_policy_saved": "Passwortrichtlinie wurde erfolgreich gespeichert",
+ "password_changed_success": "Das Passwort wurde erfolgreich geändert",
"pushover_settings_edited": "Pushover-Konfiguration gespeichert, bitte den Zugang im Anschluss verifizieren.",
"qlearn_spam": "Nachricht-ID %s wurde als Spam gelernt und gelöscht",
"queue_command_success": "Queue-Aufgabe erfolgreich ausgeführt",
"recipient_map_entry_deleted": "Empfängerumschreibung mit der ID %s wurde gelöscht",
"recipient_map_entry_saved": "Empfängerumschreibung für Objekt \"%s\" wurde gespeichert",
+ "recovery_email_sent": "Wiederherstellungs-E-Mail an %s gesendet",
"relayhost_added": "Map-Eintrag %s wurde hinzugefügt",
"relayhost_removed": "Map-Eintrag %s wurde entfernt",
"reset_main_logo": "Standardgrafik wurde wiederhergestellt",
@@ -1088,6 +1213,7 @@
"tls_policy_map_entry_deleted": "TLS-Richtlinie mit der ID %s wurde gelöscht",
"tls_policy_map_entry_saved": "TLS-Richtlinieneintrag \"%s\" wurde gespeichert",
"ui_texts": "Änderungen an UI-Texten",
+ "ui_theme_modified": "Theme wurde erfolgreich gespeichert",
"upload_success": "Datei wurde erfolgreich hochgeladen",
"verified_fido2_login": "FIDO2-Anmeldung verifiziert",
"verified_totp_login": "TOTP-Anmeldung verifiziert",
@@ -1113,14 +1239,19 @@
"set_tfa": "Konfiguriere Zwei-Faktor-Authentifizierungsmethode",
"start_webauthn_validation": "Starte Validierung",
"tfa": "Zwei-Faktor-Authentifizierung",
- "tfa_token_invalid": "TFA-Token ungültig!",
+ "tfa_token_invalid": "2FA-Token ungültig",
"totp": "Time-based-OTP (Google Authenticator etc.)",
"u2f_deprecated": "Es sieht so aus als wurde der Schlüssel mit der alten U2F Methode registriert. Wir werden die Zwei-Faktor-Authentifizierung deaktivieren und deinen Schlüssel löschen.",
"u2f_deprecated_important": "Bitte registriere den Schlüssel im Adminbereich mit der neuen WebAuthn Methode.",
"webauthn": "WebAuthn-Authentifizierung",
"waiting_usb_auth": "<i>Warte auf USB-Gerät...</i><br><br>Bitte jetzt den vorgesehenen Taster des USB-Gerätes berühren.",
"waiting_usb_register": "<i>Warte auf USB-Gerät...</i><br><br>Bitte zuerst das obere Passwortfeld ausfüllen und erst dann den vorgesehenen Taster des USB-Gerätes berühren.",
- "yubi_otp": "Yubico OTP-Authentifizierung"
+ "yubi_otp": "Yubico OTP-Authentifizierung",
+ "force_tfa": "Zwei-Faktor-Authentifizierung beim Login erzwingen",
+ "force_tfa_info": "Der Benutzer muss Zwei-Faktor-Authentifizierung einrichten, bevor er auf den Bereich zugreifen kann.",
+ "setup_title": "Zwei-Faktor-Authentifizierung erforderlich",
+ "setup_required": "Ihr Konto erfordert Zwei-Faktor-Authentifizierung. Bitte richten Sie eine 2FA-Methode ein, um fortzufahren.",
+ "cancel_setup": "Abbrechen und abmelden"
},
"user": {
"action": "Aktion",
@@ -1146,6 +1277,7 @@
"apple_connection_profile_mailonly": "Dieses Verbindungsprofil beinhaltet IMAP- und SMTP-Konfigurationen für ein Apple-Gerät.",
"apple_connection_profile_with_app_password": "Es wird ein neues App-Passwort erzeugt und in das Profil eingefügt, damit bei der Einrichtung kein Passwort eingegeben werden muss. Geben Sie das Profil nicht weiter, da es einen vollständigen Zugriff auf Ihr Postfach ermöglicht.",
"attribute": "Attribut",
+ "authentication": "Authentifizierung",
"change_password": "Passwort ändern",
"change_password_hint_app_passwords": "Ihre Mailbox hat %d App-Passwörter, die nicht geändert werden. Um diese zu verwalten, gehen Sie bitte zum App-Passwörter-Tab.",
"clear_recent_successful_connections": "Alle erfolgreichen Verbindungen bereinigen",
@@ -1155,10 +1287,11 @@
"created_on": "Erstellt am",
"daily": "Täglich",
"day": "Tag",
+ "description": "Beschreibung",
"delete_ays": "Soll der Löschvorgang wirklich ausgeführt werden?",
"direct_aliases": "Direkte Alias-Adressen",
"direct_aliases_desc": "Nur direkte Alias-Adressen werden für benutzerdefinierte Einstellungen berücksichtigt.",
- "direct_protocol_access": "Der Hauptbenutzer hat <b>direkten, externen Zugriff</b> auf folgende Protokolle und Anwendungen. Diese Einstellung wird vom Administrator gesteuert. App-Passwörter können verwendet werden, um individuelle Zugänge für Protokolle und Anwendungen zu erstellen.<br>Der Button \"In Webmail einloggen\" kann unabhängig der Einstellung immer verwendet werden.",
+ "direct_protocol_access": "Der Hauptbenutzer hat <b>direkten, externen Zugriff</b> auf folgende Protokolle und Anwendungen. Diese Einstellung wird vom Administrator gesteuert. App-Passwörter können verwendet werden, um individuelle Zugänge für Protokolle und Anwendungen zu erstellen.<br>Der Button Webmail kann unabhängig der Einstellung immer verwendet werden.",
"eas_reset": "ActiveSync-Geräte-Cache zurücksetzen",
"eas_reset_help": "In vielen Fällen kann ein ActiveSync-Profil durch das Zurücksetzen des Caches repariert werden.<br><b>Vorsicht:</b> Alle Elemente werden erneut heruntergeladen!",
"eas_reset_now": "Jetzt zurücksetzen",
@@ -1169,7 +1302,9 @@
"encryption": "Verschlüsselung",
"excludes": "Ausschlüsse",
"expire_in": "Ungültig in",
+ "expire_never": "Niemals ungültig",
"fido2_webauthn": "FIDO2/WebAuthn",
+ "forever": "Für immer",
"force_pw_update": "Das Passwort für diesen Benutzer <b>muss</b> geändert werden, damit die Zugriffssperre auf die Groupware-Komponenten wieder freigeschaltet wird.",
"from": "von",
"generate": "generieren",
@@ -1195,13 +1330,17 @@
"never": "Niemals",
"new_password": "Neues Passwort",
"new_password_repeat": "Neues Passwort (Wiederholung)",
+ "pw_update_required": "Ihr Konto erfordert eine Passwortänderung. Bitte setzen Sie ein neues Passwort, um fortzufahren.",
"no_active_filter": "Kein aktiver Filter vorhanden",
"no_last_login": "Keine letzte UI-Anmeldung gespeichert",
"no_record": "Kein Eintrag",
- "open_webmail_sso": "In Webmail einloggen",
+ "open_webmail_sso": "Webmail",
+ "overview": "Übersicht",
"password": "Passwort",
"password_now": "Aktuelles Passwort (Änderungen bestätigen)",
"password_repeat": "Passwort (Wiederholung)",
+ "password_reset_info": "Wenn keine E-Mail zur Passwortwiederherstellung hinterlegt ist, kann diese Funktion nicht genutzt werden.",
+ "protocols": "Protokolle",
"pushover_evaluate_x_prio": "Hohe Priorität eskalieren [<code>X-Priority: 1</code>]",
"pushover_info": "Push-Benachrichtungen werden angewendet auf alle nicht-Spam Nachrichten zugestellt an <b>%s</b>, einschließlich Alias-Adressen (shared, non-shared, tagged).",
"pushover_only_x_prio": "Nur Mail mit hoher Priorität berücksichtigen [<code>X-Priority: 1</code>]",
@@ -1211,6 +1350,7 @@
"pushover_title": "Notification Titel",
"pushover_vars": "Wenn kein Sender-Filter definiert ist, werden alle E-Mails berücksichtigt.<br>Die direkte Absenderprüfung und reguläre Ausdrücke werden unabhängig voneinander geprüft, sie <b>hängen nicht voneinander ab</b> und werden der Reihe nach ausgeführt. <br>Verwendbare Variablen für Titel und Text (Datenschutzrichtlinien beachten)",
"pushover_verify": "Verbindung verifizieren",
+ "pw_recovery_email": "E-Mail zur Passwortwiederherstellung",
"q_add_header": "Junk-Ordner",
"q_all": "Alle Kategorien",
"q_reject": "Abgelehnt",
@@ -1228,14 +1368,15 @@
"shared_aliases_desc": "Geteilte Alias-Adressen werden nicht bei benutzerdefinierten Einstellungen, wie die des Spam-Filters oder der Verschlüsselungsrichtlinie, berücksichtigt. Entsprechende Spam-Filter können lediglich von einem Administrator vorgenommen werden.",
"show_sieve_filters": "Zeige aktiven Filter des Benutzers",
"sogo_profile_reset": "SOGo-Profil zurücksetzen",
- "sogo_profile_reset_help": "Das Profil wird inklusive <b>aller</b> Kalender- und Kontaktdaten <b>unwiederbringlich gelöscht</b>.",
+ "sogo_profile_reset_help": "Das Profil wird inklusive <b>aller Kalender- und Kontaktdaten unwiederbringlich gelöscht</b>.",
"sogo_profile_reset_now": "Profil jetzt zurücksetzen",
- "spam_aliases": "Temporäre E-Mail-Aliasse",
+ "spam_aliases": "Spam E-Mail-Aliasse",
+ "spam_aliases_info": "Ein Spam-Alias ist eine temporäre E-Mailadresse, die benutzt werden kann, um eine echte E-Mail Adressen zu schützen. <br>Optional kann eine Ablaufzeit gesetzt werden, sodass der Alias nach dem definierten Zeitraum automatisch deaktiviert wird, was missbrauchte oder geleakte Adressen effektiv entsorgt.",
"spam_score_reset": "Auf Server-Standard zurücksetzen",
"spamfilter": "Spamfilter",
"spamfilter_behavior": "Bewertung",
- "spamfilter_bl": "Blacklist",
- "spamfilter_bl_desc": "Für E-Mail-Adressen, die vom Spamfilter <b>immer</b> als Spam erfasst und abgelehnt werden. Die Quarantäne-Funktion ist für diese Nachrichten deaktiviert. Die Verwendung von Wildcards ist gestattet. Ein Filter funktioniert lediglich für direkte nicht-\"Catch All\" Alias-Adressen (Alias-Adressen mit lediglich einer Mailbox als Ziel-Adresse) sowie die Mailbox-Adresse selbst.",
+ "spamfilter_bl": "Denyliste",
+ "spamfilter_bl_desc": "Für E-Mail-Adressen, die vom Spamfilter <b>immer</b> als Spam erfasst und abgelehnt werden. Die Quarantäne-Funktion ist für diese Nachrichten <b>deaktiviert</b>. Die Verwendung von Wildcards ist gestattet. Ein Filter funktioniert lediglich für direkte Nicht-„Catch-All“-Alias-Adressen (Alias-Adressen mit lediglich einer Mailbox als Ziel-Adresse) sowie die Mailbox-Adresse selbst.",
"spamfilter_default_score": "Standardwert",
"spamfilter_green": "Grün: Die Nachricht ist kein Spam",
"spamfilter_hint": "Der erste Wert beschreibt den \"low spam score\", der zweite Wert den \"high spam score\".",
@@ -1246,8 +1387,8 @@
"spamfilter_table_empty": "Keine Einträge vorhanden",
"spamfilter_table_remove": "Entfernen",
"spamfilter_table_rule": "Regel",
- "spamfilter_wl": "Whitelist",
- "spamfilter_wl_desc": "Für E-Mail-Adressen, die vom Spamfilter <b>nicht</b> erfasst werden sollen. Die Verwendung von Wildcards ist gestattet. Ein Filter funktioniert lediglich für direkte nicht-\"Catch All\" Alias-Adressen (Alias-Adressen mit lediglich einer Mailbox als Ziel-Adresse) sowie die Mailbox-Adresse selbst.",
+ "spamfilter_wl": "Allowliste",
+ "spamfilter_wl_desc": "Für E-Mail-Adressen, die vom Spamfilter <b>nicht</b> erfasst werden sollen. Die Verwendung von Wildcards ist gestattet. Ein Filter funktioniert lediglich für direkte Nicht-„Catch-All“-Alias-Adressen (Alias-Adressen mit lediglich einer Mailbox als Ziel-Adresse) sowie die Mailbox-Adresse selbst.",
"spamfilter_yellow": "Gelb: Die Nachricht ist vielleicht Spam, wird als Spam markiert und in den Junk-Ordner verschoben",
"status": "Status",
"sync_jobs": "Sync Jobs",
@@ -1258,6 +1399,7 @@
"tag_in_subfolder": "In Unterordner",
"tag_in_subject": "In Betreff",
"text": "Text",
+ "tfa_info": "Zwei-Faktor-Authentifizierung hilft dabei, Ihr Konto zu schützen. Wenn Sie sie aktivieren, benötigen Sie App-Passwörter, um sich bei Apps oder Diensten anzumelden, die die Zwei-Faktor-Authentifizierung nicht unterstützen (z.B. Mailclients).",
"title": "Title",
"tls_enforce_in": "TLS eingehend erzwingen",
"tls_enforce_out": "TLS ausgehend erzwingen",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.en-gb.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.en-gb.json
index 964caad..1f1c1f2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.en-gb.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.en-gb.json
@@ -1,6 +1,7 @@
{
"acl": {
"alias_domains": "Add alias domains",
+ "alias_external_goto": "Allow aliases with external goto domains",
"app_passwds": "Manage app passwords",
"bcc_maps": "BCC maps",
"delimiter_action": "Delimiter action",
@@ -14,6 +15,7 @@
"prohibited": "Prohibited by ACL",
"protocol_access": "Change protocol access",
"pushover": "Pushover",
+ "pw_reset": "Allow to reset mailcow user password",
"quarantine": "Quarantine actions",
"quarantine_attachments": "Quarantine attachments",
"quarantine_category": "Change quarantine notification category",
@@ -24,7 +26,7 @@
"sogo_access": "Allow management of SOGo access",
"sogo_profile_reset": "Reset SOGo profile",
"spam_alias": "Temporary aliases",
- "spam_policy": "Blacklist/Whitelist",
+ "spam_policy": "Denylist/Allowlist",
"spam_score": "Spam score",
"syncjobs": "Sync jobs",
"tls_policy": "TLS policy",
@@ -70,6 +72,9 @@
"goto_spam": "Learn as <span class=\"text-danger\"><b>spam</b></span>",
"hostname": "Host",
"inactive": "Inactive",
+ "internal": "Internal",
+ "internal_info": "Internal aliases are only accessible from the own domain or alias domains.",
+ "sender_allowed": "Allow to send as this alias",
"kind": "Kind",
"mailbox_quota_def": "Default mailbox quota",
"mailbox_quota_m": "Max. quota per mailbox (MiB)",
@@ -133,6 +138,7 @@
"admin_domains": "Domain assignments",
"admins": "Administrators",
"admins_ldap": "LDAP Administrators",
+ "admin_quicklink": "Hide Quicklink to Admin Login Page",
"advanced_settings": "Advanced settings",
"allowed_methods": "Access-Control-Allow-Methods",
"allowed_origins": "Access-Control-Allow-Origin",
@@ -142,13 +148,14 @@
"api_read_only": "Read-Only Access",
"api_read_write": "Read-Write Access",
"api_skip_ip_check": "Skip IP check for API",
+ "app_hide": "Hide for login",
"app_links": "App links",
"app_name": "App name",
"apps_name": "\"mailcow Apps\" name",
"arrival_time": "Arrival time (server time)",
"authed_user": "Auth. user",
"ays": "Are you sure you want to proceed?",
- "ban_list_info": "See a list of banned IPs below: <b>network (remaining ban time) - [actions]</b>.<br />IPs queued to be unbanned will be removed from the active ban list within a few seconds.<br />Red labels indicate active permanent bans by blacklisting.",
+ "ban_list_info": "See a list of banned IPs below: <b>network (remaining ban time) - [actions]</b>.<br />IPs queued to be unbanned will be removed from the active ban list within a few seconds.<br />Red labels indicate active permanent bans by denylisting.",
"change_logo": "Change logo",
"logo_normal_label": "Normal",
"logo_dark_label": "Inverted for dark mode",
@@ -159,6 +166,7 @@
"credentials_transport_warning": "<b>Warning</b>: Adding a new transport map entry will update the credentials for all entries with a matching next hop column.",
"customer_id": "Customer ID",
"customize": "Customize",
+ "login_page": "Login Page",
"destination": "Destination",
"dkim_add_key": "Add ARC/DKIM key",
"dkim_domains_selector": "Selector",
@@ -177,6 +185,7 @@
"domain": "Domain",
"domain_admin": "Domain administrator",
"domain_admins": "Domain administrators",
+ "domainadmin_quicklink": "Hide Quicklink to Domainadmin Login Page",
"domain_s": "Domain/s",
"duplicate": "Duplicate",
"duplicate_dkim": "Duplicate DKIM record",
@@ -185,9 +194,9 @@
"excludes": "Excludes these recipients",
"f2b_ban_time": "Ban time (s)",
"f2b_ban_time_increment": "Ban time is incremented with each ban",
- "f2b_blacklist": "Blacklisted networks/hosts",
+ "f2b_blacklist": "Denylisted networks/hosts",
"f2b_filter": "Regex filters",
- "f2b_list_info": "A blacklisted host or network will always outweigh a whitelist entity. <b>List updates will take a few seconds to be applied.</b>",
+ "f2b_list_info": "A denylisted host or network will always outweigh a allowlist entity. <b>List updates will take a few seconds to be applied.</b>",
"f2b_manage_external": "Manage Fail2Ban externally",
"f2b_manage_external_info": "Fail2ban will still maintain the banlist, but it will not actively set rules to block traffic. Use the generated banlist below to externally block the traffic.",
"f2b_max_attempts": "Max. attempts",
@@ -197,8 +206,11 @@
"f2b_parameters": "Fail2ban parameters",
"f2b_regex_info": "Logs taken into consideration: SOGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Retry window (s) for max. attempts",
- "f2b_whitelist": "Whitelisted networks/hosts",
+ "f2b_whitelist": "Allowlisted networks/hosts",
+ "filter": "Filter",
"filter_table": "Filter table",
+ "force_sso_text": "If an external OIDC provider is configured, this option hides the default mailcow login forms and only shows the Single Sign-On button",
+ "force_sso": "Disable mailcow Login and show only Single Sign-On",
"forwarding_hosts": "Forwarding Hosts",
"forwarding_hosts_add_hint": "You can either specify IPv4/IPv6 addresses, networks in CIDR notation, host names (which will be resolved to IP addresses), or domain names (which will be resolved to IP addresses by querying SPF records or, in their absence, MX records).",
"forwarding_hosts_hint": "Incoming messages are unconditionally accepted from any hosts listed here. These hosts are then not checked against DNSBLs or subjected to greylisting. Spam received from them is never rejected, but optionally it can be filed into the Junk folder. The most common use for this is to specify mail servers on which you have set up a rule that forwards incoming emails to your mailcow server.",
@@ -210,6 +222,44 @@
"help_text": "Override help text below login mask (HTML allowed)",
"host": "Host",
"html": "HTML",
+ "iam": "Identity Provider",
+ "iam_attribute_field": "Attribute Field",
+ "iam_authorize_url": "Authorization endpoint",
+ "iam_auth_flow": "Authentication Flow",
+ "iam_auth_flow_info": "In addition to the Authorization Code Flow (Standard Flow in Keycloak), which is used for Single-Sign On login, mailcow also supports Authentication Flow with direct Credentials. The Mailpassword Flow attempts to validate the user's credentials by using the Keycloak Admin REST API. mailcow retrieves the hashed password from the <code>mailcow_password</code> attribute, which is mapped in Keycloak.",
+ "iam_basedn": "Base DN",
+ "iam_client_id": "Client ID",
+ "iam_client_secret": "Client Secret",
+ "iam_client_scopes": "Client Scopes",
+ "iam_default_template": "Default Template",
+ "iam_default_template_description": "If no template is assigned to a user, the default template will be used for creating the mailbox, but not for updating the mailbox.",
+ "iam_description": "Configure an external Provider for Authentication<br>User's mailboxes will be automatically created upon their first login, provided that an attribute mapping has been set.",
+ "iam_extra_permission": "For the following settings to work, the mailcow client in Keycloak needs a <code>Service account</code> and the permission to <code>view-users</code>.",
+ "iam_host": "Host",
+ "iam_host_info": "Enter one or more LDAP hosts, separated by commas.",
+ "iam_import_users": "Import Users",
+ "iam_login_provisioning": "Auto-create users on login",
+ "iam_mapping": "Attribute Mapping",
+ "iam_bindpass": "Bind Password",
+ "iam_periodic_full_sync": "Periodic Full Sync",
+ "iam_port": "Port",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "Redirect Url",
+ "iam_rest_flow": "Mailpassword Flow",
+ "iam_server_url": "Server Url",
+ "iam_sso": "Single Sign-On",
+ "iam_sync_interval": "Sync / Import interval (min)",
+ "iam_test_connection": "Test Connection",
+ "iam_token_url": "Token endpoint",
+ "iam_userinfo_url": "User info endpoint",
+ "iam_username_field": "Username Field",
+ "iam_binddn": "Bind DN",
+ "iam_use_ssl": "Use SSL",
+ "iam_use_ssl_info": "If enabling SSL, and port is set to 389, it will be automatically overridden to use 636.",
+ "iam_use_tls": "Use StartTLS",
+ "iam_use_tls_info": "If enabling TLS, you must use the default port for your LDAP server (389). SSL ports cannot be used.",
+ "iam_version": "Version",
+ "ignore_ssl_error": "Ignore SSL Errors",
"import": "Import",
"import_private_key": "Import private key",
"in_use_by": "In use by",
@@ -233,6 +283,7 @@
"message": "Message",
"message_size": "Message size",
"nexthop": "Next hop",
+ "needs_restart": "needs restart",
"no": "✕",
"no_active_bans": "No active bans",
"no_new_rows": "No further rows available",
@@ -256,6 +307,11 @@
"password_policy_numbers": "Must contain at least one number",
"password_policy_special_chars": "Must contain special characters",
"password_repeat": "Confirmation password (repeat)",
+ "password_reset_info": "If no recovery email is provided, this function cannot be used.",
+ "password_reset_settings": "Password Recovery Settings",
+ "password_reset_tmpl_html": "HTML Template",
+ "password_reset_tmpl_text": "Text Template",
+ "password_settings": "Password Settings",
"priority": "Priority",
"private_key": "Private key",
"quarantine": "Quarantine",
@@ -272,6 +328,7 @@
"quarantine_release_format_att": "As attachment",
"quarantine_release_format_raw": "Unmodified original",
"quarantine_retention_size": "Retentions per mailbox:<br><small>0 indicates <b>inactive</b>.</small>",
+ "quicklink_text": "Show or hide quick links to other login pages under the login form",
"quota_notification_html": "Notification email template:<br><small>Leave empty to restore default template.</small>",
"quota_notification_sender": "Notification email sender",
"quota_notification_subject": "Notification email subject",
@@ -296,6 +353,8 @@
"remove_row": "Remove row",
"reset_default": "Reset to default",
"reset_limit": "Remove hash",
+ "reset_password_vars": "<code>{{link}}</code> The generated password reset link<br><code>{{username}}</code> The mailbox name of the user who requested the password reset<br><code>{{username2}}</code> The recovery mailbox name<br><code>{{date}}</code> The date the password reset request was made<br><code>{{token_lifetime}}</code> The token lifetime in minutes<br><code>{{hostname}}</code> The mailcow hostname",
+ "restore_template": "Leave empty to restore default template.",
"routing": "Routing",
"rsetting_add_rule": "Add rule",
"rsetting_content": "Rule content",
@@ -310,8 +369,8 @@
"rspamd_com_settings": "A setting name will be auto-generated, please see the example presets below. For more details see <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd docs</a>",
"rspamd_global_filters": "Global filter maps",
"rspamd_global_filters_agree": "I will be careful!",
- "rspamd_global_filters_info": "Global filter maps contain different kind of global black and whitelists.",
- "rspamd_global_filters_regex": "Their names explain their purpose. All content must contain valid regular expression in the format of \"/pattern/options\" (e.g. <code>/.+@domain\\.tld/i</code>).<br>\r\n Although rudimentary checks are being executed on each line of regex, Rspamds functionality can be broken, if it fails to read the syntax correctly.<br>\r\n Rspamd will try to read the map content when changed. If you experience problems, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">restart Rspamd</a> to enforce a map reload.<br>Blacklisted elements are excluded from quarantine.",
+ "rspamd_global_filters_info": "Global filter maps contain different kind of global deny and allowlists.",
+ "rspamd_global_filters_regex": "Their names explain their purpose. All content must contain valid regular expression in the format of \"/pattern/options\" (e.g. <code>/.+@domain\\.tld/i</code>).<br>\r\n Although rudimentary checks are being executed on each line of regex, Rspamds functionality can be broken, if it fails to read the syntax correctly.<br>\r\n Rspamd will try to read the map content when changed. If you experience problems, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">restart Rspamd</a> to enforce a map reload.<br>Denylisted elements are excluded from quarantine.",
"rspamd_settings_map": "Rspamd settings map",
"sal_level": "Moo level",
"save": "Save changes",
@@ -325,6 +384,7 @@
"subject": "Subject",
"success": "Success",
"sys_mails": "System mails",
+ "task": "Task",
"text": "Text",
"time": "Time",
"title": "Title",
@@ -345,16 +405,24 @@
"ui_header_announcement_type_info": "Info",
"ui_header_announcement_type_warning": "Important",
"ui_texts": "UI labels and texts",
+ "ui_theme": "Theme",
+ "ui_theme_dark": "Includes a dark mode variant",
+ "ui_theme_default": "Default",
+ "ui_theme_info": "Themes are folders in <code>data/web/css/themes/<name>/</code> with the following files:<ul class=\"mb-0\"><li><code>theme.css</code> (required)</li><li><code>dark.css</code> (optional, dark mode)</li><li><code>bootstrap.css</code> (optional, replaces the Bootstrap base theme)</li><li><code>theme.json</code> (optional, <code>name</code> and <code>description</code>)</li></ul>",
+ "ui_theme_none": "No themes found.",
"unban_pending": "unban pending",
"unchanged_if_empty": "If unchanged leave blank",
"upload": "Upload",
"username": "Username",
+ "user_link": "User-Link",
+ "user_quicklink": "Hide Quicklink to User Login Page",
"validate_license_now": "Validate GUID against license server",
"verify": "Verify",
"yes": "✓"
},
"danger": {
"access_denied": "Access denied or invalid form data",
+ "tfa_removal_blocked": "Two-factor authentication cannot be removed because it is required for your account.",
"alias_domain_invalid": "Alias domain %s is invalid",
"alias_empty": "Alias address must not be empty",
"alias_goto_identical": "Alias and goto address must not be identical",
@@ -363,6 +431,7 @@
"aliases_in_use": "Max. aliases must be greater or equal to %d",
"app_name_empty": "App name cannot be empty",
"app_passwd_id_invalid": "App password ID %s invalid",
+ "authsource_in_use": "The identity provider cannot be changed or deleted as it is currently in use by one or more users.",
"bcc_empty": "BCC destination cannot be empty",
"bcc_exists": "A BCC map %s exists for type %s",
"bcc_must_be_email": "BCC destination %s is not a valid email address",
@@ -381,18 +450,21 @@
"domain_not_found": "Domain %s not found",
"domain_quota_m_in_use": "Domain quota must be greater or equal to %s MiB",
"extended_sender_acl_denied": "missing ACL to set external sender addresses",
+ "external_goto_denied": "External goto address %s is not allowed",
"extra_acl_invalid": "External sender address \"%s\" is invalid",
"extra_acl_invalid_domain": "External sender \"%s\" uses an invalid domain",
"fido2_verification_failed": "FIDO2 verification failed: %s",
"file_open_error": "File cannot be opened for writing",
"filter_type": "Wrong filter type",
"from_invalid": "Sender must not be empty",
+ "generic_server_error": "An unexpected server error occurred. Please contact your administrator.",
"global_filter_write_error": "Could not write filter file: %s",
"global_map_invalid": "Global map ID %s invalid",
"global_map_write_error": "Could not write global map ID %s: %s",
"goto_empty": "An alias address must contain at least one valid goto address",
"goto_invalid": "Goto address %s is invalid",
"ham_learn_error": "Ham learn error: %s",
+ "iam_test_connection": "Connection failed",
"imagick_exception": "Error: Imagick exception while reading image",
"img_dimensions_exceeded": "Image exceeds the maximum image size",
"img_invalid": "Cannot validate image file",
@@ -407,6 +479,7 @@
"invalid_nexthop_authenticated": "Next hop exists with different credentials, please update the existing credentials for this next hop first.",
"invalid_recipient_map_new": "Invalid new recipient specified: %s",
"invalid_recipient_map_old": "Invalid original recipient specified: %s",
+ "invalid_reset_token": "Invalid reset token",
"ip_list_empty": "List of allowed IPs cannot be empty",
"is_alias": "%s is already known as an alias address",
"is_alias_or_mailbox": "%s is already known as an alias, a mailbox or an alias address expanded from an alias domain.",
@@ -421,10 +494,13 @@
"mailboxes_in_use": "Max. mailboxes must be greater or equal to %d",
"malformed_username": "Malformed username",
"map_content_empty": "Map content cannot be empty",
+ "max_age_invalid": "Max age %s is invalid",
"max_alias_exceeded": "Max. aliases exceeded",
"max_mailbox_exceeded": "Max. mailboxes exceeded (%d of %d)",
"max_quota_in_use": "Mailbox quota must be greater or equal to %d MiB",
"maxquota_empty": "Max. quota per mailbox must not be 0.",
+ "mode_invalid": "Mode %s is invalid",
+ "mx_invalid": "MX record %s is invalid",
"mysql_error": "MySQL error: %s",
"network_host_invalid": "Invalid network or host: %s",
"next_hop_interferes": "%s interferes with nexthop %s",
@@ -436,18 +512,24 @@
"password_complexity": "Password does not meet the policy",
"password_empty": "Password must not be empty",
"password_mismatch": "Confirmation password does not match",
+ "password_reset_invalid_user": "Mailbox not found or no recovery email is set",
+ "password_reset_na": "The password recovery is currently unavailable. Please contact your administrator.",
"policy_list_from_exists": "A record with given name exists",
"policy_list_from_invalid": "Record has invalid format",
"private_key_error": "Private key error: %s",
"pushover_credentials_missing": "Pushover token and or key missing",
"pushover_key": "Pushover key has a wrong format",
"pushover_token": "Pushover token has a wrong format",
+ "quarantine_category_invalid": "Quarantine category must be one of: add_header, reject, all",
"quota_not_0_not_numeric": "Quota must be numeric and >= 0",
"recipient_map_entry_exists": "A Recipient map entry \"%s\" exists",
+ "recovery_email_failed": "Could not send a recovery email. Please contact your administrator.",
"redis_error": "Redis error: %s",
"relayhost_invalid": "Map entry %s is invalid",
"release_send_failed": "Message could not be released: %s",
+ "required_data_missing": "Required data %s is missing",
"reset_f2b_regex": "Regex filter could not be reset in time, please try again or wait a few more seconds and reload the website.",
+ "reset_token_limit_exceeded": "Reset token limit has been exceeded. Please try again later.",
"resource_invalid": "Resource name %s is invalid",
"rl_timeframe": "Rate limit time frame is incorrect",
"rspamd_ui_pw_length": "Rspamd UI password should be at least 6 chars long",
@@ -470,18 +552,21 @@
"tls_policy_map_dest_invalid": "Policy destination is invalid",
"tls_policy_map_entry_exists": "A TLS policy map entry \"%s\" exists",
"tls_policy_map_parameter_invalid": "Policy parameter is invalid",
+ "to_invalid": "Recipient must not be empty",
"totp_verification_failed": "TOTP verification failed",
"transport_dest_exists": "Transport destination \"%s\" exists",
"webauthn_verification_failed": "WebAuthn verification failed: %s",
"webauthn_authenticator_failed": "The selected authenticator was not found",
"webauthn_publickey_failed": "No public key was stored for the selected authenticator",
"webauthn_username_failed": "The selected authenticator belongs to another account",
+ "ui_theme_invalid": "Theme not found",
"unknown": "An unknown error occurred",
"unknown_tfa_method": "Unknown TFA method",
"unlimited_quota_acl": "Unlimited quota prohibited by ACL",
"username_invalid": "Username %s cannot be used",
"validity_missing": "Please assign a period of validity",
"value_missing": "Please provide all values",
+ "version_invalid": "Version %s is invalid",
"yotp_verification_failed": "Yubico OTP verification failed: %s"
},
"datatables": {
@@ -525,7 +610,6 @@
"external_logs": "External logs",
"history_all_servers": "History (all servers)",
"in_memory_logs": "In-memory logs",
- "jvm_memory_solr": "JVM memory usage",
"last_modified": "Last modified",
"log_info": "<p>mailcow <b>in-memory logs</b> are collected in Redis lists and trimmed to LOG_LINES (%d) every minute to reduce hammering.\r\n <br>In-memory logs are not meant to be persistent. All applications that log in-memory, also log to the Docker daemon and therefore to the default logging driver.\r\n <br>The in-memory log type should be used for debugging minor issues with containers.</p>\r\n <p><b>External logs</b> are collected via API of the given application.</p>\r\n <p><b>Static logs</b> are mostly activity logs, that are not logged to the Dockerd but still need to be persistent (except for API logs).</p>",
"login_time": "Time",
@@ -536,8 +620,6 @@
"service": "Service",
"show_ip": "Show public IP",
"size": "Size",
- "solr_dead": "Solr is starting, disabled or died.",
- "solr_status": "Solr status",
"started_at": "Started at",
"started_on": "Started on",
"static_logs": "Static logs",
@@ -570,7 +652,7 @@
"alias": "Edit alias",
"allow_from_smtp": "Only allow these IPs to use <b>SMTP</b>",
"allow_from_smtp_info": "Leave empty to allow all senders.<br>IPv4/IPv6 addresses and networks.",
- "allowed_protocols": "Allowed protocols",
+ "allowed_protocols": "Allowed protocols for direct user access (does not affect app password protocols)",
"app_name": "App name",
"app_passwd": "App password",
"app_passwd_protocols": "Allowed protocols for app password",
@@ -621,12 +703,21 @@
"grant_types": "Grant types",
"hostname": "Hostname",
"inactive": "Inactive",
+ "internal": "Internal",
+ "internal_info": "Internal aliases are only accessible from the own domain or alias domains.",
+ "sender_allowed": "Allow to send as this alias",
+ "sender_allowed_info": "If disabled, this alias can only receive mail. Use sender ACL to override and grant specific mailboxes permission to send.",
"kind": "Kind",
"last_modified": "Last modified",
"lookup_mx": "Destination is a regular expression to match against MX name (<code>.*\\.google\\.com</code> to route all mail targeted to a MX ending in google.com over this hop)",
"mailbox": "Edit mailbox",
"mailbox_quota_def": "Default mailbox quota",
"mailbox_relayhost_info": "Applied to the mailbox and direct aliases only, does override a domain relayhost.",
+ "mailbox_rename": "Rename mailbox",
+ "mailbox_rename_agree": "I have created a backup.",
+ "mailbox_rename_warning": "IMPORTANT! Create a backup before renaming the mailbox.",
+ "mailbox_rename_alias": "Create alias automatically",
+ "mailbox_rename_title": "New local mailbox name",
"max_aliases": "Max. aliases",
"max_mailboxes": "Max. possible mailboxes",
"max_quota": "Max. quota per mailbox (MiB)",
@@ -634,10 +725,23 @@
"maxbytespersecond": "Max. bytes per second <br><small>(0 = unlimited)</small>",
"mbox_rl_info": "This rate limit is applied on the SASL login name, it matches any \"from\" address used by the logged-in user. A mailbox rate limit overrides a domain-wide rate limit.",
"mins_interval": "Interval (min)",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> is a standard that enforces email delivery between mail servers to use TLS with valid certificates. <br>It is used when <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> is not possible due to missing or unsupported DNSSEC.<br><b>Note</b>: If the receiving domain supports DANE with DNSSEC, DANE is <b>always</b> preferred – MTA-STS only acts as a fallback.",
+ "mta_sts_version": "Version",
+ "mta_sts_version_info": "Defines the version of the MTA-STS standard – currently only <code>STSv1</code> is valid.",
+ "mta_sts_mode": "Mode",
+ "mta_sts_mode_info": "There are three modes to choose from:<ul><li><em>testing</em> – policy is only monitored, violations have no impact.</li><li><em>enforce</em> – policy is strictly enforced, connections without valid TLS are rejected.</li><li><em>none</em> – policy is published but not applied.</li></ul>",
+ "mta_sts_max_age": "Max age",
+ "mta_sts_max_age_info": "Time in seconds that receiving mail servers may cache this policy until refetching.",
+ "mta_sts_mx": "MX server",
+ "mta_sts_mx_info": "Allows sending only to explicitly listed mail server hostnames; the sending MTA checks if the DNS MX hostname matches the policy list, and only allows delivery with a valid TLS certificate (guards against MITM).",
+ "mta_sts_mx_notice": "Multiple MX servers can be specified (separated by commas).",
+ "mta_sts_active_info": "If unchecked, the MTA-STS policy will not be published and no certificate will be requested for the mta-sts subdomain via ACME.",
"multiple_bookings": "Multiple bookings",
"none_inherit": "None / Inherit",
"nexthop": "Next hop",
"password": "Password",
+ "password_recovery_email": "Password recovery email",
"password_repeat": "Confirmation password (repeat)",
"previous": "Previous page",
"private_comment": "Private comment",
@@ -674,13 +778,13 @@
"sieve_desc": "Short description",
"sieve_type": "Filter type",
"skipcrossduplicates": "Skip duplicate messages across folders (first come, first serve)",
- "sogo_access": "Grant direct login access to SOGo",
- "sogo_access_info": "Single-sign-on from within the mail UI remains working. This setting does neither affect access to all other services nor does it delete or change a user's existing SOGo profile.",
+ "sogo_access": "Direct forwarding to SOGo",
+ "sogo_access_info": "After logging in, the user is automatically redirected to SOGo.",
"sogo_visible": "Alias is visible in SOGo",
"sogo_visible_info": "This option only affects objects, that can be displayed in SOGo (shared or non-shared alias addresses pointing to at least one local mailbox). If hidden, an alias will not appear as selectable sender in SOGo.",
"spam_alias": "Create or change time limited alias addresses",
"spam_filter": "Spam filter",
- "spam_policy": "Add or remove items to white-/blacklist",
+ "spam_policy": "Add or remove items to allow-/denylist",
"spam_score": "Set a custom spam score",
"subfolder2": "Sync into subfolder on destination<br><small>(empty = do not use subfolder)</small>",
"syncjob": "Edit sync job",
@@ -741,13 +845,28 @@
"session_expires": "Your session will expire in about 15 seconds"
},
"login": {
+ "back_to_mailcow": "Back to mailcow",
"delayed": "Login was delayed by %s seconds.",
"fido2_webauthn": "FIDO2/WebAuthn Login",
+ "forgot_password": "> Forgot Password?",
+ "invalid_pass_reset_token": "The reset password token is invalid or has expired.<br>Please request a new password reset link.",
"login": "Login",
+ "login_linkstext": "Not the correct login?",
+ "login_usertext": "Log in as user",
+ "login_domainadmintext": "Log in as domain admin",
+ "login_admintext": "Log in as admin",
+ "login_user": "User Login",
+ "login_dadmin": "Domain-Administrator Login",
+ "login_admin": "Administrator Login",
"mobileconfig_info": "Please login as mailbox user to download the requested Apple connection profile.",
- "other_logins": "Key login",
+ "new_password": "New Password",
+ "new_password_confirm": "Confirm new password",
+ "other_logins": "or login with",
"password": "Password",
- "username": "Username"
+ "reset_password": "Reset Password",
+ "request_reset_password": "Request password change",
+ "username": "Username",
+ "email": "Email address"
},
"mailbox": {
"action": "Action",
@@ -774,7 +893,7 @@
"all_domains": "All Domains",
"allow_from_smtp": "Only allow these IPs to use <b>SMTP</b>",
"allow_from_smtp_info": "Leave empty to allow all senders.<br>IPv4/IPv6 addresses and networks.",
- "allowed_protocols": "Allowed protocols for direct user access (does not affect app password protocols)",
+ "allowed_protocols": "Allowed protocols",
"backup_mx": "Relay domain",
"bcc": "BCC",
"bcc_destination": "BCC destination",
@@ -819,13 +938,16 @@
"filters": "Filters",
"fname": "Full name",
"force_pw_update": "Force password update at next login",
+ "force_tfa": "TFA",
"gal": "Global Address List",
"goto_ham": "Learn as <b>ham</b>",
"goto_spam": "Learn as <b>spam</b>",
"hourly": "Hourly",
+ "iam": "Identity Provider",
"in_use": "In use (%)",
"inactive": "Inactive",
"insert_preset": "Insert example preset \"%s\"",
+ "internal": "Internal",
"kind": "Kind",
"last_mail_login": "Last mail login",
"last_modified": "Last modified",
@@ -863,9 +985,9 @@
"recipient_map": "Recipient map",
"recipient_map_info": "Recipient maps are used to replace the destination address on a message before it is delivered.",
"recipient_map_new": "New recipient",
- "recipient_map_new_info": "Recipient map destination must be a valid email address.",
+ "recipient_map_new_info": "Recipient map destination must be a valid email addresses or a domain name.",
"recipient_map_old": "Original recipient",
- "recipient_map_old_info": "A recipient maps original destination must be valid email addresses or a domain name.",
+ "recipient_map_old_info": "A recipient maps original destination must be a valid email addresses or a domain name.",
"recipient_maps": "Recipient maps",
"relay_all": "Relay all recipients",
"relay_unknown": "Relay unknown mailboxes",
@@ -954,7 +1076,7 @@
"notified": "Notified",
"qhandler_success": "Request successfully sent to the system. You can now close the window.",
"qid": "Rspamd QID",
- "qinfo": "The quarantine system will save rejected mail to the database (the sender will <em>not</em> be given the impression of a delivered mail) as well as mail, that is delivered as copy into the Junk folder of a mailbox.\r\n <br>\"Learn as spam and delete\" will learn a message as spam via Bayesian theorem and also calculate fuzzy hashes to deny similar messages in the future.\r\n <br>Please be aware that learning multiple messages can be - depending on your system - time consuming.<br>Blacklisted elements are excluded from the quarantine.",
+ "qinfo": "The quarantine system will save rejected mail to the database (the sender will <em>not</em> be given the impression of a delivered mail) as well as mail, that is delivered as copy into the Junk folder of a mailbox.\r\n <br>\"Learn as spam and delete\" will learn a message as spam via Bayesian theorem and also calculate fuzzy hashes to deny similar messages in the future.\r\n <br>Please be aware that learning multiple messages can be - depending on your system - time consuming.<br>Denylisted elements are excluded from the quarantine.",
"qitem": "Quarantine item",
"quarantine": "Quarantine",
"quick_actions": "Actions",
@@ -974,7 +1096,7 @@
"rspamd_result": "Rspamd result",
"sender": "Sender (SMTP)",
"sender_header": "Sender (\"From\" header)",
- "settings_info": "Maximum amount of elements to be quarantined: %s<br>Maximum email size: %s MiB",
+ "settings_info": "Maximum amount of elements to be quarantined (per mailbox): %s<br>Maximum email size: %s MiB",
"show_item": "Show item",
"spam": "Spam",
"spam_score": "Score",
@@ -1011,9 +1133,7 @@
},
"start": {
"help": "Show/Hide help panel",
- "imap_smtp_server_auth_info": "Please use your full email address and the PLAIN authentication mechanism.<br>\r\nYour login data will be encrypted by the server-side mandatory encryption.",
- "mailcow_apps_detail": "Use a mailcow app to access your mails, calendar, contacts and more.",
- "mailcow_panel_detail": "<b>Domain administrators</b> create, modify or delete mailboxes and aliases, change domains and read further information about their assigned domains.<br>\r\n<b>Mailbox users</b> are able to create time-limited aliases (spam aliases), change their password and spam filter settings."
+ "imap_smtp_server_auth_info": "Please use your full email address and the PLAIN authentication mechanism.<br>\r\nYour login data will be encrypted by the server-side mandatory encryption."
},
"success": {
"acl_saved": "ACL for object %s saved",
@@ -1034,6 +1154,7 @@
"bcc_edited": "BCC map entry %s edited",
"bcc_saved": "BCC map entry saved",
"cors_headers_edited": "CORS settings have been saved",
+ "custom_login_modified": "Login customisation was saved successfully",
"db_init_complete": "Database initialization completed",
"delete_filter": "Deleted filters ID %s",
"delete_filters": "Deleted filters: %s",
@@ -1058,6 +1179,7 @@
"forwarding_host_removed": "Forwarding host %s has been removed",
"global_filter_written": "Filter was successfully written to file",
"hash_deleted": "Hash deleted",
+ "iam_test_connection": "Connection successful",
"ip_check_opt_in_modified": "IP check was saved successfully",
"item_deleted": "Item %s successfully deleted",
"item_released": "Item %s released",
@@ -1069,14 +1191,17 @@
"mailbox_added": "Mailbox %s has been added",
"mailbox_modified": "Changes to mailbox %s have been saved",
"mailbox_removed": "Mailbox %s has been removed",
+ "mailbox_renamed": "Mailbox was renamed from %s to %s",
"nginx_reloaded": "Nginx was reloaded",
"object_modified": "Changes to object %s have been saved",
"password_policy_saved": "Password policy was saved successfully",
+ "password_changed_success": "Password was successfully changed",
"pushover_settings_edited": "Pushover settings successfully set, please verify credentials.",
"qlearn_spam": "Message ID %s was learned as spam and deleted",
"queue_command_success": "Queue command completed successfully",
"recipient_map_entry_deleted": "Recipient map ID %s has been deleted",
"recipient_map_entry_saved": "Recipient map entry \"%s\" has been saved",
+ "recovery_email_sent": "Recovery email sent to %s",
"relayhost_added": "Map entry %s has been added",
"relayhost_removed": "Map entry %s has been removed",
"reset_main_logo": "Reset to default logo",
@@ -1095,6 +1220,7 @@
"tls_policy_map_entry_deleted": "TLS policy map ID %s has been deleted",
"tls_policy_map_entry_saved": "TLS policy map entry \"%s\" has been saved",
"ui_texts": "Saved changes to UI texts",
+ "ui_theme_modified": "Theme was saved successfully",
"upload_success": "File uploaded successfully",
"verified_fido2_login": "Verified FIDO2 login",
"verified_totp_login": "Verified TOTP login",
@@ -1108,6 +1234,11 @@
"confirm_totp_token": "Please confirm your changes by entering the generated token",
"delete_tfa": "Disable TFA",
"disable_tfa": "Disable TFA until next successful login",
+ "force_tfa": "Force 2FA enrollment at login",
+ "force_tfa_info": "The user will be required to set up two-factor authentication before accessing the panel.",
+ "setup_title": "Two-Factor Authentication Required",
+ "setup_required": "Your account requires two-factor authentication. Please set up a 2FA method to continue.",
+ "cancel_setup": "Cancel and log out",
"enter_qr_code": "Your TOTP code if your device cannot scan QR codes",
"error_code": "Error code",
"init_webauthn": "Initializing, please wait...",
@@ -1153,6 +1284,7 @@
"apple_connection_profile_mailonly": "This connection profile includes IMAP and SMTP configuration parameters for an Apple device.",
"apple_connection_profile_with_app_password": "A new app password is generated and added to the profile so that no password needs to be entered when setting up your device. Please do not share the file as it grants full access to your mailbox.",
"attribute": "Attribute",
+ "authentication": "Authentication",
"change_password": "Change password",
"change_password_hint_app_passwords": "Your account has %d app passwords that will not be changed. To manage these, go to the App passwords tab.",
"clear_recent_successful_connections": "Clear seen successful connections",
@@ -1162,10 +1294,11 @@
"created_on": "Created on",
"daily": "Daily",
"day": "day",
+ "description": "Description",
"delete_ays": "Please confirm the deletion process.",
"direct_aliases": "Direct alias addresses",
"direct_aliases_desc": "Direct alias addresses are affected by spam filter and TLS policy settings.",
- "direct_protocol_access": "This mailbox user has <b>direct, external access</b> to the following protocols and applications. This setting is controlled by your administrator. App passwords can be created to grant access to individual protocols and applications.<br>The \"Login to webmail\" button provides single-sign-on to SOGo and is always available.",
+ "direct_protocol_access": "This mailbox user has <b>direct, external access</b> to the following protocols and applications. This setting is controlled by your administrator. App passwords can be created to grant access to individual protocols and applications.<br>The \"Webmail\" button provides single-sign-on to SOGo and is always available.",
"eas_reset": "Reset ActiveSync device cache",
"eas_reset_help": "In many cases a device cache reset will help to recover a broken ActiveSync profile.<br><b>Attention:</b> All elements will be redownloaded!",
"eas_reset_now": "Reset now",
@@ -1176,7 +1309,9 @@
"encryption": "Encryption",
"excludes": "Excludes",
"expire_in": "Expire in",
+ "expire_never": "Never Expire",
"fido2_webauthn": "FIDO2/WebAuthn",
+ "forever": "Forever",
"force_pw_update": "You <b>must</b> set a new password to be able to access groupware related services.",
"from": "from",
"generate": "generate",
@@ -1206,10 +1341,14 @@
"no_last_login": "No last UI login information",
"no_record": "No record",
"open_logs": "Open logs",
- "open_webmail_sso": "Login to webmail",
+ "open_webmail_sso": "Webmail",
+ "overview": "Overview",
"password": "Password",
"password_now": "Current password (confirm changes)",
+ "pw_update_required": "Your account requires a password change. Please set a new password to continue.",
"password_repeat": "Password (repeat)",
+ "password_reset_info": "If no email for password recovery is provided, this function cannot be used.",
+ "protocols": "Protocols",
"pushover_evaluate_x_prio": "Escalate high priority mail [<code>X-Priority: 1</code>]",
"pushover_info": "Push notification settings will apply to all clean (non-spam) mail delivered to <b>%s</b> including aliases (shared, non-shared, tagged).",
"pushover_only_x_prio": "Only consider high priority mail [<code>X-Priority: 1</code>]",
@@ -1220,6 +1359,7 @@
"pushover_sound": "Sound",
"pushover_vars": "When no sender filter is defined, all mails will be considered.<br>Regex filters as well as exact sender checks can be defined individually and will be considered sequentially. They do not depend on each other.<br>Useable variables for text and title (please take note of data protection policies)",
"pushover_verify": "Verify credentials",
+ "pw_recovery_email": "Password recovery email",
"q_add_header": "Junk folder",
"q_all": "All categories",
"q_reject": "Rejected",
@@ -1239,12 +1379,13 @@
"sogo_profile_reset": "Reset SOGo profile",
"sogo_profile_reset_help": "This will destroy a user's SOGo profile and <b>delete all contact and calendar data irretrievable</b>.",
"sogo_profile_reset_now": "Reset profile now",
- "spam_aliases": "Temporary email aliases",
+ "spam_aliases": "Spam email aliases",
+ "spam_aliases_info": "A spam alias is a temporary email address that can be used to protect real email addresses. <br>Optionally, an expiration time can be set so that the alias is automatically deactivated after the defined period, effectively disposing of abused or leaked addresses.",
"spam_score_reset": "Reset to server default",
"spamfilter": "Spam filter",
"spamfilter_behavior": "Rating",
- "spamfilter_bl": "Blacklist",
- "spamfilter_bl_desc": "Blacklisted email addresses to <b>always</b> classify as spam and reject. Rejected mail will <b>not</b> be copied to quarantine. Wildcards may be used. A filter is only applied to direct aliases (aliases with a single target mailbox) excluding catch-all aliases and a mailbox itself.",
+ "spamfilter_bl": "Denylist",
+ "spamfilter_bl_desc": "Denylisted email addresses to <b>always</b> classify as spam and reject. Rejected mail will <b>not</b> be copied to quarantine. Wildcards may be used. A filter is only applied to direct aliases (aliases with a single target mailbox) excluding catch-all aliases and a mailbox itself.",
"spamfilter_default_score": "Default values",
"spamfilter_green": "Green: this message is not spam",
"spamfilter_hint": "The first value describes the \"low spam score\", the second represents the \"high spam score\".",
@@ -1255,8 +1396,8 @@
"spamfilter_table_empty": "No data to display",
"spamfilter_table_remove": "remove",
"spamfilter_table_rule": "Rule",
- "spamfilter_wl": "Whitelist",
- "spamfilter_wl_desc": "Whitelisted email addresses are programmed to <b>never</b> classify as spam. Wildcards may be used. A filter is only applied to direct aliases (aliases with a single target mailbox) excluding catch-all aliases and a mailbox itself.",
+ "spamfilter_wl": "Allowlist",
+ "spamfilter_wl_desc": "Allowlisted email addresses are programmed to <b>never</b> classify as spam. Wildcards may be used. A filter is only applied to direct aliases (aliases with a single target mailbox) excluding catch-all aliases and a mailbox itself.",
"spamfilter_yellow": "Yellow: this message may be spam, will be tagged as spam and moved to your junk folder",
"status": "Status",
"sync_jobs": "Sync jobs",
@@ -1276,6 +1417,7 @@
"tag_in_subfolder": "In subfolder",
"tag_in_subject": "In subject",
"text": "Text",
+ "tfa_info": "Two-factor authentication helps protect your account. If you enable it, you need app passwords to log in to apps or services that don't support two-factor authentication (e.g. Mailclients).",
"title": "Title",
"tls_enforce_in": "Enforce TLS incoming",
"tls_enforce_out": "Enforce TLS outgoing",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.es-es.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.es-es.json
index 78580cc..7d86973 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.es-es.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.es-es.json
@@ -10,11 +10,11 @@
"quarantine": "Acciones de cuarentena",
"quarantine_attachments": "Archivos ajuntos en cuarentena",
"quarantine_notification": "Notificaciones de cuarentena",
- "ratelimit": "Rate limit",
+ "ratelimit": "Límite de peticiones",
"recipient_maps": "Rutas del destinatario",
"sogo_profile_reset": "Resetear perfil SOGo",
"spam_alias": "Aliases temporales",
- "spam_policy": "Lista blanca/negra",
+ "spam_policy": "Lista de bloqueo/desbloqueo",
"spam_score": "Puntuación de spam",
"syncjobs": "Trabajos de sincronización",
"tls_policy": "Póliza de TLS",
@@ -22,7 +22,13 @@
"app_passwds": "Gestionar las contraseñas de aplicaciones",
"domain_desc": "Cambiar descripción del dominio",
"protocol_access": "Cambiar protocolo de acceso",
- "quarantine_category": "Cambiar categoría de las notificaciones de cuarentena"
+ "quarantine_category": "Cambiar categoría de las notificaciones de cuarentena",
+ "domain_relayhost": "Cambiar relayhost por un dominio",
+ "extend_sender_acl": "Permitir extender la ACL del remitente por direcciones externas",
+ "pw_reset": "Permitir el restablecimiento de la contraseña del usuario mailcow",
+ "sogo_access": "Permitir la gestión del acceso a SOGo",
+ "mailbox_relayhost": "Cambiar el host de reenvío para un buzón",
+ "smtp_ip_access": "Cambiar hosts permitidos para SMTP"
},
"add": {
"activate_filter_warn": "Todos los demás filtros se desactivarán cuando este filtro se active.",
@@ -30,7 +36,7 @@
"add": "Agregar",
"add_domain_only": "Agregar dominio solamente",
"add_domain_restart": "Agregar dominio y reiniciar SOGo",
- "alias_address": "Dirección(es) alias:",
+ "alias_address": "Dirección(es) alias",
"alias_address_info": "<small>Dirección(es) de correo completa(s) ó @dominio.com, para atrapar todos los mensajes para un dominio (separado por coma). <b>Dominios que existan en mailcow solamente</b>.</small>",
"alias_domain": "Dominio alias",
"alias_domain_info": "<small>Nombres de dominio válidos solamente (separado por coma).</small>",
@@ -41,13 +47,13 @@
"delete1": "Eliminar de la fuente cuando se complete",
"delete2": "Eliminar mensajes en el destino que no están en la fuente",
"delete2duplicates": "Eliminar duplicados en el destino",
- "description": "Descripción:",
+ "description": "Descripción",
"destination": "Destino",
"domain": "Dominio",
- "domain_quota_m": "Cuota total del dominio (MiB):",
+ "domain_quota_m": "Cuota total del dominio (MiB)",
"enc_method": "Método de cifrado",
"exclude": "Excluir objectos (regex)",
- "full_name": "Nombre completo:",
+ "full_name": "Nombre completo",
"gal": "Lista global de direcciones (GAL)",
"gal_info": "El GAL contiene todos los objetos de un dominio y no puede ser editado por ningún usuario. Falta información de disponibilidad en SOGo, si está desactivada. <b>Reinicia SOGo para aplicar los cambios.</b>",
"generate": "Generar",
@@ -57,20 +63,20 @@
"hostname": "Host",
"kind": "Tipo",
"mailbox_quota_def": "Cuota de buzón predeterminada",
- "mailbox_quota_m": "Máx. cuota por buzón (MiB):",
- "mailbox_username": "Nombre de usuario (parte izquierda de una dirección de correo):",
- "max_aliases": "Máx. alias posibles:",
- "max_mailboxes": "Máx. buzones posibles:",
+ "mailbox_quota_m": "Máx. cuota por buzón (MiB)",
+ "mailbox_username": "Nombre de usuario (parte izquierda de una dirección de correo)",
+ "max_aliases": "Máx. alias posibles",
+ "max_mailboxes": "Máx. buzones posibles",
"mins_interval": "Intervalo de sondeo (minutos)",
"multiple_bookings": "Múltiples reservas",
"nexthop": "Siguiente destino",
- "password": "Constraseña:",
- "password_repeat": "Confirmación de contraseña (repetir):",
+ "password": "Contraseña",
+ "password_repeat": "Confirmación de contraseña (repetir)",
"port": "Puerto",
- "post_domain_add": "<b>Nota:</b> Necesitarás reiniciar el contenedor del servicio SOGo despues de agregar un nuevo dominio",
- "quota_mb": "Cuota (MiB):",
+ "post_domain_add": "Es necesario reiniciar el contenedor del servicio SOGo, \"sogo-mailcow\", tras agregar un nuevo dominio.<br><br>Además, la configuración DNS de los dominios debería ser comprobada. En cuanto la configuración DNS se apruebe, reinicie \"acme-mailcow\" para generar automáticamente certificados para su nuevo dominio (autoconfig.<dominio>, autodiscover.<dominio>).<br>Este paso es opcional y se reintentará cada 24 horas.",
+ "quota_mb": "Cuota (MiB)",
"relay_all": "Retransmitir todos los destinatarios",
- "relay_all_info": "<small>Si eliges <b>no</b> retransmitir a todos los destinatarios, necesitas agregar un buzón \"ciego\" por cada destinatario que debe ser retransmitido.</small>",
+ "relay_all_info": "↪ Si se elige <b>no</b> retransmitir todos los destinatarios, será necesario agregar un buzón \"ciego\" por cada destinatario que deba ser retransmitido.",
"relay_domain": "Retransmitir este dominio",
"select": "Por favor selecciona...",
"select_domain": "Por favor elige un dominio primero",
@@ -79,7 +85,7 @@
"skipcrossduplicates": "Omitir mensajes duplicados en carpetas (orden de llegada)",
"subscribeall": "Suscribirse a todas las carpetas",
"syncjob": "Añadir trabajo de sincronización",
- "syncjob_hint": "Ten en cuenta que las contraseñas deben guardarse en texto sin cifrado",
+ "syncjob_hint": "Tenga en cuenta que las contraseñas deben guardarse en texto plano sin cifrar",
"target_address": "Direcciones destino:",
"target_address_info": "<small>Dirección(es) de correo completa(s) (separado por coma).</small>",
"target_domain": "Dominio destino:",
@@ -93,7 +99,16 @@
"app_password": "Añadir contraseña para la app",
"public_comment": "Comentarios públicos",
"disable_login": "Desactivar login (el correo entrante seguirá activo)",
- "comment_info": "Los comentarios privados no son visibles al usuario, mientras que los comentarios públicos aparecerán sobre la información general del usuario"
+ "comment_info": "Los comentarios privados no son visibles al usuario, mientras que los comentarios públicos aparecerán sobre la información general del usuario",
+ "dry": "Simular la sincronización",
+ "private_comment": "Comentario privado",
+ "app_passwd_protocols": "Protocolos autorizados para la contraseña de la aplicación",
+ "relay_transport_info": "<div class=\"label label-info\">Información</div> Puede definir mapas de transporte para un destino personalizado para este dominio. En caso de no definirlo, se realizará una búsqueda MX.",
+ "bcc_dest_format": "El destino del CCO debe ser una única dirección de correo electrónico válida.<br>Si necesita enviar una copia a varias direcciones, cree un alias y utilícelo aquí.",
+ "domain_matches_hostname": "El dominio %s coincide con el nombre de host",
+ "relay_unknown_only": "Reenviar sólo los buzones no existentes. Los buzones existentes se entregarán localmente.",
+ "relayhost_wrapped_tls_info": "Por favor, no utilice puertos con TLS (habitualmente, el puerto 465). <br>Utilice cualquier puerto no cifrado y emita STARTTLS. Se puede crear una política para imponer TLS en \"TLS policy maps\".",
+ "tags": "Etiquetas"
},
"admin": {
"access": "Acceso",
@@ -122,7 +137,7 @@
"app_name": "Nombre de la app",
"apps_name": "Nombre \"mailcow Apps\"",
"arrival_time": "Tiempo de llegada (hora del servidor)",
- "ban_list_info": "Lista de IPs bloqueadas: <b>red (tiempo de prohibición restante) - [acciones]</b>.<br />Las IPs en cola para ser desbloqueadas se eliminarán de la lista de bloqueos en unos pocos segundos.<br />Las etiquetas rojas indican bloqueos permanentes mediante la inclusión en la lista negra.",
+ "ban_list_info": "Lista de direcciones IP bloqueadas: <b>red (tiempo de prohibición restante) - [acciones]</b>.<br />Las direcciones IP en cola para ser desbloqueadas se eliminarán de la lista de bloqueos en unos segundos.<br />Las etiquetas rojas indican bloqueos permanentes por inclusión en la lista de bloqueo.",
"change_logo": "Cambiar logo",
"configuration": "Configuración",
"credentials_transport_warning": "<b>Advertencia</b>: al agregar una nueva entrada de ruta de transporte se actualizarán las credenciales para todas las entradas con una columna de \"siguiente destino\" coincidente.",
@@ -150,15 +165,15 @@
"excludes": "Excluye a estos destinatarios",
"f2b_ban_time": "Tiempo de restricción (s)",
"f2b_ban_time_increment": "Tiempo de restricción se incrementa con cada restricción",
- "f2b_blacklist": "Redes y hosts en lista negra",
- "f2b_list_info": "Un host o red en lista negra siempre superará a una entidad de la lista blanca. <b>Las actualizaciones de la lista tardarán unos segundos en aplicarse.</b>",
+ "f2b_blacklist": "Redes y hosts en lista de bloqueo",
+ "f2b_list_info": "Un host o red en lista de bloqueo siempre tendrá prioridad sobre una entidad de la lista de desbloqueo. <b>Las actualizaciones de la lista tardarán unos segundos en aplicarse.</b>",
"f2b_max_attempts": "Max num. de intentos",
"f2b_max_ban_time": "Max tiempo de restricción (s)",
"f2b_netban_ipv4": "Tamaño de subred IPv4 para aplicar la restricción (8-32)",
"f2b_netban_ipv6": "Tamaño de subred IPv6 para aplicar la restricción (8-128)",
"f2b_parameters": "Parametros Fail2ban",
"f2b_retry_window": "Ventana de tiempo entre reintentos",
- "f2b_whitelist": "Redes y hosts en lista blanca",
+ "f2b_whitelist": "Redes y hosts en lista de desbloqueo",
"filter_table": "Filtrar tabla",
"forwarding_hosts": "Hosts de reenvío",
"forwarding_hosts_add_hint": "Se puede especificar direcciones IPv4 / IPv6, redes en notación CIDR, nombres de host (que se resolverán en direcciones IP) o dominios (que se resolverán en direcciones IP consultando registros SPF o, en su defecto, registros MX)",
@@ -246,7 +261,146 @@
"unban_pending": "Desbloqueo pendiente",
"unchanged_if_empty": "Si no hay cambios déjalo en blanco",
"upload": "Cargar",
- "username": "Nombre de usuario"
+ "username": "Nombre de usuario",
+ "force_sso_text": "Si se configura un proveedor OIDC externo, esta opción oculta los formularios por defecto de inicio de sesión y muestra solamente el botón de inicio de sesión único",
+ "admin_quicklink": "Ocultar enlace rápido a página de inicio de sesión para administradores",
+ "iam_default_template_description": "Si no se asigna una plantilla a un usuario, se utilizará la plantilla por defecto para crear el buzón, pero no para actualizarlo.",
+ "reset_password_vars": "<code>{{link}}</code> El enlace generado para el restablecimiento de contraseña<br><code>{{username}}</code> El buzón del usuario que ha solicitado el restablecimiento de contraseña<br><code>{{username2}}</code> La dirección del buzón de recuperación de contraseña<br><code>{{date}}</code> La fecha en que se realizó la solicitud de restablecimiento de contraseña<br><code>{{token_lifetime}}</code> El periodo de vigencia del token en minutos<br><code>{{hostname}}</code> El servidor Mailcow",
+ "api_info": "La API es un trabajo en curso. La documentación se puede encontrar en <a href=\"/api\">/api</a>",
+ "iam_description": "Configurar un proveedor de autenticación externo<br>Los buzones de usuario se crearán automáticamente la primera vez que se inicie sesión, siempre que se hayan configurado las equivalencias de atributos",
+ "ui_header_announcement_help": "El anuncio será visible para todos los usuarios conectados y también en la pantalla de inicio de sesión.",
+ "html": "HTML",
+ "oauth2_redirect_uri": "URI de redirección",
+ "quarantine_bcc": "Remitir una copia de todas las notificaciones (CCO) a este destinatario: <br><small>Dejar en blanco para desactivar. <b>Correo sin firmar y sin comprobar. Debe entregarse solo internamente.</b></small>",
+ "quarantine_redirect": "<b>Redirigir todas las notificaciones</b> a este destinatario:<br><small>Dejar en blanco para desactivar. <b>Correo sin firmar y sin comprobar. Debe entregarse sólo internamente.</b></small>",
+ "iam_authorize_url": "Endpoint de autorización",
+ "sal_level": "Nivel de Moo",
+ "ui_footer": "Pie de página (se permite HTML)",
+ "is_mx_based": "Basado en MX",
+ "password_reset_tmpl_text": "Plantilla de texto",
+ "password_length": "Longitud de la contraseña",
+ "quicklink_text": "Mostrar u ocultar enlaces rápidos a otras páginas de inicio bajo el formulario de inicio de sesión",
+ "password_policy_lowerupper": "Debe contener caracteres en minúsculas y mayúsculas",
+ "rspamd_global_filters_regex": "Sus nombres indican su propósito. Todo el contenido debe constar de expresiones regulares válidas con el formato \"/patrón/opciones\" (por ejemplo, <code>/.+@domain\\.tld/i</code>).<br>\n Si bien se llevan a cabo comprobaciones básicas de cada expresión regular, la funcionalidad de Rspamd puede verse inutilizada, si no consigue interpretar correctamente la sintaxis utilizada.<br>\n Rspamd intentará leer el contenido del mapa cuando éste se modifique. En caso de de problemas, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">reinicie Rspamd</a> para forzar una recarga del mapa.<br>Los elementos incluidos en listas de bloqueo se excluyen de la cuarentena.",
+ "iam_use_ssl_info": "Si se habilita SSL y el puerto se establece en el 389, se cambiará automáticamente al 636.",
+ "iam_login_provisioning": "Crear usuarios automáticamente al iniciar sesión",
+ "iam_periodic_full_sync": "Sincronización completa periódica",
+ "iam_port": "Puerto",
+ "iam_realm": "Ámbito",
+ "iam_redirect_url": "URL de redirección",
+ "iam_server_url": "URL del servidor",
+ "iam_sso": "Inicio de sesión único (SSO)",
+ "iam_sync_interval": "Intervalo de sincronización/importación (minutos)",
+ "iam_test_connection": "Comprobar conexión",
+ "iam_token_url": "Endpoint del token",
+ "iam_username_field": "Campo de nombre de usuario",
+ "iam_use_ssl": "Utilizar SSL",
+ "iam_use_tls": "Utilizar STARTTLS",
+ "iam_userinfo_url": "Endopint de información de usuario",
+ "iam_use_tls_info": "Si se habilita TLS, se debe utilizar el puerto por defecto del servidor LDAP (389). No se permiten puertos SSL.",
+ "iam_version": "Versión",
+ "ignore_ssl_error": "Ignorar errores de SSL",
+ "ip_check": "Comprobación IP",
+ "ip_check_disabled": "La comprobación de IP está desactivada. Puede activarla en<br> <strong>Sistema > Configuración > Opciones > Personalizar</strong>.",
+ "ip_check_opt_in": "Aceptar utilizar el servicio de terceros <strong>ipv4.mailcow.email</strong> y <strong>ipv6.mailcow.email</strong> para resolver direcciones IP externas.",
+ "last_applied": "Aplicado por última vez",
+ "license_info": "No es obligatorio contar con una licencia, pero ayuda a continuar el desarrollo.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Indique aquí su GUID</a> o <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Support order\">adquiera servicios de soporte para su instalación de Mailcow.</a>",
+ "login_time": "Hora de inicio de sesión",
+ "lookup_mx": "Destino es una expresión regular con la que contrastar el nombre MX (<code>.*\\.google\\.com</code> para dirigir todo el tráfico dirigido a un MX que termina en google.com a través de este salto)",
+ "message": "Mensaje",
+ "no": "✕",
+ "optional": "opcional",
+ "app_hide": "Ocultar para inicio de sesión",
+ "convert_html_to_text": "Convertir HTML a texto plano",
+ "cors_settings": "Configuración de CORS",
+ "customer_id": "ID de cliente",
+ "dkim_overwrite_key": "Sobrescribir la clave DKIM existente",
+ "domain_admin": "Administrador de dominio",
+ "f2b_manage_external": "Gestionar Fail2Ban de manera externa",
+ "f2b_manage_external_info": "Fail2Ban conservará la lista de bloqueo, pero no establecerá activamente reglas para bloquear el tráfico. Utilizar la lista de bloqueo siguiente para bloquear externamente el tráfico.",
+ "filter": "Filtrar",
+ "admins": "Administradores",
+ "admins_ldap": "Administradores de LDAP",
+ "advanced_settings": "Configuración avanzada",
+ "allowed_methods": "Access-Control-Allow-Methods",
+ "allowed_origins": "Access-Control-Allow-Origin",
+ "api_read_only": "Acceso de sólo lectura",
+ "api_read_write": "Acceso de lectura y escritura",
+ "api_skip_ip_check": "Omitir la comprobación de la IP para la API",
+ "authed_user": "Usuario autentificado",
+ "ays": "¿Está seguro de querer continuar?",
+ "logo_normal_label": "Normal",
+ "logo_dark_label": "Invertido para modo oscuro",
+ "copy_to_clipboard": "¡Texto copiado al portapapeles!",
+ "login_page": "Inicio de sesión",
+ "domainadmin_quicklink": "Ocultar enlace rápido a página de inicio de sesión para administradores de dominios",
+ "domain_s": "Dominio(s)",
+ "f2b_filter": "Filtros regex",
+ "f2b_regex_info": "Registros tomados en consideración: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "force_sso": "Deshabilitar el inicio de sesión de Mailcow y mostrar solamente el inicio de sesión único",
+ "guid": "GUID - ID de instancia único",
+ "guid_and_license": "GUID y licencia",
+ "hash_remove_info": "Al eliminar un hash de límite de velocidad (si todavía existe) se reiniciará su contador por completo.<br> Cada hash se indica con un color individual.",
+ "iam": "Proveedor de identidad",
+ "iam_attribute_field": "Campo de atributo",
+ "iam_auth_flow": "Flujo de autenticación",
+ "iam_basedn": "DN de base",
+ "iam_client_id": "ID de cliente",
+ "iam_client_secret": "Secreto de cliente",
+ "iam_client_scopes": "Ámbitos de cliente",
+ "iam_default_template": "Plantilla por defecto",
+ "iam_host": "Host",
+ "iam_host_info": "Introduzca uno o más hosts de LDAP, separados por comas.",
+ "iam_import_users": "Importar usuarios",
+ "iam_mapping": "Equivalencias de atributos",
+ "needs_restart": "necesita reinicio",
+ "oauth2_apps": "Aplicaciones OAuth2",
+ "oauth2_add_client": "Añadir cliente OAuth2",
+ "oauth2_renew_secret": "Generar nuevo secreto de cliente",
+ "oauth2_revoke_tokens": "Revocar todos los tokens de cliente",
+ "options": "Opciones",
+ "password_policy": "Política de contraseñas",
+ "password_policy_chars": "Debe contener al menos un caracter alfabético",
+ "password_policy_length": "La longitud mínima de la contraseña es %d",
+ "password_policy_numbers": "Debe contener al menos un número",
+ "password_policy_special_chars": "Debe contener caracteres especiales",
+ "password_reset_info": "Si no se indica una dirección para la recuperación de contraseñas, esta función no puede utilizarse.",
+ "password_reset_settings": "Configuración de recuperación de contraseña",
+ "password_reset_tmpl_html": "Plantilla HTML",
+ "password_settings": "Configuración de contraseña",
+ "priority": "Prioridad",
+ "quarantine_max_score": "Descartar notificación si la puntuación de spam de un mensaje de correo es mayor que este valor:<br><small>Por defecto 9999.0</small>",
+ "queue_unban": "desbloquear",
+ "regex_maps": "Mapas regex",
+ "relay_rcpt": "Dirección \"Para:\"",
+ "reset_limit": "Eliminar hash",
+ "restore_template": "Dejar en blanco para restablecer la plantilla por defecto",
+ "rsetting_no_selection": "Seleccione una regla",
+ "rsettings_preset_3": "Permitir solamente remitentes específicos para un buzón (utilizar únicamente como buzón interno)",
+ "rsettings_preset_4": "Deshabilitar Rspamd para un dominio",
+ "rspamd_global_filters": "Mapas de filtrado globales",
+ "rspamd_global_filters_agree": "¡Tendré cuidado!",
+ "rspamd_global_filters_info": "Los mapas de filtrado globales contienen distintos tipos de listos de bloqueo y desbloqueo.",
+ "service": "Servicio",
+ "service_id": "ID de servicio",
+ "success": "Éxito",
+ "task": "Tarea",
+ "time": "Tiempo",
+ "title": "Título",
+ "transport_dest_format": "Regex o sintaxis: ejemplo.org, .ejemplo.org, *, buzon@ejemplo.org (se pueden introducir varios valores separados por comas)",
+ "transport_test_rcpt_info": "• Utilizar null@hosted.mailcow.de para comprobar la retransmisión a un destino externo.",
+ "ui_header_announcement": "Anuncios",
+ "ui_header_announcement_content": "Texto (se permite HTML)",
+ "ui_header_announcement_select": "Seleccionar tipo de anuncio",
+ "ui_header_announcement_type": "Tipo",
+ "ui_header_announcement_type_danger": "Muy importante",
+ "ui_header_announcement_type_info": "Información",
+ "ui_header_announcement_type_warning": "Importante",
+ "user_link": "Enlace de usuario",
+ "user_quicklink": "Ocultar enlace rápido a página de inicio de sesión de usuario",
+ "validate_license_now": "Validar el GUID contra el servidor de licencias",
+ "verify": "Verificar",
+ "yes": "✓"
},
"danger": {
"access_denied": "Acceso denegado o datos del formulario inválidos",
@@ -334,7 +488,60 @@
"username_invalid": "Nombre de usuario no se puede utilizar",
"validity_missing": "Por favor asigna un periodo de validez",
"value_missing": "Por favor proporcione todos los valores",
- "yotp_verification_failed": "Verificación Yubico OTP fallida: %s"
+ "yotp_verification_failed": "Verificación Yubico OTP fallida: %s",
+ "last_key": "La última clave no se puede eliminar, en su lugar desactive la autenticación de doble factor.",
+ "img_dimensions_exceeded": "La imagen excede el tamaño máximo permitido",
+ "authsource_in_use": "El proveedor de identidades no se puede cambiar al estar en uso por uno o más usuario(s).",
+ "app_name_empty": "El nombre de la aplicación no puede quedar vacío",
+ "recovery_email_failed": "No se ha podido enviar un correo de recuperación. Contacte con su administrador.",
+ "tls_policy_map_dest_invalid": "Destino de política no válido",
+ "cors_invalid_method": "Allow-Method especificado no válido",
+ "dkim_domain_or_sel_exists": "Ya existe una clave DKIM para \"%s\" y no será sobrescrita",
+ "webauthn_publickey_failed": "No se ha almacenado ninguna clave pública para el autenticador seleccionado",
+ "invalid_reset_token": "Token de restablecimiento no válido",
+ "password_reset_na": "El restablecimiento de contraseña no está disponible en estos momentos. Contacte con su administrador.",
+ "generic_server_error": "Se ha producido un error inesperado en el servidor. Contacte con su administrador.",
+ "reset_f2b_regex": "El filtro Regex no se ha podido restablecer a tiempo, inténtelo de nuevo o espere unos segundos y vuelva a cargar la página web.",
+ "extra_acl_invalid": "Dirección de remitente externo \"%s\" no válida",
+ "extra_acl_invalid_domain": "El remitente externo \"%s\" utiliza un dominio no válido",
+ "max_alias_exceeded": "Se ha excedido el número máximo de alias",
+ "app_passwd_id_invalid": "Contraseña de aplicación con ID %s no válida",
+ "comment_too_long": "Comentario demasiado largo, máximo de 160 caracteres permitidos",
+ "cors_invalid_origin": "Allow-Origin especificado no válido",
+ "demo_mode_enabled": "Modo demo activado",
+ "description_invalid": "Descripción de recurso para %s no válida",
+ "extended_sender_acl_denied": "no se encuentra ACL para establecer direcciones de remitente externo",
+ "fido2_verification_failed": "Verificación FIDO2 fallida: %s",
+ "file_open_error": "El archivo no se puede abrir para escritura",
+ "global_filter_write_error": "No se ha podido escribir el archivo de filtro: %s",
+ "global_map_invalid": "Mapa global con ID %s no válido",
+ "global_map_write_error": "No se ha podido guardar el mapa global con ID %s: %s",
+ "ham_learn_error": "Error de aprendizaje de correo deseado: %s",
+ "iam_test_connection": "Conexión fallida",
+ "imagick_exception": "Error: Excepción en Imagick al leer la imagen",
+ "img_invalid": "No se ha podido validar el archivo de imagen",
+ "img_size_exceeded": "La imagen excede el tamaño máximo de archivo",
+ "img_tmp_missing": "No se ha podido validar el archivo de imagen: archivo temporal no encontrado",
+ "invalid_filter_type": "Tipo de filtro no válido",
+ "invalid_mime_type": "Tipo MIME no válido",
+ "maxquota_empty": "La cuota máxima por buzón no debe ser cero.",
+ "nginx_reload_failed": "Recarga de Nginx fallida: %s",
+ "password_reset_invalid_user": "Buzón no encontrado o dirección de correo para recuperación no establecida",
+ "pushover_credentials_missing": "Falta el token y/o la clave de Pushover",
+ "pushover_key": "La clave de Pushover tiene un formato incorrecto",
+ "pushover_token": "El token de Pushover tiene un formato incorrecto",
+ "required_data_missing": "Datos necesarios %s no proporcionados",
+ "reset_token_limit_exceeded": "Se ha superado el límite de tokens de restablecimiento. Inténtelo más tarde.",
+ "resource_invalid": "Nombre de recurso %s no válido",
+ "targetd_relay_domain": "El dominio de destino %s es un dominio de retransmisión",
+ "template_exists": "La plantilla %s ya existe",
+ "template_id_invalid": "Plantilla con ID %s no válida",
+ "template_name_invalid": "Nombre de plantilla no válido",
+ "temp_error": "Error transitorio",
+ "tfa_token_invalid": "Token de autenticación de doble factor no válido",
+ "to_invalid": "El destinatario no puede quedar en blanco",
+ "webauthn_authenticator_failed": "No se ha localizado el autenticador seleccionado",
+ "webauthn_username_failed": "El autenticador seleccionado pertenece a otra cuenta"
},
"debug": {
"containers_info": "Información de los contenedores",
@@ -344,15 +551,35 @@
"log_info": "<p>Los <b>logs en memoria</b> son recopilados en listas de Redis y recortados a LOG_LINES (%d) cada minuto para prevenir sobrecarga en el sistema.\r\n <br>Los logs en memoria no están destinados a ser persistentes. Todas las aplicaciones que logean a la memoria, también logean en el daemon de Docker y, por lo tanto, en el controlador de registro predeterminado.\r\n El log en memoria se debe utilizar para analizar problemas menores con los contenedores.</p>\r\n <p>Los <b>logs externos</b> se recopilan a través de la API de la aplicación dada.</p>\r\n <p>Los <b>logs estáticos</b> son principalmente registros de actividad, que no están registrados en Dockerd pero que aún deben ser persistentes (excepto los registros de API).</p>",
"logs": "Logs",
"restart_container": "Reiniciar",
- "solr_dead": "Solr está empezando, deshabilitado o caído.",
"docs": "Docs",
"last_modified": "Última modificación",
"size": "Tamaño",
"started_at": "Iniciado el",
- "solr_status": "Solr status",
"uptime": "Uptime",
"static_logs": "Logs estáticos",
- "system_containers": "Sistema y Contenedores"
+ "system_containers": "Sistema y Contenedores",
+ "show_ip": "Mostrar IP pública",
+ "wip": "Actualmente incompleto",
+ "current_time": "Hora del sistema",
+ "service": "Servicio",
+ "timezone": "Huso horario",
+ "update_available": "Hay una actualización disponible",
+ "update_failed": "No se han podido comprobar las actualizaciones",
+ "architecture": "Arquitectura",
+ "chart_this_server": "Gráfico (este servidor)",
+ "container_running": "En ejecución",
+ "container_disabled": "Contenedor detenido o desactivado",
+ "container_stopped": "Detenido",
+ "cores": "Núcleos",
+ "error_show_ip": "No se han podido resolver las direcciones IP públicas",
+ "history_all_servers": "Historial (todos los servidores)",
+ "login_time": "Tiempo",
+ "memory": "Memoria",
+ "online_users": "Usuarios conectados",
+ "started_on": "Iniciado",
+ "success": "Éxito",
+ "no_update_available": "El sistema está actualizado",
+ "username": "Nombre de usuario"
},
"diagnostics": {
"cname_from_a": "Valor derivado del registro A / AAAA. Esto es permitido siempre que el registro apunte al recurso correcto.",
@@ -362,7 +589,8 @@
"dns_records_name": "Nombre",
"dns_records_status": "Información actual",
"dns_records_type": "Tipo",
- "optional": "Este récord es opcional."
+ "optional": "Este récord es opcional.",
+ "dns_records_docs": "Consulte también <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">la documentación</a>."
},
"edit": {
"active": "Activo",
@@ -430,13 +658,79 @@
"title": "Editar objeto",
"unchanged_if_empty": "Si no hay cambios dejalo en blanco",
"username": "Nombre de usuario",
- "validate_save": "Validar y guardar"
+ "validate_save": "Validar y guardar",
+ "app_passwd_protocols": "Protocolos permitidos con contraseña de aplicación",
+ "domain_footer_info": "Los pies de página de dominio se añaden a todos los mensajes salientes remitidos por una dirección de dicho dominio.<br> Están disponibles las siguientes variables para el pie de página:",
+ "sender_acl_info": "Si el usuario del buzón A tiene permitido enviar como el buzón B, la dirección de remitente no se mostrará automáticamente como seleccionable en el campo \"De\" en SOGo.<br>\n El usuario del buzón B necesitará crear una delegación en SOGo para permitir al usuario A seleccionar su dirección como remitente. Para delegar un buzón en SOGo, utilice el menú (tres puntos) a la derecha del nombre del buzón en la esquina superior izquierda, en la vista de correo. Este comportamiento no se aplica a direcciones alias.",
+ "sogo_access_info": "Tras iniciar sesión, el usuario será redirigido automáticamente a SOGo.",
+ "comment_info": "Un comentario privado no es visible para el usuario, mientras que un comentario público se muestra como descripción emergente al pasar el ratón en la vista general del usuario",
+ "quota_warning_bcc_info": "Los avisos se enviarán como copias separadas a los siguientes destinatarios. Se indicará en el asunto el usuario afectado entre paréntesis, como por ejemplo: <code>Aviso de cuota (usuario@ejemplo.com)</code>.",
+ "sogo_access": "Redirección directa a SOGo",
+ "sogo_visible_info": "Esta opción solamente afecta a objetos que puedan ser visualizados en SOGo (alias compartidos o no compartidos que apunten al menos a un buzón interno). Si se oculta, el alias no aparecerá como seleccionable en SOGo.",
+ "extended_sender_acl_info": "Se aconseja importar una clave de dominio DKIM, si está disponible.<br>\n Recuerde añadir este servidor al registro SPF correspondiente.<br>\n Siempre que se añada un dominio o alias a este servidor, que se superponga con una dirección externa, se eliminará la dirección externa.<br>\n Utilice @dominio.tld para permitir enviar como *@dominio.tld.",
+ "pushover_info": "La configuración de notificaciones push se aplicará a todos los mensajes limpios (no spam) entregados a <b>%s</b> incluyendo alias (compartidos, no compartidos, etiquetados).",
+ "mbox_rl_info": "Este límite de peticiones se aplica al nombre de inicio de sesión SASL, coincide con cualquier dirección \"de\" que utilice el usuario conectado. Un límite de buzón tiene precedencia sobre un límite del dominio.",
+ "admin": "Editar administrador",
+ "none_inherit": "Ninguno / heredar",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Comprobación de remitente desactivada</span>",
+ "footer_exclude": "Excluir del pie de página",
+ "acl": "ACL (permisos)",
+ "advanced_settings": "Configuración avanzada",
+ "allow_from_smtp": "Permitir únicamente a las siguientes direcciones IP utilizar <b>SMTP</b>",
+ "allow_from_smtp_info": "Dejar en blanco para permitir cualquier remitente.<br>Direcciones y redes IPv4/IPv6.",
+ "allowed_protocols": "Protocolos permitidos para acceso directo del usuario (no afecta a protocolos con contraseña de aplicación)",
+ "app_name": "Nombre de aplicación",
+ "app_passwd": "Contraseña de aplicación",
+ "created_on": "Creado",
+ "custom_attributes": "Atributos personalizados",
+ "delete_ays": "Por favor, confirme el proceso de eliminación.",
+ "disable_login": "Deshabilitar inicio de sesión (se aceptará el correo entrante)",
+ "domain_footer": "Pie de página para todos los usuarios del dominio",
+ "domain_footer_html": "Pie de página HTML",
+ "domain_footer_skip_replies": "Descartar pie de página en correos de respuesta",
+ "extended_sender_acl": "Direcciones de remisión externas",
+ "generate": "generar",
+ "lookup_mx": "El destino es una expresión regular con la que contrastar el nombre MX (<code>.*\\.google\\.com</code> para dirigir todo el correo enviado a un MX que termine en google.com a través de este salto)",
+ "mailbox_relayhost_info": "Aplicable únicamente al buzón y sus alias directos, anula el host de retransmisión para el dominio",
+ "mailbox_rename": "Renombrar buzón",
+ "mailbox_rename_agree": "He creado una copia de seguridad.",
+ "mailbox_rename_warning": "¡IMPORTANTE! Realice una copia de seguridad antes de renombrar el buzón.",
+ "mailbox_rename_alias": "Crear alias automáticamente",
+ "mailbox_rename_title": "Nuevo nombre de buzón local",
+ "password_recovery_email": "Dirección de correo para recuperación de contraseña",
+ "private_comment": "Comentario privado",
+ "public_comment": "Comentario público",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Escalar correo de alta prioridad [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Tener en cuenta únicamente las siguientes direcciones de correo de remitente <small>(separados por comas)</small>",
+ "pushover_text": "Texto de notificación",
+ "pushover_title": "Título de notificación",
+ "pushover_sound": "Sonido",
+ "pushover_verify": "Verificar credenciales",
+ "quota_warning_bcc": "CCO de aviso de cuota",
+ "ratelimit": "Límite de peticiones",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Información</div> Puede definir mapas de transporte para destinatarios personalizados para este dominio. Si no se establece, se realizará una búsqueda MX.",
+ "relay_unknown_only": "Reenviar solamente los buzones no existentes. Los buzones existentes se entregarán localmente.",
+ "sogo_visible": "Alias visible en SOGo.",
+ "spam_alias": "Crear o modificar alias temporales (con caducidad)",
+ "spam_filter": "Filtro de spam",
+ "spam_policy": "Añadir o eliminar elementos de la lista de bloqueo/desbloqueo",
+ "spam_score": "Establecer una puntuación de spam personalizada"
},
"footer": {
"hibp_nok": "¡Se encontró coincidencia - esta es una contraseña <b>no segura</b>, selecciona otra!",
"hibp_ok": "No se encontraron coincidencias",
"loading": "Espera por favor...",
- "restart_now": "Reiniciar ahora"
+ "restart_now": "Reiniciar ahora",
+ "restart_container": "Reiniciar contenedor",
+ "restart_container_info": "<b>Importante:</b> Un reinicio limpio puede llevar un tiempo. Por favor, espere a que finalice.",
+ "cancel": "Cancelar",
+ "confirm_delete": "Confirmar eliminación",
+ "delete_now": "Eliminar ahora",
+ "delete_these_items": "Confirme sus cambios para el siguiente ID de objeto",
+ "hibp_check": "Comprobar en haveibeenpwned.com",
+ "nothing_selected": "Nada seleccionado",
+ "restarting_container": "Reiniciando contenedor, puede llevar un tiempo"
},
"header": {
"administration": "Administración",
@@ -445,17 +739,38 @@
"mailcow_config": "Configuración",
"quarantine": "Cuarentena",
"restart_sogo": "Reiniciar SOGo",
- "user_settings": "Configuraciones de usuario"
+ "user_settings": "Configuraciones de usuario",
+ "mailcow_system": "Sistema",
+ "apps": "Aplicaciones",
+ "restart_netfilter": "Reiniciar netfilter"
},
"info": {
"awaiting_tfa_confirmation": "En espera de confirmación de TFA",
- "no_action": "No hay acción aplicable"
+ "no_action": "No hay acción aplicable",
+ "session_expires": "Su sesión expirará en unos 15 segundos"
},
"login": {
"delayed": "El inicio de sesión ha sido retrasado %s segundos.",
"login": "Inicio de sesión",
"password": "Contraseña",
- "username": "Nombre de usuario"
+ "username": "Nombre de usuario",
+ "login_admin": "Inicio de sesión de administrador",
+ "invalid_pass_reset_token": "El token de restablecimiento de contraseña no es válido o ha caducado.<br>Solicite un nuevo enlace de restablecimiento de contraseña.",
+ "fido2_webauthn": "Inicio de sesión FIDO2/WebAuthn",
+ "forgot_password": "> ¿Contraseña olvidada?",
+ "mobileconfig_info": "Inicie sesión como usuario de buzón para descargar el perfil de conexión solicitado para dispositivos Apple.",
+ "new_password": "Nueva contraseña",
+ "back_to_mailcow": "Volver a mailcow",
+ "login_linkstext": "¿Sesión incorrecta?",
+ "login_usertext": "Iniciar sesión como usuario",
+ "login_domainadmintext": "Iniciar sesión como administrador de dominio",
+ "login_admintext": "Iniciar sesión como administrador",
+ "login_user": "Inicio de sesión de usuario",
+ "login_dadmin": "Inicio de sesión de administrador de dominio",
+ "new_password_confirm": "Confirmar nueva contraseña",
+ "other_logins": "o iniciar sesión con",
+ "reset_password": "Restablecer contraseña",
+ "request_reset_password": "Solicitar cambio de contraseña"
},
"mailbox": {
"action": "Acción",
@@ -539,7 +854,7 @@
"recipient_map": "Regla de destinatario",
"recipient_map_info": "Las reglas de destinatarios se utilizan para reemplazar la dirección de destino en un mensaje antes de que se entregue.",
"recipient_map_new": "Destinatario nuevo",
- "recipient_map_new_info": "El destino de la regla debe ser una dirección de correo válida.",
+ "recipient_map_new_info": "El destino de la regla debe ser una dirección de correo electrónico válida o un nombre de dominio.",
"recipient_map_old": "Destinatario original",
"recipient_map_old_info": "El destino original de una regla de destinatario debe ser una dirección de correo electrónico válida o un nombre de dominio.",
"recipient_maps": "Reglas de destinatario",
@@ -567,7 +882,67 @@
"toggle_all": "Selecionar todo",
"username": "Nombre de usuario",
"waiting": "Esperando",
- "weekly": "Cada semana"
+ "weekly": "Cada semana",
+ "sieve_preset_4": "Colocar en bandeja de entrada, omitir procesamiento posterior en filtros de sieve",
+ "goto_spam": "Aprender como <b>correo no deseado</b>",
+ "sieve_preset_header": "Vea los preajustes de ejemplo más abajo. Para más detalles, consulte <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedia</a>.",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Nombre de usuario o contraseña incorrectos",
+ "tls_policy_maps_enforced_tls": "Estas políticas tendrán precedencia también para aquellos usuarios de buzones en los que sea obligatoria una conexión TLS. Si no se indica ninguna política a continuación, dichos usuarios aplicarán los valores predeterminados que se especifiquen en <code>smtp_tls_mandatory_protocols</code> y <code>smtp_tls_mandatory_ciphers</code>.",
+ "alias_domain_alias_hint": "Los alias <b>no</b> se aplican a dominios de alias automáticamente. Una dirección alias <code>mi-alias@dominio</code> <b>no cubre</b> la dirección <code>mi-alias@dominio-alias</code> (donde \"dominio-alias\" es un hipotético alias para el dominio \"dominio\").<br>Utilice un filtro sieve para redirigir el correo a un buzón externo (ver la pestaña \"Filtros\" o utilice SOGo -> Desvío). Utilice \"expandir alias a dominio de alias\" para agregar automáticamente los alias que falten.",
+ "domain_templates": "Plantillas de dominio",
+ "sieve_preset_1": "Desechar correo con tipos de archivo probablemente peligrosos",
+ "created_on": "Creado",
+ "disable_login": "No permitir iniciar sesión (se seguirá aceptando el correo entrante)",
+ "mailbox": "Buzón",
+ "mailbox_defaults": "Ajustes por defecto",
+ "sogo_visible_y": "Mostrar alias en SOGo",
+ "spam_aliases": "Alias temporal",
+ "add_template": "Añadir plantilla",
+ "all_domains": "Todos los dominios",
+ "allow_from_smtp": "Permitir únicamente a estas direcciones IP utilizar <b>SMTP</b>",
+ "allow_from_smtp_info": "Dejar vacío para permitir cualquier remitente.<br>Direcciones y redes IPv4/IPv6.",
+ "allowed_protocols": "Protocolos permitidos",
+ "goto_ham": "Aprender como <b>correo deseado</b>",
+ "iam": "Proveedor de identidad",
+ "insert_preset": "Insertar valor predeterminado de ejemplo \"%s\"",
+ "last_mail_login": "Último acceso al correo",
+ "last_pw_change": "Último cambio de contraseña",
+ "mailbox_defaults_info": "Definir configuración por defecto para nuevos buzones.",
+ "mailbox_templates": "Plantillas de buzón",
+ "no": "✕",
+ "open_logs": "Abrir registros",
+ "owner": "Propietario",
+ "private_comment": "Comentario privado",
+ "public_comment": "Comentario público",
+ "q_add_header": "al mover a carpeta de Spam",
+ "q_all": " al mover a carpeta de Spam y al rechazar",
+ "q_reject": "al rechazar",
+ "quarantine_category": "Categoría de notificación de cuarentena",
+ "recipient": "Destinatario",
+ "relay_unknown": "Retransmitir buzones desconocidos",
+ "sender": "Remitente",
+ "sieve_preset_2": "Marcar siempre el correo de un remitente específico como leído",
+ "sieve_preset_3": "Descartar silenciosamente, detener procesado de sieve",
+ "sieve_preset_5": "Respuesta automática (vacaciones)",
+ "sieve_preset_6": "Rechazar correo con respuesta",
+ "sieve_preset_7": "Redireccionar y guardar/descartar",
+ "sieve_preset_8": "Redirigir correo de un remitente específico, marcarlo como leído y clasificarlo en subcarpeta",
+ "sogo_visible": "Alias visible en SOGo",
+ "sogo_visible_n": "Ocultar alias en SOGo",
+ "stats": "Estadísticas",
+ "syncjob_check_log": "Comprobar registros",
+ "syncjob_last_run_result": "Resultado de la última ejecución",
+ "syncjob_EX_OK": "Éxito",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Problema de conexión",
+ "syncjob_EXIT_TLS_FAILURE": "Problema con la conexión cifrada",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Problema de autenticación",
+ "syncjob_EXIT_OVERQUOTA": "El buzón de destino ha superado la cuota",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "No es posible conectar con el servidor remoto",
+ "table_size": "Tamaño de la tabla",
+ "table_size_show_n": "Mostrar %s elementos",
+ "templates": "Plantillas",
+ "template": "Plantilla",
+ "yes": "✓"
},
"oauth2": {
"access_denied": "Inicie sesión como propietario del buzón para otorgar acceso a través de OAuth2.",
@@ -609,16 +984,20 @@
"subj": "Asunto",
"text_from_html_content": "Contenido (html convertido)",
"text_plain_content": "Contenido (text/plain)",
- "toggle_all": "Seleccionar todos"
+ "toggle_all": "Seleccionar todos",
+ "confirm": "Confirmar",
+ "deliver_inbox": "Entregar en bandeja de entrada",
+ "download_eml": "Descargar (.eml)",
+ "info": "Información",
+ "junk_folder": "Carpeta de correo no deseado",
+ "notified": "Notificado"
},
"queue": {
"queue_manager": "Administrador de cola"
},
"start": {
"help": "Mostrar/Ocultar panel de ayuda",
- "imap_smtp_server_auth_info": "Por favor utiliza tu dirección de correo completa y el mecanismo de autenticación PLAIN.<br>\r\nTus datos para iniciar sesión serán cifrados por el cifrado obligatorio del servidor",
- "mailcow_apps_detail": "Utiliza una aplicación de mailcow para acceder a tus correos, calendario, contactos y más.",
- "mailcow_panel_detail": "<b>Administradores por dominio</b> pueden crear, modificar o eliminar buzones y alias, modificar los dominios asignados y ver información más detallada sobre los dominios asignados<br>\r\n\t<b>Usuarios de buzón</b> son capaces de crear alias de tiempo limitado (spam alias), cambiar su contraseña y la configuración del filtro de spam del buzón."
+ "imap_smtp_server_auth_info": "Por favor utiliza tu dirección de correo completa y el mecanismo de autenticación PLAIN.<br>\r\nTus datos para iniciar sesión serán cifrados por el cifrado obligatorio del servidor"
},
"success": {
"acl_saved": "ACL para el objeto %s guardado",
@@ -705,8 +1084,10 @@
"aliases_send_as_all": "No verificar permisos del remitente para los siguientes dominios (y sus aliases)",
"change_password": "Cambiar contraseña",
"create_syncjob": "Crear nuevo trabajo de sincronización",
+ "created_on": "Creado",
"daily": "Cada día",
"day": "Día",
+ "description": "Descripción",
"direct_aliases": "Alias directos",
"direct_aliases_desc": "Los alias directos se ven afectadas por el filtro de correo no deseado y la configuración de la política TLS del usuario.",
"eas_reset": "Resetear el caché ActiveSync",
@@ -715,6 +1096,9 @@
"edit": "Editar",
"encryption": "Cifrado",
"excludes": "Excluye",
+ "expire_in": "Expirará en",
+ "expire_never": "Nunca expirará",
+ "forever": "Siempre",
"hour": "Hora",
"hourly": "Cada hora",
"hours": "Horas",
@@ -735,7 +1119,8 @@
"shared_aliases": "Alias compartidos",
"shared_aliases_desc": "Los alias compartidos no se ven afectados por la configuración específica del usuario, como el filtro de correo no deseado o la política de cifrado. Los filtros de spam correspondientes solo pueden ser realizados por un administrador como una política de dominio.",
"sogo_profile_reset": "Resetear perfil SOGo",
- "spam_aliases": "Alias de email temporales",
+ "spam_aliases": "Alias de email de spam",
+ "spam_aliases_info": "Un alias de spam es una dirección de correo electrónico temporal que se puede usar para proteger direcciones de correo electrónico reales. <br>Opcionalmente, se puede establecer un tiempo de expiración para que el alias se desactive automáticamente después del período definido, eliminando efectivamente las direcciones abusadas o filtradas.",
"spamfilter": "Filtro anti-spam",
"spamfilter_behavior": "Clasificación",
"spamfilter_bl": "Lista negra",
@@ -769,11 +1154,55 @@
"waiting": "Esperando",
"week": "Semana",
"weekly": "Cada semana",
- "weeks": "Semanas"
+ "weeks": "Semanas",
+ "with_app_password": "con contraseña de aplicación",
+ "year": "año",
+ "years": "años"
},
"warning": {
"domain_added_sogo_failed": "Se agregó el dominio pero no se pudo reiniciar SOGo, revisa los logs del servidor.",
"fuzzy_learn_error": "Error aprendiendo hash: %s",
- "ip_invalid": "IP inválida omitida: %s"
+ "ip_invalid": "IP inválida omitida: %s",
+ "cannot_delete_self": "No se puede eliminar el usuario conectado"
+ },
+ "datatables": {
+ "collapse_all": "Contraer todo",
+ "aria": {
+ "sortAscending": ": activar para ordenar ascendentemente según la columna",
+ "sortDescending": ": activar para ordenar descendentemente según la columna"
+ },
+ "infoEmpty": "Mostrando 0 a 0 de 0 apuntes",
+ "paginate": {
+ "last": "Última",
+ "next": "Siguiente",
+ "previous": "Anterior",
+ "first": "Primero"
+ },
+ "processing": "Espere, por favor...",
+ "decimal": ".",
+ "emptyTable": "Sin datos disponibles en la tabla",
+ "expand_all": "Ampliar todo",
+ "info": "Mostrando apuntes _START_ a _END_ de _TOTAL_",
+ "infoFiltered": "(filtrado a partir de _MAX_ entradas totales)",
+ "thousands": ",",
+ "lengthMenu": "Mostrar entradas de _MENU_",
+ "loadingRecords": "Cargando...",
+ "search": "Buscar:",
+ "zeroRecords": "No se han encontrado registros coincidentes"
+ },
+ "fido2": {
+ "set_fido2": "Registrar dispositivo FIDO2",
+ "set_fido2_touchid": "Registrar Touch ID en Apple M1",
+ "set_fn": "Establecer nombre amistoso (fácil de recordar)",
+ "confirm": "Confirmar",
+ "fido2_auth": "Iniciar sesión con FIDO2",
+ "fido2_success": "Dispositivo registrado con éxito",
+ "fido2_validation_failed": "Validación fallida",
+ "fn": "Nombre amistoso (fácil de recordar)",
+ "known_ids": "ID conocidas",
+ "none": "Deshabilitado",
+ "register_status": "Estado de registro",
+ "rename": "Renombrar",
+ "start_fido2_validation": "Iniciar validación FIDO2"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.fi-fi.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.fi-fi.json
index d4a5a08..5dd6a9b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.fi-fi.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.fi-fi.json
@@ -267,7 +267,11 @@
"upload": "Lataa",
"username": "Käyttäjätunnus",
"validate_license_now": "Vahvista GUID-tunnus lisenssi palvelinta vastaan",
- "yes": "✓"
+ "yes": "✓",
+ "allowed_methods": "Kulunvalvonta-salli-menetelmät",
+ "admins": "Järjestelmänvalvojat",
+ "admins_ldap": "LDAP-ylläpitäjät",
+ "advanced_settings": "Lisäasetukset"
},
"danger": {
"access_denied": "Käyttö estetty tai lomake tiedot eivät kelpaa",
@@ -376,16 +380,13 @@
"disk_usage": "Levyn käyttö",
"external_logs": "Ulkoiset loki",
"in_memory_logs": "Muistissa olevat lokit",
- "jvm_memory_solr": "JVM-muistin käyttö",
"log_info": "<p>mailcow <b>muistissa olevat lokit</b> kerätään Redis-luetteloihin ja leikataan LOG_LINES (%d) joka minuutti lyömisen vähentämiseksi.\r\n <br>Muistissa olevien lokien ei ole tarkoitus olla pysyviä. Kaikki sovellukset, jotka kirjautuvat muistiin, kirjautuvat myös Docker-daemoniin ja siten oletusarvoiseen lokitiedostoon.\r\n <br>Muistin lokityyppiä olisi käytettävä virheiden virheenkorjaukseen säilöissä.</p>\r\n <p><b>Ulkoiset lokit</b> kerätään annetun sovelluksen API: n kautta.</p>\r\n <p><b>Staattiset lokit</b> ovat useimmiten toimintalokkeja, joita ei kirjata Dockerdiin, mutta joiden on silti oltava pysyviä (paitsi API-lokit).</p>",
"logs": "Logit tausta palveluista",
"restart_container": "Uudelleen käynnistä",
- "solr_dead": "Solr käynnistyy, on poissa käytöstä tai kuoli.",
"docs": "Docs",
"last_modified": "Viimeksi muokattu",
"size": "Koko",
"started_at": "Käynnistetty",
- "solr_status": "Solr-tila",
"uptime": "Päällä",
"started_on": "Aloitettiin",
"static_logs": "Staattiset lokit",
@@ -606,7 +607,7 @@
"recipient_map": "Vastaanottajien yhdistämis määritykset",
"recipient_map_info": "Vastaanottajan karttoja käytetään korvaamaan viestin kohde osoite ennen sen toimittamista.",
"recipient_map_new": "Uusi vastaanottaja",
- "recipient_map_new_info": "Vastaanottajan yhdistämis kartan kohteen on oltava kelvollinen sähköposti osoite.",
+ "recipient_map_new_info": "Vastaanottajan yhdistämis kartan kohteen on oltava kelvollinen sähköposti osoite tai verkkotunnus alueen nimi.",
"recipient_map_old": "Alkuperäinen vastaanottaja",
"recipient_map_old_info": "Vastaanottajan yhdistämis määritysten alkuperäisen kohteen on oltava kelvollinen sähköposti osoite tai verkkotunnus alueen nimi.",
"recipient_maps": "Vastaanottajien yhdistämis määritykset",
@@ -690,9 +691,7 @@
},
"start": {
"help": "Näytä/Piilota help paneeli",
- "imap_smtp_server_auth_info": "Käytä täydellistä sähkö posti osoitetta ja tavallista todennus mekanismia.<br>\r\nPalvelin puolen pakollinen salaus salaa kirjautumistietosi.",
- "mailcow_apps_detail": "Käytä mailcow-sovellusta, kun haluat käyttää sähköposteja, kalenteria, yhteys tietoja ja paljon muuta",
- "mailcow_panel_detail": "<b>Verkkotunnus alueen järjestelmänvalvojat</b> Luo, muokkaa tai poistaa posti laatikoita ja aliaksia, muita verkko tunnuksia ja lue lisä tietoja niiden määritetyista verkko tunnuksista.<br>\r\n<b>Posti laatikon käyttäjät</b> pystyvät luomaan rajoitetun ajan aliaksia (roska posti asetuksia), muuttamaan salasanaa ja roska posti suodattimen asetuksia."
+ "imap_smtp_server_auth_info": "Käytä täydellistä sähkö posti osoitetta ja tavallista todennus mekanismia.<br>\r\nPalvelin puolen pakollinen salaus salaa kirjautumistietosi."
},
"success": {
"acl_saved": "Objektin ACL %s tallenettu",
@@ -806,6 +805,7 @@
"create_syncjob": "Luo uusi synkronointi työ",
"daily": "Päivittäin",
"day": "Päivä",
+ "description": "Kuvaus",
"direct_aliases": "Suorat alias osoitteet",
"direct_aliases_desc": "Roska posti suodatus-ja TLS-käytäntö asetukset vaikuttavat suora aliaksen osoitteisiin.",
"eas_reset": "Tyhjennä ActiveSync-laitteen väli muisti",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.fr-fr.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.fr-fr.json
index 374da54..9ee9167 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.fr-fr.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.fr-fr.json
@@ -3,32 +3,33 @@
"alias_domains": "Ajouter un alias de domaine",
"app_passwds": "Gérer les mots de passe d'application",
"bcc_maps": "Mapping BCC",
- "delimiter_action": "Délimitation d'action",
- "eas_reset": "Réinitialiser les périphériques EA",
+ "delimiter_action": "Action du délimiteur",
+ "eas_reset": "Réinitialiser les périphériques EAS",
"extend_sender_acl": "Autoriser l'extension des ACL par des adresses externes",
"filters": "Filtres",
"login_as": "S'identifier en tant qu'utilisateur",
"prohibited": "Interdit par les ACL",
- "protocol_access": "Modifier le protocol d'acces",
+ "protocol_access": "Modifier le protocole d’accès",
"pushover": "Pushover",
"quarantine": "Actions de quarantaine",
"quarantine_attachments": "Pièces jointes en quarantaine",
"quarantine_notification": "Modifier la notification de quarantaine",
"quarantine_category": "Modifier la catégorie de la notification de quarantaine",
"ratelimit": "Limite d'envoi",
- "recipient_maps": "Cartes destinataire",
+ "recipient_maps": "Cartes des destinataires",
"smtp_ip_access": "Changer les hôtes autorisés pour SMTP",
"sogo_access": "Autoriser la gestion des accès à SOGo",
"sogo_profile_reset": "Réinitialiser le profil SOGo",
- "spam_alias": "Alias temporaire",
+ "spam_alias": "Alias temporaires",
"spam_policy": "Liste Noire/Liste Blanche",
"spam_score": "Score SPAM",
"syncjobs": "Tâches de synchronisation",
"tls_policy": "Politique TLS",
- "unlimited_quota": "Quota illimité pour les boites de courriel",
+ "unlimited_quota": "Quota illimité pour les boîtes de réception",
"domain_desc": "Modifier la description du domaine",
"domain_relayhost": "Changer le relais pour un domaine",
- "mailbox_relayhost": "Changer le relais d’une boîte de réception"
+ "mailbox_relayhost": "Changer le relais d’une boîte de réception",
+ "pw_reset": "Autoriser la réinitialisation du mot de passe de l'utilisateur"
},
"add": {
"activate_filter_warn": "Tous les autres filtres seront désactivés, quand activé est coché.",
@@ -42,20 +43,20 @@
"alias_domain_info": "<small>Seulement des noms de domaines valides (séparés par des virgules).</small>",
"app_name": "Nom de l'application",
"app_password": "Mot de passe de l'application",
- "automap": "Tenter de cibler automatiquement les dossiers (\"Sent items\", \"Sent\" => \"Sent\" etc.)",
+ "automap": "Tenter de cibler automatiquement les dossiers (« Sent items », « Sent » => « Sent » etc.)",
"backup_mx_options": "Options de MX secondaire",
"comment_info": "Un commentaire privé n'est pas visible pour l'utilisateur, tandis qu'un commentaire public est affiché sous forme d'info-bulle lorsqu'on le survole dans un aperçu des utilisateurs",
"custom_params": "Paramètres personnalisés",
- "custom_params_hint": "Correct : --param=xy, Incorrect : --param xy",
- "delete1": "Supprimer à la source lorsque la synchronisation terminée",
- "delete2": "Supprimer les messages à destination qui ne sont pas présents à la source",
- "delete2duplicates": "Supprimer les doubles à destination",
+ "custom_params_hint": "Correct : --param=xy, incorrect : --param xy",
+ "delete1": "Supprimer sur la source lorsque la synchronisation est terminée",
+ "delete2": "Supprimer les messages sur la destination qui ne sont pas présents sur la source",
+ "delete2duplicates": "Supprimer les doublons sur la destination",
"description": "Description",
"destination": "Destination",
- "disable_login": "Désactiver l'authentification (les mails entrants resteront acceptés)",
- "domain": "domaine",
+ "disable_login": "Désactiver l'authentification (les courriels entrants resteront acceptés)",
+ "domain": "Domaine",
"domain_matches_hostname": "Le domaine %s correspond à la machine (hostname)",
- "domain_quota_m": "Quota total du domaine (Mo)",
+ "domain_quota_m": "Quota total du domaine (Mio)",
"enc_method": "Méthode de chiffrement",
"exclude": "Exclure des objets (expression régulière - regex)",
"full_name": "Nom complet",
@@ -68,27 +69,27 @@
"hostname": "Nom d'hôte",
"inactive": "Inactif",
"kind": "Type",
- "mailbox_quota_def": "Quota boîte mail par défaut",
- "mailbox_quota_m": "Quota max par boîte (Mo)",
+ "mailbox_quota_def": "Quota boîte de réception par défaut",
+ "mailbox_quota_m": "Quota max par boîte de réception (Mio)",
"mailbox_username": "Identifiant (partie gauche d'une adresse de courriel)",
"max_aliases": "Nombre maximal d'alias",
- "max_mailboxes": "Nombre maximal de boîtes",
+ "max_mailboxes": "Nombre maximal de boîtes de réception",
"mins_interval": "Période de relève (minutes)",
"multiple_bookings": "Inscriptions multiples",
"nexthop": "Suivant",
"password": "Mot de passe",
"password_repeat": "Confirmation du mot de passe (répéter)",
"port": "Port",
- "post_domain_add": "le conteneur SOGo, \"sogo-mailcow\", doit être redémarré après l'ajout d'un nouveau domaine!<br><br>De plus, la configuration DNS doit être révisée. Lorsque la configuration DNS est approuvée, redémarrer \"acme-mailcow\" pour générer automatiquement les certificats pour votre nouveau domaine (autoconfig.<domain>, autodiscover.<domain>).<br>Cette étape est optionelle et sera réessayée toutes les 24 heures.",
+ "post_domain_add": "Le conteneur SOGo, « sogo-mailcow », doit être redémarré après l'ajout d'un nouveau domaine !<br><br>De plus, la configuration DNS doit être révisée. Lorsque la configuration DNS est approuvée, redémarrer « acme-mailcow » pour générer automatiquement les certificats pour votre nouveau domaine (autoconfig.<domain>, autodiscover.<domain>).<br>Cette étape est optionnelle et sera réessayée toutes les 24 heures.",
"private_comment": "Commentaire privé",
"public_comment": "Commentaire public",
- "quota_mb": "Quota (Mo)",
+ "quota_mb": "Quota (Mio)",
"relay_all": "Relayer tous les destinataires",
- "relay_all_info": "↪ Si vous choissisez <b>de ne pas</b> relayer tous les destinataires, vous devez ajouter une boîte (\"aveugle\") pour chaque destinataire simple qui doit être relayé.",
+ "relay_all_info": "↪ Si vous choisissez <b>de ne pas</b> relayer tous les destinataires, vous devez ajouter une boîte de réception (« aveugle ») pour chaque destinataire simple qui doit être relayé.",
"relay_domain": "Relayer ce domaine",
- "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> Vous pouvez définir des cartes de transport vers une destination personnalisée pour ce domaine. sinon, une recherche MX sera effectuée.",
- "relay_unknown_only": "Relayer uniquement les boîtes inexistantes. Les boîtes existantes seront livrées localement.",
- "relayhost_wrapped_tls_info": "Veuillez <b>ne pas</b> utiliser des ports TLS wrappés (généralement utilisés sur le port 465).<br>\r\nUtilisez n'importe quel port non encapsulé et lancez STARTTLS. Une politique TLS pour appliquer TLS peut être créée dans \"Cartes de politique TLS\".",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> Vous pouvez définir des cartes de transport vers une destination personnalisée pour ce domaine. Sinon, une recherche MX sera effectuée.",
+ "relay_unknown_only": "Relayer uniquement les boîtes de réception inexistantes. Les boîtes de réception existantes seront livrées localement.",
+ "relayhost_wrapped_tls_info": "Veuillez <b>ne pas</b> utiliser des ports TLS wrappés (généralement utilisés sur le port 465).<br>\nUtilisez n'importe quel port non encapsulé et lancez STARTTLS. Une politique TLS pour appliquer TLS peut être créée dans « Cartes de politique TLS ».",
"select": "Veuillez sélectionner…",
"select_domain": "Sélectionner d'abord un domaine",
"sieve_desc": "Description courte",
@@ -96,7 +97,7 @@
"skipcrossduplicates": "Ignorer les messages en double dans les dossiers (premier arrivé, premier servi)",
"subscribeall": "S'abonner à tous les dossiers",
"syncjob": "Ajouter une tâche de synchronisation",
- "syncjob_hint": "Sachez que les mots de passe seront sauvegardés en clair !",
+ "syncjob_hint": "Sachez que les mots de passe seront enregistrés en clair !",
"target_address": "Aller à l'adresse",
"target_address_info": "<small>Adresse(s) de courriel complète(s) (séparées par des virgules).</small>",
"target_domain": "Domaine cible",
@@ -105,10 +106,13 @@
"username": "Nom d'utilisateur",
"validate": "Valider",
"validation_success": "Validation réussie",
- "bcc_dest_format": "La destination Cci doit être une seule adresse e-mail valide.<br>Si vous avez besoin d'envoyer une copie à plusieurs adresses, créez un alias et utilisez-le ici.",
+ "bcc_dest_format": "La destination Cci doit être une seule adresse de courriel valide.<br>Si vous avez besoin d'envoyer une copie à plusieurs adresses, créez un alias et utilisez-le ici.",
"tags": "Etiquettes",
"app_passwd_protocols": "Protocoles autorisés pour le mot de passe de l'application",
- "dry": "Simuler la synchronisation"
+ "dry": "Simuler la synchronisation",
+ "internal": "Interne",
+ "internal_info": "Les alias internes sont accessibles uniquement depuis le domaine ou les alias du domaine.",
+ "sender_allowed": "Autoriser l'envoi sous cet alias"
},
"admin": {
"access": "Accès",
@@ -138,15 +142,15 @@
"api_skip_ip_check": "Passer la vérification d'IP pour l'API",
"app_links": "Liens des applications",
"app_name": "Nom de l'application",
- "apps_name": "\"mailcow Apps\" nom",
+ "apps_name": "Nom « mailcow Apps »",
"arrival_time": "Heure d'arrivée (heure du serveur)",
"authed_user": "Utilisateur autorisé",
"ays": "Voulez-vous vraiment le faire ?",
- "ban_list_info": "Consultez la liste des adresses IP bannies ci-dessous : <b>réseau (durée de bannissement restante) - [actions]</b>.<br />Les adresses IP mises en file d'attente pour être dé-bannies seront supprimées de la liste de bannissement dans quelques secondes.<br />Les étiquettes rouges indiquent les bannissement permanent par liste noire.",
+ "ban_list_info": "Consultez la liste des adresses IP bannies ci-dessous : <b>réseau (durée de bannissement restante) - [actions]</b>.<br />Les adresses IP mises en file d'attente pour être dé-bannies seront supprimées de la liste de bannissement dans quelques secondes.<br />Les étiquettes rouges indiquent les bannissements permanent par liste noire.",
"change_logo": "Changer de logo",
"configuration": "Configuration",
"convert_html_to_text": "Convertir le code HTML en texte brut",
- "credentials_transport_warning": "<b>Attention</b> : L’ajout d’une nouvelle entrée de carte de transport mettra à jour les informations d’identification pour toutes les entrées avec une colonne nexthop.",
+ "credentials_transport_warning": "<b>Attention</b> : L’ajout d’une nouvelle entrée de carte de transport mettra à jour les informations d’identification pour toutes les entrées avec une colonne nexthop.",
"customer_id": "ID client",
"customize": "Personnaliser",
"destination": "Destination",
@@ -170,7 +174,7 @@
"domain_s": "Domaine(s)",
"duplicate": "Dupliquer",
"duplicate_dkim": "Dupliquer l'enregistrement DKIM",
- "edit": "Editer",
+ "edit": "Éditer",
"empty": "Aucun résultat",
"excludes": "Exclure ces destinataires",
"f2b_ban_time": "Durée du bannissement (s)",
@@ -183,7 +187,7 @@
"f2b_netban_ipv4": "Taille du sous-réseau IPv4 pour l'application du bannissement (8-32)",
"f2b_netban_ipv6": "Taille du sous-réseau IPv6 pour l'application du bannissement (8-128)",
"f2b_parameters": "Paramètres Fail2ban",
- "f2b_regex_info": "Logs pris en compte : SOGo, Postfix, Dovecot, PHP-FPM.",
+ "f2b_regex_info": "Logs pris en compte : SOGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Fenêtre de nouvel essai pour le nb max. de tentatives",
"f2b_whitelist": "Réseaux/hôtes en liste blanche",
"filter_table": "Table de filtrage",
@@ -194,24 +198,24 @@
"generate": "générer",
"guid": "GUID - Identifiant de l'instance",
"guid_and_license": "GUID & Licence",
- "hash_remove_info": "La suppression d'un hachage ratelimit (s'il existe toujours) réinitialisera complètement son compteur.<br>\r\n Chaque hachage est indiqué par une couleur individuelle.",
+ "hash_remove_info": "La suppression d'un hachage limite d'envoi (s'il existe toujours) réinitialisera complètement son compteur.<br>\n Chaque hachage est indiqué par une couleur individuelle.",
"help_text": "Remplacer le texte d'aide sous le masque de connexion (HTML autorisé)",
"host": "Hôte",
"html": "HTML",
"import": "Importer",
- "import_private_key": "Importer la clè privée",
+ "import_private_key": "Importer la clé privée",
"in_use_by": "Utilisé par",
"inactive": "Inactif",
"include_exclude": "Inclure/Exclure",
- "include_exclude_info": "Par défaut - sans sélection - <b>toutes les boîtes</b> sont adressées",
+ "include_exclude_info": "Par défaut - sans sélection - <b>toutes les boîte de réception</b> sont adressées",
"includes": "Inclure ces destinataires",
"last_applied": "Dernière application",
- "license_info": "Une licence n’est pas requise, mais contribue au développement.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Enregistrer votre GUID ici</a> or <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Support order\">acheter le support pour votre intallation Mailcow.</a>",
+ "license_info": "Une licence n’est pas requise, mais contribue au développement.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Enregistrer votre GUID ici</a> ou <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Support order\">acheter le support pour votre installation mailcow.</a>",
"link": "Lien",
"loading": "Veuillez patienter…",
"logo_info": "Votre image sera redimensionnée à une hauteur de 40 pixels pour la barre de navigation du haut et à un maximum de 250 pixels en largeur pour la page d'accueil. Un graphique extensible est fortement recommandé.",
"lookup_mx": "Faire correspondre la destination à MX (<code>.*\\.google\\.com</code> pour acheminer tous les messages ciblés vers un MX se terminant par google.com sur ce tronçon)",
- "main_name": "\"mailcow UI\" nom",
+ "main_name": "Nom « mailcow UI »",
"merged_vars_hint": "Les lignes grisées ont été importées depuis <code>vars.(local.)inc.php</code> et ne peuvent pas être modifiées.",
"message": "Message",
"message_size": "Taille du message",
@@ -222,7 +226,7 @@
"no_record": "Aucun enregistrement",
"oauth2_client_id": "Client ID",
"oauth2_client_secret": "Secret client",
- "oauth2_info": "L'implémentation OAuth2 prend en charge le type d'autorisation \"Authorization Code\" et émet des jetons d'actualisation.<br>\nLe serveur émet également automatiquement de nouveaux jetons d'actualisation, après qu'un jeton d'actualisation a été utilisé.<br><br>\n→ La portée par défaut est <i>profile</i>. Seuls les utilisateurs d'une boîte peuvent être authentifiés par rapport à OAuth2. Si le paramètre scope est omis, il revient au <i>profile</i>.<br>\n→ Le paramètre <i>state</i> doit être envoyé par le client dans le cadre de la demande d'autorisation.<br><br>\nChemins d'accès aux requêtes vers l'API OAuth <br>\n<ul>\n <li>Point de terminaison d'autorisation : <code>/oauth/authorize</code></li>\n <li>Point de terminaison du jeton : <code>/oauth/token</code></li>\n <li>Page de ressource : <code>/oauth/profile</code></li>\n</ul>\nLa régénération du secret client ne fera pas expirer les codes d'autorisation existants, mais ils ne pourront pas renouveler leur jeton.<br><br>\nLa révocation des jetons clients entraînera la fin immédiate de toutes les sessions actives. Tous les clients doivent se ré-authentifier.",
+ "oauth2_info": "L'implémentation OAuth2 prend en charge le type d'autorisation « Authorization Code » et émet des jetons d'actualisation.<br>\nLe serveur émet également automatiquement de nouveaux jetons d'actualisation, après qu'un jeton d'actualisation a été utilisé.<br><br>\n→ La portée par défaut est <i>profile</i>. Seuls les utilisateurs d'une boîte de réception peuvent être authentifiés par rapport à OAuth2. Si le paramètre scope est omis, il revient au <i>profile</i>.<br>\n→ Le paramètre <i>state</i> doit être envoyé par le client dans le cadre de la demande d'autorisation.<br><br>\nChemins d'accès aux requêtes vers l'API OAuth <br>\n<ul>\n <li>Point de terminaison d'autorisation : <code>/oauth/authorize</code></li>\n <li>Point de terminaison du jeton : <code>/oauth/token</code></li>\n <li>Page de ressource : <code>/oauth/profile</code></li>\n</ul>\nLa régénération du secret client ne fera pas expirer les codes d'autorisation existants, mais ils ne pourront pas renouveler leur jeton.<br><br>\nLa révocation des jetons clients entraînera la fin immédiate de toutes les sessions actives. Tous les clients doivent se ré-authentifier.",
"oauth2_redirect_uri": "URI de redirection",
"oauth2_renew_secret": "Générer un nouveau secret client",
"oauth2_revoke_tokens": "Révoquer tous les jetons",
@@ -232,29 +236,29 @@
"priority": "Priorité",
"private_key": "Clé privée",
"quarantine": "Quarantaine",
- "quarantine_bcc": "Envoyer une copie de toutes les notifications (BCC) à ce destinataire:<br><small>Laisser vide pour le désactiver. <b>Courrier non signé et non coché. Doit être livré en l’interne seulement.</b></small>",
+ "quarantine_bcc": "Envoyer une copie de toutes les notifications (BCC) à ce destinataire :<br><small>Laisser vide pour le désactiver. <b>Courrier non signé et non coché. Doit être livré en interne seulement.</b></small>",
"quarantine_exclude_domains": "Exclure les domaines et les alias de domaine",
"quarantine_max_age": "Âge maximun en jour(s)<br><small>La valeur doit être égale ou supérieure à 1 jour.</small>",
- "quarantine_max_size": "Taille maximum en Mo (les éléments plus grands sont mis au rebut):<br><small>0 ne signifie <b>pas</b> illimité.</small>",
- "quarantine_max_score": "Ignorer la notification si le score de spam est au dessus de cette valeur :<br><small>Par défaut : 9999.0</small>",
- "quarantine_notification_html": "Modèle de courriel de notification:<br><small>Laisser vide pour restaurer le modèle par défaut.</small>",
- "quarantine_notification_sender": "Notification par e-mail de l’expéditeur",
+ "quarantine_max_size": "Taille maximum en Mio (les éléments plus grands sont mis au rebut) :<br><small>0 ne signifie <b>pas</b> illimité.</small>",
+ "quarantine_max_score": "Ignorer la notification si le score de spam est au dessus de cette valeur :<br><small>Par défaut : 9999.0</small>",
+ "quarantine_notification_html": "Modèle de courriel de notification :<br><small>Laisser vide pour restaurer le modèle par défaut.</small>",
+ "quarantine_notification_sender": "Notification par courriel de l’expéditeur",
"quarantine_notification_subject": "Objet du courriel de notification",
- "quarantine_redirect": "<b>Rediriger toutes les notifications</b> vers ce destinataire:<br><small>Laisser vide pour désactiver. <b>Courrier non signé et non coché. Doit être livré en interne seulement.</b></small>",
+ "quarantine_redirect": "<b>Rediriger toutes les notifications</b> vers ce destinataire :<br><small>Laisser vide pour désactiver. <b>Courrier non signé et non coché. Doit être livré en interne seulement.</b></small>",
"quarantine_release_format": "Format des éléments diffusés",
"quarantine_release_format_att": "En pièce jointe",
"quarantine_release_format_raw": "Original non modifié",
- "quarantine_retention_size": "Rétentions par boîte:<br><small>0 indique <b>inactive</b>.</small>",
- "quota_notification_html": "Modèle de courriel de notification:<br><small>Laisser vide pour restaurer le modèle par défaut.</small>",
- "quota_notification_sender": "Notification par e-mail de l’expéditeur",
+ "quarantine_retention_size": "Rétentions par boîte de réception :<br><small>0 indique <b>inactive</b>.</small>",
+ "quota_notification_html": "Modèle de courriel de notification :<br><small>Laisser vide pour restaurer le modèle par défaut.</small>",
+ "quota_notification_sender": "Notification par courriel de l’expéditeur",
"quota_notification_subject": "Objet du courriel de notification",
"quota_notifications": "Notifications de quotas",
"quota_notifications_info": "Les notications de quota sont envoyées aux utilisateurs une fois lors du passage à 80 % et une fois lors du passage à 95 % d’utilisation.",
- "quota_notifications_vars": "{{percent}} égale le quota actuel de l’utilisateur<br>{{username}} est le nom de la boîte",
+ "quota_notifications_vars": "{{percent}} égale le quota actuel de l’utilisateur<br>{{username}} est le nom de la boîte de réception",
"r_active": "Restrictions actives",
"r_inactive": "Restrictions inactives",
"r_info": "Les éléments grisés/désactivés sur la liste des restrictions actives ne sont pas considérés comme des restrictions valides pour Mailcow et ne peuvent pas être déplacés. Des restrictions inconnues seront établies par ordre d’apparition de toute façon. <br>Vous pouvez ajouter de nouveaux éléments dans le code <code>inc/vars.local.inc.php</code> pour pouvoir les basculer.",
- "rate_name": "Nom du taux",
+ "rate_name": "Nom de la limite",
"recipients": "Destinataires",
"refresh": "Rafraîchir",
"regen_api_key": "Regénérer la clé API",
@@ -262,7 +266,7 @@
"relay_from": "\"De:\" adresse",
"relay_run": "Lancer le test",
"relayhosts": "Transports dépendant de l’expéditeur",
- "relayhosts_hint": "Définir les transports dépendant de l’expéditeur pour pouvoir les sélectionner dans un dialogue de configuration de domaines.<br>\n Le service de transport est toujours \"SMTP:\" et va donc essayer TLS lorsqu’il est proposé. Le TLS encapsulé (SMTPS) n’est pas pris en charge. Il est tenu compte de la définition de la politique TLS pour chaque utilisateur sortant.<br>\n Affecte les domaines sélectionnés, y compris les domaines alias.",
+ "relayhosts_hint": "Définir les transports dépendant de l’expéditeur pour pouvoir les sélectionner dans un dialogue de configuration de domaines.<br>\n Le service de transport est toujours « smtp: » et va donc essayer TLS lorsqu’il est proposé. Le TLS encapsulé (SMTPS) n’est pas pris en charge. Il est tenu compte de la définition de la politique TLS pour chaque utilisateur sortant.<br>\n Affecte les domaines sélectionnés, y compris les domaines alias.",
"remove": "Supprimer",
"remove_row": "Supprimer la ligne",
"reset_default": "Réinitialisation à la valeur par défaut",
@@ -273,10 +277,10 @@
"rsetting_desc": "Description courte",
"rsetting_no_selection": "Veuillez sélectionner une règle",
"rsetting_none": "Pas de règles disponibles",
- "rsettings_insert_preset": "Insérer un exemple de préréglage \"%s\"",
- "rsettings_preset_1": "Désactiver tout sauf DKIM et la limite tarifaire pour les utilisateurs authentifiés",
+ "rsettings_insert_preset": "Insérer un exemple de préréglage « %s »",
+ "rsettings_preset_1": "Désactiver tout sauf DKIM et la limite d'envoi pour les utilisateurs authentifiés",
"rsettings_preset_2": "Les postmasters veulent du spam",
- "rsettings_preset_3": "Autoriser uniquement des expéditeurs particuliers pour une boîte (c.-à-d. utilisation comme boîte interne seulement)",
+ "rsettings_preset_3": "Autoriser uniquement des expéditeurs particuliers pour une boîte de réception (c.-à-d. utilisation comme boîte de réception interne seulement)",
"rspamd_com_settings": "Un nom de paramètre sera généré automatiquement, voir l’exemple de préréglages ci-dessous. Pour plus de détails voir : <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Docs Rspamd</a>",
"rspamd_global_filters": "Cartes des filtres globaux",
"rspamd_global_filters_agree": "Je serai prudent !",
@@ -285,7 +289,7 @@
"rspamd_settings_map": "Carte des paramètres Rspamd",
"sal_level": "Niveau Moo",
"save": "Enregistrer les modifications",
- "search_domain_da": "Recherche domaines",
+ "search_domain_da": "Rechercher des domaines",
"send": "Envoyer",
"sender": "Expéditeur",
"service_id": "ID du service",
@@ -296,11 +300,11 @@
"text": "Texte",
"time": "Heure",
"title": "Titre",
- "title_name": "\"mailcow UI\" titre du site web",
+ "title_name": "Titre du site web « mailcow UI »",
"to_top": "Retour en haut",
"transport_dest_format": "Syntaxe : example.org, .example.org, *, box@example.org (les valeurs multiples peuvent être séparées par des virgules)",
"transport_maps": "Plans de transport",
- "transports_hint": "→ Une entrée de carte de transport <b>annule</b> une carte de transport dépendante de l’expéditeur</b>.<br>\n→ Les transports basés sur le MX sont préférables.<br>\n→ Les paramètres de politique TLS sortants par utilisateur sont ignorés et ne peuvent être appliqués que par les entrées de carte de politique TLS.<br>\n→ Pour chaque transports défini, le servie de transports sera \"smtp:\", TLS sera essayé lorsque disponible. Le Wrapped TLS (SMTPS) n’est pas pris en charge.<br>\n→ Les adresses qui correspondent à\"/localhost$/\" seront toujours transportées via \"local:\", donc une destination \"*\" ne s'applique pas à ces adresses.<br>\n→ Pour déterminer les informations d'identification dans l'exemple suivant \"[host]:25\", Postfix va <b>toujours</b> faire une requête pour \"host\" avant de chercher \"[host]:25\". Ce comportement rend impossible l’utilisation \"host\" et \"[host]:25\" en même temps.",
+ "transports_hint": "→ Une entrée de carte de transport <b>annule</b> une carte de transport dépendante de l’expéditeur</b>.<br>\n→ Les transports basés sur le MX sont préférables.<br>\n→ Les paramètres de politique TLS sortants par utilisateur sont ignorés et ne peuvent être appliqués que par les entrées de carte de politique TLS.<br>\n→ Pour chaque transports défini, le servie de transports sera « smtp: », TLS sera essayé lorsque disponible. Le Wrapped TLS (SMTPS) n’est pas pris en charge.<br>\n→ Les adresses qui correspondent à « /localhost$/ » seront toujours transportées via « local: », donc une destination « * » ne s'applique pas à ces adresses.<br>\n→ Pour déterminer les informations d'identification dans l'exemple suivant « [host]:25 », Postfix va <b>toujours</b> faire une requête pour « host » avant de chercher « [host]:25 ». Ce comportement rend impossible l’utilisation de « host » et « [host]:25 » en même temps.",
"ui_footer": "Pied de page (HTML autorisé)",
"ui_header_announcement": "Annonces",
"ui_header_announcement_active": "Définir l’annonce active",
@@ -312,7 +316,7 @@
"ui_header_announcement_type_warning": "Important",
"ui_header_announcement_type_danger": "Très important",
"ui_texts": "Textes et étiquettes de l'interface utilisateur",
- "unban_pending": "unban en attente",
+ "unban_pending": "Débanissement en attente",
"unchanged_if_empty": "Si non modifié, laisser en blanc",
"upload": "Charger",
"username": "Nom d'utilisateur",
@@ -338,7 +342,77 @@
"oauth2_apps": "Applications OAuth2",
"password_length": "Longueur des mots de passe",
"password_policy_chars": "Doit contenir au moins une lettre",
- "password_policy_length": "La longueur minimale du mot de passe est de %d"
+ "password_policy_length": "La longueur minimale du mot de passe est de %d",
+ "f2b_manage_external_info": "Fail2ban maintiendra la liste de bannissement, mais ne définira pas activement de règles pour bloquer le trafic. Utilisez la liste de bannissement générée ci-dessous pour bloquer le trafic de manière externe.",
+ "f2b_manage_external": "Gérer Fail2Ban en externe",
+ "transport_test_rcpt_info": "• ; Utilisez null@hosted.mailcow.de pour tester le relais vers une destination étrangère.",
+ "relay_rcpt": "Adresse \"À :\"",
+ "is_mx_based": "Basé sur MX",
+ "password_reset_info": "Si aucune adresse de messagerie de récupération n'est fournie, cette fonction ne peut pas être utilisée.",
+ "password_settings": "Paramètres des mots de passe",
+ "reset_password_vars": "<code>{{link}}</code> Le lien généré pour la réinitialisation du mot de passe<br><code>{{username}}</code> L'adresse de la boîte mail de l'utilisateur qui a demandé la réinitialisation du mot de passe ayant un compte mailcow<br><code>{{username2}}</code> L'adresse de la boîte mail de récupération<br><code>{{date}}</code> La date à laquelle la demande de réinitialisation du mot de passe a été faite<br><code>{{token_lifetime}}</code> La durée de vie du jeton en minutes<br><code>{{hostname}}</code> Le nom d'hôte de votre serveur mailcow",
+ "password_reset_settings": "Paramètres de récupération des mots de passe",
+ "password_reset_tmpl_html": "Modèle HTML",
+ "password_reset_tmpl_text": "Modèle en texte",
+ "restore_template": "Laisser vide pour restaurer le modèle par défaut.",
+ "admins_ldap": "Administrateurs LDAP",
+ "options": "Options",
+ "ip_check_opt_in": "Utiliser le service tiers <strong>ipv4.mailcow.email</strong> et <strong>ipv6.mailcow.email</strong> pour résoudre les adresses IP externes.",
+ "queue_unban": "débannir",
+ "service": "Service",
+ "success": "Succès",
+ "cors_settings": "Paramètres CORS",
+ "login_time": "Horodatage de connexion",
+ "domainadmin_quicklink": "Masquer le lien rapide vers la page de connexion de l'administrateur du domaine",
+ "force_sso_text": "Si un fournisseur OIDC externe est configuré, cette option masque les formulaires de connexion par défaut de mailcow et n'affiche que le bouton Singe Sign-On",
+ "app_hide": "Masquer pour la connexion",
+ "admin_quicklink": "Masquer le lien rapide vers la page de connexion de l'administrateur",
+ "login_page": "Page de connexion",
+ "force_sso": "Désactiver la connexion mailcow et n'afficher que Singe Sign-On",
+ "iam_attribute_field": "Champ d'attribut",
+ "iam_authorize_url": "Endpoint d'autorisation",
+ "iam_auth_flow": "Flow d'authentification",
+ "iam_auth_flow_info": "Outre le flux de code d'autorisation (flux standard dans Keycloak), qui est utilisé pour la connexion unique, mailcow prend également en charge le flux d'authentification avec des informations d'identification directes. Le flux Mailpassword tente de valider les informations d'identification de l'utilisateur en utilisant l'API REST de Keycloak Admin. mailcow récupère le mot de passe haché dans l'attribut <code>mailcow_password</code>, qui est mappé dans Keycloak.",
+ "iam_basedn": "Base DN",
+ "iam_client_id": "ID Client",
+ "iam_client_secret": "Secret Client",
+ "iam_use_ssl": "Utiliser SSL",
+ "iam_redirect_url": "Url de redirection",
+ "iam_use_ssl_info": "Si le protocole SSL est activé et que le port est défini sur 389, il sera automatiquement remplacé par 636.",
+ "iam_use_tls_info": "Si vous activez TLS, vous devez utiliser le port par défaut de votre serveur LDAP (389). Les ports SSL ne peuvent pas être utilisés.",
+ "iam_version": "Version",
+ "ignore_ssl_error": "Ignorer les erreurs SSL",
+ "iam_login_provisioning": "Créer automatiquement l'utilisateur à la connexion",
+ "iam_mapping": "Mapping des attributs",
+ "iam_bindpass": "Lier le mot de passe",
+ "iam_periodic_full_sync": "Synchronisation complète périodique",
+ "iam_port": "Port",
+ "iam_realm": "Realm",
+ "iam_rest_flow": "Flow Mailpassword",
+ "iam_server_url": "URL du serveur",
+ "iam_sso": "Single Sign-On",
+ "iam_sync_interval": "Interval de Sync / Import (min)",
+ "iam_test_connection": "Test de connexion",
+ "iam_token_url": "Endpoint Token",
+ "iam_userinfo_url": "Endpoint User info",
+ "iam_username_field": "Champ du nom d'utilisateur",
+ "iam_binddn": "Bind DN",
+ "iam_use_tls": "Utiliser StartTLS",
+ "quicklink_text": "Afficher ou masquer les liens rapides vers d'autres pages de connexion sous le formulaire de connexion",
+ "task": "Tâche",
+ "user_link": "Lien utilisateur",
+ "user_quicklink": "Masquer le lien rapide vers la page de connexion de l'utilisateur",
+ "iam_client_scopes": "Scopes Client",
+ "iam_default_template": "Template par défaut",
+ "iam_default_template_description": "Si aucun modèle n'est attribué à un utilisateur, le modèle par défaut sera utilisé pour créer la boîte aux lettres, mais pas pour la mettre à jour.",
+ "iam_description": "Configurer un fournisseur externe pour l'authentification<br>Les boîtes aux lettres des utilisateurs seront automatiquement créées lors de leur première connexion, à condition qu'un mappage d'attributs ait été défini.",
+ "iam_extra_permission": "Pour que les paramètres suivants fonctionnent, le client mailcow dans Keycloak a besoin d'un <code>Compte de service</code> et de l'autorisation de <code>voir les utilisateurs</code>.",
+ "iam_host": "Hôte",
+ "iam_host_info": "Saisissez un ou plusieurs hôtes LDAP, séparés par des virgules.",
+ "iam_import_users": "Importer des utilisateurs",
+ "filter": "Filtrer",
+ "needs_restart": "nécessite un redémarrage",
+ "iam": "Fournisseur d'identité"
},
"danger": {
"access_denied": "Accès refusé ou données de formulaire non valides",
@@ -352,62 +426,62 @@
"app_passwd_id_invalid": "Le mot de passe ID %s de l'application est non valide",
"bcc_empty": "La destination BCC destination ne peut pas être vide",
"bcc_exists": "Une carte de transport BCC %s existe pour le type %s",
- "bcc_must_be_email": "Le destination BCC %s n'est pas une adresse mail valide",
+ "bcc_must_be_email": "La destination BCC %s n'est pas une adresse de courriel valide",
"comment_too_long": "Le commentaire est trop long, 160 caractère max sont permis",
- "defquota_empty": "Le quota par défaut par boîte ne doit pas être 0.",
+ "defquota_empty": "Le quota par défaut par boîte de réception doit pas être 0.",
"description_invalid": "La description des ressources pour %s est non valide",
- "dkim_domain_or_sel_exists": "Une clé DKIM pour \"%s\" existe et ne sera pas écrasée",
- "dkim_domain_or_sel_invalid": "Domaine ou sélection DKIM non valide : %s",
+ "dkim_domain_or_sel_exists": "Une clé DKIM pour « %s » existe et ne sera pas écrasée",
+ "dkim_domain_or_sel_invalid": "Domaine ou sélecteur DKIM non valide : %s",
"domain_cannot_match_hostname": "Le domaine ne correspond pas au nom d’hôte",
"domain_exists": "Le domaine %s exite déjà",
- "domain_invalid": "Le mom de domaine est vide ou non valide",
+ "domain_invalid": "Le nom de domaine est vide ou non valide",
"domain_not_empty": "Impossible de supprimer le domaine non vide %s",
"domain_not_found": "Le domaine %s est introuvable",
- "domain_quota_m_in_use": "Le quota de domaine doit être supérieur ou égal à %s Mo",
- "extra_acl_invalid": "L'adresse de l’expéditeur externe \"%s\" est non valide",
- "extra_acl_invalid_domain": "L'expéditeur externe \"%s\" utilise un domaine non valide",
+ "domain_quota_m_in_use": "Le quota de domaine doit être supérieur ou égal à %s Mio",
+ "extra_acl_invalid": "L'adresse de l’expéditeur externe « %s » est non valide",
+ "extra_acl_invalid_domain": "L'expéditeur externe « %s » utilise un domaine non valide",
"file_open_error": "Le fichier ne peut pas être ouvert pour l'écriture",
"filter_type": "Type de fltre erroné",
"from_invalid": "Expéditeur ne peut pas être vide",
- "global_filter_write_error": "Impossible d’écrire le fichier de filtre : %s",
+ "global_filter_write_error": "Impossible d’écrire le fichier de filtre : %s",
"global_map_invalid": "ID de carte globale %s non valide",
- "global_map_write_error": "Impossible d’écrire l’ID de la carte globale %s : %s",
- "goto_empty": "Une adresse alias doit contenir au moins une adresse 'goto'valide",
+ "global_map_write_error": "Impossible d’écrire l’ID de la carte globale %s : %s",
+ "goto_empty": "Une adresse alias doit contenir au moins une adresse 'goto' valide",
"goto_invalid": "Adresse Goto %s non valide",
- "ham_learn_error": "Erreur d'apprentissage Ham : %s",
- "imagick_exception": "Erreur : Exception Imagick lors de la lecture de l’image",
+ "ham_learn_error": "Erreur d'apprentissage Ham : %s",
+ "imagick_exception": "Erreur : Exception Imagick lors de la lecture de l’image",
"img_invalid": "Impossible de valider le fichier image",
- "img_tmp_missing": "Impossible de valider le fichier image : Fichier temporaire introuvable",
+ "img_tmp_missing": "Impossible de valider le fichier image : Fichier temporaire introuvable",
"invalid_bcc_map_type": "Type de carte BCC non valide",
- "invalid_destination": "Le format de la destination \"%s\" est non valide",
+ "invalid_destination": "Le format de la destination « %s » est non valide",
"invalid_filter_type": "Type de filtre non valide",
- "invalid_host": "Hôte non valide spécifié : %s",
+ "invalid_host": "Hôte non valide spécifié : %s",
"invalid_mime_type": "Type mime non valide",
"invalid_nexthop": "Le format de saut suivant est non valide",
"invalid_nexthop_authenticated": "Next hop existe avec différents identifiants, veuillez d’abord mettre à jour les identifiants existants pour ce prochain saut.",
- "invalid_recipient_map_new": "Nouveau destinataire spécifié non valide : %s",
- "invalid_recipient_map_old": "Destinataire original spécifié non valide : %s",
+ "invalid_recipient_map_new": "Nouveau destinataire spécifié non valide : %s",
+ "invalid_recipient_map_old": "Destinataire original spécifié non valide : %s",
"ip_list_empty": "La liste des adresses IP autorisées ne peut pas être vide",
"is_alias": "%s est déjà connu comme une adresse alias",
- "is_alias_or_mailbox": "%s est déjà connu comme un alias, une boîte ou une adresse alias développée à partir d’un domaine alias.",
+ "is_alias_or_mailbox": "%s est déjà connu comme un alias, une boîte de réception ou une adresse alias développée à partir d’un domaine alias.",
"is_spam_alias": "%s est déjà connu comme une adresse alias temporaire (alias d'adresse spam)",
"last_key": "La dernière clé ne peut pas être supprimée, veuillez désactiver TFA à la place.",
"login_failed": "La connexion a échoué",
"mailbox_defquota_exceeds_mailbox_maxquota": "Le quota par défaut dépasse la limite maximale du quota",
- "mailbox_invalid": "Le nom de la boîte n'est pas valide",
- "mailbox_quota_exceeded": "Le quota dépasse la limite du domaine (max. %d Mo)",
- "mailbox_quota_exceeds_domain_quota": "Le quota maximum dépasse la limite du quota de domaine",
- "mailbox_quota_left_exceeded": "Espace libre insuffisant (espace libre : %d Mio)",
- "mailboxes_in_use": "Le max. des boîtes doit être supérieur ou égal à %d",
+ "mailbox_invalid": "Le nom de la boîte de réception n'est pas valide",
+ "mailbox_quota_exceeded": "Le quota dépasse la limite du domaine (max. %d Mio)",
+ "mailbox_quota_exceeds_domain_quota": "Le quota maximal dépasse la limite du quota de domaine",
+ "mailbox_quota_left_exceeded": "Espace libre insuffisant (espace libre : %d Mio)",
+ "mailboxes_in_use": "Le max. des boîtes de réception doit être supérieur ou égal à %d",
"malformed_username": "Nom d’utilisateur malformé",
"map_content_empty": "Le contenu de la carte ne peut pas être vide",
- "max_alias_exceeded": "Le nombre max. d'aliases est dépassé",
- "max_mailbox_exceeded": "Le nombre max. de boîte est dépassé (%d of %d)",
- "max_quota_in_use": "Le quota de la boîte doit être supérieur ou égal à %d Mo",
- "maxquota_empty": "Le quota maximum par boîte ne doit pas être de 0.",
- "mysql_error": "Erreur MySQL : %s",
- "nginx_reload_failed": "Le rechargement de Nginx a échoué : %s",
- "network_host_invalid": "Réseau ou hôte non valide : %s",
+ "max_alias_exceeded": "Le nombre max. d'alias est dépassé",
+ "max_mailbox_exceeded": "Le nombre max. de boîte de réception est dépassé (%d of %d)",
+ "max_quota_in_use": "Le quota de la boîte de réception doit être supérieur ou égal à %d Mio",
+ "maxquota_empty": "Le quota maximum par boîte de réception ne doit pas être de 0.",
+ "mysql_error": "Erreur MySQL : %s",
+ "nginx_reload_failed": "Le rechargement de Nginx a échoué : %s",
+ "network_host_invalid": "Réseau ou hôte non valide : %s",
"next_hop_interferes": "%s interfère avec le nexthop %s",
"next_hop_interferes_any": "Un saut suivant existant interfère avec %s",
"no_user_defined": "Aucun utilisateur défini",
@@ -418,26 +492,26 @@
"password_mismatch": "Le mot de passe de confirmation ne correspond pas",
"policy_list_from_exists": "Un enregistrement avec ce nom existe déjà",
"policy_list_from_invalid": "Le format de l’enregistrement est invalide",
- "private_key_error": "Erreur de clé privée : %s",
+ "private_key_error": "Erreur de clé privée : %s",
"pushover_credentials_missing": "Jeton Pushover ou clé manquante",
"pushover_key": "La clé Pushover a un mauvais format",
"pushover_token": "Le jeton Pushover a un mauvais format",
"quota_not_0_not_numeric": "Le quota doit être numerique et >= 0",
- "recipient_map_entry_exists": "Une entrée dans la carte du bénéficiaire \"%s\" existe",
- "redis_error": "Erreur Redis : %s",
+ "recipient_map_entry_exists": "Une entrée dans la carte du destinataire « %s » existe",
+ "redis_error": "Erreur Redis : %s",
"relayhost_invalid": "La saisie de la carte %s est invalide",
- "release_send_failed": "Le message n’a pas pu être diffusé : %s",
+ "release_send_failed": "Le message n’a pas pu être diffusé : %s",
"reset_f2b_regex": "Le filtre regex n'a pas pu être réinitialisé à temps, veuillez réessayer ou attendre quelques secondes de plus et recharger le site web.",
"resource_invalid": "Le nom de la resource %s n'est pas valide",
- "rl_timeframe": "Le délai limite du taux est incorrect",
- "rspamd_ui_pw_length": "Le mot de passe de l'interface Rspamd doit être de 6 caratères au minimum",
+ "rl_timeframe": "Le délai de la limite d'envoi est incorrect",
+ "rspamd_ui_pw_length": "Le mot de passe de l'interface Rspamd doit être de 6 caractères au minimum",
"script_empty": "Le script ne peut pas être vide",
"sender_acl_invalid": "La valeur ACL de l’expéditeur %s est invalide",
- "set_acl_failed": "Impossible de définir ACL",
+ "set_acl_failed": "Impossible de définir l'ACL",
"settings_map_invalid": "La carte des paramètres %s est invalide",
- "sieve_error": "Erreur d'analyse syntaxique Sieve : %s",
- "spam_learn_error": "Erreur d'apprentissage du spam : %s",
- "subject_empty": "Le sujet ne peut^pas être vide",
+ "sieve_error": "Erreur d'analyse syntaxique Sieve : %s",
+ "spam_learn_error": "Erreur d'apprentissage du spam : %s",
+ "subject_empty": "Le sujet ne peut pas être vide",
"target_domain_invalid": "Le domaine cible %s n'est pas valide",
"targetd_not_found": "Le domaine cible %s est introuvable",
"targetd_relay_domain": "Le domaine cible %s est un domaine de relais",
@@ -445,49 +519,85 @@
"text_empty": "La zone texte ne peut pas être vide",
"tfa_token_invalid": "Le token TFA est invalide",
"tls_policy_map_dest_invalid": "La politique de destination n'est pas valide",
- "tls_policy_map_entry_exists": "Une entrée de carte de politique \"%s\" existe",
+ "tls_policy_map_entry_exists": "Une entrée de carte de politique « %s » existe",
"tls_policy_map_parameter_invalid": "Le paramètre Policy est invalide",
"totp_verification_failed": "Echec de la vérification TOTP",
- "transport_dest_exists": "La destination de transport \"%s\" existe",
- "webauthn_verification_failed": "Echec de la vérification WebAuthn : %s",
- "fido2_verification_failed": "La vérification FIDO2 a échoué : %s",
+ "transport_dest_exists": "La destination de transport « %s » existe",
+ "webauthn_verification_failed": "Échec de la vérification WebAuthn : %s",
+ "fido2_verification_failed": "La vérification FIDO2 a échoué : %s",
"unknown": "Une erreur inconnue est survenue",
"unknown_tfa_method": "Methode TFA inconnue",
"unlimited_quota_acl": "Quota illimité interdit par les ACL",
"username_invalid": "Le nom d'utilisateur %s ne peut pas être utilisé",
"validity_missing": "Veuillez attribuer une période de validité",
"value_missing": "Veuillez fournir toutes les valeurs",
- "yotp_verification_failed": "La vérification Yubico OTP a échoué : %s",
- "webauthn_authenticator_failed": "L'authentificateur selectionné est introuvable",
+ "yotp_verification_failed": "La vérification Yubico OTP a échoué : %s",
+ "webauthn_authenticator_failed": "L'authentificateur sélectionné est introuvable",
"demo_mode_enabled": "Le mode de démonstration est activé",
- "template_exists": "La template %s existe déja",
- "template_id_invalid": "Le numéro de template %s est invalide",
- "template_name_invalid": "Le nom de la template est invalide",
+ "template_exists": "Le modèle %s existe déjà",
+ "template_id_invalid": "Le numéro de modèle %s est invalide",
+ "template_name_invalid": "Le nom du modèle est invalide",
"img_dimensions_exceeded": "L'image dépasse les dimensions maximales",
- "img_size_exceeded": "L'image dépasse la taille maximale de fichier"
+ "img_size_exceeded": "L'image dépasse la taille maximale de fichier",
+ "webauthn_publickey_failed": "Aucune clé publique n'a été stockée pour l'authentificateur sélectionné",
+ "cors_invalid_method": "Allow-Method specifiée invalide",
+ "cors_invalid_origin": "Allow-Origin spécifiée invalide",
+ "extended_sender_acl_denied": "ACL manquante pour définir les adresses des expéditeurs externes",
+ "webauthn_username_failed": "L'authentificateur sélectionné appartient à un autre compte",
+ "recovery_email_failed": "Impossible d'envoyer un email de réinitialisation. Veuillez contacter votre administrateur.",
+ "invalid_reset_token": "Jeton de réinitialisation invalide",
+ "password_reset_invalid_user": "Boîte mail introuvable ou aucune adresse de récupération n'a été définie",
+ "password_reset_na": "La réinitialisation des mots de passe est actuellement indisponible. Veuillez contacter votre administrateur.",
+ "reset_token_limit_exceeded": "Le nombre limite de jetons de réinitialisation a été dépassé. Veuillez réessayer plus tard.",
+ "to_invalid": "Le destinataire ne doit pas être vide",
+ "generic_server_error": "Une erreur de serveur inattendue s'est produite. Veuillez contacter votre administrateur.",
+ "authsource_in_use": "Le fournisseur d'identité ne peut pas être modifié ou supprimé car il est actuellement utilisé par un ou plusieurs utilisateurs.",
+ "iam_test_connection": "Échec de la connexion",
+ "required_data_missing": "La donnée requise %s est manquante",
+ "max_age_invalid": "L'âge maximum %s est invalide",
+ "mode_invalid": "Le mode %s est invalide",
+ "mx_invalid": "L'enregistrement MX %s est invalide",
+ "version_invalid": "La version %s est invalide",
+ "tfa_removal_blocked": "L’authentification à deux facteurs ne peut pas être supprimée, car elle est requise pour votre compte.",
+ "quarantine_category_invalid": "La catégorie de quarantaine doit être l’une des suivantes : add_header, reject, all\""
},
"debug": {
"chart_this_server": "Graphique (ce serveur)",
"containers_info": "Informations des conteneurs",
"disk_usage": "Utilisation du disque",
- "external_logs": "Logs externe",
+ "external_logs": "Logs externes",
"history_all_servers": "Historique (tous les serveurs)",
"in_memory_logs": "Logs En-mémoire",
- "jvm_memory_solr": "Utilisation mémoire JVM",
- "log_info": "<p>Les logs <b>En-mémoire</b> Mailcow sont collectés dans des listes Redis et découpées en LOG_LINES (%d) chaque minute pour réduire la charge.\r\n <br>Les logs En-mémoire ne sont pas destinés à être persistants. Toutes les applications qui se connectent en mémoire, se connectent également au démon Docker et donc au pilote de journalisation par défaut.\r\n <br>Le type de journal en mémoire doit être utilisé pour déboguer les problèmes mineurs avec les conteneurs.</p>\r\n <p><b>Les logs externes</b> sont collectés via l'API de l'application concernée.</p>\r\n <p>Les journaux <b>statiques</b> sont principalement des journaux d’activité, qui ne sont pas enregistrés dans Dockerd, mais qui doivent toujours être persistants (sauf pour les logs API).</p>",
+ "log_info": "<p>Les logs <b>En-mémoire</b> Mailcow sont collectés dans des listes Redis et découpées en LOG_LINES (%d) chaque minute pour réduire la charge.\n <br>Les logs En-mémoire ne sont pas destinés à être persistants. Toutes les applications qui se connectent en mémoire, se connectent également au démon Docker, et donc au pilote de journalisation par défaut.\n <br>Le type de journal en mémoire doit être utilisé pour déboguer les problèmes mineurs avec les conteneurs.</p>\n <p><b>Les logs externes</b> sont collectés via l'API de l'application concernée.</p>\n <p>Les journaux <b>statiques</b> sont principalement des journaux d’activité, qui ne sont pas enregistrés dans Dockerd, mais qui doivent toujours être persistants (sauf pour les logs API).</p>",
"logs": "Logs",
"restart_container": "Redémarrer",
- "solr_dead": "Solr est en cours de démarrage, désactivé ou mort.",
"docs": "Docs",
"last_modified": "Dernière modification",
"online_users": "Utilisateurs en ligne",
"size": "Taille",
"started_at": "Démarré à",
- "solr_status": "Etat Solr",
"uptime": "Disponibilité",
"started_on": "Démarré à",
"static_logs": "Logs statiques",
- "system_containers": "Système & Conteneurs"
+ "system_containers": "Système & Conteneurs",
+ "timezone": "Fuseau horaire",
+ "username": "Nom d'utilisateur",
+ "wip": "En cours de réalisation",
+ "architecture": "Architecture",
+ "cores": "Cœurs",
+ "current_time": "Heure du système",
+ "container_disabled": "Conteneur arrêté ou désactivé",
+ "error_show_ip": "Impossible de résoudre les adresses IP publiques",
+ "no_update_available": "Le système utilise la version la plus récente",
+ "container_running": "En cours d'exécution",
+ "container_stopped": "Arrêté",
+ "memory": "Mémoire",
+ "login_time": "Horodatage",
+ "service": "Service",
+ "success": "Succès",
+ "update_available": "Une mise à jour est disponible",
+ "update_failed": "Impossible de vérifier la présence d'une mise à jour",
+ "show_ip": "Afficher l'IP publique"
},
"diagnostics": {
"cname_from_a": "Valeur dérivée de l’enregistrement A/AAAA. Ceci est supporté tant que l’enregistrement indique la bonne ressource.",
@@ -496,38 +606,38 @@
"dns_records_docs": "Veuillez également consulter <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">la documentation</a>.",
"dns_records_data": "Données correcte",
"dns_records_name": "Nom",
- "dns_records_status": "Etat courant",
+ "dns_records_status": "État courant",
"dns_records_type": "Type",
- "optional": "Cet enregistrement est optionel."
+ "optional": "Cet enregistrement est optionnel."
},
"edit": {
"active": "Actif",
"advanced_settings": "Réglages avancés",
- "alias": "Editer les alias",
+ "alias": "Éditer les alias",
"allow_from_smtp": "Restreindre l'utilisation de <b>SMTP</b> à ces adresses IP",
"allow_from_smtp_info": "Laissez vide pour autoriser tous les expéditeurs.<br>Adresses IPv4/IPv6 et réseaux.",
- "allowed_protocols": "Protocoles autorisés",
+ "allowed_protocols": "Protocoles autorisés pour l'accès direct de l'utilisateur (n'affecte pas les protocoles de mot de passe de l'application)",
"app_name": "Nom de l'application",
"app_passwd": "Mot de passe de l'application",
- "automap": "Essayer d’automatiser les dossiers (\"Sent items\", \"Sent\" => \"Sent\" etc.)",
+ "automap": "Tenter de cibler automatiquement les dossiers (« Sent items », « Sent » => « Sent » etc.)",
"backup_mx_options": "Options Backup MX",
- "bcc_dest_format": "La destination BCC doit être une seule adresse e-mail valide.",
+ "bcc_dest_format": "La destination BCC doit être une seule adresse de courriel valide.",
"client_id": "ID client",
"client_secret": "Secret client",
"comment_info": "Un commentaire privé n’est pas visible pour l’utilisateur, tandis qu’un commentaire public est affiché comme infobulle lorsque vous le placez dans un aperçu des utilisateurs",
"delete1": "Supprimer de la source une fois terminé",
"delete2": "Supprimer les messages sur la destination qui ne sont pas sur la source",
- "delete2duplicates": "Supprimer les doublons à destination",
+ "delete2duplicates": "Supprimer les doublons sur la destination",
"delete_ays": "Veuillez confirmer le processus de suppression.",
"description": "Description",
"disable_login": "Refuser l’ouverture de session (le courrier entrant est toujours accepté)",
- "domain": "Edition du domaine",
- "domain_admin": "Edition de l'administrateur du domaine",
+ "domain": "Édition du domaine",
+ "domain_admin": "Édition de l'administrateur du domaine",
"domain_quota": "Quota du domaine",
"domains": "Domaines",
"dont_check_sender_acl": "Désactiver la vérification de l’expéditeur pour le domaine %s (+ alias de domaines)",
- "edit_alias_domain": "Edition des alias de domaine",
- "encryption": "Cryptage",
+ "edit_alias_domain": "Édition des alias de domaine",
+ "encryption": "Chiffrement",
"exclude": "Exclure des objets (regex)",
"extended_sender_acl": "Adresses de l’expéditeur externe",
"extended_sender_acl_info": "Une clé de domaine DKIM doit être importée, si disponible.<br>\r\n N’oubliez pas d’ajouter ce serveur à l’enregistrement TXT SPF correspondant.<br>\r\n Chaque fois qu’un domaine ou un alias de domaine est ajouté à ce serveur, et qui chevauche une adresse externe, l’adresse externe est supprimée.<br>\r\n Utiliser @domain.tld pour permettre l'envoi comme *@domain.tld.",
@@ -542,14 +652,14 @@
"inactive": "Inactif",
"kind": "Type",
"last_modified": "Dernière modification",
- "mailbox": "Edition de la boîte mail",
- "mailbox_quota_def": "Quota par défaut de la boîte",
+ "mailbox": "Édition de la boîte de réception",
+ "mailbox_quota_def": "Quota par défaut de la boîte de réception",
"max_aliases": "Nombre max. d'alias",
- "max_mailboxes": "Nombre max. de boîtes possibles",
- "max_quota": "Quota max. par boîte mail (Mo)",
+ "max_mailboxes": "Nombre max. de boîte de réception possibles",
+ "max_quota": "Quota max. par boîte de réception (Mio)",
"maxage": "Âge maximal en jours des messages qui seront consultés à distance<br><small>(0 = ignorer la durée)</small>",
"maxbytespersecond": "Octets max. par seconde <br><small>(0 = pas de limite)</small>",
- "mbox_rl_info": "Cette limite de taux est appliquée au nom de connexion SASL, elle correspond à toute adresse \"from\" utilisée par l’utilisateur connecté. Une limite tarifaire pour les boîtes remplace une limite tarifaire pour l’ensemble du domaine.",
+ "mbox_rl_info": "Cette limite d'envoi est appliquée au nom de connexion SASL, elle correspond à toute adresse « from » utilisée par l’utilisateur connecté. Une limite d'envoi pour les boîtes de réception remplace une limite d'envoi pour l’ensemble du domaine.",
"mins_interval": "Intervalle (min)",
"multiple_bookings": "Réservations multiples",
"nexthop": "Saut suivant",
@@ -559,22 +669,22 @@
"private_comment": "Commentaire privé",
"public_comment": "Commentaire public",
"pushover_evaluate_x_prio": "Acheminement du courrier hautement prioritaire [<code>X-Priority: 1</code>]",
- "pushover_info": "Les paramètres de notification push s’appliqueront à tout le courrier propre (non spam) livré à <b>%s</b> y compris les alias (partagés, non partagés, étiquetés).",
+ "pushover_info": "Les paramètres de notification push s’appliqueront à tout le courrier propre (non-spam) livré à <b>%s</b> y compris les alias (partagés, non partagés, étiquetés).",
"pushover_only_x_prio": "Ne tenir compte que du courrier hautement prioritaire [<code>X-Priority: 1</code>]",
- "pushover_sender_array": "Ne tenir compte que des adresses électroniques suivantes de l’expéditeur : <small>(séparées par des virgules)</small>",
+ "pushover_sender_array": "Ne tenir compte que des adresses de courriel suivantes de l’expéditeur : <small>(séparées par des virgules)</small>",
"pushover_sender_regex": "Tenir compte de l’expéditeur regex suivant",
"pushover_text": "Texte de la notification",
"pushover_title": "Titre de la notification",
"pushover_vars": "Lorsque aucun filtre d’expéditeur n’est défini, tous les messages seront considérés.<br>Les filtres Regex ainsi que les vérifications exactes de l’expéditeur peuvent être définis individuellement et seront considérés de façon séquentielle. Ils ne dépendent pas les uns des autres.<br>Variables utilisables pour le texte et le titre (veuillez prendre note des politiques de protection des données)",
- "pushover_verify": "Vérifier les justificatifs",
- "quota_mb": "Quota (Mo)",
- "ratelimit": "Limite de taux",
- "redirect_uri": "Redirection/rappel URL",
+ "pushover_verify": "Vérifier les informations d'identification",
+ "quota_mb": "Quota (Mio)",
+ "ratelimit": "Limite d'envoi",
+ "redirect_uri": "URL de redirection/callback",
"relay_all": "Relayer tous les destinataires",
- "relay_all_info": "↪ Si vous <b>ne choissisez pas</b> de relayer tous les destinataires, vous devrez ajouter une boîte (\"aveugle\") pour chaque destinataire qui devrait être relayé.",
+ "relay_all_info": "↪ Si vous <b>ne choisissez pas</b> de relayer tous les destinataires, vous devrez ajouter une boîte de réception (« aveugle ») pour chaque destinataire qui devrait être relayé.",
"relay_domain": "Relayer ce domaine",
"relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> Vous pouvez définir des cartes de transport vers une destination personnalisée pour ce domaine. Si elle n’est pas configurée, une recherche MX sera effectuée.",
- "relay_unknown_only": "Relais des boîtes non existantes seulement. Les boîtes existantes seront livrées localement..",
+ "relay_unknown_only": "Relais des boîtes de réception non existantes seulement. Les boîtes de réception existantes seront livrées localement.",
"relayhost": "Transports dépendant de l’expéditeur",
"remove": "Enlever",
"resource": "Ressource",
@@ -582,28 +692,75 @@
"scope": "Portée",
"sender_acl": "Permettre d’envoyer comme",
"sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Le contrôle de l’expéditeur est désactivé</span>",
- "sender_acl_info": "Si l’utilisateur de la boîte A est autorisé à envoyer en tant qu’utilisateur de la boîte B, l’adresse de l’expéditeur n’est pas automatiquement affichée comme sélectionnable du champ \"from\" dans SOGo.<br>\r\n L’utilisateur B de la boîte doit créer une délégation dans Sogo pour permettre à l’utilisateur A de la boîte de sélectionner son adresse comme expéditeur. Pour déléguer une boîte dans Sogo, utilisez le menu (trois points) à droite du nom de votre boîte dans le coin supérieur gauche dans la vue de courrier. Ce comportement ne s’applique pas aux adresses alias.",
+ "sender_acl_info": "Si l’utilisateur de la boîte de réception A est autorisé à envoyer en tant qu’utilisateur de la boîte de réception B, l’adresse de l’expéditeur n’est pas automatiquement affichée comme sélectionnable du champ « de » dans SOGo.<br>\n L’utilisateur B de la boîte de réception doit créer une délégation dans SOGo pour permettre à l’utilisateur A de la boîte de réception de sélectionner son adresse comme expéditeur. Pour déléguer une boîte de réception dans SOGo, utilisez le menu (trois points) à droite du nom de votre boîte dans le coin supérieur gauche dans la vue de courrier. Ce comportement ne s’applique pas aux adresses alias.",
"sieve_desc": "Description courte",
"sieve_type": "Type de filtre",
"skipcrossduplicates": "Ignorer les messages en double dans les dossiers (premier arrivé, premier servi)",
"sogo_visible": "Alias visible dans SOGo",
- "sogo_visible_info": "Cette option affecte uniquement les objets qui peuvent être affichés dans SOGo (adresses alias partagées ou non partagées pointant vers au moins une boîte mail locale). Si caché, un alias n’apparaîtra pas comme expéditeur sélectionnable dans SOGo.",
+ "sogo_visible_info": "Cette option affecte uniquement les objets qui peuvent être affichés dans SOGo (adresses alias partagées ou non partagées pointant vers au moins une boîte de réception locale). Si caché, un alias n’apparaîtra pas comme expéditeur sélectionnable dans SOGo.",
"spam_alias": "Créer ou modifier des adresses alias limitées dans le temps",
"spam_filter": "Filtre spam",
"spam_policy": "Ajouter ou supprimer des éléments à la liste blanche/noire",
"spam_score": "Définir un score spam personnalisé",
"subfolder2": "Synchronisation dans le sous-dossier sur la destination<br><small>(vide = ne pas utiliser de sous-dossier)</small>",
"syncjob": "Modifier la tâche de synchronisation",
- "target_address": "Adresse(s) Goto<small>(séparé(s) par des virgules)</small>",
+ "target_address": "Adresse(s) Goto <small>(séparé(s) par des virgules)</small>",
"target_domain": "Domaine cible",
"timeout1": "Délai de connexion à l’hôte distant",
"timeout2": "Délai de connexion à l’hôte local",
- "title": "Editer l'objet",
+ "title": "Éditer l'objet",
"unchanged_if_empty": "Si non modifié, laisser en blanc",
"username": "Nom d'utilisateur",
- "validate_save": "Valider et sauver",
+ "validate_save": "Valider et enregistrer",
"lookup_mx": "La destination est une expression régulière qui doit correspondre avec le nom du MX (<code>.*\\.google\\.com</code> pour acheminer tout le courrier destiné à un MX se terminant par google.com via ce saut)",
- "mailbox_relayhost_info": "S'applique uniquement à la boîte aux lettres et aux alias directs, remplace le relayhost du domaine."
+ "mailbox_relayhost_info": "S'applique uniquement à la boîte de réception et aux alias directs, remplace le relayhost du domaine.",
+ "acl": "ACL (Permission)",
+ "footer_exclude": "Exclure du pied de page",
+ "custom_attributes": "Attributs personnalisés",
+ "domain_footer_info_vars": {
+ "from_addr": "{= from_addr =} - Partie de l'enveloppe relative à l'adresse de provenance",
+ "from_domain": "{= from_domain =} - Partie de l'enveloppe provenant du domaine",
+ "custom": "{= foo =} - Si la boîte de réception possède l'attribut personnalisé « foo » avec la valeur « bar », elle renvoie « bar »",
+ "auth_user": "{= auth_user =} - Nom d'utilisateur authentifié spécifié par un MTA",
+ "from_user": "{= from_user =} -La partie utilisateur de l'enveloppe, par exemple, pour « moo@mailcow.tld », renvoie « moo »",
+ "from_name": "{= from_name =} - À partir du nom de l'enveloppe, par exemple, pour « Mailcow <moo@mailcow.tld> ; » on obtient « Mailcow »"
+ },
+ "domain_footer_skip_replies": "Ignorer le pied de page des courriels de réponse",
+ "domain_footer": "Pied de page du domaine",
+ "domain_footer_html": "Pied de page HTML",
+ "domain_footer_info": "Les pieds de page du domaine sont ajoutés à tous les courriels sortants associés à une adresse au sein de ce domaine. <br> Les variables suivantes peuvent être utilisées pour le pied de page :",
+ "domain_footer_plain": "Pied de page",
+ "app_passwd_protocols": "Protocoles autorisés pour le mot de passe d'application",
+ "created_on": "Créé le",
+ "none_inherit": "Aucun / Héritage",
+ "quota_warning_bcc": "Avertissement sur les quotas BCC",
+ "quota_warning_bcc_info": "Les avertissements seront envoyés en copies séparées aux destinataires suivants. Le sujet sera précédé du nom d'utilisateur correspondant entre parenthèses, par exemple : <code>Avertissement sur les quotas (user@example.com)</code>.",
+ "sogo_access_info": "Après s'être connecté, l'utilisateur est automatiquement redirigé vers SOGo.",
+ "admin": "Modifier l'administrateur",
+ "password_recovery_email": "Adresse email de récupération",
+ "mailbox_rename_title": "Nouveau nom de la partie locale de la boîte de réception",
+ "mailbox_rename": "Renommer la boîte de réception",
+ "mailbox_rename_agree": "J'ai fait une sauvegarde.",
+ "mailbox_rename_warning": "IMPORTANT ! Faites une sauvegarde avant de renommer la boîte de réception.",
+ "mailbox_rename_alias": "Créer un alias automatiquement",
+ "sogo_access": "Redirection directe vers SOGo",
+ "pushover": "Pushover",
+ "pushover_sound": "Son",
+ "internal": "Interne",
+ "internal_info": "Les alias internes sont accessibles uniquement depuis le domaine ou les alias du domaine.",
+ "mta_sts": "MTA-STS",
+ "mta_sts_version": "Version",
+ "mta_sts_version_info": "Défini la version du standard MTA-STS – actuellement seul <code>STSv1</code> est valide.",
+ "mta_sts_mode": "Mode",
+ "mta_sts_max_age": "Âge maximum",
+ "mta_sts_mx": "Serveur MX",
+ "mta_sts_mx_notice": "Plusieurs serveurs MX peuvent être spécifiés (séparés par des virgules).",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> est un standard qui oblige la délivrance des courriels entre les serveurs de courriels à utiliser TLS avec des certificats valides. <br>Il est utilisé quand <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> n'est pas possible à cause d'un manque ou d'un non support de DNSSEC.<br><b>Note</b> : Si le domaine du destinataire supporte DANE avec DNSSEC, DANE est <b>toujours</b> préféré – MTA-STS sert seulement en secours.",
+ "mta_sts_mode_info": "Il y a trois modes parmi lesquels choisir :<ul><li><em>testing</em> – la politique est seulement surveillée, les violations n'ont pas d'impact.</li><li><em>enforce</em> – la politique est appliquée strictement, les connexions sans TLS valide sont rejetées.</li><li><em>none</em> – la politique est publiée mais non appliquée.</li></ul>",
+ "mta_sts_max_age_info": "Durée en secondes pendant laquelle les serveurs de courriel peuvent mettre en cache cette politique avant de revérifier.",
+ "mta_sts_mx_info": "Autoriser l'envoi uniquement aux noms d'hôtes des serveurs de courriels indiqués explicitement ; le MTA émetteur vérifie si le nom d'hôte DNS du MX correspond à la liste de la politique, et autorise la délivrance seulement avec un certificat TLS valide (protège contre le MITM).",
+ "sender_allowed": "Autoriser l'envoi sous cet alias",
+ "sender_allowed_info": "Si cette option est désactivée, cet alias peut uniquement recevoir des courriels. Utilisez les ACL d’expéditeur pour autoriser certaines boîtes aux lettres à envoyer des messages via cet alias."
},
"footer": {
"cancel": "Annuler",
@@ -614,20 +771,23 @@
"hibp_ok": "Aucune correspondance trouvée.",
"loading": "Veuillez patienter…",
"restart_container": "Redémarrer le conteneur",
- "restart_container_info": "<b>Important:</b> Un redémarrage en douceur peut prendre un certain temps, veuillez attendre qu’il soit terminé.",
+ "restart_container_info": "<b>Important :</b> Un redémarrage en douceur peut prendre un certain temps, veuillez attendre qu’il soit terminé.",
"restart_now": "Redémarrer maintenant",
- "restarting_container": "Redémarrage du conteneur, cela peut prendre un certain temps"
+ "restarting_container": "Redémarrage du conteneur, cela peut prendre un certain temps",
+ "nothing_selected": "Rien n'est sélectionné",
+ "hibp_check": "Vérifier avec haveibeenpwned.com"
},
"header": {
"administration": "Configuration & détails",
"apps": "Applications",
"debug": "Information Système",
- "email": "E-Mail",
+ "email": "Courriel",
"mailcow_config": "Configuration",
"quarantine": "Quarantaine",
"restart_netfilter": "Redémarrer Netfilter",
"restart_sogo": "Redémarrer SOGo",
- "user_settings": "Paramètres utilisateur"
+ "user_settings": "Paramètres utilisateur",
+ "mailcow_system": "Système"
},
"info": {
"awaiting_tfa_confirmation": "En attente de la confirmation de TFA",
@@ -638,15 +798,30 @@
"delayed": "La connexion a été retardée de %s secondes.",
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Connexion",
- "mobileconfig_info": "Veuillez vous connecter en tant qu’utilisateur de la boîte pour télécharger le profil de connexion Apple demandé.",
- "other_logins": "Clé d'authentification",
+ "mobileconfig_info": "Veuillez vous connecter en tant qu’utilisateur de la boîte de réception pour télécharger le profil de connexion Apple demandé.",
+ "other_logins": "ou se connecter avec",
"password": "Mot de passe",
- "username": "Nom d'utilisateur"
+ "username": "Nom d'utilisateur",
+ "back_to_mailcow": "Revenir sur mailcow",
+ "forgot_password": "> Mot de passe oublié ?",
+ "invalid_pass_reset_token": "Le jeton de réinitialisation du mot de passe est invalide ou a expiré.<br>Veuillez demander un nouveau lien de réinitialisation de mot de passe.",
+ "new_password": "Nouveau mot de passe",
+ "new_password_confirm": "Confirmer le nouveau mot de passe",
+ "reset_password": "Réinitialiser le mot de passe",
+ "request_reset_password": "Demander le changement du mot de passe",
+ "login_user": "Connexion Utilisateur",
+ "login_dadmin": "Connexion Administrateur de domaine",
+ "login_admin": "Connexion Administrateur",
+ "login_linkstext": "L'identifiant n'est pas correct ?",
+ "login_usertext": "Se connecter en tant qu'utilisateur",
+ "login_domainadmintext": "Se connecter en tant qu'administrateur du domaine",
+ "login_admintext": "Se connecter en tant qu'administrateur",
+ "email": "Adresse de courriel"
},
"mailbox": {
"action": "Action",
"activate": "Activer",
- "active": "Active",
+ "active": "Actif",
"add": "Ajouter",
"add_alias": "Ajouter un alias",
"add_bcc_entry": "Ajouter une carte BCC",
@@ -654,19 +829,19 @@
"add_domain_alias": "Ajouter un alias de domaine",
"add_domain_record_first": "Veuillez d’abord ajouter un domaine",
"add_filter": "Ajouter un filtre",
- "add_mailbox": "Ajouter une boîte",
+ "add_mailbox": "Ajouter une boîte de réception",
"add_recipient_map_entry": "Ajouter la carte du destinataire",
"add_resource": "Ajouter une ressource",
"add_tls_policy_map": "Ajouter la carte de la politique des TLS",
"address_rewriting": "Réécriture de l’adresse",
"alias": "Alias",
- "alias_domain_alias_hint": "Les alias <b>ne sont pas</b> appliqués automatiquement sur les alias de domaine. Un alias d'adresse <code>my-alias@domain</code> <b>ne couvre pas</b> l'adresse <code>my-alias@alias-domain</code> (où \"alias-domain\" est un alias imaginaire pour \"domain\").<br>Veuillez utiliser un filtre à tamis pour rediriger le courrier vers une boîte externe (voir l'onglet \"Filtres\" ou utilisez SOGo -> Forwarder).",
+ "alias_domain_alias_hint": "Les alias <b>ne sont pas</b> appliqués automatiquement sur les alias de domaine. Un alias d'adresse <code>my-alias@domain</code> <b>ne couvre pas</b> l'adresse <code>my-alias@alias-domain</code> (où « alias-domain » est un alias imaginaire pour « domain »).<br>Veuillez utiliser un filtre sieve pour rediriger le courrier vers une boîte de réception externe (voir l'onglet « Filtres » ou utilisez SOGo → Transférer). Utilisez « Étendre l'alias aux alias de domaine » pour ajouter automatiquement les alias manquants.",
"alias_domain_backupmx": "Alias de domaine inactif pour le domaine relais",
- "aliases": "Aliases",
+ "aliases": "Alias",
"allow_from_smtp": "Restreindre l'utilisation de <b>SMTP</b> à ces adresses IP",
"allow_from_smtp_info": "Laissez vide pour autoriser tous les expéditeurs.<br>Adresses IPv4/IPv6 et réseaux.",
"allowed_protocols": "Protocoles autorisés",
- "backup_mx": "Sauvegarde MX",
+ "backup_mx": "Domaine de relais",
"bcc": "BCC",
"bcc_destination": "Destination BCC",
"bcc_destinations": "Destinations BCC",
@@ -682,9 +857,9 @@
"bcc_type": "Type de BCC",
"booking_null": "Toujours montrer comme libre",
"booking_0_short": "Toujours libre",
- "booking_custom": "Limite rigide à un nombre de réservations personnalisé",
- "booking_custom_short": "Limite rigide",
- "booking_ltnull": "Illimité, mais afficher aussi occupé lorsque réservé",
+ "booking_custom": "Limitation stricte à un nombre personnalisé de réservations",
+ "booking_custom_short": "Limite stricte",
+ "booking_ltnull": "Illimité, mais indiqué comme occupé lors de la réservation",
"booking_lt0_short": "Limite souple",
"daily": "Quotidiennement",
"deactivate": "Désactiver",
@@ -699,33 +874,33 @@
"domain_quota": "Quota",
"domain_quota_total": "Quota total du domaine",
"domains": "Domaines",
- "edit": "Editer",
- "empty": "Pas de résulats",
+ "edit": "Éditer",
+ "empty": "Pas de résultats",
"enable_x": "Activer",
- "excludes": "Exclut",
- "filter_table": "Table de filtre",
+ "excludes": "Exclus",
+ "filter_table": "Table de filtrage",
"filters": "Filtres",
"fname": "Nom complet",
"force_pw_update": "Forcer la mise à jour du mot de passe à la prochaine ouverture de session",
"gal": "Carnet d'Adresses Global (GAL)",
- "hourly": "Horaire",
+ "hourly": "Toutes les heures",
"in_use": "Utilisé (%)",
"inactive": "Inactif",
- "insert_preset": "Insérer un exemple de préréglage \"%s\"",
+ "insert_preset": "Insérer un exemple de préréglage « %s »",
"kind": "Type",
"last_mail_login": "Dernière connexion mail",
"last_modified": "Dernière modification",
- "last_run": "Dernière éxécution",
- "last_run_reset": "Calendrier suivant",
- "mailbox": "Mailbox",
- "mailbox_defquota": "Taille de boîte par défaut",
- "mailbox_quota": "Taille max. d’une boîte",
- "mailboxes": "Boîtes mail",
+ "last_run": "Dernière exécution",
+ "last_run_reset": "Exécuter maintenant",
+ "mailbox": "Boîte de réception",
+ "mailbox_defquota": "Taille de boîte de réception par défaut",
+ "mailbox_quota": "Taille max. d’une boîte de réception",
+ "mailboxes": "Boîtes de réception",
"mailbox_defaults": "Paramètres par défaut",
- "mailbox_defaults_info": "Définir les paramètres par défaut pour les nouvelles boîtes aux lettres.",
+ "mailbox_defaults_info": "Définir les paramètres par défaut pour les nouvelles boîtes de réception.",
"max_aliases": "Nombre maximal d'alias",
- "max_mailboxes": "Nombre maximal de boîtes",
- "max_quota": "Quota max. par boîte mail",
+ "max_mailboxes": "Nombre maximal de boîte de réception",
+ "max_quota": "Quota max. par boîte de réception",
"mins_interval": "Intervalle (min)",
"msg_num": "Message #",
"multiple_bookings": "Réservations multiples",
@@ -736,35 +911,35 @@
"owner": "Propriétaire",
"private_comment": "Commentaire privé",
"public_comment": "Commentaire public",
- "q_add_header": "Courriers indésirables",
- "q_all": " quand déplacé dans le dossier spam ou rejeté",
- "q_reject": "Rejecté",
+ "q_add_header": "lorsqu'il est déplacé dans le dossier Indésirables",
+ "q_all": " quand déplacé dans le dossier indésirables ou rejeté",
+ "q_reject": "en cas de refus",
"quarantine_notification": "Avis de quarantaine",
"quarantine_category": "Catégorie de la notification de quarantaine",
"quick_actions": "Actions",
"recipient_map": "Carte du destinataire",
"recipient_map_info": "Les cartes des destinataires sont utilisées pour remplacer l’adresse de destination d’un message avant sa livraison.",
"recipient_map_new": "Nouveau destinataire",
- "recipient_map_new_info": "La destination de la carte du destinataire doit être une adresse électronique valide.",
+ "recipient_map_new_info": "La destination de la carte du destinataire doit être une adresse de courriel valide ou un nom de domaine.",
"recipient_map_old": "Destinataire original",
- "recipient_map_old_info": "Une carte de destination originale doit être une adresse e-mail valide ou un nom de domaine.",
- "recipient_maps": "Cartes des bénéficiaires",
+ "recipient_map_old_info": "La destination originale des cartes des destinataires doit être une adresse de courriel valide ou un nom de domaine.",
+ "recipient_maps": "Cartes des destinataires",
"relay_all": "Relayer tous les destinataires",
"remove": "Supprimer",
"resources": "Ressources",
"running": "En fonctionnement",
"set_postfilter": "Marquer comme postfiltre",
"set_prefilter": "Marquer comme préfiltre",
- "sieve_info": "Vous pouvez stocker plusieurs filtres par utilisateur, mais un seul préfiltre et un seul postfiltre peuvent être actifs en même temps.<br>\r\nChaque filtre sera traité dans l’ordre décrit. Ni un script \"rejeter\" ni un \"garder\" n’arrêtera le traitement des autres scripts. Les modifications apportées aux scripts de tamis globaux déclencheront un redémarrage de Dovecot.<br><br>Préfiltre de tamis global → Préfiltre → Scripts utilisateur → Postfiltre → Postfiltre du tamis global",
+ "sieve_info": "Vous pouvez stocker plusieurs filtres par utilisateur, mais un seul préfiltre et un seul postfiltre peuvent être actifs simultanément.<br>\nChaque filtre sera traité dans l’ordre décrit. Ni un script en échec ni un « keep; » n’arrêtera le traitement des autres scripts. Les modifications apportées aux scripts sieve globaux déclencheront un redémarrage de Dovecot.<br><br>Préfiltre sieve global → Préfiltre → Scripts utilisateur → Postfiltre → Postfiltre sieve global",
"sieve_preset_1": "Jeter le courrier avec les types de fichiers dangereux probables",
- "sieve_preset_2": "Toujours marquer l’e-mail d’un expéditeur spécifique comme vu",
- "sieve_preset_3": "Jeter en silence, arrêter tout traitement supplémentaire du tamis",
- "sieve_preset_4": "Fichier dans INBOX, éviter le traitement ultérieur par filtres à tamis",
+ "sieve_preset_2": "Toujours marquer l'adresse de courriel d’un expéditeur spécifique comme vu",
+ "sieve_preset_3": "Jeter en silence, arrêter tout traitement supplémentaire par filtre sieve",
+ "sieve_preset_4": "Fichier dans INBOX, éviter le traitement ultérieur par filtres sieve",
"sieve_preset_5": "Répondeur auto (vacances)",
"sieve_preset_6": "Rejeter le courrier avec réponse",
"sieve_preset_7": "Rediriger et garder/déposer",
- "sieve_preset_8": "Supprimer le message envoyé à une adresse alias dont fait partie l’expéditeur",
- "sieve_preset_header": "Voir les exemples de préréglages ci-dessous. Pour plus de détails voir <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedia</a>.",
+ "sieve_preset_8": "Rediriger les courriels d'un expéditeur spécifique, les marquer comme lus et les classer dans des sous-dossiers",
+ "sieve_preset_header": "Voir les exemples de préréglages ci-dessous. Pour plus de détails, voir <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipédia</a>.",
"sogo_visible": "Alias visible dans SOGo",
"sogo_visible_n": "Masquer alias dans SOGo",
"sogo_visible_y": "Afficher alias dans SOGo",
@@ -785,19 +960,47 @@
"tls_map_policy": "Politique",
"tls_policy_maps": "Cartes des politiques des TLS",
"tls_policy_maps_info": "Cette carte de politique remplace les règles de transport TLS sortantes indépendamment des paramètres de politique TLS des utilisateurs.<br>\r\n Veuillez vérifier <a href=\"http://www.postfix.org/postconf.5.html#smtp_tls_policy_maps\" target=\"_blank\">la doc \"smtp_tls_policy_maps\" </a> pour plus d'informations.",
- "tls_policy_maps_enforced_tls": "Ces politiques remplaceront également le comportement des utilisateurs de boîtes qui appliquent les connexions TLS sortantes. Si aucune politique n’existe ci-dessous, ces utilisateurs appliqueront les valeurs par défaut spécifiées comme <code>smtp_tls_mandatory_protocols</code> et <code>smtp_tls_mandatory_ciphers</code>.",
+ "tls_policy_maps_enforced_tls": "Ces politiques remplaceront également le comportement des utilisateurs de boîtes de réception qui appliquent les connexions TLS sortantes. Si aucune politique n’existe ci-dessous, ces utilisateurs appliqueront les valeurs par défaut spécifiées comme <code>smtp_tls_mandatory_protocols</code> et <code>smtp_tls_mandatory_ciphers</code>.",
"tls_policy_maps_long": "Contournement de la carte de politique TLS sortante",
"toggle_all": "Tout basculer",
"username": "Nom d'utilisateur",
"waiting": "En attente",
"weekly": "Hebdomadaire",
- "yes": "✓"
+ "yes": "✓",
+ "add_alias_expand": "Étendre l'alias aux alias de domaine",
+ "catch_all": "Catch-All",
+ "created_on": "Créé le",
+ "goto_ham": "Apprendre comme <b>ham</b>",
+ "goto_spam": "Apprendre comme <b>pourriel</b>",
+ "last_pw_change": "Dernier changement de mot de passe",
+ "mailbox_templates": "Modèle de boîte de réception",
+ "relay_unknown": "Relayer les boîtes de réception inconnues",
+ "all_domains": "Tous les domaines",
+ "syncjob_EXIT_OVERQUOTA": "Quota dépassé de la boîte de réception cible",
+ "domain_templates": "Modèles de domaine",
+ "syncjob_last_run_result": "Résultat de la dernière exécution",
+ "sender": "Expéditeur",
+ "add_template": "Ajouter un modèle",
+ "syncjob_EX_OK": "Succès",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Problème de connexion",
+ "syncjob_EXIT_TLS_FAILURE": "Problème avec le chiffrement de la connexion",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Problème d'authentification",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Impossible de se connecter au serveur distant",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Utilisateur ou mot de passe erroné",
+ "templates": "Modèles",
+ "template": "Modèle",
+ "syncjob_check_log": "Vérifier le journal",
+ "recipient": "Destinataire",
+ "open_logs": "Afficher les journaux",
+ "iam": "Fournisseur d'identité",
+ "internal": "Interne",
+ "force_tfa": "TFA"
},
"oauth2": {
- "access_denied": "Veuillez vous connecter en tant que propriétaire de la boîte pour accorder l’accès via Oauth2.",
+ "access_denied": "Veuillez vous connecter en tant que propriétaire de la boîte de réception pour accorder l’accès via Oauth2.",
"authorize_app": "Autoriser l'application",
"deny": "Refuser",
- "permit": "Autorise l'application",
+ "permit": "Autoriser l'application",
"profile": "Profil",
"profile_desc": "Afficher les informations personnelles : nom d’utilisateur, nom complet, créé, modifié, actif",
"scope_ask_permission": "Une application demande les permissions suivantes"
@@ -809,9 +1012,9 @@
"confirm": "Confirmer",
"confirm_delete": "Confirmer la suppression de cet élément.",
"danger": "Danger",
- "deliver_inbox": "Envoyer dans la boîte de reception",
- "disabled_by_config": "La configuration actuelle du système désactive la fonctionnalité de quarantaine. Veuillez définir \"retentions par boîte\" et une \"taille maximum\" pour les éléments en quarantaine.",
- "settings_info": "Quantité maximum d'éléments à mettre en quarantaine : %s<br>Taille maximale des e-mails : %s MiB",
+ "deliver_inbox": "Envoyer dans la boîte de réception",
+ "disabled_by_config": "La configuration actuelle du système désactive la fonctionnalité de quarantaine. Veuillez définir « retentions par boîte » et une « taille maximale » pour les éléments en quarantaine.",
+ "settings_info": "Quantité maximale d'éléments à mettre en quarantaine : %s<br>Taille maximale des courriels : %s Mio",
"download_eml": "Télécharger (.eml)",
"empty": "Pas de résultat",
"high_danger": "Haut",
@@ -824,7 +1027,7 @@
"notified": "Notifié",
"qhandler_success": "Demande envoyée avec succès au système. Vous pouvez maintenant fermer la fenêtre.",
"qid": "Rspamd QID",
- "qinfo": "Le système de quarantaine enregistrera le courrier rejeté dans la base de données (l'expéditeur n'aura <em> pas </em> l'impression d'un courrier remis) ainsi que le courrier, qui est remis sous forme de copie dans le dossier indésirable d'une boîte aux lettres.\r\n <br>\"Apprendre comme spam et supprimer\" apprendra un message comme spam via le théorème Bayesianet calculera également des hachages flous pour refuser des messages similaires à l'avenir.\r\n <br>Veuillez noter que l'apprentissage de plusieurs messages peut prendre du temps, selon votre système. <br> Les éléments figurant sur la liste noire sont exclus de la quarantaine.",
+ "qinfo": "Le système de quarantaine enregistrera le courrier rejeté dans la base de données (l'expéditeur n'aura <em>pas</em> l'impression d'un courrier remis) ainsi que le courrier, remis sous forme de copie dans le dossier indésirable d'une boîte de réception.\n <br>« Apprendre comme spam et supprimer » apprendra un message comme spam via le théorème Bayésien et calculera également des hachages flous pour refuser des messages similaires à l'avenir.\n <br>Veuillez noter que l'apprentissage de plusieurs messages peut prendre du temps, selon votre système.<br>Les éléments figurant sur la liste noire sont exclus de la quarantaine.",
"qitem": "Élément de quarantaine",
"quarantine": "Quarantaine",
"quick_actions": "Actions",
@@ -840,7 +1043,7 @@
"rewrite_subject": "Réécrire le sujet",
"rspamd_result": "Résultat Rspamd",
"sender": "Expéditeur (SMTP)",
- "sender_header": "Expéditeur (\"From\" header)",
+ "sender_header": "Expéditeur (« From » header)",
"type": "Type",
"quick_release_link": "Ouvrir le lien de dégagement rapide",
"quick_delete_link": "Ouvrir le lien de suppression rapide",
@@ -856,45 +1059,56 @@
"toggle_all": "Tout basculer"
},
"queue": {
- "queue_manager": "Gestion de la file d'attente"
+ "queue_manager": "Gestion de la file d'attente",
+ "hold_mail": "Garder",
+ "legend": "Fonctions d'action de la file d'attente du courrier :",
+ "info": "La file d'attente contient tous les courriels en attente de livraison. Si un courriel reste longtemps dans la file d'attente, il est automatiquement supprimé par le système.<br>Le message d'erreur du courriel concerné indique pourquoi le courriel n'a pas pu être distribué.",
+ "deliver_mail_legend": "Tentatives de réexpédition des courriers sélectionnés.",
+ "hold_mail_legend": "Met en attente les courriers sélectionnés. (Empêche les tentatives de distribution ultérieures)",
+ "unban": "file d'attente d'unban",
+ "unhold_mail": "Libérer",
+ "unhold_mail_legend": "Libère les courriers sélectionnés pour la distribution. (Nécessite une mise en attente préalable)",
+ "show_message": "Afficher le message",
+ "delete": "Tout supprimer",
+ "flush": "Vider la file d'attente",
+ "ays": "Veuillez confirmer que vous souhaitez supprimer tous les éléments de la file d'attente actuelle.",
+ "deliver_mail": "Délivrer"
},
"start": {
"help": "Afficher/masquer le panneau d’aide",
- "imap_smtp_server_auth_info": "Veuillez utiliser votre adresse e-mail complète et le mécanisme d’authentification PLAIN.<br>\r\nVos données de connexion seront cryptées par le cryptage obligatoire côté serveur.",
- "mailcow_apps_detail": "Utiliser une application mailcow pour accéder à vos messages, calendrier, contacts et plus.",
- "mailcow_panel_detail": "<b>Les administrateurs de domaines</b> peuvent créer, modifier or supprimer des boîtes et alias, changer de domaines et lire de plus amples renseignements sur les domaines qui leurs sont attribués.<br>\r\n<b>Les utilisateurs de boîtes</b> sont en mesure de créer des alias limités dans le temps (alias spam), de modifier leurs mots de passe et les paramètres du filtre anti-spam."
+ "imap_smtp_server_auth_info": "Veuillez utiliser votre adresse courriel complète et le mécanisme d’authentification PLAIN.<br>\nVos données de connexion seront cryptées par le cryptage obligatoire côté serveur."
},
"success": {
- "acl_saved": "ACL (Access Control List) pour l'objet %s sauvé",
- "admin_added": "Administrateur %s a été ajoutées",
+ "acl_saved": "ACL (Access Control List) pour l'objet %s enregistré",
+ "admin_added": "Administrateur %s a été ajouté",
"admin_api_modified": "Les modifications apportées à l’API ont été enregistrées",
"admin_modified": "Les modifications apportées à l’administrateur ont été enregistrées",
"admin_removed": "Administrateur %s a été effacé",
"alias_added": "L'adresse alias %s (%d) a été ajoutée",
"alias_domain_removed": "L'alias de domaine %s a été effacé",
- "alias_modified": "Le changement de l'adresse alias %s a été sauvegardée",
+ "alias_modified": "Le changement de l'adresse alias %s a été enregistré",
"alias_removed": "L'alias %s a été effacé",
"aliasd_added": "Alias de domaine %s ajouté",
- "aliasd_modified": "Les changements de l'alias de domaine %s ont été sauvegardés",
+ "aliasd_modified": "Les changements de l'alias de domaine %s ont été enregistrés",
"app_links": "Modifications enregistrées dans les liens d’application",
"app_passwd_added": "Ajout d’un nouveau mot de passe d’application",
"app_passwd_removed": "Suppression de l’identifiant du mot de passe de l’application %s",
- "bcc_deleted": "Suppression des entrées de la carte BCC : %s",
+ "bcc_deleted": "Suppression des entrées de la carte BCC : %s",
"bcc_edited": "Entrée de la carte BCC %s modifiée",
"bcc_saved": "Saisie de carte BCC enregistrée",
"db_init_complete": "Initialisation de la base de données terminée",
"delete_filter": "ID des filtres supprimés %s",
- "delete_filters": "Filtres supprimés : %s",
- "deleted_syncjob": "ID du travail de synchronisation supprimé : %s",
- "deleted_syncjobs": "Travail de synchronisation supprimé : %s",
- "dkim_added": "La clé DKIM %s a été sauvegardée",
- "dkim_duplicated": "La clé DKIM pour e domaine %s a été copiée vers %s",
+ "delete_filters": "Filtres supprimés : %s",
+ "deleted_syncjob": "ID de la tâche de synchronisation supprimée : %s",
+ "deleted_syncjobs": "Tâche de synchronisation supprimée : %s",
+ "dkim_added": "La clé DKIM %s a été enregistrée",
+ "dkim_duplicated": "La clé DKIM pour le domaine %s a été copiée vers %s",
"dkim_removed": "La clé DKIM %s a été supprimée",
"domain_added": "Domaine ajouté %s",
"domain_admin_added": "L'administrateur de domaine %s a été ajouté",
- "domain_admin_modified": "Les modifications de l'administrateur de domaine %s ont été sauvées",
+ "domain_admin_modified": "Les modifications de l'administrateur de domaine %s ont été enregistrées",
"domain_admin_removed": "L'administrateur de domaine %s a été supprimé",
- "domain_modified": "Les modification du domaine %s ont été sauvées",
+ "domain_modified": "Les modifications du domaine %s ont été enregistrées",
"domain_removed": "Le domaine %s a été supprimé",
"dovecot_restart_success": "Dovecot a été relancé avec succès",
"eas_reset": "Les périphériques Activesync pour l’utilisateur %s ont été réinitialisés",
@@ -910,40 +1124,54 @@
"learned_ham": "ID %s acquis avec succès comme ham",
"license_modified": "Les modifications apportées à la licence ont été enregistrées",
"logged_in_as": "Connecté en tant que %s",
- "mailbox_added": "La boîte mail %s a été ajoutée",
- "mailbox_modified": "Les modifications de la boîte %s ont été sauvées",
- "mailbox_removed": "La boîte %s a été supprimée",
+ "mailbox_added": "La boîte de réception %s a été ajoutée",
+ "mailbox_modified": "Les modifications de la boîte de réception %s ont été enregistrées",
+ "mailbox_removed": "La boîte de réception %s a été supprimée",
"nginx_reloaded": "Nginx a été rechargé",
- "object_modified": "Les changements de %s ont été sauvés",
+ "object_modified": "Les changements de %s ont été enregistrés",
"pushover_settings_edited": "Paramètres Pushover réglés avec succès, veuillez vérifier les informations d’identification.",
"qlearn_spam": "Le message ID %s a été appris comme spam et supprimé",
"queue_command_success": "Queue de commande terminée avec succès",
"recipient_map_entry_deleted": "La carte du destinataire ID %s a été effacée",
- "recipient_map_entry_saved": "L'entrée de la carte du bénéficiaire \"%s\" a été sauvée",
+ "recipient_map_entry_saved": "L'entrée de la carte du destinataire « %s » a été enregistrée",
"relayhost_added": "L'entrée de la carte %s a été ajoutée",
"relayhost_removed": "L'entrée de la carte %s a été supprimée",
"reset_main_logo": "Réinitialisation du logo par défaut",
"resource_added": "La ressource %s a été ajoutée",
- "resource_modified": "Les modifications apportées à la boîte %s ont été enregistrées",
+ "resource_modified": "Les modifications apportées à la boîte de réception %s ont été enregistrées",
"resource_removed": "La ressource %s a été supprimée",
- "rl_saved": "Limite de taux pour l’objet %s enregistrée",
+ "rl_saved": "Limite d'envoi pour l’objet %s enregistrée",
"rspamd_ui_pw_set": "Mot de passe de l'interface Rspamd sauvegardé avec succès",
"saved_settings": "Paramètres enregistrés",
"settings_map_added": "Ajout de l’entrée de la carte des paramètres",
"settings_map_removed": "Suppression de la carte des paramètres ID %s",
"sogo_profile_reset": "Le profil SOGo profile pour l'utilisateur %s est remis à zéro",
- "tls_policy_map_entry_deleted": "La carte de stratégie TLS ID %s a été supprimé",
- "tls_policy_map_entry_saved": "La carte de stratégie TLS ID \"%s\" a été sauvée",
+ "tls_policy_map_entry_deleted": "La carte de stratégie TLS ID %s a été supprimée",
+ "tls_policy_map_entry_saved": "La carte de stratégie TLS ID « %s » a été enregistrée",
"ui_texts": "Enregistrement des modifications apportées aux textes de l’interface utilisateur",
"upload_success": "Fichier téléchargé avec succès",
"verified_totp_login": "Authentification TOTP vérifiée",
"verified_webauthn_login": "Authentification WebAuthn vérifiée",
"verified_fido2_login": "Authentification FIDO2 vérifiée",
- "verified_yotp_login": "Authentification Yubico OTP vérifiée"
+ "verified_yotp_login": "Authentification Yubico OTP vérifiée",
+ "cors_headers_edited": "Les paramètres CORS ont été enregistrés",
+ "domain_footer_modified": "Les modifications apportées au pied de page du domaine %s ont été enregistrées",
+ "f2b_banlist_refreshed": "L'ID de la liste de ban a été actualisé avec succès.",
+ "template_added": "Modèles ajoutés %s",
+ "template_removed": "Le modèle ayant l'ID %s a été supprimé",
+ "domain_add_dkim_available": "A DKIM key did already exist",
+ "ip_check_opt_in_modified": "Le contrôle de l'IP a été enregistré avec succès",
+ "password_changed_success": "Le mot de passe a été modifié avec succès",
+ "recovery_email_sent": "Email de réinitialisation envoyé à %s",
+ "mailbox_renamed": "La boîte de réception a été renommée de %s à %s",
+ "template_modified": "Les modifications au modèle %s ont été enregistrées",
+ "password_policy_saved": "La politique de mot de passe a été enregistrée avec succès",
+ "custom_login_modified": "La personnalisation de la connexion a été sauvegardée avec succès",
+ "iam_test_connection": "Connexion réussie"
},
"tfa": {
- "api_register": "%s utilise l'API Yubico Cloud. Veuillez obtenir une clé API pour votre clé <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">here</a>",
- "confirm": "confirmer",
+ "api_register": "%s utilise l'API Yubico Cloud. Veuillez obtenir une clé API pour votre clé <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">ici</a>",
+ "confirm": "Confirmer",
"confirm_totp_token": "Veuillez confirmer vos modifications en saisissant le jeton généré",
"delete_tfa": "Désactiver TFA",
"disable_tfa": "Désactiver TFA jusqu’à la prochaine ouverture de session réussie",
@@ -960,25 +1188,33 @@
"start_webauthn_validation": "Début de la validation",
"tfa": "Authentification à deux facteurs",
"tfa_token_invalid": "Token TFA invalide",
- "totp": "OTP (One Time Password = Mot de passe à usage unique : Google Authenticator, Authy, etc.)",
+ "totp": "OTP (One Time Password = Mot de passe à usage unique : Google Authenticator, Authy, etc.)",
"webauthn": "Authentification WebAuthn",
"waiting_usb_auth": "<i>En attente d’un périphérique USB…</i><br><br>S’il vous plaît appuyez maintenant sur le bouton de votre périphérique USB WebAuthn.",
"waiting_usb_register": "<i>En attente d’un périphérique USB…</i><br><br>Veuillez entrer votre mot de passe ci-dessus et confirmer votre inscription WebAuthn en appuyant sur le bouton de votre périphérique USB WebAuthn.",
- "yubi_otp": "Authentification OTP Yubico"
+ "yubi_otp": "Authentification OTP Yubico",
+ "authenticators": "Authentificateurs",
+ "u2f_deprecated_important": "Veuillez enregistrer votre clé dans le panneau d'administration avec la nouvelle méthode WebAuthn.",
+ "u2f_deprecated": "Il semble que votre clé ait été enregistrée à l'aide de la méthode U2F obsolète. Nous allons désactiver l'authentification à deux facteurs pour vous et supprimer votre clé.",
+ "force_tfa": "Imposer l'authentification à deux facteurs lors de la connexion",
+ "force_tfa_info": "L’utilisateur doit configurer l’authentification à deux facteurs avant de pouvoir accéder à l’interface.",
+ "setup_title": "Authentification à deux facteurs requise",
+ "setup_required": "Votre compte nécessite l’authentification à deux facteurs. Veuillez configurer une méthode 2FA pour continuer."
},
"fido2": {
"set_fn": "Définir un nom",
"fn": "Nom",
- "rename": "renommer",
+ "rename": "Renommer",
"confirm": "Confirmer",
- "register_status": "Etat de l'enregistrement",
+ "register_status": "État de l'enregistrement",
"known_ids": "Identifiant(s) connu(s)",
"none": "Désactivé",
"set_fido2": "Enregistrer un nouvel appareil FIDO2",
"start_fido2_validation": "Tester la validation FIDO2",
"fido2_auth": "Se connecter avec FIDO2",
"fido2_success": "L'appareil est enregistré avec succès",
- "fido2_validation_failed": "La validation a échoué"
+ "fido2_validation_failed": "La validation a échoué",
+ "set_fido2_touchid": "Enregistrer Touch ID sur Apple M1"
},
"user": {
"action": "Action",
@@ -995,9 +1231,9 @@
"alias_valid_until": "Valide jusque",
"aliases_also_send_as": "Aussi autorisé à envoyer en tant qu’utilisateur",
"aliases_send_as_all": "Ne pas vérifier l’accès de l’expéditeur pour les domaines suivants et leurs alias",
- "app_hint": "Les mots de passe d’application sont des mots de passe alternatifs pour votre connexion IMAP, SMTP, Caldav, Carddav et EAS. Le nom d’utilisateur reste inchangé.<br>SOGo n'est pas disponible au travers de mots de passe.",
+ "app_hint": "Les mots de passe d’application sont des mots de passe alternatifs pour votre connexion IMAP, SMTP, CalDAV, CardDAV et EAS. Le nom d’utilisateur reste inchangé.<br>Le webmail SOGo n'est pas disponible au travers des mots de passe d'application.",
"app_name": "Nom d'application",
- "app_passwds": "Mots de passe de l'application",
+ "app_passwds": "Mots de passe d'applications",
"apple_connection_profile": "Profil de connexion Apple",
"apple_connection_profile_complete": "Ce profil de connexion inclut les paramètres IMAP et SMTP ainsi que les chemins Caldav (calendriers) et Carddav (contacts) pour un appareil Apple.",
"apple_connection_profile_mailonly": "Ce profil de connexion inclut les paramètres de configuration IMAP et SMTP pour un périphérique Apple.",
@@ -1007,18 +1243,19 @@
"create_syncjob": "Créer une tâche de synchronisation",
"daily": "Quotidien",
"day": "jour",
+ "description": "Description",
"delete_ays": "Veuillez confirmer le processus de suppression.",
- "direct_aliases": "Adresses alias directes",
+ "direct_aliases": "Adresses d'alias directes",
"direct_aliases_desc": "Les adresses d’alias directes sont affectées par le filtre anti-spam et les paramètres de politique TLS.",
- "eas_reset": "Réinitialiser le cache de l’appareil Activesync",
- "eas_reset_help": "Dans de nombreux cas, une réinitialisation du cache de l’appareil aidera à récupérer un profil Activesync cassé.<br><b>Attention :</b> Tous les éléments seront à nouveau téléchargés !",
+ "eas_reset": "Réinitialiser le cache de l’appareil ActiveSync",
+ "eas_reset_help": "Dans de nombreux cas, une réinitialisation du cache de l’appareil aidera à récupérer un profil ActiveSync cassé.<br><b>Attention :</b> Tous les éléments seront de nouveau téléchargés !",
"eas_reset_now": "Réinitialiser maintenant",
"edit": "Éditer",
- "email": "E-mail",
- "email_and_dav": "E-mail, calendriers et contacts",
- "encryption": "Cryptage",
- "excludes": "Exclut",
- "expire_in": "Expire dans",
+ "email": "Courriel",
+ "email_and_dav": "Courriel, calendriers et contacts",
+ "encryption": "Chiffrement",
+ "excludes": "Exclus",
+ "expire_in": "Expirer dans",
"force_pw_update": "Vous <b>devez</b> définir un nouveau mot de passe pour pouvoir accéder aux services liés aux logiciels de groupe.",
"generate": "générer",
"hour": "heure",
@@ -1030,7 +1267,7 @@
"last_mail_login": "Dernière connexion mail",
"last_run": "Dernière exécution",
"loading": "Chargement…",
- "mailbox_details": "Détails de la boîte",
+ "mailbox_details": "Détails",
"messages": "messages",
"never": "jamais",
"new_password": "Nouveau mot de passe",
@@ -1039,32 +1276,32 @@
"no_last_login": "Aucune dernière information de connexion à l'interface",
"no_record": "Pas d'enregistrement",
"password": "Mot de passe",
- "password_now": "Mot de passe courant (confirmer les changements)",
+ "password_now": "Mot de passe actuel (confirmer les changements)",
"password_repeat": "Mot de passe (répéter)",
"pushover_evaluate_x_prio": "Acheminement du courrier hautement prioritaire [<code>X-Priority: 1</code>]",
"pushover_info": "Les paramètres de notification push s’appliqueront à tout le courrier propre (non spam) livré à <b>%s</b> y compris les alias (partagés, non partagés, étiquetés).",
"pushover_only_x_prio": "Ne tenir compte que du courrier hautement prioritaire [<code>X-Priority: 1</code>]",
- "pushover_sender_array": "Tenez compte des adresses courriel suivantes de l’expéditeur : <small>(comma-separated)</small>",
+ "pushover_sender_array": "Tenir compte des adresses de courriel de l’expéditeur suivantes : <small>(séparées par des virgules)</small>",
"pushover_sender_regex": "Apparier les expéditeurs par le regex suivant",
"pushover_text": "Texte de notification",
"pushover_title": "Titre de la notification",
- "pushover_vars": "Lorsqu’aucun filtre d’expéditeur n’est défini, tous les messages seront considérés.<br>Les filtres Regex ainsi que les vérifications exactes de l’expéditeur peuvent être définis individuellement et seront considérés de façon séquentielle. Ils ne dépendent pas les uns des autres.<br>Variables utilisables pour le texte et le titre (veuillez prendre note des politiques de protection des données)",
- "pushover_verify": "Vérifier les justificatifs",
+ "pushover_vars": "Lorsque aucun filtre d’expéditeur n’est défini, tous les messages seront considérés.<br>Les filtres Regex ainsi que les vérifications exactes de l’expéditeur peuvent être définis individuellement et seront considérés de façon séquentielle. Ils ne dépendent pas les uns des autres.<br>Variables utilisables pour le texte et le titre (veuillez prendre note des politiques de protection des données)",
+ "pushover_verify": "Vérifier les identifiants",
"q_add_header": "Courrier indésirable",
"q_all": "Toutes les catégories",
"q_reject": "Rejeté",
"quarantine_notification": "Avis de quarantaine",
"quarantine_category": "Catégorie de la notification de quarantaine",
- "quarantine_notification_info": "Une fois qu’un avis a été envoyé, les articles seront marqués comme \"notified\" et aucune autre notification ne sera envoyée pour ce point particulier.",
- "quarantine_category_info": "La catégorie de notification \"Rejeté\" inclut le courrier qui a été rejeté, tandis que \"Dossier indésirable\" informera un utilisateur des e-mails qui ont été placés dans le dossier indésirable.",
+ "quarantine_notification_info": "Une fois qu’un avis a été envoyé, les articles seront marqués comme « notifiés » et aucune autre notification ne sera envoyée pour ce point particulier.",
+ "quarantine_category_info": "La catégorie de notification « Rejeté » inclut le courrier rejeté, tandis que « Dossier indésirable » informera un utilisateur des courriels placés dans le dossier indésirable.",
"remove": "Enlever",
- "running": "En fonction",
- "save": "Sauvegarder les changements",
- "save_changes": "Sauvegarder les changements",
+ "running": "En fonctionnement",
+ "save": "Enregistrer les changements",
+ "save_changes": "Enregistrer les changements",
"sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Le contrôle de l’expéditeur est désactivé</span>",
"shared_aliases": "Adresses alias partagées",
"shared_aliases_desc": "Les alias partagés ne sont pas affectés par les paramètres spécifiques à l’utilisateur tels que le filtre anti-spam ou la politique de chiffrement. Les filtres anti-spam correspondants ne peuvent être effectués que par un administrateur en tant que politique de domaine.",
- "show_sieve_filters": "Afficher le filtre de tamis actif de l’utilisateur",
+ "show_sieve_filters": "Afficher le filtre sieve actif de l’utilisateur",
"sogo_profile_reset": "Remise à zéro du profil SOGo",
"sogo_profile_reset_help": "Ceci détruira un profil Sogo des utilisateurs et <b>supprimera toutes les données de contact et de calendrier irrécupérables</b>.",
"sogo_profile_reset_now": "Remise à zéro du profil maintenant",
@@ -1073,11 +1310,11 @@
"spamfilter": "Filtre de spam",
"spamfilter_behavior": "Note",
"spamfilter_bl": "Liste noire (BlackList)",
- "spamfilter_bl_desc": "Les adresses de courriel sur la liste noire de <b>always (toujours)</b> peuvent être classées comme des pourriels et rejetées. Des caractères génériques peuvent être utilisés. Un filtre n’est appliqué qu’aux alias directs (alias avec une seule boîte cible), à l’exclusion des alias tous azimuts et d’une boîte elle-même.",
+ "spamfilter_bl_desc": "Les adresses de courriel sur liste noire qui doivent <b>toujours</b> être classées comme des pourriels et rejetées. Les messages rejetés ne seront <b>pas</b> copiés dans la quarantaine. Des caractères génériques peuvent être utilisés. Un filtre n’est appliqué qu’aux alias directs (alias avec une seule boîte de réception cible), à l’exclusion des alias attrape-tout et d’une boîte de réception elle-même.",
"spamfilter_default_score": "Valeurs par défaut",
- "spamfilter_green": "Vert : ce message n'est pas un spam",
- "spamfilter_hint": "La première valeur indique un \"faible score de spam\", la seconde représente un \"haut score de spam\".",
- "spamfilter_red": "Rouge : Ce message est un spam et sera rejeté par le serveur",
+ "spamfilter_green": "Vert : ce message n'est pas un spam",
+ "spamfilter_hint": "La première valeur indique un « faible score de spam », la seconde représente un « haut score de spam ».",
+ "spamfilter_red": "Rouge : Ce message est un spam et sera rejeté par le serveur",
"spamfilter_table_action": "Action",
"spamfilter_table_add": "Ajouter un élément",
"spamfilter_table_domain_policy": "n/a (politique de domaine)",
@@ -1085,13 +1322,13 @@
"spamfilter_table_remove": "supprimer",
"spamfilter_table_rule": "Règle",
"spamfilter_wl": "Liste blanche (WhiteList)",
- "spamfilter_wl_desc": "La liste blanche est programmé pour <b> ne jamais</b> classer comme spam les adresses e-mail qu'elle contient. Des caractères génériques peuvent être utilisés. Un filtre n’est appliqué qu’aux alias directs (alias avec une seule boîte cible), à l’exclusion des alias catch-all et d’une boîte mail.",
- "spamfilter_yellow": "Jaune : ce message est peut être un spam, il sera étiqueté comme spam et déplacé vers votre dossier Pourriel",
+ "spamfilter_wl_desc": "La liste blanche est programmée pour <b> ne jamais</b> classer comme spam les adresses de courriel qu'elle contient. Des caractères génériques peuvent être utilisés. Un filtre n’est appliqué qu’aux alias directs (alias avec une seule boîte de réception cible), à l’exclusion des alias attrape-tout et d’une boîte de réception.",
+ "spamfilter_yellow": "Jaune : ce message est peut-être un spam, il sera étiqueté comme spam et déplacé vers votre dossier Pourriel",
"status": "Statut",
- "sync_jobs": "Jobs de synchronisation",
+ "sync_jobs": "Tâches de synchronisation",
"tag_handling": "Régler la manipulation du courrier étiqueté",
- "tag_help_example": "Exemple pour une adresse e-mail étiquetée : me<b>+Facebook</b>@example.org",
- "tag_help_explain": "Dans un sous-dossier : un nouveau sous-dossier nommé selon l'étiquette sera créé sous INBOX (\"INBOX/Facebook\").<br>\nDans le sujet : le nom des balises sera ajouté au début du sujet du mail, exemple : \"[Facebook] My News\".",
+ "tag_help_example": "Exemple pour une adresse de courriel étiquetée : me<b>+Facebook</b>@example.org",
+ "tag_help_explain": "Dans un sous-dossier : un nouveau sous-dossier nommé selon l'étiquette sera créé sous INBOX (« INBOX/Facebook »).<br>\nDans le sujet : le nom des balises sera ajouté au début du sujet de l'e-mail, exemple : « [Facebook] My News ».",
"tag_in_none": "Ne rien faire",
"tag_in_subfolder": "Dans un sous dossier",
"tag_in_subject": "Dans le sujet",
@@ -1100,7 +1337,7 @@
"tls_enforce_in": "Appliquer le TLS entrant",
"tls_enforce_out": "Appliquer le TLS sortant",
"tls_policy": "Politique de chiffrement",
- "tls_policy_warning": "<strong>Attention:</strong> Si vous décidez d’appliquer le transfert de courrier chiffré, vous risquez de perdre des courriels.<br>Les messages qui ne satisfont pas à la politique seront renvoyés avec une erreur grave par le système de messagerie.<br>Cette option s’applique à votre adresse courriel principale (login name), toutes les adresses dérivées de domaines alias ainsi que les adresses alias <b>avec cette seule boîte</b> comme cible.",
+ "tls_policy_warning": "<strong>Attention :</strong> Si vous décidez d’appliquer le transfert de courrier chiffré, vous risquez de perdre des courriels.<br>Les messages qui ne satisfont pas à la politique seront renvoyés avec une erreur grave par le système de messagerie.<br>Cette option s’applique à votre adresse courriel principale (login name), toutes les adresses dérivées de domaines alias ainsi que les adresses alias <b>avec cette seule boîte de réception</b> comme cible.",
"user_settings": "Paramètres utilisateur",
"username": "Nom d'utilisateur",
"verify": "Vérification",
@@ -1111,18 +1348,92 @@
"months": "mois",
"year": "année",
"years": "années",
- "with_app_password": "avec le mot de passe de l'application"
+ "with_app_password": "avec le mot de passe de l'application",
+ "apple_connection_profile_with_app_password": "Un nouveau mot de passe est généré et ajouté au profil, de sorte qu'aucun mot de passe ne doit être saisi lors de la configuration de votre appareil. Ne partagez pas le fichier car il vous donne un accès complet à votre boîte de réception.",
+ "attribute": "Attribut",
+ "direct_protocol_access": "Cet utilisateur de la boîte aux lettres dispose d'un <b>accès externe direct</b> aux protocoles et applications suivants. Votre administrateur contrôle ce paramètre. Il est possible de créer des mots de passe d'application pour accorder l'accès à des protocoles et des applications individuels.<br>Le bouton « Connexion au Webmail » permet une connexion unique à SOGo et est toujours disponible.",
+ "open_webmail_sso": "Connexion au Webmail",
+ "recent_successful_connections": "Voir les connexions réussies",
+ "syncjob_EXIT_TLS_FAILURE": "Problème de connexion chiffrée",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Problème d'authentification",
+ "syncjob_EXIT_OVERQUOTA": "La boîte de réception cible a dépassé le quota",
+ "login_history": "Historique des connexions",
+ "change_password_hint_app_passwords": "Votre compte a %d mots de passe d'application qui ne seront pas modifiés. Pour les gérer, allez dans l'onglet Mots de passe de l'application.",
+ "clear_recent_successful_connections": "Vider l'historique des connexions réussies",
+ "created_on": "Créé le",
+ "last_ui_login": "Dernière connexion sur l'interface",
+ "syncjob_check_log": "Vérifier le journal",
+ "syncjob_last_run_result": "Résultat du dernier lancement",
+ "syncjob_EX_OK": "Succès",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Problème de connexion",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Impossible de se connecter au serveur distant",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Nom d'utilisateur ou mot de passe incorrect",
+ "value": "Valeur",
+ "allowed_protocols": "Protocoles autorisés",
+ "mailbox": "Boîte de réception",
+ "password_reset_info": "Si aucun email pour la récupération du mot de passe n'est fourni, cette fonction ne peut pas être utilisée.",
+ "pw_recovery_email": "Email de récupération pour son mot de passe",
+ "month": "mois",
+ "from": "de",
+ "empty": "Aucun résultat",
+ "fido2_webauthn": "FIDO2/WebAuthn",
+ "last_pw_change": "Dernier changement de mot de passe",
+ "open_logs": "Afficher les journaux",
+ "pushover_sound": "Son",
+ "mailbox_general": "Général",
+ "mailbox_settings": "Paramètres",
+ "tfa_info": "L'authentification à deux facteurs permet de protéger votre compte. Si vous l'activez, vous aurez besoin de mots de passe d'application pour vous connecter à des applications ou des services qui ne prennent pas en charge l'authentification à deux facteurs (par exemple les clients e-mails).",
+ "overview": "Vue d'ensemble",
+ "expire_never": "Ne jamais expirer",
+ "forever": "Pour toujours",
+ "spam_aliases_info": "Un alias de spam est une adresse de courriel temporaire qui peut être utilisée pour protéger les véritables adresses de courriel. <br> De manière optionnelle, une durée d'expiration peut être définie afin que l'alias soit automatiquement désactivé après la période définie, éliminant ainsi les adresses étant abusées ou ayant fuité.",
+ "authentication": "Authentification",
+ "protocols": "Protocoles",
+ "pw_update_required": "Votre compte nécessite un changement de mot de passe. Veuillez définir un nouveau mot de passe pour continuer."
},
"warning": {
"cannot_delete_self": "Impossible de supprimer l’utilisateur connecté",
"domain_added_sogo_failed": "Ajout d’un domaine mais échec du redémarrage de Sogo, veuillez vérifier les journaux de votre serveur.",
"dovecot_restart_failed": "Dovecot n’a pas pu redémarrer, veuillez vérifier les journaux",
- "fuzzy_learn_error": "Erreur d’apprentissage du hachage flou: %s",
+ "fuzzy_learn_error": "Erreur d’apprentissage du hachage flou : %s",
"hash_not_found": "Hachage non trouvé ou déjà supprimé",
- "ip_invalid": "IP non valide ignorée : %s",
- "no_active_admin": "Impossible de désactiver le dernier administrateur active",
- "quota_exceeded_scope": "Dépassement du quota de domaine : Seules des boîtes illimitées peuvent être créées dans ce domaine.",
- "session_token": "Jeton de formulaire invalide : Jeton différent",
- "session_ua": "Jeton de formulaire invalide : erreur de validation User-Agent"
+ "ip_invalid": "IP non valide ignorée : %s",
+ "no_active_admin": "Impossible de désactiver le dernier administrateur actif",
+ "quota_exceeded_scope": "Dépassement du quota de domaine : Seules des boîtes de réception illimitées peuvent être créées dans ce domaine.",
+ "session_token": "Jeton de formulaire invalide : Jeton différent",
+ "session_ua": "Jeton de formulaire invalide : erreur de validation User-Agent",
+ "is_not_primary_alias": "Alias non primaire ignoré %s"
+ },
+ "datatables": {
+ "decimal": ".",
+ "expand_all": "Tout déplier",
+ "thousands": ",",
+ "paginate": {
+ "first": "Premier",
+ "last": "Dernier",
+ "next": "Suivant",
+ "previous": "Précédent"
+ },
+ "aria": {
+ "sortAscending": ": activer pour trier les colonnes en ordre croissant",
+ "sortDescending": ": activer pour trier les colonnes en ordre décroissant"
+ },
+ "infoEmpty": "Affichage de 0 à 0 sur 0 entrée",
+ "infoFiltered": "(filtré à partir de _MAX_ entrée(s) totale(s))",
+ "lengthMenu": "Afficher les entrées _MENU_",
+ "loadingRecords": "Chargement…",
+ "processing": "Veuillez patienter…",
+ "collapse_all": "Tout réduire",
+ "info": "Affichage de _START_ à _END_ sur _TOTAL_ entrée(s)",
+ "search": "Rechercher :",
+ "emptyTable": "Aucune donnée présente dans la table",
+ "zeroRecords": "Aucun enregistrement correspondant trouvé"
+ },
+ "ratelimit": {
+ "disabled": "Désactivé",
+ "second": "msgs / seconde",
+ "minute": "msgs / minute",
+ "hour": "msgs / heure",
+ "day": "msgs / jour"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.gr-gr.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.gr-gr.json
index df9127a..a070ea8 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.gr-gr.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.gr-gr.json
@@ -6,7 +6,8 @@
"weeks": "Εβδομάδες",
"with_app_password": "με κωδικό εφαρμογής",
"year": "χρόνος",
- "years": "χρόνια"
+ "years": "χρόνια",
+ "value": "Τιμή"
},
"warning": {
"cannot_delete_self": "Αδυναμία διαγραφής συνδεδεμένου χρήστη",
@@ -16,5 +17,170 @@
"hash_not_found": "Η κατακερματισμένη τιμή (hash value) δεν βρέθηκε ή έχει είδη διαγραφεί.",
"ip_invalid": "Παραλείφθηκε μη έγκυρη διεύθυνση IP: %s",
"is_not_primary_alias": "Παραλείφθηκε μη πρωτεύον ψευδώνυμο %s"
+ },
+ "acl": {
+ "alias_domains": "Προσθήκη ψευδωνύμων τομέων",
+ "app_passwds": "Διαχείριση κωδικών εφαρμογής",
+ "bcc_maps": "χαρτογράφηση BCC",
+ "delimiter_action": "Ενέργεια οριοθέτη",
+ "domain_desc": "Αλλαγή περιγραφής τομέα",
+ "domain_relayhost": "Αλλαγή του διακομιστή αναμετάδοσης για ένα τομέα",
+ "eas_reset": "Επαναφορά συσκευών EAS",
+ "extend_sender_acl": "Να επιτρέπεται η επέκταση ACL του αποστολέα με εξωτερικές διευθύνσεις",
+ "filters": "Φίλτρα",
+ "login_as": "Είσοδος ως χρήστης e-mail",
+ "mailbox_relayhost": "Αλλαγή διακομιστή αναμετάδοσης για ένα γραμματοκιβώτιο",
+ "prohibited": "Απαγορεύεται από την ACL",
+ "protocol_access": "Αλλαγή πρόσβασης πρωτοκόλλου",
+ "pushover": "Pushover",
+ "pw_reset": "Επιτρέψτε την επαναφορά κωδικού πρόσβασης του χρήστη",
+ "quarantine": "Ενέργειες καραντίνας",
+ "quarantine_attachments": "Συνημμένα καραντίνας",
+ "quarantine_category": "Αλλαγή κατηγορίας ειδοποιήσεων καραντίνας",
+ "quarantine_notification": "Αλλαγή ειδοποιήσεων καραντίνας",
+ "ratelimit": "Όριο τιμής",
+ "recipient_maps": "Χάρτες παραληπτών",
+ "smtp_ip_access": "Αλλαγή επιτρεπόμενων διακομιστών SMTP",
+ "sogo_access": "Επιτρέψτε τη διαχείριση της πρόσβασης στο SOGo",
+ "sogo_profile_reset": "Επαναφορά του προφίλ SOGo",
+ "spam_alias": "Προσωρινά ψευδώνυμα",
+ "spam_policy": "Λίστα απορρίψεων/Λίστα επιτρεπόμενων",
+ "spam_score": "Βαθμολογία ανεπιθύμητης αλληλογραφίας",
+ "syncjobs": "Εργασίες συγχρονισμού",
+ "tls_policy": "Πολιτική TLS",
+ "unlimited_quota": "Απεριόριστο όριο για γραμματοκιβώτια"
+ },
+ "add": {
+ "activate_filter_warn": "Όλα τα άλλα φίλτρα θα απενεργοποιηθούν, όταν επιλεγεί η επιλογή \"ενεργό\".",
+ "active": "Ενεργό",
+ "add": "Προσθήκη",
+ "add_domain_only": "Προσθήκη μόνο του τομέα",
+ "add_domain_restart": "Προσθήκη του τομέα και επανεκκίνηση του SOGo",
+ "alias_address": "Διευθύνσεις ψευδωνύμων",
+ "alias_address_info": "<small>Πλήρης διεύθυνση(εις) e-mail ή @example.com, για να λαμβάνετε ΟΛΑ τα μηνύματα ενός τομέα (χωρισμένα με κόμα). <b>μόνο τομείς του mailcow</b>.</small>",
+ "alias_domain": "Ψευδώνυμο τομέα",
+ "alias_domain_info": "<small>Μόνο έγκυρα ονόματα τομέα (χωρισμένα με κόμα).</small>",
+ "app_name": "Όνομα εφαρμογής",
+ "app_password": "Προσθήκη κωδικού εφαρμογής",
+ "app_passwd_protocols": "Επιτρεπόμενα πρωτόκολλα για κωδικούς εφαρμογών",
+ "automap": "Αυτόματη αντιστοίχηση φακέλων (\"Απεσταλμένα μηνύματα\", \"Απεσταλμένα\" => \"Στάλθηκαν\" κ.τ.λ.)",
+ "backup_mx_options": "Επιλογές αναμετάδοσης",
+ "bcc_dest_format": "Η BCC διεύθυνση πρέπει να είναι μία και έγκυρη διεύθυνση e-mail.<br>Αν θέλετε να στείλετε αντίγραφα σε πολλούς παραλήπτες, δημιουργήστε ένα ψευδόνυμο για όλους και χρησιμοποιήστε το εδώ.",
+ "comment_info": "Τα προσωπικά σχόλια δεν είναι ορατά στον χρήστη. Τα δημόσια σχόλια εμφανίζονται ως tooltips.",
+ "custom_params": "Προσαρμοσμένες παράμετροι",
+ "custom_params_hint": "Σωστή σύνταξη: --param=xy, λάθος σύνταξη: --param xy",
+ "delete1": "Διαγραφή όταν ολοκληρωθεί",
+ "delete2": "Διαγραφή μηνυμάτων στον προορισμό που δεν βρίσκονται στην πηγή",
+ "delete2duplicates": "Διαγραφή διπλότυπων στον προορισμό",
+ "description": "Περιγραφή",
+ "destination": "Προορισμός",
+ "disable_login": "Απαγόρευση εισόδου (η εισερχόμενη αλληλογραφία εξακολουθεί να γίνεται δεκτή)",
+ "domain": "Τομέας",
+ "domain_matches_hostname": "Ο τομέας %s είναι ο ίδιος με το όνομα του διακομιστή",
+ "domain_quota_m": "Συνολικό όριο τομέα (MiB)",
+ "dry": "Προσομοίωση συγχρονισμού",
+ "enc_method": "Μέθοδος κρυπτογράφησης",
+ "exclude": "Εξαίρεση αντικειμένων (regex)",
+ "full_name": "Πλήρες όνομα",
+ "gal": "Κοινόχρηστη λίστα διευθύνσεων"
+ },
+ "danger": {
+ "unknown": "Παρουσιάστηκε κάποιο άγωνστο σφάλμα",
+ "unknown_tfa_method": "Άγνωστη μέθοδος TFA",
+ "unlimited_quota_acl": "Το απεριόριστο όριο απαγορεύεται από την ACL",
+ "username_invalid": "Το όνομα χρήστη %s δεν μπορεί να χρησιμοποιηθεί",
+ "validity_missing": "Παρακαλώ ορίστε μία περίοδο εγκυρότητας",
+ "value_missing": "Παρακαλώ συμπληρώστε όλα τα δεδομένα",
+ "version_invalid": "Η έκδοση %s δεν είναι έγκυρη",
+ "yotp_verification_failed": "Η επαλήθευση μέσω Yubico OTP απέτυχε: %s"
+ },
+ "datatables": {
+ "collapse_all": "Σύμπτυξη όλων",
+ "decimal": ".",
+ "emptyTable": "Δεν υπάρχουν εγγραφές",
+ "expand_all": "Επέκταση όλων",
+ "info": "Εμφανίζονται _START_ εώς _END_ από _TOTAL_ εγγραφές",
+ "infoEmpty": "Εμφανίζονται 0 εώς 0 από 0 εγγραφές",
+ "infoFiltered": "(φιλτραρισμένες από _MAX_ συνολικές εγγραφές)",
+ "thousands": ",",
+ "lengthMenu": "Εμφάνιση _MENU_ εγγραφών",
+ "loadingRecords": "Γίνεται φόρτωση...",
+ "processing": "Παρακαλώ περιμένετε...",
+ "search": "Αναζήτηση:",
+ "zeroRecords": "Δε βρέθηκαν εγγραφές",
+ "paginate": {
+ "first": "Πρώτη",
+ "last": "Τελευταία",
+ "next": "Επόμενη",
+ "previous": "Προηγούμενη"
+ },
+ "aria": {
+ "sortAscending": ": ενεργοποίηση αύξουσας ταξινόμησης",
+ "sortDescending": ": ενεργοποίηση φθίνουσας ταξινόμησης"
+ }
+ },
+ "debug": {
+ "architecture": "Αρχιτεκτονική",
+ "chart_this_server": "Γράφημα (αυτός ο διακομιστής)",
+ "containers_info": "Πληροφορίες για τον container",
+ "container_running": "Εκτελείται",
+ "container_disabled": "Ο container έχει σταματήσει ή απενεργοποιηθεί",
+ "container_stopped": "Σταματημένος",
+ "cores": "Πυρήνες",
+ "current_time": "Ώρα συστήματος",
+ "disk_usage": "Χρήση αποθ. χώρου",
+ "docs": "Έγγραφα",
+ "error_show_ip": "Δεν είναι δυνατή η επίλυση της δημόσιας IP διεύθυνσης",
+ "external_logs": "Εξωτερικά αρχεία καταγραφής",
+ "history_all_servers": "Ιστορικό (Όλοι οι διακομιστές)",
+ "in_memory_logs": "Αρχεία καταγραφής στη μνήμη",
+ "last_modified": "Τελευταία τροποποίηση",
+ "log_info": "<p>mailcow <b>in-memory logs</b> are collected in Redis lists and trimmed to LOG_LINES (%d) every minute to reduce hammering.\n <br>In-memory logs are not meant to be persistent. All applications that log in-memory, also log to the Docker daemon and therefore to the default logging driver.\n <br>The in-memory log type should be used for debugging minor issues with containers.</p>\n <p><b>External logs</b> are collected via API of the given application.</p>\n <p><b>Static logs</b> are mostly activity logs, that are not logged to the Dockerd but still need to be persistent (except for API logs).</p>",
+ "login_time": "Ώρα",
+ "logs": "Αρχεία καταγραφής",
+ "memory": "Μνήμη",
+ "online_users": "Συνδεδεμένοι χρήστες",
+ "restart_container": "Επανεκκίνηση",
+ "service": "Υπηρεσία",
+ "show_ip": "Εμφάνιση δημόσιας IP",
+ "size": "Μέγεθος",
+ "started_at": "Ξεκίνησε στις",
+ "started_on": "Ξεκίνησε στις",
+ "static_logs": "Στατικά αρχεία καταγραφής",
+ "success": "Επιτυχία",
+ "system_containers": "Σύστημα και Containers",
+ "timezone": "Ζώνη ώρας",
+ "uptime": "Χρόνος λειτουργίας",
+ "update_available": "Υπάρχει διαθέσιμη ενημέρωση",
+ "no_update_available": "Έχετε τη τελευταία έκδοση του συστήματος",
+ "update_failed": "Δεν ήταν δυνατός ο έλεγχος για ενημερώσεις",
+ "username": "Όνομα χρήστη",
+ "wip": "Currently Work in Progress"
+ },
+ "diagnostics": {
+ "cname_from_a": "Value derived from A/AAAA record. This is supported as long as the record points to the correct resource.",
+ "dns_records": "Εγγραφές DNS",
+ "dns_records_24hours": "Παρακαλώ σημειώστε ότι οι αλλαγές στο DNS μπορεί να χρειαστούν μέχρι 24 ώρες για να ενημερωθούν σωστά και να εμφανιστούν σε αυτή τη σελίδα. Ο σκοπός της είναι να δείτε πως μπορείτε να ρυθμίσετε σωστά τις εγγραφές DNS και να ελέγξετε αν είναι σωστές.",
+ "dns_records_data": "Σωστά δεδομένα",
+ "dns_records_docs": "Παρακαλώ συμβουλευτείτε επίσης <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">την τεκμηρίωση</a>.",
+ "dns_records_name": "Όνομα",
+ "dns_records_status": "Τρέχουσα κατάσταση",
+ "dns_records_type": "Τύπος",
+ "optional": "Αυτή η εγγραφή είναι προαιρετική."
+ },
+ "edit": {
+ "acl": "ACL (Δικαίωμα)",
+ "active": "Ενεργό",
+ "admin": "Επεξεργασία διαχειριστή",
+ "advanced_settings": "Ρυθμίσεις για προχωρημένους",
+ "alias": "Επεξεργασία ψευδώνυμου",
+ "allow_from_smtp": "Επέτρεψε μόνο σε αυτές τις IPs να χρησιμοποιήσουν το <b>SMTP</b>",
+ "allow_from_smtp_info": "Αφήστε το κενό για να επιτρέψετε όλους τους αποστολείς.<br>IPv4/IPv6 διευθύνσεις και δίκτυα.",
+ "allowed_protocols": "Επιτρεπόμενα πρωτόκολλα για απ' ευθείας πρόσβαση από τους χρήστες (δεν επηρεάζει τα πρωτόκολλα κωδικών πρόσβασης εφαρμογής)",
+ "app_name": "Όνομα εφαρμογής",
+ "app_passwd": "Κωδικός πρόσβασης εφαρμογής",
+ "app_passwd_protocols": "Επιτρέπομενα πρωτόκολλα για τον κωδικό εφαρμογής",
+ "automap": "Αυτόματη αντιστοίχηση φακέλων (\"Απεσταλμένα μηνύματα\", \"Απεσταλμένα\" => \"Στάλθηκαν\" κ.τ.λ.)",
+ "backup_mx_options": "Επιλογές αναμετάδοσης"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.hu-hu.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.hu-hu.json
index 1c798bd..ff49bc5 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.hu-hu.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.hu-hu.json
@@ -9,11 +9,11 @@
"source": "Forrás",
"spamfilter": "Spam szűrő",
"subject": "Tárgy",
- "sys_mails": "Rendszer-üzenetek",
+ "sys_mails": "Rendszer e-mailek",
"text": "Szöveg",
"time": "Idő",
"title": "Cím",
- "title_name": "\"mailcow UI\" website címe",
+ "title_name": "\"mailcow UI\" weboldal címe",
"to_top": "Vissza a tetejére",
"transport_dest_format": "Szintaxis: pelda.hu, .pelda.hu, *, fiok@pelda.hu (több érték esetén vesszővel elválasztva)",
"upload": "Feltöltés",
@@ -22,14 +22,289 @@
"activate_api": "API aktiválása",
"activate_send": "Küldés gomb aktiválása",
"add": "Hozzáad",
- "active": "Aktív"
+ "active": "Aktív",
+ "api_info": "Az API még fejlesztés alatt áll. A dokumentáció megtalálható a <a href=\"/api\">/api</a> alatt",
+ "allowed_methods": "Hozzáférés-Szabályozás-Engedélyezési-Módszerek",
+ "logo_normal_label": "Normál",
+ "logo_dark_label": "Sötét üzemmódhoz invertálva",
+ "f2b_regex_info": "Figyelembe vett naplók: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "f2b_retry_window": "Újrapróbálkozási ablak (s) a maximális próbálkozásokhoz",
+ "f2b_whitelist": "Engedélyezési listás hálózatok/hostok",
+ "filter_table": "Szűrő táblázat",
+ "forwarding_hosts": "Továbbító hostok",
+ "forwarding_hosts_add_hint": "Megadhat IPv4/IPv6 címeket, hálózatokat CIDR jelölésben, állomásneveket (amelyek IP címekre lesznek feloldva) vagy tartományneveket (amelyek IP címekre lesznek feloldva az SPF rekordok vagy ezek hiányában az MX rekordok lekérdezésével).",
+ "from": "A címről",
+ "copy_to_clipboard": "Szöveg másolva a vágólapra!",
+ "f2b_manage_external": "A Fail2Ban külső kezelése",
+ "f2b_manage_external_info": "A Fail2ban továbbra is karbantartja a tiltólistát, de nem állít be aktívan szabályokat a forgalom blokkolásához. Használja az alábbi generált tiltólistát a forgalom külső blokkolásához.",
+ "f2b_max_ban_time": "Maximális tiltási idő (s)",
+ "f2b_netban_ipv4": "IPv4 alhálózat mérete, amelyre tilalmat kell alkalmazni (8-32)",
+ "f2b_netban_ipv6": "IPv6 alhálózat mérete, amelyre tilalmat kell alkalmazni (8-128)",
+ "f2b_parameters": "Fail2ban paraméterek",
+ "forwarding_hosts_hint": "A bejövő üzeneteket feltétel nélkül elfogadják az itt felsorolt összes állomásról. Ezeket az állomáshelyeket nem ellenőrzik a DNSBL-ek alapján, és nem vetik alá a szürkelistázásnak. A tőlük érkező spameket a rendszer soha nem utasítja el, de opcionálisan a Junk mappába iktathatja őket. Leggyakrabban olyan levelezőszerverek megadására használjuk, amelyeken olyan szabályt állítottunk be, amely a bejövő e-maileket a mailcow-kiszolgálóra továbbítja.",
+ "guid_and_license": "GUID & Licenc",
+ "help_text": "Súgó szöveg felülírása a bejelentkezési maszk alatt (HTML engedélyezett)",
+ "html": "HTML",
+ "import": "Import",
+ "ip_check": "IP ellenőrzés",
+ "ip_check_disabled": "Az IP ellenőrzés le van tiltva. Bekapcsolhatja a következő menüpont alatt<br> <strong>Rendszer > Beállítások > Opciók > Személyreszabás</strong>",
+ "is_mx_based": "MX alapú",
+ "last_applied": "Utoljára alkalmazott",
+ "link": "Link",
+ "loading": "Kérjük, várj...",
+ "login_time": "Bejelentkezési idő",
+ "f2b_list_info": "Egy tiltólistán szereplő állomás vagy hálózat mindig nagyobb súlyú, mint egy engedélyezési listás elem. <b>A lista frissítései néhány másodpercig tartanak.</b>",
+ "f2b_ban_time_increment": "A tiltási idő minden egyes tiltással növekszik",
+ "additional_rows": " - további sorokat adtak hozzá",
+ "admin": "Adminisztrátor",
+ "admin_details": "Rendszergazda adatok szerkesztése",
+ "admin_domains": "Domain hozzárendelések",
+ "f2b_max_attempts": "Max. próbálkozások",
+ "generate": "generálni",
+ "admins": "Adminisztrátorok",
+ "admins_ldap": "LDAP rendszergazdák",
+ "allowed_origins": "Hozzáférés-Szabályozás-Engedélyezési-Származás",
+ "api_allow_from": "API-hozzáférés engedélyezése ezekről az IP/CIDR hálózati jelölésekről",
+ "api_key": "API-kulcs",
+ "api_read_only": "Csak olvasható hozzáférés",
+ "api_read_write": "Olvasás-írás hozzáférés",
+ "api_skip_ip_check": "IP ellenőrzés kihagyása az API esetében",
+ "cors_settings": "CORS beállítások",
+ "guid": "GUID - egyedi példányazonosító",
+ "dkim_to": "A címre",
+ "dkim_to_title": "Céltartomány(ok) - felülírásra kerül",
+ "domain": "Domain",
+ "domain_admin": "Domain adminisztrátor",
+ "domain_admins": "Domain adminisztrátorok",
+ "domain_s": "Domain(ek)",
+ "duplicate": "Duplikátum",
+ "duplicate_dkim": "Duplikált DKIM bejegyzés",
+ "edit": "Szerkesztés",
+ "empty": "Nincs eredmény",
+ "excludes": "Kizárja ezeket a kedvezményezetteket",
+ "f2b_ban_time": "Tiltás időtartam (s)",
+ "f2b_blacklist": "Tiltólistás címek",
+ "f2b_filter": "Regex szűrők",
+ "logo_info": "A képed 40px magasságúra lesz méretezve a felső navigációs sávhoz és max. 250px szélességűre a kezdőlaphoz. A skálázható grafika használata erősen ajánlott.",
+ "dkim_add_key": "ARC/DKIM kulcs hozzáadása",
+ "dkim_domains_selector": "Válogató",
+ "dkim_domains_wo_keys": "A hiányzó kulcsokkal rendelkező tartományok kiválasztása",
+ "dkim_from": "A címről",
+ "dkim_from_title": "Forrás tartomány, ahonnan az adatokat másolni kell",
+ "dkim_key_length": "DKIM kulcs hossza (bit)",
+ "dkim_key_missing": "Kulcs hiányzik",
+ "import_private_key": "Privát kulcs importálása",
+ "in_use_by": "Használja a",
+ "inactive": "Inaktív",
+ "include_exclude": "Beleértve/Kivéve",
+ "include_exclude_info": "Alapértelmezés szerint - kiválasztás nélkül - <b>minden postafiók</b> címzésre kerül.",
+ "includes": "Vegye fel ezeket a címzetteket",
+ "add_row": "Sor hozzáadása",
+ "host": "Host",
+ "active_rspamd_settings_map": "Aktív beállítások térképe",
+ "add_admin": "Adminisztrátor hozzáadása",
+ "add_forwarding_host": "Továbbító állomás hozzáadása",
+ "add_relayhost": "Feladófüggő szállítás hozzáadása",
+ "add_relayhost_hint": "Felhívjuk figyelmed, hogy ha vannak hitelesítési adatok, azok egyszerű szövegként kerülnek tárolásra.",
+ "add_settings_rule": "Beállítási szabály hozzáadása",
+ "add_transport": "Szállítás hozzáadása",
+ "add_transports_hint": "Felhívjuk figyelmed, hogy ha vannak hitelesítési adatok, azok egyszerű szövegként kerülnek tárolásra.",
+ "advanced_settings": "Speciális beállítások",
+ "change_logo": "Logó módosítása",
+ "dkim_key_unused": "Nem használt kulcs",
+ "add_domain_admin": "Tartományi rendszergazda hozzáadása",
+ "dkim_key_valid": "Érvényes kulcs",
+ "dkim_keys": "ARC/DKIM kulcsok",
+ "dkim_overwrite_key": "A meglévő DKIM kulcs felülírása",
+ "dkim_private_key": "Privát kulcs",
+ "app_links": "App linkek",
+ "app_name": "Alkalmazás neve",
+ "arrival_time": "Érkezési idő (szerveridő)",
+ "authed_user": "Azonosított felhasználó",
+ "ays": "Biztos, hogy folytatni akarod?",
+ "ban_list_info": "A tiltott IP címek listáját lásd alább: <b>hálózat (fennmaradó tiltási idő) - [akciók]</b>.<br />A tiltás feloldására várakozó IP-ket néhány másodpercen belül eltávolítjuk az aktív tiltási listáról.<br />A piros címkék a tiltólistán szereplő aktív állandó tiltásokat jelzik.",
+ "configuration": "Konfiguráció",
+ "convert_html_to_text": "HTML átalakítása egyszerű szöveggé",
+ "credentials_transport_warning": "<b>Figyelmeztetés</b>: Egy új közlekedési térképbejegyzés hozzáadása frissíti a hitelesítő adatokat minden olyan bejegyzéshez, amelynek a következő ugrás oszlopa megegyezik.",
+ "customize": "Testreszabás",
+ "destination": "Célállomás",
+ "customer_id": "Ügyfél azonosító",
+ "apps_name": "\"mailcow Apps\" név",
+ "admin_quicklink": "Gyorshivatkozás elrejtése az Adminisztrátori bejelentkezési oldalra",
+ "app_hide": "Elrejtés a bejelentkezéshez",
+ "domainadmin_quicklink": "Gyorshivatkozás elrejtése a Domain adminisztrátori bejelentkezési oldalra",
+ "filter": "Szűrő",
+ "force_sso_text": "Ha egy külső OIDC-szolgáltató van beállítva, ez az opció elrejti az alapértelmezett mailcow bejelentkezési űrlapokat, és csak az egységes bejelentkezési (Single Sign-On) gombot jeleníti meg",
+ "force_sso": "A mailcow bejelentkezés letiltása és csak az egységes bejelentkezés megjelenítése",
+ "hash_remove_info": "Egy arányszám-korlát hash eltávolítása (ha még létezik) teljesen visszaállítja a számlálóját.<br>\r\n Minden hash-t egyedi szín jelöl.",
+ "iam": "Azonosítási szolgáltató",
+ "iam_attribute_field": "Attribútum mező",
+ "iam_authorize_url": "Engedélyezési végpont",
+ "iam_auth_flow": "Azonosítási folyamat",
+ "iam_auth_flow_info": "Az engedélyezési kód áramláson (Authorization Code Flow) kívül, amelyet az egységes bejelentkezéshez (Single-Sign On) használnak (ez a standard áramlás Keycloak-ban), a mailcow támogatja a közvetlen hitelesítő adatokkal történő hitelesítési áramlást is. A Jelszóáramlás (Mailpassword Flow) megpróbálja érvényesíteni a felhasználó hitelesítő adatait a Keycloak Admin REST API használatával. A mailcow a <code>mailcow_password</code> attribútumból olvassa be a hash-elt jelszót, amely a Keycloak-ban van leképezve.",
+ "iam_basedn": "Bázis DN",
+ "iam_client_id": "Kliens azonosító",
+ "iam_client_secret": "Kliens titok",
+ "iam_client_scopes": "Kliens hatókörök",
+ "iam_default_template": "Alapértelmezett sablon",
+ "iam_default_template_description": "Ha nincs sablon hozzárendelve egy felhasználóhoz, az alapértelmezett sablon lesz felhasználva a postafiók létrehozásához, de a postafiók frissítéséhez nem.",
+ "iam_description": "Külső azonosítási szolgáltató konfigurálása.<br>A felhasználók postafiókjai automatikusan létrejönnek az első bejelentkezéskor, feltéve, hogy van attribútum-hozzárendelés beállítva.",
+ "iam_extra_permission": "A következő beállításokhoz a Keycloak-ban lévő mailcow kliensnek szüksége van egy <code>Service account</code>-ra és a <code>view-users</code> engedélyre.",
+ "iam_host": "Házigazda",
+ "iam_host_info": "Adjon meg egy vagy több LDAP állomást, vesszővel elválasztva.",
+ "iam_import_users": "Felhasználók importálása",
+ "iam_login_provisioning": "Felhasználók automatikus létrehozása bejelentkezéskor",
+ "iam_mapping": "Attribútum-hozzárendelés",
+ "iam_bindpass": "Bind jelszó",
+ "iam_periodic_full_sync": "Időszakos teljes szinkronizálás",
+ "iam_port": "Port",
+ "iam_realm": "Tartomány",
+ "iam_redirect_url": "Átirányítási URL",
+ "iam_rest_flow": "Mailpassword Flow",
+ "iam_server_url": "Szerver URL",
+ "iam_sso": "Egységes bejelentkezés",
+ "iam_sync_interval": "Szinkronizálási / importálási időtartam (perc)",
+ "iam_test_connection": "Kapcsolat tesztelése",
+ "iam_token_url": "Token végpont",
+ "iam_userinfo_url": "Felhasználói információ végpont",
+ "iam_username_field": "Felhasználónév mező",
+ "iam_binddn": "Bind DN",
+ "iam_use_ssl": "SSL használata",
+ "iam_use_ssl_info": "Ha az SSL-t engedélyezi, és a port 389-re van állítva, az automatikusan felülíródik 636-ra.",
+ "iam_use_tls": "StartTLS használata",
+ "iam_use_tls_info": "Ha a TLS-t engedélyezi, az LDAP szerver alapértelmezett portját kell használnia (389). Az SSL portok nem használhatók.",
+ "iam_version": "Verzió",
+ "ignore_ssl_error": "SSL hibák figyelmen kívül hagyása",
+ "ip_check_opt_in": "Választás a harmadik féltől származó <strong>ipv4.mailcow.email</strong> és <strong>ipv6.mailcow.email</strong> szolgáltatás használatára a külső IP címek feloldásához.",
+ "license_info": "A licensz nem kötelező, de segít a további fejlesztésben.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Regisztrálja a GUID-ját itt</a> vagy <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Support order\">vásároljon támogatást a mailcow telepítéséhez.</a>",
+ "lookup_mx": "A cél egy reguláris kifejezés, amely illeszkedik az MX névre (<code>.*\\.google\\.com</code>, hogy a google.com-ra végződő MX-en keresztül továbbítsa az összes levelet)",
+ "main_name": "\"mailcow UI\" név",
+ "merged_vars_hint": "A szürkével jelölt sorok a <code>vars.(local.)inc.php</code> fájlból lettek összevonva, és nem módosíthatók.",
+ "message": "Üzenet",
+ "message_size": "Üzenet mérete",
+ "nexthop": "Következő ugrás",
+ "no": "✕",
+ "no_active_bans": "Nincs aktív tiltás",
+ "no_new_rows": "Nincs több sor elérhető",
+ "no_record": "Nincs bejegyzés",
+ "oauth2_apps": "OAuth2 alkalmazások",
+ "oauth2_add_client": "OAuth2 kliens hozzáadása",
+ "oauth2_client_id": "Kliens azonosító",
+ "oauth2_client_secret": "Kliens titok",
+ "oauth2_info": "Az OAuth2 implementáció támogatja az \"Authorization Code\" engedélyezési típust és frissítési tokeneket ad ki.<br>\r\nA szerver automatikusan új frissítési tokeneket is kiad, miután egy frissítési token fel lett használva.<br><br>\r\n• Az alapértelmezett hatókör a <i>profile</i>. Csak postafiók-felhasználók hitelesíthetők az OAuth2-vel szemben. Ha a scope paraméter elmarad, az visszaesik a <i>profile</i>-ra.<br>\r\n• A <i>state</i> paramétert a kliensnek kötelező elküldenie az engedélyezési kérelem részeként.<br><br>\r\nAz OAuth2 API-hoz intézett kérések útvonalai: <br>\r\n<ul>\r\n <li>Engedélyezési végpont: <code>/oauth/authorize</code></li>\r\n <li>Token végpont: <code>/oauth/token</code></li>\r\n <li>Erőforrás oldal: <code>/oauth/profile</code></li>\r\n</ul>\r\nA kliens titok újragenerálása nem jár le a meglévő engedélyezési kódok lejáratával, de azok nem tudják megújítani a tokenjüket.<br><br>\r\nA kliens tokenek visszavonása az összes aktív munkamenet azonnali leállítását okozza. Minden kliensnek újra kell hitelesítenie magát.",
+ "oauth2_redirect_uri": "Átirányítási URI",
+ "oauth2_renew_secret": "Új kliens titok generálása",
+ "oauth2_revoke_tokens": "Minden kliens token visszavonása",
+ "optional": "opcionális",
+ "options": "Opciók",
+ "password": "Jelszó",
+ "password_length": "Jelszó hossza",
+ "password_policy": "Jelszó házirend",
+ "password_policy_chars": "Legalább egy betűkaraktert kell tartalmaznia",
+ "password_policy_length": "A jelszó minimális hossza %d",
+ "password_policy_lowerupper": "Kis- és nagybetűket kell tartalmaznia",
+ "password_policy_numbers": "Legalább egy számot kell tartalmaznia",
+ "password_policy_special_chars": "Speciális karaktereket kell tartalmaznia",
+ "password_repeat": "Megerősítő jelszó (ismétlés)",
+ "password_reset_info": "Ha nincs megadva helyreállítási e-mail cím, ez a funkció nem használható.",
+ "password_reset_settings": "Jelszó-helyreállítási beállítások",
+ "password_reset_tmpl_html": "HTML sablon",
+ "password_reset_tmpl_text": "Szöveges sablon",
+ "password_settings": "Jelszó beállítások",
+ "priority": "Prioritás",
+ "private_key": "Privát kulcs",
+ "quarantine": "Karantén",
+ "quarantine_bcc": "Az összes értesítés másolatának elküldése (BCC) erre a címzettnek:<br><small>Hagyja üresen a letiltáshoz. <b>Aláíratlan, nem ellenőrzött levél. Csak belső kézbesítésre alkalmas.</b></small>",
+ "quarantine_exclude_domains": "Tartományok és alias-tartományok kizárása",
+ "quarantine_max_age": "Maximális életkor napokban<br><small>Az értéknek legalább 1 napnak kell lennie.</small>",
+ "quarantine_max_score": "Az értesítés elvetése, ha egy levél spam pontszáma magasabb ennél az értéknél:<br><small>Alapértelmezett értéke 9999.0</small>",
+ "quarantine_max_size": "Maximális méret MiB-ban (a nagyobb elemeket elveti):<br><small>A 0 <b>nem</b> jelent korlátlant.</small>",
+ "quarantine_notification_html": "Értesítő e-mail sablon:<br><small>Hagyja üresen az alapértelmezett sablon visszaállításához.</small>",
+ "quarantine_notification_sender": "Értesítő e-mail feladója",
+ "quarantine_notification_subject": "Értesítő e-mail tárgya",
+ "quarantine_redirect": "<b>Az összes értesítés átirányítása</b> erre a címzettnek:<br><small>Hagyja üresen a letiltáshoz. <b>Aláíratlan, nem ellenőrzött levél. Csak belső kézbesítésre alkalmas.</b></small>",
+ "quarantine_release_format": "A feloldott elemek formátuma",
+ "quarantine_release_format_att": "Csatolmányként",
+ "quarantine_release_format_raw": "Eredeti, módosítatlan formában",
+ "quarantine_retention_size": "Megőrzések postafiókonként:<br><small>A 0 <b>inaktívat</b> jelent.</small>",
+ "quicklink_text": "A gyorshivatkozások megjelenítése vagy elrejtése a bejelentkezési űrlap alatt",
+ "quota_notification_html": "Értesítő e-mail sablon:<br><small>Hagyja üresen az alapértelmezett sablon visszaállításához.</small>",
+ "quota_notification_sender": "Kvóta értesítő e-mail feladója",
+ "quota_notification_subject": "Kvóta értesítő e-mail tárgya",
+ "quota_notifications": "Kvóta értesítések",
+ "quota_notifications_info": "A kvóta értesítéseket a felhasználók egyszer kapják meg, amikor a 80%-os határt, majd a 95%-os határt átlépik.",
+ "quota_notifications_vars": "{{percent}} a felhasználó aktuális kvótáját jelenti<br>{{username}} a postafiók neve",
+ "queue_unban": "tiltás feloldása",
+ "r_active": "Aktív korlátozások",
+ "r_inactive": "Inaktív korlátozások",
+ "r_info": "A szürkével/letiltva jelölt elemek az aktív korlátozások listáján a mailcow számára nem érvényes korlátozások, és nem mozgathatók. Az ismeretlen korlátozások a megjelenési sorrendben lesznek beállítva. <br>Új elemeket adhat hozzá a <code>inc/vars.local.inc.php</code> fájlban, hogy váltani tudja őket.",
+ "rate_name": "Arányszám neve",
+ "recipients": "Címzettek",
+ "refresh": "Frissítés",
+ "regen_api_key": "API kulcs újragenerálása",
+ "regex_maps": "Regex térképek",
+ "relay_from": "\"Feladó:\" cím",
+ "relay_rcpt": "\"Címzett:\" cím",
+ "relay_run": "Teszt futtatása",
+ "relayhosts": "Feladófüggő szállítások",
+ "relayhosts_hint": "Határozzon meg feladófüggő szállításokat, hogy kiválaszthassa őket egy tartomány konfigurációs párbeszédpanelén.<br>\r\n A szállítási szolgáltatás mindig \"smtp:\" és ezért megpróbálja a TLS-t, ha felajánlják. A becsomagolt TLS (SMTPS) nem támogatott. A felhasználók egyéni kimenő TLS-szabályzati beállításai figyelembe vételre kerülnek.<br>\r\n Érintik a kiválasztott tartományokat, beleértve az alias tartományokat is.",
+ "remove": "Eltávolítás",
+ "remove_row": "Sor eltávolítása",
+ "reset_default": "Visszaállítás alapértelmezettre",
+ "reset_limit": "Hash eltávolítása",
+ "reset_password_vars": "<code>{{link}}</code> A generált jelszó-helyreállítási link<br><code>{{username}}</code> A jelszó-helyreállítást kérő felhasználó postafiók neve<br><code>{{username2}}</code> A helyreállítási postafiók neve<br><code>{{date}}</code> A jelszó-helyreállítási kérelem dátuma<br><code>{{token_lifetime}}</code> A token élettartama percekben<br><code>{{hostname}}</code> A mailcow hosztnév",
+ "restore_template": "Hagyja üresen az alapértelmezett sablon visszaállításához.",
+ "routing": "Útválasztás",
+ "rsetting_add_rule": "Szabály hozzáadása",
+ "rsetting_content": "Szabály tartalma",
+ "rsetting_desc": "Rövid leírás",
+ "rsetting_no_selection": "Kérjük, válasszon egy szabályt",
+ "rsetting_none": "Nincsenek elérhető szabályok",
+ "rsettings_insert_preset": "Példa előre beállított \"%s\" beillesztése",
+ "rsettings_preset_1": "Minden letiltása, kivéve a DKIM és az arányszám-korlátot a hitelesített felhasználók számára",
+ "rsettings_preset_2": "A Postmasterek spamet akarnak",
+ "rsettings_preset_3": "Csak bizonyos feladókat engedélyezzen egy postafiók számára (pl. csak belső postafiókként használva)",
+ "rsettings_preset_4": "Rspamd letiltása egy tartomány számára",
+ "rspamd_com_settings": "A beállítás neve automatikusan generálódik, kérjük, nézze meg a lenti példa-előrebeállításokat. További részletekért lásd a <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd dokumentációját</a>",
+ "rspamd_global_filters": "Globális szűrőtérképek",
+ "rspamd_global_filters_agree": "Óvatos leszek!",
+ "rspamd_global_filters_info": "A globális szűrőtérképek különböző típusú globális tiltó- és engedélyezési listákat tartalmaznak.",
+ "rspamd_global_filters_regex": "A nevük elmagyarázza a céljukat. Minden tartalomnak érvényes reguláris kifejezést kell tartalmaznia \"/pattern/options\" formátumban (pl. <code>/.+@domain\\.tld/i</code>).<br>\r\n Bár alapvető ellenőrzések történnek minden regex soron, az Rspamd funkcionalitása megszakadhat, ha nem sikerül helyesen értelmeznie a szintaxist.<br>\r\n Az Rspamd megpróbálja elolvasni a térkép tartalmát, amikor az megváltozik. Ha problémákat tapasztal, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">indítsa újra az Rspamd-et</a>, hogy kikényszerítse a térkép újratöltését.<br>A tiltólistára került elemek ki vannak zárva a karanténból.",
+ "rspamd_settings_map": "Rspamd beállítási térkép",
+ "sal_level": "Moo szint",
+ "service": "Szolgáltatás",
+ "service_id": "Szolgáltatás azonosító",
+ "task": "Feladat",
+ "transport_maps": "Szállítási térképek",
+ "transport_test_rcpt_info": "• Használja a null@hosted.mailcow.de címet a külföldi célra történő továbbítás teszteléséhez.",
+ "transports_hint": "• Egy szállítási térkép bejegyzés <b>felülírja</b> a feladófüggő szállítási térképet</b>.<br>\r\n• Az MX-alapú szállítások előnyben részesítettek.<br>\r\n• A felhasználónkénti kimenő TLS-szabályzati beállítások figyelmen kívül hagyódnak, és csak a TLS-szabályzati térkép bejegyzései kényszeríthetik ki őket.<br>\r\n• A definiált szállításokhoz a szállítási szolgáltatás mindig \"smtp:\" és ezért megpróbálja a TLS-t, ha felajánlják. A becsomagolt TLS (SMTPS) nem támogatott.<br>\r\n• A \"/localhost$/\"-nek megfelelő címek mindig \"local:\"-on keresztül lesznek szállítva, ezért a \"*\" cél nem vonatkozik ezekre a címekre.<br>\r\n• A hitelesítő adatok meghatározásához egy példa következő ugráshoz \"[host]:25\", a Postfix <b>mindig</b> lekérdezi a \"host\"-ot, mielőtt a \"[host]:25\"-re keresne. Ez a viselkedés lehetetlenné teszi a \"host\" és a \"[host]:25\" egyidejű használatát.",
+ "ui_footer": "Lábléc (HTML engedélyezett)",
+ "ui_header_announcement": "Közlemények",
+ "ui_header_announcement_active": "Közlemény beállítása aktívra",
+ "ui_header_announcement_content": "Szöveg (HTML engedélyezett)",
+ "ui_header_announcement_help": "A közlemény minden bejelentkezett felhasználó számára látható, valamint a felhasználói felület bejelentkezési képernyőjén.",
+ "ui_header_announcement_select": "Válassza ki a közlemény típusát",
+ "ui_header_announcement_type": "Típus",
+ "ui_header_announcement_type_danger": "Nagyon fontos",
+ "ui_header_announcement_type_info": "Információ",
+ "ui_header_announcement_type_warning": "Fontos",
+ "ui_texts": "Felhasználói felület címkéi és szövegei",
+ "unban_pending": "tiltás feloldása függőben",
+ "unchanged_if_empty": "Ha nem változik, hagyja üresen",
+ "user_link": "Felhasználói-link",
+ "user_quicklink": "Gyorshivatkozás elrejtése a Felhasználói bejelentkezési oldalra",
+ "validate_license_now": "GUID érvényesítése a licenszszerverrel szemben",
+ "yes": "✓",
+ "success": "Siker",
+ "login_page": "Belépő oldal",
+ "needs_restart": "újraindítást igényel"
},
"edit": {
"active": "Aktív",
"advanced_settings": "Haladó beállítások",
"alias": "Alias szerkesztése",
- "allow_from_smtp": "Kizárólag ezen IP-címek használhatnak <b>SMTP</b>-t",
- "allow_from_smtp_info": "Leave empty to allow all senders.<br>IPv4/IPv6 addresses and networks.",
+ "allow_from_smtp": "Kizárólag ezen IP címek használhatnak <b>SMTP</b>-t",
+ "allow_from_smtp_info": "Hagyja üresen minden feladó engedélyezéséhez.<br>IPv4/IPv6 címek és hálózatok.",
"allowed_protocols": "Engedélyezett protokollok",
"app_name": "Applikáció neve",
"app_passwd": "Applikáció jelszava",
@@ -39,7 +314,127 @@
"description": "Leírás",
"domain_quota": "Domain kvóta",
"domains": "Domainek",
- "edit_alias_domain": "Alias domain szerkesztése"
+ "edit_alias_domain": "Alias domain szerkesztése",
+ "acl": "ACL (Engedélyek)",
+ "admin": "Adminisztrátor szerkesztése",
+ "app_passwd_protocols": "Engedélyezett protokollok az alkalmazás jelszavához",
+ "automap": "Próbálja automatikusan feltérképezni a mappákat (\"Elküldött elemek\", \"Elküldött\" => \"Elküldött\" stb.)",
+ "bcc_dest_format": "A BCC-célpontnak egyetlen érvényes e-mail címnek kell lennie.<br>Ha több címre kell másolatot küldenie, hozzon létre egy aliast, és használja azt itt.",
+ "comment_info": "A privát megjegyzés nem látható a felhasználó számára, míg a nyilvános megjegyzés tooltip-ként jelenik meg, amikor a felhasználó áttekintésében a megjegyzésre mutat.",
+ "created_on": "Létrehozva",
+ "custom_attributes": "Egyéni attribútumok",
+ "delete1": "Törlés a forrásból, ha befejeződött",
+ "delete2": "Üzenetek törlése a célállomáson, amelyek nincsenek a forráson",
+ "delete2duplicates": "Duplikáltak törlése a célállomáson",
+ "delete_ays": "Erősítse meg a törlési folyamatot.",
+ "disable_login": "Bejelentkezés letiltása (a bejövő leveleket továbbra is elfogadja)",
+ "domain": "Domain szerkesztése",
+ "domain_admin": "Domain adminisztrátor szerkesztése",
+ "domain_footer": "Tartományszintű lábléc",
+ "domain_footer_html": "HTML lábléc",
+ "domain_footer_info": "A tartományszintű lábléceket a tartományon belüli címmel társított összes kimenő e-mailhez hozzáadják. <br> A következő változók használhatók a lábléchez:",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - Hitelesített felhasználónév az MTA által megadott",
+ "from_user": "{= from_user =} - A boríték feladójának felhasználói része, pl. a \"moo@mailcow.tld\" esetén \"moo\"-t ad vissza",
+ "from_name": "{= from_name =} - A boríték feladójának neve, pl. a \"Mailcow <moo@mailcow.tld>\" esetén \"Mailcow\"-t ad vissza",
+ "from_addr": "{= from_addr =} - A boríték feladójának címe",
+ "from_domain": "{= from_domain =} - A boríték feladójának tartománya",
+ "custom": "{= foo =} - Ha a postafiók rendelkezik a \"foo\" egyéni attribútummal, amelynek értéke \"bar\", akkor \"bar\"-t ad vissza"
+ },
+ "domain_footer_plain": "Egyszerű szöveges lábléc",
+ "domain_footer_skip_replies": "Lábléc figyelmen kívül hagyása válasz e-maileknél",
+ "dont_check_sender_acl": "Küldő ellenőrzés letiltása a(z) %s tartományhoz (+ alias tartományok)",
+ "encryption": "Titkosítás",
+ "exclude": "Objektumok kizárása (regex)",
+ "extended_sender_acl": "Külső feladói címek",
+ "extended_sender_acl_info": "Importálni kell egy DKIM tartomány kulcsot, ha elérhető.<br>\r\n Ne felejtse el hozzáadni ezt a szervert a megfelelő SPF TXT rekordhoz.<br>\r\n Amikor egy tartományt vagy alias tartományt ad hozzá ehhez a szerverhez, amely átfedésben van egy külső címmel, a külső cím eltávolításra kerül.<br>\r\n Használja a @domain.tld címet, hogy engedélyezze a küldést *@domain.tld néven.",
+ "force_pw_update": "Jelszófrissítés kényszerítése a következő bejelentkezéskor",
+ "force_pw_update_info": "Ez a felhasználó csak a(z) %s címre tud bejelentkezni. Az alkalmazás jelszavak használhatóak maradnak.",
+ "footer_exclude": "Kizárás a láblécből",
+ "full_name": "Teljes név",
+ "gal": "Globális címlista",
+ "gal_info": "A GAL tartalmazza a tartomány összes objektumát, és egyetlen felhasználó sem szerkesztheti. A Szabad/Foglalt információ a SOGo-ban hiányzik, ha le van tiltva! <b>Indítsa újra a SOGo-t a változások alkalmazásához.</b>",
+ "generate": "generál",
+ "grant_types": "Engedélyezési típusok",
+ "hostname": "Hosztnév",
+ "inactive": "Inaktív",
+ "kind": "Típus",
+ "last_modified": "Utoljára módosítva",
+ "lookup_mx": "A cél egy reguláris kifejezés, amely illeszkedik az MX névre (<code>.*\\.google\\.com</code>, hogy a google.com-ra végződő MX-en keresztül továbbítsa az összes levelet)",
+ "mailbox": "Postafiók szerkesztése",
+ "mailbox_quota_def": "Alapértelmezett postafiók kvóta",
+ "mailbox_relayhost_info": "A postafiókra és csak a közvetlen aliasokra vonatkozik, felülírja a tartományi továbbító hostot.",
+ "mailbox_rename": "Postafiók átnevezése",
+ "mailbox_rename_agree": "Készítettem biztonsági másolatot.",
+ "mailbox_rename_warning": "FONTOS! Hozzon létre biztonsági másolatot a postafiók átnevezése előtt.",
+ "mailbox_rename_alias": "Alias automatikus létrehozása",
+ "mailbox_rename_title": "Új helyi postafiók neve",
+ "max_aliases": "Max. aliasok",
+ "max_mailboxes": "Max. lehetséges postafiókok",
+ "max_quota": "Max. kvóta postafiókonként (MiB)",
+ "maxage": "Üzenetek maximális életkora napokban, amelyek lekérdezésre kerülnek a távolról<br><small>(0 = figyelmen kívül hagyás)</small>",
+ "maxbytespersecond": "Max. bájt/másodperc <br><small>(0 = korlátlan)</small>",
+ "mbox_rl_info": "Ez a sebességkorlátozás a SASL bejelentkezési névre vonatkozik, és illeszkedik minden, a bejelentkezett felhasználó által használt \"from\" címre. Egy postafiók sebességkorlátozása felülírja a tartományszintű sebességkorlátozást.",
+ "mins_interval": "Időköz (perc)",
+ "multiple_bookings": "Több foglalás",
+ "none_inherit": "Nincs / Örökölt",
+ "nexthop": "Következő ugrás",
+ "password": "Jelszó",
+ "password_recovery_email": "Jelszó-helyreállítási e-mail",
+ "password_repeat": "Megerősítő jelszó (ismétlés)",
+ "previous": "Előző oldal",
+ "private_comment": "Privát megjegyzés",
+ "public_comment": "Nyilvános megjegyzés",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Magas prioritású levelek továbbítása [<code>X-Priority: 1</code>]",
+ "pushover_info": "A push értesítési beállítások az összes tiszta (nem-spam) levélre vonatkoznak, amelyeket a <b>%s</b> címre kézbesítettek, beleértve az aliasokat is (megosztott, nem megosztott, címkézett).",
+ "pushover_only_x_prio": "Csak a magas prioritású leveleket vegye figyelembe [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Csak a következő feladói e-mail címeket vegye figyelembe <small>(vesszővel elválasztva)</small>",
+ "pushover_sender_regex": "Feladók egyeztetése a következő regex-szel",
+ "pushover_text": "Értesítési szöveg",
+ "pushover_title": "Értesítési cím",
+ "pushover_sound": "Hang",
+ "pushover_vars": "Ha nincs feladói szűrő meghatározva, minden e-mail figyelembe vételre kerül.<br>A Regex szűrők, valamint a pontos feladói ellenőrzések egyénileg definiálhatók, és sorban lesznek figyelembe véve. Nem függenek egymástól.<br>Használható változók a szöveghez és a címhez (kérjük, vegye figyelembe az adatvédelmi szabályzatokat)",
+ "pushover_verify": "Hitelesítő adatok ellenőrzése",
+ "quota_mb": "Kvóta (MiB)",
+ "quota_warning_bcc": "Kvóta figyelmeztetés BCC",
+ "quota_warning_bcc_info": "A figyelmeztetések külön másolatként lesznek elküldve a következő címzetteknek. A tárgyat a megfelelő felhasználónévvel egészítik ki zárójelben, például: <code>Quota warning (user@example.com)</code>.",
+ "ratelimit": "Arányszám-korlát",
+ "redirect_uri": "Átirányítási/Visszahívási URL",
+ "relay_all": "Az összes címzett továbbítása",
+ "relay_all_info": "↪ Ha úgy döntesz, hogy <b>nem</b> továbbítod az összes címzettet, akkor minden egyes címzett számára, akit továbbítani kell, létre kell hoznod egy (\"vak\") postafiókot.",
+ "relay_domain": "Továbbítsa ezt a tartományt",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Információ</div> Definiálhatsz szállítási térképeket ehhez a tartományhoz egyedi célállomásra. Ha nincs beállítva, egy MX lekérdezés történik.",
+ "relay_unknown_only": "Csak a nem létező postafiókok továbbítása. A létező postafiókok helyben lesznek kézbesítve.",
+ "relayhost": "Feladófüggő szállítások",
+ "remove": "Eltávolítás",
+ "resource": "Erőforrás",
+ "save": "Módosítások mentése",
+ "scope": "Hatókör",
+ "sender_acl": "Engedélyezés küldésre mint",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">A küldő ellenőrzése le van tiltva</span>",
+ "sender_acl_info": "Ha az A postafiók felhasználója küldhet a B postafiók felhasználójaként, a feladói cím nem jelenik meg automatikusan választható \"from\" mezőként a SOGo-ban.<br>\r\n A B postafiók felhasználójának delegálást kell létrehoznia a SOGo-ban, hogy az A postafiók felhasználója kiválaszthassa a címét feladóként. A SOGo-ban egy postafiók delegálásához használja a menüt (három pont) a postafiók neve jobb oldalán a bal felső sarokban, a levélnézetben. Ez a viselkedés nem vonatkozik az alias címekre.",
+ "sieve_desc": "Rövid leírás",
+ "sieve_type": "Szűrő típusa",
+ "skipcrossduplicates": "Átugrani a duplikált üzeneteket a mappák között (aki előbb jön, előbb kapja)",
+ "sogo_access": "Közvetlen továbbítás a SOGo-ra",
+ "sogo_access_info": "A bejelentkezés után a felhasználó automatikusan átirányításra kerül a SOGo-ra.",
+ "sogo_visible": "Alias látható a SOGo-ban",
+ "sogo_visible_info": "Ez az opció csak azokra az objektumokra vonatkozik, amelyek megjeleníthetők a SOGo-ban (megosztott vagy nem megosztott alias címek, amelyek legalább egy helyi postafiókra mutatnak). Ha el van rejtve, egy alias nem jelenik meg választható feladóként a SOGo-ban.",
+ "spam_alias": "Időkorlátos alias címek létrehozása vagy módosítása",
+ "spam_filter": "Spam szűrő",
+ "spam_policy": "Elemek hozzáadása vagy eltávolítása a tiltó- vagy engedélyezési listán",
+ "spam_score": "Egyéni spam pontszám beállítása",
+ "subfolder2": "Szinkronizálás a célállomáson egy almappába<br><small>(üres = ne használjon almappát)</small>",
+ "syncjob": "Szinkronizálási feladat szerkesztése",
+ "target_address": "Célcím(ek) <small>(vesszővel elválasztva)</small>",
+ "target_domain": "Cél domain",
+ "timeout1": "Időtúllépés a távoli állomáshoz való csatlakozáskor",
+ "timeout2": "Időtúllépés a helyi állomáshoz való csatlakozáskor",
+ "title": "Objektum szerkesztése",
+ "unchanged_if_empty": "Ha nem változik, hagyja üresen",
+ "username": "Felhasználónév",
+ "validate_save": "Érvényesítés és mentés"
},
"footer": {
"cancel": "Mégse",
@@ -52,18 +447,21 @@
"restart_container": "Konténer újraindítása",
"restart_container_info": "<b>Fontos:</b> A teljes újraindulás eltarthat egy ideig, kérjük várjon, amíg befejeződik!",
"restart_now": "Újraindítás most",
- "restarting_container": "Konténer újraindítása. Ez eltarthat egy darabig."
+ "restarting_container": "Konténer újraindítása. Ez eltarthat egy darabig.",
+ "hibp_check": "Ellenőrzés a haveibeenpwned.com-on",
+ "nothing_selected": "Nincs semmi kiválasztva"
},
"header": {
"administration": "Beállítások és részletek",
"apps": "Appok",
- "debug": "Rendszer információ",
+ "debug": "Információ",
"email": "E-Mail",
"mailcow_config": "Beállítások",
"quarantine": "Karantén",
"restart_netfilter": "Netfilter újraindítása",
"restart_sogo": "SOGo újraindítása",
- "user_settings": "Felhasználó beállításai"
+ "user_settings": "Felhasználó beállításai",
+ "mailcow_system": "Rendszer"
},
"info": {
"awaiting_tfa_confirmation": "TFA megerősítésre várakozás",
@@ -75,7 +473,23 @@
"login": "Bejelentkezés",
"mobileconfig_info": "A kért Apple kapcsolat profil letöltéséhez jelentkezzen be, mint postafiók-felhasználó.",
"password": "Jelszó",
- "username": "Felhasználónév"
+ "username": "Felhasználónév",
+ "back_to_mailcow": "Vissza a mailcow-hoz",
+ "fido2_webauthn": "FIDO2/WebAuthn bejelentkezés",
+ "forgot_password": "> Elfelejtett jelszó?",
+ "invalid_pass_reset_token": "A jelszó-helyreállítási token érvénytelen vagy lejárt.<br>Kérjen új jelszó-helyreállítási linket.",
+ "login_linkstext": "Nem a megfelelő bejelentkezés?",
+ "login_usertext": "Bejelentkezés felhasználóként",
+ "login_domainadmintext": "Bejelentkezés domain adminisztrátorként",
+ "login_admintext": "Bejelentkezés adminisztrátorként",
+ "login_user": "Felhasználói bejelentkezés",
+ "login_dadmin": "Domain-adminisztrátori bejelentkezés",
+ "login_admin": "Adminisztrátori bejelentkezés",
+ "new_password": "Új jelszó",
+ "new_password_confirm": "Új jelszó megerősítése",
+ "other_logins": "vagy bejelentkezés",
+ "reset_password": "Jelszó visszaállítása",
+ "request_reset_password": "Jelszó módosítás kérése"
},
"mailbox": {
"action": "Művelet",
@@ -93,10 +507,10 @@
"add_resource": "Erőforrás hozzáadása",
"add_tls_policy_map": "TLS irányelv-térkép hozzáadása",
"address_rewriting": "Címátírás",
- "alias": "Alias",
+ "alias": "Álnév",
"alias_domain_backupmx": "Alias domain inaktív a továbbító domain részére",
- "aliases": "Alias-ok",
- "allow_from_smtp": "Kizárólag ezek az IP-címek használhatják az <b>SMTP</b>-t",
+ "aliases": "Álnevek",
+ "allow_from_smtp": "Kizárólag ezek az IP címek használhatják az <b>SMTP</b>-t",
"allow_from_smtp_info": "Hagyja üresen minden feladó engedélyezéséhez.<br>IPv4/IPv6 címek és hálózatok.",
"allowed_protocols": "Engedélyezett protokollok",
"backup_mx": "Továbbító domain",
@@ -114,7 +528,7 @@
"domain_admins": "Domain adminisztrátorok",
"domain_aliases": "Domain alias-ok",
"domain_quota": "Kvóta",
- "domains": "Domain-ek",
+ "domains": "Domainek",
"edit": "Szerkesztés",
"empty": "Nincs találat",
"enable_x": "Engedélyezés",
@@ -170,7 +584,87 @@
"toggle_all": "Összes átváltása",
"username": "Felhasználónév",
"waiting": "Várakozás",
- "weekly": "Hetente"
+ "weekly": "Hetente",
+ "add_alias_expand": "Alias kiterjesztése alias tartományokra",
+ "alias_domain_alias_hint": "Az aliasok <b>nem</b> vonatkoznak automatikusan a domain aliasokra. Egy <code>my-alias@domain</code> alias cím <b>nem</b> fedezi a <code>my-alias@alias-domain</code> címet (ahol az \"alias-domain\" a \"domain\" képzeletbeli alias tartománya).<br>Kérjük, használjon sieve szűrőt a levél külső postafiókba történő átirányításához (lásd a \"Szűrők\" fület vagy a SOGo -> Továbbító). Használja az \"Alias kiterjesztése alias tartományokra\" opciót a hiányzó aliasok automatikus hozzáadásához.",
+ "all_domains": "Minden tartomány",
+ "bcc_info": "A BCC térképek arra szolgálnak, hogy csendesen továbbítsák az összes üzenet másolatát egy másik címre. A címzett térkép típust akkor használják, ha a helyi célpont egy levél címzettjeként működik. A feladói térképek ugyanazon elv szerint működnek.<br/>\r\n A helyi célpontot nem értesítik a sikertelen kézbesítésről.",
+ "bcc_map_type": "BCC típus",
+ "bcc_maps": "BCC térképek",
+ "bcc_rcpt_map": "Címzett térkép",
+ "bcc_sender_map": "Feladó térkép",
+ "bcc_to_rcpt": "Váltás címzett térkép típusra",
+ "bcc_to_sender": "Váltás feladó térkép típusra",
+ "bcc_type": "BCC típus",
+ "booking_null": "Mindig szabadként mutat",
+ "booking_0_short": "Mindig szabad",
+ "booking_custom": "Kemény korlát a foglalások egyéni számára",
+ "booking_custom_short": "Kemény korlát",
+ "booking_ltnull": "Korlátlan, de foglaltnak mutatja magát, ha le van foglalva",
+ "booking_lt0_short": "Lágy korlát",
+ "catch_all": "Catch-All",
+ "created_on": "Létrehozva",
+ "dkim_domains_selector": "Válogató",
+ "dkim_key_length": "DKIM kulcs hossza (bit)",
+ "domain_templates": "Domain sablonok",
+ "domain_quota_total": "Teljes domain kvóta",
+ "gal": "Globális címlista",
+ "goto_ham": "Tanulás <b>ham</b>-ként",
+ "goto_spam": "Tanulás <b>spam</b>-ként",
+ "iam": "Azonosítási szolgáltató",
+ "last_modified": "Utoljára módosítva",
+ "last_pw_change": "Utolsó jelszócsere",
+ "mailbox_defaults": "Alapértelmezett beállítások",
+ "mailbox_defaults_info": "Alapértelmezett beállítások meghatározása az új postafiókokhoz.",
+ "mailbox_templates": "Postafiók sablonok",
+ "max_aliases": "Max. aliasok",
+ "max_mailboxes": "Max. lehetséges postafiókok",
+ "max_quota": "Max. kvóta postafiókonként",
+ "no": "✕",
+ "open_logs": "Naplók megnyitása",
+ "q_add_header": "amikor a levélszemét mappába kerül",
+ "q_all": " amikor a levélszemét mappába kerül és elutasításkor",
+ "q_reject": "elutasításkor",
+ "quarantine_category": "Karantén értesítési kategória",
+ "recipient": "Címzett",
+ "recipient_map_info": "A címzett térképeket arra használják, hogy egy üzenet célcímét kicseréljék, mielőtt azt kézbesítenék.",
+ "recipient_map_new_info": "A címzett térkép célja érvényes e-mail címnek vagy tartománynévnek kell lennie.",
+ "recipient_map_old_info": "Egy címzett térkép eredeti céljának érvényes e-mail címnek vagy tartománynévnek kell lennie.",
+ "relay_all": "Az összes címzett továbbítása",
+ "relay_unknown": "Ismeretlen postafiókok továbbítása",
+ "sender": "Feladó",
+ "set_postfilter": "Megjelölés poszt-szűrőként",
+ "set_prefilter": "Megjelölés pre-szűrőként",
+ "sieve_info": "Több szűrőt is tárolhatsz felhasználónként, de egyszerre csak egy pre-szűrő és egy poszt-szűrő lehet aktív.<br>\r\nMinden szűrő a leírt sorrendben lesz feldolgozva. Sem a sikertelen szkript, sem a kiadott \"keep;\" parancs nem állítja le a további szkriptek feldolgozását. A globális sieve szkriptek változásai a Dovecot újraindítását váltják ki.<br><br>Globális sieve pre-szűrő • Pre-szűrő • Felhasználói szkriptek • Poszt-szűrő • Globális sieve poszt-szűrő",
+ "sieve_preset_1": "Levél eldobása valószínűleg veszélyes fájltípusokkal",
+ "sieve_preset_2": "Egy adott feladó e-mailjét mindig olvasottként jelölje meg",
+ "sieve_preset_3": "Csendesen elvetni, leállítani minden további sieve feldolgozást",
+ "sieve_preset_4": "Fájl az INBOX-ba, kihagyni a további feldolgozást a sieve szűrőkkel",
+ "sieve_preset_5": "Auto válaszadó (szabadság)",
+ "sieve_preset_6": "Levél elutasítása válasszal",
+ "sieve_preset_7": "Átirányítás és megtartás/eldobás",
+ "sieve_preset_8": "E-mail átirányítása egy adott feladótól, olvasottként jelölés és almappába rendezés",
+ "sieve_preset_header": "Kérjük, nézze meg az alábbi példa-előrebeállításokat. További részletekért lásd a <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedia</a>-t.",
+ "sogo_visible": "Alias látható a SOGo-ban",
+ "sogo_visible_n": "Alias elrejtése a SOGo-ban",
+ "sogo_visible_y": "Alias megjelenítése a SOGo-ban",
+ "syncjob_check_log": "Napló ellenőrzése",
+ "syncjob_last_run_result": "Utolsó futás eredménye",
+ "syncjob_EX_OK": "Siker",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Kapcsolati probléma",
+ "syncjob_EXIT_TLS_FAILURE": "Probléma a titkosított kapcsolattal",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Hitelesítési probléma",
+ "syncjob_EXIT_OVERQUOTA": "A cél postafiók túllépte a kvótát",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Nem lehet csatlakozni a távoli szerverhez",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Hibás felhasználónév vagy jelszó",
+ "templates": "Sablonok",
+ "template": "Sablon",
+ "tls_map_policy": "Irányelv",
+ "tls_policy_maps": "TLS irányelv térképek",
+ "tls_policy_maps_enforced_tls": "Ezek az irányelvek felülírják a kimenő TLS szállítási szabályokat függetlenül a felhasználó TLS irányelvi beállításaitól. Ha nincs alább egyetlen irányelv sem, ezek a felhasználók az alapértelmezett értékeket alkalmazzák, amelyeket a <code>smtp_tls_mandatory_protocols</code> és a <code>smtp_tls_mandatory_ciphers</code> határoz meg.",
+ "tls_policy_maps_info": "Ez az irányelv térkép felülírja a kimenő TLS szállítási szabályokat függetlenül a felhasználó TLS irányelvi beállításaitól.<br>\r\n Kérjük, ellenőrizze a <a href=\"http://www.postfix.org/postconf.5.html#smtp_tls_policy_maps\" target=\"_blank\">\"smtp_tls_policy_maps\" dokumentációját</a> további információkért.",
+ "tls_policy_maps_long": "Kimenő TLS irányelv térkép felülírások",
+ "yes": "✓"
},
"oauth2": {
"access_denied": "Kérjük jelentkezzen be postafiók felhasználójával az OAuth2 használatához.",
@@ -194,7 +688,7 @@
"medium_danger": "Közepes veszély",
"neutral_danger": "Semleges",
"notified": "Értesítve",
- "qinfo": "A karantén-rendszer elmenti a visszautasított leveleket az adatbázisba, miközben a feladónak nem lesz az a benyomása, hogy a levelet kézbesítették.\r\n <br>\"Spamnek jelölés és törlés\" spam-ként jegyzi meg az üzenetet a Bayes-tétel segítségével, illetve fuzzy hash-eket számít, hogy hasonló üzenetek is spam-be kerüljenek a jövőben.\r\n <br>Több üzenet spamként való megjegyzése időigényes lehet.<br>Feketelistára vett levelek nem kerülnek karanténba.",
+ "qinfo": "A karantén-rendszer elmenti a visszautasított leveleket az adatbázisba, miközben a feladónak nem lesz az a benyomása, hogy a levelet kézbesítették.\r\n <br>\"Spamnek jelölés és törlés\" spam-ként jegyzi meg az üzenetet a Bayes-tétel segítségével, illetve fuzzy hash-eket számít, hogy hasonló üzenetek is spam-be kerüljenek a jövőben.\r\n <br>Több üzenet spamként való megjegyzése időigényes lehet.<br>Tiltólistára vett levelek nem kerülnek karanténba.",
"qitem": "Tétel",
"quarantine": "Karantén",
"quick_actions": "Műveletek",
@@ -217,16 +711,42 @@
"table_size_show_n": "%s tétel mutatása",
"text_from_html_content": "Tartalom (konvertált html)",
"text_plain_content": "Tartalom (sima szöveg)",
- "toggle_all": "Összes átkapcsolása"
+ "toggle_all": "Összes átkapcsolása",
+ "check_hash": "Fájl hash keresése @ VT",
+ "confirm": "Megerősítés",
+ "deliver_inbox": "Kézbesítés a beérkező mappába",
+ "disabled_by_config": "A jelenlegi rendszerkonfiguráció letiltja a karantén funkcionalitást. Kérjük, állítsa be a \"megőrzéseket postafiókonként\" és a \"maximális méretet\" a karantén elemek számára.",
+ "info": "Információ",
+ "junk_folder": "Levélszemét mappa",
+ "qhandler_success": "A kérés sikeresen elküldve a rendszernek. Most már bezárhatja az ablakot.",
+ "qid": "Rspamd QID",
+ "rejected": "Elutasítva",
+ "release_body": "A levelét eml fájlként csatoltuk ehhez az üzenethez.",
+ "rewrite_subject": "Tárgy átírása",
+ "settings_info": "A karanténba helyezhető elemek maximális száma: %s<br>Maximális e-mail méret: %s MiB",
+ "spam": "Spam",
+ "quick_info_link": "Információs link megnyitása",
+ "type": "Típus"
},
"queue": {
- "queue_manager": "Queue Manager"
+ "queue_manager": "Queue Manager",
+ "delete": "Összes törlése",
+ "flush": "Üzenetsor ürítése",
+ "info": "A levelezési üzenetsor tartalmazza az összes kézbesítésre váró e-mailt. Ha egy e-mail hosszú ideig ragad az üzenetsorban, a rendszer automatikusan törli.<br>A megfelelő levél hibaüzenete tájékoztatást ad arról, miért nem lehetett a levelet kézbesíteni.",
+ "legend": "A levelezési üzenetsor műveleti funkciói:",
+ "ays": "Kérjük, erősítse meg, hogy törölni szeretné az összes elemet az aktuális üzenetsorból.",
+ "deliver_mail": "Kézbesítés",
+ "deliver_mail_legend": "Megpróbálja újra kézbesíteni a kiválasztott leveleket.",
+ "hold_mail": "Visszatartás",
+ "hold_mail_legend": "Visszatartja a kiválasztott leveleket. (Megakadályozza a további kézbesítési kísérleteket)",
+ "show_message": "Üzenet megjelenítése",
+ "unban": "üzenetsor tiltás feloldása",
+ "unhold_mail": "Visszatartás feloldása",
+ "unhold_mail_legend": "Kiadja a kiválasztott leveleket a kézbesítéshez. (Előzetes visszatartás szükséges)"
},
"start": {
"help": "Súgó panel megjelenítése/elrejtése",
- "imap_smtp_server_auth_info": "Kérjük használja a teljes email címét és a PLAIN hitelesítési mechanizmust.<br>\r\nAdatai el lesznek kódolva szerver-oldali kötelező titkosítással.",
- "mailcow_apps_detail": "Használja a webmail appokat levelei, naptára és címjegyzéke eléréséhez.",
- "mailcow_panel_detail": "<b>Domain adminisztrátorok</b> létre tudnak hozni, tudnak módosítani vagy törölni postafiókokat és aliasokat, módosíthatnak domaineket és hozzáférnek további információhoz a domainükről.<br>\r\n<b>Postafiók-felhasználók</b> létre tudnak hozni időkorlátos alias-okat (spam alias-okat), le tudják cserélni jelszavakat, valamint spam szűrőket állíthatnak be."
+ "imap_smtp_server_auth_info": "Kérjük használja a teljes email címét és a PLAIN hitelesítési mechanizmust.<br>\r\nAdatai el lesznek kódolva szerver-oldali kötelező titkosítással."
},
"success": {
"admin_added": "Adminisztrátor %s hozzáadva",
@@ -275,7 +795,49 @@
"resource_modified": "Postafiók %s módosításai mentve",
"resource_removed": "Erőforrás %s eltávolítva",
"saved_settings": "Beállítások mentve",
- "upload_success": "File sikeresen feltöltve"
+ "upload_success": "File sikeresen feltöltve",
+ "acl_saved": "Az ACL a(z) %s objektumhoz mentve",
+ "bcc_deleted": "BCC térkép bejegyzések törölve: %s",
+ "bcc_edited": "BCC térkép bejegyzés %s szerkesztve",
+ "bcc_saved": "BCC térkép bejegyzés mentve",
+ "cors_headers_edited": "A CORS beállítások mentve",
+ "custom_login_modified": "A bejelentkezési testreszabás sikeresen mentve",
+ "domain_add_dkim_available": "Egy DKIM kulcs már létezett",
+ "dkim_duplicated": "A DKIM kulcs a(z) %s tartományhoz sikeresen átmásolva a(z) %s tartományba",
+ "domain_footer_modified": "A(z) %s tartományi lábléc módosításai mentve",
+ "f2b_banlist_refreshed": "A tiltólista azonosítója sikeresen frissítve.",
+ "f2b_modified": "A Fail2ban paraméterek módosításai mentve",
+ "forwarding_host_added": "A továbbító állomás %s hozzáadva",
+ "forwarding_host_removed": "A továbbító állomás %s eltávolítva",
+ "iam_test_connection": "Kapcsolat sikeres",
+ "ip_check_opt_in_modified": "Az IP ellenőrzés sikeresen mentve",
+ "nginx_reloaded": "Az Nginx újra lett töltve",
+ "password_policy_saved": "A jelszó házirend sikeresen mentve",
+ "password_changed_success": "A jelszó sikeresen megváltoztatva",
+ "pushover_settings_edited": "A Pushover beállítások sikeresen elmentve, kérjük, ellenőrizze a hitelesítő adatokat.",
+ "queue_command_success": "A sor parancs sikeresen befejeződött",
+ "recipient_map_entry_deleted": "A címzett térkép ID %s törölve",
+ "recipient_map_entry_saved": "A címzett térkép bejegyzés \"%s\" mentve",
+ "recovery_email_sent": "Helyreállítási e-mail elküldve a(z) %s címre",
+ "relayhost_added": "A térkép bejegyzés %s hozzáadva",
+ "relayhost_removed": "A térkép bejegyzés %s eltávolítva",
+ "reset_main_logo": "Visszaállítás alapértelmezett logóra",
+ "rl_saved": "Arányszám-korlát a(z) %s objektumhoz mentve",
+ "rspamd_ui_pw_set": "Rspamd UI jelszó sikeresen beállítva",
+ "settings_map_added": "Hozzáadott beállítási térkép bejegyzés",
+ "settings_map_removed": "Eltávolított beállítási térkép ID %s",
+ "sogo_profile_reset": "A SOGo profil a(z) %s felhasználóhoz visszaállítva",
+ "template_added": "Hozzáadott sablon %s",
+ "template_modified": "A(z) %s sablon módosításai mentve",
+ "template_removed": "A sablon ID %s törölve",
+ "tls_policy_map_entry_deleted": "TLS irányelv térkép ID %s törölve",
+ "tls_policy_map_entry_saved": "TLS irányelv térkép bejegyzés \"%s\" mentve",
+ "ui_texts": "A felhasználói felület szövegeinek módosításai mentve",
+ "verified_fido2_login": "FIDO2 bejelentkezés ellenőrizve",
+ "verified_totp_login": "TOTP bejelentkezés ellenőrizve",
+ "verified_webauthn_login": "WebAuthn bejelentkezés ellenőrizve",
+ "verified_yotp_login": "Yubico OTP bejelentkezés ellenőrizve",
+ "mailbox_renamed": "A postafiók átnevezve %s-ről %s-re"
},
"user": {
"action": "Művelet",
@@ -299,6 +861,7 @@
"create_syncjob": "Új szinkronizációs művelet létrehozása",
"daily": "Napi",
"day": "nap",
+ "description": "Leírás",
"delete_ays": "Erősítse meg a törlést.",
"direct_aliases": "Közvetlen alias címek",
"eas_reset": "ActiveSync eszköz gyorsítótár ürítése",
@@ -343,15 +906,14 @@
"spam_score_reset": "Szerver szerinti alapértelmezésre visszaállítás",
"spamfilter": "Spam szűrő",
"spamfilter_behavior": "Osztályozás",
- "spamfilter_bl": "Feketelista",
- "spamfilter_bl_desc": "A feketelistán szereplő email címek mindig spam-ként lesznek kezelve és vissza lesznek utasítva. Joker karakter használható. A szűrő csak közvetlen aliasokra vonatkozik (alias egyetlen cél-postafiókkal), magára a postafiókra, illetve mindent elkapó aliasokra nem.",
+ "spamfilter_bl": "Tiltólista",
+ "spamfilter_bl_desc": "A tiltólistán szereplő email címek mindig spam-ként lesznek kezelve és vissza lesznek utasítva. Joker karakter használható. A szűrő csak közvetlen aliasokra vonatkozik (alias egyetlen cél-postafiókkal), magára a postafiókra, illetve mindent elkapó aliasokra nem.",
"spamfilter_default_score": "Alapértelmezett értékek",
"spamfilter_green": "Zöld: ez az üzenet nem spam",
"spamfilter_hint": "Az első érték az alacsony spam pontszámot, a második a magas spam pontszámot jelöli.",
"spamfilter_red": "Vörös: Ez az üzenet spam, a szerver el fogja vetni.",
"spamfilter_table_action": "Művelet",
"spamfilter_table_add": "Tétel hozzáadása",
- "spamfilter_table_empty": "Nincs megjeleníthető adat",
"spamfilter_table_remove": "eltávolítás",
"spamfilter_table_rule": "Szabály",
"spamfilter_wl": "Engedélyezőlista",
@@ -376,15 +938,88 @@
"waiting": "Várakozás",
"week": "hét",
"weekly": "heti",
- "weeks": "hét"
+ "weeks": "hét",
+ "aliases_also_send_as": "Küldhet még mint felhasználó",
+ "aliases_send_as_all": "Ne ellenőrizze a küldő hozzáférését a következő tartomány(ok) és annak alias tartományai számára",
+ "app_hint": "Az alkalmazás jelszavak alternatív jelszavak az IMAP, SMTP, CalDAV, CardDAV és EAS bejelentkezéshez. A felhasználónév változatlan marad. A SOGo webmail nem érhető el az alkalmazás jelszavakon keresztül.",
+ "allowed_protocols": "Engedélyezett protokollok",
+ "apple_connection_profile_complete": "Ez a kapcsolati profil tartalmazza az IMAP és SMTP paramétereket, valamint a CalDAV (naptárak) és CardDAV (névjegyek) útvonalakat egy Apple eszközhöz.",
+ "apple_connection_profile_mailonly": "Ez a kapcsolati profil csak IMAP és SMTP konfigurációs paramétereket tartalmaz egy Apple eszközhöz.",
+ "apple_connection_profile_with_app_password": "Új alkalmazás jelszó generálódik és hozzáadódik a profilhoz, így nem kell jelszót megadni az eszköz beállításakor. Kérjük, ne ossza meg a fájlt, mivel teljes hozzáférést biztosít a postafiókjához.",
+ "attribute": "Attribútum",
+ "authentication": "Hitelesítés",
+ "change_password_hint_app_passwords": "Fiókodnak %d alkalmazás jelszava van, amelyek nem lesznek megváltoztatva. Ezek kezeléséhez menj az Alkalmazás jelszavak fülre.",
+ "clear_recent_successful_connections": "Sikeres kapcsolatok törlése",
+ "created_on": "Létrehozva",
+ "direct_aliases_desc": "A közvetlen alias címeket érintik a spam szűrő és a TLS irányelv beállításai.",
+ "direct_protocol_access": "Ennek a postafiók felhasználónak <b>közvetlen, külső hozzáférése</b> van a következő protokollokhoz és alkalmazásokhoz. Ezt a beállítást az adminisztrátor vezérli. Az alkalmazás jelszavak létrehozhatók, hogy hozzáférést biztosítsanak az egyedi protokollokhoz és alkalmazásokhoz.<br>A \"Webmail\" gomb egységes bejelentkezést biztosít a SOGo-ra, és mindig elérhető.",
+ "eas_reset_help": "Sok esetben a eszköz gyorsítótárának visszaállítása segít egy sérült ActiveSync profil helyreállításában.<br><b>Figyelem:</b> Minden elem újra letöltődik!",
+ "empty": "Nincs eredmény",
+ "from": "feladó",
+ "is_catch_all": "Catch-all a tartomány(ok)hoz",
+ "last_pw_change": "Utolsó jelszócsere",
+ "last_ui_login": "Utolsó UI bejelentkezés",
+ "login_history": "Bejelentkezési előzmények",
+ "mailbox": "Postafiók",
+ "mailbox_general": "Általános",
+ "mailbox_settings": "Beállítások",
+ "month": "hónap",
+ "months": "hónap",
+ "open_logs": "Naplók megnyitása",
+ "open_webmail_sso": "Webmail",
+ "overview": "Áttekintés",
+ "password_reset_info": "Ha nincs megadva e-mail a jelszó-helyreállításhoz, ez a funkció nem használható.",
+ "protocols": "Protokollok",
+ "pushover_evaluate_x_prio": "Magas prioritású levelek továbbítása [<code>X-Priority: 1</code>]",
+ "pushover_info": "A push értesítési beállítások az összes tiszta (nem-spam) levélre vonatkoznak, amelyeket a <b>%s</b> címre kézbesítettek, beleértve az aliasokat is (megosztott, nem megosztott, címkézett).",
+ "pushover_only_x_prio": "Csak a magas prioritású leveleket vegye figyelembe [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "A következő feladói e-mail címek figyelembe vétele <small>(vesszővel elválasztva)</small>",
+ "pushover_sender_regex": "Feladók egyeztetése a következő regex-szel",
+ "pushover_text": "Értesítési szöveg",
+ "pushover_title": "Értesítési cím",
+ "pushover_sound": "Hang",
+ "pushover_vars": "Ha nincs feladói szűrő meghatározva, minden e-mail figyelembe vételre kerül.<br>A Regex szűrők, valamint a pontos feladói ellenőrzések egyénileg definiálhatók, és sorban lesznek figyelembe véve. Nem függenek egymástól.<br>Használható változók a szöveghez és a címhez (kérjük, vegye figyelembe az adatvédelmi szabályzatokat)",
+ "pushover_verify": "Hitelesítő adatok ellenőrzése",
+ "pw_recovery_email": "Jelszó-helyreállítási e-mail",
+ "q_add_header": "Levélszemét mappa",
+ "q_all": "Összes kategória",
+ "q_reject": "Elutasítva",
+ "quarantine_category": "Karantén értesítési kategória",
+ "quarantine_category_info": "Az \"Elutasítva\" értesítési kategória magában foglalja azokat a leveleket, amelyeket elutasítottak, míg a \"Levélszemét mappa\" értesíti a felhasználót a levélszemét mappába helyezett levelekről.",
+ "recent_successful_connections": "Látott sikeres kapcsolatok",
+ "shared_aliases_desc": "A megosztott aliasokat nem érintik a felhasználóspecifikus beállítások, mint a spam szűrő vagy a titkosítási szabályzat. A megfelelő spam szűrőket csak egy adminisztrátor hozhatja létre tartományszintű szabályzatként.",
+ "sogo_profile_reset": "SOGo profil visszaállítása",
+ "sogo_profile_reset_help": "Ez tönkreteszi a felhasználó SOGo profilját, és <b>visszavonhatatlanul törli az összes névjegy- és naptáradatot</b>.",
+ "sogo_profile_reset_now": "Profil visszaállítása most",
+ "spamfilter_table_domain_policy": "n/a (tartományi szabályzat)",
+ "syncjob_check_log": "Napló ellenőrzése",
+ "syncjob_last_run_result": "Utolsó futás eredménye",
+ "syncjob_EX_OK": "Siker",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Kapcsolati probléma",
+ "syncjob_EXIT_TLS_FAILURE": "Probléma a titkosított kapcsolattal",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Hitelesítési probléma",
+ "syncjob_EXIT_OVERQUOTA": "A cél postafiók túllépte a kvótát",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Nem lehet csatlakozni a távoli szerverhez",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Hibás felhasználónév vagy jelszó",
+ "tfa_info": "A kétlépcsős hitelesítés segít megvédeni a fiókodat. Ha engedélyezed, alkalmazás jelszavakra lesz szükséged, hogy bejelentkezz olyan alkalmazásokba vagy szolgáltatásokba, amelyek nem támogatják a kétlépcsős hitelesítést (pl. levelező kliensek).",
+ "tls_policy_warning": "<strong>Figyelem:</strong> Ha titkosított levélátvitelt kényszerítesz ki, elveszíthetsz e-maileket.<br>Azok az üzenetek, amelyek nem felelnek meg a szabályzatnak, kemény hibával visszapattannak a levelezőrendszerből.<br>Ez az opció a fő e-mail címedre (bejelentkezési név), az alias tartományokból származó összes címre, valamint az alias címekre vonatkozik, amelyeknek <b>csak ez az egy postafiók</b> a célja.",
+ "value": "Érték",
+ "with_app_password": "alkalmazás jelszóval",
+ "year": "év",
+ "years": "év"
},
"warning": {
"cannot_delete_self": "Bejelentkezett felhasználó nem törölhető.",
- "ip_invalid": "Érvénytelen IP-cím átugorva: %s",
+ "ip_invalid": "Érvénytelen IP cím átugorva: %s",
"no_active_admin": "Utolsó aktív admin felhasználó nem deaktiválható.",
"quota_exceeded_scope": "Domain kvóta átlépve: csak korlátok nélküli postafiókok hozhatók létre ebben a domain-ben.",
- "session_token": "Űrlap-token érvénytelen: Tokenek nem egyeznek",
- "session_ua": "Űrlap-token érvénytelen: User-Agent hitelesítési probléma"
+ "session_token": "Űrlaptoken érvénytelen: Tokenek nem egyeznek",
+ "session_ua": "Űrlaptoken érvénytelen: User-Agent hitelesítési probléma",
+ "domain_added_sogo_failed": "A tartomány hozzáadva, de a SOGo újraindítása sikertelen, kérjük, ellenőrizze a szerver naplókat.",
+ "dovecot_restart_failed": "A Dovecot újraindítása sikertelen, kérjük, ellenőrizze a naplókat",
+ "fuzzy_learn_error": "Fuzzy hash tanulási hiba: %s",
+ "hash_not_found": "A hash nem található vagy már törölve lett",
+ "is_not_primary_alias": "Nem elsődleges alias %s kihagyva"
},
"acl": {
"delimiter_action": "Elhatárolás",
@@ -399,13 +1034,233 @@
"protocol_access": "Protokoll-hozzáférés módosítása",
"quarantine_attachments": "Karantén mellékletek",
"quarantine_category": "Karantén értesítési kategória módosítása",
- "quarantine_notification": "Karantén értesítések módosítása"
+ "quarantine_notification": "Karantén értesítések módosítása",
+ "eas_reset": "EAS-eszközök alaphelyzetbe állítása",
+ "extend_sender_acl": "Küldő ACL külső címekkel való bővítésének engedélyezése",
+ "mailbox_relayhost": "Relayhost módosítása egy postafiókhoz",
+ "prohibited": "ACL által tiltott",
+ "pushover": "Pushover",
+ "ratelimit": "Mérték határ",
+ "recipient_maps": "Címzett térképek",
+ "smtp_ip_access": "Az SMTP engedélyezett állomásainak módosítása",
+ "sogo_profile_reset": "SOGo profil visszaállítása",
+ "spam_alias": "Ideiglenes álnevek",
+ "spam_policy": "Tiltó/engedélyezési lista",
+ "spam_score": "Spam pontszám",
+ "syncjobs": "Szinkronizálási feladatok",
+ "tls_policy": "TLS szabályzat",
+ "unlimited_quota": "Korlátlan kvóta a postafiókok számára",
+ "sogo_access": "A SOGo-hozzáférés kezelésének lehetővé tétele",
+ "pw_reset": "Lehetővé teszi a mailcow felhasználói jelszavak visszaállítását"
},
"diagnostics": {
- "dns_records": "DNS bejegyzések"
+ "dns_records": "DNS bejegyzések",
+ "cname_from_a": "Az A/AAAA rekordból származó érték. Ez addig támogatott, amíg a rekord a megfelelő erőforrásra mutat.",
+ "dns_records_24hours": "Kérjük, vegye figyelembe, hogy a DNS-ben végrehajtott változtatások akár 24 órát is igénybe vehetnek, amíg a jelenlegi állapotuk helyesen megjelenik ezen az oldalon. Ez a célja, hogy könnyen láthassa, hogyan kell konfigurálnia a DNS rekordokat, és ellenőrizze, hogy az összes rekordja helyesen van-e tárolva a DNS-ben.",
+ "dns_records_data": "Helyes adatok",
+ "dns_records_docs": "Kérjük, konzultáljon a <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">dokumentációval</a> is.",
+ "dns_records_name": "Név",
+ "dns_records_status": "Jelenlegi állapot",
+ "dns_records_type": "Típus",
+ "optional": "Ez a rekord opcionális."
},
"add": {
"username": "Felhasználónév",
- "validation_success": "Sikeres ellenőrzés"
+ "validation_success": "Sikeres ellenőrzés",
+ "mailbox_quota_def": "Alapértelmezett postafiók kvóta",
+ "password_repeat": "Megerősítő jelszó (ismétlés)",
+ "post_domain_add": "A \"sogo-mailcow\" SOGo konténert újra kell indítani egy új tartomány hozzáadása után!<br><br>Kiegészítésképpen a tartományok DNS-konfigurációját is felül kell vizsgálni. A DNS-konfiguráció jóváhagyása után indítsa újra az \"acme-mailcow\"-t, hogy automatikusan generáljon tanúsítványokat az új tartományhoz (autoconfig.<domain>, autodiscover.<domain>).<br>Ez a lépés opcionális, és 24 óránként megismétlődik.",
+ "dry": "Szinkronizálás szimulálása",
+ "inactive": "Inaktív",
+ "kind": "Típus",
+ "mailbox_quota_m": "Maximális kvóta postafiókonként (MiB)",
+ "mailbox_username": "Felhasználónév (az e-mail cím bal oldali része)",
+ "max_aliases": "Max. lehetséges álnevek",
+ "max_mailboxes": "Max. lehetséges postafiókok",
+ "mins_interval": "A lekérdezési időköz (perc)",
+ "password": "Jelszó",
+ "port": "Port",
+ "public_comment": "Nyilvános megjegyzés",
+ "target_domain": "Céltartomány",
+ "timeout1": "Időtúllépés a távoli állomáshoz való csatlakozáskor",
+ "timeout2": "Időtúllépés a helyi állomáshoz való csatlakozáskor",
+ "validate": "Érvényesítsd",
+ "description": "Leírás",
+ "destination": "Célállomás",
+ "disable_login": "Bejelentkezés letiltása (a bejövő leveleket továbbra is elfogadja)",
+ "domain_matches_hostname": "Domain %s megegyezik a hostnévvel",
+ "domain_quota_m": "Teljes tartományi kvóta (MiB)",
+ "enc_method": "Titkosítási módszer",
+ "exclude": "Objektumok kizárása (regex)",
+ "full_name": "Teljes név",
+ "gal": "Globális címlista",
+ "goto_ham": "Tanítás <span class=\"text-success\"><b>valódi</b></span> levélként",
+ "goto_null": "Leveleket csendben eldobni",
+ "goto_spam": "Tanítás <span class=\"text-danger\"><b>spam</b></span>ként",
+ "syncjob_hint": "Ne feledje, hogy a jelszavakat egyszerű szöveges formában kell elmenteni!",
+ "target_address": "Továbbítási címek",
+ "target_address_info": "<small>Teljes e-mail cím(ek) (vesszővel elválasztva).</small>",
+ "bcc_dest_format": "A BCC-célpontnak egyetlen érvényes e-mail címnek kell lennie.<br>Ha több címre kell másolatot küldenie, hozzon létre egy aliast, és használja azt.",
+ "comment_info": "A privát megjegyzés nem látható a felhasználó számára, míg a nyilvános megjegyzés tooltip-ként jelenik meg, amikor a felhasználó áttekintésében a megjegyzésre mutat.",
+ "custom_params": "Egyéni paraméterek",
+ "gal_info": "A GAL tartalmazza a tartomány összes objektumát, és egyetlen felhasználó sem szerkesztheti. A SOGo-ban a Szabad/Elfoglalt információ hiányzik, ha ki van kapcsolva! <b>Indítsa újra a SOGo-t a változások alkalmazásához.</b>",
+ "hostname": "Hoszt",
+ "backup_mx_options": "Továbbítási opciók",
+ "custom_params_hint": "Megfelelő: --param=xy, Rossz: --param xy",
+ "delete1": "Törlés a forrásból, ha befejeződött",
+ "delete2": "A forráson kívüli üzenetek törlése a célállomáson",
+ "delete2duplicates": "Duplikáltak törlése a célállomáson",
+ "domain": "Domain",
+ "nexthop": "Következő hop",
+ "tags": "Címkék",
+ "app_password": "Alkalmazás jelszó hozzáadása",
+ "private_comment": "Privát megjegyzés",
+ "alias_address_info": "<small>Teljes e-mail cím(ek) vagy @example.com, egy domainhez tartozó összes üzenetet elfogásához (vesszővel elválasztva). <b>csak mailcow tartományok</b>.</small>",
+ "generate": "generál",
+ "activate_filter_warn": "Az összes többi szűrő deaktiválódik, ha az aktív opció be van jelölve.",
+ "active": "Aktív",
+ "add": "Hozzáad",
+ "add_domain_only": "Csak domain hozzáadása",
+ "add_domain_restart": "Domain hozzáadása és a SOGo újraindítása",
+ "alias_address": "Alias cím(ek)",
+ "alias_domain": "Alias domain",
+ "alias_domain_info": "<small>Csak érvényes tartománynevek (vesszővel elválasztva).</small>",
+ "app_name": "Alkalmazás neve",
+ "app_passwd_protocols": "Engedélyezett protokollok az alkalmazás jelszavához",
+ "automap": "Próbálja automatikusan feltérképezni a mappákat (\"Elküldött elemek\", \"Elküldött\" => \"Elküldött\" stb.)",
+ "multiple_bookings": "Több foglalás",
+ "quota_mb": "Kvóta (MiB)",
+ "relay_all": "Az összes címzett továbbítása",
+ "relay_all_info": "↪ Ha úgy döntesz, hogy <b>nem</b> továbbítod az összes címzettet, akkor minden egyes címzett számára, akit továbbítani kell, létre kell hoznod egy (\"vak\") postafiókot.",
+ "relay_domain": "Továbbítsa ezt a tartományt",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Információ</div> Definiálhatsz szállítási térképeket ehhez a tartományhoz egyedi célállomásra. Ha nincs beállítva, egy MX lekérdezés történik.",
+ "relay_unknown_only": "Csak a nem létező postafiókok továbbítása. A létező postafiókok helyben lesznek kézbesítve.",
+ "relayhost_wrapped_tls_info": "Kérjük, <b>ne</b> használjon TLS-be csomagolt portokat (többnyire a 465-ös porton használatosak).<br>\r\nHasználjon bármilyen nem csomagolt portot és adjon ki STARTTLS-t. A TLS kikényszerítésére egy TLS irányelv hozható létre a \"TLS irányelv térképek\" alatt.",
+ "select": "Kérjük, válasszon...",
+ "select_domain": "Kérjük, először válasszon egy domaint",
+ "sieve_desc": "Rövid leírás",
+ "sieve_type": "Szűrő típusa",
+ "skipcrossduplicates": "Duplikált üzenetek átugrása mappák között (érkezési sorrendben)",
+ "subscribeall": "Feliratkozás minden mappára",
+ "syncjob": "Szinkronizálási feladat hozzáadása",
+ "internal": "Belső",
+ "internal_info": "Belső álnevek csak a saját domain vagy domain álnév számára elérhető.",
+ "sender_allowed": "Küldés engedélyezése ezzel az aliasszal"
+ },
+ "danger": {
+ "access_denied": "Hozzáférés megtagatva vagy nem megfelelő űrlap adat",
+ "alias_domain_invalid": "Az alias domain %s érvénytelen",
+ "alias_empty": "Az alias cím nem lehet üres",
+ "alias_goto_identical": "Az alias és a goto cím nem lehetnek azonosak",
+ "alias_invalid": "Az alias cím %s érvénytelen",
+ "aliasd_targetd_identical": "Az alias tartomány nem lehet azonos a céltartománnyal: %s",
+ "aliases_in_use": "A maximális aliasoknak nagyobbnak vagy egyenlőnek kell lenniük mint %d",
+ "app_name_empty": "Az alkalmazás neve nem lehet üres",
+ "app_passwd_id_invalid": "Alkalmazás jelszó ID %s érvénytelen",
+ "authsource_in_use": "A személyazonosság szolgáltatót nem lehet megváltoztatni vagy törölni, mivel ez jelenleg használatban van legalább 1 felhasználónál.",
+ "bcc_empty": "BCC cél nem lehet üres",
+ "bcc_exists": "A %s típushoz létezik egy %s típusú BCC térkép.",
+ "bcc_must_be_email": "A BCC cél %s nem érvényes e-mail cím",
+ "comment_too_long": "Túl hosszú megjegyzés, max 160 karakter megengedett",
+ "cors_invalid_method": "Érvénytelen Allow-Method lett megadva",
+ "cors_invalid_origin": "Érvénytelen Allow-Origin lett megadva",
+ "defquota_empty": "A postafiókonkénti alapértelmezett kvóta nem lehet 0.",
+ "demo_mode_enabled": "Demo mód engedélyezve",
+ "description_invalid": "A %s erőforrás leírása érvénytelen",
+ "dkim_domain_or_sel_exists": "A \"%s\" DKIM-kulcs létezik, és nem lesz felülírva",
+ "dkim_domain_or_sel_invalid": "DKIM tartomány vagy szelektor érvénytelen: %s",
+ "domain_cannot_match_hostname": "A tartomány nem egyezik a hostnévvel",
+ "domain_exists": "A %s domain már létezik",
+ "domain_invalid": "A domain név üres vagy érvénytelen",
+ "domain_not_empty": "Nem lehet eltávolítani a nem üres domaint %s",
+ "domain_not_found": "Nem található domain %s",
+ "domain_quota_m_in_use": "A domain kvótának nagyobbnak vagy egyenlőnek kell lennie %s MiB-nál",
+ "extended_sender_acl_denied": "hiányzó ACL külső küldő cím beállításához",
+ "extra_acl_invalid": "A \"%s\" külső feladó címe érvénytelen",
+ "extra_acl_invalid_domain": "Külső feladó \"%s\" érvénytelen tartományt használ",
+ "fido2_verification_failed": "FIDO2 ellenőrzés sikertelen: %s",
+ "file_open_error": "A fájl nem nyitható meg írásra",
+ "filter_type": "Rossz szűrőtípus",
+ "from_invalid": "A feladó nem lehet üres",
+ "generic_server_error": "Váratlan szerver hiba keletkezett. Vedd fel a kapcsolatot az adminisztrátorral.",
+ "global_filter_write_error": "Nem tudott szűrőfájlt írni: %s",
+ "global_map_invalid": "Globális térkép azonosítója %s érvénytelen",
+ "global_map_write_error": "Nem tudott globális térképet írni ID %s: %s",
+ "goto_empty": "Egy alias címnek legalább egy érvényes goto címet kell tartalmaznia.",
+ "goto_invalid": "Goto cím %s érvénytelen",
+ "ham_learn_error": "Ham tanulási hiba: %s",
+ "iam_test_connection": "Kapcsolódás sikertelen",
+ "imagick_exception": "Hiba: Kép olvasása közben Imagick hiba keletkezett",
+ "img_dimensions_exceeded": "A kép meghaladja a maximális méretet",
+ "img_invalid": "A képfájlt nem lehet érvényesíteni",
+ "img_size_exceeded": "A kép meghaladja a maximális fájl méretet",
+ "img_tmp_missing": "A képfájlt nem lehet érvényesíteni: Ideiglenes fájl nem található",
+ "invalid_bcc_map_type": "Érvénytelen a BCC térkép típusa",
+ "invalid_destination": "A \"%s\" célállomás formátum érvénytelen",
+ "invalid_filter_type": "Érvénytelen szűrőtípus",
+ "invalid_host": "Érvénytelen host megadva: %s",
+ "invalid_mime_type": "Érvénytelen mime típus",
+ "invalid_nexthop": "A következő ugrás formátuma érvénytelen",
+ "invalid_nexthop_authenticated": "A következő ugrás más hitelesítő adatokkal létezik, kérjük, először frissítse a meglévő hitelesítő adatokat ehhez a következő ugráshoz.",
+ "invalid_recipient_map_new": "Érvénytelen új címzett megadása: %s",
+ "invalid_recipient_map_old": "Érvénytelen eredeti címzett van megadva: %s",
+ "invalid_reset_token": "Érvénytelen visszaállító kulcs",
+ "ip_list_empty": "Az engedélyezett IP-k listája nem lehet üres",
+ "is_alias": "%s már ismert álnév címként",
+ "is_alias_or_mailbox": "%s már ismert alias, egy postafiók vagy egy alias tartományból kiterjesztett alias cím.",
+ "is_spam_alias": "%s már ismert ideiglenes alias cím (spam alias cím)",
+ "last_key": "Az utolsó kulcs nem törölhető, kérjük, helyette deaktiválja a TFA-t.",
+ "login_failed": "A bejelentkezés sikertelen",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "Az alapértelmezett kvóta meghaladja a maximális kvótakorlátot",
+ "mailbox_invalid": "A postafiók neve érvénytelen",
+ "mailbox_quota_exceeded": "A kvóta meghaladja a tartományi korlátot (max. %d MiB)",
+ "mailbox_quota_exceeds_domain_quota": "A maximális kvóta meghaladja a tartományi kvótakorlátot",
+ "mailbox_quota_left_exceeded": "Nincs elég hely (maradék hely: %d MiB)",
+ "mailboxes_in_use": "A maximális postafiókoknak nagyobbnak vagy egyenlőnek kell lenniük %d-vel.",
+ "malformed_username": "Hibás felhasználónév",
+ "map_content_empty": "A térkép tartalma nem lehet üres",
+ "max_age_invalid": "Maximális kor %s érvénytelen",
+ "max_alias_exceeded": "Max. aliasok túllépése",
+ "max_mailbox_exceeded": "Max. postafiókok túllépése (%d %d-ből %d)",
+ "max_quota_in_use": "A postafiók kvótának nagyobbnak vagy egyenlőnek kell lennie %d MiB-nél",
+ "maxquota_empty": "A postafiókonkénti maximális kvóta nem lehet 0.",
+ "mode_invalid": "%s mód érvénytelen",
+ "mx_invalid": "%s MX rekord érvénytelen",
+ "mysql_error": "MySQL hiba: %s",
+ "network_host_invalid": "Érvénytelen hálózat vagy állomás: %s",
+ "next_hop_interferes": "%s zavarja a nexthop %s-t",
+ "next_hop_interferes_any": "Egy meglévő következő ugrás zavarja a %s-t.",
+ "nginx_reload_failed": "Az Nginx újratöltése sikertelen: %s",
+ "no_user_defined": "Nincs felhasználó által meghatározott",
+ "object_exists": "Az objektum %s már létezik",
+ "object_is_not_numeric": "Az érték %s nem numerikus",
+ "password_complexity": "A jelszó nem felel meg a szabályzatnak",
+ "password_empty": "A jelszó nem lehet üres",
+ "password_mismatch": "A megerősítő jelszó nem egyezik",
+ "password_reset_invalid_user": "A fiók nem található vagy nem lett megadva visszaállításhoz email cím",
+ "password_reset_na": "A jelszó visszaállítás jelenleg nem elérhető. Vedd fel a kapcsolatot az adminisztrátorral.",
+ "policy_list_from_exists": "A megadott nevű rekord létezik",
+ "policy_list_from_invalid": "A rekord érvénytelen formátumú",
+ "private_key_error": "Privát kulcs hiba: %s",
+ "pushover_credentials_missing": "Pushover token és/vagy kulcs hiányzik",
+ "pushover_key": "A pushover kulcs rossz formátumú",
+ "pushover_token": "A Pushover token rossz formátumú",
+ "quota_not_0_not_numeric": "A kvótának numerikusnak és >= 0-nak kell lennie.",
+ "recipient_map_entry_exists": "Létezik egy \"%s\" címzett-térkép bejegyzés",
+ "redis_error": "Redis hiba lépett fel: %s",
+ "relayhost_invalid": "A(z) %s elem érvénytelen a leképezésben.",
+ "release_send_failed": "Az üzenet felszabadítása sikertelen: %s",
+ "reset_f2b_regex": "A regex-szűrő időtúllépés miatt nem állt le. Próbálja újra, vagy várjon egy kicsit, és töltse újra az oldalt.",
+ "resource_invalid": "A(z) %s erőforrásnév érvénytelen",
+ "rl_timeframe": "Érvénytelen időkeret a lekérdezési korláthoz",
+ "rspamd_ui_pw_length": "A Rspamd UI jelszónak legalább 6 karakter hosszúnak kell lennie.",
+ "script_empty": "A szkript nem lehet üres",
+ "sender_acl_invalid": "A küldőhöz tartozó ACL-érték (%s) érvénytelen",
+ "set_acl_failed": "Az ACL beállítása meghiúsult",
+ "settings_map_invalid": "Érvénytelen beállítás-leképezési azonosító: %s",
+ "recovery_email_failed": "A helyreállítási email kiküldése sikertelen. Kérlek, lépj kapcsolatba az adminisztrátorral!",
+ "reset_token_limit_exceeded": "Túl sok visszaállítási kísérlet. Kérjük, várjon, mielőtt újra próbálkozna.",
+ "required_data_missing": "Hiányzik a(z) szükséges %s adat",
+ "tfa_removal_blocked": "A kétfaktoros hitelesítés nem távolítható el, mert elengedhetetlen a fiókod használatához."
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.it-it.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.it-it.json
index f652784..de228b2 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.it-it.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.it-it.json
@@ -28,7 +28,8 @@
"spam_score": "Punteggio SPAM",
"syncjobs": "Processi di sync",
"tls_policy": "Politica TLS",
- "unlimited_quota": "Spazio illimitato per le caselle di posta"
+ "unlimited_quota": "Spazio illimitato per le caselle di posta",
+ "pw_reset": "Permettere di reimpostare la password dell'utente mailcow"
},
"add": {
"activate_filter_warn": "Tutti gli altri filtri saranno disattivati, quando è attivo.",
@@ -108,7 +109,10 @@
"bcc_dest_format": "Il destinatario in copia nascosta deve essere un singolo indirizzo email.<br>Se si vuole spedire una copia del messaggio a più destinatari, bisogna creare un alias ed utilizzarlo per questa opzione.",
"app_passwd_protocols": "Protocolli consentiti per la password dell'app",
"tags": "Tag",
- "dry": "Simula sincronizzazione"
+ "dry": "Simula sincronizzazione",
+ "internal": "Interno",
+ "internal_info": "Gli alias interni sono accessibili solo dal proprio dominio o dai domini alias.",
+ "sender_allowed": "Consenti l'invio con questo alias"
},
"admin": {
"access": "Accedi",
@@ -116,7 +120,7 @@
"activate_api": "Attiva API",
"activate_send": "Attiva bottone di invio",
"active": "Attiva",
- "active_rspamd_settings_map": "Active settings map",
+ "active_rspamd_settings_map": "Mappa delle impostazioni attive",
"add": "Aggiungi",
"add_admin": "Aggiungi amministratore",
"add_domain_admin": "Aggiungi amministratore di dominio",
@@ -124,17 +128,17 @@
"add_relayhost": "Add sender-dependent transport",
"add_relayhost_hint": "Tieni presente che i dati di autenticazione, se presenti, verranno archiviati come testo semplice.",
"add_row": "Aggiungi riga",
- "add_settings_rule": "Add settings rule",
+ "add_settings_rule": "Aggiungi regola delle impostazioni",
"add_transport": "Aggiungi transport",
"add_transports_hint": "Tieni presente che i dati di autenticazione, se presenti, verranno archiviati come testo semplice.",
"additional_rows": " righe aggiuntive inserite",
"admin": "Amministratore",
"admin_details": "Modifica impostazioni amministratore",
- "admin_domains": "Assengazioni di dominio",
+ "admin_domains": "Assegnazioni di dominio",
"admins": "Amministratori",
"admins_ldap": "Amministratori LDAP",
"advanced_settings": "Impostazioni avanzate",
- "api_allow_from": "Allow API access from these IPs/CIDR network notations",
+ "api_allow_from": "Consenti l'accesso API da questi indirizzi IP/notazione di rete CIDR",
"api_info": "Questa API è in modifica. La documentazione può essere trovata su <a href=\"/api\">/api</a>",
"api_key": "Chiave API",
"api_skip_ip_check": "Salta il controllo dell'IP per l'API",
@@ -156,7 +160,7 @@
"dkim_domains_selector": "Selettore",
"dkim_domains_wo_keys": "Seleziona i domini senza chiavi",
"dkim_from": "Da",
- "dkim_from_title": "Source domain to copy data from",
+ "dkim_from_title": "Dominio di origine da cui copiare i dati",
"dkim_key_length": "Lunghezza chiave DKIM (bits)",
"dkim_key_missing": "Chiave mancante",
"dkim_key_unused": "Chiave non usata",
@@ -182,8 +186,8 @@
"f2b_list_info": "Un host oppure una rete in blacklist, avrà sempre un peso maggiore rispetto ad una in whitelist. <b>L'aggiornamento della lista richiede alcuni secondi per la sua entrata in azione.</b>",
"f2b_max_attempts": "Tentativi massimi",
"f2b_max_ban_time": "Tempo massimo di blocco (s)",
- "f2b_netban_ipv4": "IPv4 subnet size to apply ban on (8-32)",
- "f2b_netban_ipv6": "IPv6 subnet size to apply ban on (8-128)",
+ "f2b_netban_ipv4": "Dimensione della subnet IPv4 su cui applicare il blocco (8-32)",
+ "f2b_netban_ipv6": "Dimensione della subnet IPv6 su cui applicare il blocco (8-128)",
"f2b_parameters": "Parametri Fail2ban",
"f2b_regex_info": "Log presi in considerazione: SOGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Retry window (s) for max. attempts",
@@ -219,16 +223,16 @@
"merged_vars_hint": "Greyed out rows were merged from <code>vars.(local.)inc.php</code> and cannot be modified.",
"message": "Messaggio",
"message_size": "Dimensione mesaggio",
- "nexthop": "Next hop",
+ "nexthop": "Prossimo hop",
"no": "✕",
"no_active_bans": "Nessun ban attivo",
"no_new_rows": "Nessuna ulteriore riga disponibile",
"no_record": "Nessun risultato",
"oauth2_client_id": "ID cliente",
- "oauth2_client_secret": "Client secret",
+ "oauth2_client_secret": "Chiave segreta del client",
"oauth2_info": "The OAuth2 implementation supports the grant type \"Authorization Code\" and issues refresh tokens.<br>\r\nThe server also automatically issues new refresh tokens, after a refresh token has been used.<br><br>\r\n• The default scope is <i>profile</i>. Only mailbox users can be authenticated against OAuth2. If the scope parameter is omitted, it falls back to <i>profile</i>.<br>\r\n• The <i>state</i> parameter is required to be sent by the client as part of the authorize request.<br><br>\r\nPaths for requests to the OAuth2 API: <br>\r\n<ul>\r\n <li>Authorization endpoint: <code>/oauth/authorize</code></li>\r\n <li>Token endpoint: <code>/oauth/token</code></li>\r\n <li>Resource page: <code>/oauth/profile</code></li>\r\n</ul>\r\nRegenerating the client secret will not expire existing authorization codes, but they will fail to renew their token.<br><br>\r\nRevoking client tokens will cause immediate termination of all active sessions. All clients need to re-authenticate.",
"oauth2_redirect_uri": "URI di reindirizzamento",
- "oauth2_renew_secret": "Generate new client secret",
+ "oauth2_renew_secret": "Genera una nuova chiave segreta per il client",
"oauth2_revoke_tokens": "Revoca tutti i token del client",
"optional": "facoltativo",
"password": "Password",
@@ -269,7 +273,7 @@
"recipients": "Destinatari",
"refresh": "Aggiorna",
"regen_api_key": "Rinnova la chiave delle API",
- "regex_maps": "Regex maps",
+ "regex_maps": "Mappe Regex",
"relay_from": "\"Da:\" indirizzi",
"relay_rcpt": "\"A:\" indirizzi",
"relay_run": "Esegui test",
@@ -286,7 +290,7 @@
"rsetting_no_selection": "Seleziona una regola",
"rsetting_none": "Nessuna regola presente",
"rsettings_insert_preset": "Insert example preset \"%s\"",
- "rsettings_preset_1": "Disable all but DKIM and rate limit for authenticated users",
+ "rsettings_preset_1": "Disattivare tutto tranne DKIM e il limite di velocità per gli utenti autenticati",
"rsettings_preset_2": "I postmaster vogliono lo spam",
"rsettings_preset_3": "Consenti solo mittenti specifici per una casella di posta (ad esempio: utilizzo solo come casella di posta interna)",
"rspamd_com_settings": "A setting name will be auto-generated, please see the example presets below. For more details see <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd docs</a>",
@@ -341,7 +345,41 @@
"rsettings_preset_4": "Disattivare Rspamd per un dominio",
"options": "Opzioni",
"cors_settings": "Impostazioni CORS",
- "copy_to_clipboard": "Testo copiato negli appunti!"
+ "copy_to_clipboard": "Testo copiato negli appunti!",
+ "f2b_manage_external": "Gestione esterna di Fail2Ban",
+ "password_reset_info": "Se non viene fornita alcuna e-mail di recupero, questa funzione non può essere utilizzata.",
+ "password_reset_tmpl_text": "Template testuale",
+ "logo_dark_label": "Invertito per la modalità scura",
+ "ip_check": "Controllo IP",
+ "password_reset_settings": "Impostazioni per il recupero della password",
+ "password_reset_tmpl_html": "Template HTML",
+ "password_settings": "Impostazioni della password",
+ "queue_unban": "sblocca",
+ "restore_template": "Lasciare vuoto per ripristinare il modello predefinito.",
+ "logo_normal_label": "Normale",
+ "app_hide": "Nascondi per il login",
+ "ip_check_disabled": "Il controllo IP è disabilitato. Puoi abilitarlo sotto <br><strong>Sistema > Configurazione > Opzioni > Personalizza </strong>",
+ "ip_check_opt_in": "Attiva l'utilizzo dei servizi di terze parti <strong>ipv4.mailcow.email</strong> e <strong> ipv6.mailcow.email</strong> per risolvere gli indirizzi IP esterni",
+ "iam_login_provisioning": "Creazione automatica di utenti al login",
+ "iam_port": "Porta",
+ "iam_redirect_url": "URL di reindirizzamento",
+ "iam_server_url": "URL server",
+ "iam_sso": "Single Sign-On",
+ "iam_test_connection": "Test connessione",
+ "iam_use_ssl": "Usa SSL",
+ "iam_use_tls": "Usa StartTLS",
+ "iam_version": "Versione",
+ "ignore_ssl_error": "Ignorare gli errori SSL",
+ "task": "Attività",
+ "login_page": "Pagina di accesso",
+ "filter": "Filtro",
+ "iam_attribute_field": "Campo attributo",
+ "iam_authorize_url": "Endpoint di autorizzazione",
+ "iam_auth_flow": "Flusso di autenticazione",
+ "iam_client_id": "ID cliente",
+ "iam_default_template": "Template predefinito",
+ "iam_host": "Host",
+ "iam_import_users": "Importa utenti"
},
"danger": {
"access_denied": "Accesso negato o form di login non corretto",
@@ -466,7 +504,17 @@
"template_exists": "Il template %s esiste già",
"template_id_invalid": "Il template con ID %s non è valido",
"img_dimensions_exceeded": "L'immagine supera la dimensione massima consentita",
- "img_size_exceeded": "L'immagine supera la dimensione massima del file"
+ "img_size_exceeded": "L'immagine supera la dimensione massima del file",
+ "extended_sender_acl_denied": "Autorizzazioni ACL mancanti per configurare indirizzi esterni come mittente",
+ "invalid_reset_token": "Token di reset non valido",
+ "password_reset_invalid_user": "La casella di posta elettronica non è stata trovata o non è stata impostata un'e-mail di recupero",
+ "password_reset_na": "Il recupero della password non è attualmente disponibile. Contattare l'amministratore.",
+ "recovery_email_failed": "Impossibile inviare un'e-mail di recupero. Contattare l'amministratore.",
+ "to_invalid": "Il destinatario non deve essere vuoto",
+ "iam_test_connection": "Connessione non riuscita",
+ "webauthn_authenticator_failed": "L'autenticator selezionato non è stato trovato",
+ "webauthn_username_failed": "L'authenticator selezionato appartiene ad un altro account",
+ "webauthn_publickey_failed": "Nessuna chiave pubblica è stata salvata per l'authenticator selezionato"
},
"debug": {
"chart_this_server": "Grafico (questo server)",
@@ -476,7 +524,6 @@
"external_logs": "Log esterni",
"history_all_servers": "Cronologia (tutti i server)",
"in_memory_logs": "In-memory logs",
- "jvm_memory_solr": "JVM memory usage",
"last_modified": "Ultima modifica",
"log_info": "<p>mailcow <b>in-memory logs</b> are collected in Redis lists and trimmed to LOG_LINES (%d) every minute to reduce hammering.\r\n <br>In-memory logs are not meant to be persistent. All applications that log in-memory, also log to the Docker daemon and therefore to the default logging driver.\r\n <br>The in-memory log type should be used for debugging minor issues with containers.</p>\r\n <p><b>External logs</b> are collected via API of the given application.</p>\r\n <p><b>Static logs</b> are mostly activity logs, that are not logged to the Dockerd but still need to be persistent (except for API logs).</p>",
"login_time": "Orario",
@@ -485,8 +532,6 @@
"restart_container": "Riavvio",
"service": "Servizio",
"size": "Dimensione",
- "solr_dead": "Solr sta partendo, è disabilitato o morto.",
- "solr_status": "Stato Solr",
"started_at": "Iniziato alle",
"started_on": "Iniziato",
"static_logs": "Log statici",
@@ -503,7 +548,11 @@
"memory": "Memoria",
"timezone": "Fuso orario",
"no_update_available": "Il sistema è aggiornato all'ultima versione",
- "update_failed": "Impossibile verificare la presenza di un aggiornamento"
+ "update_failed": "Impossibile verificare la presenza di un aggiornamento",
+ "architecture": "Architettura",
+ "error_show_ip": "Impossibile risolvere gli indirizzi IP pubblici",
+ "show_ip": "Mostra IP pubblico",
+ "wip": "Attualmente in lavorazione"
},
"diagnostics": {
"cname_from_a": "Valore letto dal record A/AAAA. Questo è supportato finché il record punta alla risorsa corretta.",
@@ -624,15 +673,22 @@
"username": "Nome utente",
"validate_save": "Convalida e salva",
"pushover": "Pushover",
- "sogo_access_info": "Il single-sign-on dall'interno dell'interfaccia di posta rimane funzionante. Questa impostazione non influisce sull'accesso a tutti gli altri servizi né cancella o modifica il profilo SOGo esistente dell'utente.",
"none_inherit": "Nessuno / Eredita",
- "sogo_access": "Concedere l'accesso diretto a SOGo",
+ "sogo_access": "Inoltro diretto a SOGo",
+ "sogo_access_info": "Dopo aver effettuato il login, l'utente viene automaticamente reindirizzato a SOGo.",
"acl": "ACL (autorizzazione)",
"app_passwd_protocols": "Protocolli consentiti per la password dell'app",
"last_modified": "Ultima modifica",
"pushover_sound": "Suono",
"custom_attributes": "Attributi personalizzati",
- "domain_footer_skip_replies": "Ignora il piè di pagina nelle e-mail di risposta"
+ "domain_footer_skip_replies": "Ignora il piè di pagina nelle e-mail di risposta",
+ "domain_footer_html": "Piè di pagina HTML",
+ "domain_footer_plain": "Piè di pagina PLAIN",
+ "footer_exclude": "Escludi dal piè di pagina",
+ "password_recovery_email": "E-mail di recupero password",
+ "mailbox_rename": "Rinominare la casella mail",
+ "mailbox_rename_agree": "Ho creato un backup.",
+ "mailbox_rename_alias": "Creare alias automaticamente"
},
"fido2": {
"confirm": "Conferma",
@@ -686,9 +742,19 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Login",
"mobileconfig_info": "Please login as mailbox user to download the requested Apple connection profile.",
- "other_logins": "Key login",
+ "other_logins": "o accedi con",
"password": "Password",
- "username": "Nome utente"
+ "username": "Nome utente",
+ "request_reset_password": "Richiesta di modifica della password",
+ "back_to_mailcow": "Torna a mailcow",
+ "forgot_password": "> Password dimenticata?",
+ "new_password": "Nuova password",
+ "new_password_confirm": "Conferma la nuova password",
+ "reset_password": "Ripristino della password",
+ "login_linkstext": "Non è il login corretto?",
+ "login_usertext": "Accedere come utente",
+ "login_domainadmintext": "Accedere come domain admin",
+ "login_admintext": "Accedere come admin"
},
"mailbox": {
"action": "Azione",
@@ -793,9 +859,9 @@
"recipient_map": "Recipient map",
"recipient_map_info": "Recipient maps are used to replace the destination address on a message before it is delivered.",
"recipient_map_new": "New recipient",
- "recipient_map_new_info": "Recipient map destination must be a valid email address.",
+ "recipient_map_new_info": "Recipient map destination must be a valid email addresses or a domain name.",
"recipient_map_old": "Original recipient",
- "recipient_map_old_info": "A recipient maps original destination must be valid email addresses or a domain name.",
+ "recipient_map_old_info": "A recipient maps original destination must be a valid email addresses or a domain name.",
"recipient_maps": "Recipient maps",
"relay_all": "Trasmettere a tutti i destinatari",
"remove": "Rimuovi",
@@ -939,13 +1005,13 @@
"show_message": "Mostra messaggio",
"unhold_mail": "Sblocca",
"hold_mail_legend": "Blocca le mail selezionate. (Previene ulteriori tentativi di consegna)",
- "legend": "Funzioni delle azioni della coda di posta:"
+ "legend": "Funzioni delle azioni della coda di posta:",
+ "unban": "Coda di sblocco",
+ "unhold_mail_legend": "Rilascia le mail selezionate per la consegna. (Richiede una prenotazione preventiva)"
},
"start": {
"help": "Mostra/Nascondi pannello di aiuto",
- "imap_smtp_server_auth_info": "Please use your full email address and the PLAIN authentication mechanism.<br />\r\nYour login data will be encrypted by the server-side mandatory encryption.",
- "mailcow_apps_detail": "Usa l'app mailcow per accedere alla posta, calendari, contatti ed altro.",
- "mailcow_panel_detail": "<b>Amministratori di dominio</b> crea, modifica od elimina caselle ed alias, cambia i domini e informazioni relative ai domini associati.<br />\r\n\t<b>Utenti di caselle</b> possono creare degli alias temporanei (spam aliases), cambiare la loro password e le impostazioni relative ai filtri spam."
+ "imap_smtp_server_auth_info": "Please use your full email address and the PLAIN authentication mechanism.<br />\r\nYour login data will be encrypted by the server-side mandatory encryption."
},
"success": {
"acl_saved": "ACL for object %s saved",
@@ -1028,7 +1094,12 @@
"template_added": "Aggiunto template %s",
"template_modified": "Le modifiche al template %s sono state salvate",
"template_removed": "Il template con ID %s è stato cancellato",
- "f2b_banlist_refreshed": "L'ID della lista blocchi è stato aggiornato con successo."
+ "f2b_banlist_refreshed": "L'ID della lista blocchi è stato aggiornato con successo.",
+ "domain_footer_modified": "Le modifiche al piè di pagina del dominio %s sono state salvate",
+ "cors_headers_edited": "Le impostazioni CORS sono state salvate",
+ "ip_check_opt_in_modified": "Il controllo dell'indirizzo IP è stato salvato con successo",
+ "password_changed_success": "La password è stata modificata con successo",
+ "recovery_email_sent": "Email di recupero inviata a %s"
},
"tfa": {
"api_register": "%s usa le API Yubico Cloud. Richiedi una chiave API <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">qui</a>",
@@ -1087,6 +1158,7 @@
"created_on": "Creato il",
"daily": "Giornaliero",
"day": "giorno",
+ "description": "Descrizione",
"delete_ays": "Please confirm the deletion process.",
"direct_aliases": "Direct alias addresses",
"direct_aliases_desc": "Direct alias addresses are affected by spam filter and TLS policy settings.",
@@ -1129,7 +1201,7 @@
"no_active_filter": "No active filter available",
"no_last_login": "No last UI login information",
"no_record": "Nessun elemento",
- "open_webmail_sso": "Accedi alla webmail",
+ "open_webmail_sso": "Webmail",
"password": "Password",
"password_now": "Password attuale (conferma modifiche)",
"password_repeat": "Conferma password (riscrivi)",
@@ -1220,7 +1292,9 @@
"direct_protocol_access": "Questo utente della mailbox ha <b>accesso diretto ed esterno</b> ai seguenti protocolli e applicazioni. Questa impostazione è controllata dal tuo amministratore. Le password delle applicazioni possono essere create per garantire l'accesso ai singoli protocolli e applicazioni.<br>Il pulsante \"Accedi alla webmail\" fornisce un singolo accesso a SOGo ed è sempre disponibile.",
"pushover_sound": "Suono",
"attribute": "Attributo",
- "value": "Valore"
+ "value": "Valore",
+ "password_reset_info": "Se non viene fornita alcuna e-mail per il recupero della password, questa funzione non può essere utilizzata.",
+ "pw_recovery_email": "Email di recupero password"
},
"warning": {
"cannot_delete_self": "Cannot delete logged in user",
@@ -1264,6 +1338,7 @@
"aria": {
"sortAscending": ": attivare l'ordinamento crescente delle colonne",
"sortDescending": ": attivare l'ordinamento decrescente delle colonne"
- }
+ },
+ "decimal": "."
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ja-jp.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ja-jp.json
new file mode 100644
index 0000000..6dfa5d8
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ja-jp.json
@@ -0,0 +1,1339 @@
+{
+ "acl": {
+ "alias_domains": "エイリアスドメインを追加",
+ "app_passwds": "アプリパスワードの管理",
+ "bcc_maps": "BCCマップ",
+ "delimiter_action": "デリミタの動作",
+ "domain_desc": "ドメイン説明の変更",
+ "domain_relayhost": "ドメインのリレーホストを変更",
+ "eas_reset": "EASデバイスをリセット",
+ "extend_sender_acl": "外部アドレスで送信者ACLを拡張可能にする",
+ "filters": "フィルター",
+ "login_as": "メールボックスユーザーとしてログイン",
+ "mailbox_relayhost": "メールボックスのリレーホストを変更",
+ "prohibited": "ACLにより禁止されています",
+ "protocol_access": "プロトコルアクセスを変更",
+ "pushover": "Pushover",
+ "pw_reset": "mailcowユーザーパスワードのリセットを許可",
+ "quarantine": "隔離操作",
+ "quarantine_attachments": "隔離添付ファイル",
+ "quarantine_category": "隔離通知カテゴリの変更",
+ "quarantine_notification": "隔離通知の変更",
+ "ratelimit": "レート制限",
+ "recipient_maps": "受信者マップ",
+ "smtp_ip_access": "SMTPで許可されるホストの変更",
+ "sogo_access": "SOGoアクセス管理を許可",
+ "sogo_profile_reset": "SOGoプロファイルをリセット",
+ "spam_alias": "一時的なエイリアス",
+ "spam_policy": "ブラックリスト/ホワイトリスト",
+ "spam_score": "スパムスコア",
+ "syncjobs": "同期ジョブ",
+ "tls_policy": "TLSポリシー",
+ "unlimited_quota": "メールボックスの無制限クォータ"
+ },
+ "add": {
+ "activate_filter_warn": "有効を選択すると、他のすべてのフィルターは無効になります。",
+ "active": "有効",
+ "add": "追加",
+ "add_domain_only": "ドメインのみを追加",
+ "add_domain_restart": "ドメインを追加してSOGoを再起動",
+ "alias_address": "エイリアスアドレス",
+ "alias_address_info": "<small>完全なメールアドレスまたは@example.com(ドメインのすべてのメッセージをキャッチ、カンマ区切り)。<b>mailcowドメインのみ対応</b>。</small>",
+ "alias_domain": "エイリアスドメイン",
+ "alias_domain_info": "<small>有効なドメイン名のみ(カンマ区切り)。</small>",
+ "app_name": "アプリ名",
+ "app_password": "アプリパスワードを追加",
+ "app_passwd_protocols": "アプリパスワードの許可プロトコル",
+ "automap": "フォルダーを自動マッピングする試み(例:「送信済みアイテム」、「送信済み」=>「送信済み」)",
+ "backup_mx_options": "リレーオプション",
+ "bcc_dest_format": "BCC送信先は単一の有効なメールアドレスである必要があります。<br>複数のアドレスにコピーを送信する必要がある場合は、エイリアスを作成し、ここで使用してください。",
+ "comment_info": "プライベートコメントはユーザーには表示されませんが、パブリックコメントはユーザーの概要でホバーするとツールチップとして表示されます。",
+ "custom_params": "カスタムパラメータ",
+ "custom_params_hint": "正: --param=xy, 誤: --param xy",
+ "delete1": "完了時にソースから削除",
+ "delete2": "ソースに存在しないメッセージを送信先で削除",
+ "delete2duplicates": "送信先で重複を削除",
+ "description": "説明",
+ "destination": "送信先",
+ "disable_login": "ログインを禁止(受信メールは許可)",
+ "domain": "ドメイン",
+ "domain_matches_hostname": "ドメイン %s はホスト名と一致します",
+ "domain_quota_m": "ドメインの総クォータ(MiB)",
+ "dry": "同期をシミュレーション",
+ "enc_method": "暗号化方式",
+ "exclude": "オブジェクトを除外(正規表現)",
+ "full_name": "フルネーム",
+ "gal": "グローバルアドレスリスト",
+ "gal_info": "GALにはドメインのすべてのオブジェクトが含まれ、どのユーザーも編集できません。無効にすると、SOGoの空き/取り込み情報が表示されなくなります!<b>変更を適用するにはSOGoを再起動してください。</b>",
+ "generate": "生成",
+ "goto_ham": "<span class=\"text-success\"><b>ハム</b></span>として学習",
+ "goto_null": "メールを静かに破棄",
+ "goto_spam": "<span class=\"text-danger\"><b>スパム</b></span>として学習",
+ "hostname": "ホスト名",
+ "inactive": "無効",
+ "kind": "種類",
+ "mailbox_quota_def": "デフォルトのメールボックスクォータ",
+ "mailbox_quota_m": "メールボックスごとの最大クォータ(MiB)",
+ "mailbox_username": "ユーザー名(メールアドレスの左部分)",
+ "max_aliases": "作成可能なエイリアスの最大数",
+ "max_mailboxes": "作成可能なメールボックスの最大数",
+ "mins_interval": "ポーリング間隔(分)",
+ "multiple_bookings": "複数の予約",
+ "nexthop": "次のホップ",
+ "password": "パスワード",
+ "password_repeat": "確認用パスワード(再入力)",
+ "port": "ポート",
+ "post_domain_add": "新しいドメインを追加した後、SOGoコンテナ \"sogo-mailcow\" を再起動する必要があります。<br><br>さらに、ドメインのDNS設定を確認してください。DNS設定が承認されたら、\"acme-mailcow\" を再起動して新しいドメインの証明書を自動生成してください(autoconfig.<domain>, autodiscover.<domain>)。<br>この手順は任意で、24時間ごとに再試行されます。",
+ "private_comment": "プライベートコメント",
+ "public_comment": "パブリックコメント",
+ "quota_mb": "クォータ(MiB)",
+ "relay_all": "すべての受信者をリレー",
+ "relay_all_info": "<b>すべて</b>の受信者をリレーしない場合、リレーする各受信者のために(\"ブラインド\")メールボックスを追加する必要があります。",
+ "relay_domain": "このドメインをリレー",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">情報</div> このドメインのカスタム送信先のトランスポートマップを定義できます。設定されていない場合は、MXルックアップが実行されます。",
+ "relay_unknown_only": "存在しないメールボックスのみをリレー。存在するメールボックスはローカルに配信されます。",
+ "relayhost_wrapped_tls_info": "TLSラップされたポート(主にポート465で使用)を<b>使用しないでください</b>。<br>\r\n非ラップポートを使用し、STARTTLSを発行してください。TLSを強制するTLSポリシーを \"TLSポリシーマップ\" に作成できます。",
+ "select": "選択してください...",
+ "select_domain": "最初にドメインを選択してください",
+ "sieve_desc": "簡単な説明",
+ "sieve_type": "フィルタータイプ",
+ "skipcrossduplicates": "フォルダー間で重複するメッセージをスキップ(先着順)",
+ "subscribeall": "すべてのフォルダーを購読",
+ "syncjob": "同期ジョブを追加",
+ "syncjob_hint": "パスワードはプレーンテキストで保存される必要があることに注意してください!",
+ "tags": "タグ",
+ "target_address": "宛先アドレス",
+ "target_address_info": "<small>完全なメールアドレス(カンマ区切り)。</small>",
+ "target_domain": "ターゲットドメイン",
+ "timeout1": "リモートホストへの接続タイムアウト",
+ "timeout2": "ローカルホストへの接続タイムアウト",
+ "username": "ユーザー名",
+ "validate": "検証",
+ "validation_success": "正常に検証されました"
+ },
+ "admin": {
+ "access": "アクセス",
+ "action": "アクション",
+ "activate_api": "APIを有効化",
+ "activate_send": "送信ボタンを有効化",
+ "active": "アクティブ",
+ "active_rspamd_settings_map": "アクティブな設定マップ",
+ "add": "追加",
+ "add_admin": "管理者を追加",
+ "add_domain_admin": "ドメイン管理者を追加",
+ "add_forwarding_host": "転送ホストを追加",
+ "add_relayhost": "送信者依存のトランスポートを追加",
+ "add_relayhost_hint": "認証データがある場合、それはプレーンテキストとして保存されることに注意してください。",
+ "add_row": "行を追加",
+ "add_settings_rule": "設定ルールを追加",
+ "add_transport": "トランスポートを追加",
+ "add_transports_hint": "認証データがある場合、それはプレーンテキストとして保存されることに注意してください。",
+ "additional_rows": " 追加の行が追加されました",
+ "admin": "管理者",
+ "admin_details": "管理者の詳細を編集",
+ "admin_domains": "ドメインの割り当て",
+ "admins": "管理者",
+ "admins_ldap": "LDAP 管理者",
+ "advanced_settings": "詳細設定",
+ "allowed_methods": "Access-Control-Allow-Methods",
+ "allowed_origins": "Access-Control-Allow-Origin",
+ "api_allow_from": "これらのIPまたはCIDRネットワーク表記からのAPIアクセスを許可",
+ "api_info": "APIは進行中の作業です。ドキュメントは<a href=\"/api\">/api</a>にあります。",
+ "api_key": "APIキー",
+ "api_read_only": "読み取り専用アクセス",
+ "api_read_write": "読み取り書き込みアクセス",
+ "api_skip_ip_check": "APIのIPチェックをスキップ",
+ "app_links": "アプリリンク",
+ "app_name": "アプリ名",
+ "apps_name": "\"mailcow アプリ\" の名前",
+ "arrival_time": "到着時刻 (サーバー時刻)",
+ "authed_user": "認証済みユーザー",
+ "ays": "本当に続行しますか?",
+ "ban_list_info": "以下に禁止されたIPのリストを表示します: <b>ネットワーク (残りの禁止時間) - [アクション]</b>。<br />キューに入れられたIPは、数秒以内にアクティブな禁止リストから削除されます。<br />赤いラベルはブラックリストによる永久禁止を示します。",
+ "change_logo": "ロゴを変更",
+ "logo_normal_label": "通常",
+ "logo_dark_label": "ダークモード用の反転",
+ "configuration": "設定",
+ "convert_html_to_text": "HTMLをプレーンテキストに変換",
+ "copy_to_clipboard": "テキストがクリップボードにコピーされました!",
+ "cors_settings": "CORS設定",
+ "credentials_transport_warning": "<b>警告</b>: 新しいトランスポートマップエントリを追加すると、一致するネクストホップ列を持つすべてのエントリの認証情報が更新されます。",
+ "customer_id": "顧客ID",
+ "customize": "カスタマイズ",
+ "destination": "宛先",
+ "dkim_add_key": "ARC/DKIMキーを追加",
+ "dkim_domains_selector": "セレクタ",
+ "dkim_domains_wo_keys": "キーが不足しているドメインを選択",
+ "dkim_from": "From",
+ "dkim_from_title": "データをコピーする元のドメイン",
+ "dkim_key_length": "DKIMキー長 (ビット)",
+ "dkim_key_missing": "キーが不足しています",
+ "dkim_key_unused": "キーが未使用です",
+ "dkim_key_valid": "キーが有効です",
+ "dkim_keys": "ARC/DKIMキー",
+ "dkim_overwrite_key": "既存のDKIMキーを上書き",
+ "dkim_private_key": "プライベートキー",
+ "dkim_to": "To",
+ "dkim_to_title": "対象のドメイン - 上書きされます",
+ "domain": "ドメイン",
+ "domain_admin": "ドメイン管理者",
+ "domain_admins": "ドメイン管理者",
+ "domain_s": "ドメイン",
+ "duplicate": "重複",
+ "duplicate_dkim": "DKIMレコードを複製",
+ "edit": "編集",
+ "empty": "結果がありません",
+ "excludes": "これらの受信者を除外",
+ "f2b_ban_time": "禁止時間 (秒)",
+ "f2b_ban_time_increment": "禁止時間は各禁止ごとに増加します",
+ "f2b_blacklist": "ブラックリスト登録されたネットワーク/ホスト",
+ "f2b_filter": "正規表現フィルター",
+ "f2b_list_info": "ブラックリスト登録されたホストまたはネットワークは、常にホワイトリストよりも優先されます。<b>リストの更新には数秒かかります。</b>",
+ "f2b_manage_external": "Fail2Banを外部で管理",
+ "f2b_manage_external_info": "Fail2Banは引き続き禁止リストを管理しますが、トラフィックをブロックするルールをアクティブに設定しません。以下の生成された禁止リストを使用して外部でトラフィックをブロックしてください。",
+ "f2b_max_attempts": "最大試行回数",
+ "f2b_max_ban_time": "最大禁止時間 (秒)",
+ "f2b_netban_ipv4": "禁止を適用するIPv4サブネットサイズ (8-32)",
+ "f2b_netban_ipv6": "禁止を適用するIPv6サブネットサイズ (8-128)",
+ "f2b_parameters": "Fail2Banパラメータ",
+ "f2b_regex_info": "考慮されるログ: SOGo、Postfix、Dovecot、PHP-FPM。",
+ "f2b_retry_window": "最大試行回数のための再試行ウィンドウ (秒)",
+ "f2b_whitelist": "ホワイトリスト登録されたネットワーク/ホスト",
+ "filter_table": "フィルターテーブル",
+ "forwarding_hosts": "転送ホスト",
+ "forwarding_hosts_add_hint": "IPv4/IPv6アドレス、CIDR表記のネットワーク、ホスト名(IPアドレスに解決されます)、またはドメイン名(SPFレコードやMXレコードを照会してIPアドレスに解決)を指定できます。",
+ "forwarding_hosts_hint": "ここにリストされたホストからのメッセージは無条件に受け入れられます。これらのホストは、DNSBL(ブラックリスト)やグレイリスティングのチェック対象外となります。これらのホストから受信したスパムは拒否されませんが、オプションで迷惑メールフォルダーに振り分けることができます。最も一般的な使用例は、受信メールをmailcowサーバーに転送するように設定したメールサーバーを指定することです。",
+ "from": "送信元",
+ "generate": "生成",
+ "guid": "GUID - 一意のインスタンスID",
+ "guid_and_license": "GUID & ライセンス",
+ "hash_remove_info": "レート制限ハッシュ(まだ存在する場合)を削除すると、そのカウンターが完全にリセットされます。<br>\r\n各ハッシュは個別の色で表示されます。",
+ "help_text": "ログイン画面下部に表示するヘルプテキスト(HTML使用可能)",
+ "host": "ホスト",
+ "html": "HTML",
+ "import": "インポート",
+ "import_private_key": "プライベートキーをインポート",
+ "in_use_by": "使用中",
+ "inactive": "非アクティブ",
+ "include_exclude": "含める/除外する",
+ "include_exclude_info": "デフォルトでは(選択なしの場合)、<b>すべてのメールボックス</b>が対象となります",
+ "includes": "含める受信者",
+ "ip_check": "IPチェック",
+ "ip_check_disabled": "IPチェックが無効です。有効にするには<br> <strong>システム > 設定 > オプション > カスタマイズ</strong> から設定してください。",
+ "ip_check_opt_in": "外部サービス<strong>ipv4.mailcow.email</strong>および<strong>ipv6.mailcow.email</strong>を利用して外部IPアドレスを解決するオプトイン。",
+ "is_mx_based": "MXベース",
+ "last_applied": "最終適用",
+ "license_info": "ライセンスは必須ではありませんが、さらなる開発を支援します。<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">こちらでGUIDを登録</a>するか、<a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Support order\">mailcowインストールのサポートを購入</a>してください。",
+ "link": "リンク",
+ "loading": "お待ちください...",
+ "login_time": "ログイン時間",
+ "logo_info": "ナビゲーションバーの高さを40px、スタートページの最大幅を250pxにスケーリングします。スケーラブルな画像を推奨します。",
+ "lookup_mx": "宛先がMX名に一致する正規表現です(例:<code>.*\\.google\\.com</code> はgoogle.comで終わるMX宛のすべてのメールをこのホップにルートします)",
+ "main_name": "\"mailcow UI\" 名称",
+ "merged_vars_hint": "グレー表示された行は<code>vars.(local.)inc.php</code>からマージされており、変更できません。",
+ "message": "メッセージ",
+ "message_size": "メッセージサイズ",
+ "nexthop": "次のホップ",
+ "no": "✕",
+ "no_active_bans": "アクティブな禁止はありません",
+ "no_new_rows": "新しい行はありません",
+ "no_record": "レコードなし",
+ "oauth2_apps": "OAuth2 アプリ",
+ "oauth2_add_client": "OAuth2クライアントを追加",
+ "oauth2_client_id": "クライアントID",
+ "oauth2_client_secret": "クライアントシークレット",
+ "oauth2_info": "OAuth2は、\"Authorization Code\"のグラントタイプをサポートし、リフレッシュトークンを発行します。<br>\r\nサーバーはリフレッシュトークンが使用された後、自動的に新しいリフレッシュトークンを発行します。<br><br>\r\n• デフォルトのスコープは<i>profile</i>です。メールボックスユーザーのみOAuth2認証が可能です。スコープパラメータが省略されると、デフォルトで<i>profile</i>に戻ります。<br>\r\n• <i>state</i>パラメータは、クライアントが認可リクエストの一部として送信する必要があります。<br><br>\r\nOAuth2 APIリクエスト用のパス:<br>\r\n<ul>\r\n <li>認可エンドポイント: <code>/oauth/authorize</code></li>\r\n <li>トークンエンドポイント: <code>/oauth/token</code></li>\r\n <li>リソースページ: <code>/oauth/profile</code></li>\r\n</ul>\r\nクライアントシークレットを再生成しても既存の認可コードは失効しませんが、トークンの更新は失敗します。<br><br>\r\nクライアントトークンを取り消すと、すべてのアクティブなセッションが即座に終了します。すべてのクライアントは再認証が必要です。",
+ "oauth2_redirect_uri": "リダイレクトURI",
+ "oauth2_renew_secret": "新しいクライアントシークレットを生成",
+ "oauth2_revoke_tokens": "すべてのクライアントトークンを取り消す",
+ "optional": "任意",
+ "options": "オプション",
+ "password": "パスワード",
+ "password_length": "パスワード長",
+ "password_policy": "パスワードポリシー",
+ "password_policy_chars": "少なくとも1文字のアルファベットを含む必要があります",
+ "password_policy_length": "パスワードの最小長は %d です",
+ "password_policy_lowerupper": "大文字と小文字を含む必要があります",
+ "password_policy_numbers": "少なくとも1つの数字を含む必要があります",
+ "password_policy_special_chars": "特殊文字を含む必要があります",
+ "password_repeat": "確認用パスワード(再入力)",
+ "password_reset_info": "リカバリー用メールが提供されていない場合、この機能は使用できません。",
+ "password_reset_settings": "パスワードリカバリー設定",
+ "password_reset_tmpl_html": "HTMLテンプレート",
+ "password_reset_tmpl_text": "テキストテンプレート",
+ "password_settings": "パスワード設定",
+ "priority": "優先度",
+ "private_key": "プライベートキー",
+ "quarantine": "隔離",
+ "quarantine_bcc": "すべての通知をコピー(BCC)でこの受信者に送信:<br><small>無効にする場合は空欄にしてください。<b>署名なし、チェックされていないメール。内部でのみ配信してください。</b></small>",
+ "quarantine_exclude_domains": "ドメインおよびエイリアスドメインを除外",
+ "quarantine_max_age": "最大保存期間(日数)<br><small>値は1日以上である必要があります。</small>",
+ "quarantine_max_score": "スパムスコアがこの値を超えるメールの通知を破棄:<br><small>デフォルトは9999.0です。</small>",
+ "quarantine_max_size": "最大サイズ(MiB)(これを超える要素は破棄されます):<br><small>0は<b>無制限ではありません</b>。</small>",
+ "quarantine_notification_html": "通知メールのテンプレート:<br><small>空欄にするとデフォルトテンプレートに戻ります。</small>",
+ "quarantine_notification_sender": "通知メールの送信者",
+ "quarantine_notification_subject": "通知メールの件名",
+ "quarantine_redirect": "<b>すべての通知をリダイレクト</b>してこの受信者に送信:<br><small>無効にする場合は空欄にしてください。<b>署名なし、チェックされていないメール。内部でのみ配信してください。</b></small>",
+ "quarantine_release_format": "リリースされたアイテムの形式",
+ "quarantine_release_format_att": "添付ファイルとして",
+ "quarantine_release_format_raw": "変更されていないオリジナル",
+ "quarantine_retention_size": "メールボックスごとの保持量:<br><small>0は<b>無効</b>を示します。</small>",
+ "quota_notification_html": "通知メールのテンプレート:<br><small>空欄にするとデフォルトテンプレートに戻ります。</small>",
+ "quota_notification_sender": "通知メールの送信者",
+ "quota_notification_subject": "通知メールの件名",
+ "quota_notifications": "クォータ通知",
+ "quota_notifications_info": "クォータ通知は、使用率が80%と95%を超えたときに1回ずつユーザーに送信されます。",
+ "quota_notifications_vars": "{{percent}} はユーザーの現在のクォータ使用率を表します<br>{{username}} はメールボックスの名前です",
+ "queue_unban": "禁止解除",
+ "r_active": "アクティブな制限",
+ "r_inactive": "非アクティブな制限",
+ "r_info": "アクティブな制限リストでグレーアウトまたは無効化された要素は、mailcowで有効な制限として認識されていませんが、リストの順序に従って設定されます。<br>新しい要素を<code>inc/vars.local.inc.php</code>に追加することで切り替え可能にできます。",
+ "rate_name": "レート名",
+ "recipients": "受信者",
+ "refresh": "更新",
+ "regen_api_key": "APIキーを再生成",
+ "regex_maps": "正規表現マップ",
+ "relay_from": "\"送信元:\" アドレス",
+ "relay_rcpt": "\"受信先:\" アドレス",
+ "relay_run": "テストを実行",
+ "relayhosts": "送信者依存のトランスポート",
+ "relayhosts_hint": "送信者依存のトランスポートを定義し、ドメイン構成ダイアログで選択できるようにします。<br>\r\n トランスポートサービスは常に \"smtp:\" であり、提供された場合はTLSを試みます。TLSラップ(SMTPS)はサポートされていません。ユーザーごとの個別の送信TLSポリシー設定が考慮されます。<br>\r\n 選択したドメインおよびエイリアスドメインに影響します。",
+ "remove": "削除",
+ "remove_row": "行を削除",
+ "reset_default": "デフォルトにリセット",
+ "reset_limit": "ハッシュを削除",
+ "reset_password_vars": "<code>{{link}}</code> 生成されたパスワードリセットリンク<br><code>{{username}}</code> パスワードリセットをリクエストしたユーザーのメールボックス名<br><code>{{username2}}</code> リカバリーメールボックス名<br><code>{{date}}</code> パスワードリセットリクエストが行われた日付<br><code>{{token_lifetime}}</code> トークンの有効期間(分)<br><code>{{hostname}}</code> mailcowのホスト名",
+ "restore_template": "空欄にするとデフォルトテンプレートに戻ります。",
+ "routing": "ルーティング",
+ "rsetting_add_rule": "ルールを追加",
+ "rsetting_content": "ルールの内容",
+ "rsetting_desc": "簡単な説明",
+ "rsetting_no_selection": "ルールを選択してください",
+ "rsetting_none": "利用可能なルールがありません",
+ "rsettings_insert_preset": "例のプリセット \"%s\" を挿入",
+ "rsettings_preset_1": "認証済みユーザーに対してDKIMとレート制限以外を無効化",
+ "rsettings_preset_2": "ポストマスターはスパムを許可",
+ "rsettings_preset_3": "特定の送信者のみを許可(内部メールボックスとして使用)",
+ "rsettings_preset_4": "ドメインに対するRspamdを無効化",
+ "rspamd_com_settings": "設定名は自動生成されます。以下の例のプリセットをご覧ください。詳細については<a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamdのドキュメント</a>を参照してください。",
+ "rspamd_global_filters": "グローバルフィルターマップ",
+ "rspamd_global_filters_agree": "注意して操作します!",
+ "rspamd_global_filters_info": "グローバルフィルターマップには、ブラックリストやホワイトリストなど、さまざまな種類が含まれています。",
+ "rspamd_global_filters_regex": "名前はその目的を説明します。すべてのコンテンツは、\"/パターン/オプション\"(例: <code>/.+@domain\\.tld/i</code>)の形式で有効な正規表現を含む必要があります。<br>\r\n 正規表現の各行に対して簡易チェックが実行されますが、Rspamdが構文を正しく読み取れない場合、機能が損なわれる可能性があります。<br>\r\n マップの内容が変更された場合、Rspamdはそれを読み取ろうとします。問題が発生した場合は、<a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">Rspamdを再起動</a>してマップの再読み込みを強制してください。<br>ブラックリストに登録された要素は隔離の対象外です。",
+ "rspamd_settings_map": "Rspamd設定マップ",
+ "sal_level": "Mooレベル",
+ "save": "変更を保存",
+ "search_domain_da": "ドメインを検索",
+ "send": "送信",
+ "sender": "送信者",
+ "service": "サービス",
+ "service_id": "サービスID",
+ "source": "ソース",
+ "spamfilter": "スパムフィルター",
+ "subject": "件名",
+ "success": "成功",
+ "sys_mails": "システムメール",
+ "text": "テキスト",
+ "time": "時間",
+ "title": "タイトル",
+ "title_name": "\"mailcow UI\" サイトのタイトル",
+ "to_top": "トップへ戻る",
+ "transport_dest_format": "正規表現または構文: example.org, .example.org, *, box@example.org(複数の値はカンマ区切りで指定可能)",
+ "transport_maps": "トランスポートマップ",
+ "transport_test_rcpt_info": "• 外部宛先へのリレーをテストするには null@hosted.mailcow.de を使用してください。",
+ "transports_hint": "• トランスポートマップのエントリーは送信者依存のトランスポートマップを<b>上書き</b>します。<br>\r\n• MXベースのトランスポートが優先的に使用されます。<br>\r\n• ユーザーごとの送信TLSポリシー設定は無視され、TLSポリシーマップエントリーによってのみ強制できます。<br>\r\n• 定義されたトランスポートのトランスポートサービスは常に \"smtp:\" であり、提供された場合はTLSを試みます。TLSラップ(SMTPS)はサポートされていません。<br>\r\n• アドレスが \"/localhost$/\" に一致する場合、それらは常に \"local:\" 経由で転送されるため、\"*\" 宛先はこれらのアドレスには適用されません。<br>\r\n• 次のホップ \"[host]:25\" の認証情報を判定するために、Postfixは<b>常に</b> \"host\" を最初に照会し、その後 \"[host]:25\" を検索します。この動作により、\"host\" と \"[host]:25\" を同時に使用することはできません。",
+ "ui_footer": "フッター(HTML使用可)",
+ "ui_header_announcement": "お知らせ",
+ "ui_header_announcement_active": "お知らせを有効に設定",
+ "ui_header_announcement_content": "テキスト(HTML使用可)",
+ "ui_header_announcement_help": "お知らせはすべてのログイン済みユーザーとUIのログイン画面に表示されます。",
+ "ui_header_announcement_select": "お知らせタイプを選択",
+ "ui_header_announcement_type": "タイプ",
+ "ui_header_announcement_type_danger": "非常に重要",
+ "ui_header_announcement_type_info": "情報",
+ "ui_header_announcement_type_warning": "重要",
+ "ui_texts": "UIラベルとテキスト",
+ "unban_pending": "禁止解除保留中",
+ "unchanged_if_empty": "変更がない場合は空白のままにしてください",
+ "upload": "アップロード",
+ "username": "ユーザー名",
+ "validate_license_now": "GUIDをライセンスサーバーで検証",
+ "verify": "確認",
+ "yes": "✓"
+ },
+ "danger": {
+ "access_denied": "アクセスが拒否されるか、フォームデータが無効です",
+ "alias_domain_invalid": "エイリアスドメイン %s は無効です",
+ "alias_empty": "エイリアスアドレスを空にすることはできません",
+ "alias_goto_identical": "エイリアスと転送先アドレスは同一であってはなりません",
+ "alias_invalid": "エイリアスアドレス %s は無効です",
+ "aliasd_targetd_identical": "エイリアスドメインはターゲットドメインと同じであってはなりません: %s",
+ "aliases_in_use": "最大エイリアス数は %d 以上である必要があります",
+ "app_name_empty": "アプリ名を空にすることはできません",
+ "app_passwd_id_invalid": "アプリパスワードID %s は無効です",
+ "bcc_empty": "BCC送信先を空にすることはできません",
+ "bcc_exists": "BCCマップ %s がタイプ %s に存在します",
+ "bcc_must_be_email": "BCC送信先 %s は有効なメールアドレスではありません",
+ "comment_too_long": "コメントが長すぎます。最大160文字まで許可されます",
+ "cors_invalid_method": "指定された許可メソッドが無効です",
+ "cors_invalid_origin": "指定された許可オリジンが無効です",
+ "defquota_empty": "メールボックスごとのデフォルトクォータを0にすることはできません。",
+ "demo_mode_enabled": "デモモードが有効です",
+ "description_invalid": "リソース %s の説明が無効です",
+ "dkim_domain_or_sel_exists": "\"%s\" のDKIMキーが既に存在しており、上書きされません",
+ "dkim_domain_or_sel_invalid": "DKIMドメインまたはセレクタが無効です: %s",
+ "domain_cannot_match_hostname": "ドメインはホスト名と一致してはなりません",
+ "domain_exists": "ドメイン %s は既に存在します",
+ "domain_invalid": "ドメイン名が空か無効です",
+ "domain_not_empty": "非空のドメイン %s を削除することはできません",
+ "domain_not_found": "ドメイン %s が見つかりません",
+ "domain_quota_m_in_use": "ドメインクォータは %s MiB 以上である必要があります",
+ "extended_sender_acl_denied": "外部送信者アドレスを設定するためのACLが不足しています",
+ "extra_acl_invalid": "外部送信者アドレス \"%s\" は無効です",
+ "extra_acl_invalid_domain": "外部送信者 \"%s\" は無効なドメインを使用しています",
+ "fido2_verification_failed": "FIDO2認証に失敗しました: %s",
+ "file_open_error": "ファイルを開いて書き込むことができません",
+ "filter_type": "フィルタタイプが間違っています",
+ "from_invalid": "送信者を空にすることはできません",
+ "global_filter_write_error": "フィルターファイルを書き込めません: %s",
+ "global_map_invalid": "グローバルマップID %s は無効です",
+ "global_map_write_error": "グローバルマップID %s を書き込めません: %s",
+ "goto_empty": "エイリアスアドレスには少なくとも1つの有効な転送先アドレスが含まれている必要があります",
+ "goto_invalid": "転送先アドレス %s は無効です",
+ "ham_learn_error": "ハム学習エラー: %s",
+ "imagick_exception": "エラー: 画像の読み取り中にImagick例外が発生しました",
+ "img_dimensions_exceeded": "画像が最大サイズを超えています",
+ "img_invalid": "画像ファイルを検証できません",
+ "img_size_exceeded": "画像が最大ファイルサイズを超えています",
+ "img_tmp_missing": "画像ファイルを検証できません: 一時ファイルが見つかりません",
+ "invalid_bcc_map_type": "無効なBCCマップタイプ",
+ "invalid_destination": "送信先フォーマット \"%s\" は無効です",
+ "invalid_filter_type": "無効なフィルタタイプ",
+ "invalid_host": "無効なホストが指定されました: %s",
+ "invalid_mime_type": "無効なMIMEタイプ",
+ "invalid_nexthop": "次のホップフォーマットが無効です",
+ "invalid_nexthop_authenticated": "異なる認証情報で次のホップが存在します。最初にこの次のホップの既存の認証情報を更新してください。",
+ "invalid_recipient_map_new": "無効な新しい受信者が指定されました: %s",
+ "invalid_recipient_map_old": "無効な元の受信者が指定されました: %s",
+ "invalid_reset_token": "無効なリセットトークン",
+ "ip_list_empty": "許可されるIPリストを空にすることはできません",
+ "is_alias": "%s は既にエイリアスアドレスとして登録されています",
+ "is_alias_or_mailbox": "%s は既にエイリアス、メールボックス、またはエイリアスドメインから展開されたエイリアスアドレスとして登録されています。",
+ "is_spam_alias": "%s は既に一時的なエイリアスアドレス(スパムエイリアスアドレス)として登録されています",
+ "last_key": "最後のキーを削除することはできません。代わりにTFAを無効化してください。",
+ "login_failed": "ログインに失敗しました",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "デフォルトクォータが最大クォータ制限を超えています",
+ "mailbox_invalid": "メールボックス名が無効です",
+ "mailbox_quota_exceeded": "クォータがドメイン制限を超えています(最大 %d MiB)",
+ "mailbox_quota_exceeds_domain_quota": "最大クォータがドメインクォータ制限を超えています",
+ "mailbox_quota_left_exceeded": "残り容量が不足しています(残り容量: %d MiB)",
+ "mailboxes_in_use": "最大メールボックス数は %d 以上である必要があります",
+ "malformed_username": "ユーザー名が不正な形式です",
+ "map_content_empty": "マップの内容を空にすることはできません",
+ "max_alias_exceeded": "最大エイリアス数を超えています",
+ "max_mailbox_exceeded": "最大メールボックス数を超えています(%d / %d)",
+ "max_quota_in_use": "メールボックスクォータは %d MiB 以上である必要があります",
+ "maxquota_empty": "メールボックスごとの最大クォータを0にすることはできません。",
+ "mysql_error": "MySQLエラー: %s",
+ "network_host_invalid": "無効なネットワークまたはホスト: %s",
+ "next_hop_interferes": "%s は次のホップ %s と干渉しています",
+ "next_hop_interferes_any": "既存の次のホップが %s と干渉しています",
+ "nginx_reload_failed": "Nginxのリロードに失敗しました: %s",
+ "no_user_defined": "ユーザーが定義されていません",
+ "object_exists": "オブジェクト %s は既に存在します",
+ "object_is_not_numeric": "値 %s は数値ではありません",
+ "password_complexity": "パスワードがポリシーを満たしていません",
+ "password_empty": "パスワードを空にすることはできません",
+ "password_mismatch": "確認用パスワードが一致しません",
+ "password_reset_invalid_user": "メールボックスが見つからないか、リカバリーメールが設定されていません",
+ "password_reset_na": "現在パスワードリカバリは利用できません。管理者にお問い合わせください。",
+ "policy_list_from_exists": "指定された名前のレコードが存在します",
+ "policy_list_from_invalid": "レコードの形式が無効です",
+ "private_key_error": "プライベートキーエラー: %s",
+ "pushover_credentials_missing": "Pushoverトークンまたはキーが不足しています",
+ "pushover_key": "Pushoverキーの形式が間違っています",
+ "pushover_token": "Pushoverトークンの形式が間違っています",
+ "quota_not_0_not_numeric": "クォータは数値で >= 0 である必要があります",
+ "recipient_map_entry_exists": "受信者マップエントリ \"%s\" が存在します",
+ "recovery_email_failed": "リカバリーメールを送信できませんでした。管理者にお問い合わせください。",
+ "redis_error": "Redisエラー: %s",
+ "relayhost_invalid": "マップエントリ %s は無効です",
+ "release_send_failed": "メッセージをリリースできませんでした: %s",
+ "reset_f2b_regex": "正規表現フィルターをタイムリーにリセットできませんでした。再試行するか、数秒待ってからウェブサイトをリロードしてください。",
+ "reset_token_limit_exceeded": "リセットトークン制限を超えました。後でもう一度試してください。",
+ "resource_invalid": "リソース名 %s は無効です",
+ "rl_timeframe": "レート制限の時間枠が正しくありません",
+ "rspamd_ui_pw_length": "Rspamd UIのパスワードは6文字以上である必要があります",
+ "script_empty": "スクリプトを空にすることはできません",
+ "sender_acl_invalid": "送信者ACL値 %s は無効です",
+ "set_acl_failed": "ACLの設定に失敗しました",
+ "settings_map_invalid": "設定マップID %s は無効です",
+ "sieve_error": "Sieveパーサーエラー: %s",
+ "spam_learn_error": "スパム学習エラー: %s",
+ "subject_empty": "件名を空にすることはできません",
+ "target_domain_invalid": "ターゲットドメイン %s は無効です",
+ "targetd_not_found": "ターゲットドメイン %s が見つかりません",
+ "targetd_relay_domain": "ターゲットドメイン %s はリレードメインです",
+ "template_exists": "テンプレート %s は既に存在します",
+ "template_id_invalid": "テンプレートID %s は無効です",
+ "template_name_invalid": "テンプレート名が無効です",
+ "temp_error": "一時的なエラー",
+ "text_empty": "テキストを空にすることはできません",
+ "tfa_token_invalid": "TFAトークンが無効です",
+ "tls_policy_map_dest_invalid": "ポリシーの宛先が無効です",
+ "tls_policy_map_entry_exists": "TLSポリシーマップエントリ \"%s\" が存在します",
+ "tls_policy_map_parameter_invalid": "ポリシーパラメータが無効です",
+ "to_invalid": "受信者を空にすることはできません",
+ "totp_verification_failed": "TOTP認証に失敗しました",
+ "transport_dest_exists": "トランスポートの宛先 \"%s\" が存在します",
+ "webauthn_verification_failed": "WebAuthn認証に失敗しました: %s",
+ "webauthn_authenticator_failed": "選択された認証器が見つかりませんでした",
+ "webauthn_publickey_failed": "選択された認証器に公開鍵が保存されていません",
+ "webauthn_username_failed": "選択された認証器は別のアカウントに属しています",
+ "unknown": "不明なエラーが発生しました",
+ "unknown_tfa_method": "未知のTFA方法",
+ "unlimited_quota_acl": "ACLによって無制限クォータは禁止されています",
+ "username_invalid": "ユーザー名 %s は使用できません",
+ "validity_missing": "有効期限を設定してください",
+ "value_missing": "すべての値を入力してください",
+ "yotp_verification_failed": "Yubico OTP認証に失敗しました: %s"
+ },
+ "datatables": {
+ "collapse_all": "すべて折りたたむ",
+ "decimal": ".",
+ "emptyTable": "テーブルにデータがありません",
+ "expand_all": "すべて展開する",
+ "info": "_TOTAL_ 件中 _START_ から _END_ を表示中",
+ "infoEmpty": "0 件中 0 から 0 を表示中",
+ "infoFiltered": "(_MAX_ 件のデータから絞り込み)",
+ "infoPostFix": "",
+ "thousands": ",",
+ "lengthMenu": "_MENU_ 件を表示",
+ "loadingRecords": "読み込み中...",
+ "processing": "お待ちください...",
+ "search": "検索:",
+ "zeroRecords": "一致する記録が見つかりません",
+ "paginate": {
+ "first": "最初",
+ "last": "最後",
+ "next": "次へ",
+ "previous": "前へ"
+ },
+ "aria": {
+ "sortAscending": ": 昇順に並べ替えるには有効化",
+ "sortDescending": ": 降順に並べ替えるには有効化"
+ }
+ },
+ "debug": {
+ "architecture": "アーキテクチャ",
+ "chart_this_server": "チャート(このサーバー)",
+ "containers_info": "コンテナ情報",
+ "container_running": "稼働中",
+ "container_disabled": "コンテナ停止または無効",
+ "container_stopped": "停止",
+ "cores": "コア数",
+ "current_time": "システム時間",
+ "disk_usage": "ディスク使用量",
+ "docs": "ドキュメント",
+ "error_show_ip": "パブリックIPアドレスを解決できませんでした",
+ "external_logs": "外部ログ",
+ "history_all_servers": "履歴(すべてのサーバー)",
+ "in_memory_logs": "インメモリーログ",
+ "last_modified": "最終更新日時",
+ "log_info": "<p>mailcowの<b>インメモリーログ</b>はRedisリストに収集され、ハンマリングを軽減するために1分ごとにLOG_LINES (%d)にトリムされます。\r\n <br>インメモリーログは永続化を目的としたものではありません。インメモリーログを記録するすべてのアプリケーションは、Dockerデーモンとデフォルトのログドライバーにもログを記録します。\r\n <br>インメモリーログタイプは、コンテナの軽微な問題をデバッグするために使用してください。</p>\r\n <p><b>外部ログ</b>は指定されたアプリケーションのAPIを介して収集されます。</p>\r\n <p><b>静的ログ</b>は主にアクティビティログであり、Dockerdには記録されませんが(APIログを除く)、永続化が必要です。</p>",
+ "login_time": "ログイン時間",
+ "logs": "ログ",
+ "memory": "メモリ",
+ "online_users": "オンラインユーザー",
+ "restart_container": "再起動",
+ "service": "サービス",
+ "show_ip": "パブリックIPを表示",
+ "size": "サイズ",
+ "started_at": "開始時刻",
+ "started_on": "開始日",
+ "static_logs": "静的ログ",
+ "success": "成功",
+ "system_containers": "システムとコンテナ",
+ "timezone": "タイムゾーン",
+ "uptime": "稼働時間",
+ "update_available": "利用可能なアップデートがあります",
+ "no_update_available": "システムは最新バージョンです",
+ "update_failed": "アップデートの確認に失敗しました",
+ "username": "ユーザー名",
+ "wip": "作業中"
+ },
+ "diagnostics": {
+ "cname_from_a": "A/AAAAレコードから派生した値です。この値は、レコードが正しいリソースを指している限りサポートされています。",
+ "dns_records": "DNSレコード",
+ "dns_records_24hours": "DNSに加えた変更が正しく反映されるまで最大24時間かかる場合があります。このページは、DNSレコードの設定方法を簡単に確認したり、すべてのレコードがDNSに正しく保存されているかを確認するためのものです。",
+ "dns_records_data": "正しいデータ",
+ "dns_records_docs": "<a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">ドキュメント</a>も参照してください。",
+ "dns_records_name": "名前",
+ "dns_records_status": "現在の状態",
+ "dns_records_type": "タイプ",
+ "optional": "このレコードは任意です。"
+ },
+ "edit": {
+ "acl": "ACL(権限)",
+ "active": "アクティブ",
+ "admin": "管理者を編集",
+ "advanced_settings": "詳細設定",
+ "alias": "エイリアスを編集",
+ "allow_from_smtp": "<b>SMTP</b>を使用するこれらのIPのみを許可",
+ "allow_from_smtp_info": "すべての送信者を許可するには空欄にしてください。<br>IPv4/IPv6アドレスおよびネットワークを指定できます。",
+ "allowed_protocols": "直接ユーザーアクセスで許可されるプロトコル(アプリパスワードプロトコルには影響しません)",
+ "app_name": "アプリ名",
+ "app_passwd": "アプリパスワード",
+ "app_passwd_protocols": "アプリパスワードで許可されるプロトコル",
+ "automap": "フォルダーを自動マッピングする(例:\"Sent items\", \"Sent\" => \"Sent\" など)",
+ "backup_mx_options": "リレーオプション",
+ "bcc_dest_format": "BCC送信先は1つの有効なメールアドレスである必要があります。<br>複数のアドレスにコピーを送信する必要がある場合は、エイリアスを作成してここで使用してください。",
+ "client_id": "クライアントID",
+ "client_secret": "クライアントシークレット",
+ "comment_info": "プライベートコメントはユーザーには表示されませんが、パブリックコメントはユーザー概要でホバーするとツールチップとして表示されます。",
+ "created_on": "作成日時",
+ "custom_attributes": "カスタム属性",
+ "delete1": "完了時にソースから削除",
+ "delete2": "ソースに存在しないメッセージを送信先で削除",
+ "delete2duplicates": "送信先で重複を削除",
+ "delete_ays": "削除プロセスを確認してください。",
+ "description": "説明",
+ "disable_login": "ログインを禁止(受信メールは許可)",
+ "domain": "ドメインを編集",
+ "domain_admin": "ドメイン管理者を編集",
+ "domain_footer": "ドメイン全体のフッター",
+ "domain_footer_html": "HTMLフッター",
+ "domain_footer_info": "ドメイン全体のフッターは、このドメイン内のアドレスに関連付けられたすべての送信メールに追加されます。<br>フッターで使用できる変数は以下の通りです:",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - MTAによって指定された認証済みユーザー名",
+ "from_user": "{= from_user =} - エンベロープの送信者部分。例:「moo@mailcow.tld」の場合、「moo」を返します。",
+ "from_name": "{= from_name =} - エンベロープの送信者名。例:「Mailcow <moo@mailcow.tld>」の場合、「Mailcow」を返します。",
+ "from_addr": "{= from_addr =} - エンベロープの送信者アドレス部分",
+ "from_domain": "{= from_domain =} - エンベロープの送信者ドメイン部分",
+ "custom": "{= foo =} - メールボックスに「foo」というカスタム属性があり、その値が「bar」の場合、「bar」を返します。"
+ },
+ "domain_footer_plain": "プレインテキストのフッター",
+ "domain_footer_skip_replies": "返信メールでフッターを無視",
+ "domain_quota": "ドメインクォータ",
+ "domains": "ドメイン",
+ "dont_check_sender_acl": "ドメイン %s(およびエイリアスドメイン)の送信者チェックを無効化",
+ "edit_alias_domain": "エイリアスドメインを編集",
+ "encryption": "暗号化",
+ "exclude": "オブジェクトを除外(正規表現)",
+ "extended_sender_acl": "外部送信者アドレス",
+ "extended_sender_acl_info": "可能であればDKIMドメインキーをインポートしてください。<br>\r\n このサーバーを対応するSPF TXTレコードに追加することを忘れないでください。<br>\r\n このサーバーに外部アドレスと重複するドメインまたはエイリアスドメインを追加するたびに、外部アドレスは削除されます。<br>\r\n *@domain.tld として送信を許可するには @domain.tld を使用してください。",
+ "force_pw_update": "次回ログイン時にパスワードの更新を強制",
+ "force_pw_update_info": "このユーザーは %s にのみログインできます。アプリパスワードは引き続き使用可能です。",
+ "footer_exclude": "フッターから除外",
+ "full_name": "フルネーム",
+ "gal": "グローバルアドレスリスト",
+ "gal_info": "GALにはドメインのすべてのオブジェクトが含まれ、ユーザーは編集できません。無効にすると、SOGoの空き/取り込み情報が欠落します!<b>変更を適用するにはSOGoを再起動してください。</b>",
+ "generate": "生成",
+ "grant_types": "付与タイプ",
+ "hostname": "ホスト名",
+ "inactive": "非アクティブ",
+ "kind": "種類",
+ "last_modified": "最終更新日時",
+ "lookup_mx": "宛先がMX名に一致する正規表現です(例:<code>.*\\.google\\.com</code> は google.com で終わるMX宛のすべてのメールをこのホップにルートします)",
+ "mailbox": "メールボックスを編集",
+ "mailbox_quota_def": "デフォルトのメールボックスクォータ",
+ "mailbox_relayhost_info": "メールボックスおよび直接エイリアスにのみ適用され、ドメインリレーホストを上書きします。",
+ "mailbox_rename": "メールボックス名を変更",
+ "mailbox_rename_agree": "バックアップを作成しました。",
+ "mailbox_rename_warning": "重要!メールボックス名を変更する前にバックアップを作成してください。",
+ "mailbox_rename_alias": "エイリアスを自動作成",
+ "mailbox_rename_title": "新しいローカルメールボックス名",
+ "max_aliases": "最大エイリアス数",
+ "max_mailboxes": "作成可能な最大メールボックス数",
+ "max_quota": "メールボックスごとの最大クォータ(MiB)",
+ "maxage": "リモートから取得するメッセージの最大日数<br><small>(0 = 日数を無視)</small>",
+ "maxbytespersecond": "毎秒の最大バイト数<br><small>(0 = 無制限)</small>",
+ "mbox_rl_info": "このレート制限はSASLログイン名に適用され、ログインしたユーザーによって使用されるすべての「送信者」アドレスに一致します。メールボックスレート制限は、ドメイン全体のレート制限を上書きします。",
+ "mins_interval": "間隔(分)",
+ "multiple_bookings": "複数予約",
+ "none_inherit": "なし / 継承",
+ "nexthop": "次のホップ",
+ "password": "パスワード",
+ "password_recovery_email": "パスワードリカバリメール",
+ "password_repeat": "確認用パスワード(再入力)",
+ "previous": "前のページ",
+ "private_comment": "プライベートコメント",
+ "public_comment": "パブリックコメント",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "高優先度メールをエスカレーションする [<code>X-Priority: 1</code>]",
+ "pushover_info": "プッシュ通知設定は<b>%s</b>に配信されるすべてのクリーン(スパムでない)メールに適用されます。エイリアス(共有、非共有、タグ付き)も含まれます。",
+ "pushover_only_x_prio": "高優先度メールのみを考慮 [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "以下の送信者メールアドレスのみを考慮<small>(カンマ区切り)</small>",
+ "pushover_sender_regex": "以下の送信者正規表現を考慮",
+ "pushover_text": "通知テキスト",
+ "pushover_title": "通知タイトル",
+ "pushover_sound": "通知音",
+ "pushover_vars": "送信者フィルターが定義されていない場合、すべてのメールが考慮されます。<br>正規表現フィルターおよび正確な送信者チェックを個別に定義可能で、順次考慮されます。これらは互いに依存しません。<br>テキストおよびタイトルに使用可能な変数(データ保護ポリシーに注意してください)",
+ "pushover_verify": "資格情報を確認",
+ "quota_mb": "クォータ(MiB)",
+ "quota_warning_bcc": "クォータ警告BCC",
+ "quota_warning_bcc_info": "警告は別のコピーとして以下の受信者に送信されます。件名には対応するユーザー名が括弧内に付加されます(例:<code>Quota warning (user@example.com)</code>)。",
+ "ratelimit": "レート制限",
+ "redirect_uri": "リダイレクト/コールバックURL",
+ "relay_all": "すべての受信者をリレー",
+ "relay_all_info": "↪ すべての受信者をリレー<b>しない</b>場合、リレーする必要のある各受信者のために(\"ブラインド\")メールボックスを追加する必要があります。",
+ "relay_domain": "このドメインをリレー",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">情報</div> このドメインのカスタム宛先のトランスポートマップを定義できます。設定されていない場合、MXルックアップが実行されます。",
+ "relay_unknown_only": "存在しないメールボックスのみをリレー。存在するメールボックスはローカルに配信されます。",
+ "relayhost": "送信者依存のトランスポート",
+ "remove": "削除",
+ "resource": "リソース",
+ "save": "変更を保存",
+ "scope": "スコープ",
+ "sender_acl": "送信を許可するアドレス",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">送信者チェックが無効です</span>",
+ "sender_acl_info": "メールボックスユーザーAがメールボックスユーザーBとして送信することを許可されている場合、SOGoで送信者アドレスが自動的に選択可能な「送信者」フィールドとして表示されることはありません。<br>\r\n メールボックスユーザーBは、SOGoでメールボックスを委任する必要があります。この委任は、メールビューの左上にあるメールボックス名の右にあるメニュー(三点ボタン)を使用して行います。この動作はエイリアスアドレスには適用されません。",
+ "sieve_desc": "簡単な説明",
+ "sieve_type": "フィルタータイプ",
+ "skipcrossduplicates": "フォルダー間で重複するメッセージをスキップ(先着順)",
+ "sogo_access": "SOGoへの直接ログインアクセスを許可",
+ "sogo_access_info": "メールUI内からのシングルサインオンは引き続き動作します。この設定は他のすべてのサービスへのアクセスには影響しません。また、ユーザーの既存のSOGoプロファイルを削除または変更するものでもありません。",
+ "sogo_visible": "SOGoにエイリアスが表示される",
+ "sogo_visible_info": "このオプションは、SOGoで表示可能なオブジェクト(ローカルメールボックスを指す共有または非共有のエイリアスアドレス)にのみ影響します。非表示にすると、SOGoで選択可能な送信者としてエイリアスは表示されません。",
+ "spam_alias": "時間制限付きエイリアスアドレスを作成または変更",
+ "spam_filter": "スパムフィルター",
+ "spam_policy": "ホワイトリスト/ブラックリストにアイテムを追加または削除",
+ "spam_score": "カスタムスパムスコアを設定",
+ "subfolder2": "送信先でサブフォルダーに同期<br><small>(空欄 = サブフォルダーを使用しない)</small>",
+ "syncjob": "同期ジョブを編集",
+ "target_address": "転送先アドレス<small>(カンマ区切り)</small>",
+ "target_domain": "ターゲットドメイン",
+ "timeout1": "リモートホストへの接続タイムアウト",
+ "timeout2": "ローカルホストへの接続タイムアウト",
+ "title": "オブジェクトを編集",
+ "unchanged_if_empty": "変更がない場合は空欄にしてください",
+ "username": "ユーザー名",
+ "validate_save": "検証して保存"
+ },
+ "fido2": {
+ "confirm": "確認",
+ "fido2_auth": "FIDO2でログイン",
+ "fido2_success": "デバイスが正常に登録されました",
+ "fido2_validation_failed": "検証に失敗しました",
+ "fn": "フレンドリーネーム",
+ "known_ids": "登録済みID",
+ "none": "無効",
+ "register_status": "登録状況",
+ "rename": "名前を変更",
+ "set_fido2": "FIDO2デバイスを登録",
+ "set_fido2_touchid": "Apple M1でTouch IDを登録",
+ "set_fn": "フレンドリーネームを設定",
+ "start_fido2_validation": "FIDO2検証を開始"
+ },
+ "footer": {
+ "cancel": "キャンセル",
+ "confirm_delete": "削除の確認",
+ "delete_now": "今すぐ削除",
+ "delete_these_items": "次のオブジェクトIDに対する変更を確認してください",
+ "hibp_check": "haveibeenpwned.comで確認",
+ "hibp_nok": "一致しました!これは潜在的に危険なパスワードです!",
+ "hibp_ok": "一致は見つかりませんでした。",
+ "loading": "お待ちください...",
+ "nothing_selected": "選択されていません",
+ "restart_container": "コンテナを再起動",
+ "restart_container_info": "<b>重要:</b> 優雅な再起動には時間がかかる場合があります。完了するまでお待ちください。",
+ "restart_now": "今すぐ再起動",
+ "restarting_container": "コンテナを再起動中です。これには時間がかかる場合があります。"
+ },
+ "header": {
+ "administration": "構成と詳細",
+ "apps": "アプリ",
+ "debug": "情報",
+ "email": "Eメール",
+ "mailcow_system": "システム",
+ "mailcow_config": "構成",
+ "quarantine": "隔離",
+ "restart_netfilter": "netfilterを再起動",
+ "restart_sogo": "SOGoを再起動",
+ "user_settings": "ユーザー設定"
+ },
+ "info": {
+ "awaiting_tfa_confirmation": "TFA(二要素認証)の確認待ち",
+ "no_action": "適用可能なアクションはありません",
+ "session_expires": "セッションは約15秒で期限切れになります"
+ },
+ "login": {
+ "back_to_mailcow": "mailcowに戻る",
+ "delayed": "ログインが %s 秒遅れました。",
+ "fido2_webauthn": "FIDO2/WebAuthnでログイン",
+ "forgot_password": "> パスワードをお忘れですか?",
+ "invalid_pass_reset_token": "パスワードリセットトークンが無効または期限切れです。<br>新しいパスワードリセットリンクをリクエストしてください。",
+ "login": "ログイン",
+ "mobileconfig_info": "リクエストされたApple接続プロファイルをダウンロードするには、メールボックスユーザーとしてログインしてください。",
+ "new_password": "新しいパスワード",
+ "new_password_confirm": "新しいパスワードを確認",
+ "other_logins": "キーでログイン",
+ "password": "パスワード",
+ "reset_password": "パスワードをリセット",
+ "request_reset_password": "パスワード変更をリクエスト",
+ "username": "ユーザー名"
+ },
+ "mailbox": {
+ "action": "アクション",
+ "activate": "有効化",
+ "active": "有効",
+ "add": "追加",
+ "add_alias": "エイリアスを追加",
+ "add_alias_expand": "エイリアスドメインでエイリアスを展開",
+ "add_bcc_entry": "BCCマップを追加",
+ "add_domain": "ドメインを追加",
+ "add_domain_alias": "ドメインエイリアスを追加",
+ "add_domain_record_first": "まずドメインを追加してください",
+ "add_filter": "フィルタを追加",
+ "add_mailbox": "メールボックスを追加",
+ "add_recipient_map_entry": "受信者マップを追加",
+ "add_resource": "リソースを追加",
+ "add_template": "テンプレートを追加",
+ "add_tls_policy_map": "TLSポリシーマップを追加",
+ "address_rewriting": "アドレス書き換え",
+ "alias": "エイリアス",
+ "alias_domain_alias_hint": "エイリアスはドメインエイリアスに自動的には適用<b>されません</b>。エイリアスアドレス<code>my-alias@domain</code>は、アドレス<code>my-alias@alias-domain</code>を<b>カバーしません</b>(\"alias-domain\"は\"domain\"の仮想エイリアスドメイン)。<br>外部メールボックスにメールを転送するには、シーブフィルタを使用してください(\"Filters\"タブまたはSOGoのForwarderを使用)。\"エイリアスドメインでエイリアスを展開\"を使用して不足しているエイリアスを自動的に追加できます。",
+ "alias_domain_backupmx": "リレードメイン用にエイリアスドメインが無効",
+ "aliases": "エイリアス",
+ "all_domains": "すべてのドメイン",
+ "allow_from_smtp": "<b>SMTP</b>を使用するこれらのIPのみを許可",
+ "allow_from_smtp_info": "すべての送信者を許可するには空欄にしてください。<br>IPv4/IPv6アドレスおよびネットワークを指定可能。",
+ "allowed_protocols": "許可されたプロトコル",
+ "backup_mx": "リレードメイン",
+ "bcc": "BCC",
+ "bcc_destination": "BCC送信先",
+ "bcc_destinations": "BCC送信先",
+ "bcc_info": "BCCマップはすべてのメッセージのコピーを他のアドレスに静かに転送するために使用されます。ローカル送信先がメールの受信者として機能するときに受信者マップタイプのエントリが使用されます。送信者マップも同じ原則に従います。<br>\r\n ローカル送信先は配送失敗について通知されません。",
+ "bcc_local_dest": "ローカル送信先",
+ "bcc_map": "BCCマップ",
+ "bcc_map_type": "BCCタイプ",
+ "bcc_maps": "BCCマップ",
+ "bcc_rcpt_map": "受信者マップ",
+ "bcc_sender_map": "送信者マップ",
+ "bcc_to_rcpt": "受信者マップタイプに切り替え",
+ "bcc_to_sender": "送信者マップタイプに切り替え",
+ "bcc_type": "BCCタイプ",
+ "booking_null": "常に空きとして表示",
+ "booking_0_short": "常に空き",
+ "booking_custom": "特定の予約数に制限",
+ "booking_custom_short": "ハードリミット",
+ "booking_ltnull": "無制限だが予約時は使用中として表示",
+ "booking_lt0_short": "ソフトリミット",
+ "catch_all": "キャッチオール",
+ "created_on": "作成日",
+ "daily": "毎日",
+ "deactivate": "無効化",
+ "description": "説明",
+ "disable_login": "ログインを禁止(受信メールは許可)",
+ "disable_x": "無効化",
+ "dkim_domains_selector": "セレクタ",
+ "dkim_key_length": "DKIMキーの長さ(ビット)",
+ "domain": "ドメイン",
+ "domain_admins": "ドメイン管理者",
+ "domain_aliases": "ドメインエイリアス",
+ "domain_templates": "ドメインテンプレート",
+ "domain_quota": "クォータ",
+ "domain_quota_total": "ドメイン全体のクォータ",
+ "domains": "ドメイン",
+ "edit": "編集",
+ "empty": "結果なし",
+ "enable_x": "有効化",
+ "excludes": "除外",
+ "filter_table": "フィルタテーブル",
+ "filters": "フィルタ",
+ "fname": "フルネーム",
+ "force_pw_update": "次回ログイン時にパスワード更新を強制",
+ "gal": "グローバルアドレスリスト",
+ "goto_ham": "<b>Ham</b>として学習",
+ "goto_spam": "<b>Spam</b>として学習",
+ "hourly": "毎時",
+ "in_use": "使用中 (%)",
+ "inactive": "非アクティブ",
+ "insert_preset": "例のプリセット \"%s\" を挿入",
+ "kind": "種類",
+ "last_mail_login": "最後のメールログイン",
+ "last_modified": "最終更新日",
+ "last_pw_change": "最後のパスワード変更",
+ "last_run": "最後の実行",
+ "last_run_reset": "次回のスケジュール設定",
+ "mailbox": "メールボックス",
+ "mailbox_defaults": "デフォルト設定",
+ "mailbox_defaults_info": "新しいメールボックスのデフォルト設定を定義します。",
+ "mailbox_defquota": "デフォルトのメールボックスサイズ",
+ "mailbox_templates": "メールボックステンプレート",
+ "mailbox_quota": "メールボックスの最大サイズ",
+ "mailboxes": "メールボックス",
+ "max_aliases": "最大エイリアス数",
+ "max_mailboxes": "作成可能な最大メールボックス数",
+ "max_quota": "メールボックスごとの最大クォータ",
+ "mins_interval": "間隔(分)",
+ "msg_num": "メッセージ番号",
+ "multiple_bookings": "複数予約",
+ "never": "なし",
+ "no": "✕",
+ "no_record": "オブジェクト %s に記録がありません",
+ "no_record_single": "記録なし",
+ "open_logs": "ログを開く",
+ "owner": "所有者",
+ "private_comment": "プライベートコメント",
+ "public_comment": "パブリックコメント",
+ "q_add_header": "迷惑メールフォルダに移動時",
+ "q_all": "迷惑メールフォルダに移動時および拒否時",
+ "q_reject": "拒否時",
+ "quarantine_category": "隔離通知カテゴリ",
+ "quarantine_notification": "隔離通知",
+ "quick_actions": "アクション",
+ "recipient": "受信者",
+ "recipient_map": "受信者マップ",
+ "recipient_map_info": "受信者マップは、メッセージが配信される前に宛先アドレスを置き換えるために使用されます。",
+ "recipient_map_new": "新しい受信者",
+ "recipient_map_new_info": "受信者マップの宛先は有効なメールアドレスまたはドメイン名である必要があります。",
+ "recipient_map_old": "元の受信者",
+ "recipient_map_old_info": "受信者マップの元の宛先は有効なメールアドレスまたはドメイン名である必要があります。",
+ "recipient_maps": "受信者マップ",
+ "relay_all": "すべての受信者をリレー",
+ "relay_unknown": "未知のメールボックスをリレー",
+ "remove": "削除",
+ "resources": "リソース",
+ "running": "稼働中",
+ "sender": "送信者",
+ "set_postfilter": "ポストフィルターとして設定",
+ "set_prefilter": "プリフィルターとして設定",
+ "sieve_info": "ユーザーごとに複数のフィルタを保存できますが、同時にアクティブにできるのは1つのプリフィルタと1つのポストフィルタだけです。<br>\r\n各フィルタは指定された順序で処理されます。スクリプトの失敗や\"keep;\"の発行は、後続のスクリプトの処理を停止しません。グローバルシーブスクリプトの変更はDovecotの再起動をトリガーします。<br><br>グローバルシーブプリフィルタ • プリフィルタ • ユーザースクリプト • ポストフィルタ • グローバルシーブポストフィルタ",
+ "sieve_preset_1": "危険性の高いファイルタイプのメールを破棄",
+ "sieve_preset_2": "特定の送信者のメールを常に既読としてマーク",
+ "sieve_preset_3": "静かに破棄し、すべてのシーブ処理を停止",
+ "sieve_preset_4": "INBOXにファイルし、シーブフィルタによるさらなる処理をスキップ",
+ "sieve_preset_5": "自動返信(バケーション)",
+ "sieve_preset_6": "応答付きでメールを拒否",
+ "sieve_preset_7": "リダイレクトして保持/削除",
+ "sieve_preset_8": "特定の送信者からのメールをリダイレクトし、既読としてマークしてサブフォルダーに分類",
+ "sieve_preset_header": "以下の例のプリセットをご覧ください。詳細については<a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedia</a>を参照してください。",
+ "sogo_visible": "エイリアスはSOGoで表示されます",
+ "sogo_visible_n": "SOGoでエイリアスを非表示",
+ "sogo_visible_y": "SOGoでエイリアスを表示",
+ "spam_aliases": "一時的なエイリアス",
+ "stats": "統計",
+ "status": "ステータス",
+ "sync_jobs": "同期ジョブ",
+ "syncjob_check_log": "ログを確認",
+ "syncjob_last_run_result": "最後の実行結果",
+ "syncjob_EX_OK": "成功",
+ "syncjob_EXIT_CONNECTION_FAILURE": "接続問題",
+ "syncjob_EXIT_TLS_FAILURE": "暗号化接続の問題",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "認証問題",
+ "syncjob_EXIT_OVERQUOTA": "宛先メールボックスがクォータを超過",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "リモートサーバーに接続できません",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "ユーザー名またはパスワードが間違っています",
+ "table_size": "テーブルサイズ",
+ "table_size_show_n": "%s 件を表示",
+ "target_address": "転送先アドレス",
+ "target_domain": "ターゲットドメイン",
+ "templates": "テンプレート",
+ "template": "テンプレート",
+ "tls_enforce_in": "TLSの受信を強制",
+ "tls_enforce_out": "TLSの送信を強制",
+ "tls_map_dest": "宛先",
+ "tls_map_dest_info": "例: example.org, .example.org, [mail.example.org]:25",
+ "tls_map_parameters": "パラメータ",
+ "tls_map_parameters_info": "空欄またはパラメータ(例: protocols=!SSLv2 ciphers=medium exclude=3DES)",
+ "tls_map_policy": "ポリシー",
+ "tls_policy_maps": "TLSポリシーマップ",
+ "tls_policy_maps_enforced_tls": "これらのポリシーは、送信TLS接続を強制するメールボックスユーザーの動作も上書きします。以下にポリシーが存在しない場合、これらのユーザーはデフォルト値(<code>smtp_tls_mandatory_protocols</code>および<code>smtp_tls_mandatory_ciphers</code>)を適用します。",
+ "tls_policy_maps_info": "このポリシーマップは、ユーザーのTLSポリシー設定とは無関係に送信TLSトランスポートルールを上書きします。<br>\r\n 詳細については<a href=\"http://www.postfix.org/postconf.5.html#smtp_tls_policy_maps\" target=\"_blank\">\"smtp_tls_policy_maps\"のドキュメント</a>をご確認ください。",
+ "tls_policy_maps_long": "送信TLSポリシーマップの上書き",
+ "toggle_all": "すべて切り替え",
+ "username": "ユーザー名",
+ "waiting": "待機中",
+ "weekly": "毎週",
+ "yes": "✓"
+ },
+ "oauth2": {
+ "access_denied": "OAuth2経由でアクセスを許可するには、メールボックスの所有者としてログインしてください。",
+ "authorize_app": "アプリケーションを認証",
+ "deny": "拒否",
+ "permit": "アプリケーションを許可",
+ "profile": "プロファイル",
+ "profile_desc": "個人情報を表示: ユーザー名、フルネーム、作成日、更新日、アクティブ状態",
+ "scope_ask_permission": "以下の権限を要求するアプリケーションがあります"
+ },
+ "quarantine": {
+ "action": "アクション",
+ "atts": "添付ファイル",
+ "check_hash": "ファイルハッシュをVTで検索",
+ "confirm": "確認",
+ "confirm_delete": "この要素の削除を確認してください。",
+ "danger": "危険",
+ "deliver_inbox": "受信トレイに配信",
+ "disabled_by_config": "現在のシステム設定では隔離機能が無効になっています。「メールボックスごとの保存期間」と「隔離要素の最大サイズ」を設定してください。",
+ "download_eml": "ダウンロード(.eml)",
+ "empty": "結果がありません",
+ "high_danger": "高",
+ "info": "情報",
+ "junk_folder": "迷惑メールフォルダ",
+ "learn_spam_delete": "スパムとして学習して削除",
+ "low_danger": "低",
+ "medium_danger": "中",
+ "neutral_danger": "中立",
+ "notified": "通知済み",
+ "qhandler_success": "リクエストがシステムに正常に送信されました。このウィンドウを閉じることができます。",
+ "qid": "Rspamd QID",
+ "qinfo": "隔離システムは拒否されたメールをデータベースに保存します(送信者には配信されたようには見えません)。また、メールボックスの迷惑メールフォルダにコピーとして配信されたメールも保存します。\r\n <br>「スパムとして学習して削除」は、ベイズ理論を使用してメッセージをスパムとして学習し、将来的に類似メッセージを拒否するためのファジーハッシュを計算します。\r\n <br>複数のメッセージを学習することは、システムによっては時間がかかる場合があります。<br>ブラックリスト登録された要素は隔離対象外です。",
+ "qitem": "隔離項目",
+ "quarantine": "隔離",
+ "quick_actions": "クイックアクション",
+ "quick_delete_link": "クイック削除リンクを開く",
+ "quick_info_link": "情報リンクを開く",
+ "quick_release_link": "クイックリリースリンクを開く",
+ "rcpt": "受信者",
+ "received": "受信日時",
+ "recipients": "受信者",
+ "refresh": "更新",
+ "rejected": "拒否",
+ "release": "リリース",
+ "release_body": "メッセージを.emlファイルとして添付しました。",
+ "release_subject": "潜在的に危険な隔離項目 %s",
+ "remove": "削除",
+ "rewrite_subject": "件名の書き換え",
+ "rspamd_result": "Rspamd 結果",
+ "sender": "送信者(SMTP)",
+ "sender_header": "送信者(「From」ヘッダー)",
+ "settings_info": "隔離対象の要素数の最大値: %s<br>最大メールサイズ: %s MiB",
+ "show_item": "項目を表示",
+ "spam": "スパム",
+ "spam_score": "スコア",
+ "subj": "件名",
+ "table_size": "テーブルサイズ",
+ "table_size_show_n": "%s 件表示",
+ "text_from_html_content": "コンテンツ(変換されたHTML)",
+ "text_plain_content": "コンテンツ(text/plain)",
+ "toggle_all": "すべて選択/解除",
+ "type": "タイプ"
+ },
+ "queue": {
+ "delete": "すべて削除",
+ "flush": "キューをフラッシュ",
+ "info": "メールキューには、配信を待っているすべてのメールが含まれています。メールが長時間メールキューに停滞している場合、システムによって自動的に削除されます。<br>該当メールのエラーメッセージは、メールが配信できなかった理由についての情報を提供します。",
+ "legend": "メールキュー操作機能:",
+ "ays": "現在のキューからすべてのアイテムを削除することを確認してください。",
+ "deliver_mail": "配信",
+ "deliver_mail_legend": "選択されたメールの再配信を試みます。",
+ "hold_mail": "保留",
+ "hold_mail_legend": "選択されたメールを保留します。(さらに配信を試みるのを防ぎます)",
+ "queue_manager": "キューマネージャー",
+ "show_message": "メッセージを表示",
+ "unban": "キューの禁止解除",
+ "unhold_mail": "保留解除",
+ "unhold_mail_legend": "配信のために選択されたメールを解放します。(事前に保留が必要)"
+ },
+ "ratelimit": {
+ "disabled": "無効",
+ "second": "通数 / 秒",
+ "minute": "通数 / 分",
+ "hour": "通数 / 時間",
+ "day": "通数 / 日"
+ },
+ "start": {
+ "help": "ヘルプパネルを表示/非表示",
+ "imap_smtp_server_auth_info": "メールアドレス全体を使用し、PLAIN認証メカニズムを使用してください。<br>\r\nログインデータはサーバー側の強制暗号化により保護されます。"
+ },
+ "success": {
+ "acl_saved": "オブジェクト %s のACLを保存しました",
+ "admin_added": "管理者 %s が追加されました",
+ "admin_api_modified": "APIの変更が保存されました",
+ "admin_modified": "管理者の変更が保存されました",
+ "admin_removed": "管理者 %s が削除されました",
+ "alias_added": "エイリアスアドレス %s (%d) が追加されました",
+ "alias_domain_removed": "エイリアスドメイン %s が削除されました",
+ "alias_modified": "エイリアスアドレス %s の変更が保存されました",
+ "alias_removed": "エイリアス %s が削除されました",
+ "aliasd_added": "エイリアスドメイン %s が追加されました",
+ "aliasd_modified": "エイリアスドメイン %s の変更が保存されました",
+ "app_links": "アプリリンクの変更を保存しました",
+ "app_passwd_added": "新しいアプリパスワードを追加しました",
+ "app_passwd_removed": "アプリパスワードID %s を削除しました",
+ "bcc_deleted": "BCCマップエントリを削除しました: %s",
+ "bcc_edited": "BCCマップエントリ %s を編集しました",
+ "bcc_saved": "BCCマップエントリを保存しました",
+ "cors_headers_edited": "CORS設定が保存されました",
+ "db_init_complete": "データベースの初期化が完了しました",
+ "delete_filter": "フィルターID %s を削除しました",
+ "delete_filters": "フィルターを削除しました: %s",
+ "deleted_syncjob": "同期ジョブID %s を削除しました",
+ "deleted_syncjobs": "同期ジョブを削除しました: %s",
+ "dkim_added": "DKIMキー %s を保存しました",
+ "domain_add_dkim_available": "既にDKIMキーが存在していました",
+ "dkim_duplicated": "ドメイン %s のDKIMキーを %s にコピーしました",
+ "dkim_removed": "DKIMキー %s を削除しました",
+ "domain_added": "ドメイン %s を追加しました",
+ "domain_admin_added": "ドメイン管理者 %s が追加されました",
+ "domain_admin_modified": "ドメイン管理者 %s の変更が保存されました",
+ "domain_admin_removed": "ドメイン管理者 %s が削除されました",
+ "domain_footer_modified": "ドメインフッター %s の変更が保存されました",
+ "domain_modified": "ドメイン %s の変更が保存されました",
+ "domain_removed": "ドメイン %s が削除されました",
+ "dovecot_restart_success": "Dovecotが正常に再起動されました",
+ "eas_reset": "ユーザー %s のActiveSyncデバイスをリセットしました",
+ "f2b_banlist_refreshed": "Banlist ID が正常に更新されました。",
+ "f2b_modified": "Fail2banのパラメータの変更が保存されました",
+ "forwarding_host_added": "転送ホスト %s を追加しました",
+ "forwarding_host_removed": "転送ホスト %s を削除しました",
+ "global_filter_written": "フィルターが正常にファイルに書き込まれました",
+ "hash_deleted": "ハッシュを削除しました",
+ "ip_check_opt_in_modified": "IPチェックが正常に保存されました",
+ "item_deleted": "アイテム %s を正常に削除しました",
+ "item_released": "アイテム %s をリリースしました",
+ "items_deleted": "アイテム %s を正常に削除しました",
+ "items_released": "選択されたアイテムをリリースしました",
+ "learned_ham": "ID %s をhamとして正常に学習しました",
+ "license_modified": "ライセンスの変更が保存されました",
+ "logged_in_as": "%s としてログインしました",
+ "mailbox_added": "メールボックス %s を追加しました",
+ "mailbox_modified": "メールボックス %s の変更が保存されました",
+ "mailbox_removed": "メールボックス %s が削除されました",
+ "mailbox_renamed": "メールボックス名を %s から %s に変更しました",
+ "nginx_reloaded": "Nginxをリロードしました",
+ "object_modified": "オブジェクト %s の変更が保存されました",
+ "password_policy_saved": "パスワードポリシーが正常に保存されました",
+ "password_changed_success": "パスワードが正常に変更されました",
+ "pushover_settings_edited": "Pushover設定が正常に設定されました。資格情報を確認してください。",
+ "qlearn_spam": "メッセージID %s をスパムとして学習し削除しました",
+ "queue_command_success": "キューコマンドが正常に完了しました",
+ "recipient_map_entry_deleted": "受信者マップID %s を削除しました",
+ "recipient_map_entry_saved": "受信者マップエントリ \"%s\" を保存しました",
+ "recovery_email_sent": "リカバリーメールを %s に送信しました",
+ "relayhost_added": "マップエントリ %s を追加しました",
+ "relayhost_removed": "マップエントリ %s を削除しました",
+ "reset_main_logo": "メインロゴをデフォルトにリセットしました",
+ "resource_added": "リソース %s を追加しました",
+ "resource_modified": "メールボックス %s の変更が保存されました",
+ "resource_removed": "リソース %s を削除しました",
+ "rl_saved": "オブジェクト %s のレート制限を保存しました",
+ "rspamd_ui_pw_set": "Rspamd UIパスワードを正常に設定しました",
+ "saved_settings": "設定を保存しました",
+ "settings_map_added": "設定マップエントリを追加しました",
+ "settings_map_removed": "設定マップID %s を削除しました",
+ "sogo_profile_reset": "ユーザー %s のSOGoプロファイルをリセットしました",
+ "template_added": "テンプレート %s を追加しました",
+ "template_modified": "テンプレート %s の変更が保存されました",
+ "template_removed": "テンプレートID %s を削除しました",
+ "tls_policy_map_entry_deleted": "TLSポリシーマップID %s を削除しました",
+ "tls_policy_map_entry_saved": "TLSポリシーマップエントリ \"%s\" を保存しました",
+ "ui_texts": "UIテキストの変更を保存しました",
+ "upload_success": "ファイルを正常にアップロードしました",
+ "verified_fido2_login": "FIDO2ログインを確認しました",
+ "verified_totp_login": "TOTPログインを確認しました",
+ "verified_webauthn_login": "WebAuthnログインを確認しました",
+ "verified_yotp_login": "Yubico OTPログインを確認しました"
+ },
+ "tfa": {
+ "authenticators": "認証アプリ",
+ "api_register": "%s は Yubico Cloud API を使用しています。<a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">こちら</a>からAPIキーを取得してください。",
+ "confirm": "確認",
+ "confirm_totp_token": "生成されたトークンを入力して変更を確認してください。",
+ "delete_tfa": "TFAを無効化",
+ "disable_tfa": "次回の成功したログインまでTFAを無効化",
+ "enter_qr_code": "デバイスがQRコードをスキャンできない場合、以下のTOTPコードを入力してください。",
+ "error_code": "エラーコード",
+ "init_webauthn": "初期化中です。しばらくお待ちください...",
+ "key_id": "デバイスの識別子",
+ "key_id_totp": "キーの識別子",
+ "none": "無効化",
+ "reload_retry": "- (エラーが続く場合はブラウザを再読み込みしてください)",
+ "scan_qr_code": "以下のコードを認証アプリでスキャンするか、手動でコードを入力してください。",
+ "select": "選択してください",
+ "set_tfa": "二要素認証方法を設定",
+ "start_webauthn_validation": "検証を開始",
+ "tfa": "二要素認証",
+ "tfa_token_invalid": "TFAトークンが無効です",
+ "totp": "時間ベースOTP(Google Authenticator、Authyなど)",
+ "u2f_deprecated": "キーが非推奨のU2F方式で登録されているようです。二要素認証を無効化し、キーを削除します。",
+ "u2f_deprecated_important": "管理パネルで新しいWebAuthn方式を使用してキーを登録してください。",
+ "webauthn": "WebAuthn認証",
+ "waiting_usb_auth": "<i>USBデバイスを待っています...</i><br><br>USBデバイスのボタンを押してください。",
+ "waiting_usb_register": "<i>USBデバイスを待っています...</i><br><br>上記にパスワードを入力し、USBデバイスのボタンを押して登録を確認してください。",
+ "yubi_otp": "Yubico OTP認証"
+ },
+ "user": {
+ "action": "アクション",
+ "active": "有効",
+ "active_sieve": "アクティブなフィルタ",
+ "advanced_settings": "詳細設定",
+ "alias": "エイリアス",
+ "alias_create_random": "ランダムなエイリアスを生成",
+ "alias_extend_all": "エイリアスを1時間延長",
+ "alias_full_date": "d.m.Y, H:i:s T",
+ "alias_remove_all": "すべてのエイリアスを削除",
+ "alias_select_validity": "有効期間",
+ "alias_time_left": "残り時間",
+ "alias_valid_until": "有効期限",
+ "aliases_also_send_as": "ユーザーとしての送信も許可",
+ "aliases_send_as_all": "以下のドメインおよびそのエイリアスドメインの送信者アクセスを確認しない",
+ "app_hint": "アプリパスワードは、IMAP、SMTP、CalDAV、CardDAV、EASのログイン用の代替パスワードです。ユーザー名は変更されません。SOGoウェブメールはアプリパスワードで利用できません。",
+ "allowed_protocols": "許可されたプロトコル",
+ "app_name": "アプリ名",
+ "app_passwds": "アプリパスワード",
+ "apple_connection_profile": "Apple接続プロファイル",
+ "apple_connection_profile_complete": "この接続プロファイルには、Appleデバイス向けのIMAPおよびSMTPパラメータ、CalDAV(カレンダー)、CardDAV(連絡先)のパスが含まれます。",
+ "apple_connection_profile_mailonly": "この接続プロファイルには、Appleデバイス向けのIMAPおよびSMTP設定パラメータが含まれます。",
+ "apple_connection_profile_with_app_password": "新しいアプリパスワードが生成され、プロファイルに追加されるため、デバイスのセットアップ時にパスワードを入力する必要はありません。このファイルを共有しないでください。メールボックスへの完全なアクセス権を与えます。",
+ "attribute": "属性",
+ "change_password": "パスワードを変更",
+ "change_password_hint_app_passwords": "アカウントには %d のアプリパスワードがあり、それらは変更されません。これらを管理するには、「アプリパスワード」タブに移動してください。",
+ "clear_recent_successful_connections": "最近の成功した接続をクリア",
+ "client_configuration": "メールクライアントとスマートフォンの設定ガイドを表示",
+ "create_app_passwd": "アプリパスワードを作成",
+ "create_syncjob": "新しい同期ジョブを作成",
+ "created_on": "作成日",
+ "daily": "毎日",
+ "day": "日",
+ "description": "説明",
+ "delete_ays": "削除プロセスを確認してください。",
+ "direct_aliases": "直接エイリアスアドレス",
+ "direct_aliases_desc": "直接エイリアスアドレスは、スパムフィルターおよびTLSポリシー設定の影響を受けます。",
+ "direct_protocol_access": "このメールボックスユーザーは以下のプロトコルおよびアプリケーションへの<b>直接的かつ外部からのアクセス</b>が可能です。この設定は管理者によって制御されます。アプリパスワードを作成することで、個々のプロトコルおよびアプリケーションへのアクセスを許可できます。<br>「ウェブメールにログイン」ボタンはSOGoへのシングルサインオンを提供し、常に利用可能です。",
+ "eas_reset": "ActiveSyncデバイスキャッシュをリセット",
+ "eas_reset_help": "多くの場合、デバイスキャッシュのリセットは壊れたActiveSyncプロファイルの回復に役立ちます。<br><b>注意:</b> すべての要素が再ダウンロードされます!",
+ "eas_reset_now": "今すぐリセット",
+ "edit": "編集",
+ "email": "メール",
+ "email_and_dav": "メール、カレンダー、および連絡先",
+ "empty": "結果なし",
+ "encryption": "暗号化",
+ "excludes": "除外",
+ "expire_in": "有効期限まで",
+ "expire_never": "有効期限なし",
+ "fido2_webauthn": "FIDO2/WebAuthn",
+ "forever": "有効期限なし",
+ "force_pw_update": "グループウェア関連サービスにアクセスするには、新しいパスワードを<b>必ず</b>設定する必要があります。",
+ "from": "送信元",
+ "generate": "生成",
+ "hour": "時間",
+ "hourly": "毎時",
+ "hours": "時間",
+ "in_use": "使用中",
+ "interval": "間隔",
+ "is_catch_all": "ドメイン用キャッチオール",
+ "last_mail_login": "最後のメールログイン",
+ "last_pw_change": "最後のパスワード変更",
+ "last_run": "最後の実行",
+ "last_ui_login": "最後のUIログイン",
+ "loading": "読み込み中...",
+ "login_history": "ログイン履歴",
+ "mailbox": "メールボックス",
+ "mailbox_details": "詳細",
+ "mailbox_general": "一般",
+ "mailbox_settings": "設定",
+ "messages": "メッセージ",
+ "month": "月",
+ "months": "ヶ月",
+ "never": "なし",
+ "new_password": "新しいパスワード",
+ "new_password_repeat": "確認用パスワード(再入力)",
+ "no_active_filter": "利用可能なアクティブなフィルタがありません",
+ "no_last_login": "最後のUIログイン情報がありません",
+ "no_record": "記録なし",
+ "open_logs": "ログを開く",
+ "open_webmail_sso": "ウェブメールにログイン",
+ "password": "パスワード",
+ "password_now": "現在のパスワード(変更を確認)",
+ "password_repeat": "パスワード(再入力)",
+ "password_reset_info": "パスワードリカバリ用のメールが提供されていない場合、この機能は使用できません。",
+ "pushover_evaluate_x_prio": "高優先度メールをエスカレーション [<code>X-Priority: 1</code>]",
+ "pushover_info": "プッシュ通知設定は、<b>%s</b>に配信されるすべてのクリーン(スパムでない)メールに適用されます。エイリアス(共有、非共有、タグ付き)も含まれます。",
+ "pushover_only_x_prio": "高優先度メールのみを考慮 [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "以下の送信者メールアドレスを考慮<small>(カンマ区切り)</small>",
+ "pushover_sender_regex": "以下の正規表現で送信者を一致",
+ "pushover_text": "通知テキスト",
+ "pushover_title": "通知タイトル",
+ "pushover_sound": "通知音",
+ "pushover_vars": "送信者フィルターが定義されていない場合、すべてのメールが考慮されます。<br>正規表現フィルターおよび正確な送信者チェックを個別に定義可能で、順次考慮されます。これらは互いに依存しません。<br>テキストおよびタイトルに使用可能な変数(データ保護ポリシーに注意してください)",
+ "pushover_verify": "資格情報を確認",
+ "pw_recovery_email": "パスワードリカバリメール",
+ "q_add_header": "迷惑メールフォルダ",
+ "q_all": "すべてのカテゴリ",
+ "q_reject": "拒否された",
+ "quarantine_category": "隔離通知カテゴリ",
+ "quarantine_category_info": "通知カテゴリ\"拒否\"には拒否されたメールが含まれます。一方\"迷惑メールフォルダ\"は、迷惑メールフォルダに振り分けられたメールをユーザーに通知します。",
+ "quarantine_notification": "隔離通知",
+ "quarantine_notification_info": "通知が送信されると、アイテムは\"通知済み\"としてマークされ、該当アイテムに対してさらに通知は送信されません。",
+ "recent_successful_connections": "最近の成功した接続",
+ "remove": "削除",
+ "running": "稼働中",
+ "save": "変更を保存",
+ "save_changes": "変更を保存",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">送信者チェックが無効です</span>",
+ "shared_aliases": "共有エイリアスアドレス",
+ "shared_aliases_desc": "共有エイリアスは、スパムフィルターや暗号化ポリシーなどのユーザー固有の設定の影響を受けません。対応するスパムフィルターは、ドメイン全体のポリシーとして管理者のみが設定可能です。",
+ "show_sieve_filters": "アクティブなユーザーシーブフィルタを表示",
+ "sogo_profile_reset": "SOGoプロファイルをリセット",
+ "sogo_profile_reset_help": "これにより、ユーザーのSOGoプロファイルが破壊され、<b>連絡先とカレンダーデータが完全に削除されます</b>。",
+ "sogo_profile_reset_now": "今すぐプロファイルをリセット",
+ "spam_aliases": "一時メールエイリアス",
+ "spam_score_reset": "サーバーデフォルトにリセット",
+ "spamfilter": "スパムフィルター",
+ "spamfilter_behavior": "評価",
+ "spamfilter_bl": "ブラックリスト",
+ "spamfilter_bl_desc": "ブラックリストに登録されたメールアドレスは<b>常に</b>スパムとして分類され拒否されます。拒否されたメールは<b>隔離されません</b>。ワイルドカードを使用できます。フィルターは直接エイリアス(単一ターゲットメールボックスを持つエイリアス)にのみ適用され、キャッチオールエイリアスやメールボックス自体には適用されません。",
+ "spamfilter_default_score": "デフォルト値",
+ "spamfilter_green": "緑: このメッセージはスパムではありません",
+ "spamfilter_hint": "最初の値は「低スパムスコア」を表し、2番目の値は「高スパムスコア」を表します。",
+ "spamfilter_red": "赤: このメッセージはスパムであり、サーバーによって拒否されます",
+ "spamfilter_table_action": "アクション",
+ "spamfilter_table_add": "アイテムを追加",
+ "spamfilter_table_domain_policy": "該当なし(ドメインポリシー)",
+ "spamfilter_table_empty": "表示するデータがありません",
+ "spamfilter_table_remove": "削除",
+ "spamfilter_table_rule": "ルール",
+ "spamfilter_wl": "ホワイトリスト",
+ "spamfilter_wl_desc": "ホワイトリストに登録されたメールアドレスは<b>絶対に</b>スパムとして分類されません。ワイルドカードを使用できます。フィルターは直接エイリアス(単一ターゲットメールボックスを持つエイリアス)にのみ適用され、キャッチオールエイリアスやメールボックス自体には適用されません。",
+ "spamfilter_yellow": "黄: このメッセージはスパムの可能性があり、スパムとしてタグ付けされ、迷惑メールフォルダに移動されます",
+ "status": "ステータス",
+ "sync_jobs": "同期ジョブ",
+ "syncjob_check_log": "ログを確認",
+ "syncjob_last_run_result": "最後の実行結果",
+ "syncjob_EX_OK": "成功",
+ "syncjob_EXIT_CONNECTION_FAILURE": "接続問題",
+ "syncjob_EXIT_TLS_FAILURE": "暗号化接続の問題",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "認証問題",
+ "syncjob_EXIT_OVERQUOTA": "宛先メールボックスがクォータ超過",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "リモートサーバーに接続できません",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "ユーザー名またはパスワードが間違っています",
+ "tag_handling": "タグ付きメールの処理を設定",
+ "tag_help_example": "タグ付きメールアドレスの例: me<b>+Facebook</b>@example.org",
+ "tag_help_explain": "サブフォルダー: タグ名に基づいて新しいサブフォルダーがINBOXの下に作成されます(例: \"INBOX/Facebook\")。<br>\r\n件名: タグ名がメールの件名に追加されます(例: \"[Facebook] My News\")。",
+ "tag_in_none": "何もしない",
+ "tag_in_subfolder": "サブフォルダーに移動",
+ "tag_in_subject": "件名に追加",
+ "text": "テキスト",
+ "title": "タイトル",
+ "tls_enforce_in": "TLS受信を強制",
+ "tls_enforce_out": "TLS送信を強制",
+ "tls_policy": "暗号化ポリシー",
+ "tls_policy_warning": "<strong>警告:</strong> 暗号化メール転送を強制する場合、メールを失う可能性があります。<br>ポリシーを満たさないメッセージは、メールシステムによってハードフェイルでバウンスされます。<br>このオプションは、プライマリメールアドレス(ログイン名)、エイリアスドメインから派生したすべてのアドレス、および<b>この単一メールボックスのみ</b>をターゲットとするエイリアスアドレスに適用されます。",
+ "user_settings": "ユーザー設定",
+ "username": "ユーザー名",
+ "value": "値",
+ "verify": "確認",
+ "waiting": "待機中",
+ "week": "週",
+ "weekly": "毎週",
+ "weeks": "週",
+ "with_app_password": "アプリパスワードを使用",
+ "year": "年",
+ "years": "年"
+ },
+ "warning": {
+ "cannot_delete_self": "ログイン中のユーザーは削除できません",
+ "domain_added_sogo_failed": "ドメインは追加されましたが、SOGoの再起動に失敗しました。サーバーログを確認してください。",
+ "dovecot_restart_failed": "Dovecotの再起動に失敗しました。ログを確認してください。",
+ "fuzzy_learn_error": "ファジーハッシュ学習エラー: %s",
+ "hash_not_found": "ハッシュが見つからないか、すでに削除されています",
+ "ip_invalid": "無効なIPをスキップしました: %s",
+ "is_not_primary_alias": "プライマリアイアスではないためスキップされました: %s",
+ "no_active_admin": "最後のアクティブな管理者を無効化することはできません",
+ "quota_exceeded_scope": "ドメインのクォータを超えています。このドメインスコープでは無制限のメールボックスのみ作成可能です。",
+ "session_token": "フォームトークンが無効です: トークンの不一致",
+ "session_ua": "フォームトークンが無効です: ユーザーエージェント検証エラー"
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ko-kr.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ko-kr.json
index 3f3cb15..684339b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ko-kr.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ko-kr.json
@@ -25,7 +25,11 @@
"syncjobs": "동기화 작업",
"tls_policy": "TLS 정책",
"unlimited_quota": "메일에 무제한 할당",
- "domain_desc": "도메인 설명 변경"
+ "domain_desc": "도메인 설명 변경",
+ "pw_reset": "mailcow 사용자 비밀번호 재설정 허용",
+ "domain_relayhost": "도메인의 릴레이 호스트 변경",
+ "mailbox_relayhost": "메일함의 릴레이 호스트 변경",
+ "quarantine_category": "검역소 알림 카테고리 변경"
},
"add": {
"activate_filter_warn": "활성화가 체크되어 있으면 모든 다른 필터들은 비활성화됩니다.",
@@ -101,7 +105,9 @@
"timeout2": "로컬 호스트 연결 시간 초과",
"username": "사용자명",
"validate": "확인하기",
- "validation_success": "성공적으로 확인됨"
+ "validation_success": "성공적으로 확인됨",
+ "tags": "태그",
+ "app_passwd_protocols": "앱 비밀번호에 대해 허용되는 프로토콜"
},
"admin": {
"access": "접근",
@@ -195,7 +201,7 @@
"link": "Link",
"loading": "잠시만 기다려주세요...",
"logo_info": "이미지 크기는 상단 탐색 막대의 경우 40px, 시작 페이지의 경우 최대 너비 250px로 조정됩니다. 확장 가능한 그래픽을 권장합니다.",
- "lookup_mx": "MX와 목적지 일치 (.outlook.com이 홉을 통해서 MX *.outlook.com을 대상으로 하는 모든 메일을 라우트한다.)",
+ "lookup_mx": "목적지가 MX 이름과 일치하는 정규 표현식입니다. (<code>.*\\.google\\.com</code>를 사용하여 이 홉을 통해 google.com으로 끝나는 모든 메일을 대상으로 하는 MX로 라우팅합니다.)",
"main_name": "\"mailcow UI\" 이름",
"merged_vars_hint": "회색으로 표시된 행은 <code>vars.(local.)php</code> 에서 병합되었고 이는 수정할 수 없습니다.",
"message": "메세지",
@@ -301,7 +307,53 @@
"username": "사용자 이름",
"validate_license_now": "라이선스 서버와 GUID 확인",
"verify": "확인",
- "yes": "✓"
+ "yes": "✓",
+ "domain_admin": "도메인 관리자",
+ "f2b_filter": "정규식 필터",
+ "f2b_manage_external": "외부에서 Fail2Ban 관리",
+ "f2b_max_ban_time": "최대 차단 시간(초)",
+ "f2b_regex_info": "고려되는 로그: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "html": "HTML",
+ "oauth2_apps": "OAuth2 앱",
+ "oauth2_add_client": "OAuth2 클라이언트 추가",
+ "optional": "선택 사항",
+ "options": "옵션",
+ "password_length": "비밀번호 길이",
+ "password_policy_chars": "하나 이상의 알파벳 문자를 포함해야 합니다.",
+ "password_policy_length": "최소 암호 길이가 %d입니다.",
+ "password_policy_numbers": "숫자 하나 이상을 포함해야 합니다.",
+ "password_policy_special_chars": "특수 문자를 포함해야 합니다.",
+ "password_reset_info": "복구 이메일이 제공되지 않으면 이 기능을 사용할 수 없습니다.",
+ "password_reset_settings": "비밀번호 복구 설정",
+ "password_reset_tmpl_html": "HTML 템플릿",
+ "password_reset_tmpl_text": "Text 템플릿",
+ "password_settings": "비밀번호 설정",
+ "queue_unban": "차단 해제",
+ "restore_template": "기본 템플릿을 복원하려면 비워둡니다.",
+ "service": "서비스",
+ "success": "성공",
+ "dkim_overwrite_key": "기존 DKIM 키 덮어쓰기",
+ "f2b_ban_time_increment": "차단 시간은 차단될 때마다 증가합니다.",
+ "password_policy": "비밀번호 정책",
+ "quarantine_max_score": "메일의 스팸 점수가 이 값보다 높으면 알림을 삭제합니다:<br><small>기본값: 9999.0</small>",
+ "f2b_manage_external_info": "Fail2ban은 차단 목록을 유지하지만 트래픽을 차단하는 규칙을 능동적으로 설정하지는 않습니다. 트래픽을 외부에서 차단하려면 아래 생성된 차단 목록을 사용하세요.",
+ "password_policy_lowerupper": "소문자 및 대문자를 포함해야 합니다.",
+ "transport_test_rcpt_info": "• null@hosted.mailcow.de 을 사용하여 해외 목적지로 릴레이를 테스트하세요.",
+ "ip_check_disabled": "IP 확인이 비활성화됩니다. 아래에서 활성화할 수 있습니다<br> <strong>시스템 > 구성 > 옵션 > 사용자 정의</strong>",
+ "logo_normal_label": "일반",
+ "logo_dark_label": "다크 모드의 경우 반전",
+ "convert_html_to_text": "HTML을 일반 텍스트로 변환",
+ "copy_to_clipboard": "클립보드에 텍스트가 복사되었습니다!",
+ "cors_settings": "CORS 설정",
+ "rsettings_preset_4": "도메인에 대해 Rspamd 비활성화",
+ "ip_check": "IP 확인",
+ "admins": "관리자",
+ "admins_ldap": "LDAP 관리자",
+ "api_read_only": "읽기 전용 액세스",
+ "api_read_write": "읽기-쓰기 액세스",
+ "is_mx_based": "MX 기반",
+ "login_time": "로그인 시간",
+ "ip_check_opt_in": "외부 IP 주소 확인을 위해 타사 서비스 <strong>ipv4.mailcow.email</strong> 및 <strong>ipv6.mailcow.email</strong>을 사용하도록 설정합니다."
},
"danger": {
"access_denied": "접근이 거부되거나 잘못된 데이터 양식",
@@ -415,7 +467,30 @@
"username_invalid": "%s는 사용지 이름으로 사용할 수 없습니다.",
"validity_missing": "유효 기간을 지정해주세요.",
"value_missing": "모든 값을 입력해주세요.",
- "yotp_verification_failed": "Yubico OTP 검증 실패: %s"
+ "yotp_verification_failed": "Yubico OTP 검증 실패: %s",
+ "dkim_domain_or_sel_exists": "“%s\"에 대한 DKIM 키가 존재하며 덮어쓰지 않습니다.",
+ "img_size_exceeded": "이미지가 최대 파일 크기를 초과합니다.",
+ "invalid_reset_token": "잘못된 리셋 토큰",
+ "nginx_reload_failed": "Nginx 리로드 실패: %s",
+ "password_reset_na": "현재 비밀번호 복구를 사용할 수 없습니다. 관리자에게 문의하세요.",
+ "reset_f2b_regex": "정규식 필터를 제때 재설정하지 못했습니다. 다시 시도하거나 몇 초 더 기다렸다가 웹사이트를 다시 로드하세요.",
+ "template_exists": "템플릿 %s이(가) 이미 존재합니다.",
+ "template_id_invalid": "템플릿 ID %s가 잘못되었습니다.",
+ "template_name_invalid": "템플릿 이름이 잘못되었습니다.",
+ "tfa_token_invalid": "TFA 토큰이 유효하지 않습니다.",
+ "to_invalid": "수신자가 비어 있지 않아야 합니다.",
+ "webauthn_authenticator_failed": "선택한 인증기를 찾을 수 없습니다.",
+ "webauthn_username_failed": "선택한 인증기가 다른 계정에 속해 있습니다.",
+ "demo_mode_enabled": "데모 모드가 활성화됨",
+ "recovery_email_failed": "복구 이메일을 보낼 수 없습니다. 관리자에게 문의하세요.",
+ "password_reset_invalid_user": "사서함을 찾을 수 없거나 복구 이메일이 설정되어 있지 않습니다.",
+ "webauthn_publickey_failed": "선택한 인증기에 대한 공개 키가 저장되지 않았습니다.",
+ "fido2_verification_failed": "FIDO2 인증 실패: %s",
+ "extended_sender_acl_denied": "외부 발신자 주소를 설정하는 ACL 누락",
+ "img_dimensions_exceeded": "이미지가 최대 이미지 크기를 초과합니다.",
+ "reset_token_limit_exceeded": "토큰 재설정 한도를 초과했습니다. 나중에 다시 시도해 주세요.",
+ "cors_invalid_method": "잘못된 허용 메서드를 지정했습니다.",
+ "cors_invalid_origin": "잘못된 허용 원본을 지정했습니다."
},
"debug": {
"chart_this_server": "Chart (this server)",
@@ -424,20 +499,34 @@
"external_logs": "External logs",
"history_all_servers": "History (all servers)",
"in_memory_logs": "In-memory logs",
- "jvm_memory_solr": "JVM memory usage",
"log_info": "<p>mailcow <b>in-memory logs</b> are collected in Redis lists and trimmed to LOG_LINES (%d) every minute to reduce hammering.\r\n <br>In-memory logs are not meant to be persistent. All applications that log in-memory, also log to the Docker daemon and therefore to the default logging driver.\r\n <br>The in-memory log type should be used for debugging minor issues with containers.</p>\r\n <p><b>External logs</b> are collected via API of the given application.</p>\r\n <p><b>Static logs</b> are mostly activity logs, that are not logged to the Dockerd but still need to be persistent (except for API logs).</p>",
"logs": "Logs",
"restart_container": "Restart",
- "solr_dead": "Solr is starting, disabled or died.",
"docs": "Docs",
"last_modified": "Last modified",
"size": "Size",
"started_at": "Started at",
- "solr_status": "Solr status",
"uptime": "Uptime",
"started_on": "Started on",
"static_logs": "Static logs",
- "system_containers": "System & Containers"
+ "system_containers": "System & Containers",
+ "current_time": "시스템 시간",
+ "no_update_available": "시스템이 최신 버전입니다.",
+ "architecture": "아키텍처",
+ "container_running": "실행 중",
+ "container_disabled": "컨테이너 중지 또는 비활성화",
+ "container_stopped": "중지됨",
+ "online_users": "온라인 사용자",
+ "service": "서비스",
+ "success": "성공",
+ "show_ip": "공인 IP 표시",
+ "timezone": "시간대",
+ "update_available": "사용 가능한 업데이트가 있습니다.",
+ "update_failed": "업데이트를 확인할 수 없습니다",
+ "username": "사용자 이름",
+ "memory": "메모리",
+ "error_show_ip": "공인 IP 주소를 확인할 수 없습니다",
+ "login_time": "시간"
},
"diagnostics": {
"cname_from_a": "Value derived from A/AAAA record. This is supported as long as the record points to the correct resource.",
@@ -545,7 +634,13 @@
"title": "Edit object",
"unchanged_if_empty": "If unchanged leave blank",
"username": "Username",
- "validate_save": "Validate and save"
+ "validate_save": "Validate and save",
+ "allow_from_smtp": "다음 IP만 <b>SMTP</b>를 사용하도록 허용합니다.",
+ "allow_from_smtp_info": "모든 발신자를 허용하려면 비워둡니다.<br>IPv4/IPv6 주소 및 네트워크.",
+ "allowed_protocols": "허용된 프로토콜",
+ "app_passwd_protocols": "앱 비밀번호에 대해 허용되는 프로토콜",
+ "acl": "ACL (권한)",
+ "admin": "관리자 수정"
},
"footer": {
"cancel": "Cancel",
@@ -563,13 +658,14 @@
"header": {
"administration": "Configuration & Details",
"apps": "Apps",
- "debug": "System Information",
+ "debug": "정보",
"email": "E-Mail",
"mailcow_config": "Configuration",
"quarantine": "Quarantine",
"restart_netfilter": "Restart netfilter",
"restart_sogo": "Restart SOGo",
- "user_settings": "User Settings"
+ "user_settings": "User Settings",
+ "mailcow_system": "시스템"
},
"info": {
"awaiting_tfa_confirmation": "Awaiting TFA confirmation",
@@ -676,9 +772,9 @@
"recipient_map": "Recipient map",
"recipient_map_info": "Recipient maps are used to replace the destination address on a message before it is delivered.",
"recipient_map_new": "New recipient",
- "recipient_map_new_info": "Recipient map destination must be a valid email address.",
+ "recipient_map_new_info": "Recipient map destination must be a valid email addresses or a domain name.",
"recipient_map_old": "Original recipient",
- "recipient_map_old_info": "A recipient maps original destination must be valid email addresses or a domain name.",
+ "recipient_map_old_info": "A recipient maps original destination must be a valid email addresses or a domain name.",
"recipient_maps": "Recipient maps",
"relay_all": "모든 수신자에게 릴레이",
"remove": "Remove",
@@ -781,9 +877,7 @@
},
"start": {
"help": "Show/Hide help panel",
- "imap_smtp_server_auth_info": "Please use your full email address and the PLAIN authentication mechanism.<br>\r\nYour login data will be encrypted by the server-side mandatory encryption.",
- "mailcow_apps_detail": "Use a mailcow app to access your mails, calendar, contacts and more.",
- "mailcow_panel_detail": "<b>Domain administrators</b> create, modify or delete mailboxes and aliases, change domains and read further information about their assigned domains.<br>\r\n<b>Mailbox users</b> are able to create time-limited aliases (spam aliases), change their password and spam filter settings."
+ "imap_smtp_server_auth_info": "Please use your full email address and the PLAIN authentication mechanism.<br>\r\nYour login data will be encrypted by the server-side mandatory encryption."
},
"success": {
"acl_saved": "ACL for object %s saved",
@@ -911,6 +1005,7 @@
"create_syncjob": "새 동기화 작업 생성",
"daily": "매일",
"day": "일",
+ "description": "Description",
"delete_ays": "진짜 삭제하겠습니까?",
"direct_aliases": "Direct alias addresses",
"direct_aliases_desc": "Direct alias addresses are affected by spam filter and TLS policy settings.",
@@ -1019,5 +1114,25 @@
"quota_exceeded_scope": "Domain quota exceeded: Only unlimited mailboxes can be created in this domain scope.",
"session_token": "Form token invalid: Token mismatch",
"session_ua": "Form token invalid: User-Agent validation error"
+ },
+ "datatables": {
+ "collapse_all": "모두 접기",
+ "decimal": ".",
+ "emptyTable": "테이블에 사용 가능한 데이터가 없습니다.",
+ "expand_all": "모두 펼치기",
+ "infoEmpty": "0개 항목 중 0개부터 0개까지 표시",
+ "infoFiltered": "(_MAX_ 총 항목에서 필터링됨)",
+ "thousands": ",",
+ "lengthMenu": "_MENU_ 항목 표시",
+ "loadingRecords": "로딩 중...",
+ "processing": "잠시만 기다려 주세요...",
+ "search": "검색:",
+ "zeroRecords": "일치하는 레코드가 없습니다.",
+ "paginate": {
+ "first": "처음",
+ "last": "마지막",
+ "next": "다음",
+ "previous": "이전"
+ }
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.lt-lt.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.lt-lt.json
new file mode 100644
index 0000000..78e48ea
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.lt-lt.json
@@ -0,0 +1,354 @@
+{
+ "acl": {
+ "app_passwds": "Tvarkyti programėlių slaptažodžius",
+ "bcc_maps": "BCC žemėlapiai",
+ "domain_desc": "Keisti domeno aprašymą",
+ "eas_reset": "Išvalyti EAS įrenginius",
+ "filters": "Filtrai",
+ "login_as": "Prisijungti kaip elektroninio pašto naudotojas",
+ "protocol_access": "Keisti protokolų prieigą",
+ "quarantine": "Karantino valdymas",
+ "quarantine_category": "Keisti karantino pranešimo katrgoriją",
+ "quarantine_notification": "Keisti karantino pranešimus",
+ "ratelimit": "Prieigos limitas",
+ "recipient_maps": "Gavėjų sąsajos",
+ "smtp_ip_access": "Pakeisti prieinamuosius SMTP serverius",
+ "sogo_access": "Leisti SOGo prieigos valdymą",
+ "spam_policy": "Juodasis/Baltasis sąrašas",
+ "spam_score": "Šlamsto balas",
+ "tls_policy": "TLS politika",
+ "unlimited_quota": "Neribota elektroninio pašto dėžudžių kvota",
+ "quarantine_attachments": "Karantino priedai",
+ "sogo_profile_reset": "Nustatyti SOGo profilį iš naujo",
+ "alias_domains": "Pridėti pakaitinius domenus",
+ "delimiter_action": "Delimitatoriaus veiksmas",
+ "domain_relayhost": "Pakeisti peradresavimo serverį domenui",
+ "extend_sender_acl": "Leisti išplėsti siuntėjo ACL išoriniais adresais",
+ "mailbox_relayhost": "Pakeisti siuntimo serverį pašto dėžutei",
+ "prohibited": "Draudžiama pagal ACL",
+ "spam_alias": "Laikini slapyvardžiai",
+ "syncjobs": "Sinchronizuoti darbus"
+ },
+ "add": {
+ "active": "Aktyvus",
+ "add": "Pridėti",
+ "add_domain_only": "Pridėti tik domeną",
+ "add_domain_restart": "Pridėti domeną ir paleisti SOGo iš naujo",
+ "alias_domain_info": "<small>Tik tinkami domenų vardai (išskirta kableliais).</small>",
+ "app_name": "Programėlės pavadinimas",
+ "app_password": "Pridėti programėlės slaptažodį",
+ "app_passwd_protocols": "Prieinamieji programėlės slaptažodžio protokolai",
+ "custom_params": "Pasirinktiniai parametrai",
+ "delete1": "Ištrinti iš šaltinio, kai baigta",
+ "activate_filter_warn": "Visi kiti filtrai bus deaktivuoti, kai „aktyvus“ yra pražymėtas.",
+ "custom_params_hint": "Teisingai: --param=xy, neteisingai: --param xy",
+ "description": "Aprašymas",
+ "destination": "Gavėjas",
+ "domain": "Domenas",
+ "domain_quota_m": "Viso domeno kvota (MiB)",
+ "dry": "Simuliuoti sinchronizaciją",
+ "enc_method": "Šifravimo metodas",
+ "full_name": "Prilnas vardas",
+ "generate": "generuoti",
+ "goto_null": "Tyliai atmesti žinutes",
+ "goto_spam": "Išmokti kaip <span class=\"text-danger\"><b>šlamštas</b></span>",
+ "password": "Slaptažodis",
+ "select": "Pasirinkite...",
+ "select_domain": "Prima, pasirinkite domeną",
+ "sieve_desc": "Trumpas aprašymas",
+ "sieve_type": "Filtro tipas",
+ "mailbox_quota_def": "Numatytoji elelktroninio pašto dėžutės kvota",
+ "password_repeat": "Slaptažodžio patvirtininas (pakartoti)",
+ "disable_login": "Uždrausti prisijungimą (ateinančios žinutės vistiek bus gaunamos)",
+ "inactive": "Neaktyvus",
+ "alias_address": "Pakaitiniai/is adresai/as",
+ "alias_address_info": "<small>Pilnas el. pašto adresas (-ai) arba @example.com, kad gautumėte visus pranešimus iš domeno (atskirtus kableliais). <b>Tik \"mailcow\" domenai</b>.</small>",
+ "alias_domain": "Pakaitinis domenas",
+ "automap": "Stenktis automatiškai susieti aplankus (\"Išsiųsti\", \"Išsiųsti\" => \"išsiųsti\" ir tt.)",
+ "backup_mx_options": "Perdavimo nustatymai",
+ "bcc_dest_format": "BCC gavimo adresas turi būti vienas galiojantis el. pašto adresas.<br>Jei turite siųsti kopiją į kelis adresus, sukurkite slapyvardį ir naudokite jį čia.",
+ "delete2": "Ištrinti žinutes gavimo vietoje, kurios nėra šaltinyje.",
+ "delete2duplicates": "Ištrinti dublikatus gavimo vietoje",
+ "domain_matches_hostname": "Domenas %s atitinka serverio vardą",
+ "exclude": "Išskirti objektus (regex)",
+ "gal": "Visuotinis adresų sąrašas",
+ "gal_info": "GAL (Global Address List) apima visus domeno objektus ir jų negali redaguoti joks vartotojas. SOGo trūksta laisvosios/užimtosios informacijos, jei tai išjungta! <b>Perkraukite SOGo, kad pritaikytumėte pakeitimus.</b>"
+ },
+ "admin": {
+ "access": "Prieiga",
+ "active": "Aktyvus",
+ "add": "Pridėti",
+ "add_admin": "Pridėti administratorių",
+ "add_domain_admin": "Pridėti domeno administratorių",
+ "add_settings_rule": "Pridėti nustatymų taisyklę",
+ "admin": "Administratorius",
+ "admins": "Administratoriai",
+ "admins_ldap": "LDAP administratoriai",
+ "api_key": "API prieigos raktas",
+ "copy_to_clipboard": "Tekstas nukopijuotas!",
+ "cors_settings": "CORS nustatymai",
+ "dkim_from": "Iš",
+ "dkim_key_length": "DKIM rakto ilgis (bitai)",
+ "dkim_key_valid": "Raktas tinkamas",
+ "dkim_keys": "ARC/DKIM raktai",
+ "dkim_private_key": "Slaptasis raktas",
+ "dkim_to": "Į",
+ "domain": "Domenas",
+ "domain_admin": "Domeno administratorius",
+ "domain_admins": "Doneno administratoriai",
+ "domain_s": "Domenas/ai",
+ "duplicate": "Dublikatas",
+ "duplicate_dkim": "Dublikuotas DKIM įrašas",
+ "edit": "Redaguoti",
+ "empty": "Jokių rezultatų",
+ "f2b_filter": "Regex filtrai",
+ "filter_table": "Filtrų lentelė",
+ "from": "Nuo",
+ "generate": "generuoti",
+ "html": "HTML",
+ "import": "Importuoti",
+ "inactive": "Neaktyvus",
+ "message": "Žinutė",
+ "message_size": "Žinutės dydis",
+ "nexthop": "Kitas šuolis",
+ "no": "✕",
+ "no_record": "Nėra įrašo",
+ "oauth2_apps": "OAuth2 Programėlės",
+ "oauth2_add_client": "Pridėti OAuth2 klientą",
+ "oauth2_client_id": "Kliento ID",
+ "optional": "pasirinktinas",
+ "options": "Nustatymai",
+ "password": "Slaptažodis",
+ "password_length": "Slaptažodžio ilgis",
+ "password_policy_chars": "Privalo turėti bent vieną numerį ar skaičių",
+ "password_policy_length": "Mažiausias slaptažodžio ilgis - %d",
+ "password_policy_numbers": "Privalo turėti bent vieną skaičių",
+ "password_policy_special_chars": "Privalo turėti specialiųjų ženklų",
+ "password_repeat": "Slaptažodžio patvirtinimas (pakartoti)",
+ "quarantine": "Karantinas",
+ "quarantine_notification_sender": "Pranešimų e-pašto siuntėjas",
+ "quarantine_release_format_att": "Kaip priedą",
+ "quarantine_release_format_raw": "Nepakeitas originalas",
+ "quota_notifications": "Kvotos pranešimai",
+ "r_active": "Aktyvūs apribojimai",
+ "r_inactive": "Neaktyvus apribojimai",
+ "refresh": "Perkrauti",
+ "regen_api_key": "Regeneruoti API raktą",
+ "relay_rcpt": "„Kam:“ adresas",
+ "relay_run": "Paleisti testą",
+ "remove": "Ištrinti",
+ "rsetting_add_rule": "Pridėti taisyklę",
+ "rsetting_desc": "Trumpas aprašymas",
+ "rspamd_global_filters_agree": "Aš busiu atsargus/i!",
+ "save": "Išsaugoti pakeitimus",
+ "search_domain_da": "Ieškoti domenus",
+ "send": "Siųsti",
+ "sender": "Siuntėjas",
+ "source": "Šaltinis",
+ "spamfilter": "Šlamšto filtras",
+ "text": "Tekstas",
+ "time": "Laikas",
+ "to_top": "Atgal į viršų",
+ "ui_header_announcement_content": "Tekstas (HTML leistina)",
+ "ui_header_announcement_select": "Pasirinkite pranešimo tipą",
+ "ui_header_announcement_type": "Tipas",
+ "ui_header_announcement_type_danger": "Labai svarbus",
+ "ui_header_announcement_type_info": "Info",
+ "upload": "Įkelti",
+ "username": "Naudotojo vardas",
+ "verify": "Patikrinti",
+ "yes": "✓",
+ "customer_id": "Kliento ID",
+ "f2b_parameters": "„Fail2Ban“ parametrai",
+ "import_private_key": "Importuoti slaptąjį raktą",
+ "action": "Veiksmas",
+ "convert_html_to_text": "Konvertuoti HTML į paprastą tekstą",
+ "oauth2_renew_secret": "Geberuoti naują kliento slapuką",
+ "private_key": "Slaptasis raktas",
+ "sal_level": "Moo lygis",
+ "ui_header_announcement_type_warning": "Svarbus",
+ "admin_details": "Redaguoti administratoriaus duomenis",
+ "login_time": "Prisijungino laikas",
+ "ui_header_announcement": "Pranešimai",
+ "dkim_overwrite_key": "Perrašyti egzistuojantį DKIK raktą",
+ "f2b_whitelist": "Tinklai baltajama sąraše",
+ "f2b_blacklist": "Tinklai juodajame saraše",
+ "loading": "Prašau palaukite...",
+ "password_policy_lowerupper": "Privalo turėti mažuosius ir didžiuosius ženklus/raides",
+ "relay_from": "„Nuo:“ adresas"
+ },
+ "danger": {
+ "demo_mode_enabled": "Demo Režimas įjungtas",
+ "description_invalid": "Resurso %s aprašymas yra netinkamas",
+ "domain_exists": "Domenas %s jau egzistuoja",
+ "domain_invalid": "Domeno vardas tuščias arba netinkamas",
+ "domain_not_found": "Domenas %s nerastas",
+ "domain_quota_m_in_use": "Domeno kvota turi būti daygiau arba lygiai %s MiB",
+ "file_open_error": "Failas negali būti atidarytas įrašymui",
+ "filter_type": "Netinkamas filtro tipas",
+ "invalid_mime_type": "Netinkamas MIME tipas",
+ "login_failed": "Prisijungimas nepavyko",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "Numatytoji kvota didesnė nei maksimalus kvotos limitas",
+ "mysql_error": "MySQL problema: %s",
+ "img_invalid": "Negalimas nuotraukos patikrinimas",
+ "mailbox_quota_left_exceeded": "Per mažai vietos diske (liko %d MiB)",
+ "comment_too_long": "Komentaeas per ilgas, maksimalus leistinas simbolių skaičius yra 160",
+ "nginx_reload_failed": "Nginx perkrovimas nepavyko: %s",
+ "invalid_filter_type": "Netinkamas filtro tipas"
+ },
+ "edit": {
+ "validate_save": "Patikrinti ir išsaugoti",
+ "unchanged_if_empty": "Jei nepakeista, palikite tuščią",
+ "username": "Naudotojo vardas"
+ },
+ "fido2": {
+ "confirm": "Patvirtinti",
+ "fido2_success": "Įrenginys sėkmingai užregistruotas",
+ "fido2_validation_failed": "Patikrinimas nepavyko",
+ "fn": "Draugiškasis vardas",
+ "known_ids": "Žinomi ID",
+ "none": "Neįgalintas",
+ "register_status": "Registracijos statusas",
+ "rename": "Pervadyti",
+ "set_fido2_touchid": "Registruokite Touch ID su Apple M1",
+ "set_fn": "Nustatyti draugiškąjį vardą",
+ "start_fido2_validation": "Pradėti FIDO2 patikrinimą",
+ "fido2_auth": "Prisijungti su FIDO2",
+ "set_fido2": "Registruoti FIDO2 įrengenį"
+ },
+ "footer": {
+ "cancel": "Atšaukti",
+ "confirm_delete": "Patvirtinti trynimą",
+ "delete_now": "Ištrinti dabar",
+ "hibp_check": "Patikrinti naudodami haveibeenpwned.com",
+ "hibp_nok": "Atitikta! Tai yra galimai pavojingas slaptažodis!",
+ "hibp_ok": "Nerasta jokių atitikmenų.",
+ "loading": "Prašome palaukti...",
+ "nothing_selected": "Niekas nepasirinkta",
+ "restart_container": "Paleiskite konteinerį iš naujo",
+ "restart_now": "Perkrauti dabar",
+ "restarting_container": "Perkraunamas konteineris, tai gali užtrukti.",
+ "delete_these_items": "Prašome patvirtinti savo pakeitimus šiam objekto ID",
+ "restart_container_info": "<b>Svarbu:</b> Sklandus paleidimas iš naujo gali užtrukti, prašome palaukti, kol jis baigsis."
+ },
+ "header": {
+ "administration": "Konfigūracija ir detalės",
+ "apps": "Programėlės",
+ "debug": "Informacija",
+ "email": "El. paštas",
+ "mailcow_system": "Sistema",
+ "mailcow_config": "Konfiguracija",
+ "quarantine": "Karantinas",
+ "restart_netfilter": "Paleisti „netfilter“ iš naujo",
+ "restart_sogo": "Paleisti SOGo iš naujo",
+ "user_settings": "Naudotojo Nustatymai"
+ },
+ "info": {
+ "no_action": "Nėra taikomų veiksmų",
+ "session_expires": "Jūsų sesija pasibaigs už maždaug 15 sekundžių.",
+ "awaiting_tfa_confirmation": "Laukiama DFA patvirtinimo"
+ },
+ "login": {
+ "fido2_webauthn": "FIDO2/WebAuthn Prisijungimas",
+ "login": "Prisijungti",
+ "other_logins": "ar prisijungti su",
+ "password": "Slaptažodis",
+ "username": "Naudotojo vardas",
+ "mobileconfig_info": "Prašome prisijungti kaip pašto dėžutės vartotojui, kad galėtumėte atsisiųsti pageidaujamą „Apple“ ryšio profilį."
+ },
+ "mailbox": {
+ "action": "Veiksmas",
+ "activate": "Aktivuoti",
+ "active": "Aktyvus",
+ "add": "Pridėti",
+ "add_alias": "Pridėti pseudonimą",
+ "add_alias_expand": "Išplėsti pseudonimą per pseudonimų domenus",
+ "add_bcc_entry": "Pridėti BCC žemėlapį",
+ "add_domain": "Pridėti domeną",
+ "add_domain_alias": "Pridėti pakaitinį domeną",
+ "add_domain_record_first": "Prašome pridėti domeną pirmiausia",
+ "add_filter": "Pridėti filtrą",
+ "add_mailbox": "Pridėti pašto dėžutę",
+ "add_recipient_map_entry": "Pridėti gavėjų žemėlapį",
+ "add_resource": "Pridėti resursą",
+ "add_template": "Pridėti Šabloną",
+ "add_tls_policy_map": "Pridėti TLS politikos schemą",
+ "address_rewriting": "Adresų perrašymas",
+ "alias": "Slapyvardis",
+ "alias_domain_backupmx": "Pakaitinis domenas nėra aktyvuotas peradresavimo domenui",
+ "all_domains": "Visi Domenai",
+ "allow_from_smtp_info": "Palikite tuščią, norėdami leisti visiems siuntėjams.<br>IPv4/IPv6 adresai ir tinklai.",
+ "backup_mx": "Peradresavimo domenas",
+ "bcc": "BCC",
+ "bcc_destination": "BCC gavimo vieta",
+ "bcc_destinations": "BCC gavimo vieta",
+ "bcc_local_dest": "Vietinė gavimo vieta",
+ "bcc_map": "BCC žemėlapis",
+ "bcc_map_type": "BCC tipas",
+ "bcc_maps": "BCC žemėlapiai",
+ "bcc_type": "BCC tipas",
+ "booking_null": "Visada rodyti kaip laisvą",
+ "booking_0_short": "Visada laisvas",
+ "booking_custom": "Nekintamasis apribojimas pagal individualią užsakymų sumą",
+ "booking_custom_short": "Nekintamasis ribojimas",
+ "booking_ltnull": "Neribotas, bet rodyti kaip užimtas, kai užrezervuota",
+ "booking_lt0_short": "Kintamasis apribojimas",
+ "catch_all": "Viską sugriebiantis",
+ "daily": "Kasdien",
+ "description": "Aprašymas",
+ "disable_login": "Uždrausti prisijungimą (gaunami el. laiškai vis dar priimami)",
+ "disable_x": "Išjungti",
+ "dkim_key_length": "DKIM rakto ilgis (bitai)",
+ "domain": "Domenas",
+ "domain_aliases": "Pakaitomieji domenai",
+ "domain_templates": "Domenų Šablonai",
+ "domain_quota": "Kvota",
+ "domain_quota_total": "Bendroji domeno kvota",
+ "domains": "Domenai",
+ "edit": "Redaguoti",
+ "filters": "Filtrai",
+ "fname": "Pilnas vardas",
+ "gal": "Visuotinis adresų sąrašas",
+ "goto_spam": "Išmokti kaip <b>šlamštas</b>",
+ "hourly": "Kas valandą",
+ "in_use": "Naudojimas (%)",
+ "inactive": "Neaktyvus",
+ "allowed_protocols": "Leidžiami protokolai tiesioginiam vartotojo prieigai (neturi įtakos programėlių slaptažodžių protokolams)",
+ "goto_ham": "Išmokti kaip <b>ham</b>",
+ "aliases": "Pseudonimai",
+ "allow_from_smtp": "Leiskite tik šiems IP naudotis <b>SMTP</b>",
+ "alias_domain_alias_hint": "Pseudonimai <b>nėra</b> taikomi domeno pseudonimams automatiškai. Pseudonimo adresas <code>my-alias@domain</code> <b>neapima</b> adreso <code>my-alias@alias-domain</code> (kur \"alias-domain\" yra įsivaizduojamas \"domain\" pseudonimas).<br>Prašome naudoti sieve filtrą, kad nukreiptumėte laiškus į išorinę pašto dėžutę (žr. skirtuką \"Filtrai\" arba naudokite SOGo -> Peradresavimas). Naudokite \"Išplėsti pseudonimus per pseudonimų sritis\" kad automatiškai pridėti trūkstamus pseudonimus.",
+ "deactivate": "Deaktivuoti",
+ "domain_admins": "Domeno administratoriai",
+ "enable_x": "Įjungti",
+ "last_run_reset": "Suplanuoti kitą",
+ "mailbox": "Pašto dėžutė",
+ "mailbox_defaults": "Numatytieji nustatymai",
+ "mailbox_defaults_info": "Nustatyti numatytuosius nustatymus naujoms pašto dėžutėms.",
+ "mailbox_defquota": "Numatytasis pašto dėžutės dydis",
+ "mailbox_templates": "Pašto dėžučių šablonai",
+ "mailbox_quota": "Maks. pašto dėžutės dydis",
+ "mailboxes": "Pašto dėžutės",
+ "max_aliases": "Maks. slapyvardžiai",
+ "max_mailboxes": "Maks. galimų pašto dėžučių",
+ "max_quota": "Maks. kvota kiekvienai pašto dėžutei",
+ "mins_interval": "Intervalas (min)",
+ "msg_num": "Žinutė #"
+ },
+ "quarantine": {
+ "atts": "Priedaj",
+ "check_hash": "Ieškoti failo Hash'o @ VT",
+ "confirm": "Patvirtinti",
+ "confirm_delete": "Patvirtinti šio elemento trynimą",
+ "danger": "Pavojus"
+ },
+ "success": {
+ "domain_admin_added": "Pridėtas domeno administractorius %s",
+ "domain_admin_removed": "Domeno administratorius %s ištrintas",
+ "domain_modified": "Domeno %s pakitimai išsaugoti",
+ "domain_removed": "Domenas %s ištrintas",
+ "dovecot_restart_success": "„Doveccot“ perkrautas",
+ "domain_added": "Pridėtas domenas %s",
+ "domain_admin_modified": "Pakeitimai domeno adminustratoriui %s išsaugoti"
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.lv-lv.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.lv-lv.json
index 962b900..df16972 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.lv-lv.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.lv-lv.json
@@ -4,7 +4,28 @@
"filters": "Filtri",
"recipient_maps": "Saņēmēja kartes",
"syncjobs": "Sinhronizācijas uzdevumi",
- "spam_score": "Mēstules novērtējums"
+ "spam_score": "Mēstules novērtējums",
+ "alias_domains": "Pievienot aizstājdomēnus",
+ "spam_alias": "Pagaidu aizstājvārdi",
+ "app_passwds": "Lietotņu paroļu pārvaldība",
+ "delimiter_action": "Atdalītāja darbība",
+ "domain_desc": "Mainīt domēna aprakstu",
+ "domain_relayhost": "Mainīt domēna relayhost",
+ "eas_reset": "EAS ierīču atiestatīšana",
+ "extend_sender_acl": "Ļauj paplašināt sūtītāja ACL ar ārējām adresēm",
+ "login_as": "Pieteikties kā pastkastes lietotājam",
+ "mailbox_relayhost": "Pasta kastītes relayhost maiņa",
+ "prohibited": "Aizliegts ar ACL",
+ "protocol_access": "Protokola piekļuves maiņa",
+ "pw_reset": "Ļaut atiestatīt mailcow lietotāja paroli",
+ "ratelimit": "Piekļuves biežuma ierobežojums",
+ "quarantine": "Karantīnas darbības",
+ "quarantine_attachments": "Karantīnas pielikumi",
+ "quarantine_category": "Mainīt karantīnas paziņojumu kategoriju",
+ "quarantine_notification": "Mainīt karantīnas paziņojumus",
+ "smtp_ip_access": "Mainīt SMTP atļautos saimniekdatorus",
+ "sogo_access": "Atļaut SOGo piekļuves pārvaldību",
+ "sogo_profile_reset": "Atiestatīt SOGo profilu"
},
"add": {
"activate_filter_warn": "Visi pārējie filtri tiks deaktivizēti, kad aktīvs ir atzīmēts.",
@@ -12,51 +33,57 @@
"add": "Pievienot",
"add_domain_only": "Tikai pievienot domēnu",
"add_domain_restart": "Pievienot domēnu un restartēt SOGo",
- "alias_address": "Alias addrese/s",
- "alias_address_info": "<small>Pilna epasta addrese/s vai @piemērs.com, lai notvertu visas domēna ziņas (komatu atdalītas). <b>tikai mailcow domēni</b>.</small>",
- "alias_domain": "Alias domēni",
+ "alias_address": "Aizstājadrese/s",
+ "alias_address_info": "<small>Pilna epasta adrese/s vai @example.com, lai notvertu visus domēna ziņojumus (atdalītas ar komatu). <b>Tikai mailcow domēni</b>.</small>",
+ "alias_domain": "Aizstājdomēni",
"alias_domain_info": "<small>Tikai derīgi domēna vārdi (komatu atdalīti).</small>",
"automap": "Mēģiniet automatizēt mapes (\"Nosūtītie vienumi\", \"Nosūtītie\" => \"Nosūtītie\" etc.)",
- "backup_mx_options": "Dublējuma MX iespējas",
- "delete1": "Dzēst no avota, kad tas ir pabeigts",
+ "backup_mx_options": "Releja iespējas",
+ "delete1": "Izdzēst no avota pēc pabeigšanas",
"delete2": "Dzēsiet ziņojumus galamērķī, kas nav avotā",
- "delete2duplicates": "Dzēst dublikātus galamērķī",
+ "delete2duplicates": "Izdzēst atkārtojošos vienumus galamērķī",
"description": "Apraksts",
"domain": "Domēns",
- "domain_quota_m": "Kopējā domēna kvota (MiB)",
+ "domain_quota_m": "Kopējā domēna kvota (MiB)",
"enc_method": "Šifrēšanas metode",
"exclude": "Izslēgt objektus (regex)",
"full_name": "Pilns vārds",
- "goto_null": "Klusām dzēst pastu",
- "hostname": "Hosta nosaukums",
+ "goto_null": "Klusām atmest pastu",
+ "hostname": "Saimniekdators",
"kind": "Veids",
"mailbox_quota_m": "Maks. kvota pastkastei (MiB)",
"mailbox_username": "Lietotājvārds (kriesā daļa no epasta adreses)",
- "max_aliases": "Maks. iespejamās aliases",
+ "max_aliases": "Lielākais pieļaujamo aizstājvārdu skaits",
"max_mailboxes": "Maks. iespējamās pastkastes",
"mins_interval": "Aptauajs intervāls (minūtes)",
"multiple_bookings": "Vairākas rezervācijas",
"password": "Parole",
"password_repeat": "Apstiprinājuma parole (atkārtot)",
"port": "Ports",
- "post_domain_add": "Jums būs nepieciešams atsāknēt SOGo servisa konteineru pēc jauna domēna pievienošanas!",
+ "post_domain_add": "SOGO konteineru \"sogo-mailcow\" ir nepieciešams pārsāknēt pēc jauna domēna pievienošanas.<br><br>Papildus vajadzētu pārskatīt domēnu DNS konfigurāciju. Tiklīdz DNS konfigurācija ir apstiprināta, jāpārsāknē \"acme-mailcow\", lai automātiski izveidotu sertifikātus jaunajam domēnam (autoconfig.<domain>, autodiscover.<domain>).<br>Šis solis ir izvēles un tiks atkārtots ik pēc 24 stundām.",
"quota_mb": "Kvota (MiB)",
"relay_all": "Pārsūtīt visus saņēmējus",
- "relay_all_info": "<small>Ja izvēlies <b>nepārsūtīt</b> visus saņēmējus, tad Tev būs nepieciešams pievienot (\"tukšu\") pastkasti katram saņēmējam, kas būtu jāpārsūta.</small>",
+ "relay_all_info": "↪ Ja izvēlies <b>nepārsūtīt</b> visus saņēmējus, tad Tev būs nepieciešams pievienot (\"aklo\") pastkasti katram saņēmējam, kas būtu jāpārsūta.",
"relay_domain": "Pārsūtīt šo domēnu",
- "select": "Lūdzu izvēlaties...",
- "select_domain": "Lūdzu sākumā izvēlaties domēnu",
+ "select": "Lūgums atlasīt…",
+ "select_domain": "Lūgums vispirms atlasīt domēnu",
"sieve_desc": "Īss apraksts",
"sieve_type": "Filtra tips",
"skipcrossduplicates": "Izlaist dublētus ziņojumus pa mapēm (pirmais nāk, pirmais kalpo)",
"syncjob": "Pievienot sinhronizācijas darbu",
"syncjob_hint": "Ņemiet vērā, ka parole ir jāuzglabā vienkāršā tekstā!",
- "target_address": "Iet uz adresēm",
- "target_address_info": "<small>Pilna epasta addrese/s (comma-separated).</small>",
+ "target_address": "Mērķa adreses",
+ "target_address_info": "<small>Pilna epasta adrese/s (atdalītas ar komatu).</small>",
"target_domain": "Mērķa domēns",
"username": "Lietotājvārds",
"validate": "Apstiprināt",
- "validation_success": "Apstiprināts veiksmīgi"
+ "validation_success": "Sekmīgi apstiprināts",
+ "bcc_dest_format": "BCC galamērķim ir jābūt vienai derīgai e-pasta adresei.<br>Ja ir nepieciešams nosūtīt kopiju vairākām adresēm, jāizveido aizstājvārds un jāizmanto tas šeit.",
+ "domain_matches_hostname": "Domēns %s atbilst saimniekdatora nosaukumam",
+ "disable_login": "Neļaut pieteikšanos (ienākošais pasts joprojām tiks pieņemts)",
+ "app_password": "Pievienot lietotnes paroli",
+ "app_passwd_protocols": "Atļautie lietotnes paroles protokoli",
+ "goto_spam": "Apgūt kā <span class=\"text-danger\"><b>mēstuli</b></span>"
},
"admin": {
"access": "Pieeja",
@@ -64,12 +91,12 @@
"activate_api": "Aktivizēt API",
"active": "Aktīvs",
"add": "Pievienot",
- "add_domain_admin": "Pievienot domēna administratoru",
+ "add_domain_admin": "Pievienot domēna pārvaldītāju",
"add_forwarding_host": "Pievienot pāradresācijas hostu",
"add_relayhost": "Pievienot Relayhost",
"add_row": "Pievienot rindu",
- "admin": "Administrators",
- "admin_details": "Labot administratora detaļas",
+ "admin": "Pārvaldītājs",
+ "admin_details": "Labot informāciju par pārvaldītāju",
"admin_domains": "Domēna uzdevumi",
"api_allow_from": "Atļaut API piekļuvi no šīm IP",
"api_key": "API atslēga",
@@ -87,21 +114,21 @@
"dkim_keys": "ARC/DKIM atslēgas",
"dkim_private_key": "Privāta atslēga",
"domain": "Domēns",
- "domain_admins": "Domēna administratori",
+ "domain_admins": "Domēna pārvaldītāji",
"edit": "Labot",
- "empty": "Nav rezultātu",
+ "empty": "Nav iznākuma",
"f2b_ban_time": "Aizlieguma laiks (s)",
"f2b_max_attempts": "Maks. piegājieni",
"f2b_netban_ipv4": "IPv4 apakštīkla izmērs, lai piemērotu aizliegumu uz (8-32)",
- "f2b_netban_ipv6": "IPv6 apakštīkla izmērs, lai piemērotu aizliegumu uz (8-128)",
+ "f2b_netban_ipv6": "IPv6 apakštīkla izmērs, lai piemērotu aizliegumu uz (8-128)",
"f2b_parameters": "Fail2ban parametri",
"f2b_retry_window": "Atkārtošanas logs (s) priekš maks. piegājiena",
- "f2b_whitelist": "Baltā saraksta tīkls/hosts",
+ "f2b_whitelist": "Atļautie tīkli/resursdatori",
"filter_table": "Filtru tabula",
"forwarding_hosts": "Hostu pārsūtīšana",
- "forwarding_hosts_add_hint": "Jūs varat norādīt IPv4/IPv6 addreses, tīklu iekš CIDR apzīmējuma, hosta nosaukumu (kas tiks atrisinātas IP adresēs), vai domēna vārdos (kas tiks atrisināts IP adresēs vaicājot SPF ierakstus vai, ja tādu nav, MX ierakstus).",
- "forwarding_hosts_hint": "Ienākošie ziņojumi ir bez nosacījumiem pieņemti no visiem šeit norādītajiem hostiem. Pēc tam šie hosti netiek pārbaudīti pret DNSBL vai pakļauti Greylistei. No tiem saņemtās mēstules nekad netiek noraidītas, bet pēc izvēles tās var pārvietot mapē Nevēlamais. Visbiežāk to izmanto, lai precizētu pasta serverus, kuros ir iestatīts noteikums, kas pārsūta ienākošos e-pasta ziņojumus uz jūsu mailcow serveri.",
- "help_text": "Ignorēt palīdzības tekstu zem pieteikšanās maskas (HTML ir atļauta)",
+ "forwarding_hosts_add_hint": "Var norādīt vai nu IPv4/IPv6 adreses, tīklu ar CIDR apzīmējumu, saimniekdatoru nosaukumus (kas tiks atrisināti IP adresēs) vai arī domēna vārdus (kas tiks atrisināti IP adresēs, vaicājot SPF ierakstus, vai, ja tādu nav, MX ierakstus).",
+ "forwarding_hosts_hint": "Ienākošie ziņojumi tiek bez nosacījumiem pieņemti no visiem šeit norādītajiem saimniekdatoriem. Tie tad netiek pārbaudīti pret DNSBL vai pakļauti ievietošanai pelēkajā sarakstā. No tiem saņemtās mēstules nekad netiek noraidītas, bet pēc izvēles tās var pārvietot mapē \"Nevēlams\". Visbiežāk to izmanto, lai norādītu pasta serverus, kuros ir uzstādīts nosacījums, kas pārsūta ienākošās e-pasta vēstules uz Tavu mailcow serveri.",
+ "help_text": "Pārrakstīt palīdzības tekstu zem pieteikšanās maskas (var izmantot HTML)",
"host": "Hosts",
"import": "Importēt",
"import_private_key": "Importēt privātu atslēgu",
@@ -109,7 +136,7 @@
"inactive": "Neaktīvs",
"link": "Saite",
"loading": "Lūgums uzgaidīt...",
- "logo_info": "Jūsu attēls augšējā navigācijas joslā tiks palielināts līdz 40 pikseļiem un maks. sākumlapas platums par 250 pikseļi. Ir ļoti ieteicama pielāgojama grafikaYour image will be scaled to a height of 40px for the top navigation bar and a max. width of 250px for the start page. Ir ļoti ieteicama pielāgojamā grafika",
+ "logo_info": "Tavs attēls augšējā pārvietošanās joslā tiks mērogots līdz 40 pikseļiem un ne vairāk par 250 pikseļiem platumā sākumlapā. Ļoti ieteicams izmantot mērogojamus attēlus.",
"main_name": "\"mailcow UI\" nosaukums",
"merged_vars_hint": "Pelēkās rindas tika apvienotas <code>vars.(local.)inc.php</code> un nevar tikt modificētas.",
"no_new_rows": "Papildu rindas nav pieejamas",
@@ -118,18 +145,18 @@
"password_repeat": "Apstiprināt paroli (atkārtot)",
"private_key": "Privāta atslēga",
"quarantine": "Karantīna",
- "quarantine_exclude_domains": "Izslēgt domēnus un alias-domēnus:",
- "quarantine_max_size": "Maks. izmērs MiB (lielāki vienumi ir atbrīvoti):",
- "quarantine_retention_size": "Atlikumi pastkastēs:",
+ "quarantine_exclude_domains": "Neņemt vērā domēnus un aizstājdomēnus",
+ "quarantine_max_size": "Lielākais pieļaujamais izmērs MiB (lielāki vienumi tiek atmesti):<br><small>0 <b>nenorāda</b> neierobežotu.</small>",
+ "quarantine_retention_size": "Paturējumi katrā pastkastē:<br><small>0 norāda, ka ir <b>atspējoti</b>.</small>",
"r_active": "Aktīvie ierobežojumi",
"r_inactive": "Neaktīvie ierobežojumi",
- "r_info": " Pelēki/atslēgti elementi aktīvo ierobežojumu sarakstā nav zināmi kā mailcow spēkā esoši ierobežojumi un tos nevar pārvietot. Jebkurā gadījumā nezināmi ierobežojumi tiks sakārtoti pēc pievienošanas. <br>Jūs varat pievienot jaunus elementus <code>inc/vars.local.inc.php</code>, lai varētu tos pārslēgt.",
+ "r_info": "Pelēkie/atspējotie vienumi spēkā esošo ierobežojumu sarakstā mailcow nav zināmi kā derīgi ierobežojumi, un tos nevar pārvietot. Nezināmi ierobežojumi jebkurā gadījumā parādīšanas secībā. <br>Jaunus vienumus var pievienot <code>inc/vars.local.inc.php</code>, lai varētu tos pārslēgt.",
"recipients": "Adresāts",
"refresh": "Atsvaidzināt",
- "regen_api_key": "Reģenerēt API atslēgu",
- "relay_from": "\"No:\" addrese",
+ "regen_api_key": "Atkārtoti izveidot API atslēgu",
+ "relay_from": "\"No:\" adrese",
"relay_run": "Palaist testu",
- "relayhosts_hint": "Definējiet relejhostus šeit, lai tos varētu izvēlēties domēna konfigurācijas logā.",
+ "relayhosts_hint": "Norādīt no sūtītāja atkarīgas piegādes, lai varētu tos atlasīt domēnu konfigurācijas uzvednē.<br>\n Piegādes pakalpojums vienmēr ir \"smtp\", tādējādi tiks mēģināts TLS, kad piedāvāts. Iekļautais TLS (SMTPS) netiek atbalstīts. Tiek ņemts vērā lietotāja atsevišķais izejošā TLS nosacījuma iestatījums.<br>\n Ietekmē atlasītos domēnus, tajā skaitā aizstājdomēnus.",
"remove": "Noņemt",
"remove_row": "Noņemt rindu",
"reset_default": "Atiestatīt uz noklusējumu",
@@ -148,16 +175,36 @@
"username": "Lietotājvārds",
"generate": "izveidot",
"message": "Ziņojums",
- "last_applied": "Pēdējoreiz pielietots"
+ "last_applied": "Pēdējoreiz pielietots",
+ "f2b_regex_info": "Vērā ņemtie žurnāli: SOGO, Postfix, Dovecot, PHP-FPM.",
+ "sys_mails": "Sistēmas pasts",
+ "ip_check_disabled": "IP pārbaude ir atspējota. To var iespējot<br><strong>Sistēma > Konfigurācija > iespējas > Pielāgot</strong>",
+ "rspamd_com_settings": "Iestatījuma nosaukums tiks izveidots automātiski. Lūgums zemāk skatīt priekšiestatījumu piemērus. Vairāk informācijas ir <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd dokumentācijā</a>",
+ "reset_password_vars": "<code>{{link}}</code> Izveidotā paroles atiestatīšanas saite<br><code>{{username}}</code> Lietotāja, kurš pieprasīja paroles atiestatīšanu, pastkastes nosaukums<br><code>{{username2}}</code> Atkopšanas pastkastes nosaukums<br><code>{{date}}</code> Paroles atiestatīšanas pieprasījuma veikšanas datums<br><code>{{token_lifetime}}</code> Pilnvaras derīgums minūtēs<br><code>{{hostname}}</code> mailcow saimniekdatora nosaukums",
+ "ui_header_announcement_help": "Paziņojums ir redzams visiem lietotājiem, kuri ir pieteikušies, un pieteikšanās ekrānā saskarnē.",
+ "login_time": "Pieteikšanās laiks",
+ "iam_version": "Versija",
+ "quarantine_max_age": "Lielākais pieļaujamais vecums dienās<br><small>Vērtībai jābūt vienādai ar vai lielākai par 1 dienu.</small>",
+ "quarantine_max_score": "Atmest paziņojumu, ja e-pasta ziņojuma mēstuļu novērtējums ir augstāks par šo vērtību:<br><small>Noklusējums ir 9999.0</small>",
+ "options": "Iespējas",
+ "password_reset_settings": "Paroļu atkopes iestatījumi",
+ "password_settings": "Paroļu iestatījumi",
+ "add_admin": "Pievienot pārvaldītāju",
+ "admins": "Pārvaldītāji",
+ "admins_ldap": "LDAP pārvaldītāji",
+ "admin_quicklink": "Paslēpt ātro saiti uz pārvaldītāju pieteikšanās lapu",
+ "domain_admin": "Domēna pārvaldītājs",
+ "domainadmin_quicklink": "Paslēpt ātro saiti uz domēna pārvaldītāju pieteikšanās lapu",
+ "user_quicklink": "Paslēpt ātro saiti uz lietotāju pieteikšanās lapu"
},
"danger": {
"access_denied": "Piekļuve liegta, vai nepareizi dati",
- "alias_domain_invalid": "Alias domēns ir nepareizs",
- "alias_empty": "Alias adrese nevar būt tukša",
- "alias_goto_identical": "Alias un domēnvārds nevar būt identisks",
- "alias_invalid": "Alias adrese nepareiza",
- "aliasd_targetd_identical": "Alias domēns nevar būt vienāds ar mērķa domēnu",
- "aliases_in_use": "Maks. aliases jabūt lielākām vai vienādām ar %d",
+ "alias_domain_invalid": "Aizstājdomēns %s ir nederīgs",
+ "alias_empty": "Aizstājadrese nedrīkst būt tukša",
+ "alias_goto_identical": "Aizstājvārds un mērķa adrese nedrīkst būt vienādi",
+ "alias_invalid": "Aizstājadrese %s ir nederīga",
+ "aliasd_targetd_identical": "Aizstājdomēns nedrīkst būt vienāds ar mērķa domēnu: %s",
+ "aliases_in_use": "Pieļaujamajam aizstājvārdu skaitam jābūt lielākam vai vienādam ar %d",
"description_invalid": "Resursa apraksts ir nederīgs",
"dkim_domain_or_sel_invalid": "DKIM domēns vai selektors nepareizs",
"domain_exists": "Domēns %s jau pastāv",
@@ -165,23 +212,23 @@
"domain_not_empty": "Nevar noņemt neaizpildītu domēnu",
"domain_not_found": "Domēns %s nav atrasts",
"domain_quota_m_in_use": "Domēna kvotai jābūt lielākai vai vienādai ar %s MiB",
- "goto_empty": "Goto adrese nevar būt tukša",
+ "goto_empty": "Aizstājādresei jāsatur vismaz viena derīga mērķa adrese",
"goto_invalid": "Goto adrese nepareiza",
"imagick_exception": "Kļūda: Imagick izņēmums, lasot attēlu",
- "img_invalid": "Nevar apstiprināt attēla failu",
- "img_tmp_missing": "Nevar apstiprināt attēla failu: pagaidu failu nav atrasts",
+ "img_invalid": "Nevar apstiprināt attēla datni",
+ "img_tmp_missing": "Nevar apstiprināt attēla datni: pagaidu datne nav atrasta",
"invalid_mime_type": "Nederīgs mime tips",
- "is_alias": "%s jau ir zināms alias",
- "is_alias_or_mailbox": "%s jau ir zināms alias, pastkastes vai alias addrese izvērsta no alias domēna.",
- "is_spam_alias": "%s ir jau zināms spam alias",
+ "is_alias": "%s jau ir zināma kā aizstājadrese",
+ "is_alias_or_mailbox": "%s jau ir zināms kā aizstājvārds, pastkaste vai aizstājadrese, kas ir izvērsta no aizstājdomēna.",
+ "is_spam_alias": "%s jau ir zināma kā pagaidu aizstājadrese (mēstuļu aizstājadrese)",
"last_key": "Pēdējo atslēgu nevar izdzēst, tā vietā jāatspējo divpakāpju pārbaude.",
- "login_failed": "Ielogošanās neveiksmīga",
+ "login_failed": "Pieteikšanās neizdevās",
"mailbox_invalid": "Pastkastes vārds ir nederīgs",
"mailbox_quota_exceeded": "Kvota pārsniedz domēna limitu (max. %d MiB)",
"mailbox_quota_exceeds_domain_quota": "Pastkastes izmērs pārsniedz maksimāli pieļaujamo",
"mailbox_quota_left_exceeded": "Nav pietiekami daudz vietas (atlikusī vieta: %d MiB)",
"mailboxes_in_use": "Maks. pastkastēm jābūt lielākām vai vienādām ar %d",
- "max_alias_exceeded": "Visas aliases izmantotas",
+ "max_alias_exceeded": "Pārsniegts pieļaujamo aizstājvārdu skaits",
"max_mailbox_exceeded": "Maksimālais pastkastšu skaits sasniegts (%d of %d)",
"max_quota_in_use": "Pastkastes kvotai jābūt lielākai vai vienādai %d MiB",
"maxquota_empty": "Maksimālais pieļaujamais izmērs nevar būt 0.",
@@ -199,10 +246,18 @@
"target_domain_invalid": "Goto domēns ir nepareizs",
"targetd_not_found": "Mērķa domēns nav atrasts",
"username_invalid": "Lietotājvārds nevar tikt izmantots",
- "validity_missing": "Lūdzu piešķiriet derīguma termiņu"
+ "validity_missing": "Lūdzu piešķiriet derīguma termiņu",
+ "domain_cannot_match_hostname": "Domēns nevar atbilst saimniekdatora nosaukumam",
+ "app_passwd_id_invalid": "Lietotnes paroles Id %s ir nederīgs",
+ "img_dimensions_exceeded": "Attēls pārsniedz lielāko pieļaujamo attēla lielumu",
+ "img_size_exceeded": "Attēls pārsniedz lielāko pieļaujamo datnes lielumu",
+ "version_invalid": "Versija %s ir nederīga",
+ "generic_server_error": "Atgadījās neparedzēta servera kļūda. Lūgums sazināties ar pārvaldītāju.",
+ "password_reset_na": "Paroļu atkope šobrīd nav pieejama. Lūgums sazināties ar pārvaldītāju.",
+ "recovery_email_failed": "Nevarēja nosūtīt atkopes e-pasta ziņojumu. Lūgums sazināties ar pārvaldītāju."
},
"diagnostics": {
- "cname_from_a": "Vērtība, kas iegūta no A/AAAA ieraksta. Tas tiek atbalstīts tik ilgi, kamēr ieraksts norāda pareizo resursu.",
+ "cname_from_a": "Vērtība, kas iegūta no A/AAAA ieraksta. Tas tiek atbalstīts tik ilgi, kamēr ieraksts norāda uz pareizo resursu.",
"dns_records": "DNS Ieraksti",
"dns_records_24hours": "Lūdzu ņemiet vērā, ka DNS izmaiņas var aizņemt laiku līdz 24 stundām, lai pareizi varētu atspoguļot izmaiņas šajā lapā. Tas ir paredzēts, lai jūs varētu viegli uzzināt, kā konfigurēt savus DNS ierakstus un pārbaudīt, vai visi jūsu ieraksti ir pareizi saglabāti DNS.",
"dns_records_data": "Pareizi dati",
@@ -213,32 +268,32 @@
},
"edit": {
"active": "Aktīvs",
- "alias": "Rediģēt alias",
+ "alias": "Labot aizstājvārdu",
"automap": "Mēģiniet automatizēt mapes (\"Nosūtītie vienumi\", \"Nosūtītie\" => \"Nosūtītie\" utt.)",
- "backup_mx_options": "Dublēt MX iespējas",
- "delete1": "Dzēst no avota, kad pabeigts",
+ "backup_mx_options": "Retranslācijas iespējams",
+ "delete1": "Izdzēst no avota pēc pabeigšanas",
"delete2": "Dzēsiet ziņojumus galamērķī, kas nav avotā",
- "delete2duplicates": "Dzēst dublikātus galamērķī",
+ "delete2duplicates": "Izdzēst atkārtojošos vienumus galamērķī",
"description": "Apraksts",
"domain": "Labot domēnu",
- "domain_admin": "Labot domēna administratoru",
+ "domain_admin": "Labot domēna pārvaldītāju",
"domain_quota": "Domēna kvota",
"domains": "Domēni",
- "dont_check_sender_acl": "Atspējot domēna sūtītāju pārbaudi %s + alias domēni",
- "edit_alias_domain": "Rediģēt alias domēnu",
+ "dont_check_sender_acl": "Atspējot sūtītāju pārbaudi domēnam %s (+ aizstājdomēni)",
+ "edit_alias_domain": "Labot aizstājdomēnu",
"encryption": "Šifrēšana",
"exclude": "Neiekļaut objektus (regex)",
- "force_pw_update": "Piespiedu paroles atjaunošana pie nākošās pieslēgšanās",
- "force_pw_update_info": "Šis lietotājs varēs pieslēgties tikai %s.",
+ "force_pw_update": "Piespiedu paroles atjaunošana nākamajā pieteikšanās reizē",
+ "force_pw_update_info": "Šis lietotājs varēs pieteikties tikai %s. Lietotņu paroles joprojām būs izmantojamas.",
"full_name": "Pilns vārds",
- "hostname": "Hosta nosaukums",
+ "hostname": "Saimniekdatora nosaukums",
"inactive": "Neaktīvs",
"kind": "Veids",
- "mailbox": "Rediģēt pastkasti",
- "max_aliases": "Maks. aliases",
+ "mailbox": "Labot pastkasti",
+ "max_aliases": "Lielākais aizstājvārdu skaits",
"max_mailboxes": "Maks. iespējamās pastkastes",
"max_quota": "Maks. kvota uz pastkasti (MiB)",
- "maxage": "Maximum age of messages in days that will be polled from remote<br><small>(0 = ignore age)</small>",
+ "maxage": "Lielākais pieļaujamais ziņojumu, kuri tiks vaicāti attālajā serverī, vecums dienās<br><small>(0 = neņemt vērā vecumu)</small>",
"maxbytespersecond": "Maks. baiti sekundē (0 ir vienāds ar neierobežotu skaitu)",
"mins_interval": "Intervāls (min)",
"multiple_bookings": "Vairāki rezervējumi",
@@ -247,7 +302,7 @@
"previous": "Iepriekšējā lapa",
"quota_mb": "Kvota (MiB)",
"relay_all": "Pārsūtīt visus adresātus",
- "relay_all_info": "<small>Ja tu izvēlies <b>nepārsūtīt</b> visus adresātus, tad tev vajadzēs pievienot (\"tukšu\") pastkasti katram saņēmējam, kas būtu jāpārsūta.</small>",
+ "relay_all_info": "↪ Ja izvēlies <b>nepārsūtīt</b> visus adresātus, tad tev vajadzēs pievienot (\"aklo\") pastkasti katram saņēmējam, kas būtu jāpārsūta.",
"relay_domain": "Pārsūtīt domēnu",
"remove": "Noņemt",
"resource": "Resurss",
@@ -256,68 +311,98 @@
"sieve_desc": "Īss apraksts",
"sieve_type": "Filtra tips",
"skipcrossduplicates": "Izlaist dublētus ziņojumus pa mapēm (pirmais nāk, pirmais kalpo)",
- "spam_alias": "Izveidot vai mainīt laika ierobežotas alias adreses",
- "spam_policy": "Pievienot vai noņemt vienības baltajā-/melnajā sarakstā",
- "spam_score": "Iestatīt pielāgotu surogātpastu",
+ "spam_alias": "Izveidot vai mainīt laika ierobežotas aizstājadreses",
+ "spam_policy": "Pievienot vai noņemt vienumus atļautajā/liegumu sarakstā",
+ "spam_score": "Iestatīt pielāgotu mēstules vērtējumu",
"subfolder2": "Sinhronizēt galamērķa apakšmapē<br><small>(tukšs = neizmantot apakšmapi)</small>",
- "syncjob": "Rediģēt sinhronizācijas darbu",
- "target_address": "Iet uz adresi/ēm <small>(komatu atdalītas)</small>",
+ "syncjob": "Labot sinhronizācijas darbu",
+ "target_address": "Mērķa adrese/s <small>(atdalītas ar komatu)</small>",
"target_domain": "Mērķa domēns",
"title": "Labot priekšmetu",
"unchanged_if_empty": "Ja neizmainīts atstājiet tukšu",
"username": "Lietotājvārds",
"validate_save": "Apstiprināt un saglabāt",
- "last_modified": "Pēdējoreiz mainīts"
+ "last_modified": "Pēdējoreiz mainīts",
+ "domain_footer_skip_replies": "Neņemt vērā kājeni atbildes e-pastos",
+ "bcc_dest_format": "BCC galamērķim jābūt vienai derīgai e-pasta adresei.<br>Ja ir nepieciešams nosūtīt kopiju uz vairākām adresēm, jāizveido aizstājvārds, un tas ir jāizmanto šeit.",
+ "extended_sender_acl_info": "Vajadzētu ievietot DKIM domēna atslēgu, ja tā ir pieejama.<br>\n Jāatceras pievienot šo serveri attiecīgajam SPF TXT ierakstam.<br>\n Kad vien šim serverim tiek pievienots domēns vai aizstājdomēns, kas pārklājas ar ārēju adresi, ārējā adrese tiek noņemta.<br>\n Jāizmanto @domain.tld, lai ļautu nosūtīt kā *@domain.tld.",
+ "pushover_info": "Pašpiegādes paziņojumu iestatījumi tiks piemēroti visiem tīrajiem (ne surogātpasta) sūtījumiem, kas piegādāti <b>%s</b>, tostarp aizstājvārdiem (kopīgotiem, nekopīgotiem, ar birkām).",
+ "mailbox_relayhost_info": "Tiek piemērots tikai pastkastei un tiešajiem aizstājvārdiem, aizstāj domēna retranslācijas saimniekdatoru.",
+ "sender_acl_info": "Ja pastkastes lietotājam A ir ļauts sūtīt kā pastkastes lietotājam B, sūtītāja adrese SOGo netiek automātiski parādīta kā atlasāms lauks \"no\".<br>.\n Pastkastes lietotājam B SOGo ir jāizveido pilnvarojums, lai pastkastes lietotājs A varētu izvēlēties tā adresi kā sūtītāja. Lai SOGo pilnvarotu pastkasti, pasta skatā jāizmanto izvēlne (trīs punkti) pa labi no pastkastes nosaukuma augšējā kreisajā pusē. Šī darbība neattiecas uz aizstājadresēm.",
+ "sogo_visible": "Aizstājvārds ir redzams SOGo",
+ "sogo_visible_info": "Šī iespēja ietekmē tikai tos objektus, kurus var parādīt SOGo (koplietojamās vai nekoplietojamās aizstājadreses, kas norāda uz vismaz vienu vietējo pastkasti). Ja paslēpts, netiks parādīts SOGo kā atlasāms sūtītājs.",
+ "mbox_rl_info": "Šis pieprasījumu ierobežojums tiek piemērots SASL pieteikšanās vārdam, tas atbilst jebkurai \"from\" adresei, ko izmanto lietotājs, kurš ir pieteicies. Pastkastes pieprasījumu ierobežojums pārraksta domēna mēroga pieprasījumu ierobežojumu.",
+ "sogo_access": "Tieša pārvirzīšana uz SOGo",
+ "disable_login": "Neļaut pieteikšanos (ienākošais pasts joprojām tiks pieņemts)",
+ "app_passwd_protocols": "Atļautie lietotnes paroles protokoli",
+ "allowed_protocols": "Atļautie protokoli tiešai lietotāja piekļuvei (neietekmē lietotnes paroles protokolus)",
+ "app_passwd": "Lietotnes parole",
+ "mta_sts_version": "Versija",
+ "mta_sts_version_info": "Norāda MTA-STS standarta versiju – pašreiz ir derīga tikai <code>STSv1</code>.",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Sūtītāja pārbaude ir atspējota</span>",
+ "admin": "Labot pārvaldītāju"
},
"footer": {
"cancel": "Atcelt",
- "confirm_delete": "Apstiprināt dzēšanu",
- "delete_now": "Dzēst tagad",
- "delete_these_items": "Lūdzu apstipriniet darbīku šiem abjektiem:",
- "loading": "Lūdzu uzgaidiet...",
+ "confirm_delete": "Apstiprināt izdzēšanu",
+ "delete_now": "Izdzēst tagad",
+ "delete_these_items": "Lūgums apstiprināt izmaiņas šim objekta Id",
+ "loading": "Lūgums uzgaidīt...",
"restart_container": "Restartēt konteineri",
- "restart_container_info": "<b>Important:</b> Piespiedu restartēšana var aizņemt ilgu laiku, lūdzu uzgaidiet.",
- "restart_now": "Restartēt "
+ "restart_container_info": "<b>Svarīgi:</b> nesteidzīga pārsāknēšana var aizņemt ilgāku laiku. Lūgums uzgaidīt, līdz tā tiek pabeigta.",
+ "restart_now": "Pārsāknēt tagad",
+ "hibp_nok": "Sakrīt. Šī, iespējams, ir bīstama parole."
},
"header": {
- "administration": "Administrēšana",
- "debug": "Atkļūdošana",
- "email": "E-Mail",
- "mailcow_config": "Configurācija",
+ "administration": "Konfigurācija un informācija",
+ "debug": "Informācija",
+ "email": "E-pasts",
+ "mailcow_config": "Konfigurācija",
"quarantine": "Karantīna",
"restart_sogo": "Restartēt SOGo",
- "user_settings": "Lietotāja uzstādījumi"
+ "user_settings": "Lietotāja uzstādījumi",
+ "mailcow_system": "Sistēma"
},
"info": {
"no_action": "No action applicable"
},
"login": {
- "delayed": "Pieslēgšanās aizkavējās par %s sekundēm.",
- "login": "Pieslēgties",
+ "delayed": "Pieteikšanās tika aizkavēta %s sekundes.",
+ "login": "Pieteikties",
"password": "Parole",
- "username": "Lietotājvārds"
+ "username": "Lietotājvārds",
+ "fido2_webauthn": "FIDO/WebAuthn pieteikšanās",
+ "mobileconfig_info": "Lūgums pieteikties kā pastkastes lietotājam, lai lejupielādētu pieprasīto Apple savienojuma profilu.",
+ "other_logins": "vai pieteikties ar",
+ "forgot_password": "> Aizmirsta parole?",
+ "login_linkstext": "Nepareiza pieteikšanās?",
+ "login_domainadmintext": "Pieteikties kā domēna pārvaldītājam",
+ "login_admintext": "Pieteikties kā pārvaldītājam",
+ "login_user": "Lietotu pieteikšanās",
+ "login_dadmin": "Domēna pārvaldītāju pieteikšanās",
+ "login_admin": "Pārvaldītāju pieteikšanās"
},
"mailbox": {
"action": "Rīcība",
- "activate": "Activate",
+ "activate": "Aktivizēt",
"active": "Aktīvs",
"add": "Pievienot",
- "add_alias": "Pievienot alias",
+ "add_alias": "Pievienot aizstājvārdu",
"add_bcc_entry": "Pievienot BCC karti",
"add_domain": "Pievienot domēnu",
- "add_domain_alias": "Pievienot domēna alias",
+ "add_domain_alias": "Pievienot domēna aizstājvārdu",
"add_filter": "Pievienot filtru",
"add_mailbox": "Pievienot pastkasti",
"add_recipient_map_entry": "Pievienot saņēmēja karti",
"add_resource": "Pievienot resursu",
"address_rewriting": "Adreses pārrakstīšana",
- "alias": "Alias",
- "aliases": "Aliases",
+ "alias": "Aizstājvārds",
+ "aliases": "Aizstājvārdi",
"backup_mx": "Rezerves kopija MX",
"bcc": "BCC",
"bcc_destination": "BCC galamērķi/s",
"bcc_destinations": "BCC galamērķi/s",
- "bcc_info": "BCC kartes tiek izmantotas, lai klusu pārsūtītu visu ziņojumu kopijas uz citu adresi. Saņēmēja kartes tipa ieraksts tiek izmantots, kad vietējais galamērķis darbojas kā pasta adresāts. Sūtītāja kartes atbilst vienam un tam pašam principam. <br/>\r\n Vietējais galamērķis netiks informēts par piegādes neveiksmi. ",
+ "bcc_info": "BCC kartes tiek izmantotas, lai klusi pārsūtītu visu ziņojumu kopijas uz citu adresi. Saņēmēja kartes veida ieraksts tiek izmantots, kad vietējais galamērķis darbojas kā pasta saņēmējs. Sūtītāja kartes atbilst vienam un tam pašam principam.<br/>\n Vietējais galamērķis netiks informēts par neizdevušos piegādi.",
"bcc_local_dest": "Vietējais galamērķis",
"bcc_map_type": "BCC veids",
"bcc_maps": "BCC kartes",
@@ -330,18 +415,18 @@
"description": "Apraksts",
"dkim_key_length": "DKIM atslēgas garums (bits)",
"domain": "Domēns",
- "domain_admins": "Domēna administratori",
- "domain_aliases": "Domēna aliases",
+ "domain_admins": "Domēna pārvaldītāji",
+ "domain_aliases": "Domēna aizstājvārdi",
"domain_quota": "Kvota",
"domain_quota_total": "Kopējais domēna ierobežojums",
"domains": "Domēns",
"edit": "Labot",
- "empty": "Nav rezultātu",
+ "empty": "Nav iznākuma",
"excludes": "Izslēdzot",
"filter_table": "Filtra tabula",
"filters": "Filtri",
"fname": "Pilns vārds",
- "force_pw_update": "Piespiedu paroles atjaunošana pie nākošās pieslēgšanās",
+ "force_pw_update": "Piespiedu paroles atjaunināšana nākamajā pieteikšanās reizē",
"in_use": "Lietošanā (%)",
"inactive": "Neaktīvs",
"kind": "Veids",
@@ -349,7 +434,7 @@
"last_run_reset": "Ievietot sarakstā kā nākamo",
"mailbox_quota": "Maks. pastkastes izmērs",
"mailboxes": "Pastkaste",
- "max_aliases": "Maks. iespejamās aliases",
+ "max_aliases": "Lielākais aizstājvārdu skaits",
"max_mailboxes": "Maks. iespējamās pastkastes",
"max_quota": "Maks. kvota uz pastkasti",
"mins_interval": "Intervāls (min)",
@@ -369,11 +454,11 @@
"running": "Darbojas",
"set_postfilter": "Atzīmēt kā pēcfiltru",
"set_prefilter": "Atzīmēt kā pimrsfiltru",
- "sieve_info": "Jūs varat saglabāt vairākus filtrus katram lietotājam, bet tikai viens pirmsfiltrs un viens pēcfiltrs var būt aktīvs vienlaicīgi.<br>\r\nKatrs filtrs tiks apstrādāts aprakstītajā kārtībā. Kļūdains vai izdots skripts \"Paturēt;\" pārtrauks turpmāko skriptu apstrādi.<br>\r\n<a href=\"https://github.com/mailcow/mailcow-dockerized/blob/master/data/conf/dovecot/global_sieve_before\" target=\"_blank\">Global sieve prefilter</a> → Pirmsfiltrs → Lietotāja skripts → Pēcfiltrs → <a href=\"https://github.com/mailcow/mailcow-dockerized/blob/master/data/conf/dovecot/global_sieve_after\" target=\"_blank\">Global sieve postfilter</a>",
- "spam_aliases": "Temp. alias",
+ "sieve_info": "Katram lietotājam var saglabāt vairākus filtrus, bet tikai viens pirmsfiltrs un viens pēcfiltrs var darboties vienlaicīgi.<br>\nKatrs filtrs tiks apstrādāts norādītajā kārtībā. Ne kļūdains skripts, ne izdots \"keep;\" nepārtrauks turpmāko skriptu apstrādi. Vispārējo sieve skriptu izmaiņas izsauks Dovecot pārsāknēšanu.<br><br>Vispārējais sieve pirmsfiltrs • Pirmsfiltrs • Lietotāja skripti • Pēcfiltrs • Vispārējais sieve pēcfiltrs",
+ "spam_aliases": "Pagaidu aizstājvārds",
"status": "Status",
"sync_jobs": "Sinhronizācijas darbi",
- "target_address": "Doties uz adresi",
+ "target_address": "Doties uz adresi",
"target_domain": "Mērķa domēns",
"tls_enforce_in": "Piespiest TLS ienākošajiem",
"tls_enforce_out": "Piespiest TLS izejošajiem",
@@ -385,13 +470,25 @@
"daily": "Ik dienu",
"hourly": "Ik stundu",
"last_mail_login": "Pēdējā pieteikšanās pastkastē",
- "mailbox": "Pastkaste"
+ "mailbox": "Pastkaste",
+ "sieve_preset_2": "Vienmēr atzīmēt noteikta sūtītāja e-pastu kā izlasītu",
+ "open_logs": "Atvērt žurnālus",
+ "sieve_preset_8": "Pārvirzīt noteikta sūtītāja e-pastu, atzīmēt kā izlasītu un ievietot to apakšmapē",
+ "sogo_visible": "Aizstājvārds ir redzams SOGo",
+ "sogo_visible_n": "Paslēpt aizstājvārdu SOGo",
+ "sogo_visible_y": "Rādīt aizstājvārdu SOGo",
+ "add_alias_expand": "Izvērst aizstājvārdu pār aizstājdomēniem",
+ "alias_domain_alias_hint": "Aizstājvārdi <b>netiek</b> automātiski piemēroti domēnu aizstājvārdiem. Aizstājadrese <code>my-alias@domain</code> <b>nenosedz</b> adresi <code>my-alias@alias-domain</code> (kur \"alias-domain\" ir iedomāts \"domain\" aizstājdomēns).<br>Lūgums izmantot sieta atlasi, lai pārvirzītu pastu uz ārēju pastkasti (skatīt cilti \"Atlasīšana\" vai izmantot SOGo -> Pārsūtītājs). \"Izvērst aizstājvārdu pār aizstājdomēniem\" ir izmantojams, lai automātiski pievienotu trūkstošos aiztājvārdus.",
+ "alias_domain_backupmx": "Aizstājdomēns ir neaktīvs retranslācijas domēnam",
+ "disable_login": "Neļaut pieteikšanos (ienākošais pasts joprojām tiks pieņemts)",
+ "sieve_preset_1": "Atmest e-pasta vēstules ar iespējami bīstamiem datņu veidiem",
+ "syncjob_last_run_result": "Pēdējās izpildes iznākums"
},
"quarantine": {
"action": "Darbības",
"atts": "Pielikumi",
- "check_hash": "Meklēt faila hašu @ VT",
- "empty": "Nav rezultātu",
+ "check_hash": "Meklēt datnes jaucējvērtību @ VT",
+ "empty": "Nav iznākuma",
"qid": "Rspamd QID",
"qitem": "Karantīnas vienumi",
"quarantine": "Karantīna",
@@ -400,7 +497,7 @@
"received": "Saņemtie",
"recipients": "Adresāts",
"release": "Atbrīvot",
- "release_body": "Šim ziņojumam mēs esam pievienojuši jūsu ziņojumu kā eml failu.",
+ "release_body": "Mēs pievienojām Tavu ziņojumu kā .eml datni šim ziņojumam.",
"release_subject": "Potenciāli kaitīgs karantīnas vienums %s",
"remove": "Noņemt",
"sender": "Sūtītājs (SMTP)",
@@ -408,40 +505,48 @@
"subj": "Priekšmets",
"text_from_html_content": "Saturs (konvertēts html)",
"text_plain_content": "Saturs (teksts/vienkāršs)",
- "toggle_all": "Pārslēgt visu"
+ "toggle_all": "Pārslēgt visu",
+ "disabled_by_config": "Pašreizējā sistēmas konfigurācija atspējo karantīnu. Lūgums iestatīt \"saglabāšanu katrai pastkastītei\" un \"lielākais pieļaujamais lielums\" karantīnas vienumiem.",
+ "qhandler_success": "Pieprasījums sekmīgi nosūtīts sistēmai. Logu tagad var aizvērt.",
+ "qinfo": "Karantīnas sistēma datubāzē saglabās noraidīto pastu (sūtītājam <em>netiks</em> radīts iespaids par piegādātu pastu), kā arī pastu, kas tiek piegādāts kā kopija pastkastes mēstuļu mapē.\n <br>\"Apgūt kā surogātpastu un izdzēst\" apgūs ziņojumu kā surogātpastu ar Bajesa teorēmu un aprēķinās arī nestriktas jaucējvērtības, lai nākotnē noraidītu līdzīgus ziņojumus.\n <br>Lūgums apzināties, ka vairāku ziņojumu apgūšana var būt laikietilpīga atkarībā no sistēmas.<br>Lieguma saraksta vienumi karantīnā netiek iekļauti.",
+ "danger": "Bīstamība",
+ "notified": "Paziņots",
+ "refresh": "Atsvaidzināt",
+ "rspamd_result": "Rspamd iznākums",
+ "settings_info": "Lielākais pieļaujamais karantējamo vienumu daudzums: %s<br>Lielākais pieļaujamais e-pasta lielums: %s MiB",
+ "spam_score": "Novērtējums"
},
"queue": {
- "queue_manager": "Queue Manager"
+ "queue_manager": "Rindas pārvaldnieks",
+ "info": "Pasta rinda satur visus e-pastus, kas gaida piegādi. Ja e-pasts ir iestrēdzis pasta rindā ilgu laiku, sistēma to automātiski izdzēš.<br>Attiecīgā pasta kļūdas ziņojums sniedz informāciju par to, kāpēc pastu neizdevās piegādāt."
},
"start": {
- "help": "Rādīt/Paslēp palīdzības paneli",
- "imap_smtp_server_auth_info": "Lūdzu, izmantojiet pilnu e-pasta adresi un PLAIN autentifikācijas mehānismu.<br>\r\nJūsu pieteikšanās dati tiks šifrēti, izmantojot servera puses obligātu šifrēšanu",
- "mailcow_apps_detail": "Izmantojiet lietotni mailcow, lai piekļūtu savam pastam, kalendāram, kontaktiem un citām lietām.",
- "mailcow_panel_detail": "<b>Domēna administrators</b> izveidot, mainīt vai dzēst pastkastes un aliases, mainīt domēnus un lasīt papildu informāciju par saviem piešķirtajiem domēniem.<br>\r\n <b>Pastkastes lietotāji</b> var izveidot ierobežotus laika ierobežojumus (surogātpasta aliases), mainīt paroli un surogātpasta filtru iestatījumus."
+ "help": "Rādīt/Paslēpt palīdzības paneli",
+ "imap_smtp_server_auth_info": "Lūgums izmantot pilnu e-pasta adresi un PLAIN autentificēšanās mehānismu.<br>\nPieteikšanās dati tiks šifrēti ar servera puses obligātu šifrēšanu."
},
"success": {
- "admin_modified": "Izmaiņas administrātoram ir saglabātas",
- "alias_added": "Aliasi pievienoti",
- "alias_domain_removed": "Alias domēns %s tika noņemts",
- "alias_modified": "Izmaiņas aliasiem %s ir saglabātas",
- "alias_removed": "Alias %s ir noņemts",
- "aliasd_added": "Pievients alias domēnam %s",
- "aliasd_modified": "Izmaiņas aloas domēnam %s ir saglabātas",
+ "admin_modified": "Pārvaldītāja izmaiņas tika saglabātas",
+ "alias_added": "Aizstājadrese %s (%d) tika pievienota",
+ "alias_domain_removed": "Aizstājdomēns %s tika noņemts",
+ "alias_modified": "Aizstājadreses izmaiņas %s tika saglabātas",
+ "alias_removed": "Aizstājvārds %s tika noņemts",
+ "aliasd_added": "Pievienots aizstājdomēns %s",
+ "aliasd_modified": "Aizstājdomēna %s izmaiņas tika saglabātas",
"app_links": "Saglabāt izmaiņas lietotņu saitēm",
"dkim_added": "DKIM atslēga saglabāta",
"dkim_removed": "DKIM atslēga %s ir noņemta",
"domain_added": "Pievienots domēns %s",
- "domain_admin_added": "Domēna administrātors %s pievienots",
- "domain_admin_modified": "Izmaiņas domēna administrātoram %s ir saglabātas",
- "domain_admin_removed": "Domēna administrators %s tika noņemts",
+ "domain_admin_added": "Tika pievienots domēna pārvaldītājs %s",
+ "domain_admin_modified": "Domēna pārvaldītāja %s izmaiņas tika saglabātas",
+ "domain_admin_removed": "Tika noņemts domēna pārvaldītājs %s",
"domain_modified": "Izmaiņas domēnam %s ir saglabātas",
"domain_removed": "Domēns %s ir noņemts",
"eas_reset": "ActiveSync ierīces priekš lietotāja %s tika atiestatītas",
- "f2b_modified": "Izmaiņas Fail2ban parameteriem ir saglabātas",
+ "f2b_modified": "Fail2ban parametru izmaiņas tika saglabātas",
"forwarding_host_added": "Pāradresācijas hosts %s pievienotsd",
"forwarding_host_removed": "Pāradresācijas hosts %s noņemts",
- "item_deleted": "Vērtība %s veiksmīgi dzēsta",
- "items_deleted": "Vērtība %s veiksmīgi dzēsta",
+ "item_deleted": "Vienums %s izdzēsts sekmīgi",
+ "items_deleted": "Vienums %s izdzēsts sekmīgi",
"items_released": "Atlasītie vienumi tika izlaisti",
"mailbox_added": "Pastkaste %s ir pievienota",
"mailbox_modified": "Izmaiņas pastkastei %s ir saglabātas",
@@ -450,54 +555,66 @@
"relayhost_added": "Relejhosts %s pievienots",
"relayhost_removed": "Relejhosts %s noņemts",
"reset_main_logo": "Atjaunot noklusējuma logotipu",
- "resource_added": "Resource %s has been added",
+ "resource_added": "Avots %s tika pievienots",
"resource_modified": "Izmaiņas %s ir saglabātas",
"resource_removed": "Resurs %s tika noņemts",
"ui_texts": "Saglabāt UI izmaiņas tekstiem",
- "upload_success": "Faila augšupielāde veiksmīga"
+ "upload_success": "Datne sekmīgi augšupielādēta",
+ "verified_fido2_login": "Apliecināta FIDO2 pieteikšanās",
+ "verified_webauthn_login": "Apliecināta WebAuthn pieteikšanās",
+ "verified_totp_login": "Apliecināta TOTP pieteikšanās",
+ "verified_yotp_login": "Apliecināta Yubico OTP pieteikšanās",
+ "app_passwd_removed": "Noņemta lietotnes parole ar Id %s",
+ "app_passwd_added": "Pievienota jauna lietotnes parole",
+ "f2b_banlist_refreshed": "Liegumu saraksta Id tika sekmīgi atsvaidzināts.",
+ "admin_added": "Tika pievienots pārvaldītājs %s",
+ "admin_removed": "Tika noņemts pārvaldītājs %s"
},
"tfa": {
"api_register": "%s izmanto Yubico Cloud API. Lūdzu iegūstiet API atslēgu priekš Jūsu atslēgas<a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">here</a>",
"confirm": "Apstiprināt",
- "confirm_totp_token": "Lūdzu apstipriniet Jūsu izmaiņas ievadot uzģenerēto tekstu",
+ "confirm_totp_token": "Lūgums apstiprināt savas izmaiņas ar izveidotās tekstvienības ievadīšanu",
"delete_tfa": "Atspējot TFA",
- "disable_tfa": "Atspējot TFA līdz nākamajai veiksmīgai pieteikšanās",
- "enter_qr_code": "Jūsu TOTP kods, ja Jūsu ierīce nevar noskanēt QR kodus.",
+ "disable_tfa": "Atspējot TFA līdz nākamajai sekmīgajai pieteikšanās reizei",
+ "enter_qr_code": "TOTP kods, ja Tava ierīce nevar nolasīt kvadrātkodus",
"key_id": "Jūsu YubiKey identifikators",
"key_id_totp": "Identifikators Jūsu atslēgai",
"none": "Deaktivizēt",
"scan_qr_code": "Lūdzu, skenējiet šo kodu ar savu autentifikācijas lietojumprogrammu vai ievadiet kodu manuāli.",
- "select": "Lūdzu izvēlaties",
+ "select": "Lūgums atlasīt",
"set_tfa": "Uzstādīt difi faktoru autentifik;acijas metodi",
- "tfa": "Divu faktoru autentifikācija",
+ "tfa": "Divpakāpju pieteikšanās",
"totp": "Uz laiku bāzēta vienreizēja parole (Google Autentifikātors utt.)",
"webauthn": "WebAuthn autentifikācija",
"waiting_usb_auth": "<i>Gaida USB ierīci...</i><br><br>Lūdzu, tagad nospiežiet pogu uz Jūsu WebAuthn USB ierīces.",
- "waiting_usb_register": "<i>Gaida USB ierīci...</i><br><br>Lūdzu augšā ievadiet Jūsu paroli un apstipriniet WebAuthn reģistrāciju nospiežot pogu uz Jūsu WebAuthn USB ierīces.",
- "yubi_otp": "Yubico OTP autentifikators"
+ "waiting_usb_register": "<i>Gaida USB ierīci...</i><br><br>Lūgums augstāk ievadīt savu paroli un apstiprināt reģistrēšanos ar USB ierīces pogas nospiešanu.",
+ "yubi_otp": "Yubico OTP autentifikators",
+ "authenticators": "Autentificētāji",
+ "u2f_deprecated_important": "Lūgums reģistrēt savu atslēgu pārvaldības lapā ar jauno WebAuthn veidu."
},
"user": {
"action": "Rīcība",
"active": "Aktīvs",
"active_sieve": "Aktīvais filtrs",
- "alias": "Alias",
- "alias_create_random": "Ģenerēt nejaušā nosaukuma alias",
- "alias_extend_all": "Pagarināt alias par 1 stundu",
+ "alias": "Aizstājvārds",
+ "alias_create_random": "Izveidot nejaušu aizstājvārdu",
+ "alias_extend_all": "Pagarināt aizstājvārdus par 1 stundu",
"alias_full_date": "d.m.Y, H:i:s T",
- "alias_remove_all": "Noņemt visus alias",
+ "alias_remove_all": "Noņemt visus aizstājvārdus",
"alias_select_validity": "Derīguma periods",
"alias_time_left": "Laiks atlicis",
"alias_valid_until": "Derīgs līdz",
"aliases_also_send_as": "Atļauts arī sūtīt kā lietotājam",
- "aliases_send_as_all": "Nepārbaudīt sūtītāja peikļuvi domēnam/iem un alias domēniem",
+ "aliases_send_as_all": "Nepārbaudīt sūtītāja piekļuvi šiem domēniem un to aizstājdomēniem",
"change_password": "Nomainīt paroli",
- "client_configuration": "Parādīt konfigurācijas piemērus dažādām iekārtām",
+ "client_configuration": "Parādīt konfigurācijas norādes e-pasta klientiem un tālruņiem",
"create_syncjob": "Izveidot jaunu sinhronizācijas darbu",
"day": "Dienas",
- "direct_aliases": "Tiešas alias adreses",
- "direct_aliases_desc": "Tiešie alias tiek ietekmēti no spam filtra un TLS politikas iestatījumiem affected by spam filter and TLS policy settings.",
+ "description": "Apraksts",
+ "direct_aliases": "Tiešas aizstājadreses",
+ "direct_aliases_desc": "Tiešās aizstājadreses ir surogātpasta atlasīšanas un TLS nosacījumu iestatījumu ietekmētas.",
"eas_reset": "Atiestatīt ActiveSync ierīces kešatmiņu",
- "eas_reset_help": "Daudzos gadījumos ierīces kešatmiņas atiestatīšana palīdz atjaunot bojāto ActiveSync profilu.<br><b>Uzmanību:</b> Visi elementi tiks atkārtoti ielādēti!",
+ "eas_reset_help": "Daudzos gadījumos ierīces kešatmiņas atiestatīšana palīdz atjaunot bojāto ActiveSync profilu.<br><b>Uzmanību:</b> visi vienumi tiks atkārtoti lejupielādēti!",
"eas_reset_now": "Atiestatīt tagad",
"edit": "Labot",
"encryption": "Šifrēšana",
@@ -516,21 +633,21 @@
"new_password_repeat": "Paroles apstiprinājums (atkārtoti)",
"no_active_filter": "Nav pieejami aktīvi filtri",
"no_record": "Nav ieraksta",
- "password_now": "Pašreizējā parole (Apstiprināt izmaiņas)",
+ "password_now": "Pašreizējā parole (apstiprināt izmaiņas)",
"remove": "Noņemt",
- "running": "Running",
+ "running": "Darbojas",
"save_changes": "Saglabāt izmaiņas",
- "shared_aliases": "Koplietotās alias adreses",
- "shared_aliases_desc": "Koplietotais alias netiek ietekmēts no lietotāju darbībām. Pielāgots spam filtra iestatījums var būt arhivēts no domēna ietvaros uzstādīta noteikuma no administrātora..",
+ "shared_aliases": "Kopīgotās aizstājadreses",
+ "shared_aliases_desc": "Tādi lietotāja iestatījumi kā surogātpasta atlasīšana vai šifrēšanas nosacījumi neietekmē kopīgotos aizstājvārdus. Atbilstošu surogātpasta atlasi var izveidot tikai pārvaldītājs kā domēnu aptverošu nosacījumu.",
"show_sieve_filters": "Parādīt aktīvā lietotāja Sieve filtru",
- "spam_aliases": "Pagaidu e-pasta alias",
+ "spam_aliases": "Pagaidu e-pasta aizstājvārdi",
"spamfilter": "Mēstuļu filtrs",
"spamfilter_behavior": "Reitings",
- "spamfilter_bl": "Melnais saraksts",
- "spamfilter_bl_desc": "Melajā sarakstā iekļautās adreses vienmēr tiks uzskatītas par mēstulēm.",
- "spamfilter_default_score": "Noklusētās vērtības:",
+ "spamfilter_bl": "Liegumu saraksts",
+ "spamfilter_bl_desc": "No lieguma sarakstā iekļautajām e-pasta adresēm saņemtās vēstules <b>vienmēr</b> tiks atzīmētas kā mēstules un noraidītas. Noraidītais pasts <b>netiks</b> ievietots karantīnā. Var izmantot aizstājzīmes. Atlasīšana tiek pielietota tikai tiešiem aizstājvārdiem (aizstājvārdiem ar vienu mērķa pastkasti), izņemot visu tverošos aizstājvārdus un pašu pastkasti.",
+ "spamfilter_default_score": "Noklusējuma vērtības",
"spamfilter_green": "Zaļš: šī nav mēstule",
- "spamfilter_hint": "Pirmā vērtība norāda uz zemu \"Spam vērtējumu\" vērtējumu, otra vērtība par \"Augstu spam vērtējumu\".",
+ "spamfilter_hint": "Pirmā vērtība norāda uz zemu \"mēstules novērtējumu\", otrā atspoguļo \"augstu mēstules novērtējumu\".",
"spamfilter_red": "Sarkans: Šī vēstule noteikti ir spams un tiek nekavējoties noraidīta",
"spamfilter_table_action": "Darbība",
"spamfilter_table_add": "Pievienot vienību",
@@ -538,8 +655,8 @@
"spamfilter_table_empty": "Nav datu ko parādīt",
"spamfilter_table_remove": "noņemt",
"spamfilter_table_rule": "Noteikums",
- "spamfilter_wl": "Baltais saraksts",
- "spamfilter_wl_desc": "Baltajā sarakstā iekļautās adreses nekad netiks klasificētas kā mēstules.",
+ "spamfilter_wl": "Atļautais saraksts",
+ "spamfilter_wl_desc": "No atļautā saraksta e-pasta adresēm saņemtās vēstules <b>nekad</b> netiks atzīmētas kā mēstules. Var tikt izmantotas aizstājzīmes. Atlase tiek piemērota tikai tiešiem aizstājvārdiem (aizstājvārdiem ar vienu mērķa pastkasti), izņemot visu tverošos aizstājvārdus un pašu pastkasti.",
"spamfilter_yellow": "Dzeltens: šī vēstule visticamāk ir spams un tiks pārvietota uz Junk mapi",
"status": "Status",
"sync_jobs": "Sinhronizācijas uzdevumi",
@@ -552,20 +669,66 @@
"tls_enforce_in": "Piespiest TLS ienākošajiem",
"tls_enforce_out": "Piespiest TLS izejošajiem",
"tls_policy": "Šifrēšanas politika",
- "tls_policy_warning": "<strong>Uzmanību:</strong> Ja jūs izlemjat aktivizēt e-pastu šifrēšanu, Jūs varat pazaudēt vēstules.<br>Vēstules kas neatbilst politikai atleks atpakaļ no sistēmas ar kļūdu.<br>Šī opcija attiecas uz Jūsu primāro e-pasta adresi, visām adresēm, kas atvasinātas no alias domēniem, kā arī aliasi <b>,kas saistīti tikai ar šo pastkasti</b> kā mērķis.",
+ "tls_policy_warning": "<strong>Brīdinājums:</strong> ja tiek izlemts ieviest šifrēta pasta nosūtīšanu, var tikt pazaudēti e-pasta ziņojumi.<br>Ziņojumi, kas neatbilst nosacījumiem, pasta sistēma atmetīs ar kļūdu.<br>Šī iespēja attiecas uz galveno e-pasta adresi (pieteikšanās vārdu), visām adresēm, kas atvasinātas no aizstājdomēniem, kā arī aizstājadreses, <b>kas norāda tikai uz šo pastkasti</b>.",
"user_settings": "Lietotāja iestatījumi",
"username": "Lietotājvārds",
- "waiting": "Waiting",
+ "waiting": "Gaida",
"week": "Nedēļa",
- "weeks": "Nedēļas"
+ "weeks": "Nedēļas",
+ "open_logs": "Atvērt žurnālus",
+ "apple_connection_profile_mailonly": "Šis savienojuma profils iekļauj IMAP un SMTP konfigurācijas parametrus Apple ierīcei.",
+ "pushover_info": "Pašpiegādes paziņojumu iestatījumi attieksies uz visu tīro (ne surogātpasta) pastu, kas piegādāts uz <b>%s</b>, ieskaitot aizstājvārdus (kopīgotus, nekopīgotus, ar birkām).",
+ "app_hint": "Lietotņu paroles ir aizstājējparoles, lai pieteiktos IMAP, SMTP, CalDAV, CardDAV un EAS. Lietotājvārds paliek nemainīgs. SOGo tīmekļa pasts nav pieejams ar lietotņu parolēm.",
+ "direct_protocol_access": "Šim pastkastes lietotājam ir <b> tieša, ārēja piekļuve</b> zemāk uzskaitītajiem protokoliem un lietotnēm. Šo iestatījumu pārrauga pārvaldītājs. Lietotņu paroles var izveidot, lai nodrošinātu piekļuvi atsevišķiem protokoliem un lietotnēm.<br>Poga \"Tīmekļa pasts\" nodrošina vienotu pieteikšanos SOGo un vienmēr ir pieejama.",
+ "last_ui_login": "Pēdējā pieteikšanās saskarnē",
+ "login_history": "Pieteikšanās vēsture",
+ "no_last_login": "Nav informācijas par pēdējām pieteikšanās saskarnē reizēm",
+ "open_webmail_sso": "Tīmekļa pasts",
+ "last_mail_login": "Pēdējā pasta pieteikšanās",
+ "change_password_hint_app_passwords": "Kontā ir %d lietotņu paroles, kas netiks mainītas. Lai pārvaldītu tās, jādodas uz cilni \"Lietotņu paroles\".",
+ "with_app_password": "ar lietotnes paroli",
+ "apple_connection_profile_with_app_password": "Jauna lietotnes parole ir izveidota un pievienota profilam, lai ierīces iestatīšanas laikā nebūtu nepieciešams ievadīt paroli. Lūgums nekopīgot datni, jo tā nodrošina pilnu piekļuvi pastkastei.",
+ "tfa_info": "Divpakāpju autentificēšanās palīdz aizsargāt kontu.Ja tā ir iespējota, ir nepieciešamas lietotņu paroles, lai pieteiktos lietotnēs vai pakalpojumos, kas nenodrošina divpakāpju autentificēšanos (piem., e-pasta klienti).",
+ "app_passwds": "Lietotņu paroles",
+ "create_app_passwd": "Izveidot lietotnes paroli",
+ "empty": "Nav iznākuma",
+ "quarantine_notification_info": "Tiklīdz paziņojums ir nosūtīts, vienumi tiks atzīmēti kā \"paziņoti\", un par šo vienumu vairs netiks sūtīti paziņojumi.",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Sūtītāja pārbaude ir atspējota</span>",
+ "syncjob_last_run_result": "Pēdējās izpildes iznākums"
},
"datatables": {
"paginate": {
"first": "Pirmā",
"last": "Pēdējā"
- }
+ },
+ "emptyTable": "Tabulā nav datu",
+ "search": "Meklēt:"
},
"debug": {
- "last_modified": "Pēdējoreiz mainīts"
+ "last_modified": "Pēdējoreiz mainīts",
+ "static_logs": "Nemainīgie žurnāli",
+ "no_update_available": "Sistēma izmanto jaunāko versiju",
+ "in_memory_logs": "Atmiņā esošie žurnāli",
+ "system_containers": "Sistēma un konteineri",
+ "current_time": "Sistēmas laiks",
+ "external_logs": "Ārējie žurnāli",
+ "logs": "Žurnāli",
+ "architecture": "Arhitektūra",
+ "disk_usage": "Diska lietojums",
+ "memory": "Atmiņa",
+ "timezone": "Laika josla",
+ "uptime": "Darbošanās laiks"
+ },
+ "warning": {
+ "domain_added_sogo_failed": "Domēns pievienots, bet neizdevās pārsāknēt SOGO. Lūgums pārbaudīt servera žurnālus.",
+ "dovecot_restart_failed": "Dovecot neizdevās pārsāknēties. Lūgums pārbaudīt žurnālus",
+ "is_not_primary_alias": "Izlaists aizstājvārds %s, kas nav galvenais",
+ "no_active_admin": "Nevar deaktivēt pēdējo aktīvo pārvaldītāju"
+ },
+ "oauth2": {
+ "access_denied": "Lūgums pieteikties kā pastkastes īpašniekam, lai nodrošinātu piekļuvi ar OAuth2."
+ },
+ "fido2": {
+ "fido2_auth": "Pieteikties ar FIDO2"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.nb-no.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.nb-no.json
index 8e09462..bca6087 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.nb-no.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.nb-no.json
@@ -92,7 +92,73 @@
"r_active": "Aktive begrensninger",
"queue_unban": "fjern blokkering",
"r_inactive": "Inaktive begrensninger",
- "r_info": "Grå/deaktivere elementer i listen over aktive restriksjoner er ikke kjente som gyldige restriksjoner i mailcow og kan ikke flyttes. Ukjente begrensninger vil bli aktivert i den rekkefølgen de opptrer uansett.<br>Du kan legge til nye elementer i <code>inc/vars.local.inc.php</code> for å kunne slå dem av og på."
+ "r_info": "Grå/deaktivere elementer i listen over aktive restriksjoner er ikke kjente som gyldige restriksjoner i mailcow og kan ikke flyttes. Ukjente begrensninger vil bli aktivert i den rekkefølgen de opptrer uansett.<br>Du kan legge til nye elementer i <code>inc/vars.local.inc.php</code> for å kunne slå dem av og på.",
+ "relayhosts_hint": "Definer sender-avhengige transportmetoder for å kunne velge dem i domenekonfigurasjonsdialogen<br>\n Transportmetoden er alltid \"smtp:\" og vil derfor forsøke TLS når tilbudt. Innpakket TLS (SMTPS) er ikke støttet. En brukers individuelle utgående TLS-policyinnstilling tas til etterretning.<br>\n Gjelder for valgte domener inkludert alias-domener.",
+ "rspamd_global_filters_regex": "Navnene forklarer deres mening. Alt innhold må inneholde gyldige regulære utstrykk etter formatet \"/mønster/alternativer\" (f.eks. <code>/.+@domain\\.tld/i</code>).<br>\n Selv om grove sjekkrutiner kjøres for hver linje regex, kan funksjonaliteten i Rspamd bli ødelagt dersom den ikke klarer å lese syntakset riktig.<br>\n Rspamd vil forsøke å lese innholdet når det endres. Hvis du opplever problemer, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">start Rspamd på nytt</a> for å tvinge ny innlesing av mappingene.<br>Svartelistede elementer er ekskluderte fra karantene.",
+ "transport_test_rcpt_info": "• Bruk null@hosted.mailcow.de for å teste videresending til en ekstern destinasjon.",
+ "transports_hint": "• En transportmapping <b>overstyrer</b> en sender-avhengig transportmapping</b>.<br>\n• MX-baserte transportmappinger er foretrukket brukt.<br>\n• Utgående TLS-policyinnstillinger per-bruker blir ignorert og kan kun tvinges via TLS-policymappinger.<br>\n• Transporttjenesten for definerte transportmetoder er alltid \"smtp:\" og vil derfor forsøke TLS når tilbudt. Innpakket TLS (SMTPS) støttes ikke.<br>\n• Adresser som matcher \"/localhost$/\" vil alltid sendes via \"local:\", derfor vil en \"*\"-destinasjon ikke gjelde disse adressene.<br>\n• For å bestemme identifikasjon for et eksempelvis neste hopp \"[host]:25\", vil Postfix <b>alltid</b> sende en forespørsel for \"host\" før den søker etter \"[host]:25\". Denne oppførselen gjør det umulig å bruke både \"host\" og \"[host]:25\" samtidig.",
+ "regex_maps": "Regex-mappinger",
+ "relay_from": "\"Fra:\"-adresse",
+ "relay_rcpt": "\"Til:\"-adresse",
+ "relay_run": "Kjør test",
+ "relayhosts": "Sender-avhengige transportmetoder",
+ "remove": "Fjern",
+ "remove_row": "Fjern rad",
+ "reset_default": "Tilbakestill til standardinnstillinger",
+ "reset_limit": "Fjern hash",
+ "routing": "Ruting",
+ "rsetting_add_rule": "Legg til regel",
+ "rsetting_content": "Regelinnhold",
+ "rsetting_desc": "Kort beskrivelse",
+ "rsetting_no_selection": "Vennligst velg en regel",
+ "rsetting_none": "Ingen regler tilgjengelig",
+ "rsettings_insert_preset": "Legg inn eksempel-forvalg \"%s\"",
+ "rsettings_preset_1": "Deaktiver alt unntatt DKIM og mengdebegrensning for autentiserte brukere",
+ "rsettings_preset_2": "Postmastere vil ha spam",
+ "rsettings_preset_3": "Bare tillat spesifikke sendere for en postboks (f.eks. kun bruk som intern postboks)",
+ "rsettings_preset_4": "Deaktiver Rspamd for et domene",
+ "rspamd_com_settings": "Et navn for innstillingen vil bli autogenerert, vennligst se eksempelforvalgene under. For ytterligere detaljer se <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd-dokumentasjonen</a>",
+ "rspamd_global_filters": "Globale filtreringsmappinger",
+ "rspamd_global_filters_agree": "Jeg skal være forsiktig!",
+ "rspamd_global_filters_info": "Globale filtermappinger inneholder forskjellige typer globale svarte- og hvitelister.",
+ "rspamd_settings_map": "Rspamd innstillingsmapping",
+ "sal_level": "Moo-nivå",
+ "save": "Lagre endringer",
+ "search_domain_da": "Søk domener",
+ "send": "Send",
+ "sender": "Avsender",
+ "service": "Tjeneste",
+ "service_id": "TjenesteID",
+ "source": "Kilde",
+ "spamfilter": "Spamfilter",
+ "subject": "Emne",
+ "success": "Suksess",
+ "sys_mails": "Systemeposter",
+ "text": "Tekst",
+ "time": "Tid",
+ "title": "Tittel",
+ "title_name": "\"mailcow UI\" nettstedstittel",
+ "to_top": "Tilbake til toppen",
+ "transport_dest_format": "Regex eller syntaks: example.org, .example.org, *, box@example.org (flere verdier kan separeres via komma)",
+ "transport_maps": "Transportmappinger",
+ "ui_footer": "Bunntekst (HTML tillatt)",
+ "ui_header_announcement": "Annonseringer",
+ "ui_header_announcement_active": "Gjør annonsering aktiv",
+ "ui_header_announcement_content": "Tekst (HTML tillatt)",
+ "ui_header_announcement_help": "Annonseringen er synlig for alle innloggede brukere og på innloggingsskjermen for grensesnittet.",
+ "ui_header_announcement_select": "Velg annonseringstype",
+ "ui_header_announcement_type": "Type",
+ "ui_header_announcement_type_danger": "Veldig viktig",
+ "ui_header_announcement_type_info": "Info",
+ "ui_header_announcement_type_warning": "Viktig",
+ "ui_texts": "Grensesnittmerkelapper og tekster",
+ "unban_pending": "fjerning av utestenging avventes",
+ "unchanged_if_empty": "Hvis uendret, la være tomt",
+ "upload": "Last opp",
+ "username": "Brukernavn",
+ "validate_license_now": "Validér GUID mot lisenstjener",
+ "verify": "Validér",
+ "yes": "✓"
},
"acl": {
"ratelimit": "Nivågrense",
@@ -119,11 +185,12 @@
"protocol_access": "Endre protokolltilgang",
"pushover": "Pushover",
"quarantine": "Karantenehandlinger",
- "quarantine_attachments": "Sett vedlegg i karantene",
+ "quarantine_attachments": "Se vedlegg i karantene",
"quarantine_category": "Endre varslingskategori for karantene",
"quarantine_notification": "Endre karantenevarslinger",
"domain_desc": "Endre domenebeskrivelse",
- "extend_sender_acl": "Tillat utvidelse av sender-ACL fra eksterne adresser"
+ "extend_sender_acl": "Tillat utvidelse av sender-ACL fra eksterne adresser",
+ "pw_reset": "Tillat endring av brukerpassord"
},
"add": {
"app_passwd_protocols": "Tillatte protokoller for app-passord",
@@ -204,5 +271,198 @@
"select_domain": "Vennligst velg et domene først",
"active": "Aktiv",
"target_address_info": "<small>Komplett/e epostadresse/r (kommaseparert).</small>"
+ },
+ "danger": {
+ "dkim_domain_or_sel_exists": "En DKIM-nøkkel for \"%s\" eksisterer og vil ikke bli overskrevet",
+ "from_invalid": "Avsender kan ikke være tom",
+ "bcc_must_be_email": "BCC-destinasjon %s er ikke en gyldig epostadresse",
+ "domain_quota_m_in_use": "Domenekvote må være større enn eller lik %s MiB",
+ "access_denied": "Tilgang nektet eller ugyldige skjemadata",
+ "alias_domain_invalid": "Aliasdomene %s er ugyldig",
+ "alias_empty": "Aliasadresse kan ikke være tom",
+ "alias_goto_identical": "Alias og gå-til-adresse kan ikke være identiske",
+ "alias_invalid": "Aliasadresse %s er ugyldig",
+ "aliasd_targetd_identical": "Aliasdomene kan ikke være likt som måldomene: %s",
+ "aliases_in_use": "Max. aliaser må være større enn eller det samme som %d",
+ "app_name_empty": "App-navn kan ikke være tomt",
+ "app_passwd_id_invalid": "App-passord ID %s ugyldig",
+ "bcc_empty": "BCC-destinasjon kan ikke være tom",
+ "bcc_exists": "En BCC-mapping %s eksisterer for type %s",
+ "comment_too_long": "Kommentar for lang, maks 160 tegn tillatt",
+ "cors_invalid_method": "Ugyldig Allow-Method spesifisert",
+ "cors_invalid_origin": "Ugyldig Allow-Origin angitt",
+ "defquota_empty": "Standardkvote pr. postboks kan ikke være 0.",
+ "demo_mode_enabled": "Demomodus er aktivert",
+ "description_invalid": "Ressursbeskrivelse for %s er ugyldig",
+ "dkim_domain_or_sel_invalid": "DKIM-domene eller selector ugyldig: %s",
+ "domain_cannot_match_hostname": "Domenet kan ikke være det samme som vertsnavnet",
+ "domain_exists": "Domenet %s eksisterer allerede",
+ "domain_invalid": "Domenenavn er tomt eller ugyldig",
+ "domain_not_empty": "Kan ikke fjerne ikke-tomt domene %s",
+ "domain_not_found": "Domene %s ikke funnet",
+ "extended_sender_acl_denied": "manglende ACL for å angi ekstern avsenderadresse",
+ "extra_acl_invalid": "Ekstern avsenderadresse \"%s\" er ugyldig",
+ "extra_acl_invalid_domain": "Ekstern avsenderadresse \"%s\" bruker et ugyldig domene",
+ "fido2_verification_failed": "FIDO2-verifisering feilet: %s",
+ "file_open_error": "Fil kan ikke åpnes for skriving",
+ "filter_type": "Feil filtertype",
+ "global_filter_write_error": "Kunne ikke skrive filterfil: %s",
+ "global_map_invalid": "Global mapping-ID %s ugyldig",
+ "global_map_write_error": "Kunne ikke skrive global mapping-ID %s: %s",
+ "goto_empty": "En aliasadresse må inneholde minst en gyldig gå-til-adresse",
+ "goto_invalid": "Gå-til-adresse %s er ugyldig",
+ "ham_learn_error": "Ham-læringsfeil: %s",
+ "imagick_exception": "Feil: Imagick-avvik under lesing av bilde",
+ "img_invalid": "Kan ikke validere bildefil",
+ "img_tmp_missing": "Kan ikke validere bildefil: Midlertidig fil ikke funnet",
+ "invalid_bcc_map_type": "Ugyldig BCC-mappingtype",
+ "invalid_destination": "Målformat \"%s\" er ugyldig",
+ "invalid_filter_type": "Ugyldig filtertype",
+ "invalid_host": "Ugyldig vert angitt: %s",
+ "invalid_mime_type": "Ugyldig mime-type",
+ "invalid_nexthop": "\"Next hop\"-format er ugyldig",
+ "img_dimensions_exceeded": "Bildet overskriver maksimal bildestørrelse",
+ "img_size_exceeded": "Bildet overskrider maksimal filstørrelse"
+ },
+ "debug": {
+ "logs": "Logger",
+ "update_available": "En oppdatering er tilgjengelig",
+ "service": "Tjeneste",
+ "show_ip": "Vis offentlig IP",
+ "memory": "Minne",
+ "online_users": "Tilkoblede brukere",
+ "restart_container": "Omstart",
+ "size": "Størrelse",
+ "started_at": "Startet ved",
+ "started_on": "Startet den",
+ "static_logs": "Statiske logger",
+ "success": "Suksess",
+ "system_containers": "System og kontainere",
+ "timezone": "Tidssone",
+ "uptime": "Oppetid",
+ "no_update_available": "Systemet kjører siste versjon",
+ "update_failed": "Kunne ikke se etter oppdateringer",
+ "username": "Brukernavn",
+ "wip": "Foreløpig under utvikling"
+ },
+ "diagnostics": {
+ "dns_records_24hours": "Vennligst vær oppmerksom på at endringer gjort i DNS kan ta opp til 24 timer før riktig status vises på denne siden. Den er ment som en måte for deg å enkelt se hvordan du kan sette opp DNS-oppføringene dine og se at alle oppføringer er korrekt lagret i DNS.",
+ "cname_from_a": "Verdi hentet fra A/AAAA-oppføring. Dette er støttet så lenge oppføringen peker til riktig ressurs.",
+ "dns_records_docs": "Vennligst også se <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">dokumentasjonen</a>.",
+ "dns_records": "DNS-oppføringer",
+ "dns_records_data": "Korrekte data",
+ "dns_records_name": "Navn",
+ "dns_records_status": "Nåværende status",
+ "dns_records_type": "Type",
+ "optional": "Denne oppføringen er valgfri."
+ },
+ "edit": {
+ "bcc_dest_format": "BCC-destinasjon må være en enkelt, gyldig epostadresse.<br>Hvis du trenger å sende en kopi til flere adresser, opprett et alias og bruk det her.",
+ "pushover_info": "Innstillinger for pushvarslinger vil gjelde alle rene (ikke-spam) eposter levert til <b>%s</b>, inkludert aliaser (delte, ikke-delte, taggede).",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> Du kan definere transportmappinger for et spesifikt mål for dette domenet. Hvis dette ikke er definert, blir det gjort et MX-oppslag.",
+ "delete2duplicates": "Slett duplikater på målvert",
+ "description": "Beskrivelse",
+ "disable_login": "Ikke tillat innlogging (innkommende epost blir likevel mottatt)",
+ "domain_admin": "Endre domeneadministrator",
+ "max_mailboxes": "Maks antall mailbokser",
+ "quota_warning_bcc_info": "Advarsler blir sendt som separate kopier til de følgende mottakerne. Emnet vil få lagt til det korresponderende brukernavnet i parantes, for eksempel: <code>Kvotevarsel (user@example.com)</code>.",
+ "domain_footer_skip_replies": "Ignorer bunntekst ved svar på epost",
+ "extended_sender_acl": "Eksterne avsenderadresser",
+ "extended_sender_acl_info": "En DKIM-domenenøkkel bør importeres, hvis tilgjengelig.<br>\n Husk å legge denne serveren til den korresponderende SPF TXT-oppføringen.<br>\n Når et domene eller aliasdomene legges til på denne serveren, og det overlapper med en ekstern adresse, blir den eksterne adressen fjernet.<br>\n Bruk @domain.tld for å tillate sending som *@domain.tld.",
+ "password_repeat": "Bekreft passord (gjenta)",
+ "pushover_title": "Varslingstittel",
+ "pushover_vars": "Når et avsenderfilter ikke er definert, vil alle epostere bli vurdert.<br>Regex-filtre såvel så eksakte avsendersjekker kan bli individuelt definert og vil bli vurdert sekvensielt. De er ikke avhengige av hverandre.<br>Tilgjengelige variabler for tekst og tittel (vennligst observer policyer for databeskyttelse)",
+ "admin": "Endre administrator",
+ "domain_footer_info": "Bunntekst for hele domenet leggese til alle utgående eposter assosiert med en adresse innenfor dette domenet. <br> De følgende variablene kan brukes for bunnteksten:",
+ "domain_footer_info_vars": {
+ "custom": "{= foo =} - Hvis mailboksen har en spesialattributt \"foo\" med verdi \"bar\", vil den vise \"bar\"",
+ "auth_user": "{= auth_user =} - Autentisert brukernavn spesifisert av en MTA",
+ "from_user": "{= from_user =} - Fra brukerdelen av konvolutten, f.eks. for \"moo@mailcow.tld\" vil den returnere \"moo\"",
+ "from_name": "{= from_name =} - Fra-navn fra konvolutten, f.eks. for \"Mailcow <moo@mailcow.tld>\" vil den vise \"Mailcow\"",
+ "from_addr": "{= from_addr =} - Fra adressedelen av konvolutten",
+ "from_domain": "{= from_domain =} - Fra domene-delen av konvolutten"
+ },
+ "mailbox_relayhost_info": "Aktiveres kun for mailboksen og direkte aliaser, overstyrer domene-videresendingsvert.",
+ "mbox_rl_info": "Denne begrensningen gjelder for SASL-innloggingsnavnet, dersom det er likt noen \"from\"-adresser benyttet av den innloggede brukeren. En mailboks-begrensning overstyrer en domene-begrensning.",
+ "allow_from_smtp_info": "La stå tom for å tillate alle avsendere.<br>IPv4/IPv6-adresser og -nettverk.",
+ "domain": "Endre domene",
+ "encryption": "Kryptering",
+ "exclude": "Ekskluder objekter (regex)",
+ "footer_exclude": "Ekskluder fra bunntekst",
+ "gal_info": "GAL inneholder alle objeker i et domene og kan ikke redigeres av noen brukere. Ledig/opptatt-informasjon i SOGo mangler dersom den deaktiveres! <b>Start SOGo på nytt for å aktivere endringene.</b>",
+ "grant_types": "Grant-typer",
+ "hostname": "Vertsnavn",
+ "inactive": "Inaktiv",
+ "kind": "Type",
+ "last_modified": "Sist endret",
+ "lookup_mx": "Målet er et regex-uttrykk for å matche mot MX_navnet (<code>*\\.google\\.com</code> for å route all epost som skal til en MX-server som slutter på google.com, via dette målet)",
+ "mailbox": "Endre mailboks",
+ "mailbox_quota_def": "Standardkvote for mailboks",
+ "max_quota": "Maks kvote pr. mailboks (MiB)",
+ "maxage": "Maksimal alder for meldinger, i dager, som vil hentes fra ekstern<br><small>(0 = ignorer alder)</small>",
+ "maxbytespersecond": "Maks bytes pr. sekund <br><small>(0 = ubegrenset)</small>",
+ "pushover_sender_array": "Bare vurder de følgende avsenderadressene <small>(komma-separert)</small>",
+ "pushover_sender_regex": "Vurder følgende avsender-regex",
+ "pushover_text": "Varslingstekst",
+ "pushover_sound": "Lyd",
+ "pushover_verify": "Bekreft identifikasjon",
+ "quota_mb": "Kvote (MiB)",
+ "quota_warning_bcc": "Kvotevarsling BCC",
+ "ratelimit": "Mengdebegrensning",
+ "domain_footer": "Bunntekst for hele domenet",
+ "private_comment": "Privat kommentar",
+ "public_comment": "Offentlig kommentar",
+ "client_id": "Klient-ID",
+ "full_name": "Fullt navn",
+ "gal": "Global adresseliste",
+ "max_aliases": "Maks. antall aliaser",
+ "mins_interval": "Intervall (min)",
+ "multiple_bookings": "Flere bookinger",
+ "none_inherit": "Ingen / arve",
+ "acl": "ACL (rettighet)",
+ "active": "Aktiv",
+ "advanced_settings": "Avanserte innstillinger",
+ "alias": "Endre alias",
+ "allow_from_smtp": "Tillat kun disse IPene å bruke <b>SMTP</b>",
+ "allowed_protocols": "Tillatte protokoller",
+ "app_name": "Appnavn",
+ "app_passwd": "App-passord",
+ "app_passwd_protocols": "Tillatte protokoller for app-passord",
+ "automap": "Prøv å automatisk mappe opp mapper (\"Sent items\", \"Sent\" => \"Sendt\" etc.)",
+ "backup_mx_options": "Videresendingsalternativer",
+ "client_secret": "Klient-hemmelighet",
+ "comment_info": "En privat kommentar er ikke synlig for brukeren, mens en offentlig kommentar vises som et tooltip når man holder muspekeren over det",
+ "created_on": "Opprettet den",
+ "custom_attributes": "Valgfrie attributter",
+ "delete1": "Slett fra kilde når fullført",
+ "delete2": "Slett meldinger på målvert som ikke finnes på kildeverten",
+ "delete_ays": "Vennligst bekreft slettingen.",
+ "domain_footer_html": "HTML-bunntekst",
+ "domain_footer_plain": "PLAIN-bunntekst",
+ "domain_quota": "Domenekvote",
+ "domains": "Domener",
+ "dont_check_sender_acl": "Deaktivere sendersjekk for domene %s (+ aliasdomener)",
+ "edit_alias_domain": "Endre aliasdomene",
+ "force_pw_update": "Tving endring av passord ved neste innlogging",
+ "force_pw_update_info": "Denne brukeren vil bare kunne logge inn på %s. App-passord kan fremdeles brukes.",
+ "generate": "generer",
+ "nexthop": "Neste hopp",
+ "password": "Passord",
+ "previous": "Forrige side",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Eskaler mail med høy prioritet [<code>X-Priority: 1</code>]",
+ "pushover_only_x_prio": "Bare vurder epost med høy prioritet [<code>X-Priority: 1</code>]",
+ "redirect_uri": "Omdirigerings-/tilbakekallings-URL",
+ "relay_all": "Videresend alle mottakere",
+ "relay_all_info": "↪ Hvis du velger å <b>ikke</b> videresende alle mottakkere, så må du legge til en (\"blind\") mailboks for hver eneste mottaker det skal videresendes for.",
+ "relay_domain": "Videresend dette domenet",
+ "relay_unknown_only": "Videresend kun ikke-eksisterende mailbokser. Eksisterende mailbokser vil bli levert lokalt.",
+ "relayhost": "Avsender-avhengige transportmetoder",
+ "remove": "Fjern",
+ "resource": "Ressurs",
+ "save": "Lagre endringer",
+ "scope": "Omfang",
+ "sender_acl": "Tillat å sende som",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Avsender-sjekk er deaktivert</span>"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.nl-nl.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.nl-nl.json
index 46325ef..6ed9e32 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.nl-nl.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.nl-nl.json
@@ -26,7 +26,9 @@
"syncjobs": "Sync jobs",
"tls_policy": "Versleutelingsbeleid",
"unlimited_quota": "Onbeperkte quota voor mailboxen",
- "domain_desc": "Wijzig domeinbeschrijving"
+ "domain_desc": "Wijzig domeinbeschrijving",
+ "pw_reset": "Toegang om mailcow gebruikers wachtwoord te resetten",
+ "domain_relayhost": "Verander relayhost voor een domein"
},
"add": {
"activate_filter_warn": "Alle andere filters worden gedeactiveerd zolang deze geactiveerd is.",
@@ -104,7 +106,11 @@
"validate": "Verifieer",
"validation_success": "Succesvol geverifieerd",
"tags": "Tags",
- "bcc_dest_format": "BCC-bestemming moet één geldig e-mailadres zijn.<br>Als u een kopie naar meerdere adressen wilt sturen, maak dan een alias aan en gebruik die hier."
+ "bcc_dest_format": "BCC-bestemming moet één geldig e-mailadres zijn.<br>Als u een kopie naar meerdere adressen wilt sturen, maak dan een alias aan en gebruik die hier.",
+ "dry": "Synchronisatie simuleren",
+ "internal": "Intern",
+ "internal_info": "Interne aliassen zijn alleen toegankelijk vanuit het eigen (alias)domein.",
+ "sender_allowed": "Toestaan om te verzenden als deze alias"
},
"admin": {
"access": "Toegang",
@@ -138,7 +144,7 @@
"arrival_time": "Aankomsttijd",
"authed_user": "Geauthenticeerde gebruiker",
"ays": "Weet je zeker dat je deze actie wilt uitvoeren?",
- "ban_list_info": "Bekijk de lijst met verbannen IP-adressen hieronder: <b>netwerk (resterende tijd) - [acties]</b>.<br />Rode labels geven een permanente verbanning aan.<br />Het kan enkele seconden duren voordat wijzigingen hieronder zichtbaar zijn.",
+ "ban_list_info": "Bekijk de lijst met verbannen IP-adressen hieronder: <b>netwerk (resterende tijd) - [acties]</b>.<br />IP-adressen die in de wachtrij staan om te worden gedeblokkeerd, worden binnen enkele seconden uit de actieve banlijst verwijderd.<br />\n<br />Rode labels geven actieve permanente blokkades door denylisting aan.",
"change_logo": "Logo",
"configuration": "Instellingen",
"convert_html_to_text": "Converteer HTML naar plaintext",
@@ -171,7 +177,7 @@
"excludes": "Exclusief",
"f2b_ban_time": "Verbanningstijd (s)",
"f2b_ban_time_increment": "Verbanningstijd wordt verhoogd met elk verbanning",
- "f2b_blacklist": "Netwerken/hosts op de blacklist",
+ "f2b_blacklist": "Netwerken/hosts op de denylist",
"f2b_filter": "Regex-filters",
"f2b_list_info": "Een host of netwerk op de blacklist staat altijd boven eenzelfde op de whitelist. <b>Het doorvoeren van wijzigingen kan enkele seconden in beslag nemen.</b>",
"f2b_max_attempts": "Maximaal aantal pogingen",
@@ -185,7 +191,7 @@
"filter_table": "Filtertabel",
"forwarding_hosts": "Forwarding hosts",
"forwarding_hosts_add_hint": "Het is mogelijk om IPv4- of IPv6-adressen, netwerken in CIDR-notatie, hostnames (worden omgezet naar IP-adressen) of domeinnamen (worden tevens omgezet naar IP-adressen of, bij gebrek daaraan, MX-records) op te geven.",
- "forwarding_hosts_hint": "Inkomende berichten worden onvoorwaardelijk geaccepteerd vanaf iedere host hieronder vermeld. Deze hosts worden hierdoor niet gecontroleerd op DNSBLs, en zullen de greylisting omzeilen. Spam wordt daarentegen zoals gebruikelijk in de spamfolder geplaatst. Dit wordt vaak gebruikt om mailservers te specificeren die forwarden naar deze Mailcow-server.",
+ "forwarding_hosts_hint": "Inkomende berichten worden onvoorwaardelijk geaccepteerd vanaf iedere host hieronder vermeld. Deze hosts worden hierdoor niet gecontroleerd op DNSBLs, en zullen de greylisting omzeilen. Spam wordt daarentegen zoals gebruikelijk in de spamfolder geplaatst. Dit wordt vaak gebruikt om mailservers te specificeren die alles doorsturen naar deze Mailcow-server.",
"from": "Afzender",
"generate": "genereer",
"guid": "Identificatienummer - GUID",
@@ -206,7 +212,7 @@
"link": "Link",
"loading": "Even geduld aub...",
"logo_info": "De afbeelding zal worden geschaald naar een hoogte van 40px voor de navigatiebar, en naar een breedte van 250px voor de startpagina.",
- "lookup_mx": "Match bestemming aan MX (gebruik .outlook.com om alle mail gericht aan MX *.outlook.com over deze hop te laten gaan)",
+ "lookup_mx": "Bestemming is een reguliere expressie die wordt gematcht met de MX-naam (<code>.*\\.google\\.com</code> om alle e-mail die gericht is aan een MX die eindigt op google.com via deze hop te routeren)",
"main_name": "\"Mailcow\"",
"merged_vars_hint": "Grijze rijen zijn samengevoegd van <code>vars.(local.)inc.php</code> en kunnen niet worden gewijzigd.",
"message": "Bericht",
@@ -275,7 +281,7 @@
"rspamd_com_settings": "Een beschrijving voor deze instelling zal automatisch worden gegenereerd, gebruik de onderstaande presets als voorbeeld. Raadpleeg de <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd-documentatie</a> voor meer informatie.",
"rspamd_global_filters": "Globale filters",
"rspamd_global_filters_agree": "Ik ben me ervan bewust dat aanpassingen desastreuze gevolgen kunnen hebben",
- "rspamd_global_filters_info": "Ieder globaal filter heeft zijn eigen functie, zie de namen.",
+ "rspamd_global_filters_info": "Globale filtermaps bevatten verschillende soorten globale deny- en allowlists.",
"rspamd_global_filters_regex": "De velden kunnen uitsluitend regular expressions bevatten met het formaat \"/pattern/options\", bijvoorbeeld <code>/.+@domain\\.tld/i</code>.<br>Ondanks dat alle invoer wordt gecontroleerd op fouten, is het toch mogelijk dat Rspamd onbruikbaar wordt als deze de invoer niet kan lezen.<br>Als je problemen ervaart, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">herstart Rspamd</a> dan om de filters opnieuw te laten lezen.<br>Elementen op de blacklist zijn uitgesloten van de quarantaine.",
"rspamd_settings_map": "Rspamd",
"sal_level": "Moo-level",
@@ -295,7 +301,7 @@
"to_top": "Naar boven",
"transport_dest_format": "Voorbeeld: example.org, .example.org, *, mailbox@example.org (meerdere waarden zijn kommagescheiden)",
"transport_maps": "Transport-maps",
- "transports_hint": "→ Een transport-map wordt boven een afzendergebonden transport-map verkozen.<br>→ Het uitgaande versleutelingsbeleid van individuele gebruikers wordt genegeerd en kan uitsluitend worden gehandhaafd doormiddel van globaal versleutelingsbeleid.<br>→ De transportservice is altijd \"smtp:\" en zal daarom met TLS proberen te verbinden. Wrapped TLS (SMTPS) wordt niet ondersteund.<br>→ Adressen overeenkomend met \"/localhost$/\" zullen altijd via \"local:\" getransporteerd worden, hierdoor zullen \"*\"-bestemmingen niet van toepassing zijn op deze adressen.<br>→ Om de aanmeldingsgegevens van een (voorbeeld) nexthop \"[host]:25\" te bepalen, zoekt Postfix <b>altijd</b> naar \"nexthop\" voodat er wordt gekeken naar \"[nexthop]:25\". Dit maakt het onmogelijk om \"nexthop\" en \"[nexthop]:25\" tegelijkertijd te gebruiken.",
+ "transports_hint": "→ Een transport-map wordt boven een afzendergebonden transport-map verkozen.<br>→ Het uitgaande versleutelingsbeleid van individuele gebruikers wordt genegeerd en kan uitsluitend worden gehandhaafd door middel van globaal versleutelingsbeleid.<br>→ De transportservice is altijd \"smtp:\" en zal daarom met TLS proberen te verbinden. Wrapped TLS (SMTPS) wordt niet ondersteund.<br>→ Adressen overeenkomend met \"/localhost$/\" zullen altijd via \"local:\" getransporteerd worden, hierdoor zullen \"*\"-bestemmingen niet van toepassing zijn op deze adressen.<br>→ Om de aanmeldingsgegevens van een (voorbeeld) nexthop \"[host]:25\" te bepalen, zoekt Postfix <b>altijd</b> naar \"nexthop\" voodat er wordt gekeken naar \"[nexthop]:25\". Dit maakt het onmogelijk om \"nexthop\" en \"[nexthop]:25\" tegelijkertijd te gebruiken.",
"ui_footer": "Footer (HTML toegestaan)",
"ui_header_announcement": "Aankondigingen",
"ui_header_announcement_active": "Activeer aankondiging",
@@ -337,7 +343,71 @@
"admins_ldap": "LDAP administrators",
"api_read_only": "Alleen-lezen toegang",
"api_read_write": "Lees en schrijf toegang",
- "login_time": "Login tijd"
+ "login_time": "Login tijd",
+ "admin_quicklink": "Snelle link naar de admin-loginpagina verbergen",
+ "allowed_methods": "Toegestane toegangsmethoden",
+ "app_hide": "Verberg voor login",
+ "copy_to_clipboard": "Tekst gekopieerd naar het klembord!",
+ "login_page": "Loginpagina",
+ "domainadmin_quicklink": "Snelle link naar de domeinbeheerder-loginpagina verbergen",
+ "f2b_manage_external": "Fail2Ban extern beheren",
+ "f2b_manage_external_info": "Fail2Ban zal nog steeds de banlijst bijhouden, maar zal niet actief regels instellen om verkeer te blokkeren. Gebruik de onderstaande gegenereerde banlijst om het verkeer extern te blokkeren.",
+ "filter": "Filter",
+ "force_sso_text": "Als een externe OIDC-provider is geconfigureerd, verbergt deze optie de standaard Mailcow-loginformulieren en wordt alleen de Single SignOn-knop weergegeven.",
+ "force_sso": "Mailcow-login uitschakelen en alleen Single SignOn tonen",
+ "iam": "Identiteitsprovider",
+ "iam_attribute_field": "Attribuutveld",
+ "iam_authorize_url": "Autorisatie endpoint",
+ "iam_auth_flow": "Autorisatie flow",
+ "iam_auth_flow_info": "Naast de Authorization Code Flow (Standard Flow in Keycloak), die wordt gebruikt voor Single SignOn-login, ondersteunt Mailcow ook een authenticatiestroom met directe inloggegevens. De Mailpassword Flow probeert de gebruikersgegevens te valideren door gebruik te maken van de Keycloak Admin REST API. Mailcow haalt het gehashte wachtwoord op uit het attribuut <code>mailcow_password</code>, dat in Keycloak is gekoppeld.",
+ "iam_client_id": "Client ID",
+ "iam_client_secret": "Client Secret",
+ "iam_client_scopes": "Clientscopes",
+ "iam_default_template": "Standaardsjabloon",
+ "iam_default_template_description": "Als er geen sjabloon aan een gebruiker is toegewezen, wordt het standaardsjabloon gebruikt voor het aanmaken van de mailbox, maar niet voor het bijwerken van de mailbox.",
+ "iam_description": "Configureer een externe provider voor authenticatie. De mailboxen van gebruikers worden automatisch aangemaakt bij hun eerste login, mits er een attribuutkoppeling is ingesteld.",
+ "iam_extra_permission": "Om de volgende instellingen te laten werken, heeft de mailcow-client in Keycloak een <code>service account</code> nodig en de toestemming <code>view-users</code>.",
+ "iam_host": "Hostname",
+ "iam_host_info": "Voer één of meerdere LDAP-hosts in, gescheiden door komma’s.",
+ "iam_import_users": "Importeer gebruikers",
+ "iam_login_provisioning": "Gebruikers automatisch aanmaken bij het inloggen",
+ "iam_mapping": "Attribuutkoppeling",
+ "iam_bindpass": "Bind-wachtwoord",
+ "iam_periodic_full_sync": "Periodieke volledige synchronisatie",
+ "iam_port": "Poort",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "Redirect-URL",
+ "iam_rest_flow": "Mailwachtwoord-flow",
+ "iam_server_url": "Server Url",
+ "iam_sso": "Single SignOn",
+ "iam_sync_interval": "Synchronisatie-/importinterval (min)",
+ "iam_test_connection": "Verbinding testen",
+ "iam_token_url": "Token endpoint",
+ "iam_userinfo_url": "Gebruikersinfo endpoint",
+ "iam_username_field": "Gebruikersnaam veld",
+ "iam_use_ssl": "Gebruik SSL",
+ "iam_use_ssl_info": "Als SSL wordt ingeschakeld en de poort is ingesteld op 389, wordt deze automatisch aangepast naar 636.",
+ "iam_use_tls": "Gebruik StartTLS",
+ "iam_use_tls_info": "Als TLS wordt ingeschakeld, moet je de standaardpoort voor je LDAP-server (389) gebruiken. SSL-poorten kunnen niet worden gebruikt.",
+ "iam_version": "Versie",
+ "ignore_ssl_error": "Negeer SSL foutmeldingen",
+ "ip_check_opt_in": "Kies ervoor om de externe diensten <strong>ipv4.mailcow.email</strong> en <strong>ipv6.mailcow.email</strong> te gebruiken om externe IP-adressen te bepalen.",
+ "needs_restart": "vereist een herstart",
+ "no": "✕",
+ "password_reset_info": "Als er geen herstel-e-mailadres is opgegeven, kan deze functie niet worden gebruikt.",
+ "password_reset_settings": "Instellingen voor wachtwoordherstel",
+ "password_reset_tmpl_html": "HTML sjabloon",
+ "password_reset_tmpl_text": "Tekst sjabloon",
+ "password_settings": "Wachtwoordinstellingen",
+ "quicklink_text": "Toon of verberg snelle links naar andere inlogpagina’s onder het inlogformulier",
+ "queue_unban": "deblokkeren",
+ "reset_password_vars": "<code>{{link}}</code> De gegenereerde link om het wachtwoord te resetten<br><code>{{username}}</code> De mailboxnaam van de gebruiker die het wachtwoordherstel heeft aangevraagd<br><code>{{username2}}</code> De naam van de herstelmailbox<br><code>{{date}}</code> De datum waarop het verzoek tot wachtwoordherstel is gedaan<br><code>{{token_lifetime}}</code> De geldigheidsduur van de token in minuten<br><code>{{hostname}}</code> De mailcow-hostnaam",
+ "restore_template": "Leeg laten om het standaardsjabloon te herstellen.",
+ "task": "Taak",
+ "transport_test_rcpt_info": "• Gebruik null@hosted.mailcow.de om relaying naar een externe bestemming te testen.",
+ "user_link": "Gebruikerslink",
+ "user_quicklink": "Snelle link naar de gebruikers-loginpagina verbergen",
+ "yes": "✓"
},
"danger": {
"access_denied": "Toegang geweigerd of ongeldige gegevens",
@@ -463,7 +533,27 @@
"demo_mode_enabled": "Demo modus is ingeschakeld",
"template_exists": "Sjabloon %s bestaat al",
"template_id_invalid": "Sjabloon ID %s ongeldig",
- "template_name_invalid": "Sjabloon naam ongeldig"
+ "template_name_invalid": "Sjabloon naam ongeldig",
+ "tfa_removal_blocked": "Twee-factor-authenticatie kan niet worden verwijderd omdat dit vereist is voor uw account.",
+ "authsource_in_use": "De identiteitsprovider kan niet worden gewijzigd of verwijderd omdat deze momenteel door één of meerdere gebruikers wordt gebruikt.",
+ "cors_invalid_origin": "Ongeldige Allow-Origin opgegeven",
+ "extended_sender_acl_denied": "Ontbrekende ACL om externe afzenderadressen in te stellen",
+ "generic_server_error": "Er is een onverwachte serverfout opgetreden. Neem contact op met uw beheerder.",
+ "iam_test_connection": "Verbinding mislukt",
+ "img_dimensions_exceeded": "De afbeelding overschrijdt de maximale afbeeldingsgrootte",
+ "img_size_exceeded": "De afbeelding overschrijdt de maximale afbeeldingsgrootte",
+ "invalid_reset_token": "Ongeldige reset-token",
+ "max_age_invalid": "Maximale leeftijd %s is ongeldig",
+ "mode_invalid": "Mode %s is ongeldig",
+ "mx_invalid": "MX-record %s is ongeldig",
+ "password_reset_invalid_user": "Mailbox niet gevonden of er is geen herstel-e-mailadres ingesteld",
+ "password_reset_na": "Wachtwoordherstel is momenteel niet beschikbaar. Neem contact op met uw beheerder.",
+ "recovery_email_failed": "Kon geen herstel-e-mail verzenden. Neem contact op met uw beheerder.",
+ "required_data_missing": "Vereiste gegevens %s ontbreken",
+ "reset_token_limit_exceeded": "De limiet voor reset-tokens is overschreden. Probeer het later opnieuw.",
+ "to_invalid": "Ontvanger mag niet leeg zijn",
+ "webauthn_username_failed": "De geselecteerde authenticator behoort tot een ander account",
+ "version_invalid": "Versie %s is ongeldig"
},
"debug": {
"chart_this_server": "Grafiek (deze server)",
@@ -472,17 +562,14 @@
"external_logs": "Externe logs",
"history_all_servers": "Geschiedenis (alle servers)",
"in_memory_logs": "Geheugenlogs",
- "jvm_memory_solr": "JVM-geheugengebruik",
- "log_info": "<p>Mailcows <b>geheugenlogs</b> worden elke minuut afgesneden naar maximaal %d regels (LOG_LINES) om de stabiliteit te garanderen.<br>Geheugenlogs zijn niet bedoeld om bewaard te blijven. Alle applicaties die geheugenlogs schrijven worden ook naar het Docker-proces gelogd.<br>De geheugenlogs kunnen gebruikt worden voor het oplossen van problemen met bepaalde containers.</p><p><b>Externe logs</b> worden verzameld doormiddel van de API van deze applicaties.</p><p><b>Statische logs</b> zijn activiteitenlogs die niet naar het Docker-proces worden gelogd, maar wel bewaard moeten blijven (uitgezonderd API-logs).</p>",
+ "log_info": "<p>Mailcows <b>geheugenlogs</b> worden elke minuut afgesneden naar maximaal %d regels (LOG_LINES) om de stabiliteit te garanderen.<br>Geheugenlogs zijn niet bedoeld om bewaard te blijven. Alle applicaties die geheugenlogs schrijven worden ook naar het Docker-proces gelogd.<br>De geheugenlogs kunnen gebruikt worden voor het oplossen van problemen met bepaalde containers.</p><p><b>Externe logs</b> worden verzameld door middel van de API van deze applicaties.</p><p><b>Statische logs</b> zijn activiteitenlogs die niet naar het Docker-proces worden gelogd, maar wel bewaard moeten blijven (uitgezonderd API-logs).</p>",
"logs": "Logs",
"restart_container": "Herstart",
- "solr_dead": "Solr is uitgeschakeld, uitgevallen of nog bezig met opstarten.",
"docs": "Documenten",
"last_modified": "Voor het laatst bijgewerkt op",
"online_users": "Gebruikers online",
"size": "Grootte",
"started_at": "Opgestart op",
- "solr_status": "Solr-status",
"uptime": "Uptime",
"started_on": "Gestart op",
"static_logs": "Statische logs",
@@ -523,7 +610,7 @@
"alias": "Wijzig alias",
"allow_from_smtp": "Sta enkel de volgende IP-adressen toe voor <b>SMTP</b>",
"allow_from_smtp_info": "Laat leeg om alle afzenders toe te staan.<br>IPv4/IPv6-adressen en netwerken.",
- "allowed_protocols": "Toegestane protocollen",
+ "allowed_protocols": "Toegestane protocollen voor directe gebruikerstoegang (heeft geen invloed op protocollen voor app-wachtwoorden).",
"app_name": "Naam van app",
"app_passwd": "Appwachtwoord",
"automap": "Probeer mappen automatisch te koppelen (\"Verzonden items\", \"Verzonden\" => \"Verzonden\" etc.)",
@@ -608,7 +695,7 @@
"sogo_visible_info": "Wanneer verborgen zal een alias niet worden weergegeven als een selecteerbaar verzendadres. Deze optie beïnvloedt uitsluitend objecten die kunnen worden weergegeven in SOGo (gedeelde of niet-gedeelde aliasadressen die naar minstens één mailbox verwijzen).",
"spam_alias": "Maak een nieuw tijdelijk alias aan, of pas deze aan",
"spam_filter": "Spamfilter",
- "spam_policy": "Voeg items toe of verwijder items van de white- of blacklist",
+ "spam_policy": "Voeg items toe of verwijder items van de deny- en allowlists",
"spam_score": "Stel een aangepaste spamscore in",
"subfolder2": "Synchroniseer in submap op bestemming<br><small>(leeg = gebruik geen submappen)</small>",
"syncjob": "Wijzig sync job",
@@ -627,7 +714,47 @@
"acl": "ACL (Toestemming)",
"domain_footer": "Domeinbreede footer",
"domain_footer_html": "HTML footer",
- "mailbox_relayhost_info": "Wordt alleen toegepast op de mailbox en directe aliassen, maar heft een domein relayhost op."
+ "mailbox_relayhost_info": "Wordt alleen toegepast op de mailbox en directe aliassen, maar heft een domein relayhost op.",
+ "custom_attributes": "Aangepaste attributen",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - Geauthenticeerde gebruikersnaam opgegeven door een MTA",
+ "from_user": "{= from_user =} - Afzendergedeelte van het e-mailadres, bijvoorbeeld bij \"moo@mailcow.tld\" wordt \"moo\" teruggegeven",
+ "from_name": "{= from_name =} - Naam van de afzender, bijvoorbeeld bij \"Mailcow <moo@mailcow.tld>\" wordt \"Mailcow\" teruggegeven",
+ "from_addr": "{= from_addr =} - Adres van de afzender",
+ "from_domain": "{= from_domain =} - Domein van de afzender",
+ "custom": "{= foo =} - Als de mailbox het aangepaste attribuut \"foo\" met de waarde \"bar\" heeft, wordt \"bar\" teruggegeven."
+ },
+ "domain_footer_plain": "PLAIN-voettekst",
+ "domain_footer_skip_replies": "Voettekst negeren bij antwoord-e-mails",
+ "footer_exclude": "Uitsluiten van voettekst",
+ "internal": "Intern",
+ "internal_info": "Interne aliassen zijn alleen toegankelijk vanuit het eigen (alias)domein.",
+ "sender_allowed": "Toestaan om als deze alias te verzenden",
+ "sender_allowed_info": "Als dit is uitgeschakeld, kan deze alias alleen e-mail ontvangen. Gebruik de afzender-ACL om dit te overschrijven en specifieke mailboxen toestemming te geven om te verzenden.",
+ "lookup_mx": "Bestemming is een reguliere expressie die wordt gematcht met de MX-naam (<code>.*.google.com</code> om alle e-mail die gericht is aan een MX die eindigt op google.com via deze hop te routeren)",
+ "mailbox_rename": "Hernoem mailbox",
+ "mailbox_rename_agree": "Ik heb een backup gemaakt.",
+ "mailbox_rename_warning": "BELANGRIJK! Maak een back-up voordat u de mailbox hernoemt.",
+ "mailbox_rename_alias": "Alias automatisch aanmaken.",
+ "mailbox_rename_title": "Nieuwe naam van de lokale mailbox",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> is een standaard die afdwingt dat e-mailbezorging tussen mailservers TLS met geldige certificaten gebruikt. <br>\nDeze wordt gebruikt wanneer <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> niet mogelijk is vanwege ontbrekende of niet-ondersteunde DNSSEC.<br>\n<b>Opmerking</b>: Als het ontvangende domein DANE met DNSSEC ondersteunt, heeft DANE <b>altijd</b> de voorkeur – MTA-STS fungeert alleen als een fallback.",
+ "mta_sts_version": "Versie",
+ "mta_sts_version_info": "Definieert de versie van de MTA-STS-standaard – momenteel is alleen <code>STSv1</code> geldig.",
+ "mta_sts_mode": "Modus",
+ "mta_sts_mode_info": "Er zijn drie modus om uit te kiezen:<ul><li><em>testing</em> – het beleid wordt alleen gemonitord, overtredingen hebben geen impact.</li><li><em>enforce</em> – het beleid wordt strikt afgedwongen, verbindingen zonder geldige TLS worden geweigerd.</li><li><em>none</em> – het beleid wordt gepubliceerd maar niet toegepast.</li></ul>",
+ "mta_sts_max_age": "Maximale leeftijd",
+ "mta_sts_max_age_info": "Tijd in seconden dat ontvangende mailservers dit beleid mogen cachen voordat het opnieuw wordt opgehaald.",
+ "mta_sts_mx": "MX server",
+ "mta_sts_mx_info": "Staat verzending alleen toe naar expliciet vermelde mailserver-hostnamen; de verzendende MTA controleert of de DNS MX-hostnaam overeenkomt met de beleidslijst en staat levering alleen toe met een geldig TLS-certificaat (beschermt tegen MITM).",
+ "mta_sts_mx_notice": "Meerdere MX-servers kunnen worden opgegeven (gescheiden door komma’s).",
+ "none_inherit": "Geen / Erven",
+ "password_recovery_email": "E-mail voor wachtwoordherstel",
+ "pushover": "Pushover",
+ "quota_warning_bcc": "Quotum waarschuwing BCC",
+ "quota_warning_bcc_info": "Waarschuwingen zullen in afzonderlijke exemplaren naar de volgende ontvangers worden gestuurd. Het onderwerp zal worden gevolgd door de bijbehorende gebruikersnaam tussen haakjes, bijvoorbeeld: <code>Contingentwaarschuwing (user@example.com)</code>.",
+ "sogo_access": "Verleen directe logintoegang tot SOGo",
+ "sogo_access_info": "Na het inloggen wordt de gebruiker automatisch doorgestuurd naar SOGo"
},
"footer": {
"cancel": "Annuleren",
@@ -640,18 +767,21 @@
"restart_container": "Herstart container",
"restart_container_info": "<b>Belangrijk:</b> Een herstart kan enige tijd in beslag nemen, wacht aub totdat dit proces voltooid is.<br>Deze pagina zal zichzelf verversen zodra het proces voltooid is.",
"restart_now": "Nu herstarten",
- "restarting_container": "Container wordt herstart, even geduld aub..."
+ "restarting_container": "Container wordt herstart, even geduld aub...",
+ "hibp_check": "Controleer tegen haveibeenpwned.com",
+ "nothing_selected": "Niets geselecteerd"
},
"header": {
"administration": "Configuratie & details",
"apps": "Apps",
- "debug": "Systeeminformatie",
+ "debug": "Informatie",
"email": "E-Mail",
"mailcow_config": "Beheer",
"quarantine": "Quarantaine",
"restart_netfilter": "Herstart netfilter",
"restart_sogo": "Herstart SOGo",
- "user_settings": "Gebruikersinstellingen"
+ "user_settings": "Gebruikersinstellingen",
+ "mailcow_system": "Systeem"
},
"info": {
"awaiting_tfa_confirmation": "In afwachting van tweefactorauthenticatie...",
@@ -663,9 +793,24 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Aanmelden",
"mobileconfig_info": "Log in als mailboxgebruiker om het Apple-verbindingsprofiel te downloaden.",
- "other_logins": "Meld aan met key",
+ "other_logins": "of aanmelden met",
"password": "Wachtwoord",
- "username": "Gebruikersnaam"
+ "username": "Gebruikersnaam",
+ "back_to_mailcow": "Terug naar mailcow",
+ "forgot_password": "> Wachtwoord vergeten?",
+ "invalid_pass_reset_token": "De reset-wachtwoordtoken is ongeldig of verlopen.<br>Vraag een nieuwe link voor het resetten van het wachtwoord aan.",
+ "login_linkstext": "Niet de juiste login?",
+ "login_usertext": "Log in als gebruiker",
+ "login_domainadmintext": "Login in als domeinbeheerder",
+ "login_admintext": "Log in als administrator",
+ "login_user": "Gebruikerslogin",
+ "login_dadmin": "Domeinbeheerder login",
+ "login_admin": "Administrator login",
+ "new_password": "Nieuw wachtwoord",
+ "new_password_confirm": "Bevestig nieuw wachtwoord",
+ "reset_password": "Herstel wachtwoord",
+ "request_reset_password": "Verzoek wachtwoord wijziging",
+ "email": "E-mailadres"
},
"mailbox": {
"action": "Handeling",
@@ -684,7 +829,7 @@
"add_tls_policy_map": "Voeg versleutelingsbeleid toe",
"address_rewriting": "Adresomleidingen",
"alias": "Alias",
- "alias_domain_alias_hint": "Aliassen worden <b>niet</b> automatisch toegepast op domeinaliassen. Aliasadres <code>alias@domein</code> dekt het adres <code>alias@alias-domein</code> <b>niet</b> (waarbij \"alias-domein\" een aliasdomein is voor \"domein\").<br>Gebruik een filter om mail te forwarden naar een externe mailbox (zie het tabje \"Filters\" of gebruik SOGo -> Doorsturen).",
+ "alias_domain_alias_hint": "Aliassen worden <b>niet</b> automatisch toegepast op domeinaliassen. Aliasadres <code>alias@domein</code> dekt het adres <code>alias@alias-domein</code> <b>niet</b> (waarbij \"alias-domein\" een aliasdomein is voor \"domein\").<br>Gebruik een filter om mail door te sturen naar een externe mailbox (zie het tabje \"Filters\" of gebruik SOGo -> Doorsturen).",
"alias_domain_backupmx": "Aliasdomein inactief voor geforward domein",
"aliases": "Aliassen",
"allow_from_smtp": "Sta enkel de volgende IP-adressen toe voor <b>SMTP</b>",
@@ -694,7 +839,7 @@
"bcc": "BCC",
"bcc_destination": "BCC-bestemming",
"bcc_destinations": "BCC-bestemmingen",
- "bcc_info": "BCC-maps worden gebruikt om kopieën van alle berichten naar een ander adres te forwarden.<br>Wees er van bewust dat er geen melding wordt gedaan van een mislukte aflevering.",
+ "bcc_info": "BCC-maps worden gebruikt om kopieën van alle berichten naar een ander adres door te sturen.<br>Wees er van bewust dat er geen melding wordt gedaan van een mislukte aflevering.",
"bcc_local_dest": "Lokale bestemming",
"bcc_map": "BCC-map",
"bcc_map_type": "BCC-type",
@@ -767,7 +912,7 @@
"recipient_map": "Ontvanger-map",
"recipient_map_info": "Ontvanger-maps worden gebruikt om het doeladres van een bericht te vervangen voordat het in een mailbox terecht komt.",
"recipient_map_new": "Nieuwe ontvanger",
- "recipient_map_new_info": "De bestemming van een ontvanger-map dient een geldig mailadres te zijn.",
+ "recipient_map_new_info": "De bestemming van een ontvanger-map dient een geldig mailadres of domeinnaam te zijn.",
"recipient_map_old": "Oorspronkelijke ontvanger",
"recipient_map_old_info": "De oorspronkelijke bestemming van een ontvanger-map dient een geldig mailadres of domeinnaam te zijn.",
"recipient_maps": "Ontvanger-maps",
@@ -785,7 +930,7 @@
"sieve_preset_5": "Autoreply (vakantie)",
"sieve_preset_6": "Weiger mail met antwoord",
"sieve_preset_7": "Forward en behoud/verwijder",
- "sieve_preset_8": "Verwijder mail verstuurd naar een aliasadres van de afzender",
+ "sieve_preset_8": "E-mail van een specifieke afzender doorsturen, als gelezen markeren en in een submap plaatsen",
"sieve_preset_header": "Zie de onderstaande voorbeelden. Raadpleeg <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedia</a> voor meer informatie.",
"sogo_visible": "Alias tonen in SOGo",
"sogo_visible_n": "Verberg alias in SOGo",
@@ -812,7 +957,37 @@
"toggle_all": "Selecteer alles",
"username": "Gebruikersnaam",
"waiting": "Wachten",
- "weekly": "Wekelijks"
+ "weekly": "Wekelijks",
+ "add_alias_expand": "Alias uitbreiden over alias-domeinen",
+ "add_template": "Sjabloon toevoegen",
+ "all_domains": "Alle domeinen",
+ "catch_all": "Catch-All",
+ "created_on": "Aangemaakt op",
+ "domain_templates": "Domein sjablonen",
+ "domain_quota_total": "Totale domein-opslagruimte",
+ "goto_ham": "Leren als <b>Ham</b>",
+ "goto_spam": "Leren als <b>spam</b>",
+ "iam": "Identiteitsprovider",
+ "internal": "Intern",
+ "last_pw_change": "Laatste wachtwoordwijziging",
+ "mailbox_templates": "Mailbox sjablonen",
+ "no": "✕",
+ "open_logs": "Open logs",
+ "recipient": "Ontvanger",
+ "relay_unknown": "Onbekende mailboxen relayen",
+ "sender": "Afzender",
+ "syncjob_check_log": "Controleer log",
+ "syncjob_last_run_result": "Laatste uitvoeringsresultaat",
+ "syncjob_EX_OK": "Succes",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Verbindingsprobleem",
+ "syncjob_EXIT_TLS_FAILURE": "Probleem met versleutelde verbinding",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Authenticatieprobleem",
+ "syncjob_EXIT_OVERQUOTA": "Doel mailbox is over quota",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Kan geen verbinding maken met de externe server",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Verkeerde gebruikersnaam of wachtwoord",
+ "templates": "Sjablonen",
+ "template": "Sjabloon",
+ "yes": "✓"
},
"oauth2": {
"access_denied": "Log in als een mailboxgebruiker om toegang via OAuth te verlenen",
@@ -845,7 +1020,7 @@
"notified": "Verwittigd",
"qhandler_success": "Aanvraag succesvol verzonden naar het systeem. Je kunt nu het venster sluiten.",
"qid": "Rspamd QID",
- "qinfo": "Het quarantainesysteem slaat een kopie van zowel geweigerde mail (voor de afzender zal het lijken alsof de mail <em>niet</em> afgeleverd is), als mail die afgeleverd is de spamfolder, op in de database.\r\n <br>\"Markeer als spam en verwijder\" traint het systeem om soortgelijke mails in de toekomst opnieuw als spam te markeren.\r\n <br>Wanneer er meerdere berichten tegelijkertijd worden behandeld kan het mogelijk enige tijd duren.<br>Elementen op de blacklist zijn uitgesloten van de quarantaine.",
+ "qinfo": "Het quarantainesysteem slaat een kopie van zowel geweigerde mail (voor de afzender zal het lijken alsof de mail <em>niet</em> afgeleverd is), als mail die afgeleverd is de spamfolder, op in de database.\n <br>\"Markeer als spam en verwijder\" traint het systeem om soortgelijke mails in de toekomst opnieuw als spam te markeren.\n <br>Wanneer er meerdere berichten tegelijkertijd worden behandeld kan het mogelijk enige tijd duren.<br>Elementen op de denylist zijn uitgesloten van de quarantaine.",
"qitem": "Quarantaine-item",
"quarantine": "Quarantaine",
"quick_actions": "Handelingen",
@@ -877,13 +1052,23 @@
"toggle_all": "Selecteer alles"
},
"queue": {
- "queue_manager": "Queue manager"
+ "queue_manager": "Queue manager",
+ "delete": "Verwijder alles",
+ "flush": "Wachtrij leegmaken",
+ "info": "De mailwachtrij bevat alle e-mails die wachten op aflevering. Als een e-mail lange tijd in de mailwachtrij blijft staan, wordt deze automatisch door het systeem verwijderd.<br>De foutmelding van de betreffende e-mail geeft informatie over waarom de e-mail niet kon worden afgeleverd.",
+ "legend": "Functies voor acties in de mailwachtrij:",
+ "ays": "Bevestig dat u alle items uit de huidige wachtrij wilt verwijderen.",
+ "deliver_mail": "Afleveren",
+ "deliver_mail_legend": "Probeert de geselecteerde e-mails opnieuw te bezorgen.",
+ "hold_mail": "Vasthouden",
+ "hold_mail_legend": "Houdt de geselecteerde e-mails vast. (Voorkomt verdere afleverpogingen)",
+ "show_message": "Bericht weergeven",
+ "unban": "Wachtrij deblokkeren",
+ "unhold_mail": "Vrijgeven"
},
"start": {
"help": "Toon/verberg hulppaneel",
- "imap_smtp_server_auth_info": "Gebruik je volledige mailadres en het bijbehorende (onversleutelde) verificatiemechanisme.<br>De aanmeldgegevens worden versleuteld verzonden.",
- "mailcow_apps_detail": "Gebruik een Mailcow-app om je mails, agenda, contacten en meer te bekijken.",
- "mailcow_panel_detail": "<b>Domeinadministrators</b> kunnen mailboxen en aliassen aanmaken, wijzigen en verwijderen. Ook kunnen ze domeinen weergeven en aanpassen.<br><b>Gebruikers</b> kunnen tijdelijke aliassen aanmaken, hun wachtwoord aanpassen en de spamfilterinstellingen wijzigen."
+ "imap_smtp_server_auth_info": "Gebruik je volledige mailadres en het bijbehorende (onversleutelde) verificatiemechanisme.<br>De aanmeldgegevens worden versleuteld verzonden."
},
"success": {
"acl_saved": "Toegangscontrole voor object %s is opgeslagen",
@@ -999,7 +1184,8 @@
"start_fido2_validation": "Start FIDO2-validatie",
"fido2_auth": "Aanmelden met FIDO2",
"fido2_success": "Apparaat succesvol geregistreerd",
- "fido2_validation_failed": "Validatie mislukt"
+ "fido2_validation_failed": "Validatie mislukt",
+ "set_fido2_touchid": "Registreer Touch ID op Apple M1"
},
"user": {
"action": "Handeling",
@@ -1028,6 +1214,7 @@
"create_syncjob": "Voeg sync job toe",
"daily": "Dagelijks",
"day": "dag",
+ "description": "Beschrijving",
"delete_ays": "Bevestig de verwijdering.",
"direct_aliases": "Directe aliasadressen",
"direct_aliases_desc": "Directe aliasadressen worden beïnvloed door spamfilters en het versleutelingsbeleid.",
@@ -1165,6 +1352,7 @@
"loadingRecords": "Laden...",
"processing": "Wachten alstublieft..",
"search": "Zoeken:",
- "zeroRecords": "Geen overeenkomsten gevonden"
+ "zeroRecords": "Geen overeenkomsten gevonden",
+ "infoFiltered": "(gefilterd uit _MAX_ totale vermeldingen)"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.pl-pl.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.pl-pl.json
index aa185d3..de3557c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.pl-pl.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.pl-pl.json
@@ -1,49 +1,117 @@
{
"acl": {
- "sogo_profile_reset": "Usuń profil SOGo (webmail)",
- "syncjobs": "Polecenie synchronizacji",
- "alias_domains": "Dodaj aliasy domen"
+ "sogo_profile_reset": "Zresetuj profil SOGo",
+ "syncjobs": "Zadania doryczące synchronizacji kont",
+ "alias_domains": "Dodaj domeny aliasowe",
+ "delimiter_action": "Akcja oparta na separatorze",
+ "app_passwds": "Zarządzaj hasłami do aplikacji",
+ "bcc_maps": "Mapy BCC",
+ "domain_desc": "Zmień opis dotyczący domeny",
+ "domain_relayhost": "Zmień serwer przekazujący dla tej domeny",
+ "eas_reset": "Resetuj urządzenia EAS",
+ "extend_sender_acl": "Zezwalaj na rozszerzenie listy kontroli dostępu nadawców(ACL) o adresy zewnętrzne",
+ "filters": "Dostępne filtry",
+ "login_as": "Zaloguj się jako użytkownik poczty",
+ "mailbox_relayhost": "Zmień serwer pocztowy(relayhost) dla skrzynki pocztowej",
+ "prohibited": "Zakazane przez liste kontroli dostępu(ACL)",
+ "protocol_access": "Zmień dostęp do protokołów",
+ "pushover": "Pushover(powiadomienia push w czasie rzeczywistym)",
+ "pw_reset": "Zezwalaj na resetowanie hasła użytkownika mailcow",
+ "quarantine": "Akcje kwarantanny",
+ "quarantine_attachments": "Załączniki do kwarantanny",
+ "quarantine_category": "Zmień kategorię dotyczącą powiadomień o kwarantannie",
+ "quarantine_notification": "Zmień powiadomienia o kwarantannie",
+ "ratelimit": "Ograniczenie liczby zapytań",
+ "recipient_maps": "Mapy odbiorców",
+ "smtp_ip_access": "Zmiana dozwolonych hostów SMTP",
+ "sogo_access": "Zezwól na zarządzanie dostępem SOGo",
+ "spam_alias": "Tymczasowe aliasy",
+ "spam_policy": "Zablokowane adresy/Dozwolone adresy",
+ "spam_score": "Wskaźnik spam",
+ "tls_policy": "Polityka TLS",
+ "unlimited_quota": "Nieograniczony limit dla skrzynek pocztowych"
},
"add": {
"active": "Aktywny",
"add": "Dodaj",
- "alias_address": "Alias/y:",
+ "alias_address": "Alias/y",
"alias_address_info": "<small>Pełny/e adres/y email lub @example.com, aby przejąć wszystkie wiadomości dla domeny (oddzielone przecinkami). <b>tylko domeny mailcow</b>.</small>",
"alias_domain": "Alias domeny",
"alias_domain_info": "<small>Tylko prawidłowe nazwy domen (oddzielone przecinkami).</small>",
- "backup_mx_options": "Opcje Backup MX:",
+ "backup_mx_options": "Opcje Backup MX",
"delete1": "Usuń ze źródła po zakończeniu",
"delete2duplicates": "Usuń duplikaty w miejscu docelowym",
- "description": "Opis:",
+ "description": "Opis",
"domain": "Domena",
- "domain_quota_m": "Łączny limit domeny (MiB):",
+ "domain_quota_m": "Łączny limit domeny (MiB)",
"enc_method": "Metoda szyfrowania",
"exclude": "Wyklucz obiekty (regex)",
- "full_name": "Pełna nazwa:",
+ "full_name": "Pełna nazwa",
"hostname": "Nazwa hosta",
"kind": "Rodzaj",
- "mailbox_quota_m": "Maks. wielkość skrzynki (MiB):",
- "mailbox_username": "Nazwa użytkownika (lewa strona adresu email):",
- "max_aliases": "Maks. liczba aliasów:",
- "max_mailboxes": "Maks. liczba skrzynek:",
+ "mailbox_quota_m": "Maks. wielkość skrzynki (MiB)",
+ "mailbox_username": "Nazwa użytkownika (lewa strona adresu email)",
+ "max_aliases": "Maks. liczba aliasów",
+ "max_mailboxes": "Maks. liczba skrzynek",
"mins_interval": "Zakres pobierania (minuty)",
"multiple_bookings": "Wielokrotne rejestracje",
- "password": "Hasło:",
- "password_repeat": "Potwierdź hasło(powtórz):",
+ "password": "Hasło",
+ "password_repeat": "Potwierdź hasło(powtórz)",
"port": "Port",
- "post_domain_add": "Po dodaniu nowej domeny będziesz musiał ponownie uruchomić kontener serwisowy SOGo!",
- "quota_mb": "Limit wielkości (MiB):",
+ "post_domain_add": "Kontener SOGo, \"sogo-mailcow\", musi zostać ponownie uruchomiony po dodaniu nowej domeny!<br><br>Dodatkowo należy przejrzeć konfigurację DNS domeny. Po zatwierdzeniu konfiguracji DNS uruchom ponownie \"acme-mailcow\", aby automatycznie wygenerować certyfikaty dla nowej domeny (autoconfig.<domain>, autodiscover.<domain>).<br>Ten krok jest opcjonalny i będzie ponownie wykonywany co 24 godziny.",
+ "quota_mb": "Limit wielkości (MiB)",
"relay_all": "Przekaż wszystkim odbiorcom",
- "relay_all_info": "<small>Jeśli decydujesz się <b>nie</b> przekazywać wszystkim odbiorcom, musisz dodać (\"ślepą\")skrzynkę dla każdego poszczególnego odbiorcy, któremu należy przekazać.</small>",
+ "relay_all_info": "↪Jeśli wybierzesz <b>not</b>, aby przekazać wszystkich odbiorców, musisz dodać (\"ślepą\") skrzynkę pocztową dla każdego pojedynczego odbiorcy, która powinna być przekazywana.",
"relay_domain": "Domena przekaźnikowa",
"select": "Proszę wybrać...",
"select_domain": "Proszę najpierw wybrać domenę",
"syncjob": "Dodaj polecenie synchronizacji",
"syncjob_hint": "Pamiętaj, że hasła należy zapisywać w zwykłym tekście!",
- "target_address": "Adresy Idź do:",
+ "target_address": "Adresy Idź do",
"target_address_info": "<small> Pełny/e adres/y email (oddzielone przecinkami).</small>",
- "target_domain": "Domena docelowa:",
- "username": "Nazwa użytkownika"
+ "target_domain": "Domena docelowa",
+ "username": "Nazwa użytkownika",
+ "activate_filter_warn": "Wszystkie pozostałe filtry zostaną wyłączone, gdy opcja active zostanie zaznaczona.",
+ "add_domain_only": "Dodaj wyłącznie domene",
+ "add_domain_restart": "Dodaj domenę i uruchom ponownie SOGo",
+ "app_name": "Nazwa aplikacji",
+ "app_password": "Dodaj hasło do aplikacji",
+ "app_passwd_protocols": "Dozwolone protokoły dla hasła aplikacji",
+ "automap": "Spróbuj automatycznie mapować foldery (\"Wysłane elementy\", \"Wysłane\" => \"Wysłane\" itp.)",
+ "bcc_dest_format": "Miejscem docelowym BCC musi być jeden prawidłowy adres e-mail.<br>Jeśli chcesz wysłać kopię do wielu adresów, utwórz alias i użyj go tutaj.",
+ "comment_info": "Prywatny komentarz nie jest widoczny dla użytkownika, podczas gdy publiczny komentarz jest wyświetlany jako podpowiedź, które pojawia się, gdy użytkownik najedzie myszką nad elementem",
+ "custom_params": "Niestandardowe parametry",
+ "custom_params_hint": "Właściwa: --param=xy, błędna: --param xy",
+ "delete2": "Usuń wiadomości w miejscu docelowym, które nie znajdują się w źródle",
+ "destination": "Miejsce docelowe",
+ "disable_login": "Nie pozwalaj na logowanie(poczta przychodząca jest nadal akceptowana)",
+ "domain_matches_hostname": "Domena pasuje do nazwy hosta",
+ "dry": "Symulacja synchronizacji",
+ "gal": "Globalna lista adresów",
+ "gal_info": "GAL zawiera wszystkie obiekty domeny i nie może być edytowany przez żadnego użytkownika. Wolne/zajęte logi w SOGo bedą nidostępne, jeśli są wyłączone! <b>Uruchom ponownie SOGo, aby zastosować zmiany.</b>",
+ "generate": "generuj",
+ "goto_ham": "Ucz się jako <span class=\"text-success\"><b>ham</b></span>",
+ "goto_null": "Odrzucaj pocztę \"po cichu\"",
+ "goto_spam": "Ucz się jako <span class=\"text-danger\"><b>spam</b></span>",
+ "inactive": "Nieaktywny",
+ "internal": "Wewnętrzny",
+ "internal_info": "Aliasy wewnętrzne są dostępne tylko z domeny własnej lub domeny aliasów.",
+ "mailbox_quota_def": "Domyślny przydział skrzynki pocztowej",
+ "nexthop": "Następny hop",
+ "private_comment": "Prywatny komentarz",
+ "public_comment": "Komentarz publiczny",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div>Możesz transports maps dla niestandardowego miejsca docelowego dla tej domeny. Jeśli nie jest ustawiony, zostanie aktywowany lookup MX.",
+ "relay_unknown_only": "Przekaż tylko nieistniejące skrzynki pocztowe. Istniejące skrzynki pocztowe będą dostarczane lokalnie.",
+ "relayhost_wrapped_tls_info": "Proszę <b>nie</b> używać portów owiniętych TLS (głównie używanych na porcie 465).<br>\nUżyj dowolnego portu niezawiniętego i uruchom STARTTLS. Polityka TLS w celu egzekwowania TLS może być utworzona w \"mapie zasad TLS\".",
+ "sieve_desc": "Krótki opis",
+ "sieve_type": "Typ filtra",
+ "skipcrossduplicates": "Pomiń duplikaty wiadomości w folderach (na zasadzie kolejności zgłoszeń)",
+ "subscribeall": "Subskrybuj wszystkie foldery",
+ "tags": "Tagi",
+ "timeout1": "Limit czasu połączenia z hostem zdalnym",
+ "timeout2": "Limit czasu połączenia dla lokalnego hosta",
+ "validate": "Zatwierdź",
+ "validation_success": "Zatwierdzone z powodzeniem"
},
"admin": {
"access": "Dostęp",
@@ -71,7 +139,7 @@
"f2b_max_attempts": "Max. ilość prób",
"f2b_parameters": "Parametry Fail2ban",
"f2b_retry_window": "Spróbuj ponownie (s) dla max. ilości prób",
- "f2b_whitelist": "Biała lista sieci/hosty",
+ "f2b_whitelist": "Dozwolone sieci/hosty",
"filter_table": "Tabela filtru",
"forwarding_hosts": "Hosty przekazujące",
"forwarding_hosts_add_hint": "Możesz albo wyszczególnić adresy IPv4/IPv6, sieci w notacji CIDR, nazwy hostów (które zostaną rozłożone na adresy IP), albo nazwy domen (które zostaną rozłożone na adresy IP poprzez sprawdzanie rekordów SPF lub, w razie ich braku, rekordów MX).",
@@ -99,30 +167,274 @@
"spamfilter": "Filtr spamu",
"time": "Czas",
"unchanged_if_empty": "W przypadku braku zmian, nie wypełniaj",
- "username": "Nazwa użytkownika"
+ "username": "Nazwa użytkownika",
+ "activate_api": "Aktywuj API",
+ "activate_send": "Aktywuj przycisk wysyłania",
+ "active_rspamd_settings_map": "Aktywne ustawienia mapy",
+ "add_admin": "Dodaj administratora",
+ "add_relayhost": "Dodaj transport zależny od nadawcy",
+ "add_relayhost_hint": "Miej na uwadze, że dane uwierzytelniające, jeśli takie istnieją, będą przechowywane w postaci zwykłego tekstu.",
+ "add_row": "Dodaj wiersz",
+ "add_settings_rule": "Dodaj regułę ustawień",
+ "add_transport": "Dodaj transport",
+ "add_transports_hint": "Należy pamiętać, że dane uwierzytelniające, jeśli takie istnieją, będą przechowywane jako zwykły tekst.",
+ "additional_rows": " Dodano kolejne rzędy",
+ "admins": "Administratorzy",
+ "admins_ldap": "Administratorzy LDAP",
+ "admin_quicklink": "Ukryj szybki link do strony logowania administratora",
+ "advanced_settings": "Ustawienia zaawansowane",
+ "allowed_methods": "Dostęp-kontrola-zezwolenie-metody",
+ "allowed_origins": "Dostęp-Kontrola-Zezwolenia-Pochodzenie",
+ "api_allow_from": "Zezwalaj na dostęp API z tych notacji sieciowych IP/CIDR",
+ "api_info": "API jest w trakcie prac. Dokumentację można znaleźć pod adresem <a href=\"/api\">/api</a>",
+ "api_key": "klucz API",
+ "api_read_only": "Dostęp tylko do odczytu",
+ "api_read_write": "Dostęp do odczytu i zapisu",
+ "api_skip_ip_check": "Pomiń sprawdzenie IP dla API",
+ "app_hide": "Ukryj dla logowania",
+ "app_links": "Linki aplikacji",
+ "app_name": "Nazwa aplikacji",
+ "apps_name": "Nazwa \"aplikacji mailcow\"",
+ "arrival_time": "Czas serwera",
+ "authed_user": "Autoryzowany użytkownik",
+ "ays": "Jesteś pewien, że chcesz kontynuować?",
+ "ban_list_info": "Zobacz listę zakazanych adresów IP poniżej: <b>network (pozostały czas zakazu) - [działania]</b>.<br/>IP kolejkowane do odbanowania zostaną usunięte z listy aktywnych zakazów w ciągu kilku sekund.<br/>Czerwone etykiety wskazują aktywny stałe zakazy poprzez odmowę wpisu.",
+ "change_logo": "Zmień logo",
+ "logo_normal_label": "Normalna",
+ "logo_dark_label": "Odwrócony dla trybu ciemnego",
+ "convert_html_to_text": "Konwertuj HTML na zwykły tekst",
+ "copy_to_clipboard": "Tekst skopiowany do schowka!",
+ "cors_settings": "Ustawienia CORS",
+ "credentials_transport_warning": "<b>Ostrzeżenie</b>: Dodanie nowego wpisu mapy transportu spowoduje aktualizację danych uwierzytelniających dla wszystkich wpisów z pasującą kolumną hop.",
+ "customer_id": "Identyfikator klienta",
+ "customize": "Dostosuj",
+ "login_page": "Strona logowania",
+ "destination": "Miejsce docelowe",
+ "dkim_domains_selector": "Selektor",
+ "dkim_domains_wo_keys": "Wybierz domeny z brakującymi kluczami",
+ "dkim_from": "Od",
+ "dkim_from_title": "Domena źródłowa do kopiowania danych z",
+ "dkim_overwrite_key": "Nadpisanie istniejącego klucza DKIM",
+ "dkim_to": "Do",
+ "dkim_to_title": "Domeny docelowe - zostaną nadpisane",
+ "domain_admin": "Administrator domeny",
+ "domainadmin_quicklink": "Ukryj szybki link do strony logowania administratora domeny",
+ "domain_s": "Domena/y",
+ "duplicate": "Duplikat",
+ "duplicate_dkim": "Duplikat rekordu DKIM",
+ "excludes": "Wyklucza tych odbiorców",
+ "f2b_ban_time_increment": "Czas zakazu jest zwiększany z każdym zakazem",
+ "f2b_blacklist": "Lista odrzuconych sieci/hostów",
+ "f2b_filter": "Filtry Regex",
+ "f2b_list_info": "Odrzucony host lub sieć zawsze będzie przewyższać jednostkę zezwalającą.<b>Zastosowanie aktualizacji listy zajmie kilka sekund.</b>",
+ "f2b_manage_external": "Zarządzaj Fail2Ban zewnętrznie",
+ "f2b_manage_external_info": "Fail2ban nadal będzie utrzymywać listę banów, ale nie będzie aktywnie ustalać zasad blokowania ruchu. Użyj wygenerowane listy banów poniżej, aby zewnętrznie zablokować ruch.",
+ "f2b_max_ban_time": "Max. czas bana (s)",
+ "f2b_netban_ipv4": "Rozmiar podsieci IPv4 do zastosowania zakazu (8-32)",
+ "f2b_netban_ipv6": "Rozmiar podsieci IPv6 do zastosowania zakazu (8-128)",
+ "f2b_regex_info": "Logi brane pod uwagę: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "filter": "Filtr",
+ "force_sso_text": "Jeśli skonfigurowany jest zewnętrzny dostawca OIDC, ta opcja ukrywa domyślne formularze logowania mailcow i pokazuje tylko przycisk logowania pojedynczego",
+ "force_sso": "Wyłącz logowanie mailcow i pokaż tylko pojedyncze logowanie",
+ "from": "Od",
+ "generate": "Generuj",
+ "guid": "GUID - unikalny identyfikator instancji",
+ "guid_and_license": "GUID & licencja",
+ "hash_remove_info": "Usunięcie hasha z limitem współczynnika (jeśli nadal istnieje) spowoduje całkowite zresetowanie jego licznika.<br> Każdy hash jest oznaczony indywidualnym kolorem.",
+ "help_text": "Zastąp tekst pomocy poniżej maski logowania (dozwolone HTML)",
+ "html": "HTML",
+ "iam": "Dostawca tożsamości",
+ "iam_attribute_field": "Pole atrybutów",
+ "iam_authorize_url": "Punkt końcowy autoryzacji",
+ "iam_auth_flow": "Przepływ uwierzytelniania",
+ "iam_auth_flow_info": "Oprócz przepływu kodu autoryzacyjnego (Standardowy przepływ w Keycloak), który służy do logowania jednokrotnego logowania, mailcow obsługuje również przepływ uwierzytelniania z bezpośrednimi poświadczeniami. Mailpassword Flow próbuje zweryfikować dane uwierzytelniające użytkownika za pomocą Keycloak Admin REST API. mailcow pobiera hashowane hasło z atrybutu <code>mailcow_password</code>, który jest mapowany w Keycloak.",
+ "iam_basedn": "Baza DN",
+ "iam_client_id": "ID klienta",
+ "iam_client_secret": "Sekret klienta",
+ "iam_client_scopes": "Zakresy klientów",
+ "iam_default_template": "Domyślny szablon",
+ "iam_default_template_description": "Jeśli użytkownikowi nie zostanie przypisany żaden szablon, domyślny szablon zostanie użyty do utworzenia skrzynki pocztowej, ale nie do aktualizacji skrzynki pocztowej.",
+ "iam_description": "Skonfiguruj zewnętrznego dostawce uwierzytelniania<br>Skrzynki pocztowe użytkownika zostaną automatycznie utworzone przy pierwszym logowaniu, pod warunkiem, że zostało ustawione mapowanie atrybutów.",
+ "iam_extra_permission": "Aby następujące ustawienia działały, klient mailcow w Keycloak potrzebuje <code>konta serwisowego</code> oraz uprawnień do <code>podgląd-użytkowników</code>.",
+ "iam_host": "Host",
+ "iam_host_info": "Wprowadź jeden lub więcej hostów LDAP, oddzielonych przecinkami.",
+ "iam_import_users": "Zaimportuj użytkowników",
+ "iam_login_provisioning": "Automatyczne tworzenie użytkowników przy logowaniu",
+ "iam_mapping": "Mapowanie atrybutów",
+ "iam_bindpass": "Powiąż hasło",
+ "iam_periodic_full_sync": "Okresowa pełna synchronizacja",
+ "iam_port": "Port",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "Przekierowanie Url",
+ "iam_rest_flow": "Procedura uwierzytelniania hasła pocztowego",
+ "iam_server_url": "Adres URL serwera",
+ "iam_sso": "Pojedyncze logowanie",
+ "iam_sync_interval": "Interwał synchronizacji / importu (min)",
+ "iam_test_connection": "Test połączenia",
+ "iam_token_url": "Tokenowy punkt końcowy",
+ "iam_userinfo_url": "Endpoint informacji o użytkowniku",
+ "iam_username_field": "Pole nazwy użytkownika",
+ "iam_binddn": "Powiąź DN",
+ "iam_use_ssl": "Używaj SSL",
+ "iam_use_ssl_info": "Jeśli włączysz SSL, a port zostanie ustawiony na 389, zostanie automatycznie nadpisany, aby użyć 636.",
+ "iam_use_tls": "Używaj StartTLS",
+ "iam_use_tls_info": "Jeśli włączono TLS, należy użyć domyślnego portu dla serwera LDAP (389). Nie można używać portów SSL.",
+ "iam_version": "Wersja",
+ "ignore_ssl_error": "Ignoruj błędy SSL",
+ "in_use_by": "W użyciu przez",
+ "include_exclude": "Uwzględnij/Nie uwzględniaj",
+ "include_exclude_info": "Domyślnie - bez zaznaczenia - <b>wszystkie skrzynki pocztowe</b> są adresowane",
+ "includes": "Uwzględnij tych odbiorców",
+ "ip_check": "Sprawdź IP",
+ "ip_check_disabled": "Sprawdzenie IP jest wyłączone. Możesz go włączyć w obszarze <br> <strong>System > Konfiguracja > Opcje > Dostosuj</strong>",
+ "ip_check_opt_in": "Opt-In korzystania z usług stron trzecich <strong>ipv4.mailcow.email</strong> i <strong>ipv6.mailcow.email</strong> w celu rozwiązania zewnętrznych adresów IP.",
+ "is_mx_based": "Bazuje na MX",
+ "last_applied": "ostatnio zastosowany",
+ "license_info": "Licencja nie jest wymagana, ale pomaga w dalszym rozwoju.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Zarejestruj swój GUID tutaj</a> lub <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Zamówienie wsparcia\">kup wsparcie dla instalacji mailcow.</a>",
+ "link": "Link",
+ "login_time": "Cześć logowania",
+ "logo_info": "Twój obraz zostanie przeskalowany do wysokości 40px dla górnego paska nawigacyjnego i max. szerokości 250px dla strony startowej. Zalecana jest skalowalna grafika.",
+ "recipients": "Odbiorcy",
+ "send": "Wyślij",
+ "sender": "Nadawca",
+ "lookup_mx": "Destynacja jest regularnym wyrażeniem, które pasuje do nazwy MX (<code>.*\\\\.google\\.com</code>, aby przekierować całą pocztę skierowaną do MX kończącego się na google.com w tym hopie)",
+ "main_name": "Nazwa \"mailcow UI\"",
+ "merged_vars_hint": "Wyszarzone wiersze zostały połączone z <code>vars. (local.) inc.php</code> i nie można ich modyfikować.",
+ "message_size": "Rozmiar wiadomości",
+ "nexthop": "Następny hop",
+ "needs_restart": "potrzebny restart",
+ "no": "✕",
+ "no_active_bans": "Brak aktywnych banów",
+ "no_new_rows": "Brak dostępnych kolejnych wierszy",
+ "oauth2_apps": "Aplikacje OAuth2",
+ "oauth2_add_client": "Dodaj klienta OAuth2",
+ "oauth2_client_id": "ID klienta",
+ "oauth2_client_secret": "Sekret klienta",
+ "oauth2_info": "Implementacja OAuth2 obsługuje typ grantu \"Kod autoryzacji\" i wydaje tokeny odświeżania.<br>\nSerwer automatycznie wydaje również nowe tokeny odświeżania, po użyciu tokena odświeżania.<br><br>\n• Domyślnym zakresem jest <i>profil</i>. Tylko użytkownicy skrzynek pocztowych mogą być uwierzytelniani w OAuth2. Jeśli parametr zakresu zostanie pominięty, wraca do <i>profil</i>.<br>\n\nParametr <i>state</i> musi zostać wysłany przez klienta w ramach żądania autoryzacji.<br><br>>\nŚcieżki zapytań do API OAuth2: <br>\n<ul>\nPunkt końcowy autoryzacji\n<code>/oauth/authorize</code></li> <li>Token endpoint: <code>/oauth/token</code></li> <li>Resource page: <code>/oauth/profile</code></li>\n</ul>\nRegeneracja tajemnicy klienta nie spowoduje wygaśnięcia istniejących kodów autoryzacyjnych, ale nie odnowi ich tokena.<br><br>\nOdwołanie tokenów klienta spowoduje natychmiastowe zakończenie wszystkich aktywnych sesji. Wszyscy klienci muszą się ponownie uwierzytelnić.",
+ "oauth2_redirect_uri": "Przekieruj URI",
+ "oauth2_renew_secret": "Wygeneruj sekret nowego klienta",
+ "oauth2_revoke_tokens": "Unieważnij wszystkie tokeny klienta",
+ "optional": "Opcjonalny",
+ "options": "Opcje",
+ "password_length": "Długość hasła",
+ "password_policy": "Polityka haseł",
+ "password_policy_chars": "Musi zawierać co najmniej jeden znak alfabetyczny",
+ "password_policy_length": "Minimalna długość hasła to %d",
+ "password_policy_lowerupper": "Musi zawierać małe i duże litery",
+ "password_policy_numbers": "Musi zawierać co najmniej jeden numer",
+ "password_policy_special_chars": "Musi zawierać znaki specjalne",
+ "password_reset_info": "Jeśli nie jest udostępniony e-mail zapasowy, ta funkcja nie może być używana.",
+ "password_reset_settings": "Ustawienia odzyskiwania haseł",
+ "password_reset_tmpl_html": "Szablon HTML",
+ "password_reset_tmpl_text": "Szablon tekstu",
+ "password_settings": "Ustawienia hasła",
+ "quarantine_bcc": "Wyślij kopię wszystkich powiadomień (BCC) do tego odbiorcy: <br><small>Pozostaw pustą aby wyłączyć. <b>Niepodpisana, niezaznaczona poczta. Powinna być dostarczana tylko wewnętrznie.</b></small>",
+ "quarantine_exclude_domains": "Wyklucz domeny i domeny aliasowe",
+ "quarantine_max_age": "Maksymalny wiek w dniach <br><small>Wartość musi być równa lub większa niż 1 dzień.</small>",
+ "quarantine_max_score": "Odrzuć powiadomienie, jeśli wskaźnik spamu wiadomości jest wyższy niż ta wartość: <br><small>Domyślne do 9999.0</small>",
+ "quarantine_max_size": "Maksymalny rozmiar w MiB (większe elementy są odrzucane):<br><small>0 oznacza, że <b>nie</b> oznacza nieograniczony.</small>",
+ "quarantine_notification_html": "Szablon wiadomości e-mail z powiadomieniem:<br><small> Pozostaw puste, aby przywrócić szablon domyślny.</small>",
+ "quarantine_notification_sender": "Powiadomienie nadawcy wiadomości e-mail",
+ "quarantine_notification_subject": "Powiadomienie E-mail Temat",
+ "quarantine_redirect": "<b>Przekieruj wszystkie powiadomienia </b> do tego odbiorcy:<br><small> Pozostaw pusty aby wyłączyć. <b>Niepodpisana, niezaznaczona poczta. Powinny być dostarczane tylko wewnętrznie.</b></small>",
+ "quarantine_release_format": "Format zwolnionych przedmiotów",
+ "quarantine_release_format_att": "Jako załącznik",
+ "quarantine_release_format_raw": "Niezmodyfikowany oryginał",
+ "quarantine_retention_size": "Retencje na skrzynkę pocztową: <br><small>0 oznacza <b>nieaktywne</b>.</small>",
+ "quicklink_text": "Pokaż lub ukryj szybkie linki do innych stron logowania pod formularzem logowania",
+ "quota_notification_html": "Szablon wiadomości e-mail z powiadomieniem:<br><small> Pozostaw puste, aby przywrócić szablon domyślny.</small>",
+ "quota_notification_sender": "Powiadomienie nadawcy wiadomości e-mail",
+ "quota_notification_subject": "Temat powiadomienia e-mail",
+ "quota_notifications": "Powiadomienia o limitach",
+ "quota_notifications_info": "Powiadomienia o limktach są wysyłane do użytkowników raz przy przekroczaniu 80% i raz przy przekraczaniu 95% zużycia.",
+ "quota_notifications_vars": "{{percent}} równa się aktualnemu limitowi użytkownika<br>{{username}} jest nazwą skrzynki pocztowej",
+ "queue_unban": "Zdejmij bana",
+ "rate_name": "Nazwa oceny",
+ "regen_api_key": "Regeneruj klucz API",
+ "regex_maps": "Mapy Regex",
+ "relay_from": "\"Od:\" adres",
+ "relay_rcpt": "\"Do:\"Adres",
+ "relay_run": "Uruchom test",
+ "relayhosts": "Transporty zależne od nadawcy",
+ "relayhosts_hint": "Zdefiniuj transporty zależne od nadawcy, aby móc wybrać je w oknie dialogowym konfiguracji domeny.<br>\nUsługa transportu jest zawsze \"smtp:\" i dlatego uruchomj TLS, gdy będzie oferowana. Owinięty TLS (SMTPS) nie jest obsługiwany. Pod uwagę brane jest indywidualne ustawienie polityki wychodzącej TLS użytkownika.<br>\nDotyczy wybranych domen, w tym domen aliasowych.",
+ "remove_row": "Usuń wiersz",
+ "reset_default": "Zresetuj do ustawień domyślnych",
+ "reset_limit": "Usuń hash",
+ "reset_password_vars": "<code>{{link}}</code> Wygenerowany link do resetu hasła <br><code>{{username}}</code> Nazwa skrzynki pocztowej użytkownika, który poprosił o zresetowanie hasła<br><code>{{username2}}</code> Nazwa skrzynki pocztowej do odzyskiwania <br><code>{{date}}</code> Data złożenia żądania resetowania hasła<br><code>{{token_lifetime}}</code>Żywotność tokena w minutach<br><code>{{hostname}}</code> Nazwa hosta mailcow",
+ "restore_template": "Pozostaw puste, aby przywrócić szablon domyślny.",
+ "routing": "Routowanie",
+ "rsetting_add_rule": "Dodaj regułę",
+ "rsetting_content": "Zawartość reguły",
+ "rsetting_desc": "Krótki opis",
+ "rsetting_no_selection": "Proszę zaznaczyć regułę",
+ "rsetting_none": "Brak dostępnych reguł",
+ "rsettings_insert_preset": "Wstaw przykładowy preset",
+ "rsettings_preset_1": "Wyłącz wszystkie z wyjątkiem DKIM i limitu stawek dla uwierzytelnionych użytkowników",
+ "rsettings_preset_2": "Administratorzy poczty pozwalają na spam",
+ "rsettings_preset_3": "Zezwalaj tylko określonym nadawcom na skrzynkę pocztową (tj. używaj tylko jako wewnętrznej skrzynki pocztowej)",
+ "rsettings_preset_4": "Wyłącz Rspamd dla domeny",
+ "rspamd_com_settings": "Nazwa ustawienia zostanie automatycznie wygenerowana, zobacz przykładowe ustawienia wstępne poniżej. Aby uzyskać więcej informacji, zobacz <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd docs</a>",
+ "rspamd_global_filters": "Globalne mapy filtrów",
+ "rspamd_global_filters_agree": "Będę ostrożny!",
+ "rspamd_global_filters_info": "Globalne mapy filtrów zawierają różne rodzaje globalnych list dozwolonych i zablokowanych adresów.",
+ "rspamd_global_filters_regex": "Ich imiona wyjaśniają ich cel. Cała zawartość musi zawierać ważne wyrażenie regularne w formacie \"/pattern/options\" (e.g. <code>/.+@domain\\.tld/i</code>).<br>\nChociaż podstawowe kontrole są wykonywane na każdej linii regex, funkcja Rspamd może zostać złamana, jeśli nie odczyta poprawnie składni.<br>>\nRspamd po zmianie spróbuje odczytać zawartość mapy. Jeśli wystąpią problemy, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">restart Rspamd</a>, aby wymusić ponowne ładowanie mapy.<br> Elementy z listy odrzuconych są wyłączone z kwarantanny.",
+ "rspamd_settings_map": "Mapa ustawień Rspamd",
+ "sal_level": "Poziom Moo",
+ "service": "Usługa",
+ "service_id": "Id usługi",
+ "subject": "Temat",
+ "success": "Sukces",
+ "sys_mails": "Maile systemowe",
+ "task": "Zadanie",
+ "text": "Tekst",
+ "title": "Tytuł",
+ "title_name": "Tytuł strony internetowej \"mailcow UI\"",
+ "to_top": "Powrót na górę",
+ "transport_dest_format": "Regex lub syntax: example.org, .example.org, *, box@example.org(wiele wartości można rozdzielić przecinkami)",
+ "transport_maps": "Mapy transportu",
+ "transport_test_rcpt_info": "• Użyj null@hosted.mailcow.de aby przetestować przekazywanie do nieznanego miejsca docelowego.",
+ "transports_hint": "• Wpis mapy transportowej <b>overrules</b> mapa transportowa zależna od nadawcy</b>.<br>\nNajlepiej stosować transporty oparte na MX •.<br>\nUstawienia zasad Outbound TLS dotyczące użytkownika są ignorowane i mogą być egzekwowane tylko przez wpisy mapy zasad TLS\n• Usługa transportu dla zdefiniowanych transportów jest zawsze \"smtp:\" i dlatego uruchomi TLS, gdy będzie oferowana. Wrapped TLS (SMTPS) nie jest obsługiwany.<br>\nAdresy pasujące do \"/localhost$/\" będą zawsze transportowane przez \"lokalne:\", dlatego miejsce docelowe \"*\" nie będzie miało zastosowania do tych adresów.<br>\n• Aby określić poświadczenia dla przykładowego następnego hopa \"[host]:25\", Postfix <b>zawsze</b> kolejkuje zapytania o \"host\" przed wyszukaniem \"[host]:25\". Takie zachowanie uniemożliwia jednoczesne użycie \"host\" i \"[host]:25.",
+ "ui_footer": "Stopka (dozwolone HTML)",
+ "ui_header_announcement": "Ogłoszenia",
+ "ui_header_announcement_active": "Ustaw ogłoszenie jako aktywne",
+ "ui_header_announcement_content": "Tekst (dozwolony HTML)",
+ "ui_header_announcement_help": "Ogłoszenie jest widoczne dla wszystkich zalogowanych użytkowników oraz na ekranie logowania interfejsu użytkownika.",
+ "ui_header_announcement_select": "Wybierz typ ogłoszenia",
+ "ui_header_announcement_type": "Typ",
+ "ui_header_announcement_type_danger": "Bardzo ważne",
+ "ui_header_announcement_type_info": "Info",
+ "ui_header_announcement_type_warning": "Ważne",
+ "ui_texts": "Etykiety i teksty UI",
+ "unban_pending": "oczekuje na odblokowanie",
+ "upload": "Prześlij",
+ "user_link": "Link użytkownika",
+ "user_quicklink": "Ukryj Quicklink do strony logowania użytkownika",
+ "validate_license_now": "Sprawdź identyfikator GUID względem serwera licencji",
+ "verify": "Zweryfikuj",
+ "yes": "✓"
},
"danger": {
"access_denied": "Odmowa dostępu lub nieprawidłowe dane w formularzu",
"alias_domain_invalid": "Alias domeny nieprawidłowy",
"alias_empty": "Alias nie może być pusty",
"alias_goto_identical": "Alias i Idź do nie mogą być identyczne",
- "alias_invalid": "Alias nieprawidłowy",
+ "alias_invalid": "Adres aliasu jest nieprawidłowy",
"aliasd_targetd_identical": "Alias domeny nie może być identyczny z domeną docelową",
"aliases_in_use": "Maks. liczba aliasów musi być większa od lub równa %d",
"description_invalid": "Nieprawidłowy opis źródła",
"dkim_domain_or_sel_invalid": "Nieprawidłowa domena lub selektor DKIM",
- "domain_exists": "Domena %s już istnieje",
- "domain_invalid": "Błędna nazwa domeny",
+ "domain_exists": "Domena już istnieje",
+ "domain_invalid": "Nazwa domeny jest pusta lub nieprawidłowa",
"domain_not_empty": "Nie można usunąć niepustej domeny",
- "domain_not_found": "Nie znaleziono domeny %s",
- "domain_quota_m_in_use": "Limit domeny %s MiB",
- "goto_empty": "Adres Idź do nie może być pusty",
+ "domain_not_found": "Nie znaleziono domeny",
+ "domain_quota_m_in_use": "Limit domeny musi być większy lub równy do MiB",
+ "goto_empty": "Adres alias musi zawierać co najmniej jeden prawidłowy adres goto",
"goto_invalid": "Adres Idź do jest nieprawidłowy",
- "is_alias": "%s został już podany jako alias",
- "is_alias_or_mailbox": "%s podano wcześniej jako alias lub skrzynkę",
- "is_spam_alias": "%s podano wcześniej jako alias dla spam",
- "last_key": "Nie można usunąć ostatniego klucza",
- "login_failed": "Niepowodzenie logowania",
+ "is_alias": "został już podany jako alias",
+ "is_alias_or_mailbox": "jest już znany jako alias, skrzynka pocztowa lub adres aliasu rozwinięty z domeny aliasu.",
+ "is_spam_alias": "jest już znany jako tymczasowy adres aliasu (adres aliasu antyspamowego)",
+ "last_key": "Nie można usunąć ostatniego klucza, zamiast tego należy wyłączyć TFA.",
+ "login_failed": "Logowanie nie powiodło się",
"mailbox_invalid": "Nieprawidłowa nazwa skrzynki",
"mailbox_quota_exceeded": "Wielkość przekracza limit domeny (maks. %d MiB)",
"mailbox_quota_exceeds_domain_quota": "Maksymalna wielkość przekracza limit domeny",
@@ -144,8 +456,107 @@
"sender_acl_invalid": "ACL Nadawcy jest nieprawidłowy",
"target_domain_invalid": "Domena Idź do jest nieprawidłowa",
"targetd_not_found": "Nie znaleziono domeny docelowej",
- "username_invalid": "Nie można użyć nazwy użytkownika",
- "validity_missing": "Proszę wyznaczyć termin ważności"
+ "username_invalid": "Nie można użyć tej nazwy użytkownika",
+ "validity_missing": "Proszę wyznaczyć termin ważności",
+ "to_invalid": "Pole odbiorca nie może być puste",
+ "app_name_empty": "Nazwa aplikacji nie może być pusta",
+ "app_passwd_id_invalid": "Identyfikator hasła aplikacji jest niepoprawny",
+ "authsource_in_use": "Nie można zmienić ani usunąć dostawcy tożsamości, ponieważ jest używany przez co najmniej jednego użytkownika.",
+ "bcc_empty": "Miejsce docelowe BCC nie może być puste",
+ "bcc_exists": "Mapa BCC istnieje już dla tego typu",
+ "bcc_must_be_email": "Miejsce docelowe BCC nie jest prawidłowym adresem e-mail",
+ "comment_too_long": "Komentarz zbyt długi, maksymalnie 160 dozwolonych znaków",
+ "cors_invalid_method": "Podano nieprawidłową metodę Allow-Method",
+ "cors_invalid_origin": "Podano nieprawidłową wartość Allow-Origin",
+ "defquota_empty": "Domyślny limit skrzynki pocztowej nie może wynosić 0.",
+ "demo_mode_enabled": "Tryb demo jest włączony",
+ "dkim_domain_or_sel_exists": "Klucz DKIM już istnieje i nie zostanie nadpisany",
+ "domain_cannot_match_hostname": "Domena nie może być taka sama jak nazwa hosta",
+ "extended_sender_acl_denied": "brak ACL do ustawiania adresów nadawcy zewnętrznego",
+ "extra_acl_invalid": "Adres nadawcy zewnętrznego jest nieprawidłowy",
+ "extra_acl_invalid_domain": "Nadawca zewnętrzny używa nieprawidłowej domeny",
+ "fido2_verification_failed": "Weryfikacja FIDO2 nie powiodła się",
+ "file_open_error": "Nie można otworzyć pliku do zapisu",
+ "filter_type": "Niewłaściwy typ filtra",
+ "from_invalid": "Nadawca nie może być pusty",
+ "generic_server_error": "Wystąpił nieoczekiwany błąd serwera. Skontaktuj się z administratorem.",
+ "global_filter_write_error": "Nie można zapisać pliku filtra",
+ "global_map_invalid": "Id mapy globalnej nieprawidłowe",
+ "global_map_write_error": "Nie można zapisać globalnej mapy ID",
+ "ham_learn_error": "Błąd uczenia ham",
+ "iam_test_connection": "Połączenie nie powiodło się",
+ "imagick_exception": "Błąd: wyjątek Imagick podczas odczytu obrazu",
+ "img_dimensions_exceeded": "Obraz przekracza maksymalny rozmiar obrazu",
+ "img_invalid": "Nie można zweryfikować pliku obrazu",
+ "img_size_exceeded": "Obraz przekracza maksymalny rozmiar pliku",
+ "img_tmp_missing": "Nie można zweryfikować pliku obrazu: Nie znaleziono pliku tymczasowego",
+ "invalid_bcc_map_type": "Nieprawidłowy typ mapy BCC",
+ "invalid_destination": "Format docelowy jest nieprawidłowy",
+ "invalid_filter_type": "Nieprawidłowy typ filtra",
+ "invalid_host": "Nieprawidłowy określony host",
+ "invalid_mime_type": "Niepoprawny typ mime",
+ "invalid_nexthop": "Następny format hop jest nieprawidłowy",
+ "invalid_nexthop_authenticated": "Następny hop już istnieje z innymi danymi logowania, zaktualizuj najpierw istniejące dane uwierzytelniające dla tego hopa.",
+ "invalid_recipient_map_new": "Określony nieprawidłowy nowy odbiorca",
+ "invalid_recipient_map_old": "Określony nieprawidłowy pierwotny odbiorca",
+ "invalid_reset_token": "Nieprawidłowy token resetu",
+ "ip_list_empty": "Lista dozwolonych adresów IP nie może być pusta",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "Domyślny limit skrzynki pocztowej przekracza maksymalny dozwolony limit",
+ "malformed_username": "Nieprawidłowy format nazwy użytkownika",
+ "map_content_empty": "Zawartość mapy nie może być pusta",
+ "max_age_invalid": "Nieprawidłowa wartość maksymalnego wieku: %s",
+ "mode_invalid": "Tryb %s jest nieprawidłowy",
+ "mx_invalid": "Rekord MX %s jest nieprawidłowy",
+ "mysql_error": "Błąd MySQL: %s",
+ "network_host_invalid": "Nieprawidłowa sieć lub host: %s",
+ "next_hop_interferes": "%s powoduje konflikt z nexthopem %s",
+ "next_hop_interferes_any": "Istniejący next hop koliduje z %s.”",
+ "nginx_reload_failed": "Nie udało się przeładować Nginx: %s",
+ "no_user_defined": "Brak zdefiniowanego użytkownika",
+ "password_reset_invalid_user": "Skrzynka pocztowa nie została znaleziona lub nie ustawiono adresu e-mail do odzyskiwania",
+ "password_reset_na": "Odzyskiwanie hasła jest obecnie niedostępne. Skontaktuj się ze swoim administratorem.",
+ "private_key_error": "Błąd klucza prywatnego: %s",
+ "pushover_credentials_missing": "Brak tokena i/lub klucza Pushover",
+ "pushover_key": "Klucz Pushover ma niewłaściwy format",
+ "pushover_token": "Token Pushover ma zły format",
+ "recipient_map_entry_exists": "Istnieje wpis mapy odbiorcy \"%s",
+ "recovery_email_failed": "Nie można wysłać e-maila odzyskiwania. Skontaktuj się ze swoim administratorem.",
+ "redis_error": "Błąd Redis: %s",
+ "relayhost_invalid": "Wpis mapy %s jest niepoprawny",
+ "release_send_failed": "Nie udało się zwolnić wiadomości: %s",
+ "required_data_missing": "Brakuje wymaganych danych %s",
+ "reset_f2b_regex": "Filtr Regex nie mógł zostać zresetowany na czas, spróbuj ponownie lub poczekaj jeszcze kilka sekund i przeładuj stronę.",
+ "reset_token_limit_exceeded": "Limit tokenów Reset został przekroczony. Spróbuj ponownie później.",
+ "rl_timeframe": "Nieprawidłowo ustawiony przedział czasu limitu",
+ "rspamd_ui_pw_length": "Hasło do Rspamd UI powinno mieć co najmniej 6 znaków długości",
+ "script_empty": "Skrypt nie może być pusty",
+ "set_acl_failed": "Nie udało się ustawić ACL",
+ "settings_map_invalid": "Ustawienia id mapy %s są nieprawidłowe",
+ "sieve_error": "Błąd podczas analizy skryptu Sieve: %s",
+ "spam_learn_error": "Błąd uczenia spamu: %s",
+ "subject_empty": "Temat nie może być pusty",
+ "targetd_relay_domain": "Domena docelowa %s jest skonfigurowana jako domena przekazująca relay",
+ "template_exists": "Szablon %s już istnieje",
+ "template_id_invalid": "Identyfikator szablonu %s niepoprawny",
+ "template_name_invalid": "Nazwa szablonu niepoprawna",
+ "temp_error": "Tymczasowy błąd",
+ "text_empty": "Pole tekstowe nie może być puste",
+ "tfa_token_invalid": "Niepoprawny token TFA",
+ "tls_policy_map_dest_invalid": "Podano błędne lub nieobsługiwane miejsce docelowe dla tej polityki",
+ "tls_policy_map_entry_exists": "Istnieje mapa polityki TLS \"%s",
+ "tls_policy_map_parameter_invalid": "Parametr polityki jest nieprawidłowy",
+ "totp_verification_failed": "Weryfikacja TOTP nie powiodła się",
+ "transport_dest_exists": "Miejsce docelowe transportu „%s” już istnieje",
+ "webauthn_verification_failed": "Weryfikacja WebAuthn nie powiodła się: %s",
+ "webauthn_authenticator_failed": "Wybrany autoryzator nie został odnaleziony",
+ "webauthn_publickey_failed": "Nie przechowywano klucza publicznego dla wybranego uwierzytelniacza",
+ "webauthn_username_failed": "Wybrany autoryzator należy do innego konta",
+ "unknown": "Wystąpił nieznany błąd",
+ "unknown_tfa_method": "Nieznana metodą TFA",
+ "unlimited_quota_acl": "Ustawienie nieograniczonego limitu przestrzeni jest zabronione przez reguły ACL",
+ "value_missing": "Proszę o podanie wszystkich wartości",
+ "version_invalid": "Wersja %s jest niepoprawna",
+ "yotp_verification_failed": "Weryfikacja OTP Yubico nie powiodła się: %s"
},
"edit": {
"active": "Aktywny",
@@ -178,7 +589,7 @@
"previous": "Poprzednia strona",
"quota_mb": "Limit wielkośći (MiB)",
"relay_all": "Przekaż wszystkim odbiorcom",
- "relay_all_info": "<small>Jeśli decydujesz się <b>nie</b> przekazywać wszystkim odbiorcom, musisz dodać (\"ślepą\")skrzynkę dla każdego poszczególnego odbiorcy, któremu należy przekazać.</small>",
+ "relay_all_info": "↪ Jeśli zdecydujesz się <b>nie</b> przekazywać wszystkim odbiorcom, musisz dodać (\"ślepą\")skrzynkę dla każdego poszczególnego odbiorcy, któremu należy przekazać.",
"relay_domain": "Domena przekaźnikowa",
"remove": "Usuń",
"resource": "Zasób",
@@ -190,15 +601,127 @@
"target_domain": "Domena docelowa",
"title": "Edytuj obiekt",
"unchanged_if_empty": "Jeżli bez zmian, nie wypełniaj",
- "username": "Nazwa użytkownika"
+ "username": "Nazwa użytkownika",
+ "delete_ays": "Proszę o potwierdzenie procesu usuwania.",
+ "acl": "ACL (Pozwolenie)",
+ "admin": "Edytyj administratora",
+ "advanced_settings": "Ustawienia zaawansowane",
+ "allow_from_smtp": "Zezwalaj tylko tym adresom IP na używanie <b>SMTP</b>",
+ "allow_from_smtp_info": "Pozostaw puste, aby zezwolić na wszystkich nadawców.<br>adresy IPv4/IPv6 i sieci.",
+ "allowed_protocols": "Dozwolone protokoły dla bezpośredniego dostępu użytkownika (nie wpływa na protokoły haseł aplikacji)",
+ "app_name": "Nazwa aplikacji",
+ "app_passwd": "Hasło do aplikacji",
+ "app_passwd_protocols": "Dozwolone protokoły dla hasła aplikacji",
+ "automap": "Spróbuj automatycznie mapować foldery (np. „Sent items”, „Sent” ⇒ „Sent” itp.)",
+ "bcc_dest_format": "Miejscem docelowym BCC musi być jeden prawidłowy adres e-mail.<br>Jeśli chcesz wysłać kopię na wiele adresów, utwórz alias i użyj go tutaj.",
+ "client_id": "Id klienta",
+ "client_secret": "Tajny klucz klienta(sekret)",
+ "comment_info": "Komentarz prywatny nie jest widoczny dla użytkownika, natomiast komentarz publiczny jest wyświetlany jako podpowiedź po najechaniu kursorem w widoku użytkownika",
+ "created_on": "Stworzony na",
+ "custom_attributes": "Niestandardowe atrybuty",
+ "delete2": "Usuń wiadomości na koncie docelowym, które nie występują na koncie źródłowym",
+ "disable_login": "Zablokuj logowanie (przychodząca poczta nadal będzie przyjmowana)",
+ "domain_footer": "Stopka dla całej domeny",
+ "domain_footer_html": "Stopka HTML",
+ "domain_footer_info": "Stopki dla całej domeny są dodawane do wszystkich wychodzących wiadomości e-mail powiązanych z adresami w tej domenie.<br>W stopce można użyć następujących zmiennych:",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - Uwierzytelniona nazwa użytkownika określona przez MTA",
+ "from_user": "{= from_user =} – część użytkownika (local-part) adresu nadawcy; np. dla „moo@mailcow.tld\n” zwróci „moo”",
+ "from_name": "{= from_name =} – nazwa nadawcy (From name) z nagłówka wiadomości; np. dla \"Mailcow <moo@mailcow.tld>\" zwróci \"Mailcow\"",
+ "from_addr": "{= from_addr =} – pełny adres nadawcy (z części envelope)",
+ "from_domain": "{= from_domain =} – część domenowa adresu nadawcy (z envelope)",
+ "custom": "{= foo =} - jeśli skrzynka pocztowa ma niestandardowy atrybut „foo” o wartości „bar”, zwraca „bar”"
+ },
+ "domain_footer_plain": "Stopka w formacie tekstowym(PLAIN)",
+ "domain_footer_skip_replies": "Nie dodawaj stopki do odpowiedzi na e-maile",
+ "extended_sender_acl": "Adresy nadawców zewnętrznych",
+ "extended_sender_acl_info": "Klucz DKIM dla domeny powinien zostać zaimportowany, jeśli jest dostępny.\nPamiętaj, aby dodać ten serwer do odpowiadającego rekordu SPF typu TXT.\nKiedy domena lub domena aliasu zostanie dodana do tego serwera i pokrywa się z zewnętrznym adresem, zewnętrzny adres zostanie usunięty.",
+ "force_pw_update": "Wymuszenie aktualizacji hasła przy następnym logowaniu",
+ "force_pw_update_info": "Ten użytkownik będzie mógł logować się wyłącznie tutaj %s. Hasła aplikacyjne pozostają aktywne.",
+ "footer_exclude": "Wyklucz ze stopki",
+ "gal": "Globalna lista adresowa",
+ "gal_info": "GAL zawiera wszystkie obiekty domeny i nie może być edytowana przez żadnego użytkownika. Informacje o dostępności (free/busy) w SOGo są niedostępne, jeśli funkcja jest wyłączona!<b>Uruchom ponownie SOGo, aby zastosować zmiany.</b>",
+ "generate": "generuj",
+ "grant_types": "Rodzaje grantów(Typy przyznawania dostępu)",
+ "internal": "Wewnętrzny",
+ "internal_info": "Aliasów wewnętrznych można używać tylko w obrębie własnej domeny lub domen aliasów.",
+ "last_modified": "Ostatnio modyfikowany",
+ "lookup_mx": "Destination to wyrażenie regularne dopasowujące nazwę serwera MX (np. <code>.*.google.com</code> — aby kierować całą pocztę wysyłaną do MX kończących się na google.com przez ten hop)",
+ "pushover_title": "Tytuł powiadomienia",
+ "pushover_sound": "Dźwięk powiadomienia",
+ "pushover_vars": "Gdy nie zdefiniowano żadnego filtra nadawcy, brane będą pod uwagę wszystkie wiadomości. Filtry oparte na wyrażeniach regularnych (regex) oraz dokładne dopasowania nadawców można definiować indywidualnie — będą one przetwarzane kolejno, niezależnie od siebie. Dostępne zmienne do użycia w treści i tytule (należy pamiętać o zasadach ochrony danych osobowych).",
+ "pushover_verify": "Zweryfikuj dane logowania",
+ "quota_warning_bcc": "Ukryta kopia ostrzeżenia o przekroczeniu limitu",
+ "quota_warning_bcc_info": "Ostrzeżenia będą wysyłane jako osobne kopie do poniższych odbiorców. Temat wiadomości zostanie rozszerzony o nazwę użytkownika w nawiasach, na przykład: <code>Ostrzeżenie o limicie (user@example.com\n)</code>.",
+ "ratelimit": "Limit wysyłania",
+ "redirect_uri": "Adres przekierowania / adres zwrotny (Redirect/Callback URL)",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Informacja</div> **Możesz zdefiniować mapy transportu (transport maps) dla niestandardowego miejsca docelowego tej domeny.** Jeśli nie zostanie to ustawione, zostanie wykonane wyszukiwanie",
+ "relay_unknown_only": "Przekazuj (relay) tylko nieistniejące skrzynki pocztowe. Istniejące skrzynki będą dostarczane lokalnie.",
+ "relayhost": "Transporty przypisane do nadawcy",
+ "scope": "Zakres",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Sprawdzanie nadawcy jest wyłączone</span>",
+ "sender_acl_info": "Jeżeli użytkownik skrzynki pocztowej A ma pozwolenie na wysyłkę jako użytkownik skrzynki B, adres nadawcy nie jest automatycznie wyświetlany jako opcja w polu „Od” w SOGo.<br>\nUżytkownik skrzynki B musi utworzyć delegację w SOGo, aby użytkownik A mógł wybrać ich adres jako nadawcę. Aby zdelegować skrzynkę w SOGo, użyj menu (trzy kropki) po prawej stronie nazwy skrzynki w lewym górnym rogu, będąc w widoku poczty. To zachowanie nie dotyczy adresów aliasów.",
+ "sieve_desc": "Krótki opis",
+ "sieve_type": "Typ filtra",
+ "skipcrossduplicates": "Pomijaj duplikaty wiadomości w różnych folderach (pierwsza napotkana wiadomość zostaje zachowana).",
+ "sogo_access": "Bezpośrednie przekazywanie do SOGo",
+ "sogo_access_info": "Po zalogowaniu użytkownik jest automatycznie przekierowywany do SOGo.",
+ "sogo_visible": "Alias jest widoczny w SOGO",
+ "sogo_visible_info": "Ta opcja dotyczy tylko obiektów, które mogą być wyświetlane w SOGo (aliasy współdzielone lub nie współdzielone, wskazujące przynajmniej na jedną lokalną skrzynkę).\nJeśli obiekt zostanie ukryty, alias nie będzie dostępny jako wybieralny nadawca w SOGo.",
+ "spam_alias": "Tworzenie lub zmiana ograniczonych czasowo adresów aliasów",
+ "spam_filter": "Filtr spam",
+ "spam_policy": "Dodaj lub usuń elementy z listy dozwolonych / zablokowanych",
+ "spam_score": "Ustaw własny poziom punktacji spamu",
+ "timeout1": "Limit czasu połączenia z serwerem zdalnym",
+ "timeout2": "Limit czasu połączenia z serwerem lokalnym",
+ "validate_save": "Zatwierdź i zapisz",
+ "pushover_info": "Ustawienia powiadomień push będą miały zastosowanie do wszystkich czystych (niespamowych) wiadomości dostarczanych do <b>%s</b> w tym aliasów (współdzielonych, niewspółdzielonych, oznaczonych).",
+ "mailbox_quota_def": "Domyślny limit skrzynki pocztowej",
+ "mailbox_relayhost_info": "Dotyczy wyłącznie skrzynki pocztowej i bezpośrednich aliasów, nadpisuje ustawienie serwera pośredniczącego (relayhost) dla domeny.",
+ "maxbytespersecond": "Max. Ilość bajtów na sekundę <br><small>(0 = unlimited)</small>",
+ "mailbox_rename": "Zmień nazwę skrzynki pocztowej",
+ "mailbox_rename_agree": "Stworzyłem kopię zapasową.",
+ "mailbox_rename_warning": "WAŻNE! Utwórz kopię zapasową przed zmianą nazwy skrzynki pocztowej.",
+ "mailbox_rename_alias": "Tworzenie aliasów automatycznie",
+ "mailbox_rename_title": "Nowa nazwa lokalnej skrzynki pocztowej",
+ "mbox_rl_info": "Ten limit szybkości dotyczy nazwy logowania SASL i odpowiada dowolnemu adresowi „from” używanemu przez zalogowanego użytkownika. Limit szybkości dla skrzynki pocztowej nadpisuje limit szybkości dla całej domeny.",
+ "nexthop": "Następny hop",
+ "private_comment": "Prywatny komentarz",
+ "public_comment": "Komentarz publiczny",
+ "mta_sts": "Konfiguruj MTA-STS",
+ "mta_sts_info": "<a\n\nhref='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> to standard wymuszający dostarczanie poczty elektronicznej pomiędzy serwerami pocztowymi z użyciem TLS oraz ważnych certyfikatów.\n\nJest stosowany wtedy, gdy użycie DANE nie jest możliwe z powodu braku lub nieobsługiwanego DNSSEC.\n\n<br><b>Uwaga</b>: Jeżeli domena odbiorcza obsługuje DANE z DNSSEC, DANE jest <b>zawsze</b> preferowane — MTA-STS działa wyłącznie jako mechanizm zapasowy.",
+ "mta_sts_version": "Wersja.",
+ "mta_sts_version_info": "Określa wersję standardu MTA-STS — obecnie jedyną prawidłową wartością jest <code>STSv1</code>..",
+ "mta_sts_mode": "Tryb.",
+ "mta_sts_mode_info": "Dostępne są trzy tryby do wyboru:\n<ul> <li><em>testing</em> – polityka jest wyłącznie monitorowana, a naruszenia nie mają wpływu na dostarczanie poczty.</li> <li><em>enforce</em> – polityka jest ściśle egzekwowana; połączenia bez ważnego TLS są odrzucane.</li> <li><em>none</em> – polityka jest publikowana, lecz nie jest stosowana.</li> </ul>.",
+ "mta_sts_max_age": "Maksymalny czas obowiązywania.",
+ "mta_sts_max_age_info": "Czas (w sekundach) przechowywania polityki w cache przez serwery odbierające..",
+ "mta_sts_mx": "serwer MX.",
+ "mta_sts_mx_info": "Umożliwia wysyłanie poczty wyłącznie do jawnie wymienionych nazw hostów serwerów pocztowych; wysyłający MTA sprawdza, czy nazwa hosta MX w DNS odpowiada liście z polityki, i zezwala na dostarczenie tylko przy użyciu ważnego certyfikatu TLS (ochrona przed atakami MITM)..",
+ "mta_sts_mx_notice": "Dopuszcza się podanie wielu serwerów MX, rozdzielonych przecinkami..",
+ "none_inherit": "Brak /Dziedzicz",
+ "password_recovery_email": "Email do odzyskiwania hasła",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Eskaluj wiadomości o wysokim priorytecie [<code>X-Priority: 1</code>]",
+ "pushover_only_x_prio": "Uwzględniaj wyłącznie wiadomości o wysokim priorytecie [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Uwzględniaj wyłącznie następujące adresy e-mail nadawców <small>(oddzielone przecinkami)</small>",
+ "pushover_sender_regex": "Bierz pod uwagę następujący regex nadawcy",
+ "pushover_text": "Tekst powiadomienia"
},
"footer": {
"cancel": "Anuluj",
"confirm_delete": "Potwierdź usunięcie",
"delete_now": "Usuń teraz",
- "delete_these_items": "Czy jesteś pewien, że chcesz usunąć następujące elementy?",
+ "delete_these_items": "Proszę potwierdzić zmiany w poniższym identyfikatorze obiektu",
"loading": "Proszę czekać...",
- "restart_now": "Uruchom ponownie teraz"
+ "restart_now": "Uruchom ponownie teraz",
+ "hibp_check": "Sprawdź w stosunku do haveibeenpwned.com",
+ "hibp_nok": "Dopasowano! To potencjalnie niebezpieczne hasło!",
+ "hibp_ok": "Nie znaleziono żadnego dopasowania.",
+ "nothing_selected": "Nic wybranego",
+ "restart_container": "Zresetuj kontener",
+ "restart_container_info": "<b>Ważne:</b> Łagodne ponowne uruchomienie może zająć trochę czasu — proszę poczekać na jego zakończenie.",
+ "restarting_container": "Ponowne uruchomienie kontenera, może to zająć trochę czasu"
},
"header": {
"administration": "Administrowanie",
@@ -206,16 +729,40 @@
"mailcow_config": "Konfiguracja",
"quarantine": "Kwarantanna",
"restart_sogo": "Uruchom ponownie SOGo",
- "user_settings": "Ustawienia użytkownika"
+ "user_settings": "Ustawienia użytkownika",
+ "apps": "Aplikacje",
+ "debug": "Informacja",
+ "mailcow_system": "System",
+ "restart_netfilter": "Uruchom ponownie netfilter"
},
"info": {
- "no_action": "Żadne działanie nie ma zastosowania"
+ "no_action": "Żadne działanie nie ma zastosowania",
+ "awaiting_tfa_confirmation": "Oczekiwanie na potwierdzenie TFA",
+ "session_expires": "Twoja sesja wygaśnie za około 15 sekund"
},
"login": {
"delayed": "Logowanie zostało opóźnione o %s sekund.",
"login": "Zaloguj się",
"password": "Hasło",
- "username": "Nazwa użytkownika"
+ "username": "Nazwa użytkownika",
+ "forgot_password": "Zapomniałeś hasła?",
+ "login_linkstext": "Login nieprawidłowy?",
+ "login_usertext": "Zaloguj się jako użytkownik",
+ "login_domainadmintext": "Zaloguj się jako administrator domeny",
+ "login_admintext": "Zaloguj się jako admin",
+ "other_logins": "lub zaloguj za pomocą",
+ "email": "Adres e-mail",
+ "back_to_mailcow": "Wróć do mailcow",
+ "fido2_webauthn": "Logowanie FIDO2/WebAuthn",
+ "invalid_pass_reset_token": "Token resetowania hasła jest nieprawidłowy lub wygasł.<br>Proszę poprosić o nowy link do resetowania hasła.",
+ "login_user": "Logowanie użytkownika",
+ "login_dadmin": "Logowanie administratora domeny",
+ "login_admin": "Login Administratora",
+ "mobileconfig_info": "Zaloguj się jako użytkownik skrzynki pocztowej, aby pobrać żądany profil połączenia Apple.",
+ "new_password": "Nowe hasło",
+ "new_password_confirm": "Potwierdź nowe hasło",
+ "reset_password": "Zresetuj hasło",
+ "request_reset_password": "Poproś o zmianę hasła"
},
"mailbox": {
"action": "Działanie",
@@ -275,7 +822,55 @@
"tls_enforce_out": "Uruchom TLS wychodzące",
"toggle_all": "Zaznacz wszystkie",
"username": "Nazwa użytkownika",
- "weekly": "Co tydzień"
+ "weekly": "Co tydzień",
+ "add_alias_expand": "Rozszerz alias na domeny alias",
+ "add_bcc_entry": "Dodaj mapę BCC",
+ "add_filter": "Dodaj filtr",
+ "recipient_map_old_info": "Mapa odbiorcy (pierwotne miejsce docelowe) musi być prawidłowym adresem e-mail lub nazwą domeny.",
+ "recipient_maps": "Mapy odbiorców",
+ "relay_unknown": "Przekazuj nieznane skrzynki pocztowe",
+ "running": "Uruchomione",
+ "sender": "Nadawca",
+ "set_postfilter": "Oznacz jako postfilter",
+ "set_prefilter": "Oznacz jako prefilter",
+ "sieve_info": "Możesz przechowywać wiele filtrów dla każdego użytkownika, jednak w danym momencie aktywny może być tylko jeden prefilter i jeden postfilter<br>\nKażdy filtr będzie przetwarzany w opisanej kolejności. Ani błędny skrypt, ani polecenie „keep;” nie zatrzymają przetwarzania kolejnych skryptów.\nZmiany w globalnych skryptach Sieve spowodują ponowne uruchomienie usługi Dovecot.<br><br>\nGlobalny prefiltr Sieve • Prefilter • Skrypty użytkownika • Postfilter • Globalny postfilter Sieve",
+ "sieve_preset_1": "Odrzuć pocztę z prawdopodobnymi niebezpiecznymi typami plików",
+ "sieve_preset_2": "Zawsze zaznaczaj e-mail konkretnego nadawcy jako odczytane",
+ "sieve_preset_3": "Odrzuć po cichu, zatrzymaj cały proces sieve",
+ "sieve_preset_4": "Plik do INBOX, pomiń dalszy proces przez filtry sieve",
+ "sieve_preset_5": "Automatyczna odpowiedź (urlopowa)",
+ "sieve_preset_6": "Odrzuć pocztę z odpowiedzią",
+ "sieve_preset_7": "Przekierowanie wiadomości z możliwością zachowania lub usunięcia kopii",
+ "sieve_preset_8": "Przekieruj wiadomość e-mail od określonego nadawcy, oznacz jako odczytaną i posortuj do podfoldera",
+ "sieve_preset_header": "Zbacz przykładowe ustawienia poniżej. Więcej szczegółów znajdziesz w <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedii</a>.",
+ "sogo_visible": "Alias jest widoczny w SOGo",
+ "sogo_visible_n": "Ukryj alias w SOGo",
+ "sogo_visible_y": "Pokaż alias w SOGo",
+ "stats": "Statystyki",
+ "status": "Status",
+ "syncjob_check_log": "Sprawdź log",
+ "syncjob_last_run_result": "Wynik ostatniego uruchomienia",
+ "syncjob_EX_OK": "Sukces",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Problem z połączeniem",
+ "syncjob_EXIT_TLS_FAILURE": "Problem z szyfrowanym połączeniem",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Problem uwierzytelniania",
+ "syncjob_EXIT_OVERQUOTA": "Docelowa skrzynka pocztowa przekroczyła limit pojemności",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Nie można połączyć się ze zdalnym serwerem",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Niewłaściwa nazwa użytkownika lub hasło",
+ "table_size": "Rozmiar tabeli",
+ "table_size_show_n": "Pokaż %s elementy",
+ "templates": "Szablony",
+ "template": "Szablon",
+ "tls_map_dest": "Miejsce docelowe",
+ "tls_map_dest_info": "Przykłady: example.org, .example.org, [mail.example.org]:25",
+ "tls_map_parameters": "Parametry",
+ "add_recipient_map_entry": "Dodaj mapę odbiorców",
+ "add_template": "Dodaj szablon",
+ "add_tls_policy_map": "Dodaj mapę polityk TLS",
+ "address_rewriting": "Przepisywanie adresów",
+ "alias_domain_alias_hint": "Aliasy <b>nie</b> są automatycznie stosowane do aliasów domen. Adres aliasu <code>my-alias@domain</code> <b>nie</b> obejmuje adresu <code>my-alias@alias-domain</code> (gdzie „alias-domain” jest przykładową domeną aliasową dla „domain”).\n<br> Aby przekierować pocztę do zewnętrznej skrzynki, użyj filtra Sieve (zob. kartę „Filtry” lub SOGo → Przekazywanie). Skorzystaj z opcji „Rozszerz alias na domeny aliasowe”, aby automatycznie dodać brakujące aliasy.",
+ "alias_domain_backupmx": "Domena aliasowa nieaktywna dla domeny przekaźnikowej",
+ "all_domains": "Wszystkie domeny"
},
"quarantine": {
"action": "Działanie",
@@ -283,23 +878,51 @@
"quarantine": "Kwarantanna",
"quick_actions": "Szybkie działania",
"remove": "Usuń",
- "toggle_all": "Zaznacz wszystkie"
+ "toggle_all": "Zaznacz wszystkie",
+ "confirm_delete": "Potwierdź usunięcie tego elementu.",
+ "learn_spam_delete": "Zapamiętaj jako spam i usuwaj w przyszłości",
+ "quick_delete_link": "Otwórz szybki link do usuwania",
+ "refresh": "Odśwież",
+ "rejected": "Odrzucony",
+ "release": "Zwolnij",
+ "release_body": "Dołączyliśmy Twoją wiadomość jako plik eml do tej wiadomości.",
+ "release_subject": "Potencjalnie szkodliwa pozycja kwarantanny %s",
+ "show_item": "Pokaż element",
+ "spam": "Spam",
+ "spam_score": "Wskaźnik",
+ "subj": "Temat",
+ "table_size": "Rozmiar tabeli",
+ "table_size_show_n": "Pokaż %s elementy",
+ "text_from_html_content": "Zawartość (przekonwertowany HTML)",
+ "text_plain_content": "Zawartość (tekst zwykły)",
+ "type": "Typ"
},
"queue": {
- "queue_manager": "Queue Manager"
+ "queue_manager": "Menedżer kolejki",
+ "delete": "Usuń wszystko",
+ "ays": "Potwierdź, że chcesz usunąć wszystkie elementy z bieżącej kolejki.",
+ "flush": "Opróżnij kolejkę wiadomości",
+ "info": "Kolejka poczty zawiera wszystkie wiadomości e-mail oczekujące na dostarczenie.\nJeśli wiadomość e-mail pozostaje w kolejce przez dłuższy czas, system automatycznie ją usuwa.<br>\nKomunikat błędu dla danej wiadomości zawiera informacje o przyczynie, dla której nie mogła zostać dostarczona.",
+ "legend": "Funkcje zarządzania kolejką poczty:",
+ "deliver_mail": "Dostarcz",
+ "deliver_mail_legend": "Próby ponownego dostarczenia wybranych wiadomości.",
+ "hold_mail": "Wstrzymane",
+ "hold_mail_legend": "Wstrzymuję wybrane maile. (Zapobiega dalszym próbom dostarczenia)",
+ "show_message": "Pokaż wiadomość",
+ "unban": "Usuń zablokowanie w kolejce",
+ "unhold_mail": "Zwolnij wiadomość",
+ "unhold_mail_legend": "Zwalnia wybrane wiadomości do dostarczenia (wymaga wcześniejszego wstrzymania)."
},
"start": {
"help": "Pokaż/Ukryj panel pomocy",
- "imap_smtp_server_auth_info": "Proszę korzystać z pełnego adresu email i mechanizmu uwierzytelniania PLAIN.<br>\r\nTwoje dane logowania zostaną zaszyfrowane przez obowiązkowe szyfrowanie po stronie serwera.",
- "mailcow_apps_detail": "Użyj aplikacji mailcow, aby mieć dostęp do wiadomości, kalendarza, kontaktów i innych.",
- "mailcow_panel_detail": "<b>Administratorzy domeny</b> tworzą, modyfikują lub usuwają skrzynki i aliasy, zmieniają domeny i czytają dalsze informacje o przypisanych im domenach.<br>\r\n\t<b>Użytkownicy skrzynek</b> mogą tworzyć ograniczone czasowo aliasy (aliasy spam), zmieniać swoje hasła i ustawienia filtru spam."
+ "imap_smtp_server_auth_info": "Proszę korzystać z pełnego adresu email i mechanizmu uwierzytelniania PLAIN.<br>\r\nTwoje dane logowania zostaną zaszyfrowane przez obowiązkowe szyfrowanie po stronie serwera."
},
"success": {
"admin_modified": "Zapisano zmiany w administratorze",
"alias_added": "Alias/y został/y dodany/e",
"alias_domain_removed": "Usunięto alias domeny %s",
"alias_modified": "Zapisano zmiany w aliasie/ach %s",
- "alias_removed": "Usunięto alias %s ",
+ "alias_removed": "Usunięto alias %s",
"aliasd_added": "Dodano alias domeny %s",
"aliasd_modified": "Zapisano zmiany w aliasie domeny %s",
"dkim_added": "Klucz DKIM został zapisany",
@@ -314,24 +937,85 @@
"f2b_modified": "Zmiany w Fail2ban zostały zapisane",
"forwarding_host_added": "Dodano hosta przekazującego %s",
"forwarding_host_removed": "Usunięto hosta przekazującego %s",
- "item_deleted": "",
- "items_deleted": "Item %s successfully deleted",
+ "item_deleted": "Element %s skutecznie usunięte",
+ "items_deleted": "Elementy %s skutecznie usunięte",
"mailbox_added": "Dodano skrzynkę %s",
"mailbox_modified": "Zapisano zmiany w skrzynce %s",
"mailbox_removed": "Usunięto skrzynkę %s",
"object_modified": "Zapisano zmiany w obiekcie %s",
"resource_added": "Dodano śródło %s",
"resource_modified": "Zapisano zmiany w skrzynce %s",
- "resource_removed": "Usunięto zasób %s"
+ "resource_removed": "Usunięto zasób %s",
+ "template_removed": "Szablon o identyfikatorze %s został usunięty.",
+ "tls_policy_map_entry_deleted": "Mapa polityki TLS o identyfikatorze %s została usunięta",
+ "tls_policy_map_entry_saved": "Wpis mapy polityki TLS \"%s\" został zapisany",
+ "ui_texts": "Zapisane zmiany w tekstach UI",
+ "upload_success": "Plik przesłany pomyślnie",
+ "verified_fido2_login": "Zweryfikowany login FIDO2",
+ "verified_totp_login": "Zweryfikowany login TOTP",
+ "verified_webauthn_login": "Zweryfikowany login WebAuthn",
+ "verified_yotp_login": "Zweryfikowany login Yubico OTP",
+ "acl_saved": "ACL dla obiektu %s zapisany",
+ "admin_added": "Administrator %s został dodany",
+ "admin_api_modified": "Zmiany w API zostały zapisane",
+ "admin_removed": "Administrator %s został usunięty",
+ "app_links": "Zapisane zmiany w linkach aplikacji",
+ "app_passwd_added": "Dodano nowe hasło aplikacji",
+ "app_passwd_removed": "Usunięto ID hasła aplikacji %s",
+ "bcc_deleted": "Wpisy map BCC usunięte: %s",
+ "bcc_edited": "Wpis mapy BCC %s edytowany",
+ "bcc_saved": "Wpis mapy BCC zapisany",
+ "cors_headers_edited": "Ustawienia CORS zostały zapisane",
+ "custom_login_modified": "Dostosowanie logowania zostało pomyślnie zapisane",
+ "db_init_complete": "Inicjalizacja bazy danych zakończona",
+ "delete_filter": "Filtry %s ID usunięte",
+ "delete_filters": "Usunięte filtry: %s",
+ "deleted_syncjob": "Usunięte syncjob ID %s",
+ "deleted_syncjobs": "Usunięte syncjobs: %s”.",
+ "domain_add_dkim_available": "Klucz DKIM już istniał",
+ "dkim_duplicated": "Klucz DKIM dla domeny %s został skopiowany do %s",
+ "domain_footer_modified": "Zmiany w stopce domeny %s zostały zapisane",
+ "dovecot_restart_success": "Dovecot został pomyślnie zrestartowany",
+ "f2b_banlist_refreshed": "ID listy banów został pomyślnie odświeżony.",
+ "global_filter_written": "Filtr został pomyślnie zapisany do pliku",
+ "hash_deleted": "Hash usunięty",
+ "iam_test_connection": "Połączenie powiodło się",
+ "ip_check_opt_in_modified": "Sprawdzenie adresu IP zostało pomyślnie zapisane",
+ "item_released": "Pozycja %s zwolniona",
+ "items_released": "Wybrane elementy zostały zwolnione",
+ "learned_ham": "Pomyślnie nauczono ID %s jako ham",
+ "license_modified": "Zmiany w licencji zostały zapisane",
+ "logged_in_as": "Zalogowany jako %s",
+ "mailbox_renamed": "Nazwa skrzynki pocztowej została zmieniona z %s na %s",
+ "nginx_reloaded": "Nginx został przeładowany",
+ "password_policy_saved": "Polityka haseł została pomyślnie zapisana",
+ "password_changed_success": "Hasło zostało pomyślnie zmienione",
+ "pushover_settings_edited": "Ustawienia Pushover pomyślnie ustawione, proszę zweryfikować dane uwierzytelniające.",
+ "qlearn_spam": "Identyfikator wiadomości %s został nauczony jako spam i usunięty",
+ "queue_command_success": "Polecenie kolejki zostało pomyślnie wykonane",
+ "recipient_map_entry_deleted": "Id mapy odbiorcy %s został usunięty",
+ "recipient_map_entry_saved": "Wpis mapy odbiorcy \"%s\" został zapisany",
+ "recovery_email_sent": "E-mail do odzyskiwania wysłany do %s",
+ "relayhost_added": "Wpis mapy %s został dodany",
+ "relayhost_removed": "Wpis mapy %s został usunięty",
+ "reset_main_logo": "Reset do domyślnego logo",
+ "rl_saved": "Limit szybkości dla obiektu %s został zapisany",
+ "rspamd_ui_pw_set": "Hasło do Rspamd UI pomyślnie ustawione",
+ "saved_settings": "Zapisane ustawienia",
+ "settings_map_added": "Dodano ustawienia (wpis mapy)",
+ "settings_map_removed": "Usunięte ustawienia mapy ID %s",
+ "sogo_profile_reset": "Profil SOGo dla użytkownika/ów został zresetowany",
+ "template_added": "Dodano szablon",
+ "template_modified": "Zmiany w szablonie/ach zostały zapisane"
},
"tfa": {
- "api_register": "%s używa Yubico Cloud API. Proszę pobrać klucz API dla Twojego klucza <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">here</a>",
+ "api_register": "%s używa Yubico Cloud API. Proszę pobrać klucz API dla Twojego klucza <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">tutaj</a>",
"confirm": "Potwierdź",
"confirm_totp_token": "Potwierdź zmiany przez wprowadzenie wygenerowanego tokenu",
"delete_tfa": "Wyłącz TFA",
"disable_tfa": "Wyłącz TFA do kolejnego udanego logowania",
"enter_qr_code": "Twój kod TOTP, jeśli Twoje urządzenie nie skanuje kodów QR.",
- "key_id": "Identyfikator dla Twojego YubiKey",
+ "key_id": "Identyfikator dla twojego urządzenia",
"key_id_totp": "Identyfikator dla Twojego klucza",
"none": "Deaktywuj",
"scan_qr_code": "Zeskanuj następujący kod aplikacją uwierzytelniającą lub wprowadź kod ręcznie.",
@@ -341,8 +1025,16 @@
"totp": "Time-based OTP (Google Authenticator itd.)",
"webauthn": "Uwierzytelnianie WebAuthn",
"waiting_usb_auth": "<i>Czekam na urządzenie USB...</i><br><br>Wciśnij teraz przycisk na urządzeniu WebAuthn USB.",
- "waiting_usb_register": "<i> Czekam na urządzenie USB...</i><br><br>Wprowadź swoje hasło powyżej i potwierdź rejestrację WebAuthn przez naciśnięcie przycisku na urządzeniu WebAuthn USB.",
- "yubi_otp": "Uwierzytelnianie Yubico OTP"
+ "waiting_usb_register": "<i> Czekam na urządzenie USB...</i><br><br>Wprowadź swoje hasło powyżej i potwierdź rejestrację przez naciśnięcie przycisku na urządzeniu USB.",
+ "yubi_otp": "Uwierzytelnianie Yubico OTP",
+ "authenticators": "Uwierzytelniacze",
+ "error_code": "Kod błędu",
+ "init_webauthn": "Inicjalizacja, proszę czekać...",
+ "reload_retry": "- (przeładuj przeglądarkę, jeśli błąd nadal występuje)",
+ "start_webauthn_validation": "Rozpocznij walidację",
+ "tfa_token_invalid": "Token TFA nieprawidłowy",
+ "u2f_deprecated": "Wygląda na to, że Twój klucz został zarejestrowany przy użyciu przestarzałej metody U2F. Dezaktywujemy dla Ciebie uwierzytelnianie dwuskładnikowe i usuniemy Twój klucz.",
+ "u2f_deprecated_important": "Zarejestruj swój klucz w panelu administracyjnym za pomocą nowej metody WebAuthn."
},
"user": {
"action": "Działanie",
@@ -363,6 +1055,7 @@
"create_syncjob": "Utwórz nowe polecenie synchronizacji",
"daily": "Co dzień",
"day": "Dzień",
+ "description": "Opis",
"direct_aliases": "Aliasy bezpośrednie",
"direct_aliases_desc": "Na aliasy bezpośrednie wpływają filtry spamu i ustawienia TLS.",
"eas_reset": "Zresetuj pamięć podręczną urządzenia ActiveSync",
@@ -371,7 +1064,7 @@
"edit": "Edytuj",
"encryption": "Szyfrowanie",
"excludes": "Wyłączenia",
- "force_pw_update": "<b>Musisz</b> zmienić hasło, aby używać webmaila.",
+ "force_pw_update": "<b>Musisz</b> ustawić nowe hasło, aby mieć dostęp do usług groupware.",
"hour": "Godzina",
"hourly": "Co godzinę",
"hours": "Godziny",
@@ -379,7 +1072,7 @@
"interval": "Zakres",
"is_catch_all": "Funkcja catch-all dla domen/y",
"last_run": "Ostatnie uruchomienie",
- "mailbox_details": " Szczegóły skrzynki",
+ "mailbox_details": "Szczegóły",
"messages": "wiadomości",
"never": "Nigdy",
"new_password": "Nowe hasło",
@@ -391,17 +1084,17 @@
"remove": "Usuń",
"save_changes": "Zapisz zmiany",
"shared_aliases": "Aliasy współdzielone",
- "shared_aliases_desc": "Na aliasy współdzielone nie wpływają filtry spamu i ustawienia TLS.",
- "show_sieve_filters": "Twój filtr sieve",
- "sogo_profile_reset": "Usuń profil SOGo (webmail)",
- "sogo_profile_reset_help": "To usunie ustawienia SOGo <b>bezpowrotnie</b>.",
- "sogo_profile_reset_now": "Usuń profil teraz",
- "spam_aliases": "Tymczasowy alias email",
+ "shared_aliases_desc": "Współdzielone aliasy nie są objęte ustawieniami specyficznymi dla użytkownika, takimi jak filtr antyspamowy czy polityka szyfrowania.\nOdpowiadające im filtry antyspamowe mogą być tworzone wyłącznie przez administratora — jako polityki obowiązujące dla całej domeny.",
+ "show_sieve_filters": "Pokaż filtr sieve aktywnego użytkownika",
+ "sogo_profile_reset": "Zresetuj profil SOGo",
+ "sogo_profile_reset_help": "Spowoduje to usunięcie profilu użytkownika SOGo oraz bezpowrotne <b>usunięcie wszystkich danych kontaktów i kalendarza.</b>",
+ "sogo_profile_reset_now": "Zresetuj profil teraz",
+ "spam_aliases": "Tymczasowe aliasy email",
"spamfilter": "Filtr spamu",
- "spamfilter_behavior": "Rating",
+ "spamfilter_behavior": "Ocena",
"spamfilter_bl": "Czarna lista",
- "spamfilter_bl_desc": "Adresy email z czarnej listy <b>zawsze</b> klasyfikuj jako spam i odrzucaj. Można użyć wildcards.",
- "spamfilter_default_score": "Wartości domyślne:",
+ "spamfilter_bl_desc": "Adresy e-mail znajdujące się na liście zablokowanych (denylist) są <b>zawsze</b>klasyfikowane jako spam i odrzucane.\nOdrzucone wiadomości <b>nie są</b>kopiowane do kwarantanny.\nMożna używać symboli wieloznacznych (wildcardów).\nFiltr jest stosowany wyłącznie do bezpośrednich aliasów (aliasów kierujących do jednej skrzynki pocztowej), z wyłączeniem aliasów typu „catch-all” oraz samej skrzynki.",
+ "spamfilter_default_score": "Wartości domyślne",
"spamfilter_green": "Zielony: ta wiadomość nie jest spamem",
"spamfilter_hint": "Pierwsza wartość oznacza \"niską punktację spam\", druga wartość oznacza \"wysoką punktację spam\".",
"spamfilter_red": "Czerwony: ta wiadomość jest spamem i zostanie odrzucona przez serwer",
@@ -412,13 +1105,13 @@
"spamfilter_table_remove": "Usuń",
"spamfilter_table_rule": "Zasada",
"spamfilter_wl": "Biała lista",
- "spamfilter_wl_desc": "Adresy email z białej listy <b>nigdy</b> nie klasyfikuj jako spam. Można użyć wildcards.",
+ "spamfilter_wl_desc": "Adresy e-mail znajdujące się na liście dozwolonych (allowlist) są zaprogramowane tak, aby <b> nigdy nie </b> były klasyfikowane jako spam. Można używać symboli wieloznacznych (wildcardów).Filtr jest stosowany wyłącznie do bezpośrednich aliasów (aliasów wskazujących na jedną skrzynkę pocztową), z wyłączeniem aliasów typu „catch-all” oraz samej skrzynki pocztowej",
"spamfilter_yellow": "Żółty: ta wiadomość może być spamem, zostanie oznaczona jako spam i przeniesiona do folderu spam",
- "sync_jobs": "Polecenie synchronizacji",
+ "sync_jobs": "Zadania synchronizacji",
"tag_handling": "Ustaw obsługę znaczników pocztowych",
"tag_help_example": "Przykład adresu email z etykietą: ja<b>+Facebook</b>@example.org",
"tag_help_explain": "W podfolderze: tworzy nowy podfolder z nazwą taką jak etykieta, który zostanie umieszczony pod Skrzynką odbiorczą (\"Skrzynka odbiorcza/Facebook\").<br>\r\nW temacie: nazwy etykiet zostaną dodane na początku tematów wiadomości, np.: \"[Facebook] Moje wiadomości\".",
- "tag_in_none": "Nic nie robić",
+ "tag_in_none": "Nie wykonuj żadnej akcji",
"tag_in_subfolder": "W podfolderze",
"tag_in_subject": "W temacie",
"tls_enforce_in": "Uruchom TLS przychodzące",
@@ -429,6 +1122,199 @@
"username": "Nazwa użytkownika",
"week": "Tydzień",
"weekly": "Co tydzień",
- "weeks": "Tygodnie"
+ "weeks": "Tygodnie",
+ "q_add_header": "Spam",
+ "advanced_settings": "Ustawienia zaawansowane",
+ "app_hint": "Hasła aplikacji są alternatywnymi hasłami dla logowania IMAP, SMTP, CalDAV, CardDAV i EAS. Nazwa użytkownika pozostaje niezmieniona. Webmail SOGo nie jest dostępny za pośrednictwem haseł aplikacji.",
+ "allowed_protocols": "Dozwolone protokoły",
+ "app_name": "Nazwa aplikacji",
+ "app_passwds": "Hasła do aplikacji",
+ "apple_connection_profile": "Profil połączenia Apple",
+ "apple_connection_profile_complete": "Ten profil połączenia obejmuje parametry IMAP i SMTP, a także ścieżki CalDAV (kalendarze) i CardDAV (kontakty) dla urządzenia Apple.",
+ "apple_connection_profile_mailonly": "Ten profil połączenia zawiera parametry konfiguracji IMAP i SMTP dla urządzenia Apple.",
+ "apple_connection_profile_with_app_password": "Nowe hasło aplikacji jest generowane i dodawane do profilu, dzięki czemu nie trzeba wprowadzać hasła podczas konfigurowania urządzenia. Proszę nie udostępniaj tego pliku, ponieważ zapewnia on pełny dostęp do skrzynki pocztowej.",
+ "attribute": "Atrybut",
+ "authentication": "Uwierzytelnianie",
+ "change_password_hint_app_passwords": "Twoje konto ma %d hasła aplikacji, które nie zostaną zmienione. Aby nimi zarządzać, przejdź do zakładki Hasła aplikacji.",
+ "clear_recent_successful_connections": "Wyczyść udane połączenia",
+ "create_app_passwd": "Stwórz hasło do aplikacji",
+ "created_on": "Stworzony na",
+ "delete_ays": "Proszę o potwierdzenie procesu usuwania.",
+ "direct_protocol_access": "Ten użytkownik skrzynki pocztowej ma <b>bezpośredni, zewnętrzny dostęp</b> do następujących protokołów i aplikacji. To ustawienie jest kontrolowane przez administratora. Można tworzyć hasła aplikacji, aby przyznać dostęp do poszczególnych protokołów i aplikacji.Przycisk „Webmail” umożliwia jednokrotne logowanie (SSO) do SOGo i jest zawsze dostępny.",
+ "email": "Email",
+ "email_and_dav": "E-maile, kalendarze i kontakty",
+ "empty": "Brak wyników",
+ "expire_in": "wygasa w",
+ "fido2_webauthn": "FIDO2/WebAuthn (standard uwierzytelniania)",
+ "from": "od",
+ "generate": "generuj",
+ "last_mail_login": "Ostatni login na skrzynkę pocztową",
+ "last_pw_change": "Ostatnia zmiana hasła",
+ "last_ui_login": "Ostatni login UI",
+ "loading": "Ładowanie...",
+ "login_history": "Historia logowania",
+ "mailbox": "Skrzynka pocztowa",
+ "mailbox_general": "Ogólne ustawienia skrzynki",
+ "mailbox_settings": "Ustawienia",
+ "month": "miesiąc",
+ "months": "miesiące",
+ "no_last_login": "Brak ostatnich danych logowania do interfejsu użytkownika",
+ "open_logs": "Otwórz logi użytkownika",
+ "open_webmail_sso": "Webmail",
+ "overview": "Przegląd",
+ "password": "Hasło",
+ "password_repeat": "Hasło (powtórz)",
+ "password_reset_info": "Jeśli nie ma wiadomości e-mail do odzyskiwania hasła, ta funkcja nie może być używana.",
+ "protocols": "Protokoły",
+ "pushover_evaluate_x_prio": "Eskaluj wiadomości o wysokim priorytecie [<code>X-Priority: 1</code>]",
+ "pushover_info": "Ustawienia powiadomień push będą stosowane do wszystkich czystych (niebędących spamem) wiadomości dostarczonych do <b>%s</b>, w tym aliasów (współdzielonych, niewspółdzielonych i oznaczonych).",
+ "pushover_only_x_prio": "Uwzględniaj tylko wiadomości o wysokim priorytecie [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Uwzględnij następujące adresy e-mail nadawców <small>(oddzielone przecinkami)</small>",
+ "pushover_sender_regex": "Dopasuj nadawców według następującego regexu",
+ "pushover_text": "Tekst powiadomienia",
+ "pushover_title": "Tytuł powiadomienia",
+ "pushover_sound": "Dźwięk powiadomienia",
+ "pushover_vars": "Jeśli nie zdefiniowano filtra nadawcy, wszystkie wiadomości będą brane pod uwagę.<br>Filtry regex oraz dokładne sprawdzanie nadawców można definiować indywidualnie – są one przetwarzane kolejno i nie zależą od siebie.</br>Dostępne zmienne dla treści i tytułu (prosimy pamiętać o zasadach ochrony danych osobowych).",
+ "pushover_verify": "Zweryfikuj dane logowania",
+ "pw_recovery_email": "E-mail do odzyskiwania hasła",
+ "q_all": "Wszystkie kategorie",
+ "q_reject": "Odrzucono",
+ "quarantine_category": "Kategoria powiadomień o kwarantannie",
+ "quarantine_category_info": "Kategoria powiadomień „Odrzucone” obejmuje wiadomości, które zostały odrzucone, natomiast „Folder spam” powiadamia użytkownika o wiadomościach umieszczonych w folderze spam.",
+ "quarantine_notification_info": "Po wysłaniu powiadomienia elementy zostaną oznaczone jako „powiadomione” i żadne kolejne powiadomienia nie zostaną wysłane dla danego elementu.",
+ "recent_successful_connections": "Zarejestrowano udane połączenia",
+ "running": "Uruchomiony",
+ "save": "Zapisz zmiany",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Sprawdzenie nadawcy jest wyłączone</span>",
+ "spam_score_reset": "Przywróć domyślne ustawienia serwera",
+ "status": "Status",
+ "syncjob_check_log": "Sprawdź log",
+ "syncjob_last_run_result": "Wynik ostatniego uruchomienia",
+ "syncjob_EX_OK": "Sukces",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Problem z połączeniem",
+ "syncjob_EXIT_TLS_FAILURE": "Problem z szyfrowanym połączeniem",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Problem uwierzytelniania",
+ "syncjob_EXIT_OVERQUOTA": "Docelowa skrzynka pocztowa przekroczyła limit pojemności",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Nie można połączyć się ze zdalnym serwerem",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Niewłaściwa nazwa użytkownika lub hasło",
+ "text": "Tekst",
+ "tfa_info": "Uwierzytelnianie dwuskładnikowe pomaga chronić Twoje konto. Jeśli je włączysz, będziesz potrzebować haseł aplikacji, aby logować się do programów lub usług, które nie obsługują uwierzytelniania dwuskładnikowego (np. klientów poczty).",
+ "title": "Tytuł",
+ "value": "Wartość",
+ "verify": "Zweryfikuj",
+ "waiting": "Oczekuje",
+ "with_app_password": "z hasłem aplikacji",
+ "year": "rok",
+ "years": "lata",
+ "spam_aliases_info": "Alias antyspamowy to tymczasowy adres e-mail, który może być używany do ochrony właściwych adresów pocztowych. <br>Opcjonalnie można ustawić czas wygaśnięcia, po którym alias zostanie automatycznie dezaktywowany, co pozwala skutecznie pozbyć się nadużywanych lub ujawnionych adresów."
+ },
+ "warning": {
+ "session_ua": "Nieprawidłowy token formularza: Błąd walidacji User-Agent",
+ "cannot_delete_self": "Nie można usunąć zalogowanego użytkownika",
+ "domain_added_sogo_failed": "Dodano domenę, ale nie udało się ponownie uruchomić SOGo, sprawdź logi serwera.",
+ "dovecot_restart_failed": "Nie udało się ponownie uruchomić Dovecota, sprawdź logi",
+ "fuzzy_learn_error": "Błąd uczenia fuzzy hash: %s",
+ "hash_not_found": "Hash nie został odnaleziony lub został już usunięty",
+ "ip_invalid": "Pominięto nieprawidłowe IP: %s",
+ "is_not_primary_alias": "Pominięto alias niebędący głównym: %s",
+ "no_active_admin": "Nie można dezaktywować ostatniego aktywnego administratora",
+ "quota_exceeded_scope": "Przekroczono limit pojemności domeny: w tym zakresie domeny można tworzyć tylko skrzynki o nieograniczonej pojemności.",
+ "session_token": "Nieprawidłowy token formularza: niedopasowanie tokenów"
+ },
+ "datatables": {
+ "collapse_all": "Zwiń wszystko",
+ "decimal": ".",
+ "emptyTable": "Brak danych w tabeli",
+ "expand_all": "Rozszerz wszystko",
+ "info": "Wyświetlanie od _START_ do _END_ z _TOTAL_ wpisów",
+ "infoEmpty": "Wyświetlanie od 0 do 0 z 0 wpisów",
+ "infoFiltered": "(filtrowane z _MAX_ suma wpisów)",
+ "thousands": ",",
+ "lengthMenu": "Pokaż wpisy _MENU_",
+ "loadingRecords": "Ładowanie...",
+ "processing": "Proszę czekać...",
+ "search": "Szukaj:",
+ "zeroRecords": "Nie znaleziono pasujących rekordów",
+ "paginate": {
+ "first": "Pierwszy",
+ "last": "Ostatni",
+ "next": "Następny",
+ "previous": "Poprzedni"
+ },
+ "aria": {
+ "sortAscending": "Aktywuj, aby posortować kolumnę rosnąco",
+ "sortDescending": "Aktywuj, aby posortować kolumnę malejąco"
+ }
+ },
+ "debug": {
+ "architecture": "Architektura",
+ "chart_this_server": "Wykres (ten serwer)",
+ "containers_info": "Informacje o kontenerze",
+ "container_running": "uruchomiony",
+ "container_disabled": "Kontener zatrzymany lub wyłączony",
+ "container_stopped": "Zatrzymany",
+ "cores": "rdzenie",
+ "current_time": "Czas systemowy",
+ "disk_usage": "Użycie dysku",
+ "docs": "Dokumentacja",
+ "error_show_ip": "Nie można ustalić publicznych adresów IP",
+ "external_logs": "Logi zewnętrzne",
+ "history_all_servers": "Historia (wszystkie serwery)",
+ "in_memory_logs": "Logi w pamięci",
+ "last_modified": "Ostatnia modyfikacja",
+ "log_info": "<p>mailcow <b>logi w pamięci</b> są gromadzone na listach Redis i przycinane do wartości <code>LOG_LINES</code> (%d) co minutę, aby ograniczyć nadmierne obciążenie systemu.</p> <p>Logi w pamięci nie są przeznaczone do trwałego przechowywania. Wszystkie aplikacje, które zapisują logi w pamięci, wysyłają je również do daemon Dockera, a więc do domyślnego sterownika logowania.</p> <p>Ten typ logów należy wykorzystywać do <b>debugowania drobnych problemów z kontenerami</b>.</p> <p><b>Logi zewnętrzne</b> są zbierane za pośrednictwem API danej aplikacji.</p> <p><b>Logi statyczne</b> to głównie dzienniki aktywności, które nie są zapisywane przez Dockerd, ale powinny być trwałe (z wyjątkiem logów API).</p>",
+ "login_time": "Czas",
+ "logs": "Logi",
+ "memory": "Pamięć",
+ "online_users": "Użytkownik online",
+ "restart_container": "Restart",
+ "service": "Usługa",
+ "show_ip": "Pokaż publiczne IP",
+ "size": "Rozmiar",
+ "started_at": "Zaczęło się od",
+ "started_on": "Zaczęło się od",
+ "static_logs": "Logi statyczne",
+ "success": "Sukces",
+ "system_containers": "System i kontenery",
+ "timezone": "Strefa czasowa",
+ "uptime": "Czas pracy",
+ "update_available": "Dostępna jest aktualizacja",
+ "no_update_available": "System jest w najnowszej wersji",
+ "update_failed": "Nie można było sprawdzić aktualizacji",
+ "username": "Nazwa użytkownika",
+ "wip": "Obecnie praca w toku"
+ },
+ "diagnostics": {
+ "cname_from_a": "Wartość pochodzi z rekordu A/AAAA. Obsługiwane, o ile rekord wskazuje na prawidłowy zasób.",
+ "dns_records": "Rekordy DNS",
+ "dns_records_24hours": "Pamiętaj, że zmiany wprowadzone w DNS mogą zająć nawet do 24 godzin, zanim ich aktualny stan zostanie poprawnie odzwierciedlony na tej stronie.\nTa sekcja ma na celu ułatwienie Ci konfiguracji rekordów DNS oraz sprawdzenie, czy wszystkie rekordy zostały prawidłowo zapisane w DNS.",
+ "dns_records_data": "Poprawne dane",
+ "dns_records_docs": "Proszę skonsultuj również <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">dokumnetację</a>.",
+ "dns_records_name": "Nazwa",
+ "dns_records_status": "Aktualny stan",
+ "dns_records_type": "Typ",
+ "optional": "Ten rekord jest opcjonalny."
+ },
+ "fido2": {
+ "confirm": "Potwierdź",
+ "fido2_auth": "Logowanie za pomocą FIDO2",
+ "fido2_success": "Urządzenie pomyślnie zarejestrowane",
+ "fido2_validation_failed": "Walidacja nie powiodła się",
+ "fn": "Przyjazna nazwa FIDO",
+ "known_ids": "Znane Id",
+ "none": "Wyłączony",
+ "register_status": "Status rejestracji",
+ "rename": "Zmień nazwę",
+ "set_fido2": "Zarejestruj urządzenie FIDO2",
+ "set_fido2_touchid": "Zarejestruj Touch ID w Apple M1",
+ "set_fn": "Ustaw przyjazną nazwę w FIDO",
+ "start_fido2_validation": "Rozpocznij walidację FIDO2"
+ },
+ "ratelimit": {
+ "disabled": "Wyłączone",
+ "second": "wiadomości / sekundę",
+ "minute": "wiadomości / minutę",
+ "hour": "wiadomości / godzinę",
+ "day": "wiadomości/ dzień"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-br.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-br.json
index 5854cc1..5645537 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-br.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-br.json
@@ -1,7 +1,7 @@
{
"acl": {
- "alias_domains": "Adicionar domínios alias",
- "app_passwds": "Gerenciar senhas de aplicativos",
+ "alias_domains": "Adicionar alias de domínios",
+ "app_passwds": "Gerenciar senhas de app",
"bcc_maps": "Mapas BCC",
"delimiter_action": "Ação delimitadora",
"domain_desc": "Alterar descrição do domínio",
@@ -9,11 +9,12 @@
"eas_reset": "Redefinir dispositivos EAS",
"extend_sender_acl": "Permitir estender a ACL do remetente por endereços externos",
"filters": "Filtros",
- "login_as": "Faça login como usuário da mailbox",
+ "login_as": "Fazer login como usuário da mailbox",
"mailbox_relayhost": "Alterar relayhost para uma mailbox",
"prohibited": "Proibido pela ACL",
"protocol_access": "Alterar o acesso ao protocolo",
"pushover": "Pushover",
+ "pw_reset": "Permite resetar a senha do usuário do Mailcow",
"quarantine": "Ações de quarentena",
"quarantine_attachments": "Anexos de quarentena",
"quarantine_category": "Alterar categoria de notificação de quarentena",
@@ -37,7 +38,7 @@
"add_domain_only": "Adicionar somente domínio",
"add_domain_restart": "Adicionar domínio e reiniciar o SoGo",
"alias_address": "Endereço (s) de alias",
- "alias_address_info": "<small>Endereço/s de e-mail completo ou @example .com, para capturar todas as mensagens de um domínio (separadas por vírgula). <b> somente domínios mailcow</b>.</small>",
+ "alias_address_info": "<small>Endereço(s) de e-mail completo(s) ou @example.com, para capturar todas as mensagens de um domínio (separadas por vírgula). <b>Apenas domínios do Mailcow</b>.</small>",
"alias_domain": "Domínio de alias",
"alias_domain_info": "<small>Somente nomes de domínio válidos (separados por vírgula).</small>",
"app_name": "Nome do aplicativo",
@@ -108,7 +109,10 @@
"username": "Nome de usuário",
"validate": "Validar",
"validation_success": "Validado com sucesso",
- "dry": "Simular sincronização"
+ "dry": "Simular sincronização",
+ "internal": "Interno",
+ "internal_info": "Aliases internos são acessíveis apenas a partir do próprio domínio ou alias de domínio.",
+ "sender_allowed": "Permitir enviar como este alias"
},
"admin": {
"access": "Acesso",
@@ -148,12 +152,13 @@
"arrival_time": "Hora de chegada (hora do servidor)",
"authed_user": "Usuário autoritário",
"ays": "Tem certeza de que deseja continuar?",
- "ban_list_info": "Veja uma lista de IPs banidos abaixo: <b>rede (tempo restante de banimento) - [ações]</b>. <br />Os IPs na fila para serem desbanidos serão removidos da lista de banimentos ativos em alguns segundos. <br />Rótulos vermelhos indicam proibições permanentes ativas na lista negra.",
+ "ban_list_info": "Veja abaixo a lista de IPs banidos: <b>rede (tempo restante do banimento) - [ações]</b>.<br />IPs na fila para serem desbanidos serão removidos da lista de banimentos ativos em alguns segundos.<br />Rótulos vermelhos indicam banimentos permanentes ativos na lista de bloqueio.",
"change_logo": "Alterar logotipo",
"logo_normal_label": "Normal",
"logo_dark_label": "Invertido para o modo escuro",
"configuration": "Configuração",
"convert_html_to_text": "Converter HTML em texto sem formatação",
+ "copy_to_clipboard": "Copiado para a área de transferência!",
"cors_settings": "Configurações do CORS",
"credentials_transport_warning": "<b>Aviso</b>: Adicionar uma nova entrada no mapa de transporte atualizará as credenciais de todas as entradas com uma coluna correspondente do próximo salto.",
"customer_id": "ID do cliente",
@@ -184,9 +189,11 @@
"excludes": "Exclui esses destinatários",
"f2b_ban_time": "Tempo (s) de proibição",
"f2b_ban_time_increment": "O tempo de banimento é incrementado com cada banimento",
- "f2b_blacklist": "Redes/hosts na lista negra",
+ "f2b_blacklist": "Redes/hosts na lista de bloqueio",
"f2b_filter": "Filtros Regex",
- "f2b_list_info": "Um host ou rede na lista negra sempre superará uma entidade na lista branca. <b>As atualizações da lista levarão alguns segundos para serem aplicadas.</b>",
+ "f2b_list_info": "Um host ou rede na lista de bloqueio sempre terá prioridade sobre uma entidade na lista de permissões. <b>As atualizações das listas levarão alguns segundos para serem aplicadas.</b>",
+ "f2b_manage_external": "Gerenciar Fail2Ban externamente",
+ "f2b_manage_external_info": "O Fail2ban ainda manterá a lista de banimentos, mas não definirá ativamente regras para bloquear o tráfego. Use a lista de banimento gerada abaixo para bloquear externamente o tráfego.",
"f2b_max_attempts": "Máximo de tentativas",
"f2b_max_ban_time": "Tempo (s) máximo (s) de banimento",
"f2b_netban_ipv4": "Tamanho da sub-rede IPv4 a ser proibida (8-32)",
@@ -194,7 +201,7 @@
"f2b_parameters": "Parâmetros do Fail2ban",
"f2b_regex_info": "Registros considerados: SoGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Repita a (s) janela (s) para o máximo de tentativas",
- "f2b_whitelist": "Redes/hosts incluídos na lista branca",
+ "f2b_whitelist": "Redes/hosts na lista de permissões",
"filter_table": "Tabela de filtros",
"forwarding_hosts": "Anfitriões de encaminhamento",
"forwarding_hosts_add_hint": "Você pode especificar endereços IPv4/IPv6, redes em notação CIDR, nomes de host (que serão resolvidos para endereços IP) ou nomes de domínio (que serão resolvidos para endereços IP consultando registros SPF ou, na ausência deles, registros MX).",
@@ -216,7 +223,7 @@
"includes": "Inclua esses destinatários",
"ip_check": "Verificação de IP",
"ip_check_disabled": "A verificação de IP está desativada. Você pode ativá-lo em <br><strong>Sistema > Configuração > Opções > Personalizar</strong>",
- "ip_check_opt_in": "Opte por usar o serviço de terceiros <strong>ipv4.mailcow.email.</strong> e <strong>ipv6.mailcow.email</strong> para resolver endereços IP externos.",
+ "ip_check_opt_in": "Opte por usar o serviço de terceiros <strong>ipv4.mailcow.email</strong> e <strong>ipv6.mailcow.email</strong> para resolver endereços IP externos.",
"is_mx_based": "Baseado em MX",
"last_applied": "Aplicado pela última vez",
"license_info": "Uma licença não é necessária, mas ajuda no desenvolvimento.<br><a href=\"https://www.servercow.de/mailcow? Lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Registre seu GUID aqui</a> ou <a href=\"https://www.servercow.de/mailcow? Lang=en#support\" target=\"_blank\" alt=\"Support order\">comprar suporte para sua instalação de mailcow.</a>",
@@ -238,7 +245,7 @@
"oauth2_add_client": "Adicionar cliente OAuth2",
"oauth2_client_id": "ID do cliente",
"oauth2_client_secret": "Segredo do cliente",
- "oauth2_info": "A implementação OAuth2 suporta o tipo de concessão \"Código de Autorização\" e emite tokens de atualização.<br>\nO servidor também emite automaticamente novos tokens de atualização, depois que um token de atualização foi usado.<br><br>\n• O escopo padrão é <i>perfil</i>. Somente usuários com caixa de e-mail podem ser autenticados contra o OAuth2. Se o parâmetro de escopo for omitido, ele voltará para <i>perfil</i>.<br>\nCaminhos para solicitações OAuth2 API: <br>\n<ul>\n<li>Endpoint de autorização: <code>/oauth/authorize</code></li>\n<li>Endpoint token: <code>/oauth/token</code></li>\n<li>Página de recursos: <code>/oauth/profile</code></li>\n</ul>\nRegenerar o segredo do cliente não expirará os códigos de autorização existentes, mas eles não renovarão seu token.<br><br>\nA revogação dos tokens do cliente causará o término imediato de todas as sessões ativas. Todos os clientes precisam se autenticar novamente.",
+ "oauth2_info": "A implementação do OAuth2 suporta o tipo de concessão \"Código de Autorização\" e emite tokens de atualização.<br>\nO servidor também emite automaticamente novos tokens de atualização após um token de atualização ter sido usado.<br>\nO escopo padrão é <i>profile</i>. Somente usuários de caixa de correio podem ser autenticados com o OAuth2. Se o parâmetro de escopo for omitido, o padrão será <i>profile</i>.<br>\nO parâmetro <i>state</i> deve ser enviado pelo cliente como parte da solicitação de autorização.<br><br>\nCaminhos para solicitações à API OAuth2: <br>\n\n<ul>\n <li>Ponto de extremidade de autorização: <code>/oauth/authorize</code></li>\n <li>Endpoint do token: <code>/oauth/token</code></li>\n <li>Página de recursos: <code>/oauth/profile</code></li>\n</ul>\n\nRegenerar o segredo do cliente não expirará os códigos de autorização existentes, mas impedirá a renovação do token.<br><br>\nA revogação dos tokens de cliente causará o encerramento imediato de todas as sessões ativas. Todos os clientes precisarão se autenticar novamente.",
"oauth2_redirect_uri": "URI de redirecionamento",
"oauth2_renew_secret": "Gere um novo segredo de cliente",
"oauth2_revoke_tokens": "Revogar todos os tokens do cliente",
@@ -253,6 +260,11 @@
"password_policy_numbers": "Deve conter pelo menos um número",
"password_policy_special_chars": "Deve conter caracteres especiais",
"password_repeat": "Senha de confirmação (repetição)",
+ "password_reset_info": "Se nenhum email de recuperação for definido, esta função não poderá ser utilizada.",
+ "password_reset_settings": "Configurações de recuperação de senha",
+ "password_reset_tmpl_html": "Template HTML",
+ "password_reset_tmpl_text": "Template de Texto",
+ "password_settings": "Configurações de senha",
"priority": "Prioridade",
"private_key": "Chave privada",
"quarantine": "Quarentena",
@@ -293,6 +305,8 @@
"remove_row": "Remover linha",
"reset_default": "Redefinir para o padrão",
"reset_limit": "Remover o hash",
+ "reset_password_vars": "<code>{{link}}</code> Link de recuperação de senha gerado<br><code>{{username}}</code> nome da caixa de email do usuário que requisitou a recuperação de senha<br><code>{{username2}}</code> Nome da caixa de email recuperada<br><code>{{date}}</code> Data que a requisição de recuperação de senha foi feita<br><code>{{token_lifetime}}</code> O tempo de vida em minutos do token<br><code>{{hostname}}</code> O servidor do mailcow",
+ "restore_template": "Deixe limpo para o template padrão de recuperação.",
"routing": "Roteamento",
"rsetting_add_rule": "Adicionar regra",
"rsetting_content": "Conteúdo da regra",
@@ -307,8 +321,8 @@
"rspamd_com_settings": "Um nome de configuração será gerado automaticamente, veja os exemplos de predefinições abaixo. Para obter mais detalhes, consulte a documentação <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">do Rspamd</a>",
"rspamd_global_filters": "Mapas de filtro globais",
"rspamd_global_filters_agree": "Eu vou ter cuidado!",
- "rspamd_global_filters_info": "Os mapas de filtros globais contêm diferentes tipos de listas negras e brancas globais.",
- "rspamd_global_filters_regex": "Seus nomes explicam seu propósito. <code>Todo o conteúdo deve conter uma expressão regular válida no formato “/padrão/opções” (por exemplo, /. + @domain\\ .tld/i</code>). <br>\r\n Embora verificações rudimentares estejam sendo executadas em cada linha de regex, a funcionalidade do Rspamd pode ser interrompida se não conseguir ler a sintaxe corretamente. <br>\r\n O Rspamd tentará ler o conteúdo do mapa quando alterado. Se você tiver problemas, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">reinicie o Rspamd</a> para forçar o recarregamento do mapa. <br>Os elementos da lista negra são excluídos da quarentena.",
+ "rspamd_global_filters_info": "Os mapas de filtros globais contêm diferentes tipos de listas globais de bloqueio e de permissões.",
+ "rspamd_global_filters_regex": "Os nomes explicam sua finalidade. Todo o conteúdo deve conter uma expressão regular válida no formato \"/padrão/opções\" (por exemplo, <code>/.[+@domain.tld](mailto:+@domain.tld)/i</code>).<br>\nEmbora verificações básicas sejam executadas em cada linha de regex, a funcionalidade do Rspamd pode ser comprometida se ele não conseguir ler a sintaxe corretamente.<br>\nO Rspamd tentará ler o conteúdo do mapa quando ele for alterado. Se você tiver problemas, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">reinicie o Rspamd</a> para forçar o recarregamento do mapa.<br>Elementos na lista de bloqueio são excluídos da quarentena.",
"rspamd_settings_map": "Mapa de configurações do Rspamd",
"sal_level": "Nível de humor",
"save": "Salvar alterações",
@@ -349,9 +363,56 @@
"validate_license_now": "Valide o GUID em relação ao servidor de licenças",
"verify": "Verificar",
"yes": "✓",
- "copy_to_clipboard": "Texto copiado para a área de transferência!",
- "f2b_manage_external": "Gerenciar Fail2Ban externamente",
- "f2b_manage_external_info": "O Fail2ban ainda manterá a lista de banimentos, mas não definirá ativamente regras para bloquear o tráfego. Use a lista de banimento gerada abaixo para bloquear externamente o tráfego."
+ "iam_client_id": "ID de cliente",
+ "iam_client_secret": "Senha de cliente",
+ "iam_auth_flow": "Fluxo de autenticação",
+ "iam_client_scopes": "Escopo do cliente",
+ "iam_default_template": "Template Padrão",
+ "admin_quicklink": "Ocultar link rápido para página de login do administrador",
+ "app_hide": "Ocultar para login",
+ "login_page": "Página de login",
+ "domainadmin_quicklink": "Ocultar link rápido para página de login do administrador de domínio",
+ "filter": "Filtro",
+ "force_sso_text": "Se um provedor OIDC externo for configurado, esta opção oculta os formulários de login padrão do mailcow e mostra apenas o botão de single sign-on",
+ "force_sso": "Desabilitar login do mailcow e mostrar apenas single sign-on",
+ "iam": "Provedor de identidade",
+ "iam_attribute_field": "Campo de atributo",
+ "iam_authorize_url": "Endpoint de autorização",
+ "iam_auth_flow_info": "Além do fluxo de código de autorização (fluxo padrão no Keycloak), que é usado para login de single sign-on, o mailcow também suporta fluxo de autenticação com credenciais diretas. O fluxo Mailpassword tenta validar as credenciais do usuário usando a API REST do administrador do Keycloak. O mailcow recupera a senha hash do atributo <code>mailcow_password</code>, que é mapeado no Keycloak.",
+ "iam_basedn": "DN base",
+ "iam_default_template_description": "Se nenhum template for atribuído a um usuário, o template padrão será usado para criar a caixa de correio, mas não para atualizar a caixa de correio.",
+ "iam_description": "Configure um provedor externo para autenticação<br>As caixas de correio dos usuários serão criadas automaticamente no primeiro login, desde que um mapeamento de atributos tenha sido definido.",
+ "iam_extra_permission": "Para que as configurações a seguir funcionem, o cliente mailcow no Keycloak precisa de uma <code>conta de serviço</code> e a permissão para <code>visualizar usuários</code>.",
+ "iam_host": "Host",
+ "iam_host_info": "Digite um ou mais hosts LDAP, separados por vírgulas.",
+ "iam_import_users": "Importar usuários",
+ "iam_login_provisioning": "Criar usuários automaticamente no login",
+ "iam_mapping": "Mapeamento de atributos",
+ "iam_bindpass": "Senha de vinculação",
+ "iam_periodic_full_sync": "Sincronização completa periódica",
+ "iam_port": "Porta",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "URL de redirecionamento",
+ "iam_rest_flow": "Fluxo Mailpassword",
+ "iam_server_url": "URL do servidor",
+ "iam_sso": "Single sign-on",
+ "iam_sync_interval": "Intervalo de sincronização/importação (min)",
+ "iam_test_connection": "Testar conexão",
+ "iam_token_url": "Endpoint de token",
+ "iam_userinfo_url": "Endpoint de informações do usuário",
+ "iam_username_field": "Campo de nome de usuário",
+ "iam_binddn": "DN de vinculação",
+ "iam_use_ssl": "Usar SSL",
+ "iam_use_ssl_info": "Se habilitar SSL e a porta estiver definida como 389, ela será automaticamente substituída para usar 636.",
+ "iam_use_tls": "Usar StartTLS",
+ "iam_use_tls_info": "Se habilitar TLS, você deve usar a porta padrão para seu servidor LDAP (389). Portas SSL não podem ser usadas.",
+ "iam_version": "Versão",
+ "ignore_ssl_error": "Ignorar erros SSL",
+ "needs_restart": "precisa reiniciar",
+ "quicklink_text": "Mostrar ou ocultar links rápidos para outras páginas de login abaixo do formulário de login",
+ "task": "Tarefa",
+ "user_link": "Link do usuário",
+ "user_quicklink": "Ocultar link rápido para página de login do usuário"
},
"danger": {
"access_denied": "Acesso negado ou dados de formulário inválidos",
@@ -394,7 +455,9 @@
"goto_invalid": "O endereço Goto %s é inválido",
"ham_learn_error": "Erro de aprendizado do Ham: %s",
"imagick_exception": "Erro: exceção Imagick ao ler a imagem",
+ "img_dimensions_exceeded": "A imagem excede o tamanho máximo",
"img_invalid": "Não é possível validar o arquivo de imagem",
+ "img_size_exceeded": "A imagem excede o tamanho máximo",
"img_tmp_missing": "Não é possível validar o arquivo de imagem: Arquivo temporário não encontrado",
"invalid_bcc_map_type": "Tipo de mapa BCC inválido",
"invalid_destination": "O formato de destino “%s” é inválido",
@@ -405,6 +468,7 @@
"invalid_nexthop_authenticated": "O próximo salto existe com credenciais diferentes. Primeiro, atualize as credenciais existentes para o próximo salto.",
"invalid_recipient_map_new": "Novo destinatário inválido especificado: %s",
"invalid_recipient_map_old": "Destinatário original inválido especificado: %s",
+ "invalid_reset_token": "Token de recuperação inválido",
"ip_list_empty": "A lista de IPs permitidos não pode estar vazia",
"is_alias": "%s já é conhecido como endereço de alias",
"is_alias_or_mailbox": "%s já é conhecido como alias, mailbox ou alias de endereço expandido a partir de um domínio de alias.",
@@ -434,6 +498,8 @@
"password_complexity": "A senha não atende à política",
"password_empty": "A senha não deve estar vazia",
"password_mismatch": "A senha de confirmação não corresponde",
+ "password_reset_invalid_user": "Caixa de email não encontrada ou email de recuperação não definido",
+ "password_reset_na": "A recuperação de senha está indisponível no momento. Por favor, contacte o administrador.",
"policy_list_from_exists": "Existe um registro com nome próprio",
"policy_list_from_invalid": "O registro tem formato inválido",
"private_key_error": "Erro de chave privada: %s",
@@ -442,10 +508,12 @@
"pushover_token": "O token Pushover tem um formato errado",
"quota_not_0_not_numeric": "A cota deve ser numérica e >= 0",
"recipient_map_entry_exists": "Existe uma entrada de mapa de destinatários “%s”",
+ "recovery_email_failed": "Não foi possível enviar um email de recuperação. Por favor, contacte seu administrador.",
"redis_error": "Erro do Redis: %s",
"relayhost_invalid": "A entrada de mapa %s é inválida",
"release_send_failed": "A mensagem não pôde ser liberada: %s",
"reset_f2b_regex": "O filtro Regex não pôde ser redefinido a tempo. Tente novamente ou aguarde mais alguns segundos e recarregue o site.",
+ "reset_token_limit_exceeded": "O limite de token de recuperação foi excedido. Por favor tente novamente mais tarde.",
"resource_invalid": "O nome do recurso %s é inválido",
"rl_timeframe": "O prazo do limite de taxa está incorreto",
"rspamd_ui_pw_length": "A senha do Rspamd UI deve ter pelo menos 6 caracteres",
@@ -468,6 +536,7 @@
"tls_policy_map_dest_invalid": "O destino da política é inválido",
"tls_policy_map_entry_exists": "Existe uma entrada “%s” no mapa de políticas TLS",
"tls_policy_map_parameter_invalid": "O parâmetro de política é inválido",
+ "to_invalid": "Destinatário não pode ser vazio",
"totp_verification_failed": "Falha na verificação do TOTP",
"transport_dest_exists": "O destino de transporte “%s” existe",
"webauthn_verification_failed": "Falha na verificação do WebAuthn: %s",
@@ -481,8 +550,16 @@
"validity_missing": "Por favor, atribua um período de validade",
"value_missing": "Forneça todos os valores",
"yotp_verification_failed": "Falha na verificação do Yubico OTP: %s",
- "img_dimensions_exceeded": "A imagem excede o tamanho máximo",
- "img_size_exceeded": "A imagem excede o tamanho máximo"
+ "authsource_in_use": "O provedor de identidade não pode ser alterado ou excluído pois está sendo usado por um ou mais usuários.",
+ "generic_server_error": "Ocorreu um erro inesperado no servidor. Entre em contato com seu administrador.",
+ "iam_test_connection": "Falha na conexão",
+ "max_age_invalid": "Idade máxima %s é inválida",
+ "mode_invalid": "Modo %s é inválido",
+ "mx_invalid": "Registro MX %s é inválido",
+ "required_data_missing": "Dados obrigatórios %s estão ausentes",
+ "version_invalid": "Versão %s é inválida",
+ "tfa_removal_blocked": "A autenticação de dois fatores não pode ser removida, pois é obrigatória para a sua conta.",
+ "quarantine_category_invalid": "A categoria da quarentena deve ser uma das seguintes: add_header, reject, all"
},
"datatables": {
"collapse_all": "Recolher tudo",
@@ -494,7 +571,7 @@
"infoFiltered": "(filtrado do total de entradas _MAX_)",
"infoPostFix": "",
"thousands": ",",
- "lengthMenu": "Mostrar _ MENU_ entradas",
+ "lengthMenu": "Mostrar _MENU_ entradas",
"loadingRecords": "Carregando...",
"processing": "Por favor, aguarde...",
"search": "Pesquisa:",
@@ -525,7 +602,6 @@
"external_logs": "Registros externos",
"history_all_servers": "Histórico (todos os servidores)",
"in_memory_logs": "Registros na memória",
- "jvm_memory_solr": "Uso de memória JVM",
"last_modified": "Última modificação",
"log_info": "<p>Os <b>registros na memória do</b> mailcow são coletados em listas do Redis e reduzidos para LOG_LINES (%d) a cada minuto para reduzir o martelamento.\r\n Os <br>registros na memória não devem ser persistentes. Todos os aplicativos que fazem login na memória também fazem login no daemon do Docker e, portanto, no driver de registro padrão.\r\n </p><br>O tipo de registro na memória deve ser usado para depurar pequenos problemas com contêineres.\r\n <p>Os <b>registros externos</b> são coletados por meio da API do aplicativo em questão.</p>\r\n <p>Os <b>registros estáticos</b> são principalmente registros de atividades, que não são registrados no Dockerd, mas ainda precisam ser persistentes (exceto os registros da API).</p>",
"login_time": "Hora",
@@ -536,8 +612,6 @@
"service": "Serviço",
"show_ip": "Mostrar IP público",
"size": "Tamanho",
- "solr_dead": "O Solr está iniciando, desativado ou morreu.",
- "solr_status": "Status do solr",
"started_at": "Começou em",
"started_on": "Começou em",
"static_logs": "Registros estáticos",
@@ -570,7 +644,7 @@
"alias": "Editar alias",
"allow_from_smtp": "<b>Permita que esses IPs usem apenas SMTP</b>",
"allow_from_smtp_info": "Deixe em branco para permitir todos os remetentes. Endereços e <br>redes IPv4/IPv6.",
- "allowed_protocols": "Protocolos permitidos",
+ "allowed_protocols": "Protocolos permitidos para acesso direto do usuário (não afeta os protocolos de senha do aplicativo)",
"app_name": "Nome do aplicativo",
"app_passwd": "Senha do aplicativo",
"app_passwd_protocols": "Protocolos permitidos para a senha do aplicativo",
@@ -581,6 +655,7 @@
"client_secret": "Segredo do cliente",
"comment_info": "Um comentário privado não é visível para o usuário, enquanto um comentário público é mostrado como dica de ferramenta ao passar o mouse sobre ele na visão geral do usuário",
"created_on": "Criado em",
+ "custom_attributes": "Atributos personalizados",
"delete1": "Excluir da fonte quando concluído",
"delete2": "Excluir mensagens no destino que não estão na origem",
"delete2duplicates": "Excluir duplicatas no destino",
@@ -601,6 +676,7 @@
"custom": "{= foo =} - Se o mailbox tiver o atributo personalizado \"foo\" com valor \"bar\", retornará \"bar\""
},
"domain_footer_plain": "Rodapé simples",
+ "domain_footer_skip_replies": "Ignore o rodapé nos e-mails de resposta",
"domain_quota": "Cota de domínio",
"domains": "Domínios",
"dont_check_sender_acl": "Desativar a verificação de remetente para o domínio %s (+ domínios de alias)",
@@ -636,6 +712,7 @@
"none_inherit": "Nenhum/Herdar",
"nexthop": "Próximo salto",
"password": "Senha",
+ "password_recovery_email": "Email de recuperação de senha",
"password_repeat": "Senha de confirmação (repetição)",
"previous": "Página anterior",
"private_comment": "Comentário privado",
@@ -653,7 +730,7 @@
"pushover_verify": "Verifique as credenciais",
"quota_mb": "Cota (MiB)",
"quota_warning_bcc": "Aviso de cota BCC",
- "quota_warning_bcc_info": "Os avisos serão enviados em cópias separadas para os seguintes destinatários. O assunto será sufixado pelo nome de usuário correspondente entre colchetes, por exemplo: <code>Aviso de cota (</code>user@example.com).",
+ "quota_warning_bcc_info": "Os avisos serão enviados em cópias separadas para os seguintes destinatários. O assunto será precedido pelo nome de usuário correspondente entre colchetes, por exemplo: <code>Aviso de cota (user@example.com)</code>.",
"ratelimit": "Limite de taxa",
"redirect_uri": "URL de redirecionamento/retorno de chamada",
"relay_all": "Retransmita todos os destinatários",
@@ -672,26 +749,45 @@
"sieve_desc": "Breve descrição",
"sieve_type": "Tipo de filtro",
"skipcrossduplicates": "Ignore mensagens duplicadas entre pastas (primeiro a chegar, primeiro a ser servido)",
- "sogo_access": "Conceder acesso de login direto ao SoGo",
- "sogo_access_info": "O login único de dentro da interface do usuário de e-mail continua funcionando. Essa configuração não afeta o acesso a todos os outros serviços nem exclui ou altera o perfil SoGo existente de um usuário.",
+ "sogo_access": "Encaminhamento direto para o SOGo",
+ "sogo_access_info": "Após o login, o usuário é automaticamente redirecionado para o SOGo.",
"sogo_visible": "O alias é visível no SoGo",
"sogo_visible_info": "Essa opção afeta somente objetos, que podem ser exibidos no SoGo (endereços de alias compartilhados ou não compartilhados apontando para pelo menos uma mailbox local). Se estiver oculto, um alias não aparecerá como remetente selecionável no SoGo.",
"spam_alias": "Crie ou altere endereços de alias com limite de tempo",
"spam_filter": "Filtro de spam",
- "spam_policy": "Adicionar ou remover itens da lista branca/negra",
+ "spam_policy": "Adicionar ou remover itens da lista de permissões/bloqueio",
"spam_score": "Defina uma pontuação de spam personalizada",
"subfolder2": "Sincronizar na subpasta no destino <br><small>(vazio = não usar subpasta</small>)",
"syncjob": "Editar tarefa de sincronização",
- "target_address": "<small>Ir para endereço/es (separados por vírgula)</small>",
+ "target_address": "Ir para o(s) endereço(s) <small>(separados por vírgula)</small>",
"target_domain": "Domínio de destino",
"timeout1": "Tempo limite para conexão com o host remoto",
"timeout2": "Tempo limite para conexão com o host local",
"title": "Editar objeto",
"unchanged_if_empty": "Se inalterado, deixe em branco",
"username": "Nome de usuário",
- "validate_save": "Valide e salve",
- "custom_attributes": "Atributos personalizados",
- "domain_footer_skip_replies": "Ignore o rodapé nos e-mails de resposta"
+ "validate_save": "Validar e salvar",
+ "internal": "Interno",
+ "internal_info": "Aliases internos são acessíveis apenas a partir do próprio domínio ou domínios alias.",
+ "mailbox_rename": "Renomear caixa de correio",
+ "mailbox_rename_agree": "Eu criei um backup.",
+ "mailbox_rename_warning": "IMPORTANTE! Crie um backup antes de renomear a caixa de correio.",
+ "mailbox_rename_alias": "Criar alias automaticamente",
+ "mailbox_rename_title": "Novo nome da caixa de correio local",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> é um padrão que força a entrega de email entre servidores de email para usar TLS com certificados válidos. <br>É usado quando <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> não é possível devido ao DNSSEC ausente ou não suportado.<br><b>Nota</b>: Se o domínio de recepção suporta DANE com DNSSEC, DANE é <b>sempre</b> preferido – MTA-STS atua apenas como fallback.",
+ "mta_sts_version": "Versão",
+ "mta_sts_version_info": "Define a versão do padrão MTA-STS – atualmente apenas <code>STSv1</code> é válido.",
+ "mta_sts_mode": "Modo",
+ "mta_sts_mode_info": "Há três modos para escolher:<ul><li><em>testing</em> – política é apenas monitorada, violações não têm impacto.</li><li><em>enforce</em> – política é rigorosamente aplicada, conexões sem TLS válido são rejeitadas.</li><li><em>none</em> – política é publicada mas não aplicada.</li></ul>",
+ "mta_sts_max_age": "Idade máxima",
+ "mta_sts_max_age_info": "Tempo em segundos que servidores de email de recepção podem armazenar esta política em cache até buscar novamente.",
+ "mta_sts_mx": "Servidor MX",
+ "mta_sts_mx_info": "Permite envio apenas para nomes de host de servidor de email explicitamente listados; o MTA de envio verifica se o nome do host DNS MX corresponde à lista de políticas e permite entrega apenas com certificado TLS válido (protege contra MITM).",
+ "mta_sts_mx_notice": "Múltiplos servidores MX podem ser especificados (separados por vírgulas).",
+ "sender_allowed": "Permitir enviar como este alias",
+ "sender_allowed_info": "Se desativado, este alias poderá apenas receber e-mails. Use a ACL de remetente para substituir essa configuração e conceder a caixas de correio específicas permissão para enviar.",
+ "mta_sts_active_info": "Se esta opção estiver desmarcada, a política MTA-STS não será publicada e nenhum certificado será solicitado via ACME para o subdomínio mta-sts."
},
"fido2": {
"confirm": "Confirme",
@@ -712,7 +808,7 @@
"cancel": "Cancelar",
"confirm_delete": "Confirme a exclusão",
"delete_now": "Excluir agora",
- "delete_these_items": "Confirme suas alterações no seguinte ID de objeto",
+ "delete_these_items": "Por favor, confirme as alterações feitas no seguinte ID de objeto.",
"hibp_check": "Verifique em haveibeenpwned.com",
"hibp_nok": "Combinado! Essa é uma senha potencialmente perigosa!",
"hibp_ok": "Nenhuma combinação encontrada.",
@@ -741,13 +837,28 @@
"session_expires": "Sua sessão expirará em cerca de 15 segundos"
},
"login": {
+ "back_to_mailcow": "Voltar para o mailcow",
"delayed": "O login foi atrasado em %s segundos.",
"fido2_webauthn": "Login do FIDO2/WebAuthn",
+ "forgot_password": "> Esqueceu a senha?",
+ "invalid_pass_reset_token": "O token de recuperação de senha está inválido ou expirado.<br>Por favor solicite um novo link de recuperação de senha.",
"login": "Login",
"mobileconfig_info": "Faça login como usuário da mailbox para baixar o perfil de conexão Apple solicitado.",
- "other_logins": "Login com chave",
+ "new_password": "Nova senha",
+ "new_password_confirm": "Confirmar nova senha",
+ "other_logins": "ou faça login com",
"password": "Senha",
- "username": "Nome de usuário"
+ "reset_password": "Recuperar a senha",
+ "request_reset_password": "Solicitar troca de senha",
+ "username": "Nome de usuário",
+ "login_linkstext": "Login incorreto?",
+ "login_usertext": "Entrar como usuário",
+ "login_domainadmintext": "Entrar como administrador de domínio",
+ "login_admintext": "Entrar como administrador",
+ "login_user": "Login de usuário",
+ "login_dadmin": "Login como administrador de domínio",
+ "login_admin": "Login como administrador",
+ "email": "Endereço de email"
},
"mailbox": {
"action": "Ação",
@@ -774,7 +885,7 @@
"all_domains": "Todos os domínios",
"allow_from_smtp": "<b>Permita que esses IPs usem apenas SMTP</b>",
"allow_from_smtp_info": "Deixe em branco para permitir todos os remetentes. Endereços e <br>redes IPv4/IPv6.",
- "allowed_protocols": "Protocolos permitidos para acesso direto do usuário (não afeta os protocolos de senha do aplicativo)",
+ "allowed_protocols": "Protocolos permitidos",
"backup_mx": "Domínio de retransmissão",
"bcc": "BCC",
"bcc_destination": "Destino BCC",
@@ -863,9 +974,9 @@
"recipient_map": "Mapa do destinatário",
"recipient_map_info": "Os mapas de destinatários são usados para substituir o endereço de destino em uma mensagem antes que ela seja entregue.",
"recipient_map_new": "Novo destinatário",
- "recipient_map_new_info": "O destino do mapa do destinatário deve ser um endereço de e-mail válido.",
+ "recipient_map_new_info": "O destino do mapa do destinatário deve ser um endereço de e-mail válido ou um nome de domínio.",
"recipient_map_old": "Destinatário original",
- "recipient_map_old_info": "O destino original do mapa de um destinatário deve ser um endereço de e-mail válido ou um nome de domínio.",
+ "recipient_map_old_info": "O destino original do mapa de destinatário deve ser um endereço de e-mail válido ou um nome de domínio.",
"recipient_maps": "Mapas de destinatários",
"relay_all": "Retransmita todos os destinatários",
"relay_unknown": "Retransmitir mailboxes desconhecidas",
@@ -922,7 +1033,10 @@
"username": "Nome de usuário",
"waiting": "Esperando",
"weekly": "Semanalmente",
- "yes": "✓"
+ "yes": "✓",
+ "iam": "Provedor de Identidade",
+ "internal": "Interno",
+ "force_tfa": "A2F"
},
"oauth2": {
"access_denied": "Faça login como proprietário da mailbox para conceder acesso via OAuth2.",
@@ -937,8 +1051,8 @@
"action": "Ação",
"atts": "Anexos",
"check_hash": "Arquivo de pesquisa hash @ VT",
- "confirm": "Confirme",
- "confirm_delete": "Confirme a exclusão desse elemento.",
+ "confirm": "Confirmar",
+ "confirm_delete": "Confirmar exclusão desse elemento.",
"danger": "Perigo",
"deliver_inbox": "Entregar na caixa de entrada",
"disabled_by_config": "A configuração atual do sistema desativa a funcionalidade de quarentena. Defina “retenções por mailbox” e um “tamanho máximo” para os elementos de quarentena.",
@@ -954,7 +1068,7 @@
"notified": "Notificado",
"qhandler_success": "Solicitação enviada com sucesso para o sistema. Agora você pode fechar a janela.",
"qid": "Respand AID",
- "qinfo": "O sistema de quarentena salvará as mensagens rejeitadas no banco de dados (o remetente <em>não</em> terá a impressão de uma mensagem entregue), bem como as mensagens, que são entregues como cópia na pasta Lixo eletrônico de uma mailbox.\n <br>“Aprenda como spam e exclua” aprenderá uma mensagem como spam por meio do Teorema de Bayes e também calculará hashes difusos para negar mensagens semelhantes no futuro.\n <br>Esteja ciente de que aprender várias mensagens pode ser demorado, dependendo do seu sistema. <br>Os elementos da lista negra são excluídos da quarentena.",
+ "qinfo": "O sistema de quarentena irá salvar no banco de dados os e-mails rejeitados (o remetente <em>não</em> terá a impressão de que o e-mail foi entregue), bem como os e-mails que são entregues como cópia na pasta de spam de uma mailbox.\n<br>“Aprender como spam e excluir” irá classificar a mensagem como spam por meio do Teorema de Bayes e também calcular hashes fuzzy para bloquear mensagens semelhantes no futuro.\n<br>Esteja ciente de que o aprendizado de múltiplas mensagens pode, dependendo do seu sistema, levar tempo. <br>Elementos na lista de bloqueio são excluídos da quarentena.",
"qitem": "Item de quarentena",
"quarantine": "Quarentena",
"quick_actions": "Ações",
@@ -974,7 +1088,7 @@
"rspamd_result": "Resultado do Rspamd",
"sender": "Remetente (SMTP)",
"sender_header": "Remetente (cabeçalho “De”)",
- "settings_info": "Quantidade máxima de elementos a serem colocados em quarentena: %s <br>Tamanho máximo do e-mail: %s MiB",
+ "settings_info": "Número máximo de elementos em quarentena (por caixa de correio): %s <br>Tamanho máximo do e-mail: %s MiB",
"show_item": "Mostrar item",
"spam": "Spam",
"spam_score": "Ponto",
@@ -1011,9 +1125,7 @@
},
"start": {
"help": "Mostrar/ocultar painel de ajuda",
- "imap_smtp_server_auth_info": "Use seu endereço de e-mail completo e o mecanismo de autenticação PLAIN. <br>\r\nSeus dados de login serão criptografados pela criptografia obrigatória do lado do servidor.",
- "mailcow_apps_detail": "Use um aplicativo mailcow para acessar seus e-mails, calendário, contatos e muito mais.",
- "mailcow_panel_detail": "<b>Os administradores de domínio</b> criam, modificam ou excluem mailboxes e aliases, alteram domínios e leem mais informações sobre seus domínios atribuídos. <br>\n<b>Os usuários de mailbox </b> podem criar aliases com limite de tempo (aliases de spam), alterar suas configurações de senha e filtro de spam."
+ "imap_smtp_server_auth_info": "Use seu endereço de e-mail completo e o mecanismo de autenticação PLAIN. <br>\r\nSeus dados de login serão criptografados pela criptografia obrigatória do lado do servidor."
},
"success": {
"acl_saved": "ACL para o objeto %s salvo",
@@ -1052,6 +1164,7 @@
"domain_removed": "O domínio %s foi removido",
"dovecot_restart_success": "O Dovecot foi reiniciado com sucesso",
"eas_reset": "Os dispositivos ActiveSync para o usuário %s foram redefinidos",
+ "f2b_banlist_refreshed": "O Banlist ID foi atualizado com sucesso.",
"f2b_modified": "As alterações nos parâmetros do Fail2ban foram salvas",
"forwarding_host_added": "O host de encaminhamento %s foi adicionado",
"forwarding_host_removed": "O host de encaminhamento %s foi removido",
@@ -1071,11 +1184,13 @@
"nginx_reloaded": "O Nginx foi recarregado",
"object_modified": "As alterações no objeto %s foram salvas",
"password_policy_saved": "A política de senha foi salva com sucesso",
+ "password_changed_success": "Alteração de senha realizada com sucesso",
"pushover_settings_edited": "Configurações de Pushover definidas com sucesso. Verifique as credenciais.",
"qlearn_spam": "A ID da mensagem %s foi detectada como spam e excluída",
"queue_command_success": "Comando de fila concluído com sucesso",
"recipient_map_entry_deleted": "A ID do mapa do destinatário %s foi excluída",
"recipient_map_entry_saved": "A entrada “%s” do mapa do destinatário foi salva",
+ "recovery_email_sent": "Email de recuperação enviado para %s",
"relayhost_added": "A entrada de mapa %s foi adicionada",
"relayhost_removed": "A entrada de mapa %s foi removida",
"reset_main_logo": "Redefinir para o logotipo padrão",
@@ -1099,11 +1214,14 @@
"verified_totp_login": "Login TOTP verificado",
"verified_webauthn_login": "Login verificado do WebAuthn",
"verified_yotp_login": "Login OTP verificado do Yubico",
- "f2b_banlist_refreshed": "O Banlist ID foi atualizado com sucesso."
+ "custom_login_modified": "Personalização de login foi salva com sucesso",
+ "iam_test_connection": "Conexão bem-sucedida",
+ "mailbox_renamed": "Caixa de correio foi renomeada de %s para %s"
},
"tfa": {
+ "authenticators": "Autenticadores",
"api_register": "%s usa a API Yubico Cloud. Obtenha uma chave de API para sua chave <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">aqui</a>",
- "confirm": "Confirme",
+ "confirm": "Confirmar",
"confirm_totp_token": "Confirme suas alterações inserindo o token gerado",
"delete_tfa": "Desativar o TFA",
"disable_tfa": "Desative o TFA até o próximo login bem-sucedido",
@@ -1116,7 +1234,7 @@
"reload_retry": "- (recarregue o navegador se o erro persistir)",
"scan_qr_code": "Escaneie o código a seguir com seu aplicativo autenticador ou insira o código manualmente.",
"select": "Por favor, selecione",
- "set_tfa": "Defina o método de autenticação de dois fatores",
+ "set_tfa": "Método de autenticação de dois fatores",
"start_webauthn_validation": "Iniciar validação",
"tfa": "Autenticação de dois fatores",
"tfa_token_invalid": "Token TFA inválido",
@@ -1127,7 +1245,11 @@
"waiting_usb_auth": "<i>Aguardando o dispositivo USB...</i> <br><br>Toque no botão no seu dispositivo USB agora.",
"waiting_usb_register": "<i>Aguardando o dispositivo USB...</i> <br><br>Digite sua senha acima e confirme seu registro tocando no botão no seu dispositivo USB.",
"yubi_otp": "Autenticação Yubico OTP",
- "authenticators": "Autenticadores"
+ "force_tfa": "Forçar o cadastro de 2FA no login",
+ "force_tfa_info": "O usuário será obrigado a configurar a autenticação de dois fatores antes de acessar o painel.",
+ "setup_title": "Autenticação de Dois Fatores Obrigatória",
+ "setup_required": "Sua conta exige autenticação de dois fatores. Configure um método de 2FA para continuar.",
+ "cancel_setup": "Cancelar e sair"
},
"user": {
"action": "Ação",
@@ -1152,6 +1274,7 @@
"apple_connection_profile_complete": "Esse perfil de conexão inclui parâmetros IMAP e SMTP, bem como caminhos CalDAV (calendários) e CardDAV (contatos) para um dispositivo Apple.",
"apple_connection_profile_mailonly": "Esse perfil de conexão inclui parâmetros de configuração IMAP e SMTP para um dispositivo Apple.",
"apple_connection_profile_with_app_password": "Uma nova senha de aplicativo é gerada e adicionada ao perfil para que nenhuma senha precise ser inserida ao configurar seu dispositivo. Não compartilhe o arquivo, pois ele concede acesso total à sua mailbox.",
+ "attribute": "Atributo",
"change_password": "Alterar senha",
"change_password_hint_app_passwords": "Sua conta tem %d senhas de aplicativos que não serão alteradas. Para gerenciá-las, acesse a guia Senhas do aplicativo.",
"clear_recent_successful_connections": "Conexões bem-sucedidas e claras",
@@ -1161,10 +1284,11 @@
"created_on": "Criado em",
"daily": "Diariamente",
"day": "dia",
+ "description": "Descrição",
"delete_ays": "Confirme o processo de exclusão.",
"direct_aliases": "Endereços de alias diretos",
"direct_aliases_desc": "Os endereços de alias diretos são afetados pelo filtro de spam e pelas configurações da política TLS.",
- "direct_protocol_access": "Esse usuário da mailbox tem <b>acesso externo direto</b> aos seguintes protocolos e aplicativos. Essa configuração é controlada pelo administrador. As senhas de aplicativos podem ser criadas para conceder acesso a protocolos e aplicativos individuais. <br>O botão “Login no webmail” fornece login único no SoGo e está sempre disponível.",
+ "direct_protocol_access": "Este usuário da mailbox possui <b>acesso direto e externo</b> aos seguintes protocolos e aplicações. Esta configuração é controlada pelo seu administrador. Senhas de aplicativo podem ser criadas para conceder acesso a protocolos e aplicações específicos.<br>O botão “Webmail” fornece login único (SSO) para o SOGo e está sempre disponível.",
"eas_reset": "Redefinir o cache do dispositivo ActiveSync",
"eas_reset_help": "Em muitos casos, uma redefinição do cache do dispositivo ajudará a recuperar um perfil quebrado do ActiveSync. <br><b>Atenção:</b> Todos os elementos serão baixados novamente!",
"eas_reset_now": "Reinicie agora",
@@ -1205,10 +1329,11 @@
"no_last_login": "Nenhuma informação de login da última interface",
"no_record": "Sem registro",
"open_logs": "Registros abertos",
- "open_webmail_sso": "Faça login no webmail",
+ "open_webmail_sso": "Webmail",
"password": "Senha",
"password_now": "Senha atual (confirme as alterações)",
"password_repeat": "Senha (repetição)",
+ "password_reset_info": "Se nenhum email de recuperação for definido, esta função não poderá ser utilizada.",
"pushover_evaluate_x_prio": "Escale e-mails de alta prioridade [<code>X-Priority:</code> 1]",
"pushover_info": "As configurações de notificação push serão aplicadas a todos os e-mails limpos (sem spam) entregues a <b>%s</b>, incluindo aliases (compartilhados, não compartilhados, marcados).",
"pushover_only_x_prio": "Considere somente e-mails de alta prioridade [<code>X-Priority: 1</code>]",
@@ -1219,6 +1344,7 @@
"pushover_sound": "Som",
"pushover_vars": "Quando nenhum filtro de remetente for definido, todos os e-mails serão considerados. <br>Os filtros Regex, bem como as verificações exatas do remetente, podem ser definidos individualmente e serão considerados sequencialmente. Eles não dependem um do outro. <br>Variáveis utilizáveis para texto e título (observe as políticas de proteção de dados)",
"pushover_verify": "Verifique as credenciais",
+ "pw_recovery_email": "Email de recuperação de senha",
"q_add_header": "Pasta de lixo eletrônico",
"q_all": "Todas as categorias",
"q_reject": "Rejeitado",
@@ -1238,12 +1364,12 @@
"sogo_profile_reset": "Redefinir perfil SoGo",
"sogo_profile_reset_help": "Isso destruirá o perfil SoGo de um usuário e <b>excluirá todos os dados de contato e calendário irrecuperáveis</b>.",
"sogo_profile_reset_now": "Redefina o perfil agora",
- "spam_aliases": "Aliases de e-mail temporários",
+ "spam_aliases": "Aliases de e-mail de spam",
"spam_score_reset": "Redefinir para o padrão do servidor",
"spamfilter": "Filtro de spam",
"spamfilter_behavior": "Avaliação",
- "spamfilter_bl": "Lista negra",
- "spamfilter_bl_desc": "Endereços de e-mail na lista negra para <b>sempre</b> serem classificados como spam e rejeitados. E-mails rejeitados <b>não</b> serão copiados para a quarentena. Podem ser usados curingas. Um filtro só é aplicado a aliases diretos (aliases com uma única caixa de correio de destino), excluindo aliases abrangentes e a própria mailbox.",
+ "spamfilter_bl": "Lista de bloqueio",
+ "spamfilter_bl_desc": "Endereços de e-mail na lista de bloqueio para <b>sempre</b> classificar como spam e rejeitados. E-mails rejeitados <b>não</b> serão copiados para a quarentena. Coringas podem ser utilizados. O filtro é aplicado apenas a aliases diretos (aliases com uma única mailbox de destino), excluindo aliases catch-all e a própria mailbox.",
"spamfilter_default_score": "Valores padrão",
"spamfilter_green": "Verde: esta mensagem não é spam",
"spamfilter_hint": "O primeiro valor descreve a “pontuação baixa de spam”, o segundo representa a “alta pontuação de spam”.",
@@ -1254,8 +1380,8 @@
"spamfilter_table_empty": "Não há dados para exibir",
"spamfilter_table_remove": "remover",
"spamfilter_table_rule": "Regra",
- "spamfilter_wl": "Lista branca",
- "spamfilter_wl_desc": "Os endereços de e-mail incluídos na lista branca são programados para <b>nunca</b> serem classificados como spam. Podem ser usados curingas. Um filtro só é aplicado a aliases diretos (aliases com uma única mailbox de destino), excluindo aliases abrangentes e a própria mailbox.",
+ "spamfilter_wl": "Lista de permissões",
+ "spamfilter_wl_desc": "Endereços de e-mail na lista de permissões são configurados para <b>nunca</b> serem classificados como spam. Coringas podem ser utilizados. O filtro é aplicado apenas a aliases diretos (aliases com uma única mailbox de destino), excluindo aliases catch-all e a própria mailbox.",
"spamfilter_yellow": "Amarelo: esta mensagem pode ser spam, será marcada como spam e movida para sua pasta de lixo eletrônico",
"status": "Status",
"sync_jobs": "Trabalhos de sincronização",
@@ -1269,7 +1395,7 @@
"syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Não é possível se conectar ao servidor remoto",
"syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Nome de usuário ou senha incorretos",
"tag_handling": "Definir o tratamento para e-mails marcados",
- "tag_help_example": "Exemplo de um endereço de e-mail marcado: me <b>+Facebook</b> @example .org",
+ "tag_help_example": "Exemplo de endereço de e-mail com tag: eu+Facebook</b>@exemplo.org",
"tag_help_explain": "Na subpasta: uma nova subpasta com o nome da tag será criada abaixo da CAIXA DE ENTRADA (“Caixa de entrada/Facebook”). <br>\r\nNo assunto: o nome das tags será anexado ao assunto do e-mail, por exemplo: “[Facebook] Minhas notícias”.",
"tag_in_none": "Não faça nada",
"tag_in_subfolder": "Na subpasta",
@@ -1282,6 +1408,7 @@
"tls_policy_warning": "<strong>Aviso:</strong> Se você decidir impor a transferência de e-mail criptografada, poderá perder e-mails. <br>As mensagens que não satisfizerem a política serão devolvidas com uma falha grave pelo sistema de correio. <br>Essa opção se aplica ao seu endereço de e-mail principal (nome de login), a todos os endereços derivados de domínios de alias, bem como aos endereços de alias <b>com apenas essa única mailbox </b> como destino.",
"user_settings": "Configurações do usuário",
"username": "Nome de usuário",
+ "value": "Valor",
"verify": "Verificar",
"waiting": "Esperando",
"week": "semana",
@@ -1290,8 +1417,14 @@
"with_app_password": "com senha do aplicativo",
"year": "ano",
"years": "anos",
- "attribute": "Atributo",
- "value": "Valor"
+ "authentication": "Autenticação",
+ "overview": "Visão geral",
+ "protocols": "Protocolos",
+ "tfa_info": "A autenticação de dois fatores ajuda a proteger sua conta. Se você habilitá-la, precisará de senhas de aplicativo para fazer login em aplicativos ou serviços que não suportam autenticação de dois fatores (por exemplo, clientes de email).",
+ "expire_never": "Nunca expirar",
+ "forever": "Para sempre",
+ "pw_update_required": "Sua conta exige a alteração de senha. Defina uma nova senha para continuar.",
+ "spam_aliases_info": "Um alias de spam é um endereço de e-mail temporário que pode ser usado para proteger endereços de e-mail reais. <br>Opcionalmente, pode-se definir um tempo de expiração para que o alias seja automaticamente desativado após o período definido, descartando efetivamente endereços que tenham sido abusados ou vazados."
},
"warning": {
"cannot_delete_self": "Não é possível excluir o usuário conectado",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-pt.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-pt.json
index bfd640f..64f85dd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-pt.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.pt-pt.json
@@ -1,7 +1,7 @@
{
"add": {
"active": "Ativo",
- "add": "Salvar",
+ "add": "Guardar",
"alias_address": "Apelidos:",
"alias_address_info": "<small>Endereço de email completo ou @example.com, para uma conta coringa -catch all. (separado por vírgula). <b>apenas domínios cadastrados</b>.</small>",
"alias_domain": "Encaminhamento de Domínio",
@@ -12,12 +12,12 @@
"domain_quota_m": "Total de espaço por domínio (MiB):",
"full_name": "Nome:",
"mailbox_quota_m": "Máximo espaço por conta (MiB):",
- "mailbox_username": "Usuário (primeira parte do endereço de email):",
+ "mailbox_username": "Utilizador (primeira parte do endereço de email):",
"max_aliases": "Máximo de apelidos:",
"max_mailboxes": "Máximo de contas:",
"password": "Senha:",
"password_repeat": "Confirmar a senha (repetir):",
- "port": "Port",
+ "port": "Porta",
"quota_mb": "Espaço (MiB):",
"relay_all": "Relay para todas as contas",
"relay_all_info": "<small>Se <b>não</b> selecionar para retransmitir todas as contas, você deve adicionar uma (\"blind\") para cada conta que será direcionada.</small>",
@@ -27,13 +27,26 @@
"target_address": "Encaminhar para:",
"target_address_info": "<small>Endereço de email completo (separado por vírgulas).</small>",
"target_domain": "Domínio de Destino:",
- "username": "Administrador"
+ "username": "Nome de utilizador",
+ "app_name": "Nome da App",
+ "destination": "Destino",
+ "generate": "gerar",
+ "private_comment": "Comentário privado",
+ "inactive": "Inativo",
+ "public_comment": "Comentário público",
+ "sieve_desc": "Breve descrição",
+ "sieve_type": "Tipo de filtro",
+ "subscribeall": "Subscrever todas as pastas",
+ "syncjob": "Adicionar sincronização",
+ "validate": "Validar",
+ "validation_success": "Validado com sucesso",
+ "app_passwd_protocols": "Protocolos permitidos para senha de aplicação"
},
"admin": {
"access": "Acessos",
"action": "Ação",
"active": "Ativo",
- "add": "Salvar",
+ "add": "Adicionar",
"add_domain_admin": "Adicionar administrador de domínio(s)",
"admin": "Administrador",
"admin_details": "Editar informações do administrator",
@@ -58,7 +71,47 @@
"search_domain_da": "Selecione o(s) domínio(s)",
"spamfilter": "Filtro de Spam",
"unchanged_if_empty": "Deixar em branco para não alterar",
- "username": "Administrador"
+ "username": "Administrador",
+ "add_row": "Adicionar linha",
+ "add_transport": "Adicionar transporte",
+ "change_logo": "Alterar logo",
+ "filter": "Filtro",
+ "iam_port": "Porta",
+ "iam_use_ssl": "Usar SSL",
+ "iam_version": "Versão",
+ "import": "Importar",
+ "import_private_key": "Importar chave privada",
+ "message": "Mensagem",
+ "dkim_private_key": "Chave privada",
+ "customize": "Personalizar",
+ "destination": "Destino",
+ "dkim_from": "De",
+ "activate_api": "Ativar API",
+ "add_admin": "Adicionar administrador",
+ "admins": "Administradores",
+ "advanced_settings": "Configurações avançadas",
+ "api_key": "Chave API",
+ "api_read_only": "Acesso leitura",
+ "api_read_write": "Acesso leitura e escrita",
+ "login_page": "Página de login",
+ "dkim_key_missing": "Chave em falta",
+ "dkim_key_valid": "Chave válida",
+ "dkim_to": "Para",
+ "domain_admin": "Administrador de dominio",
+ "domain_s": "Dominio(s)",
+ "duplicate": "Duplicar",
+ "duplicate_dkim": "Duplicar registo DKIM",
+ "empty": "Sem resultados",
+ "excludes": "Excluir estes recipientes",
+ "f2b_filter": "Filtros de regex",
+ "from": "De",
+ "generate": "gerar",
+ "html": "HTML",
+ "iam_import_users": "Importar Utilizadores",
+ "ui_header_announcement_content": "Texto (HTML permitido)",
+ "ui_footer": "Rodapé (HTML permitido)",
+ "activate_send": "Ativar botão de envio",
+ "help_text": "Anular texto de ajuda abaixo da máscara de login (HTML permitido)"
},
"danger": {
"access_denied": "Acesso negado ou dados inválidos",
@@ -96,8 +149,11 @@
"sender_acl_invalid": "Campo Sender ACL é inválido",
"target_domain_invalid": "O endereço de Domínio Destino é inválido",
"targetd_not_found": "Domínio de Destino não encontrado",
- "username_invalid": "Nome de usuário inválido",
- "validity_missing": "Você deve definir um período de validade"
+ "username_invalid": "Nome de utilizador inválido",
+ "validity_missing": "Você deve definir um período de validade",
+ "comment_too_long": "Comentário demasiado longo, máximo 160 chars permitidos",
+ "ip_list_empty": "Lista de IPs permitidos não pode estar vazia",
+ "last_key": "A última tecla não pode ser apagada, por favor desactivar a TFA."
},
"edit": {
"active": "Ativo",
@@ -129,7 +185,9 @@
"target_domain": "Domínio de Destino:",
"title": "Editar dos Objetos",
"unchanged_if_empty": "Deixar em branco para não modificar",
- "username": "Administrador"
+ "username": "Administrador",
+ "app_passwd_protocols": "Protocolos permitidos para palavra-passe de aplicação",
+ "allowed_protocols": "Protocolos permitidos para acesso direto do utilizador (não afeta os protocolos de palavra-passe da aplicação)"
},
"footer": {
"loading": "Aguarde..."
@@ -138,7 +196,7 @@
"administration": "Administração",
"email": "E-Mail",
"mailcow_config": "Configuração",
- "user_settings": "Configurações do usuário"
+ "user_settings": "Configurações do utilizador"
},
"info": {
"no_action": "Nenhuma ação foi definida"
@@ -147,7 +205,7 @@
"delayed": "Sua entrada será atrasada por %s segundos.",
"login": "Entrar",
"password": "Senha",
- "username": "Usuário"
+ "username": "Utilizador"
},
"mailbox": {
"action": "Ação",
@@ -186,20 +244,22 @@
"target_domain": "Domínio Destino",
"tls_enforce_in": "Forçar TLS na entrada",
"tls_enforce_out": "Forçar TLS na saída",
- "username": "Usuário"
+ "username": "Utilizador",
+ "allowed_protocols": "Protocolos permitidos",
+ "activate": "Ativar",
+ "deactivate": "Desativar"
},
"quarantine": {
"action": "Ação",
- "remove": "Remover"
+ "remove": "Remover",
+ "check_hash": "Pesquisar hash de ficheiro @ VT"
},
"queue": {
"queue_manager": "Queue Manager"
},
"start": {
"help": "Mostrar/Ocultar painel de ajuda",
- "imap_smtp_server_auth_info": "Utilize o endereço de email completo com o método de autentucação PLAIN.<br>\r\nOs dados de login serão encryptados pelo servidor.",
- "mailcow_apps_detail": "Use um mailcow app para acessar seus emails, calendário, contatos e outras informações.",
- "mailcow_panel_detail": "<b>Administradores:</b> podem criar, alterar ou apagar contas e apelidos , alterar domínios e outras informações de seus domínios atribuídos.<br>\r\n\t<b>Usuários:</b> podem criar apelidos por tempo determinado , alterar senha e configuração do nível do filtro de spam."
+ "imap_smtp_server_auth_info": "Utilize o endereço de email completo com o método de autentucação PLAIN.<br>\r\nOs dados de login serão encryptados pelo servidor."
},
"success": {
"admin_modified": "Administrador alterado com sucesso",
@@ -236,6 +296,7 @@
"aliases_send_as_all": "Não verificar remetente para os domínios",
"change_password": "Alterar senha",
"day": "Dia",
+ "description": "Descrição",
"edit": "Editar",
"hour": "Hora",
"hours": "Horas",
@@ -267,9 +328,35 @@
"tls_enforce_out": "Forçar TLS na saída",
"tls_policy": "Regras de Encryptação",
"tls_policy_warning": "<strong>Aviso:</strong> Se você selecionar para forçar o envio encryptado , alguns emails poderão ser rejeitados.<br>Mensages que não satisfizerem as politicas dos outros servidores serão rejeitadas definitivamente.",
- "user_settings": "Configurações do usuário",
+ "user_settings": "Configurações do utilizador",
"username": "Administrador",
"week": "Semana",
- "weeks": "Semanas"
+ "weeks": "Semanas",
+ "aliases_also_send_as": "Também autorizado a enviar como utilizador",
+ "app_hint": "As senhas de aplicação são senhas alternativas para o seu login IMAP, SMTP, CalDAV, CardDAV e EAS. O nome de utilizador permanece inalterado. O webmail SOGo não está disponível através de passwords de aplicação.",
+ "allowed_protocols": "Protocolos permitidos"
+ },
+ "acl": {
+ "tls_policy": "Política de TLS",
+ "quarantine_attachments": "Anexos de quarentena",
+ "filters": "Filtros",
+ "smtp_ip_access": "Mudar anfitriões permitidos para SMTP",
+ "app_passwds": "Gerenciar senhas de aplicativos"
+ },
+ "warning": {
+ "no_active_admin": "Não é possível desactivar o último administrador activo"
+ },
+ "tfa": {
+ "u2f_deprecated": "Parece que a sua chave foi registada usando o método U2F depreciado. Desactivaremos dois factores-autenticação para si e apagaremos a sua Chave.",
+ "none": "Desativar"
+ },
+ "datatables": {
+ "search": "Procurar:",
+ "info": "A mostrar _START_ a _END_ de _TOTAL_ entradas",
+ "infoEmpty": "A mostrar 0 a 0 de 0 entradas",
+ "aria": {
+ "sortAscending": ": activar para ordenar a coluna ascendente",
+ "sortDescending": ": activar para ordenar a coluna descendente"
+ }
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ro-ro.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ro-ro.json
index 90c96c2..8b002fd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ro-ro.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ro-ro.json
@@ -481,7 +481,6 @@
"external_logs": "Jurnale externe",
"history_all_servers": "Istoric (toate serverele)",
"in_memory_logs": "Jurnale din memorie",
- "jvm_memory_solr": "Memorie utilizată de JVM",
"last_modified": "Ultima modificare",
"log_info": "<p><b>jurnalele din memorie</b> pentru mailcow sunt colectate în listele Redis și trimise la LOG_LINES (%d) în fiecare minut pentru a reduce ciocnirea.\n <br>Jurnalele din memorie nu sunt menite a fi persistente. Toate aplicațiile care înregistrează jurnale în memorie, înregistrează de asemenea jurnale în daemonul Docker și, prin urmare, în driverul de jurnale implicit.\n <br>Tipul de jurnal din memorie trebuie utilizat pentru depanarea problemelor minore cu containerele.</p>\n <p><b>Jurnalele externe</b> sunt colectate prin API-ul aplicației respective.</p>\n <p><b>Jurnalele statice</b> sunt, în majoritate, jurnale de activitate care nu sunt înregistrate în Docker, dar trebuie să fie persistente (cu excepția jurnalelor API).</p>",
"login_time": "Moment",
@@ -490,8 +489,6 @@
"restart_container": "Repornire",
"service": "Serviciu",
"size": "Mărime",
- "solr_dead": "Solr începe, este invalid sau s-a oprit.",
- "solr_status": "Stare Solr",
"started_at": "Pornit la",
"started_on": "Început pe",
"static_logs": "Jurnale statice",
@@ -607,8 +604,8 @@
"sieve_desc": "Descriere scurtă",
"sieve_type": "Tip filtru",
"skipcrossduplicates": "Sari peste mesajele duplicate din toate folderele (primul venit, primul servit)",
- "sogo_access": "Acordați acces direct de conectare la SOGo",
- "sogo_access_info": "Conectarea unică din interfața de administrare a e-mailului continuă să funcționeze. Această setare nu afectează accesul la toate celelalte servicii și nici nu șterge sau modifică profilul SOGo existent al unui utilizator.",
+ "sogo_access": "Redirecționare directă către SOGo",
+ "sogo_access_info": "După logare, utilizatorul este redirecționat automat către SOGo.",
"sogo_visible": "Aliasul este vizibil în SOGo",
"sogo_visible_info": "Această opțiune afectează doar obiecte, care pot fi afișate în SOGo (adrese alias partajate sau ne-partajate cu cel puțin o căsuță poștală locală). Dacă este ascuns, un alias nu va apărea ca expeditor selectabil în SOGo.",
"spam_alias": "Crează sau modifică adrese alias limitate în funcție de timp",
@@ -677,7 +674,7 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Autentificare",
"mobileconfig_info": "Autentificați-vă cu adresa de email pentru a descărca profilul de conexiune Apple.",
- "other_logins": "Autentificare cu cheie",
+ "other_logins": "sau autentificare cu",
"password": "Parolă",
"username": "Nume de utilizator"
},
@@ -792,7 +789,7 @@
"recipient_map": "Hartă destinatar",
"recipient_map_info": "Hărțile destinatarilor sunt folosite pentru a înlocui adresa de destinație a unui mesaj înainte de a fi livrat.",
"recipient_map_new": "Destinatar nou",
- "recipient_map_new_info": "Destinația hărții destinatarului trebuie să fie o adresă de email validă.",
+ "recipient_map_new_info": "Destinația hărții destinatarului trebuie să fie adrese de email valide sau nume de domeniu.",
"recipient_map_old": "Destinatar original",
"recipient_map_old_info": "Destinația originală a hărților destinatarilor trebuie să fie adrese de email valide sau nume de domeniu.",
"recipient_maps": "Hărți destinatar",
@@ -924,9 +921,7 @@
},
"start": {
"help": "Afișează/Ascunde panoul de ajutor",
- "imap_smtp_server_auth_info": "Utilizează adresa completă de email și mecanismul de autentificare SIMPLU.<br>\nDatele tale de conectare vor fi criptate prin criptarea obligatorie de la server.",
- "mailcow_apps_detail": "Utilizează o aplicație mailcow pentru a accesa mailurile, agenda, contactele și altele.",
- "mailcow_panel_detail": "<b>Administratorii de domeniu</b> creează, modifică sau șterg căsuțe poștale și aliasuri, modifică domenii și citesc informații suplimentare despre domeniile lor atribuite.<br>\n<b>Utilizatorii cu cutii poștale</b> pot să creeze aliasuri limitate în timp (aliasuri spam), să își schimbe parola și setările pentru filtrul de spam."
+ "imap_smtp_server_auth_info": "Utilizează adresa completă de email și mecanismul de autentificare SIMPLU.<br>\nDatele tale de conectare vor fi criptate prin criptarea obligatorie de la server."
},
"success": {
"acl_saved": "ACL pentru obiectul %s a fost salvat",
@@ -1064,10 +1059,11 @@
"created_on": "Creat în",
"daily": "Zilnic",
"day": "zi",
+ "description": "Descriere",
"delete_ays": "Vă rugăm să confirmați stergerea.",
"direct_aliases": "Adrese alias directe",
"direct_aliases_desc": "Adresele alias directe sunt afectate de setările filtrului de spam și ale politicii TLS.",
- "direct_protocol_access": "Acest utilizator are <b>acces direct, extern</b> la următoarele protocoale și aplicații. Această setare este controlată de administratorul dvs. Parolele pentru aplicații pot fi create pentru a acorda acces la protocoale și aplicații individuale.<br>Butonul \"Conectați-vă la webmail\" oferă conectare unică la SOGo și este întotdeauna disponibil.",
+ "direct_protocol_access": "Acest utilizator are <b>acces direct, extern</b> la următoarele protocoale și aplicații. Această setare este controlată de administratorul dvs. Parolele pentru aplicații pot fi create pentru a acorda acces la protocoale și aplicații individuale.<br>Butonul \"Webmail\" oferă conectare unică la SOGo și este întotdeauna disponibil.",
"eas_reset": "Resetează memoria cache a dispozitivului ActiveSync",
"eas_reset_help": "În multe cazuri, resetarea cache-ului dispozitivului va ajuta la recuperarea unui profil ActiveSync defect.<br><b>Atenţie:</b> Toate elementele vor fi descărcate din nou!",
"eas_reset_now": "Resetează acum",
@@ -1108,7 +1104,7 @@
"no_last_login": "Nu există informații despre ultima autentificare în interfață",
"no_record": "Nici o înregistrare",
"open_logs": "Deschide jurnalele",
- "open_webmail_sso": "Autentificare în webmail",
+ "open_webmail_sso": "Webmail",
"password": "Parolă",
"password_now": "Parola curentă (confirmă modificările)",
"password_repeat": "Parolă (repetă)",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ru-ru.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ru-ru.json
index 5891b6a..58353fb 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.ru-ru.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.ru-ru.json
@@ -2,7 +2,7 @@
"acl": {
"alias_domains": "Создание псевдонимов домена",
"app_passwds": "Пароли приложений",
- "bcc_maps": "Правила BBC",
+ "bcc_maps": "Правила BCC",
"delimiter_action": "Обработка тегированной почты",
"domain_desc": "Изменение описания домена",
"domain_relayhost": "Изменение промежуточных узлов для домена",
@@ -14,6 +14,7 @@
"prohibited": "Запрещено правилами ACL",
"protocol_access": "Настройка разрешенных протоколов",
"pushover": "Pushover API",
+ "pw_reset": "Разрешить пользователям mailcow восстановление паролей",
"quarantine": "Карантин - действия",
"quarantine_attachments": "Карантин - вложения",
"quarantine_category": "Категория уведомлений о спаме",
@@ -41,13 +42,14 @@
"alias_domain": "Псевдоним домена",
"alias_domain_info": "<small>Действительные имена доменов, раздёленные запятыми.</small>",
"app_name": "Название приложения",
+ "app_passwd_protocols": "Разрешенные протоколы для пароля приложения",
"app_password": "Добавить пароль приложения",
"automap": "Автоматическое слияние папок (\"Sent items\", \"Sent\" => \"Sent\" etc.)",
"backup_mx_options": "Параметры резервного MX",
"bcc_dest_format": "Место назначения BCC должно быть единственным действительным адресом электронной почты.<br>Если вам нужно отправить копию на несколько адресов - используйте псевдоним.",
"comment_info": "Приватный комментарий не виден пользователям, а публичный - отображается рядом с псевдонимом в личном кабинете пользователя.",
"custom_params": "Пользовательские параметры",
- "custom_params_hint": "Верно: --param=xy, не верно: --param xy",
+ "custom_params_hint": "Верно: --param=xy, неверно: --param xy",
"delete1": "Удаление из источника после завершения",
"delete2": "Удаление писем по месту назначения, которые не находятся на исходном",
"delete2duplicates": "Удаление дубликатов по назначению",
@@ -57,6 +59,7 @@
"domain": "Домен",
"domain_matches_hostname": "Домен %s соответствует имени хоста",
"domain_quota_m": "Квота домена (MiB)",
+ "dry": "Имитировать синхронизацию",
"enc_method": "Метод шифрования",
"exclude": "Исключить объекты (regex)",
"full_name": "Полное имя",
@@ -88,7 +91,7 @@
"relay_all_info": "↪<small>Если вы решите <b>не</b> ретранслировать всех получателей, вам нужно будет добавить (\"слепой\") почтовый адрес для каждого получателя, которого следует ретранслировать.</small>",
"relay_domain": "Ретрансляция этого домена",
"relay_transport_info": "<div class=\"badge fs-6 bg-info\">Инфо</div> Вы можете настроить собственный транспорт для домена. Если такой настройки нет, то доставка будет выполнена на основе MX записей.",
- "relay_unknown_only": "Ретрансляция только не существующих почтовых ящиков. Почта к существующим почтовым ящикам будут доставляться локально.",
+ "relay_unknown_only": "Ретрансляция только несуществующих почтовых ящиков. Почта существующих почтовых ящиков будут доставляться локально.",
"relayhost_wrapped_tls_info": "Пожалуйста <b>не</b> используйте TLS порты (в основном это 465 порт).<br>\r\nИспользуйте любой <b>не</b> TLS порт который поддерживает STARTTLS. А для защиты от downgrate атак - настройке принудительную политику TLS.",
"select": "Пожалуйста, выберите...",
"select_domain": "Пожалуйста, сначала выберите домен",
@@ -98,6 +101,7 @@
"subscribeall": "Подписаться на все папки и подпапки",
"syncjob": "Добавить задание синхронизации",
"syncjob_hint": "Пароли к вашему аккаунту будут сохранены на сервере в виде простого текста!",
+ "tags": "Теги",
"target_address": "Владельцы псевдонима",
"target_address_info": "<small>Адреса почтовых ящиков, разделенные запятыми.</small>",
"target_domain": "Целевой домен",
@@ -106,9 +110,9 @@
"username": "Имя пользователя",
"validate": "Проверить",
"validation_success": "Проверка прошла успешно",
- "tags": "Теги",
- "app_passwd_protocols": "Разрешенные протоколы для пароля приложения",
- "dry": "Имитировать синхронизацию"
+ "internal": "Внутренний",
+ "internal_info": "Внутренние псевдонимы доступны только из самого домена или доменов-псевдонимов.",
+ "sender_allowed": "Разрешить отправку с этим псевдонимом"
},
"admin": {
"access": "Настройки доступа",
@@ -134,6 +138,8 @@
"admins": "Администраторы",
"admins_ldap": "Администраторы LDAP",
"advanced_settings": "Расширенные настройки",
+ "allowed_methods": "Access-Control-Allow-Methods",
+ "allowed_origins": "Access-Control-Allow-Origin",
"api_allow_from": "Список IP-адресов для доступа к API (разделенных запятой или новой строкой)",
"api_info": "API находится в стадии разработки. Документация находится по адресу <a href=\"/api\">/api</a>",
"api_key": "Ключ API",
@@ -150,6 +156,8 @@
"change_logo": "Изменить логотип",
"configuration": "Глобальные настройки",
"convert_html_to_text": "Сконвертировать HTML в обычный текст",
+ "copy_to_clipboard": "Текст скопирован в буфер обмена!",
+ "cors_settings": "Настройки CORS",
"credentials_transport_warning": "<b>Предупреждение</b>: добавление новой записи перезапишет учетные данные для всех записей с таким же <i>следующим хостом</i>.",
"customer_id": "ID клиента",
"customize": "Персонализация",
@@ -178,16 +186,20 @@
"empty": "Пусто",
"excludes": "Исключает этих получателей",
"f2b_ban_time": "Время бана (в секундах)",
- "f2b_blacklist": "Черный список подсетей/хостов",
+ "f2b_ban_time_increment": "Время бана увеличивается с каждым баном",
+ "f2b_blacklist": "Черный список сетей/хостов",
"f2b_filter": "Правила фильтрации с помощью регулярных выражений",
"f2b_list_info": "Хосты или подсети, занесенные в черный список, всегда будут перевешивать объекты из белого списка. <b>Обновление списка займет несколько секунд.</b>",
+ "f2b_manage_external": "Внешнее управление Fail2Ban",
+ "f2b_manage_external_info": "Fail2ban по-прежнему будет вести банлист, но не будет активно устанавливать правила для блокировки трафика. Используйте сгенерированный ниже банлист для внешнего блокирования трафика.",
"f2b_max_attempts": "Максимальное количество попыток",
+ "f2b_max_ban_time": "Максимальное время блокировки",
"f2b_netban_ipv4": "Размер подсети IPv4 для применения бана (8-32)",
"f2b_netban_ipv6": "Размер подсети IPv6 для применения бана (8-128)",
"f2b_parameters": "Настройки Fail2ban",
"f2b_regex_info": "Журналы которые принимаются во внимание: SOGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Промежуток времени для следующего бана (в секундах)",
- "f2b_whitelist": "Белый список подсетей/хостов",
+ "f2b_whitelist": "Белый список сетей/хостов",
"filter_table": "Поиск",
"forwarding_hosts": "Переадресация хостов",
"forwarding_hosts_add_hint": "Можно указывать: IPv4/IPv6 подсети в нотации CIDR, имена хостов (которые будут разрешаться в IP-адреса) или доменные имена (которые будут решаться с IP-адресами путем запроса SPF записей или, в случае их отсутствия - запросом MX записей).",
@@ -207,14 +219,19 @@
"include_exclude": "Включить/Исключить",
"include_exclude_info": "По умолчанию - без выбора - <b>все почтовые ящики</b> адресованы",
"includes": "Включить этих получателей",
+ "ip_check": "Проверить IP",
+ "ip_check_disabled": "Проверка IP-адресов отключена. Вы можете включить её в разделе <br> <strong>Система > Конфигурация > Параметры > Персонализация</strong>.",
+ "ip_check_opt_in": "Согласие на использование сторонних служб <strong>ipv4.mailcow.email</strong> и <strong>ipv6.mailcow.email</strong> для разрешения внешних IP-адресов.",
"is_mx_based": "На основе MX",
"last_applied": "Посл. применение",
- "license_info": "Лицензия не обязательна, но её приобретение помогает дальнейшему развитию mailcow.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Зарегистрируйте свой GUID здесь</a> или <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Заказать поддержку\">приобретите поддержку для вашей установки mailcow.</a>",
+ "license_info": "Лицензия необязательна, но её приобретение помогает дальнейшему развитию mailcow.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">Зарегистрируйте свой GUID здесь</a> или <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Заказать поддержку\">приобретите поддержку для вашей установки mailcow.</a>",
"link": "Ссылка",
"loading": "Пожалуйста, подождите...",
"login_time": "Время входа",
- "logo_info": "Ваше изображение будет масштабироваться до высоты 40px для верхней панели навигации и до 250px ширины для стартовой страницы. <br>Рекомендуется использовать векторную графику, на пример: .svg.",
- "lookup_mx": "Назначение на основе резовинга MX записи по регулярному выражению (<code>.*\\.example\\.com$</code> для маршрутизации всей почты через этот хост, если MX заканчивающийся на example.com)",
+ "logo_dark_label": "Инвертированный для темного режима",
+ "logo_info": "Ваше изображение будет масштабироваться до высоты 40px для верхней панели навигации и до 250px ширины для стартовой страницы. <br>Рекомендуется использовать векторную графику, например: .svg.",
+ "logo_normal_label": "Обычный",
+ "lookup_mx": "Назначение - регулярное выражение для сопоставления с именем MX (<code>.*\\.google\\.com</code> для направления всей почты, адресованной MX, заканчивающейся на google.com, через этот хоп)",
"main_name": "Название для \"mailcow UI\"",
"merged_vars_hint": "Серым цветом выделены строки полученные из <code>vars.(local.)inc.php</code>, они не могут быть изменены.",
"message": "Сообщение",
@@ -224,15 +241,16 @@
"no_active_bans": "В данный момент нет забаненных подсетей/хостов",
"no_new_rows": "Нет доступных строк",
"no_record": "Нет записей",
- "oauth2_client_id": "ID клиента",
- "oauth2_apps": "Приложения OAuth2",
"oauth2_add_client": "Добавить клиента OAuth2",
+ "oauth2_apps": "Приложения OAuth2",
+ "oauth2_client_id": "ID клиента",
"oauth2_client_secret": "Секретный ключ пользователя",
"oauth2_info": "Реализация OAuth2 поддерживает предоставления кодов авторизации и выдает токены продления сессии.<br>\r\nСервер также автоматически выдает новый токен продления сессии, после того, как предыдущий был использован.<br><br>\r\n• Scope по умолчанию: <i>profile</i>. Только пользователи почтовых аккаунтов могут проходить аутентификацию через OAuth2. Если параметр области не указан, он возвращается к <i>profile</i>.<br>\r\n• Параметр <i>state</i> должен быть отправлен клиентом как часть запроса для авторизации.<br><br>\r\nПути для запросов OAuth2 API: <br>\r\n<ul>\r\n <li>Authorization endpoint: <code>/oauth/authorize</code></li>\r\n <li>Token endpoint: <code>/oauth/token</code></li>\r\n <li>Resource page: <code>/oauth/profile</code></li>\r\n</ul>\r\nГенерирование нового клиентского секрета не приводит к истечению существующих кодов авторизации, но они не смогут обновить свой токен.<br><br>\r\nОтзыв клиентских токенов приведет к немедленному прекращению всех активных сеансов. Все клиенты должны будут пройти повторную аутентификацию.",
"oauth2_redirect_uri": "Переадресация URI",
"oauth2_renew_secret": "Сгенерировать новый ключ клиента",
"oauth2_revoke_tokens": "Отозвать все клиентские токены",
"optional": "опционально",
+ "options": "Параметры",
"password": "Пароль",
"password_length": "Минимальная длина пароля",
"password_policy": "Политика паролей",
@@ -242,6 +260,11 @@
"password_policy_numbers": "Должен содержать цифру",
"password_policy_special_chars": "Должны содержать специальный символ",
"password_repeat": "Подтверждение пароля (повтор)",
+ "password_reset_info": "Если получатель не указан, использование данной функции недоступно.",
+ "password_reset_settings": "Параметры восстановления паролей",
+ "password_reset_tmpl_html": "Шаблон в виде HTML",
+ "password_reset_tmpl_text": "Шаблон в виде обычного текста",
+ "password_settings": "Параметры паролей",
"priority": "Приоритет",
"private_key": "Закрытый ключ",
"quarantine": "Карантин",
@@ -249,7 +272,7 @@
"quarantine_exclude_domains": "Исключить домены и псевдонимы доменов",
"quarantine_max_age": "Максимальный период хранения в днях<br><small>Значение должно быть равно или больше 1 дня.</small>",
"quarantine_max_score": "Не уведомлять о спаме, если оценка письма выше, чем:<br><small>По умолчанию 9999.0</small>",
- "quarantine_max_size": "Максимальный размер в MiB (письма большего размера не будет сохранены):<br><small>0 означает, что карантин <b>отключён</b>.</small>",
+ "quarantine_max_size": "Максимальный размер в MiB (письма большего размера не будут сохранены):<br><small>0 означает, что карантин <b>отключён</b>.</small>",
"quarantine_notification_html": "Шаблон уведомления:<br><small>Оставьте пустым, чтобы восстановить шаблон по умолчанию.</small>",
"quarantine_notification_sender": "Email-адрес для отправки уведомления",
"quarantine_notification_subject": "Тема письма",
@@ -258,6 +281,7 @@
"quarantine_release_format_att": "Как вложение",
"quarantine_release_format_raw": "Оригинальное письмо",
"quarantine_retention_size": "Количество писем, сохраняемых в карантине на аккаунт:<br><small>0 означает, что карантин <b>отключён</b>.</small>",
+ "queue_unban": "разблокировать",
"quota_notification_html": "Шаблон уведомления:<br><small>Оставьте пустым, чтобы восстановить шаблон по умолчанию.</small>",
"quota_notification_sender": "Email-адрес для отправки уведомления",
"quota_notification_subject": "Тема письма",
@@ -266,7 +290,7 @@
"quota_notifications_vars": "{{percent}} равно текущей квоте пользователя<br>{{username}} - имя почтового аккаунта",
"r_active": "Включенные ограничения",
"r_inactive": "Отключенные ограничения",
- "r_info": "Не активные (серые) элементы списка ограничений - это не валидные ограничения, и они не могут быть перемещены. <br>Вы можете добавить новые элементы в <code>inc/vars.local.inc.php</code> чтобы иметь возможность настраивать их.",
+ "r_info": "Неактивные (серые) элементы списка ограничений - это некорректные ограничения, и они не могут быть перемещены. <br>Вы можете добавить новые элементы в <code>inc/vars.local.inc.php</code> чтобы иметь возможность настраивать их.",
"rate_name": "Название очереди",
"recipients": "Получатели",
"refresh": "Обновить",
@@ -281,6 +305,8 @@
"remove_row": "Удалить строку",
"reset_default": "Восстановить по умолчанию",
"reset_limit": "Удалить хэш",
+ "reset_password_vars": "<code>{{link}}</code> Сгенерированная ссылка для восстановление пароля<br><code>{{username}}</code> Имя почтового ящика пользователя, запросившего восстановление пароля<br><code>{{username2}}</code> Имя почтового ящика для восстановления<br><code>{{date}}</code> Дата запроса на восстановление пароля<br><code>{{token_lifetime}}</code> Срок действия токена в минутах<br><code>{{hostname}}</code> Имя хоста mailcow",
+ "restore_template": "Оставьте пустым, чтобы восстановить шаблон по умолчанию.",
"routing": "Маршрутизация",
"rsetting_add_rule": "Добавить правило",
"rsetting_content": "Содержание правила",
@@ -289,14 +315,14 @@
"rsetting_none": "Нет доступных правил",
"rsettings_insert_preset": "Вставить пример \"%s\"",
"rsettings_preset_1": "Отключить все, кроме DKIM и ограничения скорости для аутентифицированных пользователей",
- "rsettings_preset_2": "Не проверять письма на спам Postmaster",
+ "rsettings_preset_2": "Не проверять письма Postmaster на спам",
"rsettings_preset_3": "Разрешить только определённых отправителей для почтового ящика (использование только в качестве внутреннего почтового ящика)",
"rsettings_preset_4": "Отключить Rspamd для домена",
"rspamd_com_settings": "Имена правил будут сгенерированы на основе их ID.<br> Инструкция доступна на сайте <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">документация Rspamd user settings</a>, заготовленные шаблоны:",
"rspamd_global_filters": "Глобальные правила фильтрации",
"rspamd_global_filters_agree": "Я понимаю, что я делаю, и буду осторожен!",
"rspamd_global_filters_info": "Глобальные правила фильтрации содержат различные виды глобальных черных и белых списков.",
- "rspamd_global_filters_regex": "Названия фильтров отражают их предназначение. Все правила должены состоять из регулярных выражений в формате \"/pattern/options\" (на пример: <code>/.+@domain\\.tld/i</code>).<br>\r\nНесмотря на то, что перед сохранением правил выполняется проверка регулярных выражений, функциональность Rspamds может быть нарушена, если будет использован<br>\r\n некорректный синтаксис. Будьте внимательны при написании правил.<br>Электронные письма от адресов электронной почты, проходящие по регулярным выражениям черных списков, будут отклонены без сохранения в карантин.<br>\r\n Rspamd попытается прочитать содержимое правил при их изменении. Но, если что, вы можете <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">перезапустить Rspamd</a>, чтобы принять последние изменения принудительно.",
+ "rspamd_global_filters_regex": "Названия фильтров отражают их предназначение. Все правила должны состоять из регулярных выражений в формате \"/pattern/options\" (например: <code>/.+@domain\\.tld/i</code>).<br>\nНесмотря на то, что перед сохранением правил выполняется проверка регулярных выражений, функциональность Rspamds может быть нарушена, если будет использован<br>\n некорректный синтаксис. Будьте внимательны при написании правил.<br>Электронные письма от адресов электронной почты, проходящие по регулярным выражениям черных списков, будут отклонены без сохранения в карантин.<br>\n Rspamd попытается прочитать содержимое правил при их изменении. Но, если что, вы можете <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">перезапустить Rspamd</a>, чтобы принять последние изменения принудительно.",
"rspamd_settings_map": "Правила Rspamd",
"sal_level": "Уровень Муу",
"save": "Сохранить изменения",
@@ -337,18 +363,56 @@
"validate_license_now": "Получить лицензию на основе GUID с сервера лицензий",
"verify": "Проверить",
"yes": "✓",
- "queue_unban": "разблокировать",
- "f2b_ban_time_increment": "Время бана увеличивается с каждым баном",
- "f2b_max_ban_time": "Максимальное время блокировки",
- "allowed_origins": "Access-Control-Allow-Origin",
- "cors_settings": "Настройки CORS",
- "allowed_methods": "Access-Control-Allow-Methods",
- "ip_check": "Проверить IP",
- "ip_check_disabled": "Проверка IP отключена. Вы можете включить его в разделе <br> <strong>Система > Конфигурация > Параметры > Настроить</strong>.",
- "ip_check_opt_in": "Согласие на использование сторонних служб <strong>ipv4.mailcow.email</strong> и <strong>ipv6.mailcow.email</strong> для разрешения внешних IP-адресов.",
- "f2b_manage_external": "Внешнее управление Fail2Ban",
- "f2b_manage_external_info": "Fail2ban по-прежнему будет вести банлист, но не будет активно устанавливать правила для блокировки трафика. Используйте сгенерированный ниже банлист для внешнего блокирования трафика.",
- "copy_to_clipboard": "Текст скопирован в буфер обмена!"
+ "force_sso_text": "Если настроен внешний провайдер OIDC, эта опция скрывает стандартные формы входа mailcow и показывает только кнопку Singe Sign-On",
+ "domainadmin_quicklink": "Скрыть ссылку на вход для администраторов домена",
+ "iam_periodic_full_sync": "Периодическая полная синхронизация",
+ "iam_sync_interval": "Интервал синхронизации/импорта (мин)",
+ "iam_use_tls_info": "При включённом TLS необходимо использовать стандартный порт LDAP-сервера (389). Порты SSL не подходят.",
+ "iam_use_ssl_info": "При включённом SSL, если указан порт 389, то вместо него автоматически будет использоваться порт 636.",
+ "quicklink_text": "Показать или скрыть ссылки для быстрого перехода к другим страницам входа под формой авторизации",
+ "iam_login_provisioning": "Автоматическое создание пользователей при входе в систему",
+ "iam_mapping": "Сопоставление атрибутов",
+ "iam_bindpass": "Bind пароль",
+ "iam_port": "Порт",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "URL переадресации",
+ "iam_rest_flow": "Поток Mailpassword",
+ "iam_server_url": "URL сервера",
+ "iam_sso": "Технология единого входа (SSO)",
+ "iam_token_url": "Token endpoint",
+ "iam_userinfo_url": "User info endpoint",
+ "iam_username_field": "Поле имени пользователя",
+ "iam_binddn": "Bind DN",
+ "iam_use_ssl": "Использовать SSL",
+ "iam_use_tls": "Использовать StartTLS",
+ "iam_version": "Версия",
+ "ignore_ssl_error": "Игнорировать ошибки SSL",
+ "task": "Задача",
+ "user_link": "Пользовательская ссылка",
+ "user_quicklink": "Скрыть ссылку на вход для пользователей",
+ "app_hide": "Скрыть для входа",
+ "iam_test_connection": "Проверка соединения",
+ "login_page": "Страница входа",
+ "filter": "Фильтр",
+ "force_sso": "Отключить mailcow авторизацию и показывать только Singe Sign-On",
+ "iam": "Провайдер идентификации",
+ "iam_attribute_field": "Поле атрибута",
+ "iam_authorize_url": "Конечная точка авторизации",
+ "iam_auth_flow": "Процесс аутентификации",
+ "iam_auth_flow_info": "В дополнение к потоку кода авторизации (стандартный поток в Keycloak), который используется для Single-Sign On входа, mailcow также поддерживает поток аутентификации с непосредственными учетными данными. Поток Mailpassword пытается проверить учетные данные пользователя с помощью REST API администратора Keycloak. mailcow извлекает хешированный пароль из атрибута <code>mailcow_password</code>, который отображается в Keycloak.",
+ "iam_basedn": "Base DN",
+ "iam_client_id": "ID клиента",
+ "iam_client_secret": "Секрет клиента",
+ "iam_client_scopes": "Области действия клиента",
+ "iam_default_template": "Шаблон по умолчанию",
+ "iam_default_template_description": "Если пользователю не назначен шаблон, шаблон по умолчанию будет использоваться при создании почтового ящика, но не при обновлении почтового ящика.",
+ "iam_description": "Настройка внешнего провайдера для аутентификации<br>Почтовые ящики пользователей будут автоматически создаваться при первом входе в систему, если было задано сопоставление атрибутов.",
+ "iam_extra_permission": "Для работы следующих настроек клиенту mailcow в Keycloak необходима <code>служебная учетная запись</code> и разрешение на <code>просмотр пользователей</code>.",
+ "iam_host": "Хост",
+ "iam_host_info": "Укажите один или несколько LDAP-хостов через запятую.",
+ "iam_import_users": "Импорт пользователей",
+ "admin_quicklink": "Скрыть ссылку на вход для администраторов",
+ "needs_restart": "необходим перезапуск"
},
"danger": {
"access_denied": "Доступ запрещён, или указаны неверные данные",
@@ -364,7 +428,10 @@
"bcc_exists": "Для типов %s уже существует карта BCC %s",
"bcc_must_be_email": "Назначение BCC %s не является правильным адресом электронной почты",
"comment_too_long": "Комментарий слишком длинный, придел 160 символов",
+ "cors_invalid_method": "Указан недопустимый метод разрешения",
+ "cors_invalid_origin": "Указан неверный Allow-Origin",
"defquota_empty": "Квота по умолчанию не может быть 0.",
+ "demo_mode_enabled": "Демонстрационный режим включен",
"description_invalid": "Недопустимое описание ресурса %s",
"dkim_domain_or_sel_exists": "Ключ DKIM для \"%s\" уже существует",
"dkim_domain_or_sel_invalid": "DKIM домен или селектор недопустимы для %s",
@@ -374,30 +441,34 @@
"domain_not_empty": "Нельзя удалить непустой домен %s",
"domain_not_found": "Домен %s не найден",
"domain_quota_m_in_use": "Квота домена должна быть больше или равна %s MiB",
- "extra_acl_invalid": "Адрес внешнего отправителя \"%s\" не валидный.",
- "extra_acl_invalid_domain": "Адрес внешнего отправителя \"%s\" не валидный домен",
+ "extended_sender_acl_denied": "отсутствует ACL для установки внешних адресов отправителей",
+ "extra_acl_invalid": "Адрес внешнего отправителя \"%s\" некорректен",
+ "extra_acl_invalid_domain": "Адрес внешнего отправителя \"%s\" содержит некорректный домен",
"fido2_verification_failed": "Ошибка валидации FIDO2: %s",
"file_open_error": "Файл не может быть открыт на запись",
"filter_type": "Неверный тип фильтра",
"from_invalid": "Отправитель не может быть пустым",
"global_filter_write_error": "Ошибка записи фильтра в файл: %s",
- "global_map_invalid": "Идентификатор глобального правила %s не валидный",
+ "global_map_invalid": "Недопустимый идентификатор глобального правила %s",
"global_map_write_error": "Не удалось создать глобальное правило ID %s: %s",
- "goto_empty": "Псевдоним должен содержать по крайней мере один валидный адрес владельца",
+ "goto_empty": "Псевдоним должен содержать по крайней мере один действующий адрес владельца",
"goto_invalid": "Недопустимый основной адрес %s",
"ham_learn_error": "Ошибка при обучении полезной почты: %s",
"imagick_exception": "Ошибка в Imagick при чтении изображения",
+ "img_dimensions_exceeded": "Разрешение изображения превышает допустимое значение",
"img_invalid": "Невозможно проверить файл изображения",
+ "img_size_exceeded": "Изображение превышает допустимый размер файла",
"img_tmp_missing": "Невозможно проверить файл изображения: временный файл не найден",
- "invalid_bcc_map_type": "Неверный тип правила BBC",
+ "invalid_bcc_map_type": "Неверный тип правила BCC",
"invalid_destination": "Назначение \"%s\" указано неверно",
"invalid_filter_type": "Неверный тип фильтра",
"invalid_host": "Хост %s указан неверно",
"invalid_mime_type": "Неверный mime type",
"invalid_nexthop": "Формат следующего хоста неверен",
"invalid_nexthop_authenticated": "Следующий хост существует с разными данными авторизации, пожалуйста, обновите существующие данные авторизации сначала для этого хоста.",
- "invalid_recipient_map_new": "Новый получатель: %s не валидный",
- "invalid_recipient_map_old": "Первоначальный получатель: %s не валидный",
+ "invalid_recipient_map_new": "Недопустимый новый получатель: %s",
+ "invalid_recipient_map_old": "Недопустимый исходный получатель: %s",
+ "invalid_reset_token": "Неверный токен восстановления",
"ip_list_empty": "Список разрешенных IP адресов не может быть пустым",
"is_alias": "%s уже известен как псевдоним адреса",
"is_alias_or_mailbox": "%s уже известен как псевдоним или почтовый аккаунт",
@@ -417,7 +488,7 @@
"max_quota_in_use": "Квота почтового аккаунта должна быть больше или равна %d MiB",
"maxquota_empty": "Максимальная квота почтового аккаунта не должна быть 0.",
"mysql_error": "Ошибка в MySQL: %s",
- "network_host_invalid": "Сеть или хост: %s не валидный",
+ "network_host_invalid": "Недопустимые сеть или хост: %s",
"next_hop_interferes": "%s пересекается с %s",
"next_hop_interferes_any": "Существующий хост пересекается с %s",
"nginx_reload_failed": "Обновление конфигурации Nginx не удалось: %s",
@@ -427,6 +498,8 @@
"password_complexity": "Пароль не соответствует требованиям",
"password_empty": "Пароль не может быть пустым",
"password_mismatch": "Введенные пароли не совпадают",
+ "password_reset_invalid_user": "Почтовый ящик не найден или не задан адрес электронной почты для восстановления",
+ "password_reset_na": "Восстановление пароля в настоящее время недоступно. Пожалуйста, свяжитесь с вашим администратором.",
"policy_list_from_exists": "Запись с указанным именем уже существует",
"policy_list_from_invalid": "Запись имеет недопустимый формат",
"private_key_error": "Ошибка приватного ключа: %s",
@@ -435,17 +508,19 @@
"pushover_token": "Токен Pushover указан в неверном формате",
"quota_not_0_not_numeric": "Размер квоты должен быть больше или равен нулю",
"recipient_map_entry_exists": "Правило перезаписи \"%s\" уже существует",
+ "recovery_email_failed": "Не удалось отправить письмо для восстановления. Пожалуйста, свяжитесь с вашим администратором.",
"redis_error": "Ошибка в Redis: %s",
- "relayhost_invalid": "Правило %s не валидное",
+ "relayhost_invalid": "Недопустимое правило %s",
"release_send_failed": "Сообщение не может быть восстановлено: %s",
"reset_f2b_regex": "Сброс фильтров не был выполнен за отведённый промежуток времени, пожалуйста, повторите попытку или подождите еще несколько секунд и перезагрузите веб страницу.",
+ "reset_token_limit_exceeded": "Превышен лимит запросов на восстановление. Пожалуйста, попробуйте ещё раз позже.",
"resource_invalid": "Недопустимое имя ресурса",
"rl_timeframe": "Не верный временной интервал для лимита отправки",
"rspamd_ui_pw_length": "Длина пароля должна составлять не менее 6 символов для Rspamd UI",
"script_empty": "Скрипт не может быть пустым",
"sender_acl_invalid": "Недопустимое значение ACL для: %s",
"set_acl_failed": "Не удалось установить ACL",
- "settings_map_invalid": "Правило ID: %s не валидное",
+ "settings_map_invalid": "Недопустимое правило ID %s",
"sieve_error": "Ошибка в синтаксисе Sieve: %s",
"spam_learn_error": "Ошибка при обучении спам фильтра: %s",
"subject_empty": "Тема письма не может быть пустой",
@@ -453,51 +528,100 @@
"targetd_not_found": "Основной домен %s не найден",
"targetd_relay_domain": "Целевой домен %s уже является домен ретрансляции",
"temp_error": "Временная ошибка",
- "text_empty": "Текст не должен быть пустым",
+ "template_exists": "Шаблон %s уже существует",
+ "template_id_invalid": "Недопустимое значение ID шаблона: %s",
+ "template_name_invalid": "Недопустимое название шаблона",
+ "text_empty": "Текст не может быть пустым",
"tfa_token_invalid": "Неправильный TFA токен",
"tls_policy_map_dest_invalid": "Недопустимое значение назначения политики",
"tls_policy_map_entry_exists": "Правило политики шифрования \"%s\" уже существует",
"tls_policy_map_parameter_invalid": "Недопустимое значение параметра политики",
+ "to_invalid": "Получатель не может быть пустым",
"totp_verification_failed": "Ошибка валидации TOTP",
"transport_dest_exists": "Назначение для отправки \"%s\" уже существует",
- "webauthn_verification_failed": "Ошибка валидации WebAuthn: %s",
"unknown": "Произошла неизвестная ошибка",
"unknown_tfa_method": "Неизвестный метод TFA",
"unlimited_quota_acl": "Неограниченная квота запрещена политикой доступа",
"username_invalid": "Имя пользователя %s нельзя использовать",
"validity_missing": "Пожалуйста, назначьте срок действия",
"value_missing": "Пожалуйста заполните все поля",
+ "webauthn_authenticator_failed": "Выбранный аутентификатор не был найден",
+ "webauthn_publickey_failed": "Для выбранного аутентификатора не был сохранен открытый ключ",
+ "webauthn_username_failed": "Выбранный аутентификатор принадлежит другой учетной записи",
+ "webauthn_verification_failed": "Ошибка валидации WebAuthn: %s",
"yotp_verification_failed": "Ошибка валидации Yubico OTP: %s",
- "cors_invalid_method": "Указан недопустимый метод разрешения",
- "demo_mode_enabled": "Демонстрационный режим включен",
- "cors_invalid_origin": "Указан неверный Allow-Origin"
+ "generic_server_error": "На сервере произошла непредвиденная ошибка. Пожалуйста, свяжитесь с вашим администратором.",
+ "authsource_in_use": "Поставщик идентификационных данных не может быть изменен или удален, так как в данный момент он используется одним или несколькими пользователями.",
+ "iam_test_connection": "Ошибка соединения",
+ "required_data_missing": "Отсутствуют необходимые данные %s",
+ "max_age_invalid": "Максимальный возраст %s недействителен",
+ "mode_invalid": "Режим %s недействителен",
+ "mx_invalid": "Запись MX %s недействительна",
+ "version_invalid": "Версия %s недействительна"
+ },
+ "datatables": {
+ "collapse_all": "Свернуть все",
+ "decimal": ",",
+ "emptyTable": "В таблице отсутствуют данные",
+ "expand_all": "Развернуть все",
+ "info": "Показаны записи с _START_ по _END_ из _TOTAL_",
+ "infoEmpty": "Показано 0 записей",
+ "infoFiltered": "(отфильтровано из _MAX_ всех записей)",
+ "infoPostFix": "",
+ "lengthMenu": "Показать _MENU_ записей",
+ "loadingRecords": "Загрузка...",
+ "processing": "Пожалуйста, подождите...",
+ "search": "Поиск:",
+ "thousands": " ",
+ "zeroRecords": "Не найдено соответствующих записей",
+ "paginate": {
+ "first": "Первая",
+ "last": "Последняя",
+ "next": "Следующая",
+ "previous": "Предыдущая"
+ },
+ "aria": {
+ "sortAscending": ": активируйте для сортировки столбца по возрастанию",
+ "sortDescending": ": активируйте для сортировки столбца по убыванию"
+ }
},
"debug": {
+ "architecture": "Архитектура",
"chart_this_server": "Диаграмма (текущий сервер)",
+ "container_disabled": "Контейнер остановлен или отключен",
+ "container_running": "Работающий",
+ "container_stopped": "Остановлен",
"containers_info": "Статус контейнеров Docker",
+ "cores": "яд.",
+ "current_time": "Системное время",
"disk_usage": "Использование дискового пространства",
"docs": "Проиндексировано объектов",
+ "error_show_ip": "Не удалось определить публичные IP-адреса",
"external_logs": "Внешние журналы",
"history_all_servers": "История (все серверы)",
"in_memory_logs": "Журналы контейнеров",
- "jvm_memory_solr": "Использовано оперативной памяти JVM",
"last_modified": "Последние изменения",
"log_info": "<p><b>Журналы контейнеров</b> mailcow сохраняются в Redis, и раз в минуту строки журнала за пределами <code>LOG_LINES (%d)</code> удаляются, чтобы уменьшить нагрузку на сервер.\r\n <br>Сами журналы контейнеров не сохраняются после перезагрузки контейнера. Все контейнеры дополнительно пишут логи в службу Docker, и, следовательно, используют драйвер логирования по умолчанию. Журналы контейнеров предусмотрены только для отладки мелких проблем. Для других задач, пожалуйста, настройте драйвер логирования Docker самостоятельно.</p>\r\n <p><b>Внешние журналы</b> собираются через API приложений.</p>\r\n <p><b>Статические журналы</b> – это, в основном, журналы активности, которые не записываются в Dockerd, но все равно должны быть постоянными (за исключением журналов API).</p>",
"login_time": "Время входа",
"logs": "Журналы",
+ "memory": "Память",
+ "no_update_available": "Система обновлена до последней версии",
"online_users": "Подключено пользователей",
"restart_container": "Перезапустить",
"service": "Сервис",
+ "show_ip": "Показать публичные IP-адреса",
"size": "Индексы занимают",
- "solr_dead": "Solr не запущен. Если вы включили Solf в файле настроек <code>mailcow.conf</code> и это сообщение отображается более получаса, скорее всего Solr сломан.",
- "solr_status": "Состояние Solr",
"started_at": "Запущен",
"started_on": "Запущен в",
"static_logs": "Статические журналы",
"success": "Успех",
"system_containers": "Система и контейнеры",
+ "timezone": "Часовой пояс",
+ "update_available": "Доступно обновление",
+ "update_failed": "Не удалось проверить наличие обновлений",
"uptime": "Время работы",
- "username": "Имя пользователя"
+ "username": "Имя пользователя",
+ "wip": "В настоящее время идёт разработка"
},
"diagnostics": {
"cname_from_a": "Значение, полученное из записи A/AAAA. Это поддерживается до тех пор, пока запись указывает на правильный ресурс.",
@@ -508,7 +632,7 @@
"dns_records_name": "Название",
"dns_records_status": "Статус",
"dns_records_type": "Тип",
- "optional": "Эта запись не обязательна."
+ "optional": "Эта запись необязательна."
},
"edit": {
"acl": "ACL (Список прав)",
@@ -518,16 +642,18 @@
"alias": "Изменить псевдоним",
"allow_from_smtp": "Разрешить использование <b>SMTP</b> только для этих IP",
"allow_from_smtp_info": "Укажите IPv4/IPv6 адреса и/или подсети.<br>Оставьте поле пустым, чтобы разрешить отправку с любых адресов.",
- "allowed_protocols": "Разрешённые протоколы",
+ "allowed_protocols": "Разрешённые протоколы для прямого доступа пользователей (не влияет на протоколы паролей приложений)",
"app_name": "Название приложения",
"app_passwd": "Пароль приложения",
+ "app_passwd_protocols": "Разрешенные протоколы для пароля приложения",
"automap": "Автоматическое слияние папок (\"Sent items\", \"Sent\" => \"Sent\" etc.)",
"backup_mx_options": "Параметры резервного копирования MX",
- "bcc_dest_format": "Назначением для правила BBC должен быть единственный действительный адрес электронной почты.",
+ "bcc_dest_format": "Назначением для правила BCC должен быть единственный действительный адрес электронной почты.",
"client_id": "ID клиента",
"client_secret": "Секретный ключ пользователя",
"comment_info": "Приватный комментарий не виден пользователям, а публичный - отображается рядом с псевдонимом в личном кабинете пользователя",
"created_on": "Дата создания",
+ "custom_attributes": "Пользовательские атрибуты",
"delete1": "Удаление из источника после завершения",
"delete2": "Удаление писем по месту назначения, которые не находятся на исходном",
"delete2duplicates": "Удаление дубликатов по назначению",
@@ -536,6 +662,19 @@
"disable_login": "Вход в систему запрещен",
"domain": "Изменение домена",
"domain_admin": "Изменение администратора домена",
+ "domain_footer": "Нижний колонтитул домена",
+ "domain_footer_html": "HTML нижний колонтитул",
+ "domain_footer_info": "Нижние колонтитулы на уровне домена добавляются ко всем исходящим электронным письмам, связанным с адресом в этом домене. <br> Для нижнего колонтитула можно использовать следующие переменные:",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - Аутентифицированное имя пользователя, указанное MTA",
+ "custom": "{= foo =} - Если почтовый ящик имеет пользовательский атрибут \"foo\" со значением \"bar\", он возвращает \"bar\".",
+ "from_addr": "{= from_addr =} - Из адресной части envelope",
+ "from_domain": "{= from_domain =} - из доменной части envelope",
+ "from_name": "{= from_name =} - Из названия envelope, например, для \"Mailcow <moo@mailcow.tld>\" возвращается \"Mailcow\"",
+ "from_user": "{= from_user =} - Из пользовательской части envelope, например, для \"moo@mailcow.tld\" возвращается \"moo\""
+ },
+ "domain_footer_plain": "ПРОСТОЙ нижний колонтитул",
+ "domain_footer_skip_replies": "Ignore footer on reply e-mails",
"domain_quota": "Квота домена",
"domains": "Домены",
"dont_check_sender_acl": "Отключить проверку отправителя для домена %s и псевдонимов домена",
@@ -544,9 +683,9 @@
"exclude": "Исключить объекты (regex)",
"extended_sender_acl": "Внешние адреса почты",
"extended_sender_acl_info": "Для внешних доменов должен быть импортирован или сгенерирован доменный ключ DKIM с соответствующей записью TXT в домене, если внешний домен использует DMARC.<br>\r\n Не забудьте добавить этот сервер к соответствующей записи SPF TXT внешнего домена.<br>\r\n Добавление домена из списка внешних адресов в mailcow автоматически удалит соответствующие записи из внешних адресов пользователей.<br>\r\n Чтобы разрешить пользователю отправку от имени *@domain.tld, укажите @domain.tld.",
+ "footer_exclude": "Исключить из нижнего колонтитула",
"force_pw_update": "Требовать смены пароля при следующем входе в систему",
"force_pw_update_info": "Пользователь должен будет войти в %s и сменить свой пароль. mailcow OAuth2, SOGo, EAS, IMAP/POP3 и SMTP будут не доступны до смены пароля.",
- "footer_exclude": "Исключить из нижнего колонтитула",
"full_name": "Полное имя",
"gal": "GAL - Глобальная адресная книга",
"gal_info": "GAL содержит все объекты домена и не подлежит редактированию. Информация о занятости в SOGo будет отсутствовать для домена, если данная функция будет отключена! <b>Требуется перезапустить SOGo, чтобы применить изменения.</b>",
@@ -560,6 +699,11 @@
"mailbox": "Изменение почтового аккаунта",
"mailbox_quota_def": "Квота по умолчанию",
"mailbox_relayhost_info": "Применяется только к почтовому ящику и личным псевдонимам, вне зависимости от настроек маршрутизации на уровне домена.",
+ "mailbox_rename": "Переименовать почтовый ящик",
+ "mailbox_rename_agree": "Я сделал резервную копию.",
+ "mailbox_rename_alias": "Автоматически создать псевдоним",
+ "mailbox_rename_title": "Новое имя локального почтового ящика",
+ "mailbox_rename_warning": "ВАЖНО! Перед переименованием почтового ящика создайте резервную копию.",
"max_aliases": "Максимум псевдонимов",
"max_mailboxes": "Максимум почтовых ящиков",
"max_quota": "Максимальная квота почтового аккаунта (MiB)",
@@ -568,9 +712,10 @@
"mbox_rl_info": "Этот лимит применяется к SASL логину пользователя и соответствует любому адресу отправителя, используемому зарегистрированным пользователем. Лимит скорости почтового аккаунта перекрывает лимит скорости для всего домена.",
"mins_interval": "Интервал (в минутах)",
"multiple_bookings": "Несколько бронирований",
- "none_inherit": "Отсутствует / Наследуется",
"nexthop": "Следующий хост",
+ "none_inherit": "Отсутствует / Наследуется",
"password": "Пароль",
+ "password_recovery_email": "Адрес для восстановления пароля",
"password_repeat": "Подтверждение пароля (повтор)",
"previous": "Предыдущая страница",
"private_comment": "Приватный комментарий",
@@ -581,6 +726,7 @@
"pushover_only_x_prio": "Получать уведомления только об письмах с высоким приоритетом [<code>X-Priority: 1</code>]",
"pushover_sender_array": "Получать уведомления от списка адресов электронной почты <small>(envelop-from разделенные запятыми)</small>:",
"pushover_sender_regex": "Получать уведомления от отправителей, удовлетворяющих regex-выражению:",
+ "pushover_sound": "Звук уведомления",
"pushover_text": "Текст уведомления",
"pushover_title": "Заголовок уведомления",
"pushover_vars": "Когда фильтрация по отправителю не определена, уведомления будут доставлятся от всех отправителей.<br>Можно использовать обычный фильтр по отправителю и расширенный regex-фильтр, а также оба сразу.<br>Пожалуйста, ознакомьтесь с <a href=\"https://pushover.net/privacy\">Pushover Privacy Policy</a> перед использованием шаблонов для текста и заголовка",
@@ -594,7 +740,7 @@
"relay_all_info": "↪<small>Если вы решите <b>не</b> ретранслировать всех получателей, вам нужно будет добавить (\"слепой\") почтовый аккаунт для каждого получателя, которого следует ретранслировать.</small>",
"relay_domain": "Ретрансляция этого домена",
"relay_transport_info": "<div class=\"badge fs-6 bg-info\">Инфо</div> Вы можете настроить собственный транспорт для домена. Если такой настройки нет, то доставка будет выполнена на основе MX записей.",
- "relay_unknown_only": "Ретрансляция только не существующих почтовых ящиков. Почта к существующим почтовым ящикам будут доставляться локально.",
+ "relay_unknown_only": "Ретрансляция только несуществующих почтовых ящиков. Почта к существующим почтовым ящикам будут доставляться локально.",
"relayhost": "Маршрутизация на основе отправителя",
"remove": "Удалить",
"resource": "Ресурс",
@@ -606,11 +752,13 @@
"sieve_desc": "Краткое описание",
"sieve_type": "Тип фильтра",
"skipcrossduplicates": "Пропускать повторяющиеся сообщения в папках",
+ "sogo_access": "Прямая переадресация в SOGo",
+ "sogo_access_info": "После входа в систему пользователь автоматически перенаправляется в SOGo.",
"sogo_visible": "Отображать псевдоним в SOGo",
"sogo_visible_info": "Влияет только на объекты, которые могут отображаться в SOGo (персональные или общие псевдонимы, указывающие как минимум на один локальный почтовый аккаунт). Учтите, что если функция отключена, у пользователей не будет возможности выбрать адрес псевдонима в качестве отправителя в SOGo.",
"spam_alias": "Создать или изменить временные (спам) псевдонимы",
"spam_filter": "Спам фильтр",
- "spam_policy": "Добавление или удаление элементов в белом/черном списке",
+ "spam_policy": "Добавить или удалить элементы белого/черного списка",
"spam_score": "Задать индивидуальное определение спама",
"subfolder2": "Синхронизировать в подпапку<br><small>(пусто = в корень)</small>",
"syncjob": "Изменить задание синхронизации",
@@ -622,21 +770,21 @@
"unchanged_if_empty": "Если без изменений - оставьте пустым",
"username": "Имя пользователя",
"validate_save": "Подтвердить и сохранить",
- "sogo_access_info": "Единый вход из интерфейса почты продолжает работать. Эта настройка не влияет на доступ ко всем другим службам, а также не удаляет или изменяет существующий профиль пользователя SOGo.",
- "app_passwd_protocols": "Разрешенные протоколы для пароля приложения",
- "domain_footer_info": "Нижние колонтитулы на уровне домена добавляются ко всем исходящим электронным письмам, связанным с адресом в этом домене. <br> Для нижнего колонтитула можно использовать следующие переменные:",
- "domain_footer_info_vars": {
- "from_name": "{= from_name =} - Из названия envelope, например, для \"Mailcow <moo@mailcow.tld>\" возвращается \"Mailcow\"",
- "auth_user": "{= auth_user =} - Аутентифицированное имя пользователя, указанное MTA",
- "from_user": "{= from_user =} - Из пользовательской части envelope, например, для \"moo@mailcow.tld\" возвращается \"moo\"",
- "from_addr": "{= from_addr =} - Из адресной части envelope",
- "from_domain": "{= from_domain =} - из доменной части envelope",
- "custom": "{= foo =} - Если почтовый ящик имеет пользовательский атрибут \"foo\" со значением \"bar\", он возвращает \"bar\"."
- },
- "domain_footer": "Нижний колонтитул домена",
- "domain_footer_html": "HTML нижний колонтитул",
- "domain_footer_plain": "ПРОСТОЙ нижний колонтитул",
- "custom_attributes": "Пользовательские атрибуты"
+ "internal": "Внутренний",
+ "internal_info": "Внутренние псевдонимы доступны только из самого домена или доменов-псевдонимов.",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> — это стандарт, который обязывает почтовые серверы использовать TLS с подлинными сертификатами для доставки электронной почты.<br>Он используется, когда <a target='_blank' href='https://ru.wikipedia.org/wiki/DANE'>DANE</a> невозможен из-за неиспользуемого или неподдерживаемого DNSSEC.<br><b>Примечание</b>: если принимающий домен поддерживает DANE с DNSSEC, <b>всегда</b> предпочитается DANE — MTA-STS действует только как резервный вариант.",
+ "mta_sts_version": "Версия",
+ "mta_sts_version_info": "Определяет версию стандарта MTA-STS – на данный момент существует только <code>STSv1</code>.",
+ "mta_sts_mode": "Режим",
+ "mta_sts_mode_info": "Есть три режима на выбор:<ul><li><em>testing</em> – политика только наблюдается, нарушения не имеют последствий.</li><li><em>enforce</em> – политика соблюдается строго, соединения без подлинного TLS отклоняются.</li><li><em>none</em> – политика опубликована, но не применяется.</li></ul>",
+ "mta_sts_max_age": "Максимальный возраст",
+ "mta_sts_max_age_info": "Время в секундах, в течение которого принимающие почтовые серверы могут кэшировать эту политику перед повторной загрузкой.",
+ "mta_sts_mx": "Сервер MX",
+ "mta_sts_mx_info": "Разрешает отправку только на явно указанные имена хостов почтовых серверов; отправляющий MTA проверяет, соответствует ли DNS-имя MX-хоста списку политик, и разрешает доставку только с подлинным TLS-сертификатом (защита от MITM).",
+ "mta_sts_mx_notice": "Можно указать несколько MX-серверов (через запятую).",
+ "sender_allowed": "Разрешить отправку с этим псевдонимом",
+ "sender_allowed_info": "Если отключено, этот псевдоним может только принимать почту. Используйте ACL отправителя, чтобы переопределить и предоставить определенным почтовым ящикам разрешение на отправку."
},
"fido2": {
"confirm": "Подтвердить",
@@ -671,9 +819,10 @@
"header": {
"administration": "Настройка сервера",
"apps": "Приложения",
- "debug": "Состояние сервера",
+ "debug": "Информация",
"email": "E-Mail",
"mailcow_config": "Конфигурация",
+ "mailcow_system": "Система",
"quarantine": "Карантин",
"restart_netfilter": "Перезапустить netfilter",
"restart_sogo": "Перезапустить SOGo",
@@ -685,13 +834,28 @@
"session_expires": "Ваш сеанс закончится примерно через 15 секунд"
},
"login": {
+ "back_to_mailcow": "Вернуться к mailcow",
"delayed": "Вход был отложен на %s секунд.",
"fido2_webauthn": "FIDO2/WebAuthn Login",
+ "forgot_password": "> Забыли пароль?",
+ "invalid_pass_reset_token": "Токен восстановления пароля недействителен или срок его действия истек.<br>Пожалуйста, запросите новую ссылку для восстановления пароля.",
"login": "Войти",
"mobileconfig_info": "Пожалуйста, войдите в систему как пользователь почтового аккаунта для загрузки профиля подключения Apple.",
- "other_logins": "Вход с помощью ключа",
+ "new_password": "Новый пароль",
+ "new_password_confirm": "Повторите новый пароль",
+ "other_logins": "или войти с",
"password": "Пароль",
- "username": "Имя пользователя"
+ "request_reset_password": "Запросить восстановление пароля",
+ "reset_password": "Восстановление пароля",
+ "username": "Имя пользователя",
+ "login_linkstext": "Неправильный логин?",
+ "login_usertext": "Войти как пользователь",
+ "login_domainadmintext": "Войти как администратор домена",
+ "login_admintext": "Войти как администратор",
+ "login_user": "Вход для пользователей",
+ "login_dadmin": "Вход для администраторов домена",
+ "login_admin": "Вход для администраторов",
+ "email": "Email-адрес"
},
"mailbox": {
"action": "Действия",
@@ -700,7 +864,7 @@
"add": "Добавить",
"add_alias": "Добавить псевдоним",
"add_alias_expand": "Скопировать псевдонимы на псевдонимы домена",
- "add_bcc_entry": "Добавить правило BBC",
+ "add_bcc_entry": "Добавить правило BCC",
"add_domain": "Добавить домен",
"add_domain_alias": "Добавить псевдоним домена",
"add_domain_record_first": "Пожалуйста, сначала добавьте домен",
@@ -708,6 +872,7 @@
"add_mailbox": "Добавить почтовый аккаунт",
"add_recipient_map_entry": "Добавить перезапись получателя",
"add_resource": "Добавить ресурс",
+ "add_template": "Добавить шаблон",
"add_tls_policy_map": "Добавить политику TLS",
"address_rewriting": "Перезапись адресов",
"alias": "Псевдоним",
@@ -719,25 +884,25 @@
"allow_from_smtp_info": "Укажите IPv4/IPv6 адреса и/или подсети.<br>Оставьте поле пустым, чтобы разрешить отправку с любых адресов.",
"allowed_protocols": "Разрешенные протоколы",
"backup_mx": "Резервный MX",
- "bcc": "Правила BBC",
+ "bcc": "Правила BCC",
"bcc_destination": "Назначение BCC",
"bcc_destinations": "Назначение BCC",
"bcc_info": "Правила BCC используются для скрытой пересылки копий всех сообщений на другой адрес. Правило типа \"получатель\" используется, когда локальный получатель выступает в качестве получателя почты. Правило типа \"отправитель\" соответствуют тому же принципу. Локальный домен не будут проинформированы о неудачной доставке.",
"bcc_local_dest": "Локальный домен",
- "bcc_map": "Правила BBC",
+ "bcc_map": "Правила BCC",
"bcc_map_type": "Тип BCC",
- "bcc_maps": "Правила BBC",
+ "bcc_maps": "Правила BCC",
"bcc_rcpt_map": "Получатель",
"bcc_sender_map": "Отправитель",
"bcc_to_rcpt": "Переключиться на тип \"получатель\"",
"bcc_to_sender": "Переключиться на тип \"отправитель\"",
"bcc_type": "Тип BCC",
- "booking_null": "Всегда показывать как свободный",
"booking_0_short": "Всегда свободнен",
"booking_custom": "Лимит на количество бронирований",
"booking_custom_short": "Жесткий лимит",
- "booking_ltnull": "Неограниченный, занят при бронировании",
"booking_lt0_short": "Неограниченный лимит",
+ "booking_ltnull": "Неограниченный, занят при бронировании",
+ "booking_null": "Всегда показывать как свободный",
"catch_all": "Catch-all",
"created_on": "Дата создания",
"daily": "Раз в день",
@@ -752,6 +917,7 @@
"domain_aliases": "Псевдонимы доменов",
"domain_quota": "Квота",
"domain_quota_total": "Квота домена",
+ "domain_templates": "Шаблоны доменов",
"domains": "Домены",
"edit": "Изменить",
"empty": "Пусто",
@@ -779,6 +945,7 @@
"mailbox_defaults_info": "Установите настройки по умолчанию для новых почтовых аккаунтов.",
"mailbox_defquota": "Квота по умолчанию",
"mailbox_quota": "Макс. квота почт. ящика",
+ "mailbox_templates": "Шаблоны почтовых ящиков",
"mailboxes": "Почтовые ящики",
"max_aliases": "Максимум псевдонимов",
"max_mailboxes": "Максимум почтовых ящиков",
@@ -804,18 +971,19 @@
"recipient_map": "Перезапись получателя",
"recipient_map_info": "Перезапись получателя используются для замены получателя в сообщении до его доставки.",
"recipient_map_new": "Перезапись на",
- "recipient_map_new_info": "Должен быть действующим почтовым ящиком.",
+ "recipient_map_new_info": "Должен быть действующим почтовым ящиком или доменом.",
"recipient_map_old": "Получатель",
- "recipient_map_old_info": "Должен быть валидный почтовым ящиком или доменом.",
+ "recipient_map_old_info": "Должен быть действующим почтовым ящиком или доменом.",
"recipient_maps": "Перезапись получателя",
"relay_all": "Ретрансляция всех получателей",
+ "relay_unknown": "Ретрансляция неизвестных получателей",
"remove": "Удалить",
"resources": "Ресурсы",
"running": "В процессе",
"sender": "Отправитель",
"set_postfilter": "Использовать как постфильтр",
"set_prefilter": "Использовать как предварительный фильтр",
- "sieve_info": "Вы можете сохранить несколько фильтров для каждого пользователя, но только один предварительный фильтр и один постфильтр могут быть активными одновременно.<br>\r\n Каждый фильтр будет обработан в описанном порядке. Не сломанный скрипт, не <code>keep;</code> не остановит обработку дальнейших скриптов.<br><br>Global sieve prefilter • Prefilter • User scripts • Postfilter • Global sieve postfilter",
+ "sieve_info": "Вы можете сохранить несколько фильтров для каждого пользователя, но только один предварительный фильтр и один постфильтр могут быть активными одновременно.<br>\r\n Каждый фильтр будет обработан в описанном порядке. Ни сломанный скрипт, ни <code>keep;</code> не остановит обработку дальнейших скриптов.<br><br>Global sieve prefilter • Prefilter • User scripts • Postfilter • Global sieve postfilter",
"sieve_preset_1": "Discard mail with probable dangerous file types",
"sieve_preset_2": "Always mark the e-mail of a specific sender as seen",
"sieve_preset_3": "Discard silently, stop all further sieve processing",
@@ -823,7 +991,7 @@
"sieve_preset_5": "Auto responder (vacation)",
"sieve_preset_6": "Reject mail with response",
"sieve_preset_7": "Redirect and keep/drop",
- "sieve_preset_8": "Discard message sent to an alias address the sender is part of",
+ "sieve_preset_8": "Переслать письмо от определенного отправителя, пометить его как прочитанное и поместить в подпапку",
"sieve_preset_header": "Пожалуйста, ознакомьтесь с примерами ниже. Для более подробной информации прочитайте <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Sieve Wikipedia</a>.",
"sogo_visible": "Отображать псевдоним в SOGo",
"sogo_visible_n": "Не отображать псевдоним в SOGo",
@@ -832,25 +1000,27 @@
"stats": "Статистика",
"status": "Статус",
"sync_jobs": "Задания синхронизации",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Ошибка авторизации",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Неправильное имя пользователя или пароль",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Ошибка связи с сервером",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Не удалось подключиться к удаленному серверу",
+ "syncjob_EXIT_OVERQUOTA": "Целевой почтовый ящик превысил квоту",
+ "syncjob_EXIT_TLS_FAILURE": "Ошибка установки шифрованного соединения",
+ "syncjob_EX_OK": "Успешно",
"syncjob_check_log": "Проверить журнал",
"syncjob_last_run_result": "Результат последнего запуска",
- "syncjob_EX_OK": "Успешно",
- "syncjob_EXIT_CONNECTION_FAILURE": "Ошибка связи с сервером",
- "syncjob_EXIT_TLS_FAILURE": "Ошибка установки шифрованного соединения",
- "syncjob_EXIT_AUTHENTICATION_FAILURE": "Ошибка авторизации",
- "syncjob_EXIT_OVERQUOTA": "Целевой почтовый ящик превысил квоту",
- "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Не удалось подключиться к удаленному серверу",
- "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Неправильное имя пользователя или пароль",
"table_size": "Размер таблицы",
"table_size_show_n": "Отображать %s полей",
"target_address": "Владельцы псевдонима",
"target_domain": "Целевой домен",
+ "template": "Шаблон",
+ "templates": "Шаблоны",
"tls_enforce_in": "Принудительный TLS (входящие)",
"tls_enforce_out": "Принудительный TLS (исходящие)",
"tls_map_dest": "Назначение",
"tls_map_dest_info": "пример: example.org, .example.org, [mail.example.org]:25",
"tls_map_parameters": "Параметры",
- "tls_map_parameters_info": "Оставьте поле пустым или укажите параметры, на пример: protocols=!SSLv2 ciphers=medium exclude=3DES",
+ "tls_map_parameters_info": "Оставьте поле пустым или укажите параметры, например: protocols=!SSLv2 ciphers=medium exclude=3DES",
"tls_map_policy": "Политика",
"tls_policy_maps": "Правила TLS",
"tls_policy_maps_enforced_tls": "Для исходящих сообщений от пользователей с включенной принудительной политикой шифрования исходящих соединений не описанные глобальной политикой,<br>\r\n будут применены значения по умолчанию, указанные в <code>smtp_tls_mandatory_protocols</code> и <code>smtp_tls_mandatory_ciphers</code>.",
@@ -860,7 +1030,9 @@
"username": "Имя пользователя",
"waiting": "В ожидании",
"weekly": "Раз в неделю",
- "yes": "✓"
+ "yes": "✓",
+ "iam": "Поставщик идентификационных данных",
+ "internal": "Внутренний"
},
"oauth2": {
"access_denied": "Пожалуйста, войдите в систему как владелец почтового аккаунта, чтобы получить доступ через OAuth2.",
@@ -892,7 +1064,7 @@
"notified": "Увед.",
"qhandler_success": "Запрос успешно отправлен в систему. Теперь вы можете закрыть окно.",
"qid": "Rspamd QID",
- "qinfo": "Карантин сохраняет входящие сообщения, классифицированные как нежелательные, в базу данных.\r\n <br>Отправители писем, которые помечены как отвергнутые, будут уверены что их письма <b>не</b> были доставлены вам.\r\n <br>\"Освободить из карантина\" изучит сообщение как полезную почту; по теореме Байеса и доставит его вам в Inbox.\r\n <br>\"Запомнить как спам и удалить\" изучит сообщение как спам по теореме Байеса, а также вычислит нечёткие хэши, чтобы лучше блокировать подобные сообщения в дальнейшем.\r\n <br>Учтите, что в зависимости от технических характеристик вашей системы, изучение большого количества сообщений может занять много времени.",
+ "qinfo": "Карантин сохраняет входящие сообщения, классифицированные как нежелательные, в базу данных.\n <br>Отправители писем, которые помечены как отвергнутые, будут уверены что их письма <b>не</b> были доставлены вам.\n <br>\"Освободить из карантина\" изучит сообщение как полезную почту; по теореме Байеса и доставит его вам в Inbox.\n <br>\"Запомнить как спам и удалить\" изучит сообщение как спам по теореме Байеса, а также вычислит нечёткие хэши, чтобы лучше блокировать подобные сообщения в дальнейшем.\n <br>Учтите, что в зависимости от технических характеристик вашей системы, изучение большого количества сообщений может занять много времени.",
"qitem": "Обьект карантина",
"quarantine": "Карантин",
"quick_actions": "Действия",
@@ -925,20 +1097,31 @@
"type": "Тип"
},
"queue": {
- "queue_manager": "Очередь на отправку"
+ "ays": "Пожалуйста, подтвердите, что вы хотите удалить все элементы из текущей очереди.",
+ "delete": "Удалить все",
+ "deliver_mail": "Доставить",
+ "deliver_mail_legend": "Попытаться повторно доставить выбранные письма.",
+ "flush": "Обработать очередь",
+ "hold_mail": "Отложить",
+ "hold_mail_legend": "Удержать выбранные сообщения. (Предотвратить дальнейшие попытки доставки)",
+ "info": "Очередь отправки почты содержит все письма, которые ожидают доставки. Если письмо надолго задерживается в почтовой очереди, оно автоматически удаляется системой.<br>Сообщение об ошибке в соответствующих письмах содержит информацию о том, почему письмо не удалось доставить.",
+ "legend": "Описание действий с почтовой очередью:",
+ "queue_manager": "Очередь на отправку",
+ "show_message": "Показать сообщение",
+ "unhold_mail": "Высвободить",
+ "unhold_mail_legend": "Освобождает выбранные письма для доставки. (Требуется предварительное удержание)",
+ "unban": "освободить очередь"
},
"ratelimit": {
+ "day": "сообщений / день",
"disabled": "Отключен",
- "second": "сообщений / секунду",
- "minute": "сообщений / минуту",
"hour": "сообщений / час",
- "day": "сообщений / день"
+ "minute": "сообщений / минуту",
+ "second": "сообщений / секунду"
},
"start": {
"help": "Справка",
- "imap_smtp_server_auth_info": "Пожалуйста, используйте свой полный адрес электронной почты в формате <code>user@example.com</code> и PLAIN механизм авторизации.<br>\r\nВаши данные авторизации будут зашифрованы на уровне шифрования канала подключения к серверу, поэтому убедитесь, что вы используете надежное TLS подключение.",
- "mailcow_apps_detail": "Используйте приложения для доступа к вашей почте, календарю, контактам, и прочим функциям.",
- "mailcow_panel_detail": "<b>Администраторы домена</b> могут создавать, изменять или удалять почтовые ящики и псевдонимы, измененять домены и смотреть информацию о своих назначенных доменах. <br><b>Пользователи почтовых ящиков</b> имеют возможность создавать временные псевдонимы (спам псевдонимы), менять свой пароль и настройки фильтра спама."
+ "imap_smtp_server_auth_info": "Пожалуйста, используйте свой полный адрес электронной почты в формате <code>user@example.com</code> и PLAIN механизм авторизации.<br>\r\nВаши данные авторизации будут зашифрованы на уровне шифрования канала подключения к серверу, поэтому убедитесь, что вы используете надежное TLS подключение."
},
"success": {
"acl_saved": "ACL для %s сохранено",
@@ -958,6 +1141,7 @@
"bcc_deleted": "Правила BCC удалены: %s",
"bcc_edited": "Правило BCC %s отредактировано",
"bcc_saved": "Правило BCC сохранено",
+ "cors_headers_edited": "Настройки CORS сохранены",
"db_init_complete": "Инициализация базы данных завершена",
"delete_filter": "Фильтр ID %s удалён",
"delete_filters": "Фильтры удалены: %s",
@@ -966,19 +1150,23 @@
"dkim_added": "DKIM ключ сохранён",
"dkim_duplicated": "DKIM ключи для домена %s были скопированы в %s",
"dkim_removed": "DKIM ключ %s удалён",
+ "domain_add_dkim_available": "DKIM ключ уже существует",
"domain_added": "Добавлен домен %s",
"domain_admin_added": "Администратор домена %s добавлен",
"domain_admin_modified": "Сохранить изменения администратора домена %s",
"domain_admin_removed": "Администратор домена %s удалён",
+ "domain_footer_modified": "Изменения в нижнем колонтитуле домена %s сохранены",
"domain_modified": "Сохранить изменения домена %s",
"domain_removed": "Домен %s удалён",
"dovecot_restart_success": "Dovecot перезапущен успешно",
"eas_reset": "Кеш ActiveSync для пользователя %s был сброшен",
+ "f2b_banlist_refreshed": "Идентификатор банлиста был успешно обновлен.",
"f2b_modified": "Изменения параметров Fail2ban сохранены",
"forwarding_host_added": "Перенаправление узла %s добавлено",
"forwarding_host_removed": "Перенаправление узла %s удалено",
"global_filter_written": "Фильтр успешно записан в файл",
"hash_deleted": "Хеш удалён",
+ "ip_check_opt_in_modified": "Параметры проверки IP успешно обновлены",
"item_deleted": "Обьект %s удалён",
"item_released": "Письмо %s восстановлено из карантина",
"items_deleted": "Обьекты %s удалены",
@@ -989,14 +1177,17 @@
"mailbox_added": "Почтовый аккаунт %s добавлен",
"mailbox_modified": "Изменения почтового аккаунта %s сохранены",
"mailbox_removed": "Почтовый аккаунт %s удалён",
+ "mailbox_renamed": "Почтовый аккаунт %s был переименован в %s",
"nginx_reloaded": "Обновление конфигурация Nginx закончено",
"object_modified": "Изменения объекта %s сохранены",
+ "password_changed_success": "Пароль был успешно изменен",
"password_policy_saved": "Политика паролей сохранена",
"pushover_settings_edited": "Настройки сохранены, пожалуйста, выполните проверку доступа",
"qlearn_spam": "Письмо ID %s было изучено как спам и удалено",
"queue_command_success": "Команда выполнена успешно",
"recipient_map_entry_deleted": "Правило перезаписи получателя ID %s было удалено",
"recipient_map_entry_saved": "Правило перезаписи получателя \"%s\" было сохранено",
+ "recovery_email_sent": "Письмо для восстановления пароля отправлено на %s",
"relayhost_added": "Промежуточный узел %s добавлен",
"relayhost_removed": "Промежуточный узел %s удалён",
"reset_main_logo": "Восстановить логотип по умолчанию",
@@ -1009,6 +1200,9 @@
"settings_map_added": "Правило добавлено",
"settings_map_removed": "Правило ID %s удалено",
"sogo_profile_reset": "Профиль пользователя SOGo %s сброшен",
+ "template_added": "Шаблон %s добавлен",
+ "template_modified": "Изменения шаблона %s сохранены",
+ "template_removed": "Шаблон ID %s удален",
"tls_policy_map_entry_deleted": "Политика TLS ID %s удалено",
"tls_policy_map_entry_saved": "Политика TLS \"%s\" сохранена",
"ui_texts": "Изменения текстов UI сохранены",
@@ -1017,12 +1211,12 @@
"verified_totp_login": "Авторизация TOTP пройдена",
"verified_webauthn_login": "Авторизация WebAuthn пройдена",
"verified_yotp_login": "Авторизация Yubico OTP пройдена",
- "cors_headers_edited": "Настройки CORS сохранены",
- "domain_footer_modified": "Изменения в нижнем колонтитуле домена %s сохранены",
- "f2b_banlist_refreshed": "Идентификатор банлиста был успешно обновлен."
+ "iam_test_connection": "Успешное соединение",
+ "custom_login_modified": "Настройки входа успешно сохранены"
},
"tfa": {
"api_register": "%s использует Yubico Cloud API. Пожалуйста, получите ключ API для вашего ключа <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">здесь</a>",
+ "authenticators": "Аутентификаторы",
"confirm": "Подтвердите",
"confirm_totp_token": "Пожалуйста, подтвердите изменения, введя сгенерированный код",
"delete_tfa": "Отключить TFA",
@@ -1041,11 +1235,12 @@
"tfa": "Двухфакторная проверка подлинности",
"tfa_token_invalid": "Неправильный TFA токен",
"totp": "OTP (Authy, Google Authenticator и др.)",
- "webauthn": "WebAuthn аутентификация",
+ "u2f_deprecated": "Похоже, что ваш ключ был зарегистрирован с использованием устаревшего метода U2F. Мы деактивируем для вас двухфакторную аутентификацию и удалим ваш ключ.",
+ "u2f_deprecated_important": "Пожалуйста, зарегистрируйте ваш ключ в панели администратора с помощью нового метода WebAuthn.",
"waiting_usb_auth": "<i>Ожидание устройства USB...</i><br><br>Пожалуйста, нажмите кнопку на USB устройстве сейчас.",
"waiting_usb_register": "<i>Ожидание устройства USB...</i><br><br>Пожалуйста, введите пароль выше и подтвердите регистрацию, нажав кнопку на USB устройстве.",
- "yubi_otp": "Yubico OTP аутентификация",
- "u2f_deprecated": "Похоже, что ваш ключ был зарегистрирован с использованием устаревшего метода U2F. Мы деактивируем для вас двухфакторную аутентификацию и удалим ваш ключ."
+ "webauthn": "WebAuthn аутентификация",
+ "yubi_otp": "Yubico OTP аутентификация"
},
"user": {
"action": "Действия",
@@ -1062,13 +1257,17 @@
"alias_valid_until": "Действителен до",
"aliases_also_send_as": "Разрешено отправлять письма от имени",
"aliases_send_as_all": "Разрешено отправлять письма от любого имени для домена и его псевдонимов",
+ "allowed_protocols": "Разрешенные протоколы",
"app_hint": "Пароли приложений - это альтернативные пароли для авторизации в IMAP, SMTP, CalDAV, CardDAV и EAS. При этом имя пользователя остается неизменным. <br>SOGo недоступен через пароли приложений.",
"app_name": "Название приложения",
"app_passwds": "Пароли приложений",
"apple_connection_profile": "Профиль подключения Apple",
"apple_connection_profile_complete": "Этот профиль включает настройки IMAP и SMTP, а также CalDAV (календарей) и CardDAV (контактов) для устройства Apple.",
"apple_connection_profile_mailonly": "Этот профиль включает только настройки IMAP и SMTP для устройства Apple.",
+ "apple_connection_profile_with_app_password": "Новый пароль приложения генерируется и добавляется в профиль, поэтому при настройке устройства не требуется вводить пароль. Не предоставляйте доступ к файлу, поскольку он предоставляет полный доступ к вашему почтовому ящику.",
+ "attribute": "Атрибут",
"change_password": "Изменить пароль",
+ "change_password_hint_app_passwords": "В вашей учетной записи есть %d паролей приложений, которые не будут изменены. Чтобы управлять ими, перейдите на вкладку \"Пароли приложений\".",
"clear_recent_successful_connections": "Очистить историю успешных подключений",
"client_configuration": "Показать руководство по настройке почтовых клиентов и смартфонов",
"create_app_passwd": "Создать новый пароль",
@@ -1076,9 +1275,11 @@
"created_on": "Дата создания",
"daily": "Раз в день",
"day": "день",
+ "description": "Описание",
"delete_ays": "Пожалуйста, подтвердите удаление",
"direct_aliases": "Личные псевдонимы",
"direct_aliases_desc": "На личные псевдонимы распространяются фильтры нежелательной почты и параметры политики TLS.",
+ "direct_protocol_access": "Этот пользователь почтового ящика имеет <b>прямой, внешний доступ</b> к следующим протоколам и приложениям. Эта настройка контролируется вашим администратором. Для предоставления доступа к отдельным протоколам и приложениям могут быть созданы пароли приложений.<br> Кнопка \"Веб-почта\" обеспечивает единый вход в SOGo и всегда доступна.",
"eas_reset": "Сбросить кеш ActiveSync устройств",
"eas_reset_help": "Во многих случаях сброс кеша устройств помогает восстановить повреждённый профиль ActiveSync.<br><b>Внимание:</b> все письма, календари и контакты будут загружены заново на все ваши устройства!",
"eas_reset_now": "Сбросить кеш сейчас",
@@ -1119,19 +1320,22 @@
"no_last_login": "Информация о последнем входе в пользовательский интерфейс отсутствует",
"no_record": "Записи отсутствуют",
"open_logs": "Показать журнал",
- "open_webmail_sso": "Вход в веб-почту",
+ "open_webmail_sso": "веб-почту",
"password": "Пароль",
"password_now": "Текущий пароль (подтверждение изменения)",
"password_repeat": "Подтверждение пароля (повтор)",
+ "password_reset_info": "If no email for password recovery is provided, this function cannot be used.",
"pushover_evaluate_x_prio": "Установить высокий приоритет уведомлений для писем с высоким приоритетом [<code>X-Priority: 1</code>]",
"pushover_info": "Настройки Push-уведомления будут применяться ко всей почте <b>%s</b> (за исключением спама), включая псевдонимы (личные, общие и тегированные).",
"pushover_only_x_prio": "Получать уведомления только о письмах с высоким приоритетом [<code>X-Priority: 1</code>]",
"pushover_sender_array": "Получать уведомления от списка адресов электронной почты <small>(envelop-from, разделённые запятыми)</small>:",
"pushover_sender_regex": "Получать уведомления от отправителей, удовлетворяющих regex-выражению:",
+ "pushover_sound": "Звук уведомления",
"pushover_text": "Текст уведомления",
"pushover_title": "Заголовок уведомления",
"pushover_vars": "Когда фильтрация по отправителю не определена, уведомения будут доставлятся от всех отправителей.<br>Можно использовать обычный фильтр по отправителю и расширенный regex-фильтр, а также оба сразу.<br>Пожалуйста, ознакомьтесь с <a href=\"https://pushover.net/privacy\">Pushover Privacy Policy</a> перед использованием шаблонов для текста и заголовка",
"pushover_verify": "Проверить доступ",
+ "pw_recovery_email": "Адрес для восстановления пароля",
"q_add_header": "Нежелательная почта",
"q_all": "Все категории",
"q_reject": "Отклонённая почта",
@@ -1151,7 +1355,7 @@
"sogo_profile_reset": "Сбросить профиль SOGo",
"sogo_profile_reset_help": "<b>Внимание:</b> это удалит настройки профиля SOGo вместе с <b>всеми контактами, календарями и фильтрами безвозвратно</b>.",
"sogo_profile_reset_now": "Сбросить профиль сейчас",
- "spam_aliases": "Временные псевдонимы электронной почты",
+ "spam_aliases": "Псевдонимы для спама",
"spam_score_reset": "Сброс на настройки по умолчанию",
"spamfilter": "Спам фильтр",
"spamfilter_behavior": "Фильтрация спама",
@@ -1172,15 +1376,15 @@
"spamfilter_yellow": "Жёлтый: эти письма могут быть спамом, будут доставлены в папку \"Спам\"",
"status": "Статус",
"sync_jobs": "Задания синхронизации",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Ошибка авторизации",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Неправильное имя пользователя или пароль",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Ошибка связи с сервером",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Не удалось подключиться к удаленному серверу",
+ "syncjob_EXIT_OVERQUOTA": "Целевой почтовый ящик превысил квоту",
+ "syncjob_EXIT_TLS_FAILURE": "Ошибка установки шифрованного соединения",
+ "syncjob_EX_OK": "Успешно",
"syncjob_check_log": "Проверить журнал",
"syncjob_last_run_result": "Результат",
- "syncjob_EX_OK": "Успешно",
- "syncjob_EXIT_CONNECTION_FAILURE": "Ошибка связи с сервером",
- "syncjob_EXIT_TLS_FAILURE": "Ошибка установки шифрованного соединения",
- "syncjob_EXIT_AUTHENTICATION_FAILURE": "Ошибка авторизации",
- "syncjob_EXIT_OVERQUOTA": "Целевой почтовый ящик превысил квоту",
- "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Не удалось подключиться к удаленному серверу",
- "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Неправильное имя пользователя или пароль",
"tag_handling": "Обработка тегированной почты",
"tag_help_example": "Пример тегированного адреса электронной почты: <code>ich<b>+Facebook</b>@example.org</code>",
"tag_help_explain": "Переместить в подпапку: будет создана новая подпапка в INBOX с именем тега, например: \"INBOX/Facebook\".<br>\r\n Добавить к теме письма: имя тега будет добавлено к теме письма, например: \"[Facebook] My News\".",
@@ -1195,20 +1399,22 @@
"tls_policy_warning": "<strong>Предупреждение:</strong> Если вы включите принудительное шифрованние почты, вы можете столкнуться с потерей писем.<br>Сообщения, которые не соответствуют политике, будут отбрасываться с сообщением почтовым сервером о серьёзном сбое.<br>Этот параметр применяется к вашему основному адресу электронной почты (логину), всем личным псевдонимам и псевдонимам доменов. Подразумеваются только псевдонимы <b>с одним почтовым ящиком</b>, как получатель.",
"user_settings": "Настройки пользователя",
"username": "Имя пользователя",
+ "value": "Значение",
"verify": "Проверить",
"waiting": "В ожидании",
"week": "неделю",
"weekly": "Раз в неделю",
"weeks": "недели",
+ "with_app_password": "с паролем приложения",
"year": "год",
"years": "лет",
- "allowed_protocols": "Разрешенные протоколы",
- "apple_connection_profile_with_app_password": "Новый пароль приложения генерируется и добавляется в профиль, поэтому при настройке устройства не требуется вводить пароль. Не предоставляйте доступ к файлу, поскольку он предоставляет полный доступ к вашему почтовому ящику.",
- "direct_protocol_access": "Этот пользователь почтового ящика имеет <b>прямой, внешний доступ</b> к следующим протоколам и приложениям. Эта настройка контролируется вашим администратором. Для предоставления доступа к отдельным протоколам и приложениям могут быть созданы пароли приложений.<br> Кнопка \"Вход в веб-почту\" обеспечивает единый вход в SOGo и всегда доступна.",
- "with_app_password": "с паролем приложения",
- "change_password_hint_app_passwords": "В вашей учетной записи есть {{number_of_app_passwords}} паролей приложений, которые не будут изменены. Чтобы управлять ими, перейдите на вкладку \"Пароли приложений\".",
- "attribute": "Атрибут",
- "value": "Значение"
+ "authentication": "Аутентификация",
+ "tfa_info": "Двухфакторная аутентификация помогает защитить вашу учетную запись. Если вы включите эту функцию, вам понадобятся пароли приложений для входа в приложения или службы, которые не поддерживают двухфакторную аутентификацию (например, почтовые клиенты).",
+ "protocols": "Протоколы",
+ "overview": "Обзор",
+ "expire_never": "Никогда не истекает",
+ "forever": "Навсегда",
+ "spam_aliases_info": "Псевдоним для спама — это временный адрес электронной почты, который можно использовать для защиты реальных адресов.<br>При желании можно установить срок действия, по истечении которого псевдоним будет автоматически деактивирован, что позволяет эффективно избавляться от адресов, которые были использованы не по назначению или стали доступны посторонним лицам."
},
"warning": {
"cannot_delete_self": "Вы не можете удалить сами себя",
@@ -1222,8 +1428,5 @@
"quota_exceeded_scope": "Квота домена превышена: могут быть созданы только почтовые ящики без лимита.",
"session_token": "Неверный токен формы: несоответствие токена",
"session_ua": "Неверный токен формы: ошибка проверки User-Agent"
- },
- "datatables": {
- "infoPostFix": ""
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.si-si.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.si-si.json
index 3a42463..c13a089 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.si-si.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.si-si.json
@@ -3,11 +3,11 @@
"app_passwds": "Upravljaj gesla aplikacij",
"bcc_maps": "Preslikave SKP (BCC)",
"delimiter_action": "Dejanje ločila",
- "domain_relayhost": "Spremeni gostitelja relay za domeno",
+ "domain_relayhost": "Spremenite posrednika za domeno",
"eas_reset": "Ponastavi EAS naprave",
"filters": "Filtri",
"login_as": "Prijavi se kot uporabnik poštnega predala",
- "mailbox_relayhost": "Spremeni gostitelja relay za poštni predal",
+ "mailbox_relayhost": "Spremenite posrednika za e-poštni nabiralnik",
"prohibited": "Prepovedano z ACL",
"protocol_access": "Spremeni dostop do protokola",
"pushover": "Pushover",
@@ -17,33 +17,35 @@
"ratelimit": "Omejitev pošiljanja",
"recipient_maps": "Preslikave prejemnikov",
"smtp_ip_access": "Spremeni dovoljene gostitelje za SMTP",
- "sogo_access": "Dovoli upravljanje SOGo dostopov",
+ "sogo_access": "Dovoli upravljanje SOGo dostopa",
"sogo_profile_reset": "Ponastavi SOGo profil",
- "spam_alias": "Začasni aliasi",
- "spam_policy": "Blacklist/Whitelist",
+ "spam_alias": "Začasni vzdevki",
+ "spam_policy": "Seznam zavrnjenih/dovoljenih",
"spam_score": "Ocena neželene pošte",
"tls_policy": "Politika TLS",
"unlimited_quota": "Neomejena kvota za poštne predale",
- "alias_domains": "Dodaj alias domene",
+ "alias_domains": "Dodaj vzdevke domen",
"domain_desc": "Spremeni opis domene",
"extend_sender_acl": "Dovoli razširitev pošiljateljevega ACL z zunanjimi e-poštnimi naslovi",
"quarantine_category": "Spremeni kategorijo obvestil o karanteni",
- "syncjobs": "Opravila sinhronizacije"
+ "syncjobs": "Sinhronizacijska opravila",
+ "pw_reset": "Dovoli ponastavitev uporabniškega gesla mailcow",
+ "alias_external_goto": "Dovoli vzdevke z zunanjimi domenami goto"
},
"add": {
"active": "Aktivno",
"add": "Dodaj",
"add_domain_only": "Dodaj samo domeno",
"add_domain_restart": "Dodaj domeno in ponovno zaženi SOGo",
- "alias_address": "Alias naslov/i",
- "alias_domain": "Alias domena",
+ "alias_address": "Naslov/i vzdevk/a/ov",
+ "alias_domain": "Vzdevek domene",
"alias_domain_info": "<small>Samo veljavne domene (ločene z vejico).</small>",
"app_name": "Ime aplikacije",
"app_password": "Dodaj geslo aplikacije",
"app_passwd_protocols": "Dovoljeni protokoli za geslo aplikacije",
- "automap": "Poskusi samodejno preslikati mape (\"Sent items\", \"Sent\" => \"Poslano\" ipd.)",
+ "automap": "Poskusi samodejno preslikati mape (\"Poslani elementi\", \"Poslano\" => \"Poslano\" ipd.)",
"backup_mx_options": "Možnosti posredovanja (relay)",
- "comment_info": "Zasebni komentarji niso vidni uporabnikom, javni komentarji pa so prikazani kot tooltip, ko se z miško postavimo nad uporabnika v pregledu",
+ "comment_info": "Zasebni komentarji niso vidni uporabnikom, javni komentarji pa so prikazani kot opis, ko se z miško postavimo nad uporabnika v pregledu",
"custom_params": "Parametri po meri",
"custom_params_hint": "Pravilno: --param=xy, napačno: --param xy",
"delete1": "Izbriši na viru, ko je končano",
@@ -67,7 +69,7 @@
"kind": "Tip",
"mailbox_quota_def": "Privzeta kvota za poštni predal",
"mailbox_username": "Uporabniško ime (levi del e-poštnega naslova)",
- "max_aliases": "Največje število dovoljenih aliasov",
+ "max_aliases": "Največje število dovoljenih vzdevkov",
"max_mailboxes": "Največje dovoljeno število poštnih predalov",
"mins_interval": "Interval preverjanja (minute)",
"multiple_bookings": "Več rezervacij",
@@ -88,26 +90,30 @@
"sieve_type": "Vrsta filtra",
"skipcrossduplicates": "Preskoči podvojena sporočila po mapah (prvi pride, prvi melje)",
"subscribeall": "Prijavi vse mape",
- "syncjob": "Dodaj opravilo sinhronizacije",
+ "syncjob": "Dodaj sinhronizacijsko opravilo",
"tags": "Oznake",
- "target_address": "Goto naslov",
+ "target_address": "Pojdi na naslov",
"target_address_info": "<small>Polni e-poštni naslov/i (ločeni z vejico).</small>",
"target_domain": "Ciljna domena",
"timeout1": "Časovna omejitev za povezavo do oddaljenega gostitelja",
"username": "Uporabniško ime",
- "validate": "Preveri",
- "validation_success": "Uspešno preverjeno",
- "activate_filter_warn": "Ko je aktivni izbran, bodo vsi ostali filtri deaktivirani.",
- "alias_address_info": "<small>Polni email naslov/i oziroma @example.com za zajem vseh sporočil domene (ločeno z vejico), <b>samo domene mailcow</b>.</small>",
- "bcc_dest_format": "BCC naslov mora biti en veljaven e-poštni naslov.<br>Če morate poslati kopijo na več naslov, ustvarite alias in ga uporabite tukaj.",
+ "validate": "Potrditev",
+ "validation_success": "Uspešno potrjeno",
+ "activate_filter_warn": "Vsi drugi filtri bodo deaktivirani, če je označeno aktivno.",
+ "alias_address_info": "<small>Polni e-poštni naslov/i oziroma @example.com za zajem vseh sporočil domene (ločeno z vejico), <b>samo domene mailcow</b>.</small>",
+ "bcc_dest_format": "BCC naslov mora biti en veljaven e-poštni naslov.<br>Če morate poslati kopijo na več naslov, ustvarite vzdevek in ga uporabite tukaj.",
"disable_login": "Prepovej vpis (vhodna e-pošta je še vedno sprejeta)",
"gal_info": "GAL vsebuje vse objekte domene in ga uporabniki ne morejo urejati. Informacija o zasedenosti v SOGo ni na voljo, če je onemogočena! <b>Ponovno zaženi SOGo za uveljavitev sprememb.</b>",
"mailbox_quota_m": "Najvišja kvota na poštni predal (MiB)",
"password": "Geslo",
- "post_domain_add": "SOGo container \"sogo-mailcow\" mora biti ponovno zagnan po dodajanju nove domene!<br><br>Dodatno se mora preveriti DNS konfiguracija domene. Ko je DNS konfiguracija domene odobrena, ponovno zaženite \"acme-mailcow\" za samodejno generiranje certifikatov za novo domeno (autoconfig.<domain>, autodiscover.<domain>).<br>Ta korak je opcijski in se ponovno poskuša vsakih 24 ur.",
+ "post_domain_add": "SOGo zabojnik\"sogo-mailcow\" mora biti ponovno zagnan po dodajanju nove domene!<br><br>Dodatno se mora preveriti DNS konfiguracija domene. Ko je DNS konfiguracija domene odobrena, ponovno zaženite \"acme-mailcow\" za samodejno generiranje certifikatov za novo domeno (autoconfig.<domain>, autodiscover.<domain>).<br>Ta korak je opcijski in se ponovno poskuša vsakih 24 ur.",
"relay_transport_info": "<div class=\"badge fs-6 bg-info\">Info</div> Definirate lahko preslikave transportov za cilj po meri za to domeno. Če ni nastavljena, se ustvari MX poizvedba.",
- "syncjob_hint": "Pozor! Gesla se morajo shraniti v plain-text!",
- "timeout2": "Časovna omejitev za povezavo do lokalnega gostitelja"
+ "syncjob_hint": "Pozor! Gesla se morajo shraniti v golo besedilo!",
+ "timeout2": "Časovna omejitev za povezavo do lokalnega gostitelja",
+ "dry": "Simuliraj sinhronizacijo",
+ "internal": "Notranje",
+ "internal_info": "Notranji vzdevki so dostopni samo iz lastne domene ali vzdevkov domen.",
+ "sender_allowed": "Dovoli pošiljanje kot ta vzdevek"
},
"admin": {
"access": "Dostop",
@@ -123,7 +129,7 @@
"add_row": "Dodaj vrstico",
"add_settings_rule": "Dodaj pravilo nastavitev",
"add_transport": "Dodaj transport",
- "add_transports_hint": "Prosimo zavedajte se, da se podatki za avtentikacijo, če obstajajo, shranijo v plain text.",
+ "add_transports_hint": "Prosimo zavedajte se, da se podatki za avtentikacijo, če obstajajo, shranijo v golo besedilo.",
"additional_rows": " nove vrstice so bile dodane",
"admin_details": "Uredi podrobnosti skrbnika",
"admin_domains": "Dodeljene domene",
@@ -148,7 +154,7 @@
"customize": "Prilagodi",
"destination": "Cilj",
"dkim_add_key": "Dodaj ARC/DKIM ključ",
- "dkim_domains_selector": "Izbira",
+ "dkim_domains_selector": "Izbirnik",
"dkim_domains_wo_keys": "Izberi domene z manjkajočimi ključi",
"dkim_from": "Od",
"dkim_from_title": "Izvorna domena od katere prekopiram podatke",
@@ -170,56 +176,56 @@
"excludes": "Izključuje te prejemnike",
"f2b_ban_time": "Čas blokade (s)",
"f2b_ban_time_increment": "Čas blokade se poveča z vsako blokado",
- "f2b_blacklist": "Mreže/gostitelji na blacklisti",
+ "f2b_blacklist": "Omrežja/gostitelji na seznamu zavrnjenih",
"f2b_filter": "Regex filtri",
"f2b_max_attempts": "Največ poskusov",
"f2b_max_ban_time": "Maksimalno trajanje blokade (s)",
- "f2b_netban_ipv4": "velikost subneta IPv4 za blokiranje (8-32)",
- "f2b_netban_ipv6": "Velikost subneta IPv6 za blokiranje (8-128)",
+ "f2b_netban_ipv4": "velikost podomrežja IPv4 za blokiranje (8-32)",
+ "f2b_netban_ipv6": "Velikost podomrežja IPv6 za blokiranje (8-128)",
"f2b_parameters": "Fail2ban parametri",
"f2b_regex_info": "Upoštevajo se dnevniki SOGo, Postfix, Dovecot, PHP-FPM.",
"f2b_retry_window": "Upoštevan čas (s) za največ poskusov",
- "f2b_whitelist": "Mreže/gostitelji na whitelisti",
+ "f2b_whitelist": "Omrežja/gostitelji na seznamu dovoljenih",
"filter_table": "Filtriraj tabelo",
"from": "Od",
"generate": "ustvari",
"guid": "GUID - enolični ID instance",
"guid_and_license": "GUID & licenca",
- "hash_remove_info": "Odstranitev hasha za omejitev (če obstaja) bo povsem ponastavilo njen števec.<br>\n Vsak hash je prikazan z individualno barvo.",
- "help_text": "Zamenjaj tekst za pomoč pod masko za prijavo (HTML je dovoljen)",
+ "hash_remove_info": "Odstranitev zgoščene vrednosti za omejitev (če obstaja) bo povsem ponastavilo njen števec.<br>\n Vsaka zgoščena vrednost je prikazana z individualno barvo.",
+ "help_text": "Preglasi besedilo za pomoč pod masko za prijavo (HTML je dovoljen)",
"host": "Gostitelj",
"html": "HTML",
"import": "Uvozi",
"import_private_key": "Uvozi zasebni ključ",
- "in_use_by": "V uporabi",
+ "in_use_by": "V uporabi od",
"inactive": "Neaktivno",
"include_exclude": "Vključi/Izključi",
"include_exclude_info": "Privzeto - če ni izbire - so vključeni <b>vsi poštni predali</b>",
"includes": "Vključi te prejemnike",
- "ip_check": "Kontrola IP",
- "ip_check_disabled": "Kontrola IP je onemogočena. Lahko jo omogočite pod <br/> <strong>Sistem > Konfiguracija > Možnosti > Prilagodi</strong>",
- "ip_check_opt_in": "Opt-in za uporabo zunanje storitve <strong>ipv4.mailcow.email</strong> in <strong>ipv6.mailcow.email</strong> za razreševanje zunanjih IP.",
- "is_mx_based": "Glede na MX",
- "last_applied": "Nazadnje aplicirano",
+ "ip_check": "Preverjanje IP-ja",
+ "ip_check_disabled": "Preverjanje IP-ja je onemogočeno. Lahko ga omogočite pod <br/> <strong>Sistem > Konfiguracija > Možnosti > Prilagodi</strong>",
+ "ip_check_opt_in": "Prijavite se za uporabo storitev tretjih oseb <strong>ipv4.mailcow.email</strong> in <strong>ipv6.mailcow.email</strong> za razreševanje zunanjih IP naslovov.",
+ "is_mx_based": "Glede na MX zapis",
+ "last_applied": "Nazadnje uporabljeno",
"link": "Povezava",
"loading": "Prosim počakajte...",
"login_time": "Čas prijave",
- "logo_info": "Vaša slika bo pomanjšana na velikost 40px za zgornjo navigacijo in največjo velikost 250px za začetno stran. Zelo priporočena je uporaba grafike brez izgube kakovosti ob spremembi velikosti.",
+ "logo_info": "Vaša slika bo pomanjšana na višino 40 slikovnih pik za zgornjo navigacijsko vrstico in na največjo širino 250 slikovnih pik za začetno stran. Zelo priporočljiva je skalabilna grafika.",
"message": "Sporočilo",
"message_size": "Velikost sporočila",
"nexthop": "Naslednji skok",
"no": "✕",
"no_active_bans": "Ni aktivnih blokad",
- "no_new_rows": "Ni dodatnih vrstic",
+ "no_new_rows": "Nadaljnjih vrstic ni na voljo",
"no_record": "Ni zapisa",
"oauth2_apps": "OAuth2 aplikacije",
"oauth2_add_client": "Dodaj OAuth2 klienta",
- "oauth2_client_id": "ID klienta",
- "oauth2_client_secret": "Skrivnost (secret)",
+ "oauth2_client_id": "ID odjemalca",
+ "oauth2_client_secret": "Skrivnost odjemalca",
"oauth2_redirect_uri": "URI za preusmeritev",
- "oauth2_renew_secret": "Generiraj nov client secret",
- "oauth2_revoke_tokens": "Zavrni vse tokene klientov",
- "optional": "opcijsko",
+ "oauth2_renew_secret": "Generiraj novo skrivnost odjemalca",
+ "oauth2_revoke_tokens": "Prekliči vse žetone odjemalca",
+ "optional": "neobvezno",
"options": "Možnosti",
"password": "Geslo",
"password_length": "Dolžina gesla",
@@ -234,21 +240,21 @@
"private_key": "Zasebni ključ",
"quarantine": "Karantena",
"quarantine_bcc": "Pošlji kopijo vseh obvestil (BCC) temu prejemniku:<br><small>Pustite prazno za izklop te funkcije. <b>Nepodpisana, nepreverjena pošta. Uporabljalo naj bi se samo za interno dostavo.</b></small>",
- "quarantine_exclude_domains": "Izključi domene in alias-domene",
- "quarantine_max_age": "Maksimalna starost v dnevnih<br><small>Vrednost mora biti večja ali enaka 1 dnevu</small>",
- "quarantine_max_score": "Opusti obvestilo, če je ocena spama večja od te vrednosti:<br><small>Privzeto 9999.0</small>",
- "quarantine_max_size": "Največja velikost v MiB (Večji elementi so zavrženi):<br><small>0 <b>ne</b> pomeni neomejeno.</small>",
- "quarantine_notification_html": "Predloga sporočila za obvestilo:<br><small>Pustite prazno za obnovitev privzete predloge.</small>",
- "quarantine_notification_sender": "Pošiljatelj obvestila",
- "quarantine_notification_subject": "Naslov obvestila",
- "quarantine_release_format": "Oblika sproščenih elementov",
+ "quarantine_exclude_domains": "Izključi domene in vzdevke domen",
+ "quarantine_max_age": "Najvišja starost v dneh<br><small>Vrednost mora biti enaka ali večja od 1 dneva.</small>",
+ "quarantine_max_score": "Zavrzi obvestilo, če je ocena neželene pošte višja od te vrednosti:<br><small>Privzeto 9999,0</small>",
+ "quarantine_max_size": "Največja velikost v MiB (večji elementi so zavrženi):<br><small>0 <b>ne</b> pomeni neomejeno.</small>",
+ "quarantine_notification_html": "Predloga za obvestilo po e-pošti:<br><small>Pustite prazno, če želite obnoviti privzeto predlogo.</small>",
+ "quarantine_notification_sender": "Pošiljatelj obvestil po e-pošti",
+ "quarantine_notification_subject": "Zadeva e-poštnega obvestila",
+ "quarantine_release_format": "Oblika izdanih elementov",
"quarantine_release_format_att": "Kot priponka",
- "quarantine_release_format_raw": "Nespremenjen original",
- "quarantine_retention_size": "Število zadržanj na poštni predal: <br><small>0 pomeni <b>neaktivno</b>,</small>",
+ "quarantine_release_format_raw": "Nespremenjen izvirnik",
+ "quarantine_retention_size": "Hrambe na poštni predal:<br><small>0 pomeni <b>neaktivno</b>.</small>",
"quota_notification_sender": "Pošiljatelj obvestila",
"quota_notification_subject": "Predmet obvestila",
- "quota_notifications": "Obvestila o omejitvi",
- "quota_notifications_info": "Obvestila o omejitvi so poslana uporabnikom enkrat, ko presežejo 80% in enkrat ko presežejo 95% zasedenosti.",
+ "quota_notifications": "Obvestila o kvotah",
+ "quota_notifications_info": "Obvestila o kvoti se uporabnikom pošljejo enkrat, ko presežejo 80 % in enkrat, ko presežejo 95 % porabe.",
"queue_unban": "odblokiraj",
"r_active": "Aktivne omejitve",
"r_inactive": "Neaktivne omejitve",
@@ -264,8 +270,8 @@
"remove": "Odstrani",
"remove_row": "Odstrani vrstico",
"reset_default": "Ponastavi na privzeto",
- "reset_limit": "Odstrani hash",
- "routing": "Routing",
+ "reset_limit": "Odstrani zgoščeno vrednost",
+ "routing": "Usmerjanje",
"rsetting_add_rule": "Dodaj pravilo",
"rsetting_content": "Vsebina pravila",
"rsetting_desc": "Kratek opis",
@@ -273,48 +279,48 @@
"rsetting_none": "Ni pravil na voljo",
"rsettings_insert_preset": "Vstavi prednastavljen primer \"%s\"",
"rsettings_preset_1": "Onemogoči vse razen DKIM in omejitve za prijavljene uporabnike",
- "rsettings_preset_2": "Postmasterji želijo spam",
- "rsettings_preset_3": "Dovoli samo specifične pošiljatelje za poštni predal (npr. uporaba samo kot interni poštni predal)",
+ "rsettings_preset_2": "Poštni upravitelji želijo neželeno pošto",
+ "rsettings_preset_3": "Dovoli samo določene pošiljatelje za poštni predal (tj. uporabo samo kot notranji poštni predal)",
"rsettings_preset_4": "Onemogoči Rspamd za domeno",
- "rspamd_com_settings": "Ime nastavitve bo samodejno generirano. Prosim oglejte si primere nastavitev spodaj. Za več informacij si oglejte <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">dokumentacijo Rspamd</a>",
+ "rspamd_com_settings": "Ime nastavitve bo samodejno ustvarjeno, oglejte si spodnje primere prednastavitev. Za več podrobnosti glejte <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">dokumentacijo Rspamd</a>",
"rspamd_global_filters": "Globalne preslikave filtrov",
"rspamd_global_filters_agree": "Previden bom!",
- "rspamd_global_filters_info": "Globalne preslikave filtrov vsebujejo različne vrste globalnih blacklist in whitelist.",
+ "rspamd_global_filters_info": "Globalni filtri vsebujejo različne vrste globalnih seznamov zavrnjenih in dovoljenih vsebin.",
"add_admin": "Dodaj skrbnika",
- "add_relayhost_hint": "Prosimo zavedajte se, da se podatki za avtentikacijo, če obstajajo, shranijo v plain text.",
+ "add_relayhost_hint": "Prosimo zavedajte se, da se podatki za avtentikacijo, če obstajajo, shranijo v golo besedilo.",
"admin": "Skrbnik",
"api_allow_from": "Dovoli API dostop s teh IP naslovov / CIDR mrežnih zapisov",
"apps_name": "Ime aplikacije v mailcow",
- "ban_list_info": "Oglejte si seznam blokiranih IP naslovov spodaj: <b>network (remaining ban time) - [actions]</b>.<br />. IPji v vrsti za odstranitev blokade bodo odstranjeni iz aktivnega seznama blokad v nekaj sekundah.<br />Rdeče oznake prikazujejo trajne blokade z blacklisto.",
+ "ban_list_info": "Spodaj si oglejte seznam prepovedanih IP-jev: <b>omrežje (preostali čas prepovedi) - [dejanja]</b>.<br />IP-ji, ki so v čakalni vrsti za odpravo prepovedi, bodo v nekaj sekundah odstranjeni s seznama aktivnih prepovedi.<br />Rdeče oznake označujejo aktivne trajne prepovedi s seznama zavrnjenih.",
"dkim_key_length": "Dolžina DKIM ključa (v bitih)",
"dkim_to_title": "Ciljne domene bodo prepisane",
- "f2b_list_info": "Gostitelj ali omrežje na blacklisti bo vedno prevladal zapis na whitelisti. <b>Apliciranje sprememb seznama traja nekaj sekund.</b>",
+ "f2b_list_info": "Gostitelj ali omrežje na seznamu zavrnjenih bo vedno imelo prednost pred entiteto na seznamu dovoljenih. <b>Posodobitve seznama bodo trajale nekaj sekund, da se uporabijo.</b>",
"forwarding_hosts": "Gostitelji za posredovanje",
"forwarding_hosts_add_hint": "Lahko vpišete IPv4/IPv6 naslove, mreže v CIDR obliki, imena gostiteljev (kateri se prevedejo v IP naslove) ali imena domen (katera se prevedejo v IP naslove glede na poizvedbo po SPF zapisih, v primeru manjkajočih zapisov pa MX zapisih).",
- "forwarding_hosts_hint": "Dohodna sporočila so brezpogojno sprejeta od katerih koli gostiteljev v tem seznamu. Ti gostitelji se ne bodo preverjali po DNSBL seznamih in ne bodo dodani v greyliste. Prejeti spam s teh gostiteljev ni nikoli zavrnjen, opcijsko pa se lahko premakne v mapo neželene pošte. Najpogostejša uporaba za to je navedba poštnih strežnikov, iz katerih ste nastavili pravilo za posredovanje pošte na vaš mailcow strežnik.",
- "license_info": "Licenca ni zahtevana, a pomaga pri nadaljnjem razvoju. <br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"Naročilo SAL\">Registrirajte svoj GUID tukaj</a> ali <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Naročilo podpora\">Kupite podporo za svojo namestitev Mailcow.</a>",
- "lookup_mx": "Cilj je regular expression za ujemanje MX zapisov (<code>.*\\.google\\.com</code> za usmeritev vse pošte na MX, ki se konča z google.com, preko tega skoka)",
+ "forwarding_hosts_hint": "Dohodna sporočila so brezpogojno sprejeta od katerih koli gostiteljev v tem seznamu. Ti gostitelji se ne bodo preverjali po DNSBL seznamih in ne bodo dodani v listo sivih. Prejeta neželena pošta s teh gostiteljev ni nikoli zavrnjena, opcijsko pa se lahko premakne v mapo neželene pošte. Najpogostejša uporaba za to je navedba poštnih strežnikov, iz katerih ste nastavili pravilo za posredovanje pošte na vaš mailcow strežnik.",
+ "license_info": "Licenca ni zahtevana, a pomaga pri nadaljnjem razvoju. <br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"Naročilo SAL\">Registrirajte svoj GUID tukaj</a> ali <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Naročilo podpore\">Kupite podporo za svojo namestitev Mailcow.</a>",
+ "lookup_mx": "Cilj je regularni izraz, ki se ujema z imenom MX (<code>.*\\.google\\.com</code> za usmerjanje vse pošte, usmerjene na MX, ki se konča na google.com, prek tega skoka)",
"main_name": "Naziv \"mailcow UI\"",
"merged_vars_hint": "Sive vrstice so združene iz <code>vars.(local.)inc.php</code> in jih ni mogoče spremeniti.",
- "oauth2_info": "OAuth2 implementacija omogoča grant vrste \"Authorization code\" in izdaja refresh tokene.<br>\nStrežnik prav tako izda nove refresh tokene, ko je bil refresh token uporabljen<br><br>\n• Privzeti obseg je <i>profile</i>. Samo uporabniki poštnih predalov se lahko prijavijo s pomočjo OAuth2. Če parameter obsega ni vnesen, se nastavi na <i>profile</i>.<br>\n• Parameter <i>state</i> mora biti poslan s strani klienta kot del zahtevka za avtorizacijo .<br><br>\nPoti za OAuth2 API: <br>\n<ul>\n <li>Endpoint za avtorizacijo: <code>/oauth/authorize</code></li>\n <li>Endpoint za tokene: <code>/oauth/token</code></li>\n <li>Stran vira: <code>/oauth/profile</code></li>\n</ul>\nPonovno generiranje client secret ne bo razveljavilo obstoječih avtorizacijskih kod, ne bodo pa mogle obnoviti svoje tokene.<br><br>\nZavrnitev client tokenov bo povzročilo tekojčno prekinitev aktivnih sej. Vsi klienti se bodo morali ponovno prijaviti.",
- "quarantine_redirect": "<b>Preusmeri vsa obvestila</b> k temu prejemniku:<br><small>Pustite prazno, da onemogočite. <b>Nepodpisana, nepreverjena pošta. Uporabljalo bi se naj samo za interno dostavo.</b></small>",
+ "oauth2_info": "Implementacija OAuth2 podpira vrsto odobritve »Avtorizacijska koda« in izda osvežilne žetone.<br>\nStrežnik samodejno izda tudi nove osvežilne žetone, ko je žeton za osvežitev uporabljen.<br><br>\n• Privzeti obseg je <i>profile</i>. Prek OAuth2 je mogoče overiti samo uporabnike poštnega predala. Če parameter obsega izpustite, se vrne na <i>profile</i>.<br>\n• Parameter <i>state</i> mora odjemalec poslati kot del zahteve za avtorizacijo.<br><br>\nPoti za zahteve do API-ja OAuth2: <br>\n<ul>\n<li>Končna točka avtorizacije: <code>/oauth/authorize</code></li>\n<li>Končna točka žetona: <code>/oauth/token</code></li>\n<li>Stran z viri: <code>/oauth/profile</code></li>\n</ul>\nPonovno ustvarjanje skrivnosti odjemalca ne bo poteklo obstoječih kod za avtorizacijo, vendar ne bo obnovilo žetona.<br><br>\nPreklic žetonov odjemalca bo povzročil takojšnjo prekinitev vseh aktivnih sej. Vse stranke se morajo ponovno overiti.",
+ "quarantine_redirect": "<b>Preusmerite vsa obvestila</b> temu prejemniku:<br><small>Pustite prazno, če želite onemogočiti. <b>Nepodpisana, nepreverjena pošta. Dostavljeno samo interno.</b></small>",
"quota_notification_html": "Predloga sporočila za obvestilo:<br><small>Pustite prazno za obnovitev privzete predloge.</small>",
- "quota_notifications_vars": "{{percent}} pomeni trenutna omejitev uporabnika<br>{{username}} je ime poštnega predala",
- "r_info": "Sivi/onemogočeni elementi v seznamu aktivnih omejitev niso znane kot veljavne omejitve za mailcow in ne morejo biti premaknjene. Neznane omejitve bodo kljub temu nastavljene po vrstnem redu pojavitve. <br>Nove elemente lahko dodate v <code>inc/vars.local.inc.php</code> da jih lahko vklopite ali izklopite.",
- "relayhosts_hint": "Določite transporte glede na pošiljatelja, da jih lahko izberete v konfiguraciji domene.<br>\nTransportni servis je vedno \"smtp:\" in bo poskušal s TLS ko bo na voljo. Wrapped TLS (SMTPS) ni podprto. Upošteva se uporabnikova politika odhodnega TLS.<br>\nVpliva na izbrane domene vključno z alias domenami.",
- "transport_dest_format": "Regex ali sintaksa: example.org, .example.org, *, box@example.org (več vrednosti ločite z vejico)",
- "transport_test_rcpt_info": "• Uporabite null@hosted.mailcow.de za testiranje relaya na drugo destinacijo.",
- "rspamd_global_filters_regex": "Njihovi nazivi pojasnijo njihov namen. Vsa vsebina mora imeti veljaven regular expression v obliki \"/pattern/options\" (npr. <code>/.+@domain\\.tld/i</code>).<br>\nČeprav se v vsaki vrstici regexa izvedejo osnovni pregledi, je lahko funkcionalnost programa Rspamd motena, če sintaksa ni pravilna.<br>\nRspamd bo poskušal prebrati vsebino preslikave, ko bo spremenjena. Če imate težave, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">ponovno zaženite Rspamd</a>, da prisilite ponovno nalaganje preslikav.<br> Elementi z Blackliste so izključeni iz karantene.",
+ "quota_notifications_vars": "{{percent}} je enako trenutni kvoti uporabnika<br>{{username}} je ime poštnega predala",
+ "r_info": "Sivi/onemogočeni elementi v seznamu aktivnih omejitev niso znane kot veljavne omejitve za mailcow in ne morejo biti premaknjene. Neznane omejitve bodo kljub temu nastavljene po vrstnem redu pojavljanja. <br>Nove elemente lahko dodate v <code>inc/vars.local.inc.php</code> da jih lahko vklopite ali izklopite.",
+ "relayhosts_hint": "Določite transporte, odvisne od pošiljatelja, da jih boste lahko izbrali v pogovornem oknu za konfiguracijo domen.<br>\n Transportna storitev je vedno »smtp:« in bo zato poskusila s TLS, ko bo ponujena. Zaviti TLS (SMTPS) ni podprt. Upošteva se individualna nastavitev pravilnika za odhodni TLS uporabnika.<br>\n Vpliva na izbrane domene, vključno z vzdevki domen.",
+ "transport_dest_format": "Regex ali sintaksa: example.org, .example.org, *, box@example.org (več vrednosti je lahko ločenih z vejicami)",
+ "transport_test_rcpt_info": "• Za preizkus posredovanja v tujino uporabite null@hosted.mailcow.de.",
+ "rspamd_global_filters_regex": "Njihova imena pojasnjujejo njihov namen. Vsa vsebina mora vsebovati veljaven regularni izraz v obliki »/vzorec/možnosti« (npr. <code>/.+@domena\\.tld/i</code>).<br>\n Čeprav se v vsaki vrstici regularnega izraza izvajajo osnovna preverjanja, je lahko funkcionalnost Rspamdsa pokvarjena, če sintakse ne prebere pravilno.<br>\n Rspamd bo poskušal prebrati vsebino zemljevida, ko se bo spremenila. Če pride do težav, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">znova zaženite Rspamd</a>, da uveljavite ponovno nalaganje zemljevida.<br>Elementi na seznamu zavrnjenih so izključeni iz karantene.",
"rspamd_settings_map": "Preslikava nastavitev Rspamd",
"sal_level": "Moo stopnja",
"save": "Shrani spremembe",
"search_domain_da": "Išči domene",
"send": "Pošlji",
"sender": "Pošiljatelj",
- "service": "Servis",
- "service_id": "ID servisa",
+ "service": "Storitev",
+ "service_id": "ID storitve",
"source": "Vir",
- "spamfilter": "Spam filter",
+ "spamfilter": "Filter neželene pošte",
"subject": "Predmet",
"success": "Uspešno",
"sys_mails": "Sistemska pošta",
@@ -324,7 +330,7 @@
"title_name": "Naziv spletnega mesta \"mailcow UI\"",
"to_top": "Nazaj na vrh",
"transport_maps": "Preslikave transportov",
- "transports_hint": "• Vpis preslikave transporta <b>nadredi</b> preslikavo transporta odvisno od pošiljatelja.<br>\n• Preferenčno se uporabljajo transporti glede na MX zapise.<br>\n• Izhodne TLS politike na uporabnika so ignorirane in se lahko vsilijo samo s preslikavami TLS politik.<br>\n• Transportni servis za definirane transporte je vedno \"smtp:\" in bo posledično poskušal TLS ko bo ponujeno. Wrapped TLS (SMTPS) ni podprto.<br>\n• Naslovi, ki se ujemajo z \"/localhost$/\" bodo vedno preneseni preko \"local:\", in zato destinacija \"*\" ne bo vplivala na te naslove.<br>\n• Za določitev poverilnic za naslednji skok (npr. \"[host]:25\"), Postfix <b>vedno</b> preveri \"host\" preden išče \"[host]:25\". Zaradi takšnega obnašanja je nemogoče hkrati uporabiti \"host\" in \"[host]:25\".",
+ "transports_hint": "• Vnos preslikave transporta <b>preglasi</b> preslikavo transporta, ki je odvisen od pošiljatelja.<br>\n• Po možnosti se uporabljajo transporti, ki temeljijo na MX.<br>\n• Nastavitve pravilnika TLS za odhodne uporabnike se prezrejo in jih je mogoče uveljaviti le z vnosi v zemljevidu pravilnika TLS.<br>\n• Storitev transporta za definirane transporte je vedno »smtp:« in bo zato poskusila s TLS, ko bo ponujena. Zaviti TLS (SMTPS) ni podprt.<br>\n• Naslovi, ki se ujemajo z \"/localhost$/\" bodo vedno preneseni preko \"local:\", in zato cilj \"*\" ne bo veljal za te naslove.<br>\n• Za določitev poverilnic za zgledni naslednji skok \"[host]:25\", Postfix <b>vedno</b> poišče \"host\" preden poišče \"[host]:25\". Zaradi tega vedenja je nemogoče hkrati uporabljati \"host\" in \"[host]:25\".",
"ui_footer": "Noga (HTML dovoljen)",
"ui_header_announcement": "Obvestila",
"ui_header_announcement_active": "Nastavi obvestilo kot aktivno",
@@ -336,7 +342,7 @@
"ui_header_announcement_type_info": "Info",
"ui_header_announcement_type_warning": "Pomembno",
"ui_texts": "Oznake in besedila UI",
- "unban_pending": "unban v postopku",
+ "unban_pending": "odblokada v teku",
"unchanged_if_empty": "Če je nespremenjeno, pustite prazno",
"upload": "Naloži",
"username": "Uporabniško ime",
@@ -347,13 +353,78 @@
"logo_dark_label": "Za temni način",
"cors_settings": "Nastavitve CORS",
"allowed_methods": "Dovoljene metode za upravljanje dostopa",
- "allowed_origins": "Upravljanje-dostopa-Dovoljeni-Viri"
+ "allowed_origins": "Upravljanje-dostopa-Dovoljeni-Viri",
+ "copy_to_clipboard": "Besedilo kopirano v odložišče!",
+ "f2b_manage_external": "Zunanje upravljanje Fail2Ban",
+ "f2b_manage_external_info": "Fail2ban bo še vedno vzdrževal seznam prepovedi, vendar ne bo aktivno nastavil pravil za blokiranje prometa. Uporabite spodnji ustvarjeni seznam prepovedi za zunanje blokiranje prometa.",
+ "force_sso_text": "Če je konfiguriran zunanji ponudnik OIDC, ta možnost skrije privzete obrazce za prijavo v Mailcow in prikaže samo gumb za enotno prijavo",
+ "app_hide": "Skrij za prijavo",
+ "iam_login_provisioning": "Samodejno ustvarjanje uporabnikov ob prijavi",
+ "admin_quicklink": "Skrij hitro povezavo do strani za prijavo skrbnika",
+ "login_page": "Prijavna stran",
+ "domainadmin_quicklink": "Skrij hitro povezavo do strani za prijavo v Skrbnik domen",
+ "filter": "Filter",
+ "force_sso": "Onemogoči prijavo v mailcow in prikaži samo enotno prijavo",
+ "iam": "Ponudnik identitete",
+ "iam_attribute_field": "Polje atributa",
+ "iam_authorize_url": "Končna točka avtorizacije",
+ "iam_auth_flow": "Potek preverjanja pristnosti",
+ "iam_auth_flow_info": "Poleg toka avtorizacijske kode (standardni tok v Keycloaku), ki se uporablja za prijavo z enotno prijavo, mailcow podpira tudi tok preverjanja pristnosti z neposrednimi poverilnicami. Tok Mailpassword poskuša preveriti uporabnikove poverilnice z uporabo REST API-ja Keycloak Admin. mailcow pridobi zgoščeno geslo iz atributa <code>mailcow_password</code>, ki je preslikan v Keycloaku.",
+ "iam_basedn": "Osnovni DN",
+ "iam_client_id": "ID odjemalca",
+ "iam_client_secret": "Skrivnost odjemalca",
+ "iam_client_scopes": "Obsegi odjemalcev",
+ "iam_default_template": "Privzeta predloga",
+ "iam_default_template_description": "Če uporabniku ni dodeljena nobena predloga, bo privzeta predloga uporabljena za ustvarjanje nabiralnika, ne pa za posodabljanje nabiralnika.",
+ "iam_description": "Konfigurirajte zunanjega ponudnika za preverjanje pristnosti<br>Uporabnikovi poštni nabiralniki bodo samodejno ustvarjeni ob prvi prijavi, če je nastavljeno preslikavanje atributov.",
+ "iam_extra_permission": "Za delovanje naslednjih nastavitev potrebuje odjemalec mailcow v Keycloaku <code>Servisni račun</code> in dovoljenje za <code>ogled uporabnikov</code>.",
+ "iam_host": "Gostitelj",
+ "iam_host_info": "Vnesite enega ali več gostiteljev LDAP, ločenih z vejicami.",
+ "iam_import_users": "Uvozi uporabnike",
+ "iam_use_tls_info": "Če omogočite TLS, morate uporabiti privzeta vrata za strežnik LDAP (389). Vrat SSL ni mogoče uporabiti.",
+ "iam_sync_interval": "Interval sinhronizacije / uvoza (min)",
+ "user_quicklink": "Skrij hitro povezavo do strani za prijavo uporabnika",
+ "iam_use_ssl_info": "Če omogočite SSL in so vrata nastavljena na 389, bodo samodejno prepisana na uporabo 636.",
+ "iam_mapping": "Preslikava atributov",
+ "iam_bindpass": "Vezano geslo",
+ "iam_periodic_full_sync": "Periodična popolna sinhronizacija",
+ "iam_port": "Vrata",
+ "iam_redirect_url": "Preusmeri URL",
+ "iam_rest_flow": "Tok gesla za pošto",
+ "iam_server_url": "URL strežnika",
+ "iam_sso": "Enotna prijava",
+ "iam_test_connection": "Preizkus povezave",
+ "iam_token_url": "Končna točka žetona",
+ "iam_userinfo_url": "Končna točka z uporabniškimi podatki",
+ "iam_username_field": "Polje z uporabniškim imenom",
+ "iam_binddn": "Vezava DN",
+ "iam_use_ssl": "Uporabi SSL",
+ "iam_use_tls": "Uporabi StartTLS",
+ "iam_version": "Različica",
+ "ignore_ssl_error": "Prezri napake SSL",
+ "password_reset_info": "Če ni naveden e-poštni naslov za obnovitev, te funkcije ni mogoče uporabiti.",
+ "password_reset_settings": "Nastavitve za obnovitev gesla",
+ "password_reset_tmpl_html": "Predloga HTML",
+ "password_reset_tmpl_text": "Predloga besedila",
+ "password_settings": "Nastavitve gesla",
+ "quicklink_text": "Prikaži ali skrij hitre povezave do drugih strani za prijavo pod prijavnim obrazcem",
+ "reset_password_vars": "<code>{{link}}<code> Ustvarjena povezava za ponastavitev gesla<br><code>{{username}}<code> Ime nabiralnika uporabnika, ki je zahteval ponastavitev gesla<br><code>{{username2}}<code> Ime obnovitvenega nabiralnika<br><code>{{date}}<code> Datum zahteve za ponastavitev gesla<br><code>{{token_lifetime}}<code> Življenjska doba žetona v minutah<br><code>{{hostname}}<code> Ime gostitelja mailcow",
+ "restore_template": "Za obnovitev privzete predloge pustite polje prazno.",
+ "task": "Naloga",
+ "user_link": "Uporabniška povezava",
+ "iam_realm": "Realm",
+ "needs_restart": "potreben je ponovni zagon",
+ "ui_theme": "Tema",
+ "ui_theme_dark": "Vključuje različico s temnim načinom",
+ "ui_theme_default": "Privzeto",
+ "ui_theme_info": "Teme so mape v <code>data/web/css/themes/<name>/</code>, ki vsebujejo naslednje datoteke:<ul class=\"mb-0\"><li><code>theme.css</code> (obvezna)</li><li><code>dark.css</code> (neobvezna, temni način)</li><li><code>bootstrap.css</code> (neobvezna, nadomesti osnovno temo Bootstrap)</li><li><code>theme.json</code> (neobvezna, <code>name</code> in <code>description</code>)</li></ul>",
+ "ui_theme_none": "Tem ni bilo mogoče najti."
},
"danger": {
- "alias_goto_identical": "Alias in goto naslov morata biti identična",
- "aliasd_targetd_identical": "Alias domena ne sme biti enaka ciljni domeni: %s",
- "bcc_exists": "BCC preslikava obstaja za vrsto %s",
- "dkim_domain_or_sel_exists": "DKIM ključ za \"%s\" obstaja in ne bo prepisan.",
+ "alias_goto_identical": "Vzdevek in ciljni naslov se ne smeta ujemati",
+ "aliasd_targetd_identical": "Vzdevek domene ne sme biti enak ciljni domeni: %s",
+ "bcc_exists": "Za tip %s obstaja BCC preslikava %s",
+ "dkim_domain_or_sel_exists": "DKIM ključ za \"%s\" obstaja in ne bo prepisan",
"domain_quota_m_in_use": "Kvota domene mora biti večja ali enaka %s MiB",
"extra_acl_invalid_domain": "Zunanji pošiljatelj \"%s\" uporablja neveljavno domeno",
"global_map_write_error": "Ni mogoče zapisati ID globalne preslikave %s: %s",
@@ -361,71 +432,71 @@
"invalid_nexthop": "Oblika naslednjega skoka ni veljavna",
"invalid_nexthop_authenticated": "Naslednji skok obstaja z drugačnimi poverilnicami. Prosim najprej posodobite obstoječe poverilnice za ta naslednji skok.",
"demo_mode_enabled": "Demo način je omogočen",
- "access_denied": "Dostop zavrnjen ali pa so podatki obrazca napačni",
- "alias_domain_invalid": "Alias domena %s ni veljavna",
- "alias_empty": "Alias naslov ne sme biti prazen",
- "alias_invalid": "Alias naslov %s ni veljaven",
- "aliases_in_use": "Max. aliasov mora biti večje ali enako %d",
- "app_name_empty": "Naziv aplikacije ne more biti prazno",
- "app_passwd_id_invalid": "ID gesla aplikacije %s je neveljaven",
- "bcc_empty": "BCC cilj ne more biti prazen",
- "bcc_must_be_email": "BCC cilj %s ni veljaven e-poštni naslov",
- "comment_too_long": "Komentar je predolg, dovoljeno je največ 100 znakov.",
- "defquota_empty": "Privzeta kvota na poštni predal ne more biti 0",
- "description_invalid": "Opis resursa za %s ni veljaven",
+ "access_denied": "Dostop zavrnjen ali neveljavni podatki obrazca",
+ "alias_domain_invalid": "Vzdevek domene %s ni veljaven",
+ "alias_empty": "Naslov vzdevka ne sme biti prazen",
+ "alias_invalid": "Naslov vzdevka %s ni veljaven",
+ "aliases_in_use": "Največje število vzdevkov mora biti večje ali enako %d",
+ "app_name_empty": "Ime aplikacije ne sme biti prazno",
+ "app_passwd_id_invalid": "ID gesla za aplikacijo %s neveljaven",
+ "bcc_empty": "Polje za prejemnika BCC ne sme biti prazno",
+ "bcc_must_be_email": "Cilj BCC %s ni veljaven e-poštni naslov",
+ "comment_too_long": "Komentar je predolg, dovoljeno je največ 160 znakov",
+ "defquota_empty": "Privzeta kvota na poštni predal ne more biti 0.",
+ "description_invalid": "Opis vira za %s je neveljaven",
"dkim_domain_or_sel_invalid": "Domena ali izbirnik DKIM ni veljaven: %s",
"domain_cannot_match_hostname": "Domena se ne more ujemati z imenom gostitelja",
"domain_exists": "Domena %s že obstaja",
- "domain_invalid": "Manjka ali napačno ime domene",
- "domain_not_empty": "Ne morem odstraniti ne-prazno domeno %s",
+ "domain_invalid": "Ime domene je prazno ali neveljavno",
+ "domain_not_empty": "Neprazne domene %s ni mogoče odstraniti",
"domain_not_found": "Domene %s ni bilo mogoče najti",
"extended_sender_acl_denied": "manjka ACL za določitev naslovov zunanjih pošiljateljev",
"extra_acl_invalid": "Naslov zunanjega pošiljatelja \"%s\" ni veljaven",
"fido2_verification_failed": "Preverjanje FIDO2 ni uspelo: %s",
- "file_open_error": "Datoteka ne more biti odprta za urejanje",
+ "file_open_error": "Datoteke ni mogoče odpreti za pisanje",
"filter_type": "Napačna vrsta filtra",
- "from_invalid": "Pošiljatelj ne sme biti prazno",
+ "from_invalid": "Polje za pošiljatelja ne sme biti prazno",
"global_filter_write_error": "Ni mogoče zapisati datoteke filtra: %s",
"global_map_invalid": "ID globalne preslikave %s ni veljaven",
- "goto_empty": "Alias naslov mora vsebovati vsaj en veljaven goto naslov",
- "goto_invalid": "Goto naslov %s ni veljaven",
+ "goto_empty": "Naslov vzdevka mora vsebovati vsaj en veljaven ciljni naslov",
+ "goto_invalid": "Ciljni naslov %s ni veljaven",
"ham_learn_error": "Napaka pri učenju Ham: %s",
- "imagick_exception": "Napaka: Imagick napaka pri branju slike",
+ "imagick_exception": "Napaka: Izjema Imagick med branjem slike",
"img_invalid": "Ni možno preveriti slikovne datoteke",
"invalid_bcc_map_type": "Neveljavna vrsta preslikave BCC",
"invalid_destination": "Ciljna oblika \"%s\" ni veljavna",
"invalid_filter_type": "Neveljavna vrsta filtra",
"invalid_host": "Naveden je neveljaven gostitelj (host): %s",
- "invalid_mime_type": "Neveljaven mime type",
+ "invalid_mime_type": "Neveljavna vrsta MIME",
"max_quota_in_use": "Kvota poštnega predala mora biti večja ali enaka %d MB",
"password_complexity": "Geslo ne ustreza varnostni politiki",
- "pushover_credentials_missing": "Manjka Pushover token ali ključ",
+ "pushover_credentials_missing": "Manjka žeton in/ali ključ Pushover",
"release_send_failed": "Sporočila ni bilo mogoče sprostiti: %s",
- "tls_policy_map_dest_invalid": "Cilj politike ni veljaven",
+ "tls_policy_map_dest_invalid": "Cilj pravilnika je neveljaven",
"webauthn_authenticator_failed": "Izbrani avtentikator ni bil najden",
"reset_f2b_regex": "Regex filter ni bilo možno ponastaviti v ustreznem času. Prosim poskusite ponovno ali počakajte nekaj sekund in ponovno naložite stran.",
"target_domain_invalid": "Ciljna domena %s ni veljavna",
- "validity_missing": "Prosim nastavite obdobje veljavnosti",
+ "validity_missing": "Prosim določite obdobje veljavnosti",
"invalid_recipient_map_old": "Naveden neveljaven izvirni prejemnik: %s",
- "ip_list_empty": "Seznam dovoljenih IPjev ne sme biti prazen",
- "is_alias": "%s je že znan kot alias naslov",
- "is_alias_or_mailbox": "%s je že znan kot alias, poštni naslov, ali alias izveden iz alias domene",
- "is_spam_alias": "%s že obstaja kot začasen alias (spam alias naslov)",
- "last_key": "Zadnji ključ ne more biti izbrisan, prosim raje deaktivirajte dvofaktorsko avtentikacijo (TFA)",
+ "ip_list_empty": "Seznam dovoljenih IP-jev ne sme biti prazen",
+ "is_alias": "%s je že znan kot naslov vzdevka",
+ "is_alias_or_mailbox": "%s je že znan kot vzdevek, poštni predal ali naslov vzdevka, razširjen iz vzdevka domene.",
+ "is_spam_alias": "%s je že znan kot začasni vzdevek (neželeni vzdevek)",
+ "last_key": "Zadnji ključ ne more biti izbrisan, prosim raje deaktivirajte dvofaktorsko avtentikacijo (TFA).",
"login_failed": "Prijava ni uspela",
"mailbox_defquota_exceeds_mailbox_maxquota": "Privzeta kvota presega najvišjo omejitev",
"mailbox_invalid": "Ime poštnega predala ni veljavno",
- "mailbox_quota_exceeded": "Kvota presega omejitev domene (maksimalno %d MB)",
+ "mailbox_quota_exceeded": "Kvota presega omejitev domene (največ %d MB)",
"mailbox_quota_exceeds_domain_quota": "Najvišja kvota presega omejitev domene",
"mailbox_quota_left_exceeded": "Ni dovolj prostora (preostali prostor: %d MB)",
"mailboxes_in_use": "Največje število poštnih predalov mora biti večje ali enako %d",
"malformed_username": "Nepravilno oblikovano uporabniško ime",
"map_content_empty": "Preslikava vsebine ne more biti prazna",
- "max_alias_exceeded": "Preseženo največje število aliasov",
+ "max_alias_exceeded": "Preseženo največje število vzdevkov",
"max_mailbox_exceeded": "Preseženo največje število poštnih predalov (%d od %d)",
- "maxquota_empty": "Največja kvota na poštni predal ne more biti 0",
+ "maxquota_empty": "Največja kvota na poštni predal ne more biti 0.",
"mysql_error": "Napaka MySQL: %s",
- "network_host_invalid": "Nepravilno omrežje ali gostitel: %s",
+ "network_host_invalid": "Nepravilno omrežje ali gostitelj: %s",
"next_hop_interferes": "% moti naslednji skok %s",
"next_hop_interferes_any": "Obstoječi naslednji skok moti %s",
"nginx_reload_failed": "Ponovni zagon Nginx ni uspel: %s",
@@ -438,30 +509,30 @@
"policy_list_from_invalid": "Zapis ima nepravilno obliko",
"private_key_error": "Napaka zasebnega ključa: %s",
"pushover_key": "Pushover ključ ni v pravilni obliki",
- "pushover_token": "Pushover token ni v pravilni obliki",
- "quota_not_0_not_numeric": "Quota mora biti število in večje ali enako 0",
+ "pushover_token": "Pushover žeton ni v pravilni obliki",
+ "quota_not_0_not_numeric": "Kvota mora biti numerična in >= 0",
"recipient_map_entry_exists": "Preslikava prejemnika \"%s\" že obstaja",
"redis_error": "Napaka Redis: %s",
"relayhost_invalid": "Vnos preslikave %s ni pravilen",
- "resource_invalid": "Ime vira je neveljavno",
- "rl_timeframe": "Časovni okvir za rate limit je nepravilen",
+ "resource_invalid": "Ime vira %s je neveljavno",
+ "rl_timeframe": "Časovni okvir omejitve je nepravilen",
"rspamd_ui_pw_length": "Rspamd UI geslo mora biti dolgo vsaj 6 znakov",
- "script_empty": "Script ne more biti prazen",
+ "script_empty": "Skripta ne sme biti prazna",
"sender_acl_invalid": "Vrednost ACL pošiljatelja %s ni veljavna",
"set_acl_failed": "Ni uspelo nastaviti ACL",
"settings_map_invalid": "ID preslikave nastavitev %s ni veljaven",
- "sieve_error": "Napaka Sieve parserja: %s",
- "spam_learn_error": "Napaka pri učenju spama: %s",
- "subject_empty": "Predmet ne sme biti prazno",
+ "sieve_error": "Napaka Sieve razčlenjevalnika: %s",
+ "spam_learn_error": "Napaka pri učenju neželene pošte: %s",
+ "subject_empty": "Zadeva ne sme biti prazna",
"targetd_not_found": "Ciljna domena %s ni bila najdena",
- "targetd_relay_domain": "Ciljna domena %s je relay domena",
+ "targetd_relay_domain": "Ciljna domena %s je posredovalna domena",
"template_exists": "Predloga %s že obstaja",
"template_id_invalid": "ID predloge %s ni veljaven",
"template_name_invalid": "Ime predloge ni veljavno",
"text_empty": "Besedilo ne sme biti prazno",
- "tfa_token_invalid": "Neveljaven token TFA",
- "tls_policy_map_entry_exists": "Vpis preslikave TLS \"%s\" že obstaja",
- "tls_policy_map_parameter_invalid": "Parameter politike ni pravilen",
+ "tfa_token_invalid": "Neveljaven TFA žeton",
+ "tls_policy_map_entry_exists": "Vnos pravilnika preslikave TLS \"%s\" obstaja",
+ "tls_policy_map_parameter_invalid": "Parameter pravilnika je neveljaven",
"totp_verification_failed": "Neuspešno preverjanje TOTP",
"transport_dest_exists": "Cilj transporta \"%s\" že obstaja",
"webauthn_verification_failed": "Preverjanje WebAuthn ni uspelo: %s",
@@ -476,10 +547,30 @@
"temp_error": "Začasna napaka",
"cors_invalid_method": "Navedena neveljavna Allow metoda",
"cors_invalid_origin": "Naveden neveljaven Allow-Origin",
- "invalid_recipient_map_new": "Naveden neveljaven nov prejemnik: %s"
+ "invalid_recipient_map_new": "Naveden neveljaven nov prejemnik: %s",
+ "img_dimensions_exceeded": "Slika presega največje dovoljene dimenzije",
+ "img_size_exceeded": "Slika presega največjo dovoljeno velikost datoteke",
+ "iam_test_connection": "Povezava ni uspela",
+ "authsource_in_use": "Ponudnika identitete ni mogoče spremeniti ali izbrisati, ker ga trenutno uporablja eden ali več uporabnikov.",
+ "password_reset_na": "Obnovitev gesla trenutno ni na voljo. Obrnite se na skrbnika.",
+ "generic_server_error": "Prišlo je do nepričakovane napake strežnika. Obrnite se na skrbnika.",
+ "invalid_reset_token": "Neveljaven žeton za ponastavitev",
+ "password_reset_invalid_user": "Poštni predal ni bil najden ali pa ni nastavljen e-poštni naslov za obnovitev",
+ "recovery_email_failed": "E-poštnega sporočila za obnovitev ni bilo mogoče poslati. Obrnite se na skrbnika.",
+ "required_data_missing": "Manjkajo zahtevani podatki %s",
+ "reset_token_limit_exceeded": "Omejitev žetonov za ponastavitev je bila presežena. Poskusite znova pozneje.",
+ "to_invalid": "Polje za prejemnika ne sme biti prazno",
+ "max_age_invalid": "Najvišja starost %s je neveljavna",
+ "mode_invalid": "Način %s ni veljaven",
+ "mx_invalid": "Zapis MX %s je neveljaven",
+ "version_invalid": "Različica %s je neveljavna",
+ "tfa_removal_blocked": "Dvofaktorske avtentikacije ni mogoče odstraniti, ker je obvezna za vaš račun.",
+ "quarantine_category_invalid": "Kategorija karantene mora biti ena od: add_header, reject, all",
+ "external_goto_denied": "Zunanji naslov goto %s ni dovoljen",
+ "ui_theme_invalid": "Tema ni najdena"
},
"debug": {
- "containers_info": "Informacije o vsebniku (containerju)",
+ "containers_info": "Informacije o zabojniku",
"architecture": "Arhitektura",
"chart_this_server": "Diagram (ta strežnik)",
"container_running": "Aktiven",
@@ -493,31 +584,34 @@
"external_logs": "Zunanji dnevniki",
"last_modified": "Nazadnje spremenjeno",
"history_all_servers": "Zgodovina (vsi strežniki)",
- "in_memory_logs": "In-memory dnevniki",
- "jvm_memory_solr": "JVM zasedenost spomina",
- "service": "Servis",
+ "in_memory_logs": "Dnevniki v pomnilniku",
+ "service": "Storitev",
"show_ip": "Prikaži javni IP",
"size": "Velikost",
- "solr_dead": "Solr se zaganja, je onemogočen ali se je ustavil.",
- "solr_status": "Status Solr",
"started_at": "Zagnano ob",
"started_on": "Zagnano na",
"static_logs": "Statični dnevniki",
"success": "Uspešno",
- "system_containers": "Sistem in Containerji",
+ "system_containers": "Sistem in zabojniki",
"timezone": "Časovni pas",
"uptime": "Čas delovanja",
"update_available": "Posodobitev je na voljo",
"no_update_available": "Sistem je na najnovejši verziji",
"update_failed": "Ni mogoče preveriti za posodobitve",
"username": "Uporabniško ime",
- "wip": "Trenutno v delu"
+ "wip": "Trenutno delo v teku",
+ "log_info": "<p>Dnevniki v pomnilniku mailcow se zbirajo na seznamih Redis in vsako minuto skrajšajo na LOG_LINES (%d), da se zmanjša preobremenitev.\n <br>Dnevniki v pomnilniku niso namenjeni trajnemu beleženju. Vse aplikacije, ki se beležijo v pomnilnik, se beležijo tudi v Dockerjev demon in s tem v privzeti gonilnik beleženja.</p>\n </p>Vrsta dnevnika v pomnilniku se mora uporabljati za odpravljanje manjših težav s kontejnerji.</p>\n <p><b>Zunanji dnevniki</b> se zbirajo prek API-ja dane aplikacije.</p>\n <p><b>Statični dnevniki</b> so večinoma dnevniki dejavnosti, ki se ne beležijo v Dockerd, vendar morajo biti še vedno trajni (razen dnevnikov API-ja).</p>",
+ "login_time": "Čas",
+ "logs": "Dnevniki",
+ "memory": "Spomin",
+ "online_users": "Prijavljeni uporabniki",
+ "restart_container": "Ponovno zaženi"
},
"datatables": {
"infoFiltered": "(filtrirano od _MAX_ skupaj zapisov)",
"collapse_all": "Strni vse",
"decimal": ",",
- "emptyTable": "Ni podatkov",
+ "emptyTable": "V tabeli ni na voljo podatkov",
"expand_all": "Razširi vse",
"info": "Prikazano _START_ do _END_ od _TOTAL_ zapisov",
"infoEmpty": "Prikazano 0 do 0 od 0 zapisov",
@@ -539,9 +633,9 @@
}
},
"diagnostics": {
- "cname_from_a": "Vrednost pridobljena iz A/AAAA zapisa. To je podprto, če zapis kaže na pravilen resurs.",
+ "cname_from_a": "Vrednost, izpeljana iz zapisa A/AAAA. To je podprto, če zapis kaže na pravilen vir.",
"dns_records": "DNS zapisi",
- "dns_records_24hours": "Prosim upoštevajte, da lahko traja do 24 ur da se spremembe v DNS pravilno prikažejo na tej strani. Namen je da lahko enostavno vidite, kako konfigurirati svoje DNS zapise in preverite ali so vaši zapisi pravilno shranjeni v DNS.",
+ "dns_records_24hours": "Upoštevajte, da se lahko spremembe DNS-a pravilno odražajo na tej strani v 24 urah. Namenjena je temu, da si preprosto ogledate, kako konfigurirati zapise DNS, in preverite, ali so vsi vaši zapisi pravilno shranjeni v DNS-u.",
"dns_records_data": "Pravilni podatki",
"dns_records_docs": "Prosim preverite tudi <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">dokumentacijo</a>.",
"dns_records_name": "Ime",
@@ -551,6 +645,806 @@
},
"edit": {
"acl": "ACL (Dovoljenje)",
- "active": "Aktivno"
+ "active": "Aktivno",
+ "allow_from_smtp": "Dovoli samo tem IP naslovom uporabo <b>SMTP</b>",
+ "bcc_dest_format": "Ciljna stran za polje SKP (BCC) mora biti en veljaven e-poštni naslov.<br>Če morate kopijo poslati na več naslovov, ustvarite vzdevek in ga uporabite tukaj.",
+ "automap": "Poskusite samodejno preslikati mape (\"Poslani predmeti\", \"Poslano\" => \"Poslano\" itd.)",
+ "admin": "Uredi skrbnika",
+ "domain_footer_info_vars": {
+ "custom": "{= foo =} - Če ima poštni predal atribut po meri \"foo\" z vrednostjo \"bar\", vrne \"bar\"",
+ "auth_user": "{= auth_user =} - Preverjeno uporabniško ime, ki ga določi MTA",
+ "from_user": "{= from_user =} - Iz uporabniškega dela ovojnice, npr. za \"moo@mailcow.tld\" vrne \"moo\"",
+ "from_name": "{= from_name =} - Iz imena ovojnice, npr. za \"Mailcow <moo@mailcow.tld>\" vrne \"Mailcow\"",
+ "from_addr": "{= from_addr =} - Del ovojnice z naslovom od",
+ "from_domain": "{= from_domain =} - Iz domenskega dela ovojnice"
+ },
+ "dont_check_sender_acl": "Onemogoči preverjanje pošiljatelja za domeno %s (+ vzdevki domen)",
+ "pushover_title": "Naslov obvestila",
+ "domains": "Domene",
+ "extended_sender_acl_info": "Uvoziti je treba ključ domene DKIM, če je na voljo.<br>\n Ne pozabite dodati tega strežnika v ustrezni zapis SPF TXT.<br>\n Kadar koli je temu strežniku dodana domena ali vzdevek domene, ki se prekriva z zunanjim naslovom, se zunanji naslov odstrani.<br>\n Uporabite @domain.tld, da omogočite pošiljanje kot *@domain.tld.",
+ "lookup_mx": "Cilj je regularni izraz, ki se ujema z imenom MX (<code>.*\\.google\\.com</code> za usmerjanje vse pošte, usmerjene na MX, ki se konča na google.com, prek tega skoka)",
+ "maxbytespersecond": "Največ bajtov na sekundo <br><small>(0 = neomejeno)</small>",
+ "pushover_sender_array": "Upoštevaj samo sledeče e-poštne naslove pošiljateljev <small>(ločeni z vejico)</small>",
+ "mbox_rl_info": "Ta omejitev se uporabi za prijavno ime SASL in se ujema z naslovom \"od\", ki ga uporablja prijavljeni uporabnik. Omejitev poštnega nabiralnika preglasi omejitev za celotno domeno.",
+ "kind": "Tip",
+ "client_secret": "Skrivnost odjemalca",
+ "comment_info": "Zasebni komentar ni viden uporabniku, javni komentar pa se prikaže kot opis orodja, ko nanj v pregledu uporabnika zadržite miško",
+ "created_on": "Ustvarjeno",
+ "custom_attributes": "Atributi po meri",
+ "delete1": "Izbriši iz vira, ko je končano",
+ "delete2": "Izbriši sporočila na cilju, ki niso na izvoru",
+ "delete2duplicates": "Izbriši dvojnike na cilju",
+ "delete_ays": "Prosim potrdite proces izbrisa.",
+ "description": "Opis",
+ "disable_login": "Onemogoči prijavo (dohodna pošta je še vedno sprejeta)",
+ "domain": "Uredi domeno",
+ "domain_admin": "Uredi skrbnika domene",
+ "domain_footer": "Noga za celo domeno",
+ "domain_footer_html": "HTML noga",
+ "pushover_vars": "Če filter pošiljatelja ni definiran, bodo upoštevana vsa e-poštna sporočila.<br>Filtre regularnih izrazov in natančna preverjanja pošiljateljev je mogoče definirati posamično in bodo obravnavana zaporedno. Niso odvisna drug od drugega.<br>Uporabne spremenljivke za besedilo in naslov (upoštevajte pravilnike o varstvu podatkov)",
+ "pushover_verify": "Preveri poverilnice",
+ "quota_mb": "Omejitev (MiB)",
+ "quota_warning_bcc": "Opozorilo o kvoti BCC",
+ "quota_warning_bcc_info": "Opozorila bodo poslana kot ločene kopije naslednjim prejemnikom. Zadevi bo v oklepaju dodano ustrezno uporabniško ime, na primer: <code>Opozorilo o kvoti (uporabnik@example.com)</code>.",
+ "ratelimit": "Omejitev pošiljanja",
+ "advanced_settings": "Napredne nastavitve",
+ "allow_from_smtp_info": "Pustite prazno, da dovolite vse pošiljatelje.<br>Naslovi in omrežja IPv4/IPv6.",
+ "allowed_protocols": "Dovoljeni protokoli za neposreden dostop uporabnikov (ne vpliva na protokole za gesla aplikacij)",
+ "app_name": "Ime aplikacije",
+ "app_passwd": "Geslo aplikacije",
+ "app_passwd_protocols": "Dovoljeni protokoli za geslo aplikacije",
+ "backup_mx_options": "Možnosti posredovanja",
+ "client_id": "ID odjemalca",
+ "domain_footer_info": "Noge za celotno domeno so dodane vsem odhodnim e-poštnim sporočilom, povezanim z naslovom znotraj te domene. <br> Za nogo se lahko uporabijo naslednje spremenljivke:",
+ "domain_footer_plain": "NAVADNA noga",
+ "domain_footer_skip_replies": "Prezri nogo v odgovorih na e-poštna sporočila",
+ "domain_quota": "Kvota domene",
+ "edit_alias_domain": "Uredi vzdevek domene",
+ "exclude": "Izključi objekte (regex)",
+ "extended_sender_acl": "Naslovi zunanjih pošiljateljev",
+ "force_pw_update": "Obvezna zamenjava gesla ob naslednji prijavi",
+ "force_pw_update_info": "Ta uporabnik se bo lahko prijavil samo v %s. Gesla aplikacij ostajajo v rabi.",
+ "footer_exclude": "Izključi iz noge",
+ "full_name": "Polno ime",
+ "gal": "Globalni seznam naslovov (GAL)",
+ "gal_info": "GAL vsebuje vse objekte v domeni in jih uporabniki ne morejo urejati. Če je onemogočeno, ni podatkov o o zasedenosti objekta! <b>Ponovno zaženite SOGo za uveljavitev sprememb.</b>",
+ "generate": "ustvari",
+ "grant_types": "Vrste dovoljenj",
+ "hostname": "Ime gostitelja",
+ "inactive": "Neaktivno",
+ "last_modified": "Nazadnje spremenjeno",
+ "mailbox": "Uredi poštni predal",
+ "mailbox_quota_def": "Privzeta kvota nabiralnika",
+ "mailbox_relayhost_info": "Uporablja se samo za poštni nabiralnik in neposredne vzdevke, preglasi gostitelja posredovalne domene.",
+ "max_aliases": "Največje število vzdevkov",
+ "max_mailboxes": "Največje možno število poštnih predalov",
+ "max_quota": "Največja kvota na poštni predal (MiB)",
+ "maxage": "Najvišja starost sporočil v dnevih, ki bodo prebrana z oddaljenega strežnika<br><small>(0 = prezri starost)</small>",
+ "mins_interval": "Interval (min)",
+ "multiple_bookings": "Več rezervacij",
+ "none_inherit": "Brez / podeduj",
+ "nexthop": "Naslednji skok",
+ "password": "Geslo",
+ "password_repeat": "Potrditev gesla (ponovite)",
+ "previous": "Prejšnja stran",
+ "private_comment": "Zasebni komentar",
+ "public_comment": "Javni komentar",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Eskaliraj visoko prednostno pošto [<code>X-Priority: 1</code>]",
+ "pushover_info": "Nastavitve potisnih obvestil bodo veljale za vso čisto (ne neželeno) pošto, dostavljeno na <b>%s</b>, vključno z vzdevki (v skupni rabi, brez skupne rabe, označeni).",
+ "pushover_only_x_prio": "Upoštevaj samo pošto z visoko prioriteto [<code>X-Priority: 1</code>]",
+ "pushover_sender_regex": "Upoštevaj sledeči regex za pošiljatelja",
+ "pushover_text": "Besedilo obvestila",
+ "pushover_sound": "Zvok",
+ "encryption": "Šifriranje",
+ "alias": "Uredi vzdevek",
+ "relayhost": "Prenosi, odvisni od pošiljatelja",
+ "mailbox_rename_alias": "Samodejno ustvari vzdevek",
+ "sender_acl_info": "Če lahko uporabnik poštnega predala A pošilja kot uporabnik poštnega predala B, se naslov pošiljatelja v SOGo ne prikaže samodejno kot izbirno polje \"od\".<br>\n Uporabnik poštnega predala B mora v SOGo ustvariti pooblastilo, da lahko uporabnik poštnega predala A izbere svoj naslov kot pošiljatelja. Če želite pooblastiti poštni predal v SOGo, uporabite meni (tri pike) desno od imena vašega poštnega predala v zgornjem levem kotu v pogledu pošte. To vedenje ne velja za vzdevke.",
+ "redirect_uri": "URL za preusmeritev/povratni klic",
+ "relay_all": "Posreduj vsem prejemnikom",
+ "relay_unknown_only": "Posreduj samo neobstoječe poštne nabiralnike. Obstoječi poštni nabiralniki bodo dostavljeni lokalno.",
+ "relay_domain": "Posreduj to domeno",
+ "remove": "Odstrani",
+ "resource": "Vir",
+ "mailbox_rename_title": "Novo ime lokalnega poštnega predala",
+ "password_recovery_email": "E-poštno sporočilo za obnovitev gesla",
+ "relay_all_info": "↪ Če se odločite, da <b>ne</b> želite posredovati vseh prejemnikov, boste morali za vsakega posameznega prejemnika, ki ga želite posredovati, dodati (\"slepi\") poštni predal.",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Informacije</div> Za to domeno lahko določite transportne zemljevide za cilj po meri. Če niso nastavljeni, bo izvedeno iskanje MX.",
+ "save": "Shrani spremembe",
+ "scope": "Obseg",
+ "sender_acl": "Dovoli pošiljanje kot",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Preverjanje pošiljatelja je onemogočeno</span>",
+ "sieve_type": "Vrsta filtra",
+ "skipcrossduplicates": "Preskoči podvojena sporočila med mapami (po principu \"kdor prej pride, prej melje\")",
+ "sogo_access": "Neposredno posredovanje na SOGo",
+ "sogo_access_info": "Po prijavi je uporabnik samodejno preusmerjen na SOGo.",
+ "sogo_visible": "Vzdevek je viden v SOGo",
+ "sogo_visible_info": "Ta možnost vpliva samo na objekte, ki jih je mogoče prikazati v SOGo (naslovi vzdevkov v skupni rabi ali brez nje, ki kažejo na vsaj en lokalni poštni predal). Če je skrita, vzdevek ne bo prikazan kot izbirni pošiljatelj v SOGo.",
+ "spam_alias": "Ustvarjanje ali spreminjanje časovno omejenih vzdevkovnih naslovov",
+ "spam_filter": "Filter neželene pošte",
+ "spam_policy": "Dodajanje ali odstranjevanje elementov na seznam dovoljenih/zavrnjenih",
+ "spam_score": "Nastavite oceno neželene pošte po meri",
+ "subfolder2": "Sinhroniziraj v podmapo na cilju<br><small>(prazno = ne uporabi podmape)</small>",
+ "syncjob": "Urejanje sinhronizacijskega opravila",
+ "target_address": "Pojdi na naslov/e <small>(ločeno z vejico)</small>",
+ "target_domain": "Ciljna domena",
+ "timeout1": "Časovna omejitev za povezavo z oddaljenim gostiteljem",
+ "timeout2": "Časovna omejitev za povezavo z lokalnim gostiteljem",
+ "title": "Urejanje predmeta",
+ "unchanged_if_empty": "Če ni spremenjeno, pustite prazno",
+ "username": "Uporabniško ime",
+ "validate_save": "Potrdi in shrani",
+ "mailbox_rename": "Preimenuj poštni predal",
+ "mailbox_rename_agree": "Ustvaril/a sem varnostno kopijo.",
+ "mailbox_rename_warning": "POMEMBNO! Pred preimenovanjem nabiralnika ustvarite varnostno kopijo.",
+ "sieve_desc": "Kratek opis",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> je standard, ki vsiljuje dostavo e-pošte med poštnimi strežniki z uporabo TLS z veljavnimi potrdili. <br>Uporablja se, kadar <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> ni mogoč zaradi manjkajočega ali nepodprtega DNSSEC.<br><b>Opomba</b>: Če prejemna domena podpira DANE z DNSSEC, je DANE <b>vedno</b> prednost – MTA-STS deluje le kot rezervna možnost.",
+ "mta_sts_version": "Različica",
+ "mta_sts_version_info": "Določa različico standarda MTA-STS – trenutno je veljavna samo različica <code>STSv1</code>.",
+ "mta_sts_mode": "Način",
+ "mta_sts_mode_info": "Na voljo so trije načini:<ul><li><em>testiranje</em> – pravilnik se samo spremlja, kršitve nimajo vpliva.</li><li><em>uveljavljanje</em> – pravilnik se strogo uveljavlja, povezave brez veljavnega TLS so zavrnjene.</li><li><em>brez</em> – pravilnik je objavljen, vendar se ne uporablja.</li></ul>",
+ "mta_sts_max_age": "Najvišja starost",
+ "mta_sts_max_age_info": "Čas v sekundah, ki ga lahko prejemni poštni strežniki shranijo v predpomnilnik, dokler se ne naloži ponovno.",
+ "mta_sts_mx": "MX strežnik",
+ "mta_sts_mx_info": "Omogoča pošiljanje samo na izrecno navedena imena gostiteljskih strežnikov poštnih strežnikov; pošiljajoči MTA preveri, ali se ime gostitelja DNS MX ujema s seznamom pravilnikov, in dovoljuje dostavo le z veljavnim potrdilom TLS (zaščita pred MITM).",
+ "mta_sts_mx_notice": "Določiti je mogoče več strežnikov MX (ločenih z vejicami).",
+ "internal": "Notranje",
+ "internal_info": "Notranji vzdevki so dostopni samo iz lastne domene ali vzdevkov domen.",
+ "sender_allowed": "Dovoli pošiljanje kot ta vzdevek",
+ "sender_allowed_info": "Če je onemogočeno, lahko ta vzdevek samo prejema pošto. Za preglasitev in dodelitev dovoljenja za pošiljanje določenim poštnim predalom uporabite seznam za nadzor dostopa pošiljatelja.",
+ "mta_sts_active_info": "Če ni označeno, pravilnik MTA-STS ne bo objavljen in za poddomeno mta-sts ne bo zahtevano nobeno potrdilo prek ACME."
+ },
+ "footer": {
+ "restart_container_info": "<b>Pomembno:</b> Eleganten ponovni zagon lahko traja nekaj časa, zato počakajte, da se konča.",
+ "delete_these_items": "Prosimo, potrdite spremembe naslednjega ID-ja objekta",
+ "confirm_delete": "Potrdi brisanje",
+ "delete_now": "Izbriši zdaj",
+ "hibp_check": "Preverite na haveibeenpwned.com",
+ "hibp_nok": "Ujema se! To je potencialno nevarno geslo!",
+ "hibp_ok": "Ni najdenega ujemanja.",
+ "loading": "Prosim, počakajte...",
+ "nothing_selected": "Nič izbranega",
+ "restart_container": "Znova zaženite zabojnik",
+ "restart_now": "Znova zaženi zdaj",
+ "restarting_container": "Ponovni zagon zabojnika, to lahko traja nekaj časa",
+ "cancel": "Prekliči"
+ },
+ "login": {
+ "password": "Geslo",
+ "invalid_pass_reset_token": "Žeton za ponastavitev gesla je neveljaven ali je potekel.<br>Zahtevajte novo povezavo za ponastavitev gesla.",
+ "back_to_mailcow": "Nazaj v mailcow",
+ "delayed": "Prijava je bila zakasnjena za %s sekund.",
+ "fido2_webauthn": "Prijava FIDO2/WebAuthent",
+ "forgot_password": "> Ste pozabili geslo?",
+ "login": "Prijava",
+ "login_linkstext": "Ni pravilna prijava?",
+ "login_usertext": "Prijava kot uporabnik",
+ "login_domainadmintext": "Prijava kot skrbnik domene",
+ "login_admintext": "Prijava kot skrbnik",
+ "login_user": "Prijava uporabnika",
+ "login_dadmin": "Prijava skrbnika domene",
+ "login_admin": "Prijava skrbnika",
+ "mobileconfig_info": "Za prenos zahtevanega profila povezave Apple se prijavite kot uporabnik poštnega predala.",
+ "new_password": "Novo geslo",
+ "new_password_confirm": "Potrdi novo geslo",
+ "other_logins": "ali se prijavite s/z",
+ "reset_password": "Ponastavi geslo",
+ "request_reset_password": "Zahteva za spremembo gesla",
+ "username": "Uporabniško ime",
+ "email": "E-poštni naslov"
+ },
+ "mailbox": {
+ "last_mail_login": "Zadnja prijava v e-pošto",
+ "deactivate": "Deaktiviraj",
+ "domain_admins": "Skrbniki domen",
+ "kind": "Prijazno",
+ "mailbox_defaults_info": "Določite privzete nastavitve za nove poštne nabiralnike.",
+ "allowed_protocols": "Dovoljeni protokoli",
+ "add_alias": "Dodaj vzdevek",
+ "mins_interval": "Interval (min)",
+ "recipient_map_info": "Zemljevidi prejemnikov se uporabljajo za zamenjavo naslova prejemnika v sporočilu, preden je dostavljeno.",
+ "add_domain_record_first": "Najprej dodajte domeno",
+ "booking_ltnull": "Neomejeno, vendar se ob rezervaciji prikaži kot zasedeno",
+ "alias_domain_alias_hint": "Vzdevki se na vzdevke domen samodejno <b>ne</b> uporabijo. Naslov vzdevka <code>my-alias@domain</code> <b>ne</b> pokriva naslova <code>my-alias@alias-domain</code> (kjer je \"vzdevek domene\" namišljeni vzdevek domene za \"domeno\").<br>Za preusmeritev pošte v zunanji nabiralnik uporabite filter sito (glejte zavihek »Filtri« ali uporabite SOGo -> Posrednik). Za samodejno dodajanje manjkajočih vzdevkov uporabite \"Razširi vzdevek čez domene vzdevkov\".",
+ "q_all": " ob premiku v mapo Neželena pošta in ob zavrnitvi",
+ "bcc_info": "BCC zemljevidi se uporabljajo za tiho posredovanje kopij vseh sporočil na drug naslov. Vnos vrste preslikave prejemnika se uporablja, kadar lokalni cilj deluje kot prejemnik pošte. Preslikave pošiljatelja delujejo po istem načelu.<br>\n Lokalni cilj ne bo obveščen o neuspeli dostavi.",
+ "force_pw_update": "Vsiljena posodobitev gesla ob naslednji prijavi",
+ "recipient_map_new_info": "Cilj zemljevida prejemnika mora biti veljaven e-poštni naslov ali ime domene.",
+ "recipient_map_old_info": "Izvirni cilj prejemnika mora biti veljaven e-poštni naslov ali ime domene.",
+ "action": "Dejanje",
+ "activate": "Aktiviraj",
+ "active": "Aktivno",
+ "add": "Dodaj",
+ "add_alias_expand": "Razširi vzdevek nad vzdevki domen",
+ "add_bcc_entry": "Dodaj zemljevid BCC",
+ "add_domain": "Dodaj domeno",
+ "add_domain_alias": "Dodaj vzdevek domene",
+ "add_filter": "Dodaj filter",
+ "add_mailbox": "Dodaj poštni predal",
+ "add_recipient_map_entry": "Dodaj zemljevid prejemnikov",
+ "add_resource": "Dodaj vir",
+ "add_template": "Dodaj predlogo",
+ "add_tls_policy_map": "Dodaj zemljevid pravilnikov TLS",
+ "address_rewriting": "Prepisovanje naslovov",
+ "alias": "Vzdevek",
+ "alias_domain_backupmx": "Vzdevek domene ni aktiven za posredovalno domeno",
+ "aliases": "Vzdevki",
+ "all_domains": "Vse domene",
+ "allow_from_smtp": "Dovoli samo tem IP-jem uporabo <b>SMTP</b>",
+ "allow_from_smtp_info": "Pustite prazno, da dovolite vse pošiljatelje.<br>Naslovi in omrežja IPv4/IPv6.",
+ "backup_mx": "Posredovalna domena",
+ "bcc": "BCC",
+ "bcc_destination": "Ciljna stran BCC",
+ "bcc_destinations": "Ciljna stran BCC",
+ "bcc_local_dest": "Lokalni cilj",
+ "bcc_map": "BCC zemljevid",
+ "bcc_map_type": "BCC tip",
+ "bcc_maps": "BCC zemljevidi",
+ "bcc_rcpt_map": "Zemljevid prejemnikov",
+ "bcc_sender_map": "Zemljevid pošiljatelja",
+ "bcc_to_rcpt": "Preklopi na vrsto zemljevida prejemnika",
+ "bcc_to_sender": "Preklopi na vrsto zemljevida pošiljatelja",
+ "bcc_type": "BCC tip",
+ "booking_null": "Vedno prikaži kot brezplačno",
+ "booking_0_short": "Vedno prost",
+ "booking_custom": "Točna omejitev na število rezervacij po meri",
+ "booking_custom_short": "Trda omejitev",
+ "booking_lt0_short": "Mehka omejitev",
+ "catch_all": "Zajemi vse",
+ "created_on": "Ustvarjeno dne",
+ "daily": "Dnevno",
+ "description": "Opis",
+ "disable_login": "Prepreči prijavo (dohodna pošta je še vedno sprejeta)",
+ "disable_x": "Onemogoči",
+ "dkim_domains_selector": "Izbirnik",
+ "dkim_key_length": "Dolžina ključa DKIM (biti)",
+ "domain": "Domena",
+ "domain_aliases": "Vzdevki domen",
+ "domain_templates": "Predloge domen",
+ "domain_quota": "Kvota",
+ "domain_quota_total": "Celotna kvota domene",
+ "domains": "Domene",
+ "edit": "Uredi",
+ "empty": "Ni rezultatov",
+ "enable_x": "Omogoči",
+ "filters": "Filtri",
+ "fname": "Polno ime",
+ "gal": "Globalni seznam naslovov",
+ "goto_ham": "Uči se kot <b>ham</b>",
+ "goto_spam": "Uči se kot <b>spam</b>",
+ "hourly": "Urno",
+ "iam": "Ponudnik identitete",
+ "in_use": "V uporabi (%)",
+ "inactive": "Neaktivno",
+ "insert_preset": "Vstavi primer prednastavitve \"%s\"",
+ "last_modified": "Zadnja sprememba",
+ "last_pw_change": "Zadnja sprememba gesla",
+ "last_run_reset": "Načrtuj naslednje",
+ "mailbox": "Poštni nabiralnik",
+ "mailbox_defaults": "Privzete nastavitve",
+ "mailbox_defquota": "Privzeta velikost poštnega nabiralnika",
+ "mailbox_templates": "Predloge poštnih nabiralnikov",
+ "mailbox_quota": "Največja velikost poštnega nabiralnika",
+ "mailboxes": "Poštni nabiralniki",
+ "max_aliases": "Največje število vzdevkov",
+ "max_mailboxes": "Največje možno število poštnih predalov",
+ "max_quota": "Največja kvota na poštni predal",
+ "msg_num": "Sporočilo #",
+ "multiple_bookings": "Več rezervacij",
+ "never": "Nikoli",
+ "no": "✕",
+ "no_record": "Ni zapisa za objekt %s",
+ "no_record_single": "Ni zapisa",
+ "open_logs": "Odpri dnevnike",
+ "owner": "Lastnik",
+ "private_comment": "Zasebni komentar",
+ "public_comment": "Javni komentar",
+ "q_add_header": "ko je premaknjeno v mapo Neželena pošta",
+ "q_reject": "ob zavrnitvi",
+ "quarantine_category": "Kategorija obvestil o karanteni",
+ "quarantine_notification": "Obvestila o karanteni",
+ "quick_actions": "Dejanja",
+ "recipient": "Prejemnik",
+ "recipient_map": "Zemljevid prejemnikov",
+ "recipient_map_new": "Nov prejemnik",
+ "recipient_map_old": "Prvotni prejemnik",
+ "recipient_maps": "Zemljevidi prejemnikov",
+ "relay_all": "Posreduj vsem prejemnikom",
+ "relay_unknown": "Posredovanje neznanih poštnih predalov",
+ "remove": "Odstrani",
+ "resources": "Viri",
+ "running": "V teku",
+ "sender": "Pošiljatelj",
+ "set_postfilter": "Označi kot postfilter",
+ "set_prefilter": "Označi kot predfilter",
+ "sieve_preset_1": "Zavrzi pošto z verjetno nevarnimi vrstami datotek",
+ "filter_table": "Filtriraj tabelo",
+ "excludes": "Izključuje",
+ "last_run": "Zadnji zagon",
+ "sieve_preset_2": "Vedno označi e-pošto določenega pošiljatelja kot videno",
+ "target_address": "Pojdi na naslov",
+ "syncjob_EXIT_TLS_FAILURE": "Težava s šifrirano povezavo",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Ni mogoče vzpostaviti povezave z oddaljenim strežnikom",
+ "tls_map_parameters_info": "Prazno ali parametri, na primer: protocols=!SSLv2 ciphers=medium exclude=3DES",
+ "tls_policy_maps_enforced_tls": "Ti pravilniki bodo preglasili tudi vedenje uporabnikov poštnih predalov, ki vsiljujejo odhodne povezave TLS. Če spodaj ni pravilnika, bodo ti uporabniki uporabili privzete vrednosti, določene kot <code>smtp_tls_mandatory_protocols</code> in <code>smtp_tls_mandatory_ciphers</code>.",
+ "spam_aliases": "Začasni vzdevek",
+ "sieve_preset_3": "Tiho zavrzite, ustavite vso nadaljnjo obdelavo s presejanjem",
+ "sieve_preset_4": "Vloži v mapo PREJETO, preskoči nadaljnjo obdelavo s sitastimi filtri",
+ "sieve_preset_5": "Samodejni odzivnik (dopust)",
+ "sieve_preset_6": "Zavrni pošto z odgovorom",
+ "sieve_preset_7": "Preusmeritev in ohrani/opusti",
+ "sieve_preset_8": "Preusmeritev e-pošte od določenega pošiljatelja, označitev kot prebrano in razvrščanje v podmapo",
+ "sieve_preset_header": "Spodaj si oglejte primere prednastavitev. Za več podrobnosti glejte <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipedijo</a>.",
+ "sogo_visible": "Vzdevek je viden v SOGo",
+ "sogo_visible_n": "Skrij vzdevek v SOGo",
+ "sogo_visible_y": "Prikaži vzdevek v SOGo",
+ "stats": "Statistika",
+ "status": "Stanje",
+ "sync_jobs": "Sinhronizacija opravil",
+ "syncjob_check_log": "Preveri dnevnik",
+ "syncjob_last_run_result": "Rezultat zadnjega zagona",
+ "syncjob_EX_OK": "Uspešno",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Težava s povezavo",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Težava z overjanjem",
+ "syncjob_EXIT_OVERQUOTA": "Ciljni poštni predal presega kvoto",
+ "table_size_show_n": "Prikaži %s elementov",
+ "target_domain": "Ciljna domena",
+ "template": "Predloga",
+ "tls_enforce_in": "Uveljavi dohodni TLS",
+ "tls_enforce_out": "Uveljavi odhodni TLS",
+ "tls_map_dest": "Cilj",
+ "tls_map_dest_info": "Primeri: example.org, .example.org, [mail.example.org]:25",
+ "tls_map_parameters": "Parametri",
+ "tls_map_policy": "Politika",
+ "tls_policy_maps": "Zemljevidi pravilnikov TLS",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Napačno uporabniško ime ali geslo",
+ "templates": "Predloge",
+ "tls_policy_maps_long": "Preglasitve zemljevidov pravilnikov odhodnega TLS",
+ "table_size": "Velikost tabele",
+ "toggle_all": "Preklopi vse",
+ "username": "Uporabniško ime",
+ "waiting": "Čakanje",
+ "yes": "✓",
+ "weekly": "Tedensko",
+ "sieve_info": "Na uporabnika lahko shranite več filtrov, vendar je lahko hkrati aktiven le en predfilter in en postfilter.<br>\nVsak filter bo obdelan v opisanem vrstnem redu. Niti neuspešen skript niti izdan ukaz »keep;« ne bosta ustavila obdelave nadaljnjih skript. Spremembe globalnih skriptov sita bodo sprožile ponovni zagon Dovecota.<br><br>Globalni predfilter sita • Predfilter • Uporabniški skripti • Postfilter • Globalni postfilter sita",
+ "tls_policy_maps_info": "Ta preslikava pravilnikov preglasi pravila odhodnega prenosa TLS neodvisno od uporabnikovih nastavitev pravilnikov TLS.<br>\n Za več informacij preverite <a href=\"http://www.postfix.org/postconf.5.html#smtp_tls_policy_maps\" target=\"_blank\">dokumentacijo »smtp_tls_policy_maps«</a>.",
+ "internal": "Notranje",
+ "force_tfa": "TFA"
+ },
+ "fido2": {
+ "known_ids": "Znani ID-ji",
+ "set_fido2_touchid": "Registrirajte Touch ID na Apple M1",
+ "confirm": "Potrdi",
+ "fido2_auth": "Prijava s FIDO2",
+ "fido2_success": "Naprava je bila uspešno registrirana",
+ "fido2_validation_failed": "Preverjanje ni uspelo",
+ "fn": "Prijazno ime",
+ "none": "Onemogočeno",
+ "register_status": "Status registracije",
+ "rename": "Preimenuj",
+ "set_fido2": "Registrirajte napravo FIDO2",
+ "set_fn": "Nastavi prijazno ime",
+ "start_fido2_validation": "Začni validacijo FIDO2"
+ },
+ "info": {
+ "session_expires": "Vaša seja bo potekla čez približno 15 sekund",
+ "awaiting_tfa_confirmation": "Čakam na potrditev TFA",
+ "no_action": "Ni veljavnih ukrepov"
+ },
+ "header": {
+ "administration": "Konfiguracija in podrobnosti",
+ "apps": "Aplikacije",
+ "debug": "Informacije",
+ "email": "E-pošta",
+ "mailcow_system": "Sistem",
+ "mailcow_config": "Konfiguracija",
+ "quarantine": "Karantena",
+ "restart_netfilter": "Znova zaženite omrežni filter",
+ "restart_sogo": "Znova zaženite SOGo",
+ "user_settings": "Uporabniške nastavitve"
+ },
+ "quarantine": {
+ "learn_spam_delete": "Uči se kot neželena pošta in izbriši",
+ "medium_danger": "Srednje",
+ "notified": "Obveščen",
+ "low_danger": "Nizko",
+ "qinfo": "Sistem karantene bo zavrnjeno pošto shranil v zbirko podatkov (pošiljatelj ne bo imel vtisa, da je bila pošta dostavljena), prav tako pa bo pošto, ki bo dostavljena kot kopija, shranil v mapo »Neželena pošta« v nabiralniku.\n<br>»Uči kot neželeno pošto in izbriši« bo sporočilo prepoznal kot neželeno pošto prek Bayesovega izreka in izračunal tudi mehke zgoščene vrednosti, da bi v prihodnje zavrnil podobna sporočila.\n<br>Upoštevajte, da je učenje več sporočil lahko – odvisno od vašega sistema – zamudno.<br>Elementi na seznamu zavrnjenih so izključeni iz karantene.",
+ "junk_folder": "Mapa z neželeno pošto",
+ "action": "Dejanje",
+ "atts": "Priloge",
+ "check_hash": "Iskanje zgoščene vrednosti datoteke @ VT",
+ "confirm": "Potrdi",
+ "confirm_delete": "Potrdite brisanje tega elementa.",
+ "danger": "Nevarnost",
+ "deliver_inbox": "Dostavi v mapo »Prejeto«",
+ "disabled_by_config": "Trenutna konfiguracija sistema onemogoča funkcionalnost karantene. Nastavite »število hranjenj na poštni predal« in »največjo velikost« za elemente karantene.",
+ "download_eml": "Prenesi (.eml)",
+ "empty": "Ni rezultatov",
+ "high_danger": "Visoko",
+ "info": "Informacija",
+ "neutral_danger": "Nevtralno",
+ "qhandler_success": "Zahteva je bila uspešno poslana v sistem. Zdaj lahko zaprete okno.",
+ "qid": "Rspamd QID",
+ "qitem": "Predmet iz karantene",
+ "spam_score": "Rezultat",
+ "text_from_html_content": "Vsebina (pretvorjen html)",
+ "quarantine": "Karantena",
+ "quick_delete_link": "Odpri povezavo za hitro brisanje",
+ "quick_info_link": "Odpri povezavo z informacijami",
+ "quick_release_link": "Odpri povezavo za hitro objavo",
+ "rcpt": "Prejemnik",
+ "received": "Prejeto",
+ "recipients": "Prejemniki",
+ "refresh": "Osveži",
+ "rejected": "Zavrnjeno",
+ "release": "Izdaja",
+ "release_body": "Vaše sporočilo smo priložili kot datoteko eml temu sporočilu.",
+ "release_subject": "Potencialno škodljiv predmet v karanteni %s",
+ "remove": "Odstrani",
+ "rewrite_subject": "Prepiši zadevo",
+ "rspamd_result": "Rezultat Rspamd",
+ "sender": "Pošiljatelj (SMTP)",
+ "sender_header": "Pošiljatelj (glava »Od«)",
+ "settings_info": "Največje število elementov za karanteno (na poštni predal): %s<br>Največja velikost e-pošte: %s MiB",
+ "show_item": "Prikaži element",
+ "spam": "Neželena pošta",
+ "subj": "Zadeva",
+ "table_size": "Velikost tabele",
+ "table_size_show_n": "Prikaži %s elementov",
+ "text_plain_content": "Vsebina (besedilo/navadno)",
+ "toggle_all": "Preklopi vse",
+ "type": "Vrsta",
+ "quick_actions": "Dejanja"
+ },
+ "oauth2": {
+ "access_denied": "Za odobritev dostopa prek OAuth2 se prijavite kot lastnik poštnega predala.",
+ "authorize_app": "Avtorizacija aplikacije",
+ "deny": "Zavrni",
+ "permit": "Avtorizacija aplikacije",
+ "profile": "Profil",
+ "profile_desc": "Ogled osebnih podatkov: uporabniško ime, polno ime, ustvarjeno, spremenjeno, aktivno",
+ "scope_ask_permission": "Aplikacija je zahtevala naslednja dovoljenja"
+ },
+ "queue": {
+ "info": "Čakalna vrsta pošte vsebuje vsa e-poštna sporočila, ki čakajo na dostavo. Če je e-poštno sporočilo dlje časa obtičalo v čakalni vrsti, ga sistem samodejno izbriše.<br>Sporočilo o napaki ustreznega e-poštnega sporočila vsebuje informacije o tem, zakaj sporočila ni bilo mogoče dostaviti.",
+ "delete": "Izbriši vse",
+ "flush": "Izprazni čakalno vrsto",
+ "legend": "Funkcije dejanj čakalne vrste pošte:",
+ "ays": "Potrdite, da želite izbrisati vse elemente iz trenutne čakalne vrste.",
+ "deliver_mail": "Dostavi",
+ "deliver_mail_legend": "Poskusi ponovne dostave izbranih e-poštnih sporočil.",
+ "hold_mail": "Zadrži",
+ "hold_mail_legend": "Zadrži izbrano pošto. (Prepreči nadaljnje poskuse dostave)",
+ "queue_manager": "Upravitelj čakalnih vrst",
+ "show_message": "Prikaži sporočilo",
+ "unban": "odblokiraj čakalno vrsto",
+ "unhold_mail": "Nezadrži",
+ "unhold_mail_legend": "Sprosti izbrana sporočila za dostavo. (Zahteva predhodno zadržanje)"
+ },
+ "success": {
+ "eas_reset": "Naprave ActiveSync za uporabnika %s so bile ponastavljene",
+ "alias_added": "Dodan je bil vzdevek %s (%d)",
+ "app_passwd_added": "Dodano novo geslo za aplikacijo",
+ "domain_add_dkim_available": "Ključ DKIM je že obstajal",
+ "custom_login_modified": "Prilagoditev prijave je bila uspešno shranjena",
+ "rl_saved": "Omejitev hitrosti za objekt %s je shranjena",
+ "domain_admin_modified": "Spremembe skrbnika domene %s so bile shranjene",
+ "license_modified": "Spremembe licence so bile shranjene",
+ "pushover_settings_edited": "Nastavitve Pushoverja so bile uspešno nastavljene, preverite poverilnice.",
+ "mailbox_renamed": "Poštni nabiralnik je bil preimenovan iz %s v %s",
+ "recovery_email_sent": "E-poštno sporočilo za obnovitev je bilo poslano na %s",
+ "relayhost_removed": "Vnos na zemljevidu %s je bil odstranjen",
+ "acl_saved": "ACL za objekt %s shranjen",
+ "admin_added": "Dodan je bil skrbnik %s",
+ "admin_api_modified": "Spremembe API-ja so bile shranjene",
+ "admin_modified": "Spremembe skrbnika so bile shranjene",
+ "admin_removed": "Administrator %s je bil odstranjen",
+ "alias_domain_removed": "Vzdevek domene %s je bil odstranjen",
+ "alias_modified": "Spremembe vzdevka %s so bile shranjene",
+ "alias_removed": "Vzdevek %s je bil odstranjen",
+ "aliasd_added": "Dodan vzdevek domene %s",
+ "aliasd_modified": "Spremembe vzdevka domene %s so bile shranjene",
+ "app_links": "Shranjene spremembe povezav aplikacij",
+ "app_passwd_removed": "Odstranjen ID gesla za aplikacijo %s",
+ "bcc_deleted": "Vnosi na zemljevidu BCC so izbrisani: %s",
+ "bcc_edited": "Vnos na zemljevidu BCC %s je bil urejen",
+ "db_init_complete": "Inicializacija baze podatkov končana",
+ "delete_filter": "Izbrisani filtri ID %s",
+ "delete_filters": "Izbrisani filtri: %s",
+ "deleted_syncjob": "Izbrisan ID sinhronizacijskega opravila %s",
+ "deleted_syncjobs": "Izbrisana opravila sinhronizacije: %s",
+ "dkim_added": "Ključ DKIM %s je bil shranjen",
+ "dkim_duplicated": "Ključ DKIM za domeno %s je bil kopiran v %s",
+ "dkim_removed": "Ključ DKIM %s je bil odstranjen",
+ "domain_added": "Dodana domena %s",
+ "domain_admin_added": "Dodan je bil skrbnik domene %s",
+ "domain_admin_removed": "Skrbnik domene %s je bil odstranjen",
+ "domain_footer_modified": "Spremembe v nogi domene %s so bile shranjene",
+ "domain_modified": "Spremembe domene %s so bile shranjene",
+ "domain_removed": "Domena %s je bila odstranjena",
+ "dovecot_restart_success": "Dovecot je bil uspešno ponovno zagnan",
+ "f2b_banlist_refreshed": "ID seznama prepovedanih je bil uspešno osvežen.",
+ "f2b_modified": "Spremembe parametrov Fail2ban so bile shranjene",
+ "forwarding_host_added": "Dodan je bil posredovalni gostitelj %s",
+ "forwarding_host_removed": "Gostitelj za posredovanje %s je bil odstranjen",
+ "global_filter_written": "Filter je bil uspešno zapisan v datoteko",
+ "hash_deleted": "Zgoščena vrednost je izbrisana",
+ "iam_test_connection": "Povezava je bila uspešna",
+ "ip_check_opt_in_modified": "Preverjanje IP-ja je bilo uspešno shranjeno",
+ "item_deleted": "Element %s je bil uspešno izbrisan",
+ "items_deleted": "Element %s je bil uspešno izbrisan",
+ "items_released": "Izbrani elementi so bili izdani",
+ "logged_in_as": "Prijavljen kot %s",
+ "mailbox_added": "Dodan je bil poštni predal %s",
+ "mailbox_modified": "Spremembe poštnega nabiralnika %s so bile shranjene",
+ "mailbox_removed": "Poštni nabiralnik %s je bil odstranjen",
+ "nginx_reloaded": "Nginx je bil ponovno naložen",
+ "object_modified": "Spremembe objekta %s so bile shranjene",
+ "password_policy_saved": "Pravilnik o geslih je bil uspešno shranjen",
+ "password_changed_success": "Geslo je bilo uspešno spremenjeno",
+ "qlearn_spam": "Sporočilo z ID-jem %s je bilo prepoznano kot neželena pošta in izbrisano",
+ "queue_command_success": "Ukaz za čakalno vrsto je bil uspešno zaključen",
+ "recipient_map_entry_deleted": "ID zemljevida prejemnika %s je bil izbrisan",
+ "recipient_map_entry_saved": "Vnos zemljevida prejemnika »%s« je bil shranjen",
+ "relayhost_added": "Dodan je bil vnos na zemljevid %s",
+ "reset_main_logo": "Ponastavi na privzeti logotip",
+ "resource_added": "Dodan je bil vir %s",
+ "resource_modified": "Spremembe poštnega nabiralnika %s so bile shranjene",
+ "resource_removed": "Vir %s je bil odstranjen",
+ "rspamd_ui_pw_set": "Geslo uporabniškega vmesnika Rspamd je bilo uspešno nastavljeno",
+ "settings_map_added": "Dodan vnos nastavitev zemljevida",
+ "settings_map_removed": "Odstranjen ID zemljevida nastavitev %s",
+ "sogo_profile_reset": "Profil SOGo za uporabnika %s je bil ponastavljen",
+ "template_added": "Dodana predloga %s",
+ "template_modified": "Spremembe predloge %s so bile shranjene",
+ "template_removed": "ID predloge %s je bil izbrisan",
+ "tls_policy_map_entry_deleted": "ID zemljevida pravilnika TLS %s je bil izbrisan",
+ "tls_policy_map_entry_saved": "Vnos zemljevida pravilnika TLS »%s« je bil shranjen",
+ "ui_texts": "Shranjene spremembe besedil uporabniškega vmesnika",
+ "upload_success": "Datoteka je bila uspešno naložena",
+ "verified_fido2_login": "Preverjena prijava v FIDO2",
+ "verified_totp_login": "Preverjena prijava v TOTP",
+ "verified_webauthn_login": "Preverjena prijava v WebAuth",
+ "verified_yotp_login": "Preverjena prijava z enkratnim geslom Yubico",
+ "bcc_saved": "Vnos na zemljevidu BCC je shranjen",
+ "cors_headers_edited": "Nastavitve CORS so bile shranjene",
+ "item_released": "Izdan je bil element %s",
+ "saved_settings": "Shranjene nastavitve",
+ "learned_ham": "Uspešno naučen ID %s kot zaželjen",
+ "ui_theme_modified": "Tema je bila uspešno shranjena"
+ },
+ "start": {
+ "imap_smtp_server_auth_info": "Prosimo, uporabite svoj celoten e-poštni naslov in mehanizem za preverjanje pristnosti PLAIN.<br>\nVaši podatki za prijavo bodo šifrirani z obveznim šifriranjem na strani strežnika.",
+ "help": "Prikaži/skrij ploščo s pomočjo"
+ },
+ "tfa": {
+ "api_register": "%s uporablja Yubico Cloud API. Pridobite API ključ za svoj ključ <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">tukaj</a>",
+ "authenticators": "Preverjevalniki pristnosti",
+ "confirm": "Potrdi",
+ "delete_tfa": "Onemogoči TFA",
+ "disable_tfa": "Onemogoči TFA do naslednje uspešne prijave",
+ "enter_qr_code": "Vaša koda TOTP, če vaša naprava ne more skenirati kod QR",
+ "error_code": "Koda napake",
+ "confirm_totp_token": "Spremembe potrdite z vnosom ustvarjenega žetona",
+ "tfa": "Dvofaktorska avtentikacija",
+ "webauthn": "Preverjanje pristnosti WebAuthn",
+ "none": "Deaktiviraj",
+ "init_webauthn": "Inicializacija, prosim počakajte...",
+ "key_id": "Identifikator za vašo napravo",
+ "key_id_totp": "Identifikator za vaš ključ",
+ "reload_retry": "- (če napaka vztraja, znova zaženite brskalnik)",
+ "scan_qr_code": "Prosimo, skenirajte naslednjo kodo z aplikacijo za preverjanje pristnosti ali jo vnesite ročno.",
+ "select": "Prosimo, izberite",
+ "set_tfa": "Nastavite metodo dvofaktorske avtentikacije",
+ "start_webauthn_validation": "Začni validacijo",
+ "tfa_token_invalid": "Žeton TFA neveljaven",
+ "totp": "Enkratno geslo na podlagi časa (Google Authenticator, Authy itd.)",
+ "u2f_deprecated": "Zdi se, da je bil vaš ključ registriran z zastarelo metodo U2F. Deaktivirali bomo dvofaktorsko overjanje in izbrisali vaš ključ.",
+ "u2f_deprecated_important": "Prosimo, registrirajte svoj ključ v skrbniški plošči z novo metodo WebAuthn.",
+ "waiting_usb_auth": "<i>Čakanje na napravo USB ...</i><br><br>Zdaj se dotaknite gumba na napravi USB.",
+ "waiting_usb_register": "<i>Čakanje na napravo USB ...</i><br><br>Vnesite svoje geslo zgoraj in potrdite registracijo tako, da tapnete gumb na napravi USB.",
+ "yubi_otp": "Avtentikacija z enkratnim geslom Yubico",
+ "force_tfa": "Vsiljena registracija 2FA ob prijavi",
+ "force_tfa_info": "Uporabnik bo moral pred dostopom do nadzorne plošče nastaviti dvofaktorsko overjanje.",
+ "setup_title": "Zahtevana je dvofaktorska avtentikacija",
+ "setup_required": "Vaš račun zahteva dvofaktorsko overjanje. Za nadaljevanje nastavite metodo dvofaktorske overitve.",
+ "cancel_setup": "Prekliči in se odjavi"
+ },
+ "ratelimit": {
+ "disabled": "Onemogočeno",
+ "second": "sporočil / sekundo",
+ "minute": "sporočil / minuto",
+ "hour": "sporočil / uro",
+ "day": "sporočil / dan"
+ },
+ "user": {
+ "create_syncjob": "Ustvari novo sinhronizacijsko opravilo",
+ "open_webmail_sso": "Spletna pošta",
+ "attribute": "Atribut",
+ "description": "Opis",
+ "direct_aliases_desc": "Na neposredne vzdevke vplivajo nastavitve filtra neželene pošte in pravilnika TLS.",
+ "direct_protocol_access": "Ta uporabnik poštnega predala ima <b>neposreden zunanji dostop</b> do naslednjih protokolov in aplikacij. To nastavitev nadzoruje vaš skrbnik. Za dostop do posameznih protokolov in aplikacij je mogoče ustvariti gesla za aplikacije.<br>Gumb »Spletna pošta« omogoča enotno prijavo v SOGo in je vedno na voljo.",
+ "shared_aliases_desc": "Na uporabniške nastavitve, kot sta filter neželene pošte ali pravilnik za šifriranje, ne vplivajo skupni vzdevki. Ustrezne filtre neželene pošte lahko nastavi le skrbnik kot pravilnik za celotno domeno.",
+ "force_pw_update": "Za dostop do storitev, povezanih s skupinsko programsko opremo, <b>morate</b> nastaviti novo geslo.",
+ "new_password": "Novo geslo",
+ "password_reset_info": "Če ni naveden e-poštni naslov za obnovitev gesla, te funkcije ni mogoče uporabiti.",
+ "pushover_sender_array": "Upoštevajte naslednje e-poštne naslove pošiljateljev <small>(ločeni z vejico)</small>",
+ "tag_help_explain": "V podmapi: pod mapo INBOX (\"INBOX/Facebook\") bo ustvarjena nova podmapa, poimenovana po oznaki.<br>\nV zadevi: ime oznake bo dodano pred zadevo e-poštnega sporočila, na primer: \"[Facebook] Moje novice\".",
+ "pushover_vars": "Če filter pošiljatelja ni definiran, bodo upoštevana vsa e-poštna sporočila.<br>Filtre regularnih izrazov in natančna preverjanja pošiljateljev je mogoče definirati posamično in bodo obravnavana zaporedno. Niso odvisna drug od drugega.<br>Uporabne spremenljivke za besedilo in naslov (upoštevajte pravilnike o varstvu podatkov)",
+ "quarantine_notification_info": "Ko je obvestilo poslano, bodo elementi označeni kot »obveščeni« in za ta določen element ne bodo poslana nobena nadaljnja obvestila.",
+ "verify": "Preveri",
+ "spamfilter_bl_desc": "E-poštni naslovi na seznamu zavrnjenih, ki bodo <b>vedno</b> razvrščeni kot neželena pošta in zavrnjeni. Zavrnjena pošta <b>ne</b> bo kopirana v karanteno. Uporabite lahko nadomestne znake. Filter se uporabi samo za neposredne vzdevke (vzdevke z enim samim ciljnim nabiralnikom), izključujoč vseobsegajoče vzdevke in sam nabiralnik.",
+ "spamfilter_wl_desc": "E-poštni naslovi na seznamu dovoljenih so programirani tako, da se <b>nikoli</b> ne razvrstijo kot neželena pošta. Uporabijo se lahko nadomestni znaki. Filter se uporabi samo za neposredne vzdevke (vzdevke z enim samim ciljnim poštnim predalom), izključujoč vseobsegajoče vzdevke in sam poštni predal.",
+ "tls_policy_warning": "<strong>Opozorilo:</strong> Če se odločite za uveljavitev šifriranega prenosa pošte, lahko izgubite e-pošto.<br>Sporočila, ki ne ustrezajo pravilniku, bo poštni sistem zavrnil s popolno napako.<br>Ta možnost velja za vaš primarni e-poštni naslov (prijavno ime), vse naslove, izpeljane iz vzdevkov domen, in vzdevke, <b>ki imajo samo ta en poštni predal</b> kot cilj.",
+ "allowed_protocols": "Dovoljeni protokoli",
+ "title": "Naslov",
+ "action": "Dejanje",
+ "active": "Aktivno",
+ "active_sieve": "Aktiven filter",
+ "advanced_settings": "Napredne nastavitve",
+ "alias": "Vzdevek",
+ "alias_create_random": "Generiraj naključne vzdevke",
+ "alias_extend_all": "Podaljšaj vzdevek za 1 uro",
+ "alias_full_date": "d.m.Y, H:i:s T",
+ "alias_remove_all": "Odstrani vse vzdevke",
+ "alias_select_validity": "Obdobje veljavnosti",
+ "alias_time_left": "Preostali čas",
+ "alias_valid_until": "Veljavno do",
+ "aliases_also_send_as": "Pošiljanje je dovoljeno tudi kot uporabnik",
+ "aliases_send_as_all": "Ne preverjaj dostopa pošiljatelja za naslednje domene in njihove vzdevke",
+ "app_hint": "Gesla aplikacij so alternativna gesla za prijavo v IMAP, SMTP, CalDAV, CardDAV in EAS. Uporabniško ime ostane nespremenjeno. Spletna pošta SOGo ni na voljo prek gesel aplikacij.",
+ "app_name": "Ime aplikacije",
+ "app_passwds": "Gesla aplikacij",
+ "apple_connection_profile": "Profil povezave Apple",
+ "apple_connection_profile_complete": "Ta profil povezave vključuje parametre IMAP in SMTP ter poti CalDAV (koledarji) in CardDAV (stiki) za napravo Apple.",
+ "apple_connection_profile_mailonly": "Ta profil povezave vključuje konfiguracijske parametre IMAP in SMTP za napravo Apple.",
+ "apple_connection_profile_with_app_password": "Novo geslo za aplikacijo se ustvari in doda v profil, tako da pri nastavitvi naprave ni treba vnesti gesla. Datoteke ne delite, saj omogoča poln dostop do vašega nabiralnika.",
+ "authentication": "Avtentikacija",
+ "change_password": "Spremeni geslo",
+ "change_password_hint_app_passwords": "Vaš račun ima %d gesel aplikacij, ki ne bodo spremenjena. Če jih želite upravljati, odprite zavihek Gesla aplikacij.",
+ "clear_recent_successful_connections": "Jasno vidne uspešne povezave",
+ "client_configuration": "Prikaži vodnike za konfiguracijo e-poštnih odjemalcev in pametnih telefonov",
+ "create_app_passwd": "Ustvari geslo za aplikacijo",
+ "created_on": "Ustvarjeno dne",
+ "daily": "Dnevno",
+ "day": "dan",
+ "delete_ays": "Prosimo, potrdite postopek brisanja.",
+ "direct_aliases": "Neposredni vzdevki",
+ "eas_reset": "Ponastavi predpomnilnik naprave ActiveSync",
+ "eas_reset_help": "V mnogih primerih bo ponastavitev predpomnilnika naprave pomagala obnoviti pokvarjen profil ActiveSync.<br><b>Pozor:</b> Vsi elementi bodo ponovno preneseni!",
+ "eas_reset_now": "Ponastavi zdaj",
+ "edit": "Uredi",
+ "email": "E-pošta",
+ "email_and_dav": "E-pošta, koledarji in stiki",
+ "empty": "Ni rezultatov",
+ "encryption": "Šifriranje",
+ "excludes": "Izključuje",
+ "expire_in": "Poteče čez",
+ "fido2_webauthn": "FIDO2/WebAuthn",
+ "from": "od",
+ "generate": "ustvari",
+ "hour": "ura",
+ "hourly": "Urno",
+ "hours": "ure",
+ "in_use": "Uporabljeno",
+ "interval": "Interval",
+ "is_catch_all": "Vseobsegajoča povezava za domeno/e",
+ "last_mail_login": "Zadnja prijava v e-pošto",
+ "last_pw_change": "Zadnja sprememba gesla",
+ "last_run": "Zadnji zagon",
+ "last_ui_login": "Zadnja prijava v uporabniški vmesnik",
+ "loading": "Nalaganje ...",
+ "login_history": "Zgodovina prijav",
+ "mailbox": "Poštni nabiralnik",
+ "mailbox_details": "Podrobnosti",
+ "mailbox_general": "Splošno",
+ "mailbox_settings": "Nastavitve",
+ "messages": "sporočila",
+ "month": "mesec",
+ "months": "meseci",
+ "never": "Nikoli",
+ "new_password_repeat": "Potrditveno geslo (ponovite)",
+ "no_active_filter": "Ni aktivnega filtra",
+ "no_last_login": "Ni zadnjih podatkov za prijavo v uporabniški vmesnik",
+ "no_record": "Ni zapisa",
+ "open_logs": "Odpri dnevnike",
+ "overview": "Pregled",
+ "password": "Geslo",
+ "password_now": "Trenutno geslo (potrdite spremembe)",
+ "password_repeat": "Geslo (ponovite)",
+ "protocols": "Protokoli",
+ "pushover_evaluate_x_prio": "Eskalacija e-pošte z visoko prioriteto [<code>X-Priority: 1</code>]",
+ "pushover_info": "Nastavitve potisnih obvestil bodo veljale za vso čisto (ne neželeno) pošto, dostavljeno na <b>%s</b>, vključno z vzdevki (v skupni rabi, brez skupne rabe, označeni).",
+ "pushover_only_x_prio": "Upoštevaj samo pošto z visoko prioriteto [<code>X-Priority: 1</code>]",
+ "pushover_sender_regex": "Poišči ujemanje pošiljateljev z naslednjim regularnim izrazom",
+ "pushover_text": "Besedilo obvestila",
+ "pushover_title": "Naslov obvestila",
+ "pushover_sound": "Zvok",
+ "pushover_verify": "Preverite poverilnice",
+ "pw_recovery_email": "E-poštno sporočilo za obnovitev gesla",
+ "q_add_header": "Mapa z neželeno pošto",
+ "q_reject": "Zavrnjeno",
+ "quarantine_category": "Kategorija obvestil o karanteni",
+ "quarantine_category_info": "Kategorija obvestil »Zavrnjeno« vključuje zavrnjeno pošto, medtem ko »Mapa z neželeno pošto« obvesti uporabnika o e-pošti, ki je bila premaknjena v mapo z neželeno pošto.",
+ "quarantine_notification": "Obvestila o karanteni",
+ "recent_successful_connections": "Videne uspešne povezave",
+ "remove": "Odstrani",
+ "running": "V teku",
+ "save": "Shrani spremembe",
+ "save_changes": "Shrani spremembe",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Preverjanje pošiljatelja je onemogočeno</span>",
+ "shared_aliases": "Skupni vzdevki",
+ "show_sieve_filters": "Prikaži filter sita aktivnega uporabnika",
+ "sogo_profile_reset": "Ponastavi profil SOGo",
+ "sogo_profile_reset_help": "S tem boste uničili uporabnikov profil SOGo in <b>nepovratno izbrisali vse stike in podatke koledarja</b>.",
+ "sogo_profile_reset_now": "Ponastavi profil zdaj",
+ "spam_aliases": "Vzdevki neželene e-pošte",
+ "spam_score_reset": "Ponastavi na privzete nastavitve strežnika",
+ "spamfilter": "Filter neželene pošte",
+ "spamfilter_behavior": "Ocena",
+ "spamfilter_bl": "Seznam zavrnjenih",
+ "spamfilter_default_score": "Privzete vrednosti",
+ "spamfilter_green": "Zelena: to sporočilo ni neželena pošta",
+ "spamfilter_hint": "Prva vrednost opisuje »nizko oceno neželene pošte«, druga pa »visoko oceno neželene pošte«.",
+ "spamfilter_red": "Rdeča: To sporočilo je neželena pošta in ga bo strežnik zavrnil",
+ "spamfilter_table_action": "Dejanje",
+ "spamfilter_table_add": "Dodaj element",
+ "spamfilter_table_domain_policy": "ni na voljo (pravilnik domene)",
+ "spamfilter_table_empty": "Ni podatkov za prikaz",
+ "spamfilter_table_remove": "odstrani",
+ "spamfilter_table_rule": "Pravilo",
+ "spamfilter_wl": "Seznam dovoljenih",
+ "spamfilter_yellow": "Rumena: to sporočilo je morda neželena pošta, označeno bo kot neželena pošta in premaknjeno v mapo z neželeno pošto",
+ "status": "Stanje",
+ "sync_jobs": "Sinhronizacija opravil",
+ "syncjob_check_log": "Preveri dnevnik",
+ "syncjob_last_run_result": "Rezultat zadnjega zagona",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Težava s povezavo",
+ "syncjob_EXIT_TLS_FAILURE": "Težava s šifrirano povezavo",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Težava z overjanjem",
+ "syncjob_EXIT_OVERQUOTA": "Ciljni poštni predal presega kvoto",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Ni mogoče vzpostaviti povezave z oddaljenim strežnikom",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Napačno uporabniško ime ali geslo",
+ "tag_handling": "Nastavitev obravnave označene pošte",
+ "tag_help_example": "Primer označenega e-poštnega naslova: jaz<b>+Facebook</b>@example.org",
+ "tag_in_none": "Ne naredi ničesar",
+ "tag_in_subfolder": "V podmapi",
+ "tag_in_subject": "V zadevi",
+ "text": "Besedilo",
+ "tfa_info": "Dvofaktorska avtentikacija pomaga zaščititi vaš račun. Če jo omogočite, boste za prijavo v aplikacije ali storitve, ki ne podpirajo dvofaktorske avtentikacije (npr. poštni odjemalci), potrebovali gesla za aplikacije.",
+ "tls_enforce_in": "Uveljavi dohodni TLS",
+ "tls_enforce_out": "Uveljavi odhodni TLS",
+ "tls_policy": "Pravilnik o šifriranju",
+ "user_settings": "Uporabniške nastavitve",
+ "username": "Uporabniško ime",
+ "value": "Vrednost",
+ "week": "teden",
+ "weekly": "Tedensko",
+ "weeks": "tedni",
+ "with_app_password": "z geslom za aplikacijo",
+ "year": "leto",
+ "years": "leta",
+ "waiting": "Čakanje",
+ "q_all": "Vse kategorije",
+ "syncjob_EX_OK": "Uspeh",
+ "expire_never": "Nikoli ne poteče",
+ "forever": "Za vedno",
+ "spam_aliases_info": "Vzdevek za neželeno pošto je začasni e-poštni naslov, ki ga je mogoče uporabiti za zaščito pravih e-poštnih naslovov. <br>Po želji je mogoče nastaviti čas poteka veljavnosti, tako da se vzdevek po določenem obdobju samodejno deaktivira, s čimer se učinkovito znebite zlorabljenih ali razkritih naslovov.",
+ "pw_update_required": "Za vaš račun je potrebna sprememba gesla. Za nadaljevanje nastavite novo geslo."
+ },
+ "warning": {
+ "cannot_delete_self": "Prijavljenega uporabnika ni mogoče izbrisati",
+ "domain_added_sogo_failed": "Domena je bila dodana, vendar ponovni zagon SOGo ni uspel. Preverite dnevnike strežnika.",
+ "dovecot_restart_failed": "Dovecota ni uspelo znova zagnati, preverite dnevnike",
+ "fuzzy_learn_error": "Napaka učenja mehkega zgoščevanja: %s",
+ "hash_not_found": "Zgoščena vrednost ni bila najdena ali je bila že izbrisana",
+ "ip_invalid": "Preskočen neveljaven IP: %s",
+ "is_not_primary_alias": "Preskočen neprimarni vzdevek %s",
+ "no_active_admin": "Zadnjega aktivnega skrbnika ni mogoče deaktivirati",
+ "quota_exceeded_scope": "Kvota domene presežena: V tem obsegu domene je mogoče ustvariti le neomejeno število poštnih predalov.",
+ "session_token": "Neveljaven žeton obrazca: Neujemanje žetonov",
+ "session_ua": "Neveljaven žeton obrazca: Napaka pri preverjanju uporabniškega agenta"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.sk-sk.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.sk-sk.json
index 466afdb..cf480cc 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.sk-sk.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.sk-sk.json
@@ -499,7 +499,6 @@
"external_logs": "Externé logy",
"history_all_servers": "História (všetky servery)",
"in_memory_logs": "Logy uložené v pamäti",
- "jvm_memory_solr": "JVM spotreba pamäte",
"last_modified": "Naposledy upravené",
"log_info": "<b>Logy v pamäti</b> sú zbierané do Redis listu s max. limitom LOG_LINES (%d) riadkov každú minútu, čo bráni nadmernej záťaži servera.\r\n <br>Logy v pamäti nemajú trvalý charakter. Všetky aplikácie ktoré vedú logy v pamäti, tiež logujú do Docker démona a súčasne do nastaveného logging drivera.\r\n <br>Logy v pamäti sa môžu použiť na ladenie menších problémov s kontajnermi.</p>\r\n <p><b>Externé logy</b> sú zbierané cez API danej aplikácie.</p>\r\n <p><b>Statické logy</b> sú väčšinou aktivity, ktoré nie sú logované do Docker démona, ale musia byť trvalo zaznamenané (s výnimkou API záznamov).</p>",
"login_time": "Čas",
@@ -508,8 +507,6 @@
"restart_container": "Reštartovať",
"service": "Služba",
"size": "Veľkosť",
- "solr_dead": "Solr štartuje, je vypnutý alebo nebeží.",
- "solr_status": "Solr status",
"started_at": "Spustený",
"started_on": "Spustený",
"static_logs": "Statické logy",
@@ -625,8 +622,8 @@
"sieve_desc": "Krátky popis",
"sieve_type": "Typ filtru",
"skipcrossduplicates": "Preskočiť duplikované správy naprieč priečinkami (akceptuje sa prvý nález)",
- "sogo_access": "Prideliť priame prihlásenie do SOGo",
- "sogo_access_info": "Jednotné prihlásenie z používateľského mail rozhrania zostáva funkčné. Toto nastavenie nemá vplyv na prístup k ostatným službám, ani neodstraňuje alebo nemení existujúci profil používateľa SOGo.",
+ "sogo_access": "Priame presmerovanie na SOGo",
+ "sogo_access_info": "Po prihlásení je používateľ automaticky presmerovaný na službu SOGo.",
"sogo_visible": "Alias je viditeľný v SOGo",
"sogo_visible_info": "Táto voľba ovplyvňuje len objekty, ktoré dokážu byť zobrazené v SOGo (zdieľané alebo nezdieľané alias adresy ukazujúc na minimálne jednu lokálnu mailovú schránku). Ak je skrytý, alias nebude prezentovaný ako voliteľný odosielateľ v SOGo.",
"spam_alias": "Vytvoriť alebo zmeniť časovo limitované alias adresy",
@@ -707,7 +704,7 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Prihlásenie",
"mobileconfig_info": "Prosím, prihláste sa ako mailový používateľ pre stiahnutie požadovaného Apple profilu.",
- "other_logins": "Prihlásenie kľúčom",
+ "other_logins": "alebo prihlásiť sa s",
"password": "Heslo",
"username": "Používateľské meno alebo email"
},
@@ -825,7 +822,7 @@
"recipient_map": "Mapa príjemcu",
"recipient_map_info": "Mapy príjemcov sú používané ako náhrada cieľovej adresy u správy pred doručením.",
"recipient_map_new": "Nový príjemca",
- "recipient_map_new_info": "Mapový cieľ príjemcu musí byť platná emailová adresa.",
+ "recipient_map_new_info": "Mapový cieľ príjemcu musí byť platná emailová adresa alebo meno domény.",
"recipient_map_old": "Originálny príjemca",
"recipient_map_old_info": "Originálny cieľ mapy príjemcu musí byť platná emailová adresa alebo meno domény.",
"recipient_maps": "Mapy príjemcov",
@@ -971,9 +968,7 @@
},
"start": {
"help": "Zobraziť/Skryť panel nápoveď",
- "imap_smtp_server_auth_info": "Prosím použite celú vašu emailovú adresu a metódu overenia PLAIN.<br>\r\n Vaše prihlasovacie údaje budú zašifrované na strane servera.",
- "mailcow_apps_detail": "Použite mailcow aplikácie pre prístup k vašej mailovej schránke, kalendáru, kontaktom a viac.",
- "mailcow_panel_detail": "<b>Administrátori domény</b> môžu vytvárať, modifikovať alebo mazať schránky a aliasy, meniť domény a zobraziť informácie o priradených doménach.<br>\r\n<b>Bežný používatelia</b> majú možnosť vytvoriť časovo obmedzené aliasy (spam aliasy), meniť heslá a nastavenia spam filtra."
+ "imap_smtp_server_auth_info": "Prosím použite celú vašu emailovú adresu a metódu overenia PLAIN.<br>\r\n Vaše prihlasovacie údaje budú zašifrované na strane servera."
},
"success": {
"acl_saved": "ACL pre objekt %s uložený",
@@ -1116,10 +1111,11 @@
"created_on": "Vytvorené",
"daily": "Denne",
"day": "deň",
+ "description": "Popis",
"delete_ays": "Potvrďte zmazanie.",
"direct_aliases": "Priame alias adresy",
"direct_aliases_desc": "Priame aliasy sú ovplyvnené spam filtrom a nastavením TLS pravidiel.",
- "direct_protocol_access": "Tento používateľ mailovej schránky má <b>priamy, externý prístup</b> k nasledujúcim protokolom a aplikáciám. Toto nastavenie kontroluje administrátor. Na udelenie prístupu k jednotlivým protokolom a aplikáciám je možné vytvoriť heslá aplikácií.<br>Tlačidlo \"Prihlásenie do webmailu\" poskytuje jednotné prihlásenie do systému SOGo a je vždy k dispozícii.",
+ "direct_protocol_access": "Tento používateľ mailovej schránky má <b>priamy, externý prístup</b> k nasledujúcim protokolom a aplikáciám. Toto nastavenie kontroluje administrátor. Na udelenie prístupu k jednotlivým protokolom a aplikáciám je možné vytvoriť heslá aplikácií.<br>Tlačidlo \"Webmailu\" poskytuje jednotné prihlásenie do systému SOGo a je vždy k dispozícii.",
"eas_reset": "Resetovať medzipamäť u ActiveSync zariadení",
"eas_reset_help": "Vo väčšine prípadov, reset medzipamäte ActiveSync pomôže opravit nefunkčný profil.<br><b>Pozor:</b> Všetky potrebné dáta budú opäť stiahnuté!",
"eas_reset_now": "Reset ActiveSync",
@@ -1160,7 +1156,7 @@
"no_last_login": "Žiadny záznam o prihlásení cez web",
"no_record": "Žiaden záznam",
"open_logs": "Otvoriť záznam",
- "open_webmail_sso": "Prihláste sa do webmailu",
+ "open_webmail_sso": "Webmailu",
"password": "Heslo",
"password_now": "Aktuálne heslo (potvrdiť zmeny)",
"password_repeat": "Heslo (opakovať)",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.sv-se.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.sv-se.json
index a987081..5661893 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.sv-se.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.sv-se.json
@@ -60,7 +60,7 @@
"exclude": "Exkludera objekt (regex-filter)",
"full_name": "Fullständiga namn",
"gal": "Global adressbok",
- "gal_info": "Den global adressboken innehåller alla objekt i en domän och kan inte redigeras av någon användare. Informationen om tillgänglighet i SOGo är endast synlig när den globala adressboken är påslagen. <b>Starta om SOGo för att tillämpa ändringar.</b>",
+ "gal_info": "Den global adressboken innehåller alla objekt i en domän och kan inte redigeras av någon användare. Informationen om tillgänglighet i SOGo är endast synlig när den globala adressboken är påslagen. <b>Starta om SOGo för att tillämpa ändringar.</b>",
"generate": "generera",
"goto_ham": "Markera detta som en <span class=\"text-success\"><b>felaktig spam-registrering</b>, detta kommer förhindra liknande fel i framtiden</span>",
"goto_null": "Kasta e-postmeddelanande omedelbart",
@@ -453,17 +453,14 @@
"external_logs": "Externa loggar",
"history_all_servers": "Historik (alla servrar)",
"in_memory_logs": "Loggar sparade i minnet",
- "jvm_memory_solr": "JVM minnesanvändning",
"log_info": "<p>mailcow <b>loggar sparade i minnet</b> samlas in i Redis-listor och trimmas till LOG_LINES (%d) varje minut för att minska lasten.\r\n <br>Loggar sparade i minnet är inte tänkta att vara beständiga. Alla applikationer som loggar i minnet loggar också till Docker-demonen och därefter till standardrutinen för loggning.\r\n <br>Loggar sparade i minnet bör användas för felsökning av mindre problem med olika behållare.</p>\r\n <p><b>Externa loggar</b> samlas in via ett API på den givna applikationen.</p>\r\n <p><b>Statiska loggar</b> är mestadels aktivitetsloggar som inte är loggas i Docker, men som fortfarande måste vara beständiga (utom API-loggar).</p>",
"logs": "Loggar",
"restart_container": "Omstart",
- "solr_dead": "Solr är i uppstart, har inaktiveras eller är tillfälligt avstängd.",
"online_users": "Användare online",
"docs": "Dokumentation",
"last_modified": "Senast ändrad",
"size": "Storlek",
"started_at": "Startades kl.",
- "solr_status": "Solr status",
"uptime": "Upptid",
"started_on": "Startades",
"static_logs": "Statiska loggar",
@@ -621,7 +618,7 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Logga in",
"mobileconfig_info": "Logga in som en användare av brevlåda för att ladda ner den begärda Apple-anslutningsprofilen.",
- "other_logins": "Loggain med nyckel",
+ "other_logins": "eller logga in med",
"password": "Lösenord",
"username": "Användarnamn"
},
@@ -729,7 +726,7 @@
"recipient_map": "Mottagaromskrivning",
"recipient_map_info": "En omskrivning av mottagaradressen används för att ersätta destinationsadressen i ett meddelande innan den levereras.",
"recipient_map_new": "Ny mottagare",
- "recipient_map_new_info": "Den ursprungliga mottagaren måste vara en giltig e-postadress.",
+ "recipient_map_new_info": "Den ursprungliga mottagaren måste vara en giltiga e-postadresser eller ett domännamn.",
"recipient_map_old": "Ursprunglig mottagaren",
"recipient_map_old_info": "Den ursprungliga mottagaren måste vara en giltiga e-postadresser eller ett domännamn.",
"recipient_maps": "Skriv om mottagaradressen",
@@ -844,9 +841,7 @@
},
"start": {
"help": "Visa/dölj hjälppanel",
- "imap_smtp_server_auth_info": "Använd din fullständiga e-postadress och PLAIN-autentiseringsmekanism.<br>\r\nInloggningsuppgifterna överförs krypterat eftersom obligatorisk kryptering sker till servern.",
- "mailcow_apps_detail": "Använd Mailcow-applikationen för att läsa e-postmeddelanden, kalender, kontakter och mer.",
- "mailcow_panel_detail": "<b>Domänadministratörer</b> skapar, ändrar eller kan ta bort postlådor eller aliasadresser. Dom administrerar och felsöker sina tilldelade domäner.<br>\r\n<b>Användare av påstlådor</b> kan skapa tidsbegränsade aliasadresser (skräppostalias), ändra sitt lösenord och hantera spamfilterinställningar."
+ "imap_smtp_server_auth_info": "Använd din fullständiga e-postadress och PLAIN-autentiseringsmekanism.<br>\r\nInloggningsuppgifterna överförs krypterat eftersom obligatorisk kryptering sker till servern."
},
"success": {
"acl_saved": "Åtkomstlistan för objektet %s har sparats",
@@ -993,6 +988,7 @@
"created_on": "Skapad vid",
"daily": "Dagligen",
"day": "dag",
+ "description": "Beskrivning",
"delete_ays": "Är du säker att du vill ta bort det här objektet?",
"direct_aliases": "Direkta aliasadresser",
"direct_aliases_desc": "Endast direkta aliasadresser påverkas av spamfilter och TLS-policyföreskrifter.",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.tr-tr.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.tr-tr.json
index 5219c41..bc1da77 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.tr-tr.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.tr-tr.json
@@ -1,6 +1,6 @@
{
"acl": {
- "alias_domains": "Alias domain ekle",
+ "alias_domains": "Takma alan adı ekle",
"app_passwds": "Uygulama şifrelerini yönet",
"bcc_maps": "BCC haritası",
"delimiter_action": "Sınırlandırma işlemi",
@@ -28,7 +28,8 @@
"spam_score": "Spam skoru",
"syncjobs": "Görevleri senkronize et",
"tls_policy": "TLS ilkesi",
- "unlimited_quota": "E-postalar için sınırsız kota"
+ "unlimited_quota": "E-postalar için sınırsız kota",
+ "pw_reset": "Mailcow kullanıcı şifresini sıfırlamaya izin ver"
},
"add": {
"activate_filter_warn": "Aktif edilirse diğer tüm filtreler devre dışı bırakılacak.",
@@ -68,7 +69,7 @@
"goto_null": "Postaları çöpe at",
"goto_spam": "Spam olarak<span class=\"text-danger\"><b>işaretle</b></span>",
"hostname": "Ana sunucu",
- "inactive": "İnaktif",
+ "inactive": "Pasif",
"kind": "Tür",
"mailbox_quota_def": "Varsayılan e-posta kotası",
"mailbox_quota_m": "E-posta başına maksimum kota (MiB)",
@@ -77,7 +78,7 @@
"max_mailboxes": "Maksimum e-posta hesabı",
"mins_interval": "Sorgulama döngüsü (dakika)",
"multiple_bookings": "Birden fazla rezervasyon",
- "nexthop": "Next hop",
+ "nexthop": "Sonraki atlama",
"password": "Şifre",
"password_repeat": "Şifre (tekrar)",
"port": "Port",
@@ -107,7 +108,8 @@
"timeout2": "Yerel ana bilgisayara bağlantı için zaman aşımı",
"username": "Kullanıcı Adı",
"validate": "Doğrula",
- "validation_success": "Doğrulama başarılı"
+ "validation_success": "Doğrulama başarılı",
+ "dry": "Senkronizasyonu simüle et"
},
"admin": {
"action": "İşlem",
@@ -133,7 +135,229 @@
"duplicate_dkim": "Çift DKIM kayıtları",
"f2b_ban_time": "Yasaklama süresi (saniye)",
"f2b_max_attempts": "Maksimum giriş denemesi",
- "f2b_retry_window": "Maksimum girişim için deneme pencere(leri)"
+ "f2b_retry_window": "Maksimum girişim için deneme pencere(leri)",
+ "ip_check_disabled": "IP kontrolü devre dışı. Bunu <br> <strong>Sistem > Yapılandırma > Seçenekler > Özelleştir</strong> altında etkinleştirebilirsiniz.",
+ "logo_info": "Resminiz, üst gezinme çubuğu için 40 piksel yüksekliğe ve maks. başlangıç sayfası için 250 piksel genişlik. Ölçeklenebilir bir grafik şiddetle tavsiye edilir.",
+ "forwarding_hosts_add_hint": "IPv4/IPv6 adreslerini, CIDR gösterimindeki ağları, ana bilgisayar adlarını (IP adreslerine çözümlenecek) veya alan adlarını (SPF kayıtlarını veya yokluğunda MX kayıtlarını sorgulayarak IP adreslerine çözümlenecek) belirtebilirsiniz.",
+ "include_exclude_info": "Varsayılan olarak - seçim yapılmadan - <b>tüm posta kutuları</b> adreslenir",
+ "credentials_transport_warning": "<b>Uyarı</b>: Yeni bir ulaşım haritası girişi eklemek, eşleşen bir sonraki atlama sütunuyla tüm girişlerin kimlik bilgilerini güncelleyecektir.",
+ "f2b_manage_external_info": "Fail2ban yasak listeyi koruyacak fakat trafiğe engel olacak kurallar koymayacak.Trafiği dışarıdan engellemek için aşağıda oluşturulan yasak listesini kullanın.",
+ "add_settings_rule": "Ayarlar kuralı ekle",
+ "add_transports_hint": "Lütfen, varsa, kimlik doğrulama verilerinin düz metin olarak saklanacağını unutmayın.",
+ "additional_rows": " ek satırlar eklendi",
+ "admin": "Yönetici",
+ "admins": "Yöneticiler",
+ "admins_ldap": "LDAP yöneticileri",
+ "advanced_settings": "Gelişmiş ayarlar",
+ "allowed_origins": "Access-Control-Allow-Origin",
+ "cors_settings": "CORS ayarları",
+ "last_applied": "Son uygulanan",
+ "logo_normal_label": "Normal",
+ "logo_dark_label": "Karanlık moda çevir",
+ "f2b_max_ban_time": "Max. yasaklanma süresi (s)",
+ "guid": "GUID - benzersiz örnek kimliği",
+ "guid_and_license": "GUID & Lisans",
+ "copy_to_clipboard": "Metni panoya kopyala",
+ "dkim_add_key": "ARC/DKIM key ekle",
+ "dkim_domains_selector": "Seçici",
+ "dkim_from": "Gönderen",
+ "dkim_key_length": "DKIM anahtar uzunluğu (bit)",
+ "dkim_key_missing": "Anahtar eksik",
+ "dkim_key_unused": "Anahtar kullanılamaz",
+ "dkim_key_valid": "Anahtar geçerli",
+ "dkim_keys": "ARC/DKIM anahtarları",
+ "dkim_overwrite_key": "Mevcut DKIM anahtarının üzerine yaz",
+ "dkim_private_key": "Özel anahtar",
+ "f2b_ban_time_increment": "Yasaklanma süresi her engellemede artar",
+ "f2b_manage_external": "Fail2Ban'ı dışarıdan yönetin",
+ "f2b_regex_info": "Dikkate alınan günlükler: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "f2b_whitelist": "Beyaz listeye alınan ağlar/ana bilgisayarlar",
+ "filter_table": "Tabloyu filtrele",
+ "forwarding_hosts": "Yönlendirme Ana Bilgisayarları",
+ "forwarding_hosts_hint": "Gelen mesajlar burada listelenen tüm ana bilgisayarlardan koşulsuz olarak kabul edilir. Bu ana bilgisayarlar daha sonra DNSBL'lere karşı kontrol edilmez veya gri listeye tabi tutulmaz. Onlardan gelen istenmeyen e-postalar asla reddedilmez, ancak isteğe bağlı olarak Önemsiz klasörüne dosyalanabilir. Bunun en yaygın kullanımı, gelen e-postaları mailcow sunucunuza ileten bir kural kurduğunuz posta sunucularını belirtmektir.",
+ "from": "Kimden",
+ "generate": "oluştur",
+ "hash_remove_info": "Bir hız sınırı karmasını (hala mevcutsa) kaldırmak, sayacını tamamen sıfırlayacaktır.<br>\n Her karma ayrı bir renkle belirtilir.",
+ "help_text": "Oturum açma maskesinin altındaki yardım metnini geçersiz kıl (HTML'ye izin verilir)",
+ "host": "Host",
+ "html": "HTML",
+ "import": "İçe aktar",
+ "import_private_key": "Özel anahtarı içe aktar",
+ "in_use_by": "tarafından kullanımda",
+ "inactive": "Pasif",
+ "include_exclude": "Dahil et, hariç tut",
+ "includes": "Bu alıcıları dahil et",
+ "ip_check_opt_in": "Harici IP adreslerini çözümlemek için <strong>ipv4.mailcow.email</strong> ve <strong>ipv6.mailcow.email</strong> üçüncü taraf hizmetini kullanmayı seçin.",
+ "is_mx_based": "MX tabanlı",
+ "link": "Link",
+ "loading": "Lütfen bekleyin…",
+ "login_time": "Giriş zamanı",
+ "lookup_mx": "Hedef, MX adıyla eşleşecek normal bir ifadedir (google.com ile biten bir MX'e hedeflenen tüm postaları bu atlama üzerinden yönlendirmek için <code>.*google\\\\.com</code>)",
+ "main_name": "“mailcow UI” adı",
+ "merged_vars_hint": "Grileştirilmiş satırlar <code>vars.(local.)inc.php</code> dosyasından birleştirildi ve değiştirilemez.",
+ "message": "Mesaj",
+ "message_size": "Mesaj boyutu",
+ "nexthop": "Sonraki atlama",
+ "no": "✕",
+ "no_active_bans": "Aktif yasak yok",
+ "allowed_methods": "Access-Control-Allow-Methods",
+ "f2b_netban_ipv4": "Yasak uygulanacak IPv4 alt ağ boyutu (8-32)",
+ "f2b_netban_ipv6": "Yasak uygulanacak IPv6 alt ağ boyutu (8-32)",
+ "f2b_parameters": "Fail2ban parametreleri",
+ "empty": "Sonuç yok",
+ "excludes": "Bu alıcıları hariç tutar",
+ "f2b_blacklist": "Kara listeye alınan ağlar/ana bilgisayarlar",
+ "f2b_filter": "Regex filtreleri",
+ "f2b_list_info": "Kara listeye alınmış bir ana bilgisayar veya ağ, her zaman beyaz listedeki bir varlıktan daha ağır basacaktır. <b>Liste güncellemelerinin uygulanması birkaç saniye sürecektir.</b>",
+ "ip_check": "IP Kontrol",
+ "access": "Erişim",
+ "activate_api": "API etkinleştir",
+ "activate_send": "Gönder düğmesini etkinleştir",
+ "active": "Etkinleştir",
+ "active_rspamd_settings_map": "Aktif ayarlar haritası",
+ "add_admin": "Yönetici ekle",
+ "add_relayhost": "Gönderene bağlı aktarım ekle",
+ "add_relayhost_hint": "Lütfen, varsa, kimlik doğrulama verilerinin düz metin olarak saklanacağını unutmayın.",
+ "add_row": "Satır ekle",
+ "api_allow_from": "Bu IP'lerden/CIDR ağ gösterimlerinden API erişimine izin ver",
+ "api_key": "API anahtarı",
+ "api_read_only": "Sadece okuma",
+ "api_read_write": "Okuma yazma",
+ "api_skip_ip_check": "API için IP kontrolünü atla",
+ "app_links": "Uygulama linkleri",
+ "app_name": "Uygulama adı",
+ "arrival_time": "Varış zamanı (sunucu zamanı)",
+ "customer_id": "Müşteri Kimliği",
+ "customize": "Özelleştir",
+ "destination": "Hedef",
+ "ays": "Devam etmek istediğinizden emin misiniz?",
+ "change_logo": "Logoyu değiştir",
+ "convert_html_to_text": "HTML'yi düz metne dönüştürün",
+ "edit": "Düzenle",
+ "no_new_rows": "Başka satır yok",
+ "oauth2_client_secret": "Client anahtarı",
+ "quarantine_release_format": "Serbest bırakılan öğelerin biçimi",
+ "oauth2_info": "OAuth2 uygulaması, \"Yetkilendirme Kodu\" verme türünü destekler ve yenileme belirteçleri yayınlar.<br>\nSunucu, bir yenileme belirteci kullanıldıktan sonra otomatik olarak yeni yenileme belirteçleri de verir.<br><br>\n• Varsayılan kapsam <i>profil</i>'dir. OAuth2'ye karşı yalnızca posta kutusu kullanıcılarının kimliği doğrulanabilir. Kapsam parametresi atlanırsa, <i>profile</i>'ye geri döner.<br>\n• <i>state</i> parametresinin, yetkilendirme isteğinin bir parçası olarak istemci tarafından gönderilmesi gerekir.<br><br>\nOAuth2 API'sine yapılan istekler için yollar: <br>\n< ul>\n<li>Yetkilendirme bitiş noktası: <code>/oauth/authorize</code></li>\n<li>Token bitiş noktası: <code>/oauth/token</code></ li>\n<li>Kaynak sayfası: <code>/oauth/profile</code></li>\n</ul>\nİstemci sırrının yeniden oluşturulması, mevcut yetkilendirme kodlarının süresinin dolmasına neden olmaz, ancak belirteçlerini yenileyemezler.<br><br>\nİstemci belirteçlerini iptal etmek, tüm etkin oturumların derhal sonlandırılmasına neden olur. Tüm istemcilerin yeniden kimlik doğrulaması yapması gerekir.",
+ "license_info": "Lisans gerekli değildir ancak daha fazla geliştirmeye yardımcı olur.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"\">GUID'inizi buraya kaydedin.</a> or <a href=\"https://www.servercow.de/mailcow?lang=tr#destek\" target=\"_blank\" alt=\"\">Mailcow kurulumunuz için destek satın alın.</a>",
+ "no_record": "Kayıt yok",
+ "oauth2_apps": "OAuth2 Uygulamaları",
+ "oauth2_add_client": "OAuth2 client ekle",
+ "oauth2_client_id": "Client ID",
+ "optional": "isteğe bağlı",
+ "oauth2_redirect_uri": "URI Yönlendirmesi",
+ "oauth2_renew_secret": "Yeni client anahtarı oluştur",
+ "oauth2_revoke_tokens": "Tüm client tokenlarını iptal et",
+ "quarantine": "Karantina",
+ "options": "Seçenekler",
+ "password": "Şifre",
+ "password_length": "Parola uzunluğu",
+ "password_policy": "Şifre politikası",
+ "password_policy_chars": "En az bir alfabetik karakter içermelidir",
+ "password_policy_length": "Minimum parola uzunluğu %d'dir",
+ "password_policy_lowerupper": "Küçük ve büyük harf karakterleri içermelidir",
+ "password_policy_numbers": "En az bir sayı içermelidir",
+ "password_policy_special_chars": "Özel karakterler içermelidir",
+ "password_repeat": "Onay şifresi (tekrar)",
+ "priority": "Öncelik",
+ "private_key": "Özel anahtar",
+ "quarantine_bcc": "Tüm bildirimlerin bir kopyasını (BCC) bu alıcıya gönderin:<br><small>Devre dışı bırakmak için boş bırakın. <b>İmzasız, işaretlenmemiş posta. Yalnızca dahili olarak teslim edilmelidir.</b></small>",
+ "quarantine_exclude_domains": "Alan adlarını ve diğer alan adlarını hariç tut",
+ "quarantine_max_age": "Gün cinsinden maksimum yaş<br><small>Değer 1 güne eşit veya daha büyük olmalıdır.</small>",
+ "quarantine_max_score": "Bir epostanın spam puanı bu değerden yüksekse bildirim at:<br><small>Varsayılan değer 9999,0</small>",
+ "quota_notifications_vars": "{{percent}}, kullanıcının mevcut kotasına eşittir<br>{{username}} posta kutusu adıdır",
+ "quarantine_max_size": "MiB cinsinden maksimum boyut (daha büyük öğeler atılır):<br><small>0 sınırsız olduğunu <b>değil</b> göstermez.</small>",
+ "quarantine_notification_html": "Bildirim e-posta şablonu:<br><small>Varsayılan şablonu geri yüklemek için boş bırakın.</small>",
+ "quarantine_notification_sender": "Bildirim e-postası gönderen",
+ "quarantine_notification_subject": "Bildirim e-postası konusu",
+ "quarantine_redirect": "<b>Tüm bildirimleri bu alıcıya yönlendir</b>:<br><small>Devre dışı bırakmak için boş bırakın. <b>İmzasız, kontrol edilmemiş posta. Yalnızca dahili olarak teslim edilmelidir.</b></small>",
+ "quarantine_release_format_att": "Ek olarak",
+ "quarantine_release_format_raw": "Değiştirilmemiş orijinal",
+ "quarantine_retention_size": "Posta kutusu başına tutma sayısı:<br><small>0, <b>etkin değil</b> anlamına gelir.</small>",
+ "quota_notification_html": "Bildirim e-posta şablonu:<br><small>Varsayılan şablonu geri yüklemek için boş bırakın.</small>",
+ "quota_notification_sender": "Bildirim e-postası gönderen",
+ "quota_notification_subject": "Bildirim e-postası konusu",
+ "quota_notifications": "Kota bildirimleri",
+ "quota_notifications_info": "Kota bildirimleri, kullanıcılara %80'i geçtiğinde ve %95'i geçtiğinde bir kez gönderilir.",
+ "queue_unban": "Kuyruk yasağını kaldır",
+ "r_active": "Aktif kısıtlamalar",
+ "r_inactive": "Pasif kısıtlamalar",
+ "r_info": "Etkin kısıtlamalar listesindeki grileştirilmiş/devre dışı bırakılmış öğeler, posta kutusu için geçerli kısıtlamalar olarak bilinmez ve taşınamaz. Bilinmeyen kısıtlamalar yine de görünüm sırasına göre ayarlanacaktır. <br>Onları değiştirebilmek için <code>inc/vars.local.inc.php</code> içine yeni öğeler ekleyebilirsiniz.",
+ "rate_name": "Puan adı",
+ "recipients": "Alıcılar",
+ "refresh": "Yenile",
+ "regen_api_key": "API anahtarını yeniden oluştur",
+ "regex_maps": "Regex haritaları",
+ "relay_from": "\"Kimden:\" adresi",
+ "relay_rcpt": "\"Kime:\" adresi",
+ "relay_run": "Test çalıştır",
+ "relayhosts": "Gönderene bağlı aktarımlar",
+ "relayhosts_hint": "Etki alanı yapılandırma iletişim kutusunda seçebilmek için gönderene bağlı aktarımları tanımlayın.<br>\nAktarım hizmeti her zaman \"smtp:\" şeklindedir ve bu nedenle teklif edildiğinde TLS'yi deneyecektir. Sarılmış TLS (SMTPS) desteklenmez. Kullanıcıların bireysel giden TLS politikası ayarı dikkate alınır.\n<br> Takma ad alanları da dahil olmak üzere seçili alan adlarını etkiler.",
+ "rspamd_global_filters_regex": "İsimleri amaçlarını açıklıyor. Tüm içerik, \"/pattern/options\" biçiminde geçerli normal ifade içermelidir (ör. <code>/.+@domain\\.tld/i</code>).<br>\n İlkel olmasına rağmen kontroller regex'in her satırında yürütülüyor, sözdizimini doğru okuyamazsa Rspamds işlevi bozulabilir.<br>\nRspamd değiştirildiğinde harita içeriğini okumaya çalışır. Sorun yaşarsanız, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">Rspamd'yi yeniden başlatın</a> bir haritanın yeniden yüklenmesini zorunlu kılmak için.<br>Kara listeye alınan öğeler karantinadan hariç tutulur.",
+ "transport_dest_format": "Regex veya sözdizimi: example.org, .example.org, *, box@example.org (birden çok değer virgülle ayrılabilir)",
+ "transports_hint": "• Bir aktarım haritası girişi, gönderene bağlı bir aktarım haritasını <b>geçersiz kılar</b>.<br>\n• Tercihen MX tabanlı aktarımlar kullanılır.<br>\n• Kullanıcı başına giden TLS ilke ayarları yoksayılır ve yalnızca TLS ilke eşleme girişleri tarafından zorunlu kılınabilir.<br>\n• Tanımlanmış taşımalar için taşıma hizmeti her zaman \"smtp:\" şeklindedir ve bu nedenle teklif edildiğinde TLS'yi deneyecektir. Sarılmış TLS (SMTPS) desteklenmez.<br>\n• \"/localhost$/\" ile eşleşen adresler her zaman \"local:\" yoluyla taşınır, bu nedenle bu adresler için bir \"*\" hedefi uygulanmaz.<br>\n• Örnek bir sonraki sıçrama \"[host]:25\" için kimlik bilgilerini belirlemek için, Postfix <b>her zaman</b> \"[host]:25\" için arama yapmadan önce \"host\" için sorgular. Bu davranış, aynı anda \"host\" ve \"[host]:25\" kullanımını imkansız hale getirir.",
+ "search_domain_da": "Alan adlarını ara",
+ "send": "Gönder",
+ "rspamd_com_settings": "Bir ayar adı otomatik olarak oluşturulacaktır, lütfen aşağıdaki örnek ön ayarlara bakın. Daha fazla ayrıntı için <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd belgelerine</a> bakın",
+ "rspamd_global_filters": "Küresel filtre haritaları",
+ "rspamd_global_filters_agree": "Dikkatli olacağım!",
+ "ui_header_announcement_type_warning": "Önemli",
+ "rsetting_desc": "Kısa tanım",
+ "rsetting_no_selection": "Lütfen bir kural seçin",
+ "rsetting_none": "Kullanılabilir kural yok",
+ "rsettings_insert_preset": "Örnek hazır ayar ekle \"%s\"",
+ "rsettings_preset_1": "Kimliği doğrulanmış kullanıcılar için DKIM ve hız sınırı hariç tümünü devre dışı bırakın",
+ "rsettings_preset_2": "Posta yöneticileri spam istiyor",
+ "rsettings_preset_3": "Bir posta kutusu için yalnızca belirli gönderenlere izin ver (yani yalnızca dahili posta kutusu olarak kullanım)",
+ "rsettings_preset_4": "Bir etki alanı için Rspamd'yi devre dışı bırakın",
+ "rspamd_global_filters_info": "Küresel filtre haritaları, farklı türde küresel kara ve beyaz listeler içerir.",
+ "rspamd_settings_map": "Rspamd ayarları haritası",
+ "sal_level": "Moo seviye",
+ "save": "Değişiklikleri kaydet",
+ "sender": "Gönderen",
+ "service": "Servis",
+ "service_id": "Servis ID",
+ "source": "Kaynak",
+ "spamfilter": "Spam filtresi",
+ "subject": "Konu",
+ "success": "Başarılı",
+ "sys_mails": "Sistem postaları",
+ "text": "Metin",
+ "time": "Zaman",
+ "title": "Başlık",
+ "title_name": "\"mailcow UI\" web sitesi başlığı",
+ "to_top": "Başa dön",
+ "transport_maps": "Ulaşım Haritaları",
+ "transport_test_rcpt_info": "• Yabancı bir hedefe geçişi test etmek için null@hosted.mailcow.de adresini kullanın.",
+ "ui_footer": "Altbilgi (HTML'ye izin verilir)",
+ "ui_header_announcement": "Duyurular",
+ "ui_header_announcement_active": "Duyuruyu etkin olarak ayarla",
+ "ui_header_announcement_content": "Metin (HTML'ye izin verilir)",
+ "ui_header_announcement_help": "Duyuru, oturum açmış tüm kullanıcılar tarafından ve kullanıcı arayüzünün oturum açma ekranında görülebilir.",
+ "ui_header_announcement_select": "Duyuru türünü seçin",
+ "ui_header_announcement_type_danger": "Çok önemli",
+ "ui_header_announcement_type_info": "Bilgi",
+ "ui_texts": "UI etiketleri ve metinleri",
+ "unban_pending": "Beklemede olan yasağı kaldır",
+ "unchanged_if_empty": "Değişmediyse boş bırakın",
+ "upload": "Yükle",
+ "username": "Kullanıcı adı",
+ "validate_license_now": "GUID'yi lisans sunucusuna göre doğrulayın",
+ "verify": "Doğrulayın",
+ "yes": "✓",
+ "ui_header_announcement_type": "Türü",
+ "remove": "Kaldır",
+ "remove_row": "Satırı kaldır",
+ "reset_default": "Öntanımlı değerlere dön",
+ "reset_limit": "Hashi kaldır",
+ "routing": "Yönlendirme",
+ "rsetting_add_rule": "Kural ekle",
+ "rsetting_content": "Kural içeriği",
+ "password_reset_info": "Herhangi bir kurtarma e-postası sağlanmamışsa, bu işlev kullanılamaz.",
+ "restore_template": "Varsayılan şablonu geri yüklemek için boş bırakın.",
+ "password_reset_settings": "Parola Kurtarma Ayarları",
+ "password_reset_tmpl_html": "HTML Şablonu",
+ "password_reset_tmpl_text": "Metin Şablonu",
+ "password_settings": "Şifre Ayarları"
},
"warning": {
"cannot_delete_self": "Cannot delete logged in user",
@@ -147,5 +371,942 @@
"quota_exceeded_scope": "Domain kotası aşıldı: Bu domain kapsamında yalnızca sınırsız e-posta oluşturulabilir!",
"session_token": "Form token geçersiz: Token uyuşmadı",
"session_ua": "Form token geçersiz: User-Agent doğrulama hatası"
+ },
+ "datatables": {
+ "decimal": ".",
+ "info": "TOPLAM_ girişlerin _BAŞLANGIÇ_ ile _SON_ arası gösteriliyor",
+ "paginate": {
+ "first": "İlk",
+ "last": "Son",
+ "next": "Sonraki",
+ "previous": "Önceki"
+ },
+ "aria": {
+ "sortAscending": ": sütunu artan sıralama için etkinleştir",
+ "sortDescending": ": sütunu azalan şekilde sıralama için etkinleştirin"
+ },
+ "thousands": ",",
+ "collapse_all": "Tümünü Daralt",
+ "emptyTable": "Tabloda veri mevcut değil",
+ "expand_all": "Tümünü Genişlet",
+ "infoEmpty": "0 girişten 0 ila 0 arası gösteriliyor",
+ "infoFiltered": "(_MAX_ toplam girişlerden filtrelendi)",
+ "lengthMenu": "_MENU_ girişlerini göster",
+ "loadingRecords": "Yükleniyor...",
+ "processing": "Lütfen bekleyin...",
+ "search": "Ara:",
+ "zeroRecords": "Eşleşen kayıt bulunamadı"
+ },
+ "edit": {
+ "inactive": "Pasif",
+ "mailbox": "Posta kutusunu düzenle",
+ "mailbox_quota_def": "Varsayılan posta kutusu kotası",
+ "mailbox_relayhost_info": "Yalnızca posta kutusuna ve doğrudan takma adlara uygulanır, etki alanı geçiş ana bilgisayarını geçersiz kılar.",
+ "max_aliases": "Maks. takma adlar",
+ "max_mailboxes": "Maks. olası posta kutuları",
+ "max_quota": "Maks. posta kutusu başına kota (MiB)",
+ "extended_sender_acl_info": "Varsa, bir DKIM etki alanı anahtarı içe aktarılmalıdır.<br>\\r\\n Bu sunucuyu karşılık gelen SPF TXT kaydına eklemeyi unutmayın.<br>\\r\\n Bu sunucuya bir etki alanı veya takma ad etki alanı eklendiğinde, harici bir adresle çakışırsa, harici adres kaldırılır.<br>\\r\\n *@domain.tld olarak göndermeye izin vermek için @domain.tld kullanın.",
+ "footer_exclude": "Footerdan hariç tut",
+ "last_modified": "Son değişiklik",
+ "lookup_mx": "Hedef, MX adıyla eşleşecek normal bir ifadedir (google.com ile biten bir MX'e hedeflenen tüm postaları bu atlama üzerinden yönlendirmek için <code>.*google\\\\.com</code>)",
+ "sogo_access_info": "Posta kullanıcı arayüzünden tek oturum açma çalışmaya devam eder. Bu ayar, diğer tüm hizmetlere erişimi etkilemez veya bir kullanıcının mevcut SOGo profilini silmez veya değiştirmez.",
+ "comment_info": "Gizli bir yorum kullanıcı tarafından görülmezken, genel bir yorum, kullanıcının genel bakışında üzerine gelindiğinde araç ipucu olarak gösterilir.",
+ "sender_acl_info": "Posta kutusu A kullanıcısının posta kutusu kullanıcısı B olarak göndermesine izin veriliyorsa, gönderen adresi SOGo'da seçilebilir \\\"gönderen\\\" alanı olarak otomatik olarak görüntülenmez.<br>\\r\\n Posta kutusu B kullanıcısının izin vermesi için SOGo'da bir yetkilendirme oluşturması gerekir. posta kutusu kullanıcısı A, adresini gönderen olarak seçmek için. SOGo'da bir posta kutusuna yetki vermek için, posta görünümündeyken sol üstteki posta kutusu adınızın sağındaki menüyü (üç nokta) kullanın. Bu davranış, diğer ad adresleri için geçerli değildir.",
+ "sogo_visible_info": "Bu seçenek yalnızca SOGo'da görüntülenebilen nesneleri etkiler (en az bir yerel posta kutusuna işaret eden paylaşılan veya paylaşılmayan diğer ad adresleri). Gizliyse, bir takma ad SOGo'da seçilebilir gönderici olarak görünmez.",
+ "kind": "Nitelik",
+ "maxage": "Uzaktan sorgulanacak mesajların gün cinsinden maksimum ileti yaşı<br><small>(0 = yaşı yoksay)</small>",
+ "maxbytespersecond": "Maks. saniye başına bayt <br><small>(0 = sınırsız)</small>",
+ "redirect_uri": "Yönlendirme URI'i",
+ "relay_all": "Tüm alıcıları aktar",
+ "domain_footer_skip_replies": "Yanıt postasındaki altbilgiyi yoksay",
+ "exclude": "Nesneleri hariç tut (normal ifade)",
+ "extended_sender_acl": "Harici gönderen adresleri",
+ "force_pw_update": "Bir sonraki girişte şifre güncellemesini zorla",
+ "password": "Şifre",
+ "password_repeat": "Onay şifresi (tekrar)",
+ "private_comment": "Özel yorum",
+ "public_comment": "Genel yorum",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Yüksek öncelikli postayı iletin [<code>X-Priority: 1</code>]",
+ "pushover_info": "Anında iletme bildirimi ayarları, takma adlar (paylaşılan, paylaşılmayan, etiketli) dahil <b>%s</b> adresine teslim edilen tüm temiz (spam olmayan) postalara uygulanacaktır.",
+ "pushover_sender_array": "Yalnızca aşağıdaki gönderen e-posta adreslerini göz önünde bulundurun <small>(virgülle ayrılmış)</small>",
+ "scope": "Kapsam",
+ "skipcrossduplicates": "Klasörler arasında yinelenen mesajları atlayın (ilk gelen, ilk hizmet)",
+ "sogo_visible": "Takma ad SOGo'da görünür",
+ "relay_unknown_only": "Yalnızca var olmayan posta kutularını aktarın. Mevcut posta kutuları yerel olarak teslim edilecektir.",
+ "relayhost": "Göndericiye bağlı aktarımlar",
+ "remove": "Kaldır",
+ "resource": "Kaynak",
+ "save": "Değişiklikleri Kaydet",
+ "spam_policy": "Beyaz/kara listeye öğe ekleyin veya kaldırın",
+ "spam_score": "Özel bir spam puanı ayarlayın",
+ "subfolder2": "Hedefteki alt klasörle senkronize et<br><small>(boş = alt klasörü kullanmayın)</small>",
+ "syncjob": "Senkronizasyon işini düzenle",
+ "target_address": "Adrese git <small>(virgülle ayrılmış)</small>",
+ "target_domain": "Hedef alan",
+ "timeout1": "Uzak ana bilgisayara bağlantı için zaman aşımı",
+ "timeout2": "Yerel ana bilgisayara bağlantı için zaman aşımı",
+ "unchanged_if_empty": "Değişmediyse boş bırakın",
+ "username": "Kullanıcı adı",
+ "validate_save": "Doğrula ve kaydet",
+ "acl": "ACL (İzin)",
+ "active": "Aktif",
+ "admin": "Yöneticiyi düzenle",
+ "advanced_settings": "Gelişmiş ayarlar",
+ "alias": "Takma adı düzenle",
+ "generate": "oluştur",
+ "previous": "Önceki sayfa",
+ "domain_footer_info_vars": {
+ "from_addr": "Mail adresindeki adres kısmını verir",
+ "from_domain": "Mail adresindeki alan adını verir",
+ "custom": "Posta kutusu \\\"foo\\\" özelliğine ve \\\"bar\\\" değerine sahipse, \\\"bar\\\" döndürür\"",
+ "from_name": "Mail adresindeki gönderen alanını verir. Örn: Bilgi islem bilgiislem@canakkale.bel.tr nin Bilgi islem kısmını verir.",
+ "auth_user": "MTA tarafından belirtilen doğrulanmış kullanıcı adı",
+ "from_user": "Mail adresindeki kullanıcı adını alanını verir. Örn: bilgiislem@canakkale.bel.tr nin bilgiislem kısmını verir."
+ },
+ "custom_attributes": "Kullanıcı tanımlı özellikler",
+ "delete_ays": "Lütfen silme işlemini onaylayın.",
+ "description": "Açıklama",
+ "pushover_only_x_prio": "Yalnızca yüksek öncelikli postayı dikkate alın [<code>X-Priority: 1</code>]",
+ "delete2duplicates": "Hedefteki kopyaları sil",
+ "domain_footer": "Domain footer",
+ "domain_footer_html": "HTML footer",
+ "edit_alias_domain": "Takma ad alanını düzenle",
+ "encryption": "Şifreleme",
+ "domain_footer_info": "Bu alan adındaki bir adresle ilişkili tüm giden e-postalara domain-wide footer eklenir. Footer için aşağıdaki değişkenler kullanılabilir :",
+ "domains": "Alan adları",
+ "dont_check_sender_acl": "%s etki alanı için gönderen kontrolünü devre dışı bırakın (+ takma ad etki alanları)",
+ "sieve_desc": "Kısa tanım",
+ "sieve_type": "Filtre türü",
+ "sender_acl": "olarak göndermeye izin ver",
+ "sender_acl_disabled": "<span class=\\\"label label-danger\\\">Gönderen denetimi devre dışı</span>",
+ "allow_from_smtp": "Yalnızca bu IP'lerin <b>SMTP</b> kullanmasına izin verin",
+ "allow_from_smtp_info": "Tüm gönderenlere izin vermek için boş bırakın.<br>IPv4/IPv6 adresleri ve ağları.",
+ "allowed_protocols": "Doğrudan kullanıcı erişimi için izin verilen protokoller (uygulama parola protokollerini etkilemez)",
+ "app_name": "Uygulama adı",
+ "app_passwd": "Uygulama şifresi",
+ "app_passwd_protocols": "Uygulama şifresi için izin verilen protokoller",
+ "automap": "Klasörleri otomatik eşlemeyi deneyin (\\\"Gönderilmiş öğeler\\\", \\\"Gönderildi\\\" => \\\"Gönderildi\\\" vb.)",
+ "backup_mx_options": "Relay seçenekleri",
+ "bcc_dest_format": "BCC, tek bir geçerli e-posta adresi olmalıdır.<br>Bir kopyayı birden fazla adrese göndermeniz gerekiyorsa, bir takma ad oluşturun ve burada kullanın.",
+ "client_id": "Müşteri Kimliği",
+ "client_secret": "Müşteri sırrı",
+ "created_on": "Oluşturuldu",
+ "delete1": "Tamamlandığında kaynaktan silin",
+ "delete2": "Kaynakta olmayan hedefteki mesajları sil",
+ "domain_footer_plain": "PLAIN footer",
+ "multiple_bookings": "Çoklu rezervasyon",
+ "none_inherit": "Yok / Miras",
+ "nexthop": "Sonraki atlama",
+ "pushover_sender_regex": "Aşağıdaki gönderen regexini göz önünde bulundurun",
+ "pushover_text": "Bildirim metni",
+ "force_pw_update_info": "Bu kullanıcı yalnızca %s'de oturum açabilecek. Uygulama şifreleri kullanılabilir durumda kalır.",
+ "full_name": "Ad Soyad",
+ "gal": "Genel Adres Listesi",
+ "gal_info": "GAL, bir etki alanının tüm nesnelerini içerir ve herhangi bir kullanıcı tarafından düzenlenemez. Devre dışı bırakılmışsa, SOGo'da serbest/meşgul bilgisi eksik! <b>Değişiklikleri uygulamak için SOGo'yu yeniden başlatın.</b>",
+ "grant_types": "Yetki türleri",
+ "hostname": "Ana bilgisayar adı",
+ "mbox_rl_info": "Bu hız sınırı SASL oturum açma adına uygulanır, oturum açmış kullanıcı tarafından kullanılan herhangi bir \\\"gönderen\\\" adresiyle eşleşir. Posta kutusu hız sınırı, alan genelindeki hız sınırını geçersiz kılar.",
+ "mins_interval": "Aralık(dakika)",
+ "pushover_title": "Bildirim başlığı",
+ "pushover_sound": "Ses",
+ "pushover_vars": "Gönderici filtresi tanımlanmadığında, tüm postalar dikkate alınacaktır.<br>Regex filtreleri ve tam gönderen kontrolleri ayrı ayrı tanımlanabilir ve sıralı olarak değerlendirilecektir. Birbirlerine bağlı değildirler.<br>Metin ve başlık için kullanılabilir değişkenler (lütfen veri koruma politikalarını dikkate alın)",
+ "pushover_verify": "Kimlik bilgilerini doğrulayın",
+ "quota_warning_bcc": "Kota uyarısı BCC",
+ "quota_warning_bcc_info": "Uyarılar, aşağıdaki alıcılara ayrı kopyalar halinde gönderilecektir. Konunun sonuna parantez içinde karşılık gelen kullanıcı adı eklenecektir, örneğin: <code>Kota uyarısı (user@example.com)</code>.",
+ "ratelimit": "Hız sınırı",
+ "relay_all_info": "↪ Tüm alıcıları geçirmek için <b>değil</b> seçerseniz, aktarılması gereken her alıcı için bir (\\\"kör\\\") posta kutusu eklemeniz gerekir.",
+ "relay_domain": "Bu etki alanını aktar",
+ "relay_transport_info": "<div class=\\\"label label-info\\\">Bilgi</div> Bu etki alanı için özel bir hedef için taşıma haritaları tanımlayabilirsiniz. Ayarlanmazsa, bir MX araması yapılır.",
+ "sogo_access": "SOGo'ya doğrudan giriş erişimi verin",
+ "spam_alias": "Zaman sınırlı takma ad adresleri oluşturun veya değiştirin",
+ "spam_filter": "Spam filtresi",
+ "disable_login": "Oturum açmaya izin verme (gelen posta hala kabul edilir)",
+ "domain": "Etki alanını düzenle",
+ "domain_admin": "Etki alanı yöneticisini düzenle",
+ "domain_quota": "Etki alanı kotası",
+ "quota_mb": "Kota (MiB)",
+ "title": "Nesneyi düzenle"
+ },
+ "diagnostics": {
+ "dns_records_docs": "Lütfen ayrıca <a target=\\\"_blank\\\" href=\\\"https://mailcow.github.io/mailcow-dockerized-docs/precondition/precondition-dns/\\\">belgelere</a> bakın.",
+ "cname_from_a": "A/AAAA kaydından elde edilen değer. Bu, kayıt doğru kaynağa işaret ettiği sürece desteklenir.",
+ "dns_records_24hours": "DNS'de yapılan değişikliklerin mevcut durumlarının bu sayfaya doğru bir şekilde yansıtılmasının 24 saat kadar sürebileceğini lütfen unutmayın. DNS kayıtlarınızı nasıl yapılandıracağınızı kolayca görebilmeniz ve tüm kayıtlarınızın DNS'de doğru şekilde depolanıp depolanmadığını kontrol edebilmeniz için tasarlanmıştır.",
+ "optional": "Bu kayıt isteğe bağlıdır.",
+ "dns_records_data": "Doğru veri",
+ "dns_records_name": "İsim",
+ "dns_records_status": "Mevcut Durum",
+ "dns_records_type": "Tür",
+ "dns_records": "DNS Kayıtları"
+ },
+ "danger": {
+ "is_alias_or_mailbox": "%s zaten takma ad, posta kutusu veya takma ad etki alanından genişletilmiş bir takma ad adresi olarak biliniyor.",
+ "pushover_credentials_missing": "Pushover belirteci ve / veya anahtarı eksik",
+ "quota_not_0_not_numeric": "Kota sayısal ve >= 0 olmalıdır",
+ "extended_sender_acl_denied": "harici gönderen adreslerini ayarlamak için eksik ACL",
+ "invalid_destination": "Hedef biçimi \\\"%s\\\" geçersiz",
+ "mailbox_quota_left_exceeded": "Yeterli alan kalmadı (boş alan: %d MiB)",
+ "value_missing": "Lütfen tüm değerleri sağlayın",
+ "img_dimensions_exceeded": "Görüntü maksimum resim boyutunu aşıyor",
+ "max_quota_in_use": "Posta kutusu kotası %d MiB'den büyük veya buna eşit olmalıdır",
+ "object_exists": "%s nesnesi zaten var",
+ "webauthn_verification_failed": "WebAuthn doğrulaması başarısız oldu: %s",
+ "invalid_nexthop_authenticated": "Sonraki atlama, farklı kimlik bilgileriyle var, lütfen önce bu sonraki atlama için mevcut kimlik bilgilerini güncelleyin.",
+ "alias_domain_invalid": "%s takma ad alanı geçersiz",
+ "aliases_in_use": "Maks. takma adlar %d'den büyük veya eşit olmalıdır",
+ "app_name_empty": "Uygulama adı boş olamaz",
+ "app_passwd_id_invalid": "Uygulama şifresi kimliği %s geçersiz",
+ "bcc_empty": "BCC hedefi boş olamaz",
+ "alias_empty": "Takma ad adresi boş bırakılamaz",
+ "alias_goto_identical": "Takma ad ve varış adresi aynı olmamalıdır",
+ "alias_invalid": "%s takma ad adresi geçersiz",
+ "aliasd_targetd_identical": "Takma ad etki alanı, hedef etki alanına eşit olmamalıdır: %s",
+ "cors_invalid_method": "Geçersiz Allow-Method belirtildi",
+ "cors_invalid_origin": "Geçersiz Allow-Origin belirtildi",
+ "defquota_empty": "Posta kutusu başına varsayılan kota 0 olmamalıdır.",
+ "from_invalid": "Gönderen boş olmamalıdır",
+ "global_filter_write_error": "Filtre dosyası yazılamadı: %s",
+ "global_map_invalid": "Küresel harita kimliği %s geçersiz",
+ "maxquota_empty": "Maks. posta kutusu başına kota 0 olmamalıdır.",
+ "mysql_error": "MySQL hatası: %s",
+ "webauthn_authenticator_failed": "Seçilen kimlik doğrulayıcı bulunamadı.",
+ "webauthn_publickey_failed": "Seçilen kimlik doğrulayıcı için ortak anahtar saklanmadı",
+ "webauthn_username_failed": "Seçilen kimlik doğrulayıcı başka bir hesaba ait",
+ "global_map_write_error": "%s global harita kimliği yazılamadı: %s",
+ "access_denied": "Erişim reddedildi veya geçersiz form verisi",
+ "bcc_exists": "%s türü için %s BCC haritası var",
+ "bcc_must_be_email": "BCC %s geçerli bir e-posta adresi değil",
+ "comment_too_long": "Yorum çok uzun, maksimum 160 karaktere izin verilir",
+ "demo_mode_enabled": "Demo Mod açık",
+ "description_invalid": "%s için kaynak açıklaması geçersiz",
+ "dkim_domain_or_sel_exists": "\\\"%s\\\" için bir DKIM anahtarı var ve üzerine yazılmayacak",
+ "dkim_domain_or_sel_invalid": "DKIM etki alanı veya seçici geçersiz: %s",
+ "domain_cannot_match_hostname": "Alan, ana bilgisayar adıyla eşleşemez",
+ "domain_exists": "%s alanı zaten var",
+ "domain_invalid": "Alan adı boş veya geçersiz",
+ "domain_not_empty": "Boş olmayan alan adı %s kaldırılamıyor",
+ "domain_not_found": "%s alanı bulunamadı",
+ "domain_quota_m_in_use": "Etki alanı kotası %s MiB'den büyük veya buna eşit olmalıdır",
+ "extra_acl_invalid": "Harici gönderen adresi \\\"%s\\\" geçersiz",
+ "extra_acl_invalid_domain": "Harici gönderici \\\"%s\\\" geçersiz bir etki alanı kullanıyor",
+ "fido2_verification_failed": "FIDO2 doğrulaması başarısız oldu: %s",
+ "file_open_error": "Dosya yazmak için açılamıyor",
+ "filter_type": "Yanlış filtre türü",
+ "goto_empty": "Bir takma ad adresi, en az bir geçerli git adresi içermelidir",
+ "goto_invalid": "%s adresine git geçersiz",
+ "ham_learn_error": "Öğrenme hatası: %s",
+ "imagick_exception": "Hata: Görüntü okunurken Imagick istisnası",
+ "img_invalid": "Resim dosyası doğrulanamıyor",
+ "img_tmp_missing": "Resim dosyası doğrulanamıyor: Geçici dosya bulunamadı",
+ "password_complexity": "Şifre politikaya uygun değil",
+ "policy_list_from_exists": "Verilen ada sahip bir kayıt var",
+ "img_size_exceeded": "Görüntü maksimum dosya boyutunu aşıyor",
+ "invalid_bcc_map_type": "Geçersiz BCC harita türü",
+ "invalid_filter_type": "Geçersiz filtre türü",
+ "invalid_host": "Geçersiz ana bilgisayar belirtildi: %s",
+ "invalid_mime_type": "Geçersiz mime türü",
+ "invalid_nexthop": "Sonraki atlama biçimi geçersiz",
+ "invalid_recipient_map_new": "Geçersiz yeni alıcı belirtildi: %s",
+ "invalid_recipient_map_old": "Geçersiz orijinal alıcı belirtildi: %s",
+ "ip_list_empty": "İzin verilen IP'lerin listesi boş olamaz",
+ "is_alias": "%s zaten bir takma ad adresi olarak biliniyor",
+ "is_spam_alias": "%s zaten geçici bir takma ad adresi olarak biliniyor (spam takma ad adresi)",
+ "last_key": "Son anahtar silinemez, lütfen bunun yerine TFA'yı devre dışı bırakın.",
+ "login_failed": "Giriş başarısız",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "Varsayılan kota, maksimum kota sınırını aşıyor",
+ "mailbox_invalid": "Posta kutusu adı geçersiz",
+ "mailbox_quota_exceeded": "Kota, alan sınırını aşıyor (maks. %d MiB)",
+ "mailbox_quota_exceeds_domain_quota": "Maks. kota, alan kota sınırını aşıyor",
+ "mailboxes_in_use": "Maks. posta kutuları %d'den büyük veya eşit olmalıdır",
+ "malformed_username": "Hatalı biçimlendirilmiş kullanıcı adı",
+ "map_content_empty": "Harita içeriği boş olamaz",
+ "max_alias_exceeded": "Maks. takma adlar aşıldı",
+ "max_mailbox_exceeded": "Maks. posta kutuları aşıldı (%d / %d)",
+ "network_host_invalid": "Geçersiz ağ veya ana bilgisayar: %s",
+ "next_hop_interferes": "%s, nexthop %s ile çakışıyor",
+ "next_hop_interferes_any": "Mevcut bir sonraki atlama %s ile çakışıyor",
+ "nginx_reload_failed": "Nginx yeniden yükleme başarısız oldu: %s",
+ "no_user_defined": "Kullanıcı tanımlı değil",
+ "object_is_not_numeric": "%s değeri sayısal değil",
+ "password_empty": "Şifre boş olmamalıdır",
+ "password_mismatch": "Onay şifresi eşleşmiyor",
+ "policy_list_from_invalid": "Kayıt geçersiz biçime sahip",
+ "private_key_error": "Özel anahtar hatası: %s",
+ "pushover_key": "Pushover anahtarı yanlış formatta",
+ "pushover_token": "Pushover token yanlış formatta",
+ "recipient_map_entry_exists": "Alıcı haritası girişi \\\"%s\\\" var",
+ "redis_error": "Redis hatası: %s",
+ "relayhost_invalid": "%s harita girişi geçersiz",
+ "template_exists": "%s isimli şablon zaten mevcut",
+ "template_id_invalid": "Şablon kimliği %s geçersiz",
+ "text_empty": "Metin boş olmamalıdır",
+ "unknown": "Bilinmeyen bir hata oluştu",
+ "unknown_tfa_method": "Bilinmeyen TFA yöntemi",
+ "unlimited_quota_acl": "ACL tarafından yasaklanan sınırsız kota",
+ "username_invalid": "Kullanıcı adı %s kullanılamaz",
+ "validity_missing": "Lütfen bir geçerlilik süresi atayın",
+ "yotp_verification_failed": "Yubico OTP doğrulaması başarısız oldu: %s",
+ "rspamd_ui_pw_length": "Rspamd UI şifresi en az 6 karakter uzunluğunda olmalıdır",
+ "tfa_token_invalid": "Hatalı TFA belirteci",
+ "release_send_failed": "Mesaj bırakılamadı: %s",
+ "reset_f2b_regex": "Regex filtresi zamanında sıfırlanamadı, lütfen tekrar deneyin veya birkaç saniye daha bekleyin ve web sitesini yeniden yükleyin.",
+ "resource_invalid": "%s kaynak adı geçersiz",
+ "rl_timeframe": "Hız sınırı zaman çerçevesi yanlış",
+ "script_empty": "Komut dosyası boş olamaz",
+ "sender_acl_invalid": "Gönderen ACL değeri %s geçersiz",
+ "set_acl_failed": "ACL ayarlanamadı",
+ "settings_map_invalid": "Ayarlar haritası kimliği %s geçersiz",
+ "sieve_error": "Elek ayrıştırıcı hatası: %s",
+ "spam_learn_error": "Spam öğrenme hatası: %s",
+ "subject_empty": "Konu boş olmamalıdır",
+ "target_domain_invalid": "Hedef alan %s geçersiz",
+ "targetd_not_found": "Hedef alan %s bulunamadı",
+ "targetd_relay_domain": "Hedef etki alanı %s bir geçiş etki alanıdır",
+ "template_name_invalid": "Şablon adı geçersiz",
+ "temp_error": "Geçici hata",
+ "tls_policy_map_dest_invalid": "Politika hedefi geçersiz",
+ "tls_policy_map_entry_exists": "Bir TLS ilke haritası girişi \\\"%s\\\" mevcut",
+ "tls_policy_map_parameter_invalid": "Politika parametresi geçersiz",
+ "totp_verification_failed": "TOTP doğrulaması başarısız oldu",
+ "transport_dest_exists": "\\\"%s\\\" aktarım hedefi mevcut",
+ "password_reset_invalid_user": "Posta kutusu bulunamadı veya kurtarma e-postası ayarlanmadı",
+ "invalid_reset_token": "Geçersiz sıfırlama token'ı"
+ },
+ "debug": {
+ "container_disabled": "Container durduruldu veya devre dışı bırakıldı",
+ "last_modified": "Son değişiklik",
+ "log_info": "<p>mailcow <b>bellek içi günlükler</b>, Redis listelerinde toplanır ve çekiçlemeyi azaltmak için her dakika LOG_LINES (%d) olacak şekilde kırpılır.\\r\\n <br>Bellek içi günlükler ısrarcı. Bellekte oturum açan tüm uygulamalar, ayrıca Docker arka plan programında ve dolayısıyla varsayılan günlük sürücüsünde oturum açar.\\r\\n <br>Bellek içi günlük türü, kapsayıcılarla ilgili küçük sorunları ayıklamak için kullanılmalıdır.</p>\\r\\n <p><b>Harici günlükler</b>, verilen uygulamanın API'si aracılığıyla toplanır.</p>\\r\\n <p><b>Statik günlükler</b> çoğunlukla etkinlik günlükleridir. Dockerd'da günlüğe kaydedilmez ancak yine de kalıcı olmaları gerekir (API günlükleri hariç).</p>",
+ "architecture": "Mimari",
+ "chart_this_server": "Grafik (bu sunucu)",
+ "containers_info": "Kapsayıcı bilgileri",
+ "container_running": "Çalıştırılıyor...",
+ "login_time": "Zaman",
+ "logs": "Loglar",
+ "static_logs": "Statik günlükler",
+ "success": "Başarılı",
+ "started_on": "Başladı",
+ "update_available": "Mevcut bir güncelleme var",
+ "container_stopped": "Durduruldu",
+ "cores": "Çekirdekler",
+ "current_time": "Sistem Zamanı",
+ "disk_usage": "Disk kullanımı",
+ "error_show_ip": "Genel IP adresleri çözümlenemedi.",
+ "external_logs": "Harici günlükler",
+ "history_all_servers": "Geçmiş (tüm sunucular)",
+ "in_memory_logs": "Bellek içi günlükler",
+ "memory": "Hafıza",
+ "online_users": "Aktif kullanıcılar",
+ "restart_container": "Yeniden başlat",
+ "service": "Servis",
+ "show_ip": "Genel IP'yi göster",
+ "size": "Boyut",
+ "started_at": "Başlangıç",
+ "system_containers": "Sistem ve Konteynerler",
+ "timezone": "Zaman Dilimi",
+ "uptime": "Çalışma Süresi",
+ "no_update_available": "Sistem en son sürümde",
+ "update_failed": "Güncelleme olup olmadığı kontrol edilemedi",
+ "username": "Kullanıcı Adı",
+ "wip": "Şu Anda Çalışma Devam Ediyor",
+ "docs": "Dokümanlar"
+ },
+ "mailbox": {
+ "domain_admins": "Etki alanı yöneticileri",
+ "insert_preset": "Örnek ön ayar \\\"%s\\\" ekle",
+ "mins_interval": "Aralık (dk)",
+ "bcc_info": "BCC haritaları, tüm mesajların kopyalarını başka bir adrese sessizce iletmek için kullanılır. Yerel hedef bir postanın alıcısı olarak hareket ettiğinde, bir alıcı eşleme türü girişi kullanılır. Gönderici haritaları aynı prensibe uygundur.<br/>\\r\\n Yerel hedef, başarısız bir teslimat hakkında bilgilendirilmez.",
+ "booking_custom": "Özel bir rezervasyon miktarıyla sabit sınırlama",
+ "force_pw_update": "Bir sonraki girişte parola güncellemesini zorunlu kıl",
+ "allow_from_smtp_info": "Tüm gönderenlere izin vermek için boş bırakın.<br>IPv4/IPv6 adresleri ve ağları.",
+ "tls_policy_maps_enforced_tls": "Bu ilkeler, giden TLS bağlantılarını zorlayan posta kutusu kullanıcılarının davranışını da geçersiz kılar. Aşağıda herhangi bir politika yoksa, bu kullanıcılar <code>smtp_tls_mandatory_protocols</code> ve <code>smtp_tls_mandatory_ciphers</code> olarak belirtilen varsayılan değerleri uygular.",
+ "tls_map_parameters_info": "Boş veya parametreler, örneğin: protokoller=!SSLv2 şifreleri=orta hariç tutma=3DES",
+ "recipient_map": "Alıcı haritası",
+ "sieve_info": "Kullanıcı başına birden fazla filtre saklayabilirsiniz, ancak aynı anda yalnızca bir ön filtre ve bir son filtre etkin olabilir.<br>\\r\\nHer filtre açıklanan sırayla işlenir. Ne başarısız bir komut dosyası ne de verilen bir \\\"keep;\\\", başka komut dosyalarının işlenmesini durdurmayacaktır. Global elek komut dosyalarında yapılan değişiklikler, Dovecot'un yeniden başlatılmasını tetikleyecektir.<br><br>Global elek ön filtresi • Ön filtre • Kullanıcı komut dosyaları • Son filtre • Küresel elek son filtresi",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Kimlik doğrulama sorunu",
+ "tls_enforce_in": "TLS gelenini uygula",
+ "tls_policy_maps_info": "Bu politika haritası, bir kullanıcının TLS politika ayarlarından bağımsız olarak giden TLS aktarım kurallarını geçersiz kılar.<br>\\r\\n Lütfen <a href=\\\"http://www.postfix.org/postconf.5.html#smtp_tls_policy_maps\\\" adresini kontrol edin. daha fazla bilgi için target=\\\"_blank\\\">\\\"smtp_tls_policy_maps\\\" dokümanları</a>.",
+ "remove": "Kaldır",
+ "resources": "Kaynaklar",
+ "running": "Çalıştırılıyor...",
+ "sender": "Gönderen",
+ "set_postfilter": "Son filtre olarak işaretle",
+ "set_prefilter": "Ön filtre olarak işaretle",
+ "add_domain": "Alan adı ekle",
+ "action": "İşlem",
+ "activate": "Etkinleştir",
+ "active": "Aktif",
+ "add": "Ekle",
+ "add_alias": "Takma ad ekle",
+ "add_alias_expand": "Diğer adları diğer ad etki alanları üzerinde genişletin",
+ "add_tls_policy_map": "TLS politika haritası ekle",
+ "address_rewriting": "Adresi yeniden yaz",
+ "alias": "Takma ad",
+ "alias_domain_alias_hint": "Takma adlar, alan takma adlarına otomatik olarak <b>uygulanmaz</b>. Bir takma ad adresi <code>takma ad@etki alanım</code> <b>kapsamıyor</b> <code>takma ad@takma ad-domain</code> adresini (burada \\\"takma ad-domain\\\" \\\"domain\\\" için hayali bir takma addır.<br>Postaları harici bir posta kutusuna yönlendirmek için lütfen bir elek filtresi kullanın (\\\"Filtreler\\\" sekmesine bakın veya SOGo -> Yönlendiriciyi kullanın). Eksik takma adları otomatik olarak eklemek için \\\"Takma adı diğer ad alanları üzerinden genişlet\\\" seçeneğini kullanın.",
+ "booking_custom_short": "Kesin sınır",
+ "booking_ltnull": "Sınırsız, ancak rezervasyon yapıldığında meşgul olarak göster",
+ "catch_all": "Hepsini Yakala",
+ "created_on": "Oluşturuldu.",
+ "daily": "Günlük",
+ "deactivate": "Devre dışı bırak",
+ "mailbox": "Posta Kutusu",
+ "mailbox_defaults": "Varsayılan ayarlar",
+ "mailbox_defaults_info": "Yeni posta kutuları için varsayılan ayarları tanımlayın.",
+ "mailbox_defquota": "Varsayılan posta kutusu boyutu",
+ "mailbox_templates": "Mail Kutusu Şablonları",
+ "mailbox_quota": "Maks. posta kutusu boyutu",
+ "mailboxes": "Posta kutuları",
+ "public_comment": "Genel yorum",
+ "q_add_header": "önemsiz klasörüne taşındığında",
+ "q_all": " önemsiz klasörüne taşındığında ve reddedildiğinde",
+ "q_reject": "Red aşamasında",
+ "quarantine_category": "Karantina bildirim kategorisi",
+ "quarantine_notification": "Karantina bildirimleri",
+ "quick_actions": "İşlemler",
+ "stats": "İstatistikler",
+ "status": "Durum",
+ "tls_policy_maps_long": "Giden TLS politika haritası geçersiz kılmaları",
+ "toggle_all": "Tümünü değiştir",
+ "booking_lt0_short": "Esnek sınır",
+ "msg_num": "Mesaj #",
+ "spam_aliases": "Geçici takma ad",
+ "sieve_preset_2": "Her zaman belirli bir gönderenin e-postasını görüldüğü gibi işaretleyin",
+ "add_bcc_entry": "BCC haritası ekle",
+ "add_domain_alias": "Alan adı ekle",
+ "add_domain_record_first": "Lütfen önce bir alan adı ekleyin",
+ "add_filter": "Filtre ekle",
+ "add_mailbox": "Posta kutusu ekle",
+ "add_recipient_map_entry": "Alıcı haritası ekle",
+ "add_resource": "Kaynak ekle",
+ "add_template": "Şablon Ekle",
+ "alias_domain_backupmx": "Takma alan adı geçiş alanı için etkin değil",
+ "aliases": "Takma Adlar",
+ "all_domains": "Tüm Alan Adları",
+ "allow_from_smtp": "Yalnızca bu IP'lerin <b>SMTP</b> kullanmasına izin verin",
+ "allowed_protocols": "İzin verilen protokoller",
+ "backup_mx": "Geçiş alanı",
+ "bcc": "BCC",
+ "bcc_destination": "Gizli hedef",
+ "bcc_destinations": "Gizli hedef",
+ "bcc_local_dest": "Yerel hedef",
+ "bcc_map": "BCC haritası",
+ "bcc_map_type": "BCC türü",
+ "bcc_maps": "BCC haritaları",
+ "bcc_rcpt_map": "Alıcı haritası",
+ "bcc_sender_map": "Gönderen haritası",
+ "bcc_to_rcpt": "Alıcı harita türüne geç",
+ "bcc_to_sender": "Gönderici harita türüne geç",
+ "bcc_type": "BCC türü",
+ "booking_null": "Her zaman ücretsiz olarak göster",
+ "booking_0_short": "Her zaman ücretsiz",
+ "description": "Açıklama",
+ "disable_login": "Oturum açmaya izin verme (gelen posta hala kabul edilir)",
+ "disable_x": "Devre dışı bırak",
+ "dkim_domains_selector": "Seçici",
+ "dkim_key_length": "DKIM anahtar uzunluğu (bit)",
+ "domain": "Etki Alanı",
+ "domain_aliases": "Alan adı takma adları",
+ "domain_templates": "Etki Alanı Şablonları",
+ "domain_quota": "Kota",
+ "domain_quota_total": "Toplam alan kotası",
+ "domains": "Etki Alanları",
+ "edit": "Düzenle",
+ "empty": "Sonuç yok",
+ "enable_x": "Etkinleştir",
+ "excludes": "Hariç tutulanlar",
+ "filter_table": "Tabloyu filtrele",
+ "filters": "Filtreler",
+ "fname": "Tam adı",
+ "gal": "Genel Adres Listesi",
+ "goto_ham": "<b>ham</b> olarak öğrenin",
+ "goto_spam": "<b>spam</b> olarak öğrenin",
+ "hourly": "Saatlik",
+ "in_use": "Kullanılan (%)",
+ "inactive": "Pasif",
+ "kind": "Nitelik",
+ "last_mail_login": "Son posta girişi",
+ "last_modified": "Son değişiklik",
+ "last_pw_change": "Son şifre değişikliği",
+ "last_run": "Son çalıştırma",
+ "last_run_reset": "Sonrakini planla",
+ "max_aliases": "Max. kısayollar",
+ "max_mailboxes": "Max. mail kutuları",
+ "max_quota": "Mail kutusu başına max. kota",
+ "multiple_bookings": "Çoklu rezervasyonlar",
+ "never": "Hiçbir zaman",
+ "no": "✕",
+ "no_record": "%s nesnesi için kayıt yok",
+ "no_record_single": "Kayıt yok",
+ "open_logs": "Logları aç",
+ "owner": "Sahip",
+ "private_comment": "Özel yorum",
+ "recipient": "Alıcı",
+ "recipient_map_info": "Alıcı haritaları, teslim edilmeden önce bir mesajdaki hedef adresi değiştirmek için kullanılır.",
+ "recipient_map_new": "Yeni alıcı",
+ "recipient_map_old_info": "Bir alıcı eşleme orijinal hedefi, geçerli e-posta adresleri veya bir alan adı olmalıdır.",
+ "recipient_maps": "Alıcı haritaları",
+ "relay_all": "Tüm alıcıları ilet",
+ "relay_unknown": "Bilinmeyen posta kutularını aktar",
+ "sieve_preset_1": "Olası tehlikeli dosya türlerine sahip postaları atın",
+ "sieve_preset_3": "Sessizce atın, tüm diğer elek işlemlerini durdurun",
+ "sieve_preset_4": "INBOX'a dosyalayın, elek filtreleriyle daha fazla işlemi atlayın",
+ "sieve_preset_5": "Otomatik yanıtlayıcı (tatil)",
+ "sieve_preset_6": "Postayı reddedildi olarak yanıtla",
+ "sieve_preset_7": "Yönlendir ve sakla/bırak",
+ "sieve_preset_8": "Gönderenin parçası olduğu bir takma ad adresine gönderilen mesajı atın",
+ "sieve_preset_header": "Lütfen aşağıdaki örnek ön ayarlara bakın. Daha fazla ayrıntı için <a href=\\\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\\\" target=\\\"_blank\\\">Wikipedia</a>'ya bakın.",
+ "sogo_visible": "Takma ad SOGo'da görünür",
+ "sogo_visible_n": "SOGo'da takma adı gizle",
+ "sogo_visible_y": "SOGo'da takma adı göster",
+ "sync_jobs": "İşleri senkronize et",
+ "syncjob_check_log": "Günlüğü kontrol et",
+ "syncjob_last_run_result": "Son çalıştırma sonucu",
+ "syncjob_EX_OK": "Başarılı",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Bağlantı sorunu",
+ "syncjob_EXIT_TLS_FAILURE": "Şifreli bağlantıyla ilgili sorun",
+ "syncjob_EXIT_OVERQUOTA": "Hedef posta kutusu kotayı aştı",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Uzak sunucuya bağlanılamıyor",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Yanlış kullanıcı adı veya şifre",
+ "table_size": "Tablo boyutu",
+ "table_size_show_n": "%s öğeleri göster",
+ "target_address": "Adrese git",
+ "target_domain": "Hedef alan",
+ "templates": "Şablonlar",
+ "template": "Şablon",
+ "tls_enforce_out": "TLS gidenini uygula",
+ "tls_map_dest_info": "Örnekler: example.org, .example.org, [mail.example.org]:25",
+ "tls_map_policy": "Politika",
+ "tls_policy_maps": "TLS politika haritaları",
+ "username": "Kullanıcı Adı",
+ "waiting": "Bekliyor...",
+ "weekly": "Haftalık",
+ "yes": "OK",
+ "recipient_map_new_info": "Alıcı harita hedefi geçerli bir e-posta adresi olmalıdır.",
+ "recipient_map_old": "Orijinal alıcı",
+ "tls_map_dest": "Hedef",
+ "tls_map_parameters": "Parametreler"
+ },
+ "login": {
+ "mobileconfig_info": "İstenen Apple bağlantı profilini indirmek için lütfen posta kutusu kullanıcısı olarak oturum açın.",
+ "delayed": "Giriş %s saniye gecikti.",
+ "fido2_webauthn": "FIDO2/WebAuthn Giriş",
+ "login": "Giriş",
+ "password": "Şifre",
+ "username": "Kullanıcı Adı",
+ "other_logins": "veya ile giriş yap"
+ },
+ "success": {
+ "bcc_saved": "BCC harita girişi kaydedildi",
+ "item_deleted": "Öğe %s başarıyla silindi",
+ "verified_webauthn_login": "Doğrulanmış WebAuthn girişi",
+ "f2b_modified": "Fail2ban parametrelerinde yapılan değişiklikler kaydedildi",
+ "rl_saved": "Kaydedilen %s nesnesi için hız sınırı",
+ "alias_added": "Takma ad adresi %s (%d) eklendi",
+ "aliasd_modified": "%s takma ad etki alanında yapılan değişiklikler kaydedildi",
+ "global_filter_written": "Filtre dosyaya başarıyla yazıldı",
+ "dkim_removed": "DKIM anahtarı %s kaldırıldı",
+ "pushover_settings_edited": "Pushover ayarları başarıyla ayarlandı, lütfen kimlik bilgilerini doğrulayın.",
+ "verified_yotp_login": "Doğrulanmış Yubico OTP girişi",
+ "deleted_syncjobs": "Silinen senkronizasyon işleri: %s",
+ "sogo_profile_reset": "%s kullanıcısı için SOGo profili sıfırlandı",
+ "domain_admin_removed": "Alan yöneticisi %s kaldırıldı",
+ "domain_admin_modified": "Alan yöneticisi %s'de yapılan değişiklikler kaydedildi",
+ "domain_footer_modified": "Domain footer değişiklikleri %s kaydedildi",
+ "domain_removed": "%s etki alanı kaldırıldı",
+ "dovecot_restart_success": "Dovecot başarıyla yeniden başlatıldı",
+ "hash_deleted": "Hash silindi",
+ "items_deleted": "Öğe %s başarıyla silindi",
+ "items_released": "Seçilen öğeler yayınlandı.",
+ "learned_ham": "Kimlik %s jambon olarak başarıyla öğrenildi",
+ "license_modified": "Lisansta yapılan değişiklikler kaydedildi",
+ "logged_in_as": "%s olarak oturum açıldı",
+ "mailbox_added": "Posta kutusu %s eklendi",
+ "mailbox_modified": "%s posta kutusunda yapılan değişiklikler kaydedildi",
+ "mailbox_removed": "Posta kutusu %s kaldırıldı",
+ "nginx_reloaded": "Nginx yeniden yüklendi",
+ "object_modified": "%s nesnesindeki değişiklikler kaydedildi",
+ "reset_main_logo": "Varsayılan logoya sıfırla",
+ "saved_settings": "Kaydedilen ayarlar",
+ "eas_reset": "%s kullanıcısı için ActiveSync cihazları sıfırlandı",
+ "domain_added": "%s etki alanı eklendi",
+ "template_modified": "%s şablonuna değişiklikler işlendi",
+ "ui_texts": "Kullanıcı arayüzü metinlerinde yapılan değişiklikler kaydedildi",
+ "template_added": "%s şablonu eklendi",
+ "acl_saved": "%s nesnesi için ACL kaydedildi",
+ "admin_added": "%s yöneticisi eklendi",
+ "admin_api_modified": "API'deki değişiklikler kaydedildi",
+ "admin_modified": "Yönetici değişiklikleri kaydedildi",
+ "admin_removed": "%s yöneticisi kaldırıldı",
+ "alias_domain_removed": "Takma ad alan adı %s kaldırıldı",
+ "alias_modified": "%s takma ad adresindeki değişiklikler kaydedildi",
+ "alias_removed": "%s takma adı kaldırıldı",
+ "aliasd_added": "%s takma ad alanı eklendi",
+ "app_links": "Uygulama bağlantılarında yapılan değişiklikler kaydedildi",
+ "app_passwd_added": "Yeni uygulama şifresi eklendi",
+ "app_passwd_removed": "Kaldırılan uygulama parolası kimliği %s",
+ "bcc_deleted": "BCC harita girişleri silindi: %s",
+ "bcc_edited": "BCC harita girişi %s düzenlendi",
+ "cors_headers_edited": "CORS ayarları kaydedildi",
+ "db_init_complete": "Veritabanı başlatma işlemi tamamlandı",
+ "delete_filter": "Silinen filtre kimliği %s",
+ "delete_filters": "Silinen filtreler: %s",
+ "deleted_syncjob": "Syncjob kimliği %s silindi.",
+ "dkim_added": "DKIM anahtarı %s kaydedildi",
+ "domain_add_dkim_available": "Bir DKIM anahtarı zaten mevcuttu",
+ "dkim_duplicated": "%s etki alanı için DKIM anahtarı %s'ye kopyalandı",
+ "domain_admin_added": "Alan yöneticisi %s eklendi",
+ "domain_modified": "%s etki alanında yapılan değişiklikler kaydedildi",
+ "f2b_banlist_refreshed": "Banlist ID başarıyla yenilendi.",
+ "forwarding_host_added": "Yönlendirme ana bilgisayarı %s eklendi",
+ "forwarding_host_removed": "Yönlendirme ana bilgisayarı %s kaldırıldı",
+ "ip_check_opt_in_modified": "IP kontrolü başarıyla kaydedildi",
+ "item_released": "Öğe %s yayınlandı",
+ "password_policy_saved": "Parola politikası başarıyla kaydedildi",
+ "qlearn_spam": "Mesaj kimliği %s spam olarak öğrenildi ve silindi",
+ "queue_command_success": "Kuyruk komutu başarıyla tamamlandı",
+ "recipient_map_entry_deleted": "Alıcı harita kimliği %s silindi",
+ "recipient_map_entry_saved": "Alıcı harita girişi \\\"%s\\\" kaydedildi",
+ "relayhost_added": "%s harita girişi eklendi",
+ "relayhost_removed": "%s harita girişi kaldırıldı",
+ "resource_added": "Kaynak %s eklendi",
+ "resource_modified": "%s posta kutusunda yapılan değişiklikler kaydedildi",
+ "resource_removed": "Kaynak %s kaldırıldı",
+ "rspamd_ui_pw_set": "Rspamd UI parolası başarıyla ayarlandı",
+ "settings_map_added": "Ayarlar haritası girişi eklendi",
+ "settings_map_removed": "Kaldırılan ayarlar haritası kimliği %s",
+ "template_removed": "%s şablonu silindi",
+ "tls_policy_map_entry_deleted": "TLS politika haritası kimliği %s silindi",
+ "tls_policy_map_entry_saved": "TLS ilke haritası girişi \\\"%s\\\" kaydedildi",
+ "upload_success": "Dosya başarıyla yüklendi",
+ "verified_fido2_login": "Doğrulanmış FIDO2 girişi",
+ "verified_totp_login": "Doğrulanmış TOTP girişi"
+ },
+ "quarantine": {
+ "remove": "Kaldır",
+ "disabled_by_config": "Geçerli sistem yapılandırması, karantina işlevini devre dışı bırakır. Lütfen karantina öğeleri için \\\"posta kutusu başına tutma\\\" ve \\\"maksimum boyut\\\" ayarlayın.",
+ "qinfo": "Karantina sistemi, reddedilen postaları veritabanına (gönderene teslim edilmiş bir posta izlenimi verilmeyecek</em>) ve bir posta kutusunun Önemsiz klasörüne kopya olarak teslim edilen postayı kaydeder.\\r\\n <br>\\\"Spam olarak öğren ve sil\\\", Bayes teoremi aracılığıyla bir mesajı spam olarak öğrenecek ve ayrıca gelecekte benzer mesajları reddetmek için bulanık karmaları hesaplayacaktır.\\r\\n <br>Lütfen birden fazla öğrenmenin olduğunu unutmayın. iletiler - sisteminize bağlı olarak - zaman alabilir.<br>Kara listeye alınan öğeler karantinadan hariç tutulur.",
+ "sender_header": "Gönderen (\"Kimden\" başlığı)",
+ "table_size": "Tablo boyutu",
+ "confirm_delete": "Bu öğenin silinmesini onaylayın.",
+ "danger": "Tehlike",
+ "deliver_inbox": "Gelen kutusuna teslim et",
+ "download_eml": "İndir (.eml)",
+ "show_item": "Öğeyi göster",
+ "spam": "Spam",
+ "spam_score": "Skor",
+ "subj": "Konu",
+ "table_size_show_n": "%s öğeleri göster",
+ "text_from_html_content": "İçerik (dönüştürülmüş html)",
+ "text_plain_content": "İçerik (metin/düz)",
+ "toggle_all": "Hepsini aç/kapat",
+ "type": "Tür",
+ "qhandler_success": "İstek sisteme başarıyla gönderildi. Artık pencereyi kapatabilirsiniz.",
+ "recipients": "Alıcılar",
+ "refresh": "Yenile",
+ "received": "Alındı.",
+ "action": "İşlem",
+ "atts": "Ekler",
+ "check_hash": "Dosya hash @ VT ara",
+ "confirm": "Onayla",
+ "empty": "Sonuç Yok",
+ "high_danger": "Yüksek",
+ "info": "Bilgi",
+ "junk_folder": "Gereksiz klasör",
+ "learn_spam_delete": "Spam olarak öğren ve sil",
+ "low_danger": "Düşük",
+ "medium_danger": "Orta",
+ "neutral_danger": "Nötr",
+ "notified": "Bildirildi.",
+ "qid": "Rspamd QID",
+ "qitem": "Karantina öğesi",
+ "quarantine": "Karantina",
+ "quick_actions": "İşlemler",
+ "quick_delete_link": "Hızlı silme bağlantısını aç",
+ "quick_info_link": "Bilgi bağlantısını aç",
+ "quick_release_link": "Hızlı yayın bağlantısını aç",
+ "rcpt": "Alıcı",
+ "rejected": "Reddedildi.",
+ "release": "Serbest Bırak",
+ "release_body": "Mesajınızı eml dosyası olarak bu mesaja ekledik.",
+ "release_subject": "Potansiyel olarak zarar veren karantina öğesi %s",
+ "rewrite_subject": "Konuyu yeniden yaz",
+ "rspamd_result": "Rspamd sonucu",
+ "sender": "Gönderen (SMTP)",
+ "settings_info": "Karantinaya alınacak maksimum öğe miktarı: %s<br>Maksimum e-posta boyutu: %s MiB"
+ },
+ "tfa": {
+ "waiting_usb_register": "<i>USB cihazı bekleniyor...</i><br><br>Lütfen şifrenizi yukarıya girin ve USB cihazınızdaki düğmeye dokunarak kaydınızı onaylayın.",
+ "scan_qr_code": "Lütfen aşağıdaki kodu kimlik doğrulama uygulamanızla tarayın veya kodu manuel olarak girin.",
+ "u2f_deprecated": "Anahtarınız, kullanımdan kaldırılmış U2F yöntemi kullanılarak kaydedilmiş gibi görünüyor. İki Faktörlü Kimlik Doğrulamayı sizin için devre dışı bırakacağız ve Anahtarınızı sileceğiz.",
+ "none": "Devre dışı bırak",
+ "authenticators": "Kimlik doğrulayıcılar",
+ "api_register": "%s, Yubico Bulut API'sini kullanır. Lütfen anahtarınız için <a href=\\\"https://upgrade.yubico.com/getapikey/\\\" target=\\\"_blank\\\">buradan bir API anahtarı edinin. </a>",
+ "confirm": "Onayla",
+ "confirm_totp_token": "Lütfen oluşturulan jetonu girerek değişikliklerinizi onaylayın",
+ "delete_tfa": "Çift faktörlü doğrulamayı kaldırın",
+ "disable_tfa": "Bir olayla başarılı girişe kadar çift geçişli çıkışı devre dışı bırak",
+ "enter_qr_code": "Cihazınız QR kodlarını tarayamıyorsa TOTP kodunuz",
+ "error_code": "Hata kodu",
+ "init_webauthn": "Başlatılıyor, lütfen bekleyin...",
+ "key_id": "Cihazınız için bir tanımlayıcı",
+ "key_id_totp": "Anahtarınız için bir tanımlayıcı",
+ "reload_retry": "- (hata devam ederse tarayıcıyı yeniden yükleyin)",
+ "select": "Lütfen seçiniz",
+ "set_tfa": "Çift faktörlü yöntem metodu",
+ "tfa_token_invalid": "Çift faktörlü doğrulama geçersiz",
+ "totp": "Zamana dayalı OTP (Google Authenticator, Authy, vb.)",
+ "u2f_deprecated_important": "Lütfen Anahtarınızı yeni WebAuthn yöntemiyle yönetici panelinde kaydedin.",
+ "webauthn": "WebAuthn kimlik doğrulaması",
+ "waiting_usb_auth": "<i>USB cihazı bekleniyor...</i><br><br>Lütfen şimdi USB cihazınızdaki düğmeye dokunun.",
+ "yubi_otp": "Yubico OTP kimlik doğrulaması",
+ "start_webauthn_validation": "Doğrulamayı başlat",
+ "tfa": "Çift faktörlü doğrulama"
+ },
+ "start": {
+ "imap_smtp_server_auth_info": "Lütfen tam e-posta adresinizi ve PLAIN kimlik doğrulama mekanizmasını kullanın.<br>\\r\\nGiriş verileriniz, sunucu tarafı zorunlu şifreleme ile şifrelenecektir.",
+ "help": "Yardım panelini göster/gizle"
+ },
+ "queue": {
+ "hold_mail_legend": "Seçilen postaları bekletir. (Daha fazla teslimat girişimini önler)",
+ "legend": "Posta kuyruğu eylemleri işlevleri:",
+ "ays": "Lütfen geçerli kuyruktaki tüm öğeleri silmek istediğinizi onaylayın.",
+ "deliver_mail": "Teslim Et",
+ "deliver_mail_legend": "Seçilen postaları yeniden teslim etme girişimleri.",
+ "delete": "Tümünü Sil",
+ "flush": "Kuyruğu Temizle",
+ "info": "Posta kuyruğu, teslim edilmeyi bekleyen tüm e-postaları içerir. Bir mail uzun süre mail kuyruğunda kalırsa sistem tarafından otomatik olarak silinir.<br>İlgili mailin hata mesajı mailin neden teslim edilemediği hakkında bilgi verir.",
+ "queue_manager": "Kuyruk Yöneticisi",
+ "show_message": "Mesajı göster",
+ "unban": "Yasağı Kaldır",
+ "unhold_mail": "Bırak",
+ "unhold_mail_legend": "Seçilen postaları teslimat için serbest bırakır. (önceden bekletme gerektirir)",
+ "hold_mail": "Tut"
+ },
+ "fido2": {
+ "confirm": "Onayla",
+ "fido2_auth": "FIDO2 ile giriş yap",
+ "fido2_success": "Cihaz başarıyla kaydedildi",
+ "set_fido2": "FIDO2 cihazını kaydedin",
+ "set_fn": "Kolay ad belirleyin",
+ "start_fido2_validation": "FIDO2 doğrulamasını başlat",
+ "fido2_validation_failed": "Doğrulama başarısız",
+ "fn": "Kolay ad",
+ "known_ids": "Bilinen Kimlikler",
+ "none": "Engellendi.",
+ "register_status": "Kayıt Durumu",
+ "rename": "Yeniden adlandır",
+ "set_fido2_touchid": "Apple M1'de Touch ID'yi kaydedin"
+ },
+ "footer": {
+ "confirm_delete": "Silmeyi Onayla",
+ "delete_now": "Şimdi sil",
+ "delete_these_items": "Lütfen aşağıdaki nesne kimliğindeki değişikliklerinizi onaylayın",
+ "restart_container_info": "<b>Önemli:</b> Düzgün bir yeniden başlatmanın tamamlanması biraz zaman alabilir, lütfen bitmesini bekleyin.",
+ "restart_now": "Şimdi yeniden başlat",
+ "restarting_container": "Konteyner yeniden başlatılıyor, bu işlem biraz zaman alabilir",
+ "hibp_check": "haveibeenpwned.com adresinden kontrol edin",
+ "cancel": "İptal",
+ "hibp_nok": "Eşleşti! Bu potansiyel olarak tehlikeli bir şifredir!",
+ "hibp_ok": "Eşleşme bulunamadı.",
+ "loading": "Lütfen bekleyin...",
+ "nothing_selected": "Seçim yapılmadı",
+ "restart_container": "Konteyneri yeniden başlat"
+ },
+ "header": {
+ "administration": "Yapılandırma ve Ayrıntılar",
+ "apps": "Uygulamalar",
+ "debug": "Bilgi",
+ "email": "E-Posta",
+ "mailcow_system": "Sistem",
+ "mailcow_config": "Yapılandırma",
+ "quarantine": "Karantina",
+ "restart_netfilter": "netfilter'ı yeniden başlat",
+ "restart_sogo": "SOGo'yu yeniden başlat",
+ "user_settings": "Kullanıcı Ayarları"
+ },
+ "info": {
+ "awaiting_tfa_confirmation": "TFA onayı bekleniyor",
+ "no_action": "Uygulanabilir bir işlem yok",
+ "session_expires": "Oturumunuz yaklaşık 15 saniye içinde sona erecek"
+ },
+ "oauth2": {
+ "access_denied": "OAuth2 aracılığıyla erişim izni vermek için lütfen posta kutusu sahibi olarak giriş yapın.",
+ "authorize_app": "Uygulamayı yetkilendir",
+ "deny": "Reddet",
+ "permit": "Uygulamayı yetkilendir",
+ "profile": "Profil",
+ "profile_desc": "Kişisel bilgileri görüntüleyin: kullanıcı adı, tam ad, oluşturuldu, değiştirildi, etkin",
+ "scope_ask_permission": "Bir uygulama aşağıdaki izinleri istedi"
+ },
+ "ratelimit": {
+ "disabled": "Engellendi",
+ "second": "mesaj / saniye",
+ "minute": "mesaj / dakika",
+ "hour": "mesaj / saat",
+ "day": "mesaj / gün"
+ },
+ "user": {
+ "advanced_settings": "Gelişmiş ayarlar",
+ "aliases_also_send_as": "Kullanıcı olarak göndermeye de izin verilir",
+ "direct_aliases_desc": "Doğrudan takma ad adresleri spam filtresi ve TLS ilke ayarlarından etkilenir.",
+ "direct_protocol_access": "Bu posta kutusu kullanıcısının aşağıdaki protokollere ve uygulamalara <b>doğrudan, harici erişimi</b> vardır. Bu ayar yöneticiniz tarafından kontrol edilir. Bireysel protokollere ve uygulamalara erişim vermek için uygulama şifreleri oluşturulabilir.< br>\\\"Web postasında oturum aç\\\" düğmesi, SOGo'da tek oturum açmayı sağlar ve her zaman kullanılabilir.",
+ "pushover_info": "Push bildirim ayarları, takma adlar (paylaşılan, paylaşılmayan, etiketli) dahil <b>%s</b> adresine teslim edilen tüm temiz (spam olmayan) postalar için geçerli olacaktır.",
+ "last_pw_change": "Son şifre değişikliği",
+ "mailbox_details": "Detaylar",
+ "quarantine_notification_info": "Bir bildirim gönderildiğinde, öğeler \\\"bildirildi\\\" olarak işaretlenecek ve bu belirli öğe için başka bildirim gönderilmeyecek.",
+ "alias_extend_all": "Takma adları 1 saat uzat",
+ "app_hint": "Uygulama parolaları, IMAP, SMTP, CalDAV, CardDAV ve EAS oturum açma bilgileriniz için alternatif parolalardır. Kullanıcı adı değişmeden kalır. SOGo web postası, uygulama parolalarıyla kullanılamaz.",
+ "apple_connection_profile_mailonly": "Bu bağlantı profili, bir Apple aygıtı için IMAP ve SMTP yapılandırma parametrelerini içerir.",
+ "no_last_login": "Son kullanıcı arayüzü oturum açma bilgisi yok",
+ "pushover_vars": "Gönderen filtresi tanımlanmadığında, tüm postalar dikkate alınacaktır.<br>Düzenli ifade filtreleri ve tam gönderen kontrolleri ayrı ayrı tanımlanabilir ve sıralı olarak değerlendirilecektir. Birbirlerine bağlı değildirler.<br> Metin ve başlık için kullanılabilir değişkenler (lütfen veri koruma politikalarını dikkate alın)",
+ "shared_aliases_desc": "Paylaşılan takma adlar, spam filtresi veya şifreleme politikası gibi kullanıcıya özel ayarlardan etkilenmez. Karşılık gelen spam filtreleri yalnızca bir yönetici tarafından etki alanı çapında bir politika olarak yapılabilir.",
+ "action": "Eylem",
+ "create_app_passwd": "Uygulama parolası oluştur",
+ "create_syncjob": "Yeni senkronizasyon işi oluştur",
+ "change_password": "Şifre değiştirme",
+ "clear_recent_successful_connections": "Görünen başarılı bağlantıları temizle",
+ "client_configuration": "E-posta istemcileri ve akıllı telefonlar için yapılandırma kılavuzlarını göster",
+ "messages": "mesajlar",
+ "spam_aliases": "Geçici e-posta takma adları",
+ "spam_score_reset": "Sunucu varsayılanına sıfırla",
+ "years": "Yıllar",
+ "change_password_hint_app_passwords": "Hesabınızda değiştirilmeyecek uygulama şifresi var. Bunları yönetmek için Uygulama şifreleri sekmesine gidin.",
+ "pushover_evaluate_x_prio": "Yüksek öncelikli postayı ilet [<code>X-Priority: 1</code>]",
+ "spamfilter_table_add": "Öge Ekle",
+ "spamfilter_table_domain_policy": "n/a (alan politikası)",
+ "spamfilter_table_empty": "Görüntülenecek veri yok\"",
+ "spamfilter_table_remove": "Kaldır",
+ "tls_policy_warning": "<strong>Uyarı:</strong> Şifreli posta aktarımını zorunlu kılmaya karar verirseniz, e-postalarınızı kaybedebilirsiniz.<br>Politikayı karşılamayan iletiler, posta sistemi tarafından kesin bir başarısızlıkla geri döner.< br>Bu seçenek, birincil e-posta adresiniz (oturum açma adı), takma ad alanlarından türetilen tüm adresler ve ayrıca <b>hedef olarak yalnızca bu tek posta kutusuyla</b> takma ad adresleri için geçerlidir.",
+ "interval": "Aralık",
+ "username": "Kullanıcı adı",
+ "verify": "Doğrula",
+ "waiting": "Bekliyor",
+ "spamfilter_default_score": "Varsayılan değerler",
+ "status": "Durum",
+ "active": "Aktif",
+ "active_sieve": "Aktif filtre",
+ "alias": "Takma ad",
+ "alias_create_random": "Rastgele takma ad oluştur",
+ "alias_full_date": "d.m.Y, H:i:s T",
+ "alias_remove_all": "Tüm takma adları kaldır",
+ "alias_select_validity": "Geçerlilik süresi",
+ "alias_time_left": "Kalan süre",
+ "alias_valid_until": "Tarihe Kadar Geçerli",
+ "aliases_send_as_all": "Aşağıdaki alan(lar) ve takma ad alanları için gönderici erişimini kontrol etmeyin",
+ "allowed_protocols": "İzin verilen protokoller",
+ "app_name": "Uygulama adı",
+ "app_passwds": "Uygulama şifreleri",
+ "apple_connection_profile": "Apple bağlantı profili",
+ "apple_connection_profile_complete": "Bu bağlantı profili, bir Apple aygıtı için IMAP ve SMTP parametrelerinin yanı sıra CalDAV (takvimler) ve CardDAV (kişiler) yollarını içerir.",
+ "apple_connection_profile_with_app_password": "Yeni bir uygulama parolası oluşturulur ve profile eklenir, böylece cihazınızı kurarken parola girilmesi gerekmez. Posta kutunuza tam erişim sağladığı için lütfen dosyayı paylaşmayın.",
+ "attribute": "Özellik",
+ "created_on": "Oluşturulma tarihi",
+ "daily": "Günlük",
+ "day": "Gün",
+ "description": "Açıklama",
+ "delete_ays": "Lütfen silme işlemini onaylayın.",
+ "direct_aliases": "Doğrudan takma ad adresleri",
+ "eas_reset_help": "Birçok durumda cihaz önbelleğini sıfırlama, bozuk bir ActiveSync profilini kurtarmaya yardımcı olur.<br><b>Dikkat:</b> Tüm öğeler yeniden indirilecek!",
+ "edit": "Düzenle",
+ "email": "e-posta",
+ "email_and_dav": "e-posta, takvimler ve kişiler",
+ "empty": "Sonuç yok",
+ "encryption": "Şifreleme",
+ "excludes": "Hariçtir",
+ "expire_in": "Son kullanma tarihi",
+ "fido2_webauthn": "FIDO2/WebAuthn",
+ "force_pw_update": "Grup yazılımıyla ilgili hizmetlere erişebilmek için yeni bir parola <b>gerekir</b> ayarlamalısınız.",
+ "from": "Kimden",
+ "generate": "Oluştur",
+ "hour": "Saat",
+ "hourly": "Saatlik",
+ "hours": "Saatler",
+ "in_use": "Kullanılmış",
+ "is_catch_all": "Alan/alanlar için tümünü yakala",
+ "last_mail_login": "Son posta girişi",
+ "last_run": "Son çalıştırma",
+ "last_ui_login": "Kullanıcının son arayüzü girişi",
+ "loading": "Yükleniyor...",
+ "login_history": "Giriş geçmişi",
+ "mailbox": "Posta Kutusu",
+ "mailbox_general": "Genel",
+ "mailbox_settings": "Ayarlar",
+ "month": "Ay",
+ "months": "Aylar",
+ "never": "Asla",
+ "new_password": "Yeni şifre",
+ "new_password_repeat": "Onay şifresi (tekrar)",
+ "no_active_filter": "Aktif filtre mevcut değil",
+ "no_record": "Kayıt yok",
+ "open_logs": "Günlükleri açın",
+ "open_webmail_sso": "Web postasına giriş yapın",
+ "password": "Şifre",
+ "password_now": "Geçerli şifre (değişiklikleri onaylayın)",
+ "password_repeat": "Şifre (tekrar)",
+ "pushover_only_x_prio": "Yalnızca yüksek öncelikli postaları dikkate alın [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Aşağıdaki gönderen e-posta adreslerini <small>(virgülle ayrılmış)</small> göz önünde bulundurun",
+ "pushover_sender_regex": "Gönderenleri aşağıdaki normal ifadeye göre eşleştir",
+ "pushover_text": "Bildirim metni",
+ "pushover_title": "Bildirim başlığı",
+ "pushover_sound": "Ses",
+ "pushover_verify": "Kimlik bilgilerini doğrula",
+ "q_add_header": "Önemsiz klasör",
+ "q_all": "Tüm kategoriler",
+ "quarantine_category": "Karantina bildirim kategorisi",
+ "quarantine_category_info": "\\\"Reddedildi\\\" bildirim kategorisi reddedilen postaları içerirken, \\\"Önemsiz klasör\\\" bir kullanıcıyı önemsiz klasörüne konan postalar hakkında bilgilendirir.",
+ "quarantine_notification": "Karantina bildirimleri",
+ "recent_successful_connections": "Başarılı bağlantılar görüldü",
+ "remove": "Kaldır.",
+ "running": "Çalıştırılıyor...",
+ "save": "Değişiklikleri Kaydet",
+ "save_changes": "Değişiklikleri Kaydet",
+ "sender_acl_disabled": "<span class=\\\"label label-danger\\\">Gönderen denetimi devre dışı</span>",
+ "shared_aliases": "Paylaşılan takma ad adresleri",
+ "show_sieve_filters": "Etkin kullanıcı elek filtresini göster",
+ "sogo_profile_reset": "SOGo profilini sıfırla",
+ "sogo_profile_reset_help": "Bu, kullanıcının SOGo profilini yok edecek ve <b>geri alınamayan tüm kişi ve takvim verilerini siler</b>.",
+ "sogo_profile_reset_now": "Profili şimdi sıfırla",
+ "spamfilter": "Spam filtresi",
+ "spamfilter_behavior": "Derecelendirme",
+ "spamfilter_bl": "Kara liste",
+ "sync_jobs": "İşleri senkronize et",
+ "spamfilter_bl_desc": "Spam olarak sınıflandırılacak ve reddedilecek <b>her zaman</b> kara listeye alınan e-posta adresleri. Reddedilen postalar karantinaya <b>kopyalanmaz</b>. Joker karakterler kullanılabilir. Bir filtre yalnızca şunlara uygulanır tüm takma adları ve bir posta kutusunun kendisi hariç doğrudan takma adlar (tek bir hedef posta kutusuna sahip takma adlar).",
+ "spamfilter_green": "Yeşil: bu mesaj spam değil",
+ "spamfilter_hint": "İlk değer \\\"düşük spam puanını\\\" tanımlar, ikincisi \\\"yüksek spam puanını\\\" temsil eder.",
+ "spamfilter_red": "Kırmızı: Bu ileti istenmeyen postadır ve sunucu tarafından reddedilecektir",
+ "spamfilter_table_action": "Eylem",
+ "spamfilter_table_rule": "Kural",
+ "spamfilter_wl": "Beyaz liste",
+ "spamfilter_wl_desc": "Beyaz listeye alınan e-posta adresleri spam olarak <b>asla</b> sınıflandırılmayacak şekilde programlanmıştır. Joker karakterler kullanılabilir. Bir filtre yalnızca, tümünü yakalama takma adları ve bir posta kutusunun kendisi.",
+ "spamfilter_yellow": "Sarı: bu mesaj spam olabilir, spam olarak etiketlenecek ve gereksiz klasörünüze taşınacak",
+ "syncjob_check_log": "İşleri senkronize et",
+ "syncjob_last_run_result": "Son çalıştırma sonucu",
+ "syncjob_EX_OK": "Başarılı",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Bağlantı sorunu",
+ "syncjob_EXIT_TLS_FAILURE": "Şifreli bağlantı ile ilgili sorun",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Kimlik doğrulama sorunu",
+ "syncjob_EXIT_OVERQUOTA": "Hedef posta kutusu kotayı aştı",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Uzak sunucuya bağlanılamıyor",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Yanlış kullanıcı adı veya şifre",
+ "tag_handling": "Etiketli postalar için işlemeyi ayarla",
+ "tag_help_example": "Etiketli bir e-posta adresi örneği: ben<b>+Facebook</b>@example.org",
+ "tag_help_explain": "Alt klasörde: INBOX (\\\"INBOX/Facebook\\\") altında etiketten sonra adlandırılan yeni bir alt klasör oluşturulacak.<br>\\r\\nKonuda: etiketlerin adı posta konusunun önüne eklenecek, örnek: \\\"[Facebook] Haberlerim\\\".",
+ "tag_in_none": "Hiçbir şey yapma",
+ "tag_in_subfolder": "Alt klasörde",
+ "tag_in_subject": "Konuda",
+ "text": "Metin",
+ "title": "Başlık",
+ "tls_enforce_in": "TLS gelenini zorunlu kıl",
+ "tls_enforce_out": "TLS gidenini zorunlu kıl",
+ "tls_policy": "Şifreleme politikası",
+ "user_settings": "Kullanıcı ayarları",
+ "value": "Değer",
+ "weekly": "Haftalık",
+ "weeks": "Haftalar",
+ "with_app_password": "Uygulama şifresi ile",
+ "year": "Yıl",
+ "eas_reset": "ActiveSync cihaz önbelleğini sıfırla",
+ "eas_reset_now": "Şimdi sıfırla",
+ "q_reject": "Reddedildi",
+ "week": "Hafta"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.uk-ua.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.uk-ua.json
index 7312246..61c401a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.uk-ua.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.uk-ua.json
@@ -28,13 +28,14 @@
"app_passwds": "Паролі додатків",
"domain_relayhost": "Змінити relayhost для домену",
"login_as": "Увійти як користувач поштової скриньки",
- "sogo_profile_reset": "Скинути профіль SOGo"
+ "sogo_profile_reset": "Скинути профіль SOGo",
+ "pw_reset": "Скидання паролю користувача"
},
"add": {
"app_name": "Назва додатка",
"app_password": "Додати пароль додатка",
"app_passwd_protocols": "Дозволені протоколи для пароля додатка",
- "comment_info": "Приватний коментар не видно користувачам, а публічний – відображається поряд із псевдонімом в особистому кабінеті користувача.",
+ "comment_info": "Приватний коментар не видно користувачам, а публічний – відображається поряд із псевдонімом в особистому кабінеті користувача",
"custom_params": "Налаштування користувача",
"gal": "GAL - Глобальна адресна книга",
"mailbox_quota_m": "Максимальна квота поштового акаунту (MiB)",
@@ -77,7 +78,7 @@
"password_repeat": "Підтвердження пароля (повтор)",
"post_domain_add": "Після додавання нового домену контейнер SOGo (\"sogo-mailcow\") необхідно перезапустити!<br><br>Крім того, слід перевірити конфігурацію DNS доменів. Після затвердження конфігурації DNS перезапустіть контейнер \"acme-mailcow\", щоб автоматично згенерувати сертифікати для вашого нового домену.<br>Цей крок не є обов'язковим і повторюватиметься кожні 24 години.",
"relay_all_info": "Якщо ви вирішите <b>не</b> ретранслювати всіх одержувачів, вам потрібно буде додати (\"сліпу\") поштову адресу для кожного одержувача, якого слід ретранслювати.",
- "relay_transport_info": "<div class=\"label label-info\">Інфо</div> Ви можете налаштувати власний транспорт для домену. Якщо такої установки немає, то доставка буде виконана на основі MX-записів.",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Інфо</div> Ви можете налаштувати власний транспорт для домену. Якщо такої установки немає, то доставка буде виконана на основі MX-записів.",
"relayhost_wrapped_tls_info": "Будь ласка, <b>не</b> використовуйте TLS порти (в основному це 465 порт).<br>\nВикористовуйте будь-який <b>не</b> порт TLS, який підтримує STARTTLS. А для захисту від downgrate атак - налаштуйте примусову політику TLS.",
"syncjob_hint": "Паролі до вашого акаунту будуть збережені на сервері у вигляді простого тексту!",
"timeout1": "Тайм-аут для підключення до віддаленого хоста",
@@ -299,7 +300,7 @@
"api_allow_from": "Список IP-адрес для доступу до API (розділених комою або новим рядком)",
"api_skip_ip_check": "Пропустити перевірку IP для API",
"arrival_time": "Время получения (час. пояс сервера)",
- "ban_list_info": "Список заблокованих IP-адрес: <b>підмережа (час, що залишився) - [дія]</b>.<br />IP-адреси, що знаходяться в черзі на розблокування, будуть видалені зі списку активних блокувань протягом декількох секунд.<br> />Червона мітка означає, що підмережа/хост знаходиться в чорному списку.",
+ "ban_list_info": "Список заблокованих IP-адрес: <b>підмережа (час, що залишився) - [дія]</b>.<br />IP-адреси, що знаходяться в черзі на розблокування, будуть видалені зі списку активних блокувань протягом декількох секунд.<br>Червона мітка означає, що підмережа/хост знаходиться в чорному списку.",
"credentials_transport_warning": "<b>Попередження</b>: додавання нового запису перезапише облікові дані для всіх записів з таким самим <i>наступним хостом</i>.",
"dkim_to_title": "Цільовий домен(и) (DKIM буде перезаписаний)",
"duplicate_dkim": "Копіювання DKIM запису",
@@ -349,7 +350,13 @@
"queue_unban": "розблокувати",
"f2b_manage_external": "Керування Fail2Ban ззовні",
"f2b_manage_external_info": "Fail2ban буде підтримувати список заборонених, але не буде активно встановлювати правила для блокування трафіку. Використовуйте згенерований список заборон нижче для зовнішнього блокування трафіку.",
- "copy_to_clipboard": "Текст скопійовано в буфер обміну!"
+ "copy_to_clipboard": "Текст скопійовано в буфер обміну!",
+ "password_reset_tmpl_text": "Plain-text шаблон",
+ "password_reset_info": "Якщо електронну адресу для відновлення не надано, ця функція не може бути використана.",
+ "logo_dark_label": "Темна тема",
+ "password_reset_settings": "Налаштування відновлення паролів",
+ "password_reset_tmpl_html": "HTML шаблон",
+ "logo_normal_label": "Світла тема"
},
"danger": {
"alias_domain_invalid": "Неприпустимий псевдонім домену: %s",
@@ -391,7 +398,7 @@
"last_key": "Останній ключ не можна видалити, натомість вимкніть TFA.",
"login_failed": "Введено неправильний логін або пароль",
"mailbox_invalid": "Неприпустима адреса поштового акаунту",
- "mailbox_quota_left_exceeded": "Недостатньо вільного місця (місця залишилося: %d МіБ)",
+ "mailbox_quota_left_exceeded": "Недостатньо вільного місця (залишилося: %d МіБ)",
"malformed_username": "Некоректне ім'я користувача",
"map_content_empty": "Зміст правила не може бути порожнім",
"max_alias_exceeded": "Перевищено максимальну кількість псевдонімів",
@@ -478,7 +485,9 @@
"extended_sender_acl_denied": "відсутній ACL для встановлення зовнішніх адрес відправників",
"template_exists": "Шаблон %s вже існує",
"template_id_invalid": "Ідентифікатор шаблону %s недійсний",
- "template_name_invalid": "Ім'я шаблону невірне"
+ "template_name_invalid": "Ім'я шаблону невірне",
+ "img_size_exceeded": "Зображення перевищує максимальний розмір файлу",
+ "img_dimensions_exceeded": "Зображення перевищує максимальний розмір"
},
"debug": {
"chart_this_server": "Діаграма (цей сервер)",
@@ -494,8 +503,6 @@
"restart_container": "Перезапустити",
"service": "Сервіс",
"size": "Розмір індексів",
- "solr_dead": "Solr запускається, відключений або сламаний.",
- "solr_status": "Стан Solr",
"started_at": "Запущений",
"started_on": "Запущений у",
"static_logs": "Статичні журнали",
@@ -504,7 +511,6 @@
"uptime": "Час роботи",
"username": "Ім'я користувача",
"external_logs": "Зовнішні журнали",
- "jvm_memory_solr": "Використання оперативної пам'яті JVM",
"log_info": "<p><b>Журнали контейнерів</b> mailcow зберігаються в Redis, і раз на хвилину рядки журналу за межами <code>LOG_LINES (%d)</code> видаляються, щоб зменшити навантаження на сервер.\n <br>Самі журнали контейнерів не зберігаються після перезавантаження контейнера. Усі контейнери додатково пишуть логи у службу Docker, і, отже, використовують драйвер логування за промовчанням. Журнали контейнерів призначені лише для налагодження дрібних проблем. Для інших завдань, будь ласка, настройте драйвер логування Docker самостійно.</p>\n <p><b>Зовнішні журнали</b> збираються через API програм.</p>\n <p><b>Статичні журнали</b> – це в основному журнали активності, які не записуються в Dockerd, але все одно повинні бути постійними (за винятком журналів API).</p>",
"error_show_ip": "Не вдалося розпізнати публічні IP-адреси",
"no_update_available": "Система працює на останній версії",
@@ -608,8 +614,8 @@
"sieve_desc": "Короткий опис",
"sieve_type": "Тип фільтра",
"skipcrossduplicates": "Пропускати в папках повідомлення, що повторюються",
- "sogo_access": "Надати прямий доступ до SOGo",
- "sogo_access_info": "Єдиний вхід із інтерфейсу пошти продовжує працювати. Це налаштування не впливає на доступ до всіх інших служб, а також не видаляє чи змінює наявний профіль користувача SOGo.",
+ "sogo_access": "Пряме перенаправлення до SOGo",
+ "sogo_access_info": "Після входу користувач автоматично перенаправляється на SOGo.",
"sogo_visible": "Відображати псевдонім у SOGo",
"spam_alias": "Створити або змінити тимчасові (спам) псевдоніми",
"spam_filter": "Спам фільтр",
@@ -626,7 +632,7 @@
"admin": "Редагувати адміністратора",
"allow_from_smtp": "Дозволити <b>SMTP</b> тільки для цих IP",
"allow_from_smtp_info": "Вкажіть IPv4/IPv6 адреси та/або підмережі.<br>Залиште поле порожнім, щоб дозволити відправлення з будь-яких адрес.",
- "bcc_dest_format": "Призначенням правила BBC має бути єдина дійсна адреса електронної пошти.<br>Якщо вам потрібно надіслати копію на кілька адрес, створіть псевдонім і використовуйте його тут.",
+ "bcc_dest_format": "Призначенням правила BCC має бути єдина дійсна адреса електронної пошти.<br>Якщо вам потрібно надіслати копію на кілька адрес, створіть псевдонім і використовуйте його тут.",
"comment_info": "Приватний коментар не видно користувачам, а публічний - відображається поряд із псевдонімом в особистому кабінеті користувача",
"domain_quota": "Квота домену",
"dont_check_sender_acl": "Вимкнути перевірку відправника для домену %s та псевдонімів домену",
@@ -660,7 +666,8 @@
},
"domain_footer_html": "Нижній колонтитул HTML",
"domain_footer_plain": "ЗВИЧАЙНИЙ нижній колонтитул",
- "custom_attributes": "Користувацькі атрибути"
+ "custom_attributes": "Користувацькі атрибути",
+ "domain_footer_skip_replies": "Ігнорувати нижній колонтитул у листах-відповідях"
},
"fido2": {
"confirm": "Підтвердити",
@@ -712,7 +719,7 @@
"login": {
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "Увійти",
- "other_logins": "Вхід за допомогою ключа",
+ "other_logins": "або увійти з",
"password": "Пароль",
"username": "Ім'я користувача",
"delayed": "Вхід був затриманий на %s секунд.",
@@ -725,7 +732,7 @@
"add": "Додати",
"add_alias": "Додати псевдонім",
"add_alias_expand": "Копіювати псевдоніми на псевдоніми домену",
- "add_bcc_entry": "Додати правило BBC",
+ "add_bcc_entry": "Додати правило BCC",
"add_domain": "Додати домен",
"add_domain_alias": "Додати псевдонім домену",
"add_filter": "Додати фільтр",
@@ -745,7 +752,7 @@
"bcc_local_dest": "Локальний домен",
"bcc_map": "Правила ВВС",
"bcc_map_type": "Тип BCC",
- "bcc_maps": "Правила BBC",
+ "bcc_maps": "Правила BCC",
"bcc_rcpt_map": "Одержувач",
"bcc_sender_map": "Відправник",
"bcc_to_rcpt": "Перейти на тип \"одержувач\"",
@@ -980,9 +987,7 @@
},
"start": {
"help": "Довідка",
- "mailcow_apps_detail": "Використовуйте mailcow, щоб отримати доступ до своєї пошти, календаря, контактів тощо.",
- "imap_smtp_server_auth_info": "Будь ласка, використовуйте повну адресу електронної пошти у форматі <code>user@example.com</code> та PLAIN механізм авторизації.<br>\nВаші дані авторизації будуть зашифровані на рівні шифрування каналу підключення до сервера, тому переконайтеся, що ви використовуєте надійне підключення TLS.",
- "mailcow_panel_detail": "<b>Адміністратори домену</b> можуть створювати, змінювати або видаляти поштові скриньки та псевдоніми, змінювати домени та дивитися інформацію про свої призначені домени. <br><b>Користувачі поштових скриньок</b> мають можливість створювати тимчасові псевдоніми (спам псевдоніми), змінювати свій пароль та налаштування фільтра спаму."
+ "imap_smtp_server_auth_info": "Будь ласка, використовуйте повну адресу електронної пошти у форматі <code>user@example.com</code> та PLAIN механізм авторизації.<br>\nВаші дані авторизації будуть зашифровані на рівні шифрування каналу підключення до сервера, тому переконайтеся, що ви використовуєте надійне підключення TLS."
},
"success": {
"acl_saved": "ACL для %s збережено",
@@ -1067,7 +1072,8 @@
"cors_headers_edited": "Налаштування CORS збережено",
"ip_check_opt_in_modified": "Перевірка IP-адреси успішно збережено",
"template_removed": "Шаблону із ID %s видалено",
- "f2b_banlist_refreshed": "Ідентифікатор списку заборонених успішно оновлено."
+ "f2b_banlist_refreshed": "Ідентифікатор списку заборонених успішно оновлено.",
+ "domain_footer_modified": "Зміни в нижньому колонтитулі домену %s збережено"
},
"tfa": {
"confirm": "Підтвердьте",
@@ -1094,7 +1100,8 @@
"set_tfa": "Встановити метод двофакторної перевірки",
"u2f_deprecated": "Схоже, ваш ключ був зареєстрований за допомогою застарілого методу U2F. Ми дезактивуємо двофакторну автентифікацію для вас і видалимо ваш ключ.",
"waiting_usb_auth": "<i>Очікування пристрою USB...</i><br><br>Будь ласка, натисніть зараз кнопку на USB пристрої.",
- "waiting_usb_register": "<i>Очікування USB-пристрою...</i><br><br>Будь ласка, введіть пароль вище та підтвердіть реєстрацію, натиснувши кнопку на USB пристрої."
+ "waiting_usb_register": "<i>Очікування USB-пристрою...</i><br><br>Будь ласка, введіть пароль вище та підтвердіть реєстрацію, натиснувши кнопку на USB пристрої.",
+ "authenticators": "Аутентифікатори"
},
"user": {
"action": "Дії",
@@ -1123,6 +1130,7 @@
"created_on": "Дата створення",
"daily": "Раз на день",
"day": "день",
+ "description": "Опис",
"delete_ays": "Будь ласка, підтвердіть видалення.",
"eas_reset": "Скинути кеш ActiveSync пристроїв",
"eas_reset_help": "У багатьох випадках скидання кешу пристроїв допомагає відновити пошкоджений профіль ActiveSync.<br><b>Увага:</b> всі листи, календарі та контакти будуть завантажені заново на всі ваші пристрої!",
@@ -1230,13 +1238,13 @@
"client_configuration": "Показати посібники з налаштування поштових клієнтів та смартфонів",
"direct_aliases": "Особисті псевдоніми",
"direct_aliases_desc": "На особисті псевдоніми розповсюджуються фільтри небажаної пошти та параметри політики TLS.",
- "direct_protocol_access": "Цей користувач поштової скриньки має <b>прямий, зовнішній доступ</b> до наведених нижче протоколів і програм. Цими параметрами керує ваш адміністратор. Паролі додатків можна створювати для надання доступу до окремих протоколів і програм.<br>Кнопка \"Увійти до веб-пошти\" забезпечує єдиний вхід в SOGo і завжди доступна.",
+ "direct_protocol_access": "Цей користувач поштової скриньки має <b>прямий, зовнішній доступ</b> до наведених нижче протоколів і програм. Цими параметрами керує ваш адміністратор. Паролі додатків можна створювати для надання доступу до окремих протоколів і програм.<br>Кнопка \"веб-пошти\" забезпечує єдиний вхід в SOGo і завжди доступна.",
"force_pw_update": "Ви <b>повинні</b> встановити новий пароль для доступу до сервісів, що належать до цього облікового запису.",
"is_catch_all": "Catch-all для домена/ів",
"last_ui_login": "Останній вхід до особистого кабінету",
"months": "місяців",
"new_password_repeat": "Підтвердження пароля (повтор)",
- "open_webmail_sso": "Вхід до веб-пошти",
+ "open_webmail_sso": "веб-пошти",
"pushover_evaluate_x_prio": "Встановити високий пріоритет повідомлень для листів із високим пріоритетом [<code>X-Priority: 1</code>]",
"pushover_info": "Налаштування Push-повідомлень будуть застосовуватися до всієї пошти <b>%s</b> (за винятком спаму), включаючи псевдоніми (особисті, загальні та теговані).",
"pushover_title": "Заголовок сповіщення",
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.uz-uz.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.uz-uz.json
new file mode 100644
index 0000000..a8d2ecf
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.uz-uz.json
@@ -0,0 +1,1440 @@
+{
+ "acl": {
+ "alias_domains": "Taxallus domenlarini qoʻshish",
+ "app_passwds": "Ilova parollarini boshqarish",
+ "bcc_maps": "BCC xaritalari",
+ "delimiter_action": "Ajratuvchi amali",
+ "domain_desc": "Domen tavsifini oʻzgartirish",
+ "domain_relayhost": "Domen uchun relay xostni oʻzgartirish",
+ "eas_reset": "EAS qurilmalarini tiklash",
+ "extend_sender_acl": "Tashqi manzillar yordamida joʻnatuvchi ACL ni kengaytirishga ruxsat berish",
+ "filters": "Filtrlar",
+ "login_as": "Pochta qutisi foydalanuvchisi sifatida kirish",
+ "mailbox_relayhost": "Pochta qutisi uchun relay xostni oʻzgartirish",
+ "prohibited": "ACL tomonidan taqiqlangan",
+ "protocol_access": "Protokolga kirishni oʻzgartirish",
+ "pushover": "Pushover",
+ "pw_reset": "mailcow foydalanuvchi parolini tiklashga ruxsat berish",
+ "quarantine": "Karantin amallari",
+ "quarantine_attachments": "Karantindagi ilovalar",
+ "quarantine_category": "Karantin bildirishnoma turkumini oʻzgartirish",
+ "quarantine_notification": "Karantin bildirishnomalarini oʻzgartirish",
+ "ratelimit": "Tezlik chegarasi",
+ "recipient_maps": "Qabul qiluvchi xaritalari",
+ "smtp_ip_access": "SMTP uchun ruxsat etilgan xostlarni oʻzgartirish",
+ "sogo_access": "SOGo kirishini boshqarishga ruxsat berish",
+ "sogo_profile_reset": "SOGo profilini tiklash",
+ "spam_alias": "Vaqtinchalik taxalluslar",
+ "spam_policy": "Qora roʻyxat/Oq roʻyxat",
+ "spam_score": "Spam bahosi",
+ "syncjobs": "Sinxronizatsiya vazifalari",
+ "tls_policy": "TLS siyosati",
+ "unlimited_quota": "Pochta qutilari uchun cheksiz kvota"
+ },
+ "add": {
+ "activate_filter_warn": "Faol belgilansa, boshqa barcha filtrlar oʻchirib qoʻyiladi.",
+ "active": "Faol",
+ "add": "Qoʻshish",
+ "add_domain_only": "Faqat domen qoʻshish",
+ "add_domain_restart": "Domen qoʻshish va SOGoni qayta ishga tushirish",
+ "alias_address": "Taxallus manzil(lar)i",
+ "alias_address_info": "<small>Toʻliq e-pochta manzil(lar)i yoki @example.com — domenga keladigan barcha xabarlarni qabul qilish uchun (vergul bilan ajratilgan). <b>Faqat mailcow domenlari</b>.</small>",
+ "alias_domain": "Taxallus domeni",
+ "alias_domain_info": "<small>Faqat haqiqiy domen nomlari (vergul bilan ajratilgan).</small>",
+ "app_name": "Ilova nomi",
+ "app_password": "Ilova paroli qoʻshish",
+ "app_passwd_protocols": "Ilova paroli uchun ruxsat etilgan protokollar",
+ "automap": "Papkalarni avtomatik xaritalashga harakat qilish (\"Sent items\", \"Sent\" => \"Sent\" va h.k.)",
+ "backup_mx_options": "Relay sozlamalari",
+ "bcc_dest_format": "BCC manzili bitta haqiqiy e-pochta manzili boʻlishi kerak.<br>Agar bir nechta manzilga nusxa joʻnatish kerak boʻlsa, taxallus yarating va shu yerda ishlating.",
+ "comment_info": "Maxfiy izoh foydalanuvchiga koʻrinmaydi, ommaviy izoh esa foydalanuvchi koʻrinishida ustiga sichqoncha kelganda maslahat sifatida koʻrsatiladi",
+ "custom_params": "Maxsus parametrlar",
+ "custom_params_hint": "Toʻgʻri: --param=xy, notoʻgʻri: --param xy",
+ "delete1": "Tugatilgach manbadan oʻchirish",
+ "delete2": "Manbada boʻlmagan xabarlarni manzildan oʻchirish",
+ "delete2duplicates": "Manzildagi dublikatlarni oʻchirish",
+ "description": "Tavsif",
+ "destination": "Manzil",
+ "disable_login": "Kirishni taqiqlash (kiruvchi pochta hali ham qabul qilinadi)",
+ "domain": "Domen",
+ "domain_matches_hostname": "%s domeni xost nomiga mos keladi",
+ "domain_quota_m": "Domenning umumiy kvotasi (MiB)",
+ "dry": "Sinxronizatsiyani simulyatsiya qilish",
+ "enc_method": "Shifrlash usuli",
+ "exclude": "Obyektlarni istisno qilish (regex)",
+ "full_name": "Toʻliq ism",
+ "gal": "Global manzillar roʻyxati",
+ "gal_info": "GAL domenning barcha obyektlarini oʻz ichiga oladi va hech bir foydalanuvchi tomonidan tahrirlanmaydi. Oʻchirilsa, SOGodagi bandlik maʼlumotlari yoʻqoladi! <b>Oʻzgarishlarni qoʻllash uchun SOGoni qayta ishga tushiring.</b>",
+ "generate": "yaratish",
+ "goto_ham": "<span class=\"text-success\"><b>ham</b></span> sifatida oʻrgatish",
+ "goto_null": "Xatni jimgina rad etish",
+ "goto_spam": "<span class=\"text-danger\"><b>spam</b></span> sifatida oʻrgatish",
+ "hostname": "Xost",
+ "inactive": "Nofaol",
+ "internal": "Ichki",
+ "internal_info": "Ichki taxalluslarga faqat oʻz domeni yoki taxallus domenlaridan kirish mumkin.",
+ "sender_allowed": "Ushbu taxallus orqali joʻnatishga ruxsat berish",
+ "kind": "Turi",
+ "mailbox_quota_def": "Standart pochta qutisi kvotasi",
+ "mailbox_quota_m": "Bitta pochta qutisining maks. kvotasi (MiB)",
+ "mailbox_username": "Foydalanuvchi nomi (e-pochta manzilining chap qismi)",
+ "max_aliases": "Mumkin boʻlgan maks. taxalluslar",
+ "max_mailboxes": "Mumkin boʻlgan maks. pochta qutilari",
+ "mins_interval": "Soʻrov oraligʻi (daqiqa)",
+ "multiple_bookings": "Bir nechta bandlovlar",
+ "nexthop": "Keyingi nuqta",
+ "password": "Parol",
+ "password_repeat": "Tasdiqlash paroli (takrorlang)",
+ "port": "Port",
+ "post_domain_add": "Yangi domen qoʻshilgandan keyin SOGo konteyneri (\"sogo-mailcow\") qayta ishga tushirilishi kerak!<br><br>Bundan tashqari, domenning DNS sozlamalarini koʻrib chiqing. DNS sozlamalari tasdiqlangach, yangi domeningiz (autoconfig.<domain>, autodiscover.<domain>) uchun sertifikatlarni avtomatik yaratish uchun \"acme-mailcow\" konteynerini qayta ishga tushiring.<br>Bu qadam ixtiyoriy va har 24 soatda qayta urinib koʻriladi.",
+ "private_comment": "Maxfiy izoh",
+ "public_comment": "Ommaviy izoh",
+ "quota_mb": "Kvota (MiB)",
+ "relay_all": "Barcha qabul qiluvchilarni relay qilish",
+ "relay_all_info": "↪ Agar barcha qabul qiluvchilarni relay qilmaslikni tanlasangiz, relay qilinishi kerak boʻlgan har bir qabul qiluvchi uchun (\"koʻr\") pochta qutisi qoʻshishingiz kerak boʻladi.",
+ "relay_domain": "Ushbu domenni relay qilish",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Maʼlumot</div> Bu domen uchun maxsus manzilga transport xaritalarini belgilashingiz mumkin. Agar oʻrnatilmagan boʻlsa, MX qidiruvi amalga oshiriladi.",
+ "relay_unknown_only": "Faqat mavjud boʻlmagan pochta qutilarini relay qilish. Mavjud pochta qutilari mahalliy yetkazib beriladi.",
+ "relayhost_wrapped_tls_info": "Iltimos, TLS-oʻralgan portlardan <b>foydalanmang</b> (asosan 465-portda).<br>\r\nO'ralmagan istalgan portdan foydalaning va STARTTLS chiqaring. TLS ni majburlash uchun TLS siyosatini \"TLS siyosati xaritalari\"da yaratish mumkin.",
+ "select": "Iltimos, tanlang...",
+ "select_domain": "Avval domenni tanlang",
+ "sieve_desc": "Qisqa tavsif",
+ "sieve_type": "Filtr turi",
+ "skipcrossduplicates": "Papkalararo dublikat xabarlarni oʻtkazib yuborish (birinchi kelgan, birinchi xizmatlanadi)",
+ "subscribeall": "Barcha papkalarga obuna boʻlish",
+ "syncjob": "Sinxronizatsiya vazifasi qoʻshish",
+ "syncjob_hint": "Parollar oddiy matn sifatida saqlanishini unutmang!",
+ "tags": "Teglar",
+ "target_address": "Yoʻnaltirish manzillari",
+ "target_address_info": "<small>Toʻliq e-pochta manzil(lar)i (vergul bilan ajratilgan).</small>",
+ "target_domain": "Maqsad domen",
+ "timeout1": "Masofaviy xostga ulanish vaqtining tugashi",
+ "timeout2": "Mahalliy xostga ulanish vaqtining tugashi",
+ "username": "Foydalanuvchi nomi",
+ "validate": "Tekshirish",
+ "validation_success": "Muvaffaqiyatli tekshirildi"
+ },
+ "admin": {
+ "access": "Kirish",
+ "action": "Amal",
+ "activate_api": "API ni faollashtirish",
+ "activate_send": "Joʻnatish tugmasini faollashtirish",
+ "active": "Faol",
+ "active_rspamd_settings_map": "Faol sozlamalar xaritasi",
+ "add": "Qoʻshish",
+ "add_admin": "Administrator qoʻshish",
+ "add_domain_admin": "Domen administratorini qoʻshish",
+ "add_forwarding_host": "Yoʻnaltirish xosti qoʻshish",
+ "add_relayhost": "Joʻnatuvchiga bogʻliq transport qoʻshish",
+ "add_relayhost_hint": "Autentifikatsiya maʼlumotlari, agar boʻlsa, oddiy matn sifatida saqlanishini unutmang.",
+ "add_row": "Satr qoʻshish",
+ "add_settings_rule": "Sozlamalar qoidasini qoʻshish",
+ "add_transport": "Transport qoʻshish",
+ "add_transports_hint": "Autentifikatsiya maʼlumotlari, agar boʻlsa, oddiy matn sifatida saqlanishini unutmang.",
+ "additional_rows": " ta qoʻshimcha satr qoʻshildi",
+ "admin": "Administrator",
+ "admin_details": "Administrator maʼlumotlarini tahrirlash",
+ "admin_domains": "Domen tayinlashlari",
+ "admins": "Administratorlar",
+ "admins_ldap": "LDAP administratorlari",
+ "admin_quicklink": "Admin kirish sahifasiga tezkor havolani yashirish",
+ "advanced_settings": "Kengaytirilgan sozlamalar",
+ "allowed_methods": "Access-Control-Allow-Methods",
+ "allowed_origins": "Access-Control-Allow-Origin",
+ "api_allow_from": "API kirishini ushbu IP / CIDR tarmoq belgilanishlaridan ruxsat berish",
+ "api_info": "API ishlab chiqilmoqda. Hujjatlarni <a href=\"/api\">/api</a> manzilida topishingiz mumkin",
+ "api_key": "API kaliti",
+ "api_read_only": "Faqat oʻqish uchun kirish",
+ "api_read_write": "Oʻqish va yozish uchun kirish",
+ "api_skip_ip_check": "API uchun IP tekshiruvini oʻtkazib yuborish",
+ "app_hide": "Kirishda yashirish",
+ "app_links": "Ilova havolalari",
+ "app_name": "Ilova nomi",
+ "apps_name": "\"mailcow Apps\" nomi",
+ "arrival_time": "Kelish vaqti (server vaqti)",
+ "authed_user": "Avtorizatsiya qilingan foydalanuvchi",
+ "ays": "Davom etishni xohlayotganingizga ishonchingiz komilmi?",
+ "ban_list_info": "Quyida bloklangan IP roʻyxati keltirilgan: <b>tarmoq (qolgan blok vaqti) - [amallar]</b>.<br />Blokdan chiqarishga navbatga qoʻyilgan IP lar bir necha soniya ichida faol bloklash roʻyxatidan olib tashlanadi.<br />Qizil yorliqlar qora roʻyxat orqali faol doimiy bloklarni bildiradi.",
+ "change_logo": "Logotipni oʻzgartirish",
+ "logo_normal_label": "Oddiy",
+ "logo_dark_label": "Qorongʻi rejim uchun teskari",
+ "configuration": "Konfiguratsiya",
+ "convert_html_to_text": "HTMLni oddiy matnga aylantirish",
+ "copy_to_clipboard": "Matn vaqtinchalik xotiraga koʻchirildi!",
+ "cors_settings": "CORS sozlamalari",
+ "credentials_transport_warning": "<b>Diqqat</b>: Yangi transport xaritasi yozuvi qoʻshish keyingi nuqta ustunlari mos keladigan barcha yozuvlar uchun maʼlumotlarni yangilaydi.",
+ "customer_id": "Mijoz ID",
+ "customize": "Sozlash",
+ "login_page": "Kirish sahifasi",
+ "destination": "Manzil",
+ "dkim_add_key": "ARC/DKIM kaliti qoʻshish",
+ "dkim_domains_selector": "Tanlovchi",
+ "dkim_domains_wo_keys": "Kalit yetishmaydigan domenlarni tanlash",
+ "dkim_from": "Kimdan",
+ "dkim_from_title": "Maʼlumotlarni koʻchirib olish uchun manba domen",
+ "dkim_key_length": "DKIM kalit uzunligi (bit)",
+ "dkim_key_missing": "Kalit yetishmaydi",
+ "dkim_key_unused": "Kalit ishlatilmagan",
+ "dkim_key_valid": "Kalit haqiqiy",
+ "dkim_keys": "ARC/DKIM kalitlari",
+ "dkim_overwrite_key": "Mavjud DKIM kalitini ustidan yozish",
+ "dkim_private_key": "Maxfiy kalit",
+ "dkim_to": "Kimga",
+ "dkim_to_title": "Maqsad domen(lar) — ustidan yoziladi",
+ "domain": "Domen",
+ "domain_admin": "Domen administratori",
+ "domain_admins": "Domen administratorlari",
+ "domainadmin_quicklink": "Domen admin kirish sahifasiga tezkor havolani yashirish",
+ "domain_s": "Domen(lar)",
+ "duplicate": "Nusxalash",
+ "duplicate_dkim": "DKIM yozuvini nusxalash",
+ "edit": "Tahrirlash",
+ "empty": "Natijalar yoʻq",
+ "excludes": "Ushbu qabul qiluvchilarni istisno qiladi",
+ "f2b_ban_time": "Bloklash vaqti (s)",
+ "f2b_ban_time_increment": "Har bir bloklashda blok vaqti ortadi",
+ "f2b_blacklist": "Qora roʻyxatdagi tarmoqlar/xostlar",
+ "f2b_filter": "Regex filtrlari",
+ "f2b_list_info": "Qora roʻyxatdagi xost yoki tarmoq har doim oq roʻyxat elementidan ustun keladi. <b>Roʻyxat yangilanishlarini qoʻllash uchun bir necha soniya kerak boʻladi.</b>",
+ "f2b_manage_external": "Fail2ban ni tashqi boshqarish",
+ "f2b_manage_external_info": "Fail2ban hali ham banlist ni saqlaydi, ammo trafikni bloklash uchun faol qoidalarni oʻrnatmaydi. Trafikni tashqi tomondan bloklash uchun quyida yaratilgan banlist dan foydalaning.",
+ "f2b_max_attempts": "Maks. urinishlar",
+ "f2b_max_ban_time": "Maks. bloklash vaqti (s)",
+ "f2b_netban_ipv4": "Blokni qoʻllash uchun IPv4 subtarmoq oʻlchami (8-32)",
+ "f2b_netban_ipv6": "Blokni qoʻllash uchun IPv6 subtarmoq oʻlchami (8-128)",
+ "f2b_parameters": "Fail2ban parametrlari",
+ "f2b_regex_info": "Eʼtiborga olinadigan jurnallar: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "f2b_retry_window": "Maks. urinishlar uchun qayta urinish oynasi (s)",
+ "f2b_whitelist": "Oq roʻyxatdagi tarmoqlar/xostlar",
+ "filter": "Filtr",
+ "filter_table": "Filtr jadvali",
+ "force_sso_text": "Tashqi OIDC provayder sozlangan boʻlsa, bu variant standart mailcow kirish formalarini yashiradi va faqat Yagona kirish tugmasini koʻrsatadi",
+ "force_sso": "mailcow kirishini oʻchirib, faqat Yagona kirishni koʻrsatish",
+ "forwarding_hosts": "Yoʻnaltirish xostlari",
+ "forwarding_hosts_add_hint": "Siz IPv4/IPv6 manzillarini, CIDR yozuvidagi tarmoqlarni, xost nomlarini (IP manzillariga aylantiriladi) yoki domen nomlarini (SPF TXT yoki yoʻq boʻlsa MX yozuvlarini soʻrash orqali IP manzillariga aylantiriladi) belgilashingiz mumkin.",
+ "forwarding_hosts_hint": "Kiruvchi xabarlar bu yerda keltirilgan istalgan xostlardan shartsiz qabul qilinadi. Bu xostlar keyin DNSBL ga qarshi tekshirilmaydi yoki greylisting ga olinmaydi. Ulardan kelgan spam hech qachon rad etilmaydi, ammo ixtiyoriy ravishda Junk papkasiga joylashtirilishi mumkin. Buning eng keng tarqalgan ishlatilishi — mailcow serveringizga kiruvchi xatlarni yoʻnaltirish qoidasi oʻrnatilgan pochta serverlarini koʻrsatish.",
+ "from": "Kimdan",
+ "generate": "yaratish",
+ "guid": "GUID - noyob nusxa ID si",
+ "guid_and_license": "GUID va litsenziya",
+ "hash_remove_info": "Ratelimit hashini oʻchirish (agar mavjud boʻlsa) uning hisoblagichini butunlay tiklaydi.<br>\r\n Har bir hash alohida rang bilan koʻrsatiladi.",
+ "help_text": "Kirish maskasi ostidagi yordam matnini bekor qilish (HTML ruxsat etilgan)",
+ "host": "Xost",
+ "html": "HTML",
+ "iam": "Identifikatsiya provayderi",
+ "iam_attribute_field": "Atribut maydoni",
+ "iam_authorize_url": "Avtorizatsiya nuqtasi",
+ "iam_auth_flow": "Autentifikatsiya oqimi",
+ "iam_auth_flow_info": "Yagona kirish (SSO) uchun ishlatiladigan Authorization Code Flow (Keycloak da Standard Flow) qoʻshimcha ravishda, mailcow toʻgʻridan-toʻgʻri maʼlumotlar bilan Autentifikatsiya oqimini ham qoʻllab-quvvatlaydi. Mailpassword Flow Keycloak Admin REST API yordamida foydalanuvchi maʼlumotlarini tekshirishga harakat qiladi. mailcow Keycloakda xaritalangan <code>mailcow_password</code> atributidan xeshlangan parolni oladi.",
+ "iam_basedn": "Base DN",
+ "iam_client_id": "Mijoz ID",
+ "iam_client_secret": "Mijoz maxfiy soʻzi",
+ "iam_client_scopes": "Mijoz qamrovlari",
+ "iam_default_template": "Standart shablon",
+ "iam_default_template_description": "Agar foydalanuvchiga shablon tayinlanmagan boʻlsa, pochta qutisini yaratishda standart shablon ishlatiladi, lekin pochta qutisini yangilash uchun emas.",
+ "iam_description": "Autentifikatsiya uchun tashqi provayderni sozlash<br>Foydalanuvchi pochta qutilari atribut xaritalashi oʻrnatilgan boʻlsa, ular birinchi marta kirgan zahoti avtomatik yaratiladi.",
+ "iam_extra_permission": "Quyidagi sozlamalarning ishlashi uchun Keycloak dagi mailcow mijoziga <code>Service account</code> va <code>view-users</code> ruxsati kerak.",
+ "iam_host": "Xost",
+ "iam_host_info": "Bir yoki bir nechta LDAP xostni vergul bilan ajratib kiriting.",
+ "iam_import_users": "Foydalanuvchilarni import qilish",
+ "iam_login_provisioning": "Kirishda foydalanuvchilarni avto-yaratish",
+ "iam_mapping": "Atribut xaritalashi",
+ "iam_bindpass": "Bind paroli",
+ "iam_periodic_full_sync": "Davriy toʻliq sinxronizatsiya",
+ "iam_port": "Port",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "Yoʻnaltirish URL",
+ "iam_rest_flow": "Mailpassword Flow",
+ "iam_server_url": "Server URL",
+ "iam_sso": "Yagona kirish (SSO)",
+ "iam_sync_interval": "Sinxronizatsiya / import oraligʻi (daqiqa)",
+ "iam_test_connection": "Ulanishni tekshirish",
+ "iam_token_url": "Token nuqtasi",
+ "iam_userinfo_url": "Foydalanuvchi maʼlumotlari nuqtasi",
+ "iam_username_field": "Foydalanuvchi nomi maydoni",
+ "iam_binddn": "Bind DN",
+ "iam_use_ssl": "SSL dan foydalanish",
+ "iam_use_ssl_info": "SSL yoqilsa va port 389 ga oʻrnatilgan boʻlsa, u avtomatik ravishda 636 ga oʻzgartiriladi.",
+ "iam_use_tls": "StartTLS dan foydalanish",
+ "iam_use_tls_info": "TLS yoqilsa, LDAP serveringiz uchun standart portni (389) ishlatishingiz kerak. SSL portlari ishlatilmaydi.",
+ "iam_version": "Versiya",
+ "ignore_ssl_error": "SSL xatolarini eʼtiborsiz qoldirish",
+ "import": "Import",
+ "import_private_key": "Maxfiy kalitni import qilish",
+ "in_use_by": "Kim ishlatadi",
+ "inactive": "Nofaol",
+ "include_exclude": "Kiritish/Istisno qilish",
+ "include_exclude_info": "Standart holatda — tanlovsiz — <b>barcha pochta qutilariga</b> murojaat qilinadi",
+ "includes": "Ushbu qabul qiluvchilarni kiritish",
+ "ip_check": "IP tekshiruvi",
+ "ip_check_disabled": "IP tekshiruvi oʻchirilgan. Uni quyidagi joydan yoqishingiz mumkin:<br> <strong>Tizim > Konfiguratsiya > Variantlar > Sozlash</strong>",
+ "ip_check_opt_in": "Tashqi IP manzillarni aniqlash uchun <strong>ipv4.mailcow.email</strong> va <strong>ipv6.mailcow.email</strong> uchinchi tomon xizmatidan foydalanishga rozilik.",
+ "is_mx_based": "MX asosida",
+ "last_applied": "Oxirgi qoʻllanilgan",
+ "license_info": "Litsenziya talab qilinmaydi, ammo bu loyihaning rivojlanishiga yordam beradi.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"SAL order\">GUID ni bu yerda roʻyxatdan oʻtkazing</a> yoki <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Support order\">mailcow oʻrnatmangiz uchun yordam sotib oling.</a>",
+ "link": "Havola",
+ "loading": "Iltimos, kuting...",
+ "login_time": "Kirish vaqti",
+ "logo_info": "Tasviringiz yuqori navigatsiya paneli uchun 40px balandlikka, bosh sahifa uchun maks. 250px kenglikka oʻlchanadi. Masshtablanadigan grafika tavsiya etiladi.",
+ "lookup_mx": "Manzil — MX nomiga mos keladigan muntazam ifoda (<code>.*\\.google\\.com</code> — google.com bilan tugaydigan MX ga yoʻnaltirilgan barcha pochtani ushbu nuqta orqali yoʻnaltirish uchun)",
+ "main_name": "\"mailcow UI\" nomi",
+ "merged_vars_hint": "Kulrang satrlar <code>vars.(local.)inc.php</code> dan birlashtirilgan va oʻzgartirib boʻlmaydi.",
+ "message": "Xabar",
+ "message_size": "Xabar oʻlchami",
+ "nexthop": "Keyingi nuqta",
+ "needs_restart": "qayta ishga tushirish kerak",
+ "no": "✕",
+ "no_active_bans": "Faol bloklar yoʻq",
+ "no_new_rows": "Boshqa satrlar mavjud emas",
+ "no_record": "Yozuv yoʻq",
+ "oauth2_apps": "OAuth2 ilovalari",
+ "oauth2_add_client": "OAuth2 mijozini qoʻshish",
+ "oauth2_client_id": "Mijoz ID",
+ "oauth2_client_secret": "Mijoz maxfiy soʻzi",
+ "oauth2_info": "OAuth2 amalga oshirilishi \"Authorization Code\" grant turini qoʻllab-quvvatlaydi va refresh tokenlarini chiqaradi.<br>\r\nServer shuningdek refresh token ishlatilgandan keyin avtomatik ravishda yangi refresh tokenlarini chiqaradi.<br><br>\r\n• Standart qamrov — <i>profile</i>. Faqat pochta qutisi foydalanuvchilari OAuth2 ga qarshi autentifikatsiya qilinishi mumkin. Agar scope parametri tashlab ketilgan boʻlsa, u <i>profile</i> ga qaytadi.<br>\r\n• <i>state</i> parametri mijoz tomonidan avtorizatsiya soʻrovining bir qismi sifatida yuborilishi shart.<br><br>\r\nOAuth2 API ga soʻrovlar uchun yoʻllar: <br>\r\n<ul>\r\n <li>Avtorizatsiya nuqtasi: <code>/oauth/authorize</code></li>\r\n <li>Token nuqtasi: <code>/oauth/token</code></li>\r\n <li>Resurs sahifasi: <code>/oauth/profile</code></li>\r\n</ul>\r\nMijoz maxfiy soʻzini qayta yaratish mavjud avtorizatsiya kodlarini muddati tugashiga olib kelmaydi, lekin ular tokenni yangilashda muvaffaqiyatsiz boʻladi.<br><br>\r\nMijoz tokenlarini bekor qilish barcha faol sessiyalarning darhol tugashiga olib keladi. Barcha mijozlar qayta autentifikatsiya qilishlari kerak.",
+ "oauth2_redirect_uri": "Yoʻnaltirish URI",
+ "oauth2_renew_secret": "Yangi mijoz maxfiy soʻzini yaratish",
+ "oauth2_revoke_tokens": "Barcha mijoz tokenlarini bekor qilish",
+ "optional": "ixtiyoriy",
+ "options": "Variantlar",
+ "password": "Parol",
+ "password_length": "Parol uzunligi",
+ "password_policy": "Parol siyosati",
+ "password_policy_chars": "Kamida bitta alifbo belgisini oʻz ichiga olishi kerak",
+ "password_policy_length": "Minimal parol uzunligi %d",
+ "password_policy_lowerupper": "Kichik va katta harflarni oʻz ichiga olishi kerak",
+ "password_policy_numbers": "Kamida bitta raqamni oʻz ichiga olishi kerak",
+ "password_policy_special_chars": "Maxsus belgilarni oʻz ichiga olishi kerak",
+ "password_repeat": "Tasdiqlash paroli (takrorlang)",
+ "password_reset_info": "Agar tiklash uchun e-pochta kiritilmagan boʻlsa, bu funksiyadan foydalanib boʻlmaydi.",
+ "password_reset_settings": "Parolni tiklash sozlamalari",
+ "password_reset_tmpl_html": "HTML shablon",
+ "password_reset_tmpl_text": "Matnli shablon",
+ "password_settings": "Parol sozlamalari",
+ "priority": "Muhimlik darajasi",
+ "private_key": "Maxfiy kalit",
+ "quarantine": "Karantin",
+ "quarantine_bcc": "Barcha bildirishnomalarning nusxasini (BCC) ushbu qabul qiluvchiga yuborish:<br><small>Oʻchirish uchun boʻsh qoldiring. <b>Imzolanmagan, tekshirilmagan xat. Faqat ichki yetkazib berilishi kerak.</b></small>",
+ "quarantine_exclude_domains": "Domenlar va taxallus domenlarini istisno qilish",
+ "quarantine_max_age": "Maksimal yosh (kunlarda)<br><small>Qiymat 1 kun yoki undan koʻp boʻlishi kerak.</small>",
+ "quarantine_max_score": "Agar xatning spam bahosi ushbu qiymatdan yuqori boʻlsa, bildirishnomani rad etish:<br><small>Standart 9999.0</small>",
+ "quarantine_max_size": "Maksimal oʻlcham (MiB) (kattaroq elementlar rad etiladi):<br><small>0 cheksizlikni <b>bildirmaydi</b>.</small>",
+ "quarantine_notification_html": "Bildirishnoma e-pochta shabloni:<br><small>Standart shablonni tiklash uchun boʻsh qoldiring.</small>",
+ "quarantine_notification_sender": "Bildirishnoma e-pochta joʻnatuvchisi",
+ "quarantine_notification_subject": "Bildirishnoma e-pochta mavzusi",
+ "quarantine_redirect": "<b>Barcha bildirishnomalarni</b> ushbu qabul qiluvchiga yoʻnaltirish:<br><small>Oʻchirish uchun boʻsh qoldiring. <b>Imzolanmagan, tekshirilmagan xat. Faqat ichki yetkazib berilishi kerak.</b></small>",
+ "quarantine_release_format": "Chiqarilgan elementlar formati",
+ "quarantine_release_format_att": "Ilova sifatida",
+ "quarantine_release_format_raw": "Oʻzgartirilmagan asl nusxa",
+ "quarantine_retention_size": "Pochta qutisi uchun saqlash:<br><small>0 — <b>nofaol</b>ligini bildiradi.</small>",
+ "quicklink_text": "Boshqa kirish sahifalariga tezkor havolalarni kirish formasi ostida koʻrsatish yoki yashirish",
+ "quota_notification_html": "Bildirishnoma e-pochta shabloni:<br><small>Standart shablonni tiklash uchun boʻsh qoldiring.</small>",
+ "quota_notification_sender": "Bildirishnoma e-pochta joʻnatuvchisi",
+ "quota_notification_subject": "Bildirishnoma e-pochta mavzusi",
+ "quota_notifications": "Kvota bildirishnomalari",
+ "quota_notifications_info": "Kvota bildirishnomalari foydalanuvchilarga foydalanish 80% va 95% ga yetganda bir martadan yuboriladi.",
+ "quota_notifications_vars": "{{percent}} — foydalanuvchining joriy kvotasi<br>{{username}} — pochta qutisi nomi",
+ "queue_unban": "blokdan chiqarish",
+ "r_active": "Faol cheklovlar",
+ "r_inactive": "Nofaol cheklovlar",
+ "r_info": "Faol cheklovlar roʻyxatidagi kulrang/oʻchirilgan elementlar mailcow uchun haqiqiy cheklovlar sifatida tanilmaydi va koʻchirib boʻlmaydi. Nomaʼlum cheklovlar baribir koʻrinish tartibida oʻrnatiladi. <br><code>inc/vars.local.inc.php</code> da yangi elementlarni qoʻshib, ularni almashtirishingiz mumkin.",
+ "rate_name": "Tezlik nomi",
+ "recipients": "Qabul qiluvchilar",
+ "refresh": "Yangilash",
+ "regen_api_key": "API kalitini qayta yaratish",
+ "regex_maps": "Regex xaritalari",
+ "relay_from": "\"From:\" manzili",
+ "relay_rcpt": "\"To:\" manzili",
+ "relay_run": "Sinovni ishga tushirish",
+ "relayhosts": "Joʻnatuvchiga bogʻliq transportlar",
+ "relayhosts_hint": "Domen konfiguratsiya muloqotida tanlash mumkin boʻlgan joʻnatuvchiga bogʻliq transportlarni belgilang.<br>\r\n Transport xizmati har doim \"smtp:\" va shuning uchun taklif qilinganda TLS ga harakat qiladi. Oʻralgan TLS (SMTPS) qoʻllab-quvvatlanmaydi. Foydalanuvchining individual chiquvchi TLS siyosati sozlamasi eʼtiborga olinadi.<br>\r\n Taxallus domenlari bilan birga tanlangan domenlarga taʼsir qiladi.",
+ "remove": "Olib tashlash",
+ "remove_row": "Satrni olib tashlash",
+ "reset_default": "Standartga qaytarish",
+ "reset_limit": "Hash ni olib tashlash",
+ "reset_password_vars": "<code>{{link}}</code> Yaratilgan parolni tiklash havolasi<br><code>{{username}}</code> Parolni tiklashni soʻragan foydalanuvchining pochta qutisi nomi<br><code>{{username2}}</code> Tiklash uchun pochta qutisi nomi<br><code>{{date}}</code> Parolni tiklash soʻrovi qilingan sana<br><code>{{token_lifetime}}</code> Daqiqalardagi token muddati<br><code>{{hostname}}</code> mailcow xost nomi",
+ "restore_template": "Standart shablonni tiklash uchun boʻsh qoldiring.",
+ "routing": "Yoʻnaltirish",
+ "rsetting_add_rule": "Qoida qoʻshish",
+ "rsetting_content": "Qoida mazmuni",
+ "rsetting_desc": "Qisqa tavsif",
+ "rsetting_no_selection": "Iltimos, qoidani tanlang",
+ "rsetting_none": "Qoidalar mavjud emas",
+ "rsettings_insert_preset": "Misol presetini kiritish \"%s\"",
+ "rsettings_preset_1": "Autentifikatsiya qilingan foydalanuvchilar uchun DKIM va tezlik chegarasidan boshqa hamma narsani oʻchirib qoʻyish",
+ "rsettings_preset_2": "Postmasterlar spamni xohlaydi",
+ "rsettings_preset_3": "Pochta qutisi uchun faqat maxsus joʻnatuvchilarga ruxsat berish (yaʼni, faqat ichki pochta qutisi sifatida ishlatish)",
+ "rsettings_preset_4": "Domen uchun Rspamd ni oʻchirish",
+ "rspamd_com_settings": "Sozlama nomi avtomatik yaratiladi, quyidagi misol presetlariga qarang. Batafsil maʼlumot uchun <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd hujjatlariga</a> qarang",
+ "rspamd_global_filters": "Global filtr xaritalari",
+ "rspamd_global_filters_agree": "Ehtiyot boʻlaman!",
+ "rspamd_global_filters_info": "Global filtr xaritalari turli xil global rad etish va ruxsat berish roʻyxatlarini oʻz ichiga oladi.",
+ "rspamd_global_filters_regex": "Ularning nomlari ularning maqsadini tushuntiradi. Barcha mazmun \"/pattern/options\" formatidagi haqiqiy muntazam ifodalarni oʻz ichiga olishi kerak (masalan, <code>/.+@domain\\.tld/i</code>).<br>\r\n Har bir regex satriga oddiy tekshiruvlar bajariladi, ammo agar Rspamd sintaksisni toʻgʻri oʻqiy olmasa, uning funksionalligi buzilishi mumkin.<br>\r\n Rspamd oʻzgarganda xarita mazmunini oʻqishga harakat qiladi. Agar muammolarga duch kelsangiz, xarita qayta yuklanishi uchun <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">Rspamd ni qayta ishga tushiring</a>.<br>Qora roʻyxatdagi elementlar karantindan istisno qilinadi.",
+ "rspamd_settings_map": "Rspamd sozlamalar xaritasi",
+ "sal_level": "Moo darajasi",
+ "save": "Oʻzgarishlarni saqlash",
+ "search_domain_da": "Domenlarni qidirish",
+ "send": "Joʻnatish",
+ "sender": "Joʻnatuvchi",
+ "service": "Xizmat",
+ "service_id": "Xizmat ID",
+ "source": "Manba",
+ "spamfilter": "Spam filtri",
+ "subject": "Mavzu",
+ "success": "Muvaffaqiyatli",
+ "sys_mails": "Tizim xatlari",
+ "task": "Vazifa",
+ "text": "Matn",
+ "time": "Vaqt",
+ "title": "Sarlavha",
+ "title_name": "\"mailcow UI\" veb-sayt sarlavhasi",
+ "to_top": "Yuqoriga qaytish",
+ "transport_dest_format": "Regex yoki sintaksis: example.org, .example.org, *, box@example.org (bir nechta qiymatlarni vergul bilan ajratish mumkin)",
+ "transport_maps": "Transport xaritalari",
+ "transport_test_rcpt_info": "• Tashqi manzilga relay qilishni sinash uchun null@hosted.mailcow.de dan foydalaning.",
+ "transports_hint": "• Transport xaritasi yozuvi joʻnatuvchiga bogʻliq transport xaritasidan <b>ustun</b>.<br>\r\n• MX asosidagi transportlar afzalroq ishlatiladi.<br>\r\n• Foydalanuvchi boʻyicha chiquvchi TLS siyosati sozlamalari eʼtiborga olinmaydi va faqat TLS siyosati xaritasi yozuvlari orqali majburlanishi mumkin.<br>\r\n• Belgilangan transportlar uchun transport xizmati har doim \"smtp:\" va shuning uchun taklif qilinganda TLS ga harakat qiladi. Oʻralgan TLS (SMTPS) qoʻllab-quvvatlanmaydi.<br>\r\n• \"/localhost$/\" ga mos keladigan manzillar har doim \"local:\" orqali tashiladi, shuning uchun \"*\" manzili bu manzillarga qoʻllanmaydi.<br>\r\n• Misol uchun keyingi nuqta \"[host]:25\" uchun maʼlumotlarni aniqlash uchun, Postfix <b>har doim</b> \"[host]:25\" ni qidirishdan oldin \"host\" ni soʻraydi. Bu xatti-harakat \"host\" va \"[host]:25\" ni bir vaqtning oʻzida ishlatishni imkonsiz qiladi.",
+ "ui_footer": "Pastki qism (HTML ruxsat etilgan)",
+ "ui_header_announcement": "Eʼlonlar",
+ "ui_header_announcement_active": "Eʼlonni faollashtirish",
+ "ui_header_announcement_content": "Matn (HTML ruxsat etilgan)",
+ "ui_header_announcement_help": "Eʼlon barcha tizimga kirgan foydalanuvchilarga va UI ning kirish ekranida koʻrinadi.",
+ "ui_header_announcement_select": "Eʼlon turini tanlang",
+ "ui_header_announcement_type": "Tur",
+ "ui_header_announcement_type_danger": "Juda muhim",
+ "ui_header_announcement_type_info": "Maʼlumot",
+ "ui_header_announcement_type_warning": "Muhim",
+ "ui_texts": "UI yorliqlari va matnlari",
+ "unban_pending": "blokdan chiqarish kutilmoqda",
+ "unchanged_if_empty": "Oʻzgartirilmagan boʻlsa, boʻsh qoldiring",
+ "upload": "Yuklash",
+ "username": "Foydalanuvchi nomi",
+ "user_link": "Foydalanuvchi havolasi",
+ "user_quicklink": "Foydalanuvchi kirish sahifasiga tezkor havolani yashirish",
+ "validate_license_now": "GUID ni litsenziya serveriga qarshi tekshirish",
+ "verify": "Tasdiqlash",
+ "yes": "✓"
+ },
+ "danger": {
+ "access_denied": "Kirish rad etildi yoki noma'lum forma ma'lumotlari",
+ "tfa_removal_blocked": "Ikki faktorli autentifikatsiyani olib tashlab boʻlmaydi, chunki u sizning hisobingiz uchun talab qilinadi.",
+ "alias_domain_invalid": "%s taxallus domeni noto'g'ri",
+ "alias_empty": "Taxallus manzili boʻsh boʻlmasligi kerak",
+ "alias_goto_identical": "Taxallus va yoʻnaltirish manzili bir xil boʻlmasligi kerak",
+ "alias_invalid": "%s taxallus manzili noto'g'ri",
+ "aliasd_targetd_identical": "Taxallus domeni maqsad domeniga teng boʻlmasligi kerak: %s",
+ "aliases_in_use": "Maks. taxalluslar %d dan katta yoki teng boʻlishi kerak",
+ "app_name_empty": "Ilova nomi boʻsh boʻlolmaydi",
+ "app_passwd_id_invalid": "Ilova paroli ID %s noto'g'ri",
+ "authsource_in_use": "Identifikatsiya provayderini oʻzgartirib yoki oʻchirib boʻlmaydi, chunki u hozirda bir yoki bir nechta foydalanuvchilar tomonidan ishlatilmoqda.",
+ "bcc_empty": "BCC manzili boʻsh boʻlolmaydi",
+ "bcc_exists": "%s turi uchun %s BCC xaritasi mavjud",
+ "bcc_must_be_email": "BCC manzili %s haqiqiy e-pochta manzili emas",
+ "comment_too_long": "Izoh juda uzun, maks. 160 ta belgiga ruxsat berilgan",
+ "cors_invalid_method": "Noto'g'ri Allow-Method belgilangan",
+ "cors_invalid_origin": "Noto'g'ri Allow-Origin belgilangan",
+ "defquota_empty": "Bitta pochta qutisi uchun standart kvota 0 boʻlmasligi kerak.",
+ "demo_mode_enabled": "Demo rejim yoqilgan",
+ "description_invalid": "%s uchun resurs tavsifi noto'g'ri",
+ "dkim_domain_or_sel_exists": "\"%s\" uchun DKIM kaliti mavjud va u ustidan yozilmaydi",
+ "dkim_domain_or_sel_invalid": "DKIM domeni yoki tanlovchi noto'g'ri: %s",
+ "domain_cannot_match_hostname": "Domen xost nomiga mos kelishi mumkin emas",
+ "domain_exists": "%s domeni allaqachon mavjud",
+ "domain_invalid": "Domen nomi boʻsh yoki noto'g'ri",
+ "domain_not_empty": "Boʻsh boʻlmagan %s domenini olib tashlab boʻlmaydi",
+ "domain_not_found": "%s domeni topilmadi",
+ "domain_quota_m_in_use": "Domen kvotasi %s MiB dan katta yoki teng boʻlishi kerak",
+ "extended_sender_acl_denied": "Tashqi joʻnatuvchi manzillarini oʻrnatish uchun ACL yetishmayapti",
+ "extra_acl_invalid": "Tashqi joʻnatuvchi manzili \"%s\" noto'g'ri",
+ "extra_acl_invalid_domain": "Tashqi joʻnatuvchi \"%s\" noto'g'ri domendan foydalanmoqda",
+ "fido2_verification_failed": "FIDO2 tekshiruvi muvaffaqiyatsiz: %s",
+ "file_open_error": "Faylni yozish uchun ochib boʻlmadi",
+ "filter_type": "Notoʻgʻri filtr turi",
+ "from_invalid": "Joʻnatuvchi boʻsh boʻlmasligi kerak",
+ "generic_server_error": "Kutilmagan server xatosi yuz berdi. Iltimos, administratoringiz bilan bogʻlaning.",
+ "global_filter_write_error": "Filtr faylini yozib boʻlmadi: %s",
+ "global_map_invalid": "Global xarita ID %s noto'g'ri",
+ "global_map_write_error": "Global xarita ID %s ni yozib boʻlmadi: %s",
+ "goto_empty": "Taxallus manzili kamida bitta haqiqiy yoʻnaltirish manzilini oʻz ichiga olishi kerak",
+ "goto_invalid": "Yoʻnaltirish manzili %s noto'g'ri",
+ "ham_learn_error": "Ham oʻrgatish xatosi: %s",
+ "iam_test_connection": "Ulanish muvaffaqiyatsiz",
+ "imagick_exception": "Xato: Tasvirni oʻqishda Imagick istisnosi",
+ "img_dimensions_exceeded": "Tasvir maksimal tasvir oʻlchamidan oshib ketdi",
+ "img_invalid": "Tasvir faylini tekshirib boʻlmadi",
+ "img_size_exceeded": "Tasvir maksimal fayl oʻlchamidan oshib ketdi",
+ "img_tmp_missing": "Tasvir faylini tekshirib boʻlmadi: Vaqtinchalik fayl topilmadi",
+ "invalid_bcc_map_type": "Noto'g'ri BCC xarita turi",
+ "invalid_destination": "Manzil formati \"%s\" noto'g'ri",
+ "invalid_filter_type": "Noto'g'ri filtr turi",
+ "invalid_host": "Noto'g'ri xost belgilangan: %s",
+ "invalid_mime_type": "Noto'g'ri MIME turi",
+ "invalid_nexthop": "Keyingi nuqta formati noto'g'ri",
+ "invalid_nexthop_authenticated": "Keyingi nuqta boshqa maʼlumotlar bilan mavjud, iltimos avval bu keyingi nuqta uchun mavjud maʼlumotlarni yangilang.",
+ "invalid_recipient_map_new": "Yangi qabul qiluvchi noto'g'ri belgilangan: %s",
+ "invalid_recipient_map_old": "Asl qabul qiluvchi noto'g'ri belgilangan: %s",
+ "invalid_reset_token": "Noto'g'ri tiklash tokeni",
+ "ip_list_empty": "Ruxsat etilgan IP roʻyxati boʻsh boʻlolmaydi",
+ "is_alias": "%s allaqachon taxallus manzili sifatida tanilgan",
+ "is_alias_or_mailbox": "%s allaqachon taxallus, pochta qutisi yoki taxallus domenidan kengaytirilgan taxallus manzili sifatida tanilgan.",
+ "is_spam_alias": "%s allaqachon vaqtinchalik taxallus manzili (spam taxallus manzili) sifatida tanilgan",
+ "last_key": "Oxirgi kalitni oʻchirib boʻlmaydi, iltimos uning oʻrniga TFA ni oʻchiring.",
+ "login_failed": "Kirish muvaffaqiyatsiz",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "Standart kvota maksimal kvota chegarasidan oshib ketdi",
+ "mailbox_invalid": "Pochta qutisi nomi noto'g'ri",
+ "mailbox_quota_exceeded": "Kvota domen chegarasidan oshib ketdi (maks. %d MiB)",
+ "mailbox_quota_exceeds_domain_quota": "Maks. kvota domen kvota chegarasidan oshib ketdi",
+ "mailbox_quota_left_exceeded": "Yetarli joy qolmadi (qolgan joy: %d MiB)",
+ "mailboxes_in_use": "Maks. pochta qutilari %d dan katta yoki teng boʻlishi kerak",
+ "malformed_username": "Noto'g'ri shakldagi foydalanuvchi nomi",
+ "map_content_empty": "Xarita mazmuni boʻsh boʻlolmaydi",
+ "max_age_invalid": "Maks. yosh %s noto'g'ri",
+ "max_alias_exceeded": "Maks. taxalluslar oshib ketdi",
+ "max_mailbox_exceeded": "Maks. pochta qutilari oshib ketdi (%d / %d)",
+ "max_quota_in_use": "Pochta qutisi kvotasi %d MiB dan katta yoki teng boʻlishi kerak",
+ "maxquota_empty": "Bitta pochta qutisi uchun maks. kvota 0 boʻlmasligi kerak.",
+ "mode_invalid": "Rejim %s noto'g'ri",
+ "mx_invalid": "MX yozuvi %s noto'g'ri",
+ "mysql_error": "MySQL xatosi: %s",
+ "network_host_invalid": "Noto'g'ri tarmoq yoki xost: %s",
+ "next_hop_interferes": "%s keyingi nuqta %s bilan tortishuvga kirishadi",
+ "next_hop_interferes_any": "Mavjud keyingi nuqta %s bilan tortishuvga kirishadi",
+ "nginx_reload_failed": "Nginx qayta yuklash muvaffaqiyatsiz: %s",
+ "no_user_defined": "Foydalanuvchi belgilanmagan",
+ "object_exists": "%s obyekti allaqachon mavjud",
+ "object_is_not_numeric": "%s qiymati raqamli emas",
+ "password_complexity": "Parol siyosatga mos kelmaydi",
+ "password_empty": "Parol boʻsh boʻlmasligi kerak",
+ "password_mismatch": "Tasdiqlash paroli mos kelmadi",
+ "password_reset_invalid_user": "Pochta qutisi topilmadi yoki tiklash uchun e-pochta oʻrnatilmagan",
+ "password_reset_na": "Parolni tiklash hozirda mavjud emas. Iltimos, administratoringiz bilan bogʻlaning.",
+ "policy_list_from_exists": "Berilgan nomli yozuv mavjud",
+ "policy_list_from_invalid": "Yozuv noto'g'ri formatga ega",
+ "private_key_error": "Maxfiy kalit xatosi: %s",
+ "pushover_credentials_missing": "Pushover tokeni va/yoki kaliti yetishmayapti",
+ "pushover_key": "Pushover kaliti notoʻgʻri formatga ega",
+ "pushover_token": "Pushover tokeni notoʻgʻri formatga ega",
+ "quarantine_category_invalid": "Karantin turkumi quyidagilardan biri boʻlishi kerak: add_header, reject, all",
+ "quota_not_0_not_numeric": "Kvota raqamli va >= 0 boʻlishi kerak",
+ "recipient_map_entry_exists": "Qabul qiluvchi xaritasi yozuvi \"%s\" mavjud",
+ "recovery_email_failed": "Tiklash e-pochtasini yuborib boʻlmadi. Iltimos, administratoringiz bilan bogʻlaning.",
+ "redis_error": "Redis xatosi: %s",
+ "relayhost_invalid": "Xarita yozuvi %s noto'g'ri",
+ "release_send_failed": "Xabarni chiqarib boʻlmadi: %s",
+ "required_data_missing": "Talab qilinadigan ma'lumotlar %s yetishmayapti",
+ "reset_f2b_regex": "Regex filtrini oʻz vaqtida tiklab boʻlmadi, iltimos qaytadan urinib koʻring yoki bir necha soniya kuting va sahifani qayta yuklang.",
+ "reset_token_limit_exceeded": "Tiklash tokeni chegarasi oshib ketdi. Iltimos, keyinroq urinib koʻring.",
+ "resource_invalid": "Resurs nomi %s noto'g'ri",
+ "rl_timeframe": "Tezlik chegarasi vaqt oraligʻi noto'g'ri",
+ "rspamd_ui_pw_length": "Rspamd UI paroli kamida 6 ta belgi uzunlikda boʻlishi kerak",
+ "script_empty": "Skript boʻsh boʻlolmaydi",
+ "sender_acl_invalid": "Joʻnatuvchi ACL qiymati %s noto'g'ri",
+ "set_acl_failed": "ACL ni oʻrnatib boʻlmadi",
+ "settings_map_invalid": "Sozlamalar xaritasi ID %s noto'g'ri",
+ "sieve_error": "Sieve tahlilchisi xatosi: %s",
+ "spam_learn_error": "Spam oʻrgatish xatosi: %s",
+ "subject_empty": "Mavzu boʻsh boʻlmasligi kerak",
+ "target_domain_invalid": "Maqsad domen %s noto'g'ri",
+ "targetd_not_found": "Maqsad domen %s topilmadi",
+ "targetd_relay_domain": "Maqsad domen %s relay domen",
+ "template_exists": "%s shabloni allaqachon mavjud",
+ "template_id_invalid": "Shablon ID %s noto'g'ri",
+ "template_name_invalid": "Shablon nomi noto'g'ri",
+ "temp_error": "Vaqtinchalik xato",
+ "text_empty": "Matn boʻsh boʻlmasligi kerak",
+ "tfa_token_invalid": "TFA tokeni noto'g'ri",
+ "tls_policy_map_dest_invalid": "Siyosat manzili noto'g'ri",
+ "tls_policy_map_entry_exists": "TLS siyosati xaritasi yozuvi \"%s\" mavjud",
+ "tls_policy_map_parameter_invalid": "Siyosat parametri noto'g'ri",
+ "to_invalid": "Qabul qiluvchi boʻsh boʻlmasligi kerak",
+ "totp_verification_failed": "TOTP tekshiruvi muvaffaqiyatsiz",
+ "transport_dest_exists": "Transport manzili \"%s\" mavjud",
+ "webauthn_verification_failed": "WebAuthn tekshiruvi muvaffaqiyatsiz: %s",
+ "webauthn_authenticator_failed": "Tanlangan autentifikator topilmadi",
+ "webauthn_publickey_failed": "Tanlangan autentifikator uchun ochiq kalit saqlanmagan",
+ "webauthn_username_failed": "Tanlangan autentifikator boshqa hisobga tegishli",
+ "unknown": "Noma'lum xato yuz berdi",
+ "unknown_tfa_method": "Noma'lum TFA usuli",
+ "unlimited_quota_acl": "Cheksiz kvota ACL tomonidan taqiqlangan",
+ "username_invalid": "Foydalanuvchi nomi %s ishlatib boʻlmaydi",
+ "validity_missing": "Iltimos, amal qilish muddatini tayinlang",
+ "value_missing": "Iltimos, barcha qiymatlarni kiriting",
+ "version_invalid": "Versiya %s noto'g'ri",
+ "yotp_verification_failed": "Yubico OTP tekshiruvi muvaffaqiyatsiz: %s"
+ },
+ "datatables": {
+ "collapse_all": "Hammasini yigʻish",
+ "decimal": ".",
+ "emptyTable": "Jadvalda ma'lumot mavjud emas",
+ "expand_all": "Hammasini kengaytirish",
+ "info": "_TOTAL_ tadan _START_ dan _END_ gacha koʻrsatilmoqda",
+ "infoEmpty": "0 tadan 0 dan 0 gacha koʻrsatilmoqda",
+ "infoFiltered": "(jami _MAX_ tadan filtrlangan)",
+ "infoPostFix": "",
+ "thousands": ",",
+ "lengthMenu": "_MENU_ ta yozuvni koʻrsatish",
+ "loadingRecords": "Yuklanmoqda...",
+ "processing": "Iltimos, kuting...",
+ "search": "Qidirish:",
+ "zeroRecords": "Mos keladigan yozuvlar topilmadi",
+ "paginate": {
+ "first": "Birinchi",
+ "last": "Oxirgi",
+ "next": "Keyingi",
+ "previous": "Oldingi"
+ },
+ "aria": {
+ "sortAscending": ": ustunni oʻsish boʻyicha saralash uchun faollashtiring",
+ "sortDescending": ": ustunni kamayish boʻyicha saralash uchun faollashtiring"
+ }
+ },
+ "debug": {
+ "architecture": "Arxitektura",
+ "chart_this_server": "Diagramma (bu server)",
+ "containers_info": "Konteyner ma'lumotlari",
+ "container_running": "Ishlamoqda",
+ "container_disabled": "Konteyner toʻxtatilgan yoki oʻchirilgan",
+ "container_stopped": "Toʻxtatilgan",
+ "cores": "Yadrolar",
+ "current_time": "Tizim vaqti",
+ "disk_usage": "Disk foydalanish",
+ "docs": "Hujjatlar",
+ "error_show_ip": "Ommaviy IP manzillarini aniqlab boʻlmadi",
+ "external_logs": "Tashqi jurnallar",
+ "history_all_servers": "Tarix (barcha serverlar)",
+ "in_memory_logs": "Xotiradagi jurnallar",
+ "last_modified": "Oxirgi oʻzgartirilgan",
+ "log_info": "<p>mailcow <b>xotiradagi jurnallar</b> Redis roʻyxatlarida toʻplanadi va har daqiqada hammomilik kamaytirish uchun LOG_LINES (%d) ga qisqartiriladi.\r\n <br>Xotiradagi jurnallar doimiy boʻlishi mumkin emas. Xotirada jurnal yurituvchi barcha ilovalar ham Docker daemoniga, demak standart jurnal yuritish drayveriga ham yozadi.\r\n <br>Xotiradagi jurnal turi konteynerlar bilan kichik muammolarni nosozliklarni bartaraf etish uchun ishlatilishi kerak.</p>\r\n <p><b>Tashqi jurnallar</b> berilgan ilovaning API si orqali toʻplanadi.</p>\r\n <p><b>Statik jurnallar</b> asosan faollik jurnallaridir, ular Dockerd ga yozilmaydi, lekin baribir doimiy boʻlishi kerak (API jurnallaridan tashqari).</p>",
+ "login_time": "Vaqt",
+ "logs": "Jurnallar",
+ "memory": "Xotira",
+ "online_users": "Onlayn foydalanuvchilar",
+ "restart_container": "Qayta ishga tushirish",
+ "service": "Xizmat",
+ "show_ip": "Ommaviy IP ni koʻrsatish",
+ "size": "Oʻlcham",
+ "started_at": "Boshlangan vaqt",
+ "started_on": "Boshlangan sana",
+ "static_logs": "Statik jurnallar",
+ "success": "Muvaffaqiyatli",
+ "system_containers": "Tizim va konteynerlar",
+ "timezone": "Vaqt mintaqasi",
+ "uptime": "Ishlash vaqti",
+ "update_available": "Yangilanish mavjud",
+ "no_update_available": "Tizim oxirgi versiyada",
+ "update_failed": "Yangilanishni tekshirib boʻlmadi",
+ "username": "Foydalanuvchi nomi",
+ "wip": "Hozir ishlab chiqilmoqda"
+ },
+ "diagnostics": {
+ "cname_from_a": "Qiymat A/AAAA yozuvidan olingan. Yozuv toʻgʻri resursga ishora qilsa, bu qoʻllab-quvvatlanadi.",
+ "dns_records": "DNS yozuvlari",
+ "dns_records_24hours": "DNS ga kiritilgan oʻzgarishlar ushbu sahifada toʻgʻri aks ettirilishi uchun 24 soatgacha vaqt ketishi mumkinligini hisobga oling. Bu DNS yozuvlaringizni qanday sozlash kerakligini osongina koʻrish va barcha yozuvlaringiz DNS da toʻgʻri saqlanganligini tekshirish uchun moʻljallangan.",
+ "dns_records_data": "Toʻgʻri ma'lumot",
+ "dns_records_docs": "Iltimos, <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">hujjatlarga</a> ham murojaat qiling.",
+ "dns_records_name": "Nomi",
+ "dns_records_status": "Joriy holat",
+ "dns_records_type": "Tur",
+ "optional": "Bu yozuv ixtiyoriy."
+ },
+ "edit": {
+ "acl": "ACL (Ruxsat)",
+ "active": "Faol",
+ "admin": "Administratorni tahrirlash",
+ "advanced_settings": "Kengaytirilgan sozlamalar",
+ "alias": "Taxallusni tahrirlash",
+ "allow_from_smtp": "Faqat ushbu IP larga <b>SMTP</b> dan foydalanishga ruxsat berish",
+ "allow_from_smtp_info": "Barcha joʻnatuvchilarga ruxsat berish uchun boʻsh qoldiring.<br>IPv4/IPv6 manzillari va tarmoqlari.",
+ "allowed_protocols": "Toʻgʻridan-toʻgʻri foydalanuvchi kirishi uchun ruxsat etilgan protokollar (ilova paroli protokollariga taʼsir qilmaydi)",
+ "app_name": "Ilova nomi",
+ "app_passwd": "Ilova paroli",
+ "app_passwd_protocols": "Ilova paroli uchun ruxsat etilgan protokollar",
+ "automap": "Papkalarni avtomatik xaritalashga harakat qilish (\"Sent items\", \"Sent\" => \"Sent\" va h.k.)",
+ "backup_mx_options": "Relay sozlamalari",
+ "bcc_dest_format": "BCC manzili bitta haqiqiy e-pochta manzili boʻlishi kerak.<br>Agar bir nechta manzilga nusxa joʻnatish kerak boʻlsa, taxallus yarating va shu yerda ishlating.",
+ "client_id": "Mijoz ID",
+ "client_secret": "Mijoz maxfiy soʻzi",
+ "comment_info": "Maxfiy izoh foydalanuvchiga koʻrinmaydi, ommaviy izoh esa foydalanuvchi koʻrinishida ustiga sichqoncha kelganda maslahat sifatida koʻrsatiladi",
+ "created_on": "Yaratilgan sana",
+ "custom_attributes": "Maxsus atributlar",
+ "delete1": "Tugatilgach manbadan oʻchirish",
+ "delete2": "Manbada boʻlmagan xabarlarni manzildan oʻchirish",
+ "delete2duplicates": "Manzildagi dublikatlarni oʻchirish",
+ "delete_ays": "Iltimos, oʻchirish jarayonini tasdiqlang.",
+ "description": "Tavsif",
+ "disable_login": "Kirishni taqiqlash (kiruvchi pochta hali ham qabul qilinadi)",
+ "domain": "Domenni tahrirlash",
+ "domain_admin": "Domen administratorini tahrirlash",
+ "domain_footer": "Domen boʻyicha pastki qism",
+ "domain_footer_html": "HTML pastki qism",
+ "domain_footer_info": "Domen boʻyicha pastki qismlar ushbu domendagi manzilga bog'liq barcha chiquvchi xatlarga qoʻshiladi. <br> Pastki qism uchun quyidagi oʻzgaruvchilarni ishlatish mumkin:",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - MTA tomonidan belgilangan autentifikatsiya qilingan foydalanuvchi nomi",
+ "from_user": "{= from_user =} - Konvertning Kimdan qismi, masalan \"moo@mailcow.tld\" uchun \"moo\" qaytaradi",
+ "from_name": "{= from_name =} - Konvertning Kimdan ismi, masalan \"Mailcow <moo@mailcow.tld>\" uchun \"Mailcow\" qaytaradi",
+ "from_addr": "{= from_addr =} - Konvertning Kimdan manzili qismi",
+ "from_domain": "{= from_domain =} - Konvertning Kimdan domeni qismi",
+ "custom": "{= foo =} - Agar pochta qutisida \"bar\" qiymatli \"foo\" maxsus atributi boʻlsa \"bar\" qaytaradi"
+ },
+ "domain_footer_plain": "PLAIN pastki qism",
+ "domain_footer_skip_replies": "Javob xatlarida pastki qismni e'tiborsiz qoldirish",
+ "domain_quota": "Domen kvotasi",
+ "domains": "Domenlar",
+ "dont_check_sender_acl": "%s domeni uchun joʻnatuvchi tekshiruvini oʻchirish (+ taxallus domenlari)",
+ "edit_alias_domain": "Taxallus domenini tahrirlash",
+ "encryption": "Shifrlash",
+ "exclude": "Obyektlarni istisno qilish (regex)",
+ "extended_sender_acl": "Tashqi joʻnatuvchi manzillari",
+ "extended_sender_acl_info": "DKIM domen kaliti mavjud boʻlsa, import qilinishi kerak.<br>\r\n Ushbu serverni mos SPF TXT yozuviga qoʻshishni unutmang.<br>\r\n Ushbu serverga tashqi manzil bilan ust-ust tushadigan domen yoki taxallus domeni qoʻshilganda, tashqi manzil olib tashlanadi.<br>\r\n *@domain.tld sifatida joʻnatishga ruxsat berish uchun @domain.tld dan foydalaning.",
+ "force_pw_update": "Keyingi kirishda parolni majburiy yangilash",
+ "force_pw_update_info": "Bu foydalanuvchi faqat %s ga kira oladi. Ilova parollari ishlash holatida qoladi.",
+ "footer_exclude": "Pastki qismdan istisno qilish",
+ "full_name": "Toʻliq ism",
+ "gal": "Global manzillar roʻyxati",
+ "gal_info": "GAL domenning barcha obyektlarini oʻz ichiga oladi va hech bir foydalanuvchi tomonidan tahrirlanmaydi. Oʻchirilsa, SOGodagi bandlik maʼlumotlari yoʻqoladi! <b>Oʻzgarishlarni qoʻllash uchun SOGoni qayta ishga tushiring.</b>",
+ "generate": "yaratish",
+ "grant_types": "Grant turlari",
+ "hostname": "Xost nomi",
+ "inactive": "Nofaol",
+ "internal": "Ichki",
+ "internal_info": "Ichki taxalluslarga faqat oʻz domeni yoki taxallus domenlaridan kirish mumkin.",
+ "sender_allowed": "Ushbu taxallus orqali joʻnatishga ruxsat berish",
+ "sender_allowed_info": "Oʻchirilgan boʻlsa, bu taxallus faqat xat qabul qilishi mumkin. Maxsus pochta qutilariga joʻnatishga ruxsat berish uchun joʻnatuvchi ACL dan foydalaning.",
+ "kind": "Turi",
+ "last_modified": "Oxirgi oʻzgartirilgan",
+ "lookup_mx": "Manzil — MX nomiga mos keladigan muntazam ifoda (<code>.*\\.google\\.com</code> — google.com bilan tugaydigan MX ga yoʻnaltirilgan barcha pochtani ushbu nuqta orqali yoʻnaltirish uchun)",
+ "mailbox": "Pochta qutisini tahrirlash",
+ "mailbox_quota_def": "Standart pochta qutisi kvotasi",
+ "mailbox_relayhost_info": "Faqat pochta qutisi va to'g'ridan-to'g'ri taxalluslarga qoʻllaniladi, domen relay xostini bekor qiladi.",
+ "mailbox_rename": "Pochta qutisini qayta nomlash",
+ "mailbox_rename_agree": "Men zaxira nusxasini yaratdim.",
+ "mailbox_rename_warning": "MUHIM! Pochta qutisini qayta nomlashdan oldin zaxira nusxasi yarating.",
+ "mailbox_rename_alias": "Taxallusni avtomatik yaratish",
+ "mailbox_rename_title": "Yangi mahalliy pochta qutisi nomi",
+ "max_aliases": "Maks. taxalluslar",
+ "max_mailboxes": "Mumkin boʻlgan maks. pochta qutilari",
+ "max_quota": "Bitta pochta qutisining maks. kvotasi (MiB)",
+ "maxage": "Masofadan soʻraladigan xabarlarning maksimal yoshi (kunlarda)<br><small>(0 = yoshni e'tiborsiz qoldirish)</small>",
+ "maxbytespersecond": "Maks. soniyaga bayt <br><small>(0 = cheksiz)</small>",
+ "mbox_rl_info": "Bu tezlik chegarasi SASL kirish nomiga qoʻllaniladi, u kirgan foydalanuvchi tomonidan ishlatiladigan har qanday \"from\" manziliga mos keladi. Pochta qutisi tezlik chegarasi domen boʻyicha tezlik chegarasini bekor qiladi.",
+ "mins_interval": "Oraliq (daqiqa)",
+ "mta_sts": "MTA-STS",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> — pochta serverlari oʻrtasida xat yetkazib berishni haqiqiy sertifikatli TLS dan foydalanishga majburlovchi standart. <br>U DNSSEC mavjud emasligi yoki qoʻllab-quvvatlanmasligi sababli <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> imkoni boʻlmaganda ishlatiladi.<br><b>Eslatma</b>: Agar qabul qiluvchi domen DNSSEC bilan DANE ni qoʻllab-quvvatlasa, DANE <b>har doim</b> afzal koʻriladi — MTA-STS faqat zaxira sifatida ishlaydi.",
+ "mta_sts_version": "Versiya",
+ "mta_sts_version_info": "MTA-STS standartining versiyasini belgilaydi — hozirda faqat <code>STSv1</code> haqiqiy.",
+ "mta_sts_mode": "Rejim",
+ "mta_sts_mode_info": "Tanlash uchun uchta rejim mavjud:<ul><li><em>testing</em> — siyosat faqat kuzatiladi, buzilishlar taʼsir koʻrsatmaydi.</li><li><em>enforce</em> — siyosat qatʼiy qoʻllaniladi, haqiqiy TLS siz ulanishlar rad etiladi.</li><li><em>none</em> — siyosat eʼlon qilinadi, ammo qoʻllanilmaydi.</li></ul>",
+ "mta_sts_max_age": "Maks. yosh",
+ "mta_sts_max_age_info": "Qabul qiluvchi pochta serverlari ushbu siyosatni qayta olishdan oldin keshlashi mumkin boʻlgan vaqt (soniyalarda).",
+ "mta_sts_mx": "MX server",
+ "mta_sts_mx_info": "Faqat aniq sanab oʻtilgan pochta server xost nomlariga joʻnatishga ruxsat beradi; joʻnatuvchi MTA DNS MX xost nomi siyosat roʻyxatiga mos kelishini tekshiradi va faqat haqiqiy TLS sertifikati bilan yetkazib berishga ruxsat beradi (MITM ga qarshi himoya qiladi).",
+ "mta_sts_mx_notice": "Bir nechta MX serverlar belgilanishi mumkin (vergul bilan ajratilgan).",
+ "multiple_bookings": "Bir nechta bandlovlar",
+ "none_inherit": "Hech biri / Meros qilib olish",
+ "nexthop": "Keyingi nuqta",
+ "password": "Parol",
+ "password_recovery_email": "Parolni tiklash e-pochtasi",
+ "password_repeat": "Tasdiqlash paroli (takrorlang)",
+ "previous": "Oldingi sahifa",
+ "private_comment": "Maxfiy izoh",
+ "public_comment": "Ommaviy izoh",
+ "pushover": "Pushover",
+ "pushover_evaluate_x_prio": "Yuqori muhimlikdagi xatni eskalatsiya qilish [<code>X-Priority: 1</code>]",
+ "pushover_info": "Push bildirishnoma sozlamalari <b>%s</b> ga taxalluslar bilan birga (umumiy, umumiy boʻlmagan, teglangan) yetkazib beriladigan barcha toza (spam boʻlmagan) xatlarga qoʻllaniladi.",
+ "pushover_only_x_prio": "Faqat yuqori muhimlikdagi xatlarni koʻrib chiqish [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Faqat quyidagi joʻnatuvchi e-pochta manzillarini koʻrib chiqish <small>(vergul bilan ajratilgan)</small>",
+ "pushover_sender_regex": "Quyidagi joʻnatuvchi regexini koʻrib chiqish",
+ "pushover_text": "Bildirishnoma matni",
+ "pushover_title": "Bildirishnoma sarlavhasi",
+ "pushover_sound": "Tovush",
+ "pushover_vars": "Joʻnatuvchi filtri belgilanmagan boʻlsa, barcha xatlar koʻrib chiqiladi.<br>Regex filtrlari va aniq joʻnatuvchi tekshiruvlari alohida belgilanishi mumkin va ketma-ket koʻrib chiqiladi. Ular bir-biriga bogʻliq emas.<br>Matn va sarlavha uchun ishlatiladigan oʻzgaruvchilar (ma'lumotlarni himoya qilish siyosatiga e'tibor bering)",
+ "pushover_verify": "Maʼlumotlarni tekshirish",
+ "quota_mb": "Kvota (MiB)",
+ "quota_warning_bcc": "Kvota ogohlantirishi BCC",
+ "quota_warning_bcc_info": "Ogohlantirishlar alohida nusxa sifatida quyidagi qabul qiluvchilarga yuboriladi. Mavzu mos foydalanuvchi nomi bilan qavs ichida qoʻshib qoʻyiladi, masalan: <code>Kvota ogohlantirishi (user@example.com)</code>.",
+ "ratelimit": "Tezlik chegarasi",
+ "redirect_uri": "Yoʻnaltirish/Qaytarish URL",
+ "relay_all": "Barcha qabul qiluvchilarni relay qilish",
+ "relay_all_info": "↪ Agar barcha qabul qiluvchilarni relay qilmaslikni tanlasangiz, relay qilinishi kerak boʻlgan har bir qabul qiluvchi uchun (\"koʻr\") pochta qutisi qoʻshishingiz kerak boʻladi.",
+ "relay_domain": "Ushbu domenni relay qilish",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Maʼlumot</div> Bu domen uchun maxsus manzilga transport xaritalarini belgilashingiz mumkin. Agar oʻrnatilmagan boʻlsa, MX qidiruvi amalga oshiriladi.",
+ "relay_unknown_only": "Faqat mavjud boʻlmagan pochta qutilarini relay qilish. Mavjud pochta qutilari mahalliy yetkazib beriladi.",
+ "relayhost": "Joʻnatuvchiga bogʻliq transportlar",
+ "remove": "Olib tashlash",
+ "resource": "Resurs",
+ "save": "Oʻzgarishlarni saqlash",
+ "scope": "Qamrov",
+ "sender_acl": "Quyidagi sifatida joʻnatishga ruxsat berish",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Joʻnatuvchi tekshiruvi oʻchirilgan</span>",
+ "sender_acl_info": "Agar A pochta qutisi foydalanuvchisi B pochta qutisi foydalanuvchisi sifatida joʻnatishga ruxsat etilgan boʻlsa, joʻnatuvchi manzili SOGo da tanlanadigan \"from\" maydoni sifatida avtomatik koʻrsatilmaydi.<br>\r\n B pochta qutisi foydalanuvchisi A pochta qutisi foydalanuvchisi oʻz manzilini joʻnatuvchi sifatida tanlay olishi uchun SOGo da delegatsiya yaratishi kerak. SOGo da pochta qutisini delegatsiya qilish uchun pochta koʻrinishida yuqori chap qismdagi pochta qutisi nomingiz oʻng tomonidagi menyudan (uch nuqta) foydalaning. Bu xatti-harakat taxallus manzillariga qoʻllanmaydi.",
+ "sieve_desc": "Qisqa tavsif",
+ "sieve_type": "Filtr turi",
+ "skipcrossduplicates": "Papkalararo dublikat xabarlarni oʻtkazib yuborish (birinchi kelgan, birinchi xizmatlanadi)",
+ "sogo_access": "SOGo ga toʻgʻridan-toʻgʻri yoʻnaltirish",
+ "sogo_access_info": "Tizimga kirgandan keyin foydalanuvchi avtomatik ravishda SOGo ga yoʻnaltiriladi.",
+ "sogo_visible": "Taxallus SOGo da koʻrinadi",
+ "sogo_visible_info": "Bu variant faqat SOGo da koʻrsatilishi mumkin boʻlgan obyektlarga taʼsir qiladi (kamida bitta mahalliy pochta qutisiga ishora qiluvchi umumiy yoki umumiy boʻlmagan taxallus manzillari). Yashirilgan boʻlsa, taxallus SOGo da tanlanadigan joʻnatuvchi sifatida koʻrinmaydi.",
+ "spam_alias": "Vaqt cheklangan taxallus manzillarini yaratish yoki oʻzgartirish",
+ "spam_filter": "Spam filtri",
+ "spam_policy": "Elementlarni ruxsat etilgan/qora roʻyxatga qoʻshish yoki olib tashlash",
+ "spam_score": "Maxsus spam bahosini oʻrnatish",
+ "subfolder2": "Manzilning subpapkasiga sinxronizatsiya qilish<br><small>(boʻsh = subpapkadan foydalanmang)</small>",
+ "syncjob": "Sinxronizatsiya vazifasini tahrirlash",
+ "target_address": "Yoʻnaltirish manzil(lar)i <small>(vergul bilan ajratilgan)</small>",
+ "target_domain": "Maqsad domen",
+ "timeout1": "Masofaviy xostga ulanish vaqtining tugashi",
+ "timeout2": "Mahalliy xostga ulanish vaqtining tugashi",
+ "title": "Obyektni tahrirlash",
+ "unchanged_if_empty": "Oʻzgartirilmagan boʻlsa, boʻsh qoldiring",
+ "username": "Foydalanuvchi nomi",
+ "validate_save": "Tekshirish va saqlash"
+ },
+ "fido2": {
+ "confirm": "Tasdiqlash",
+ "fido2_auth": "FIDO2 bilan kirish",
+ "fido2_success": "Qurilma muvaffaqiyatli roʻyxatdan oʻtkazildi",
+ "fido2_validation_failed": "Tekshirish muvaffaqiyatsiz",
+ "fn": "Doʻstona nom",
+ "known_ids": "Maʼlum ID lar",
+ "none": "Oʻchirilgan",
+ "register_status": "Roʻyxatga olish holati",
+ "rename": "Qayta nomlash",
+ "set_fido2": "FIDO2 qurilmasini roʻyxatdan oʻtkazish",
+ "set_fido2_touchid": "Apple M1 da Touch ID ni roʻyxatdan oʻtkazish",
+ "set_fn": "Doʻstona nomni oʻrnatish",
+ "start_fido2_validation": "FIDO2 tekshiruvini boshlash"
+ },
+ "footer": {
+ "cancel": "Bekor qilish",
+ "confirm_delete": "Oʻchirishni tasdiqlash",
+ "delete_now": "Hozir oʻchirish",
+ "delete_these_items": "Iltimos, quyidagi obyekt ID siga oʻzgarishlaringizni tasdiqlang",
+ "hibp_check": "haveibeenpwned.com ga qarshi tekshirish",
+ "hibp_nok": "Mos keldi! Bu xavfli parol boʻlishi mumkin!",
+ "hibp_ok": "Mos kelmadi.",
+ "loading": "Iltimos, kuting...",
+ "nothing_selected": "Hech narsa tanlanmadi",
+ "restart_container": "Konteynerni qayta ishga tushirish",
+ "restart_container_info": "<b>Muhim:</b> Yumshoq qayta ishga tushirish biroz vaqt olishi mumkin, iltimos uning tugashini kuting.",
+ "restart_now": "Hozir qayta ishga tushirish",
+ "restarting_container": "Konteyner qayta ishga tushirilmoqda, bu biroz vaqt olishi mumkin"
+ },
+ "header": {
+ "administration": "Konfiguratsiya va tafsilotlar",
+ "apps": "Ilovalar",
+ "debug": "Maʼlumot",
+ "email": "E-pochta",
+ "mailcow_system": "Tizim",
+ "mailcow_config": "Konfiguratsiya",
+ "quarantine": "Karantin",
+ "restart_netfilter": "Netfilterni qayta ishga tushirish",
+ "restart_sogo": "SOGoni qayta ishga tushirish",
+ "user_settings": "Foydalanuvchi sozlamalari"
+ },
+ "info": {
+ "awaiting_tfa_confirmation": "TFA tasdiqlanishi kutilmoqda",
+ "no_action": "Amal qoʻllanib boʻlmaydi",
+ "session_expires": "Sessiyangiz taxminan 15 soniyadan keyin tugaydi"
+ },
+ "login": {
+ "back_to_mailcow": "mailcow ga qaytish",
+ "delayed": "Kirish %s soniyaga kechiktirildi.",
+ "fido2_webauthn": "FIDO2/WebAuthn kirish",
+ "forgot_password": "> Parolni unutdingizmi?",
+ "invalid_pass_reset_token": "Parolni tiklash tokeni noto'g'ri yoki muddati tugagan.<br>Iltimos, yangi parolni tiklash havolasini soʻrang.",
+ "login": "Kirish",
+ "login_linkstext": "Toʻgʻri kirish emasmi?",
+ "login_usertext": "Foydalanuvchi sifatida kirish",
+ "login_domainadmintext": "Domen administratori sifatida kirish",
+ "login_admintext": "Administrator sifatida kirish",
+ "login_user": "Foydalanuvchi kirishi",
+ "login_dadmin": "Domen-administratori kirishi",
+ "login_admin": "Administrator kirishi",
+ "mobileconfig_info": "Soʻralgan Apple ulanish profilini yuklab olish uchun pochta qutisi foydalanuvchisi sifatida kiring.",
+ "new_password": "Yangi parol",
+ "new_password_confirm": "Yangi parolni tasdiqlang",
+ "other_logins": "yoki quyidagi orqali kiring",
+ "password": "Parol",
+ "reset_password": "Parolni tiklash",
+ "request_reset_password": "Parol oʻzgartirishni soʻrash",
+ "username": "Foydalanuvchi nomi",
+ "email": "E-pochta manzili"
+ },
+ "mailbox": {
+ "action": "Amal",
+ "activate": "Faollashtirish",
+ "active": "Faol",
+ "add": "Qoʻshish",
+ "add_alias": "Taxallus qoʻshish",
+ "add_alias_expand": "Taxallusni taxallus domenlari boʻylab kengaytirish",
+ "add_bcc_entry": "BCC xaritasi qoʻshish",
+ "add_domain": "Domen qoʻshish",
+ "add_domain_alias": "Domen taxallusini qoʻshish",
+ "add_domain_record_first": "Iltimos, avval domen qoʻshing",
+ "add_filter": "Filtr qoʻshish",
+ "add_mailbox": "Pochta qutisi qoʻshish",
+ "add_recipient_map_entry": "Qabul qiluvchi xaritasini qoʻshish",
+ "add_resource": "Resurs qoʻshish",
+ "add_template": "Shablon qoʻshish",
+ "add_tls_policy_map": "TLS siyosati xaritasini qoʻshish",
+ "address_rewriting": "Manzilni qayta yozish",
+ "alias": "Taxallus",
+ "alias_domain_alias_hint": "Taxalluslar domen taxalluslariga avtomatik <b>qoʻllanilmaydi</b>. <code>my-alias@domain</code> taxallus manzili <code>my-alias@alias-domain</code> manzilini <b>qoplamaydi</b> (bu yerda \"alias-domain\" — \"domain\" uchun tasavvur qilingan taxallus domeni).<br>Tashqi pochta qutisiga xatni yoʻnaltirish uchun sieve filtridan foydalaning (\"Filtrlar\" yorligʻiga qarang yoki SOGo -> Forwarder dan foydalaning). Yoʻq taxalluslarni avtomatik qoʻshish uchun \"Taxallusni taxallus domenlari boʻylab kengaytirish\" dan foydalaning.",
+ "alias_domain_backupmx": "Relay domeni uchun taxallus domeni nofaol",
+ "aliases": "Taxalluslar",
+ "all_domains": "Barcha domenlar",
+ "allow_from_smtp": "Faqat ushbu IP larga <b>SMTP</b> dan foydalanishga ruxsat berish",
+ "allow_from_smtp_info": "Barcha joʻnatuvchilarga ruxsat berish uchun boʻsh qoldiring.<br>IPv4/IPv6 manzillari va tarmoqlari.",
+ "allowed_protocols": "Ruxsat etilgan protokollar",
+ "backup_mx": "Relay domeni",
+ "bcc": "BCC",
+ "bcc_destination": "BCC manzili",
+ "bcc_destinations": "BCC manzili",
+ "bcc_info": "BCC xaritalari barcha xabarlarning nusxalarini boshqa manzilga jimgina yoʻnaltirish uchun ishlatiladi. Qabul qiluvchi xaritasi turi yozuvi mahalliy manzil xatning qabul qiluvchisi sifatida ishlaganda ishlatiladi. Joʻnatuvchi xaritalari ham xuddi shu tamoyilga muvofiq ishlaydi.<br/>\r\n Mahalliy manzilga yetkazib berish muvaffaqiyatsiz boʻlsa, xabar berilmaydi.",
+ "bcc_local_dest": "Mahalliy manzil",
+ "bcc_map": "BCC xaritasi",
+ "bcc_map_type": "BCC turi",
+ "bcc_maps": "BCC xaritalari",
+ "bcc_rcpt_map": "Qabul qiluvchi xaritasi",
+ "bcc_sender_map": "Joʻnatuvchi xaritasi",
+ "bcc_to_rcpt": "Qabul qiluvchi xaritasi turiga oʻtish",
+ "bcc_to_sender": "Joʻnatuvchi xaritasi turiga oʻtish",
+ "bcc_type": "BCC turi",
+ "booking_null": "Doimo boʻsh sifatida koʻrsatish",
+ "booking_0_short": "Doimo boʻsh",
+ "booking_custom": "Maxsus bandlovlar soni bilan qatʼiy cheklash",
+ "booking_custom_short": "Qatʼiy chegara",
+ "booking_ltnull": "Cheksiz, lekin bandlangan boʻlsa band sifatida koʻrsatish",
+ "booking_lt0_short": "Yumshoq chegara",
+ "catch_all": "Hammasini-qabul qilish",
+ "created_on": "Yaratilgan sana",
+ "daily": "Kunlik",
+ "deactivate": "Oʻchirish",
+ "description": "Tavsif",
+ "disable_login": "Kirishni taqiqlash (kiruvchi pochta hali ham qabul qilinadi)",
+ "disable_x": "Oʻchirish",
+ "dkim_domains_selector": "Tanlovchi",
+ "dkim_key_length": "DKIM kalit uzunligi (bit)",
+ "domain": "Domen",
+ "domain_admins": "Domen administratorlari",
+ "domain_aliases": "Domen taxalluslari",
+ "domain_templates": "Domen shablonlari",
+ "domain_quota": "Kvota",
+ "domain_quota_total": "Umumiy domen kvotasi",
+ "domains": "Domenlar",
+ "edit": "Tahrirlash",
+ "empty": "Natijalar yoʻq",
+ "enable_x": "Yoqish",
+ "excludes": "Istisnolar",
+ "filter_table": "Filtr jadvali",
+ "filters": "Filtrlar",
+ "fname": "Toʻliq ism",
+ "force_pw_update": "Keyingi kirishda parolni majburiy yangilash",
+ "gal": "Global manzillar roʻyxati",
+ "goto_ham": "<b>ham</b> sifatida oʻrgatish",
+ "goto_spam": "<b>spam</b> sifatida oʻrgatish",
+ "hourly": "Soatlik",
+ "iam": "Identifikatsiya provayderi",
+ "in_use": "Foydalanilmoqda (%)",
+ "inactive": "Nofaol",
+ "insert_preset": "Misol presetini kiritish \"%s\"",
+ "internal": "Ichki",
+ "kind": "Turi",
+ "last_mail_login": "Oxirgi pochta kirishi",
+ "last_modified": "Oxirgi oʻzgartirilgan",
+ "last_pw_change": "Oxirgi parol oʻzgarishi",
+ "last_run": "Oxirgi ishga tushirilgan",
+ "last_run_reset": "Keyingisini rejalashtirish",
+ "mailbox": "Pochta qutisi",
+ "mailbox_defaults": "Standart sozlamalar",
+ "mailbox_defaults_info": "Yangi pochta qutilari uchun standart sozlamalarni belgilang.",
+ "mailbox_defquota": "Standart pochta qutisi oʻlchami",
+ "mailbox_templates": "Pochta qutisi shablonlari",
+ "mailbox_quota": "Pochta qutisining maks. oʻlchami",
+ "mailboxes": "Pochta qutilari",
+ "max_aliases": "Maks. taxalluslar",
+ "max_mailboxes": "Mumkin boʻlgan maks. pochta qutilari",
+ "max_quota": "Bitta pochta qutisining maks. kvotasi",
+ "mins_interval": "Oraliq (daqiqa)",
+ "msg_num": "Xabar #",
+ "multiple_bookings": "Bir nechta bandlovlar",
+ "never": "Hech qachon",
+ "no": "✕",
+ "no_record": "%s obyekti uchun yozuv yoʻq",
+ "no_record_single": "Yozuv yoʻq",
+ "open_logs": "Jurnallarni ochish",
+ "owner": "Egasi",
+ "private_comment": "Maxfiy izoh",
+ "public_comment": "Ommaviy izoh",
+ "q_add_header": "Junk papkasiga koʻchirilganda",
+ "q_all": " Junk papkasiga koʻchirilganda va rad etilganda",
+ "q_reject": "rad etilganda",
+ "quarantine_category": "Karantin bildirishnoma turkumi",
+ "quarantine_notification": "Karantin bildirishnomalari",
+ "quick_actions": "Amallar",
+ "recipient": "Qabul qiluvchi",
+ "recipient_map": "Qabul qiluvchi xaritasi",
+ "recipient_map_info": "Qabul qiluvchi xaritalari xabar yetkazib berilishidan oldin manzilni almashtirish uchun ishlatiladi.",
+ "recipient_map_new": "Yangi qabul qiluvchi",
+ "recipient_map_new_info": "Qabul qiluvchi xaritasi manzili haqiqiy e-pochta manzili yoki domen nomi boʻlishi kerak.",
+ "recipient_map_old": "Asl qabul qiluvchi",
+ "recipient_map_old_info": "Qabul qiluvchi xaritasining asl manzili haqiqiy e-pochta manzili yoki domen nomi boʻlishi kerak.",
+ "recipient_maps": "Qabul qiluvchi xaritalari",
+ "relay_all": "Barcha qabul qiluvchilarni relay qilish",
+ "relay_unknown": "Nomaʼlum pochta qutilarini relay qilish",
+ "remove": "Olib tashlash",
+ "resources": "Resurslar",
+ "running": "Ishlamoqda",
+ "sender": "Joʻnatuvchi",
+ "set_postfilter": "Postfiltr sifatida belgilash",
+ "set_prefilter": "Prefiltr sifatida belgilash",
+ "sieve_info": "Bitta foydalanuvchi uchun bir nechta filtrlarni saqlash mumkin, lekin bir vaqtning oʻzida faqat bitta prefiltr va bitta postfiltr faol boʻlishi mumkin.<br>\r\nHar bir filtr tasvirlangan tartibda qayta ishlanadi. Muvaffaqiyatsiz skript ham, chiqarilgan \"keep;\" ham keyingi skriptlarning qayta ishlanishini toʻxtatmaydi. Global sieve skriptlariga oʻzgartirishlar Dovecot ni qayta ishga tushirishni keltirib chiqaradi.<br><br>Global sieve prefilter • Prefilter • Foydalanuvchi skriptlari • Postfilter • Global sieve postfilter",
+ "sieve_preset_1": "Xavfli boʻlishi mumkin boʻlgan fayl turlari bilan xatlarni rad etish",
+ "sieve_preset_2": "Aniq joʻnatuvchining xatini har doim oʻqilgan deb belgilash",
+ "sieve_preset_3": "Jimgina rad etish, keyingi sieve qayta ishlashini toʻxtatish",
+ "sieve_preset_4": "INBOX ga joylash, sieve filtrlari tomonidan keyingi qayta ishlashni oʻtkazib yuborish",
+ "sieve_preset_5": "Avto-javob (taʼtil)",
+ "sieve_preset_6": "Javob bilan xatni rad etish",
+ "sieve_preset_7": "Yoʻnaltirish va saqlash/tashlash",
+ "sieve_preset_8": "Aniq joʻnatuvchining xatini yoʻnaltirish, oʻqilgan deb belgilash va subpapkaga saralash",
+ "sieve_preset_header": "Iltimos, quyidagi misol presetlariga qarang. Batafsil maʼlumot uchun <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Wikipediaga</a> qarang.",
+ "sogo_visible": "Taxallus SOGo da koʻrinadi",
+ "sogo_visible_n": "Taxallusni SOGo da yashirish",
+ "sogo_visible_y": "Taxallusni SOGo da koʻrsatish",
+ "spam_aliases": "Vaqt. taxallus",
+ "stats": "Statistika",
+ "status": "Holat",
+ "sync_jobs": "Sinxronizatsiya vazifalari",
+ "syncjob_check_log": "Jurnalni tekshirish",
+ "syncjob_last_run_result": "Oxirgi ishga tushirilgan natija",
+ "syncjob_EX_OK": "Muvaffaqiyatli",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Ulanish muammosi",
+ "syncjob_EXIT_TLS_FAILURE": "Shifrlangan ulanish bilan muammo",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Autentifikatsiya muammosi",
+ "syncjob_EXIT_OVERQUOTA": "Maqsad pochta qutisi kvotadan oshib ketdi",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Masofaviy serverga ulanib boʻlmadi",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Notoʻgʻri foydalanuvchi nomi yoki parol",
+ "table_size": "Jadval oʻlchami",
+ "table_size_show_n": "%s ta element koʻrsatish",
+ "target_address": "Yoʻnaltirish manzili",
+ "target_domain": "Maqsad domen",
+ "templates": "Shablonlar",
+ "template": "Shablon",
+ "tls_enforce_in": "Kiruvchi TLS ni majburlash",
+ "tls_enforce_out": "Chiquvchi TLS ni majburlash",
+ "tls_map_dest": "Manzil",
+ "tls_map_dest_info": "Misollar: example.org, .example.org, [mail.example.org]:25",
+ "tls_map_parameters": "Parametrlar",
+ "tls_map_parameters_info": "Boʻsh yoki parametrlar, masalan: protocols=!SSLv2 ciphers=medium exclude=3DES",
+ "tls_map_policy": "Siyosat",
+ "tls_policy_maps": "TLS siyosati xaritalari",
+ "tls_policy_maps_enforced_tls": "Bu siyosatlar chiquvchi TLS ulanishlarini majburlovchi pochta qutisi foydalanuvchilari uchun ham xatti-harakatni bekor qiladi. Agar quyida siyosat boʻlmasa, bu foydalanuvchilar <code>smtp_tls_mandatory_protocols</code> va <code>smtp_tls_mandatory_ciphers</code> sifatida belgilangan standart qiymatlarni qoʻllaydi.",
+ "tls_policy_maps_info": "Bu siyosat xaritasi foydalanuvchining TLS siyosati sozlamalaridan mustaqil ravishda chiquvchi TLS transport qoidalarini bekor qiladi.<br>\r\n Batafsil maʼlumot uchun <a href=\"http://www.postfix.org/postconf.5.html#smtp_tls_policy_maps\" target=\"_blank\">\"smtp_tls_policy_maps\" hujjatlarini</a> tekshiring.",
+ "tls_policy_maps_long": "Chiquvchi TLS siyosati xaritasi bekor qilishlari",
+ "toggle_all": "Hammasini almashtirish",
+ "username": "Foydalanuvchi nomi",
+ "waiting": "Kutilmoqda",
+ "weekly": "Haftalik",
+ "yes": "✓"
+ },
+ "oauth2": {
+ "access_denied": "OAuth2 orqali kirishga ruxsat berish uchun pochta qutisi egasi sifatida kiring.",
+ "authorize_app": "Ilovaga ruxsat berish",
+ "deny": "Rad etish",
+ "permit": "Ilovaga ruxsat berish",
+ "profile": "Profil",
+ "profile_desc": "Shaxsiy maʼlumotlarni koʻrish: foydalanuvchi nomi, toʻliq ism, yaratilgan, oʻzgartirilgan, faol",
+ "scope_ask_permission": "Ilova quyidagi ruxsatlarni soʻradi"
+ },
+ "quarantine": {
+ "action": "Amal",
+ "atts": "Ilovalar",
+ "check_hash": "VT da fayl hashini qidirish",
+ "confirm": "Tasdiqlash",
+ "confirm_delete": "Ushbu elementni oʻchirishni tasdiqlang.",
+ "danger": "Xavf",
+ "deliver_inbox": "Inbox ga yetkazib berish",
+ "disabled_by_config": "Joriy tizim konfiguratsiyasi karantin funksiyasini oʻchirib qoʻyadi. Iltimos, karantin elementlari uchun \"pochta qutisi boʻyicha saqlash\" va \"maksimal oʻlcham\"ni oʻrnating.",
+ "download_eml": "Yuklab olish (.eml)",
+ "empty": "Natijalar yoʻq",
+ "high_danger": "Yuqori",
+ "info": "Maʼlumot",
+ "junk_folder": "Junk papkasi",
+ "learn_spam_delete": "Spam sifatida oʻrgatish va oʻchirish",
+ "low_danger": "Past",
+ "medium_danger": "Oʻrtacha",
+ "neutral_danger": "Neytral",
+ "notified": "Xabar berildi",
+ "qhandler_success": "Soʻrov tizimga muvaffaqiyatli yuborildi. Endi oynani yopishingiz mumkin.",
+ "qid": "Rspamd QID",
+ "qinfo": "Karantin tizimi rad etilgan xatni (joʻnatuvchiga xat yetkazib berilgandek <em>taassurot bermay</em>) hamda pochta qutisining Junk papkasiga nusxa sifatida yetkazib berilgan xatni maʼlumotlar bazasiga saqlaydi.\r\n <br>\"Spam sifatida oʻrgatish va oʻchirish\" xabarni Bayesian teoremasi orqali spam sifatida oʻrgatadi va kelajakda oʻxshash xabarlarni rad etish uchun fuzzy hashlarni hisoblaydi.\r\n <br>Bir nechta xabarlarni oʻrgatish — tizimingizga qarab — vaqt talab qilishi mumkinligini unutmang.<br>Qora roʻyxatdagi elementlar karantindan istisno qilinadi.",
+ "qitem": "Karantin elementi",
+ "quarantine": "Karantin",
+ "quick_actions": "Amallar",
+ "quick_delete_link": "Tezkor oʻchirish havolasini ochish",
+ "quick_info_link": "Maʼlumot havolasini ochish",
+ "quick_release_link": "Tezkor chiqarish havolasini ochish",
+ "rcpt": "Qabul qiluvchi",
+ "received": "Qabul qilingan",
+ "recipients": "Qabul qiluvchilar",
+ "refresh": "Yangilash",
+ "rejected": "Rad etilgan",
+ "release": "Chiqarish",
+ "release_body": "Xabaringizni ushbu xabarga eml fayl sifatida ilova qildik.",
+ "release_subject": "Potensial xavfli karantin elementi %s",
+ "remove": "Olib tashlash",
+ "rewrite_subject": "Mavzuni qayta yozish",
+ "rspamd_result": "Rspamd natijasi",
+ "sender": "Joʻnatuvchi (SMTP)",
+ "sender_header": "Joʻnatuvchi (\"From\" sarlavhasi)",
+ "settings_info": "Karantinga olinadigan maksimal elementlar soni: %s<br>Maksimal e-pochta oʻlchami: %s MiB",
+ "show_item": "Elementni koʻrsatish",
+ "spam": "Spam",
+ "spam_score": "Baho",
+ "subj": "Mavzu",
+ "table_size": "Jadval oʻlchami",
+ "table_size_show_n": "%s ta element koʻrsatish",
+ "text_from_html_content": "Mazmun (oʻzgartirilgan html)",
+ "text_plain_content": "Mazmun (text/plain)",
+ "toggle_all": "Hammasini almashtirish",
+ "type": "Tur"
+ },
+ "queue": {
+ "delete": "Hammasini oʻchirish",
+ "flush": "Navbatni tozalash",
+ "info": "Pochta navbati yetkazib berilishini kutayotgan barcha xatlarni oʻz ichiga oladi. Agar e-pochta uzoq vaqt davomida pochta navbatida tursa, u tizim tomonidan avtomatik ravishda oʻchiriladi.<br>Tegishli xatning xato xabari xat nima uchun yetkazib berilmaganligi haqida maʼlumot beradi.",
+ "legend": "Pochta navbati amallari funksiyalari:",
+ "ays": "Iltimos, joriy navbatdagi barcha elementlarni oʻchirishni tasdiqlang.",
+ "deliver_mail": "Yetkazib berish",
+ "deliver_mail_legend": "Tanlangan xatlarni qayta yetkazib berishga harakat qiladi.",
+ "hold_mail": "Ushlab turish",
+ "hold_mail_legend": "Tanlangan xatlarni ushlab turadi. (Keyingi yetkazib berish urinishlarining oldini oladi)",
+ "queue_manager": "Navbat menejeri",
+ "show_message": "Xabarni koʻrsatish",
+ "unban": "navbatdan blokdan chiqarish",
+ "unhold_mail": "Ushlab turishni bekor qilish",
+ "unhold_mail_legend": "Tanlangan xatlarni yetkazib berish uchun chiqaradi. (Avval ushlab turish talab qilinadi)"
+ },
+ "ratelimit": {
+ "disabled": "Oʻchirilgan",
+ "second": "xabarlar / soniya",
+ "minute": "xabarlar / daqiqa",
+ "hour": "xabarlar / soat",
+ "day": "xabarlar / kun"
+ },
+ "start": {
+ "help": "Yordam panelini koʻrsatish/yashirish",
+ "imap_smtp_server_auth_info": "Iltimos, toʻliq e-pochta manzilingiz va PLAIN autentifikatsiya mexanizmidan foydalaning.<br>\r\nKirish maʼlumotlaringiz server tomonidagi majburiy shifrlash orqali shifrlanadi."
+ },
+ "success": {
+ "acl_saved": "%s obyekti uchun ACL saqlandi",
+ "admin_added": "Administrator %s qoʻshildi",
+ "admin_api_modified": "API ga oʻzgarishlar saqlandi",
+ "admin_modified": "Administrator oʻzgarishlari saqlandi",
+ "admin_removed": "Administrator %s olib tashlandi",
+ "alias_added": "Taxallus manzili %s (%d) qoʻshildi",
+ "alias_domain_removed": "Taxallus domeni %s olib tashlandi",
+ "alias_modified": "Taxallus manzili %s ga oʻzgarishlar saqlandi",
+ "alias_removed": "Taxallus %s olib tashlandi",
+ "aliasd_added": "Taxallus domeni %s qoʻshildi",
+ "aliasd_modified": "Taxallus domeni %s ga oʻzgarishlar saqlandi",
+ "app_links": "Ilova havolalariga oʻzgarishlar saqlandi",
+ "app_passwd_added": "Yangi ilova paroli qoʻshildi",
+ "app_passwd_removed": "Ilova paroli ID %s olib tashlandi",
+ "bcc_deleted": "BCC xaritasi yozuvlari oʻchirildi: %s",
+ "bcc_edited": "BCC xaritasi yozuvi %s tahrirlandi",
+ "bcc_saved": "BCC xaritasi yozuvi saqlandi",
+ "cors_headers_edited": "CORS sozlamalari saqlandi",
+ "custom_login_modified": "Kirishni sozlash muvaffaqiyatli saqlandi",
+ "db_init_complete": "Maʼlumotlar bazasini ishga tushirish tugadi",
+ "delete_filter": "Filtr ID %s oʻchirildi",
+ "delete_filters": "Filtrlar oʻchirildi: %s",
+ "deleted_syncjob": "Sinxronizatsiya vazifasi ID %s oʻchirildi",
+ "deleted_syncjobs": "Sinxronizatsiya vazifalari oʻchirildi: %s",
+ "dkim_added": "DKIM kaliti %s saqlandi",
+ "domain_add_dkim_available": "DKIM kaliti allaqachon mavjud edi",
+ "dkim_duplicated": "%s domeni uchun DKIM kaliti %s ga nusxalandi",
+ "dkim_removed": "DKIM kaliti %s olib tashlandi",
+ "domain_added": "Domen %s qoʻshildi",
+ "domain_admin_added": "Domen administratori %s qoʻshildi",
+ "domain_admin_modified": "Domen administratori %s ga oʻzgarishlar saqlandi",
+ "domain_admin_removed": "Domen administratori %s olib tashlandi",
+ "domain_footer_modified": "Domen pastki qismi %s ga oʻzgarishlar saqlandi",
+ "domain_modified": "Domen %s ga oʻzgarishlar saqlandi",
+ "domain_removed": "Domen %s olib tashlandi",
+ "dovecot_restart_success": "Dovecot muvaffaqiyatli qayta ishga tushirildi",
+ "eas_reset": "%s foydalanuvchisi uchun ActiveSync qurilmalari tiklandi",
+ "f2b_banlist_refreshed": "Banlist ID muvaffaqiyatli yangilandi.",
+ "f2b_modified": "Fail2ban parametrlariga oʻzgarishlar saqlandi",
+ "forwarding_host_added": "Yoʻnaltirish xosti %s qoʻshildi",
+ "forwarding_host_removed": "Yoʻnaltirish xosti %s olib tashlandi",
+ "global_filter_written": "Filtr faylga muvaffaqiyatli yozildi",
+ "hash_deleted": "Hash oʻchirildi",
+ "iam_test_connection": "Ulanish muvaffaqiyatli",
+ "ip_check_opt_in_modified": "IP tekshiruvi muvaffaqiyatli saqlandi",
+ "item_deleted": "Element %s muvaffaqiyatli oʻchirildi",
+ "item_released": "Element %s chiqarildi",
+ "items_deleted": "Element %s muvaffaqiyatli oʻchirildi",
+ "items_released": "Tanlangan elementlar chiqarildi",
+ "learned_ham": "ID %s ham sifatida muvaffaqiyatli oʻrgatildi",
+ "license_modified": "Litsenziyaga oʻzgarishlar saqlandi",
+ "logged_in_as": "%s sifatida tizimga kirildi",
+ "mailbox_added": "Pochta qutisi %s qoʻshildi",
+ "mailbox_modified": "Pochta qutisi %s ga oʻzgarishlar saqlandi",
+ "mailbox_removed": "Pochta qutisi %s olib tashlandi",
+ "mailbox_renamed": "Pochta qutisi %s dan %s ga qayta nomlandi",
+ "nginx_reloaded": "Nginx qayta yuklandi",
+ "object_modified": "Obyekt %s ga oʻzgarishlar saqlandi",
+ "password_policy_saved": "Parol siyosati muvaffaqiyatli saqlandi",
+ "password_changed_success": "Parol muvaffaqiyatli oʻzgartirildi",
+ "pushover_settings_edited": "Pushover sozlamalari muvaffaqiyatli oʻrnatildi, iltimos maʼlumotlarni tekshiring.",
+ "qlearn_spam": "Xabar ID %s spam sifatida oʻrgatildi va oʻchirildi",
+ "queue_command_success": "Navbat buyrugʻi muvaffaqiyatli yakunlandi",
+ "recipient_map_entry_deleted": "Qabul qiluvchi xaritasi ID %s oʻchirildi",
+ "recipient_map_entry_saved": "Qabul qiluvchi xaritasi yozuvi \"%s\" saqlandi",
+ "recovery_email_sent": "Tiklash e-pochtasi %s ga yuborildi",
+ "relayhost_added": "Xarita yozuvi %s qoʻshildi",
+ "relayhost_removed": "Xarita yozuvi %s olib tashlandi",
+ "reset_main_logo": "Standart logotipga qaytarildi",
+ "resource_added": "Resurs %s qoʻshildi",
+ "resource_modified": "Pochta qutisi %s ga oʻzgarishlar saqlandi",
+ "resource_removed": "Resurs %s olib tashlandi",
+ "rl_saved": "%s obyekti uchun tezlik chegarasi saqlandi",
+ "rspamd_ui_pw_set": "Rspamd UI paroli muvaffaqiyatli oʻrnatildi",
+ "saved_settings": "Sozlamalar saqlandi",
+ "settings_map_added": "Sozlamalar xaritasi yozuvi qoʻshildi",
+ "settings_map_removed": "Sozlamalar xaritasi ID %s olib tashlandi",
+ "sogo_profile_reset": "%s foydalanuvchisi uchun SOGo profili tiklandi",
+ "template_added": "Shablon %s qoʻshildi",
+ "template_modified": "Shablon %s ga oʻzgarishlar saqlandi",
+ "template_removed": "Shablon ID %s oʻchirildi",
+ "tls_policy_map_entry_deleted": "TLS siyosati xaritasi ID %s oʻchirildi",
+ "tls_policy_map_entry_saved": "TLS siyosati xaritasi yozuvi \"%s\" saqlandi",
+ "ui_texts": "UI matnlariga oʻzgarishlar saqlandi",
+ "upload_success": "Fayl muvaffaqiyatli yuklandi",
+ "verified_fido2_login": "FIDO2 kirishi tasdiqlandi",
+ "verified_totp_login": "TOTP kirishi tasdiqlandi",
+ "verified_webauthn_login": "WebAuthn kirishi tasdiqlandi",
+ "verified_yotp_login": "Yubico OTP kirishi tasdiqlandi"
+ },
+ "tfa": {
+ "authenticators": "Autentifikatorlar",
+ "api_register": "%s Yubico Cloud API dan foydalanadi. Iltimos, kalitingiz uchun API kalitini <a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">bu yerdan</a> oling",
+ "confirm": "Tasdiqlash",
+ "confirm_totp_token": "Iltimos, yaratilgan tokenni kiritib oʻzgarishlaringizni tasdiqlang",
+ "delete_tfa": "TFA ni oʻchirish",
+ "disable_tfa": "Keyingi muvaffaqiyatli kirishgacha TFA ni oʻchirish",
+ "force_tfa": "Kirishda 2FA roʻyxatdan oʻtkazishni majburlash",
+ "force_tfa_info": "Foydalanuvchidan panelga kirishdan oldin ikki faktorli autentifikatsiyani sozlash talab qilinadi.",
+ "setup_title": "Ikki faktorli autentifikatsiya talab qilinadi",
+ "setup_required": "Hisobingiz ikki faktorli autentifikatsiyani talab qiladi. Davom etish uchun 2FA usulini sozlang.",
+ "cancel_setup": "Bekor qilish va chiqish",
+ "enter_qr_code": "Agar qurilmangiz QR kodlarni skanerlay olmasa, TOTP kodingiz",
+ "error_code": "Xato kodi",
+ "init_webauthn": "Ishga tushirilmoqda, iltimos kuting...",
+ "key_id": "Qurilmangiz uchun identifikator",
+ "key_id_totp": "Kalitingiz uchun identifikator",
+ "none": "Oʻchirish",
+ "reload_retry": "- (xato davom etsa, brauzerni qayta yuklang)",
+ "scan_qr_code": "Iltimos, quyidagi kodni autentifikator ilovangiz bilan skanerlang yoki kodni qoʻlda kiriting.",
+ "select": "Iltimos, tanlang",
+ "set_tfa": "Ikki faktorli autentifikatsiya usulini oʻrnatish",
+ "start_webauthn_validation": "Tekshiruvni boshlash",
+ "tfa": "Ikki faktorli autentifikatsiya",
+ "tfa_token_invalid": "TFA tokeni noto'g'ri",
+ "totp": "Vaqt asosidagi OTP (Google Authenticator, Authy va h.k.)",
+ "u2f_deprecated": "Sizning kalitingiz eskirgan U2F usulidan foydalanib roʻyxatdan oʻtkazilganga oʻxshaydi. Biz siz uchun ikki faktorli autentifikatsiyani oʻchirib qoʻyamiz va kalitingizni oʻchiramiz.",
+ "u2f_deprecated_important": "Iltimos, kalitingizni admin panelida yangi WebAuthn usuli bilan roʻyxatdan oʻtkazing.",
+ "webauthn": "WebAuthn autentifikatsiya",
+ "waiting_usb_auth": "<i>USB qurilmasi kutilmoqda...</i><br><br>Iltimos, hozir USB qurilmangizdagi tugmani bosing.",
+ "waiting_usb_register": "<i>USB qurilmasi kutilmoqda...</i><br><br>Iltimos, yuqorida parolingizni kiriting va USB qurilmangizdagi tugmani bosib roʻyxatga olinishingizni tasdiqlang.",
+ "yubi_otp": "Yubico OTP autentifikatsiya"
+ },
+ "user": {
+ "action": "Amal",
+ "active": "Faol",
+ "active_sieve": "Faol filtr",
+ "advanced_settings": "Kengaytirilgan sozlamalar",
+ "alias": "Taxallus",
+ "alias_create_random": "Tasodifiy taxallus yaratish",
+ "alias_extend_all": "Taxalluslarni 1 soatga uzaytirish",
+ "alias_full_date": "d.m.Y, H:i:s T",
+ "alias_remove_all": "Barcha taxalluslarni olib tashlash",
+ "alias_select_validity": "Amal qilish muddati",
+ "alias_time_left": "Qolgan vaqt",
+ "alias_valid_until": "Amal qiladi (gacha)",
+ "aliases_also_send_as": "Foydalanuvchi sifatida ham joʻnatishga ruxsat berilgan",
+ "aliases_send_as_all": "Quyidagi domen(lar) va ularning taxallus domenlari uchun joʻnatuvchi kirishini tekshirmaslik",
+ "app_hint": "Ilova parollari sizning IMAP, SMTP, CalDAV, CardDAV va EAS kirishi uchun muqobil parollardir. Foydalanuvchi nomi oʻzgarmaydi. SOGo webmail ilova parollari orqali mavjud emas.",
+ "allowed_protocols": "Ruxsat etilgan protokollar",
+ "app_name": "Ilova nomi",
+ "app_passwds": "Ilova parollari",
+ "apple_connection_profile": "Apple ulanish profili",
+ "apple_connection_profile_complete": "Bu ulanish profili Apple qurilmasi uchun IMAP va SMTP parametrlari hamda CalDAV (kalendarlar) va CardDAV (kontaktlar) yoʻllarini oʻz ichiga oladi.",
+ "apple_connection_profile_mailonly": "Bu ulanish profili Apple qurilmasi uchun IMAP va SMTP konfiguratsiya parametrlarini oʻz ichiga oladi.",
+ "apple_connection_profile_with_app_password": "Yangi ilova paroli yaratiladi va profilga qoʻshiladi, shunda qurilmangizni sozlashda parol kiritish kerak boʻlmaydi. Iltimos, faylni ulashmang, chunki u pochta qutingizga toʻliq kirish huquqini beradi.",
+ "attribute": "Atribut",
+ "authentication": "Autentifikatsiya",
+ "change_password": "Parolni oʻzgartirish",
+ "change_password_hint_app_passwords": "Hisobingizda %d ta ilova paroli mavjud va ular oʻzgartirilmaydi. Ularni boshqarish uchun Ilova parollari yorligʻiga oʻting.",
+ "clear_recent_successful_connections": "Koʻrilgan muvaffaqiyatli ulanishlarni tozalash",
+ "client_configuration": "E-pochta mijozlari va smartfonlar uchun konfiguratsiya qoʻllanmalarini koʻrsatish",
+ "create_app_passwd": "Ilova paroli yaratish",
+ "create_syncjob": "Yangi sinxronizatsiya vazifasi yaratish",
+ "created_on": "Yaratilgan sana",
+ "daily": "Kunlik",
+ "day": "kun",
+ "description": "Tavsif",
+ "delete_ays": "Iltimos, oʻchirish jarayonini tasdiqlang.",
+ "direct_aliases": "Toʻgʻridan-toʻgʻri taxallus manzillari",
+ "direct_aliases_desc": "Toʻgʻridan-toʻgʻri taxallus manzillariga spam filtri va TLS siyosati sozlamalari taʼsir qiladi.",
+ "direct_protocol_access": "Bu pochta qutisi foydalanuvchisi quyidagi protokollar va ilovalarga <b>toʻgʻridan-toʻgʻri, tashqi kirish</b>ga ega. Bu sozlama administratoringiz tomonidan boshqariladi. Maxsus protokollar va ilovalarga kirishga ruxsat berish uchun ilova parollarini yaratish mumkin.<br>\"Webmail\" tugmasi SOGo ga yagona kirish (SSO) imkonini beradi va doimo mavjud.",
+ "eas_reset": "ActiveSync qurilma keshini tiklash",
+ "eas_reset_help": "Koʻp hollarda qurilma keshini tiklash buzilgan ActiveSync profilini tiklashga yordam beradi.<br><b>Diqqat:</b> Barcha elementlar qayta yuklab olinadi!",
+ "eas_reset_now": "Hozir tiklash",
+ "edit": "Tahrirlash",
+ "email": "E-pochta",
+ "email_and_dav": "E-pochta, kalendarlar va kontaktlar",
+ "empty": "Natijalar yoʻq",
+ "encryption": "Shifrlash",
+ "excludes": "Istisnolar",
+ "expire_in": "Tugaydi",
+ "expire_never": "Hech qachon tugamasin",
+ "fido2_webauthn": "FIDO2/WebAuthn",
+ "forever": "Abadiy",
+ "force_pw_update": "Guruh dasturi xizmatlariga kirish uchun siz <b>yangi</b> parol oʻrnatishingiz kerak.",
+ "from": "dan",
+ "generate": "yaratish",
+ "hour": "soat",
+ "hourly": "Soatlik",
+ "hours": "soat",
+ "in_use": "Foydalanilmoqda",
+ "interval": "Oraliq",
+ "is_catch_all": "Domen(lar) uchun Hammasini-qabul qilish",
+ "last_mail_login": "Oxirgi pochta kirishi",
+ "last_pw_change": "Oxirgi parol oʻzgarishi",
+ "last_run": "Oxirgi ishga tushirilgan",
+ "last_ui_login": "Oxirgi UI kirishi",
+ "loading": "Yuklanmoqda...",
+ "login_history": "Kirish tarixi",
+ "mailbox": "Pochta qutisi",
+ "mailbox_details": "Tafsilotlar",
+ "mailbox_general": "Umumiy",
+ "mailbox_settings": "Sozlamalar",
+ "messages": "xabarlar",
+ "month": "oy",
+ "months": "oy",
+ "never": "Hech qachon",
+ "new_password": "Yangi parol",
+ "new_password_repeat": "Tasdiqlash paroli (takrorlang)",
+ "no_active_filter": "Faol filtr mavjud emas",
+ "no_last_login": "Oxirgi UI kirishi haqida maʼlumot yoʻq",
+ "no_record": "Yozuv yoʻq",
+ "open_logs": "Jurnallarni ochish",
+ "open_webmail_sso": "Webmail",
+ "overview": "Umumiy koʻrinish",
+ "password": "Parol",
+ "password_now": "Joriy parol (oʻzgarishlarni tasdiqlang)",
+ "pw_update_required": "Hisobingiz parol oʻzgartirishni talab qiladi. Davom etish uchun yangi parolni oʻrnating.",
+ "password_repeat": "Parol (takrorlang)",
+ "password_reset_info": "Agar parolni tiklash uchun e-pochta kiritilmagan boʻlsa, bu funksiyadan foydalanib boʻlmaydi.",
+ "protocols": "Protokollar",
+ "pushover_evaluate_x_prio": "Yuqori muhimlikdagi xatni eskalatsiya qilish [<code>X-Priority: 1</code>]",
+ "pushover_info": "Push bildirishnoma sozlamalari <b>%s</b> ga taxalluslar bilan birga (umumiy, umumiy boʻlmagan, teglangan) yetkazib beriladigan barcha toza (spam boʻlmagan) xatlarga qoʻllaniladi.",
+ "pushover_only_x_prio": "Faqat yuqori muhimlikdagi xatlarni koʻrib chiqish [<code>X-Priority: 1</code>]",
+ "pushover_sender_array": "Quyidagi joʻnatuvchi e-pochta manzillarini koʻrib chiqish <small>(vergul bilan ajratilgan)</small>",
+ "pushover_sender_regex": "Joʻnatuvchilarni quyidagi regex orqali mos kelishini tekshirish",
+ "pushover_text": "Bildirishnoma matni",
+ "pushover_title": "Bildirishnoma sarlavhasi",
+ "pushover_sound": "Tovush",
+ "pushover_vars": "Joʻnatuvchi filtri belgilanmagan boʻlsa, barcha xatlar koʻrib chiqiladi.<br>Regex filtrlari va aniq joʻnatuvchi tekshiruvlari alohida belgilanishi mumkin va ketma-ket koʻrib chiqiladi. Ular bir-biriga bogʻliq emas.<br>Matn va sarlavha uchun ishlatiladigan oʻzgaruvchilar (ma'lumotlarni himoya qilish siyosatiga e'tibor bering)",
+ "pushover_verify": "Maʼlumotlarni tekshirish",
+ "pw_recovery_email": "Parolni tiklash e-pochtasi",
+ "q_add_header": "Junk papkasi",
+ "q_all": "Barcha turkumlar",
+ "q_reject": "Rad etilgan",
+ "quarantine_category": "Karantin bildirishnoma turkumi",
+ "quarantine_category_info": "\"Rad etilgan\" bildirishnoma turkumi rad etilgan xatlarni oʻz ichiga oladi, \"Junk papkasi\" esa Junk papkasiga joylashtirilgan xatlar haqida foydalanuvchini xabardor qiladi.",
+ "quarantine_notification": "Karantin bildirishnomalari",
+ "quarantine_notification_info": "Bildirishnoma yuborilgandan keyin elementlar \"xabar berildi\" deb belgilanadi va bu element uchun keyingi bildirishnomalar yuborilmaydi.",
+ "recent_successful_connections": "Koʻrilgan muvaffaqiyatli ulanishlar",
+ "remove": "Olib tashlash",
+ "running": "Ishlamoqda",
+ "save": "Oʻzgarishlarni saqlash",
+ "save_changes": "Oʻzgarishlarni saqlash",
+ "sender_acl_disabled": "<span class=\"badge fs-6 bg-danger\">Joʻnatuvchi tekshiruvi oʻchirilgan</span>",
+ "shared_aliases": "Umumiy taxallus manzillari",
+ "shared_aliases_desc": "Umumiy taxalluslarga foydalanuvchining maxsus sozlamalari (spam filtri yoki shifrlash siyosati kabi) taʼsir qilmaydi. Mos spam filtrlarini faqat administrator domen boʻyicha siyosat sifatida sozlashi mumkin.",
+ "show_sieve_filters": "Faol foydalanuvchi sieve filtrini koʻrsatish",
+ "sogo_profile_reset": "SOGo profilini tiklash",
+ "sogo_profile_reset_help": "Bu foydalanuvchining SOGo profilini yoʻq qiladi va <b>barcha kontakt va kalendar maʼlumotlarini qaytarib boʻlmas tarzda oʻchiradi</b>.",
+ "sogo_profile_reset_now": "Profilni hozir tiklash",
+ "spam_aliases": "Spam e-pochta taxalluslari",
+ "spam_aliases_info": "Spam taxallusi — bu haqiqiy e-pochta manzillarini himoya qilish uchun ishlatilishi mumkin boʻlgan vaqtinchalik e-pochta manzilidir. <br>Ixtiyoriy ravishda muddat tugash vaqtini belgilash mumkin, shunda taxallus belgilangan davrdan keyin avtomatik oʻchirib qoʻyiladi, suiisteʼmol qilingan yoki tarqalib ketgan manzillarni samarali tarzda chiqarib tashlaydi.",
+ "spam_score_reset": "Server standartiga qaytarish",
+ "spamfilter": "Spam filtri",
+ "spamfilter_behavior": "Baholash",
+ "spamfilter_bl": "Qora roʻyxat",
+ "spamfilter_bl_desc": "Qora roʻyxatdagi e-pochta manzillari <b>har doim</b> spam sifatida tasniflanadi va rad etiladi. Rad etilgan xat karantinga <b>nusxalanmaydi</b>. Joker belgilar ishlatilishi mumkin. Filtr faqat toʻgʻridan-toʻgʻri taxalluslarga (bitta maqsad pochta qutisiga ega taxalluslarga) qoʻllaniladi, hammasini-qabul qilish taxalluslari va pochta qutisining oʻzi istisno qilinadi.",
+ "spamfilter_default_score": "Standart qiymatlar",
+ "spamfilter_green": "Yashil: bu xabar spam emas",
+ "spamfilter_hint": "Birinchi qiymat \"past spam bahosi\"ni tavsiflaydi, ikkinchisi \"yuqori spam bahosi\"ni ifodalaydi.",
+ "spamfilter_red": "Qizil: bu xabar spam va server tomonidan rad etiladi",
+ "spamfilter_table_action": "Amal",
+ "spamfilter_table_add": "Element qoʻshish",
+ "spamfilter_table_domain_policy": "n/a (domen siyosati)",
+ "spamfilter_table_empty": "Koʻrsatish uchun ma'lumot yoʻq",
+ "spamfilter_table_remove": "olib tashlash",
+ "spamfilter_table_rule": "Qoida",
+ "spamfilter_wl": "Oq roʻyxat",
+ "spamfilter_wl_desc": "Oq roʻyxatdagi e-pochta manzillari <b>hech qachon</b> spam sifatida tasniflanmaydi. Joker belgilar ishlatilishi mumkin. Filtr faqat toʻgʻridan-toʻgʻri taxalluslarga (bitta maqsad pochta qutisiga ega taxalluslarga) qoʻllaniladi, hammasini-qabul qilish taxalluslari va pochta qutisining oʻzi istisno qilinadi.",
+ "spamfilter_yellow": "Sariq: bu xabar spam boʻlishi mumkin, spam sifatida belgilanadi va Junk papkangizga koʻchiriladi",
+ "status": "Holat",
+ "sync_jobs": "Sinxronizatsiya vazifalari",
+ "syncjob_check_log": "Jurnalni tekshirish",
+ "syncjob_last_run_result": "Oxirgi ishga tushirilgan natija",
+ "syncjob_EX_OK": "Muvaffaqiyatli",
+ "syncjob_EXIT_CONNECTION_FAILURE": "Ulanish muammosi",
+ "syncjob_EXIT_TLS_FAILURE": "Shifrlangan ulanish bilan muammo",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE": "Autentifikatsiya muammosi",
+ "syncjob_EXIT_OVERQUOTA": "Maqsad pochta qutisi kvotadan oshib ketdi",
+ "syncjob_EXIT_CONNECTION_FAILURE_HOST1": "Masofaviy serverga ulanib boʻlmadi",
+ "syncjob_EXIT_AUTHENTICATION_FAILURE_USER1": "Notoʻgʻri foydalanuvchi nomi yoki parol",
+ "tag_handling": "Teglangan xat uchun ishlovni oʻrnatish",
+ "tag_help_example": "Teglangan e-pochta manzili misoli: me<b>+Facebook</b>@example.org",
+ "tag_help_explain": "Subpapkada: tegga qarab nomlangan yangi subpapka INBOX ostida yaratiladi (\"INBOX/Facebook\").<br>\r\nMavzuda: teg nomi xatning mavzusiga oldindan qoʻshiladi, misol: \"[Facebook] Mening yangiliklarim\".",
+ "tag_in_none": "Hech narsa qilmaslik",
+ "tag_in_subfolder": "Subpapkada",
+ "tag_in_subject": "Mavzuda",
+ "text": "Matn",
+ "tfa_info": "Ikki faktorli autentifikatsiya hisobingizni himoya qilishga yordam beradi. Uni yoqsangiz, ikki faktorli autentifikatsiyani qoʻllab-quvvatlamaydigan ilovalar yoki xizmatlarga (masalan, pochta mijozlari) kirish uchun ilova parollari kerak boʻladi.",
+ "title": "Sarlavha",
+ "tls_enforce_in": "Kiruvchi TLS ni majburlash",
+ "tls_enforce_out": "Chiquvchi TLS ni majburlash",
+ "tls_policy": "Shifrlash siyosati",
+ "tls_policy_warning": "<strong>Diqqat:</strong> Agar shifrlangan pochta transferini majburlashga qaror qilsangiz, e-pochtalarni yoʻqotishingiz mumkin.<br>Siyosatga mos kelmaydigan xabarlar pochta tizimi tomonidan qatʼiy muvaffaqiyatsizlik bilan qaytariladi.<br>Bu variant sizning asosiy e-pochta manzilingiz (kirish nomingiz), taxallus domenlaridan olingan barcha manzillar va <b>faqat ushbu pochta qutisi</b> maqsad sifatida boʻlgan taxallus manzillariga qoʻllaniladi.",
+ "user_settings": "Foydalanuvchi sozlamalari",
+ "username": "Foydalanuvchi nomi",
+ "value": "Qiymat",
+ "verify": "Tasdiqlash",
+ "waiting": "Kutilmoqda",
+ "week": "hafta",
+ "weekly": "Haftalik",
+ "weeks": "hafta",
+ "with_app_password": "ilova paroli bilan",
+ "year": "yil",
+ "years": "yil"
+ },
+ "warning": {
+ "cannot_delete_self": "Tizimga kirgan foydalanuvchini oʻchirib boʻlmaydi",
+ "domain_added_sogo_failed": "Domen qoʻshildi, ammo SOGoni qayta ishga tushirib boʻlmadi, iltimos server jurnallaringizni tekshiring.",
+ "dovecot_restart_failed": "Dovecot qayta ishga tushirib boʻlmadi, iltimos jurnallarni tekshiring",
+ "fuzzy_learn_error": "Fuzzy hash oʻrgatish xatosi: %s",
+ "hash_not_found": "Hash topilmadi yoki allaqachon oʻchirilgan",
+ "ip_invalid": "Notoʻgʻri IP oʻtkazib yuborildi: %s",
+ "is_not_primary_alias": "Asosiy boʻlmagan taxallus oʻtkazib yuborildi: %s",
+ "no_active_admin": "Oxirgi faol administratorni oʻchirib boʻlmaydi",
+ "quota_exceeded_scope": "Domen kvotasi oshib ketdi: Bu domen doirasida faqat cheksiz pochta qutilari yaratilishi mumkin.",
+ "session_token": "Forma tokeni noto'g'ri: Token mos kelmadi",
+ "session_ua": "Forma tokeni noto'g'ri: User-Agent tekshiruvi xatosi"
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.vi-vn.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.vi-vn.json
new file mode 100644
index 0000000..42813fd
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.vi-vn.json
@@ -0,0 +1,715 @@
+{
+ "acl": {
+ "alias_domains": "Thêm tên miền bí danh",
+ "app_passwds": "Quản lý mật khẩu ứng dụng",
+ "bcc_maps": "Ánh xạ BCC",
+ "delimiter_action": "Hành động phân cách",
+ "domain_desc": "Thay đổi mô tả tên miền",
+ "domain_relayhost": "Thay đổi máy chủ chuyển tiếp cho tên miền",
+ "eas_reset": "Đặt lại thiết bị EAS",
+ "extend_sender_acl": "Cho phép mở rộng ACL người gửi bằng địa chỉ bên ngoài",
+ "filters": "Bộ lọc",
+ "login_as": "Đăng nhập với tư cách người dùng hộp thư",
+ "mailbox_relayhost": "Thay đổi máy chủ chuyển tiếp cho hộp thư",
+ "prohibited": "Bị cấm bởi ACL",
+ "protocol_access": "Thay đổi quyền truy cập giao thức",
+ "pushover": "Thông báo đẩy",
+ "pw_reset": "Cho phép đặt lại mật khẩu người dùng mailcow",
+ "quarantine": "Hành động cách ly",
+ "quarantine_attachments": "Cách ly tệp đính kèm",
+ "quarantine_category": "Thay đổi danh mục thông báo cách ly",
+ "quarantine_notification": "Thay đổi thông báo cách ly",
+ "ratelimit": "Giới hạn tốc độ",
+ "recipient_maps": "Ánh xạ người nhận",
+ "smtp_ip_access": "Thay đổi máy chủ được phép cho SMTP",
+ "sogo_access": "Cho phép quản lý truy cập SOGo",
+ "sogo_profile_reset": "Đặt lại hồ sơ SOGo",
+ "spam_alias": "Bí danh tạm thời",
+ "spam_policy": "Danh sách chặn/Danh sách cho phép",
+ "spam_score": "Điểm thư rác",
+ "syncjobs": "Công việc đồng bộ",
+ "tls_policy": "Chính sách TLS",
+ "unlimited_quota": "Hạn ngạch không giới hạn cho hộp thư"
+ },
+ "add": {
+ "activate_filter_warn": "Tất cả các bộ lọc khác sẽ bị vô hiệu hóa khi tùy chọn kích hoạt được chọn.",
+ "active": "Đang hoạt động",
+ "add": "Thêm",
+ "add_domain_only": "Chỉ thêm tên miền",
+ "add_domain_restart": "Thêm tên miền và khởi động lại SOGo",
+ "alias_address": "Địa chỉ bí danh",
+ "alias_address_info": "<small>Địa chỉ email đầy đủ hoặc @example.com để bắt tất cả thư cho một tên miền (phân cách bằng dấu phẩy). <b>Chỉ áp dụng cho tên miền mailcow</b>.</small>",
+ "alias_domain": "Tên miền bí danh",
+ "alias_domain_info": "<small>Chỉ cho phép tên miền hợp lệ (phân cách bằng dấu phẩy).</small>",
+ "app_name": "Tên ứng dụng",
+ "app_password": "Thêm mật khẩu ứng dụng",
+ "app_passwd_protocols": "Các giao thức được phép cho mật khẩu ứng dụng",
+ "automap": "Thử tự động ánh xạ thư mục (\"Mục đã gửi\", \"Đã gửi\" => \"Đã gửi\" v.v.)",
+ "backup_mx_options": "Tùy chọn chuyển tiếp",
+ "bcc_dest_format": "Địa chỉ BCC phải là một địa chỉ email hợp lệ duy nhất.<br>Nếu bạn cần gửi bản sao đến nhiều địa chỉ, hãy tạo một bí danh và sử dụng nó ở đây.",
+ "comment_info": "Bình luận riêng tư không hiển thị với người dùng, trong khi bình luận công khai được hiển thị dưới dạng chú thích khi di chuột qua trong tổng quan người dùng",
+ "custom_params": "Tham số tùy chỉnh",
+ "custom_params_hint": "Đúng: --param=xy, sai: --param xy",
+ "delete1": "Xóa từ nguồn khi hoàn thành",
+ "delete2": "Xóa thư ở đích không có ở nguồn",
+ "delete2duplicates": "Xóa các bản sao ở đích",
+ "description": "Mô tả",
+ "destination": "Đích",
+ "disable_login": "Không cho phép đăng nhập (vẫn nhận được thư đến)",
+ "domain": "Tên miền",
+ "domain_matches_hostname": "Tên miền %s khớp với tên máy chủ",
+ "domain_quota_m": "Tổng hạn ngạch tên miền (MiB)",
+ "dry": "Mô phỏng đồng bộ hóa",
+ "enc_method": "Phương thức mã hóa",
+ "exclude": "Loại trừ đối tượng (biểu thức chính quy)",
+ "full_name": "Tên đầy đủ",
+ "gal": "Danh sách địa chỉ toàn cục",
+ "gal_info": "GAL chứa tất cả các đối tượng của một tên miền và không thể được chỉnh sửa bởi bất kỳ người dùng nào. Thông tin rảnh/bận trong SOGo sẽ bị thiếu nếu vô hiệu hóa! <b>Khởi động lại SOGo để áp dụng thay đổi.</b>",
+ "generate": "Tạo",
+ "goto_ham": "\"Học là <span class=\"text-success\"><b>thư bình thường</b></span>",
+ "goto_null": "Loại bỏ thư một cách thầm lặng",
+ "goto_spam": "Học là <span class=\"text-danger\"><b>thư rác</b></span>",
+ "hostname": "Máy chủ",
+ "inactive": "Không hoạt động",
+ "internal": "Nội bộ",
+ "internal_info": "Bí danh nội bộ chỉ có thể truy cập từ tên miền sở hữu hoặc tên miền bí danh.",
+ "kind": "Loại",
+ "mailbox_quota_def": "Hạn ngạch hộp thư mặc định",
+ "mailbox_quota_m": "Hạn ngạch tối đa mỗi hộp thư (MiB)",
+ "mailbox_username": "Tên người dùng (phần bên trái của địa chỉ email)",
+ "max_aliases": "Số lượng bí danh tối đa có thể tạo",
+ "max_mailboxes": "Số lượng hộp thư tối đa có thể tạo",
+ "mins_interval": "Khoảng thời gian kiểm tra (phút)",
+ "multiple_bookings": "Đặt chỗ nhiều lần",
+ "nexthop": "Bước nhảy tiếp theo",
+ "password": "Mật khẩu",
+ "password_repeat": "Xác nhận mật khẩu (nhập lại)",
+ "port": "Cổng",
+ "post_domain_add": "Container SOGo, \\\"sogo-mailcow\\\", cần được khởi động lại sau khi thêm tên miền mới!<br><br>Ngoài ra, cấu hình DNS của tên miền cần được xem xét. Khi cấu hình DNS được phê duyệt, khởi động lại \\\"acme-mailcow\\\" để tự động tạo chứng chỉ cho tên miền mới của bạn (autoconfig.<domain>, autodiscover.<domain>).<br>Bước này là tùy chọn và sẽ được thử lại sau mỗi 24 giờ.",
+ "private_comment": "Bình luận riêng tư",
+ "public_comment": "Bình luận công khai",
+ "quota_mb": "Hạn ngạch (MiB)",
+ "relay_all": "Chuyển tiếp tất cả người nhận",
+ "relay_all_info": "↪ Nếu bạn chọn <b>không</b> chuyển tiếp tất cả người nhận, bạn sẽ cần thêm một hộp thư (\"ẩn\") cho từng người nhận cần được chuyển tiếp.",
+ "relay_domain": "Chuyển tiếp tên miền này",
+ "relay_transport_info": "<div class=\"badge fs-6 bg-info\">Thông tin</div> Bạn có thể định nghĩa ánh xạ vận chuyển cho đích tùy chỉnh cho tên miền này. Nếu không được đặt, tra cứu MX sẽ được thực hiện.",
+ "relay_unknown_only": "Chỉ chuyển tiếp hộp thư không tồn tại. Hộp thư hiện có sẽ được gửi cục bộ.",
+ "relayhost_wrapped_tls_info": "Vui lòng <b>không</b> sử dụng các cổng được bọc TLS (thường được sử dụng trên cổng 465).<br>\nSử dụng bất kỳ cổng không được bọc nào và sử dụng STARTTLS. Chính sách TLS để thực thi TLS có thể được tạo trong \"Ánh xạ chính sách TLS\".",
+ "select": "Vui lòng chọn...",
+ "select_domain": "Vui lòng chọn tên miền trước",
+ "sieve_desc": "Mô tả ngắn",
+ "sieve_type": "Loại bộ lọc",
+ "skipcrossduplicates": "Bỏ qua tin nhắn trùng lặp giữa các thư mục (ai đến trước được phục vụ trước)",
+ "subscribeall": "Đăng ký tất cả thư mục",
+ "syncjob": "Thêm công việc đồng bộ",
+ "syncjob_hint": "Lưu ý rằng mật khẩu cần được lưu dưới dạng văn bản thuần!",
+ "tags": "Thẻ",
+ "target_address": "Địa chỉ chuyển tiếp",
+ "target_address_info": "<small>Địa chỉ email đầy đủ (phân cách bằng dấu phẩy).</small>",
+ "target_domain": "Tên miền đích",
+ "timeout1": "Thời gian chờ kết nối đến máy chủ từ xa",
+ "timeout2": "Thời gian chờ kết nối đến máy chủ cục bộ",
+ "username": "Tên người dùng",
+ "validate": "Xác thực",
+ "validation_success": "Xác thực thành công",
+ "sender_allowed": "Cho phép gửi dưới bí danh này"
+ },
+ "admin": {
+ "access": "Truy cập",
+ "action": "Hành động",
+ "activate_api": "Kích hoạt API",
+ "activate_send": "Kích hoạt nút gửi",
+ "active": "Đang hoạt động",
+ "active_rspamd_settings_map": "Ánh xạ cài đặt đang hoạt động",
+ "add": "Thêm",
+ "add_admin": "Thêm quản trị viên",
+ "add_domain_admin": "Thêm quản trị viên tên miền",
+ "add_forwarding_host": "Thêm máy chủ chuyển tiếp",
+ "add_relayhost": "Thêm vận chuyển phụ thuộc người gửi",
+ "add_relayhost_hint": "Vui lòng lưu ý rằng dữ liệu xác thực, nếu có, sẽ được lưu trữ dưới dạng văn bản thuần.",
+ "add_row": "Thêm hàng",
+ "add_settings_rule": "Thêm quy tắc cài đặt",
+ "add_transport": "Thêm vận chuyển",
+ "add_transports_hint": "Vui lòng lưu ý rằng dữ liệu xác thực, nếu có, sẽ được lưu trữ dưới dạng văn bản thuần.",
+ "additional_rows": " hàng bổ sung đã được thêm",
+ "admin": "Quản trị viên",
+ "admin_details": "Chỉnh sửa chi tiết quản trị viên",
+ "admin_domains": "Gán tên miền",
+ "admins": "Những quản trị viên",
+ "admins_ldap": "Quản trị viên LDAP",
+ "admin_quicklink": "Ẩn liên kết nhanh đến trang đăng nhập quản trị",
+ "advanced_settings": "Cài đặt nâng cao",
+ "allowed_methods": "Phương thức cho phép kiểm soát truy cập",
+ "allowed_origins": "Nguồn gốc cho phép kiểm soát truy cập",
+ "api_allow_from": "Cho phép truy cập API từ các IP/ký hiệu mạng CIDR này",
+ "api_info": "API đang được phát triển. Tài liệu có thể được tìm thấy tại <a href=\"/api\">/api</a>",
+ "api_key": "Khóa API",
+ "api_read_only": "Truy cập chỉ đọc",
+ "api_read_write": "Truy cập đọc-ghi",
+ "api_skip_ip_check": "Bỏ qua kiểm tra IP cho API",
+ "app_hide": "Ẩn khi đăng nhập",
+ "app_links": "Liên kết ứng dụng",
+ "app_name": "Tên ứng dụng",
+ "apps_name": "Tên \"Ứng dụng mailcow\"",
+ "arrival_time": "Thời gian đến (giờ máy chủ)",
+ "authed_user": "Người dùng đã xác thực",
+ "ays": "Bạn có chắc chắn muốn tiếp tục không?",
+ "ban_list_info": "Xem danh sách IP bị cấm bên dưới: <b>mạng (thời gian cấm còn lại) - [hành động]</b>.<br />IP trong hàng đợi bỏ cấm sẽ được xóa khỏi danh sách cấm hoạt động trong vài giây.<br />Nhãn đỏ cho biết lệnh cấm vĩnh viễn đang hoạt động bởi danh sách từ chối.",
+ "change_logo": "Thay đổi logo",
+ "logo_normal_label": "Bình thường",
+ "logo_dark_label": "Đảo ngược cho chế độ tối",
+ "configuration": "Cấu hình",
+ "convert_html_to_text": "Chuyển đổi HTML thành văn bản thuần",
+ "copy_to_clipboard": "Văn bản đã được sao chép vào bộ nhớ tạm!",
+ "cors_settings": "Cài đặt CORS",
+ "credentials_transport_warning": "<b>Cảnh báo</b>: Thêm một mục ánh xạ vận chuyển mới sẽ cập nhật thông tin xác thực cho tất cả các mục có cột bước nhảy tiếp theo khớp.",
+ "customer_id": "ID Khách hàng",
+ "customize": "Tùy chỉnh",
+ "login_page": "Trang đăng nhập",
+ "destination": "Đích đến",
+ "dkim_add_key": "Thêm khóa ARC/DKIM",
+ "dkim_domains_selector": "Bộ chọn",
+ "dkim_domains_wo_keys": "Chọn tên miền thiếu khóa",
+ "dkim_from": "Từ",
+ "dkim_from_title": "Tên miền nguồn để sao chép dữ liệu",
+ "dkim_key_length": "Độ dài khóa DKIM (bits)",
+ "dkim_key_missing": "Thiếu khóa",
+ "dkim_key_unused": "Khóa không được sử dụng",
+ "dkim_key_valid": "Khóa hợp lệ",
+ "dkim_keys": "Khóa ARC/DKIM",
+ "dkim_overwrite_key": "Ghi đè khóa DKIM hiện có",
+ "dkim_private_key": "Khóa riêng tư",
+ "dkim_to": "Đến",
+ "dkim_to_title": "Tên miền đích - sẽ bị ghi đè",
+ "domain": "Tên miền",
+ "domain_admin": "Quản trị viên tên miền",
+ "domain_admins": "Các quản trị viên tên miền",
+ "domainadmin_quicklink": "Ẩn liên kết nhanh đến trang đăng nhập quản trị viên tên miền",
+ "domain_s": "Tên miền/s",
+ "duplicate": "Nhân bản",
+ "duplicate_dkim": "Nhân bản bản ghi DKIM",
+ "edit": "Chỉnh sửa",
+ "empty": "Không có kết quả",
+ "excludes": "Loại trừ những người nhận này",
+ "f2b_ban_time": "Thời gian cấm (giây)",
+ "f2b_ban_time_increment": "Thời gian cấm tăng dần với mỗi lần cấm",
+ "f2b_blacklist": "Mạng/máy chủ bị từ chối",
+ "f2b_filter": "Bộ lọc biểu thức chính quy",
+ "f2b_list_info": "Một máy chủ hoặc mạng bị từ chối sẽ luôn có quyền ưu tiên cao hơn một thực thể trong danh sách cho phép. <b>Cập nhật danh sách sẽ mất vài giây để được áp dụng.</b>",
+ "f2b_manage_external": "Quản lý Fail2Ban từ bên ngoài",
+ "f2b_manage_external_info": "Fail2ban sẽ vẫn duy trì danh sách cấm, nhưng sẽ không chủ động đặt quy tắc để chặn lưu lượng. Sử dụng danh sách cấm được tạo bên dưới để chặn lưu lượng từ bên ngoài.",
+ "f2b_max_attempts": "Số lần thử tối đa",
+ "f2b_max_ban_time": "Thời gian cấm tối đa (giây)",
+ "f2b_netban_ipv4": "Kích thước mạng con IPv4 để áp dụng lệnh cấm (8-32)",
+ "f2b_netban_ipv6": "Kích thước mạng con IPv6 để áp dụng lệnh cấm (8-128",
+ "f2b_parameters": "Tham số Fail2ban",
+ "f2b_regex_info": "Nhật ký được xem xét: SOGo, Postfix, Dovecot, PHP-FPM.",
+ "f2b_retry_window": "Cửa sổ thử lại (giây) cho số lần thử tối đa",
+ "f2b_whitelist": "Mạng/máy chủ được cho phép",
+ "filter": "Bộ lọc",
+ "filter_table": "Bảng bộ lọc",
+ "force_sso_text": "Nếu nhà cung cấp OIDC bên ngoài được cấu hình, tùy chọn này sẽ ẩn biểu mẫu đăng nhập mailcow mặc định và chỉ hiển thị nút Đăng nhập một lần",
+ "force_sso": "Vô hiệu hóa đăng nhập mailcow và chỉ hiển thị Đăng nhập một lần",
+ "forwarding_hosts": "Máy chủ chuyển tiếp",
+ "forwarding_hosts_add_hint": "Bạn có thể chỉ định địa chỉ IPv4/IPv6, mạng theo ký hiệu CIDR, tên máy chủ (sẽ được phân giải thành địa chỉ IP), hoặc tên miền (sẽ được phân giải thành địa chỉ IP bằng cách truy vấn bản ghi SPF hoặc, nếu không có, bản ghi MX).",
+ "forwarding_hosts_hint": "Tin nhắn đến được chấp nhận vô điều kiện từ bất kỳ máy chủ nào được liệt kê ở đây. Các máy chủ này sau đó không bị kiểm tra với DNSBL hoặc danh sách xám. Thư rác nhận từ chúng không bao giờ bị từ chối, nhưng có thể được chuyển vào thư mục Rác. Công dụng phổ biến nhất cho việc này là chỉ định các máy chủ thư mà bạn đã thiết lập quy tắc chuyển tiếp email đến cho máy chủ mailcow của bạn.",
+ "from": "Từ",
+ "generate": "tạo",
+ "guid": "GUID - ID phiên bản duy nhất",
+ "guid_and_license": "GUID & Giấy phép",
+ "hash_remove_info": "Xóa một giá trị băm giới hạn tốc độ (nếu vẫn tồn tại) sẽ đặt lại hoàn toàn bộ đếm của nó.<br\n Mỗi giá trị băm được chỉ định bằng một màu riêng biệt.",
+ "help_text": "Ghi đè văn bản trợ giúp bên dưới mặt nạ đăng nhập (cho phép HTML)",
+ "host": "Máy chủ",
+ "html": "HTML",
+ "iam": "Nhà cung cấp danh tính",
+ "iam_attribute_field": "Trường thuộc tính",
+ "iam_authorize_url": "Điểm cuối ủy quyền",
+ "iam_auth_flow": "Luồng xác thực",
+ "iam_auth_flow_info": "Ngoài Luồng mã ủy quyền (Luồng chuẩn trong Keycloak), được sử dụng cho đăng nhập một lần, mailcow còn hỗ trợ Luồng xác thực với thông tin xác thực trực tiếp. Luồng mật khẩu thư cố gắng xác thực thông tin người dùng bằng cách sử dụng API REST quản trị Keycloak. mailcow lấy mật khẩu đã băm từ thuộc tính <code>mailcow_password</code>, được ánh xạ trong Keycloak.",
+ "iam_basedn": "DN cơ sở",
+ "iam_client_id": "ID khách hàng",
+ "iam_client_secret": "Bí mật khách hàng",
+ "iam_client_scopes": "Phạm vi khách hàng",
+ "iam_default_template": "Mẫu mặc định",
+ "iam_default_template_description": "Nếu không có mẫu nào được gán cho người dùng, mẫu mặc định sẽ được sử dụng để tạo hộp thư, nhưng không dùng để cập nhật hộp thư.",
+ "iam_description": "Cấu hình Nhà cung cấp bên ngoài cho Xác thực<br>Hộp thư của người dùng sẽ được tự động tạo khi họ đăng nhập lần đầu, với điều kiện ánh xạ thuộc tính đã được thiết lập.",
+ "iam_extra_permission": "Để các cài đặt sau hoạt động, ứng dụng khách mailcow trong Keycloak cần một <code>Tài khoản dịch vụ</code> và quyền <code>xem người dùng</code>.",
+ "iam_host": "Máy chủ",
+ "iam_host_info": "Nhập một hoặc nhiều máy chủ LDAP, phân cách bằng dấu phẩy.",
+ "iam_import_users": "Nhập người dùng",
+ "iam_login_provisioning": "Tự động tạo người dùng khi đăng nhập",
+ "iam_mapping": "Ánh xạ thuộc tính",
+ "iam_bindpass": "Mật khẩu ràng buộc",
+ "iam_periodic_full_sync": "Đồng bộ hóa đầy đủ định kỳ",
+ "iam_port": "Cổng",
+ "iam_realm": "Vùng",
+ "iam_redirect_url": "URL chuyển hướng",
+ "iam_rest_flow": "Luồng mật khẩu thư",
+ "iam_server_url": "URL máy chủ",
+ "iam_sso": "Đăng nhập một lần",
+ "iam_sync_interval": "Khoảng thời gian đồng bộ / nhập (phút)",
+ "iam_test_connection": "Kiểm tra kết nối",
+ "iam_token_url": "Điểm cuối token",
+ "iam_userinfo_url": "Điểm cuối thông tin người dùng",
+ "iam_username_field": "Trường tên người dùng",
+ "iam_binddn": "DN ràng buộc",
+ "iam_use_ssl": "Sử dụng SSL",
+ "iam_use_ssl_info": "Nếu bật SSL và cổng được đặt là 389, nó sẽ tự động được ghi đè để sử dụng cổng 636.",
+ "iam_use_tls": "Sử dụng StartTLS",
+ "iam_use_tls_info": "Nếu bật TLS, bạn phải sử dụng cổng mặc định cho máy chủ LDAP của bạn (389). Không thể sử dụng các cổng SSL.",
+ "iam_version": "Phiên bản",
+ "ignore_ssl_error": "Bỏ qua lỗi SSL",
+ "import": "Nhập",
+ "import_private_key": "Nhập khóa riêng tư",
+ "in_use_by": "Đang được sử dụng bởi",
+ "inactive": "Không hoạt động",
+ "include_exclude": "Bao gồm/Loại trừ",
+ "include_exclude_info": "Mặc định - khi không có lựa chọn - <b>tất cả hộp thư</b> được đề cập",
+ "includes": "Bao gồm những người nhận này",
+ "ip_check": "Kiểm tra IP",
+ "ip_check_disabled": "Kiểm tra IP đã bị vô hiệu hóa. Bạn có thể bật nó trong<br> <strong>Hệ thống > Cấu hình > Tùy chọn > Tùy chỉnh</strong>",
+ "ip_check_opt_in": "Đăng ký tham gia sử dụng dịch vụ bên thứ ba dùng <strong>ipv4.mailcow.email</strong> và <strong>ipv6.mailcow.email</strong> để phân giải địa chỉ IP bên ngoài.",
+ "is_mx_based": "Dựa trên MX",
+ "last_applied": "Áp dụng lần cuối",
+ "license_info": "Giấy phép tuy không bắt buộc nhưng giúp phát triển thêm.<br><a href=\"https://www.servercow.de/mailcow?lang=en#sal\" target=\"_blank\" alt=\"Đặt hàng SAL\">Đăng ký GUID của bạn tại đây</a> hoặc <a href=\"https://www.servercow.de/mailcow?lang=en#support\" target=\"_blank\" alt=\"Đặt hàng hỗ trợ\">mua hỗ trợ cho cài đặt mailcow của bạn.</a>",
+ "link": "Liên kết",
+ "loading": "Vui lòng đợi...",
+ "login_time": "Thời gian đăng nhập",
+ "logo_info": "Hình ảnh của bạn sẽ được điều chỉnh theo chiều cao 40px cho thanh điều hướng trên cùng và chiều rộng tối đa 250px cho trang bắt đầu. Khuyến nghị sử dụng đồ họa có thể thay đổi kích thước.",
+ "lookup_mx": "Đích đến là một biểu thức chính quy để so khớp với tên MX (<code>.*.google.com</code> để định tuyến tất cả thư nhắm đến MX kết thúc bằng google.com qua bước nhảy này)",
+ "main_name": "Tên \"Giao diện mailcow\"",
+ "merged_vars_hint": "Các hàng bị mờ đã được hợp nhất từ <code>vars.(local.)inc.php</code> và không thể sửa đổi.",
+ "message": "Tin nhắn",
+ "message_size": "Kích thước tin nhắn",
+ "nexthop": "Bước nhảy tiếp theo",
+ "needs_restart": "cần khởi động lại",
+ "no_active_bans": "Không có lệnh cấm đang hoạt động",
+ "no_new_rows": "Không có hàng nào khác",
+ "no_record": "Không có bản ghi",
+ "oauth2_apps": "Ứng dụng OAuth2",
+ "oauth2_add_client": "Thêm ứng dụng khách OAuth2",
+ "oauth2_client_id": "ID ứng dụng khách",
+ "oauth2_client_secret": "Bí mật ứng dụng khách",
+ "oauth2_info": "Triển khai OAuth2 hỗ trợ loại cấp phép \"Mã ủy quyền\" và cấp token làm mới.<br>\nMáy chủ cũng tự động cấp token làm mới mới sau khi token làm mới đã được sử dụng.<br><br>\n• Phạm vi mặc định là <i>profile</i>. Chỉ người dùng hộp thư mới có thể được xác thực qua OAuth2. Nếu tham số phạm vi bị bỏ qua, nó sẽ trở về <i>profile</i>.<br>\n• Tham số <i>state</i> phải được gửi bởi ứng dụng khách như một phần của yêu cầu ủy quyền.<br><br>\nĐường dẫn cho các yêu cầu đến API OAuth2: <br>\n<ul>\n<li>Điểm cuối ủy quyền: <code>/oauth/authorize</code></li>\n<li>Điểm cuối token: <code>/oauth/token</code></li>\n<li>Trang tài nguyên: <code>/oauth/profile</code></li>\n</ul>\nTạo lại bí mật ứng dụng khách sẽ không làm hết hạn các mã ủy quyền hiện có, nhưng chúng sẽ không thể làm mới token của họ.<br><br>\nThu hồi token ứng dụng khách sẽ gây ra việc chấm dứt ngay lập tức tất cả các phiên hoạt động. Tất cả ứng dụng khách cần xác thực lại.",
+ "oauth2_redirect_uri": "URI chuyển hướng",
+ "oauth2_renew_secret": "Tạo bí mật ứng dụng khách mới",
+ "oauth2_revoke_tokens": "Thu hồi tất cả token ứng dụng khách",
+ "optional": "tùy chọn",
+ "options": "Các tùy chọn",
+ "password": "Mật khẩu",
+ "password_length": "Độ dài mật khẩu",
+ "password_policy": "Chính sách mật khẩu",
+ "password_policy_chars": "Phải chứa ít nhất một ký tự chữ cái",
+ "password_policy_length": "Độ dài mật khẩu tối thiểu là %d",
+ "password_policy_lowerupper": "Phải chứa ký tự viết thường và viết hoa",
+ "password_policy_numbers": "Phải chứa ít nhất một số",
+ "password_policy_special_chars": "Phải chứa ký tự đặc biệt",
+ "password_repeat": "Xác nhận mật khẩu (nhập lại)",
+ "password_reset_info": "Nếu không cung cấp email khôi phục, chức năng này không thể được sử dụng.",
+ "password_reset_settings": "Cài đặt khôi phục mật khẩu",
+ "password_reset_tmpl_html": "Mẫu HTML",
+ "password_reset_tmpl_text": "Mẫu văn bản",
+ "password_settings": "Cài đặt mật khẩu",
+ "priority": "Độ ưu tiên",
+ "private_key": "Khóa riêng tư",
+ "quarantine": "Cách ly",
+ "quarantine_bcc": "Gửi một bản sao của tất cả thông báo (BCC) đến người nhận này:<br><small>Để trống để vô hiệu hóa. <b>Thư không ký, không kiểm tra. Chỉ nên gửi nội bộ.</b></small>",
+ "quarantine_exclude_domains": "Loại trừ tên miền và tên miền bí danh",
+ "quarantine_max_age": "Tuổi tối đa theo ngày<br><small>Giá trị phải bằng hoặc lớn hơn 1 ngày.</small>",
+ "quarantine_max_score": "Bỏ thông báo nếu điểm thư rác của một thư cao hơn giá trị này:<br><small>Mặc định là 9999.0</small>",
+ "quarantine_max_size": "Kích thước tối đa tính bằng MiB (các phần tử lớn hơn sẽ bị loại bỏ):<br><small>0 <b>không</b> có nghĩa là không giới hạn.</small>",
+ "quarantine_notification_html": "Mẫu email thông báo:<br><small>Để trống để khôi phục mẫu mặc định.</small>",
+ "quarantine_notification_sender": "Người gửi email thông báo",
+ "quarantine_notification_subject": "Chủ đề email thông báo",
+ "quarantine_redirect": "<b>Chuyển hướng tất cả thông báo</b> đến người nhận này:<br><small>Để trống để vô hiệu hóa. <b>Thư không ký, không kiểm tra. Chỉ nên gửi nội bộ.</b></small>",
+ "quarantine_release_format": "Định dạng của các mục được phát hành",
+ "quarantine_release_format_att": "Dưới dạng tệp đính kèm",
+ "quarantine_release_format_raw": "Bản gốc không sửa đổi",
+ "quarantine_retention_size": "ưu giữ cho mỗi hộp thư:<br><small>0 có nghĩa là <b>không hoạt động</b>.</small>",
+ "quicklink_text": "Hiển thị hoặc ẩn liên kết nhanh đến các trang đăng nhập khác dưới biểu mẫu đăng nhập",
+ "quota_notification_html": "Mẫu email thông báo:<br><small>Để trống để khôi phục mẫu mặc định.</small>",
+ "quota_notification_sender": "Người gửi email thông báo",
+ "quota_notification_subject": "Chủ đề email thông báo",
+ "quota_notifications": "Thông báo hạn ngạch",
+ "quota_notifications_info": "Thông báo hạn ngạch được gửi cho người dùng một lần khi vượt quá 80% và một lần khi vượt quá 95% mức sử dụng.",
+ "quota_notifications_vars": "{{percent}} bằng hạn ngạch hiện tại của người dùng<br>{{username}} là tên hộp thư",
+ "queue_unban": "bỏ cấm",
+ "r_active": "Hạn chế đang hoạt động",
+ "r_inactive": "Hạn chế không hoạt động",
+ "r_info": "Các phần tử bị mờ/vô hiệu hóa trong danh sách hạn chế đang hoạt động không được mailcow công nhận là hạn chế hợp lệ và không thể di chuyển. Các hạn chế không xác định sẽ vẫn được đặt theo thứ tự xuất hiện. <br>Bạn có thể thêm phần tử mới trong <code>inc/vars.local.inc.php</code> để có thể bật/tắt chúng.",
+ "rate_name": "Tên tỷ lệ",
+ "recipients": "Người nhận",
+ "refresh": "Làm mới",
+ "regen_api_key": "Tạo lại khóa API",
+ "regex_maps": "Ánh xạ biểu thức chính quy",
+ "relay_from": "Địa chỉ \"Từ:\"",
+ "relay_rcpt": "Địa chỉ \"Đến:\"",
+ "relay_run": "Chạy thử",
+ "relayhosts": "Vận chuyển phụ thuộc người gửi",
+ "relayhosts_hint": "Xác định vận chuyển phụ thuộc người gửi để có thể chọn chúng trong hộp thoại cấu hình tên miền.<br>\nDịch vụ vận chuyển luôn là \"smtp:\" và do đó sẽ thử TLS khi được cung cấp. TLS được bọc (SMTPS) không được hỗ trợ. Cài đặt chính sách TLS gửi đi riêng của người dùng được tính đến.<br>\nẢnh hưởng đến các tên miền được chọn bao gồm cả tên miền bí danh.",
+ "remove": "Xóa",
+ "remove_row": "Xóa hàng",
+ "reset_default": "Đặt lại về mặc định",
+ "reset_limit": "Xóa giá trị băm",
+ "reset_password_vars": "<code>{{link}}</code> Liên kết đặt lại mật khẩu đã tạo<br><code>{{username}}</code> Tên hộp thư của người dùng yêu cầu đặt lại mật khẩu<br><code>{{username2}}</code> Tên hộp thư khôi phục<br><code>{{date}}</code> Ngày yêu cầu đặt lại mật khẩu được thực hiện<br><code>{{token_lifetime}}</code> Thời gian sống của token tính bằng phút<br><code>{{hostname}}</code> Tên máy chủ mailcow",
+ "restore_template": "Để trống để khôi phục mẫu mặc định.",
+ "routing": "Định tuyến",
+ "rsetting_add_rule": "Thêm quy tắc",
+ "rsetting_content": "Nội dung quy tắc",
+ "rsetting_desc": "Mô tả ngắn",
+ "rsetting_no_selection": "Vui lòng chọn một quy tắc",
+ "rsetting_none": "Không có quy tắc nào",
+ "rsettings_insert_preset": "Chèn mẫu ví dụ \"%s\"",
+ "rsettings_preset_1": "Vô hiệu hóa tất cả trừ DKIM và giới hạn tốc độ cho người dùng đã xác thực",
+ "rsettings_preset_2": "Quản trị viên bưu điện muốn thư rác",
+ "rsettings_preset_3": "Chỉ cho phép người gửi cụ thể cho một hộp thư (ví dụ: sử dụng như hộp thư nội bộ)",
+ "rsettings_preset_4": "Vô hiệu hóa Rspamd cho một tên miền",
+ "rspamd_com_settings": "Tên cài đặt sẽ được tự động tạo, vui lòng xem các mẫu ví dụ bên dưới. Để biết thêm chi tiết, xem <a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Tài liệu Rspamd</a>",
+ "rspamd_global_filters": "Ánh xạ bộ lọc toàn cục",
+ "rspamd_global_filters_agree": "Tôi sẽ cẩn thận!",
+ "rspamd_global_filters_info": "Ánh xạ bộ lọc toàn cục chứa các loại danh sách từ chối và cho phép toàn cục khác nhau.",
+ "rspamd_global_filters_regex": "Tên của chúng giải thích mục đích sử dụng. Tất cả nội dung phải chứa biểu thức chính quy hợp lệ theo định dạng \"/mẫu/tùy chọn\" (ví dụ: <code>/.+@domain.tld/i</code>).<br>\nMặc dù kiểm tra cơ bản được thực hiện trên mỗi dòng của regex, chức năng của Rspamd có thể bị hỏng nếu nó không đọc được cú pháp chính xác.<br>\nRspamd sẽ cố gắng đọc nội dung ánh xạ khi thay đổi. Nếu bạn gặp vấn đề, <a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">khởi động lại Rspamd</a> để bắt buộc tải lại ánh xạ.<br>Các phần tử trong danh sách từ chối được loại trừ khỏi cách ly.",
+ "rspamd_settings_map": "Ánh xạ cài đặt Rspamd",
+ "sal_level": "Cấp độ Moo",
+ "save": "Lưu thay đổi",
+ "search_domain_da": "Tìm kiếm tên miền",
+ "send": "Gửi",
+ "sender": "Người gửi",
+ "service": "Dịch vụ",
+ "service_id": "ID Dịch vụ",
+ "source": "Nguồn",
+ "spamfilter": "Bộ lọc thư rác",
+ "subject": "Chủ đề",
+ "success": "Thành công",
+ "sys_mails": "Thư hệ thống",
+ "task": "Nhiệm vụ",
+ "text": "Văn bản",
+ "time": "Thời gian",
+ "title": "Tiêu đề",
+ "title_name": "Tiêu đề trang web \"Giao diện mailcow\"",
+ "to_top": "Về đầu trang",
+ "transport_dest_format": "Regex hoặc cú pháp: example.org, .example.org, *, box@example.org (nhiều giá trị có thể được phân cách bằng dấu phẩy)",
+ "transport_maps": "Ánh xạ vận chuyển",
+ "transport_test_rcpt_info": "• Sử dụng null@hosted.mailcow.de để kiểm tra chuyển tiếp đến đích nước ngoài.",
+ "transports_hint": "• Một mục ánh xạ vận chuyển <b>ghi đè</b> một ánh xạ vận chuyển phụ thuộc người gửi</b>.<br>\n• Vận chuyển dựa trên MX được ưu tiên sử dụng.<br>\n• Cài đặt chính sách TLS gửi đi cho từng người dùng bị bỏ qua và chỉ có thể được thực thi bởi các mục ánh xạ chính sách TLS.<br>\n• Dịch vụ vận chuyển cho các vận chuyển đã định nghĩa luôn là \"smtp:\" và do đó sẽ thử TLS khi được cung cấp. TLS được bọc (SMTPS) không được hỗ trợ.<br>\n• Địa chỉ khớp với \"/localhost$/\" sẽ luôn được vận chuyển qua \"local:\", do đó đích \"*\" sẽ không áp dụng cho những địa chỉ đó.<br>\n• Để xác định thông tin xác thực cho bước nhảy tiếp theo ví dụ \"[host]:25\", Postfix <b>luôn</b> truy vấn \"host\" trước khi tìm kiếm \"[host]:25\". Hành vi này khiến không thể sử dụng \"host\" và \"[host]:25\" cùng một lúc.",
+ "ui_footer": "Chân trang (cho phép HTML)",
+ "ui_header_announcement": "Thông báo",
+ "ui_header_announcement_active": "Đặt thông báo hoạt động",
+ "ui_header_announcement_content": "Văn bản (cho phép HTML)",
+ "ui_header_announcement_help": "Thông báo hiển thị cho tất cả người dùng đã đăng nhập và trên màn hình đăng nhập của giao diện người dùng.",
+ "ui_header_announcement_select": "Chọn loại thông báo",
+ "ui_header_announcement_type": "Loại",
+ "ui_header_announcement_type_danger": "Rất quan trọng",
+ "ui_header_announcement_type_info": "Thông tin",
+ "ui_header_announcement_type_warning": "Quan trọng",
+ "ui_texts": "Nhãn và văn bản giao diện người dùng",
+ "unban_pending": "đang chờ bỏ cấm",
+ "unchanged_if_empty": "Nếu không thay đổi hãy để trống",
+ "upload": "Tải lên",
+ "username": "Tên người dùng",
+ "user_link": "Liên kết người dùng",
+ "user_quicklink": "Ẩn liên kết nhanh đến trang đăng nhập người dùng",
+ "validate_license_now": "Xác thực GUID với máy chủ giấy phép",
+ "verify": "Xác minh",
+ "yes": "✓"
+ },
+ "danger": {
+ "access_denied": "Truy cập bị từ chối hoặc dữ liệu biểu mẫu không hợp lệ",
+ "alias_domain_invalid": "Tên miền bí danh %s không hợp lệ",
+ "alias_empty": "Địa chỉ bí danh không được để trống",
+ "alias_goto_identical": "Địa chỉ bí danh và địa chỉ chuyển tiếp không được giống nhau",
+ "alias_invalid": "Địa chỉ bí danh %s không hợp lệ",
+ "aliasd_targetd_identical": "Tên miền bí danh không được giống với tên miền đích: %s",
+ "aliases_in_use": "Số bí danh tối đa phải lớn hơn hoặc bằng %d",
+ "app_name_empty": "Tên ứng dụng không được để trống",
+ "app_passwd_id_invalid": "ID mật khẩu ứng dụng %s không hợp lệ",
+ "authsource_in_use": "Nhà cung cấp danh tính không thể thay đổi hoặc xóa vì hiện đang được sử dụng bởi một hoặc nhiều người dùng.",
+ "bcc_empty": "Đích BCC không được để trống",
+ "bcc_exists": "Một ánh xạ BCC %s đã tồn tại cho loại %s",
+ "bcc_must_be_email": "Đích BCC %s không phải là địa chỉ email hợp lệ",
+ "comment_too_long": "Bình luận quá dài, cho phép tối đa 160 ký tự",
+ "cors_invalid_method": "Phương thức Allow-Method được chỉ định không hợp lệ",
+ "cors_invalid_origin": "Allow-Origin được chỉ định không hợp lệ",
+ "defquota_empty": "Hạn ngạch mặc định cho mỗi hộp thư không được là 0.",
+ "demo_mode_enabled": "Chế độ Demo đang được bật",
+ "description_invalid": "Mô tả tài nguyên cho %s không hợp lệ",
+ "dkim_domain_or_sel_exists": "Một khóa DKIM cho \"%s\" đã tồn tại và sẽ không bị ghi đè",
+ "dkim_domain_or_sel_invalid": "Tên miền hoặc bộ chọn DKIM không hợp lệ: %s",
+ "domain_cannot_match_hostname": "Tên miền không thể trùng với tên máy chủ",
+ "domain_exists": "Tên miền %s đã tồn tại",
+ "domain_invalid": "Tên miền trống hoặc không hợp lệ",
+ "domain_not_empty": "Không thể xóa tên miền %s không trống",
+ "domain_not_found": "Không tìm thấy tên miền %s",
+ "domain_quota_m_in_use": "Hạn ngạch tên miền phải lớn hơn hoặc bằng %s MiB",
+ "extended_sender_acl_denied": "thiếu ACL để đặt địa chỉ người gửi bên ngoài",
+ "extra_acl_invalid": "Địa chỉ người gửi bên ngoài \"%s\" không hợp lệ",
+ "extra_acl_invalid_domain": "Người gửi bên ngoài \"%s\" sử dụng tên miền không hợp lệ",
+ "fido2_verification_failed": "Xác minh FIDO2 thất bại: %s",
+ "file_open_error": "Không thể mở tệp để ghi",
+ "filter_type": "Loại bộ lọc không đúng",
+ "from_invalid": "Người gửi không được để trống",
+ "generic_server_error": "Đã xảy ra lỗi máy chủ không mong đợi. Vui lòng liên hệ quản trị viên của bạn.",
+ "global_filter_write_error": "Không thể ghi tệp bộ lọc: %s",
+ "global_map_invalid": "ID ánh xạ toàn cục %s không hợp lệ",
+ "global_map_write_error": "Không thể ghi ID ánh xạ toàn cục %s: %s",
+ "goto_empty": "Một địa chỉ bí danh phải chứa ít nhất một địa chỉ chuyển tiếp hợp lệ",
+ "goto_invalid": "Địa chỉ chuyển tiếp %s không hợp lệ",
+ "ham_learn_error": "Lỗi học thư hợp lệ: %s",
+ "iam_test_connection": "Kết nối thất bại",
+ "imagick_exception": "Lỗi: Ngoại lệ Imagick khi đọc hình ảnh",
+ "img_dimensions_exceeded": "Hình ảnh vượt quá kích thước tối đa cho phép",
+ "img_invalid": "Không thể xác thực tệp hình ảnh",
+ "img_size_exceeded": "Hình ảnh vượt quá kích thước tệp tối đa",
+ "img_tmp_missing": "Không thể xác thực tệp hình ảnh: Không tìm thấy tệp tạm thời",
+ "invalid_bcc_map_type": "Loại ánh xạ BCC không hợp lệ",
+ "invalid_destination": "Định dạng đích \"%s\" không hợp lệ",
+ "invalid_filter_type": "Loại bộ lọc không hợp lệ",
+ "invalid_host": "Máy chủ được chỉ định không hợp lệ: %s",
+ "invalid_mime_type": "Kiểu MIME không hợp lệ",
+ "invalid_nexthop": "Định dạng bước nhảy tiếp theo không hợp lệ",
+ "invalid_nexthop_authenticated": "Bước nhảy tiếp theo tồn tại với thông tin xác thực khác, vui lòng cập nhật thông tin xác thực hiện có cho bước nhảy này trước.",
+ "invalid_recipient_map_new": "Người nhận mới được chỉ định không hợp lệ: %s",
+ "invalid_recipient_map_old": "Người nhận gốc được chỉ định không hợp lệ: %s",
+ "invalid_reset_token": "Token đặt lại không hợp lệ",
+ "ip_list_empty": "Danh sách IP được phép không được để trống",
+ "is_alias": "%s đã được biết đến như một địa chỉ bí danh",
+ "is_alias_or_mailbox": "%s đã được biết đến như một bí danh, một hộp thư hoặc một địa chỉ bí danh được mở rộng từ một tên miền bí danh.",
+ "is_spam_alias": "%s đã được biết đến như một địa chỉ bí danh tạm thời (địa chỉ bí danh thư rác)",
+ "last_key": "Không thể xóa khóa cuối cùng, vui lòng vô hiệu hóa TFA thay thế.",
+ "login_failed": "Đăng nhập không thành công",
+ "mailbox_defquota_exceeds_mailbox_maxquota": "Hạn ngạch mặc định vượt quá giới hạn hạn ngạch tối đa",
+ "mailbox_invalid": "Tên hộp thư không hợp lệ",
+ "mailbox_quota_exceeded": "Hạn ngạch vượt quá giới hạn tên miền (tối đa %d MiB)",
+ "mailbox_quota_exceeds_domain_quota": "Hạn ngạch tối đa vượt quá giới hạn hạn ngạch tên miền",
+ "mailbox_quota_left_exceeded": "Không đủ dung lượng còn lại (dung lượng còn lại: %d MiB)",
+ "mailboxes_in_use": "Số hộp thư tối đa phải lớn hơn hoặc bằng %d",
+ "malformed_username": "Tên người dùng không đúng định dạng",
+ "map_content_empty": "Nội dung ánh xạ không được để trống",
+ "max_age_invalid": "Tuổi tối đa %s không hợp lệ",
+ "max_alias_exceeded": "Vượt quá số bí danh tối đa",
+ "max_mailbox_exceeded": "Vượt quá số hộp thư tối đa (%d trên %d)",
+ "max_quota_in_use": "Hạn ngạch hộp thư phải lớn hơn hoặc bằng %d MiB",
+ "maxquota_empty": "Hạn ngạch tối đa cho mỗi hộp thư không được là 0.",
+ "mode_invalid": "Chế độ %s không hợp lệ",
+ "mx_invalid": "Bản ghi MX %s không hợp lệ",
+ "mysql_error": "Lỗi MySQL: %s",
+ "network_host_invalid": "Mạng hoặc máy chủ không hợp lệ: %s",
+ "next_hop_interferes": "%s xung đột với bước nhảy tiếp theo %s",
+ "next_hop_interferes_any": "Một bước nhảy tiếp theo hiện có xung đột với %s",
+ "nginx_reload_failed": "Tải lại Nginx thất bại: %s",
+ "no_user_defined": "Không có người dùng được định nghĩa",
+ "object_exists": "Đối tượng %s đã tồn tại",
+ "object_is_not_numeric": "Giá trị %s không phải là số",
+ "password_complexity": "Mật khẩu không đáp ứng chính sách",
+ "password_empty": "Mật khẩu không được để trống",
+ "password_mismatch": "Mật khẩu xác nhận không khớp",
+ "password_reset_invalid_user": "Không tìm thấy hộp thư hoặc không có email khôi phục được thiết lập",
+ "password_reset_na": "Tính năng khôi phục mật khẩu hiện không khả dụng. Vui lòng liên hệ quản trị viên của bạn.",
+ "policy_list_from_exists": "Một bản ghi với tên đã cho tồn tại",
+ "policy_list_from_invalid": "Bản ghi có định dạng không hợp lệ",
+ "private_key_error": "Lỗi khóa riêng tư: %s",
+ "pushover_credentials_missing": "Thiếu token hoặc khóa Pushover",
+ "pushover_key": "Khóa Pushover có định dạng không đúng",
+ "pushover_token": "Token Pushover có định dạng không đúng",
+ "quota_not_0_not_numeric": "Hạn ngạch phải là số và >= 0",
+ "recipient_map_entry_exists": "Mục ánh xạ người nhận \"%s\" đã tồn tại",
+ "recovery_email_failed": "Không thể gửi email khôi phục. Vui lòng liên hệ quản trị viên của bạn.",
+ "redis_error": "Lỗi Redis: %s",
+ "relayhost_invalid": "Mục ánh xạ %s không hợp lệ",
+ "release_send_failed": "Không thể phát hành thư: %s",
+ "required_data_missing": "Thiếu dữ liệu bắt buộc %s",
+ "reset_f2b_regex": "Không thể đặt lại bộ lọc biểu thức chính quy kịp thời, vui lòng thử lại hoặc đợi thêm vài giây và tải lại trang web.",
+ "reset_token_limit_exceeded": "Đã vượt quá giới hạn token đặt lại. Vui lòng thử lại sau.",
+ "resource_invalid": "Tên tài nguyên %s không hợp lệ",
+ "rl_timeframe": "Khung thời gian giới hạn tốc độ không chính xác",
+ "rspamd_ui_pw_length": "Mật khẩu giao diện Rspamd phải có ít nhất 6 ký tự",
+ "script_empty": "Tập lệnh không được để trống",
+ "sender_acl_invalid": "Giá trị ACL người gửi %s không hợp lệ",
+ "set_acl_failed": "Không thể thiết lập ACL",
+ "settings_map_invalid": "ID ánh xạ cài đặt %s không hợp lệ",
+ "sieve_error": "Lỗi phân tích cú pháp Sieve: %s",
+ "spam_learn_error": "Lỗi học thư rác: %s",
+ "subject_empty": "Tiêu đề không được để trống",
+ "target_domain_invalid": "Tên miền đích %s không hợp lệ",
+ "targetd_not_found": "Không tìm thấy tên miền đích %s",
+ "targetd_relay_domain": "Tên miền đích %s là tên miền chuyển tiếp",
+ "template_exists": "Mẫu %s đã tồn tại",
+ "template_id_invalid": "ID mẫu %s không hợp lệ",
+ "template_name_invalid": "Tên mẫu không hợp lệ",
+ "temp_error": "Lỗi tạm thời",
+ "text_empty": "Văn bản không được để trống",
+ "tfa_token_invalid": "Token xác thực hai yếu tố không hợp lệ",
+ "tls_policy_map_dest_invalid": "Đích chính sách TLS không hợp lệ",
+ "tls_policy_map_entry_exists": "Mục ánh xạ chính sách TLS \"%s\" đã tồn tại",
+ "tls_policy_map_parameter_invalid": "Tham số chính sách không hợp lệ",
+ "to_invalid": "Người nhận không được để trống",
+ "totp_verification_failed": "Xác thực TOTP thất bại",
+ "transport_dest_exists": "Đích vận chuyển \"%s\" đã tồn tại",
+ "webauthn_verification_failed": "Xác thực WebAuthn thất bại: %s",
+ "webauthn_authenticator_failed": "Không tìm thấy trình xác thực đã chọn",
+ "webauthn_publickey_failed": "Không có khóa công khai nào được lưu cho trình xác thực đã chọn",
+ "webauthn_username_failed": "Trình xác thực đã chọn thuộc về tài khoản khác",
+ "unknown": "Đã xảy ra lỗi không xác định",
+ "unknown_tfa_method": "Phương thức xác thực hai yếu tố không xác định",
+ "unlimited_quota_acl": "Hạn ngạch không giới hạn bị cấm bởi ACL",
+ "username_invalid": "Tên người dùng %s không thể sử dụng được",
+ "validity_missing": "Vui lòng gán thời hạn hiệu lực",
+ "value_missing": "Vui lòng cung cấp tất cả các giá trị",
+ "version_invalid": "Phiên bản %s không hợp lệ",
+ "yotp_verification_failed": "Xác thực Yubico OTP thất bại: %s",
+ "tfa_removal_blocked": "Xác thực hai yếu tố không thể bị xóa vì đây là yêu cầu bắt buộc đối với tài khoản của bạn.",
+ "quarantine_category_invalid": "Danh mục cách ly phải là một trong các loại sau : add_header, reject, all."
+ },
+ "datatables": {
+ "collapse_all": "Thu gọn tất cả",
+ "emptyTable": "Không có dữ liệu trong bảng",
+ "expand_all": "Mở rộng tất cả",
+ "info": "Hiển thị từ _START_ đến _END_ của _TOTAL_ mục",
+ "infoEmpty": "Hiển thị 0 đến 0 của 0 mục",
+ "infoFiltered": "(được lọc từ tổng số _MAX_ mục)",
+ "lengthMenu": "Hiển thị _MENU_ mục",
+ "loadingRecords": "Đang tải...",
+ "processing": "Vui lòng đợi...",
+ "search": "Tìm kiếm:",
+ "zeroRecords": "Không tìm thấy bản ghi phù hợp",
+ "paginate": {
+ "first": "Đầu",
+ "last": "Cuối",
+ "next": "Tiếp",
+ "previous": "Trước"
+ },
+ "aria": {
+ "sortAscending": ": kích hoạt để sắp xếp cột tăng dần",
+ "sortDescending": ": kích hoạt để sắp xếp cột giảm dần"
+ },
+ "decimal": ".",
+ "thousands": ","
+ },
+ "debug": {
+ "architecture": "Kiến trúc",
+ "chart_this_server": "Biểu đồ (máy chủ này)",
+ "containers_info": "Thông tin container",
+ "container_running": "Đang chạy",
+ "container_disabled": "Container đã dừng hoặc bị vô hiệu hóa",
+ "container_stopped": "Đã dừng",
+ "cores": "Nhân CPU",
+ "current_time": "Thời gian hệ thống",
+ "disk_usage": "Sử dụng ổ đĩa",
+ "docs": "Tài liệu",
+ "error_show_ip": "Không thể phân giải địa chỉ IP công khai",
+ "external_logs": "Nhật ký ngoài",
+ "history_all_servers": "Lịch sử (tất cả máy chủ)",
+ "in_memory_logs": "Nhật ký trong bộ nhớ",
+ "last_modified": "Sửa đổi lần cuối",
+ "log_info": "<p>mailcow <b>nhật ký trong bộ nhớ</b> được thu thập trong danh sách Redis và được cắt giảm xuống LOG_LINES (%d) mỗi phút để giảm tải.\n<br>Nhật ký trong bộ nhớ không nhằm mục đích lưu trữ lâu dài. Tất cả các ứng dụng ghi nhật ký trong bộ nhớ cũng ghi vào Docker daemon và do đó vào trình điều khiển ghi nhật ký mặc định.r\n<br>Loại nhật ký trong bộ nhớ nên được sử dụng để gỡ lỗi các vấn đề nhỏ với các container.</p>\n<p><b>Nhật ký bên ngoài</b> được thu thập thông qua API của ứng dụng đã cho.</p>\n<p><b>Nhật ký tĩnh</b> chủ yếu là nhật ký hoạt động, không được ghi vào Dockerd nhưng vẫn cần được lưu trữ lâu dài (ngoại trừ nhật ký API).</p>",
+ "login_time": "Thời gian",
+ "logs": "Nhật ký",
+ "memory": "Bộ nhớ",
+ "online_users": "Người dùng trực tuyến",
+ "restart_container": "Khởi động lại",
+ "service": "Dịch vụ",
+ "show_ip": "Hiển thị IP công khai",
+ "size": "Kích thước",
+ "started_at": "Bắt đầu lúc",
+ "started_on": "Bắt đầu vào",
+ "static_logs": "Nhật ký tĩnh",
+ "success": "Thành công",
+ "system_containers": "Hệ thống & Container",
+ "timezone": "Múi giờ",
+ "uptime": "Thời gian hoạt động",
+ "update_available": "Có bản cập nhật mới",
+ "no_update_available": "Hệ thống đang ở phiên bản mới nhất",
+ "update_failed": "Không thể kiểm tra cập nhật",
+ "username": "Tên người dùng",
+ "wip": "Đang trong quá trình phát triển"
+ },
+ "diagnostics": {
+ "cname_from_a": "Giá trị được lấy từ bản ghi A/AAAA. Điều này được hỗ trợ miễn là bản ghi trỏ đến tài nguyên chính xác.",
+ "dns_records": "Bản ghi DNS",
+ "dns_records_24hours": "Xin lưu ý rằng các thay đổi được thực hiện đối với DNS có thể mất tới 24 giờ để phản ánh chính xác trạng thái hiện tại của chúng trên trang này. Trang này nhằm giúp bạn dễ dàng xem cách cấu hình bản ghi DNS và kiểm tra xem tất cả bản ghi của bạn có được lưu trữ chính xác trong DNS hay không.",
+ "dns_records_data": "Dữ liệu chính xác",
+ "dns_records_docs": "Vui lòng tham khảo thêm <a target=\"_blank\" href=\"https://docs.mailcow.email/getstarted/prerequisite-dns\">tài liệu hướng dẫn</a>.",
+ "dns_records_name": "Tên",
+ "dns_records_status": "Trạng thái hiện tại",
+ "dns_records_type": "Loại",
+ "optional": "Bản ghi này là tùy chọn."
+ },
+ "edit": {
+ "acl": "ACL (Quyền hạn)",
+ "active": "Hoạt động",
+ "admin": "Chỉnh sửa quản trị viên",
+ "advanced_settings": "Cài đặt nâng cao",
+ "alias": "Chỉnh sửa bí danh",
+ "allow_from_smtp": "Chỉ cho phép các IP sau sử dụng <b>SMTP</b>",
+ "allow_from_smtp_info": "Để trống để cho phép tất cả người gửi.<br>Địa chỉ và mạng IPv4/IPv6.",
+ "allowed_protocols": "Các giao thức được phép truy cập trực tiếp của người dùng (không ảnh hưởng đến giao thức mật khẩu ứng dụng)",
+ "app_name": "Tên ứng dụng",
+ "app_passwd": "Mật khẩu ứng dụng",
+ "app_passwd_protocols": "Các giao thức được phép cho mật khẩu ứng dụng",
+ "automap": "Thử tự động ánh xạ thư mục (\"Mục đã gửi\", \"Đã gửi\" => \"Đã gửi\" v.v.)",
+ "backup_mx_options": "Tùy chọn chuyển tiếp",
+ "bcc_dest_format": "Đích BCC phải là một địa chỉ email hợp lệ duy nhất.<br>Nếu bạn cần gửi bản sao đến nhiều địa chỉ, hãy tạo một bí danh và sử dụng nó ở đây.",
+ "client_id": "ID khách hàng",
+ "client_secret": "Khóa bí mật khách hàng",
+ "comment_info": "Bình luận riêng tư không hiển thị với người dùng, trong khi bình luận công khai được hiển thị dưới dạng chú thích khi di chuột qua trong tổng quan người dùng",
+ "created_on": "Được tạo vào",
+ "custom_attributes": "Thuộc tính tùy chỉnh",
+ "delete1": "Xóa từ nguồn khi hoàn thành",
+ "delete2": "Xóa thư ở đích không có ở nguồn",
+ "delete2duplicates": "Xóa các bản sao ở đích",
+ "delete_ays": "Vui lòng xác nhận quá trình xóa.",
+ "description": "Mô tả",
+ "disable_login": "Không cho phép đăng nhập (vẫn nhận được thư đến)",
+ "domain": "Chỉnh sửa tên miền",
+ "domain_admin": "Chỉnh sửa quản trị viên tên miền",
+ "domain_footer": "Chân trang toàn tên miền",
+ "domain_footer_html": "Chân trang HTML",
+ "domain_footer_info": "Chân trang toàn tên miền được thêm vào tất cả các email gửi đi liên quan đến một địa chỉ trong tên miền này. <br> Các biến sau có thể được sử dụng cho chân trang:",
+ "domain_footer_info_vars": {
+ "auth_user": "{= auth_user =} - Tên người dùng đã xác thực được chỉ định bởi MTA",
+ "from_user": "{= from_user =} - Phần người dùng của phong bì, ví dụ \"moo@mailcow.tld\" sẽ trả về \"moo\"",
+ "from_name": "{= from_name =} - Tên từ phong bì, ví dụ \"Mailcow <moo@mailcow.tld>\" sẽ trả về \"Mailcow\"",
+ "from_addr": "{= from_addr =} - Phần địa chỉ của phong bì",
+ "from_domain": "{= from_domain =} - Phần tên miền của phong bì",
+ "custom": "{= foo =} - Nếu hộp thư có thuộc tính tùy chỉnh \"foo\" với giá trị \"bar\" sẽ trả về \"bar\""
+ },
+ "domain_footer_plain": "Chân trang văn bản thuần",
+ "domain_footer_skip_replies": "Bỏ qua chân trang trong email trả lời",
+ "domain_quota": "Hạn ngạch tên miền",
+ "domains": "Các tên miền",
+ "dont_check_sender_acl": "Tắt kiểm tra người gửi cho tên miền %s (+ tên miền bí danh)",
+ "edit_alias_domain": "Chỉnh sửa tên miền bí danh",
+ "encryption": "Mã hóa",
+ "exclude": "Loại trừ đối tượng (biểu thức chính quy)",
+ "extended_sender_acl": "Địa chỉ người gửi bên ngoài",
+ "extended_sender_acl_info": "Khóa tên miền DKIM nên được nhập vào, nếu có sẵn.<br>\n Nhớ thêm máy chủ này vào bản ghi SPF TXT tương ứng.<br>\n Khi một tên miền hoặc tên miền bí danh được thêm vào máy chủ này, mà trùng với một địa chỉ bên ngoài, địa chỉ bên ngoài sẽ bị xóa.<br>\n Sử dụng @domain.tld để cho phép gửi dưới dạng *@domain.tld.",
+ "force_pw_update": "Bắt buộc cập nhật mật khẩu trong lần đăng nhập tiếp theo",
+ "force_pw_update_info": "Người dùng này sẽ chỉ có thể đăng nhập vào %s. Mật khẩu ứng dụng vẫn có thể sử dụng được.",
+ "footer_exclude": "Loại trừ khỏi chân trang",
+ "full_name": "Tên đầy đủ",
+ "gal": "Danh sách địa chỉ toàn cục",
+ "gal_info": "GAL chứa tất cả các đối tượng của một tên miền và không thể được chỉnh sửa bởi bất kỳ người dùng nào. Thông tin rảnh/bận trong SOGo sẽ bị thiếu nếu vô hiệu hóa! <b>Khởi động lại SOGo để áp dụng thay đổi.</b>",
+ "generate": "tạo",
+ "grant_types": "Các loại cấp quyền",
+ "hostname": "Tên máy chủ",
+ "inactive": "Không hoạt động",
+ "internal": "Nội bộ",
+ "internal_info": "Bí danh nội bộ chỉ có thể truy cập từ tên miền sở hữu hoặc tên miền bí danh.",
+ "kind": "Loại",
+ "last_modified": "Sửa đổi lần cuối",
+ "lookup_mx": "Đích là một biểu thức chính quy để khớp với tên MX (<code>.*.google.com</code> để định tuyến tất cả thư nhắm đến MX kết thúc bằng google.com qua bước nhảy này)",
+ "sender_allowed": "Cho phép gửi đi bằng bí danh",
+ "sender_allowed_info": "Nếu bị vô hiệu hóa, bí danh này chỉ có thể nhận thư. Sử dụng ACL của người gửi để ghi đè và cấp quyền gửi cho các hộp thư cụ thể.",
+ "mailbox": "Chỉnh sửa hộp thư",
+ "mailbox_quota_def": "Hạn mức hộp thư mặc định",
+ "mailbox_relayhost_info": "Chỉ áp dụng cho hộp thư và các bí danh trực tiếp, thao tác này sẽ ghi đè lên máy chủ chuyển tiếp tên miền.",
+ "mailbox_rename": "Đổi tên hộp thư",
+ "mailbox_rename_agree": "Tôi đã tạo bản sao lưu.",
+ "mailbox_rename_warning": "QUAN TRỌNG! Hãy tạo bản sao lưu trước khi đổi tên hộp thư.",
+ "mailbox_rename_alias": "Tạo tự động bí danh",
+ "mailbox_rename_title": "Tên mới của hộp thư cục bộ",
+ "max_aliases": "Số lượng Bí danh tối đa",
+ "max_mailboxes": "Số lượng hộp thư tối đa có thể có",
+ "max_quota": "Dung lượng tối đa cho mỗi hộp thư (MiB)"
+ }
+}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-cn.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-cn.json
index cca5ecc..2a1a080 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-cn.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-cn.json
@@ -24,11 +24,13 @@
"sogo_access": "允许管理 SOGo 访问权限",
"sogo_profile_reset": "重置 SOGo 个人资料",
"spam_alias": "临时别名",
- "spam_policy": "黑名单/白名单",
+ "spam_policy": "阻止名单/允许名单",
"spam_score": "垃圾邮件分数",
"syncjobs": "同步任务",
"tls_policy": "TLS 策略",
- "unlimited_quota": "无限邮箱容量配额"
+ "unlimited_quota": "无限邮箱容量配额",
+ "pw_reset": "允许重置mailcow使用者密码",
+ "alias_external_goto": "允许带有外部目标地址的别名"
},
"add": {
"activate_filter_warn": "当“启用”选项被勾选后,其它所有的过滤器都会被禁用。",
@@ -62,7 +64,7 @@
"exclude": "拒绝对象 (Regex)",
"full_name": "全称",
"gal": "全球地址簿",
- "gal_info": "<b>全球地址簿</b>包含了域名下的所有对象,并且此行为不能被用户更改。如果关闭,用户的 \"空闲/繁忙\" 的状态将无法在 SOGo 中显示。 <b>重启 SOGo 服务以应用更改。</b>",
+ "gal_info": "全球地址簿包含了域名下的所有对象,并且此行为不能被用户更改。如果关闭,用户的 \"空闲/繁忙\" 的状态将无法在 SOGo 中显示。 <b>重启 SOGo 服务以应用更改。</b>",
"generate": "生成",
"goto_ham": "学习为<span class=\"text-success\"><b>非垃圾邮件</b></span>",
"goto_null": "静默丢弃邮件",
@@ -107,7 +109,11 @@
"timeout2": "本地主机连接超时时间",
"username": "用户名",
"validate": "验证",
- "validation_success": "验证成功"
+ "validation_success": "验证成功",
+ "dry": "模拟同步(Dry run)",
+ "internal_info": "内部的别名只能在域内部或者别名域内部访问。",
+ "internal": "内部的",
+ "sender_allowed": "允许以该别名发送"
},
"admin": {
"access": "权限管理",
@@ -145,7 +151,7 @@
"arrival_time": "到达时间 (服务器时间)",
"authed_user": "已认证用户",
"ays": "确定继续操作?",
- "ban_list_info": "以下为被封禁的 IP 列表: <b>网络 (剩余封禁时间) - [操作]</b>。<br />被取消封禁的 IP 将会在几秒之内从封禁列表中移除<br />红色标签表示因黑名单而导致的永久封禁",
+ "ban_list_info": "以下为被封禁的 IP 列表: <b>网络 (剩余封禁时间) - [操作]</b>。<br />被取消封禁的 IP 将会在几秒之内从封禁列表中移除<br />红色标签表示因阻止名单而导致的永久封禁。",
"change_logo": "更改 Logo",
"configuration": "配置",
"convert_html_to_text": "将 HTML 转换为纯文本内容",
@@ -177,16 +183,16 @@
"empty": "结果为空",
"excludes": "除了",
"f2b_ban_time": "封禁时间 (秒)",
- "f2b_blacklist": "网络/主机黑名单",
+ "f2b_blacklist": "网络/主机阻止名单",
"f2b_filter": "正则表达式过滤器",
- "f2b_list_info": "黑名单的优先级总是高于白名单。 <b>列表更新将会在几秒之后完成。</b>",
+ "f2b_list_info": "阻止名单的优先级总是高于允许名单。 <b>列表更新将会在几秒之后完成。</b>",
"f2b_max_attempts": "最多尝试次数",
"f2b_netban_ipv4": "应用封禁的 IPv4 子网大小 (8-32)",
"f2b_netban_ipv6": "应用封禁的 IPv6 子网大小 (8-128)",
"f2b_parameters": "Fail2ban 参数",
"f2b_regex_info": "将会过滤这些应用的日志: SOGo,Postfix,Dovecot 和 PHP-FPM。",
"f2b_retry_window": "最多尝试次数重试窗口 (秒)",
- "f2b_whitelist": "网络/主机白名单",
+ "f2b_whitelist": "网络/主机允许名单",
"filter_table": "筛选表格",
"forwarding_hosts": "转发主机",
"forwarding_hosts_add_hint": "你可以指定 IPv4/IPv6 地址、CIDR 表示的网络、主机名 (解析为 IP 地址),或者邮箱域名 (查询 SPF 记录或 MX 记录并解析为 IP 地址)。",
@@ -204,7 +210,7 @@
"in_use_by": "使用者",
"inactive": "禁用",
"include_exclude": "包括/排除",
- "include_exclude_info": "默认 - 没有选择时默认包括所有邮箱",
+ "include_exclude_info": "默认 - 没有选择时默认包括<b>所有邮箱</b>",
"includes": "包括这些收件人",
"is_mx_based": "基于 MX 记录",
"last_applied": "最后应用的条目",
@@ -291,11 +297,11 @@
"rsettings_preset_2": "允许管理员接收垃圾邮件",
"rsettings_preset_3": "只允许指定的发件人发信 (例如只允许内部邮箱发送)",
"rsettings_preset_4": "禁用域名的 Rspamd 服务",
- "rspamd_com_settings": "设置名称将会自动生成,请看参考下方的示例预设。查看<a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd 文档</a>以了解更多的细节。",
+ "rspamd_com_settings": "设置名称将会自动生成,请看参考下方的示例预设。查看<a href=\"https://rspamd.com/doc/configuration/settings.html#settings-structure\" target=\"_blank\">Rspamd 文档</a>以了解更多的细节",
"rspamd_global_filters": "全局过滤规则",
"rspamd_global_filters_agree": "我会小心谨慎的!",
- "rspamd_global_filters_info": "全局过滤规则包含了不同类型的全局黑名单和白名单。",
- "rspamd_global_filters_regex": "它们的名字解释了它们的用途。所有内容必须包含 \"/pattern/options\" 格式的合法表达式 (例如 <code>/.+@domain\\.tld/i</code>)。<br>\r\n 因为仅对正则表达式执行了基本的检查,Rspamd 的功能仍可能因正则表达式语法问题出现错误。<br>\r\n Rspamd 会在规则更改后读取其内容。 如果你遇到了问题,<a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">重启 Rspamd</a> 以强制重载规则。<br>黑名单中的项目会被系统排除。",
+ "rspamd_global_filters_info": "全局过滤规则包含了不同类型的全局阻止名单和允许名单。",
+ "rspamd_global_filters_regex": "它们的名字解释了它们的用途。所有内容必须包含 \"/pattern/options\" 格式的合法表达式 (例如 <code>/.+@domain\\.tld/i</code>)。<br>\n 因为仅对正则表达式执行了基本的检查,Rspamd 的功能仍可能因正则表达式语法问题出现错误。<br>\n Rspamd 会在规则更改后读取其内容。 如果你遇到了问题,<a href=\"\" data-toggle=\"modal\" data-container=\"rspamd-mailcow\" data-target=\"#RestartContainer\">重启 Rspamd</a> 以强制重载规则。<br>阻止名单中的项目会被系统排除。",
"rspamd_settings_map": "Rspamd 设置",
"sal_level": "Moo 等级",
"save": "保存更改",
@@ -336,7 +342,77 @@
"validate_license_now": "通过证书服务器验证 GUID",
"verify": "验证",
"yes": "✓",
- "options": "选项"
+ "options": "选项",
+ "f2b_max_ban_time": "最长封禁时间(秒)",
+ "copy_to_clipboard": "已复制到粘贴板!",
+ "reset_password_vars": "<code>{{link}}</code> 生成的密码重置链接<br><code>{{username}}</code> 要求重置密码的使用者的邮箱名称<br><code>{{username2}}</code> 复原邮箱名称<br><code>{{date}}</code> 要求重置密码之日期<br><code>{{token_lifetime}}</code> 令牌(token)过期时间(以分钟计)<br><code>{{hostname}}</code> mailcow 主机名",
+ "logo_normal_label": "正常",
+ "f2b_manage_external_info": "Fail2Ban 还会持续维护封禁列表,但不会主动设置规则阻挡流量。请使用以下生成的封禁列表在外部阻止流量。",
+ "password_reset_info": "若无提供复原电子邮箱,此功能将无法使用。",
+ "f2b_ban_time_increment": "禁止时间会随着禁止次数增加",
+ "logo_dark_label": "为深色模式反色",
+ "cors_settings": "CORS 设定",
+ "f2b_manage_external": "外部管理Fail2Ban",
+ "ip_check_opt_in": "使用第三方服务 <strong>ipv4.mailcow.email</strong> 及 <strong>ipv6.mailcow.email</strong> 以解析外部IP地址。",
+ "password_reset_settings": "密码复原设置",
+ "password_reset_tmpl_html": "HTML 模版",
+ "password_reset_tmpl_text": "文字模版",
+ "password_settings": "密码设定",
+ "restore_template": "留空以恢复预设模版。",
+ "ip_check": "IP 检查",
+ "ip_check_disabled": "IP 检查已禁用。你可透过以下路径启用<br> <strong>系统 > 配置 > 选项 > 页面自定义</strong>",
+ "queue_unban": "解除封禁",
+ "allowed_methods": "访问控制允许方式",
+ "allowed_origins": "访问控制允许原",
+ "iam": "身份识别提供者",
+ "iam_attribute_field": "Attribute 域",
+ "iam_authorize_url": "Authorization endpoint",
+ "iam_auth_flow": "认证流程",
+ "iam_basedn": "Base DN",
+ "iam_client_id": "客户端 ID",
+ "iam_client_secret": "客户端凭据",
+ "iam_client_scopes": "客户端 Scopes",
+ "iam_default_template": "默认模板",
+ "iam_default_template_description": "如果未为用户分配模板,则在创建邮箱时将使用默认模板,但在更新邮箱时不会使用默认模板。",
+ "iam_description": "配置外部认证提供者<br>如果已设置好属性映射,用户在首次登录时将会自动创建其 Mailbox。",
+ "iam_host": "Host",
+ "iam_host_info": "请输入一个或多个 LDAP 主机,使用英文逗号分隔。",
+ "iam_import_users": "导入用户",
+ "iam_mapping": "属性映射",
+ "iam_bindpass": "密码绑定(Bind Password)",
+ "iam_periodic_full_sync": "周期性全量同步",
+ "iam_port": "端口",
+ "iam_realm": "Realm",
+ "iam_redirect_url": "重定向 Url",
+ "iam_rest_flow": "Mailpassword 流程",
+ "iam_server_url": "服务器 Url",
+ "iam_sso": "单点登录(SSO)",
+ "iam_sync_interval": "同步/导入周期(min)",
+ "iam_test_connection": "测试连接",
+ "iam_token_url": "Token endpoint",
+ "iam_userinfo_url": "User info endpoint",
+ "iam_username_field": "Username 域",
+ "iam_binddn": "Bind DN",
+ "iam_use_ssl": "使用 SSL",
+ "iam_use_tls": "使用 StartTLS",
+ "iam_version": "版本",
+ "ignore_ssl_error": "忽略 SSL 错误",
+ "iam_auth_flow_info": "除了在单点登录(SSO)中使用的 Authorization Code 流程(在 Keycloak 中是标准流程)之外,mailcow 还支持使用 Credentials 的身份认证流程。Mailpassword 流程尝试通过 Keycloak 的 Admin REST API 验证用户凭据,mailcow 会从 Keycloak 中的 <code>mailcow_password</code> 属性中获取哈希后的密码。",
+ "filter": "过滤",
+ "iam_extra_permission": "要使以下设置生效,Keycloak 中的 mailcow 客户端需要一个 <code>服务账户(Service account)</code> 以及 <code>查看用户(view-users)</code> 的权限。",
+ "domainadmin_quicklink": "隐藏指向域管理员登陆页面的快捷链接",
+ "force_sso_text": "如果配置了外部的 OIDC 认证,这个选项隐藏默认的 mailcow 登陆界面,只显示单点登录(SSO)的按钮",
+ "iam_login_provisioning": "登录时自动创建用户",
+ "login_page": "登陆页面",
+ "iam_use_ssl_info": "如果使用了 SSL,且端口被设置为 389,该端口将自动被覆盖为 636。",
+ "quicklink_text": "显示或隐藏登陆表单下面指向其他登陆页面的快捷链接",
+ "user_quicklink": "隐藏指向用户登陆页面的快捷链接",
+ "admin_quicklink": "隐藏指向管理员登陆页面的快捷链接",
+ "force_sso": "强制要求单点登录(SSO)",
+ "user_link": "自定义链接",
+ "app_hide": "在登入界面隐藏",
+ "needs_restart": "需要重启",
+ "iam_use_tls_info": "如果使用了 TLS,必须使用 LDAP 服务器的默认端口(389)。SSL 的端口不能使用。"
},
"danger": {
"access_denied": "访问被拒绝或者表单数据无效",
@@ -356,7 +432,7 @@
"description_invalid": "%s 的资源描述无效",
"dkim_domain_or_sel_exists": "\"%s\"的 DKIM 密钥已存在,因此不会被覆盖",
"dkim_domain_or_sel_invalid": "DKIM 域名或选择器无效: %s",
- "domain_cannot_match_hostname": "域名与主机名称不匹配",
+ "domain_cannot_match_hostname": "域名不应与主机名相同",
"domain_exists": "域名 %s 已存在",
"domain_invalid": "域名地址为空或无效",
"domain_not_empty": "不能删除非空域名 %s",
@@ -456,7 +532,35 @@
"validity_missing": "请设置有效期",
"value_missing": "请填入所有值",
"yotp_verification_failed": "Yubico OTP 认证失败: %s",
- "template_exists": "模板 %s 已存在"
+ "template_exists": "模板 %s 已存在",
+ "template_name_invalid": "模板名称无效",
+ "cors_invalid_method": "制定的允许模式无效",
+ "cors_invalid_origin": "指定的允许原无效",
+ "reset_token_limit_exceeded": "Reset token 数量已达上限。请稍后再尝试。",
+ "extended_sender_acl_denied": "缺少设置外部发送者地址的 ACL",
+ "img_dimensions_exceeded": "图片超出最大图片大小",
+ "img_size_exceeded": "图片超过最大文件大小",
+ "invalid_reset_token": "不合法的 reset token",
+ "password_reset_invalid_user": "未找到此信箱或未设置恢复邮箱",
+ "password_reset_na": "密码恢复目前无法使用。请联系您的管理员。",
+ "recovery_email_failed": "无法发送恢复邮件。请联系您的管理员。",
+ "template_id_invalid": "Template ID %s 无效",
+ "to_invalid": "收件人不能为空",
+ "webauthn_authenticator_failed": "找不到所选的 authenticator",
+ "webauthn_publickey_failed": "没有为选定的身份验证器保存公钥",
+ "webauthn_username_failed": "所选的 authenticator 属于另一个账户",
+ "demo_mode_enabled": "演示模式已开启",
+ "generic_server_error": "服务器错误。请联系您的管理员。",
+ "authsource_in_use": "由于当前有一个或多个用户正在使用该身份提供者(IDP),因此无法更改或删除。",
+ "iam_test_connection": "连接失败",
+ "required_data_missing": "缺少需要的 %s 数据",
+ "max_age_invalid": "最大有效时间 %s 无效",
+ "mode_invalid": "模式 %s 无效",
+ "mx_invalid": "MX 记录 %s 无效",
+ "version_invalid": "版本 %s 无效",
+ "tfa_removal_blocked": "无法移除两步验证,你的账户必须使用两步验证。",
+ "external_goto_denied": "不允许使用外部目标地址 %s",
+ "quarantine_category_invalid": "隔离分类必须是 add_header, reject, all 的其中一个"
},
"debug": {
"chart_this_server": "图表 (此服务器)",
@@ -466,7 +570,6 @@
"external_logs": "外部日志",
"history_all_servers": "历史 (所有服务器)",
"in_memory_logs": "内存日志",
- "jvm_memory_solr": "JVM 内存使用",
"last_modified": "最后修改",
"log_info": "<p>Mailcow 的<b>内存日志</b>储存于 Redis 列表中,并且每分钟自动降低到 LOG_LINES (%d) 以减少错误。\r\n <br>内存日志不是为了持久化储存的,所有使用内存日志的应用同时也会写入日志到 Docker 的守护进程的默认日志驱动中。\r\n <br>内存日志应该用于分析 (Debug) 容器中不明显的问题。</p>\r\n <p><b>外部日志</b>通过相应应用提供的 API 收集。</p>\r\n <p><b>静态日志</b>大多数为不写入日志到 Docker ,但仍然需要被持久化的活动日志 (API 日志外的)。</p>",
"login_time": "时间",
@@ -475,8 +578,6 @@
"restart_container": "重启",
"service": "服务",
"size": "大小",
- "solr_dead": "Solr 在启动中、已关闭或已停止。",
- "solr_status": "Solr 状态",
"started_at": "开始于",
"started_on": "启动于",
"static_logs": "静态日志",
@@ -486,8 +587,18 @@
"username": "用户名",
"container_disabled": "容器已被停止或禁用",
"container_running": "运行中",
- "cores": "核心数",
- "memory": "内存"
+ "cores": "核",
+ "memory": "内存",
+ "error_show_ip": "无法解析公网IP地址",
+ "show_ip": "显示公网IP",
+ "update_available": "有可用更新",
+ "update_failed": "无法检查更新",
+ "architecture": "架构",
+ "container_stopped": "已停止",
+ "current_time": "系统时间",
+ "timezone": "时区",
+ "no_update_available": "系统已经是最新版本",
+ "wip": "正在施工中"
},
"diagnostics": {
"cname_from_a": "来自 A/AAAA 记录的值。但只要记录指向正确的资源即可。",
@@ -508,7 +619,7 @@
"alias": "编辑别名",
"allow_from_smtp": "只允许这些 IP 使用 <b>SMTP</b>",
"allow_from_smtp_info": "留空以允许所有发送者。<br>IPv4/IPv6 地址和网络。",
- "allowed_protocols": "允许的协议",
+ "allowed_protocols": "允许用户直接访问的协议 (不会影响应用的密码协议)",
"app_name": "应用名称",
"app_passwd": "应用密码",
"app_passwd_protocols": "应用密码允许的协议",
@@ -538,7 +649,7 @@
"force_pw_update_info": "此用户只能登录到 %s。",
"full_name": "全名",
"gal": "全球地址簿",
- "gal_info": "<b>全球地址簿</b>包含了域名下的所有对象,并且此行为不能被用户更改。如果关闭,用户的 \"空闲/繁忙\" 的信息将不能在 SOGo 中显示。 <b>重启 SOGo 服务以应用更改。</b>",
+ "gal_info": "全球地址簿(GAL)包含了域名下的所有对象,并且此行为不能被用户更改。如果关闭,用户的 \"空闲/繁忙\" 的信息将不能在 SOGo 中显示。 <b>重启 SOGo 服务以应用更改。</b>",
"generate": "生成",
"grant_types": "授权类型",
"hostname": "主机名",
@@ -594,8 +705,8 @@
"sieve_desc": "简短描述",
"sieve_type": "过滤器类型",
"skipcrossduplicates": "跳过其他文件夹中已存在的邮件(保留已经存在的邮件)",
- "sogo_access": "允许直接登录 SOGo",
- "sogo_access_info": "在邮箱的用户界面内的单点登录仍然有效。这一设置既不影响对所有其他服务的访问,也不删除或改变用户现有的 SOGo 的配置文件。",
+ "sogo_access": "直接转到 SOGo",
+ "sogo_access_info": "登录后,用户会自动跳转到 SOGo。",
"sogo_visible": "SOGo 显示的别名",
"sogo_visible_info": "此设置只影响 SOGo 上可显示的对象 (指向本地邮箱的共享或非共享别名地址)。如果设置为隐藏,则别名地址不会作为可选发件人的下拉项显示。",
"spam_alias": "添加或更改临时别名地址",
@@ -611,7 +722,47 @@
"title": "编辑对象",
"unchanged_if_empty": "如果不更改则留空",
"username": "用户名",
- "validate_save": "验证并保存"
+ "validate_save": "验证并保存",
+ "domain_footer_info_vars": {
+ "from_name": "{= from_name =} - 信件中的 From name 字段,例如对于 \"Mailcow <moo@mailcow.tld>\" 来说它是 \"Mailcow\"",
+ "auth_user": "{= auth_user =} - MTA 指定的经过认证的用户名",
+ "from_user": "{= from_user =} - 信件中的 From user 字段,例如对于 \"moo@mailcow.tld\" 来说它是 \"moo\"",
+ "from_addr": "{= from_addr =} - 信件中的 From address 字段",
+ "from_domain": "{= from_domain =} - 信件中的 From domain 字段",
+ "custom": "{= foo =} - 如果信箱有一个自定义属性 \"foo\" 的值为 \"bar\", 它将返回 \"bar\""
+ },
+ "created_on": "创建于",
+ "custom_attributes": "自定义属性",
+ "mailbox_rename": "重命名信箱",
+ "mailbox_rename_agree": "我已经创建了一个备份。",
+ "mailbox_rename_warning": "重要! 重命名信箱之前请先创建备份。",
+ "mailbox_rename_alias": "自动创建别名",
+ "mailbox_rename_title": "新本地信箱的名字",
+ "password_recovery_email": "密码重置邮箱",
+ "domain_footer": "域页脚",
+ "domain_footer_html": "HTML footer",
+ "domain_footer_info": "Domain-wide footers 会被加入到该 domain 下的地址发出的所有邮件中。 <br> 下列变量可以在 footer 中使用:",
+ "domain_footer_plain": "纯文字 footer",
+ "domain_footer_skip_replies": "在回信中忽略 footer",
+ "footer_exclude": "从 footer 中排除",
+ "last_modified": "上次修改时间",
+ "pushover_sound": "声音",
+ "internal": "内部的",
+ "internal_info": "内部的别名只能在域内部或者别名域内部访问。",
+ "mta_sts": "邮件传输代理严格传输安全协议(MTA-STS)",
+ "mta_sts_version": "版本",
+ "mta_sts_info": "<a href='https://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_MTA_Strict_Transport_Security' target='_blank'>MTA-STS</a> 是一项 MTA 标准,它强制要求 MTA 间传输必须使用 TLS 和有效的证书。<br>当因没有 DNSSEC 而无法使用 <a target='_blank' href='https://en.wikipedia.org/wiki/DNS-based_Authentication_of_Named_Entities'>DANE</a> 时,该标准将被启用。<br><b>注意</b>:若收件域支持基于 DNSSEC 的 DANE 协议,则系统将<b>始终</b>优先采用 DANE —— MTA-STS 仅作为备用机制存在。",
+ "mta_sts_version_info": "定义 MTA-STS 标准的版本——当前仅 <code>STSv1</code> 为有效版本。",
+ "mta_sts_mode": "模式",
+ "mta_sts_mode_info": "提供三种可选模式:<ul><li><em>测试模式</em>——仅监控策略执行情况,违反策略不会产生实际影响。</li><li><em>强制模式</em>——严格执行策略,拒绝所有未使用有效 TLS 加密的连接。</li><li><em>禁用模式</em>——发布策略但不生效。</li></ul>",
+ "mta_sts_max_age": "最长有效期",
+ "mta_sts_max_age_info": "接收方邮件服务器可缓存该策略的时长(秒),超出后需重新获取策略。",
+ "mta_sts_mx": "MX 服务器",
+ "mta_sts_mx_info": "仅允许向明确列出的邮件服务器发送邮件;发送方 MTA 会验证 DNS MX 记录的主机名是否与策略列表匹配,并仅允许携带有效 TLS 证书的投递(可防范中间人攻击)。",
+ "mta_sts_mx_notice": "可配置多个 MX 服务器(以逗号分隔)。",
+ "sender_allowed": "允许以此别名发送",
+ "sender_allowed_info": "如果禁用了,此别名只能接收邮件。使用发件者 ACL 来覆盖此选项并赋予指定的邮箱发送权限。",
+ "mta_sts_active_info": "如果未选中,MTA-STS 策略不会被公布并且不会通过 ACME 为 MTA-STS 子域名请求证书。"
},
"fido2": {
"confirm": "确认",
@@ -646,13 +797,14 @@
"header": {
"administration": "配置和管理",
"apps": "应用",
- "debug": "系统信息",
+ "debug": "信息",
"email": "E-Mail",
"mailcow_config": "配置",
"quarantine": "隔离",
"restart_netfilter": "重启 netfilter",
"restart_sogo": "重启 SOGo",
- "user_settings": "用户设置"
+ "user_settings": "用户设置",
+ "mailcow_system": "系统"
},
"info": {
"awaiting_tfa_confirmation": "等待 TFA 确认",
@@ -664,9 +816,24 @@
"fido2_webauthn": "使用 FIDO2/WebAuthn Login 登录",
"login": "登录",
"mobileconfig_info": "请使用邮箱用户登录以下载 Apple 连接描述文件。",
- "other_logins": "Key 登录",
+ "other_logins": "或通过以下方式登录",
"password": "密码",
- "username": "用户名"
+ "username": "用户名",
+ "forgot_password": "> 忘记密码?",
+ "back_to_mailcow": "返回到 mailcow",
+ "new_password": "新密码",
+ "new_password_confirm": "确认新密码",
+ "reset_password": "重置密码",
+ "request_reset_password": "请求重置密码",
+ "invalid_pass_reset_token": "密码重置 token 无效或已过期。<br> 请重新获取新的密码重置链接。",
+ "login_user": "用户登录",
+ "login_dadmin": "域管理员登录",
+ "login_admin": "管理员登录",
+ "login_linkstext": "不是正确的登陆页面?",
+ "login_usertext": "以用户身份登陆",
+ "login_domainadmintext": "以域管理员身份登陆",
+ "login_admintext": "以管理员身份登陆",
+ "email": "邮箱地址"
},
"mailbox": {
"action": "操作",
@@ -692,7 +859,7 @@
"all_domains": "全部域名",
"allow_from_smtp": "只允许这些 IP 使用 <b>SMTP</b>",
"allow_from_smtp_info": "留空以允许所有发送者。<br>IPv4/IPv6 地址或网络。",
- "allowed_protocols": "允许用户直接访问的协议 (不会影响应用的密码协议)",
+ "allowed_protocols": "允许的协议",
"backup_mx": "中继域名",
"bcc": "BCC",
"bcc_destination": "BCC 目标地址",
@@ -770,9 +937,9 @@
"recipient_map": "收件人映射",
"recipient_map_info": "收件人映射用于在邮件被发送前替换收件人的地址。",
"recipient_map_new": "新收件人",
- "recipient_map_new_info": "新收件人必须为合法的邮箱地址",
+ "recipient_map_new_info": "收件人映射的目标必须为合法的邮件地址或域名。",
"recipient_map_old": "原收件人",
- "recipient_map_old_info": "原收件人必须为合法的邮箱地址",
+ "recipient_map_old_info": "原收件人必须为合法的邮箱地址或域名。",
"recipient_maps": "收件人映射",
"relay_all": "中继所有收件人",
"remove": "删除",
@@ -789,7 +956,7 @@
"sieve_preset_5": "自动回复 (休假)",
"sieve_preset_6": "拒绝接收邮件并通知",
"sieve_preset_7": "重定向邮件并保留或删除",
- "sieve_preset_8": "删除发件人发送给自己别名地址的邮件",
+ "sieve_preset_8": "重定向来自特定发件人的邮件,标记为已读并放入子文件夹中",
"sieve_preset_header": "请看下方的示例预设。 查看 <a href=\"https://en.wikipedia.org/wiki/Sieve_(mail_filtering_language)\" target=\"_blank\">Sieve Wikipedia 页面 (英文)</a>以了解更多细节。",
"sogo_visible": "SOGo 别名显示",
"sogo_visible_n": "在 SOGo 中隐藏别名",
@@ -831,10 +998,23 @@
"mailbox_templates": "邮箱模板",
"gal": "全局地址列表",
"max_aliases": "最大别名数",
- "max_mailboxes": "最大可能的邮箱数"
+ "max_mailboxes": "最大可能的邮箱数",
+ "created_on": "建立于",
+ "force_pw_update": "强制在下一次登陆时更新密码",
+ "add_template": "新增模板",
+ "goto_ham": "学习为 <b> 非垃圾邮件 </b>",
+ "goto_spam": "学习为 <b> 垃圾邮件 </b>",
+ "last_modified": "上次修改时间",
+ "max_quota": "每个信箱的最大容量配额",
+ "relay_unknown": "转发未知信箱",
+ "templates": "模板",
+ "template": "模板",
+ "iam": "身份提供者(IDP)",
+ "internal": "内部的",
+ "force_tfa": "两步验证"
},
"oauth2": {
- "access_denied": "请作为邮箱所有者登录以使用 OAuth2 授权",
+ "access_denied": "请作为邮箱所有者登录以使用 OAuth2 授权。",
"authorize_app": "授权应用",
"deny": "拒绝",
"permit": "授权应用",
@@ -862,8 +1042,8 @@
"neutral_danger": "无危险等级",
"notified": "已发送通知",
"qhandler_success": "已成功向系统发送请求,现在你可以关闭这个窗口了。",
- "qid": "Rspamd QID",
- "qinfo": "隔离系统会把已被拒绝接收的邮件以及作为拷贝发送到垃圾箱的邮件保存到数据库中 (发件人<em>不</em>会知道)。\r\n <br>\"学习为垃圾并删除\" 会根据贝叶斯定理将消息作为垃圾学习并计算其模糊特征以拒绝未来收到相似消息。\r\n <br>请注意,这取决于你的系统资源,学习多个消息可能会花费较长时间。<br>黑名单中项目会被隔离系统排除。",
+ "qid": "Rspamd 队列ID(QID)",
+ "qinfo": "隔离系统会把已被拒绝接收的邮件以及作为拷贝发送到垃圾箱的邮件保存到数据库中 (发件人<em>不</em>会知道)。\n <br>\"学习为垃圾并删除\" 会根据贝叶斯定理将消息作为垃圾学习并计算其模糊特征以拒绝未来收到相似消息。\n <br>请注意,这取决于你的系统资源,学习多个消息可能会花费较长时间。<br>阻止名单中项目会被隔离系统排除。",
"qitem": "隔离项目",
"quarantine": "隔离",
"quick_actions": "操作",
@@ -897,20 +1077,30 @@
},
"queue": {
"queue_manager": "队列管理器",
- "delete": "全部删除"
+ "delete": "全部删除",
+ "info": "邮件队列包含所有等待投递的邮件。如果邮件长时间停留在邮件队列中,系统会自动将其删除。<br>对应的邮件错误信息会提供有关邮件无法送达的原因。",
+ "flush": "刷新队列",
+ "legend": "邮件队列操作功能:",
+ "ays": "请确认您要删除当前队列中的所有项目。",
+ "deliver_mail": "投递",
+ "deliver_mail_legend": "尝试重新投递选中的邮件。",
+ "hold_mail": "保留",
+ "hold_mail_legend": "保持选中的邮件。(不继续投递)",
+ "show_message": "显示内容",
+ "unban": "队列解除限制",
+ "unhold_mail": "取消保持",
+ "unhold_mail_legend": "允许选中的邮件继续投递。(需要在保持状态)"
},
"ratelimit": {
"disabled": "禁用",
"second": "msgs / 秒",
"minute": "msgs / 分钟",
- "hour": "msgs / 小说",
+ "hour": "msgs / 小时",
"day": "msgs / 天"
},
"start": {
"help": "显示/隐藏 帮助面板",
- "imap_smtp_server_auth_info": "请使用你的完整邮箱地址并使用 PLAIN (明文) 认证方法。<br>\r\n你的登录数据会被服务端强制加密。",
- "mailcow_apps_detail": "使用 Mailcow 应用访问你的邮件、日历、联系人以及更多内容。",
- "mailcow_panel_detail": "<b>域名管理员</b>可以创建、修改或删除邮箱的别名,更改分配给用户的域名并读取更多域名相关信息。<br>\r\n<b>邮箱用户</b>可以创建临时别名 (垃圾邮件别名),更改密码以及设置垃圾邮件过滤器。"
+ "imap_smtp_server_auth_info": "请使用你的完整邮箱地址并使用 PLAIN (明文) 认证方法。<br>\r\n你的登录数据会被服务端强制加密。"
},
"success": {
"acl_saved": "已保存对象 %s 的 ACL 设置",
@@ -965,7 +1155,7 @@
"nginx_reloaded": "Nginx 已重新启动",
"object_modified": "已保存对象 %s 更改",
"password_policy_saved": "已成功保存密码规则",
- "pushover_settings_edited": "已成功设置 Pushover,请重新校验凭证",
+ "pushover_settings_edited": "Pushover 设置已保存,请重新校验凭证。",
"qlearn_spam": "消息 ID %s 已被学习为垃圾邮件并被删除",
"queue_command_success": "成功执行配额命令",
"recipient_map_entry_deleted": "已删除接收人映射 ID %s",
@@ -989,7 +1179,19 @@
"verified_fido2_login": "FIDO2 登录验证成功",
"verified_totp_login": "TOTP 登录验证成功",
"verified_webauthn_login": "WebAuthn 登录验证成功",
- "verified_yotp_login": "Yubico OTP 登录验证成功"
+ "verified_yotp_login": "Yubico OTP 登录验证成功",
+ "domain_footer_modified": "对域 footer %s 的修改已保存",
+ "cors_headers_edited": "CORS 设置已保存",
+ "ip_check_opt_in_modified": "IP 检查已保存",
+ "f2b_banlist_refreshed": "黑名单 ID 已成功刷新。",
+ "mailbox_renamed": "信箱 %s 已被重命名为 %s",
+ "password_changed_success": "密码重置成功",
+ "recovery_email_sent": "重置邮件已发送至 %s",
+ "template_added": "新增了模板 %s",
+ "template_modified": "模板 %s 的修改已保存",
+ "template_removed": "模板 ID %s 已删除",
+ "iam_test_connection": "连接成功",
+ "custom_login_modified": "登陆选项保存成功"
},
"tfa": {
"api_register": "%s 使用了 Yubico Cloud API,请<a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">在此</a>为你的密钥获取 API 密钥",
@@ -1016,7 +1218,13 @@
"webauthn": "WebAuthn 认证",
"waiting_usb_auth": "<i>等待 USB 设备中...</i><br><br>现在请触碰你的 WebAuthn USB 设备上的按钮。",
"waiting_usb_register": "<i>等待 USB 设备中...</i><br><br>请在上方输入你的密码并请触碰你的 WebAuthn USB 设备上的按钮以确认注册该 WebAuthn 设备。",
- "yubi_otp": "Yubico OTP 认证"
+ "yubi_otp": "Yubico OTP 认证",
+ "authenticators": "验证器(Authenticators)",
+ "force_tfa": "在登录时强制启用 2FA",
+ "force_tfa_info": "在访问面板前用户会被要求设置两步验证。",
+ "setup_title": "需要设置两步验证",
+ "setup_required": "你的账户需要设置两步验证。请添加一个两步验证方法以继续。",
+ "cancel_setup": "取消并注销"
},
"user": {
"action": "操作",
@@ -1033,7 +1241,7 @@
"alias_valid_until": "有效至",
"aliases_also_send_as": "同时允许发送为",
"aliases_send_as_all": "已关闭发件人可访性检查的域名和域名别名",
- "app_hint": "应用密码是你登录 <b>IMAP 和 SMTP</b> 时的可选替代密码,用户名仍然保持不变。<br>应用密码不适用于 SOGo (包括 ActiveSync) ",
+ "app_hint": "应用密码是你登录 <b>IMAP 和 SMTP</b> 时的可选替代密码,用户名仍然保持不变。<br>应用密码不适用于 SOGo (包括 ActiveSync)。",
"allowed_protocols": "允许使用的协议",
"app_name": "应用名称",
"app_passwds": "应用密码",
@@ -1050,10 +1258,11 @@
"created_on": "添加于",
"daily": "每日",
"day": "日",
+ "description": "描述",
"delete_ays": "请确认删除。",
"direct_aliases": "直接别名",
"direct_aliases_desc": "垃圾邮件过滤和 TLS 策略会作用于直接别名。",
- "direct_protocol_access": "该邮箱用户可以<b>直接</b>从<b>外部</b>访问以下的协议和应用程序。该选项由你的管理员进行设置。并可以创建应用密码,以授予对个别协议和应用的访问权限。<br>\"登录到 Webmail\" 按钮提供到 SOGo 的单点登录方式,并且始终可用。",
+ "direct_protocol_access": "该邮箱用户可以<b>直接</b>从<b>外部</b>访问以下的协议和应用程序。该选项由你的管理员进行设置。并可以创建应用密码,以授予对个别协议和应用的访问权限。<br>\"Webmail\" 按钮提供到 SOGo 的单点登录方式,并且始终可用。",
"eas_reset": "重置 ActiveSync 设备缓存",
"eas_reset_help": "在许多情况下,重置设备缓存可以帮助恢复错误的 ActiveSync 资料。<br><b>注意:</b> 所有元素将会被重新下载!",
"eas_reset_now": "立即重置",
@@ -1094,7 +1303,7 @@
"no_last_login": "没有最后一次 UI 登录信息",
"no_record": "没有记录",
"open_logs": "打开日志",
- "open_webmail_sso": "登录到 Webmail",
+ "open_webmail_sso": "Webmail",
"password": "密码",
"password_now": "当前密码 (确认更改)",
"password_repeat": "确认密码 (重复)",
@@ -1126,12 +1335,12 @@
"sogo_profile_reset": "重置 SOGo 个人资料",
"sogo_profile_reset_help": "此操作会不可恢复地删除用户的 SOGo 个人资料并<b>删除所有联系人和日历数据</b>。",
"sogo_profile_reset_now": "立即重置个人资料",
- "spam_aliases": "临时邮箱别名",
+ "spam_aliases": "垃圾邮件别名",
"spam_score_reset": "重置为服务器默认值",
"spamfilter": "垃圾邮件过滤器",
"spamfilter_behavior": "分数",
- "spamfilter_bl": "黑名单",
- "spamfilter_bl_desc": "黑名单中地址<b>总是会</b>被标记为垃圾邮件。被拒绝的邮件<b>不会</b>进入隔离区。此处可以使用通配符 \"*\"。此过滤器也会应用到直接别名 (只指向一个目标邮箱),但不会应用到\"接收所有\"别名和邮箱地址本身。",
+ "spamfilter_bl": "阻止名单",
+ "spamfilter_bl_desc": "阻止名单中地址<b>总是会</b>被标记为垃圾邮件。被拒绝的邮件<b>不会</b>进入隔离区。此处可以使用通配符 \"*\"。此过滤器也会应用到直接别名 (只指向一个目标邮箱),但不会应用到\"接收所有\"别名和邮箱地址本身。",
"spamfilter_default_score": "默认值",
"spamfilter_green": "绿色: 此消息不是垃圾邮件",
"spamfilter_hint": "第一个值表示\"低垃圾邮件分数\",第二个值表示\"高垃圾邮件分数\"。",
@@ -1142,8 +1351,8 @@
"spamfilter_table_empty": "数据为空",
"spamfilter_table_remove": "删除",
"spamfilter_table_rule": "规则",
- "spamfilter_wl": "白名单",
- "spamfilter_wl_desc": "白名单中地址<b>永远不会</b>被标记为垃圾邮件。此处可以使用通配符 \"*\"。此过滤器也会应用到直接别名 (只指向一个目标邮箱),但不会应用到\"接收所有\"别名和邮箱地址本身。",
+ "spamfilter_wl": "允许名单",
+ "spamfilter_wl_desc": "允许名单中地址<b>永远不会</b>被标记为垃圾邮件。此处可以使用通配符 \"*\"。此过滤器也会应用到直接别名 (只指向一个目标邮箱),但不会应用到\"接收所有\"别名和邮箱地址本身。",
"spamfilter_yellow": "黄色: 此为垃圾邮件,会被标记为垃圾邮件并且移入垃圾邮件文件夹",
"status": "状态",
"sync_jobs": "同步任务",
@@ -1177,7 +1386,20 @@
"weeks": "周",
"with_app_password": "包含应用密码",
"year": "年",
- "years": "年"
+ "years": "年",
+ "pw_recovery_email": "密码重置邮箱",
+ "password_reset_info": "如果不提供密码重置邮箱,此功能将无法使用。",
+ "pushover_sound": "声音",
+ "value": "值",
+ "attribute": "属性",
+ "protocols": "协议",
+ "authentication": "认证",
+ "tfa_info": "两步验证有助于保护您的账户安全。启用后,对于不支持两步验证的应用程序或服务(例如邮件客户端),需要使用应用专用密码进行登录。",
+ "overview": "概览",
+ "expire_never": "永不过期",
+ "forever": "永久",
+ "spam_aliases_info": "垃圾邮件别名是一种临时电子邮件地址,可用于保护真实电子邮件地址。<br>还可以选择设置过期时间,以便在设定的时间后自动停用别名,从而有效地销毁被滥用或泄露的地址。",
+ "pw_update_required": "你的账户需要修改一次密码。请设置一个新密码以继续。"
},
"warning": {
"cannot_delete_self": "不能删除已登录的用户",
@@ -1202,7 +1424,19 @@
"paginate": {
"first": "第一页",
"last": "最后一页",
- "previous": "上一页"
- }
+ "previous": "上一页",
+ "next": "下一页"
+ },
+ "aria": {
+ "sortDescending": ": 激活以降序对列进行排序",
+ "sortAscending": ": 激活以升序对列进行排序"
+ },
+ "decimal": ".",
+ "emptyTable": "表中没有可用的数据",
+ "infoFiltered": "(从 _MAX_ 个总条目中过滤)",
+ "thousands": ",",
+ "lengthMenu": "显示 _MENU_ 条目",
+ "loadingRecords": "加载中...",
+ "zeroRecords": "未找到符合条件的记录"
}
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-tw.json b/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-tw.json
index c3c2cf7..e7310be 100644
--- a/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-tw.json
+++ b/mailcow/src/mailcow-dockerized/data/web/lang/lang.zh-tw.json
@@ -24,11 +24,12 @@
"sogo_access": "管理 SOGo 存取權",
"sogo_profile_reset": "重設 SOGo 個人資料",
"spam_alias": "臨時別名",
- "spam_policy": "黑名單/白名單",
+ "spam_policy": "封鎖名單/允許名單",
"spam_score": "垃圾郵件分數",
"syncjobs": "同步任務",
"tls_policy": "TLS 規則",
- "unlimited_quota": "信箱容量配額無上限"
+ "unlimited_quota": "信箱容量配額無上限",
+ "pw_reset": "允許重置mailcow使用者密碼"
},
"add": {
"activate_filter_warn": "當\"啟用\"被勾選,所有其他過濾器都會被消除。",
@@ -351,7 +352,14 @@
"ip_check_opt_in": "選擇使用第三方服務 <strong>ipv4.mailcow.email</strong> 和 <strong>ipv6.mailcow.email</strong> 來解析外部 IP 位址。",
"ip_check_disabled": "IP 檢查已停用。 您可以在<br> <strong>系統 > 配置 > 選項 > 自訂</strong>下啟用它",
"options": "選項",
- "queue_unban": "解除禁令"
+ "queue_unban": "解除禁令",
+ "reset_password_vars": "<code>{{link}}</code> 生成密碼重置連結<br><code>{{username}}</code> 請求密碼重置的使用者信箱<br><code>{{username2}}</code> 備援電子信箱名稱<br><code>{{date}}</code> 密碼重置要求之日期<br><code>{{token_lifetime}}</code> 權杖(token)壽命(以分鐘計)<br><code>{{hostname}}</code> mailcow 主機名稱(hostname)",
+ "password_reset_info": "若無提供備援電子郵件,此功能將無法使用。",
+ "password_reset_settings": "密碼復原設定",
+ "password_reset_tmpl_html": "HTML 範本",
+ "password_reset_tmpl_text": "文字範本",
+ "password_settings": "密碼設定",
+ "restore_template": "留白以還原預設範本"
},
"danger": {
"access_denied": "存取拒絕或表單資料有誤",
@@ -480,7 +488,14 @@
"extended_sender_acl_denied": "缺少設定外部寄件者地址的 ACL",
"template_exists": "模板 %s 已存在",
"template_id_invalid": "範本 ID %s 無效",
- "template_name_invalid": "模板名稱無效"
+ "template_name_invalid": "模板名稱無效",
+ "password_reset_invalid_user": "查無此信箱或無設定備援郵件",
+ "password_reset_na": "密碼恢復目前無法使用。請聯繫您的管理員。",
+ "to_invalid": "收件者不能為空",
+ "img_size_exceeded": "圖片超出最大檔案大小",
+ "recovery_email_failed": "無法寄送還原電子郵件。請聯絡您的管理員。",
+ "reset_token_limit_exceeded": "重置權杖(token)已達上限。請稍後再試。",
+ "img_dimensions_exceeded": "圖片超出最大圖片大小"
},
"debug": {
"chart_this_server": "圖表 (此伺服器)",
@@ -490,7 +505,6 @@
"external_logs": "外部紀錄",
"history_all_servers": "歷史 (所有伺服器)",
"in_memory_logs": "記憶體紀錄",
- "jvm_memory_solr": "JVM 記憶體使用量",
"last_modified": "上次修改時間",
"log_info": "<p>mailcow 的<b>記憶體紀錄</b>會被收集到 Redis 清單中並且每分鐘自動縮減到 LOG_LINES (%d) 以避免重複撞擊 (hammering) 造成的大量記錄。\r\n<br>記憶體紀錄並不會永久保存。所有記錄到記憶體的應用程式也會同時透過預設紀錄的驅動程式寫入紀錄到 Docker 常駐程式中。\r\n<br>記憶體紀錄是設計用來為容器中的小問題除錯的。</p>\r\n<p><b>外部紀錄</b>透過應用程式提供的 API 收集。</p>\r\n<p><b>靜態紀錄</b>大多為不寫入到 Dockerd,但仍然需要被保存的活動紀錄 (API 紀錄除外)。</p>",
"login_time": "時間",
@@ -499,8 +513,6 @@
"restart_container": "重新啟動",
"service": "服務",
"size": "大小",
- "solr_dead": "Solr 正在啟動,停用或已停止運行.",
- "solr_status": "Solr 狀態",
"started_at": "啟動於",
"started_on": "啟動於",
"static_logs": "靜態紀錄",
@@ -511,7 +523,7 @@
"architecture": "結構",
"current_time": "系統時間",
"container_running": "正在執行",
- "memory": "記憶",
+ "memory": "記憶體",
"container_disabled": "容器停止或停用",
"container_stopped": "已停止",
"cores": "核心",
@@ -541,7 +553,7 @@
"alias": "編輯別名",
"allow_from_smtp": "只允許這些 IP 使用 <b>SMTP</b>",
"allow_from_smtp_info": "留空將允許所有寄件人<br>IPv4/IPv6 地址或網路",
- "allowed_protocols": "允許的協定",
+ "allowed_protocols": "使用者直接存取時允許的協定 (不影響應用程式密碼所能使用的協定)",
"app_name": "應用程式名稱",
"app_passwd": "應用程式密碼",
"app_passwd_protocols": "應用程式密碼允許的協定",
@@ -630,8 +642,8 @@
"sieve_desc": "簡短描述",
"sieve_type": "過濾器類型",
"skipcrossduplicates": "跳過在其他資料夾中重複的郵件 (優先使用先找到的郵件)",
- "sogo_access": "授權 SOGo 的直接存取權",
- "sogo_access_info": "mail UI 內的 SSO 仍可以運作。此設定既不會影響到存取其他服務的權限,也不會刪除或更改使用者既有的個人檔案。",
+ "sogo_access": "直接轉寄至SOGo",
+ "sogo_access_info": "登入後,使用者會自動重新導向至SOGo。",
"sogo_visible": "別名會在 SOGo 中顯示",
"sogo_visible_info": "此選項只會影響可以顯示於 SOGo 上物件 (指向至少一個本地信箱的共享或非共享別名地址)。如果設為隱藏,別名地址將不會顯示於寄件人下拉選項中。",
"spam_alias": "新增或更改臨時別名地址",
@@ -650,7 +662,19 @@
"validate_save": "驗證並儲存",
"domain_footer_info": "網域範圍的頁尾將會新增至與該網域內的位址關聯的所有外發電子郵件。 <br> 以下變數可用於頁尾:",
"custom_attributes": "自訂屬性",
- "pushover_sound": "聲音"
+ "pushover_sound": "聲音",
+ "domain_footer": "全域頁腳",
+ "domain_footer_info_vars": {
+ "from_name": "{= from_name =} - 從信封中的名稱部分,例如:\"Mailcow <moo@mailcow.tld>\" 則回傳 \"Mailcow\"",
+ "auth_user": "{= auth_user =} - MTA所認證之指定使用者名稱",
+ "from_user": "{= from_user =} - 從信封中的使用者部分。例如:\"moo@mailcow.tld\" 則回傳\"moo\"",
+ "from_addr": "{= from_addr =} - 從信封中的地址部分",
+ "from_domain": "{= from_domain =} - 從信封中的域名(domain)部分"
+ },
+ "domain_footer_skip_replies": "於回信中忽落頁腳",
+ "domain_footer_html": "HTML 頁腳",
+ "password_recovery_email": "密碼重置備援信箱",
+ "domain_footer_plain": "純文字頁腳"
},
"fido2": {
"confirm": "確認",
@@ -704,9 +728,16 @@
"fido2_webauthn": "FIDO2/WebAuthn Login",
"login": "登入",
"mobileconfig_info": "請使用信箱使用者登入以下載 Apple 連接描述檔案。",
- "other_logins": "金鑰登入",
+ "other_logins": "或透過以下方式登入",
"password": "密碼",
- "username": "使用者名稱"
+ "username": "使用者名稱",
+ "back_to_mailcow": "返回至mailcow",
+ "invalid_pass_reset_token": "密碼重置權杖(token)無效或已過期<br>請重新請求新的重置連結。",
+ "forgot_password": "> 忘記密碼?",
+ "new_password": "新密碼",
+ "new_password_confirm": "確認新密碼",
+ "reset_password": "重置密碼",
+ "request_reset_password": "要求重置密碼"
},
"mailbox": {
"action": "操作",
@@ -732,7 +763,7 @@
"all_domains": "所有域名",
"allow_from_smtp": "只允許這些 IP 使用<b>SMTP</b>",
"allow_from_smtp_info": "留空以允許所有發送者<br>IPv4/IPv6 地址或網路",
- "allowed_protocols": "使用者直接存取時允許的協定 (不影響應用程式密碼所能使用的協定)",
+ "allowed_protocols": "允許的協定",
"backup_mx": "中繼域名",
"bcc": "密件副本",
"bcc_destination": "密件副本目標地址",
@@ -954,9 +985,7 @@
},
"start": {
"help": "顯示/隱藏 幫助面板",
- "imap_smtp_server_auth_info": "請使用完整的信箱地址及明文認證 (PLAIN) 來登入。<br>\r\n你的登入資訊會在伺服器端被加密。",
- "mailcow_apps_detail": "使用 mailcow 應用程式來存取你的郵件、行事曆、聯絡資訊及其他更多功能。",
- "mailcow_panel_detail": "<b>域名管理員</b> 可以創建、修改、刪除信箱別名,以及讀取並修改被指定他們名下的域名。<br>\r\n<b>信箱使用者</b> 可以創建臨時別名 (垃圾郵件別名),更改密碼和垃圾郵件過濾器設定。"
+ "imap_smtp_server_auth_info": "請使用完整的信箱地址及明文認證 (PLAIN) 來登入。<br>\r\n你的登入資訊會在伺服器端被加密。"
},
"success": {
"acl_saved": "%s 的存取權限表已儲存",
@@ -1042,7 +1071,9 @@
"cors_headers_edited": "CORS 設定已儲存",
"domain_footer_modified": "網域頁尾 %s 的變更已儲存",
"f2b_banlist_refreshed": "禁止清單 ID 已成功刷新。",
- "ip_check_opt_in_modified": "IP檢查已成功儲存"
+ "ip_check_opt_in_modified": "IP檢查已成功儲存",
+ "password_changed_success": "密碼重置成功",
+ "recovery_email_sent": "已寄送復原郵件至 %s"
},
"tfa": {
"api_register": "%s 使用 Yubico Cloud API,請在<a href=\"https://upgrade.yubico.com/getapikey/\" target=\"_blank\">這裡</a>為這把金鑰獲取 API 金鑰",
@@ -1069,7 +1100,8 @@
"webauthn": "WebAuthn 認證",
"waiting_usb_auth": "<i>等待 USB 裝置...</i><br><br>請觸碰 USB 裝置上的按鈕。",
"waiting_usb_register": "<i>等待 USB 裝置...</i><br><br>請輸入密碼並觸碰 USB 裝置上的按鈕來確認註冊。",
- "yubi_otp": "Yubico OTP 認證"
+ "yubi_otp": "Yubico OTP 認證",
+ "authenticators": "驗證器(Authenticators)"
},
"user": {
"action": "操作",
@@ -1103,10 +1135,11 @@
"created_on": "建立於",
"daily": "每日",
"day": "日",
+ "description": "描述",
"delete_ays": "請確認刪除。",
"direct_aliases": "直接別名",
"direct_aliases_desc": "直接別名會受到垃圾郵件過濾器和 TLS 規則限制。",
- "direct_protocol_access": "此信箱使用者有 <b>直接、外部存取</b> 至下列協定及應用程式。此設定是由管理者設定。應用程式密碼則可以用於授權單獨的協定及應用程式存取權限。<br>\"登入至網頁信箱\" 使用 SSO (single-sign-on) 來登入至 SOGO 且不受前面的限制。",
+ "direct_protocol_access": "此信箱使用者有 <b>直接、外部存取</b> 至下列協定及應用程式。此設定是由管理者設定。應用程式密碼則可以用於授權單獨的協定及應用程式存取權限。<br>\"网络邮件\" 使用 SSO (single-sign-on) 來登入至 SOGO 且不受前面的限制。",
"eas_reset": "重設 ActiveSync 裝置快取",
"eas_reset_help": "在許多情況下,重設裝置快取可以幫助恢復錯誤的 ActiveSync 資料。<br><b>注意:</b> 所有元素都會被重新下載!",
"eas_reset_now": "立即重設",
@@ -1147,7 +1180,7 @@
"no_last_login": "沒有最後 UI 登入訊息",
"no_record": "沒有紀錄",
"open_logs": "開啟日誌",
- "open_webmail_sso": "登入至網頁信箱",
+ "open_webmail_sso": "網頁信箱",
"password": "密碼",
"password_now": "目前密碼 (確認更改)",
"password_repeat": "密碼 (再次輸入)",
@@ -1233,7 +1266,9 @@
"years": "年",
"attribute": "屬性",
"pushover_sound": "聲音",
- "value": "數值"
+ "value": "數值",
+ "password_reset_info": "若無提供密碼備援電子信箱,此功能將無法使用。",
+ "pw_recovery_email": "密碼備援電子信箱"
},
"warning": {
"cannot_delete_self": "不能刪除已登入的使用者",
diff --git a/mailcow/src/mailcow-dockerized/data/web/mailbox.php b/mailcow/src/mailcow-dockerized/data/web/mailbox.php
deleted file mode 100644
index 65c76f5..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/mailbox.php
+++ /dev/null
@@ -1,47 +0,0 @@
-<?php
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
-
-if (!isset($_SESSION['mailcow_cc_role']) || $_SESSION['mailcow_cc_role'] != "admin" && $_SESSION['mailcow_cc_role'] != "domainadmin") {
- header('Location: /');
- exit();
-}
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
-$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
-
-
-
-$js_minifier->add('/web/js/site/mailbox.js');
-$js_minifier->add('/web/js/presets/sieveMailbox.js');
-$js_minifier->add('/web/js/site/pwgen.js');
-
-$role = ($_SESSION['mailcow_cc_role'] == "admin") ? 'admin' : 'domainadmin';
-$is_dual = (!empty($_SESSION["dual-login"]["username"])) ? 'true' : 'false';
-$allow_admin_email_login = (preg_match("/^([yY][eE][sS]|[yY])+$/", $_ENV["ALLOW_ADMIN_EMAIL_LOGIN"])) ? 'true' : 'false';
-
-// domains
-$domains = mailbox('get', 'domains');
-
-// mailboxes
-$mailboxes = [];
-foreach ($domains as $domain) {
- foreach (mailbox('get', 'mailboxes', $domain) as $mailbox) {
- $mailboxes[] = $mailbox;
- }
-}
-
-$template = 'mailbox.twig';
-$template_data = [
- 'acl' => $_SESSION['acl'],
- 'acl_json' => json_encode($_SESSION['acl']),
- 'role' => $role,
- 'is_dual' => $is_dual,
- 'allow_admin_email_login' => $allow_admin_email_login,
- 'global_filters' => mailbox('get', 'global_filter_details'),
- 'domains' => $domains,
- 'mailboxes' => $mailboxes,
- 'lang_mailbox' => json_encode($lang['mailbox']),
- 'lang_rl' => json_encode($lang['ratelimit']),
- 'lang_datatables' => json_encode($lang['datatables']),
-];
-
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/mobileconfig.php b/mailcow/src/mailcow-dockerized/data/web/mobileconfig.php
index 44aaa30..c57c488 100644
--- a/mailcow/src/mailcow-dockerized/data/web/mobileconfig.php
+++ b/mailcow/src/mailcow-dockerized/data/web/mobileconfig.php
@@ -34,15 +34,15 @@
if (isset($_GET['only_email'])) {
$onlyEmailAccount = true;
- $description = 'IMAP';
+ $description = 'IMAP';
} else {
$onlyEmailAccount = false;
- $description = 'IMAP, CalDAV, CardDAV';
+ $description = 'IMAP, CalDAV, CardDAV';
}
if (isset($_GET['app_password'])) {
$app_password = true;
$description .= ' with application password';
-
+
if (strpos($_SERVER['HTTP_USER_AGENT'], 'iPad') !== FALSE)
$platform = 'iPad';
elseif (strpos($_SERVER['HTTP_USER_AGENT'], 'iPhone') !== FALSE)
@@ -51,8 +51,9 @@
$platform = 'Mac';
else
$platform = $_SERVER['HTTP_USER_AGENT'];
-
- $password = bin2hex(openssl_random_pseudo_bytes(16));
+
+ $password = password_generate();
+
$attr = array(
'app_name' => $platform,
'app_passwd' => $password,
@@ -64,6 +65,7 @@
$attr['protocols'][] = 'dav_access';
}
app_passwd("add", $attr);
+ $password = htmlspecialchars($password, ENT_NOQUOTES);
} else {
$app_password = false;
}
diff --git a/mailcow/src/mailcow-dockerized/data/web/mta-sts.php b/mailcow/src/mailcow-dockerized/data/web/mta-sts.php
new file mode 100644
index 0000000..0c6f1a2
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/mta-sts.php
@@ -0,0 +1,54 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+
+if (!isset($_SERVER['HTTP_HOST']) || strpos($_SERVER['HTTP_HOST'], 'mta-sts.') !== 0) {
+ http_response_code(404);
+ exit;
+}
+
+$host = preg_replace('/:[0-9]+$/', '', $_SERVER['HTTP_HOST']);
+$domain = idn_to_ascii(strtolower(str_replace('mta-sts.', '', $host)), 0, INTL_IDNA_VARIANT_UTS46);
+
+// Validate domain or return 404 on error
+if ($domain === false || empty($domain)) {
+ http_response_code(404);
+ exit;
+}
+
+// Check if domain is an alias domain and resolve to target domain
+try {
+ $stmt = $pdo->prepare("SELECT `target_domain` FROM `alias_domain` WHERE `alias_domain` = :domain");
+ $stmt->execute(array(':domain' => $domain));
+ $alias_row = $stmt->fetch(PDO::FETCH_ASSOC);
+
+ if ($alias_row !== false && !empty($alias_row['target_domain'])) {
+ // This is an alias domain, use the target domain for MTA-STS lookup
+ $domain = $alias_row['target_domain'];
+ }
+} catch (PDOException $e) {
+ // On database error, return 404
+ http_response_code(404);
+ exit;
+}
+
+$mta_sts = mailbox('get', 'mta_sts', $domain);
+
+if (count($mta_sts) == 0 ||
+ !isset($mta_sts['version']) ||
+ !isset($mta_sts['mode']) ||
+ !isset($mta_sts['max_age']) ||
+ !isset($mta_sts['mx']) ||
+ $mta_sts['active'] != 1) {
+ http_response_code(404);
+ exit;
+}
+
+header('Content-Type: text/plain; charset=utf-8');
+echo "version: {$mta_sts['version']}\n";
+echo "mode: {$mta_sts['mode']}\n";
+echo "max_age: {$mta_sts['max_age']}\n";
+foreach ($mta_sts['mx'] as $mx) {
+ echo "mx: {$mx}\n";
+}
+
+?>
diff --git a/mailcow/src/mailcow-dockerized/data/web/oauth/authorize.php b/mailcow/src/mailcow-dockerized/data/web/oauth/authorize.php
index 1fdcd03..2bde21d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/oauth/authorize.php
+++ b/mailcow/src/mailcow-dockerized/data/web/oauth/authorize.php
@@ -4,6 +4,7 @@
if (!isset($_SESSION['mailcow_cc_role'])) {
$_SESSION['oauth2_request'] = $_SERVER['REQUEST_URI'];
header('Location: /?oauth');
+ exit;
}
$request = OAuth2\Request::createFromGlobals();
@@ -24,6 +25,11 @@
exit;
}
+if (empty($_SESSION['mailcow_cc_username'])) {
+ header('Location: /?oauth');
+ exit;
+}
+
// print the authorization code if the user has authorized your client
$is_authorized = ($_POST['authorized'] == '1');
$oauth2_server->handleAuthorizeRequest($request, $response, $is_authorized, $_SESSION['mailcow_cc_username']);
diff --git a/mailcow/src/mailcow-dockerized/data/web/queue.php b/mailcow/src/mailcow-dockerized/data/web/queue.php
deleted file mode 100644
index ffce8d8..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/queue.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?php
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
-
-if (!isset($_SESSION['mailcow_cc_role']) || $_SESSION['mailcow_cc_role'] != "admin") {
- header('Location: /');
- exit();
-}
-
-
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
-$js_minifier->add('/web/js/site/queue.js');
-$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
-
-$role = ($_SESSION['mailcow_cc_role'] == "admin") ? 'admin' : 'domainadmin';
-
-$template = 'queue.twig';
-$template_data = [
- 'acl' => $_SESSION['acl'],
- 'acl_json' => json_encode($_SESSION['acl']),
- 'role' => $role,
- 'lang_admin' => json_encode($lang['admin']),
- 'lang_queue' => json_encode($lang['queue']),
- 'lang_datatables' => json_encode($lang['datatables'])
-];
-
-require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/reset-password.php b/mailcow/src/mailcow-dockerized/data/web/reset-password.php
new file mode 100644
index 0000000..d717d9d
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/reset-password.php
@@ -0,0 +1,32 @@
+<?php
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.user.inc.php';
+
+if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'admin') {
+ header('Location: /admin/dashboard');
+ exit();
+}
+elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'domainadmin') {
+ header('Location: /domainadmin/mailbox');
+ exit();
+}
+elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'user') {
+ header('Location: /user');
+ exit();
+}
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+$_SESSION['index_query_string'] = $_SERVER['QUERY_STRING'];
+
+if (isset($_GET['token'])) $is_reset_token_valid = reset_password("check", $_GET['token']);
+else $is_reset_token_valid = False;
+
+$template = 'reset-password.twig';
+$template_data = [
+ 'is_mobileconfig' => str_contains($_SESSION['index_query_string'], 'mobileconfig'),
+ 'is_reset_token_valid' => $is_reset_token_valid,
+ 'reset_token' => $_GET['token']
+];
+
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/footer.inc.php';
diff --git a/mailcow/src/mailcow-dockerized/data/web/sogo-auth.php b/mailcow/src/mailcow-dockerized/data/web/sogo-auth.php
index 40fff58..bc9694d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/sogo-auth.php
+++ b/mailcow/src/mailcow-dockerized/data/web/sogo-auth.php
@@ -8,22 +8,29 @@
$session_var_user_allowed = 'sogo-sso-user-allowed';
$session_var_pass = 'sogo-sso-pass';
+// only the internal nginx auth_request loopback (127.0.0.1:65510) sets this;
+// external clients can never supply it (bare fastcgi param, not an HTTP header)
+$is_internal_auth = (($_SERVER['SOGO_AUTH_INTERNAL'] ?? '') === '1');
+
// validate credentials for basic auth requests
-if (isset($_SERVER['PHP_AUTH_USER'])) {
+if ($is_internal_auth && isset($_SERVER['PHP_AUTH_USER'])) {
// load prerequisites only when required
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
+
$username = $_SERVER['PHP_AUTH_USER'];
$password = $_SERVER['PHP_AUTH_PW'];
- $is_eas = false;
- $is_dav = false;
+
+ // Determine service type for protocol access check
+ $service = 'NONE';
$original_uri = isset($_SERVER['HTTP_X_ORIGINAL_URI']) ? $_SERVER['HTTP_X_ORIGINAL_URI'] : '';
if (preg_match('/^(\/SOGo|)\/dav.*/', $original_uri) === 1) {
- $is_dav = true;
+ $service = 'DAV';
}
elseif (preg_match('/^(\/SOGo|)\/Microsoft-Server-ActiveSync.*/', $original_uri) === 1) {
- $is_eas = true;
+ $service = 'EAS';
}
- $login_check = check_login($username, $password, array('dav' => $is_dav, 'eas' => $is_eas));
+
+ $login_check = check_login($username, $password, array('service' => $service));
if ($login_check === 'user') {
header("X-User: $username");
header("X-Auth: Basic ".base64_encode("$username:$password"));
@@ -47,36 +54,50 @@
(($_SESSION['acl']['login_as'] == "1" && $ALLOW_ADMIN_EMAIL_LOGIN !== 0) || ($is_dual === false && $login == $_SESSION['mailcow_cc_username']))) {
if (filter_var($login, FILTER_VALIDATE_EMAIL)) {
if (user_get_alias_details($login) !== false) {
- // load master password
- $sogo_sso_pass = file_get_contents("/etc/sogo-sso/sogo-sso.pass");
- // register username and password in session
+ // enforce tenant boundary
+ if (!hasMailboxObjectAccess($_SESSION['mailcow_cc_username'], $_SESSION['mailcow_cc_role'], $login)) {
+ header("Location: /");
+ exit;
+ }
+ // Block SOGo access if pending actions (2FA setup, password update)
+ if (!empty($_SESSION['pending_tfa_setup']) || !empty($_SESSION['pending_pw_update'])) {
+ header("Location: /");
+ exit;
+ }
+ // register username in session
$_SESSION[$session_var_user_allowed][] = $login;
- $_SESSION[$session_var_pass] = $sogo_sso_pass;
+ // set dual login
+ if ($_SESSION['acl']['login_as'] == "1" && $ALLOW_ADMIN_EMAIL_LOGIN !== 0 && $is_dual === false && $_SESSION['mailcow_cc_role'] != "user"){
+ $_SESSION["dual-login"]["username"] = $_SESSION['mailcow_cc_username'];
+ $_SESSION["dual-login"]["role"] = $_SESSION['mailcow_cc_role'];
+ $_SESSION['mailcow_cc_username'] = $login;
+ $_SESSION['mailcow_cc_role'] = "user";
+ }
// update sasl logs
- $service = ($app_passwd_data['eas'] === true) ? 'EAS' : 'DAV';
$stmt = $pdo->prepare("REPLACE INTO sasl_log (`service`, `app_password`, `username`, `real_rip`) VALUES ('SSO', 0, :username, :remote_addr)");
$stmt->execute(array(
':username' => $login,
':remote_addr' => ($_SERVER['HTTP_X_REAL_IP'] ?? $_SERVER['REMOTE_ADDR'])
));
// redirect to sogo (sogo will get the correct credentials via nginx auth_request
- header("Location: /SOGo/so/{$login}");
+ header("Location: /SOGo/so/");
exit;
}
}
}
- header('HTTP/1.0 403 Forbidden');
- echo "Forbidden";
+ header("Location: /");
exit;
}
// only check for admin-login on sogo GUI requests
-elseif (isset($_SERVER['HTTP_X_ORIGINAL_URI']) && strcasecmp(substr($_SERVER['HTTP_X_ORIGINAL_URI'], 0, 9), "/SOGo/so/") === 0) {
+elseif ($is_internal_auth && isset($_SERVER['HTTP_X_ORIGINAL_URI']) && strcasecmp(substr($_SERVER['HTTP_X_ORIGINAL_URI'], 0, 9), "/SOGo/so/") === 0) {
// this is an nginx auth_request call, we check for existing sogo-sso session variables
- session_start();
- // extract email address from "/SOGo/so/user@domain/xy"
- $url_parts = explode("/", $_SERVER['HTTP_X_ORIGINAL_URI']);
+ require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/vars.inc.php';
+ if (file_exists($_SERVER['DOCUMENT_ROOT'] . '/inc/vars.local.inc.php')) {
+ include_once $_SERVER['DOCUMENT_ROOT'] . '/inc/vars.local.inc.php';
+ }
+ require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/sessions.inc.php';
+
$email_list = array(
- $url_parts[3], // Requested mailbox
($_SESSION['mailcow_cc_username'] ?? ''), // Current user
($_SESSION["dual-login"]["username"] ?? ''), // Dual login user
);
@@ -86,10 +107,12 @@
!empty($email) &&
filter_var($email, FILTER_VALIDATE_EMAIL) &&
is_array($_SESSION[$session_var_user_allowed]) &&
- in_array($email, $_SESSION[$session_var_user_allowed])
+ in_array($email, $_SESSION[$session_var_user_allowed]) &&
+ !$_SESSION['pending_pw_update'] &&
+ !$_SESSION['pending_tfa_setup']
) {
$username = $email;
- $password = $_SESSION[$session_var_pass];
+ $password = file_get_contents("/etc/sogo-sso/sogo-sso.pass");
header("X-User: $username");
header("X-Auth: Basic ".base64_encode("$username:$password"));
header("X-Auth-Type: Basic");
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin.twig
index 33f2422..651107c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/admin.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/admin.twig
@@ -7,6 +7,7 @@
<a class="nav-link dropdown-toggle active" data-bs-toggle="dropdown" href="#" role="button" aria-expanded="false">{{ lang.admin.access }}</a>
<ul class="dropdown-menu">
<li><button class="dropdown-item active" data-bs-target="#tab-config-admins" aria-selected="false" aria-controls="tab-config-admins" role="tab" data-bs-toggle="tab">{{ lang.admin.admins }}</button></li>
+ <li><button class="dropdown-item" data-bs-target="#tab-config-identity-provider" aria-selected="false" aria-controls="tab-config-identity-provider" role="tab" data-bs-toggle="tab">Identity Provider</button></li>
<!-- <li><button class="dropdown-item" data-bs-target="#tab-config-ldap-admins" aria-controls="tab-config-ldap-admins" role="tab" data-bs-toggle="tab">{{ lang.admin.admins_ldap }}</button></li> -->
<li><button class="dropdown-item" data-bs-target="#tab-config-oauth2" aria-selected="false" aria-controls="tab-config-oauth2" role="tab" data-bs-toggle="tab">{{ lang.admin.oauth2_apps }}</button></li>
<li><button class="dropdown-item" data-bs-target="#tab-config-rspamd" aria-selected="false" aria-controls="tab-config-rspamd" role="tab" data-bs-toggle="tab">Rspamd UI</button></li>
@@ -22,7 +23,7 @@
<li><button class="dropdown-item" data-bs-target="#tab-config-quarantine" aria-selected="false" aria-controls="tab-config-quarantine" role="tab" data-bs-toggle="tab">{{ lang.admin.quarantine }}</button></li>
<li><button class="dropdown-item" data-bs-target="#tab-config-quota" aria-selected="false" aria-controls="tab-config-quota" role="tab" data-bs-toggle="tab">{{ lang.admin.quota_notifications }}</button></li>
<li><button class="dropdown-item" data-bs-target="#tab-config-rsettings" aria-selected="false" aria-controls="tab-config-rsettings" role="tab" data-bs-toggle="tab">{{ lang.admin.rspamd_settings_map }}</button></li>
- <li><button class="dropdown-item" data-bs-target="#tab-config-password-policy" aria-selected="false" aria-controls="tab-config-password-policy" role="tab" data-bs-toggle="tab">{{ lang.admin.password_policy }}</button></li>
+ <li><button class="dropdown-item" data-bs-target="#tab-config-password-settings" aria-selected="false" aria-controls="tab-config-password-settings" role="tab" data-bs-toggle="tab">{{ lang.admin.password_settings }}</button></li>
<li><button class="dropdown-item" data-bs-target="#tab-config-customize" aria-selected="false" aria-controls="tab-config-customize" role="tab" data-bs-toggle="tab">{{ lang.admin.customize }}</button></li>
</ul>
</li>
@@ -40,6 +41,7 @@
<div class="col-md-12">
<div class="tab-content" style="padding-top:20px">
{% include 'admin/tab-config-admins.twig' %}
+ {% include 'admin/tab-config-identity-provider.twig' %}
{# {% include 'admin/tab-ldap.twig' %} #}
{% include 'admin/tab-config-oauth2.twig' %}
{% include 'admin/tab-config-rspamd.twig' %}
@@ -51,7 +53,7 @@
{% include 'admin/tab-config-quota.twig' %}
{% include 'admin/tab-config-rsettings.twig' %}
{% include 'admin/tab-config-customize.twig' %}
- {% include 'admin/tab-config-password-policy.twig' %}
+ {% include 'admin/tab-config-password-settings.twig' %}
{% include 'admin/tab-sys-mails.twig' %}
{% include 'admin/tab-globalfilter-regex.twig' %}
</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-customize.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-customize.twig
index 7fc990a..f28e4c1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-customize.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-customize.twig
@@ -7,7 +7,33 @@
<span class="d-none d-md-block">{{ lang.admin.customize }}</span>
</div>
<div id="collapse-tab-config-customize" class="card-body collapse" data-bs-parent="#admin-content">
- <legend><i class="bi bi-file-image"></i> {{ lang.admin.change_logo }}</legend><hr />
+ <legend><i class="bi bi-palette"></i> {{ lang.admin.ui_theme }}</legend><hr />
+ <div class="text-muted mb-3">{{ lang.admin.ui_theme_info|raw }}</div>
+ <form class="form" data-id="ui_theme" role="form" method="post">
+ <div class="row">
+ <div class="col-12 col-md-6 col-lg-4">
+ <p><select data-width="100%" id="ui_theme" name="ui_theme" class="selectpicker show-tick">
+ <option value="" {% if not ui_theme %}selected{% endif %}>{{ lang.admin.ui_theme_default }}</option>
+ {% for key, theme in ui_themes %}
+ <option value="{{ key }}" {% if ui_theme == key %}selected{% endif %}>{{ theme.name }}</option>
+ {% endfor %}
+ </select></p>
+ </div>
+ </div>
+ {% if ui_themes %}
+ <ul class="list-unstyled text-muted small mb-4">
+ {% for key, theme in ui_themes %}
+ <li><b>{{ theme.name }}</b> <code>{{ key }}</code>{% if theme.dark %} <i class="bi bi-moon-fill" title="{{ lang.admin.ui_theme_dark }}"></i>{% endif %}{% if theme.description %} - {{ theme.description }}{% endif %}</li>
+ {% endfor %}
+ </ul>
+ {% else %}
+ <p class="text-muted small mb-4">{{ lang.admin.ui_theme_none }}</p>
+ {% endif %}
+ <p><div class="btn-group">
+ <button class="btn btn-sm btn-xs-half d-block d-sm-inline btn-success" data-action="edit_selected" data-item="admin" data-id="ui_theme" data-api-url='edit/ui_theme' data-api-attr='{}' href="#"><i class="bi bi-check-lg"></i> {{ lang.admin.save }}</button>
+ </div></p>
+ </form>
+ <legend style="padding-top:20px"><i class="bi bi-file-image"></i> {{ lang.admin.change_logo }}</legend><hr />
<p class="text-muted">{{ lang.admin.logo_info }}</p>
<form class="form-inline" role="form" method="post" enctype="multipart/form-data">
<div class="mb-4">
@@ -51,20 +77,63 @@
</div></p>
</form>
</div>
- <legend>{{ lang.admin.app_links }}</legend><hr />
+ <legend style="padding-top:20px" unselectable="on">{{ lang.admin.login_page }}</legend><hr />
+ <div>
+ <form class="form" data-id="custom_login" role="form" method="post">
+ <p class="text-muted">{{ lang.admin.quicklink_text }}</p>
+ <div class="ms-2 mb-1">
+ <input class="form-check-input" type="checkbox" value="1" name="hide_user_quicklink" id="hide_user_quicklink" {% if custom_login.hide_user_quicklink == 1 %}checked{% endif %}>
+ <label class="form-check-label" for="hide_user_quicklink">
+ {{ lang.admin.user_quicklink|raw }}
+ </label>
+ </div>
+ <div class="ms-2 mb-1">
+ <input class="form-check-input" type="checkbox" value="1" name="hide_domainadmin_quicklink" id="hide_domainadmin_quicklink" {% if custom_login.hide_domainadmin_quicklink == 1 %}checked{% endif %}>
+ <label class="form-check-label" for="hide_domainadmin_quicklink">
+ {{ lang.admin.domainadmin_quicklink|raw }}
+ </label>
+ </div>
+ <div class="ms-2 mb-4">
+ <input class="form-check-input" type="checkbox" value="1" name="hide_admin_quicklink" id="hide_admin_quicklink" {% if custom_login.hide_admin_quicklink == 1 %}checked{% endif %}>
+ <label class="form-check-label" for="hide_admin_quicklink">
+ {{ lang.admin.admin_quicklink|raw }}
+ </label>
+ </div>
+ <p class="text-muted">{{ lang.admin.force_sso_text|raw }}</p>
+ <div class="ms-2 mb-4">
+ <input class="form-check-input" type="checkbox" value="1" name="force_sso" id="force_sso" {% if custom_login.force_sso == 1 %}checked{% endif %}>
+ <label class="form-check-label" for="force_sso">
+ {{ lang.admin.force_sso|raw }}
+ </label>
+ </div>
+ <p><div class="btn-group">
+ <button class="btn btn-sm btn-xs-half d-block d-sm-inline btn-success" data-action="edit_selected" data-item="admin" data-id="custom_login" data-reload="no" data-api-url='edit/custom_login' data-api-attr='{}' href="#"><i class="bi bi-check-lg"></i> {{ lang.admin.save }}</button>
+ </div></p>
+ </form>
+ </div>
+ <legend style="padding-top:20px">{{ lang.admin.app_links }}</legend><hr />
<p class="text-muted">{{ lang.admin.merged_vars_hint|raw }}</p>
<form class="form-inline" data-id="app_links" role="form" method="post">
<table class="table table-condensed" style="white-space: nowrap;" id="app_link_table">
<tr>
<th>{{ lang.admin.app_name }}</th>
<th>{{ lang.admin.link }}</th>
+ <th>{{ lang.admin.user_link }}</th>
+ <th style="width:125px;">{{ lang.admin.app_hide }}</th>
<th style="width:100px;"> </th>
</tr>
{% for row in app_links %}
{% for key, val in row %}
<tr>
<td><input class="input-sm input-xs-lg form-control" data-id="app_links" type="text" name="app" required value="{{ key }}"></td>
- <td><input class="input-sm input-xs-lg form-control" data-id="app_links" type="text" name="href" required value="{{ val }}"></td>
+ <td><input class="input-sm input-xs-lg form-control" data-id="app_links" type="text" name="href" required value="{{ val.link }}"></td>
+ <td><input class="input-sm input-xs-lg form-control" data-id="app_links" type="text" name="user_href" required value="{{ val.user_link }}"></td>
+ <td>
+ <div class="d-flex align-items-center justify-content-center" style="height: 33.5px">
+ <input data-id="app_links" type="hidden" name="hide" {% if val.hide %}value="1"{% else %}value="0"{% endif %}>
+ <input class="form-check-input app_hide" type="checkbox" value="1" {% if val.hide %}checked{% endif %}>
+ </div>
+ </td>
<td><a href="#" role="button" class="btn btn-sm btn-xs-lg btn-secondary h-100 w-100" type="button">{{ lang.admin.remove_row }}</a></td>
</tr>
{% endfor %}
@@ -73,6 +142,12 @@
<tr>
<td><input class="input-sm input-xs-lg form-control" value="{{ app.name }}" disabled></td>
<td><input class="input-sm input-xs-lg form-control" value="{{ app.link }}" disabled></td>
+ <td><input class="input-sm input-xs-lg form-control" value="{{ app.user_link }}" disabled></td>
+ <td>
+ <div class="d-flex align-items-center justify-content-center" style="height: 33.5px">
+ <input class="form-check-input" data-id="app_links" type="checkbox" name="hide" value="1" disabled {% if app.hide %}checked{% endif %}>
+ </div>
+ </td>
<td><a href="#" role="button" class="btn btn-sm btn-xs-lg btn-secondary h-100 w-100 disabled" type="button">{{ lang.admin.remove_row }}</a></td>
</tr>
{% endfor %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-dkim.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-dkim.twig
index 85c6dc6..ec77139 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-dkim.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-dkim.twig
@@ -117,6 +117,8 @@
<select data-style="btn btn-light btn-sm" class="form-control" id="key_size" name="key_size" title="{{ lang.admin.dkim_key_length }}" required>
<option data-subtext="bits">1024</option>
<option data-subtext="bits">2048</option>
+ <option data-subtext="bits">3072</option>
+ <option data-subtext="bits">4096</option>
</select>
</div>
</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-f2b.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-f2b.twig
index bb4a2e8..29535b7 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-f2b.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-f2b.twig
@@ -99,7 +99,7 @@
{% endif %}
<form class="form-inline" data-id="f2b_banlist" role="form" method="post">
<div class="input-group mb-3">
- <input type="text" class="form-control" aria-label="Banlist url" value="{{ f2b_banlist_url}}" id="banlist_url">
+ <input type="text" class="form-control" aria-label="Banlist url" value="{{ f2b_banlist_url }}" id="banlist_url">
{% if is_https %}
<button class="btn btn-secondary" type="button" onclick="copyToClipboard('banlist_url')"><i class="bi bi-clipboard"></i></button>
{% endif %}
@@ -110,7 +110,7 @@
<p>
<span class="badge fs-7 bg-info d-block d-sm-inline-block">
<i class="bi bi-funnel-fill"></i>
- <a href="https://bgp.he.net/ip/{{ active_ban.ip }}" target="_blank">
+ <a href="https://bgp.tools/prefix/{{ active_ban.ip }}" target="_blank">
{{ active_ban.network }}
</a>
({{ active_ban.banned_until }})
@@ -118,8 +118,8 @@
<span class="d-none d-sm-inline"> - </span>
{% if active_ban.queued_for_unban == 0 %}
<a data-action="edit_selected" data-item="{{ active_ban.network }}" data-id="f2b-quick" data-api-url='edit/fail2ban' data-api-attr='{"action":"unban"}' href="#">[{{ lang.admin.queue_unban }}]</a>
- <a data-action="edit_selected" data-item="{{ active_ban.network }}" data-id="f2b-quick" data-api-url='edit/fail2ban' data-api-attr='{"action":"whitelist"}' href="#">[whitelist]</a>
- <a data-action="edit_selected" data-item="{{ active_ban.network }}" data-id="f2b-quick" data-api-url='edit/fail2ban' data-api-attr='{"action":"blacklist"}' href="#">[blacklist (<b>needs restart</b>)]</a>
+ <a data-action="edit_selected" data-item="{{ active_ban.network }}" data-id="f2b-quick" data-api-url='edit/fail2ban' data-api-attr='{"action":"whitelist"}' href="#">[allowlist]</a>
+ <a data-action="edit_selected" data-item="{{ active_ban.network }}" data-id="f2b-quick" data-api-url='edit/fail2ban' data-api-attr='{"action":"blacklist"}' href="#">[denylist (<b>{{ lang.admin.needs_restart }}</b>)]</a>
{% else %}
<i>{{ lang.admin.unban_pending }}</i>
{% endif %}
@@ -130,7 +130,7 @@
<p>
<span class="badge fs-7 bg-danger d-block d-sm-inline-block">
<i class="bi bi-funnel-fill"></i>
- <a href="https://bgp.he.net/ip/{{ perm_ban.ip }}" target="_blank">
+ <a href="https://bgp.tools/prefix/{{ perm_ban.ip }}" target="_blank">
{{ perm_ban.network }}
</a>
</span>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-identity-provider.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-identity-provider.twig
new file mode 100644
index 0000000..4572d7f
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-identity-provider.twig
@@ -0,0 +1,720 @@
+<div role="tabpanel" class="tab-pane fade" id="tab-config-identity-provider" role="tabpanel" aria-labelledby="tab-config-identity-provider">
+ <div class="card mb-4">
+ <div class="card-header d-flex fs-5">
+ <button class="btn d-md-none flex-grow-1 text-start" data-bs-target="#collapse-tab-config-identity-provider" data-bs-toggle="collapse" aria-controls="collapse-tab-config-identity-provider">
+ {{ lang.admin.iam }}
+ </button>
+ <span class="d-none d-md-block">{{ lang.admin.iam }}</span>
+ </div>
+ <div id="collapse-tab-config-identity-provider" class="card-body collapse" data-bs-parent="#admin-content">
+ <p class="offset-sm-3 mb-4">{{ lang.admin.iam_description|raw }}</p>
+ <div class="row mb-4">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_realm">{{ lang.admin.iam }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <select
+ data-style="btn btn-secondary"
+ data-id="iam_provider"
+ title="{{ lang.admin.iam_provider }}"
+ name="iam_provider" id="iam_provider" class="full-width-select form-control" required>
+ <option value="keycloak" {% if not iam_settings.authsource or iam_settings.authsource == 'keycloak' %}selected{% endif %}>Keycloak</option>
+ <option value="generic-oidc" {% if iam_settings.authsource == 'generic-oidc' %}selected{% endif %}>Generic-OIDC</option>
+ <option value="ldap" {% if iam_settings.authsource == 'ldap' %}selected{% endif %}>LDAP</option>
+ </select>
+ </div>
+ </div>
+ <div id="keycloak_settings" class="{% if iam_settings.authsource and iam_settings.authsource != 'keycloak' %}d-none{% endif %}">
+ <form class="form-horizontal" autocapitalize="none" data-id="iam_keycloak" autocorrect="off" role="form" method="post">
+ <input type="hidden" name="authsource" value="keycloak">
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_keycloak_url">{{ lang.admin.iam_server_url }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_keycloak_url" name="server_url" value="{{ iam_settings.server_url }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_keycloak_realm">{{ lang.admin.iam_realm }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_keycloak_realm" name="realm" value="{{ iam_settings.realm }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_keycloak_clientid">{{ lang.admin.iam_client_id }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_keycloak_clientid" name="client_id" value="{{ iam_settings.client_id }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_keycloak_clientsecret">{{ lang.admin.iam_client_secret }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="reveal-password-input input-group">
+ <input type="password" class="password-field form-control" id="iam_keycloak_clientsecret" name="client_secret" value="{{ iam_settings.client_secret }}" required>
+ <button class="toggle-password btn btn-secondary" type="button"><i class="bi bi-eye"></i></button>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_redirect_url }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="row px-2 align-items-center">
+ <span class="col-10 p-0 pe-2">
+ <input type="text" class="form-control" name="redirect_url" value="{{ iam_settings.redirect_url }}" required>
+ </span>
+ <div class="col-2 p-0 d-flex">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary ms-auto iam_redirect_add_keycloak"><i class="bi bi-plus-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2" id="iam_keycloak_redirect_list">
+ <input type="hidden" name="redirect_url_extra" value="">
+ {% for key, url in iam_settings.redirect_url_extra %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-10 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="redirect_url_extra" value="{{ iam_settings.redirect_url_extra[key] }}">
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_keycloak_redirect_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ {% endfor %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-10 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="redirect_url_extra" value="">
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_keycloak_redirect_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_keycloak_version">{{ lang.admin.iam_version }}:</label>
+ </div>
+ <div class="col-sm-4">
+ <input type="text" class="form-control" id="iam_keycloak_version" name="version" value="{{ iam_settings.version }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_mapping }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="row px-2 align-items-center">
+ <span class="col-5 p-0 pe-2">{{ lang.user.attribute }}</span>
+ <span class="col-5 p-0 pe-2">{{ lang.mailbox.template }}</span>
+ <div class="col-2 p-0 d-flex">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary ms-auto iam_rolemap_add_keycloak"><i class="bi bi-plus-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2" id="iam_keycloak_mapping_list">
+ <input type="hidden" name="mappers" value="">
+ <input type="hidden" name="templates" value="">
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.admin.iam_default_template_description }}"></i>
+ <span>{{ lang.admin.iam_default_template}}</span>
+ </div>
+ <div class="col-5 p-0 pe-2 align-content-end">
+ <select data-live-search="true" name="default_template" class="form-control" title="-- {{ lang.mailbox.template }} --">
+ <option value="" {% if not iam_settings.default_template %}selected{% endif %}>-- {{ lang.mailbox.template }} --</option>
+ {% for mbox_template in mbox_templates %}
+ <option {% if mbox_template.template == iam_settings.default_template %}selected{% endif %}>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex"></div>
+ </div>
+ </div>
+ {% for key, role in iam_settings.mappers %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="mappers" value="{{ iam_settings.mappers[key] }}" required>
+ </div>
+ <div class="col-5 p-0 pe-2">
+ <select data-live-search="true" name="templates" class="form-control" title="-- {{ lang.mailbox.template }} --" required>
+ {% for mbox_template in mbox_templates %}
+ <option{% if mbox_template.template == iam_settings.templates[key] %} selected{% endif %}>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_keycloak_rolemap_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ {% endfor %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="mappers" value="">
+ </div>
+ <div class="col-5 p-0 pe-2">
+ <select data-live-search="true" name="templates" class="form-control" title="-- {{ lang.mailbox.template }} --">
+ <option value="" selected>-- {{ lang.mailbox.template }} --</option>
+ {% for mbox_template in mbox_templates %}
+ <option>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_keycloak_rolemap_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2 mt-4">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end"></div>
+ <div class="col-12 col-md-9">
+ <span>{{ lang.admin.iam_extra_permission|raw }}</span>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-start justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_rest_flow }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="mailpassword_flow" value="1" {% if iam_settings.mailpassword_flow == 1 %}checked{% endif %}>
+ </div>
+ <p class="text-muted">
+ <small>
+ {{ lang.admin.iam_auth_flow_info|raw }}
+ </small>
+ </p>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.ignore_ssl_error }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="ignore_ssl_error" value="1" {% if iam_settings.ignore_ssl_error == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_login_provisioning }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="login_provisioning" value="1" {% if iam_settings.login_provisioning == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_periodic_full_sync }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="periodic_sync" value="1" {% if iam_settings.periodic_sync == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_import_users }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="import_users" value="1" {% if iam_settings.import_users == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_sync_interval }}</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input class="form-control" type="number" min="1" name="sync_interval" style="width: 80px;" {% if iam_settings.sync_interval %}value="{{ iam_settings.sync_interval }}"{% else %}value="15"{% endif %}>
+ </div>
+ </div>
+ <div class="row mt-4 mb-2">
+ <div class="offset-md-3 col-12 col-md-9 d-flex flex-wrap">
+ <div class="btn-group mb-2">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary iam_test_connection iam_test_connection" data-id="iam_keycloak"><i class="bi bi-play"></i> {{ lang.admin.iam_test_connection }}</button>
+ <button class="btn btn-sm d-block d-sm-inline btn-success" data-item="identity-provider" data-action="edit_selected" data-id="iam_keycloak" data-api-url='edit/identity-provider' data-api-attr='{}'><i class="bi bi-check-lg"></i> {{ lang.admin.save }}</button>
+ </div>
+ <button class="btn btn-sm d-block d-sm-inline btn-danger ms-auto mb-2" data-item="identity-provider" data-action="delete_selected" data-id="iam_keycloak" data-api-url='delete/identity-provider'><i class="bi bi-trash"></i> {{ lang.mailbox.remove }}</button>
+ </div>
+ </div>
+ </form>
+ </div>
+ <div id="generic_oidc_settings" class="{% if not iam_settings.authsource or iam_settings.authsource != 'generic-oidc' %}d-none{% endif %}">
+ <form class="form-horizontal" autocapitalize="none" data-id="iam_generic" autocorrect="off" role="form" method="post">
+ <input type="hidden" name="authsource" value="generic-oidc">
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_authorize_url">{{ lang.admin.iam_authorize_url }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_authorize_url" name="authorize_url" value="{{ iam_settings.authorize_url }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_token_url">{{ lang.admin.iam_token_url }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_token_url" name="token_url" value="{{ iam_settings.token_url }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_userinfo_url">{{ lang.admin.iam_userinfo_url }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_userinfo_url" name="userinfo_url" value="{{ iam_settings.userinfo_url }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_client_id">{{ lang.admin.iam_client_id }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_client_id" name="client_id" value="{{ iam_settings.client_id }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_client_secret">{{ lang.admin.iam_client_secret }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="reveal-password-input input-group">
+ <input type="password" class="password-field form-control" id="iam_client_secret" name="client_secret" value="{{ iam_settings.client_secret }}" required>
+ <button class="toggle-password btn btn-secondary" type="button"><i class="bi bi-eye"></i></button>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_redirect_url }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="row px-2 align-items-center">
+ <span class="col-10 p-0 pe-2">
+ <input type="text" class="form-control" name="redirect_url" value="{{ iam_settings.redirect_url }}" required>
+ </span>
+ <div class="col-2 p-0 d-flex">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary ms-auto iam_redirect_add_generic"><i class="bi bi-plus-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2" id="iam_generic_redirect_list">
+ <input type="hidden" name="redirect_url_extra" value="">
+ {% for key, url in iam_settings.redirect_url_extra %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-10 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="redirect_url_extra" value="{{ iam_settings.redirect_url_extra[key] }}">
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_generic_redirect_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ {% endfor %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-10 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="redirect_url_extra" value="">
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_generic_redirect_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_client_scopes">{{ lang.admin.iam_client_scopes }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" placeholder="openid profile email mailcow_template" class="form-control" id="iam_client_scopes" name="client_scopes" value="{{ iam_settings.client_scopes }}">
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_mapping }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="row px-2 align-items-center">
+ <span class="col-5 p-0 pe-2">{{ lang.user.attribute }}</span>
+ <span class="col-5 p-0 pe-2">{{ lang.mailbox.template }}</span>
+ <div class="col-2 p-0 d-flex">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary ms-auto iam_rolemap_add_generic"><i class="bi bi-plus-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2" id="iam_generic_mapping_list">
+ <input type="hidden" name="mappers" value="">
+ <input type="hidden" name="templates" value="">
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.admin.iam_default_template_description }}"></i>
+ <span>{{ lang.admin.iam_default_template}}</span>
+ </div>
+ <div class="col-5 p-0 pe-2 align-content-end">
+ <select data-live-search="true" name="default_template" class="form-control" title="-- {{ lang.mailbox.template }} --">
+ <option value="" {% if not iam_settings.default_template %}selected{% endif %}>-- {{ lang.mailbox.template }} --</option>
+ {% for mbox_template in mbox_templates %}
+ <option {% if mbox_template.template == iam_settings.default_template %}selected{% endif %}>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex"></div>
+ </div>
+ </div>
+ {% for key, role in iam_settings.mappers %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="mappers" value="{{ iam_settings.mappers[key] }}" required>
+ </div>
+ <div class="col-5 p-0 pe-2">
+ <select data-live-search="true" name="templates" class="form-control" title="-- {{ lang.mailbox.template }} --" required>
+ {% for mbox_template in mbox_templates %}
+ <option{% if mbox_template.template == iam_settings.templates[key] %} selected{% endif %}>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_generic_rolemap_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ {% endfor %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="mappers" value="">
+ </div>
+ <div class="col-5 p-0 pe-2">
+ <select data-live-search="true" name="templates" class="form-control" title="-- {{ lang.mailbox.template }} --">
+ <option value="" selected>-- {{ lang.mailbox.template }} --</option>
+ {% for mbox_template in mbox_templates %}
+ <option>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_generic_rolemap_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.ignore_ssl_error }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="ignore_ssl_error" value="1" {% if iam_settings.ignore_ssl_error == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_login_provisioning }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="login_provisioning" value="1" {% if iam_settings.login_provisioning == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mt-4 mb-2">
+ <div class="offset-md-3 col-12 col-md-9 d-flex flex-wrap">
+ <div class="btn-group mb-2">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary iam_test_connection" data-id="iam_generic"><i class="bi bi-play"></i> {{ lang.admin.iam_test_connection }}</button>
+ <button class="btn btn-sm d-block d-sm-inline btn-success" data-item="identity-provider" data-action="edit_selected" data-id="iam_generic" data-api-url='edit/identity-provider' data-api-attr='{}'><i class="bi bi-check-lg"></i> {{ lang.admin.save }}</button>
+ </div>
+ <button class="btn btn-sm d-block d-sm-inline btn-danger ms-auto mb-2" data-item="identity-provider" data-action="delete_selected" data-id="iam_generic" data-api-url='delete/identity-provider'><i class="bi bi-trash"></i> {{ lang.mailbox.remove }}</button>
+ </div>
+ </div>
+ </form>
+ </div>
+ <div id="ldap_settings" class="{% if not iam_settings.authsource or iam_settings.authsource != 'ldap' %}d-none{% endif %}">
+ <form class="form-horizontal" autocapitalize="none" data-id="iam_ldap" autocorrect="off" role="form" method="post">
+ <input type="hidden" name="authsource" value="ldap">
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill mx-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.admin.iam_host_info }}"></i>
+ <label class="control-label" for="iam_ldap_host">{{ lang.admin.iam_host }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4 d-flex">
+ <input type="text" class="form-control" id="iam_ldap_host" name="host" value="{{ iam_settings.host }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_ldap_port">{{ lang.admin.iam_port }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="number" class="form-control" id="iam_ldap_port" name="port" value="{{ iam_settings.port }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill mx-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.admin.iam_use_ssl_info }}"></i>
+ <label class="control-label">{{ lang.admin.iam_use_ssl }}</label>
+ </div>
+ <div class="col-12 col-md-9 d-flex align-items-center">
+ <div class="form-check form-switch">
+ <input class="form-check-input"
+ type="checkbox"
+ role="switch"
+ id="use_ssl"
+ name="use_ssl"
+ value="1"
+ onchange="if(this.checked) document.getElementById('use_tls').checked = false"
+ {% if iam_settings.use_ssl == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill mx-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.admin.iam_use_tls_info }}"></i>
+ <label class="control-label">{{ lang.admin.iam_use_tls }}</label>
+ </div>
+ <div class="col-12 col-md-9 d-flex align-items-center">
+ <div class="form-check form-switch">
+ <input class="form-check-input"
+ type="checkbox"
+ role="switch"
+ id="use_tls"
+ name="use_tls"
+ value="1"
+ onchange="if(this.checked) document.getElementById('use_ssl').checked = false"
+ {% if iam_settings.use_tls == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.ignore_ssl_error }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="ignore_ssl_error" value="1" {% if iam_settings.ignore_ssl_error == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_ldap_basedn">{{ lang.admin.iam_basedn }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_ldap_basedn" name="basedn" value="{{ iam_settings.basedn }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_ldap_username_field">{{ lang.admin.iam_username_field }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" placeholder="mail" id="iam_ldap_username_field" name="username_field" value="{{ iam_settings.username_field }}">
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_ldap_filter">{{ lang.admin.filter }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" placeholder="" id="iam_ldap_filter" name="filter" value="{{ iam_settings.filter }}">
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_ldap_attribute_field">{{ lang.admin.iam_attribute_field }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_ldap_attribute_field" name="attribute_field" value="{{ iam_settings.attribute_field }}" required>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_ldap_binddn">{{ lang.admin.iam_binddn }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input type="text" class="form-control" id="iam_ldap_binddn" name="binddn" value="{{ iam_settings.binddn }}" required>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label" for="iam_ldap_bindpass">{{ lang.admin.iam_bindpass }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="reveal-password-input input-group">
+ <input type="password" class="password-field form-control" id="iam_ldap_bindpass" name="bindpass" value="{{ iam_settings.bindpass }}" required>
+ <button class="toggle-password btn btn-secondary" type="button"><i class="bi bi-eye"></i></button>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_mapping }}:</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <div class="row px-2 align-items-center">
+ <span class="col-5 p-0 pe-2">{{ lang.user.attribute }}</span>
+ <span class="col-5 p-0 pe-2">{{ lang.mailbox.template }}</span>
+ <div class="col-2 p-0 d-flex">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary ms-auto iam_rolemap_add_ldap"><i class="bi bi-plus-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2" id="iam_ldap_mapping_list">
+ <input type="hidden" name="mappers" value="">
+ <input type="hidden" name="templates" value="">
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.admin.iam_default_template_description }}"></i>
+ <span>{{ lang.admin.iam_default_template }}</span>
+ </div>
+ <div class="col-5 p-0 pe-2 align-content-end">
+ <select data-live-search="true" name="default_template" class="form-control" title="-- {{ lang.mailbox.template }} --">
+ <option value="" {% if not iam_settings.default_template %}selected{% endif %}>-- {{ lang.mailbox.template }} --</option>
+ {% for mbox_template in mbox_templates %}
+ <option {% if mbox_template.template == iam_settings.default_template %}selected{% endif %}>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex"></div>
+ </div>
+ </div>
+ {% for key, role in iam_settings.mappers %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="mappers" value="{{ iam_settings.mappers[key] }}" required>
+ </div>
+ <div class="col-5 p-0 pe-2">
+ <select data-live-search="true" name="templates" class="form-control" title="-- {{ lang.mailbox.template }} --" required>
+ {% for mbox_template in mbox_templates %}
+ <option{% if mbox_template.template == iam_settings.templates[key] %} selected{% endif %}>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_ldap_rolemap_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ {% endfor %}
+ <div class="offset-md-3 col-12 col-md-9 col-lg-4 mb-2">
+ <div class="row px-2">
+ <div class="col-5 p-0 pe-2">
+ <input type="text" class="form-control me-2" name="mappers" value="">
+ </div>
+ <div class="col-5 p-0 pe-2">
+ <select data-live-search="true" name="templates" class="form-control" title="-- {{ lang.mailbox.template }} --">
+ <option value="" selected>-- {{ lang.mailbox.template }} --</option>
+ {% for mbox_template in mbox_templates %}
+ <option>
+ {{ mbox_template.template }}
+ </option>
+ {% endfor %}
+ </select>
+ </div>
+ <div class="col-2 p-0 d-flex">
+ <button class="iam_ldap_rolemap_del btn btn-sm d-block d-sm-inline btn-secondary ms-auto"><i class="bi bi-x-lg"></i></button>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_login_provisioning }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="login_provisioning" value="1" {% if iam_settings.login_provisioning == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_periodic_full_sync }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="periodic_sync" value="1" {% if iam_settings.periodic_sync == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_import_users }}</label>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="form-check form-switch">
+ <input class="form-check-input" type="checkbox" role="switch" name="import_users" value="1" {% if iam_settings.import_users == 1 %}checked{% endif %}>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-md-3 d-flex align-items-center justify-content-md-end">
+ <label class="control-label">{{ lang.admin.iam_sync_interval }}</label>
+ </div>
+ <div class="col-12 col-md-9 col-lg-4">
+ <input class="form-control" type="number" min="1" name="sync_interval" style="width: 80px;" {% if iam_settings.sync_interval %}value="{{ iam_settings.sync_interval }}"{% else %}value="15"{% endif %}>
+ </div>
+ </div>
+ <div class="row mt-4 mb-2">
+ <div class="offset-md-3 col-12 col-md-9 d-flex flex-wrap">
+ <div class="btn-group mb-2">
+ <button class="btn btn-sm d-block d-sm-inline btn-secondary iam_test_connection iam_test_connection" data-id="iam_ldap"><i class="bi bi-play"></i> {{ lang.admin.iam_test_connection }}</button>
+ <button class="btn btn-sm d-block d-sm-inline btn-success" data-item="identity-provider" data-action="edit_selected" data-id="iam_ldap" data-api-url='edit/identity-provider' data-api-attr='{}'><i class="bi bi-check-lg"></i> {{ lang.admin.save }}</button>
+ </div>
+ <button class="btn btn-sm d-block d-sm-inline btn-danger ms-auto mb-2" data-item="identity-provider" data-action="delete_selected" data-id="iam_ldap" data-api-url='delete/identity-provider'><i class="bi bi-trash"></i> {{ lang.mailbox.remove }}</button>
+ </div>
+ </div>
+ </form>
+ </div>
+ </div>
+ </div>
+</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-password-policy.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-password-policy.twig
deleted file mode 100644
index 8209ba5..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-password-policy.twig
+++ /dev/null
@@ -1,40 +0,0 @@
-<div class="tab-pane fade" id="tab-config-password-policy" role="tabpanel" aria-labelledby="tab-config-password-policy">
- <div class="card mb-4">
- <div class="card-header d-flex fs-5">
- <button class="btn d-md-none flex-grow-1 text-start" data-bs-target="#collapse-tab-config-password-policy" data-bs-toggle="collapse" aria-controls="collapse-tab-config-password-policy">
- {{ lang.admin.password_policy }}
- </button>
- <span class="d-none d-md-block">{{ lang.admin.password_policy }}</span>
- </div>
- <div id="collapse-tab-config-password-policy" class="card-body collapse" data-bs-parent="#admin-content">
- <form class="form-horizontal" data-id="passwordpolicy" role="form" method="post">
- {% for name, value in password_complexity %}
- {% if name == 'length' %}
- <div class="row mb-4">
- <label class="control-label col-sm-3 text-sm-end" for="length">{{ lang.admin.password_length }}:</label>
- <div class="col-sm-2">
- <input type="number" class="form-control" min="3" max="64" name="length" id="length" value="{{ value }}" required>
- </div>
- </div>
- {% else %}
- <input type="hidden" name="{{ name }}" value="0">
- <div class="row mb-2">
- <div class="offset-sm-3 col-sm-9">
- <label>
- <input type="checkbox" class="form-check-input" name="{{ name }}" id="{{ name }}" value="1" {% if value == 1 %}checked{% endif %}> {{ lang.admin['password_policy_'~name] }}
- </label>
- </div>
- </div>
- {% endif %}
- {% endfor %}
- <div class="row mt-4 mb-2">
- <div class="offset-sm-3 col-sm-9">
- <div class="btn-group">
- <button class="btn btn-sm d-block d-sm-inline btn-success" data-item="passwordpolicy" data-action="edit_selected" data-id="passwordpolicy" data-api-url='edit/passwordpolicy' data-api-attr='{}' href="#"><i class="bi bi-check-lg"></i> {{ lang.admin.save }}</button>
- </div>
- </div>
- </div>
- </form>
- </div>
- </div>
-</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-password-settings.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-password-settings.twig
new file mode 100644
index 0000000..5998c63
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/admin/tab-config-password-settings.twig
@@ -0,0 +1,102 @@
+<div class="tab-pane fade" id="tab-config-password-settings" role="tabpanel" aria-labelledby="tab-config-password-settings">
+ <div class="card mb-4">
+ <div class="card-header d-flex fs-5">
+ <button class="btn d-md-none flex-grow-1 text-start" data-bs-target="#collapse-tab-config-password-settings" data-bs-toggle="collapse" aria-controls="collapse-tab-config-password-settings">
+ {{ lang.admin.password_settings }}
+ </button>
+ <span class="d-none d-md-block">{{ lang.admin.password_settings }}</span>
+ </div>
+ <div id="collapse-tab-config-password-settings" class="card-body collapse" data-bs-parent="#admin-content">
+ <form class="form-horizontal" data-id="passwordpolicy" role="form" method="post">
+ <div class="row">
+ <div class="col-sm-12">
+ <legend>
+ {{ lang.admin.password_policy }}
+ </legend>
+ <hr />
+ </div>
+ </div>
+ {% for name, value in password_complexity %}
+ {% if name == 'length' %}
+ <div class="row mb-4">
+ <label class="control-label col-sm-3 text-sm-end" for="length">{{ lang.admin.password_length }}:</label>
+ <div class="col-sm-2">
+ <input type="number" class="form-control" min="3" max="64" name="length" id="length" value="{{ value }}" required>
+ </div>
+ </div>
+ {% else %}
+ <input type="hidden" name="{{ name }}" value="0">
+ <div class="row mb-2">
+ <div class="offset-sm-3 col-sm-9">
+ <label>
+ <input type="checkbox" class="form-check-input" name="{{ name }}" id="{{ name }}" value="1" {% if value == 1 %}checked{% endif %}> {{ lang.admin['password_policy_'~name] }}
+ </label>
+ </div>
+ </div>
+ {% endif %}
+ {% endfor %}
+ <div class="row mt-4 mb-2">
+ <div class="offset-sm-3 col-sm-9">
+ <div class="btn-group">
+ <button class="btn btn-sm d-block d-sm-inline btn-success" data-item="passwordpolicy" data-action="edit_selected" data-id="passwordpolicy" data-api-url='edit/passwordpolicy' data-api-attr='{}' href="#"><i class="bi bi-check-lg"></i> {{ lang.admin.save }}</button>
+ </div>
+ </div>
+ </div>
+ </form>
+
+ <form class="form" role="form" data-id="pw_reset_notification" method="post" style="margin-top: 50px;">
+ <div class="row">
+ <div class="col-sm-12">
+ <legend>
+ {{ lang.admin.password_reset_settings }}
+ </legend>
+ <hr />
+ <small>{{ lang.admin.reset_password_vars|raw }}</small><br><br>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="col-sm-6">
+ <div>
+ <label for="pw_reset_from">{{ lang.admin.quota_notification_sender }}:</label>
+ <input type="email" class="form-control" id="pw_reset_from" name="from" value="{{ pw_reset_data.from }}">
+ </div>
+ </div>
+ <div class="col-sm-6">
+ <div>
+ <label for="pw_reset_subject">{{ lang.admin.quota_notification_subject }}:</label>
+ <input type="text" class="form-control" id="pw_reset_subject" name="subject" value="{{ pw_reset_data.subject }}">
+ </div>
+ </div>
+ </div>
+ <div class="row">
+ <div class="col-12" data-bs-target="#text_template" style="cursor:pointer" unselectable="on" data-bs-toggle="collapse">
+ <span class="d-block"><i style="font-size:10pt;" class="bi bi-plus-square"></i> {{ lang.admin.password_reset_tmpl_text }}</span>
+ <small>{{ lang.admin.restore_template }}</small>
+ </div>
+ <div id="text_template" class="col-12 collapse">
+ <textarea autocorrect="off" spellcheck="false" autocapitalize="none" class="form-control textarea-code mb-2" rows="20" name="text_tmpl">{{ pw_reset_data.text_tmpl|raw }}</textarea>
+ </div>
+ <div class="col-12 mt-3" data-bs-target="#html_template" style="cursor:pointer" unselectable="on" data-bs-toggle="collapse">
+ <span class="d-block"><i style="font-size:10pt;" class="bi bi-plus-square"></i> {{ lang.admin.password_reset_tmpl_html }}</span>
+ <small>{{ lang.admin.restore_template }}</small>
+ </div>
+ <div id="html_template" class="col-12 collapse">
+ <textarea autocorrect="off" spellcheck="false" autocapitalize="none" class="form-control textarea-code" rows="20" name="html_tmpl">{{ pw_reset_data.html_tmpl|raw }}</textarea>
+ </div>
+ </div>
+ <div class="row">
+ <div class="col-sm-10">
+ <div>
+ <br>
+ <a type="button" class="btn btn-sm d-block d-sm-inline btn-success" data-action="edit_selected"
+ data-item="pw_reset_notification"
+ data-id="pw_reset_notification"
+ data-api-url='edit/reset-password-notification'
+ data-api-attr='{}'><i class="bi bi-check-lg"></i> {{ lang.user.save_changes }}</a>
+ </div>
+ </div>
+ </div>
+ </form>
+ </div>
+ </div>
+</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/admin_index.twig b/mailcow/src/mailcow-dockerized/data/web/templates/admin_index.twig
new file mode 100644
index 0000000..0507786
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/admin_index.twig
@@ -0,0 +1,103 @@
+{% extends 'base.twig' %}
+
+{% block navbar %}{% endblock %}
+
+{% block content %}
+<div class="row mb-4" style="margin-top: 60px">
+ <div class="col-12 col-md-7 col-lg-6 col-xl-5 ms-auto me-auto">
+
+ <div class="card login-card login-admin">
+ <div class="card-header d-flex align-items-center text-break">
+ <i class="bi bi-shield-lock-fill me-2"></i> {{ lang.login.login_admin }}
+ <div class="ms-auto form-check form-switch my-auto d-flex align-items-center">
+ <label class="form-check-label"><i class="bi bi-moon-fill"></i></label>
+ <input class="form-check-input ms-2" type="checkbox" id="dark-mode-toggle">
+ </div>
+ <div class="ms-4 d-grid d-sm-block">
+ <button type="button" {% if available_languages|length == 1 %}disabled="true"{% endif %} class="text-secondary btn p-0 border-0 bg-transparent ms-auto dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
+ <span class="flag-icon flag-icon-{{ mailcow_locale[-2:] }}"></span>
+ </button>
+ <ul class="dropdown-menu ms-auto login">
+ {% for key, val in available_languages %}
+ <li>
+ <a class="dropdown-item {% if mailcow_locale == key %}active{% endif %}" href="?{{ query_string({'lang': key}) }}">
+ <span class="flag-icon flag-icon-{{ key[-2:] }}"></span>{{ val }}
+ </a>
+ </li>
+ {% endfor %}
+ </ul>
+ </div>
+ </div>
+ <div class="card-body">
+ <div class="text-center mailcow-logo mb-4">
+ <img class="main-logo" src="{{ logo|default('/img/cow_mailcow.svg') }}" alt="mailcow">
+ <img class="main-logo-dark" src="{{ logo_dark|default('/img/cow_mailcow.svg') }}" alt="mailcow-logo-dark">
+ </div>
+ {% if ui_texts.ui_announcement_text and ui_texts.ui_announcement_active %}
+ <div class="my-4 alert alert-{{ ui_texts.ui_announcement_type }} rot-enc ui-announcement-alert">{{ ui_texts.ui_announcement_text|rot13 }}</div>
+ {% endif %}
+ <form method="post" autofill="off">
+ <div class="d-flex mt-3">
+ <label class="visually-hidden" for="login_user">{{ lang.login.username }}</label>
+ <div class="input-group">
+ <div class="input-group-text"><i class="bi bi-person-fill"></i></div>
+ <input name="login_user" autocorrect="off" autocapitalize="none" type="text" id="login_user" class="form-control" placeholder="{{ lang.login.username }}" required="" autofocus="" autocomplete="username">
+ </div>
+ </div>
+ <div class="d-flex mt-3">
+ <label class="visually-hidden" for="pass_user">{{ lang.login.password }}</label>
+ <div class="input-group">
+ <div class="input-group-text"><i class="bi bi-lock-fill"></i></div>
+ <input name="pass_user" type="password" id="pass_user" class="form-control" placeholder="{{ lang.login.password }}" required="" autocomplete="current-password">
+ <button type="button" class="input-group-text" style="cursor:pointer;" onclick="var i=document.getElementById('pass_user'),ic=this.querySelector('i');if(i.type==='password'){i.type='text';ic.className='bi bi-eye-slash';}else{i.type='password';ic.className='bi bi-eye';}" tabindex="-1" aria-label="Toggle password visibility"><i class="bi bi-eye"></i></button>
+ </div>
+ </div>
+ <div class="d-flex justify-content-between mt-4" style="position: relative">
+ <button type="submit" class="btn btn-xs-lg btn-success w-100 mt-2 mx-auto" style="max-width: 400px;" value="Login">{{ lang.login.login }}</button>
+ </div>
+ </form>
+ <div class="hr-title"><strong>{{ lang.login.other_logins }}</strong></div>
+ <div class="d-flex flex-column align-items-center">
+ <a class="btn btn-xs-lg btn-secondary w-100" style="max-width: 400px;" href="#" id="fido2-login"><i class="bi bi-shield-fill-check"></i> {{ lang.login.fido2_webauthn }}</a>
+ </div>
+ {% if login_delay %}
+ <p><div class="my-4 alert alert-info">{{ lang.login.delayed|format(login_delay) }}</b></div></p>
+ {% endif %}
+ <div class="my-4" id="fido2-alerts"></div>
+ {% if (mailcow_apps or app_links) and not hide_mailcow_apps %}
+ <legend><i class="bi bi-link-45deg"></i> {{ ui_texts.apps_name|raw }}</legend><hr />
+ <div class="my-2 apps">
+ {% for app in mailcow_apps %}
+ {% if not app.hide %}
+ {% if not skip_sogo or not is_uri('SOGo', app.link) %}
+ <div class="m-2">
+ <a href="{{ app.link }}" role="button" {% if app.description %}title="{{ app.description }}"{% endif %} class="btn btn-primary btn-block">{{ app.name }}</a>
+ </div>
+ {% endif %}
+ {% endif %}
+ {% endfor %}
+ {% for row in app_links %}
+ {% for key, val in row %}
+ {% if not val.hide %}
+ <div class="m-2">
+ <a href="{{ val.link }}" role="button" class="btn btn-primary btn-block">{{ key }}</a>
+ </div>
+ {% endif %}
+ {% endfor %}
+ {% endfor %}
+ </div>
+ {% endif %}
+ </div>
+ </div>
+
+ {% if custom_login.hide_user_quicklink != 1 or custom_login.hide_domainadmin_quicklink != 1 %}
+ <p class="text-center mt-3 text-muted" style="font-size: 0.9rem;">
+ {{ lang.login.login_linkstext }}<br>
+ {% if custom_login.hide_user_quicklink != 1 %}<a href="/">{{ lang.login.login_usertext }}</a>{% endif %}
+ {% if custom_login.hide_user_quicklink != 1 and custom_login.hide_domainadmin_quicklink != 1 %}|{% endif %}
+ {% if custom_login.hide_domainadmin_quicklink != 1 %}<a href="/domainadmin">{{ lang.login.login_domainadmintext }}</a>{% endif %}
+ </p>
+ {% endif %}
+ </div>
+</div>
+{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/base.twig b/mailcow/src/mailcow-dockerized/data/web/templates/base.twig
index ca744d2..0006845 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/base.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/base.twig
@@ -10,15 +10,16 @@
<link rel="stylesheet" href="{{ css_path }}">
<script>
+ var mailcow_dark_css = '{{ dark_css_path }}';
// check if darkmode is preferred by OS or set by localStorage
- if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches && localStorage.getItem("theme") !== "light" ||
- localStorage.getItem("theme") === "dark") {
+ if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches && localStorage.getItem("mailcow_theme") !== "light" ||
+ localStorage.getItem("mailcow_theme") === "dark") {
var head = document.getElementsByTagName('head')[0];
var link = document.createElement('link');
link.id = 'dark-mode-theme';
link.rel = 'stylesheet';
link.type = 'text/css';
- link.href = '/css/themes/mailcow-darkmode.css';
+ link.href = mailcow_dark_css;
head.appendChild(link);
}
</script>
@@ -29,7 +30,7 @@
<body>
<div class="overlay"></div>
{% block navbar %}
-<nav class="navbar navbar-expand-lg navbar-light bg-light navbar-fixed-top p-0">
+<nav class="navbar navbar-expand-lg navbar-light bg-light sticky-top p-0">
<div class="container-fluid">
<a class="navbar-brand" href="/">
<img class="main-logo" alt="mailcow-logo" src="{{ logo|default('/img/cow_mailcow.svg') }}">
@@ -60,49 +61,67 @@
</ul>
</li>
{% endif %}
+
{% if mailcow_cc_role %}
+ {% if mailcow_cc_role == 'admin' %}
<li class="nav-item dropdown">
<a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown" role="button" aria-expanded="false">{{ lang.header.mailcow_system }}</a>
<ul class="dropdown-menu">
- {% if mailcow_cc_role == 'admin' %}
- <li><a href="/debug" class="dropdown-item {% if is_uri('debug') %}active{% endif %}">{{ lang.header.debug }}</a></li>
- <li><a href="/admin" class="dropdown-item {% if is_uri('admin') %}active{% endif %}">{{ lang.header.mailcow_config }}</a></li>
- {% endif %}
- {% if mailcow_cc_role != 'admin' %}
- <li><a href="/user" class="dropdown-item {% if is_uri('user') %}active{% endif %}">{{ lang.header.user_settings }}</a></li>
- {% endif %}
+ <li><a href="/admin/dashboard" class="dropdown-item {% if is_uri('dashboard') %}active{% endif %}">{{ lang.header.debug }}</a></li>
+ <li><a href="/admin/system" class="dropdown-item {% if is_uri('system') %}active{% endif %}">{{ lang.header.mailcow_config }}</a></li>
</ul>
</li>
<li class="nav-item dropdown">
<a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown" role="button" aria-expanded="false">{{ lang.header.email }}</a>
<ul class="dropdown-menu">
- {% if mailcow_cc_role == 'admin' or mailcow_cc_role == 'domainadmin' %}
- <li><a href="/mailbox" class="dropdown-item {% if is_uri('mailbox') %}active{% endif %}">{{ lang.header.mailcow_config }}</a></li>
- {% endif %}
+ <li><a href="/admin/mailbox" class="dropdown-item {% if is_uri('mailbox') %}active{% endif %}">{{ lang.header.mailcow_config }}</a></li>
<li><a href="/quarantine" class="dropdown-item {% if is_uri('quarantine') %}active{% endif %}">{{ lang.header.quarantine }}</a></li>
- {% if mailcow_cc_role == 'admin' %}
- <li><a href="/queue" class="dropdown-item {% if is_uri('queue') %}active{% endif %}">{{ lang.queue.queue_manager }}</a></li>
- {% endif %}
- {% if mailcow_cc_role == 'admin' %}
+ <li><a href="/admin/queue" class="dropdown-item {% if is_uri('queue') %}active{% endif %}">{{ lang.queue.queue_manager }}</a></li>
<li><a href="#" class="dropdown-item" data-bs-toggle="modal" data-container="sogo-mailcow" data-bs-target="#RestartContainer">{{ lang.header.restart_sogo }}</a></li>
- {% endif %}
</ul>
</li>
{% endif %}
- {% if mailcow_apps or app_links %}
+ {% if mailcow_cc_role == 'domainadmin' %}
+ <li class="nav-item dropdown">
+ <a href="/domainadmin/user" class="nav-link" role="button" aria-expanded="false">{{ lang.header.user_settings }}</a>
+ </li>
+ {% elseif mailcow_cc_role == 'user' %}
+ <li class="nav-item dropdown">
+ <a href="/user" class="nav-link" role="button" aria-expanded="false">{{ lang.header.user_settings }}</a>
+ </li>
+ {% endif %}
+
+ {% if mailcow_cc_role == 'domainadmin' %}
+ <li class="nav-item dropdown">
+ <a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown" role="button" aria-expanded="false">{{ lang.header.email }}</a>
+ <ul class="dropdown-menu">
+ <li><a href="/domainadmin/mailbox" class="dropdown-item {% if is_uri('mailbox') %}active{% endif %}">{{ lang.header.mailcow_config }}</a></li>
+ <li><a href="/quarantine" class="dropdown-item {% if is_uri('quarantine') %}active{% endif %}">{{ lang.header.quarantine }}</a></li>
+ </ul>
+ </li>
+ {% endif %}
+
+ {% if mailcow_cc_role == 'user' %}
+ <li class="nav-item dropdown">
+ <a href="/quarantine" class="nav-link">{{ lang.header.quarantine }}</a>
+ </li>
+ {% endif %}
+ {% endif %}
+
+ {% if mailcow_apps_processed or app_links %}
<li class="nav-item dropdown">
<a href="#" class="nav-link dropdown-toggle" data-bs-toggle="dropdown" role="button" aria-expanded="false"><i class="bi bi-link-45deg me-2"></i> {{ ui_texts.apps_name|raw }}</a>
<ul class="dropdown-menu">
- {% for app in mailcow_apps %}
- {% if not skip_sogo or not is_uri('SOGo', app.link) %}
+ {% for app in mailcow_apps_processed %}
+ {% if not skip_sogo or not is_uri('SOGo', app.user_link) %}
<li {% if app.description %}title="{{ app.description }}"{% endif %}>
- <a href="{{ app.link }}" class="dropdown-item">{{ app.name }}</a>
+ <a href="{{ app.user_link }}" class="dropdown-item">{{ app.name }}</a>
</li>
{% endif %}
{% endfor %}
- {% for row in app_links %}
+ {% for row in app_links_processed %}
{% for key, val in row %}
- <li><a href="{{ val }}" class="dropdown-item">{{ key }}</a></li>
+ <li><a href="{{ val.user_link }}" class="dropdown-item">{{ key }}</a></li>
{% endfor %}
{% endfor %}
</ul>
@@ -126,13 +145,13 @@
<form action="/" method="post" id="logout"><input type="hidden" name="logout"></form>
-{% if ui_texts.ui_announcement_text and ui_texts.ui_announcement_active and not is_root_uri %}
+{% if ui_texts.ui_announcement_text and ui_texts.ui_announcement_active and not is_root_uri and mailcow_cc_username %}
<div class="container mt-4">
<div class="alert alert-{{ ui_texts.ui_announcement_type }}">{{ ui_texts.ui_announcement_text }}</div>
</div>
{% endif %}
-<div class="container my-4">
+<div class="container flex-grow-1 my-4">
{% block content %}{% endblock %}
</div>
@@ -144,9 +163,11 @@
var lang_acl = {{ lang_acl|raw }};
var lang_tfa = {{ lang_tfa|raw }};
var lang_fido2 = {{ lang_fido2|raw }};
+ var lang_success = {{ lang_success|raw }};
+ var lang_danger = {{ lang_danger|raw }};
var docker_timeout = {{ docker_timeout|raw }} * 1000;
var mailcow_cc_role = '{{ mailcow_cc_role }}';
- var last_login = '{{ last_login }}';
+ {% if mailcow_cc_username %}
var mailcow_info = {
version_tag: '{{ mailcow_info.version_tag }}',
last_version_tag: '{{ mailcow_info.last_version_tag }}',
@@ -156,13 +177,24 @@
project_repo: '{{ mailcow_info.git_repo }}',
branch: '{{ mailcow_info.mailcow_branch }}'
};
+ {% else %}
+ var mailcow_info = {
+ version_tag: '',
+ last_version_tag: '',
+ updatedAt: '',
+ project_url: '',
+ project_owner: '',
+ project_repo: '',
+ branch: ''
+ };
+ {% endif %}
$(window).scroll(function() {
sessionStorage.scrollTop = $(this).scrollTop();
});
// Select language and reopen active URL without POST
function setLang(sel) {
- $.post( '{{ uri }}', {lang: sel} );
+ $.post( '{{ uri|escape("js") }}', {lang: sel} );
window.location.href = window.location.pathname + window.location.search;
}
// FIDO2 functions
@@ -236,7 +268,7 @@
$(".totp-authenticator-selection").click(function(){
$(".totp-authenticator-selection").removeClass("active");
$(this).addClass("active");
-
+
var id = $(this).children('input').first().val();
$("#totp_selected_id").val(id);
@@ -245,7 +277,7 @@
if ($('.totp-authenticator-selection').length == 1 &&
$('#pending_tfa_tab_yubi_otp').length == 0 &&
$('.webauthn-authenticator-selection').length == 0){
-
+
// select default if only one authenticator exists
$('.totp-authenticator-selection').addClass("active");
@@ -258,7 +290,7 @@
$('#pending_tfa_tab_totp').on('shown.bs.tab', function() {
// autofocus
setTimeout(function() { $("#collapseTotpTFA").find('input[name="token"]').focus(); }, 200);
- });
+ });
// validate Yubi OTP tfa
if ($('.webauthn-authenticator-selection').length == 0){
// autofocus
@@ -277,10 +309,10 @@
$(".webauthn-authenticator-selection").click(function(){
$(".webauthn-authenticator-selection").removeClass("active");
$(this).addClass("active");
-
+
var id = $(this).children('input').first().val();
$("#webauthn_selected_id").val(id);
-
+
var webauthn_status_auth = document.getElementById('webauthn_status_auth');
webauthn_status_auth.style.setProperty('display', 'flex', 'important');
var webauthn_return_code = document.getElementById('webauthn_return_code');
@@ -303,7 +335,7 @@
console.log(json);
if (json.success === false) throw new Error();
if (json.type === "error") throw new Error(json.msg);
-
+
recursiveBase64StrToArrayBuffer(json);
return json;
}).then(getCredentialArgs => {
@@ -330,7 +362,7 @@
webauthn_return_code.style.setProperty('display', 'block', 'important');
webauthn_return_code.innerHTML = lang_tfa.error_code + ': ' + err + ' ' + lang_tfa.reload_retry;
});
- }
+ }
});
$('#ConfirmTFAModal').on('hidden.bs.modal', function(){
// cancel pending login
@@ -346,6 +378,116 @@
});
{% endif %}
+ {% if pending_tfa_setup %}
+ var setupTFAModal = new bootstrap.Modal(document.getElementById("SetupTFAModal"), {
+ backdrop: 'static',
+ keyboard: false
+ });
+ setupTFAModal.show();
+
+ // Load QR code for TOTP setup in SetupTFAModal
+ var setupTotpSecret = $('#setup-tfa-qr-img').data('totp-secret');
+ if (setupTotpSecret) {
+ $.ajax({
+ type: "GET",
+ url: "/inc/ajax/qr_gen.php?token=" + encodeURIComponent(setupTotpSecret),
+ success: function(data) {
+ $('#setup-tfa-qr-img').attr('src', data);
+ }
+ });
+ }
+
+ // WebAuthn registration for SetupTFAModal
+ $('#start_setup_webauthn_register').click(function() {
+ if (!window.fetch || !navigator.credentials || !navigator.credentials.create) {
+ window.alert('Browser not supported.');
+ return;
+ }
+ var keyId = $('#setup_webauthn_reg_form input[name=key_id]').val();
+ if (!keyId) {
+ $('#setup_webauthn_return_code').show().text('Please fill in the key ID first.');
+ return;
+ }
+ window.fetch('/api/v1/get/webauthn-tfa-registration', {method: 'GET', cache: 'no-cache'}).then(function(response) {
+ return response.json();
+ }).then(function(json) {
+ if (json.success === false) throw new Error(json.error || 'Registration failed');
+ recursiveBase64StrToArrayBuffer(json);
+ return navigator.credentials.create(json);
+ }).then(function(cred) {
+ return {
+ id: cred.id,
+ rawId: arrayBufferToBase64(cred.rawId),
+ response: {
+ attestationObject: arrayBufferToBase64(cred.response.attestationObject),
+ clientDataJSON: arrayBufferToBase64(cred.response.clientDataJSON)
+ },
+ type: cred.type
+ };
+ }).then(function(credData) {
+ $('#setup_webauthn_register_data').val(JSON.stringify(credData));
+ $('#setup_webauthn_reg_form input[name=set_tfa]').val('1');
+ $('#setup_webauthn_reg_form').submit();
+ }).catch(function(err) {
+ $('#setup_webauthn_return_code').show().text(err.message || 'Registration failed');
+ });
+ });
+ {% endif %}
+
+ {% if pending_pw_update_modal and not pending_tfa_setup and not pending_tfa_methods %}
+ var changePWModal = new bootstrap.Modal(document.getElementById("ChangePWModal"), {
+ backdrop: 'static',
+ keyboard: false
+ });
+ changePWModal.show();
+
+ $('#changePWModalForm').on('submit', function(e) {
+ e.preventDefault();
+ var newPw = $('#changePWNew').val();
+ var newPw2 = $('#changePWNew2').val();
+ var role = '{{ mailcow_cc_role }}';
+ var username = '{{ mailcow_cc_username }}';
+
+ var url, attrPayload, itemsPayload;
+ if (role === 'admin') {
+ url = '/api/v1/edit/admin';
+ attrPayload = {password: newPw, password2: newPw2};
+ itemsPayload = [username];
+ } else {
+ url = '/api/v1/edit/self';
+ attrPayload = {user_new_pass: newPw, user_new_pass2: newPw2};
+ itemsPayload = null;
+ }
+
+ $('#changePWAlert').hide();
+ $.ajax({
+ type: 'POST',
+ url: url,
+ data: {
+ attr: JSON.stringify(attrPayload),
+ items: JSON.stringify(itemsPayload),
+ csrf_token: '{{ csrf_token }}'
+ },
+ dataType: 'json',
+ success: function(data) {
+ if (data && data[0] && data[0].type === 'success') {
+ window.location.reload();
+ } else {
+ var msg = (data && data[0] && data[0].msg) ? data[0].msg : 'Password change failed.';
+ // the API returns raw language keys, resolve them like the alert box does
+ if (Object.prototype.hasOwnProperty.call(lang_danger, msg)) {
+ msg = lang_danger[msg];
+ }
+ $('#changePWAlert').show().text(msg);
+ }
+ },
+ error: function() {
+ $('#changePWAlert').show().text('Request failed. Please try again.');
+ }
+ });
+ });
+ {% endif %}
+
// Validate FIDO2
$("#fido2-login").click(function(){
@@ -372,16 +514,14 @@
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'});
+ var formData = new FormData();
+ formData.append("token", AuthenticatorAttestationResponse);
+ formData.append("verify_fido2_login", "true");
+
+ return window.fetch(window.location.href, {method:'POST', body: formData, 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) {
+ window.location = window.location.href.split("#")[0];
+ }).catch(function(err) {
if (typeof err.message === 'undefined') {
mailcow_alert_box(lang_fido2.fido2_validation_failed, "danger");
} else {
@@ -541,7 +681,7 @@
Version: <a href="{{ mailcow_info.git_project_url }}/releases/tag/{{ mailcow_info.version_tag }}" target="_blank">{{ mailcow_info.version_tag }}
</a>
</span>
- {% endif %}
+ {% endif %}
{% if mailcow_cc_username and mailcow_info.mailcow_branch|lower == "nightly" and mailcow_info.version_tag|default %}
<span class="version">
🛠️🐮 + 🐋 = 💕
@@ -550,6 +690,14 @@
<span style="text-align:right;display:block;">Build: {{ mailcow_info.git_commit_date }}</span>
</span>
{% endif %}
+ {% if mailcow_cc_username and mailcow_info.mailcow_branch|lower == "legacy" and mailcow_info.version_tag|default %}
+ <span class="version">
+ ⚰️🐮 + 🐋 = 💕
+ Legacy: <a href="{{ mailcow_info.git_project_url }}/commit/{{ mailcow_info.git_commit }}" target="_blank">{{ mailcow_info.version_tag }}
+ </a><br>
+ <span style="text-align:right;display:block;">Build: {{ mailcow_info.git_commit_date }}</span>
+ </span>
+ {% endif %}
</div>
</body>
</html>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/dashboard.twig b/mailcow/src/mailcow-dockerized/data/web/templates/dashboard.twig
new file mode 100644
index 0000000..3c57afa
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/dashboard.twig
@@ -0,0 +1,561 @@
+{% extends 'base.twig' %}
+
+{% block content %}
+<ul class="nav nav-tabs" role="tablist">
+ <li role="presentation" class="nav-item"><button class="nav-link active" data-bs-target="#tab-containers" aria-controls="tab-containers" role="tab" data-bs-toggle="tab">{{ lang.debug.system_containers }}</button></li>
+ <li class="nav-item dropdown">
+ <a class="nav-link dropdown-toggle" data-bs-toggle="dropdown" href="#">{{ lang.debug.logs }}</a>
+ <ul class="dropdown-menu">
+ <li role="presentation"><span class="dropdown-header fs-6">{{ lang.debug.in_memory_logs }}</span></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-postfix-logs" aria-selected="false" aria-controls="tab-postfix-logs" role="tab" data-bs-toggle="tab">Postfix</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-dovecot-logs" aria-selected="false" aria-controls="tab-dovecot-logs" role="tab" data-bs-toggle="tab">Dovecot</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-sogo-logs" aria-selected="false" aria-controls="tab-sogo-logs" role="tab" data-bs-toggle="tab">SOGo</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-netfilter-logs" aria-selected="false" aria-controls="tab-netfilter-logs" role="tab" data-bs-toggle="tab">Netfilter</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-autodiscover-logs" aria-selected="false" aria-controls="tab-autodiscover-logs" role="tab" data-bs-toggle="tab">Autodiscover</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-watchdog-logs" aria-selected="false" aria-controls="tab-watchdog-logs" role="tab" data-bs-toggle="tab">Watchdog</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-acme-logs" aria-selected="false" aria-controls="tab-acme-logs" role="tab" data-bs-toggle="tab">ACME</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-api-logs" aria-selected="false" aria-controls="tab-api-logs" role="tab" data-bs-toggle="tab">API</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-api-rl" aria-selected="false" aria-controls="tab-api-rl" role="tab" data-bs-toggle="tab">Ratelimits</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-cron-logs" aria-selected="false" aria-controls="tab-api-rl" role="tab" data-bs-toggle="tab">Crontasks</button></li>
+ <li role="presentation"><span class="dropdown-header fs-6">{{ lang.debug.external_logs }}</span></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-rspamd-history" aria-selected="false" aria-controls="tab-rspamd-history" role="tab" data-bs-toggle="tab">Rspamd</button></li>
+ <li role="presentation"><span class="dropdown-header fs-6">{{ lang.debug.static_logs }}</span></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-ui" aria-selected="false" aria-controls="tab-ui" role="tab" data-bs-toggle="tab">Mailcow UI</button></li>
+ <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-sasl" aria-selected="false" aria-controls="tab-sasl" role="tab" data-bs-toggle="tab">SASL</button></li>
+ </ul>
+ </li>
+</ul>
+
+<div class="row">
+ <div class="col-md-12">
+ <div class="tab-content" style="padding-top:20px">
+ <div role="tabpanel" class="tab-pane active" id="tab-containers">
+
+ <div class="card mb-4">
+ <div class="card-header fs-5">
+ <span>{{ ui_texts.title_name|raw }}</span>
+ </div>
+ <div class="card-body">
+ <div class="row">
+ <div class="col-sm-12 col-md-4 d-flex flex-column">
+ <img class="main-logo img-responsive my-auto m-auto" alt="mailcow-logo" style="max-width: 85%; max-height: 85%;" src="{{ logo|default('/img/cow_mailcow.svg') }}">
+ <img class="main-logo-dark img-responsive my-auto m-auto" alt="mailcow-logo-dark" style="max-width: 85%; max-height: 85%;" src="{{ logo_dark|default('/img/cow_mailcow.svg') }}">
+ </div>
+ <div class="col-sm-12 col-md-8">
+ <div style="margin-top: 10px;">
+ <table class="table table-striped w-100">
+ <tbody>
+ <tr>
+ <td>Hostname</td>
+ <td class="text-break"><div>
+ <p><b>{{ hostname }}</b></p>
+ </div></td>
+ </tr>
+ <tr>
+ <td>{{ lang.debug.architecture }}</td>
+ <td class="text-break"><div>
+ <p id="host_architecture">-</p>
+ </div></td>
+ </tr>
+ <tr>
+ <td>IPs</td>
+ <td class="text-break">
+ {% if ip_check == 1 %}
+ <span class="d-none" id="host_ipv4">-</span>
+ <span class="d-none mb-2" id="host_ipv6">-</span>
+ <button class="d-block btn btn-primary btn-sm" id="host_show_ip">
+ <span class="text">{{ lang.debug.show_ip }}</span>
+ <div class="spinner-border spinner-border-sm d-none" role="status">
+ <span class="visually-hidden">Loading...</span>
+ </div>
+ </button>
+ {% else %}
+ <span class="d-block">{{ lang.admin.ip_check_disabled|raw }}</span>
+ {% endif %}
+ </td>
+ </tr>
+ <tr>
+ <td>Version</td>
+ <td class="text-break">
+ <div class="fw-bolder">
+ <p ><a href="#" id="mailcow_version">{{ mailcow_info.version_tag }}</a></p>
+ <p id="mailcow_update"></p>
+ </div>
+ </td>
+ </tr>
+ <tr>
+ <td>{{ lang.debug.current_time }}</td>
+ <td id="host_date" class="text-break">-</td>
+ </tr>
+ <tr>
+ <td>{{ lang.debug.timezone }}</td>
+ <td class="text-break">{{ timezone }}</td>
+ </tr>
+ <tr>
+ <td>{{ lang.debug.uptime }}</td>
+ <td id="host_uptime" class="text-break">-</td>
+ </tr>
+ <tr>
+ <td>{{ lang.debug.disk_usage }}</td>
+ <td class="text-break">
+ <div>
+ <span class="d-block"><i class="bi bi-hdd-fill"></i> {{ vmail_df[0] }}</span>
+ <span class="d-block">{{ vmail_df[2] }} / {{ vmail_df[1] }} ({{ vmail_df[4] }})</span>
+ </div>
+ <div class="mt-2 mb-4">
+ <div class="progress">
+ <div class="progress-bar bg-info" role="progressbar" style="width:{{ vmail_df[4] }}"></div>
+ </div>
+ </div>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ </div>
+
+ <div class="col-sm-6 mt-4">
+ <h3>CPU</h3>
+ <h5><span id="host_cpu_cores">-</span> {{ lang.debug.cores }} @ <span id="host_cpu_usage"></span></h5>
+ <canvas id="host_cpu_chart" width="400" height="200"></canvas>
+ </div>
+ <div class="col-sm-6 mt-4">
+ <h3>{{ lang.debug.memory|upper}}</h3>
+ <h5><span id="host_memory_total">-</span> @ <span id="host_memory_usage"></span></h5>
+ <canvas id="host_mem_chart" width="400" height="200"></canvas>
+ </div>
+
+ <div class="col-sm-12">
+ <legend class="mt-4">
+ {{ lang.admin.guid_and_license }}
+ </legend>
+ <hr />
+ <div id="license">
+ <form class="form-horizontal" autocapitalize="none" autocorrect="off" role="form" method="post">
+ <div class="row">
+ <label class="control-label col-sm-3" for="guid">{{ lang.admin.guid }}:</label>
+ <div class="col-sm-9">
+ <div class="input-group">
+ <span class="input-group-text">
+ <i class="bi bi-suit-heart{% if gal.valid == true %}-fill text-danger{% endif %}"></i>
+ </span>
+ <input type="text" id="guid" class="form-control" value="{{ license_guid }}" readonly>
+ </div>
+ <p class="text-muted">
+ {{ lang.admin.customer_id }}: {{ gal.c|default('?')|raw }} -
+ {{ lang.admin.service_id }}: {{ gal.s|default('?')|raw }} -
+ {{ lang.admin.sal_level }}: {{ gal.m|default('?')|raw }}
+ </p>
+ </div>
+ </div>
+ <div class="row">
+ <div class="offset-sm-3 col-sm-9">
+ <p class="text-muted">{{ lang.admin.license_info|raw }}</p>
+ <div class="btn-group">
+ <button class="btn btn-sm d-block d-sm-inline btn-success" name="license_validate_now" type="submit" href="#">{{ lang.admin.validate_license_now }}</button>
+ </div>
+ </div>
+ </div>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ <!-- container info -->
+ <div class="card mb-4">
+ <div class="card-header fs-5">
+ <span>{{ lang.debug.containers_info }}</span>
+ </div>
+ <div class="card-body p-0">
+ <div class="row mx-0">
+ <!-- rest of the containers -->
+ {% for container, container_info in containers %}
+ <div class="col-md-6 col-sm-12 p-2">
+ <div class="list-group-item p-0">
+ <div class="d-flex p-2 list-group-header">
+ <div>
+ <span class="fw-bold">{{ container }}</span>
+ <span class="d-block d-md-inline">({{ container_info.Config.Image }})</span>
+ <small class="d-block">({{ lang.debug.started_on }} <span class="parse_date">{{ container_info.State.StartedAtHR }}</span>)</small>
+ {% if container_info.State.Running == 1 %}
+ <span class="badge fs-7 bg-success loader" style="min-width:100px">
+ {{ lang.debug.container_running }}
+ <span class="loader-dot">.</span>
+ <span class="loader-dot">.</span>
+ <span class="loader-dot">.</span>
+ </span>
+ {% elseif container_info.State %}
+ <span class="badge fs-7 bg-danger" style="min-width:100px">
+ {{ lang.debug.container_stopped }}
+ <i class="bi-x ms-1"></i>
+ </span>
+ {% endif %}
+ </div>
+ <div class="mt-auto ms-auto">
+ <button class="btn btn-light" type="button" data-bs-toggle="collapse" data-bs-target="#{{ container }}Collapse" aria-expanded="false" aria-controls="{{ container }}Collapse">
+ <i class="bi bi-caret-down-fill caret"></i>
+ </button>
+ </div>
+ </div>
+ <div class="collapse p-0 list-group-details container-details-collapse" id="{{ container }}Collapse" data-id="{{ container_info.Id }}">
+ <div class="row p-2 pt-4">
+ <div class="mt-4 col-sm-12 col-md-6 d-flex flex-column">
+ <h6>Disk I/O</h6>
+ <div class="spinner-border my-4 mx-auto" role="status">
+ <span class="visually-hidden">Loading...</span>
+ </div>
+ <canvas class="d-none" id="{{ container }}_DiskIOChart" width="400" height="200"></canvas>
+ </div>
+ <div class="mt-4 col-sm-12 col-md-6 d-flex flex-column">
+ <h6>Net I/O</h6>
+ <div class="spinner-border my-4 mx-auto" role="status">
+ <span class="visually-hidden">Loading...</span>
+ </div>
+ <canvas class="d-none" id="{{ container }}_NetIOChart" width="400" height="200"></canvas>
+ </div>
+ <div class="col-12 d-flex" style="height: 40px">
+ <a href data-bs-toggle="modal"
+ data-container="{{ container }}"
+ data-bs-target="#RestartContainer"
+ class="btn btn-sm btn-secondary d-flex align-items-center justify-content-center mb-2 ms-auto"
+ style="height: 30px;">{{ lang.debug.restart_container }}
+ <i class="ms-1 bi
+ {% if container_info.State.Running == 1 %}
+ bi-record-fill text-success
+ {% elseif container_info.State %}
+ bi-record-fill text-danger
+ {% else %}
+ default
+ {% endif %}
+ "
+ ></i>
+ </a>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ {% endfor %}
+ </div>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-postfix-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Postfix</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_postfix_logs" data-table="postfix_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="postfix_log" data-log-url="postfix" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="postfix_log" data-log-url="postfix" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="postfix_log" data-table="postfix_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="postfix_log" data-table="postfix_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="postfix_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-ui">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Mailcow UI</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_ui_logs" data-table="ui_logs">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="mailcow_ui" data-table="ui_logs" data-log-url="ui" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="mailcow_ui" data-table="ui_logs" data-log-url="ui" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="ui_logs" data-table="ui_logs" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="ui_logs" data-table="ui_logs" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="ui_logs" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-sasl">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">SASL</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_sasl_logs" data-table="sasl_logs">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="sasl_log_table" data-table="sasl_logs" data-log-url="ui" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="sasl_log_table" data-table="sasl_logs" data-log-url="ui" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="sasl_logs" data-table="sasl_logs" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="sasl_logs" data-table="sasl_logs" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="sasl_logs" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-dovecot-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Dovecot</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_dovecot_logs" data-table="dovecot_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="dovecot_log" data-log-url="dovecot" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="dovecot_log" data-log-url="dovecot" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="dovecot_log" data-table="dovecot_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="dovecot_log" data-table="dovecot_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="dovecot_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-sogo-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">SOGo</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_sogo_logs" data-table="sogo_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="sogo_log" data-log-url="sogo" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="sogo_log" data-log-url="sogo" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="sogo_log" data-table="sogo_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="sogo_log" data-table="sogo_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="sogo_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-netfilter-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Netfilter</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_netfilter_logs" data-table="netfilter_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="netfilter_log" data-log-url="netfilter" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="netfilter_log" data-log-url="netfilter" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="netfilter_log" data-table="netfilter_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="netfilter_log" data-table="netfilter_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="netfilter_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-rspamd-history">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Rspamd history</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_rspamd_history" data-table="rspamd_history">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <legend>{{ lang.debug.chart_this_server }}</legend><hr />
+ <div id="chart-container">
+ <canvas id="rspamd_donut" style="width:100%;height:400px"></canvas>
+ </div>
+ <legend>{{ lang.debug.history_all_servers }}</legend><hr />
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="rspamd_history" data-table="rspamd_history" data-log-url="rspamd-history" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="rspamd_history" data-table="rspamd_history" data-log-url="rspamd-history" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="rspamd_history" data-table="rspamd_history" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="rspamd_history" data-table="rspamd_history" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="rspamd_history" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-autodiscover-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Autodiscover</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_autodiscover_logs" data-table="autodiscover_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="autodiscover_log" data-table="autodiscover_log" data-log-url="autodiscover" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="autodiscover_log" data-table="autodiscover_log" data-log-url="autodiscover" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="autodiscover_log" data-table="autodiscover_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="autodiscover_log" data-table="autodiscover_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="autodiscover_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-watchdog-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Watchdog</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_watchdog_logs" data-table="watchdog_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="watchdog" data-table="watchdog_log" data-log-url="watchdog" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="watchdog" data-table="watchdog_log" data-log-url="watchdog" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="watchdog_log" data-table="watchdog_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="watchdog_log" data-table="watchdog_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="watchdog_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-acme-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">ACME</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_acme_logs" data-table="acme_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="acme_log" data-log-url="acme" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="acme_log" data-log-url="acme" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="acme_log" data-table="acme_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="acme_log" data-table="acme_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="acme_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-api-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">API</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_api_logs" data-table="api_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="apilog" data-table="api_log" data-log-url="api" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="apilog" data-table="api_log" data-log-url="api" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="api_log" data-table="api_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="api_log" data-table="api_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="api_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-api-rl">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Ratelimits</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_rl_logs" data-table="rl_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="rllog" data-table="rl_log" data-log-url="ratelimited" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="rllog" data-table="rl_log" data-log-url="ratelimited" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="rl_log" data-table="rl_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="rl_log" data-table="rl_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <p class="text-muted">{{ lang.admin.hash_remove_info|raw }}</p>
+ <table id="rl_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ <div role="tabpanel" class="tab-pane" id="tab-cron-logs">
+ <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
+ <div class="card">
+ <div class="card-header d-flex align-items-center fs-5">
+ <span class="mt-2 ms-2">Crontasks</span>
+ <div class="btn-group ms-auto">
+ <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_cron_logs" data-table="cron_log">{{ lang.admin.refresh }}</button>
+ </div>
+ </div>
+ <div class="card-body">
+ <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="cron_log" data-log-url="cron" data-nrows="100" href="#">+ 100</a></li>
+ <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="cron_log" data-log-url="cron" data-nrows="1000" href="#">+ 1000</a></li>
+ <li class="table_collapse_option"><hr class="dropdown-divider"></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="cron_log" data-table="cron_log" href="#">{{ lang.datatables.expand_all }}</a></li>
+ <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="cron_log" data-table="cron_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
+ </ul>
+ <table id="cron_log" class="table table-striped dt-responsive w-100"></table>
+ </div>
+ </div>
+ </div>
+
+ </div> <!-- /tab-content -->
+ </div> <!-- /col-md-12 -->
+</div> <!-- /row -->
+
+<script type='text/javascript'>
+ var lang = {{ lang_admin|raw }};
+ var lang_debug = {{ lang_debug|raw }};
+ var lang_datatables = {{ lang_datatables|raw }};
+ var csrf_token = '{{ csrf_token }}';
+ var log_pagination_size = Math.trunc('{{ log_pagination_size }}');
+</script>
+{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/debug.twig b/mailcow/src/mailcow-dockerized/data/web/templates/debug.twig
deleted file mode 100644
index 8673711..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/templates/debug.twig
+++ /dev/null
@@ -1,639 +0,0 @@
-{% extends 'base.twig' %}
-
-{% block content %}
-<ul class="nav nav-tabs" role="tablist">
- <li role="presentation" class="nav-item"><button class="nav-link active" data-bs-target="#tab-containers" aria-controls="tab-containers" role="tab" data-bs-toggle="tab">{{ lang.debug.system_containers }}</button></li>
- <li class="nav-item dropdown">
- <a class="nav-link dropdown-toggle" data-bs-toggle="dropdown" href="#">{{ lang.debug.logs }}</a>
- <ul class="dropdown-menu">
- <li role="presentation"><span class="dropdown-header fs-6">{{ lang.debug.in_memory_logs }}</span></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-postfix-logs" aria-selected="false" aria-controls="tab-postfix-logs" role="tab" data-bs-toggle="tab">Postfix</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-dovecot-logs" aria-selected="false" aria-controls="tab-dovecot-logs" role="tab" data-bs-toggle="tab">Dovecot</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-sogo-logs" aria-selected="false" aria-controls="tab-sogo-logs" role="tab" data-bs-toggle="tab">SOGo</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-netfilter-logs" aria-selected="false" aria-controls="tab-netfilter-logs" role="tab" data-bs-toggle="tab">Netfilter</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-autodiscover-logs" aria-selected="false" aria-controls="tab-autodiscover-logs" role="tab" data-bs-toggle="tab">Autodiscover</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-watchdog-logs" aria-selected="false" aria-controls="tab-watchdog-logs" role="tab" data-bs-toggle="tab">Watchdog</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-acme-logs" aria-selected="false" aria-controls="tab-acme-logs" role="tab" data-bs-toggle="tab">ACME</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-api-logs" aria-selected="false" aria-controls="tab-api-logs" role="tab" data-bs-toggle="tab">API</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-api-rl" aria-selected="false" aria-controls="tab-api-rl" role="tab" data-bs-toggle="tab">Ratelimits</button></li>
- <li role="presentation"><span class="dropdown-header fs-6">{{ lang.debug.external_logs }}</span></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-rspamd-history" aria-selected="false" aria-controls="tab-rspamd-history" role="tab" data-bs-toggle="tab">Rspamd</button></li>
- <li role="presentation"><span class="dropdown-header fs-6">{{ lang.debug.static_logs }}</span></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-ui" aria-selected="false" aria-controls="tab-ui" role="tab" data-bs-toggle="tab">Mailcow UI</button></li>
- <li role="presentation"><button class="dropdown-item" data-bs-target="#tab-sasl" aria-selected="false" aria-controls="tab-sasl" role="tab" data-bs-toggle="tab">SASL</button></li>
- </ul>
- </li>
-</ul>
-
-<div class="row">
- <div class="col-md-12">
- <div class="tab-content" style="padding-top:20px">
- <div role="tabpanel" class="tab-pane active" id="tab-containers">
-
- <div class="card mb-4">
- <div class="card-header fs-5">
- <span>{{ ui_texts.title_name|raw }}</span>
- </div>
- <div class="card-body">
- <div class="row">
- <div class="col-sm-12 col-md-4 d-flex flex-column">
- <img class="main-logo img-responsive my-auto m-auto" alt="mailcow-logo" style="max-width: 85%; max-height: 85%;" src="{{ logo|default('/img/cow_mailcow.svg') }}">
- <img class="main-logo-dark img-responsive my-auto m-auto" alt="mailcow-logo-dark" style="max-width: 85%; max-height: 85%;" src="{{ logo_dark|default('/img/cow_mailcow.svg') }}">
- </div>
- <div class="col-sm-12 col-md-8">
- <div class="table-responsive" style="margin-top: 10px;">
- <table class="table table-striped table-condensed w-100">
- <tbody>
- <tr>
- <td>Hostname</td>
- <td class="text-break"><div>
- <p><b>{{ hostname }}</b></p>
- </div></td>
- </tr>
- <tr>
- <td>{{ lang.debug.architecture }}</td>
- <td class="text-break"><div>
- <p id="host_architecture">-</p>
- </div></td>
- </tr>
- <tr>
- <td>IPs</td>
- <td class="text-break">
- {% if ip_check == 1 %}
- <span class="d-none" id="host_ipv4">-</span>
- <span class="d-none mb-2" id="host_ipv6">-</span>
- <button class="d-block btn btn-primary btn-sm" id="host_show_ip">
- <span class="text">{{ lang.debug.show_ip }}</span>
- <div class="spinner-border spinner-border-sm d-none" role="status">
- <span class="visually-hidden">Loading...</span>
- </div>
- </button>
- {% else %}
- <span class="d-block">{{ lang.admin.ip_check_disabled|raw }}</span>
- {% endif %}
- </td>
- </tr>
- <tr>
- <td>Version</td>
- <td class="text-break">
- <div class="fw-bolder">
- <p ><a href="#" id="mailcow_version">{{ mailcow_info.version_tag }}</a></p>
- <p id="mailcow_update"></p>
- </div>
- </td>
- </tr>
- <tr>
- <td>{{ lang.debug.current_time }}</td>
- <td id="host_date" class="text-break">-</td>
- </tr>
- <tr>
- <td>{{ lang.debug.timezone }}</td>
- <td class="text-break">{{ timezone }}</td>
- </tr>
- <tr>
- <td>{{ lang.debug.uptime }}</td>
- <td id="host_uptime" class="text-break">-</td>
- </tr>
- <tr>
- <td>{{ lang.debug.disk_usage }}</td>
- <td class="text-break">
- <div>
- <span class="d-block"><i class="bi bi-hdd-fill"></i> {{ vmail_df[0] }}</span>
- <span class="d-block">{{ vmail_df[2] }} / {{ vmail_df[1] }} ({{ vmail_df[4] }})</span>
- </div>
- <div class="mt-2 mb-4">
- <div class="progress">
- <div class="progress-bar bg-info" role="progressbar" style="width:{{ vmail_df[4] }}"></div>
- </div>
- </div>
- </td>
- </tr>
- </tbody>
- </table>
- </div>
- </div>
-
- <div class="col-sm-6 mt-4">
- <h3>CPU</h3>
- <h5><span id="host_cpu_cores">-</span> {{ lang.debug.cores }} @ <span id="host_cpu_usage"></span></h5>
- <canvas id="host_cpu_chart" width="400" height="200"></canvas>
- </div>
- <div class="col-sm-6 mt-4">
- <h3>{{ lang.debug.memory|upper}}</h3>
- <h5><span id="host_memory_total">-</span> @ <span id="host_memory_usage"></span></h5>
- <canvas id="host_mem_chart" width="400" height="200"></canvas>
- </div>
-
- <div class="col-sm-12">
- <legend class="mt-4">
- {{ lang.admin.guid_and_license }}
- </legend>
- <hr />
- <div id="license">
- <form class="form-horizontal" autocapitalize="none" autocorrect="off" role="form" method="post">
- <div class="row">
- <label class="control-label col-sm-3" for="guid">{{ lang.admin.guid }}:</label>
- <div class="col-sm-9">
- <div class="input-group">
- <span class="input-group-text">
- <i class="bi bi-suit-heart{% if gal.valid == true %}-fill text-danger{% endif %}"></i>
- </span>
- <input type="text" id="guid" class="form-control" value="{{ license_guid }}" readonly>
- </div>
- <p class="text-muted">
- {{ lang.admin.customer_id }}: {{ gal.c|default('?')|raw }} -
- {{ lang.admin.service_id }}: {{ gal.s|default('?')|raw }} -
- {{ lang.admin.sal_level }}: {{ gal.m|default('?')|raw }}
- </p>
- </div>
- </div>
- <div class="row">
- <div class="offset-sm-3 col-sm-9">
- <p class="text-muted">{{ lang.admin.license_info|raw }}</p>
- <div class="btn-group">
- <button class="btn btn-sm d-block d-sm-inline btn-success" name="license_validate_now" type="submit" href="#">{{ lang.admin.validate_license_now }}</button>
- </div>
- </div>
- </div>
- </form>
- </div>
- </div>
- </div>
- </div>
- </div>
-
-
-
- <!-- container info -->
- <div class="card mb-4">
- <div class="card-header fs-5">
- <span>{{ lang.debug.containers_info }}</span>
- </div>
- <div class="card-body p-0">
- <div class="row mx-0">
- <!-- solr info -->
- <div class="col-md-6 col-sm-12 p-2">
- <div class="list-group-item p-0">
- <div class="d-flex p-2 list-group-header">
- <div>
- <span class="fw-bold">solr-mailcow</span>
- {% if containers["solr-mailcow"].State.Running == 1 %}
- <span class="d-block d-md-inline">({{ containers["solr-mailcow"].Config.Image }})</span>
- {% endif %}
- {% if containers["solr-mailcow"].State.Running == 1 %}
- <small class="d-block">({{ lang.debug.started_on }} <span class="parse_date">{{ containers["solr-mailcow"].State.StartedAtHR }}</span>)</small>
- {% elseif containers["solr-mailcow"].State.Running != 1 %}
- <small class="d-block">{{ lang.debug.container_disabled }}</small>
- {% endif %}
- {% if containers["solr-mailcow"].State.Running == 1 %}
- <span class="badge fs-7 bg-success loader" style="min-width:100px">
- {{ lang.debug.container_running }}
- <span class="loader-dot">.</span>
- <span class="loader-dot">.</span>
- <span class="loader-dot">.</span>
- </span>
- {% elseif containers["solr-mailcow"].State.Running != 1 %}
- <span class="badge fs-7 bg-danger" style="min-width:100px">
- {{ lang.debug.container_stopped }}
- <i class="bi-x ms-1"></i>
- </span>
- {% endif %}
- </div>
- {% if containers["solr-mailcow"].State.Running == 1 %}
- <div class="mt-auto ms-auto">
- <button class="btn btn-light" type="button" data-bs-toggle="collapse" data-bs-target="#solr-mailcowCollapse" aria-expanded="false" aria-controls="solr-mailcowCollapse">
- <i class="bi bi-caret-down-fill caret"></i>
- </button>
- </div>
- {% endif %}
- </div>
- {% if containers["solr-mailcow"].State.Running == 1 %}
- <div class="collapse p-0 list-group-details container-details-collapse" id="solr-mailcowCollapse" data-id="{{ containers["solr-mailcow"].Id }}">
- <div class="row p-2 pt-4">
- <div class="col-sm-3">
- <p><img class="img-responsive" alt="Solr Logo" width="128px" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAABlCAYAAAAI2qyuAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAAXEUAAFxFAbktYiwAAAAYdEVYdFNvZnR3YXJlAHBhaW50Lm5ldCA0LjEuNWRHWFIAABv7SURBVHhe7V0JuBxVlX4JMy6jM4qOC4rp6qWq+jW+ruoXkIjoS1d3EhYXRvNkFHFBYECUAXGAASEOyiLIrigOEpDoACIqwogLiwMSkIghYF4viSFhiUGWCAQIyXuZ/9w+3V3VdXtfee/+33e+16/uqXtv1T2n7j33nnvukIJCP7BjbOzvsgt0O5cyjsymzG9mU8YvcylzIucYT2Ydczt+7xDkGFuR/hf8XplxzHG6d20qauSSkfCSJUOzRWYKCtMBE3uZ/5hxjE9A4K+FEmwuKUFj9Nd1Y9brdwwNzco6xr10DXk8DAX77kTaXEQKx8UoKLz8AGE+D73BcxVC3zBl09HPUz6ZpOHI0kEboXhnrU3H5ogCFRQGHSvmzv17+stf/ZaVA71EppgXFO0Xcp4CYai2LZeKLs2m9BDxKygMHEg4Mynz+kzK2IP+X52KvlEmzI1SPml+kPLB8CyOXmJKxuMnYyvoG7l9Iv9E9yoo9B3Xjg/thC/8cegtnsffFyGcr6TrBWNcJsQNkGPeIjIHkO8yKU9teiSXiryfs1BQ6A8eWhTdBV/3W4qCid/3c9IQ9QAugW2YoGSTeSc6Snn8KTkcKAyf5Ly1iHudi9eNBV4lKqSg0Evk0tF5EN7HPILpmN/l5CEMdY71pDVKjnkFZ0HDqwulPE1QJmneM5E238ZZKih0H3ln+AB8oV/wC6TxOWYhBfmGP702offYknX0t9P9Dy6MvaE9I99Fjrk+50RiomIKCt0EBO7jENzyop6LVqNXYTbiu6YyvR5NpMz/4tuH8PvLMp6WyTFO5awVFLoDfIkXQ9CkygHatuL9c/+BWYfQwyyX8FQlKN1jGxfEX0P3blg879XoTTbJ+JolskUySeNEUae0PkxEvxUUOgoMfd4rZqkkQkgEAV/FrALgfVzGV41gb3yWbx3KYKgm42mWqKfLpqKHU54Fg9/cgHqtp8kFUZCCQidAK9UQrpoCD2H8HrMPUU9SbRhWhVZeOz6+E927A39h/K+R8DRHjrGVejzKM7dP5E3IM1NMQ92WF6ejFRTawoPjsVdA0O72CJ+E0AMcxbcMkVOhjEdGYgiUNlJ861DeMcdlfM2R8SyM8gWUHy0aQllWSPguFgUqKLSDfMrYRyJcPppImnvxLSTkSRmPlBzjRr5NAMr4eylfo+QYT2A4+C7Ki9ZAsk70NhmfUEw8myhUQaFV0PBKJmBuwvDlpXVjY6UFOVw7pJKnCm3LObHS9Cv1JBKeZuiRfHJ4N8qLPH2hbD+V8JTJMdY/OBZ7rShcQaEV7FgyNBtj9iekAsaE9AeYXSDjRJfI+CoJBvO3+BYBKNrNMr5GCHXIToyZGuVDjpIZx7xCxucjxzhbFK6g0CogSP/rEywXQThLBjoBw5fLZHxugnJsJuOZbxnKLtQtGvbIeOsRyr9vrfPOt1A+pBzoOc6V8ckIivRiUbEUFFoCBPcsmXAVKTvfPJpZBSCgv5bxecgxjmd2gXzKvErKV4egHLevTYdex9lQXZteYMykyi4yCgp1UXT3KAJC9JFKoXJTZoHxHmYVgPBnZXxFwlDqIbcTYatOidmkccNd83Z9NWczlEubR0BBpLy1iNZ31NqIQsOgIRL/FPgzBFgmWET4gm9fySvgBLFRSuqnVSYo4L8yuwAUqmmnxIxjXFncUEWgPFHupIy3EZpwzNM4KwWF6kBvEKRZqdtc+70L43q5oQ6h/BOzCZAtIOMrEgR7OeXH7IWNVU06JaJ+F7jzyM83F1GdZbyNEnqRh4uLlQoKVTGRLIzhK/d5QwApAolfuBzzSmYRoB2FUj4QlGkqM987HAP/KTJeGdH9EOST+VaBNRjeNatg1YjWbzhbBQU5MGQS0UMyaWNvviQAwTyzUqCIILReA72GvQJl+BGzCWyA/YB8G3JKLAyfyu70hDUpcwQK+pSMvxWinomzVlDwY82C0JsLgigE5iC+LABBXOwWpiKREyOzCOTmG8fL+cwXK4MqgLdBp0Rjaz41fCDfJiDcWRzjUTl/a4Q65jl7BQU/3EpQdBEvYt0iU3MLExG+uNsedbm4E6oZ3Og9zmEWAbJxoIx1nRIhtFvI3YVvE1i9KLpLxjHXyvjbIRrCqdkshapAb1BaYIOCeJz5eEX9abdAQaFWc3IJuH69h6dAIgAcswhAYQ6U8HkICviU28eLsGr/kZ0hyPfL+Nsmx9iu7BCFqoDg/colMDfx5RIgQN4FwLTXQCdgOOTznEW+HjuFAOWq45RoPDYBG4PZBWg6GUp6l5y/daLVdDzbpVBGk4tSUPAjk6RwOQWhwdf7Qb5cAoTobLdg5dLGMZwkUFgDqexlygHgiqgRKVEQ8siTjcHsAsLtPlnb5aVZwvANBr5x+rqx2Fu5mKHMmPHP/FNBoYyCa3h5oQ2/N7vXGgj5tPFRj4Alh9/HSQIUh9edhyDH/AAnl4BeoJZT4v3r9isLLKEwvDOvlvC2RJmU+TCGeF/c5PLkLYQwMi6nHoovKSiUwTv5HigKEQRyigSekwUecG2EQvp2t4ARMguNaDFd8KSMWyuVjALKkTHs5ivxO+Ydq/Ye2ZlZBUSv5JiXyPibJsdYlU1FP7XD1aPRPviC97HxLPFAQR7iJAUFL/BV9WyOyiZ1i5ME+EsuIrRDkLJ8uYTcgujC0r2pcgA4N6A0PyjyeMgxbnIHfSgCw7ivSvmbINTldjzLfm5lpWeBjXMInsMzVYz/NzOLgoIfEJDS8CefDIv4uG5gyPQbTv8hXyoBaUcU7804RikAXBHVnBJJacjGYLYSYKu0FnwOhOfYDrpudTpSCkVURGa+kULafbL7yGBnNgUFPwqr04WACxh6lPaZF4Gv8ddFGsbwfKkECPTXhKA5xnOVHsEEKMIFRUEsEuyBi+lrziwl4Iv/yWpDsVqEe15AOd9ekx7WOasSKOQP6nYjeKT3EikFeZkgEom8skixmP/r2k3Q/ggWljP4UgklQz0dHeNLJaAHuZLSMAzzecZWOiWSkIJKgeLcgPJ9CDxNub+jR3gyl4qevsoJio1TbhSimujfRHl184RyPcu3KQwq5u0679VG0NpWJF2z/8JJPYHwyHWMZyDwV/OlEvILYxHqYSoNeAKE9DbQY7J93rjn1LIQmpMQ2C9wkgf5VHg+0mu6y7sJ5a3HcO4YWZk0M4e0E4p2UyOEsh/m29vB+E6RyGjYDCY+YASsYwzN+oYRtJfi73X4eyPoZ3rQvhZ/L0cDnwOeY00t8UG6Z2hoiTpjrg4KCmLvKBIU5AlO6hkgVCeDlvO/JYjZLsdYwf96AIVam0uah/C/JRQiJRocV8t4CcryCU7yYCIZnYsy/1YptDJCfqvy6eGDZcew0TmGtFIPnnWye2tRNmn+gbNpDqY2YhqB+IkQ/JuhCJvdDdgMobGfMjT7el2zDo9G93gjZ6/gwiAoCPlY5R3DpyAECHgpCmIRPMP1e5k9AWE9UggfnSEyX9+fL3uQGTOiULCanr34uk9hCHQreoV9K6ePiyAvZFJs2f0N0vWcVX0EAmOvigTjn4Uwr3A3WKcIDb8VtAzkmU6c6RgEBSFMpMyDZLNLlQ6KBDLKi8Ha3Cg6JUJoN1d6/hbxwMLd3gHlWS8RVkFI2w7F+NFaPr1KBvIURjnXgqR5NEpQ5tM5y+oYw0OZocQR+NI/4m6oLtIkhOCqUCj+Zq7CjMagKAgNVXYc7nUTqYZqoTzFUCdl/qVyTaWI3N6RN6HnWC0TVtHjpMxLyO5hdh/W7z2yM5TvXFDVuMHNUDYZ/RhnLcdw2NpND1p/cDdQJWGYtR22xWr8vUYPJk6LBOJHmEF7cVSzFpphK4nr6TBsDj1gfRrDsRNwz6XohX6HfLdU5uUhzd5EeXBVZiwGRUHahVgFx5c/vzAsFXAy9KEcPqdFKMaTGMZ9dc2C6h9MWg0nQx+8NWN2NUu05ZiL8ANCPg7BlwoxhP5p/P0uGeaRyLtaOiSRpiuFAmn2+aQMlWUI0mjmxj6Ub5mRmC4KQj5VsvUQgvD9gj3hFk78/xB6jKNrRTskpYMNcgAUo2bklFYo45gbqtk2QwZsDTTGlLthBIlhlnXU3F384852QMoiytSsh31loh5kxDPrjMN0UZBqoJkwCGRp3wiU4n6yd9yBImQQs1wp8/bifR0nx7yUi/IirI18sDBscgupNUlTtPF4OaRLNxB/S/w1EIBzC+V5hGJ7JBj3eYLOBExnBSnMdhnfg6BTAIZbaLdg1a82Iw8jHsL7ffC3HNanESJ/LS6yDGNOPOiftrWep3ULZukJxJpK0H7OXQ8IxjM0vcwsMwbTWUHyKf0sCPo1E2Pm7nypKoSNkjK+Rsa6TKA7SajT47IZu1lQjl9VNMbWfhnKEc0eI+V01wdDvPt67WrRb0xXBaHTZnPJ3TwboWSgoVY+qR8GxdgoE+ZuEG035uLLMEKJlLshiCCk/87JfYEZtD/uqZNm5aPh0bmcPCMw3W2QWshgyAXFKO1L6RTxkG4T8qYtwT/OOcY55KKC3x9ZkzZ3l7nawzC3r/c2hEW7qfruCoJeYyno50bI3hf/zjjXlJmoIGsWRN8JO+MXbqFujjAMc8y1UIDb8HspeoTToACH0h4V2sjljgXcEDBseS2E8EV3Q0QGZw2iptE23TGTFOTBsdhbs0nzvyHYVc80LHz9yVvXXJlNGTeA//y8ox8HA//A1anou8m5kmbGOMumUHWCgBbz3I0AZSEvxhktmIOCmaAghYM+zZMg+M9guLMVtB49wB15x1iWSRtnkP8WzSpRz1I8HrpdkBLRPpGsE6VA17Sv5TcoV36ADnoLWuEuK0jQvpyTFPqMmaAgFPCBfLNoIXFFg+4szYCUgcL4YJj1CSjiebQoib+VnsJ/rRrFBC/+Ik8jBOPHcZJCnzGTjfRWQLNeHDDioGxKPx/KcHsxCEMtQg9V3e/KCFpXeBohYNd20poBGMdXJxqMG7QGZGr20REtfooesL5Cbv6RgPUZXUu8zzDmdj1uklKQ6qAYW3TwJ3qDT2N4dCGGSndimNZ0dHcM4f6Hs5QDNscyTyMEEh/mpBkFWsk3g9ZBeB8/9i+YSmkK9tsEhPZcnn7uuN3WDQWJBO3FyOvuIpG3NifVw6xhLRGIzME7ClrnmIWNcLdRHnrQuh3pXZtlJGWg6IprUvqncmnjIgj2negdOrFouJrOT+di5MADXgoqN7yWOJiTZgTItR7PfTaInDDL76FZ0ux7IsEEucR0TFG6oSAQ5s+788THoOa+B+opjVD8RJS9ynOfi5Dn80uWdGaHKLnLk0t8Nq0flqP94465HNT5FXTHeGJ1KmpwsdUBm+Msz8Nq9pc4aVpjLr5KRsg6XtesZ9zP3wG6VQ/sNszFtIV+Kkhh+t86A71F7a0JoHYURNgNwitXBIW7G387sp+jJlGk+Ipg2FUBAfm3igdeyknTFhhGDuM5a+11mYIwrscQ6ic0nMA7+rIRsk/EfafBLrkM/9+L9K2S+5isF0DHoqi2epN+KYgZsOaD7yEPXw3qQA8yi06yyiajH86n9K9AiG/CEGoj7Aq5gLdBUMAtFBOYy60PjEF39zysZq3H5Wm7DmIErAMg+M+6n7lEmrUBdsjJ4XCCNvbUfAf8hf0o7rsZ5N8eANJD9nXtbA/oh4IYwcQX/R7dLtJs2pawVOQTju+jByw7FprrOaatE6CFO/LZghH9IQyHTsVX/0YIeFs+WVC4pzNj3hOz6oK21eKBPeNvchbk5GmFQm/pdacnguD9FX8/R8MuZm0K4fDIKITql5X5EuH68tiu897ArE2hxwoyC/mf50ljwvWt+LBcYYZtGpb09eO5Hkoz4ZgfEEqTMn4GwX+EVtgrlcFHjpGjgHGcTXPAV2FpxQu5BZenVS8C5TgMz+b70uP6dZGI/SZmawez0GN8DArhM/YhlPe2svuylwqC3zRRUb5eTr+OtkKImwcTs2hLbjYV3R/Dp5PR0/wUfze4lQP//3T9/t5g2E1B10b3lLycabPdVQ/Y+0G4vMMGzdrWDY9lfc7uISjd/Z6yCnQz9dbM1hB6pSAUS8BzTVy3/6aHEp5zzF9OEEqT1PeDwizGv+1/7PFCbqh4SS/Qghgnv2yh67uH8CyerzoE+CU9EO/aeg/1FhjK3e4uU5QbtM9ilobQIwX5Fb0P9zXwPBoMjnpOdeoGyM7IJaMLs46xDMOkSzBkOoW23NKRzrR7sPLAnb6CDC28LM8CGRrkWSOQ8Byc+HICrYgbWvx3Fc9EW3g/wixdAxnxELzfu8sGTVKwCmapi54oSCVRRJlgvP76QAfB8XovhIJs9Q6NyLPXeAi/f5tPmVdRzN1M0jgy4xj75pxIjBb5KCQRZ9N90FcVL6linG5NRoLWOdTgzPaygVQYQtYJnNx1vDO451t41qdUPuqUp0B8zFITvVYQ6knYEO8LaOEOCnF9o9O7ZJzDvtgMRbor6+j/wtl0FzTNh5clmba0NqKHOb4XPkidQGzX2BtQ76fczwAB+AWSejr5wNuHPTNn5EHNyTXRawUxNevLzNZX5NKRMfQo98qUokjkdwXl+Dl+H7I2HXod39ob4GUdWjkuLRIaaSsU5SY0+rG0hjKoPYseTJxZUe9nIpGRXTm5p0AvcrG7LqCnGpnV6qmCaPYDzU4idBMU9YRc1KEo69BTPJ6lU3Md88pMKvrFtWljb1lghZ4iHEi8Gw2Slb5ML01BYTCMsH4LI/RqNMAluHY2rp2O31+BDXAKudCbgfghwjsWSsWhRbs2dhRGsmb9zVPPBr/a3UAgYL2ehNtdH12L13Xp6aWC4Lo0mHS/US8UUF9Bh7agUb6E3oQW0nwvtS0iAdbse4xg/DvkQt7JrzuU9ShvWfYm8tbl5L6AFNRTp6C1BpdrfiR6qCB/RNK0WvfqKchdAkpyGBr1LrxM30p0h4iiKN5LaxNkP3DRLQH5eGaPIBTSE4x6Ce5FPPG+jFC8pttDDxVkRod47SjMdyTeRsGoIYTfxstegb+d9oYFkQepdVEssIfnnOxGQHsWKvKa7IavUCvQtcRl7rrh3fljMLnQCwXB/1tM039KlELnMDsOm2JYi+8Z1uwPmSHr0xDKo0wtfjSdKBWhma+QvQSNcRFslGvQyHdiuLGBBNfdUDIC/7NmSKx2N2yvwNbxrApDAAbmQHg8jydABuo2wUlS9KQH0ezGD4pR6B12LTT+HjSkgsLcBPKEHvIQ0kOhuQ1N5UEIv+++Vw+OnMRJfUcsFnsFhNztSTxZa9q8Nwoi3w+iMGAYmTOys67FvwAh+LOnAYsUsFY2clQbeB903zdo7jIQyF+768dB8aRQCqLgg9jpR7NQ0n3h1l21VqHFvZ4geNakae41UONrPBcddFp+poB1DCf5oBREoSpEtPmgfZ+nMQv0HWbxgfeXl3ghUD09NrkRROhIO3cdQ/Z5nOSDUhCFmqCvv65Zd3gaNGhPVdvQJU7g9fBaKzlpYKCHhL9buY6avYyTfFAKolAXBdvEyrsbFYJyJyd7EAnEEx6+oJyvnzC1+CJ3HSl8Dif5oBREoSGE59h7oTErHCgTcU4uga55eDS7tcPguwgjYO/rrqNSEIWOAML+c3fDoqF9q+O6PkKbo8o8mvUoJw0MaFuuu46gqlFklIIoNAxDix/oadig9VtOKqGwk6/c00AYttN6CycPBMTCqes5UMczOckHpSAKDYPcTtwNC/viKU5yYzZdd/OR9zCnDQRQp8vd9cOQ60hO8kEpiEIzmI0hk3ttZErmQ0Q9i4sHZB3FSQMBDBU9C5kUpI2TfFAKotAUIOye2SxynOSkEiBEnthO6FF+wkl9R3TO6C6oU3kIqFkv1dpwphREoSlAQf7kblzy3OWkEiAA+7t5IFTPDYodEtWsw911A93NSVIoBVFoCmjcR92NKwv4Vti74t13Yc6xDuLkvgIK7gkFhN7tPzlJCqUgCg2DegE07rZy41ovVdtDjbQfuIUAgnUHJ/UNw2FrN9TFvZYzxTGAq0IpiELDoN137obF1zfDST4YoVHHzUsUDSfezcl9AQSzwg1fhHetCaUgAwLybepFJL12gF7hQk/D1j5slGa8POE/9WD8Vlzvy75rCLaF+ns2iOkhez9OrgqlIAOAsJY4WLiIa/amMIYBfHmgQF66EHjP1t560REjQXvczU+kB+I9jzUrojsW9vK760LGeV1lVQrSZ0ApTsVLKo+LNetx/N2DkwcFs1CvH5XqKMjaSLvzOL0aZlUKJglYr2NjkSHurgNoSg+OvpeTa0IpSJ8BBaG94uWXJcjaMkhRvSmmVmUdaZsuJ9cEHe4CgfAGZobBTuGMmKWrQC+2AALomlggsq7g5LpQCjIAwAs72fPCCkQnuH47Hu9vLCnagkt1cdcN9V3RTARA2UcAz3b1+ND4TszSFaCcPSB8nuB1KHcdhf9hlrpQCjIgwIv6LK3qel6ceHn2WjYme2rc0rZalF0ZrpME7MlIZDTMbA2BbAAI1m8q84po1g8bGKa1BD048l6UUXmQzgsQzncxS0PwKYjc/6wpKAVpETSNipfnWYgrkhCwOkHOOgU6bgGCMOGvh7Wl1TrQEWh4Nn+emvV/MneVNjArEkgcgfdVccCnNUneyMzTMArH49GBoKW8JqNvqx+4ohaUgrQBsae7Yt+Fl6zlaPxPxmJjHQ1YLcLhhOIfhmLcKS1XszbXcuprBBQ8Dvn7I6Zo1uN6wP4YWNrqJUX+/kOIQNakGUwcwmxNA3n80Z0fnuE4TmoJSkHaxyxDSxyMF1k1Hi/StuDFXodh2WF8fl3TwhWNju5iBu1x5EHHKlcvS7MfMAJzo3xbW9B16+0Q2JXScqCctB0WbE0F1aYeCHmeA3rel69mvdju1DIJsDtPvI9nYnPsGCdLEQvEqkakVArSIVBXjsb4ptQ2qaTC9PAvhd2gWSfga/8ZCP9iI2wdEC4clXwoBPAkPWR9C79vBs9jpXurEMreijy+3mlHQ3KRp22usjIFafYaPRj/uqmNLiqEPvUY87PI10vsfZ8jQhNRwDvpkcl4b+t1Lb4n39cywuHd34E6eYLq4V0+jWunGKFEKkrnj9BmMjFlb/0Q6WtBNLEhna5XCtJh0HFceKnfx8uvmK7sDqGsbaZmX9XtY8AovjDK82yukpP1PIT9cSjsJiGY9YN3k3AupWATXFTbQLmVaymNkDSkqFKQLoGGUpGgfTZe8EbPC+4UafFHIIhn9vLIYfIGpl6toV6yAcK7+Z0Rst7D2XcSs2nWTVZmdbIm9UDCdy64UpAug2ZWCt164gx06/fgBbtnWRomNNQTuPfXES1+SiQwOm9oaEnvDmOsQOEA08QZqJN0Fq8OPY8v/LUYVjZ8OGdrWDLbLCya+s5h95Nok7vRC7+fby5BKUiPQeE+zeDICPlGURhN9DJfZVvjcijQMnydL6PogRjSnGwER8gWSfPUal8cB2tjyWzy+kUdT4Lg3ADKg9zj/yk80yYMt+7E81xAdlavQ5vSDkTU6aOgM+g4BROE+pyH9/wfZO+R9wC1CbP7QDOVtE+/SDRxwUkKHgwN/T/fvy7K4dvMgwAAAABJRU5ErkJggg==" /></p>
- </div>
- <div class="col-sm-9">
- {% if solr_status != false %}
- <div class="progress">
- <div class="progress-bar bg-info" role="progressbar" style="width:{{ solr_status.jvm.memory.raw['used%']|round }}%"></div>
- </div>
- <p>{{ lang.debug.jvm_memory_solr }}: {{ (solr_status.jvm.memory.total - solr_status.jvm.memory.free) }} / {{ solr_status.jvm.memory.total }}
- ({{ solr_status.jvm.memory.raw['used%']|round }}%)</p>
- <hr>
- <span class="d-block">{{ lang.debug.uptime }}: {{ solr_uptime }}h</span>
- <span class="d-block">{{ lang.debug.started_at }}: <span class="parse_date">{{ solr_status.status['dovecot-fts'].startTime }}</span></span>
- <span class="d-block">{{ lang.debug.last_modified }}: <span class="parse_date">{{ solr_status.status['dovecot-fts'].index.lastModified }}</span></span>
- <span class="d-block">{{ lang.debug.size }}: {{ solr_status.status['dovecot-fts'].index.size }}</span>
- <span class="d-block"><i class="bi bi-file-text"></i> {{ lang.debug.docs }}: {{ solr_status.status['dovecot-fts'].index.numDocs }}</span>
- {% else %}
- <span class="d-block">{{ lang.debug.solr_dead }}</span>
- {% endif %}
- </div>
- <div class="mt-4 col-sm-12 col-md-6 d-flex flex-column">
- <h6>Disk I/O</h6>
- <div class="spinner-border my-4 mx-auto" role="status">
- <span class="visually-hidden">Loading...</span>
- </div>
- <canvas class="d-none" id="solr-mailcow_DiskIOChart" width="400" height="200"></canvas>
- </div>
- <div class="mt-4 col-sm-12 col-md-6 d-flex flex-column">
- <h6>Net I/O</h6>
- <div class="spinner-border my-4 mx-auto" role="status">
- <span class="visually-hidden">Loading...</span>
- </div>
- <canvas class="d-none" id="solr-mailcow_NetIOChart" width="400" height="200"></canvas>
- </div>
- <div class="col-sm-12 d-flex" style="height: 40px">
- <a href data-bs-toggle="modal"
- data-container="solr-mailcow"
- data-bs-target="#RestartContainer"
- class="btn btn-sm btn-secondary d-flex align-items-center justify-content-center mb-2 ms-auto"
- style="height: 30px;">{{ lang.debug.restart_container }}
- <i class="ms-1 bi
- {% if containers["solr-mailcow"].State.Running == 1 %}
- bi-record-fill text-success
- {% elseif containers["solr-mailcow"].State %}
- bi-record-fill text-danger
- {% else %}
- default
- {% endif %}
- "
- ></i>
- </a>
- </div>
- </div>
- </div>
- {% endif %}
- </div>
- </div>
-
- <!-- rest of the containers -->
- {% for container, container_info in containers %}
- {% if container != "solr-mailcow" %}
- <div class="col-md-6 col-sm-12 p-2">
- <div class="list-group-item p-0">
- <div class="d-flex p-2 list-group-header">
- <div>
- <span class="fw-bold">{{ container }}</span>
- <span class="d-block d-md-inline">({{ container_info.Config.Image }})</span>
- <small class="d-block">({{ lang.debug.started_on }} <span class="parse_date">{{ container_info.State.StartedAtHR }}</span>)</small>
- {% if container_info.State.Running == 1 %}
- <span class="badge fs-7 bg-success loader" style="min-width:100px">
- {{ lang.debug.container_running }}
- <span class="loader-dot">.</span>
- <span class="loader-dot">.</span>
- <span class="loader-dot">.</span>
- </span>
- {% elseif container_info.State %}
- <span class="badge fs-7 bg-danger" style="min-width:100px">
- {{ lang.debug.container_stopped }}
- <i class="bi-x ms-1"></i>
- </span>
- {% endif %}
- </div>
- <div class="mt-auto ms-auto">
- <button class="btn btn-light" type="button" data-bs-toggle="collapse" data-bs-target="#{{ container }}Collapse" aria-expanded="false" aria-controls="{{ container }}Collapse">
- <i class="bi bi-caret-down-fill caret"></i>
- </button>
- </div>
- </div>
- <div class="collapse p-0 list-group-details container-details-collapse" id="{{ container }}Collapse" data-id="{{ container_info.Id }}">
- <div class="row p-2 pt-4">
- <div class="mt-4 col-sm-12 col-md-6 d-flex flex-column">
- <h6>Disk I/O</h6>
- <div class="spinner-border my-4 mx-auto" role="status">
- <span class="visually-hidden">Loading...</span>
- </div>
- <canvas class="d-none" id="{{ container }}_DiskIOChart" width="400" height="200"></canvas>
- </div>
- <div class="mt-4 col-sm-12 col-md-6 d-flex flex-column">
- <h6>Net I/O</h6>
- <div class="spinner-border my-4 mx-auto" role="status">
- <span class="visually-hidden">Loading...</span>
- </div>
- <canvas class="d-none" id="{{ container }}_NetIOChart" width="400" height="200"></canvas>
- </div>
- <div class="col-12 d-flex" style="height: 40px">
- <a href data-bs-toggle="modal"
- data-container="{{ container }}"
- data-bs-target="#RestartContainer"
- class="btn btn-sm btn-secondary d-flex align-items-center justify-content-center mb-2 ms-auto"
- style="height: 30px;">{{ lang.debug.restart_container }}
- <i class="ms-1 bi
- {% if container_info.State.Running == 1 %}
- bi-record-fill text-success
- {% elseif container_info.State %}
- bi-record-fill text-danger
- {% else %}
- default
- {% endif %}
- "
- ></i>
- </a>
- </div>
- </div>
- </div>
- </div>
- </div>
- {% endif %}
- {% endfor %}
- </div>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-postfix-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Postfix</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_postfix_logs" data-table="postfix_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="postfix_log" data-log-url="postfix" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="postfix_log" data-log-url="postfix" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="postfix_log" data-table="postfix_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="postfix_log" data-table="postfix_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="postfix_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-ui">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Mailcow UI</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_ui_logs" data-table="ui_logs">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="mailcow_ui" data-table="ui_logs" data-log-url="ui" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="mailcow_ui" data-table="ui_logs" data-log-url="ui" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="ui_logs" data-table="ui_logs" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="ui_logs" data-table="ui_logs" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="ui_logs" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-sasl">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">SASL</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_sasl_logs" data-table="sasl_logs">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="sasl_log_table" data-table="sasl_logs" data-log-url="ui" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="sasl_log_table" data-table="sasl_logs" data-log-url="ui" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="sasl_logs" data-table="sasl_logs" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="sasl_logs" data-table="sasl_logs" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="sasl_logs" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-dovecot-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Dovecot</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_dovecot_logs" data-table="dovecot_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="dovecot_log" data-log-url="dovecot" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="dovecot_log" data-log-url="dovecot" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="dovecot_log" data-table="dovecot_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="dovecot_log" data-table="dovecot_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="dovecot_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-sogo-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">SOGo</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_sogo_logs" data-table="sogo_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="sogo_log" data-log-url="sogo" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="sogo_log" data-log-url="sogo" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="sogo_log" data-table="sogo_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="sogo_log" data-table="sogo_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="sogo_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-netfilter-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Netfilter</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_netfilter_logs" data-table="netfilter_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="netfilter_log" data-log-url="netfilter" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="netfilter_log" data-log-url="netfilter" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="netfilter_log" data-table="netfilter_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="netfilter_log" data-table="netfilter_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="netfilter_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-rspamd-history">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Rspamd history</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_rspamd_history" data-table="rspamd_history">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <legend>{{ lang.debug.chart_this_server }}</legend><hr />
- <div id="chart-container">
- <canvas id="rspamd_donut" style="width:100%;height:400px"></canvas>
- </div>
- <legend>{{ lang.debug.history_all_servers }}</legend><hr />
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="rspamd_history" data-table="rspamd_history" data-log-url="rspamd-history" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="rspamd_history" data-table="rspamd_history" data-log-url="rspamd-history" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="rspamd_history" data-table="rspamd_history" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="rspamd_history" data-table="rspamd_history" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="rspamd_history" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-autodiscover-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Autodiscover</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_autodiscover_logs" data-table="autodiscover_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="autodiscover_log" data-table="autodiscover_log" data-log-url="autodiscover" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="autodiscover_log" data-table="autodiscover_log" data-log-url="autodiscover" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="autodiscover_log" data-table="autodiscover_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="autodiscover_log" data-table="autodiscover_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="autodiscover_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-watchdog-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Watchdog</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_watchdog_logs" data-table="watchdog_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="watchdog" data-table="watchdog_log" data-log-url="watchdog" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="watchdog" data-table="watchdog_log" data-log-url="watchdog" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="watchdog_log" data-table="watchdog_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="watchdog_log" data-table="watchdog_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="watchdog_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-acme-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">ACME</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_acme_logs" data-table="acme_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="acme_log" data-log-url="acme" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="general_syslog" data-table="acme_log" data-log-url="acme" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="acme_log" data-table="acme_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="acme_log" data-table="acme_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="acme_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-api-logs">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">API</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_api_logs" data-table="api_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="apilog" data-table="api_log" data-log-url="api" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="apilog" data-table="api_log" data-log-url="api" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="api_log" data-table="api_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="api_log" data-table="api_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <table id="api_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- <div role="tabpanel" class="tab-pane" id="tab-api-rl">
- <div class="debug-log-info">{{ lang.debug.log_info|format(log_lines+1)|raw }}</div>
- <div class="card">
- <div class="card-header d-flex align-items-center fs-5">
- <span class="mt-2 ms-2">Ratelimits</span>
- <div class="btn-group ms-auto">
- <button class="btn btn-sm btn-secondary refresh_table" data-draw="draw_rl_logs" data-table="rl_log">{{ lang.admin.refresh }}</button>
- </div>
- </div>
- <div class="card-body">
- <a class="btn btn-sm btn-secondary dropdown-toggle mb-4" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item add_log_lines" data-post-process="rllog" data-table="rl_log" data-log-url="ratelimited" data-nrows="100" href="#">+ 100</a></li>
- <li><a class="dropdown-item add_log_lines" data-post-process="rllog" data-table="rl_log" data-log-url="ratelimited" data-nrows="1000" href="#">+ 1000</a></li>
- <li class="table_collapse_option"><hr class="dropdown-divider"></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-expand="rl_log" data-table="rl_log" href="#">{{ lang.datatables.expand_all }}</a></li>
- <li class="table_collapse_option"><a class="dropdown-item" data-datatables-collapse="rl_log" data-table="rl_log" href="#">{{ lang.datatables.collapse_all }}</a></li>
- </ul>
- <p class="text-muted">{{ lang.admin.hash_remove_info|raw }}</p>
- <table id="rl_log" class="table table-striped dt-responsive w-100"></table>
- </div>
- </div>
- </div>
-
- </div> <!-- /tab-content -->
- </div> <!-- /col-md-12 -->
-</div> <!-- /row -->
-
-<script type='text/javascript'>
- var lang = {{ lang_admin|raw }};
- var lang_debug = {{ lang_debug|raw }};
- var lang_datatables = {{ lang_datatables|raw }};
- var csrf_token = '{{ csrf_token }}';
- var log_pagination_size = Math.trunc('{{ log_pagination_size }}');
-</script>
-{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/domainadmin.twig b/mailcow/src/mailcow-dockerized/data/web/templates/domainadmin.twig
index 070bf00..9cfd255 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/domainadmin.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/domainadmin.twig
@@ -1,80 +1,83 @@
{% extends 'base.twig' %}
{% block content %}
-<h3>{{ lang.user.user_settings }}</h3>
-<div class="card">
- <div class="card-header">{{ lang.user.user_settings }}</div>
- <div class="card-body">
- <div class="row">
- <div class="offset-sm-3 col-sm-9">
- <p><a href="#pwChangeModal" data-bs-toggle="modal">[{{ lang.user.change_password }}]</a></p>
- <div class="last-login"></div>
- <span class="clear-last-logins">{{ lang.user.clear_recent_successful_connections }}</span>
- </div>
- </div>
- <hr>
+<div class="row">
+ <div class="col-md-12">
+ <div class="card">
+ <div class="card-header">{{ lang.user.user_settings }}</div>
+ <div class="card-body">
+ <div class="row">
+ <div class="offset-sm-3 col-sm-9">
+ <p><a href="#pwChangeModal" data-bs-toggle="modal">[{{ lang.user.change_password }}]</a></p>
+ <div class="last-ui-login"></div>
+ <span class="clear-last-logins">{{ lang.user.clear_recent_successful_connections }}</span>
+ </div>
+ </div>
+ <hr>
- {# TFA #}
- <div class="row">
- <div class="col-sm-3 col-5 text-end">{{ lang.tfa.tfa }}</div>
- <div class="col-sm-9 col-7">
- <p id="tfa_pretty">{{ tfa_data.pretty }}</p>
- {% include 'tfa_keys.twig' %}
- <br>
- </div>
- </div>
- <div class="row">
- <div class="col-sm-3 col-5 text-end">{{ lang.tfa.set_tfa }}</div>
- <div class="col-sm-9 col-7">
- <select id="selectTFA" class="selectpicker" title="{{ lang.tfa.select }}">
- <option value="yubi_otp">{{ lang.tfa.yubi_otp }}</option>
- <option value="webauthn">{{ lang.tfa.webauthn }}</option>
- <option value="totp">{{ lang.tfa.totp }}</option>
- <option value="none">{{ lang.tfa.none }}</option>
- </select>
- </div>
- </div>
+ {# TFA #}
+ <div class="row">
+ <div class="col-sm-3 col-5 text-end">{{ lang.tfa.tfa }}</div>
+ <div class="col-sm-9 col-7">
+ <p id="tfa_pretty">{{ tfa_data.pretty }}</p>
+ {% include 'tfa_keys.twig' %}
+ <br>
+ </div>
+ </div>
+ <div class="row">
+ <div class="col-sm-3 col-5 text-end">{{ lang.tfa.set_tfa }}</div>
+ <div class="col-sm-9 col-7">
+ <select id="selectTFA" class="selectpicker" title="{{ lang.tfa.select }}">
+ <option value="yubi_otp">{{ lang.tfa.yubi_otp }}</option>
+ <option value="webauthn">{{ lang.tfa.webauthn }}</option>
+ <option value="totp">{{ lang.tfa.totp }}</option>
+ <option value="none">{{ lang.tfa.none }}</option>
+ </select>
+ </div>
+ </div>
- <hr>
- {# FIDO2 #}
- <div class="row">
- <div class="col-sm-3 col-5 text-end">
- <p><i class="bi bi-shield-fill-check"></i> {{ lang.fido2.fido2_auth }}</p>
- </div>
- </div>
- <div class="row">
- <div class="col-sm-3 col-5 text-end">{{ lang.fido2.known_ids }}:</div>
- <div class="col-sm-9 col-7">
- <div class="table-responsive">
- <table class="table table-striped table-hover table-condensed w-100" id="fido2_keys">
- <tr>
- <th>ID</th>
- <th style="min-width:240px;text-align: right">{{ lang.admin.action }}</th>
- </tr>
- {% include 'fido2.twig' %}
- </table>
- </div>
- <br>
- </div>
- </div>
- <div class="row">
- <div class="offset-sm-3 col-sm-9">
- <div class="btn-group">
- <button class="btn btn-sm btn-primary" id="register-fido2">{{ lang.fido2.set_fido2 }}</button>
- <button type="button" class="btn btn-sm btn-xs-lg btn-primary dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></button>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item" href="#" id="register-fido2-touchid"><i class="bi bi-shield-fill-check"></i> {{ lang.fido2.set_fido2_touchid }}</a></li>
- </ul>
+ <hr>
+ {# FIDO2 #}
+ <div class="row">
+ <div class="col-sm-3 col-5 text-end">
+ <p><i class="bi bi-shield-fill-check"></i> {{ lang.fido2.fido2_auth }}</p>
+ </div>
+ </div>
+ <div class="row">
+ <div class="col-sm-3 col-5 text-end">{{ lang.fido2.known_ids }}:</div>
+ <div class="col-sm-9 col-7">
+ <div class="table-responsive">
+ <table class="table table-striped table-hover table-condensed w-100" id="fido2_keys">
+ <tr>
+ <th>ID</th>
+ <th style="min-width:240px;text-align: right">{{ lang.admin.action }}</th>
+ </tr>
+ {% include 'fido2.twig' %}
+ </table>
+ </div>
+ <br>
</div>
</div>
- </div>
- <br>
- <div class="row" id="status-fido2">
- <div class="col-sm-3 col-5 text-end">{{ lang.fido2.register_status }}:</div>
- <div class="col-sm-9 col-7">
- <div id="fido2-alerts">-</div>
+ <div class="row">
+ <div class="offset-sm-3 col-sm-9">
+ <div class="btn-group">
+ <button class="btn btn-sm btn-primary" id="register-fido2">{{ lang.fido2.set_fido2 }}</button>
+ <button type="button" class="btn btn-sm btn-xs-lg btn-primary dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></button>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item" href="#" id="register-fido2-touchid"><i class="bi bi-shield-fill-check"></i> {{ lang.fido2.set_fido2_touchid }}</a></li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ <br>
+ <div class="row" id="status-fido2">
+ <div class="col-sm-3 col-5 text-end">{{ lang.fido2.register_status }}:</div>
+ <div class="col-sm-9 col-7">
+ <div id="fido2-alerts">-</div>
+ </div>
+ <br>
+ </div>
</div>
- <br>
</div>
</div>
</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/domainadmin_index.twig b/mailcow/src/mailcow-dockerized/data/web/templates/domainadmin_index.twig
new file mode 100644
index 0000000..b0d70c9
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/domainadmin_index.twig
@@ -0,0 +1,103 @@
+{% extends 'base.twig' %}
+
+{% block navbar %}{% endblock %}
+
+{% block content %}
+<div class="row mb-4" style="margin-top: 60px">
+ <div class="col-12 col-md-7 col-lg-6 col-xl-5 ms-auto me-auto">
+
+ <div class="card login-card login-domainadmin">
+ <div class="card-header d-flex align-items-center text-break">
+ <i class="bi bi-globe2 me-2"></i> {{ lang.login.login_dadmin }}
+ <div class="ms-auto form-check form-switch my-auto d-flex align-items-center">
+ <label class="form-check-label"><i class="bi bi-moon-fill"></i></label>
+ <input class="form-check-input ms-2" type="checkbox" id="dark-mode-toggle">
+ </div>
+ <div class="ms-4 d-grid d-sm-block">
+ <button type="button" {% if available_languages|length == 1 %}disabled="true"{% endif %} class="text-secondary btn p-0 border-0 bg-transparent ms-auto dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
+ <span class="flag-icon flag-icon-{{ mailcow_locale[-2:] }}"></span>
+ </button>
+ <ul class="dropdown-menu ms-auto login">
+ {% for key, val in available_languages %}
+ <li>
+ <a class="dropdown-item {% if mailcow_locale == key %}active{% endif %}" href="?{{ query_string({'lang': key}) }}">
+ <span class="flag-icon flag-icon-{{ key[-2:] }}"></span>{{ val }}
+ </a>
+ </li>
+ {% endfor %}
+ </ul>
+ </div>
+ </div>
+ <div class="card-body">
+ <div class="text-center mailcow-logo mb-4">
+ <img class="main-logo" src="{{ logo|default('/img/cow_mailcow.svg') }}" alt="mailcow">
+ <img class="main-logo-dark" src="{{ logo_dark|default('/img/cow_mailcow.svg') }}" alt="mailcow-logo-dark">
+ </div>
+ {% if ui_texts.ui_announcement_text and ui_texts.ui_announcement_active %}
+ <div class="my-4 alert alert-{{ ui_texts.ui_announcement_type }} rot-enc ui-announcement-alert">{{ ui_texts.ui_announcement_text|rot13 }}</div>
+ {% endif %}
+ <form method="post" autofill="off">
+ <div class="d-flex mt-3">
+ <label class="visually-hidden" for="login_user">{{ lang.login.username }}</label>
+ <div class="input-group">
+ <div class="input-group-text"><i class="bi bi-person-fill"></i></div>
+ <input name="login_user" autocorrect="off" autocapitalize="none" type="text" id="login_user" class="form-control" placeholder="{{ lang.login.username }}" required="" autofocus="" autocomplete="username">
+ </div>
+ </div>
+ <div class="d-flex mt-3">
+ <label class="visually-hidden" for="pass_user">{{ lang.login.password }}</label>
+ <div class="input-group">
+ <div class="input-group-text"><i class="bi bi-lock-fill"></i></div>
+ <input name="pass_user" type="password" id="pass_user" class="form-control" placeholder="{{ lang.login.password }}" required="" autocomplete="current-password">
+ <button type="button" class="input-group-text" style="cursor:pointer;" onclick="var i=document.getElementById('pass_user'),ic=this.querySelector('i');if(i.type==='password'){i.type='text';ic.className='bi bi-eye-slash';}else{i.type='password';ic.className='bi bi-eye';}" tabindex="-1" aria-label="Toggle password visibility"><i class="bi bi-eye"></i></button>
+ </div>
+ </div>
+ <div class="d-flex justify-content-between mt-4" style="position: relative">
+ <button type="submit" class="btn btn-xs-lg btn-success w-100 mt-2 mx-auto" style="max-width: 400px;" value="Login">{{ lang.login.login }}</button>
+ </div>
+ </form>
+ <div class="hr-title"><strong>{{ lang.login.other_logins }}</strong></div>
+ <div class="d-flex flex-column align-items-center">
+ <a class="btn btn-xs-lg btn-secondary w-100" style="max-width: 400px;" href="#" id="fido2-login"><i class="bi bi-shield-fill-check"></i> {{ lang.login.fido2_webauthn }}</a>
+ </div>
+ {% if login_delay %}
+ <p><div class="my-4 alert alert-info">{{ lang.login.delayed|format(login_delay) }}</b></div></p>
+ {% endif %}
+ <div class="my-4" id="fido2-alerts"></div>
+ {% if (mailcow_apps or app_links) and not hide_mailcow_apps %}
+ <legend><i class="bi bi-link-45deg"></i> {{ ui_texts.apps_name|raw }}</legend><hr />
+ <div class="my-2 apps">
+ {% for app in mailcow_apps %}
+ {% if not app.hide %}
+ {% if not skip_sogo or not is_uri('SOGo', app.link) %}
+ <div class="m-2">
+ <a href="{{ app.link }}" role="button" {% if app.description %}title="{{ app.description }}"{% endif %} class="btn btn-primary btn-block">{{ app.name }}</a>
+ </div>
+ {% endif %}
+ {% endif %}
+ {% endfor %}
+ {% for row in app_links %}
+ {% for key, val in row %}
+ {% if not val.hide %}
+ <div class="m-2">
+ <a href="{{ val.link }}" role="button" class="btn btn-primary btn-block">{{ key }}</a>
+ </div>
+ {% endif %}
+ {% endfor %}
+ {% endfor %}
+ </div>
+ {% endif %}
+ </div>
+ </div>
+
+ {% if custom_login.hide_user_quicklink != 1 or custom_login.hide_admin_quicklink != 1 %}
+ <p class="text-center mt-3 text-muted" style="font-size: 0.9rem;">
+ {{ lang.login.login_linkstext }}<br>
+ {% if custom_login.hide_user_quicklink != 1 %}<a href="/">{{ lang.login.login_usertext }}</a>{% endif %}
+ {% if custom_login.hide_user_quicklink != 1 and custom_login.hide_admin_quicklink != 1 %}|{% endif %}
+ {% if custom_login.hide_admin_quicklink != 1 %}<a href="/admin">{{ lang.login.login_admintext }}</a>{% endif %}
+ </p>
+ {% endif %}
+ </div>
+</div>
+{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/admin.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/admin.twig
index e2c6f66..d9cf4ae 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/admin.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/admin.twig
@@ -39,6 +39,24 @@
</div>
</div>
</div>
+ <div class="row mb-2">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <input type="hidden" value="0" name="force_tfa">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_tfa"{% if result.attributes.force_tfa == '1' %} checked{% endif %}> {{ lang.tfa.force_tfa }}</label>
+ <small class="text-muted d-block">{{ lang.tfa.force_tfa_info }}</small>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <input type="hidden" value="0" name="force_pw_update">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_pw_update"{% if result.attributes.force_pw_update == '1' %} checked{% endif %}> {{ lang.edit.force_pw_update }}</label>
+ <small class="text-muted d-block">{{ lang.edit.force_pw_update_info|format(ui_texts.main_name) }}</small>
+ </div>
+ </div>
+ </div>
<div class="row">
<div class="offset-sm-2 col-sm-10">
<button class="btn btn-xs-lg d-block d-sm-inline btn-success" data-action="edit_selected" data-api-reload-location="/admin" data-id="editadmin" data-item="{{ admin }}" data-api-url='edit/admin' data-api-attr='{}' href="#">{{ lang.edit.save }}</button>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/alias.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/alias.twig
index 48d1961..85a946b 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/alias.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/alias.twig
@@ -6,6 +6,8 @@
<br>
<form class="form-horizontal" data-id="editalias" role="form" method="post">
<input type="hidden" value="0" name="active">
+ <input type="hidden" value="0" name="internal">
+ <input type="hidden" value="0" name="sender_allowed">
{% if not skip_sogo %}
<input type="hidden" value="0" name="sogo_visible">
{% endif %}
@@ -33,8 +35,16 @@
<div class="form-check">
<label><input type="checkbox" class="form-check-input" value="1" name="sogo_visible"{% if result.sogo_visible == '1' %} checked{% endif %}> {{ lang.edit.sogo_visible }}</label>
</div>
- <p class="text-muted">{{ lang.edit.sogo_visible_info }}</p>
+ <small class="text-muted d-block mb-2">{{ lang.edit.sogo_visible_info }}</small>
{% endif %}
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="internal"{% if result.internal == '1' %} checked{% endif %}> {{ lang.edit.internal }}</label>
+ </div>
+ <small class="text-muted d-block mb-2">{{ lang.edit.internal_info }}</small>
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="sender_allowed"{% if result.sender_allowed == '1' %} checked{% endif %}> {{ lang.edit.sender_allowed }}</label>
+ </div>
+ <small class="text-muted d-block">{{ lang.edit.sender_allowed_info }}</small>
</div>
</div>
<hr>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/app-passwd.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/app-passwd.twig
index 46dc648..efab887 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/app-passwd.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/app-passwd.twig
@@ -13,15 +13,15 @@
</div>
</div>
<div class="row mb-2">
- <label class="control-label col-sm-2" for="password">{{ lang.edit.password }} (<a href="#" class="generate_password">{{ lang.edit.generate }}</a>)</label>
+ <label class="control-label col-sm-2" for="app_passwd">{{ lang.edit.password }} (<a href="#" class="generate_password">{{ lang.edit.generate }}</a>)</label>
<div class="col-sm-10">
- <input type="password" data-pwgen-field="true" data-hibp="true" class="form-control" name="password" placeholder="" autocomplete="new-password">
+ <input type="password" data-pwgen-field="true" data-hibp="true" class="form-control" name="app_passwd" placeholder="" autocomplete="new-password">
</div>
</div>
<div class="row mb-4">
- <label class="control-label col-sm-2" for="password2">{{ lang.edit.password_repeat }}</label>
+ <label class="control-label col-sm-2" for="app_passwd2">{{ lang.edit.password_repeat }}</label>
<div class="col-sm-10">
- <input type="password" data-pwgen-field="true" class="form-control" name="password2" autocomplete="new-password">
+ <input type="password" data-pwgen-field="true" class="form-control" name="app_passwd2" autocomplete="new-password">
</div>
</div>
<div class="row mb-2">
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain-templates.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain-templates.twig
index 825e667..d4612a1 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain-templates.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain-templates.twig
@@ -103,6 +103,8 @@
<select data-style="btn btn-light" class="form-control" id="key_size" name="key_size">
<option value="1024" data-subtext="bits" {% if template.attributes.key_size == 1024 %} selected{% endif %}>1024</option>
<option value="2048" data-subtext="bits" {% if template.attributes.key_size == 2048 %} selected{% endif %}>2048</option>
+ <option value="3072" data-subtext="bits" {% if template.attributes.key_size == 3072 %} selected{% endif %}>3072</option>
+ <option value="4096" data-subtext="bits" {% if template.attributes.key_size == 4096 %} selected{% endif %}>4096</option>
</select>
</div>
</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain.twig
index 6d1d85c..45ec654 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/domain.twig
@@ -8,6 +8,7 @@
<li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#dratelimit">{{ lang.edit.ratelimit }}</button></li>
<li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#dspamfilter">{{ lang.edit.spam_filter }}</button></li>
<li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#dqwbcc">{{ lang.edit.quota_warning_bcc }}</button></li>
+ <li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#dmtasts">{{ lang.edit.mta_sts }}</button></li>
<li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#dfooter">{{ lang.edit.domain_footer }}</button></li>
</ul>
<hr class="d-none d-md-block">
@@ -38,7 +39,7 @@
<div class="row mb-2" data-acl="{{ acl.domain_desc }}">
<label class="control-label col-sm-2" for="description">{{ lang.edit.description }}</label>
<div class="col-sm-10">
- <input type="text" class="form-control" name="description" value="{{ result.description }}">
+ <input type="text" class="form-control" name="description" value="{{ result.description }}"{% if acl.domain_desc == '0' %} readonly{% endif %}>
</div>
</div>
<div class="row mb-4">
@@ -57,6 +58,7 @@
</div>
</div>
</div>
+ {% if acl.domain_relayhost == '1' %}
<div class="row mb-2">
<label class="control-label col-sm-2" for="relayhost">{{ lang.edit.relayhost }}</label>
<div class="col-sm-10">
@@ -75,6 +77,7 @@
</select>
</div>
</div>
+ {% endif %}
{% if mailcow_cc_role == 'admin' %}
<div class="row mb-2">
<label class="control-label col-sm-2" for="aliases">{{ lang.edit.max_aliases }}</label>
@@ -146,7 +149,7 @@
<div class="row">
<div class="offset-sm-2 col-sm-10">
<small class="fst-italic d-block">{{ lang.edit.created_on }}: {{ result.created }}</small>
- <small class="fst-italic d-block">{{ lang.edit.last_modified }}: {{ result.modified }}</small>
+ <small class="fst-italic d-block">{{ lang.edit.last_modified }}: {{ result.modified|default(lang.user.never) }}</small>
</div>
</div>
</form>
@@ -278,6 +281,82 @@
</div>
</div>
</div>
+ <div id="dmtasts" class="tab-pane fade" role="tabpanel" aria-labelledby="domain-mtasts">
+ <div class="card mb-4">
+ <div class="card-header d-flex d-md-none fs-5">
+ <button class="btn flex-grow-1 text-start" data-bs-target="#collapse-tab-mtasts" data-bs-toggle="collapse" aria-controls="collapse-tab-mtasts">
+ {{ lang.edit.mta_sts }} <span class="badge bg-info table-lines"></span>
+ </button>
+ </div>
+ <div id="collapse-tab-mtasts" class="card-body collapse" data-bs-parent="#domain-content">
+ <h4>{{ lang.edit.mta_sts }}</h4>
+ <p>{{ lang.edit.mta_sts_info|raw }}</p>
+ <form data-id="dommtasts" method="post">
+ <input type="hidden" value="0" name="active">
+ <input type="hidden" value="{{ domain }}" name="domain">
+ <div class="row mb-2">
+ <label class="control-label col-sm-2" for="version">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill m-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.edit.mta_sts_version_info|raw }}"></i>
+ {{ lang.edit.mta_sts_version }}
+ </label>
+ <div class="col-sm-10">
+ <select data-style="btn btn-light" class="form-control" name="version" title="" required>
+ <option value="stsv1"{% if mta_sts.version == 'STSv1' %} selected{% endif %}>STSv1</option>
+ </select>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <label class="control-label col-sm-2" for="mode">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill m-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.edit.mta_sts_mode_info|raw }}"></i>
+ {{ lang.edit.mta_sts_mode }}
+ </label>
+ <div class="col-sm-10">
+ <select data-style="btn btn-light" class="form-control" name="mode" title="" required>
+ <option value="enforce"{% if mta_sts.mode == 'enforce' %} selected{% endif %}>enforce</option>
+ <option value="testing"{% if mta_sts.mode == 'testing' %} selected{% endif %}>testing</option>
+ <option value="none"{% if mta_sts.mode == 'none' %} selected{% endif %}>none</option>
+ </select>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <label class="control-label col-sm-2" for="max_age">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill m-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.edit.mta_sts_max_age_info|raw }}"></i>
+ {{ lang.edit.mta_sts_max_age }}
+ </label>
+ <div class="col-sm-10">
+ <input type="number" class="form-control" name="max_age" value="{{ mta_sts.max_age }}">
+ </div>
+ </div>
+ <div class="row mb-2">
+ <label class="control-label col-sm-2" for="mx">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill m-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.edit.mta_sts_mx_info|raw }}"></i>
+ {{ lang.edit.mta_sts_mx }}
+ </label>
+ <div class="col-sm-10">
+ <textarea autocorrect="off" autocapitalize="none" class="form-control" rows="5" name="mx">{{ mta_sts.mx }}</textarea>
+ <small class="text-muted">{{ lang.edit.mta_sts_mx_notice|raw }}</small>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <label><i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill m-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.edit.mta_sts_active_info|raw }}"></i><input type="checkbox" class="form-check-input" value="1" name="active"{% if mta_sts.active == '1' %} checked{% endif %}> {{ lang.edit.active }}</label>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="offset-sm-2 col-sm-10">
+ {% if mta_sts == false %}
+ <button class="btn btn-xs-lg d-block d-sm-inline btn-secondary" data-action="add_item" data-id="dommtasts" data-item="{{ domain }}" data-api-url='add/mta-sts' data-api-attr='{}' href="#">{{ lang.admin.save }}</button>
+ {% else %}
+ <button class="btn btn-xs-lg d-block d-sm-inline btn-secondary" data-action="edit_selected" data-id="dommtasts" data-item="{{ domain }}" data-api-url='edit/mta-sts' data-api-attr='{}' href="#">{{ lang.admin.save }}</button>
+ {% endif %}
+ </div>
+ </div>
+ </form>
+ </div>
+ </div>
+ </div>
<div id="dfooter" class="tab-pane fade" role="tabpanel" aria-labelledby="domain-footer">
<div class="card mb-4">
<div class="card-header d-flex d-md-none fs-5">
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/domainadmin.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/domainadmin.twig
index 2c40faa..b3e0198 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/domainadmin.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/domainadmin.twig
@@ -52,6 +52,24 @@
</div>
</div>
</div>
+ <div class="row mb-2">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <input type="hidden" value="0" name="force_tfa">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_tfa"{% if result.attributes.force_tfa == '1' %} checked{% endif %}> {{ lang.tfa.force_tfa }}</label>
+ <small class="text-muted d-block">{{ lang.tfa.force_tfa_info }}</small>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <input type="hidden" value="0" name="force_pw_update">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_pw_update"{% if result.attributes.force_pw_update == '1' %} checked{% endif %}> {{ lang.edit.force_pw_update }}</label>
+ <small class="text-muted d-block">{{ lang.edit.force_pw_update_info|format(ui_texts.main_name) }}</small>
+ </div>
+ </div>
+ </div>
<div class="row mb-4">
<div class="offset-sm-2 col-sm-10">
<button class="btn btn-xs-lg d-block d-sm-inline btn-success" data-action="edit_selected" data-api-reload-location="/admin" data-id="editdomainadmin" data-item="{{ domain_admin }}" data-api-url='edit/domain-admin' data-api-attr='{}' href="#">{{ lang.edit.save }}</button>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/filter.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/filter.twig
index 124ecaf..743f088 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/filter.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/filter.twig
@@ -23,7 +23,7 @@
<div class="row mb-4">
<label class="control-label col-sm-2" for="script_data">Script:</label>
<div class="col-sm-10">
- <textarea spellcheck="false" autocorrect="off" autocapitalize="none" class="form-control textarea-code" rows="20" id="script_data" name="script_data" required>{{ result.script_data|raw }}</textarea>
+ <textarea spellcheck="false" autocorrect="off" autocapitalize="none" class="form-control textarea-code" rows="20" id="script_data" name="script_data" required>{{ result.script_data }}</textarea>
</div>
</div>
<div class="row mb-2">
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox-templates.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox-templates.twig
index f606bd4..8384fa0 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox-templates.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox-templates.twig
@@ -8,6 +8,7 @@
<input type="hidden" value="default" name="sender_acl">
<input type="hidden" value="0" name="force_pw_update">
+ <input type="hidden" value="0" name="force_tfa">
<input type="hidden" value="0" name="sogo_access">
<input type="hidden" value="0" name="protocol_access">
@@ -37,6 +38,23 @@
</div>
</div>
<div class="row mb-2">
+ <label class="control-label col-sm-2">{{ lang.user.tag_handling }}</label>
+ <div class="col-sm-10">
+ <div class="btn-group">
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="tagged_mail_handler_subfolder" autocomplete="off" value="subfolder" {% if template.attributes.tagged_mail_handler == 'subfolder' %}checked{% endif %}>
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="tagged_mail_handler_subfolder">{{ lang.user.tag_in_subfolder }}</label>
+
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="tagged_mail_handler_subject" autocomplete="off" value="subject" {% if template.attributes.tagged_mail_handler == 'subject' %}checked{% endif %}>
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="tagged_mail_handler_subject">{{ lang.user.tag_in_subject }}</label>
+
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="tagged_mail_handler_none" autocomplete="off" value="none" {% if template.attributes.tagged_mail_handler == 'none' %}checked{% endif %}>
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="tagged_mail_handler_none">{{ lang.user.tag_in_none }}</label>
+ </div>
+ <p class="text-muted"><small>{{ lang.user.tag_help_explain|raw }}</small></p>
+ <p class="text-muted"><small>{{ lang.user.tag_help_example|raw }}</small></p>
+ </div>
+ </div>
+ <div class="row mb-2">
<label class="control-label col-sm-2">{{ lang.user.quarantine_notification }}</label>
<div class="col-sm-10">
<div class="btn-group">
@@ -91,6 +109,8 @@
<option value="pop3"{% if template.attributes.pop3_access == '1' %} selected{% endif %}>POP3</option>
<option value="smtp"{% if template.attributes.smtp_access == '1' %} selected{% endif %}>SMTP</option>
<option value="sieve"{% if template.attributes.sieve_access == '1' %} selected{% endif %}>Sieve</option>
+ <option value="eas"{% if template.attributes.eas_access == '1' %} selected{% endif %}>ActiveSync</option>
+ <option value="dav"{% if template.attributes.dav_access == '1' %} selected{% endif %}>CalDAV/CardDAV</option>
</select>
</div>
</div>
@@ -112,6 +132,7 @@
<option value="quarantine_notification" {% if template.attributes.acl_quarantine_notification == '1' %} selected{% endif %}>{{ lang.acl["quarantine_notification"] }}</option>
<option value="quarantine_category" {% if template.attributes.acl_quarantine_category == '1' %} selected{% endif %}>{{ lang.acl["quarantine_category"] }}</option>
<option value="app_passwds" {% if template.attributes.acl_app_passwds == '1' %} selected{% endif %}>{{ lang.acl["app_passwds"] }}</option>
+ <option value="pw_reset" {% if template.attributes.acl_pw_reset == '1' %} selected{% endif %}>{{ lang.acl["pw_reset"] }}</option>
</select>
</div>
</div>
@@ -145,6 +166,14 @@
</div>
</div>
</div>
+ <div class="row">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_tfa" id="force_tfa"{% if template.attributes.force_tfa == '1' %} checked{% endif %}> {{ lang.tfa.force_tfa }}</label>
+ <small class="text-muted">{{ lang.tfa.force_tfa_info }}</small>
+ </div>
+ </div>
+ </div>
{% if not skip_sogo %}
<div class="row">
<div class="offset-sm-2 col-sm-10">
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox.twig b/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox.twig
index 8960ee9..db258fe 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/edit/mailbox.twig
@@ -9,6 +9,7 @@
<li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#mpushover">{{ lang.edit.pushover }}</button></li>
<li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#macl">{{ lang.edit.acl }}</button></li>
<li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#mrl">{{ lang.edit.ratelimit }}</button></li>
+ <li role="presentation" class="nav-item"><button class="nav-link" data-bs-toggle="tab" data-bs-target="#mrename">⚠️ {{ lang.edit.mailbox_rename }}</button></li>
</ul>
<hr class="d-none d-md-block">
<div class="tab-content">
@@ -23,9 +24,29 @@
<form class="form-horizontal" data-id="editmailbox" role="form" method="post">
<input type="hidden" value="default" name="sender_acl">
<input type="hidden" value="0" name="force_pw_update">
+ <input type="hidden" value="0" name="force_tfa">
<input type="hidden" value="0" name="sogo_access">
<input type="hidden" value="0" name="protocol_access">
<div class="row mb-2">
+ <label class="control-label col-sm-2">{{ lang.admin.iam }}</label>
+ <div class="col-sm-10">
+ <select
+ data-style="btn btn-secondary"
+ name="authsource" class="full-width-select form-control" required>
+ <option value="mailcow" {% if result.authsource == "mailcow" %}selected{% endif %}>mailcow</option>
+ {% if iam_settings.authsource == 'keycloak' %}
+ <option value="keycloak" {% if result.authsource == "keycloak" %}selected{% endif %}>Keycloak</option>
+ {% endif %}
+ {% if iam_settings.authsource == 'generic-oidc' %}
+ <option value="generic-oidc" {% if result.authsource == "generic-oidc" %}selected{% endif %}>Generic-OIDC</option>
+ {% endif %}
+ {% if iam_settings.authsource == 'ldap' %}
+ <option value="ldap" {% if result.authsource == "ldap" %}selected{% endif %}>LDAP</option>
+ {% endif %}
+ </select>
+ </div>
+ </div>
+ <div class="row mb-2">
<label class="control-label col-sm-2" for="name">{{ lang.edit.full_name }}</label>
<div class="col-sm-10">
<input type="text" class="form-control" name="name" value="{{ result.name }}">
@@ -65,14 +86,6 @@
{{ lang.edit.dont_check_sender_acl|format(domain) }}
</option>
{% endfor %}
- {% for alias in sender_acl_handles.sender_acl_addresses.ro %}
- <option data-subtext="Admin" disabled selected>
- {{ alias }}
- </option>
- {% endfor %}
- {% for alias in sender_acl_handles.fixed_sender_aliases %}
- <option data-subtext="Alias" disabled selected>{{ alias }}</option>
- {% endfor %}
{% for domain in sender_acl_handles.sender_acl_domains.rw %}
<option value="{{ domain }}" selected>
{{ lang.edit.dont_check_sender_acl|format(domain) }}
@@ -84,20 +97,35 @@
</option>
{% endfor %}
{% for address in sender_acl_handles.sender_acl_addresses.rw %}
- <option selected>{{ address }}</option>
+ {% if address in sender_acl_handles.fixed_sender_aliases_allowed or address in sender_acl_handles.fixed_sender_aliases_blocked %}
+ <option data-subtext="Alias" selected>{{ address }}</option>
+ {% else %}
+ <option selected>{{ address }}</option>
+ {% endif %}
{% endfor %}
{% for address in sender_acl_handles.sender_acl_addresses.selectable %}
<option>{{ address }}</option>
{% endfor %}
+ {% for alias in sender_acl_handles.fixed_sender_aliases_allowed %}
+ {% if alias not in sender_acl_handles.sender_acl_addresses.rw %}
+ <option data-subtext="Alias (allowed)" value="{{ alias }}" selected>{{ alias }}</option>
+ {% endif %}
+ {% endfor %}
+ {% for alias in sender_acl_handles.fixed_sender_aliases_blocked %}
+ {% if alias not in sender_acl_handles.sender_acl_addresses.rw %}
+ <option data-subtext="Alias (blocked)" value="{{ alias }}">{{ alias }}</option>
+ {% endif %}
+ {% endfor %}
</select>
<div id="sender_acl_disabled"><i class="bi bi-shield-exclamation"></i> {{ lang.edit.sender_acl_disabled|raw }}</div>
<small class="text-muted d-block">{{ lang.edit.sender_acl_info|raw }}</small>
</div>
</div>
+ {% if acl.mailbox_relayhost == '1' %}
<div class="row mb-2">
<label class="control-label col-sm-2" for="relayhost">{{ lang.edit.relayhost }}</label>
<div class="col-sm-10">
- <select data-acl="{{ acl.mailbox_relayhost }}" data-live-search="true" id="relayhost" name="relayhost" class="form-control mb-4">
+ <select data-acl="{{ acl.mailbox_relayhost }}" data-live-search="true" id="relayhost" name="relayhost" class="form-control">
{% for rlyhost in rlyhosts %}
<option
style="{% if rlyhost.active != '1' %}background: #ff4136; color: #fff{% endif %}"
@@ -111,7 +139,35 @@
</option>
</select>
<p class="d-block d-sm-none" style="margin: 0;padding: 0"> </p>
- <small class="text-muted d-block">{{ lang.edit.mailbox_relayhost_info }}</small>
+ <small class="text-muted d-block mb-4">{{ lang.edit.mailbox_relayhost_info }}</small>
+ </div>
+ </div>
+ {% endif %}
+ <div class="row mb-2">
+ <label class="control-label col-sm-2">{{ lang.user.tag_handling }}</label>
+ <div class="col-sm-10">
+ <div class="btn-group" data-acl="{{ acl.delimiter_action }}">
+ <button type="button" class="btn btn-sm btn-xs-third d-block d-sm-inline{% if get_tagging_options == 'subfolder' %} btn-dark{% else %} btn-light{% endif %}"
+ data-action="edit_selected"
+ data-item="{{ mailbox }}"
+ data-id="delimiter_action"
+ data-api-url='edit/delimiter_action'
+ data-api-attr='{"tagged_mail_handler":"subfolder"}'>{{ lang.user.tag_in_subfolder }}</button>
+ <button type="button" class="btn btn-sm btn-xs-third d-block d-sm-inline{% if get_tagging_options == 'subject' %} btn-dark{% else %} btn-light{% endif %}"
+ data-action="edit_selected"
+ data-item="{{ mailbox }}"
+ data-id="delimiter_action"
+ data-api-url='edit/delimiter_action'
+ data-api-attr='{"tagged_mail_handler":"subject"}'>{{ lang.user.tag_in_subject }}</button>
+ <button type="button" class="btn btn-sm btn-xs-third d-block d-sm-inline{% if get_tagging_options == 'none' %} btn-dark{% else %} btn-light{% endif %}"
+ data-action="edit_selected"
+ data-item="{{ mailbox }}"
+ data-id="delimiter_action"
+ data-api-url='edit/delimiter_action'
+ data-api-attr='{"tagged_mail_handler":"none"}'>{{ lang.user.tag_in_none }}</button>
+ </div>
+ <p class="text-muted"><small>{{ lang.user.tag_help_explain|raw }}</small></p>
+ <p class="text-muted"><small>{{ lang.user.tag_help_example|raw }}</small></p>
</div>
</div>
<div class="row mb-2">
@@ -191,6 +247,7 @@
</div>
</div>
</div>
+ {% if not result.authsource or result.authsource == 'mailcow' %}
<div class="row">
<label class="control-label col-sm-2" for="password">{{ lang.edit.password }} (<a href="#" class="generate_password">{{ lang.edit.generate }}</a>)</label>
<div class="col-sm-10">
@@ -203,6 +260,14 @@
<input type="password" data-pwgen-field="true" class="form-control" name="password2" autocomplete="new-password">
</div>
</div>
+ <div class="row mb-4">
+ <label class="control-label col-sm-2" for="pw_recovery_email">{{ lang.edit.password_recovery_email }}</label>
+ <div class="col-sm-10">
+ <input type="email" class="form-control" name="pw_recovery_email" value="{{ result.attributes.recovery_email }}">
+ <small class="text-muted">{{ lang.admin.password_reset_info }}</small>
+ </div>
+ </div>
+ {% endif %}
<div data-acl="{{ acl.extend_sender_acl }}" class="row mb-4">
<label class="control-label col-sm-2" for="extended_sender_acl">{{ lang.edit.extended_sender_acl }}</label>
<div class="col-sm-10">
@@ -223,6 +288,8 @@
<option value="pop3"{% if result.attributes.pop3_access == '1' %} selected{% endif %}>POP3</option>
<option value="smtp"{% if result.attributes.smtp_access == '1' %} selected{% endif %}>SMTP</option>
<option value="sieve"{% if result.attributes.sieve_access == '1' %} selected{% endif %}>Sieve</option>
+ <option value="eas"{% if result.attributes.eas_access == '1' %} selected{% endif %}>ActiveSync</option>
+ <option value="dav"{% if result.attributes.dav_access == '1' %} selected{% endif %}>CalDAV/CardDAV</option>
</select>
</div>
</div>
@@ -251,6 +318,14 @@
</div>
</div>
</div>
+ <div class="row">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_tfa"{% if result.attributes.force_tfa == '1' %} checked{% endif %}> {{ lang.tfa.force_tfa }}</label>
+ <small class="text-muted">{{ lang.tfa.force_tfa_info }}</small>
+ </div>
+ </div>
+ </div>
{% if not skip_sogo %}
<div data-acl="{{ acl.sogo_access }}" class="row">
<div class="offset-sm-2 col-sm-10">
@@ -269,7 +344,7 @@
<div class="row">
<div class="offset-sm-2 col-sm-10">
<small class="fst-italic d-block">{{ lang.edit.created_on }}: {{ result.created }}</small>
- <small class="fst-italic d-block">{{ lang.edit.last_modified }}: {{ result.modified }}</small>
+ <small class="fst-italic d-block">{{ lang.edit.last_modified }}: {{ result.modified|default(lang.user.never) }}</small>
</div>
</div>
</form>
@@ -280,10 +355,10 @@
<div class="card mb-4">
<div class="card-header d-flex d-md-none fs-5">
<button class="btn flex-grow-1 text-start" data-bs-target="#collapse-tab-mattr" data-bs-toggle="collapse" aria-controls="collapse-tab-mattr">
- {{ lang.edit.mailbox }} <span class="badge bg-info table-lines"></span>
+ {{ lang.edit.custom_attributes }} <span class="badge bg-info table-lines"></span>
</button>
</div>
- <div id="collapse-tab-mattr" class="card-body collapse show" data-bs-parent="#mailbox-content">
+ <div id="collapse-tab-mattr" class="card-body collapse" data-bs-parent="#mailbox-content">
<form class="form-inline" data-id="mbox_attr" role="form" method="post">
<table class="table table-condensed" style="white-space: nowrap;" id="mbox_attr_table">
<tr>
@@ -458,10 +533,10 @@
{% include 'mailbox/rl-frame.twig' %}
</select>
</div>
- </div>
+ </div>
</div>
<div class="row mb-2">
- <div class="offset-sm-2 col-sm-10">
+ <div class="offset-sm-2 col-sm-10">
<button class="btn btn-xs-lg d-block d-sm-inline btn-secondary" data-action="edit_selected" data-id="mboxratelimit" data-item="{{ mailbox }}" data-api-url='edit/rl-mbox' data-api-attr='{}' href="#">{{ lang.edit.save }}</button>
<p class="text-muted mt-2">{{ lang.edit.mbox_rl_info }}</p>
</div>
@@ -470,6 +545,58 @@
</div>
</div>
</div>
+ <div id="mrename" class="tab-pane fade" role="tabpanel" aria-labelledby="mailbox-rename">
+ <div class="card mb-4">
+ <div class="card-header d-flex d-md-none fs-5">
+ <button class="btn flex-grow-1 text-start" data-bs-target="#collapse-tab-mrename" data-bs-toggle="collapse" aria-controls="collapse-tab-mrename">
+ ⚠️ {{ lang.edit.mailbox_rename }}<span class="badge bg-info table-lines"></span>
+ </button>
+ </div>
+ <div id="collapse-tab-mrename" class="card-body collapse" data-bs-parent="#mailbox-content">
+ <div class="well">
+ <div id="rename_warning">
+ <p>{{ lang.edit.mailbox_rename_warning }}</p>
+ <div id="confirm_show_rspamd_global_filters">
+ <div class="row">
+ <div class="offset-sm-2 col-sm-10">
+ <label>
+ <input type="checkbox" class="form-check-input" id="show_mailbox_rename_form"> {{ lang.edit.mailbox_rename_agree }}
+ </label>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="rename_form" class="d-none">
+ <form data-id="mboxrename" method="post">
+ <input name="domain" type="hidden" value="{{ result.domain }}">
+ <input name="old_local_part" type="hidden" value="{{ result.local_part }}">
+ <div class="row mb-2">
+ <div class="col-sm-12 col-md-2">
+ <span>{{ lang.edit.mailbox_rename_title }}</span>
+ </div>
+ <div class="col-sm-12 col-md-10 col-xl-8">
+ <div class="input-group mb-2">
+ <input type="text" class="form-control" name="new_local_part" autocomplete="off" value="{{ result.local_part }}">
+ <span class="input-group-text">@{{ result.domain }}</span>
+ </div>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <div class="col-sm-12 offset-md-2 col-md-10 col-xl-8">
+ <label><input type="checkbox" class="form-check-input" value="1" name="create_alias" checked> {{ lang.edit.mailbox_rename_alias }}</label>
+ </div>
+ </div>
+ <div class="row mb-2">
+ <div class="col-sm-12 offset-md-2 col-md-10 col-xl-8">
+ <button class="btn btn-xs-lg d-block d-sm-inline btn-secondary" data-action="edit_selected" data-id="mboxrename" data-item="{{ mailbox }}" data-api-url='edit/rename-mbox' data-api-attr='{}' data-api-reload-location="/{{mailcow_cc_role}}/mailbox" href="#">{{ lang.edit.save }}</button>
+ </div>
+ </div>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
</div>
</div>
{% else %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/index.twig b/mailcow/src/mailcow-dockerized/data/web/templates/index.twig
deleted file mode 100644
index aa28254..0000000
--- a/mailcow/src/mailcow-dockerized/data/web/templates/index.twig
+++ /dev/null
@@ -1,112 +0,0 @@
-{% extends 'base.twig' %}
-
-{% block navbar %}{% endblock %}
-
-{% block content %}
-<div class="row mb-4" style="margin-top: 60px">
- <div class="col-12 col-md-7 col-lg-6 col-xl-5 ms-auto me-auto">
- <div class="card">
- <div class="card-header d-flex align-items-center">
- <i class="bi bi-person-fill me-2"></i> {{ lang.login.login }}
- <div class="ms-auto form-check form-switch my-auto d-flex align-items-center">
- <label class="form-check-label"><i class="bi bi-moon-fill"></i></label>
- <input class="form-check-input ms-2" type="checkbox" id="dark-mode-toggle">
- </div>
- </div>
- <div class="card-body">
- <div class="text-center mailcow-logo mb-4">
- <img class="main-logo" src="{{ logo|default('/img/cow_mailcow.svg') }}" alt="mailcow">
- <img class="main-logo-dark" src="{{ logo_dark|default('/img/cow_mailcow.svg') }}" alt="mailcow-logo-dark">
- </div>
- {% if ui_texts.ui_announcement_text and ui_texts.ui_announcement_active %}
- <div class="my-4 alert alert-{{ ui_texts.ui_announcement_type }} rot-enc ui-announcement-alert">{{ ui_texts.ui_announcement_text|rot13 }}</div>
- {% endif %}
- <legend>{% if oauth2_request %}{{ lang.oauth2.authorize_app }}{% else %}{{ ui_texts.main_name|raw }}{% endif %}</legend><hr />
- {% if is_mobileconfig %}
- <div class="my-4 alert alert-info ">{{ lang.login.mobileconfig_info }}</div>
- {% endif %}
- <form method="post" autofill="off">
- <div class="d-flex mt-3">
- <label class="visually-hidden" for="login_user">{{ lang.login.username }}</label>
- <div class="input-group">
- <div class="input-group-text"><i class="bi bi-person-fill"></i></div>
- <input name="login_user" autocorrect="off" autocapitalize="none" type="{% if is_mobileconfig %}email{% else %}text{% endif %}" id="login_user" class="form-control" placeholder="{{ lang.login.username }}" required="" autofocus="" autocomplete="username">
- </div>
- </div>
- <div class="d-flex mt-3">
- <label class="visually-hidden" for="pass_user">{{ lang.login.password }}</label>
- <div class="input-group">
- <div class="input-group-text"><i class="bi bi-lock-fill"></i></div>
- <input name="pass_user" type="password" id="pass_user" class="form-control" placeholder="{{ lang.login.password }}" required="" autocomplete="current-password">
- </div>
- </div>
- <div class="d-flex justify-content-between mt-4" style="position: relative">
- <div class="d-grid gap-2 d-sm-block">
- <button type="submit" class="btn btn-xs-lg btn-success" value="Login">{{ lang.login.login }}</button>
- <button type="button" class="btn btn-xs-lg btn-success" id="fido2-login"><i class="bi bi-shield-fill-check"></i> {{ lang.login.fido2_webauthn }}</button>
- </div>
- {% if not oauth2_request %}
- <div class="d-grid d-sm-block">
- <button type="button" {% if available_languages|length == 1 %}disabled="true"{% endif %} class="btn btn-secondary ms-auto dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
- <span class="flag-icon flag-icon-{{ mailcow_locale[-2:] }}"></span>
- </button>
- <ul class="dropdown-menu ms-auto login">
- {% for key, val in available_languages %}
- <li>
- <a class="dropdown-item {% if mailcow_locale == key %}active{% endif %}" href="?{{ query_string({'lang': key}) }}">
- <span class="flag-icon flag-icon-{{ key[-2:] }}"></span>{{ val }}
- </a>
- </li>
- {% endfor %}
- </ul>
- </div>
- {% endif %}
- </div>
- </form>
- {% if login_delay %}
- <p><div class="my-4 alert alert-info">{{ lang.login.delayed|format(login_delay) }}</b></div></p>
- {% endif %}
- <div class="my-4" id="fido2-alerts"></div>
- {% if not oauth2_request and (mailcow_apps or app_links) %}
- <legend><i class="bi bi-link-45deg"></i> {{ ui_texts.apps_name|raw }}</legend><hr />
- <div class="my-2 d-grid gap-2 d-sm-block apps">
- {% for app in mailcow_apps %}
- {% if not skip_sogo or not is_uri('SOGo', app.link) %}
- <a href="{{ app.link }}" role="button" {% if app.description %}title="{{ app.description }}"{% endif %} class="btn btn-primary">{{ app.name }}</a>
- {% endif %}
- {% endfor %}
- {% for row in app_links %}
- {% for key, val in row %}
- <a href="{{ val }}" role="button" class="btn btn-primary">{{ key }}</a>
- {% endfor %}
- {% endfor %}
- </div>
- {% endif %}
- </div>
- </div>
- </div>
-</div>
-{% if not oauth2_request %}
-<div class="row">
- <div class="col-12 col-md-7 col-lg-6 col-xl-5 ms-auto me-auto">
- <div class="card">
- <div class="card-header">
- <a class="btn btn-link" data-bs-toggle="collapse" href="#collapse1"><i class="bi bi-patch-question-fill"></i> {{ lang.start.help }}</a>
- </div>
- <div id="collapse1" class="card-collapse collapse">
- <div class="card-body">
- {% if ui_texts.help_text %}
- <p>{{ ui_texts.help_text|raw }}</p>
- {% else %}
- <p><span style="border-bottom: 1px dotted #999;">{{ ui_texts.main_name|raw }}</span></p>
- <p>{{ lang.start.mailcow_panel_detail|raw }}</p>
- <p><span style="border-bottom: 1px dotted #999;">{{ ui_texts.apps_name|raw }}</span></p>
- <p>{{ lang.start.mailcow_apps_detail|raw }}</p>
- {% endif %}
- </div>
- </div>
- </div>
- </div>
- {% endif %}
-</div>
-{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/mailbox.twig b/mailcow/src/mailcow-dockerized/data/web/templates/mailbox.twig
index b61896d..1265d00 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/mailbox.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/mailbox.twig
@@ -7,12 +7,12 @@
<li class="nav-item dropdown" role="presentation">
<a class="nav-link dropdown-toggle active" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.domains }}</a>
<ul class="dropdown-menu">
- <li><button class="dropdown-item" aria-selected="false" aria-controls="tab-domains" role="tab" data-bs-toggle="tab" data-bs-target="#tab-domains">{{ lang.mailbox.domains }}</button></li>
+ <li><button class="dropdown-item active" aria-selected="true" aria-controls="tab-domains" role="tab" data-bs-toggle="tab" data-bs-target="#tab-domains">{{ lang.mailbox.domains }}</button></li>
<li><button class="dropdown-item" aria-selected="false" aria-controls="tab-templates-domains" role="tab" data-bs-toggle="tab" data-bs-target="#tab-templates-domains">{{ lang.mailbox.templates }}</button></li>
</ul>
</li>
{% else %}
- <li class="nav-item" role="presentation"><button class="nav-link" aria-controls="tab-domains" role="tab" data-bs-toggle="tab" data-bs-target="#tab-domains">{{ lang.mailbox.domains }}</button></li>
+ <li class="nav-item" role="presentation"><button class="nav-link active" aria-selected="true" aria-controls="tab-domains" role="tab" data-bs-toggle="tab" data-bs-target="#tab-domains">{{ lang.mailbox.domains }}</button></li>
{% endif %}
{% if mailcow_cc_role == 'admin' %}
<li class="nav-item dropdown" role="presentation">
@@ -68,6 +68,7 @@
var acl = '{{ acl_json|raw }}';
var lang = {{ lang_mailbox|raw }};
var lang_rl = {{ lang_rl|raw }};
+ var lang_edit = {{ lang_edit|raw }};
var lang_datatables = {{ lang_datatables|raw }};
var csrf_token = '{{ csrf_token }}';
var pagination_size = Math.trunc('{{ pagination_size }}');
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/mailbox/tab-mailboxes.twig b/mailcow/src/mailcow-dockerized/data/web/templates/mailbox/tab-mailboxes.twig
index fce7d62..6a176cd 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/mailbox/tab-mailboxes.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/mailbox/tab-mailboxes.twig
@@ -58,6 +58,14 @@
<li class="dropdown-header">Sieve</li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"sieve_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"sieve_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
+ <li class="dropdown-header">ActiveSync (EAS)</li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"eas_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"eas_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
+ <li class="dropdown-header">CalDAV/CardDAV (DAV)</li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"dav_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"dav_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
</ul>
<a class="btn btn-sm btn-success" href="#" data-bs-toggle="modal" data-bs-target="#addMailboxModal"><i class="bi bi-plus-lg"></i> {{ lang.mailbox.add_mailbox }}</a>
</div>
@@ -104,9 +112,18 @@
<li class="dropdown-header">SMTP</li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"smtp_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"smtp_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
<li class="dropdown-header">Sieve</li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"sieve_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"sieve_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
+ <li class="dropdown-header">ActiveSync (EAS)</li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"eas_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"eas_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
+ <li class="dropdown-header">CalDAV/CardDAV (DAV)</li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"dav_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"dav_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
</ul>
</div>
<div class="btn-group">
@@ -218,9 +235,18 @@
<li class="dropdown-header">SMTP</li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"smtp_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"smtp_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
<li class="dropdown-header">Sieve</li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"sieve_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"sieve_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
+ <li class="dropdown-header">ActiveSync (EAS)</li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"eas_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"eas_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
+ <li><hr class="dropdown-divider"></li>
+ <li class="dropdown-header">CalDAV/CardDAV (DAV)</li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"dav_access":1}' href="#">{{ lang.mailbox.activate }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="mailbox" data-api-url='edit/mailbox' data-api-attr='{"dav_access":0}' href="#">{{ lang.mailbox.deactivate }}</a></li>
</ul>
</div>
<div class="btn-group">
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/modals/footer.twig b/mailcow/src/mailcow-dockerized/data/web/templates/modals/footer.twig
index 8ff112d..b39544a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/modals/footer.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/modals/footer.twig
@@ -311,6 +311,135 @@
</div>
</div>
{% endif %}
+{% if pending_tfa_setup %}
+<div class="modal fade" id="SetupTFAModal" tabindex="-1" role="dialog" aria-labelledby="SetupTFAModalLabel">
+ <div class="modal-dialog" role="document">
+ <div class="modal-content">
+ <div class="modal-header">
+ <h3 class="modal-title">{{ lang.tfa.setup_title }}</h3>
+ <form method="post" class="d-inline">
+ <button type="submit" name="logout" value="1" class="btn-close" aria-label="Close"></button>
+ </form>
+ </div>
+ <div class="modal-body">
+ <div class="alert alert-warning">
+ <i class="bi bi-shield-exclamation"></i> {{ lang.tfa.setup_required }}
+ </div>
+ <ul class="nav nav-tabs mb-3" id="setupTFATabNav">
+ <li class="nav-item">
+ <a class="nav-link active" href="#setup_tab_totp" data-bs-toggle="tab"><i class="bi bi-clock-history"></i> Time-based OTP</a>
+ </li>
+ <li class="nav-item">
+ <a class="nav-link" href="#setup_tab_webauthn" data-bs-toggle="tab"><i class="bi bi-fingerprint"></i> WebAuthn</a>
+ </li>
+ <li class="nav-item">
+ <a class="nav-link" href="#setup_tab_yubi" data-bs-toggle="tab"><i class="bi bi-usb-drive"></i> Yubi OTP</a>
+ </li>
+ </ul>
+ <div class="tab-content">
+ <div role="tabpanel" class="tab-pane active" id="setup_tab_totp">
+ <form role="form" method="post" id="setup_totp_form">
+ <div class="mb-2">
+ <input type="text" class="form-control" name="key_id" placeholder="{{ lang.tfa.key_id_totp }}" autocomplete="off" required>
+ </div>
+ <hr>
+ <input type="hidden" value="{{ totp_secret }}" name="totp_secret">
+ <input type="hidden" name="tfa_method" value="totp">
+ <ol class="mb-4">
+ <li>
+ <p>{{ lang.tfa.scan_qr_code }}</p>
+ <img id="setup-tfa-qr-img" data-totp-secret="{{ totp_secret }}" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII=">
+ <p class="text-muted">{{ lang.tfa.enter_qr_code }}:<br />
+ <code>{{ totp_secret }}</code>
+ </p>
+ </li>
+ <li>
+ <p>{{ lang.tfa.confirm_totp_token }}:</p>
+ <p><input type="number" style="width:33%" class="form-control" name="totp_confirm_token" autocomplete="off" required></p>
+ <p><button class="btn btn-sm d-block d-sm-inline btn-success" type="submit" name="set_tfa">{{ lang.tfa.confirm }}</button></p>
+ </li>
+ </ol>
+ </form>
+ </div>
+ <div role="tabpanel" class="tab-pane" id="setup_tab_webauthn">
+ <form class="d-flex flex-column" role="form" method="post" id="setup_webauthn_reg_form">
+ <div class="mb-2">
+ <input type="text" class="form-control" name="key_id" placeholder="{{ lang.tfa.key_id }}" autocomplete="off" required>
+ </div>
+ <hr>
+ <div class="text-center">
+ <div style="cursor:pointer" id="start_setup_webauthn_register">
+ <i class="bi bi-fingerprint" style="font-size:4rem"></i>
+ <p>{{ lang.tfa.start_webauthn_validation }}</p>
+ </div>
+ </div>
+ <hr>
+ <p id="setup_webauthn_status_reg"></p>
+ <div class="alert alert-danger" style="display:none" id="setup_webauthn_return_code"></div>
+ <input type="hidden" name="token" id="setup_webauthn_register_data"/>
+ <input type="hidden" name="tfa_method" value="webauthn">
+ <input type="hidden" name="set_tfa"/><br/>
+ </form>
+ </div>
+ <div role="tabpanel" class="tab-pane" id="setup_tab_yubi">
+ <form role="form" method="post">
+ <div class="mb-4">
+ <input type="text" class="form-control" name="key_id" placeholder="{{ lang.tfa.key_id }}" autocomplete="off" required>
+ </div>
+ <hr>
+ <p class="text-muted">{{ lang.tfa.api_register|format(ui_texts.main_name)|raw }}</p>
+ <div class="mb-2">
+ <input type="text" class="form-control" name="yubico_id" placeholder="Yubico API ID" autocomplete="off" required>
+ </div>
+ <div class="mb-4">
+ <input type="text" class="form-control" name="yubico_key" placeholder="Yubico API Key" autocomplete="off" required>
+ </div>
+ <hr>
+ <div class="mb-4">
+ <div class="input-group">
+ <span class="input-group-text" id="yubi-setup-addon"><img alt="Yubicon Icon" src="/img/yubi.ico"></span>
+ <input type="text" name="otp_token" class="form-control" placeholder="Touch Yubikey" aria-describedby="yubi-setup-addon">
+ <input type="hidden" name="tfa_method" value="yubi_otp">
+ </div>
+ </div>
+ <button class="btn btn-sm d-block d-sm-inline btn-success" type="submit" name="set_tfa">{{ lang.user.save_changes }}</button>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+</div>
+{% endif %}
+{% if pending_pw_update_modal and not pending_tfa_methods %}
+<div class="modal fade" id="ChangePWModal" tabindex="-1" role="dialog" aria-labelledby="ChangePWModalLabel">
+ <div class="modal-dialog" role="document">
+ <div class="modal-content">
+ <div class="modal-header">
+ <h3 class="modal-title">{{ lang.user.change_password }}</h3>
+ <form method="post" class="d-inline">
+ <button type="submit" name="logout" value="1" class="btn-close" aria-label="Close"></button>
+ </form>
+ </div>
+ <div class="modal-body">
+ <div class="alert alert-warning">
+ <i class="bi bi-key"></i> {{ lang.user.pw_update_required }}
+ </div>
+ <form role="form" id="changePWModalForm">
+ <div class="mb-3">
+ <input type="password" class="form-control" id="changePWNew" placeholder="{{ lang.user.new_password }}" autocomplete="new-password" required>
+ </div>
+ <div class="mb-4">
+ <input type="password" class="form-control" id="changePWNew2" placeholder="{{ lang.user.new_password_repeat }}" autocomplete="new-password" required>
+ </div>
+ <div id="changePWAlert" class="alert alert-danger" style="display:none"></div>
+ <button class="btn btn-sm btn-success" type="submit">{{ lang.user.save_changes }}</button>
+ </form>
+ </div>
+ </div>
+ </div>
+</div>
+{% endif %}
{% if mailcow_cc_role == 'admin' %}
<div id="RestartContainer" class="modal fade" role="dialog">
<div class="modal-dialog">
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/modals/mailbox.twig b/mailcow/src/mailcow-dockerized/data/web/templates/modals/mailbox.twig
index 6316d9f..924d88c 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/modals/mailbox.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/modals/mailbox.twig
@@ -9,8 +9,10 @@
<div class="modal-body">
<form class="form-horizontal" data-cached-form="true" data-id="add_mailbox" role="form" autocomplete="off">
<input type="hidden" value="0" name="force_pw_update">
+ <input type="hidden" value="0" name="force_tfa">
<input type="hidden" value="0" name="sogo_access">
<input type="hidden" value="0" name="protocol_access">
+ <input type="hidden" value="mailcow" name="authsource">
<div class="row mb-2">
<label class="control-label col-sm-2 text-sm-end text-sm-end" for="local_part">{{ lang.add.mailbox_username }}</label>
@@ -19,6 +21,12 @@
</div>
</div>
<div class="row mb-2">
+ <label class="control-label col-sm-2 text-sm-end text-sm-end" for="name">{{ lang.add.full_name }}</label>
+ <div class="col-sm-10">
+ <input type="text" class="form-control" name="name">
+ </div>
+ </div>
+ <div class="row mb-2">
<label class="control-label col-sm-2 text-sm-end text-sm-end" for="domain">{{ lang.add.domain }}</label>
<div class="col-sm-10">
<select class="full-width-select" data-live-search="true" id="addSelectDomain" name="domain" required>
@@ -29,30 +37,26 @@
</div>
</div>
<div class="row mb-4">
- <label class="control-label col-sm-2 text-sm-end text-sm-end" for="name">{{ lang.add.full_name }}</label>
- <div class="col-sm-10">
- <input type="text" class="form-control" name="name">
- </div>
- </div>
- <div class="row mb-2">
- <label class="control-label col-sm-2 text-sm-end text-sm-end" for="password">{{ lang.add.password }} (<a href="#" class="generate_password">{{ lang.add.generate }}</a>)</label>
- <div class="col-sm-10">
- <input type="password" data-pwgen-field="true" data-hibp="true" class="form-control" name="password" placeholder="" autocomplete="new-password" required>
- </div>
- </div>
- <div class="row mb-4">
- <label class="control-label col-sm-2 text-sm-end text-sm-end" for="password2">{{ lang.add.password_repeat }}</label>
- <div class="col-sm-10">
- <input type="password" data-pwgen-field="true" class="form-control" name="password2" placeholder="" autocomplete="new-password" required>
- </div>
- </div>
- <div class="row mb-2">
<label class="control-label col-sm-2 text-sm-end text-sm-end" for="description">{{ lang.mailbox.template }}</label>
<div class="col-sm-10">
<select data-live-search="true" id="mailbox_templates" class="form-control" title="{{ lang.mailbox.template }}">
</select>
</div>
</div>
+ <div id="mbox_add_pwds">
+ <div class="row mb-2">
+ <label class="control-label col-sm-2 text-sm-end text-sm-end" for="password">{{ lang.add.password }} (<a href="#" class="generate_password">{{ lang.add.generate }}</a>)</label>
+ <div class="col-sm-10">
+ <input type="password" data-pwgen-field="true" data-hibp="true" class="form-control" name="password" placeholder="" autocomplete="new-password" required>
+ </div>
+ </div>
+ <div class="row mb-4">
+ <label class="control-label col-sm-2 text-sm-end text-sm-end" for="password2">{{ lang.add.password_repeat }}</label>
+ <div class="col-sm-10">
+ <input type="password" data-pwgen-field="true" class="form-control" name="password2" placeholder="" autocomplete="new-password" required>
+ </div>
+ </div>
+ </div>
<div class="row mb-2">
<label class="control-label col-sm-2 text-sm-end text-sm-end">{{ lang.add.tags }}</label>
<div class="col-sm-10">
@@ -74,6 +78,23 @@
</div>
</div>
<div class="row mb-2">
+ <label class="control-label col-sm-2 text-sm-end text-sm-end">{{ lang.user.tag_handling }}</label>
+ <div class="col-sm-10">
+ <div class="btn-group">
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="tagged_mail_handler_subfolder" autocomplete="off" value="subfolder">
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="tagged_mail_handler_subfolder">{{ lang.user.tag_in_subfolder }}</label>
+
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="tagged_mail_handler_subject" autocomplete="off" value="subject">
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="tagged_mail_handler_subject">{{ lang.user.tag_in_subject }}</label>
+
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="tagged_mail_handler_none" autocomplete="off" value="none">
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="tagged_mail_handler_none">{{ lang.user.tag_in_none }}</label>
+ </div>
+ <p class="text-muted"><small>{{ lang.user.tag_help_explain|raw }}</small></p>
+ <p class="text-muted"><small>{{ lang.user.tag_help_example|raw }}</small></p>
+ </div>
+ </div>
+ <div class="row mb-2">
<label class="control-label col-sm-2 text-sm-end text-sm-end">{{ lang.user.quarantine_notification }}</label>
<div class="col-sm-10">
<div class="btn-group">
@@ -128,6 +149,8 @@
<option value="pop3">POP3</option>
<option value="smtp">SMTP</option>
<option value="sieve">Sieve</option>
+ <option value="eas">ActiveSync</option>
+ <option value="dav">CalDAV/CardDAV</option>
</select>
</div>
</div>
@@ -149,6 +172,7 @@
<option value="quarantine_notification" selected>{{ lang.acl["quarantine_notification"] }}</option>
<option value="quarantine_category" selected>{{ lang.acl["quarantine_category"] }}</option>
<option value="app_passwds" selected>{{ lang.acl["app_passwds"] }}</option>
+ <option value="pw_reset" selected>{{ lang.acl["pw_reset"] }}</option>
</select>
</div>
</div>
@@ -181,6 +205,14 @@
</div>
</div>
</div>
+ <div class="row">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_tfa" id="force_tfa"> {{ lang.tfa.force_tfa }}</label>
+ <small class="text-muted">{{ lang.tfa.force_tfa_info }}</small>
+ </div>
+ </div>
+ </div>
{% if not skip_sogo %}
<div class="row">
<div class="offset-sm-2 col-sm-10">
@@ -214,6 +246,7 @@
<form class="form-horizontal" data-id="addmailbox_template" role="form" method="post">
<input type="hidden" value="default" name="sender_acl">
<input type="hidden" value="0" name="force_pw_update">
+ <input type="hidden" value="0" name="force_tfa">
<input type="hidden" value="0" name="sogo_access">
<input type="hidden" value="0" name="protocol_access">
@@ -243,6 +276,23 @@
</div>
</div>
<div class="row mb-2">
+ <label class="control-label col-sm-2 text-sm-end text-sm-end">{{ lang.user.tag_handling }}</label>
+ <div class="col-sm-10">
+ <div class="btn-group">
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="template_tagged_mail_handler_subfolder" autocomplete="off" value="subfolder">
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="template_tagged_mail_handler_subfolder">{{ lang.user.tag_in_subfolder }}</label>
+
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="template_tagged_mail_handler_subject" autocomplete="off" value="subject">
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="template_tagged_mail_handler_subject">{{ lang.user.tag_in_subject }}</label>
+
+ <input type="radio" class="btn-check" name="tagged_mail_handler" id="template_tagged_mail_handler_none" autocomplete="off" value="none">
+ <label class="btn btn-sm btn-xs-quart d-block d-sm-inline btn-light" for="template_tagged_mail_handler_none">{{ lang.user.tag_in_none }}</label>
+ </div>
+ <p class="text-muted"><small>{{ lang.user.tag_help_explain|raw }}</small></p>
+ <p class="text-muted"><small>{{ lang.user.tag_help_example|raw }}</small></p>
+ </div>
+ </div>
+ <div class="row mb-2">
<label class="control-label col-sm-2 text-sm-end text-sm-end">{{ lang.user.quarantine_notification }}</label>
<div class="col-sm-10">
<div class="btn-group">
@@ -297,6 +347,8 @@
<option value="pop3" selected>POP3</option>
<option value="smtp" selected>SMTP</option>
<option value="sieve" selected>Sieve</option>
+ <option value="activesync" selected>ActiveSync</option>
+ <option value="dav" selected>CalDAV/CardDAV</option>
</select>
</div>
</div>
@@ -318,6 +370,7 @@
<option value="quarantine_notification" selected>{{ lang.acl["quarantine_notification"] }}</option>
<option value="quarantine_category" selected>{{ lang.acl["quarantine_category"] }}</option>
<option value="app_passwds" selected>{{ lang.acl["app_passwds"] }}</option>
+ <option value="pw_reset" selected>{{ lang.acl["pw_reset"] }}</option>
</select>
</div>
</div>
@@ -351,6 +404,14 @@
</div>
</div>
</div>
+ <div class="row">
+ <div class="offset-sm-2 col-sm-10">
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="force_tfa"> {{ lang.tfa.force_tfa }}</label>
+ <small class="text-muted">{{ lang.tfa.force_tfa_info }}</small>
+ </div>
+ </div>
+ </div>
{% if not skip_sogo %}
<div class="row">
<div class="offset-sm-2 col-sm-10">
@@ -488,6 +549,8 @@
<select data-style="btn btn-light" class="form-control" id="key_size" name="key_size">
<option data-subtext="bits" value="1024">1024</option>
<option data-subtext="bits" value="2048" selected>2048</option>
+ <option data-subtext="bits" value="3072">3072</option>
+ <option data-subtext="bits" value="4096">4096</option>
</select>
</div>
</div>
@@ -626,6 +689,8 @@
<select data-style="btn btn-light" class="form-control" id="key_size" name="key_size">
<option data-subtext="bits">1024</option>
<option data-subtext="bits" selected>2048</option>
+ <option data-subtext="bits">3072</option>
+ <option data-subtext="bits">4096</option>
</select>
</div>
</div>
@@ -734,6 +799,8 @@
<div class="modal-body">
<form class="form-horizontal" data-cached-form="true" role="form" data-id="add_alias">
<input type="hidden" value="0" name="active">
+ <input type="hidden" value="0" name="internal">
+ <input type="hidden" value="0" name="sender_allowed">
<div class="row mb-2">
<label class="control-label col-sm-2 text-sm-end" for="address">{{ lang.add.alias_address }}</label>
<div class="col-sm-10">
@@ -760,11 +827,19 @@
<div class="form-check">
<label><input type="checkbox" class="form-check-input" value="1" name="sogo_visible" checked> {{ lang.edit.sogo_visible }}</label>
</div>
- <p class="text-muted">{{ lang.edit.sogo_visible_info }}</p>
+ <small class="text-muted d-block mb-2">{{ lang.edit.sogo_visible_info }}</small>
{% endif %}
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="internal"> {{ lang.add.internal }}</label>
+ </div>
+ <small class="text-muted d-block mb-2">{{ lang.edit.internal_info }}</small>
+ <div class="form-check">
+ <label><input type="checkbox" class="form-check-input" value="1" name="sender_allowed" checked> {{ lang.add.sender_allowed }}</label>
+ </div>
+ <small class="text-muted d-block">{{ lang.edit.sender_allowed_info }}</small>
</div>
</div>
- <div class="row mb-2">
+ <div class="row mb-4">
<div class="offset-sm-2 col-sm-10">
<div class="form-check">
<label><input type="checkbox" class="form-check-input" value="1" name="active" checked> {{ lang.add.active }}</label>
@@ -841,6 +916,8 @@
<select data-style="btn btn-light" class="form-control" id="key_size2" name="key_size">
<option data-subtext="bits">1024</option>
<option data-subtext="bits" selected>2048</option>
+ <option data-subtext="bits">3072</option>
+ <option data-subtext="bits">4096</option>
</select>
</div>
</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/modals/user.twig b/mailcow/src/mailcow-dockerized/data/web/templates/modals/user.twig
index b418877..41f173a 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/modals/user.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/modals/user.twig
@@ -309,35 +309,59 @@
</div>
</div>
</div><!-- pw change modal -->
-<!-- temp alias modal -->
-<div class="modal fade" id="tempAliasModal" tabindex="-1" role="dialog" aria-labelledby="tempAliasModalLabel">
+<!-- pw recovery email modal -->
+<div class="modal fade" id="pwRecoveryEmailModal" tabindex="-1" role="dialog" aria-labelledby="pwRecoveryEmailModalLabel">
<div class="modal-dialog modal-lg" role="document">
<div class="modal-content">
+ <div class="modal-header">
+ <h3 class="modal-title">{{ lang.user.pw_recovery_email }}</h3>
+ <button type="button" class="btn-close" data-bs-dismiss="modal"></button>
+ </div>
<div class="modal-body">
- <form class="form-horizontal" data-cached-form="false" data-id="pwchange" role="form" method="post" autocomplete="off">
- <div class="row">
- <label class="control-label col-sm-3" for="user_new_pass">{{ lang.user.new_password }} (<a href="#" class="generate_password">{{ lang.user.generate }}</a>)</label>
- <div class="col-sm-5">
- <input type="password" data-pwgen-field="true" data-hibp="true" class="form-control" name="user_new_pass" autocomplete="new-password" required>
+ <form class="form-horizontal" data-cached-form="false" data-id="pw_recovery_change" role="form" method="post" autocomplete="off">
+ <div class="row mb-4">
+ <label class="control-label col-sm-3" for="pw_recovery_email">{{ lang.user.email }}</label>
+ <div class="col-sm-9">
+ <input type="email" class="form-control" name="pw_recovery_email" value="{{ mailboxdata.attributes.recovery_email }}">
+ <small class="text-muted">{{ lang.user.password_reset_info }}</small>
</div>
</div>
- <div class="row">
- <label class="control-label col-sm-3" for="user_new_pass2">{{ lang.user.new_password_repeat }}</label>
- <div class="col-sm-5">
- <input type="password" data-pwgen-field="true" class="form-control" name="user_new_pass2" autocomplete="new-password" required>
- <p class="text-muted">{{ lang.user.new_password_description }}</p>
- </div>
- </div>
- <hr>
- <div class="row">
+ <div class="row mb-4">
<label class="control-label col-sm-3" for="user_old_pass">{{ lang.user.password_now }}</label>
- <div class="col-sm-5">
+ <div class="col-sm-9">
<input type="password" class="form-control" name="user_old_pass" autocomplete="off" required>
</div>
</div>
<div class="row">
<div class="offset-sm-3 col-sm-9">
- <button class="btn btn-xs-lg d-block d-sm-inline btn-success" data-action="edit_selected" data-id="pwchange" data-item="null" data-api-url='edit/self' data-api-attr='{}' href="#">{{ lang.user.change_password }}</button>
+ <button class="btn btn-xs-lg d-block d-sm-inline btn-success" data-action="edit_selected" data-id="pw_recovery_change" data-item="null" data-api-url='edit/self' data-api-attr='{}' href="#">{{ lang.user.save }}</button>
+ </div>
+ </div>
+ </form>
+ </div>
+ </div>
+ </div>
+</div><!-- pw recovery email modal -->
+<!-- temp alias modal -->
+<div class="modal fade" id="tempAliasModal" tabindex="-1" role="dialog" aria-labelledby="tempAliasModalLabel">
+ <div class="modal-dialog modal-lg" role="document">
+ <div class="modal-content">
+ <div class="modal-header">
+ <h3 class="modal-title">{{ lang.user.alias_create_random }}</h3>
+ <button type="button" class="btn-close" data-bs-dismiss="modal"></button>
+ </div>
+ <div class="modal-body">
+ <form class="form-horizontal" data-cached-form="false" data-id="tempaliascreate" role="form" method="post" autocomplete="off">
+ <div class="row mb-4">
+ <label class="control-label col-sm-3" for="description">{{ lang.user.description }}</label>
+ <div class="col-sm-5">
+ <input type="hidden" id="temp_alias_domain" name="domain">
+ <input type="description" id="temp_alias_description" class="form-control" name="description" autocomplete="off">
+ </div>
+ </div>
+ <div class="row">
+ <div class="offset-sm-3 col-sm-9">
+ <button class="btn btn-xs-lg d-block d-sm-inline btn-success" data-action="add_item" data-id="tempaliascreate" data-item="null" data-api-url='add/time_limited_alias' data-api-attr='' href="#">{{ lang.admin.add }}</button>
</div>
</div>
</form>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/reset-password.twig b/mailcow/src/mailcow-dockerized/data/web/templates/reset-password.twig
new file mode 100644
index 0000000..5eb2027
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/reset-password.twig
@@ -0,0 +1,57 @@
+{% extends 'base.twig' %}
+
+{% block navbar %}{% endblock %}
+
+{% block content %}
+<div class="row mb-4" style="margin-top: 60px">
+ <div class="col-12 col-md-7 col-lg-6 col-xl-5 ms-auto me-auto">
+ <div class="card">
+ <div class="card-header d-flex align-items-center">
+ <i class="bi bi-person-fill me-2"></i> {{ lang.login.reset_password }}
+ <div class="ms-auto form-check form-switch my-auto d-flex align-items-center">
+ <label class="form-check-label"><i class="bi bi-moon-fill"></i></label>
+ <input class="form-check-input ms-2" type="checkbox" id="dark-mode-toggle">
+ </div>
+ </div>
+ <div class="card-body">
+ <div class="text-center mailcow-logo mb-4">
+ <img class="main-logo" src="{{ logo|default('/img/cow_mailcow.svg') }}" alt="mailcow">
+ <img class="main-logo-dark" src="{{ logo_dark|default('/img/cow_mailcow.svg') }}" alt="mailcow-logo-dark">
+ </div>
+ <legend>{{ ui_texts.main_name|raw }}</legend><hr />
+
+ {% if is_reset_token_valid %}
+ <form method="post" autofill="off">
+ <input type="hidden" name="token" value="{{ reset_token }}" />
+ <input type="password" autocorrect="off" autocapitalize="none" class="form-control mb-2" name="new_password" placeholder="{{ lang.login.new_password }}" />
+ <input type="password" autocorrect="off" autocapitalize="none" class="form-control mb-2" name="new_password2" placeholder="{{ lang.login.new_password_confirm }}" />
+
+ <small id="mismatch_alert" class="text-danger d-none">{{ lang.login.password_mismatch }}</small>
+ <div class="d-flex justify-content-end mt-4" style="position: relative">
+ <button type="submit" class="btn btn-xs-lg d-block d-sm-inline btn-success" name="pw_reset">{{ lang.login.reset_password }}</button>
+ </div>
+ </form>
+ {% elseif reset_token is null %}
+ <form method="post" autofill="off">
+ <input type="text" autocorrect="off" autocapitalize="none" class="form-control mb-2" name="username" placeholder="{{ lang.login.username }}" />
+
+ <div class="d-flex justify-content-end mt-4" style="position: relative">
+ <button type="submit" class="btn btn-xs-lg d-block d-sm-inline btn-success" name="pw_reset_request">{{ lang.login.request_reset_password }}</button>
+ </div>
+ </form>
+ {% else %}
+ <p class="text-center">{{ lang.login.invalid_pass_reset_token|raw }}</p>
+ <a href="/">{{ lang.login.back_to_mailcow }}</a>
+ {% endif %}
+
+
+ </div>
+ </div>
+ </div>
+</div>
+
+<script type='text/javascript'>
+ var csrf_token = '{{ csrf_token }}';
+ var mailcow_cc_username = '{{ mailcow_cc_username }}';
+</script>
+{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/user.twig b/mailcow/src/mailcow-dockerized/data/web/templates/user.twig
index 5536abe..4712fa3 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/user.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/user.twig
@@ -15,7 +15,7 @@
{% if acl.spam_alias == 1 %}
<li class="nav-item" role="presentation"><button class="nav-link" role="tab" aria-selected="false" aria-controls="SpamAliases" role="tab" data-bs-toggle="tab" data-bs-target="#SpamAliases">{{ lang.user.spam_aliases }}</button></li>
{% endif %}
- {% if acl.spam_score == 1 %}
+ {% if acl.spam_score == 1 or acl.spam_policy == 1 %}
<li class="nav-item" role="presentation"><button class="nav-link" role="tab" aria-selected="false" aria-controls="Spamfilter" role="tab" data-bs-toggle="tab" data-bs-target="#Spamfilter">{{ lang.user.spamfilter }}</button></li>
{% endif %}
{% if acl.syncjobs == 1 %}
@@ -36,14 +36,13 @@
{% include 'user/tab-user-details.twig' %}
{% include 'user/tab-user-settings.twig' %}
{% if acl.spam_alias == 1 %}{% include 'user/SpamAliases.twig' %}{% endif %}
- {% if acl.spam_score == 1 %}{% include 'user/Spamfilter.twig' %}{% endif %}
+ {% if acl.spam_score == 1 or acl.spam_policy == 1 %}{% include 'user/Spamfilter.twig' %}{% endif %}
{% if acl.syncjobs == 1 %}{% include 'user/Syncjobs.twig' %}{% endif %}
{% if acl.app_passwds == 1 %}{% include 'user/AppPasswds.twig' %}{% endif %}
{% if acl.pushover == 1 %}{% include 'user/Pushover.twig' %}{% endif %}
</div>
</div>
</div>
- <div style="margin-bottom:200px;"></div>
{% include 'user_domainadmin_common.twig' %}
</div>
{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/user/SpamAliases.twig b/mailcow/src/mailcow-dockerized/data/web/templates/user/SpamAliases.twig
index 40b3ec7..466c283 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/user/SpamAliases.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/user/SpamAliases.twig
@@ -8,6 +8,7 @@
</div>
<div id="collapse-tab-SpamAliases" class="card-body collapse" data-bs-parent="#user-content">
<div class="row">
+ <p>{{ lang.user.spam_aliases_info|raw }}</p>
<div class="col-md-12 col-sm-12 col-12">
<table id="tla_table" class="table table-striped dt-responsive w-100"></table>
</div>
@@ -18,12 +19,13 @@
<a class="btn btn-sm btn-xs-half d-block d-sm-inline btn-secondary" id="toggle_multi_select_all" data-id="tla" href="#"><i class="bi bi-check-all"></i> {{ lang.mailbox.toggle_all }}</a>
<a class="btn btn-sm btn-xs-half d-block d-sm-inline btn-secondary dropdown-toggle" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
<ul class="dropdown-menu">
- <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"1"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.hour }}</a></li>
- <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"24"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.day }}</a></li>
- <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"168"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.week }}</a></li>
- <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"744"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.month }}</a></li>
- <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"8760"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.year }}</a></li>
- <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"87600"}' href="#">{{ lang.user.expire_in }} 10 {{ lang.user.years }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"1","permanent":"0"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.hour }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"24","permanent":"0"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.day }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"168","permanent":"0"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.week }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"744","permanent":"0"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.month }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"8760","permanent":"0"}' href="#">{{ lang.user.expire_in }} 1 {{ lang.user.year }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"validity":"87600","permanent":"0"}' href="#">{{ lang.user.expire_in }} 10 {{ lang.user.years }}</a></li>
+ <li><a class="dropdown-item" data-action="edit_selected" data-id="tla" data-api-url='edit/time_limited_alias' data-api-attr='{"permanent":"1"}' href="#">{{ lang.user.expire_never }}</a></li>
<li><hr class="dropdown-divider"></li>
<li><a class="dropdown-item" data-action="delete_selected" data-id="tla" data-api-url='delete/time_limited_alias' href="#">{{ lang.mailbox.remove }}</a></li>
</ul>
@@ -33,7 +35,7 @@
<ul class="dropdown-menu">
{% for domain in user_domains %}
<li>
- <a class="dropdown-item" data-action="add_item" data-api-url='add/time_limited_alias' data-api-attr='{"domain":"{{ domain }}"}' href="#">
+ <a class="dropdown-item" data-bs-toggle="modal" data-bs-target="#tempAliasModal" onclick='$("#tempAliasModal #temp_alias_domain").val("{{ domain }}")' href="#">
@ {{ domain }}
</a>
</li>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/user/Spamfilter.twig b/mailcow/src/mailcow-dockerized/data/web/templates/user/Spamfilter.twig
index 280b900..1f69df9 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/user/Spamfilter.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/user/Spamfilter.twig
@@ -39,10 +39,10 @@
</div>
<hr>
<div class="row">
- <div class="col-lg-6 my-3">
+ <div class="col-lg-6 my-3 d-flex flex-column">
<h4>{{ lang.user.spamfilter_wl }}</h4>
<p>{{ lang.user.spamfilter_wl_desc|raw }}</p>
- <form class="form-inline mb-4" data-id="add_wl_policy_mailbox">
+ <form class="form-inline mb-4 mt-auto" data-id="add_wl_policy_mailbox">
<div class="input-group" data-acl="{{ acl.spam_policy }}">
<input type="text" class="form-control" name="object_from" placeholder="*@example.org" required>
<button class="btn btn-secondary" data-action="add_item" data-id="add_wl_policy_mailbox" data-api-url='add/mailbox-policy' data-api-attr='{"username": {{ mailcow_cc_username|json_encode|raw }},"object_list":"wl"}' href="#"><i class="bi bi-plus-lg"></i> {{ lang.user.spamfilter_table_add }}</button>
@@ -61,10 +61,10 @@
</div>
</div>
</div>
- <div class="col-lg-6 my-3">
+ <div class="col-lg-6 my-3 d-flex flex-column">
<h4>{{ lang.user.spamfilter_bl }}</h4>
<p>{{ lang.user.spamfilter_bl_desc|raw }}</p>
- <form class="form-inline mb-4" data-id="add_bl_policy_mailbox">
+ <form class="form-inline mb-4 mt-auto" data-id="add_bl_policy_mailbox">
<div class="input-group" data-acl="{{ acl.spam_policy }}">
<input type="text" class="form-control" name="object_from" placeholder="*@example.org" required>
<button class="btn btn-secondary" data-action="add_item" data-id="add_bl_policy_mailbox" data-api-url='add/mailbox-policy' data-api-attr='{"username": {{ mailcow_cc_username|json_encode|raw }},"object_list":"bl"}' href="#"><i class="bi bi-plus-lg"></i> {{ lang.user.spamfilter_table_add }}</button>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/user/tab-user-auth.twig b/mailcow/src/mailcow-dockerized/data/web/templates/user/tab-user-auth.twig
index 4d55b70..171545d 100644
--- a/mailcow/src/mailcow-dockerized/data/web/templates/user/tab-user-auth.twig
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/user/tab-user-auth.twig
@@ -8,157 +8,207 @@
</div>
<div id="collapse-tab-user-auth" class="card-body collapse" data-bs-parent="#user-content">
{% if mailboxdata.attributes.force_pw_update == '1' %}
- <div class="alert alert-danger">{{ lang.user.force_pw_update|raw }}</div>
+ <div class="alert alert-danger">{{ lang.user.force_pw_update|raw }}</div>
{% endif %}
- {% if not skip_sogo %}
<div class="row">
- <div class="hidden-xs col-md-3 col-xs-5 text-right"></div>
- <div class="col-md-3 col-xs-12">
- {% if dual_login and allow_admin_email_login == 'n' or mailboxdata.attributes.force_pw_update == '1' %}
- <button disabled class="btn btn-secondary btn-block btn-xs-lg">
- <i class="bi bi-inbox-fill"></i> {{ lang.user.open_webmail_sso }}
- </button>
- {% else %}
- <a target="_blank" href="/sogo-auth.php?login={{ mailcow_cc_username }}" role="button" class="btn btn-secondary btn-block btn-xs-lg">
- <i class="bi bi-inbox-fill"></i> {{ lang.user.open_webmail_sso }}
- </a>
+ <div class="col-xl-9 col-lg-7 col-md-12 col-12 d-flex flex-column mb-4">
+ {% if not skip_sogo %}
+ <div class="row mb-4">
+ <div class="col-12 col-lg-6 col-xl-4">
+ {% if dual_login and allow_admin_email_login == 'n' or mailboxdata.attributes.force_pw_update == '1' %}
+ <button disabled class="btn btn-secondary btn-block btn-xs-lg w-100">
+ {{ lang.user.open_webmail_sso }} <i class="bi bi-arrow-right"></i>
+ </button>
+ {% elseif dual_login %}
+ <a href="/sogo-auth.php?login={{ mailcow_cc_username }}" role="button" class="btn btn-primary btn-lg btn-block btn-xs-lg w-100">
+ {{ lang.user.open_webmail_sso }} <i class="bi bi-arrow-right"></i>
+ </a>
+ {% else %}
+ <a href="/SOGo/so" role="button" class="btn btn-primary btn-lg btn-block btn-xs-lg w-100">
+ {{ lang.user.open_webmail_sso }} <i class="bi bi-arrow-right"></i>
+ </a>
+ {% endif %}
+ </div>
+ </div>
{% endif %}
- </div>
- </div>
- <hr>
- <div class="row">
- <div class="d-none d-sm-flex col-md-3 col-5 text-end"></div>
- <div class="col-md-9 col-12">
- <p class="text-muted text-muted-mt-0">{{ lang.user.direct_protocol_access|raw }}</p>
- {% if mailboxdata.attributes.imap_access == 1 %}<div class="badge fs-6 bg-success mb-2">IMAP <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger">IMAP <i class="bi bi-x-lg"></i></div>{% endif %}
- {% if mailboxdata.attributes.smtp_access == 1 %}<div class="badge fs-6 bg-success mb-2">SMTP <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger">SMTP <i class="bi bi-x-lg"></i></div>{% endif %}
- {% if mailboxdata.attributes.sieve_access == 1 %}<div class="badge fs-6 bg-success mb-2">Sieve <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger">Sieve <i class="bi bi-x-lg"></i></div>{% endif %}
- {% if mailboxdata.attributes.pop3_access == 1 %}<div class="badge fs-6 bg-success mb-2">POP3 <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger">POP3 <i class="bi bi-x-lg"></i></div>{% endif %}
- {% if mailboxdata.attributes.sogo_access == 1 %}<div class="badge fs-6 bg-success mb-2">SOGo <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger">SOGo <i class="bi bi-x-lg"></i></div>{% endif %}
- </div>
- </div>
- <hr>
- {% endif %}
- <div class="row">
- <div class="col-md-3 col-12 text-sm-end text-start mb-4">{{ lang.user.in_use }}:</div>
- <div class="col-md-5 col-12">
- <div class="progress">
+
+ <legend>{{ lang.user.overview }}</legend>
+ <hr>
+ <div class="d-flex">
+ <h5><i class="bi bi-envelope-fill"></i> {{ mailboxdata.messages }} {{ lang.user.messages }}</h5>
+ <h5 class="ms-auto">{{ mailboxdata.quota_used|formatBytes(2) }} / {% if mailboxdata.quota == 0 %}∞{% else %}{{ mailboxdata.quota|formatBytes(2) }}{% endif %}</h5>
+ </div>
+ <div class="progress mb-4" style="height: 20px";>
<div class="progress-bar bg-{{ mailboxdata.percent_class }}" role="progressbar" aria-valuenow="{{ mailboxdata.percent_in_use }}" aria-valuemin="0" aria-valuemax="100" style="min-width:2em;width: {{ mailboxdata.percent_in_use }}%;">
{{ mailboxdata.percent_in_use }}%
</div>
</div>
- <p>{{ mailboxdata.quota_used|formatBytes(2) }} / {% if mailboxdata.quota == 0 %}∞{% else %}{{ mailboxdata.quota|formatBytes(2) }}{% endif %}<br>{{ mailboxdata.messages }} {{ lang.user.messages }}</p>
+
+ <div class="row">
+ <div class="col-12 col-md-3 d-flex">
+ <span class="mt-2 w-100 text-md-end">{{ lang.user.protocols }}:</span>
+ </div>
+ <div class="col-12 col-md-9 d-flex">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill m-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.direct_protocol_access|raw }}"></i>
+ <div class="d-flex flex-wrap">
+ {% if mailboxdata.attributes.imap_access == 1 %}<div class="badge fs-6 bg-success m-2">IMAP <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger m-2">IMAP <i class="bi bi-x-lg"></i></div>{% endif %}
+ {% if mailboxdata.attributes.smtp_access == 1 %}<div class="badge fs-6 bg-success m-2">SMTP <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger m-2">SMTP <i class="bi bi-x-lg"></i></div>{% endif %}
+ {% if mailboxdata.attributes.sieve_access == 1 %}<div class="badge fs-6 bg-success m-2">Sieve <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger m-2">Sieve <i class="bi bi-x-lg"></i></div>{% endif %}
+ {% if mailboxdata.attributes.pop3_access == 1 %}<div class="badge fs-6 bg-success m-2">POP3 <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger m-2">POP3 <i class="bi bi-x-lg"></i></div>{% endif %}
+ {% if mailboxdata.attributes.eas_access == 1 %}<div class="badge fs-6 bg-success m-2">ActiveSync <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger m-2">ActiveSync <i class="bi bi-x-lg"></i></div>{% endif %}
+ {% if mailboxdata.attributes.dav_access == 1 %}<div class="badge fs-6 bg-success m-2">CalDAV/CardDAV <i class="bi bi-check-lg"></i></div>{% else %}<div class="badge fs-6 bg-danger m-2">CalDAV/CardDAV <i class="bi bi-x-lg"></i></div>{% endif %}
+ </div>
+ </div>
+ </div>
+ <div class="row mt-2">
+ <div class="col-12 col-md-3 d-flex">
+ <span class="mt-2 w-100 text-md-end">{{ lang.user.apple_connection_profile }}:</span>
+ </div>
+ <div class="col-12 col-md-8">
+ <div class="d-flex">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_mailonly }}"></i>
+ <a href="/mobileconfig.php?only_email">{{ lang.user.email }} <small>[IMAP, SMTP]</small></a>
+ </div>
+ {% if not skip_sogo %}
+ <div class="d-flex">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_complete }}"></i>
+ <a href="/mobileconfig.php">{{ lang.user.email_and_dav }} <small>[IMAP, SMTP, Cal/CardDAV]</small></a>
+ </div>
+ {% endif %}
+ </div>
+ </div>
+ <div class="row mt-2">
+ <div class="col-12 col-md-3 d-flex">
+ <span class="mt-2 w-100 text-md-end">{{ lang.user.apple_connection_profile }}<br>{{ lang.user.with_app_password }}:</span>
+ </div>
+ <div class="col-12 col-md-9">
+ <div class="d-flex">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_mailonly }} {{ lang.user.apple_connection_profile_with_app_password }}"></i>
+ <a href="/mobileconfig.php?only_email&app_password">{{ lang.user.email }} <small>[IMAP, SMTP]</small></a>
+ </div>
+ {% if not skip_sogo %}
+ <div class="d-flex">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill me-2" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.apple_connection_profile_complete }} {{ lang.user.apple_connection_profile_with_app_password }}"></i>
+ <a href="/mobileconfig.php?app_password">{{ lang.user.email_and_dav }} <small>[IMAP, SMTP, Cal/CardDAV]</small></a>
+ </div>
+ {% endif %}
+ </div>
+ </div>
+ <div class="row">
+ <div class="col-12 d-flex flex-column text-center align-items-center mt-4">
+ <a target="_blank" href="https://mailcow.github.io/mailcow-dockerized-docs/client/client/#{{ clientconfigstr }}">{{ lang.user.client_configuration }}</a>
+ <a class="mt-2" href="#userFilterModal" data-bs-toggle="modal">{{ lang.user.show_sieve_filters }}</a>
+ </div>
+ </div>
+
+ {% if mailboxdata.authsource == "mailcow" %}
+ <legend class="mt-4">{{ lang.user.authentication }}</legend>
<hr>
- <p><a href="#pwChangeModal" data-bs-toggle="modal"><i class="bi bi-pencil-fill"></i> {{ lang.user.change_password }}</a></p>
- </div>
- </div>
- <hr>
- {# TFA #}
- <div class="row">
- <div class="col-sm-3 col-xs-5 text-right">{{ lang.tfa.tfa }}:</div>
- <div class="col-sm-9 col-xs-7">
- <p id="tfa_pretty">{{ tfa_data.pretty }}</p>
- {% include 'tfa_keys.twig' %}
- <br>
- </div>
- </div>
- <div class="row">
- <div class="col-sm-3 col-xs-5 text-right">{{ lang.tfa.set_tfa }}:</div>
- <div class="col-sm-9 col-xs-7">
- <select data-style="btn btn-sm dropdown-toggle bs-placeholder btn-secondary" data-width="fit" id="selectTFA" class="selectpicker" title="{{ lang.tfa.select }}">
- <option value="yubi_otp">{{ lang.tfa.yubi_otp }}</option>
- <option value="webauthn">{{ lang.tfa.webauthn }}</option>
- <option value="totp">{{ lang.tfa.totp }}</option>
- <option value="none">{{ lang.tfa.none }}</option>
- </select>
- </div>
- </div>
- <hr>
- {# FIDO2 #}
- <div class="row">
- <div class="col-sm-3 col-12 text-sm-end text-start">
- <p><i class="bi bi-shield-fill-check"></i> {{ lang.fido2.fido2_auth }}</p>
- </div>
- </div>
- <div class="row">
- <div class="col-sm-3 col-12 text-sm-end text-start mb-4">
- {{ lang.fido2.known_ids }}:
- </div>
- <div class="col-sm-9 col-12">
- <div class="table-responsive">
- <table class="table table-striped table-hover table-condensed" id="fido2_keys">
- <tr>
- <th>ID</th>
- <th style="min-width:240px;text-align: right">{{ lang.admin.action }}</th>
- </tr>
- {% include 'fido2.twig' %}
- </table>
+ {# Password Change #}
+ <div class="row">
+ <div class="col-12 col-md-3 d-flex"></div>
+ <div class="col-12 col-md-9 d-flex flex-wrap">
+ <a class="btn btn-secondary" href="#pwChangeModal" data-bs-toggle="modal"><i class="bi bi-pencil-fill"></i> {{ lang.user.change_password }}</a>
+ {% if acl.pw_reset == 1 %}
+ <a class="btn btn-secondary ms-4" href="#pwRecoveryEmailModal" data-bs-toggle="modal"><i class="bi bi-pencil-fill"></i> {{ lang.user.pw_recovery_email }}</a></p>
+ {% endif %}
+ </div>
+ </div>
+ {% endif %}
+ {# TFA #}
+ {% if mailboxdata.authsource == "mailcow" or mailboxdata.authsource == "ldap" %}
+ <div class="row mt-4">
+ <div class="col-12 col-md-3 d-flex">
+ <span class="mt-2 w-100 text-md-end">{{ lang.tfa.tfa }}:</span>
+ </div>
+ <div class="col-12 col-md-9 d-flex flex-wrap justify-content-center justify-content-sm-start">
+ <span id="tfa_pretty">{{ tfa_data.pretty }}</span>
+ {% include 'tfa_keys.twig' %}
+ </div>
+ </div>
+ <div class="row mt-2 mb-4">
+ <div class="col-12 col-md-3 d-flex">
+ <span class="mt-2 w-100 text-md-end">{{ lang.tfa.set_tfa }}:</span>
+ </div>
+ <div class="col-12 col-md-9 d-flex flex-wrap align-items-center justify-content-center justify-content-sm-start">
+ <i style="font-size: 16px; cursor: pointer;" class="bi bi-patch-question-fill m-2 ms-0" data-bs-toggle="tooltip" data-bs-html="true" data-bs-placement="bottom" title="{{ lang.user.tfa_info|raw }}"></i>
+ <select data-style="ms-2 btn btn-sm dropdown-toggle bs-placeholder btn-secondary" data-width="fit" id="selectTFA" class="selectpicker" title="{{ lang.tfa.select }}">
+ <option value="yubi_otp">{{ lang.tfa.yubi_otp }}</option>
+ <option value="webauthn">{{ lang.tfa.webauthn }}</option>
+ <option value="totp">{{ lang.tfa.totp }}</option>
+ <option value="none">{{ lang.tfa.none }}</option>
+ </select>
+ </div>
+ </div>
+ {% endif %}
+ {# FIDO2 #}
+ {% if mailboxdata.authsource == "mailcow" %}
+ <div class="row mt-4">
+ <div class="col-sm-3 col-12 text-sm-end text-start">
+ <p><i class="bi bi-shield-fill-check"></i> {{ lang.fido2.fido2_auth }}</p>
+ </div>
+ </div>
+ <div class="row">
+ <div class="col-sm-3 col-12 text-sm-end text-start mb-4">
+ {{ lang.fido2.known_ids }}:
+ </div>
+ <div class="col-sm-9 col-12">
+ <div class="table-responsive">
+ <table class="table table-striped table-hover table-condensed" id="fido2_keys">
+ <tr>
+ <th>ID</th>
+ <th style="min-width:240px;text-align: right">{{ lang.admin.action }}</th>
+ </tr>
+ {% include 'fido2.twig' %}
+ </table>
+ </div>
+ <br>
+ </div>
+ </div>
+ <div class="row">
+ <div class="offset-sm-3 col-sm-9">
+ <div class="btn-group nowrap">
+ <button class="btn btn-sm btn-primary d-block d-sm-inline" id="register-fido2">{{ lang.fido2.set_fido2 }}</button>
+ <button type="button" class="btn btn-sm btn-xs-lg btn-primary dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></button>
+ <ul class="dropdown-menu">
+ <li><a class="dropdown-item" href="#" id="register-fido2-touchid"><i class="bi bi-apple"></i> {{ lang.fido2.set_fido2_touchid }}</a></li>
+ </ul>
+ </div>
+ </div>
</div>
<br>
- </div>
- </div>
- <div class="row">
- <div class="offset-sm-3 col-sm-9">
- <div class="btn-group nowrap">
- <button class="btn btn-sm btn-primary d-block d-sm-inline" id="register-fido2">{{ lang.fido2.set_fido2 }}</button>
- <button type="button" class="btn btn-sm btn-xs-lg btn-primary dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false"></button>
- <ul class="dropdown-menu">
- <li><a class="dropdown-item" href="#" id="register-fido2-touchid"><i class="bi bi-apple"></i> {{ lang.fido2.set_fido2_touchid }}</a></li>
- </ul>
+ <div class="row" id="status-fido2">
+ <div class="col-sm-3 col-5 text-end">{{ lang.fido2.register_status }}:</div>
+ <div class="col-sm-9 col-7">
+ <div id="fido2-alerts">-</div>
+ </div>
+ <br>
</div>
- </div>
- </div>
- <br>
- <div class="row" id="status-fido2">
- <div class="col-sm-3 col-5 text-end">{{ lang.fido2.register_status }}:</div>
- <div class="col-sm-9 col-7">
- <div id="fido2-alerts">-</div>
- </div>
- <br>
- </div>
- <hr>
- <div class="row">
- <div class="col-md-3 col-12 text-sm-end text-start mb-4"><i class="bi bi-file-earmark-text"></i> {{ lang.user.apple_connection_profile }}:</div>
- <div class="col-md-9 col-12">
- <p><i class="bi bi-file-earmark-post"></i> <a href="/mobileconfig.php?only_email">{{ lang.user.email }}</a> <small>IMAP, SMTP</small></p>
- <p class="text-muted">{{ lang.user.apple_connection_profile_mailonly }}</p>
- {% if not skip_sogo %}
- <p><i class="bi bi-file-earmark-post"></i> <a href="/mobileconfig.php">{{ lang.user.email_and_dav }}</a> <small>IMAP, SMTP, Cal/CardDAV</small></p>
- <p class="text-muted">{{ lang.user.apple_connection_profile_complete }}</p>
{% endif %}
</div>
- </div>
- <div class="row">
- <div class="col-md-3 col-12 text-sm-end text-start mb-4"><i class="bi bi-file-earmark-text"></i> {{ lang.user.apple_connection_profile }}<br class="d-none d-lg-block" />{{ lang.user.with_app_password }}:</div>
- <div class="col-md-9 col-12">
- <p><i class="bi bi-file-earmark-post"></i> <a href="/mobileconfig.php?only_email&app_password">{{ lang.user.email }}</a> <small>IMAP, SMTP</small></p>
- <p class="text-muted">{{ lang.user.apple_connection_profile_mailonly }}<br /> {{ lang.user.apple_connection_profile_with_app_password }}</p>
- {% if not skip_sogo %}
- <p><i class="bi bi-file-earmark-post"></i> <a href="/mobileconfig.php?app_password">{{ lang.user.email_and_dav }}</a> <small>IMAP, SMTP, Cal/CardDAV</small></p>
- <p class="text-muted">{{ lang.user.apple_connection_profile_complete }}<br /> {{ lang.user.apple_connection_profile_with_app_password }}</p>
- {% endif %}
- </div>
- </div>
- <hr>
- <div class="row">
- <div class="offset-sm-3 col-sm-9">
- <p><a target="_blank" href="https://docs.mailcow.email/client/client/#{{ clientconfigstr }}">[{{ lang.user.client_configuration }}]</a></p>
- <p><a href="#userFilterModal" data-bs-toggle="modal">[{{ lang.user.show_sieve_filters }}]</a></p>
+ <div class="ms-auto col-xl-3 col-lg-5 col-md-12 col-12 d-flex flex-column well flex-grow-1" id="recent-logins">
+ <legend class="d-flex">
+ <span>{{ lang.user.recent_successful_connections }}</span>
+ <div id="spinner-last-login" class="ms-auto my-auto spinner-border spinner-border-sm d-none" role="status">
+ <span class="visually-hidden">Loading...</span>
+ </div>
+ </legend>
<hr>
- <h4 class="recent-login-success">{{ lang.user.recent_successful_connections }}</h4>
- <div class="dropdown mt-2">
- <button class="btn btn-secondary btn-xs btn-xs-lg dropdown-toggle" type="button" id="history_sasl_days" data-bs-toggle="dropdown">{{ lang.user.login_history }}</button>
- <ul class="dropdown-menu">
- <li class="login-history" data-days="1"><a class="dropdown-item" href="#">1 {{ lang.user.day }}</a></li>
- <li class="login-history" data-days="7"><a class="dropdown-item active" href="#">1 {{ lang.user.week }}</a></li>
- <li class="login-history" data-days="14"><a class="dropdown-item" href="#">2 {{ lang.user.weeks }}</a></li>
- <li class="login-history" data-days="31"><a class="dropdown-item" href="#">1 {{ lang.user.month }}</a></li>
- </ul>
+ <div class="d-flex">
+ <span class="clear-last-logins mt-auto mb-2">
+ {{ lang.user.clear_recent_successful_connections }}
+ </span>
+ <div class="dropdown mt-4 mb-2 ms-auto">
+ <button class="btn btn-secondary btn-xs btn-xs-lg dropdown-toggle" type="button" id="history_sasl_days" data-bs-toggle="dropdown">{{ lang.user.login_history }}</button>
+ <ul class="dropdown-menu">
+ <li class="login-history" data-days="1"><a class="dropdown-item" href="#">1 {{ lang.user.day }}</a></li>
+ <li class="login-history" data-days="7"><a class="dropdown-item active" href="#">1 {{ lang.user.week }}</a></li>
+ <li class="login-history" data-days="14"><a class="dropdown-item" href="#">2 {{ lang.user.weeks }}</a></li>
+ <li class="login-history" data-days="31"><a class="dropdown-item" href="#">1 {{ lang.user.month }}</a></li>
+ </ul>
+ </div>
</div>
- <div class="last-login mt-4"></div>
- <span class="clear-last-logins mt-2">
- {{ lang.user.clear_recent_successful_connections }}
- </span>
+ <ul class="list-group last-sasl-login overflow-auto" style="flex: 1 1 0; min-height: 400px;"></ul>
</div>
</div>
</div>
diff --git a/mailcow/src/mailcow-dockerized/data/web/templates/user_index.twig b/mailcow/src/mailcow-dockerized/data/web/templates/user_index.twig
new file mode 100644
index 0000000..9354a81
--- /dev/null
+++ b/mailcow/src/mailcow-dockerized/data/web/templates/user_index.twig
@@ -0,0 +1,137 @@
+{% extends 'base.twig' %}
+
+{% block navbar %}{% endblock %}
+
+{% block content %}
+<div class="row mb-4" style="margin-top: 60px">
+ <div class="col-12 col-md-7 col-lg-6 col-xl-5 ms-auto me-auto">
+
+ <div class="card login-card login-user">
+ <div class="card-header d-flex align-items-center text-break">
+ <i class="bi bi-person-fill me-2"></i> {{ lang.login.login_user }}
+ <div class="ms-auto form-check form-switch my-auto d-flex align-items-center">
+ <label class="form-check-label"><i class="bi bi-moon-fill"></i></label>
+ <input class="form-check-input ms-2" type="checkbox" id="dark-mode-toggle">
+ </div>
+ {% if not oauth2_request %}
+ <div class="ms-4 d-grid d-sm-block">
+ <button type="button" {% if available_languages|length == 1 %}disabled="true"{% endif %} class="text-secondary btn p-0 border-0 bg-transparent ms-auto dropdown-toggle" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
+ <span class="flag-icon flag-icon-{{ mailcow_locale[-2:] }}"></span>
+ </button>
+ <ul class="dropdown-menu ms-auto login">
+ {% for key, val in available_languages %}
+ <li>
+ <a class="dropdown-item {% if mailcow_locale == key %}active{% endif %}" href="?{{ query_string({'lang': key}) }}">
+ <span class="flag-icon flag-icon-{{ key[-2:] }}"></span>{{ val }}
+ </a>
+ </li>
+ {% endfor %}
+ </ul>
+ </div>
+ {% endif %}
+ </div>
+ <div class="card-body">
+ <div class="text-center mailcow-logo mb-4">
+ <img class="main-logo" src="{{ logo|default('/img/cow_mailcow.svg') }}" alt="mailcow">
+ <img class="main-logo-dark" src="{{ logo_dark|default('/img/cow_mailcow.svg') }}" alt="mailcow-logo-dark">
+ </div>
+ {% if ui_texts.ui_announcement_text and ui_texts.ui_announcement_active %}
+ <div class="my-4 alert alert-{{ ui_texts.ui_announcement_type }} rot-enc ui-announcement-alert">{{ ui_texts.ui_announcement_text|rot13 }}</div>
+ {% endif %}
+ <legend>{% if oauth2_request %}{{ lang.oauth2.authorize_app }}{% else %}{{ ui_texts.main_name|raw }}{% endif %}</legend><hr />
+ {% if is_mobileconfig %}
+ <div class="my-4 alert alert-info ">{{ lang.login.mobileconfig_info }}</div>
+ {% endif %}
+ {% if custom_login.force_sso != 1 %}
+ <form method="post" autofill="off">
+ <div class="d-flex mt-3">
+ <label class="visually-hidden" for="login_user">{{ lang.login.username }}</label>
+ <div class="input-group">
+ <div class="input-group-text"><i class="bi bi-person-fill"></i></div>
+ <input name="login_user" autocorrect="off" autocapitalize="none" type="{% if is_mobileconfig %}email{% else %}text{% endif %}" id="login_user" class="form-control" placeholder="{{ lang.login.email }}" required="" autofocus="" autocomplete="username">
+ </div>
+ </div>
+ <div class="d-flex mt-3">
+ <label class="visually-hidden" for="pass_user">{{ lang.login.password }}</label>
+ <div class="input-group">
+ <div class="input-group-text"><i class="bi bi-lock-fill"></i></div>
+ <input name="pass_user" type="password" id="pass_user" class="form-control" placeholder="{{ lang.login.password }}" required="" autocomplete="current-password">
+ <button type="button" class="input-group-text" style="cursor:pointer;" onclick="var i=document.getElementById('pass_user'),ic=this.querySelector('i');if(i.type==='password'){i.type='text';ic.className='bi bi-eye-slash';}else{i.type='password';ic.className='bi bi-eye';}" tabindex="-1" aria-label="Toggle password visibility"><i class="bi bi-eye"></i></button>
+ </div>
+ </div>
+ <div class="mt-2 text-muted" style="font-size: 0.9rem;">
+ <a href="/reset-password">{{ lang.login.forgot_password }}</a>
+ </div>
+ <div class="d-flex justify-content-between mt-4" style="position: relative">
+ <button type="submit" class="btn btn-xs-lg btn-success w-100 mt-2 mx-auto" style="max-width: 400px;" value="Login">{{ lang.login.login }}</button>
+ </div>
+ </form>
+ <div class="hr-title"><strong>{{ lang.login.other_logins }}</strong></div>
+ {% endif %}
+ <div class="d-flex flex-column align-items-center">
+ {% if has_iam_sso %}
+ <a class="btn btn-xs-lg btn-secondary w-100 mt-2" style="max-width: 400px;" href="/?iam_sso=1"><i class="bi bi-cloud-arrow-up-fill"></i> {{ lang.admin.iam_sso }}</a>
+ {% endif %}
+ {% if custom_login.force_sso != 1 %}
+ <a class="btn btn-xs-lg btn-secondary w-100 mt-2" style="max-width: 400px;" href="#" id="fido2-login"><i class="bi bi-shield-fill-check"></i> {{ lang.login.fido2_webauthn }}</a>
+ {% endif %}
+ </div>
+ {% if login_delay %}
+ <p><div class="my-4 alert alert-info">{{ lang.login.delayed|format(login_delay) }}</b></div></p>
+ {% endif %}
+ <div class="my-4" id="fido2-alerts"></div>
+ {% if not oauth2_request and (mailcow_apps or app_links) and not hide_mailcow_apps %}
+ <legend><i class="bi bi-link-45deg"></i> {{ ui_texts.apps_name|raw }}</legend><hr />
+ <div class="my-2 apps">
+ {% for app in mailcow_apps %}
+ {% if not app.hide %}
+ {% if not skip_sogo or not is_uri('SOGo', app.link) %}
+ <div class="m-2">
+ <a href="{{ app.link }}" role="button" {% if app.description %}title="{{ app.description }}"{% endif %} class="btn btn-primary btn-block">{{ app.name }}</a>
+ </div>
+ {% endif %}
+ {% endif %}
+ {% endfor %}
+ {% for row in app_links %}
+ {% for key, val in row %}
+ {% if not val.hide %}
+ <div class="m-2">
+ <a href="{{ val.link }}" role="button" class="btn btn-primary btn-block">{{ key }}</a>
+ </div>
+ {% endif %}
+ {% endfor %}
+ {% endfor %}
+ </div>
+ <div>
+ </div>
+ {% endif %}
+ </div>
+ </div>
+
+ {% if custom_login.hide_admin_quicklink != 1 or custom_login.hide_domainadmin_quicklink != 1 %}
+ <p class="text-center mt-3 text-muted" style="font-size: 0.9rem;">
+ {{ lang.login.login_linkstext }}<br>
+ {% if custom_login.hide_admin_quicklink != 1 %}<a href="/admin">{{ lang.login.login_admintext }}</a>{% endif %}
+ {% if custom_login.hide_admin_quicklink != 1 and custom_login.hide_domainadmin_quicklink != 1 %}|{% endif %}
+ {% if custom_login.hide_domainadmin_quicklink != 1 %}<a href="/domainadmin">{{ lang.login.login_domainadmintext }}</a>{% endif %}
+ </p>
+ {% endif %}
+ </div>
+</div>
+{% if not oauth2_request and ui_texts.help_text %}
+<div class="row">
+ <div class="col-12 col-md-7 col-lg-6 col-xl-5 ms-auto me-auto">
+ <div class="card">
+ <div class="card-header">
+ <a class="btn btn-link" data-bs-toggle="collapse" href="#collapse1"><i class="bi bi-patch-question-fill"></i> {{ lang.start.help }}</a>
+ </div>
+ <div id="collapse1" class="card-collapse collapse">
+ <div class="card-body">
+ <p>{{ ui_texts.help_text|raw }}</p>
+ </div>
+ </div>
+ </div>
+ </div>
+</div>
+{% endif %}
+{% endblock %}
diff --git a/mailcow/src/mailcow-dockerized/data/web/user.php b/mailcow/src/mailcow-dockerized/data/web/user.php
index 19aafdd..cadedf4 100644
--- a/mailcow/src/mailcow-dockerized/data/web/user.php
+++ b/mailcow/src/mailcow-dockerized/data/web/user.php
@@ -1,105 +1,80 @@
<?php
require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/prerequisites.inc.php';
-if (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'domainadmin') {
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/triggers.user.inc.php';
- /*
- / DOMAIN ADMIN
- */
+/*
+/ USER
+*/
- require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
- $_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
- $tfa_data = get_tfa();
- $fido2_data = fido2(array("action" => "get_friendly_names"));
- $username = $_SESSION['mailcow_cc_username'];
+// Protect route: user only
+protect_route(['user']);
- $template = 'domainadmin.twig';
- $template_data = [
- 'acl' => $_SESSION['acl'],
- 'acl_json' => json_encode($_SESSION['acl']),
- 'user_spam_score' => mailbox('get', 'spam_score', $username),
- 'tfa_data' => $tfa_data,
- 'fido2_data' => $fido2_data,
- 'lang_user' => json_encode($lang['user']),
- 'lang_datatables' => json_encode($lang['datatables']),
- ];
-}
-elseif (isset($_SESSION['mailcow_cc_role']) && $_SESSION['mailcow_cc_role'] == 'user') {
+require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
+$_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
+$username = $_SESSION['mailcow_cc_username'];
+$mailboxdata = mailbox('get', 'mailbox_details', $username);
+$pushover_data = pushover('get', $username);
+$tfa_data = get_tfa();
+$fido2_data = fido2(array("action" => "get_friendly_names"));
- /*
- / USER
- */
-
- require_once $_SERVER['DOCUMENT_ROOT'] . '/inc/header.inc.php';
- $_SESSION['return_to'] = $_SERVER['REQUEST_URI'];
- $username = $_SESSION['mailcow_cc_username'];
- $mailboxdata = mailbox('get', 'mailbox_details', $username);
- $pushover_data = pushover('get', $username);
- $tfa_data = get_tfa();
- $fido2_data = fido2(array("action" => "get_friendly_names"));
-
- $clientconfigstr = "host=" . urlencode($mailcow_hostname) . "&email=" . urlencode($username) . "&name=" . urlencode($mailboxdata['name']) . "&ui=" . urlencode(strtok($_SERVER['HTTP_HOST'], ':')) . "&port=" . urlencode($autodiscover_config['caldav']['port']);
- if ($autodiscover_config['useEASforOutlook'] == 'yes')
- $clientconfigstr .= "&outlookEAS=1";
- if (file_exists('thunderbird-plugins/version.csv')) {
- $fh = fopen('thunderbird-plugins/version.csv', 'r');
- if ($fh) {
- while (($row = fgetcsv($fh, 1000, ';')) !== FALSE) {
- if ($row[0] == 'sogo-connector@inverse.ca') {
- $clientconfigstr .= "&connector=" . urlencode($row[1]);
- }
+$clientconfigstr = "host=" . urlencode($mailcow_hostname) . "&email=" . urlencode($username) . "&name=" . urlencode($mailboxdata['name']) . "&ui=" . urlencode(strtok($_SERVER['HTTP_HOST'], ':')) . "&port=" . urlencode($autodiscover_config['caldav']['port']);
+if ($autodiscover_config['useEASforOutlook'] == 'yes')
+$clientconfigstr .= "&outlookEAS=1";
+if (file_exists('thunderbird-plugins/version.csv')) {
+ $fh = fopen('thunderbird-plugins/version.csv', 'r');
+ if ($fh) {
+ while (($row = fgetcsv($fh, 1000, ';')) !== FALSE) {
+ if ($row[0] == 'sogo-connector@inverse.ca') {
+ $clientconfigstr .= "&connector=" . urlencode($row[1]);
}
- fclose($fh);
}
+ fclose($fh);
}
-
- // Get user information about aliases
- $user_get_alias_details = user_get_alias_details($username);
- $user_get_alias_details['direct_aliases'] = array_filter($user_get_alias_details['direct_aliases']);
- $user_get_alias_details['shared_aliases'] = array_filter($user_get_alias_details['shared_aliases']);
- $user_domains[] = mailbox('get', 'mailbox_details', $username)['domain'];
- $user_alias_domains = $user_get_alias_details['alias_domains'];
- if (!empty($user_alias_domains)) {
- $user_domains = array_merge($user_domains, $user_alias_domains);
- }
-
- // get number of app passwords
- $number_of_app_passwords = 0;
- foreach (app_passwd("get") as $app_password)
- {
- $app_password = app_passwd("details", $app_password['id']);
- if ($app_password['active'])
- {
- $number_of_app_passwords++;
- }
- }
-
- $template = 'user.twig';
- $template_data = [
- 'acl' => $_SESSION['acl'],
- 'acl_json' => json_encode($_SESSION['acl']),
- 'user_spam_score' => mailbox('get', 'spam_score', $username),
- 'tfa_data' => $tfa_data,
- 'tfa_id' => @$_SESSION['tfa_id'],
- 'fido2_data' => $fido2_data,
- 'mailboxdata' => $mailboxdata,
- 'clientconfigstr' => $clientconfigstr,
- 'user_get_alias_details' => $user_get_alias_details,
- 'get_tagging_options' => mailbox('get', 'delimiter_action', $username),
- 'get_tls_policy' => mailbox('get', 'tls_policy', $username),
- 'quarantine_notification' => mailbox('get', 'quarantine_notification', $username),
- 'quarantine_category' => mailbox('get', 'quarantine_category', $username),
- 'user_domains' => $user_domains,
- 'pushover_data' => $pushover_data,
- 'lang_user' => json_encode($lang['user']),
- 'number_of_app_passwords' => $number_of_app_passwords,
- 'lang_datatables' => json_encode($lang['datatables']),
- ];
}
-else {
- header('Location: /');
- exit();
+
+// Get user information about aliases
+$user_get_alias_details = user_get_alias_details($username);
+$user_get_alias_details['direct_aliases'] = array_filter($user_get_alias_details['direct_aliases']);
+$user_get_alias_details['shared_aliases'] = array_filter($user_get_alias_details['shared_aliases']);
+$user_domains[] = mailbox('get', 'mailbox_details', $username)['domain'];
+$user_alias_domains = $user_get_alias_details['alias_domains'];
+if (!empty($user_alias_domains)) {
+ $user_domains = array_merge($user_domains, $user_alias_domains);
}
+// get number of app passwords
+$number_of_app_passwords = 0;
+foreach (app_passwd("get") as $app_password)
+{
+ $app_password = app_passwd("details", $app_password['id']);
+ if ($app_password['active'])
+ {
+ $number_of_app_passwords++;
+ }
+}
+
+$template = 'user.twig';
+$template_data = [
+ 'acl' => $_SESSION['acl'],
+ 'acl_json' => json_encode($_SESSION['acl']),
+ 'user_spam_score' => mailbox('get', 'spam_score', $username),
+ 'tfa_data' => $tfa_data,
+ 'tfa_id' => @$_SESSION['tfa_id'],
+ 'fido2_data' => $fido2_data,
+ 'mailboxdata' => $mailboxdata,
+ 'clientconfigstr' => $clientconfigstr,
+ 'user_get_alias_details' => $user_get_alias_details,
+ 'get_tagging_options' => mailbox('get', 'delimiter_action', $username),
+ 'get_tls_policy' => mailbox('get', 'tls_policy', $username),
+ 'quarantine_notification' => mailbox('get', 'quarantine_notification', $username),
+ 'quarantine_category' => mailbox('get', 'quarantine_category', $username),
+ 'user_domains' => $user_domains,
+ 'pushover_data' => $pushover_data,
+ 'lang_user' => json_encode($lang['user']),
+ 'number_of_app_passwords' => $number_of_app_passwords,
+ 'lang_datatables' => json_encode($lang['datatables']),
+];
+
$js_minifier->add('/web/js/site/user.js');
$js_minifier->add('/web/js/site/pwgen.js');