Announcements and discussions for Gnus, the GNU Emacs Usenet newsreader
 help / color / mirror / Atom feed
* Trouble with GnuPG 2.1
@ 2016-03-13 15:16 Nils Gillmann
  2016-03-13 15:48 ` Jens Lechtenboerger
  2016-03-14  9:39 ` Trouble with GnuPG 2.1 Nils Gillmann
  0 siblings, 2 replies; 8+ messages in thread
From: Nils Gillmann @ 2016-03-13 15:16 UTC (permalink / raw)
  To: info-gnus-english

So I ran into this issue with gpg2.1 on emacs-24.5 and Gnus where
I can *de*crypt emails but I can't encrypt or sign.

Outside of Gnus, gpg works.

So the relevant parts (leaving our filtering, eye candy etc) in
~/.gnus.el are below. If more details I needed or could break the
functionality, I can share the complete configuration.
My ~/.emacs.d/init.el has nothing obvious related to gpg related
modules in it.

;; gnus
(setq message-sendmail-envelope-from 'header)

;; BBDB enhancements / values:
(add-hook 'gnus-startup-hook 'bbdb-insinuate-gnus)
(setq gnus-score-find-score-files-function
      '(gnus-score-find-bnews bbdb/gnus-score))

(defun gnus-user-format-function-a (header)
  (let ((myself (concat "<" my-mail ">"))
	(references (mail-header-references header))
	(message-id (mail-header-id header)))
    (if (or (and (stringp references)
		 (string-match myself references))
	    (and (stringp message-id)
		 (string-match myself message-id)))
	"X" "│")))

(gnus-add-configuration
 '(article
   (vertical 1.0
	     (summary .35 point)
	     (article 1.0))))

(setq message-from-style 'angles)
(setq message-syntax-checks '((sender . disabled)))

(defun my-message-mode-setup ()
  (setq fill-column 65)
  (turn-on-auto-fill))
(add-hook 'message-mode-hook 'my-message-mode-setup)

(add-hook 'gnus-article-prepare-hook 'gnus-article-date-local)
(add-hook 'gnus-select-group-hook 'gnus-group-set-timestamp)
(add-hook 'gnus-group-mode-hook 'gnus-topic-mode)

(setq gnus-thread-sort-functions
      '((not gnus-thread-sort-by-date)
	(not gnus-thread-sort-by-number)))

(add-hook 'gnus-switch-on-after-hook 'gnus-group-first-unread-group)
(add-hook 'gnus-summary-exit-hook 'gnus-group-first-unread-group)

(setq gnus-show-threads t)
(setq gnus-asynchonous t)
(setq message-confirm-send t)

;; GPG Assistant
(require 'epa-file)
(epa-file-enable)
(setq epa-file-encrypt-to "0x300FA50FA4236AE9")
;;(setq epa-file-encrypt-to "66526D60")
;; (require 'epg)
;;(setq epg-gpg-program "/home/niasterisk/.guix-profile/bin/gpg2")
;; ;; package epa
;; (setq epa-file-cache-passphrase-for-symmetric-encryption t)
;; (setq epg-user-id "66526D60")
;; (setq epg-debug t)
;; ;; package mm-decode
;; ;;(add-to-list 'mm-attachment-override-types "image/.*")
;; ;;(add-to-list 'mm-inlined-types "text/html")
 (setq mm-text-html-renderer 'shr)
;; (setq mm-verify-option 'always)
;; (setq mm-decrypt-option 'always)
;; ;; package mm-encode
;; (setq mm-sign-option 'guided)
;; (setq mm-encrypt-option 'guided)
;; ;; package mml2015
;; (setq mml2015-use 'epg)
;; (setq mml2015-verbose t)
;; (setq mml2015-encrypt-to-self t)
;; (setq mml2015-always-trust nil)
;; (setq mml2015-cache-passphrase t)
;; (setq mml2015-passphrase-cache-expiry '36000)
;; (setq mml2015-sign-with-sender t)

;;(setq mm-text-html-renderer 'w3m)
(setq mm-inline-large-images t)
(auto-image-file-mode)
(add-to-list 'mm-attachment-override-types "image/*")

;; citation
(setq sc-attrib-selection-list nil
     sc-auto-fill-region-p nil
     sc-blank-lines-after-headers 1
     sc-citation-delimiter-regexp "[>]+\\|\\(: \\)+"
     sc-cite-blank-lines-p nil
     sc-confirm-always-p nil
     sc-electric-references-p nil
     sc-fixup-whitespace-p t
     sc-nested-citation-p nil
     sc-preferred-header-style 4
     sc-use-only-preference-p nil)

(gnus-delay-initialize)

(setq gnus-treat-emphasize t)
(setq nnmail-treat-duplicates 'warn)

;;; When displaying a signed message, show buttons and show if the
;;; signature was valid.
(setq mm-verify-option 'known
      mm-decrypt-option 'known
      gnus-article-emulate-mime t
      gnus-buttonized-mime-types
      (append
       (list "multipart/signed"
             "multipart/encrypted")
       gnus-buttonized-mime-types))

;;(setq gnus-message-replyencrypt t)
;;(setq gnus-message-replysign t)
;;(setq gnus-message-replysignencrypted t)
;;(setq gnus-treat-x-pgp-sig t)
(setq gnus-use-cache t)


thanks,
-- 
ng
personal contact: http://krosos.sdf.org
EDN: https://wiki.c3d2.de/Echt_Dezentrales_Netz/en


_______________________________________________
info-gnus-english mailing list
info-gnus-english@gnu.org
https://lists.gnu.org/mailman/listinfo/info-gnus-english

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2016-03-14 17:41 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-13 15:16 Trouble with GnuPG 2.1 Nils Gillmann
2016-03-13 15:48 ` Jens Lechtenboerger
2016-03-13 16:21   ` Nils Gillmann
2016-03-13 17:17     ` Jens Lechtenboerger
2016-03-13 19:57       ` Nils Gillmann
2016-03-14 16:55         ` possible emacs 24.5 + Gnus problem when using pgpmime and signencrypt (was: Re: Trouble with GnuPG 2.1) Nils Gillmann
2016-03-14 17:41           ` possible emacs 24.5 + Gnus problem when using pgpmime and signencrypt Jens Lechtenboerger
2016-03-14  9:39 ` Trouble with GnuPG 2.1 Nils Gillmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).