Could not verify server key (gpg key expired)

thx to Remy and Cedric for the help. My Passbolt is now working again. To help others with the same problem here an short how-to:

  • [YOUR KEY ID] has to replace with your own id, expample 2930B0302120120…
  • the path to passbolt (/var/www/passbolt/config/gpg) can be different, you have to check if it is the same like mine!

looking for the key id and expire date

gpg --list-keys

enter the gpg shell

gpg --edit-key [YOUR KEY ID]

again, list the gpg keys

list

first, take key 0

key 0

use the command expire to change the expire time of the key 0

expire

change it to never (or what ever you like)

0

confirm this

y

do the same with key 1

key 1

expire

0

y

save it!

save

check that the expire date is changed

gpg --list-keys

first we need to delete the serverkey.asc and serverkey_private.asc in /var/www/passbolt/gpg/

cd /var/www/passbolt/gpg/
rm server.key.asc
rm serverkey_private.asc

now we have to copy the gpg private key to passbolt

gpg --armor --export-secret-keys [YOUR KEY ID] > /var/www/passbolt/config/gpg/serverkey_private.asc

and now for the gpg key

gpg --armor --export [YOUR KEY ID] > /var/www/passbolt/config/gpg/serverkey.asc

change the owner to www-data

su -s /bin/bash -c "gpg --import /var/www/passbolt/config/gpg/serverkey_private.asc" www-data

check that the owner is correct

su -s /bin/bash -c "gpg --list-keys" www-data

now you can recover your account