2 * Claws Mail -- a GTK+ based, lightweight, and fast e-mail client
3 * Copyright (C) 1999-2012 Colin Leroy <colin@colino.net> and
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 3 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23 #include "claws-features.h"
32 #include <glib/gi18n.h>
39 #include <plugins/pgpcore/sgpgme.h>
40 #include <plugins/pgpcore/prefs_gpg.h>
41 #include <plugins/pgpcore/pgp_utils.h>
42 #include <plugins/pgpcore/passphrase.h>
44 #include "alertpanel.h"
45 #include "prefs_common.h"
49 typedef struct _PrivacyDataPGP PrivacyDataPGP;
51 struct _PrivacyDataPGP
55 gboolean done_sigtest;
57 gpgme_verify_result_t sigstatus;
61 static PrivacySystem smime_system;
63 static gint smime_check_signature(MimeInfo *mimeinfo);
65 static PrivacyDataPGP *smime_new_privacydata()
69 data = g_new0(PrivacyDataPGP, 1);
70 data->data.system = &smime_system;
71 data->done_sigtest = FALSE;
72 data->is_signed = FALSE;
73 data->sigstatus = NULL;
74 gpgme_new(&data->ctx);
79 static void smime_free_privacydata(PrivacyData *_data)
81 PrivacyDataPGP *data = (PrivacyDataPGP *) _data;
82 gpgme_release(data->ctx);
86 static gboolean smime_is_signed(MimeInfo *mimeinfo)
90 const gchar *protocol, *tmpstr;
91 PrivacyDataPGP *data = NULL;
93 cm_return_val_if_fail(mimeinfo != NULL, FALSE);
94 if (mimeinfo->privacy != NULL) {
95 data = (PrivacyDataPGP *) mimeinfo->privacy;
96 if (data->done_sigtest)
97 return data->is_signed;
100 if (!g_ascii_strcasecmp(mimeinfo->subtype, "pkcs7-mime") ||
101 !g_ascii_strcasecmp(mimeinfo->subtype, "x-pkcs7-mime")) {
102 tmpstr = procmime_mimeinfo_get_parameter(mimeinfo, "smime-type");
103 if (tmpstr && !g_ascii_strcasecmp(tmpstr, "signed-data")) {
105 data = smime_new_privacydata();
106 mimeinfo->privacy = (PrivacyData *) data;
109 data->done_sigtest = TRUE;
110 data->is_signed = TRUE;
111 smime_check_signature(mimeinfo);
117 parent = procmime_mimeinfo_parent(mimeinfo);
121 if ((parent->type != MIMETYPE_MULTIPART) ||
122 g_ascii_strcasecmp(parent->subtype, "signed"))
124 protocol = procmime_mimeinfo_get_parameter(parent, "protocol");
125 if ((protocol == NULL) ||
126 (g_ascii_strcasecmp(protocol, "application/pkcs7-signature") &&
127 g_ascii_strcasecmp(protocol, "application/x-pkcs7-signature")))
130 /* check if mimeinfo is the first child */
131 if (parent->node->children->data != mimeinfo)
135 /* check signature */
136 signature = parent->node->children->next != NULL ?
137 (MimeInfo *) parent->node->children->next->data : NULL;
138 if (signature == NULL)
140 if ((signature->type != MIMETYPE_APPLICATION) ||
141 (g_ascii_strcasecmp(signature->subtype, "pkcs7-signature") &&
142 g_ascii_strcasecmp(signature->subtype, "x-pkcs7-signature")))
146 data = smime_new_privacydata();
147 mimeinfo->privacy = (PrivacyData *) data;
150 data->done_sigtest = TRUE;
151 data->is_signed = TRUE;
156 static gchar *get_canonical_content(FILE *fp, const gchar *boundary)
160 guint boundary_len = 0;
164 boundary_len = strlen(boundary);
165 while (fgets(buf, sizeof(buf), fp) != NULL)
166 if (IS_BOUNDARY(buf, boundary, boundary_len))
170 textbuffer = g_string_new("");
171 while (fgets(buf, sizeof(buf), fp) != NULL) {
174 if (boundary && IS_BOUNDARY(buf, boundary, boundary_len))
177 buf2 = canonicalize_str(buf);
178 g_string_append(textbuffer, buf2);
181 g_string_truncate(textbuffer, textbuffer->len - 2);
183 ret = textbuffer->str;
184 g_string_free(textbuffer, FALSE);
189 static gint smime_check_signature(MimeInfo *mimeinfo)
191 PrivacyDataPGP *data;
192 MimeInfo *parent, *signature;
195 gchar *textstr = NULL;
197 gpgme_data_t sigdata = NULL, textdata = NULL;
199 cm_return_val_if_fail(mimeinfo != NULL, -1);
200 cm_return_val_if_fail(mimeinfo->privacy != NULL, -1);
201 data = (PrivacyDataPGP *) mimeinfo->privacy;
202 gpgme_new(&data->ctx);
203 EncodingType oldenc = ENC_BINARY;
205 debug_print("Checking S/MIME signature\n");
207 err = gpgme_set_protocol(data->ctx, GPGME_PROTOCOL_CMS);
210 debug_print ("gpgme_set_protocol failed: %s\n",
211 gpgme_strerror (err));
213 parent = procmime_mimeinfo_parent(mimeinfo);
215 fp = g_fopen(parent->data.filename, "rb");
216 cm_return_val_if_fail(fp != NULL, SIGNATURE_INVALID);
218 boundary = g_hash_table_lookup(parent->typeparameters, "boundary");
220 gchar *tmpfile = get_tmp_file();
221 debug_print("no boundary\n");
223 if (mimeinfo->encoding_type != ENC_BASE64) {
224 procmime_encode_content(mimeinfo, ENC_BASE64);
226 oldenc = mimeinfo->encoding_type;
227 if (mimeinfo->encoding_type == ENC_BASE64)
228 mimeinfo->encoding_type = ENC_BINARY;
229 if (procmime_get_part(tmpfile, mimeinfo) == 0) {
230 textstr = file_read_to_str(tmpfile);
234 if (mimeinfo->encoding_type != oldenc)
235 mimeinfo->encoding_type = oldenc;
239 textstr = get_canonical_content(fp, boundary);
241 err = gpgme_data_new_from_mem(&textdata, textstr, textstr?strlen(textstr):0, 0);
244 debug_print ("gpgme_data_new_from_mem failed: %s\n",
245 gpgme_strerror (err));
248 if (!g_ascii_strcasecmp(mimeinfo->subtype, "pkcs7-mime") ||
249 !g_ascii_strcasecmp(mimeinfo->subtype, "x-pkcs7-mime")) {
250 tmpstr = procmime_mimeinfo_get_parameter(mimeinfo, "smime-type");
251 if (tmpstr && !g_ascii_strcasecmp(tmpstr, "signed-data")) {
254 if (oldenc == ENC_BASE64)
255 gpgme_data_set_encoding (textdata, GPGME_DATA_ENCODING_BASE64);
256 gpgme_data_new(&cipher);
258 sgpgme_verify_signature (data->ctx, textdata, NULL, cipher);
259 gpgme_data_release(textdata);
261 cm_gpgme_data_rewind(cipher);
262 textstr = sgpgme_data_release_and_get_mem(cipher, &len);
264 if (textstr && len > 0)
267 if (textstr && len) {
268 gchar *tmp_file = get_tmp_file();
269 MimeInfo *newinfo = NULL, *decinfo = NULL, *parentinfo = NULL;
271 str_write_to_file(textstr, tmp_file);
272 newinfo = procmime_scan_file(tmp_file);
273 decinfo = g_node_first_child(newinfo->node) != NULL ?
274 g_node_first_child(newinfo->node)->data : NULL;
279 g_node_unlink(decinfo->node);
280 procmime_mimeinfo_free_all(newinfo);
282 parentinfo = procmime_mimeinfo_parent(mimeinfo);
284 if (parentinfo->type == MIMETYPE_MESSAGE &&
285 !strcmp(parentinfo->subtype, "rfc822")) {
286 procmime_decode_content(parentinfo);
287 procmime_encode_content(parentinfo, ENC_BASE64);
288 procmime_encode_content(parentinfo, ENC_8BIT);
289 if (parentinfo->content == MIMECONTENT_MEM) {
291 (gint)(strstr(parentinfo->data.mem, "\n\n") - parentinfo->data.mem);
293 parentinfo->length = newlen;
296 g_node_prepend(parentinfo->node, decinfo->node);
304 signature = (MimeInfo *) mimeinfo->node->next->data;
305 sigdata = sgpgme_data_from_mimeinfo(signature);
308 if (signature->encoding_type == ENC_BASE64) {
309 err = gpgme_data_set_encoding (sigdata, GPGME_DATA_ENCODING_BASE64);
313 debug_print ("gpgme_data_set_encoding failed: %s\n",
314 gpgme_strerror (err));
318 sgpgme_verify_signature (data->ctx, sigdata, textdata, NULL);
320 gpgme_data_release(sigdata);
321 gpgme_data_release(textdata);
328 static SignatureStatus smime_get_sig_status(MimeInfo *mimeinfo)
330 PrivacyDataPGP *data = (PrivacyDataPGP *) mimeinfo->privacy;
332 cm_return_val_if_fail(data != NULL, SIGNATURE_INVALID);
334 return sgpgme_sigstat_gpgme_to_privacy(data->ctx, data->sigstatus);
337 static gchar *smime_get_sig_info_short(MimeInfo *mimeinfo)
339 PrivacyDataPGP *data = (PrivacyDataPGP *) mimeinfo->privacy;
341 cm_return_val_if_fail(data != NULL, g_strdup("Error"));
343 return sgpgme_sigstat_info_short(data->ctx, data->sigstatus);
346 static gchar *smime_get_sig_info_full(MimeInfo *mimeinfo)
348 PrivacyDataPGP *data = (PrivacyDataPGP *) mimeinfo->privacy;
350 cm_return_val_if_fail(data != NULL, g_strdup("Error"));
352 return sgpgme_sigstat_info_full(data->ctx, data->sigstatus);
355 static gboolean smime_is_encrypted(MimeInfo *mimeinfo)
359 if (mimeinfo->type != MIMETYPE_APPLICATION)
361 if (!g_ascii_strcasecmp(mimeinfo->subtype, "pkcs7-mime")) {
362 tmpstr = procmime_mimeinfo_get_parameter(mimeinfo, "smime-type");
363 if (tmpstr && g_ascii_strcasecmp(tmpstr, "enveloped-data"))
368 } else if (!g_ascii_strcasecmp(mimeinfo->subtype, "x-pkcs7-mime")) {
369 tmpstr = procmime_mimeinfo_get_parameter(mimeinfo, "smime-type");
370 if (tmpstr && g_ascii_strcasecmp(tmpstr, "enveloped-data"))
378 static MimeInfo *smime_decrypt(MimeInfo *mimeinfo)
380 MimeInfo *encinfo, *decinfo, *parseinfo;
381 gpgme_data_t cipher = NULL, plain = NULL;
385 gpgme_verify_result_t sigstat = NULL;
386 PrivacyDataPGP *data = NULL;
392 cm_return_val_if_fail(smime_is_encrypted(mimeinfo), NULL);
394 if ((err = gpgme_new(&ctx)) != GPG_ERR_NO_ERROR) {
395 privacy_set_error(_("Couldn't initialize GPG context, %s"), gpgme_strerror(err));
399 err = gpgme_set_protocol(ctx, GPGME_PROTOCOL_CMS);
401 debug_print ("gpgme_set_protocol failed: %s\n",
402 gpgme_strerror (err));
403 privacy_set_error(_("Couldn't set GPG protocol, %s"), gpgme_strerror(err));
407 gpgme_set_armor(ctx, TRUE);
411 cipher = sgpgme_data_from_mimeinfo(encinfo);
413 plain = sgpgme_decrypt_verify(cipher, &sigstat, ctx);
415 gpgme_data_release(cipher);
417 debug_print("plain is null!\n");
422 fname = g_strdup_printf("%s%cplaintext.%08x",
423 get_mime_tmp_dir(), G_DIR_SEPARATOR, ++id);
425 if ((dstfp = g_fopen(fname, "wb")) == NULL) {
426 FILE_OP_ERROR(fname, "g_fopen");
428 gpgme_data_release(plain);
430 debug_print("can't open!\n");
431 privacy_set_error(_("Couldn't open temporary file"));
435 if (fprintf(dstfp, "MIME-Version: 1.0\n") < 0) {
436 FILE_OP_ERROR(fname, "fprintf");
439 gpgme_data_release(plain);
441 debug_print("can't close!\n");
442 privacy_set_error(_("Couldn't write to temporary file"));
446 chars = sgpgme_data_release_and_get_mem(plain, &len);
449 if (fwrite(chars, 1, len, dstfp) < len) {
450 FILE_OP_ERROR(fname, "fwrite");
454 gpgme_data_release(plain);
456 debug_print("can't write!\n");
457 privacy_set_error(_("Couldn't write to temporary file"));
461 if (fclose(dstfp) == EOF) {
462 FILE_OP_ERROR(fname, "fclose");
465 gpgme_data_release(plain);
467 debug_print("can't close!\n");
468 privacy_set_error(_("Couldn't close temporary file"));
473 parseinfo = procmime_scan_file(fname);
475 if (parseinfo == NULL) {
476 privacy_set_error(_("Couldn't parse decrypted file."));
480 decinfo = g_node_first_child(parseinfo->node) != NULL ?
481 g_node_first_child(parseinfo->node)->data : NULL;
482 if (decinfo == NULL) {
483 privacy_set_error(_("Couldn't parse decrypted file parts."));
488 g_node_unlink(decinfo->node);
489 procmime_mimeinfo_free_all(parseinfo);
493 if (sigstat != NULL && sigstat->signatures != NULL) {
494 if (decinfo->privacy != NULL) {
495 data = (PrivacyDataPGP *) decinfo->privacy;
497 data = smime_new_privacydata();
498 decinfo->privacy = (PrivacyData *) data;
500 data->done_sigtest = TRUE;
501 data->is_signed = TRUE;
502 data->sigstatus = sigstat;
504 gpgme_release(data->ctx);
514 gboolean smime_sign(MimeInfo *mimeinfo, PrefsAccount *account, const gchar *from_addr)
516 MimeInfo *msgcontent, *sigmultipart, *newinfo;
517 gchar *textstr, *micalg = NULL;
519 gchar *boundary = NULL;
522 gpgme_data_t gpgtext, gpgsig;
525 struct passphrase_cb_info_s info;
526 gpgme_sign_result_t result = NULL;
528 gchar *real_content = NULL;
532 perror("my_tmpfile");
535 procmime_write_mimeinfo(mimeinfo, fp);
538 /* read temporary file into memory */
539 test_msg = file_read_stream_to_str(fp);
542 memset (&info, 0, sizeof info);
544 /* remove content node from message */
545 msgcontent = (MimeInfo *) mimeinfo->node->children->data;
546 g_node_unlink(msgcontent->node);
548 /* create temporary multipart for content */
549 sigmultipart = procmime_mimeinfo_new();
550 sigmultipart->type = MIMETYPE_MULTIPART;
551 sigmultipart->subtype = g_strdup("signed");
556 boundary = generate_mime_boundary("Sig");
557 } while (strstr(test_msg, boundary) != NULL);
561 g_hash_table_insert(sigmultipart->typeparameters, g_strdup("boundary"),
563 g_hash_table_insert(sigmultipart->typeparameters, g_strdup("protocol"),
564 g_strdup("application/pkcs7-signature"));
565 g_node_append(sigmultipart->node, msgcontent->node);
566 g_node_append(mimeinfo->node, sigmultipart->node);
568 /* write message content to temporary file */
571 perror("my_tmpfile");
574 procmime_write_mimeinfo(sigmultipart, fp);
577 /* read temporary file into memory */
578 textstr = get_canonical_content(fp, boundary);
584 gpgme_data_new_from_mem(&gpgtext, textstr, textstr?strlen(textstr):0, 0);
585 gpgme_data_new(&gpgsig);
587 gpgme_set_armor(ctx, TRUE);
588 gpgme_signers_clear (ctx);
590 err = gpgme_set_protocol(ctx, GPGME_PROTOCOL_CMS);
593 debug_print ("gpgme_set_protocol failed: %s\n",
594 gpgme_strerror (err));
595 gpgme_data_release(gpgtext);
600 if (!sgpgme_setup_signers(ctx, account, from_addr)) {
601 debug_print("setup_signers failed\n");
602 gpgme_data_release(gpgtext);
608 prefs_gpg_enable_agent(TRUE);
609 gpgme_set_passphrase_cb (ctx, NULL, &info);
611 err = gpgme_op_sign(ctx, gpgtext, gpgsig, GPGME_SIG_MODE_DETACH);
612 if (err != GPG_ERR_NO_ERROR) {
613 alertpanel_error("S/MIME : Cannot sign, %s (%d)", gpg_strerror(err), gpg_err_code(err));
614 gpgme_data_release(gpgtext);
618 result = gpgme_op_sign_result(ctx);
619 if (result && result->signatures) {
620 if (gpgme_get_protocol(ctx) == GPGME_PROTOCOL_OpenPGP) {
621 micalg = g_strdup_printf("pgp-%s", g_ascii_strdown(gpgme_hash_algo_name(
622 result->signatures->hash_algo),-1));
624 micalg = g_strdup(gpgme_hash_algo_name(
625 result->signatures->hash_algo));
628 /* can't get result (maybe no signing key?) */
629 debug_print("gpgme_op_sign_result error\n");
634 sigcontent = sgpgme_data_release_and_get_mem(gpgsig, &len);
635 gpgme_data_release(gpgtext);
643 real_content = sigcontent+strlen("-----BEGIN SIGNED MESSAGE-----\n");
644 if (!strstr(real_content, "-----END SIGNED MESSAGE-----")) {
645 debug_print("missing end\n");
650 *strstr(real_content, "-----END SIGNED MESSAGE-----") = '\0';
652 g_hash_table_insert(sigmultipart->typeparameters, g_strdup("micalg"),
655 newinfo = procmime_mimeinfo_new();
656 newinfo->type = MIMETYPE_APPLICATION;
657 newinfo->subtype = g_strdup("pkcs7-signature");
658 g_hash_table_insert(newinfo->typeparameters, g_strdup("name"),
659 g_strdup("smime.p7s"));
660 newinfo->content = MIMECONTENT_MEM;
661 newinfo->disposition = DISPOSITIONTYPE_ATTACHMENT;
662 g_hash_table_insert(newinfo->dispositionparameters, g_strdup("filename"),
663 g_strdup("smime.p7s"));
664 newinfo->data.mem = g_malloc(len + 1);
665 g_memmove(newinfo->data.mem, real_content, len);
666 newinfo->data.mem[len] = '\0';
667 newinfo->encoding_type = ENC_BASE64;
668 g_node_append(sigmultipart->node, newinfo->node);
674 gchar *smime_get_encrypt_data(GSList *recp_names)
676 return sgpgme_get_encrypt_data(recp_names, GPGME_PROTOCOL_CMS);
679 static const gchar *smime_get_encrypt_warning(void)
681 if (prefs_gpg_should_skip_encryption_warning(smime_system.id))
684 return _("Please note that email headers, like Subject, "
685 "are not encrypted by the S/MIME system.");
688 static void smime_inhibit_encrypt_warning(gboolean inhibit)
691 prefs_gpg_add_skip_encryption_warning(smime_system.id);
693 prefs_gpg_remove_skip_encryption_warning(smime_system.id);
696 gboolean smime_encrypt(MimeInfo *mimeinfo, const gchar *encrypt_data)
698 MimeInfo *msgcontent, *encmultipart;
702 gchar *textstr = NULL;
703 gpgme_data_t gpgtext = NULL, gpgenc = NULL;
704 gpgme_ctx_t ctx = NULL;
705 gpgme_key_t *kset = NULL;
706 gchar **fprs = g_strsplit(encrypt_data, " ", -1);
709 gchar *tmpfile = NULL;
711 while (fprs[i] && strlen(fprs[i])) {
717 err = gpgme_set_protocol(ctx, GPGME_PROTOCOL_CMS);
720 debug_print ("gpgme_set_protocol failed: %s\n",
721 gpgme_strerror (err));
725 kset = g_malloc(sizeof(gpgme_key_t)*(i+1));
726 memset(kset, 0, sizeof(gpgme_key_t)*(i+1));
729 while (fprs[i] && strlen(fprs[i])) {
732 err = gpgme_get_key(ctx, fprs[i], &key, 0);
734 debug_print("can't add key '%s'[%d] (%s)\n", fprs[i],i, gpgme_strerror(err));
737 debug_print("found %s at %d\n", fprs[i], i);
742 debug_print("Encrypting message content\n");
744 /* remove content node from message */
745 msgcontent = (MimeInfo *) mimeinfo->node->children->data;
746 g_node_unlink(msgcontent->node);
749 /* create temporary multipart for content */
750 encmultipart = procmime_mimeinfo_new();
751 encmultipart->type = MIMETYPE_APPLICATION;
752 encmultipart->subtype = g_strdup("x-pkcs7-mime");
753 g_hash_table_insert(encmultipart->typeparameters, g_strdup("name"),
754 g_strdup("smime.p7m"));
755 g_hash_table_insert(encmultipart->typeparameters,
756 g_strdup("smime-type"),
757 g_strdup("enveloped-data"));
759 encmultipart->disposition = DISPOSITIONTYPE_ATTACHMENT;
760 g_hash_table_insert(encmultipart->dispositionparameters, g_strdup("filename"),
761 g_strdup("smime.p7m"));
763 g_node_append(encmultipart->node, msgcontent->node);
765 /* write message content to temporary file */
766 tmpfile = get_tmp_file();
767 fp = g_fopen(tmpfile, "wb");
769 perror("get_tmp_file");
773 procmime_decode_content(msgcontent);
774 procmime_write_mime_header(msgcontent, fp);
775 procmime_write_mimeinfo(msgcontent, fp);
777 canonicalize_file_replace(tmpfile);
778 fp = g_fopen(tmpfile, "rb");
780 perror("get_tmp_file");
786 /* read temporary file into memory */
787 textstr = fp_read_noconv(fp);
792 gpgme_data_new_from_mem(&gpgtext, textstr, textstr?strlen(textstr):0, 0);
793 gpgme_data_new(&gpgenc);
794 cm_gpgme_data_rewind(gpgtext);
796 gpgme_op_encrypt(ctx, kset, GPGME_ENCRYPT_ALWAYS_TRUST, gpgtext, gpgenc);
800 enccontent = sgpgme_data_release_and_get_mem(gpgenc, &len);
803 g_warning("no enccontent\n");
807 tmpfile = get_tmp_file();
808 fp = g_fopen(tmpfile, "wb");
810 if (fwrite(enccontent, 1, len, fp) < len) {
811 FILE_OP_ERROR(tmpfile, "fwrite");
813 claws_unlink(tmpfile);
817 if (fclose(fp) == EOF) {
818 FILE_OP_ERROR(tmpfile, "fclose");
819 claws_unlink(tmpfile);
824 perror("get_tmp_file");
828 gpgme_data_release(gpgtext);
831 /* create encrypted multipart */
832 procmime_mimeinfo_free_all(msgcontent);
833 g_node_append(mimeinfo->node, encmultipart->node);
835 encmultipart->content = MIMECONTENT_FILE;
836 encmultipart->data.filename = tmpfile;
837 procmime_encode_content(encmultipart, ENC_BASE64);
844 static PrivacySystem smime_system = {
848 smime_free_privacydata, /* free_privacydata */
850 smime_is_signed, /* is_signed(MimeInfo *) */
851 smime_check_signature, /* check_signature(MimeInfo *) */
852 smime_get_sig_status, /* get_sig_status(MimeInfo *) */
853 smime_get_sig_info_short, /* get_sig_info_short(MimeInfo *) */
854 smime_get_sig_info_full, /* get_sig_info_full(MimeInfo *) */
856 smime_is_encrypted, /* is_encrypted(MimeInfo *) */
857 smime_decrypt, /* decrypt(MimeInfo *) */
863 smime_get_encrypt_data,
865 smime_get_encrypt_warning,
866 smime_inhibit_encrypt_warning,
867 prefs_gpg_auto_check_signatures,
872 privacy_register_system(&smime_system);
877 privacy_unregister_system(&smime_system);
880 struct PluginFeature *plugin_provides(void)
882 static struct PluginFeature features[] =
883 { {PLUGIN_PRIVACY, N_("S/MIME")},
884 {PLUGIN_NOTHING, NULL}};
887 #endif /* USE_GPGME */