From 8d5dbd847cbc704a6a06405856e94b461011afe3 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 27 Mar 2021 06:06:27 +0000 Subject: gentoo resync : 27.03.2021 --- .../openvas-scanner/files/gvm-feed-sync-20.8.1.sh | 45 ++++++++++++++++++++++ .../openvas-scanner-20.8.1-rpath-qa-fix.patch | 14 +++++++ ...envas-scanner-7.0.1-disable-automagic-dep.patch | 33 ++++++++++++++++ 3 files changed, 92 insertions(+) create mode 100644 net-analyzer/openvas-scanner/files/gvm-feed-sync-20.8.1.sh create mode 100644 net-analyzer/openvas-scanner/files/openvas-scanner-20.8.1-rpath-qa-fix.patch create mode 100644 net-analyzer/openvas-scanner/files/openvas-scanner-7.0.1-disable-automagic-dep.patch (limited to 'net-analyzer/openvas-scanner/files') diff --git a/net-analyzer/openvas-scanner/files/gvm-feed-sync-20.8.1.sh b/net-analyzer/openvas-scanner/files/gvm-feed-sync-20.8.1.sh new file mode 100644 index 000000000000..178f49eb0493 --- /dev/null +++ b/net-analyzer/openvas-scanner/files/gvm-feed-sync-20.8.1.sh @@ -0,0 +1,45 @@ +#!/bin/sh +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 +# GVM cron script that updates feed. + +# Start to update FEED & First NVT. +try=0 +until [ $try -ge 5 ]; do + greenbone-feed-sync --type GVMD_DATA --curl &>/dev/null && break + try=$[$try+1] + sleep 30 +done + +# Check status +if [ $? -eq 0 ]; then + # Avoid your IP temporary banned because of multiple connection + sleep 5 + # Try to update scapdata. + try=0 + until [ $try -ge 5 ]; do + greenbone-feed-sync --type SCAP &>/dev/null && break + try=$[$try+1] + sleep 30 + done + + # Check status + if [ $? -eq 0 ]; then + # Avoid your IP temporary banned because of multiple connection + sleep 5 + # Try to update certdata + try=0 + until [ $try -ge 5 ]; do + greenbone-feed-sync --type CERT &>/dev/null && break + try=$[$try+1] + sleep 30 + done + + # Check status + if [ $? -eq 0 ]; then + exit 0 + else + exit 1 + fi + fi +fi diff --git a/net-analyzer/openvas-scanner/files/openvas-scanner-20.8.1-rpath-qa-fix.patch b/net-analyzer/openvas-scanner/files/openvas-scanner-20.8.1-rpath-qa-fix.patch new file mode 100644 index 000000000000..79e8692f4d6d --- /dev/null +++ b/net-analyzer/openvas-scanner/files/openvas-scanner-20.8.1-rpath-qa-fix.patch @@ -0,0 +1,14 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 69c68375..5bc000c0 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -37,6 +37,8 @@ endif (NOT CMAKE_BUILD_TYPE) + + OPTION (ENABLE_COVERAGE "Enable support for coverage analysis" OFF) + ++set(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE) ++ + ## Retrieve git revision (at configure time) + include (GetGit) + + diff --git a/net-analyzer/openvas-scanner/files/openvas-scanner-7.0.1-disable-automagic-dep.patch b/net-analyzer/openvas-scanner/files/openvas-scanner-7.0.1-disable-automagic-dep.patch new file mode 100644 index 000000000000..fd3e4610f8a4 --- /dev/null +++ b/net-analyzer/openvas-scanner/files/openvas-scanner-7.0.1-disable-automagic-dep.patch @@ -0,0 +1,33 @@ +diff --git a/nasl/CMakeLists.txt b/nasl/CMakeLists.txt +index b594679c..81c5e4a9 100644 +--- a/nasl/CMakeLists.txt ++++ b/nasl/CMakeLists.txt +@@ -100,14 +100,20 @@ execute_process (COMMAND gpgme-config --cflags + OUTPUT_VARIABLE GPGME_CFLAGS + OUTPUT_STRIP_TRAILING_WHITESPACE) + +-message (STATUS "Looking for netsnmp...") +-find_library (SNMP netsnmp) +-message (STATUS "Looking for netsnmp... ${SNMP}") +-if (SNMP) +- execute_process (COMMAND net-snmp-config --libs +- OUTPUT_VARIABLE SNMP_LDFLAGS +- OUTPUT_STRIP_TRAILING_WHITESPACE) +-endif (SNMP) ++option(BUILD_WITH_SNMP "Build with SNMP Support" ON) ++if (BUILD_WITH_SNMP) ++ message (STATUS "Looking for netsnmp...") ++ find_library (SNMP netsnmp) ++ message (STATUS "Looking for netsnmp... ${SNMP}") ++ if (SNMP) ++ execute_process (COMMAND net-snmp-config --libs ++ OUTPUT_VARIABLE SNMP_LDFLAGS ++ OUTPUT_STRIP_TRAILING_WHITESPACE) ++ endif (SNMP) ++ if (NOT SNMP) ++ message (SEND_ERROR " netsnmp not found") ++ endif(NOT SNMP) ++endif (BUILD_WITH_SNMP) + + message (STATUS "Looking for libgcrypt...") + find_library (GCRYPT gcrypt) -- cgit v1.2.3