summaryrefslogtreecommitdiff
path: root/net-analyzer
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-12-23 06:31:00 +0000
committerV3n3RiX <venerix@koprulu.sector>2024-12-23 06:31:00 +0000
commit338095605b6c9c82690f77f27a32490c9a57bdcb (patch)
tree72a4d7ec7ba10ea6da4d4f7d25b68915b12edde6 /net-analyzer
parent5a2cecfc8661e1d3a762adf05cf8eb142cd41710 (diff)
gentoo auto-resync : 23:12:2024 - 06:31:00
Diffstat (limited to 'net-analyzer')
-rw-r--r--net-analyzer/Manifest.gzbin43616 -> 43615 bytes
-rw-r--r--net-analyzer/greenbone-feed-sync/Manifest6
-rw-r--r--net-analyzer/greenbone-feed-sync/greenbone-feed-sync-23.10.0.ebuild2
-rw-r--r--net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.3.0-r1.ebuild2
-rw-r--r--net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.9.0.ebuild105
5 files changed, 111 insertions, 4 deletions
diff --git a/net-analyzer/Manifest.gz b/net-analyzer/Manifest.gz
index b967a20ceaae..0f8d3b2fd28e 100644
--- a/net-analyzer/Manifest.gz
+++ b/net-analyzer/Manifest.gz
Binary files differ
diff --git a/net-analyzer/greenbone-feed-sync/Manifest b/net-analyzer/greenbone-feed-sync/Manifest
index c16def7709f9..d5e434d1837a 100644
--- a/net-analyzer/greenbone-feed-sync/Manifest
+++ b/net-analyzer/greenbone-feed-sync/Manifest
@@ -3,6 +3,8 @@ AUX greenbone-feed-sync.service 219 BLAKE2B 7f5d17b23b56a175115a4147e16d1e8636c9
AUX greenbone-feed-sync.timer 183 BLAKE2B f91b69c6b2a5024c6cd9d678676071f7d5e175a3b35e0e34ffc03be7630df7519948c6c3285c7b265c73c0b7b4485706bba5673f89234c478ad6cd43d7305ddc SHA512 3716c8057bab3926b57e5e9868f4e00ec95940e5a9ea0506e16a152a76cb9b388ba5f0c8404245dcba5ba26bc789f0670781c41568d53a82412cd19689aca2c6
DIST greenbone-feed-sync-23.10.0.tar.gz 63001 BLAKE2B 5566cef8649e578cb498f0a5bc1e41f237a3702698b2012f3a62d8f5f647e6b1e3253c7d92e4a9fc82ad7991de8010b94ba8c1194a820511c49e5f5262e471ff SHA512 fe5864c4e650f17a072cd6e4153779ea33ad8f0ac28e92114b40c465a04b70791b603ccbe82934dcdad13fce2003e2d9786cec75854efecf8aefa74c7ce178f4
DIST greenbone-feed-sync-24.3.0.tar.gz 58949 BLAKE2B 10260850dad8781682e9f3e3eb31faa4139080b3c5661261770fe28053df472b21b4e2ef98f258b5c634c26d543313da30bb01d9eadfdb8ea8e7b7b57205b7f5 SHA512 ac1ce1f0a2898997e5a330e9a186b6203b7593e5b847d23202c28e7b3b7be1556001cc6d8ba5abd7077d1b51e0f21640728f78659ecf9a60eede28ea483344b4
-EBUILD greenbone-feed-sync-23.10.0.ebuild 1575 BLAKE2B abe5101d16ca2c904b36d622c49f3d3a4e43ae60d0ce36d76ae50522b39b694604c65d1a81fd6ee74813f697b3d21c130d4acf3f7fe98955537e4bf1a23b24e6 SHA512 fc7ffb5e2c7a155ba33952cd77fddaf7690001e25c1ba1ad4f5c6f640b1b12874c5bedaf61400155a6947d3ed8849a3d8b38f048c16ee9e8bf4c028c243b997a
-EBUILD greenbone-feed-sync-24.3.0-r1.ebuild 2899 BLAKE2B 3446df8c1279879af963cff7b7b7e8276ce95c5d94c0078e89a87ac450ed5205cc5cf0f0d36dbac4f3fa8514c3bf778bdc504a4a32c2e8b068e301109c97e314 SHA512 be665b9db06e27ef29974a7f2008a068d6d7837a61b53b72e5674c9b5d1251bf3a113071f9e2f9e2f95ffab1af2e765b2b722e972030a78a52fddfcfb2e5d2fa
+DIST greenbone-feed-sync-24.9.0.tar.gz 63052 BLAKE2B 11ecedca7474de397c938427120412dce3dab8835b800a9896e6585b3128e18608cbc7de4746d4649a28d1d87c2cfcb5a915224386d6cf03043c6e9575bedab4 SHA512 97ff2abd1ee604893546e6f4befceb70ec496e83f1920da8820c4c1de1dc8f12301aaac6030d68a19a3eeb7bd0dd143941693d8f986a7748e6bc0c463deae0bb
+EBUILD greenbone-feed-sync-23.10.0.ebuild 1575 BLAKE2B 197a8c69f8cd5f3f2107ae9d4bec4de43abccafac17a96e486e3301f84ba6f54f02b354063af375193509684ebc85dbccec282dead85bdd823597a337a63d4e4 SHA512 bc0491e5a7980d3d193253b2037d7e70a85c22cafbcfbc1207e0c7c55a201a5e96ae93c54c608207c309547b5fbe66e44d319d170015a4eb1ee0088bf42ac942
+EBUILD greenbone-feed-sync-24.3.0-r1.ebuild 2899 BLAKE2B 74c7431f5c84410ce1ce359418d8eede1875b74b9bf019add8518924e344f69db4f5645306e8c2b4389545e364c5d84069f123f4b3e2effed12d97dc738b9e11 SHA512 44c854069859da636531ad91f2cd94c21be05f13058ce4c0e37b1302022e40a533cf32067c09f449c89bb7cedb35c2e579e1d15478bad149fad6152a77f5e7ae
+EBUILD greenbone-feed-sync-24.9.0.ebuild 2900 BLAKE2B 12ef2423d4f69a9a7aa5ad41d4179486ff0e67057b787bebe19a063c264550833e3d43ff94c9347672cc5fda4285e45cdd0e3d928e5144e0eaa537b10fe29345 SHA512 5e6d3a438f79592fa7b0f70736cb34cd5feb1c95d5807c2ff072cad0dfc9d8f7df4e6a2dd3f898fc409b4f4405b6b78e845861c852d77074c300d30d234b6c38
MISC metadata.xml 822 BLAKE2B 6e48caf48d652d7892292654b2b55a1b200fedae3b34d03ed237259fda8a8c8013cda2c3ac93b080658424a21a13e9a3d4eb92c677621c17c2309cf7f7467c32 SHA512 9457919c66737a70c7cc58aa576102c46c1d296a616baf53559eb04bd89a7cc315d59980e7150afea1f9010344952e73deeb215ec5f776075b638072badf5983
diff --git a/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-23.10.0.ebuild b/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-23.10.0.ebuild
index 53a297aa1af6..1ed28d678881 100644
--- a/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-23.10.0.ebuild
+++ b/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-23.10.0.ebuild
@@ -3,7 +3,7 @@
EAPI=8
-PYTHON_COMPAT=( python3_{9..12} )
+PYTHON_COMPAT=( python3_{9..13} )
DISTUTILS_USE_PEP517=poetry
inherit distutils-r1 systemd
diff --git a/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.3.0-r1.ebuild b/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.3.0-r1.ebuild
index d62d82b0000a..c6e184d545b4 100644
--- a/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.3.0-r1.ebuild
+++ b/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.3.0-r1.ebuild
@@ -3,7 +3,7 @@
EAPI=8
-PYTHON_COMPAT=( python3_{10..12} pypy3 )
+PYTHON_COMPAT=( python3_{10..13} pypy3 )
DISTUTILS_USE_PEP517=poetry
inherit distutils-r1 systemd
diff --git a/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.9.0.ebuild b/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.9.0.ebuild
new file mode 100644
index 000000000000..a594baaa8ea7
--- /dev/null
+++ b/net-analyzer/greenbone-feed-sync/greenbone-feed-sync-24.9.0.ebuild
@@ -0,0 +1,105 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..13} pypy3 )
+DISTUTILS_USE_PEP517=poetry
+inherit distutils-r1 systemd
+
+DESCRIPTION="New script for syncing the Greenbone Community Feed"
+HOMEPAGE="https://github.com/greenbone/greenbone-feed-sync"
+SRC_URI="https://github.com/greenbone/greenbone-feed-sync/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="cron"
+
+COMMON_DEPEND="
+ acct-user/gvm
+ net-misc/rsync
+ >=net-analyzer/gvmd-22.5.0
+ $(python_gen_cond_dep '
+ >dev-python/tomli-2.0.1[${PYTHON_USEDEP}]
+ ' 3.10)
+ >=dev-python/rich-13.2.0[${PYTHON_USEDEP}]
+ >=dev-python/shtab-1.7.0[${PYTHON_USEDEP}]
+"
+DEPEND="
+ ${COMMON_DEPEND}
+ test? ( >=net-analyzer/pontos-22.12.2[${PYTHON_USEDEP}] )
+"
+RDEPEND="
+ ${COMMON_DEPEND}
+ cron? ( virtual/cron )
+"
+
+distutils_enable_tests unittest
+
+src_test() {
+ # Make a copy of the original config
+ cp greenbone/feed/sync/config.py "${T}"/config.py.orig || die
+
+ # Patch the config.py to not use files from /etc/gvm, as this may
+ # cause a PermissionError. See https://bugs.gentoo.org/932836#c10
+ sed -i \
+ -e 's:DEFAULT_CONFIG_FILE = "/etc/gvm/greenbone-feed-sync.toml":DEFAULT_CONFIG_FILE = "'"${WORKDIR}/${P}-${TARGET}"'/install/etc/gvm/greenbone-feed-sync.toml":' \
+ -e 's:DEFAULT_ENTERPRISE_KEY_PATH = "/etc/gvm/greenbone-enterprise-feed-key":DEFAULT_ENTERPRISE_KEY_PATH = "'"${WORKDIR}/${P}-${TARGET}"'/install/etc/gvm/greenbone-enterprise-feed-key":' \
+ greenbone/feed/sync/config.py || die
+
+ # Disable tests that require network access.
+ sed -i \
+ -e 's:test_do_not_run_as_root:_&:' \
+ -e 's:test_sync_nvts:_&:' \
+ -e 's:test_sync_nvts_quiet:_&:' \
+ -e 's:test_sync_nvts_rsync_error:_&:' \
+ -e 's:test_sync_nvts_verbose:_&:' \
+ -e 's:test_sync_nvts:_&:' \
+ -e 's:test_sync_nvts_error:_&:' \
+ tests/test_main.py || die
+
+ distutils-r1_src_test
+
+ # Restore config.py after test.
+ mv "${T}"/config.py.orig greenbone/feed/sync/config.py || die
+}
+
+python_install() {
+ distutils-r1_python_install
+
+ # greenbone-feed-sync should not be run as root to avoid changing file permissions
+ insinto /etc/sudoers.d
+ newins - greenbone-feed-sync <<-EOF
+ gvm ALL = NOPASSWD: /usr/bin/greenbone-feed-sync
+ EOF
+
+ fperms 0750 /etc/sudoers.d
+ fperms 0440 /etc/sudoers.d/greenbone-feed-sync
+
+ if use cron; then
+ exeinto /etc/cron.daily
+ newexe "${FILESDIR}"/${PN}.cron ${PN}
+ fi
+
+ systemd_dounit "${FILESDIR}/${PN}.timer" "${FILESDIR}/${PN}.service"
+}
+
+pkg_postinst() {
+ if [[ -n ${REPLACING_VERSIONS} ]]; then
+ return
+ fi
+
+ if use cron; then
+ elog
+ elog "Edit ${EROOT}/etc/cron.weekly/greenbone-feed-sync to activate daily feed update!"
+ elog
+ fi
+
+ if systemd_is_booted; then
+ elog
+ elog "To enable the systemd timer, run the following command:"
+ elog " systemctl enable --now greenbone-feed-sync.timer"
+ elog
+ fi
+}