Function: mml-smime-openssl-encrypt
mml-smime-openssl-encrypt is a byte-compiled function defined in
mml-smime.el.gz.
Signature
(mml-smime-openssl-encrypt CONT)
Source Code
;; Defined in /usr/src/emacs/lisp/gnus/mml-smime.el.gz
(defun mml-smime-openssl-encrypt (cont)
(let (certnames certfiles tmp file tmpfiles)
;; xxx tmp files are always an security issue
(while (setq tmp (pop cont))
(if (and (consp tmp) (eq (car tmp) 'certfile))
(push (cdr tmp) certnames)))
(while (setq tmp (pop certnames))
(if (not (and (not (file-exists-p tmp))
(get-buffer tmp)))
(push tmp certfiles)
(setq file (make-temp-file (expand-file-name "mml." mm-tmp-directory)))
(with-current-buffer tmp
(write-region (point-min) (point-max) file))
(push file certfiles)
(push file tmpfiles)))
(smime-encrypt-buffer certfiles)
(while (setq tmp (pop tmpfiles))
(delete-file tmp)))
(goto-char (point-max)))