]> granicus.if.org Git - neomutt/commitdiff
unify the naming of all the ncrypt API functions
authorRichard Russon <rich@flatcap.org>
Mon, 11 Jun 2018 23:18:17 +0000 (00:18 +0100)
committerRichard Russon <rich@flatcap.org>
Tue, 12 Jun 2018 01:01:38 +0000 (02:01 +0100)
20 files changed:
handler.c
ncrypt/crypt.c
ncrypt/crypt_gpgme.c
ncrypt/crypt_gpgme.h
ncrypt/crypt_mod.h
ncrypt/crypt_mod_pgp_classic.c
ncrypt/crypt_mod_pgp_gpgme.c
ncrypt/crypt_mod_smime_classic.c
ncrypt/crypt_mod_smime_gpgme.c
ncrypt/cryptglue.c
ncrypt/cryptglue.h
ncrypt/ncrypt.h
ncrypt/pgp.c
ncrypt/pgp.h
ncrypt/pgpinvoke.c
ncrypt/pgpinvoke.h
ncrypt/pgpkey.c
ncrypt/pgpkey.h
ncrypt/smime.c
ncrypt/smime.h

index 009e6273941f5ac3a78f54a59f9fbf475d118081..8e7329d8d03bcf54aec732d6ac7a49e8f4b36cd0 100644 (file)
--- a/handler.c
+++ b/handler.c
@@ -1536,7 +1536,7 @@ int mutt_body_handler(struct Body *b, struct State *s)
        * the only operation needed.
        */
       if (((WithCrypto & APPLICATION_PGP) != 0) && mutt_is_application_pgp(b))
-        handler = crypt_pgp_application_pgp_handler;
+        handler = crypt_pgp_application_handler;
       else if (ReflowText &&
                (mutt_str_strcasecmp("flowed",
                                     mutt_param_get(&b->parameter, "format")) == 0))
@@ -1607,9 +1607,9 @@ int mutt_body_handler(struct Body *b, struct State *s)
       plaintext = true;
     }
     else if (((WithCrypto & APPLICATION_PGP) != 0) && mutt_is_application_pgp(b))
-      handler = crypt_pgp_application_pgp_handler;
+      handler = crypt_pgp_application_handler;
     else if (((WithCrypto & APPLICATION_SMIME) != 0) && mutt_is_application_smime(b))
-      handler = crypt_smime_application_smime_handler;
+      handler = crypt_smime_application_handler;
   }
 
   /* only respect disposition == attachment if we're not
index 8efe59d931c1465758206b94a0c19ef86e41510d..5cfdf71c7055975d7189c38ed7c62a39d60bf460 100644 (file)
@@ -888,7 +888,7 @@ int crypt_get_keys(struct Header *msg, char **keylist, bool oppenc_mode)
   {
     if (((WithCrypto & APPLICATION_PGP) != 0) && (msg->security & APPLICATION_PGP))
     {
-      *keylist = crypt_pgp_findkeys(addrlist, oppenc_mode);
+      *keylist = crypt_pgp_find_keys(addrlist, oppenc_mode);
       if (!*keylist)
       {
         mutt_addr_free(&addrlist);
@@ -900,7 +900,7 @@ int crypt_get_keys(struct Header *msg, char **keylist, bool oppenc_mode)
     }
     if (((WithCrypto & APPLICATION_SMIME) != 0) && (msg->security & APPLICATION_SMIME))
     {
-      *keylist = crypt_smime_findkeys(addrlist, oppenc_mode);
+      *keylist = crypt_smime_find_keys(addrlist, oppenc_mode);
       if (!*keylist)
       {
         mutt_addr_free(&addrlist);
index 168084e6f730a149f2e18052d4d451a00435e732..b91a5d4fb701b2249edfeb0db93ed8ef30f1f6bd 100644 (file)
@@ -4729,24 +4729,27 @@ static char *find_keys(struct Address *addrlist, unsigned int app, bool oppenc_m
 }
 
 /**
- * pgp_gpgme_findkeys - Implements CryptModuleSpecs::findkeys()
+ * pgp_gpgme_find_keys - Implements CryptModuleSpecs::find_keys()
  */
-char *pgp_gpgme_findkeys(struct Address *addrlist, bool oppenc_mode)
+char *pgp_gpgme_find_keys(struct Address *addrlist, bool oppenc_mode)
 {
   return find_keys(addrlist, APPLICATION_PGP, oppenc_mode);
 }
 
 /**
- * smime_gpgme_findkeys - Implements CryptModuleSpecs::findkeys()
+ * smime_gpgme_find_keys - Implements CryptModuleSpecs::find_keys()
  */
-char *smime_gpgme_findkeys(struct Address *addrlist, bool oppenc_mode)
+char *smime_gpgme_find_keys(struct Address *addrlist, bool oppenc_mode)
 {
   return find_keys(addrlist, APPLICATION_SMIME, oppenc_mode);
 }
 
-#ifdef HAVE_GPGME_OP_EXPORT_KEYS
+/**
+ * pgp_gpgme_make_key_attachment - Implements CryptModuleSpecs::pgp_make_key_attachment()
+ */
 struct Body *pgp_gpgme_make_key_attachment(char *tempf)
 {
+#ifdef HAVE_GPGME_OP_EXPORT_KEYS
   gpgme_ctx_t context = NULL;
   gpgme_key_t export_keys[2];
   gpgme_data_t keydata = NULL;
@@ -4802,8 +4805,10 @@ bail:
   gpgme_release(context);
 
   return att;
-}
+#else
+  return NULL;
 #endif
+}
 
 /**
  * init_common - Initialise code common to PGP and SMIME parts of GPGME
@@ -5120,9 +5125,9 @@ int smime_gpgme_verify_sender(struct Header *h)
 }
 
 /**
- * mutt_gpgme_set_sender - Implements CryptModuleSpecs::set_sender()
+ * pgp_gpgme_set_sender - Implements CryptModuleSpecs::set_sender()
  */
-void mutt_gpgme_set_sender(const char *sender)
+void pgp_gpgme_set_sender(const char *sender)
 {
   mutt_debug(2, "setting to: %s\n", sender);
   FREE(&current_sender);
index 33c6943aaf0544f0225ab32d28610a765c6f1fbe..ab263368d82ce660d3d279546422349470b0fc74 100644 (file)
@@ -31,14 +31,14 @@ struct Body;
 struct Header;
 struct State;
 
-void         mutt_gpgme_set_sender(const char *sender);
+void         pgp_gpgme_set_sender(const char *sender);
 
 int          pgp_gpgme_application_handler(struct Body *m, struct State *s);
 int          pgp_gpgme_check_traditional(FILE *fp, struct Body *b, int just_one);
 int          pgp_gpgme_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur);
 int          pgp_gpgme_encrypted_handler(struct Body *a, struct State *s);
 struct Body *pgp_gpgme_encrypt_message(struct Body *a, char *keylist, int sign);
-char *       pgp_gpgme_findkeys(struct Address *addrlist, bool oppenc_mode);
+char *       pgp_gpgme_find_keys(struct Address *addrlist, bool oppenc_mode);
 void         pgp_gpgme_init(void);
 void         pgp_gpgme_invoke_import(const char *fname);
 struct Body *pgp_gpgme_make_key_attachment(char *tempf);
@@ -49,7 +49,7 @@ int          pgp_gpgme_verify_one(struct Body *sigbdy, struct State *s, const ch
 int          smime_gpgme_application_handler(struct Body *a, struct State *s);
 struct Body *smime_gpgme_build_smime_entity(struct Body *a, char *keylist);
 int          smime_gpgme_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur);
-char *       smime_gpgme_findkeys(struct Address *addrlist, bool oppenc_mode);
+char *       smime_gpgme_find_keys(struct Address *addrlist, bool oppenc_mode);
 void         smime_gpgme_init(void);
 int          smime_gpgme_send_menu(struct Header *msg);
 struct Body *smime_gpgme_sign_message(struct Body *a);
index 7121f1b97ecc3a189f06eb47bc9a69a490f2c908..3260160d45bb9f93a182decd94f515666ad22c65 100644 (file)
@@ -85,7 +85,7 @@ struct CryptModuleSpecs
    */
   int          (*encrypted_handler)(struct Body *m, struct State *s);
   /**
-   * findkeys - Find the keyids of the recipients of a message
+   * find_keys - Find the keyids of the recipients of a message
    * @param addrlist    Address List
    * @param oppenc_mode If true, use opportunistic encryption
    * @retval ptr  Space-separated string of keys
@@ -94,7 +94,7 @@ struct CryptModuleSpecs
    * If oppenc_mode is true, only keys that can be determined without prompting
    * will be used.
    */
-  char *       (*findkeys)(struct Address *addrlist, bool oppenc_mode);
+  char *       (*find_keys)(struct Address *addrlist, bool oppenc_mode);
   /**
    * sign_message - Cryptographically sign the Body of a message
    * @param a Body of the message
index d2fb036cef1909f6793f4941d6582898e749023e..e82188c61fb50fcf0e4ee133d11b4dbd3681ab5a 100644 (file)
@@ -39,24 +39,24 @@ struct CryptModuleSpecs crypt_mod_pgp_classic = {
   APPLICATION_PGP,
 
   NULL, /* init */
-  pgp_void_passphrase,
-  pgp_valid_passphrase,
-  pgp_decrypt_mime,
-  pgp_application_pgp_handler,
-  pgp_encrypted_handler,
-  pgp_find_keys,
-  pgp_sign_message,
-  pgp_verify_one,
-  pgp_send_menu,
+  pgp_class_void_passphrase,
+  pgp_class_valid_passphrase,
+  pgp_class_decrypt_mime,
+  pgp_class_application_handler,
+  pgp_class_encrypted_handler,
+  pgp_class_find_keys,
+  pgp_class_sign_message,
+  pgp_class_verify_one,
+  pgp_class_send_menu,
   NULL, /* set_sender */
 
-  pgp_encrypt_message,
-  pgp_make_key_attachment,
-  pgp_check_traditional,
-  pgp_traditional_encryptsign,
-  pgp_invoke_getkeys,
-  pgp_invoke_import,
-  pgp_extract_keys_from_attachment_list,
+  pgp_class_encrypt_message,
+  pgp_class_make_key_attachment,
+  pgp_class_check_traditional,
+  pgp_class_traditional_encryptsign,
+  pgp_class_invoke_getkeys,
+  pgp_class_invoke_import,
+  pgp_class_extract_keys_from_attachment_list,
 
   NULL, /* smime_getkeys */
   NULL, /* smime_verify_sender */
index fc8f706e08edf2bdaa02c7f9642f9b482ad509ec..42492e8e133aae0596b400eca7729689cebf99e3 100644 (file)
 #include "ncrypt.h"
 
 /**
- * crypt_mod_pgp_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
+ * pgp_gpgme_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
  *
  * This is handled by gpg-agent.
  */
-static void crypt_mod_pgp_void_passphrase(void)
+static void pgp_gpgme_void_passphrase(void)
 {
 }
 
 /**
- * crypt_mod_pgp_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
+ * pgp_gpgme_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
  *
  * This is handled by gpg-agent.
  */
-static int crypt_mod_pgp_valid_passphrase(void)
+static int pgp_gpgme_valid_passphrase(void)
 {
   return 1;
 }
 
-/**
- * crypt_mod_pgp_make_key_attachment - Implements CryptModuleSpecs::pgp_make_key_attachment()
- */
-static struct Body *crypt_mod_pgp_make_key_attachment(char *tempf)
-{
-#ifdef HAVE_GPGME_OP_EXPORT_KEYS
-  return pgp_gpgme_make_key_attachment(tempf);
-#else
-  return NULL;
-#endif
-}
-
 // clang-format off
 struct CryptModuleSpecs crypt_mod_pgp_gpgme = {
   APPLICATION_PGP,
 
   pgp_gpgme_init,
-  crypt_mod_pgp_void_passphrase,
-  crypt_mod_pgp_valid_passphrase,
+  pgp_gpgme_void_passphrase,
+  pgp_gpgme_valid_passphrase,
   pgp_gpgme_decrypt_mime,
   pgp_gpgme_application_handler,
   pgp_gpgme_encrypted_handler,
-  pgp_gpgme_findkeys,
+  pgp_gpgme_find_keys,
   pgp_gpgme_sign_message,
   pgp_gpgme_verify_one,
   pgp_gpgme_send_menu,
-  mutt_gpgme_set_sender,
+  pgp_gpgme_set_sender,
 
   pgp_gpgme_encrypt_message,
-  crypt_mod_pgp_make_key_attachment,
+  pgp_gpgme_make_key_attachment,
   pgp_gpgme_check_traditional,
   NULL, /* pgp_traditional_encryptsign  */
   NULL, /* pgp_invoke_getkeys  */
index f795238bafffcc2b6f5f925dbcf01de81d2aca60..8d050dc0b9583b36daeef7d018867704b5990718 100644 (file)
@@ -37,15 +37,15 @@ struct CryptModuleSpecs crypt_mod_smime_classic = {
   APPLICATION_SMIME,
 
   NULL, /* init */
-  smime_void_passphrase,
-  smime_valid_passphrase,
-  smime_decrypt_mime,
-  smime_application_smime_handler,
+  smime_class_void_passphrase,
+  smime_class_valid_passphrase,
+  smime_class_decrypt_mime,
+  smime_class_application_handler,
   NULL, /* encrypted_handler */
-  smime_find_keys,
-  smime_sign_message,
-  smime_verify_one,
-  smime_send_menu,
+  smime_class_find_keys,
+  smime_class_sign_message,
+  smime_class_verify_one,
+  smime_class_send_menu,
   NULL, /* set_sender */
 
   NULL, /* pgp_encrypt_message */
@@ -56,9 +56,9 @@ struct CryptModuleSpecs crypt_mod_smime_classic = {
   NULL, /* pgp_invoke_import */
   NULL, /* pgp_extract_keys_from_attachment_list */
 
-  smime_getkeys,
-  smime_verify_sender,
-  smime_build_smime_entity,
-  smime_invoke_import,
+  smime_class_getkeys,
+  smime_class_verify_sender,
+  smime_class_build_smime_entity,
+  smime_class_invoke_import,
 };
 // clang-format on
index 8c7d268d6476f43658035adcd65de1b754861b08..a24d6cdf3b9e4992b45d323288a6920d18f95082 100644 (file)
 #include "ncrypt.h"
 
 /**
- * crypt_mod_smime_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
+ * smime_gpgme_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
  *
  * This is handled by gpg-agent.
  */
-static void crypt_mod_smime_void_passphrase(void)
+static void smime_gpgme_void_passphrase(void)
 {
 }
 
 /**
- * crypt_mod_smime_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
+ * smime_gpgme_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
  *
  * This is handled by gpg-agent.
  */
-static int crypt_mod_smime_valid_passphrase(void)
+static int smime_gpgme_valid_passphrase(void)
 {
   return 1;
 }
@@ -56,12 +56,12 @@ struct CryptModuleSpecs crypt_mod_smime_gpgme = {
   APPLICATION_SMIME,
 
   smime_gpgme_init,
-  crypt_mod_smime_void_passphrase,
-  crypt_mod_smime_valid_passphrase,
+  smime_gpgme_void_passphrase,
+  smime_gpgme_valid_passphrase,
   smime_gpgme_decrypt_mime,
   smime_gpgme_application_handler,
   NULL, /* encrypted_handler */
-  smime_gpgme_findkeys,
+  smime_gpgme_find_keys,
   smime_gpgme_sign_message,
   smime_gpgme_verify_one,
   smime_gpgme_send_menu,
index 218cd772155ab76795d207d734545900b93a02aa..fa4c735a4e06aa1b357455859231c024f0cbd39c 100644 (file)
@@ -49,12 +49,6 @@ struct Envelope;
 struct Header;
 struct State;
 
-/*
-
-    Generic
-
-*/
-
 #ifdef CRYPT_BACKEND_CLASSIC_PGP
 extern struct CryptModuleSpecs crypt_mod_pgp_classic;
 #endif
@@ -191,9 +185,9 @@ int crypt_pgp_decrypt_mime(FILE *a, FILE **b, struct Body *c, struct Body **d)
 }
 
 /**
- * crypt_pgp_application_pgp_handler - MIME handler for the pgp content-type
+ * crypt_pgp_application_handler - MIME handler for the pgp content-type
  */
-int crypt_pgp_application_pgp_handler(struct Body *m, struct State *s)
+int crypt_pgp_application_handler(struct Body *m, struct State *s)
 {
   if (CRYPT_MOD_CALL_CHECK(PGP, application_handler))
     return (CRYPT_MOD_CALL(PGP, application_handler))(m, s);
@@ -249,15 +243,15 @@ struct Body *crypt_pgp_make_key_attachment(char *tempf)
 }
 
 /**
- * crypt_pgp_findkeys - Find the keyids of the recipients of the message
+ * crypt_pgp_find_keys - Find the keyids of the recipients of the message
  *
  * It returns NULL if any of the keys can not be found.  If oppenc_mode is
  * true, only keys that can be determined without prompting will be used.
  */
-char *crypt_pgp_findkeys(struct Address *addrlist, bool oppenc_mode)
+char *crypt_pgp_find_keys(struct Address *addrlist, bool oppenc_mode)
 {
-  if (CRYPT_MOD_CALL_CHECK(PGP, findkeys))
-    return (CRYPT_MOD_CALL(PGP, findkeys))(addrlist, oppenc_mode);
+  if (CRYPT_MOD_CALL_CHECK(PGP, find_keys))
+    return (CRYPT_MOD_CALL(PGP, find_keys))(addrlist, oppenc_mode);
 
   return NULL;
 }
@@ -357,9 +351,9 @@ int crypt_smime_decrypt_mime(FILE *a, FILE **b, struct Body *c, struct Body **d)
 }
 
 /**
- * crypt_smime_application_smime_handler - Handler for application/smime
+ * crypt_smime_application_handler - Handler for application/smime
  */
-int crypt_smime_application_smime_handler(struct Body *m, struct State *s)
+int crypt_smime_application_handler(struct Body *m, struct State *s)
 {
   if (CRYPT_MOD_CALL_CHECK(SMIME, application_handler))
     return (CRYPT_MOD_CALL(SMIME, application_handler))(m, s);
@@ -394,15 +388,15 @@ int crypt_smime_verify_sender(struct Header *h)
 }
 
 /**
- * crypt_smime_findkeys - Find the keyids of the recipients of the message
+ * crypt_smime_find_keys - Find the keyids of the recipients of the message
  *
  * It returns NULL if any of the keys can not be found.  If oppenc_mode is
  * true, only keys that can be determined without prompting will be used.
  */
-char *crypt_smime_findkeys(struct Address *addrlist, bool oppenc_mode)
+char *crypt_smime_find_keys(struct Address *addrlist, bool oppenc_mode)
 {
-  if (CRYPT_MOD_CALL_CHECK(SMIME, findkeys))
-    return (CRYPT_MOD_CALL(SMIME, findkeys))(addrlist, oppenc_mode);
+  if (CRYPT_MOD_CALL_CHECK(SMIME, find_keys))
+    return (CRYPT_MOD_CALL(SMIME, find_keys))(addrlist, oppenc_mode);
 
   return NULL;
 }
index ba85b2c66aca9abea1ded24fa85f81507703c2b0..d2e22ee42fd3debe8928c6859abbeb39a9e202ca 100644 (file)
@@ -28,7 +28,7 @@ struct Body;
 struct State;
 
 struct Body *crypt_pgp_encrypt_message(struct Body *a, char *keylist, int sign);
-char *       crypt_pgp_findkeys(struct Address *addrlist, bool oppenc_mode);
+char *       crypt_pgp_find_keys(struct Address *addrlist, bool oppenc_mode);
 void         crypt_pgp_invoke_import(const char *fname);
 void         crypt_pgp_set_sender(const char *sender);
 struct Body *crypt_pgp_sign_message(struct Body *a);
@@ -38,7 +38,7 @@ int          crypt_pgp_verify_one(struct Body *sigbdy, struct State *s, const ch
 void         crypt_pgp_void_passphrase(void);
 
 struct Body *crypt_smime_build_smime_entity(struct Body *a, char *certlist);
-char *       crypt_smime_findkeys(struct Address *addrlist, bool oppenc_mode);
+char *       crypt_smime_find_keys(struct Address *addrlist, bool oppenc_mode);
 void         crypt_smime_invoke_import(char *infile, char *mailbox);
 void         crypt_smime_set_sender(const char *sender);
 struct Body *crypt_smime_sign_message(struct Body *a);
index 8153b18ef1ef22f00ced1a96251c92253ee7b7ed..9a269f800c6db2e10cae27d0eb312db94af28ea4 100644 (file)
@@ -142,7 +142,7 @@ int          mutt_signed_handler(struct Body *a, struct State *s);
 int          crypt_has_module_backend(int type);
 void         crypt_init(void);
 void         crypt_invoke_message(int type);
-int          crypt_pgp_application_pgp_handler(struct Body *m, struct State *s);
+int          crypt_pgp_application_handler(struct Body *m, struct State *s);
 int          crypt_pgp_check_traditional(FILE *fp, struct Body *b, int just_one);
 int          crypt_pgp_decrypt_mime(FILE *a, FILE **b, struct Body *c, struct Body **d);
 int          crypt_pgp_encrypted_handler(struct Body *a, struct State *s);
@@ -150,7 +150,7 @@ void         crypt_pgp_extract_keys_from_attachment_list(FILE *fp, int tag, stru
 void         crypt_pgp_invoke_getkeys(struct Address *addr);
 struct Body *crypt_pgp_make_key_attachment(char *tempf);
 int          crypt_pgp_send_menu(struct Header *msg);
-int          crypt_smime_application_smime_handler(struct Body *m, struct State *s);
+int          crypt_smime_application_handler(struct Body *m, struct State *s);
 int          crypt_smime_decrypt_mime(FILE *a, FILE **b, struct Body *c, struct Body **d);
 void         crypt_smime_getkeys(struct Envelope *env);
 int          crypt_smime_send_menu(struct Header *msg);
index 314932b9b858fb0e699e28e07a88110b0ee8100f..3c83d20aef8dc3eb5d48c5a518488105da228a93 100644 (file)
@@ -64,18 +64,18 @@ char PgpPass[LONG_STRING];
 time_t PgpExptime = 0; /* when does the cached passphrase expire? */
 
 /**
- * pgp_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
+ * pgp_class_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
  */
-void pgp_void_passphrase(void)
+void pgp_class_void_passphrase(void)
 {
   memset(PgpPass, 0, sizeof(PgpPass));
   PgpExptime = 0;
 }
 
 /**
- * pgp_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
+ * pgp_class_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
  */
-int pgp_valid_passphrase(void)
+int pgp_class_valid_passphrase(void)
 {
   time_t now = time(NULL);
 
@@ -91,7 +91,7 @@ int pgp_valid_passphrase(void)
     return 1;
   }
 
-  pgp_void_passphrase();
+  pgp_class_void_passphrase();
 
   if (mutt_get_password(_("Enter PGP passphrase:"), PgpPass, sizeof(PgpPass)) == 0)
   {
@@ -321,9 +321,9 @@ static void pgp_copy_clearsigned(FILE *fpin, struct State *s, char *charset)
 }
 
 /**
- * pgp_application_pgp_handler - Implements CryptModuleSpecs::application_handler()
+ * pgp_class_application_handler - Implements CryptModuleSpecs::application_handler()
  */
-int pgp_application_pgp_handler(struct Body *m, struct State *s)
+int pgp_class_application_handler(struct Body *m, struct State *s)
 {
   bool could_not_decrypt = false;
   int needpass = -1;
@@ -459,8 +459,8 @@ int pgp_application_pgp_handler(struct Body *m, struct State *s)
         {
           if (needpass)
           {
-            if (!pgp_valid_passphrase())
-              pgp_void_passphrase();
+            if (!pgp_class_valid_passphrase())
+              pgp_class_void_passphrase();
             if (pgp_use_gpg_agent())
               *PgpPass = 0;
             fprintf(pgpin, "%s\n", PgpPass);
@@ -507,7 +507,7 @@ int pgp_application_pgp_handler(struct Body *m, struct State *s)
         if (!clearsign && (!pgpout || c == EOF))
         {
           could_not_decrypt = true;
-          pgp_void_passphrase();
+          pgp_class_void_passphrase();
         }
 
         if (could_not_decrypt && !(s->flags & MUTT_DISPLAY))
@@ -680,16 +680,16 @@ static int pgp_check_traditional_one_body(FILE *fp, struct Body *b)
 }
 
 /**
- * pgp_check_traditional - Implements CryptModuleSpecs::pgp_check_traditional()
+ * pgp_class_check_traditional - Implements CryptModuleSpecs::pgp_check_traditional()
  */
-int pgp_check_traditional(FILE *fp, struct Body *b, int just_one)
+int pgp_class_check_traditional(FILE *fp, struct Body *b, int just_one)
 {
   int rc = 0;
   int r;
   for (; b; b = b->next)
   {
     if (!just_one && is_multipart(b))
-      rc = pgp_check_traditional(fp, b->parts, 0) || rc;
+      rc = pgp_class_check_traditional(fp, b->parts, 0) || rc;
     else if (b->type == TYPETEXT)
     {
       r = mutt_is_application_pgp(b);
@@ -707,9 +707,9 @@ int pgp_check_traditional(FILE *fp, struct Body *b, int just_one)
 }
 
 /**
- * pgp_verify_one - Implements CryptModuleSpecs::verify_one()
+ * pgp_class_verify_one - Implements CryptModuleSpecs::verify_one()
  */
-int pgp_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile)
+int pgp_class_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile)
 {
   char sigfile[PATH_MAX], pgperrfile[PATH_MAX];
   FILE *pgpout = NULL, *pgperr = NULL;
@@ -797,16 +797,16 @@ static void pgp_extract_keys_from_attachment(FILE *fp, struct Body *top)
 
   mutt_file_fclose(&tempfp);
 
-  pgp_invoke_import(tempfname);
+  pgp_class_invoke_import(tempfname);
   mutt_any_key_to_continue(NULL);
 
   mutt_file_unlink(tempfname);
 }
 
 /**
- * pgp_extract_keys_from_attachment_list - Implements CryptModuleSpecs::pgp_extract_keys_from_attachment_list()
+ * pgp_class_extract_keys_from_attachment_list - Implements CryptModuleSpecs::pgp_extract_keys_from_attachment_list()
  */
-void pgp_extract_keys_from_attachment_list(FILE *fp, int tag, struct Body *top)
+void pgp_class_extract_keys_from_attachment_list(FILE *fp, int tag, struct Body *top)
 {
   if (!fp)
   {
@@ -911,7 +911,7 @@ static struct Body *pgp_decrypt_part(struct Body *a, struct State *s,
   if (pgp_check_decryption_okay(pgperr) < 0)
   {
     mutt_error(_("Decryption failed"));
-    pgp_void_passphrase();
+    pgp_class_void_passphrase();
     mutt_file_fclose(&pgperr);
     return NULL;
   }
@@ -936,7 +936,7 @@ static struct Body *pgp_decrypt_part(struct Body *a, struct State *s,
   if (fgetc(fpout) == EOF)
   {
     mutt_error(_("Decryption failed"));
-    pgp_void_passphrase();
+    pgp_class_void_passphrase();
     return NULL;
   }
 
@@ -960,9 +960,9 @@ static struct Body *pgp_decrypt_part(struct Body *a, struct State *s,
 }
 
 /**
- * pgp_decrypt_mime - Implements CryptModuleSpecs::decrypt_mime()
+ * pgp_class_decrypt_mime - Implements CryptModuleSpecs::decrypt_mime()
  */
-int pgp_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur)
+int pgp_class_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur)
 {
   char tempfile[PATH_MAX];
   struct State s;
@@ -1043,9 +1043,9 @@ bail:
 }
 
 /**
- * pgp_encrypted_handler - Implements CryptModuleSpecs::encrypted_handler()
+ * pgp_class_encrypted_handler - Implements CryptModuleSpecs::encrypted_handler()
  */
-int pgp_encrypted_handler(struct Body *a, struct State *s)
+int pgp_class_encrypted_handler(struct Body *a, struct State *s)
 {
   char tempfile[PATH_MAX];
   FILE *fpin = NULL;
@@ -1102,7 +1102,7 @@ int pgp_encrypted_handler(struct Body *a, struct State *s)
   {
     mutt_error(_("Could not decrypt PGP message"));
     /* void the passphrase, even if it's not necessarily the problem */
-    pgp_void_passphrase();
+    pgp_class_void_passphrase();
     rc = -1;
   }
 
@@ -1117,9 +1117,9 @@ int pgp_encrypted_handler(struct Body *a, struct State *s)
  */
 
 /**
- * pgp_sign_message - Implements CryptModuleSpecs::sign_message()
+ * pgp_class_sign_message - Implements CryptModuleSpecs::sign_message()
  */
-struct Body *pgp_sign_message(struct Body *a)
+struct Body *pgp_class_sign_message(struct Body *a)
 {
   struct Body *t = NULL;
   char buffer[LONG_STRING];
@@ -1211,7 +1211,7 @@ struct Body *pgp_sign_message(struct Body *a)
   {
     unlink(sigfile);
     /* most likely error is a bad passphrase, so automatically forget it */
-    pgp_void_passphrase();
+    pgp_class_void_passphrase();
     return NULL; /* fatal error while signing */
   }
 
@@ -1244,9 +1244,9 @@ struct Body *pgp_sign_message(struct Body *a)
 }
 
 /**
- * pgp_find_keys - Implements CryptModuleSpecs::findkeys()
+ * pgp_class_find_keys - Implements CryptModuleSpecs::find_keys()
  */
-char *pgp_find_keys(struct Address *addrlist, bool oppenc_mode)
+char *pgp_class_find_keys(struct Address *addrlist, bool oppenc_mode)
 {
   struct ListHead crypt_hook_list = STAILQ_HEAD_INITIALIZER(crypt_hook_list);
   struct ListNode *crypt_hook = NULL;
@@ -1321,7 +1321,7 @@ char *pgp_find_keys(struct Address *addrlist, bool oppenc_mode)
 
       if (!k_info)
       {
-        pgp_invoke_getkeys(q);
+        pgp_class_invoke_getkeys(q);
         k_info = pgp_getkeybyaddr(q, KEYFLAG_CANENCRYPT, PGP_PUBRING, oppenc_mode);
       }
 
@@ -1363,12 +1363,12 @@ char *pgp_find_keys(struct Address *addrlist, bool oppenc_mode)
 }
 
 /**
- * pgp_encrypt_message - Implements CryptModuleSpecs::pgp_encrypt_message()
+ * pgp_class_encrypt_message - Implements CryptModuleSpecs::pgp_encrypt_message()
  *
  * @warning "a" is no longer freed in this routine, you need to free it later.
  * This is necessary for $fcc_attach.
  */
-struct Body *pgp_encrypt_message(struct Body *a, char *keylist, int sign)
+struct Body *pgp_class_encrypt_message(struct Body *a, char *keylist, int sign)
 {
   char buf[LONG_STRING];
   char tempfile[PATH_MAX], pgperrfile[PATH_MAX];
@@ -1463,7 +1463,7 @@ struct Body *pgp_encrypt_message(struct Body *a, char *keylist, int sign)
   {
     /* fatal error while trying to encrypt message */
     if (sign)
-      pgp_void_passphrase(); /* just in case */
+      pgp_class_void_passphrase(); /* just in case */
     unlink(tempfile);
     return NULL;
   }
@@ -1497,9 +1497,9 @@ struct Body *pgp_encrypt_message(struct Body *a, char *keylist, int sign)
 }
 
 /**
- * pgp_traditional_encryptsign - Implements CryptModuleSpecs::pgp_traditional_encryptsign()
+ * pgp_class_traditional_encryptsign - Implements CryptModuleSpecs::pgp_traditional_encryptsign()
  */
-struct Body *pgp_traditional_encryptsign(struct Body *a, int flags, char *keylist)
+struct Body *pgp_class_traditional_encryptsign(struct Body *a, int flags, char *keylist)
 {
   struct Body *b = NULL;
 
@@ -1645,7 +1645,7 @@ struct Body *pgp_traditional_encryptsign(struct Body *a, int flags, char *keylis
   if (empty)
   {
     if (flags & SIGN)
-      pgp_void_passphrase(); /* just in case */
+      pgp_class_void_passphrase(); /* just in case */
     unlink(pgpoutfile);
     return NULL;
   }
@@ -1675,9 +1675,9 @@ struct Body *pgp_traditional_encryptsign(struct Body *a, int flags, char *keylis
 }
 
 /**
- * pgp_send_menu - Implements CryptModuleSpecs::send_menu()
+ * pgp_class_send_menu - Implements CryptModuleSpecs::send_menu()
  */
-int pgp_send_menu(struct Header *msg)
+int pgp_class_send_menu(struct Header *msg)
 {
   struct PgpKeyInfo *p = NULL;
   char *prompt = NULL, *letters = NULL, *choices = NULL;
index e379620eaf3c0cbed39334e880f2d2b14303f4b1..9eb244d74177a295fee1bba6a19dfb23038088f2 100644 (file)
@@ -40,7 +40,7 @@ struct State;
 
 bool pgp_use_gpg_agent(void);
 
-int pgp_check_traditional(FILE *fp, struct Body *b, int just_one);
+int pgp_class_check_traditional(FILE *fp, struct Body *b, int just_one);
 
 char *pgp_this_keyid(struct PgpKeyInfo *k);
 char *pgp_keyid(struct PgpKeyInfo *k);
@@ -48,22 +48,22 @@ char *pgp_short_keyid(struct PgpKeyInfo * k);
 char *pgp_long_keyid(struct PgpKeyInfo * k);
 char *pgp_fpr_or_lkeyid(struct PgpKeyInfo * k);
 
-int pgp_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur);
+int pgp_class_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur);
 
-char *pgp_find_keys(struct Address *addrlist, bool oppenc_mode);
+char *pgp_class_find_keys(struct Address *addrlist, bool oppenc_mode);
 
-int pgp_application_pgp_handler(struct Body *m, struct State *s);
-int pgp_encrypted_handler(struct Body *a, struct State *s);
-void pgp_extract_keys_from_attachment_list(FILE *fp, int tag, struct Body *top);
-void pgp_void_passphrase(void);
-int pgp_valid_passphrase(void);
+int pgp_class_application_handler(struct Body *m, struct State *s);
+int pgp_class_encrypted_handler(struct Body *a, struct State *s);
+void pgp_class_extract_keys_from_attachment_list(FILE *fp, int tag, struct Body *top);
+void pgp_class_void_passphrase(void);
+int pgp_class_valid_passphrase(void);
 
-int pgp_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile);
-struct Body *pgp_traditional_encryptsign(struct Body *a, int flags, char *keylist);
-struct Body *pgp_encrypt_message(struct Body *a, char *keylist, int sign);
-struct Body *pgp_sign_message(struct Body *a);
+int pgp_class_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile);
+struct Body *pgp_class_traditional_encryptsign(struct Body *a, int flags, char *keylist);
+struct Body *pgp_class_encrypt_message(struct Body *a, char *keylist, int sign);
+struct Body *pgp_class_sign_message(struct Body *a);
 
-int pgp_send_menu(struct Header *msg);
+int pgp_class_send_menu(struct Header *msg);
 
 #endif /* CRYPT_BACKEND_CLASSIC_PGP */
 
index 251ae3ed0442b31aea63ffe308901e81d7572f9a..78b4ad4ea55c205ca07014fcc464ae449738f33b 100644 (file)
@@ -246,9 +246,9 @@ pid_t pgp_invoke_traditional(FILE **pgpin, FILE **pgpout, FILE **pgperr,
 }
 
 /**
- * pgp_invoke_import - Implements CryptModuleSpecs::pgp_invoke_import()
+ * pgp_class_invoke_import - Implements CryptModuleSpecs::pgp_invoke_import()
  */
-void pgp_invoke_import(const char *fname)
+void pgp_class_invoke_import(const char *fname)
 {
   char tmp_fname[PATH_MAX + SHORT_STRING];
   char cmd[HUGE_STRING];
@@ -269,9 +269,9 @@ void pgp_invoke_import(const char *fname)
 }
 
 /**
- * pgp_invoke_getkeys - Implements CryptModuleSpecs::pgp_invoke_getkeys()
+ * pgp_class_invoke_getkeys - Implements CryptModuleSpecs::pgp_invoke_getkeys()
  */
-void pgp_invoke_getkeys(struct Address *addr)
+void pgp_class_invoke_getkeys(struct Address *addr)
 {
   char buf[PATH_MAX];
   char tmp[LONG_STRING];
index 7425bba6018f9ada7653f637bffee92016f28d2c..2341a96cd1e8d12867405b874742d546983e144c 100644 (file)
@@ -32,8 +32,8 @@ struct ListHead;
 
 /* The PGP invocation interface */
 
-void pgp_invoke_import(const char *fname);
-void pgp_invoke_getkeys(struct Address *addr);
+void pgp_class_invoke_import(const char *fname);
+void pgp_class_invoke_getkeys(struct Address *addr);
 
 pid_t pgp_invoke_decode     (FILE **pgpin, FILE **pgpout, FILE **pgperr, int pgpinfd, int pgpoutfd, int pgperrfd, const char *fname, short need_passphrase);
 pid_t pgp_invoke_decrypt    (FILE **pgpin, FILE **pgpout, FILE **pgperr, int pgpinfd, int pgpoutfd, int pgperrfd, const char *fname);
index c07566de77778ea56b375e511013c266ff9b4c08..c66960ae737b6f4b6407bbfbbd8c324a35e81adf 100644 (file)
@@ -740,9 +740,9 @@ struct PgpKeyInfo *pgp_ask_for_key(char *tag, char *whatfor, short abilities, en
 }
 
 /**
- * pgp_make_key_attachment - Implements CryptModuleSpecs::pgp_make_key_attachment()
+ * pgp_class_make_key_attachment - Implements CryptModuleSpecs::pgp_make_key_attachment()
  */
-struct Body *pgp_make_key_attachment(char *tempf)
+struct Body *pgp_class_make_key_attachment(char *tempf)
 {
   struct Body *att = NULL;
   char buf[LONG_STRING];
index 852fa740dc647a0448dab0949248e466da5ddb3a..2ec2e29c7df2e87b26589f9489fadfbe3847048b 100644 (file)
@@ -36,7 +36,7 @@ enum PgpRing
   PGP_SECRING, /**< Secret keys */
 };
 
-struct Body *pgp_make_key_attachment(char *tempf);
+struct Body *pgp_class_make_key_attachment(char *tempf);
 
 struct PgpKeyInfo *pgp_ask_for_key(char *tag, char *whatfor, short abilities, enum PgpRing keyring);
 struct PgpKeyInfo *pgp_getkeybyaddr(struct Address *a, short abilities, enum PgpRing keyring, bool oppenc_mode);
index 8ae31282418e83c40a74db3a278a79c69a02e942..6539557cd6794bd8ab7f46b5e217db57c64ff207 100644 (file)
@@ -123,18 +123,18 @@ static struct SmimeKey *smime_copy_key(struct SmimeKey *key)
  */
 
 /**
- * smime_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
+ * smime_class_void_passphrase - Implements CryptModuleSpecs::void_passphrase()
  */
-void smime_void_passphrase(void)
+void smime_class_void_passphrase(void)
 {
   memset(SmimePass, 0, sizeof(SmimePass));
   SmimeExptime = 0;
 }
 
 /**
- * smime_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
+ * smime_class_valid_passphrase - Implements CryptModuleSpecs::valid_passphrase()
  */
-int smime_valid_passphrase(void)
+int smime_class_valid_passphrase(void)
 {
   time_t now = time(NULL);
 
@@ -144,7 +144,7 @@ int smime_valid_passphrase(void)
     return 1;
   }
 
-  smime_void_passphrase();
+  smime_class_void_passphrase();
 
   if (mutt_get_password(_("Enter S/MIME passphrase:"), SmimePass, sizeof(SmimePass)) == 0)
   {
@@ -848,14 +848,14 @@ static void getkeys(char *mailbox)
       return;
     }
     else
-      smime_void_passphrase();
+      smime_class_void_passphrase();
 
     snprintf(SmimeKeyToUse, sizeof(SmimeKeyToUse), "%s/%s", NONULL(SmimeKeys), k);
 
     snprintf(SmimeCertToUse, sizeof(SmimeCertToUse), "%s/%s", NONULL(SmimeCertificates), k);
 
     if (mutt_str_strcasecmp(k, SmimeDefaultKey) != 0)
-      smime_void_passphrase();
+      smime_class_void_passphrase();
 
     smime_free_key(&key);
     return;
@@ -869,7 +869,7 @@ static void getkeys(char *mailbox)
       return;
     }
 
-    smime_void_passphrase();
+    smime_class_void_passphrase();
   }
 
   snprintf(SmimeKeyToUse, sizeof(SmimeKeyToUse), "%s/%s", NONULL(SmimeKeys),
@@ -880,9 +880,9 @@ static void getkeys(char *mailbox)
 }
 
 /**
- * smime_getkeys - Implements CryptModuleSpecs::smime_getkeys()
+ * smime_class_getkeys - Implements CryptModuleSpecs::smime_getkeys()
  */
-void smime_getkeys(struct Envelope *env)
+void smime_class_getkeys(struct Envelope *env)
 {
   struct Address *t = NULL;
   bool found = false;
@@ -921,9 +921,9 @@ void smime_getkeys(struct Envelope *env)
 }
 
 /**
- * smime_find_keys - Implements CryptModuleSpecs::findkeys()
+ * smime_class_find_keys - Implements CryptModuleSpecs::find_keys()
  */
-char *smime_find_keys(struct Address *addrlist, bool oppenc_mode)
+char *smime_class_find_keys(struct Address *addrlist, bool oppenc_mode)
 {
   struct SmimeKey *key = NULL;
   char *keyID = NULL, *keylist = NULL;
@@ -1224,9 +1224,9 @@ static char *smime_extract_signer_certificate(char *infile)
 }
 
 /**
- * smime_invoke_import - Implements CryptModuleSpecs::smime_invoke_import()
+ * smime_class_invoke_import - Implements CryptModuleSpecs::smime_invoke_import()
  */
-void smime_invoke_import(char *infile, char *mailbox)
+void smime_class_invoke_import(char *infile, char *mailbox)
 {
   char tmpfname[PATH_MAX], *certfile = NULL, buf[STRING];
   FILE *smimein = NULL;
@@ -1299,9 +1299,9 @@ void smime_invoke_import(char *infile, char *mailbox)
 }
 
 /**
- * smime_verify_sender - Implements CryptModuleSpecs::smime_verify_sender()
+ * smime_class_verify_sender - Implements CryptModuleSpecs::smime_verify_sender()
  */
-int smime_verify_sender(struct Header *h)
+int smime_class_verify_sender(struct Header *h)
 {
   char *mbox = NULL, *certfile = NULL, tempfname[PATH_MAX];
   int retval = 1;
@@ -1384,9 +1384,9 @@ static pid_t smime_invoke_sign(FILE **smimein, FILE **smimeout, FILE **smimeerr,
 }
 
 /**
- * smime_build_smime_entity - Implements CryptModuleSpecs::smime_build_smime_entity()
+ * smime_class_build_smime_entity - Implements CryptModuleSpecs::smime_build_smime_entity()
  */
-struct Body *smime_build_smime_entity(struct Body *a, char *certlist)
+struct Body *smime_class_build_smime_entity(struct Body *a, char *certlist)
 {
   char buf[LONG_STRING], certfile[PATH_MAX];
   char tempfile[PATH_MAX], smimeerrfile[PATH_MAX];
@@ -1537,9 +1537,9 @@ static char *openssl_md_to_smime_micalg(char *md)
 }
 
 /**
- * smime_sign_message - Implements CryptModuleSpecs::sign_message()
+ * smime_class_sign_message - Implements CryptModuleSpecs::sign_message()
  */
-struct Body *smime_sign_message(struct Body *a)
+struct Body *smime_class_sign_message(struct Body *a)
 {
   char buffer[LONG_STRING];
   char signedfile[PATH_MAX], filetosign[PATH_MAX];
@@ -1695,9 +1695,9 @@ static pid_t smime_invoke_decrypt(FILE **smimein, FILE **smimeout,
 }
 
 /**
- * smime_verify_one - Implements CryptModuleSpecs::verify_one()
+ * smime_class_verify_one - Implements CryptModuleSpecs::verify_one()
  */
-int smime_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile)
+int smime_class_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile)
 {
   char signedfile[PATH_MAX], smimeerrfile[PATH_MAX];
   FILE *smimeout = NULL;
@@ -1888,8 +1888,8 @@ static struct Body *smime_handle_entity(struct Body *m, struct State *s, FILE *o
 
   if (type & ENCRYPT)
   {
-    if (!smime_valid_passphrase())
-      smime_void_passphrase();
+    if (!smime_class_valid_passphrase())
+      smime_class_void_passphrase();
     fputs(SmimePass, smimein);
     fputc('\n', smimein);
   }
@@ -2018,9 +2018,9 @@ static struct Body *smime_handle_entity(struct Body *m, struct State *s, FILE *o
 }
 
 /**
- * smime_decrypt_mime - Implements CryptModuleSpecs::decrypt_mime()
+ * smime_class_decrypt_mime - Implements CryptModuleSpecs::decrypt_mime()
  */
-int smime_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur)
+int smime_class_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur)
 {
   char tempfile[PATH_MAX];
   struct State s;
@@ -2090,17 +2090,17 @@ bail:
 }
 
 /**
- * smime_application_smime_handler - Implements CryptModuleSpecs::application_handler()
+ * smime_class_application_handler - Implements CryptModuleSpecs::application_handler()
  */
-int smime_application_smime_handler(struct Body *m, struct State *s)
+int smime_class_application_handler(struct Body *m, struct State *s)
 {
   return smime_handle_entity(m, s, NULL) ? 0 : -1;
 }
 
 /**
- * smime_send_menu - Implements CryptModuleSpecs::send_menu()
+ * smime_class_send_menu - Implements CryptModuleSpecs::send_menu()
  */
-int smime_send_menu(struct Header *msg)
+int smime_class_send_menu(struct Header *msg)
 {
   struct SmimeKey *key = NULL;
   char *prompt = NULL, *letters = NULL, *choices = NULL;
index 3c1b7e153377dc05dc2b6d48476c9e8616794013..ac48863e80b363a41b20ee3187ee120869cb55f9 100644 (file)
@@ -48,18 +48,18 @@ struct SmimeKey
   struct SmimeKey *next;
 };
 
-int          smime_application_smime_handler(struct Body *m, struct State *s);
-struct Body *smime_build_smime_entity(struct Body *a, char *certlist);
-int          smime_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur);
-char *       smime_find_keys(struct Address *addrlist, bool oppenc_mode);
-void         smime_getkeys(struct Envelope *env);
-void         smime_invoke_import(char *infile, char *mailbox);
-int          smime_send_menu(struct Header *msg);
-struct Body *smime_sign_message(struct Body *a);
-int          smime_valid_passphrase(void);
-int          smime_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile);
-int          smime_verify_sender(struct Header *h);
-void         smime_void_passphrase(void);
+int          smime_class_application_handler(struct Body *m, struct State *s);
+struct Body *smime_class_build_smime_entity(struct Body *a, char *certlist);
+int          smime_class_decrypt_mime(FILE *fpin, FILE **fpout, struct Body *b, struct Body **cur);
+char *       smime_class_find_keys(struct Address *addrlist, bool oppenc_mode);
+void         smime_class_getkeys(struct Envelope *env);
+void         smime_class_invoke_import(char *infile, char *mailbox);
+int          smime_class_send_menu(struct Header *msg);
+struct Body *smime_class_sign_message(struct Body *a);
+int          smime_class_valid_passphrase(void);
+int          smime_class_verify_one(struct Body *sigbdy, struct State *s, const char *tempfile);
+int          smime_class_verify_sender(struct Header *h);
+void         smime_class_void_passphrase(void);
 
 #endif