(gpgsm_sign): Include a short list of capabilities.
authorWerner Koch <wk@gnupg.org>
Wed, 24 Mar 2004 14:28:18 +0000 (14:28 +0000)
committerWerner Koch <wk@gnupg.org>
Wed, 24 Mar 2004 14:28:18 +0000 (14:28 +0000)
sm/ChangeLog
sm/sign.c

index 08793b8..ecf1125 100644 (file)
@@ -1,3 +1,7 @@
+2004-03-24  Werner Koch  <wk@gnupg.org>
+
+       * sign.c (gpgsm_sign): Include a short list of capabilities.
+
 2004-03-17  Werner Koch  <wk@gnupg.org>
 
        * gpgsm.c (main) <gpgconf>: Fixed default value quoting.
index 1d3b01c..3cc1444 100644 (file)
--- a/sm/sign.c
+++ b/sm/sign.c
@@ -494,6 +494,25 @@ gpgsm_sign (CTRL ctrl, CERTLIST signerlist,
         }
     }
 
+  /* We need to write at least a minimal list of our capabilities to
+     try to convince some MUAs to use 3DEs and not the crippled
+     RC2. Our list is:
+
+        aes128-CBC
+        des-EDE3-CBC
+  */
+  err = ksba_cms_add_smime_capability (cms, "2.16.840.1.101.3.4.1.2", NULL, 0);
+  if (!err)
+    err = ksba_cms_add_smime_capability (cms, "1.2.840.113549.3.7", NULL, 0);
+  if (err)
+    {
+      log_error ("ksba_cms_add_smime_capability failed: %s\n",
+                 gpg_strerror (err));
+      goto leave;
+    }
+
+
+  /* Main building loop. */
   do 
     {
       err = ksba_cms_build (cms, &stopreason);