Function: epa-verify-cleartext-in-region

epa-verify-cleartext-in-region is an autoloaded, interactive and byte-compiled function defined in epa.el.gz.

Signature

(epa-verify-cleartext-in-region START END)

Documentation

Verify OpenPGP cleartext signed messages in current region from START to END.

Don't use this command in Lisp programs! See the reason described in the epa-verify-region documentation.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/epa.el.gz
;;;###autoload
(defun epa-verify-cleartext-in-region (start end)
  "Verify OpenPGP cleartext signed messages in current region from START to END.

Don't use this command in Lisp programs!
See the reason described in the `epa-verify-region' documentation."
  (declare (interactive-only t))
  (interactive "r")
  (save-excursion
    (save-restriction
      (narrow-to-region start end)
      (goto-char start)
      (let (cleartext-start cleartext-end)
	(while (re-search-forward "-----BEGIN PGP SIGNED MESSAGE-----$"
				  nil t)
	  (setq cleartext-start (match-beginning 0))
	  (unless (re-search-forward "^-----BEGIN PGP SIGNATURE-----$"
				     nil t)
	    (error "Invalid cleartext signed message"))
	  (setq cleartext-end (re-search-forward
			       "^-----END PGP SIGNATURE-----$"
			       nil t))
	  (unless cleartext-end
	    (error "No cleartext tail"))
          (with-suppressed-warnings ((interactive-only epa-verify-region))
	    (epa-verify-region cleartext-start cleartext-end)))))))