aboutsummaryrefslogtreecommitdiffstats
path: root/g10
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--g10/ChangeLog11
-rw-r--r--g10/card-util.c2
-rw-r--r--g10/cardglue.c2
-rw-r--r--g10/keygen.c16
-rw-r--r--g10/status.c3
-rw-r--r--g10/status.h2
6 files changed, 33 insertions, 3 deletions
diff --git a/g10/ChangeLog b/g10/ChangeLog
index c8fad2788..1f02e477f 100644
--- a/g10/ChangeLog
+++ b/g10/ChangeLog
@@ -1,3 +1,14 @@
+2005-03-14 Werner Koch <[email protected]>
+
+ * cardglue.c (pin_cb): Disable debug output.
+
+2005-03-11 Werner Koch <[email protected]>
+
+ * keygen.c (gen_card_key_with_backup): Write status line with the
+ backup filename.
+
+ * status.h, status.h (STATUS_BACKUP_KEY_CREATED): New.
+
2005-03-10 David Shaw <[email protected]>
* keyserver.c (parse_keyserver_options): Accept honor-http-proxy
diff --git a/g10/card-util.c b/g10/card-util.c
index 5c0f76b93..c63335b48 100644
--- a/g10/card-util.c
+++ b/g10/card-util.c
@@ -578,7 +578,7 @@ change_url (void)
}
-/* Fetch the key from the URL given on teh card or try to get it from
+/* Fetch the key from the URL given on the card or try to get it from
the default keyserver. */
static int
fetch_url(void)
diff --git a/g10/cardglue.c b/g10/cardglue.c
index a700a34d1..9e5a14f8c 100644
--- a/g10/cardglue.c
+++ b/g10/cardglue.c
@@ -659,7 +659,7 @@ pin_cb (void *opaque, const char *info, char **retstr)
const char *ends, *s;
*retstr = NULL;
- log_debug ("asking for PIN '%s'\n", info);
+ /* log_debug ("asking for PIN '%s'\n", info); */
/* We use a special prefix to check whether the Admin PIN has been
requested. */
diff --git a/g10/keygen.c b/g10/keygen.c
index be8a8e512..1f325ceb5 100644
--- a/g10/keygen.c
+++ b/g10/keygen.c
@@ -3420,9 +3420,25 @@ gen_card_key_with_backup (int algo, int keyno, int is_primary,
}
else
{
+ byte array[MAX_FINGERPRINT_LEN];
+ char *fprbuf, *p;
+
iobuf_close (fp);
iobuf_ioctl (NULL, 2, 0, (char*)fname);
log_info (_("NOTE: backup of card key saved to `%s'\n"), fname);
+
+ fingerprint_from_sk (sk, array, &n);
+ p = fprbuf = xmalloc (MAX_FINGERPRINT_LEN*2 + 1 + 1);
+ for (i=0; i < n ; i++, p += 2)
+ sprintf (p, "%02X", array[i]);
+ *p++ = ' ';
+ *p = 0;
+
+ write_status_text_and_buffer (STATUS_BACKUP_KEY_CREATED,
+ fprbuf,
+ fname, strlen (fname),
+ 0);
+ xfree (fprbuf);
}
free_packet (pkt);
m_free (pkt);
diff --git a/g10/status.c b/g10/status.c
index 342622601..a0c9511d9 100644
--- a/g10/status.c
+++ b/g10/status.c
@@ -1,6 +1,6 @@
/* status.c
* Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003,
- * 2004 Free Software Foundation, Inc.
+ * 2004, 2005 Free Software Foundation, Inc.
*
* This file is part of GnuPG.
*
@@ -162,6 +162,7 @@ get_status_string ( int no )
case STATUS_SIG_SUBPACKET : s = "SIG_SUBPACKET"; break;
case STATUS_SC_OP_SUCCESS : s = "SC_OP_SUCCESS"; break;
case STATUS_SC_OP_FAILURE : s = "SC_OP_FAILURE"; break;
+ case STATUS_BACKUP_KEY_CREATED:s="BACKUP_KEY_CREATED"; break;
default: s = "?"; break;
}
return s;
diff --git a/g10/status.h b/g10/status.h
index 629c28afb..8be77e4a8 100644
--- a/g10/status.h
+++ b/g10/status.h
@@ -113,6 +113,8 @@
#define STATUS_SC_OP_FAILURE 79
#define STATUS_SC_OP_SUCCESS 80
+#define STATUS_BACKUP_KEY_CREATED 81
+
/*-- status.c --*/
void set_status_fd ( int fd );