Good spot for gnupg location. I have reinstalled my old gnupg directory in /var/lib/openvas/openvasmd and restarted openvasmd; which popped up the following message in the log:
md main:MESSAGE:2019-02-06 08h26.12 utc:31382: OpenVAS Manager version 7.0.3 (DB revision 184)
base gpgme:MESSAGE:2019-02-06 08h26.12 utc:31383: Setting GnuPG dir to ‘/var/lib/openvas/openvasmd/gnupg’
base gpgme:MESSAGE:2019-02-06 08h26.12 utc:31383: Using OpenPGP engine version ‘2.1.11’
md crypt: INFO:2019-02-06 08h26.12 utc:31383: starting key generation …
md crypt: INFO:2019-02-06 08h26.13 utc:31383: OpenPGP key ‘OpenVAS Credential Encryption’ has been generated
So it seems to be good but I still have the gnupg credential decryption error appearing whenever I access the credentials page.
I would prefer to avoid resetting my encryption keys, as my current scanner serving hundreds of tasks depends on it. I have backed up all my files before migrating to openvas 9, so the original secret key should be available somewhere.
Any idea where it was located on Openvas8 and how to reinstall it in Openvas9 ?
Nevermind what I said earlier, I was able finally to recover my main key. However, I still do have the key decryption error, but it concern a new key which crypt a new credential autogenerated during migration. This credential is not used by any tasks. The credential is named:
Credential for Scanner default (Autogenerated by migration)
This certificate is using a client certificate but cannot be edited.
Any idea what this key is used for ? It seems I cannot import the gpg key of this credential since it has the same name “OpenVAS Credential Encryption” and my main key already use that name.