Skip to content

Commit 9063093

Browse files
committed
Disable XTS-384 as an allowed use in FIPS mode
1 parent 3557cc7 commit 9063093

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

fips-check.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,9 +240,9 @@ linuxv5|linuxv5.2.1)
240240
)
241241
;;
242242
v6.0.0)
243-
WOLF_REPO_TAG='WCv6.0.0-RC3'
243+
WOLF_REPO_TAG='WCv6.0.0-RC4'
244244
FIPS_REPO_TAG='WCv6.0.0-RC4'
245-
ASM_PICKUPS_TAG='WCv6.0.0-RC3'
245+
ASM_PICKUPS_TAG='WCv6.0.0-RC4'
246246
FIPS_OPTION='v6'
247247
FIPS_FILES=(
248248
"wolfcrypt/src/fips.c:${FIPS_REPO_TAG}"

wolfcrypt/src/aes.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12818,7 +12818,12 @@ int wc_AesXtsSetKeyNoInit(XtsAes* aes, const byte* key, word32 len, int dir)
1281812818
}
1281912819

1282012820
if ((len != (AES_128_KEY_SIZE*2)) &&
12821+
#ifndef HAVE_FIPS
12822+
/* XTS-384 not allowed by FIPS and can not be treated like
12823+
* RSA-4096 bit keys back in the day, can not vendor affirm
12824+
* the use of 2 concatenated 192-bit keys (XTS-384) */
1282112825
(len != (AES_192_KEY_SIZE*2)) &&
12826+
#endif
1282212827
(len != (AES_256_KEY_SIZE*2)))
1282312828
{
1282412829
WOLFSSL_MSG("Unsupported key size");

0 commit comments

Comments
 (0)