3
  1. Generated keys on an air-gapped PC.
  2. Backed-up my .gpg folder on a USB.
  3. Imported keys to smartcard 1.
  4. Keys deleted
  5. Replaced .pgp folder with .pgp from USB
  6. Imported keys to smartcard 2.

Is this setup valid and can I use same sub-keys with two completely different smartcards?

Is there a way to test those keys to make sure everything works correctly?

2

Yes, this should work as you described.

To test, try using the cards to decrypt files encrypted to your public key, use them to sign files and see if you can verify them using your pub etc.

In my limited experience the biggest issue with using the same keys on backup cards is that the system looks for the keys on a specific card, regardless of whether there's a copy of them on the currently-inserted smartcard. When I had that issue deleting my gpg directory (already backed up elsewhere) and running gpg --card-status cleared it up.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.