+(defgroup mime-mc nil
+ "Mailcrypt interface for SEMI."
+ :prefix "mime-mc-"
+ :group 'mime)
+
+(defcustom mime-mc-shell-file-name "/bin/sh"
+ "File name to load inferior shells from. Bourne shell or its equivalent
+\(not tcsh) is needed for \"2>\"."
+ :group 'mime-mc
+ :type 'file)
+
+(defcustom mime-mc-shell-command-switch "-c"
+ "Switch used to have the shell execute its command line argument."
+ :group 'mime-mc
+ :type 'string)
+
+(defcustom mime-mc-omit-micalg nil
+ "Non-nil value means to omit the micalg parameter for multipart/signed.
+See draft-yamamoto-openpgp-mime-00.txt (OpenPGP/MIME) for more information."
+ :group 'mime-mc
+ :type 'boolean)
+
+(defcustom mime-mc-comment-alist
+ (let ((product-name (mime-product-name mime-user-interface-product))
+ (version (mapconcat
+ (function number-to-string)
+ (mime-product-version mime-user-interface-product)
+ "."))
+ (codename (mime-product-code-name mime-user-interface-product))
+ string)
+ (while (string-match "ò" codename)
+ (setq codename (replace-match "o" t nil codename)))
+ (while (string-match "þ" codename)
+ (setq codename (replace-match "u" t nil codename)))
+ (setq string (format "Processed by Mailcrypt %s under %s %s%s"
+ mc-version product-name version
+ (if (string-match "^[ -~]+$" codename)
+ (concat " - \"" codename "\"")
+ "")))
+ (list (cons 'gpg string)
+ (cons 'pgp50 string)
+ (cons 'pgp string)))
+ "Alist of the schemes and strings of the comment field to appear in ASCII
+armor output."
+ :group 'mime-mc
+ :type '(repeat (cons :format "%v"
+ (choice (choice-item :tag "GnuPG" gpg)
+ (choice-item :tag "PGP 5.0i" pgp50)
+ (choice-item :tag "PGP 2.6" pgp))
+ (string :tag "Comment"))))
+
+(defvar mime-mc-symbol-format-alist
+ '((comment . "mc-%s-comment")
+ (fetch-key . "mc-%s-fetch-key")
+ (insert-key . "mc-%s-insert-public-key")
+ (mime-encrypt . "mime-mc-%s-encrypt-region")
+ (mime-sign . "mime-mc-%s-sign-region")
+ (scheme . "mc-scheme-%s")
+ (traditional-sign . "mc-%s-sign-region")
+ )
+ "Alist of service names and corresponding format strings.")
+
+(defmacro mime-mc-symbol (service)
+ (` (intern
+ (format (cdr (assq (, service) mime-mc-symbol-format-alist))
+ pgp-version))))
+
+(defmacro mime-mc-comment ()
+ "Return a string of the comment field."
+ '(or (cdr (assq pgp-version mime-mc-comment-alist))
+ (symbol-value (mime-mc-symbol 'comment))
+ ))
+
+
+;;; @ Internal variable
+;;;
+
+(defvar mime-mc-micalg-alist nil
+ "Alist of KeyID and the value of message integrity check algorithm.")
+
+
+;;; @ External variables (for avoid byte compile warnings)
+;;;
+