gnutls-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[SCM] GNU gnutls branch, master, updated. gnutls_2_9_9-104-g8728945


From: Nikos Mavrogiannopoulos
Subject: [SCM] GNU gnutls branch, master, updated. gnutls_2_9_9-104-g8728945
Date: Fri, 05 Feb 2010 13:53:06 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU gnutls".

http://git.savannah.gnu.org/cgit/gnutls.git/commit/?id=8728945992cce0019e0d286181d81dcd9d280d0d

The branch, master has been updated
       via  8728945992cce0019e0d286181d81dcd9d280d0d (commit)
      from  da9f23ae53463a5e9c44c44942fb802a9e0b8983 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 8728945992cce0019e0d286181d81dcd9d280d0d
Author: Nikos Mavrogiannopoulos <address@hidden>
Date:   Fri Feb 5 14:52:24 2010 +0100

    Corrected calculation of session data for PSK ciphersuites. Solves issue 
#107256 reported by Wolfgang Glas.

-----------------------------------------------------------------------

Summary of changes:
 lib/gnutls_session_pack.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/lib/gnutls_session_pack.c b/lib/gnutls_session_pack.c
index 27afbc9..068f694 100644
--- a/lib/gnutls_session_pack.c
+++ b/lib/gnutls_session_pack.c
@@ -754,6 +754,7 @@ error:
 /* Format: 
  *      1 byte the credentials type
  *      4 bytes the size of the whole structure
+ *
  *      4 bytes the size of the PSK username (x)
  *      x bytes the PSK username
  *      2 bytes the size of secret key in bits
@@ -776,9 +777,10 @@ pack_psk_auth_info (gnutls_session_t session, 
gnutls_datum_t * packed_session)
     {
       username_size = strlen (info->username) + 1;     /* include the 
terminating null */
       hint_size = strlen (info->hint) + 1;     /* include the terminating null 
*/
-      pack_size = username_size + hint_size +
-       2 + 4 * 3 + info->dh.prime.size + info->dh.generator.size +
-       info->dh.public_key.size;
+
+      pack_size = 1 + 4 + 4 + username_size + 4 + hint_size +
+        + 2 + 4 + info->dh.prime.size + 4 + info->dh.generator.size +
+       4 + info->dh.public_key.size;
     }
   else
     pack_size = 0;
@@ -806,7 +808,6 @@ pack_psk_auth_info (gnutls_session_t session, 
gnutls_datum_t * packed_session)
   _gnutls_write_uint32 (pack_size, &packed_session->data[pos]);
   pos += 4;
 
-
   if (pack_size > 0)
     {
       _gnutls_write_uint32 (username_size, &packed_session->data[pos]);


hooks/post-receive
-- 
GNU gnutls




reply via email to

[Prev in Thread] Current Thread [Next in Thread]