Skip to content

Commit

Permalink
Change: gpg verification failure handling of notus advisories sha256sums
Browse files Browse the repository at this point in the history
When gpg verification on sha256sums for notus advisories fails it is
printing a warning instead of crashing ospd-openvas.

This changes the behaviour mentioned in #765

(cherry picked from commit 9d0bd4e)
  • Loading branch information
nichtsfrei authored and mergify[bot] committed Jan 27, 2023
1 parent fc50d3b commit 08ea7e1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ospd_openvas/notus.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,11 @@ def hashsum_verificator(
def on_hash_sum_verification_failure(
_: Optional[Dict[str, str]]
) -> Dict[str, str]:
raise Exception("GPG verification of notus sha256sums failed")
logger.warning(
"GPG verification of notus sha256sums failed."
" Notus advisories are not loaded."
)
return {}

sha_sum_file_path = advisories_directory_path / "sha256sums"
sha_sum_reload_config = ReloadConfiguration(
Expand Down

0 comments on commit 08ea7e1

Please sign in to comment.