claws-mail : no gpg password dialog

Forum Forums General Software claws-mail : no gpg password dialog

Tagged: ,

  • This topic has 9 replies, 2 voices, and was last updated Nov 20-10:18 am by delix02.
Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #2705
    Member
    delix02

      on antiX-16 I used sylpheed as email client and the gpg plugin worked well.
      on antiX-17 I choose claws-mail and installed and activated the gpg plugins succesfully.
      pinentry-curses, pinentry-gnome3 and pinentry-gtk2 are installed.

      then I copied the ~/.gnupg directory from antiX-16 to antiX-17.
      Encryption and decryption in a terminal is working.
      In claws-mail, I use pgp-mime and the passphrase option as the gpa-agent option is greyed out, although the agent is running and I can connect to it.
      Encryption is working well in claws-mail, too.

      However, decryption failed with the (very useful) error message “deryption failed”. I just don’t get a dialog box where I can input my passphrase.
      Obviously, I can’t decrypt because I don’t get a passphrase dialog box.

      Any suggestions for a solution of the problem ?

      • This topic was modified 5 years, 5 months ago by delix02.
      #2731
      Member
      delix02
        Helpful
        Up
        0
        ::

        I found a worharoud :
        starting claws-mail with the –debug option opens a terminal window for the passphrase input. This way the email is decrypted and readable in the graphical mode window.

        Well, this is a pretty ugly “solution”…..

        #2735
        Anonymous
          Helpful
          Up
          0
          ::

          (moving this topic to “Software” subforum. If/when we agree it is “solved”, hope to see it moved to Tips-n-Tricks subforum)

          Have you read this page? ClawsMail wiki :: plugins

          How do I configure gpg-agent and the PGP plugin?

          Attempts to use your gpg key to sign/encrypt messages will fail with a ‘Signature failed’ message without even asking you for your password if:

          Your OS automatically starts the gpg-agent daemon AND
          GPGME is properly configured to use the right GnuPG version (see How do I enable GPG support in Claws Mail?) AND
          you only have the CURSES based pinentry program installed AND
          you started claws-mail from a menu or icon

          (Note: my Fedora Core 4 workstation install was configured this way). The solution is to make sure that you have the pinentry-gtk, pinentry-qt or pinentry-qt4 programs installed. Claws Mail will then present the pinentry dialog box to get your GPG passphrase.

          You can tell if this is working by the dialog box presented to you for your passphrase. The pinentry dialog is a little uglier than the Claws Mail version, and the window title is ‘pinentry’.

          One advantage of using the gpg-agent over Claws Mail password dialog is that the password caching then works with other applications using the gpg-agent (eg the command line when you specify –use-agent).

          If it still refuses to work you might want to try the following steps:

          Make sure your ~/.gnupg/gpg.conf contains the line

          use-agent

          Create a file ~/.gnupg/gpg-agent.conf with the following contents:


          pinentry-program /usr/bin/pinentry-qt4
          no-grab
          default-cache-ttl 1800

          Add the following line to some startup script. (In case of KDE you could use ~/.kde/env/gpgagent.sh
          The filename does not matter, the contents of ~/.kde/env/ is sourced by startkde)

          eval “$(gpg-agent –daemon)”

          Note: If you make any changes to ~/.gnupg/gpg-agent.conf while gpg-agent is running you will need to restart gpg-agent for the changes to take effect.

          #2738
          Member
          delix02
            Helpful
            Up
            0
            ::

            yes, I read it and followed the instructions step-by-step.
            However, I didn’t use pinentry-qt4 but pinentry-gnome3 because I use the icewm windowmanager.pinentry-qt4 is not installed and I think, it makes no sense if you are not using KDE.
            I put the eval line in ~.icewm/startup

            It didn’t change the error.

            I checked htop and can see gpg-agent up and running.

            #2740
            Member
            delix02
              Helpful
              Up
              0
              ::

              now I tried pineentry-gtk2, too. Claws-mail seems to use gtk-2.24.

              However, same error.
              Is there something missing for the gtk2 compatibility on my machine ?

              #2742
              Anonymous
                Helpful
                Up
                0
                ::

                Bubba, I’m not there. I’m not using gpg. We can wait for a reply from someone who is…
                or continue chasing down leads from “claws-mail gpg password dialog” websearch.

                #2744
                Member
                delix02
                  Helpful
                  Up
                  0
                  ::

                  thanks for your help so far !
                  what I found was https://github.com/keybase/keybase-issues/issues/1712
                  acually, I didn”t really understand the suggested solution 🙂

                  well, what I found in the meantime :
                  it isn’t necessary to use the –debug option of claws-mail, but it is to start it in a terminal. Usually I start it from a button in the icewm toolbar (that means without terminal).

                  What is really strange : it WORKS if claws-mail is started from the application menu (!!!!) – but not from the toolbar

                  it seems to be a icewm “problem”, not a claws-mail ……….

                  I”ll check this tomorrow……

                  this is misleanding: it works only if the decryption is done with starting claws-mail in the terminal before. In this case it is not necessary to start the dialog box again and so the decryption is done from the graphical instance of claws-mail, too. Probably, something is just cached….

                  So, problem and workaround is valid. And gpg-agent in the claws-mail preferences is still greyed out after following the suggestions from the FAQs.

                  Debugging of this bug seems to be far over my head.

                  • This reply was modified 5 years, 5 months ago by delix02.
                  • This reply was modified 5 years, 5 months ago by delix02.
                  #2804
                  Member
                  delix02
                    Helpful
                    Up
                    0
                    ::

                    update :
                    I tried more debugging steps and pnned down the error to

                    2017-11-19 19:16:56 gpg-agent[14263] DBG: error calling pinentry: Unpassender IOCTL (I/O-Control) für das Gerät <Pinentry>
                    2017-11-19 19:16:56 gpg-agent[14263] DBG: chan_11 -> BYE
                    2017-11-19 19:16:56 gpg-agent[14263] failed to unprotect the secret key: Unpassender IOCTL (I/O-Control) für das Gerät
                    2017-11-19 19:16:56 gpg-agent[14263] failed to read the secret key
                    2017-11-19 19:16:56 gpg-agent[14263] command ‘PKDECRYPT’ failed: Unpassender IOCTL (I/O-Control) fĂĽr das Gerät <Pinentry>
                    2017-11-19 19:16:56 gpg-agent[14263] DBG: chan_10 -> ERR 83918950 Unpassender IOCTL (I/O-Control) für das Gerät <Pinentry>
                    2017-11-19 19:16:56 gpg-agent[14263] DBG: chan_10 <- [eof]

                    this is the German version of the “Inappropriate ioctl for device” error

                    Following
                    https://www.gnupg.org/documentation/manuals/gnupg/Common-Problems.html
                    I added the export GPG_TTY=$(tty) line to my ~/.profile

                    However, no changes…….

                    #2816
                    Anonymous
                      Helpful
                      Up
                      0
                      ::

                      (sorry, need to ask, as a rule-out step)

                      Following the ~/.profile edit, did you logout+login prior to testing the result?

                      Tested verbatim, as posted? Without quotation marks?
                      export GPG_TTY=$(tty)

                      edit:

                      Ah, not specific to claws-mail… the context (non-interactive, non-login shell) probably requires declaration with .bashrc
                      (on your previous system, the sylpheed installation may have silently done so)
                      GNUpg.org :: Invoking GPG-AGENT
                      -=-
                      howto get ___ to start on the correct tty

                      #2841
                      Member
                      delix02
                        Helpful
                        Up
                        0
                        ::

                        thanks again for your input !
                        yes, I know I must restart the agent. However, no chnages again…..

                        All the tipps and tricks I found in the web are about getting the ncurses version to run. Well, is working in my case automatically.
                        So, I tried to start the pinentry-gnome3 program manually in a urxvt terminal under icewm as suggested in the pinentry-doc
                        pinentry-gnome3 --display=:0.0 and all other attempts (with or without some of the other option)
                        result in the error message
                        [b-qoute]
                        No $DBUS_SESSION_BUS_ADDRESS found, falling back to curses
                        OK PLeased to meet you
                        [/b-qoute]
                        of course, the xserver is running and htop shows the dbus-laucher.
                        pinentry-gtk-2 --display=:0.0
                        doesn’t come up with the DBUS line and starts directly with the OK Pleased…line: obviously the program falls back to curses, too

                        I don’t understand the dbus enough to make use of the message.

                        • This reply was modified 5 years, 5 months ago by delix02.
                      Viewing 10 posts - 1 through 10 (of 10 total)
                      • You must be logged in to reply to this topic.