I have Emacs 29.1, Windows 11, GnuPG 2.4.3 (from downloading gpg4win). I tried the advice here, but it doesn't work. If I start a file named test.gpg, and save it, I get a buffer like this:

Select recipients for encryption.
If no one is selected, symmetric encryption will be performed.  
- ‘m’ to mark a key on the line
- ‘u’ to unmark a key on the line
[Cancel] [OK]

  - 0B54C3C14B75C777 ...

With the key marked or not, if I select [OK], it just hangs. Eventually I hit C-g to break out of it.

Anybody got this working?

The vars I set are:

  '(epg-gpg-program  "C:/Program Files (x86)/GnuPG/bin/gpg.exe")
  '(epg-gpg-home-directory "c:/Users/rob/AppData/Roaming/gnupg")
  '(epg-gpgconf-program "c:/Program Files (x86)/GnuPG/bin/gpgconf.exe")

  • Can you tell us what version of gpg you are using? There is an issue with versions >2.2.40 that causes a freeze. Commented Dec 15, 2023 at 7:23
  • @FranBurstall That's at the top of the question, I thought. (2.4.3) That's what came from gpg --version
    – Rob N
    Commented Dec 15, 2023 at 19:30
  • 1
    sorry---did not read carefully enough. In any case, this seems to be a known problem (see here for example: irreal.org/blog/?p=11827). Solution is to downgrade gpg to 2.4.0 (at least this worked for me on linux). Commented Dec 15, 2023 at 21:32
  • Good to know. For now, I think I'll just write some scripts to make it more convenient to encrypt my files without emacs's help.
    – Rob N
    Commented Dec 15, 2023 at 21:51


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.