From ab73c5e7f5a4a63d2d2762232949145f0989f8c2 Mon Sep 17 00:00:00 2001 From: imax-ua Date: Wed, 10 Apr 2024 21:33:43 +0000 Subject: [PATCH] =?UTF-8?q?=D0=A7=D0=B8=D1=81=D1=82=D0=BA=D0=B0=20=D1=81?= =?UTF-8?q?=D1=82=D0=B0=D1=80=D1=8B=D1=85=20ebuild?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- net-analyzer/zabbix-agent/Manifest | 8 - .../files/zabbix-agent-3.0.30-mysql8.patch | 17 - ...gent-3.0.30-security-disable-PidFile.patch | 49 --- ...bbix-agent-3.0.31-fix-cve-2020-15803.patch | 83 ----- .../zabbix-agent-4.0.18-modulepathfix.patch | 11 - .../zabbix-agent/files/zabbix-agentd.init | 20 -- .../zabbix-agent/files/zabbix-agentd.tmpfiles | 1 - .../zabbix-agent/zabbix-agent-5.2.1.ebuild | 131 ------- net-analyzer/zabbix-server/Manifest | 14 - .../zabbix-server/files/zabbix-jmx-proxy.conf | 12 - .../zabbix-server/files/zabbix-jmx-proxy.init | 33 -- .../zabbix-server/files/zabbix-proxy.init | 20 -- .../zabbix-server/files/zabbix-proxy.tmpfiles | 1 - .../files/zabbix-server-3.0.30-mysql8.patch | 17 - ...rver-3.0.30-security-disable-PidFile.patch | 49 --- ...bix-server-3.0.31-fix-cve-2020-15803.patch | 83 ----- .../zabbix-server-4.0.18-modulepathfix.patch | 11 - .../zabbix-server/files/zabbix-server.init | 19 -- .../files/zabbix-server.tmpfiles | 1 - .../zabbix-server/zabbix-server-5.0.4.ebuild | 322 ------------------ .../zabbix-server/zabbix-server-5.2.1.ebuild | 320 ----------------- 21 files changed, 1222 deletions(-) delete mode 100644 net-analyzer/zabbix-agent/Manifest delete mode 100644 net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-mysql8.patch delete mode 100644 net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-security-disable-PidFile.patch delete mode 100644 net-analyzer/zabbix-agent/files/zabbix-agent-3.0.31-fix-cve-2020-15803.patch delete mode 100644 net-analyzer/zabbix-agent/files/zabbix-agent-4.0.18-modulepathfix.patch delete mode 100644 net-analyzer/zabbix-agent/files/zabbix-agentd.init delete mode 100644 net-analyzer/zabbix-agent/files/zabbix-agentd.tmpfiles delete mode 100644 net-analyzer/zabbix-agent/zabbix-agent-5.2.1.ebuild delete mode 100644 net-analyzer/zabbix-server/Manifest delete mode 100644 net-analyzer/zabbix-server/files/zabbix-jmx-proxy.conf delete mode 100644 net-analyzer/zabbix-server/files/zabbix-jmx-proxy.init delete mode 100644 net-analyzer/zabbix-server/files/zabbix-proxy.init delete mode 100644 net-analyzer/zabbix-server/files/zabbix-proxy.tmpfiles delete mode 100644 net-analyzer/zabbix-server/files/zabbix-server-3.0.30-mysql8.patch delete mode 100644 net-analyzer/zabbix-server/files/zabbix-server-3.0.30-security-disable-PidFile.patch delete mode 100644 net-analyzer/zabbix-server/files/zabbix-server-3.0.31-fix-cve-2020-15803.patch delete mode 100644 net-analyzer/zabbix-server/files/zabbix-server-4.0.18-modulepathfix.patch delete mode 100644 net-analyzer/zabbix-server/files/zabbix-server.init delete mode 100644 net-analyzer/zabbix-server/files/zabbix-server.tmpfiles delete mode 100644 net-analyzer/zabbix-server/zabbix-server-5.0.4.ebuild delete mode 100644 net-analyzer/zabbix-server/zabbix-server-5.2.1.ebuild diff --git a/net-analyzer/zabbix-agent/Manifest b/net-analyzer/zabbix-agent/Manifest deleted file mode 100644 index 42d09fa..0000000 --- a/net-analyzer/zabbix-agent/Manifest +++ /dev/null @@ -1,8 +0,0 @@ -AUX zabbix-agent-3.0.30-mysql8.patch 608 BLAKE2B 56e2cb893269cdeefbc6ca7c40e73b9af2012e4075d997369c516253211d6de6266a1f565ecbf39cd4520fe76f65968d43320ea8e5b2cd59d2a0eb9f8febc9f4 SHA512 13e95e0f3fd1aff4f2546ce5b3cb48c59e117984192a2574d799ca062ce763982d2984e5fa94b49f077aaebbbb3442a06a0d9982a38a21f5ea739fd0fed87148 -AUX zabbix-agent-3.0.30-security-disable-PidFile.patch 1378 BLAKE2B c1efdfd0b223987c9d9bf1a3f7731f0bdfeb42d1641bbf4387d70ece757f5cb2fb88bafb87f6938a5efbec091f73d5fde0450e8aa0edc3143d589df5efbe5d19 SHA512 854b198b980e4b58dc6149e285bfa6361ab2a10b83a6d8f07b46754316d6764669e68da8018b402b59317ed95b50a13d25f68f28c4c33d76f0ef1e8dedc8da99 -AUX zabbix-agent-3.0.31-fix-cve-2020-15803.patch 3081 BLAKE2B 269b3efedf4f2f4c5365f2119ae166a0bee673841ab0eeae1f3e6311d7015fd35b11330a62c705a567775429319bd440adff48f92c689d35104893eab82a86ec SHA512 950dfe3311dc74fc9068b1c51d22f2a9b2ff20c9011e551151b1aed8212ab26cd5ec369317ec5ad9b52193f59d5f79298205996dd9f2aec48608759769c63c85 -AUX zabbix-agent-4.0.18-modulepathfix.patch 330 BLAKE2B 99b3f1082e220ff842e4c4c86e8fcf57666443dd1e124412f167548ab886352077e1f0548e49cf77f28a51d20cc37dc980448eb87c9e7814ac73dcbfe43388e0 SHA512 75330dddde2f47553ac6a6f71d6f2383ab34c0d64ac5dbe45dd31707d8797d1400215d698072df3a0f0eaf862f00509791a6a0eaa43a0f686657d885c03465b5 -AUX zabbix-agentd.init 507 BLAKE2B 6d5f0e631639e766d6857304d205acbdf4d07b59deb43be2735d8caf1b3d9d156dfc3c54236b435383d0182869b8f5eb6cb45499a6dac010f5ea497f4533f80b SHA512 7dbdb94dee4bef1c5771ea02169b7f4d0a21e9d2c4ce44db1376562309e1a24455beb16e65a4bb049a1e713cb51bf38ed39ba48da5cf3c8969b6860bcbe74fc5 -AUX zabbix-agentd.tmpfiles 35 BLAKE2B 98e917ef03bd6dc5d73e5cbdb140c7e115c7593d5cebf2df9bf3d15713b16c6a44b165a3f68fd36a9119163144a2761457d16ce318bd094ed76ae6040c8b09df SHA512 3c63a2791e6ac77cb3144eb47a275cc8748f5c8943a076052300d6964994b95b18d60f504584fdcb683739dc514261402895e3f30ae2fbdb218acbc42c3d72df -DIST zabbix-agent-5.2.1.tar.gz 19869170 BLAKE2B 6f1a22533606eb875e2d2263e29d9882252cf7024c78071a2fe3ec97b691e26497ef8e9dbf032a0c3dbe84c525a46b601baaa2ac3cf30eb05c37062cdd77105c SHA512 74d0407d85e477be2c504f37c8118406acd3cd06d02f72f197d6c8917e3230eab21c328a883860d5ffed2980c8a27d42ba46ec80cd67878ca1771b2db1868db2 -EBUILD zabbix-agent-5.2.1.ebuild 2707 BLAKE2B c204ea54f9dca6b4e4da3dd596ad1938c0cc936c609fdba974a2490d4d902c71d2e1ac78007b65f30d53f0a4ac902775e1e71f40e03c2cd19b7519a260dc1414 SHA512 83cc2727859c33dd91c855d77e0a27bc536b742ec1689a6ff75ee4dbcfb43b8f628160afa7c5176712dc1b204fc81d196e5309192b7460fb7dd22b16153d77e0 diff --git a/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-mysql8.patch b/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-mysql8.patch deleted file mode 100644 index 7c3694a..0000000 --- a/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-mysql8.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff --git a/src/libs/zbxdb/db.c b/src/libs/zbxdb/db.c -index a65b9c4..e011c51 100644 ---- a/src/libs/zbxdb/db.c -+++ b/src/libs/zbxdb/db.c -@@ -285,7 +285,11 @@ int zbx_db_connect(char *host, char *user, char *password, char *dbname, char *d - #if defined(HAVE_IBM_DB2) - char *connect = NULL; - #elif defined(HAVE_MYSQL) -- my_bool mysql_reconnect = 1; -+#if LIBMYSQL_VERSION_ID >= 80000 /* my_bool type is removed in MySQL 8.0 */ -+ bool mysql_reconnect = 1; -+#else -+ my_bool mysql_reconnect = 1; -+#endif - #elif defined(HAVE_ORACLE) - char *connect = NULL; - sword err = OCI_SUCCESS; diff --git a/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-security-disable-PidFile.patch b/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-security-disable-PidFile.patch deleted file mode 100644 index e0fd74d..0000000 --- a/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.30-security-disable-PidFile.patch +++ /dev/null @@ -1,49 +0,0 @@ -diff --git a/conf/zabbix_agentd.conf b/conf/zabbix_agentd.conf -index b73bd45..c10daca 100644 ---- a/conf/zabbix_agentd.conf -+++ b/conf/zabbix_agentd.conf -@@ -5,6 +5,7 @@ - - ### Option: PidFile - # Name of PID file. -+# THIS PARAMETER IS IGNORED IN GENTOO FOR SECURITY REASONS (https://bugs.gentoo.org/629884) - # - # Mandatory: no - # Default: -diff --git a/conf/zabbix_proxy.conf b/conf/zabbix_proxy.conf -index 082f14e..de0284d 100644 ---- a/conf/zabbix_proxy.conf -+++ b/conf/zabbix_proxy.conf -@@ -109,6 +109,7 @@ LogFile=/tmp/zabbix_proxy.log - - ### Option: PidFile - # Name of PID file. -+# THIS PARAMETER IS IGNORED IN GENTOO FOR SECURITY REASONS (https://bugs.gentoo.org/629884) - # - # Mandatory: no - # Default: -diff --git a/conf/zabbix_server.conf b/conf/zabbix_server.conf -index 9f754ca..3999196 100644 ---- a/conf/zabbix_server.conf -+++ b/conf/zabbix_server.conf -@@ -62,6 +62,7 @@ LogFile=/tmp/zabbix_server.log - - ### Option: PidFile - # Name of PID file. -+# THIS PARAMETER IS IGNORED IN GENTOO FOR SECURITY REASONS (https://bugs.gentoo.org/629884) - # - # Mandatory: no - # Default: -diff --git a/src/libs/zbxnix/pid.c b/src/libs/zbxnix/pid.c -index baa8415..04c7e0c 100644 ---- a/src/libs/zbxnix/pid.c -+++ b/src/libs/zbxnix/pid.c -@@ -26,6 +26,8 @@ static int fdpid = -1; - - int create_pid_file(const char *pidfile) - { -+ return SUCCEED; -+ - int fd; - zbx_stat_t buf; - struct flock fl; diff --git a/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.31-fix-cve-2020-15803.patch b/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.31-fix-cve-2020-15803.patch deleted file mode 100644 index 0cca603..0000000 --- a/net-analyzer/zabbix-agent/files/zabbix-agent-3.0.31-fix-cve-2020-15803.patch +++ /dev/null @@ -1,83 +0,0 @@ -diff --git a/frontends/php/include/classes/screens/CScreenUrl.php b/frontends/php/include/classes/screens/CScreenUrl.php -index e35c5f1..1df396e 100644 ---- a/frontends/php/include/classes/screens/CScreenUrl.php -+++ b/frontends/php/include/classes/screens/CScreenUrl.php -@@ -29,18 +29,10 @@ class CScreenUrl extends CScreenBase { - public function get() { - // prevent from resolving macros in configuration page - if ($this->mode != SCREEN_MODE_PREVIEW && $this->mode != SCREEN_MODE_SLIDESHOW) { -- return $this->getOutput( -- CHtmlUrlValidator::validate($this->screenitem['url'], false) -- ? new CIFrame($this->screenitem['url'], $this->screenitem['width'], $this->screenitem['height'], -- 'auto') -- : makeMessageBox(false, [[ -- 'type' => 'error', -- 'message' => _s('Provided URL "%1$s" is invalid.', $this->screenitem['url']) -- ]] -- ) -- ); -+ return $this->getOutput($this->prepareElement()); - } -- elseif ($this->screenitem['dynamic'] == SCREEN_DYNAMIC_ITEM && $this->hostid == 0) { -+ -+ if ($this->screenitem['dynamic'] == SCREEN_DYNAMIC_ITEM && $this->hostid == 0) { - return $this->getOutput((new CTableInfo())->setNoDataMessage(_('No host selected.'))); - } - -@@ -54,14 +46,28 @@ class CScreenUrl extends CScreenBase { - - $this->screenitem['url'] = $url ? $url : $this->screenitem['url']; - -- return $this->getOutput( -- CHtmlUrlValidator::validate($this->screenitem['url'], false) -- ? new CIFrame($this->screenitem['url'], $this->screenitem['width'], $this->screenitem['height'], 'auto') -- : makeMessageBox(false, [[ -- 'type' => 'error', -- 'message' => _s('Provided URL "%1$s" is invalid.', $this->screenitem['url']) -- ]] -- ) -- ); -+ return $this->getOutput($this->prepareElement()); -+ } -+ -+ /** -+ * @return CTag -+ */ -+ public function prepareElement() { -+ if (CHtmlUrlValidator::validate($this->screenitem['url'], false)) { -+ $item = new CIFrame($this->screenitem['url'], $this->screenitem['width'], $this->screenitem['height'], -+ 'auto' -+ ); -+ -+ if (ZBX_IFRAME_SANDBOX !== false) { -+ $item->setAttribute('sandbox', ZBX_IFRAME_SANDBOX); -+ } -+ -+ return $item; -+ } -+ -+ return makeMessageBox(false, [[ -+ 'type' => 'error', -+ 'message' => _s('Provided URL "%1$s" is invalid.', $this->screenitem['url']) -+ ]]); - } - } -diff --git a/frontends/php/include/defines.inc.php b/frontends/php/include/defines.inc.php -index a67a625..c6a437c 100644 ---- a/frontends/php/include/defines.inc.php -+++ b/frontends/php/include/defines.inc.php -@@ -1284,6 +1284,14 @@ if (function_exists('bcscale')) { - bcscale(7); - } - -+/** -+ * The sandbox attribute enables an extra set of restrictions for the content in the iframe. Default is set to empty -+ * string, which means all restrictions are applied. To disable, set to FALSE. To set a specific set of restrictions, -+ * write a custom string. -+ * https://www.w3.org/TR/2010/WD-html5-20100624/the-iframe-element.html#attr-iframe-sandbox -+ */ -+define('ZBX_IFRAME_SANDBOX', ''); -+ - // HTTP headers - /* - * Value of HTTP X-Frame-options header. diff --git a/net-analyzer/zabbix-agent/files/zabbix-agent-4.0.18-modulepathfix.patch b/net-analyzer/zabbix-agent/files/zabbix-agent-4.0.18-modulepathfix.patch deleted file mode 100644 index c0d1650..0000000 --- a/net-analyzer/zabbix-agent/files/zabbix-agent-4.0.18-modulepathfix.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- zabbix-4.0.1/configure 2018-10-29 10:36:05.000000000 -0700 -+++ zfx/configure 2018-11-07 16:59:28.015968345 -0800 -@@ -12510,7 +12510,7 @@ - CURL_SSL_CERT_LOCATION="${datadir}/zabbix/ssl/certs" - CURL_SSL_KEY_LOCATION="${datadir}/zabbix/ssl/keys" - --LOAD_MODULE_PATH="${libdir}/modules" -+LOAD_MODULE_PATH="${libdir}/zabbix" - - - diff --git a/net-analyzer/zabbix-agent/files/zabbix-agentd.init b/net-analyzer/zabbix-agent/files/zabbix-agentd.init deleted file mode 100644 index e2433ff..0000000 --- a/net-analyzer/zabbix-agent/files/zabbix-agentd.init +++ /dev/null @@ -1,20 +0,0 @@ -#!/sbin/openrc-run -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -command="/usr/sbin/zabbix_agentd" -command_args="--foreground --config /etc/zabbix/zabbix_agentd.conf" -command_background="true" -command_user="zabbix:zabbix" -pidfile="/run/${RC_SVCNAME}.pid" - -depend() { - need net - provide zabbix-agent - use zabbix-server -} - -start_pre() { - checkpath -q -d -m 0750 -o root:zabbix /etc/zabbix - checkpath -q -f -m 0640 -o root:zabbix /etc/zabbix/*.conf -} diff --git a/net-analyzer/zabbix-agent/files/zabbix-agentd.tmpfiles b/net-analyzer/zabbix-agent/files/zabbix-agentd.tmpfiles deleted file mode 100644 index 56471bb..0000000 --- a/net-analyzer/zabbix-agent/files/zabbix-agentd.tmpfiles +++ /dev/null @@ -1 +0,0 @@ -d /run/zabbix 0755 zabbix zabbix - diff --git a/net-analyzer/zabbix-agent/zabbix-agent-5.2.1.ebuild b/net-analyzer/zabbix-agent/zabbix-agent-5.2.1.ebuild deleted file mode 100644 index 2030f5d..0000000 --- a/net-analyzer/zabbix-agent/zabbix-agent-5.2.1.ebuild +++ /dev/null @@ -1,131 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -# needed to make webapp-config dep optional -WEBAPP_OPTIONAL="yes" -inherit flag-o-matic user toolchain-funcs - -DESCRIPTION="ZABBIX is software for monitoring of your applications, network and servers" -HOMEPAGE="https://www.zabbix.com/" -MY_P=${P/_/} -MY_PV=${PV/_/} -SRC_URI="http://mirror.imax.name/src/zabbix/${PV}/${P}.tar.gz" -LICENSE="GPL-2" -SLOT="0" -WEBAPP_MANUAL_SLOT="yes" -KEYWORDS="amd64 x86" -IUSE="+agent java curl ipv6 libxml2 ssh ssl snmp static" -REQUIRED_USE="|| ( agent ) - static? ( !snmp )" - -COMMON_DEPEND=" - curl? ( net-misc/curl ) - libxml2? ( dev-libs/libxml2 ) - snmp? ( net-analyzer/net-snmp ) - ssh? ( net-libs/libssh2 ) - ssl? ( dev-libs/openssl:=[-bindist] ) -" - -DEPEND="${COMMON_DEPEND} - static? ( - curl? ( net-misc/curl[static-libs] ) - libxml2? ( dev-libs/libxml2[static-libs] ) - ssh? ( net-libs/libssh2 ) - ) -" -BDEPEND=" - virtual/pkgconfig -" - -PATCHES=( - "${FILESDIR}/${PN}-4.0.18-modulepathfix.patch" - "${FILESDIR}/${PN}-3.0.30-security-disable-PidFile.patch" -) - -S=${WORKDIR}/${MY_P} - - -pkg_setup() { - - enewgroup zabbix - enewuser zabbix -1 -1 /var/lib/zabbix/home zabbix - -} - -src_prepare() { - default -} - -src_configure() { - econf \ - $(use_enable agent) \ - $(use_enable ipv6) \ - $(use_enable static) \ - $(use_with curl libcurl) \ - $(use_with libxml2) \ - $(use_with snmp net-snmp) \ - $(use_with ssh ssh2) \ - $(use_with ssl openssl) -} - -src_compile() { - if [ -f Makefile ] || [ -f GNUmakefile ] || [ -f makefile ]; then - emake AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" - fi -} - -src_install() { - local dirs=( - /etc/zabbix - /var/log/zabbix - ) - - for dir in "${dirs[@]}"; do - dodir "${dir}" - keepdir "${dir}" - done - - if use agent; then - insinto /etc/zabbix - doins "${S}"/conf/zabbix_agentd.conf - fperms 0640 /etc/zabbix/zabbix_agentd.conf - fowners root:zabbix /etc/zabbix/zabbix_agentd.conf - - newinitd "${FILESDIR}"/zabbix-agentd.init zabbix-agentd - - dosbin src/zabbix_agent/zabbix_agentd - dobin \ - src/zabbix_sender/zabbix_sender \ - src/zabbix_get/zabbix_get - - fi - - fowners root:zabbix /etc/zabbix - fowners zabbix:zabbix \ - /var/log/zabbix - fperms 0750 \ - /etc/zabbix \ - /var/log/zabbix - - dodoc README INSTALL NEWS ChangeLog \ - conf/zabbix_agentd.conf \ - conf/zabbix_agentd/userparameter_examples.conf \ - conf/zabbix_agentd/userparameter_mysql.conf \ - -} - -pkg_postinst() { - - elog "--" - elog - elog "You may need to add these lines to /etc/services:" - elog - elog "zabbix-agent 10050/tcp Zabbix Agent" - elog "zabbix-agent 10050/udp Zabbix Agent" - elog "zabbix-trapper 10051/tcp Zabbix Trapper" - elog "zabbix-trapper 10051/udp Zabbix Trapper" - elog - -} diff --git a/net-analyzer/zabbix-server/Manifest b/net-analyzer/zabbix-server/Manifest deleted file mode 100644 index 8dae87a..0000000 --- a/net-analyzer/zabbix-server/Manifest +++ /dev/null @@ -1,14 +0,0 @@ -AUX zabbix-jmx-proxy.conf 432 BLAKE2B 188737819d39b9e8ec8913237ff048a68ef19f2ec8849bab6c62bea612ac927d00a6c7042ba87261297ff580ef9976618d6acbd24c7fda8f6eb26b2b3dc891bb SHA512 0d68b9681528256131e35b5115053242f8558f5ad06254e61a16ab14f6530048551f0b777fa81d4afe07cc6282c31a6204fd0ee2e56e0e792ed3252222212250 -AUX zabbix-jmx-proxy.init 849 BLAKE2B 14a312911a11d765210f3bd86d38c8ce3a2f230c821a03d2dd3b2a2aaf05a86cf64a59ea283ad0f11b62fe17a81936cef03463e5cee6535f1a51558b7bad790a SHA512 79a1966405546899b2e6eb4cb53f0ea1ec70575cbf97ff0f9de16d662c5750f8bf276bf8eadaf00cb69ffa078b79e9144eb9824eec6a23df6b2cd315b79b05d8 -AUX zabbix-proxy.init 487 BLAKE2B b094521d1ec12ea27f1dec78a858ff3b78acde6a0473a2f8a53cbf46c75c3b0f72a1f44f24dc5294b7157576b06abc631dfed469dcf1a1c7b8c4609a9c81b2b8 SHA512 55f1df96d7d7e6ec16d16162e37a7a494131f4dd53d5988b28663b82a6bbe17b16e901a8f4870f14fd2e1c7dd96a84fe6aa5cd9e6a745462af7b83b3f0455839 -AUX zabbix-proxy.tmpfiles 35 BLAKE2B 98e917ef03bd6dc5d73e5cbdb140c7e115c7593d5cebf2df9bf3d15713b16c6a44b165a3f68fd36a9119163144a2761457d16ce318bd094ed76ae6040c8b09df SHA512 3c63a2791e6ac77cb3144eb47a275cc8748f5c8943a076052300d6964994b95b18d60f504584fdcb683739dc514261402895e3f30ae2fbdb218acbc42c3d72df -AUX zabbix-server-3.0.30-mysql8.patch 608 BLAKE2B 56e2cb893269cdeefbc6ca7c40e73b9af2012e4075d997369c516253211d6de6266a1f565ecbf39cd4520fe76f65968d43320ea8e5b2cd59d2a0eb9f8febc9f4 SHA512 13e95e0f3fd1aff4f2546ce5b3cb48c59e117984192a2574d799ca062ce763982d2984e5fa94b49f077aaebbbb3442a06a0d9982a38a21f5ea739fd0fed87148 -AUX zabbix-server-3.0.30-security-disable-PidFile.patch 1378 BLAKE2B c1efdfd0b223987c9d9bf1a3f7731f0bdfeb42d1641bbf4387d70ece757f5cb2fb88bafb87f6938a5efbec091f73d5fde0450e8aa0edc3143d589df5efbe5d19 SHA512 854b198b980e4b58dc6149e285bfa6361ab2a10b83a6d8f07b46754316d6764669e68da8018b402b59317ed95b50a13d25f68f28c4c33d76f0ef1e8dedc8da99 -AUX zabbix-server-3.0.31-fix-cve-2020-15803.patch 3081 BLAKE2B 269b3efedf4f2f4c5365f2119ae166a0bee673841ab0eeae1f3e6311d7015fd35b11330a62c705a567775429319bd440adff48f92c689d35104893eab82a86ec SHA512 950dfe3311dc74fc9068b1c51d22f2a9b2ff20c9011e551151b1aed8212ab26cd5ec369317ec5ad9b52193f59d5f79298205996dd9f2aec48608759769c63c85 -AUX zabbix-server-4.0.18-modulepathfix.patch 330 BLAKE2B 99b3f1082e220ff842e4c4c86e8fcf57666443dd1e124412f167548ab886352077e1f0548e49cf77f28a51d20cc37dc980448eb87c9e7814ac73dcbfe43388e0 SHA512 75330dddde2f47553ac6a6f71d6f2383ab34c0d64ac5dbe45dd31707d8797d1400215d698072df3a0f0eaf862f00509791a6a0eaa43a0f686657d885c03465b5 -AUX zabbix-server.init 494 BLAKE2B e58063bfdb0bcb6ea70325d31bff4ffebab2686b7063916619aaabc5b39b1ff5d960b968e382615f84b18531465cf0ad0eab5ffa171c0b4b1797e70d58ed3450 SHA512 7dd55ffe8062bee9104218bf673aeeeea56a4a332ef6a5676b83e7f026a2b6ebc70446c63d6116b684ad16abd95de355cdbdf07c81a51daf1424b3fd8d627c74 -AUX zabbix-server.tmpfiles 35 BLAKE2B 98e917ef03bd6dc5d73e5cbdb140c7e115c7593d5cebf2df9bf3d15713b16c6a44b165a3f68fd36a9119163144a2761457d16ce318bd094ed76ae6040c8b09df SHA512 3c63a2791e6ac77cb3144eb47a275cc8748f5c8943a076052300d6964994b95b18d60f504584fdcb683739dc514261402895e3f30ae2fbdb218acbc42c3d72df -DIST zabbix-server-5.0.4.tar.gz 19315019 BLAKE2B 45a13c835385bb9f039123385ab0512a20167b90e1faf6e79fff76908b2425fe71fefcef37612020200923bb06bec9e65d637ced71e82206953feb6a7e3d3f2e SHA512 8355a416d2f622c0c5c1834a12cc220d1ab4bca3e914f263a4dd11f9aba62dfa3fee6eb716a91e8e7b992cb30cf4fabaf444a3b62e1d261eb332e79ad61a5503 -DIST zabbix-server-5.2.1.tar.gz 19869073 BLAKE2B 3b0c07aa82183afa3f9760aa878bf3934e75e530b5cb259a393dc893da0e0339237bc286ea4bbf921b3eef1a2fb89e076f165ee3e0eb56e250cfaece76992ecc SHA512 eb45ce3d1209a516424fd0eddfff7cd95442031767b42ee6436bc85f24696452e05142c4b5bb8d004aa2d1079aca7f5eadcc53f9c649466c1637adfa893ced11 -EBUILD zabbix-server-5.0.4.ebuild 8169 BLAKE2B 2c34211df14cd85e11e05a0c638eeff77f8fbf90b2b4691f785fc7136e24d717a1b2ad05a9b3880c4885c9feee80407aeb3d09dab5a8bb5efba68b1068db01e7 SHA512 9e99c5071d505c99182209996af07bc551684507062f819e0b86ea398323fd6b81960058d12bb88b774c1aa1ae18973a5001949cfedfec429ec9d85072e164ab -EBUILD zabbix-server-5.2.1.ebuild 8064 BLAKE2B 41ae48e413a5a8c6ce287ce3454c9cde144eb3b1bc811b39ebb39bcaad4f16a5fdc9be10df18c88772f4c894c011aa06762de4f995bd4e57cfddb86509fef937 SHA512 4e9e540a0efa337207415399713a4619d0627b22336b925d6d08ddd732f3a357e532002a139ae6fd55f98c6632a89b9f8019ef05bff6a7b3c4784a860dac92e6 diff --git a/net-analyzer/zabbix-server/files/zabbix-jmx-proxy.conf b/net-analyzer/zabbix-server/files/zabbix-jmx-proxy.conf deleted file mode 100644 index 6aa3cf9..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-jmx-proxy.conf +++ /dev/null @@ -1,12 +0,0 @@ -# Configuration variables for the zabbix jmx proxy - - -# LISTEN_IP="0.0.0.0" -# LISTEN_PORT=10052 -# START_POLLERS=5 -# TIMEOUT=3 - -# uncomment to enable remote monitoring of the standard JMX objects on the Zabbix Java Gateway itself -# JAVA_OPTIONS="$JAVA_OPTIONS -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=12345 -# -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false" - diff --git a/net-analyzer/zabbix-server/files/zabbix-jmx-proxy.init b/net-analyzer/zabbix-server/files/zabbix-jmx-proxy.init deleted file mode 100644 index 5722814..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-jmx-proxy.init +++ /dev/null @@ -1,33 +0,0 @@ -#!/sbin/openrc-run - -LISTEN_IP=${LISTEN_IP:-127.0.0.1} -LISTEN_PORT=${LISTEN_PORT:-10052} -START_POLLERS=${START_POLLERS:-5} -TIMEOUT=${TIMEOUT:-3} - -PID_FILE="/run/zabbix-jmx-proxy" - - -start() { - ZABBIX_OPTIONS="-Dzabbix.pidFile=$PID_FILE \ - -Dzabbix.listenIP=$LISTEN_IP \ - -Dzabbix.listenPort=$LISTEN_PORT \ - -Dzabbix.startPollers=$START_POLLERS \ - -Dzabbix.timeout=$TIMEOUT \ - -Dsun.rmi.transport.tcp.responseTimeout=${TIMEOUT}000" - - JAVA_OPTIONS="-server $JAVA_OPTIONS -Dlogback.configurationFile=logback-console.xml" - - cd /opt/zabbix_java - - CLASSPATH="lib" - for jar in lib/*.jar bin/*.jar; do - CLASSPATH="$CLASSPATH:$jar" - done - - start-stop-daemon -m --background --pidfile $PID_FILE -- java $JAVA_OPTIONS -classpath $CLASSPATH $ZABBIX_OPTIONS com.zabbix.gateway.JavaGateway -} - -stop() { - start-stop-daemon --stop --pidfile $PID_FILE -} diff --git a/net-analyzer/zabbix-server/files/zabbix-proxy.init b/net-analyzer/zabbix-server/files/zabbix-proxy.init deleted file mode 100644 index 8347b48..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-proxy.init +++ /dev/null @@ -1,20 +0,0 @@ -#!/sbin/openrc-run -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -command="/usr/sbin/zabbix_proxy" -command_args="--foreground --config /etc/zabbix/zabbix_proxy.conf" -command_background="true" -command_user="zabbix:zabbix" -pidfile="/run/${RC_SVCNAME}.pid" - -depend() { - need net - provide zabbix-proxy -} - -start_pre() { - checkpath -q -d -m 0750 -o root:zabbix /etc/zabbix - checkpath -q -f -m 0640 -o root:zabbix /etc/zabbix/*.conf -} - diff --git a/net-analyzer/zabbix-server/files/zabbix-proxy.tmpfiles b/net-analyzer/zabbix-server/files/zabbix-proxy.tmpfiles deleted file mode 100644 index 56471bb..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-proxy.tmpfiles +++ /dev/null @@ -1 +0,0 @@ -d /run/zabbix 0755 zabbix zabbix - diff --git a/net-analyzer/zabbix-server/files/zabbix-server-3.0.30-mysql8.patch b/net-analyzer/zabbix-server/files/zabbix-server-3.0.30-mysql8.patch deleted file mode 100644 index 7c3694a..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-server-3.0.30-mysql8.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff --git a/src/libs/zbxdb/db.c b/src/libs/zbxdb/db.c -index a65b9c4..e011c51 100644 ---- a/src/libs/zbxdb/db.c -+++ b/src/libs/zbxdb/db.c -@@ -285,7 +285,11 @@ int zbx_db_connect(char *host, char *user, char *password, char *dbname, char *d - #if defined(HAVE_IBM_DB2) - char *connect = NULL; - #elif defined(HAVE_MYSQL) -- my_bool mysql_reconnect = 1; -+#if LIBMYSQL_VERSION_ID >= 80000 /* my_bool type is removed in MySQL 8.0 */ -+ bool mysql_reconnect = 1; -+#else -+ my_bool mysql_reconnect = 1; -+#endif - #elif defined(HAVE_ORACLE) - char *connect = NULL; - sword err = OCI_SUCCESS; diff --git a/net-analyzer/zabbix-server/files/zabbix-server-3.0.30-security-disable-PidFile.patch b/net-analyzer/zabbix-server/files/zabbix-server-3.0.30-security-disable-PidFile.patch deleted file mode 100644 index e0fd74d..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-server-3.0.30-security-disable-PidFile.patch +++ /dev/null @@ -1,49 +0,0 @@ -diff --git a/conf/zabbix_agentd.conf b/conf/zabbix_agentd.conf -index b73bd45..c10daca 100644 ---- a/conf/zabbix_agentd.conf -+++ b/conf/zabbix_agentd.conf -@@ -5,6 +5,7 @@ - - ### Option: PidFile - # Name of PID file. -+# THIS PARAMETER IS IGNORED IN GENTOO FOR SECURITY REASONS (https://bugs.gentoo.org/629884) - # - # Mandatory: no - # Default: -diff --git a/conf/zabbix_proxy.conf b/conf/zabbix_proxy.conf -index 082f14e..de0284d 100644 ---- a/conf/zabbix_proxy.conf -+++ b/conf/zabbix_proxy.conf -@@ -109,6 +109,7 @@ LogFile=/tmp/zabbix_proxy.log - - ### Option: PidFile - # Name of PID file. -+# THIS PARAMETER IS IGNORED IN GENTOO FOR SECURITY REASONS (https://bugs.gentoo.org/629884) - # - # Mandatory: no - # Default: -diff --git a/conf/zabbix_server.conf b/conf/zabbix_server.conf -index 9f754ca..3999196 100644 ---- a/conf/zabbix_server.conf -+++ b/conf/zabbix_server.conf -@@ -62,6 +62,7 @@ LogFile=/tmp/zabbix_server.log - - ### Option: PidFile - # Name of PID file. -+# THIS PARAMETER IS IGNORED IN GENTOO FOR SECURITY REASONS (https://bugs.gentoo.org/629884) - # - # Mandatory: no - # Default: -diff --git a/src/libs/zbxnix/pid.c b/src/libs/zbxnix/pid.c -index baa8415..04c7e0c 100644 ---- a/src/libs/zbxnix/pid.c -+++ b/src/libs/zbxnix/pid.c -@@ -26,6 +26,8 @@ static int fdpid = -1; - - int create_pid_file(const char *pidfile) - { -+ return SUCCEED; -+ - int fd; - zbx_stat_t buf; - struct flock fl; diff --git a/net-analyzer/zabbix-server/files/zabbix-server-3.0.31-fix-cve-2020-15803.patch b/net-analyzer/zabbix-server/files/zabbix-server-3.0.31-fix-cve-2020-15803.patch deleted file mode 100644 index 0cca603..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-server-3.0.31-fix-cve-2020-15803.patch +++ /dev/null @@ -1,83 +0,0 @@ -diff --git a/frontends/php/include/classes/screens/CScreenUrl.php b/frontends/php/include/classes/screens/CScreenUrl.php -index e35c5f1..1df396e 100644 ---- a/frontends/php/include/classes/screens/CScreenUrl.php -+++ b/frontends/php/include/classes/screens/CScreenUrl.php -@@ -29,18 +29,10 @@ class CScreenUrl extends CScreenBase { - public function get() { - // prevent from resolving macros in configuration page - if ($this->mode != SCREEN_MODE_PREVIEW && $this->mode != SCREEN_MODE_SLIDESHOW) { -- return $this->getOutput( -- CHtmlUrlValidator::validate($this->screenitem['url'], false) -- ? new CIFrame($this->screenitem['url'], $this->screenitem['width'], $this->screenitem['height'], -- 'auto') -- : makeMessageBox(false, [[ -- 'type' => 'error', -- 'message' => _s('Provided URL "%1$s" is invalid.', $this->screenitem['url']) -- ]] -- ) -- ); -+ return $this->getOutput($this->prepareElement()); - } -- elseif ($this->screenitem['dynamic'] == SCREEN_DYNAMIC_ITEM && $this->hostid == 0) { -+ -+ if ($this->screenitem['dynamic'] == SCREEN_DYNAMIC_ITEM && $this->hostid == 0) { - return $this->getOutput((new CTableInfo())->setNoDataMessage(_('No host selected.'))); - } - -@@ -54,14 +46,28 @@ class CScreenUrl extends CScreenBase { - - $this->screenitem['url'] = $url ? $url : $this->screenitem['url']; - -- return $this->getOutput( -- CHtmlUrlValidator::validate($this->screenitem['url'], false) -- ? new CIFrame($this->screenitem['url'], $this->screenitem['width'], $this->screenitem['height'], 'auto') -- : makeMessageBox(false, [[ -- 'type' => 'error', -- 'message' => _s('Provided URL "%1$s" is invalid.', $this->screenitem['url']) -- ]] -- ) -- ); -+ return $this->getOutput($this->prepareElement()); -+ } -+ -+ /** -+ * @return CTag -+ */ -+ public function prepareElement() { -+ if (CHtmlUrlValidator::validate($this->screenitem['url'], false)) { -+ $item = new CIFrame($this->screenitem['url'], $this->screenitem['width'], $this->screenitem['height'], -+ 'auto' -+ ); -+ -+ if (ZBX_IFRAME_SANDBOX !== false) { -+ $item->setAttribute('sandbox', ZBX_IFRAME_SANDBOX); -+ } -+ -+ return $item; -+ } -+ -+ return makeMessageBox(false, [[ -+ 'type' => 'error', -+ 'message' => _s('Provided URL "%1$s" is invalid.', $this->screenitem['url']) -+ ]]); - } - } -diff --git a/frontends/php/include/defines.inc.php b/frontends/php/include/defines.inc.php -index a67a625..c6a437c 100644 ---- a/frontends/php/include/defines.inc.php -+++ b/frontends/php/include/defines.inc.php -@@ -1284,6 +1284,14 @@ if (function_exists('bcscale')) { - bcscale(7); - } - -+/** -+ * The sandbox attribute enables an extra set of restrictions for the content in the iframe. Default is set to empty -+ * string, which means all restrictions are applied. To disable, set to FALSE. To set a specific set of restrictions, -+ * write a custom string. -+ * https://www.w3.org/TR/2010/WD-html5-20100624/the-iframe-element.html#attr-iframe-sandbox -+ */ -+define('ZBX_IFRAME_SANDBOX', ''); -+ - // HTTP headers - /* - * Value of HTTP X-Frame-options header. diff --git a/net-analyzer/zabbix-server/files/zabbix-server-4.0.18-modulepathfix.patch b/net-analyzer/zabbix-server/files/zabbix-server-4.0.18-modulepathfix.patch deleted file mode 100644 index c0d1650..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-server-4.0.18-modulepathfix.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- zabbix-4.0.1/configure 2018-10-29 10:36:05.000000000 -0700 -+++ zfx/configure 2018-11-07 16:59:28.015968345 -0800 -@@ -12510,7 +12510,7 @@ - CURL_SSL_CERT_LOCATION="${datadir}/zabbix/ssl/certs" - CURL_SSL_KEY_LOCATION="${datadir}/zabbix/ssl/keys" - --LOAD_MODULE_PATH="${libdir}/modules" -+LOAD_MODULE_PATH="${libdir}/zabbix" - - - diff --git a/net-analyzer/zabbix-server/files/zabbix-server.init b/net-analyzer/zabbix-server/files/zabbix-server.init deleted file mode 100644 index b0bf752..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-server.init +++ /dev/null @@ -1,19 +0,0 @@ -#!/sbin/openrc-run -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -command="/usr/sbin/zabbix_server" -command_args="--foreground --config /etc/zabbix/zabbix_server.conf" -command_background="true" -command_user="zabbix:zabbix" -pidfile="/run/${RC_SVCNAME}.pid" - -depend() { - need net - use mysql postgresql -} - -start_pre() { - checkpath -q -d -m 0750 -o root:zabbix /etc/zabbix - checkpath -q -f -m 0640 -o root:zabbix /etc/zabbix/*.conf -} diff --git a/net-analyzer/zabbix-server/files/zabbix-server.tmpfiles b/net-analyzer/zabbix-server/files/zabbix-server.tmpfiles deleted file mode 100644 index 56471bb..0000000 --- a/net-analyzer/zabbix-server/files/zabbix-server.tmpfiles +++ /dev/null @@ -1 +0,0 @@ -d /run/zabbix 0755 zabbix zabbix - diff --git a/net-analyzer/zabbix-server/zabbix-server-5.0.4.ebuild b/net-analyzer/zabbix-server/zabbix-server-5.0.4.ebuild deleted file mode 100644 index 000db75..0000000 --- a/net-analyzer/zabbix-server/zabbix-server-5.0.4.ebuild +++ /dev/null @@ -1,322 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -# needed to make webapp-config dep optional -WEBAPP_OPTIONAL="yes" -inherit flag-o-matic webapp java-pkg-opt-2 user systemd toolchain-funcs - -DESCRIPTION="ZABBIX is software for monitoring of your applications, network and servers" -HOMEPAGE="https://www.zabbix.com/" -MY_P=${P/_/} -MY_PV=${PV/_/} -SRC_URI="http://mirror.imax.name/src/zabbix/${PV}/${P}.tar.gz" -LICENSE="GPL-2" -SLOT="0" -WEBAPP_MANUAL_SLOT="yes" -KEYWORDS="amd64 x86" -IUSE="java curl +frontend ipv6 ldap libxml2 mysql openipmi oracle +postgres proxy +server ssh ssl snmp sqlite odbc static" -REQUIRED_USE="|| ( frontend proxy server ) - proxy? ( ^^ ( mysql oracle postgres sqlite odbc ) ) - server? ( ^^ ( mysql oracle postgres odbc ) ) - static? ( !oracle !snmp )" - -COMMON_DEPEND=" - curl? ( net-misc/curl ) - java? ( >=virtual/jdk-1.8:* ) - ldap? ( - =dev-libs/cyrus-sasl-2* - net-libs/gnutls - net-nds/openldap - ) - libxml2? ( dev-libs/libxml2 ) - mysql? ( dev-db/mysql-connector-c ) - odbc? ( dev-db/unixODBC ) - openipmi? ( sys-libs/openipmi ) - oracle? ( dev-db/oracle-instantclient-basic ) - postgres? ( dev-db/postgresql:* ) - proxy? ( sys-libs/zlib ) - server? ( - dev-libs/libevent - sys-libs/zlib - ) - snmp? ( net-analyzer/net-snmp ) - sqlite? ( dev-db/sqlite ) - ssh? ( net-libs/libssh2 ) - ssl? ( dev-libs/openssl:=[-bindist] ) -" - -RDEPEND="${COMMON_DEPEND} - java? ( >=virtual/jre-1.8:* ) - mysql? ( virtual/mysql ) - proxy? ( net-analyzer/fping[suid] ) - server? ( - app-admin/webapp-config - dev-libs/libevent - dev-libs/libpcre - net-analyzer/fping[suid] - ) - frontend? ( - app-admin/webapp-config - dev-lang/php:*[bcmath,ctype,sockets,gd,truetype,xml,session,xmlreader,xmlwriter,nls,sysvipc,unicode] - media-libs/gd[png] - virtual/httpd-php:* - mysql? ( dev-lang/php[mysqli] ) - odbc? ( dev-lang/php[odbc] ) - oracle? ( dev-lang/php[oci8-instant-client] ) - postgres? ( dev-lang/php[postgres] ) - sqlite? ( dev-lang/php[sqlite] ) - ) -" -DEPEND="${COMMON_DEPEND} - static? ( - curl? ( net-misc/curl[static-libs] ) - ldap? ( - =dev-libs/cyrus-sasl-2*[static-libs] - net-libs/gnutls[static-libs] - net-nds/openldap[static-libs] - ) - libxml2? ( dev-libs/libxml2[static-libs] ) - mysql? ( dev-db/mysql-connector-c[static-libs] ) - odbc? ( dev-db/unixODBC[static-libs] ) - postgres? ( dev-db/postgresql:*[static-libs] ) - sqlite? ( dev-db/sqlite[static-libs] ) - ssh? ( net-libs/libssh2 ) - ) -" -BDEPEND=" - virtual/pkgconfig -" - -PATCHES=( - "${FILESDIR}/${PN}-4.0.18-modulepathfix.patch" - "${FILESDIR}/${PN}-3.0.30-security-disable-PidFile.patch" -) - -S=${WORKDIR}/${MY_P} - -ZABBIXJAVA_BASE="opt/zabbix_java" - -pkg_setup() { - if use oracle; then - if [ -z "${ORACLE_HOME}" ]; then - eerror - eerror "The environment variable ORACLE_HOME must be set" - eerror "and point to the correct location." - eerror "It looks like you don't have Oracle installed." - eerror - die "Environment variable ORACLE_HOME is not set" - fi - if has_version 'dev-db/oracle-instantclient-basic'; then - ewarn - ewarn "Please ensure you have a full install of the Oracle client." - ewarn "dev-db/oracle-instantclient* is NOT sufficient." - ewarn - fi - fi - - if use frontend; then - webapp_pkg_setup - fi - - enewgroup zabbix - enewuser zabbix -1 -1 /var/lib/zabbix/home zabbix - - java-pkg-opt-2_pkg_setup -} - -src_prepare() { - default -} - -src_configure() { - econf \ - $(use_enable ipv6) \ - $(use_enable java) \ - $(use_enable proxy) \ - $(use_enable server) \ - $(use_enable static) \ - $(use_with curl libcurl) \ - $(use_with ldap) \ - $(use_with libxml2) \ - $(use_with mysql) \ - $(use_with odbc unixodbc) \ - $(use_with openipmi openipmi) \ - $(use_with oracle) \ - $(use_with postgres postgresql) \ - $(use_with snmp net-snmp) \ - $(use_with sqlite sqlite3) \ - $(use_with ssh ssh2) \ - $(use_with ssl openssl) -} - -src_compile() { - if [ -f Makefile ] || [ -f GNUmakefile ] || [ -f makefile ]; then - emake AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" - fi -} - -src_install() { - local dirs=( - /etc/zabbix - /var/lib/zabbix - /var/lib/zabbix/home - /var/lib/zabbix/scripts - /var/lib/zabbix/alertscripts - /var/lib/zabbix/externalscripts - /var/log/zabbix - ) - - for dir in "${dirs[@]}"; do - dodir "${dir}" - keepdir "${dir}" - done - - if use server; then - insinto /etc/zabbix - doins "${S}"/conf/zabbix_server.conf - fperms 0640 /etc/zabbix/zabbix_server.conf - fowners root:zabbix /etc/zabbix/zabbix_server.conf - - newinitd "${FILESDIR}"/zabbix-server.init zabbix-server - - dosbin src/zabbix_server/zabbix_server - - insinto /usr/share/zabbix - doins -r "${S}"/database/ - - fi - - if use proxy; then - insinto /etc/zabbix - doins "${S}"/conf/zabbix_proxy.conf - fperms 0640 /etc/zabbix/zabbix_proxy.conf - fowners root:zabbix /etc/zabbix/zabbix_proxy.conf - - newinitd "${FILESDIR}"/zabbix-proxy.init zabbix-proxy - - dosbin src/zabbix_proxy/zabbix_proxy - - insinto /usr/share/zabbix - doins -r "${S}"/database/ - - fi - - fowners root:zabbix /etc/zabbix - fowners zabbix:zabbix \ - /var/lib/zabbix \ - /var/lib/zabbix/home \ - /var/lib/zabbix/scripts \ - /var/lib/zabbix/alertscripts \ - /var/lib/zabbix/externalscripts \ - /var/log/zabbix - fperms 0750 \ - /etc/zabbix \ - /var/lib/zabbix \ - /var/lib/zabbix/home \ - /var/lib/zabbix/scripts \ - /var/lib/zabbix/alertscripts \ - /var/lib/zabbix/externalscripts \ - /var/log/zabbix - - dodoc README INSTALL NEWS ChangeLog \ - conf/zabbix_proxy.conf \ - conf/zabbix_agentd/userparameter_examples.conf \ - conf/zabbix_agentd/userparameter_mysql.conf \ - conf/zabbix_server.conf - - if use frontend; then - webapp_src_preinst - cp -R ui/* "${D}/${MY_HTDOCSDIR}" - webapp_configfile \ - "${MY_HTDOCSDIR}"/include/db.inc.php \ - "${MY_HTDOCSDIR}"/include/config.inc.php - webapp_src_install - fi - - if use java; then - dodir \ - /${ZABBIXJAVA_BASE} \ - /${ZABBIXJAVA_BASE}/bin \ - /${ZABBIXJAVA_BASE}/lib - keepdir /${ZABBIXJAVA_BASE} - exeinto /${ZABBIXJAVA_BASE}/bin - doexe src/zabbix_java/bin/zabbix-java-gateway-${MY_PV}.jar - exeinto /${ZABBIXJAVA_BASE}/lib - doexe \ - src/zabbix_java/lib/logback-classic-0.9.27.jar \ - src/zabbix_java/lib/logback-console.xml \ - src/zabbix_java/lib/logback-core-0.9.27.jar \ - src/zabbix_java/lib/logback.xml \ - src/zabbix_java/lib/android-json-4.3_r3.1.jar \ - src/zabbix_java/lib/slf4j-api-1.6.1.jar - newinitd "${FILESDIR}"/zabbix-jmx-proxy.init zabbix-jmx-proxy - newconfd "${FILESDIR}"/zabbix-jmx-proxy.conf zabbix-jmx-proxy - fi -} - -pkg_postinst() { - if use server || use proxy ; then - elog - elog "You may need to configure your database for Zabbix" - elog "if you have not already done so." - elog - - zabbix_homedir=$(egethome zabbix) - if [ -n "${zabbix_homedir}" ] && \ - [ "${zabbix_homedir}" != "/var/lib/zabbix/home" ]; then - ewarn - ewarn "The user 'zabbix' should have his homedir changed" - ewarn "to /var/lib/zabbix/home if you want to use" - ewarn "custom alert scripts." - ewarn - ewarn "A real homedir might be needed for configfiles" - ewarn "for custom alert scripts." - ewarn - ewarn "To change the homedir use:" - ewarn " usermod -d /var/lib/zabbix/home zabbix" - ewarn - fi - fi - - if use server; then - elog - elog "For distributed monitoring you have to run:" - elog - elog "zabbix_server -n " - elog - elog "This will convert database data for use with Node ID" - elog "and also adds a local node." - elog - fi - - elog "--" - elog - elog "You may need to add these lines to /etc/services:" - elog - elog "zabbix-trapper 10051/tcp Zabbix Trapper" - elog "zabbix-trapper 10051/udp Zabbix Trapper" - elog - - if use server || use proxy ; then - # check for fping - fping_perms=$(stat -c %a /usr/sbin/fping 2>/dev/null) - case "${fping_perms}" in - 4[157][157][157]) - ;; - *) - ewarn - ewarn "If you want to use the checks 'icmpping' and 'icmppingsec'," - ewarn "you have to make /usr/sbin/fping setuid root and executable" - ewarn "by everyone. Run the following command to fix it:" - ewarn - ewarn " chmod u=rwsx,g=rx,o=rx /usr/sbin/fping" - ewarn - ewarn "Please be aware that this might impose a security risk," - ewarn "depending on the code quality of fping." - ewarn - ;; - esac - fi -} diff --git a/net-analyzer/zabbix-server/zabbix-server-5.2.1.ebuild b/net-analyzer/zabbix-server/zabbix-server-5.2.1.ebuild deleted file mode 100644 index 49113bb..0000000 --- a/net-analyzer/zabbix-server/zabbix-server-5.2.1.ebuild +++ /dev/null @@ -1,320 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -# needed to make webapp-config dep optional -WEBAPP_OPTIONAL="yes" -inherit flag-o-matic webapp java-pkg-opt-2 user systemd toolchain-funcs - -DESCRIPTION="ZABBIX is software for monitoring of your applications, network and servers" -HOMEPAGE="https://www.zabbix.com/" -MY_P=${P/_/} -MY_PV=${PV/_/} -SRC_URI="http://mirror.imax.name/src/zabbix/${PV}/${P}.tar.gz" -LICENSE="GPL-2" -SLOT="0" -WEBAPP_MANUAL_SLOT="yes" -KEYWORDS="amd64 x86 arm" -IUSE="java curl +frontend ipv6 ldap libxml2 mysql openipmi oracle postgres +server proxy ssh ssl snmp sqlite odbc static" -REQUIRED_USE="|| ( frontend proxy server ) - proxy? ( ^^ ( mysql oracle sqlite odbc ) ) - server? ( ^^ ( mysql oracle postgres odbc ) ) - static? ( !oracle !snmp )" - -COMMON_DEPEND=" - curl? ( net-misc/curl ) - java? ( >=virtual/jdk-1.8:* ) - ldap? ( - =dev-libs/cyrus-sasl-2* - net-libs/gnutls - net-nds/openldap - ) - libxml2? ( dev-libs/libxml2 ) - mysql? ( dev-db/mysql-connector-c ) - odbc? ( dev-db/unixODBC ) - openipmi? ( sys-libs/openipmi ) - oracle? ( dev-db/oracle-instantclient-basic ) - postgres? ( dev-db/postgresql:* ) - proxy? ( sys-libs/zlib ) - server? ( - dev-libs/libevent - sys-libs/zlib - ) - snmp? ( net-analyzer/net-snmp ) - sqlite? ( dev-db/sqlite ) - ssh? ( net-libs/libssh2 ) - ssl? ( dev-libs/openssl:=[-bindist] ) -" - -RDEPEND="${COMMON_DEPEND} - java? ( >=virtual/jre-1.8:* ) - mysql? ( virtual/mysql ) - proxy? ( net-analyzer/fping[suid] ) - server? ( - app-admin/webapp-config - dev-libs/libevent - dev-libs/libpcre - net-analyzer/fping[suid] - ) - frontend? ( - app-admin/webapp-config - dev-lang/php:*[bcmath,ctype,sockets,gd,truetype,xml,session,xmlreader,xmlwriter,nls,sysvipc,unicode] - media-libs/gd[png] - virtual/httpd-php:* - mysql? ( dev-lang/php[mysqli] ) - odbc? ( dev-lang/php[odbc] ) - oracle? ( dev-lang/php[oci8-instant-client] ) - postgres? ( dev-lang/php[postgres] ) - sqlite? ( dev-lang/php[sqlite] ) - ) -" -DEPEND="${COMMON_DEPEND} - static? ( - curl? ( net-misc/curl[static-libs] ) - ldap? ( - =dev-libs/cyrus-sasl-2*[static-libs] - net-libs/gnutls[static-libs] - net-nds/openldap[static-libs] - ) - libxml2? ( dev-libs/libxml2[static-libs] ) - mysql? ( dev-db/mysql-connector-c[static-libs] ) - odbc? ( dev-db/unixODBC[static-libs] ) - postgres? ( dev-db/postgresql:*[static-libs] ) - sqlite? ( dev-db/sqlite[static-libs] ) - ssh? ( net-libs/libssh2 ) - ) -" -BDEPEND=" - virtual/pkgconfig -" - -PATCHES=( - "${FILESDIR}/${PN}-4.0.18-modulepathfix.patch" - "${FILESDIR}/${PN}-3.0.30-security-disable-PidFile.patch" -) - -S=${WORKDIR}/${MY_P} - -ZABBIXJAVA_BASE="opt/zabbix_java" - -pkg_setup() { - if use oracle; then - if [ -z "${ORACLE_HOME}" ]; then - eerror - eerror "The environment variable ORACLE_HOME must be set" - eerror "and point to the correct location." - eerror "It looks like you don't have Oracle installed." - eerror - die "Environment variable ORACLE_HOME is not set" - fi - if has_version 'dev-db/oracle-instantclient-basic'; then - ewarn - ewarn "Please ensure you have a full install of the Oracle client." - ewarn "dev-db/oracle-instantclient* is NOT sufficient." - ewarn - fi - fi - - if use frontend; then - webapp_pkg_setup - fi - - enewgroup zabbix - enewuser zabbix -1 -1 /var/lib/zabbix/home zabbix - - java-pkg-opt-2_pkg_setup -} - -src_prepare() { - default -} - -src_configure() { - econf \ - $(use_enable ipv6) \ - $(use_enable java) \ - $(use_enable proxy) \ - $(use_enable server) \ - $(use_enable static) \ - $(use_with curl libcurl) \ - $(use_with ldap) \ - $(use_with libxml2) \ - $(use_with mysql) \ - $(use_with odbc unixodbc) \ - $(use_with openipmi openipmi) \ - $(use_with oracle) \ - $(use_with postgres postgresql) \ - $(use_with snmp net-snmp) \ - $(use_with sqlite sqlite3) \ - $(use_with ssh ssh2) \ - $(use_with ssl openssl) -} - -src_compile() { - if [ -f Makefile ] || [ -f GNUmakefile ] || [ -f makefile ]; then - emake AR="$(tc-getAR)" RANLIB="$(tc-getRANLIB)" - fi -} - -src_install() { - local dirs=( - /etc/zabbix - /var/lib/zabbix - /var/lib/zabbix/home - /var/lib/zabbix/scripts - /var/lib/zabbix/alertscripts - /var/lib/zabbix/externalscripts - /var/log/zabbix - ) - - for dir in "${dirs[@]}"; do - dodir "${dir}" - keepdir "${dir}" - done - - if use server; then - insinto /etc/zabbix - doins "${S}"/conf/zabbix_server.conf - fperms 0640 /etc/zabbix/zabbix_server.conf - fowners root:zabbix /etc/zabbix/zabbix_server.conf - - newinitd "${FILESDIR}"/zabbix-server.init zabbix-server - - dosbin src/zabbix_server/zabbix_server - - insinto /usr/share/zabbix - doins -r "${S}"/database/ - - fi - - if use proxy; then - insinto /etc/zabbix - doins "${S}"/conf/zabbix_proxy.conf - fperms 0640 /etc/zabbix/zabbix_proxy.conf - fowners root:zabbix /etc/zabbix/zabbix_proxy.conf - - newinitd "${FILESDIR}"/zabbix-proxy.init zabbix-proxy - - dosbin src/zabbix_proxy/zabbix_proxy - - insinto /usr/share/zabbix - doins -r "${S}"/database/ - - fi - - fowners root:zabbix /etc/zabbix - fowners zabbix:zabbix \ - /var/lib/zabbix \ - /var/lib/zabbix/home \ - /var/lib/zabbix/scripts \ - /var/lib/zabbix/alertscripts \ - /var/lib/zabbix/externalscripts \ - /var/log/zabbix - fperms 0750 \ - /etc/zabbix \ - /var/lib/zabbix \ - /var/lib/zabbix/home \ - /var/lib/zabbix/scripts \ - /var/lib/zabbix/alertscripts \ - /var/lib/zabbix/externalscripts \ - /var/log/zabbix - - dodoc README INSTALL NEWS ChangeLog \ - conf/zabbix_proxy.conf \ - conf/zabbix_server.conf - - if use frontend; then - webapp_src_preinst - cp -R ui/* "${D}/${MY_HTDOCSDIR}" - webapp_configfile \ - "${MY_HTDOCSDIR}"/include/db.inc.php \ - "${MY_HTDOCSDIR}"/include/config.inc.php - webapp_src_install - fi - - if use java; then - dodir \ - /${ZABBIXJAVA_BASE} \ - /${ZABBIXJAVA_BASE}/bin \ - /${ZABBIXJAVA_BASE}/lib - keepdir /${ZABBIXJAVA_BASE} - exeinto /${ZABBIXJAVA_BASE}/bin - doexe src/zabbix_java/bin/zabbix-java-gateway-${MY_PV}.jar - exeinto /${ZABBIXJAVA_BASE}/lib - doexe \ - src/zabbix_java/lib/logback-classic-0.9.27.jar \ - src/zabbix_java/lib/logback-console.xml \ - src/zabbix_java/lib/logback-core-0.9.27.jar \ - src/zabbix_java/lib/logback.xml \ - src/zabbix_java/lib/android-json-4.3_r3.1.jar \ - src/zabbix_java/lib/slf4j-api-1.6.1.jar - newinitd "${FILESDIR}"/zabbix-jmx-proxy.init zabbix-jmx-proxy - newconfd "${FILESDIR}"/zabbix-jmx-proxy.conf zabbix-jmx-proxy - fi -} - -pkg_postinst() { - if use server || use proxy ; then - elog - elog "You may need to configure your database for Zabbix" - elog "if you have not already done so." - elog - - zabbix_homedir=$(egethome zabbix) - if [ -n "${zabbix_homedir}" ] && \ - [ "${zabbix_homedir}" != "/var/lib/zabbix/home" ]; then - ewarn - ewarn "The user 'zabbix' should have his homedir changed" - ewarn "to /var/lib/zabbix/home if you want to use" - ewarn "custom alert scripts." - ewarn - ewarn "A real homedir might be needed for configfiles" - ewarn "for custom alert scripts." - ewarn - ewarn "To change the homedir use:" - ewarn " usermod -d /var/lib/zabbix/home zabbix" - ewarn - fi - fi - - if use server; then - elog - elog "For distributed monitoring you have to run:" - elog - elog "zabbix_server -n " - elog - elog "This will convert database data for use with Node ID" - elog "and also adds a local node." - elog - fi - - elog "--" - elog - elog "You may need to add these lines to /etc/services:" - elog - elog "zabbix-trapper 10051/tcp Zabbix Trapper" - elog "zabbix-trapper 10051/udp Zabbix Trapper" - elog - - if use server || use proxy ; then - # check for fping - fping_perms=$(stat -c %a /usr/sbin/fping 2>/dev/null) - case "${fping_perms}" in - 4[157][157][157]) - ;; - *) - ewarn - ewarn "If you want to use the checks 'icmpping' and 'icmppingsec'," - ewarn "you have to make /usr/sbin/fping setuid root and executable" - ewarn "by everyone. Run the following command to fix it:" - ewarn - ewarn " chmod u=rwsx,g=rx,o=rx /usr/sbin/fping" - ewarn - ewarn "Please be aware that this might impose a security risk," - ewarn "depending on the code quality of fping." - ewarn - ;; - esac - fi -}