aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKim Sindalsen <gentoo@vlh.dk>2024-01-06 17:58:57 +0100
committerKim Sindalsen <gentoo@vlh.dk>2024-01-06 17:58:57 +0100
commit34d6f5d31e57abfadd476ab3b3ea425d34f92e53 (patch)
treea4d7583c9e69a3993398261f328727c19f8bc4ac /mail-filter
parentapp-crypt/PBinCLI: add 0.3.5 (diff)
downloadguru-34d6f5d31e57abfadd476ab3b3ea425d34f92e53.tar.gz
guru-34d6f5d31e57abfadd476ab3b3ea425d34f92e53.tar.bz2
guru-34d6f5d31e57abfadd476ab3b3ea425d34f92e53.zip
mail-filter/postfix-mta-sts-resolver: new package, add 1.4.0
Signed-off-by: Kim Sindalsen <gentoo@vlh.dk>
Diffstat (limited to 'mail-filter')
-rw-r--r--mail-filter/postfix-mta-sts-resolver/Manifest1
-rw-r--r--mail-filter/postfix-mta-sts-resolver/files/mtasts-confd10
-rw-r--r--mail-filter/postfix-mta-sts-resolver/files/mtasts-config36
-rw-r--r--mail-filter/postfix-mta-sts-resolver/files/mtasts-initd18
-rw-r--r--mail-filter/postfix-mta-sts-resolver/postfix-mta-sts-resolver-1.4.0.ebuild50
5 files changed, 115 insertions, 0 deletions
diff --git a/mail-filter/postfix-mta-sts-resolver/Manifest b/mail-filter/postfix-mta-sts-resolver/Manifest
new file mode 100644
index 000000000..ce261f6e3
--- /dev/null
+++ b/mail-filter/postfix-mta-sts-resolver/Manifest
@@ -0,0 +1 @@
+DIST postfix-mta-sts-resolver-1.4.0.tar.gz 54714 BLAKE2B a0ca683f56c5f0f94d0622cacae034fed7c8d76b2d4ae67feb29259e1093fa98241fd18340aab205115b1ffd78b744aa0eb689c62fe9e161aaf49ea32a9fb384 SHA512 e7e566f124f3ae8e61d4cd1ba93aa276773331e11a4497d9e69eb01aa2548dc9219b1dba874d81a84a3796705dcbdba2c2d673b2449c4241a2977c02207a92f4
diff --git a/mail-filter/postfix-mta-sts-resolver/files/mtasts-confd b/mail-filter/postfix-mta-sts-resolver/files/mtasts-confd
new file mode 100644
index 000000000..4f6be0089
--- /dev/null
+++ b/mail-filter/postfix-mta-sts-resolver/files/mtasts-confd
@@ -0,0 +1,10 @@
+# /etc/conf.d/mta-sts
+
+# Configuration file
+MTASTS_CONFIGFILE="/etc/mta-sts-daemon.yml"
+
+# PID file
+MTASTS_PIDFILE="/run/mta-sts.pid"
+
+# Options to mta-sts-daemon
+MTASTS_OPTS="-l /var/log/mta-sts.log -v debug"
diff --git a/mail-filter/postfix-mta-sts-resolver/files/mtasts-config b/mail-filter/postfix-mta-sts-resolver/files/mtasts-config
new file mode 100644
index 000000000..529759bdb
--- /dev/null
+++ b/mail-filter/postfix-mta-sts-resolver/files/mtasts-config
@@ -0,0 +1,36 @@
+# Default config for mta-sts-daemon
+# If path/mode is set, host/port is ignored
+host: 127.0.0.1
+port: 8461
+#path: "/var/run/mta-sts.sock"
+#mode: 0666
+reuse_port: true
+cache_grace: 60
+shutdown_timeout: 20
+# Select one type of cache
+cache:
+ type: internal
+ options:
+ cache_size: 10000
+# type: redis
+# options:
+# url: "redis://127.0.0.1/0"
+# max_connections: 25
+# socket_timeout: 1.0
+# socket_connect_timeout: 1.0
+# type: sqlite
+# options:
+# filename: "/var/lib/mta-sts/cache.db"
+proactive_policy_fetching:
+ enabled: false
+ interval: 86400
+ concurrency_limit: 100
+ grace_ratio: 2.0
+default_zone:
+ strict_testing: false
+ timeout: 4
+ require_sni: true
+#zones:
+# myzone:
+# strict_testing: false
+# timeout: 4
diff --git a/mail-filter/postfix-mta-sts-resolver/files/mtasts-initd b/mail-filter/postfix-mta-sts-resolver/files/mtasts-initd
new file mode 100644
index 000000000..3562db135
--- /dev/null
+++ b/mail-filter/postfix-mta-sts-resolver/files/mtasts-initd
@@ -0,0 +1,18 @@
+#!/sbin/openrc-run
+# Copyright 2015-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+depend() {
+ use net
+ before postfix
+}
+
+command="/usr/bin/mta-sts-daemon"
+command_args="${MTASTS_OPTS} -c ${MTASTS_CONFIGFILE}"
+command_background="yes"
+
+pidfile="${MTASTS_PIDFILE}"
+
+required_files="${MTASTS_CONFIGFILE}"
+
+description="Postfix MTA-STS resolver"
diff --git a/mail-filter/postfix-mta-sts-resolver/postfix-mta-sts-resolver-1.4.0.ebuild b/mail-filter/postfix-mta-sts-resolver/postfix-mta-sts-resolver-1.4.0.ebuild
new file mode 100644
index 000000000..bb1a56340
--- /dev/null
+++ b/mail-filter/postfix-mta-sts-resolver/postfix-mta-sts-resolver-1.4.0.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PYTHON_COMPAT=( python3_{10..12} )
+PYPI_NO_NORMALIZE=1
+DISTUTILS_USE_PEP517=setuptools
+inherit distutils-r1 pypi
+
+DESCRIPTION="Daemon which provides TLS client policy for Postfix via socketmap, according to domain MTA-STS policy"
+HOMEPAGE="https://github.com/Snawoot/postfix-mta-sts-resolver https://pypi.org/project/postfix-mta-sts-resolver/"
+SRC_URI="https://github.com/Snawoot/postfix-mta-sts-resolver/releases/download/v${PV}/${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="uvloop sqlite redis postgres"
+
+DOCS="README.md"
+
+RDEPEND="
+ ${PYTHON_DEPS}
+ dev-python/aiodns[${PYTHON_USEDEP}]
+ dev-python/aiohttp[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+ postgres? (
+ dev-python/asyncpg[${PYTHON_USEDEP}]
+ )
+ sqlite? (
+ dev-python/aiosqlite[${PYTHON_USEDEP}]
+ )
+ redis? (
+ dev-python/redis[${PYTHON_USEDEP}]
+ )
+ uvloop? (
+ dev-python/uvloop[${PYTHON_USEDEP}]
+ )
+"
+DEPEND="${RDEPEND}"
+
+distutils_enable_tests pytest
+
+python_install() {
+ distutils-r1_python_install
+
+ newinitd "${FILESDIR}"/mtasts-initd mta-sts
+ newconfd "${FILESDIR}"/mtasts-confd mta-sts
+ insinto /etc/
+ newins "${FILESDIR}"/mtasts-config mta-sts-daemon.yml
+}