[svn] GnuPG - r4087 - branches/GNUPG-1-9-BRANCH/agent

svn author mo cvs at cvs.gnupg.org
Sat Apr 1 13:04:15 CEST 2006


Author: mo
Date: 2006-04-01 13:04:14 +0200 (Sat, 01 Apr 2006)
New Revision: 4087

Modified:
   branches/GNUPG-1-9-BRANCH/agent/ChangeLog
   branches/GNUPG-1-9-BRANCH/agent/command-ssh.c
Log:
2006-04-01  Moritz Schulte  <moritz at g10code.com>

	* command-ssh.c (ssh_identity_register): Make KEY_GRIP_RAW be 20
	instead of 21 bytes long; do not fill KEY_GRIP_RAW[20] with NUL
	byte - KEY_GRIP_RAW is a raw binary string anyway.


Modified: branches/GNUPG-1-9-BRANCH/agent/ChangeLog
===================================================================
--- branches/GNUPG-1-9-BRANCH/agent/ChangeLog	2006-04-01 02:47:53 UTC (rev 4086)
+++ branches/GNUPG-1-9-BRANCH/agent/ChangeLog	2006-04-01 11:04:14 UTC (rev 4087)
@@ -1,3 +1,9 @@
+2006-04-01  Moritz Schulte  <moritz at g10code.com>
+
+	* command-ssh.c (ssh_identity_register): Make KEY_GRIP_RAW be 20
+	instead of 21 bytes long; do not fill KEY_GRIP_RAW[20] with NUL
+	byte - KEY_GRIP_RAW is a raw binary string anyway.
+
 2006-02-09  Werner Koch  <wk at g10code.com>
 
 	* call-scd.c (struct scd_local_s): New field next_local.

Modified: branches/GNUPG-1-9-BRANCH/agent/command-ssh.c
===================================================================
--- branches/GNUPG-1-9-BRANCH/agent/command-ssh.c	2006-04-01 02:47:53 UTC (rev 4086)
+++ branches/GNUPG-1-9-BRANCH/agent/command-ssh.c	2006-04-01 11:04:14 UTC (rev 4087)
@@ -2321,7 +2321,7 @@
 ssh_identity_register (ctrl_t ctrl, gcry_sexp_t key, int ttl)
 {
   gpg_error_t err;
-  unsigned char key_grip_raw[21];
+  unsigned char key_grip_raw[20];
   char key_grip[41];
   unsigned char *buffer = NULL;
   unsigned int buffer_n;
@@ -2334,8 +2334,6 @@
   if (err)
     goto out;
 
-  key_grip_raw[sizeof (key_grip_raw) - 1] = 0; /* FIXME:  Why?? */
-
   /* Check whether the key is already in our key storage.  Don't do
      anything then.  */
   if ( !agent_key_available (key_grip_raw) )




More information about the Gnupg-commits mailing list