summaryrefslogtreecommitdiff
path: root/gcm.c
diff options
context:
space:
mode:
authorVladislav Grishenko <themiron@users.noreply.github.com>2020-05-29 18:26:22 +0500
committerVladislav Grishenko <themiron@users.noreply.github.com>2020-05-29 18:26:22 +0500
commit38a32b6ec126806c989034a4036bc8a1be83b928 (patch)
tree96fb178e1199b90fa63994379a36ee717921c518 /gcm.c
parentcaabad0d5d9ffa901675ba88a67e9c40cb5137b8 (diff)
downloaddropbear-38a32b6ec126806c989034a4036bc8a1be83b928.tar.gz
Fix ChaCha20 on 32-bit platforms (#99)
* Fix ChaCha20 on 32-bit platforms On 32-bit platforms with old compiler STORE64H() parameter is not auto-expanded to 64-bit value, causing wrong IV data. Spotted on BCM4706 MIPS32r2 with GCC 4.2.4: Exit before auth: Integrity error (bad packet size 2065808956) * Fix Chacha20-Poly1305 and AES-GCM debug messages Functions were renamed earlier and trace messages - not.
Diffstat (limited to 'gcm.c')
-rw-r--r--gcm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcm.c b/gcm.c
index 8f5f3d9..2ceced1 100644
--- a/gcm.c
+++ b/gcm.c
@@ -100,7 +100,7 @@ static int dropbear_gcm_crypt(unsigned int UNUSED(seq),
static int dropbear_gcm_getlength(unsigned int UNUSED(seq),
const unsigned char *in, unsigned int *outlen,
unsigned long len, dropbear_gcm_state* UNUSED(state)) {
- TRACE2(("enter dropbear_gcm_parse"))
+ TRACE2(("enter dropbear_gcm_getlength"))
if (len < 4) {
return CRYPT_ERROR;
@@ -108,7 +108,7 @@ static int dropbear_gcm_getlength(unsigned int UNUSED(seq),
LOAD32H(*outlen, in);
- TRACE2(("leave dropbear_gcm_parse"))
+ TRACE2(("leave dropbear_gcm_getlength"))
return CRYPT_OK;
}