From 15399a2969e453321eafaf88e05109e9c3693e17 Mon Sep 17 00:00:00 2001 From: njohnson Date: Wed, 10 Sep 2025 21:55:11 -0400 Subject: [PATCH] Fix: Handle endianness in SHA1 block expansion Addresses a potential endianness issue in the SHA1 block expansion logic, using `#ifdef WORDS_BIGENDIAN` to ensure correct data access regardless of platform. --- libs/encryption/sha1.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/libs/encryption/sha1.cpp b/libs/encryption/sha1.cpp index 69e1d98..1d7905c 100644 --- a/libs/encryption/sha1.cpp +++ b/libs/encryption/sha1.cpp @@ -94,7 +94,6 @@ void SHA1_Transform(uint32_t state[5], const uint8_t buffer[64]); /* blk0() and blk() perform the initial expand. */ /* I got the idea of expanding during the round function from SSLeay */ -/* FIXME: can we do this in an endian-proof way? */ #ifdef WORDS_BIGENDIAN #define blk0(i) block->l[i] #else