[git] GCRYPT - branch, master, updated. libgcrypt-1.5.0-226-g90fdf25

by Jussi Kivilinna cvs at cvs.gnupg.org
Sat Sep 7 11:28:34 CEST 2013


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 "The GNU crypto library".

The branch, master has been updated
       via  90fdf25f0dcc5feac7195ede55bd15948a11363e (commit)
       via  38a038a135d82231eff9d84f1ae3c4a25c6a5e75 (commit)
      from  f7135e299e659d78906aac3dfdf30f380b5cf9c6 (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 90fdf25f0dcc5feac7195ede55bd15948a11363e
Author: Jussi Kivilinna <jussi.kivilinna at iki.fi>
Date:   Sat Sep 7 11:55:19 2013 +0300

    Fix static build on AMD64
    
    * cipher/rijndael-amd64.S: Correct 'RIP' macro for non-PIC build.
    --
    
    Signed-off-by: Jussi Kivilinna <jussi.kivilinna at iki.fi>

diff --git a/cipher/rijndael-amd64.S b/cipher/rijndael-amd64.S
index 2519ada..2a7dd90 100644
--- a/cipher/rijndael-amd64.S
+++ b/cipher/rijndael-amd64.S
@@ -23,7 +23,7 @@
 #if defined(HAVE_COMPATIBLE_GCC_AMD64_PLATFORM_AS) && defined(USE_AES)
 
 #ifdef __PIC__
-#  define RIP %rip
+#  define RIP (%rip)
 #else
 #  define RIP
 #endif
@@ -177,7 +177,7 @@ _gcry_aes_amd64_encrypt_block:
 	movq %rbx, (3 * 8)(%rsp);
 	movq %r12, (4 * 8)(%rsp);
 
-	leaq .LtableE0(RIP), RTAB;
+	leaq .LtableE0 RIP, RTAB;
 
 	/* read input block */
 	movl 0 * 4(%rdx), RAd;
@@ -298,7 +298,7 @@ _gcry_aes_amd64_decrypt_block:
 	movq %rbx, (3 * 8)(%rsp);
 	movq %r12, (4 * 8)(%rsp);
 
-	leaq .LtableD0(RIP), RTAB;
+	leaq .LtableD0 RIP, RTAB;
 
 	/* read input block */
 	movl 0 * 4(%rdx), RAd;

commit 38a038a135d82231eff9d84f1ae3c4a25c6a5e75
Author: Jussi Kivilinna <jussi.kivilinna at iki.fi>
Date:   Sat Sep 7 11:52:05 2013 +0300

    scrypt: fix for big-endian systems
    
    * cipher/scrypt.c (_salsa20_core): Fix endianess issues.
    --
    
    On big-endian systems 'tests/t-kdf' was failing scrypt tests. Patch fixes the
    issue.
    
    Signed-off-by: Jussi Kivilinna <jussi.kivilinna at iki.fi>

diff --git a/cipher/scrypt.c b/cipher/scrypt.c
index 06196d6..9e29288 100644
--- a/cipher/scrypt.c
+++ b/cipher/scrypt.c
@@ -107,7 +107,9 @@ _salsa20_core(u32 *dst, const u32 *src, unsigned rounds)
 
   assert ( (rounds & 1) == 0);
 
-  memcpy (x, src, sizeof(x));
+  for (i = 0; i < SALSA20_INPUT_LENGTH; i++)
+    x[i] = LE_SWAP32(src[i]);
+
   for (i = 0; i < rounds;i += 2)
     {
       QROUND(x[0], x[4], x[8], x[12]);
@@ -123,8 +125,8 @@ _salsa20_core(u32 *dst, const u32 *src, unsigned rounds)
 
   for (i = 0; i < SALSA20_INPUT_LENGTH; i++)
     {
-      u32 t = x[i] + src[i];
-      dst[i] = LE_SWAP32 (t);
+      u32 t = x[i] + LE_SWAP32(src[i]);
+      dst[i] = LE_SWAP32(t);
     }
 }
 

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

Summary of changes:
 cipher/rijndael-amd64.S |    6 +++---
 cipher/scrypt.c         |    8 +++++---
 2 files changed, 8 insertions(+), 6 deletions(-)


hooks/post-receive
-- 
The GNU crypto library
http://git.gnupg.org




More information about the Gnupg-commits mailing list