Skip to content
This repository has been archived by the owner on Aug 25, 2023. It is now read-only.

gpg4win

Andrew Savchenko edited this page May 18, 2020 · 2 revisions

gpg4win

  1. Download from the official website
  2. Import pubkey, insert smart-card.
    1. Open kleopatra, Tools → Manage Smartcards, ensure yours is present.
    2. Do not close Kleopatra.
    3. Issue gpg.exe --card-status to refresh the SCDaemon.
    4. Press F5 in Kleopatra, assuming pubkey corresponds to private key stored on the card, relevant line will become highlighted with in bold.
    5. Change trust level of your own certificate to ultimate.
  3. Export pubkey from a (sub)key that is allowed to authenticate: gpg.exe --export-ssh-key ID
  4. Enable Putty support: echo "enable-putty-support" >> C:\Users\asv\AppData\Roaming\gnupg\test.conf
  5. Restart daemon: gpg-connect-agent KILLAGENT /bye; gpg-agent.exe -v --enable-putty-support.
  6. Try to login, authenticate card as usual. Should see something like this: 2019-08-09 21_46_11-192 168 2 202 - PuTTY
  7. Configure git to sign commits by default:
git config --global gpg.program "C:\Program Files (x86)\GnuPG\bin\gpg.exe"
git config --global user.signingkey $LONG_KEY_ID
git config --global commit.gpgsign true
Clone this wiki locally