diff --git a/ospd/__init__.py b/ospd/__init__.py index 29f793f1..ac3727e1 100644 --- a/ospd/__init__.py +++ b/ospd/__init__.py @@ -3,6 +3,6 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" OSPd core module. """ +"""OSPd core module.""" from ospd_openvas.__version__ import __version__ diff --git a/ospd/cvss.py b/ospd/cvss.py index c645c564..557844e3 100644 --- a/ospd/cvss.py +++ b/ospd/cvss.py @@ -3,7 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Common Vulnerability Scoring System handling class. """ +"""Common Vulnerability Scoring System handling class.""" import logging diff --git a/ospd/datapickler.py b/ospd/datapickler.py index 97d2ff4f..c553e894 100644 --- a/ospd/datapickler.py +++ b/ospd/datapickler.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Pickle Handler class -""" +"""Pickle Handler class""" import logging import pickle diff --git a/ospd/errors.py b/ospd/errors.py index dd479fb3..ac5113fa 100644 --- a/ospd/errors.py +++ b/ospd/errors.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" OSP class for handling errors. -""" +"""OSP class for handling errors.""" from ospd.xml import simple_response_str diff --git a/ospd/misc.py b/ospd/misc.py index bd09e813..ff62281b 100644 --- a/ospd/misc.py +++ b/ospd/misc.py @@ -5,8 +5,7 @@ # pylint: disable=too-many-lines -""" Miscellaneous classes and functions related to OSPD. -""" +"""Miscellaneous classes and functions related to OSPD.""" import logging import os diff --git a/ospd/network.py b/ospd/network.py index 3631db5d..391277ab 100644 --- a/ospd/network.py +++ b/ospd/network.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Helper module for network related functions -""" +"""Helper module for network related functions""" import binascii import collections diff --git a/ospd/ospd.py b/ospd/ospd.py index c912de69..4f41c18f 100644 --- a/ospd/ospd.py +++ b/ospd/ospd.py @@ -5,8 +5,7 @@ # pylint: disable=too-many-lines -""" OSP Daemon core class. -""" +"""OSP Daemon core class.""" import logging import multiprocessing diff --git a/ospd/protocol.py b/ospd/protocol.py index a00ae815..959be3f0 100644 --- a/ospd/protocol.py +++ b/ospd/protocol.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Helper classes for parsing and creating OSP XML requests and responses -""" +"""Helper classes for parsing and creating OSP XML requests and responses""" from typing import Dict, Union, List, Any diff --git a/ospd/resultlist.py b/ospd/resultlist.py index bef30e86..effc7d77 100644 --- a/ospd/resultlist.py +++ b/ospd/resultlist.py @@ -5,8 +5,7 @@ # pylint: disable=too-many-lines -""" Class for handling list of resutls. -""" +"""Class for handling list of resutls.""" from collections import OrderedDict from typing import Dict diff --git a/ospd/vtfilter.py b/ospd/vtfilter.py index 241929f2..83131261 100644 --- a/ospd/vtfilter.py +++ b/ospd/vtfilter.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Vulnerability Test Filter class. -""" +"""Vulnerability Test Filter class.""" import re import operator from typing import Dict, List, Optional diff --git a/ospd/vts.py b/ospd/vts.py index aa93d269..1be65b56 100644 --- a/ospd/vts.py +++ b/ospd/vts.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Classes for storing VTs -""" +"""Classes for storing VTs""" import logging import multiprocessing from hashlib import sha256 diff --git a/ospd/xml.py b/ospd/xml.py index a4cc1b78..b6d29493 100644 --- a/ospd/xml.py +++ b/ospd/xml.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" OSP XML utils class. -""" +"""OSP XML utils class.""" import re diff --git a/ospd/xmlvt.py b/ospd/xmlvt.py index ba2c342a..76967203 100644 --- a/ospd/xmlvt.py +++ b/ospd/xmlvt.py @@ -3,8 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" OSP XML utils class for VTs. -""" +"""OSP XML utils class for VTs.""" import logging from typing import List, Dict, Optional diff --git a/ospd_openvas/daemon.py b/ospd_openvas/daemon.py index df3369c0..c62b4fe9 100644 --- a/ospd_openvas/daemon.py +++ b/ospd_openvas/daemon.py @@ -5,7 +5,7 @@ # pylint: disable=too-many-lines -""" Setup for the OSP OpenVAS Server. """ +"""Setup for the OSP OpenVAS Server.""" import logging import time diff --git a/ospd_openvas/db.py b/ospd_openvas/db.py index fe33715b..b75a4448 100644 --- a/ospd_openvas/db.py +++ b/ospd_openvas/db.py @@ -4,7 +4,7 @@ # SPDX-License-Identifier: AGPL-3.0-or-later -""" Access management for redis-based OpenVAS Scanner Database.""" +"""Access management for redis-based OpenVAS Scanner Database.""" import logging import sys import time diff --git a/ospd_openvas/dryrun.py b/ospd_openvas/dryrun.py index 47cb92af..a538345f 100644 --- a/ospd_openvas/dryrun.py +++ b/ospd_openvas/dryrun.py @@ -5,7 +5,7 @@ # pylint: disable=too-many-lines -""" Methods for dry run """ +"""Methods for dry run""" import logging import time diff --git a/ospd_openvas/gpg_sha_verifier.py b/ospd_openvas/gpg_sha_verifier.py index c969025d..2e2da49f 100644 --- a/ospd_openvas/gpg_sha_verifier.py +++ b/ospd_openvas/gpg_sha_verifier.py @@ -120,7 +120,7 @@ def gpg_sha256sums( def create_verify( - sha256sums: Callable[[], Dict[str, str]] + sha256sums: Callable[[], Dict[str, str]], ) -> Callable[[Path], bool]: """ create_verify is returning a closure based on the sha256sums. diff --git a/ospd_openvas/notus.py b/ospd_openvas/notus.py index 8905ac8c..76020159 100644 --- a/ospd_openvas/notus.py +++ b/ospd_openvas/notus.py @@ -32,7 +32,7 @@ def hashsum_verificator( return lambda _: True def on_hash_sum_verification_failure( - _: Optional[Dict[str, str]] + _: Optional[Dict[str, str]], ) -> Dict[str, str]: logger.warning( "GPG verification of notus sha256sums failed." diff --git a/ospd_openvas/nvticache.py b/ospd_openvas/nvticache.py index 605a498f..9fae249e 100644 --- a/ospd_openvas/nvticache.py +++ b/ospd_openvas/nvticache.py @@ -3,7 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Provide functions to handle NVT Info Cache. """ +"""Provide functions to handle NVT Info Cache.""" import logging diff --git a/ospd_openvas/preferencehandler.py b/ospd_openvas/preferencehandler.py index 8c70a32e..f250753d 100644 --- a/ospd_openvas/preferencehandler.py +++ b/ospd_openvas/preferencehandler.py @@ -5,9 +5,9 @@ # pylint: disable=too-many-lines -""" Prepare the preferences to be used by OpenVAS. Get the data from the scan +"""Prepare the preferences to be used by OpenVAS. Get the data from the scan collection and store the data in a redis KB in the right format to be used by -OpenVAS. """ +OpenVAS.""" import logging import binascii @@ -324,7 +324,7 @@ def prepare_nvt_preferences(self): @staticmethod def build_alive_test_opt_as_prefs( - target_options: Dict[str, str] + target_options: Dict[str, str], ) -> Dict[str, str]: """Parse the target options dictionary. Arguments: diff --git a/ospd_openvas/vthelper.py b/ospd_openvas/vthelper.py index f68b8f73..20264d96 100644 --- a/ospd_openvas/vthelper.py +++ b/ospd_openvas/vthelper.py @@ -3,7 +3,7 @@ # # SPDX-License-Identifier: AGPL-3.0-or-later -""" Provide functions to handle VT Info. """ +"""Provide functions to handle VT Info.""" from hashlib import sha256 import logging