Skip to content

Commit

Permalink
Fix for big-endian architectures
Browse files Browse the repository at this point in the history
Signed-off-by: Dave Rodgman <[email protected]>
  • Loading branch information
daverodgman committed Jun 7, 2023
1 parent 2f0f998 commit 2c91f4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/sha3.c
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ int mbedtls_sha3_update(mbedtls_sha3_context *ctx,

// process input in 8-byte chunks
while (ilen >= 8) {
ABSORB(ctx, ctx->index, mbedtls_get_unaligned_uint64(input));
ABSORB(ctx, ctx->index, MBEDTLS_GET_UINT64_LE(input, 0));
input += 8;
ilen -= 8;
if ((ctx->index = (ctx->index + 8) % ctx->max_block_size) == 0) {
Expand Down

0 comments on commit 2c91f4b

Please sign in to comment.