(mm-insert-inline
handle
(concat "\n-- \n"
- (if (fboundp 'vcard-pretty-print)
- (vcard-pretty-print (mm-get-part handle))
- (vcard-format-string
- (vcard-parse-string (mm-get-part handle)
- 'vcard-standard-filter))))))
+ (ignore-errors
+ (if (fboundp 'vcard-pretty-print)
+ (vcard-pretty-print (mm-get-part handle))
+ (vcard-format-string
+ (vcard-parse-string (mm-get-part handle)
+ 'vcard-standard-filter)))))))
(t
(let ((b (point))
(charset (mail-content-type-get
(mm-string-as-unibyte
(apply 'concat
(mapcar 'char-to-string
- (list ?\x30 ?\x82 ?\x2e ?\x2e ?\x06 ?\x09 ?\x5c ?\x2a
- ?\x86 ?\x48 ?\x86 ?\xf7 ?\x0d ?\x01 ?\x07 ?\x02)))))
+ (list ?\x30 ?\x5c ?\x28 ?\x80 ?\x5c ?\x7c ?\x81 ?\x2e ?\x5c
+ ?\x7c ?\x82 ?\x2e ?\x2e ?\x5c ?\x7c ?\x83 ?\x2e ?\x2e
+ ?\x2e ?\x5c ?\x29 ?\x06 ?\x09 ?\x5c ?\x2a ?\x86 ?\x48
+ ?\x86 ?\xf7 ?\x0d ?\x01 ?\x07 ?\x02)))))
;; id-envelopedData OBJECT IDENTIFIER ::= { iso(1) member-body(2)
;; us(840) rsadsi(113549) pkcs(1) pkcs7(7) 3 }
(mm-string-as-unibyte
(apply 'concat
(mapcar 'char-to-string
- (list ?\x30 ?\x82 ?\x2e ?\x2e ?\x06 ?\x09 ?\x5c ?\x2a
- ?\x86 ?\x48 ?\x86 ?\xf7 ?\x0d ?\x01 ?\x07 ?\x03)))))
+ (list ?\x30 ?\x5c ?\x28 ?\x80 ?\x5c ?\x7c ?\x81 ?\x2e ?\x5c
+ ?\x7c ?\x82 ?\x2e ?\x2e ?\x5c ?\x7c ?\x83 ?\x2e ?\x2e
+ ?\x2e ?\x5c ?\x29 ?\x06 ?\x09 ?\x5c ?\x2a ?\x86 ?\x48
+ ?\x86 ?\xf7 ?\x0d ?\x01 ?\x07 ?\x03)))))
(defun mm-view-pkcs7-get-type (handle)
(mm-with-unibyte-buffer
(otherwise (error "Unknown or unimplemented PKCS#7 type"))))
(defun mm-view-pkcs7-decrypt (handle)
- (if (cond
- ((eq mm-decrypt-option 'never) nil)
- ((eq mm-decrypt-option 'always) t)
- ((eq mm-decrypt-option 'known) t)
- (t (y-or-n-p
- (format "Decrypt (S/MIME) part? "))))
- (let (res)
- (with-temp-buffer
- (insert-buffer (mm-handle-buffer handle))
- (goto-char (point-min))
- (insert "MIME-Version: 1.0\n")
- (mm-insert-headers "application/pkcs7-mime" "base64" "smime.p7m")
- (smime-decrypt-region
- (point-min) (point-max)
- (if (= (length smime-keys) 1)
- (cadar smime-keys)
- (smime-get-key-by-email
- (completing-read "Decrypt this part with which key? "
- smime-keys nil nil
- (and (listp (car-safe smime-keys))
- (caar smime-keys))))))
- (setq res (buffer-string)))
- (mm-insert-inline handle res))))
+ (insert-buffer (mm-handle-buffer handle))
+ (goto-char (point-min))
+ (insert "MIME-Version: 1.0\n")
+ (mm-insert-headers "application/pkcs7-mime" "base64" "smime.p7m")
+ (smime-decrypt-region
+ (point-min) (point-max)
+ (if (= (length smime-keys) 1)
+ (cadar smime-keys)
+ (smime-get-key-by-email
+ (completing-read "Decrypt this part with which key? "
+ smime-keys nil nil
+ (and (listp (car-safe smime-keys))
+ (caar smime-keys)))))))
(provide 'mm-view)