From: Andy Polyakov Date: Wed, 14 Sep 2011 20:48:49 +0000 (+0000) Subject: Allow for dynamic base in Win64 FIPS module. X-Git-Tag: OpenSSL-fips-2_0-rc1~145 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=03e389cf049e4bbc2f6d0028dc320fb0583aad2c;p=oweals%2Fopenssl.git Allow for dynamic base in Win64 FIPS module. --- diff --git a/crypto/aes/aes_core.c b/crypto/aes/aes_core.c index ba90952829..f333c1651a 100644 --- a/crypto/aes/aes_core.c +++ b/crypto/aes/aes_core.c @@ -54,6 +54,7 @@ Td3[x] = Si[x].[09, 0d, 0b, 0e]; Td4[x] = Si[x].[01]; */ +__fips_constseg static const u32 Te0[256] = { 0xc66363a5U, 0xf87c7c84U, 0xee777799U, 0xf67b7b8dU, 0xfff2f20dU, 0xd66b6bbdU, 0xde6f6fb1U, 0x91c5c554U, @@ -120,6 +121,7 @@ static const u32 Te0[256] = { 0x824141c3U, 0x299999b0U, 0x5a2d2d77U, 0x1e0f0f11U, 0x7bb0b0cbU, 0xa85454fcU, 0x6dbbbbd6U, 0x2c16163aU, }; +__fips_constseg static const u32 Te1[256] = { 0xa5c66363U, 0x84f87c7cU, 0x99ee7777U, 0x8df67b7bU, 0x0dfff2f2U, 0xbdd66b6bU, 0xb1de6f6fU, 0x5491c5c5U, @@ -186,6 +188,7 @@ static const u32 Te1[256] = { 0xc3824141U, 0xb0299999U, 0x775a2d2dU, 0x111e0f0fU, 0xcb7bb0b0U, 0xfca85454U, 0xd66dbbbbU, 0x3a2c1616U, }; +__fips_constseg static const u32 Te2[256] = { 0x63a5c663U, 0x7c84f87cU, 0x7799ee77U, 0x7b8df67bU, 0xf20dfff2U, 0x6bbdd66bU, 0x6fb1de6fU, 0xc55491c5U, @@ -252,6 +255,7 @@ static const u32 Te2[256] = { 0x41c38241U, 0x99b02999U, 0x2d775a2dU, 0x0f111e0fU, 0xb0cb7bb0U, 0x54fca854U, 0xbbd66dbbU, 0x163a2c16U, }; +__fips_constseg static const u32 Te3[256] = { 0x6363a5c6U, 0x7c7c84f8U, 0x777799eeU, 0x7b7b8df6U, 0xf2f20dffU, 0x6b6bbdd6U, 0x6f6fb1deU, 0xc5c55491U, @@ -319,6 +323,7 @@ static const u32 Te3[256] = { 0xb0b0cb7bU, 0x5454fca8U, 0xbbbbd66dU, 0x16163a2cU, }; +__fips_constseg static const u32 Td0[256] = { 0x51f4a750U, 0x7e416553U, 0x1a17a4c3U, 0x3a275e96U, 0x3bab6bcbU, 0x1f9d45f1U, 0xacfa58abU, 0x4be30393U, @@ -385,6 +390,7 @@ static const u32 Td0[256] = { 0x39a80171U, 0x080cb3deU, 0xd8b4e49cU, 0x6456c190U, 0x7bcb8461U, 0xd532b670U, 0x486c5c74U, 0xd0b85742U, }; +__fips_constseg static const u32 Td1[256] = { 0x5051f4a7U, 0x537e4165U, 0xc31a17a4U, 0x963a275eU, 0xcb3bab6bU, 0xf11f9d45U, 0xabacfa58U, 0x934be303U, @@ -451,6 +457,7 @@ static const u32 Td1[256] = { 0x7139a801U, 0xde080cb3U, 0x9cd8b4e4U, 0x906456c1U, 0x617bcb84U, 0x70d532b6U, 0x74486c5cU, 0x42d0b857U, }; +__fips_constseg static const u32 Td2[256] = { 0xa75051f4U, 0x65537e41U, 0xa4c31a17U, 0x5e963a27U, 0x6bcb3babU, 0x45f11f9dU, 0x58abacfaU, 0x03934be3U, @@ -517,6 +524,7 @@ static const u32 Td2[256] = { 0x017139a8U, 0xb3de080cU, 0xe49cd8b4U, 0xc1906456U, 0x84617bcbU, 0xb670d532U, 0x5c74486cU, 0x5742d0b8U, }; +__fips_constseg static const u32 Td3[256] = { 0xf4a75051U, 0x4165537eU, 0x17a4c31aU, 0x275e963aU, 0xab6bcb3bU, 0x9d45f11fU, 0xfa58abacU, 0xe303934bU, @@ -583,6 +591,7 @@ static const u32 Td3[256] = { 0xa8017139U, 0x0cb3de08U, 0xb4e49cd8U, 0x56c19064U, 0xcb84617bU, 0x32b670d5U, 0x6c5c7448U, 0xb85742d0U, }; +__fips_constseg static const u8 Td4[256] = { 0x52U, 0x09U, 0x6aU, 0xd5U, 0x30U, 0x36U, 0xa5U, 0x38U, 0xbfU, 0x40U, 0xa3U, 0x9eU, 0x81U, 0xf3U, 0xd7U, 0xfbU, @@ -617,6 +626,7 @@ static const u8 Td4[256] = { 0x17U, 0x2bU, 0x04U, 0x7eU, 0xbaU, 0x77U, 0xd6U, 0x26U, 0xe1U, 0x69U, 0x14U, 0x63U, 0x55U, 0x21U, 0x0cU, 0x7dU, }; +__fips_constseg static const u32 rcon[] = { 0x01000000, 0x02000000, 0x04000000, 0x08000000, 0x10000000, 0x20000000, 0x40000000, 0x80000000, diff --git a/crypto/bn/bn_gf2m.c b/crypto/bn/bn_gf2m.c index 7189ae5d82..70770a2536 100644 --- a/crypto/bn/bn_gf2m.c +++ b/crypto/bn/bn_gf2m.c @@ -101,6 +101,7 @@ /* Maximum number of iterations before BN_GF2m_mod_solve_quad_arr should fail. */ #define MAX_ITERATIONS 50 +__fips_constseg static const BN_ULONG SQR_tb[16] = { 0, 1, 4, 5, 16, 17, 20, 21, 64, 65, 68, 69, 80, 81, 84, 85 }; diff --git a/crypto/bn/bn_lib.c b/crypto/bn/bn_lib.c index e7dea71911..f77fdb75fd 100644 --- a/crypto/bn/bn_lib.c +++ b/crypto/bn/bn_lib.c @@ -69,6 +69,7 @@ #include "cryptlib.h" #include "bn_lcl.h" +__fips_constseg const char BN_version[]="Big Number" OPENSSL_VERSION_PTEXT; /* This stuff appears to be completely unused, so is deprecated */ @@ -143,6 +144,7 @@ const BIGNUM *BN_value_one(void) int BN_num_bits_word(BN_ULONG l) { + __fips_constseg static const unsigned char bits[256]={ 0,1,2,2,3,3,3,3,4,4,4,4,4,4,4,4, 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5, diff --git a/crypto/bn/bn_nist.c b/crypto/bn/bn_nist.c index 7cdf31c2f6..86bb0429f3 100644 --- a/crypto/bn/bn_nist.c +++ b/crypto/bn/bn_nist.c @@ -68,27 +68,32 @@ /* pre-computed tables are "carry-less" values of modulus*(i+1) */ #if BN_BITS2 == 64 +__fips_constseg static const BN_ULONG _nist_p_192[][BN_NIST_192_TOP] = { {0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFEULL,0xFFFFFFFFFFFFFFFFULL}, {0xFFFFFFFFFFFFFFFEULL,0xFFFFFFFFFFFFFFFDULL,0xFFFFFFFFFFFFFFFFULL}, {0xFFFFFFFFFFFFFFFDULL,0xFFFFFFFFFFFFFFFCULL,0xFFFFFFFFFFFFFFFFULL} }; +__fips_constseg static const BN_ULONG _nist_p_192_sqr[] = { 0x0000000000000001ULL,0x0000000000000002ULL,0x0000000000000001ULL, 0xFFFFFFFFFFFFFFFEULL,0xFFFFFFFFFFFFFFFDULL,0xFFFFFFFFFFFFFFFFULL }; +__fips_constseg static const BN_ULONG _nist_p_224[][BN_NIST_224_TOP] = { {0x0000000000000001ULL,0xFFFFFFFF00000000ULL, 0xFFFFFFFFFFFFFFFFULL,0x00000000FFFFFFFFULL}, {0x0000000000000002ULL,0xFFFFFFFE00000000ULL, 0xFFFFFFFFFFFFFFFFULL,0x00000001FFFFFFFFULL} /* this one is "carry-full" */ }; +__fips_constseg static const BN_ULONG _nist_p_224_sqr[] = { 0x0000000000000001ULL,0xFFFFFFFE00000000ULL, 0xFFFFFFFFFFFFFFFFULL,0x0000000200000000ULL, 0x0000000000000000ULL,0xFFFFFFFFFFFFFFFEULL, 0xFFFFFFFFFFFFFFFFULL }; +__fips_constseg static const BN_ULONG _nist_p_256[][BN_NIST_256_TOP] = { {0xFFFFFFFFFFFFFFFFULL,0x00000000FFFFFFFFULL, 0x0000000000000000ULL,0xFFFFFFFF00000001ULL}, @@ -101,12 +106,14 @@ static const BN_ULONG _nist_p_256[][BN_NIST_256_TOP] = { {0xFFFFFFFFFFFFFFFBULL,0x00000004FFFFFFFFULL, 0x0000000000000000ULL,0xFFFFFFFB00000005ULL}, }; +__fips_constseg static const BN_ULONG _nist_p_256_sqr[] = { 0x0000000000000001ULL,0xFFFFFFFE00000000ULL, 0xFFFFFFFFFFFFFFFFULL,0x00000001FFFFFFFEULL, 0x00000001FFFFFFFEULL,0x00000001FFFFFFFEULL, 0xFFFFFFFE00000001ULL,0xFFFFFFFE00000002ULL }; +__fips_constseg static const BN_ULONG _nist_p_384[][BN_NIST_384_TOP] = { {0x00000000FFFFFFFFULL,0xFFFFFFFF00000000ULL,0xFFFFFFFFFFFFFFFEULL, 0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL}, @@ -119,18 +126,21 @@ static const BN_ULONG _nist_p_384[][BN_NIST_384_TOP] = { {0x00000004FFFFFFFBULL,0xFFFFFFFB00000000ULL,0xFFFFFFFFFFFFFFFAULL, 0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL}, }; +__fips_constseg static const BN_ULONG _nist_p_384_sqr[] = { 0xFFFFFFFE00000001ULL,0x0000000200000000ULL,0xFFFFFFFE00000000ULL, 0x0000000200000000ULL,0x0000000000000001ULL,0x0000000000000000ULL, 0x00000001FFFFFFFEULL,0xFFFFFFFE00000000ULL,0xFFFFFFFFFFFFFFFDULL, 0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL }; +__fips_constseg static const BN_ULONG _nist_p_521[] = {0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL, 0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL, 0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL, 0xFFFFFFFFFFFFFFFFULL,0xFFFFFFFFFFFFFFFFULL, 0x00000000000001FFULL}; +__fips_constseg static const BN_ULONG _nist_p_521_sqr[] = { 0x0000000000000001ULL,0x0000000000000000ULL,0x0000000000000000ULL, 0x0000000000000000ULL,0x0000000000000000ULL,0x0000000000000000ULL, @@ -140,27 +150,32 @@ static const BN_ULONG _nist_p_521_sqr[] = { 0xFFFFFFFFFFFFFFFFULL,0x000000000003FFFFULL }; #elif BN_BITS2 == 32 +__fips_constseg static const BN_ULONG _nist_p_192[][BN_NIST_192_TOP] = { {0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFE,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF}, {0xFFFFFFFE,0xFFFFFFFF,0xFFFFFFFD,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF}, {0xFFFFFFFD,0xFFFFFFFF,0xFFFFFFFC,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF} }; +__fips_constseg static const BN_ULONG _nist_p_192_sqr[] = { 0x00000001,0x00000000,0x00000002,0x00000000,0x00000001,0x00000000, 0xFFFFFFFE,0xFFFFFFFF,0xFFFFFFFD,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF }; +__fips_constseg static const BN_ULONG _nist_p_224[][BN_NIST_224_TOP] = { {0x00000001,0x00000000,0x00000000,0xFFFFFFFF, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF}, {0x00000002,0x00000000,0x00000000,0xFFFFFFFE, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF} }; +__fips_constseg static const BN_ULONG _nist_p_224_sqr[] = { 0x00000001,0x00000000,0x00000000,0xFFFFFFFE, 0xFFFFFFFF,0xFFFFFFFF,0x00000000,0x00000002, 0x00000000,0x00000000,0xFFFFFFFE,0xFFFFFFFF, 0xFFFFFFFF,0xFFFFFFFF }; +__fips_constseg static const BN_ULONG _nist_p_256[][BN_NIST_256_TOP] = { {0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0x00000000, 0x00000000,0x00000000,0x00000001,0xFFFFFFFF}, @@ -173,12 +188,14 @@ static const BN_ULONG _nist_p_256[][BN_NIST_256_TOP] = { {0xFFFFFFFB,0xFFFFFFFF,0xFFFFFFFF,0x00000004, 0x00000000,0x00000000,0x00000005,0xFFFFFFFB}, }; +__fips_constseg static const BN_ULONG _nist_p_256_sqr[] = { 0x00000001,0x00000000,0x00000000,0xFFFFFFFE, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFE,0x00000001, 0xFFFFFFFE,0x00000001,0xFFFFFFFE,0x00000001, 0x00000001,0xFFFFFFFE,0x00000002,0xFFFFFFFE }; +__fips_constseg static const BN_ULONG _nist_p_384[][BN_NIST_384_TOP] = { {0xFFFFFFFF,0x00000000,0x00000000,0xFFFFFFFF,0xFFFFFFFE,0xFFFFFFFF, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF}, @@ -191,16 +208,19 @@ static const BN_ULONG _nist_p_384[][BN_NIST_384_TOP] = { {0xFFFFFFFB,0x00000004,0x00000000,0xFFFFFFFB,0xFFFFFFFA,0xFFFFFFFF, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF}, }; +__fips_constseg static const BN_ULONG _nist_p_384_sqr[] = { 0x00000001,0xFFFFFFFE,0x00000000,0x00000002,0x00000000,0xFFFFFFFE, 0x00000000,0x00000002,0x00000001,0x00000000,0x00000000,0x00000000, 0xFFFFFFFE,0x00000001,0x00000000,0xFFFFFFFE,0xFFFFFFFD,0xFFFFFFFF, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF }; +__fips_constseg static const BN_ULONG _nist_p_521[] = {0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF, 0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF,0xFFFFFFFF, 0xFFFFFFFF,0x000001FF}; +__fips_constseg static const BN_ULONG _nist_p_521_sqr[] = { 0x00000001,0x00000000,0x00000000,0x00000000,0x00000000,0x00000000, 0x00000000,0x00000000,0x00000000,0x00000000,0x00000000,0x00000000, diff --git a/crypto/bn/bn_prime.h b/crypto/bn/bn_prime.h index 51d2194feb..bd04602e4f 100644 --- a/crypto/bn/bn_prime.h +++ b/crypto/bn/bn_prime.h @@ -63,6 +63,7 @@ typedef unsigned short prime_t; #define NUMPRIMES 54 typedef unsigned char prime_t; #endif +__fips_constseg static const prime_t primes[NUMPRIMES]= { 2, 3, 5, 7, 11, 13, 17, 19, diff --git a/crypto/crypto.h b/crypto/crypto.h index 34c2d75808..040a989b23 100644 --- a/crypto/crypto.h +++ b/crypto/crypto.h @@ -148,7 +148,9 @@ */ #if defined(OPENSSL_FIPSCANISTER) -#include +# include +#else +# define __fips_constseg #endif #ifdef __cplusplus diff --git a/crypto/des/fcrypt.c b/crypto/des/fcrypt.c index 04f95fa5b0..91811168c6 100644 --- a/crypto/des/fcrypt.c +++ b/crypto/des/fcrypt.c @@ -30,6 +30,7 @@ * crypt() implementations do. The patch was sent by * Bjorn Gronvall */ +__fips_constseg static unsigned const char con_salt[128]={ 0xD2,0xD3,0xD4,0xD5,0xD6,0xD7,0xD8,0xD9, 0xDA,0xDB,0xDC,0xDD,0xDE,0xDF,0xE0,0xE1, @@ -49,6 +50,7 @@ static unsigned const char con_salt[128]={ 0x3D,0x3E,0x3F,0x40,0x41,0x42,0x43,0x44, }; +__fips_constseg static unsigned const char cov_2char[64]={ 0x2E,0x2F,0x30,0x31,0x32,0x33,0x34,0x35, 0x36,0x37,0x38,0x39,0x41,0x42,0x43,0x44, diff --git a/crypto/des/set_key.c b/crypto/des/set_key.c index ce4faf2322..25e82ead2a 100644 --- a/crypto/des/set_key.c +++ b/crypto/des/set_key.c @@ -68,6 +68,7 @@ OPENSSL_IMPLEMENT_GLOBAL(int,DES_check_key,0) /* defaults to false */ +__fips_constseg static const unsigned char odd_parity[256]={ 1, 1, 2, 2, 4, 4, 7, 7, 8, 8, 11, 11, 13, 13, 14, 14, 16, 16, 19, 19, 21, 21, 22, 22, 25, 25, 26, 26, 28, 28, 31, 31, @@ -116,6 +117,7 @@ int DES_check_key_parity(const_DES_cblock *key) * (and actual cblock values). */ #define NUM_WEAK_KEY 16 +__fips_constseg static const DES_cblock weak_keys[NUM_WEAK_KEY]={ /* weak keys */ {0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01}, @@ -161,6 +163,7 @@ int DES_is_weak_key(const_DES_cblock *key) #define HPERM_OP(a,t,n,m) ((t)=((((a)<<(16-(n)))^(a))&(m)),\ (a)=(a)^(t)^(t>>(16-(n)))) +__fips_constseg static const DES_LONG des_skb[8][64]={ { /* for C bits (numbered as per FIPS 46) 1 2 3 4 5 6 */ @@ -337,6 +340,7 @@ int DES_set_key_checked(const_DES_cblock *key, DES_key_schedule *schedule) void DES_set_key_unchecked(const_DES_cblock *key, DES_key_schedule *schedule) { + __fips_constseg static const int shifts2[16]={0,0,1,1,1,1,1,1,0,1,1,1,1,1,1,0}; register DES_LONG c,d,t,s,t2; register const unsigned char *in; diff --git a/crypto/des/spr.h b/crypto/des/spr.h index b91936a5a5..9be0dce9f6 100644 --- a/crypto/des/spr.h +++ b/crypto/des/spr.h @@ -56,6 +56,7 @@ * [including the GNU Public Licence.] */ +__fips_constseg OPENSSL_GLOBAL const DES_LONG DES_SPtrans[8][64]={ { /* nibble 0 */ diff --git a/crypto/dsa/dsa_gen.c b/crypto/dsa/dsa_gen.c index e88b3fcf7c..c013a7e660 100644 --- a/crypto/dsa/dsa_gen.c +++ b/crypto/dsa/dsa_gen.c @@ -691,6 +691,7 @@ end: for (;;) { + __fips_constseg static const unsigned char ggen[4] = {0x67,0x67,0x65,0x6e}; if (idx >= 0) { diff --git a/crypto/ec/ec_curve.c b/crypto/ec/ec_curve.c index 7d56dfcf4e..a51a545500 100644 --- a/crypto/ec/ec_curve.c +++ b/crypto/ec/ec_curve.c @@ -84,6 +84,7 @@ typedef struct { } EC_CURVE_DATA; /* the nist prime curves */ +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } _EC_NIST_PRIME_192 = { { NID_X9_62_prime_field,20,24,1 }, @@ -110,6 +111,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } 0xB4,0xD2,0x28,0x31 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+28*6]; } _EC_NIST_PRIME_224 = { { NID_X9_62_prime_field,20,28,1 }, @@ -136,6 +138,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+28*6]; } 0x13,0xDD,0x29,0x45,0x5C,0x5C,0x2A,0x3D } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+48*6]; } _EC_NIST_PRIME_384 = { { NID_X9_62_prime_field,20,48,1 }, @@ -174,6 +177,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+48*6]; } 0xEC,0xEC,0x19,0x6A,0xCC,0xC5,0x29,0x73 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+66*6]; } _EC_NIST_PRIME_521 = { { NID_X9_62_prime_field,20,66,1 }, @@ -225,6 +229,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+66*6]; } }; /* the x9.62 prime curves (minus the nist prime curves) */ +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } _EC_X9_62_PRIME_192V2 = { { NID_X9_62_prime_field,20,24,1 }, @@ -251,6 +256,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } 0x48,0xD8,0xDD,0x31 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } _EC_X9_62_PRIME_192V3 = { { NID_X9_62_prime_field,20,24,1 }, @@ -277,6 +283,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } 0xF6,0x40,0xEC,0x13 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } _EC_X9_62_PRIME_239V1 = { { NID_X9_62_prime_field,20,30,1 }, @@ -308,6 +315,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } 0x90,0x71,0xFB,0xD1,0x52,0x26,0x88,0x90,0x9D,0x0B } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } _EC_X9_62_PRIME_239V2 = { { NID_X9_62_prime_field,20,30,1 }, @@ -339,6 +347,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } 0x77,0xD4,0x14,0xC0,0x38,0x21,0xBC,0x58,0x20,0x63 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } _EC_X9_62_PRIME_239V3 = { { NID_X9_62_prime_field,20,30,1 }, @@ -371,6 +380,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+32*6]; } _EC_X9_62_PRIME_256V1 = { { NID_X9_62_prime_field,20,32,1 }, @@ -404,6 +414,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+32*6]; } }; /* the secg prime curves (minus the nist and x9.62 prime curves) */ +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+14*6]; } _EC_SECG_PRIME_112R1 = { { NID_X9_62_prime_field,20,14,1 }, @@ -424,6 +435,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+14*6]; } 0xAC,0x65,0x61,0xC5 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+14*6]; } _EC_SECG_PRIME_112R2 = { { NID_X9_62_prime_field,20,14,4 }, @@ -444,6 +456,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+14*6]; } 0x05,0x20,0xD0,0x4B } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+16*6]; } _EC_SECG_PRIME_128R1 = { { NID_X9_62_prime_field,20,16,1 }, @@ -464,6 +477,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+16*6]; } 0x0D,0x1B,0x90,0x38,0xA1,0x15 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+16*6]; } _EC_SECG_PRIME_128R2 = { { NID_X9_62_prime_field,20,16,4 }, @@ -484,6 +498,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+16*6]; } 0x24,0x72,0x06,0x13,0xB5,0xA3 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } _EC_SECG_PRIME_160K1 = { { NID_X9_62_prime_field,0,21,1 }, @@ -508,6 +523,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } 0xB3 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } _EC_SECG_PRIME_160R1 = { { NID_X9_62_prime_field,20,21,1 }, @@ -534,6 +550,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } 0x57 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } _EC_SECG_PRIME_160R2 = { { NID_X9_62_prime_field,20,21,1 }, @@ -560,6 +577,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } 0x6B } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+24*6]; } _EC_SECG_PRIME_192K1 = { { NID_X9_62_prime_field,0,24,1 }, @@ -584,6 +602,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+24*6]; } 0x74,0xDE,0xFD,0x8D } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+29*6]; } _EC_SECG_PRIME_224K1 = { { NID_X9_62_prime_field,0,29,1 }, @@ -608,6 +627,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+29*6]; } 0x84,0xCA,0xF0,0xA9,0x71,0x76,0x9F,0xB1,0xF7 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+32*6]; } _EC_SECG_PRIME_256K1 = { { NID_X9_62_prime_field,0,32,1 }, @@ -639,6 +659,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+32*6]; } }; /* some wap/wtls curves */ +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+15*6]; } _EC_WTLS_8 = { { NID_X9_62_prime_field,0,15,1 }, @@ -657,6 +678,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+15*6]; } 0x55,0x1A,0xD8,0x37,0xE9 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } _EC_WTLS_9 = { { NID_X9_62_prime_field,0,21,1 }, @@ -681,6 +703,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } 0x33 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+28*6]; } _EC_WTLS_12 = { { NID_X9_62_prime_field,0,28,1 }, @@ -708,6 +731,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+28*6]; } #ifndef OPENSSL_NO_EC2M /* characteristic two curves */ +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+15*6]; } _EC_SECG_CHAR2_113R1 = { { NID_X9_62_characteristic_two_field,20,15,2 }, @@ -728,6 +752,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+15*6]; } 0xEC,0x8A,0x39,0xE5,0x6F } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+15*6]; } _EC_SECG_CHAR2_113R2 = { { NID_X9_62_characteristic_two_field,20,15,2 }, @@ -748,6 +773,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+15*6]; } 0x9B,0x24,0x96,0xAF,0x93 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+17*6]; } _EC_SECG_CHAR2_131R1 = { { NID_X9_62_characteristic_two_field,20,17,2 }, @@ -768,6 +794,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+17*6]; } 0x23,0x95,0x3A,0x94,0x64,0xB5,0x4D } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+17*6]; } _EC_SECG_CHAR2_131R2 = { { NID_X9_62_characteristic_two_field,20,17,2 }, @@ -788,6 +815,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+17*6]; } 0x54,0xA2,0x33,0x04,0x9B,0xA9,0x8F } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } _EC_NIST_CHAR2_163K = { { NID_X9_62_characteristic_two_field,0,21,2 }, @@ -812,6 +840,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } 0xEF } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } _EC_SECG_CHAR2_163R1 = { { NID_X9_62_characteristic_two_field,0,21,2 }, @@ -843,6 +872,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } 0x9B } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } _EC_NIST_CHAR2_163B = { { NID_X9_62_characteristic_two_field,0,21,2 }, @@ -873,6 +903,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+21*6]; } 0x33 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+25*6]; } _EC_SECG_CHAR2_193R1 = { { NID_X9_62_characteristic_two_field,20,25,2 }, @@ -899,6 +930,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+25*6]; } 0xCC,0x92,0x0E,0xBA,0x49 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+25*6]; } _EC_SECG_CHAR2_193R2 = { { NID_X9_62_characteristic_two_field,20,25,2 }, @@ -925,6 +957,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+25*6]; } 0xCC,0xD4,0xEE,0x99,0xD5 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+30*6]; } _EC_NIST_CHAR2_233K = { { NID_X9_62_characteristic_two_field,0,30,4 }, @@ -954,6 +987,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+30*6]; } 0xBC,0xD4,0x6E,0xFB,0x1A,0xD5,0xF1,0x73,0xAB,0xDF } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } _EC_NIST_CHAR2_233B = { { NID_X9_62_characteristic_two_field,20,30,2 }, @@ -985,6 +1019,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } 0x8A,0x69,0x22,0x03,0x1D,0x26,0x03,0xCF,0xE0,0xD7 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+30*6]; } _EC_SECG_CHAR2_239K1 = { { NID_X9_62_characteristic_two_field,0,30,4 }, @@ -1014,6 +1049,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+30*6]; } 0xB6,0xE9,0x1F,0x1C,0x1D,0xA8,0x00,0xE4,0x78,0xA5 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+36*6]; } _EC_NIST_CHAR2_283K = { { NID_X9_62_characteristic_two_field,0,36,4 }, @@ -1044,6 +1080,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+36*6]; } 0x1E,0x06,0x1E,0x16,0x3C,0x61 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+36*6]; } _EC_NIST_CHAR2_283B = { { NID_X9_62_characteristic_two_field,20,36,2 }, @@ -1076,6 +1113,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+36*6]; } 0x2A,0x7C,0xEF,0xAD,0xB3,0x07 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+52*6]; } _EC_NIST_CHAR2_409K = { { NID_X9_62_characteristic_two_field,0,52,4 }, @@ -1118,6 +1156,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+52*6]; } 0x5F,0xCF } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+52*6]; } _EC_NIST_CHAR2_409B = { { NID_X9_62_characteristic_two_field,20,52,2 }, @@ -1162,6 +1201,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+52*6]; } 0x11,0x73 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+72*6]; } _EC_NIST_CHAR2_571K = { { NID_X9_62_characteristic_two_field,0,72,4 }, @@ -1216,6 +1256,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+72*6]; } 0x10,0x01 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+72*6]; } _EC_NIST_CHAR2_571B = { { NID_X9_62_characteristic_two_field,20,72,2 }, @@ -1272,6 +1313,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+72*6]; } 0x4E,0x47 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } _EC_X9_62_CHAR2_163V1 = { { NID_X9_62_characteristic_two_field,20,21,2 }, @@ -1298,6 +1340,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } 0xC1 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } _EC_X9_62_CHAR2_163V2 = { { NID_X9_62_characteristic_two_field,20,21,2 }, @@ -1324,6 +1367,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } 0xA7 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } _EC_X9_62_CHAR2_163V3 = { { NID_X9_62_characteristic_two_field,20,21,2 }, @@ -1350,6 +1394,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+21*6]; } 0x09 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+23*6]; } _EC_X9_62_CHAR2_176V1 = { { NID_X9_62_characteristic_two_field,0,23,0xFF6E }, @@ -1374,6 +1419,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+23*6]; } 0xFE,0x26,0xAD } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } _EC_X9_62_CHAR2_191V1 = { { NID_X9_62_characteristic_two_field,20,24,2 }, @@ -1400,6 +1446,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } 0x93,0xBB,0xB9,0xA5 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } _EC_X9_62_CHAR2_191V2 = { { NID_X9_62_characteristic_two_field,20,24,4 }, @@ -1426,6 +1473,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } 0xE0,0x6B,0x81,0x73 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } _EC_X9_62_CHAR2_191V3 = { { NID_X9_62_characteristic_two_field,20,24,6 }, @@ -1452,6 +1500,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+24*6]; } 0x28,0x8A,0x3E,0xA3 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+27*6]; } _EC_X9_62_CHAR2_208W1 = { { NID_X9_62_characteristic_two_field,0,27,0xFE48 }, @@ -1476,6 +1525,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+27*6]; } 0xBD,0xD5,0x71,0x7E,0x21,0x2F,0x9D } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } _EC_X9_62_CHAR2_239V1 = { { NID_X9_62_characteristic_two_field,20,30,4 }, @@ -1507,6 +1557,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } 0x49,0x2A,0x49,0x93,0xF1,0xCA,0xD6,0x66,0xE4,0x47 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } _EC_X9_62_CHAR2_239V2 = { { NID_X9_62_characteristic_two_field,20,30,6 }, @@ -1538,6 +1589,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } 0x9C,0x31,0xE3,0xFC,0xDF,0x15,0x46,0x24,0x52,0x2D } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } _EC_X9_62_CHAR2_239V3 = { { NID_X9_62_characteristic_two_field,20,30,0xA }, @@ -1569,6 +1621,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+30*6]; } 0xDF,0x90,0x3E,0xF9,0x88,0x8B,0x8A,0x0E,0x4C,0xFF } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+35*6]; } _EC_X9_62_CHAR2_272W1 = { { NID_X9_62_characteristic_two_field,0,35,0xFF06 }, @@ -1599,6 +1652,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+35*6]; } 0x8F,0x1E,0x62,0x95,0x21 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+39*6]; } _EC_X9_62_CHAR2_304W1 = { { NID_X9_62_characteristic_two_field,0,39,0xFE2E }, @@ -1629,6 +1683,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+39*6]; } 0x61,0xDA,0x68,0x99,0x16,0x44,0x43,0x05,0x1D } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[20+45*6]; } _EC_X9_62_CHAR2_359V1 = { { NID_X9_62_characteristic_two_field,20,45,0x4C }, @@ -1667,6 +1722,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[20+45*6]; } 0xF4,0x90,0x75,0x8D,0x3B } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+47*6]; } _EC_X9_62_CHAR2_368W1 = { { NID_X9_62_characteristic_two_field,0,47,0xFF70 }, @@ -1703,6 +1759,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+47*6]; } 0x31,0xE9,0xCF,0xCE,0x5B,0xD9,0x67 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+54*6]; } _EC_X9_62_CHAR2_431R1 = { { NID_X9_62_characteristic_two_field,0,54,0x2760 }, @@ -1745,6 +1802,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+54*6]; } 0xC1,0xAD,0x4A,0x91 } }; +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+15*6]; } _EC_WTLS_1 = { { NID_X9_62_characteristic_two_field,0,15,2 }, @@ -1769,6 +1827,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+15*6]; } * As the group order is not a prime this curve is not suitable * for ECDSA. */ +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+20*6]; } _EC_IPSEC_155_ID3 = { { NID_X9_62_characteristic_two_field,0,20,3 }, @@ -1797,6 +1856,7 @@ static const struct { EC_CURVE_DATA h; unsigned char data[0+20*6]; } * As the group order is not a prime this curve is not suitable * for ECDSA. */ +__fips_constseg static const struct { EC_CURVE_DATA h; unsigned char data[0+24*6]; } _EC_IPSEC_185_ID4 = { { NID_X9_62_characteristic_two_field,0,24,2 }, diff --git a/crypto/ec/ec_lib.c b/crypto/ec/ec_lib.c index c955f6e06d..b3db866533 100644 --- a/crypto/ec/ec_lib.c +++ b/crypto/ec/ec_lib.c @@ -70,6 +70,7 @@ #include "ec_lcl.h" +__fips_constseg static const char EC_version[] = "EC" OPENSSL_VERSION_PTEXT; diff --git a/crypto/modes/gcm128.c b/crypto/modes/gcm128.c index 2e42e71804..e638e42be8 100644 --- a/crypto/modes/gcm128.c +++ b/crypto/modes/gcm128.c @@ -148,6 +148,7 @@ static void gcm_gmult_8bit(u64 Xi[2], const u128 Htable[256]) const u8 *xi = (const u8 *)Xi+15; size_t rem, n = *xi; const union { long one; char little; } is_endian = {1}; + __fips_constseg static const size_t rem_8bit[256] = { PACK(0x0000), PACK(0x01C2), PACK(0x0384), PACK(0x0246), PACK(0x0708), PACK(0x06CA), PACK(0x048C), PACK(0x054E), @@ -326,6 +327,7 @@ static void gcm_init_4bit(u128 Htable[16], u64 H[2]) } #ifndef GHASH_ASM +__fips_constseg static const size_t rem_4bit[16] = { PACK(0x0000), PACK(0x1C20), PACK(0x3840), PACK(0x2460), PACK(0x7080), PACK(0x6CA0), PACK(0x48C0), PACK(0x54E0), @@ -461,6 +463,7 @@ static void gcm_ghash_4bit(u64 Xi[2],const u128 Htable[16], */ u128 Hshr4[16]; /* Htable shifted right by 4 bits */ u8 Hshl4[16]; /* Htable shifted left by 4 bits */ + __fips_constseg static const unsigned short rem_8bit[256] = { 0x0000, 0x01C2, 0x0384, 0x0246, 0x0708, 0x06CA, 0x048C, 0x054E, 0x0E10, 0x0FD2, 0x0D94, 0x0C56, 0x0918, 0x08DA, 0x0A9C, 0x0B5E, diff --git a/crypto/rsa/rsa_pss.c b/crypto/rsa/rsa_pss.c index e90dbea983..cb540d7c82 100644 --- a/crypto/rsa/rsa_pss.c +++ b/crypto/rsa/rsa_pss.c @@ -71,6 +71,7 @@ #include #endif +__fips_constseg static const unsigned char zeroes[] = {0,0,0,0,0,0,0,0}; #if defined(_MSC_VER) && defined(_ARM_) diff --git a/crypto/sha/sha1dgst.c b/crypto/sha/sha1dgst.c index a98690225f..63c77eab7f 100644 --- a/crypto/sha/sha1dgst.c +++ b/crypto/sha/sha1dgst.c @@ -65,6 +65,7 @@ #include +__fips_constseg const char SHA1_version[]="SHA1" OPENSSL_VERSION_PTEXT; /* The implementation is in ../md32_common.h */ diff --git a/crypto/sha/sha256.c b/crypto/sha/sha256.c index 8952d87673..d43ee653a3 100644 --- a/crypto/sha/sha256.c +++ b/crypto/sha/sha256.c @@ -14,6 +14,7 @@ #include #include +__fips_constseg const char SHA256_version[]="SHA-256" OPENSSL_VERSION_PTEXT; int SHA224_Init (SHA256_CTX *c) @@ -115,6 +116,7 @@ void sha256_block_data_order (SHA256_CTX *ctx, const void *in, size_t num); #include "md32_common.h" #ifndef SHA256_ASM +__fips_constseg static const SHA_LONG K256[64] = { 0x428a2f98UL,0x71374491UL,0xb5c0fbcfUL,0xe9b5dba5UL, 0x3956c25bUL,0x59f111f1UL,0x923f82a4UL,0xab1c5ed5UL, diff --git a/crypto/sha/sha512.c b/crypto/sha/sha512.c index e95a5b30ff..aab1f1e8d4 100644 --- a/crypto/sha/sha512.c +++ b/crypto/sha/sha512.c @@ -50,6 +50,7 @@ #include "cryptlib.h" +__fips_constseg const char SHA512_version[]="SHA-512" OPENSSL_VERSION_PTEXT; #if defined(__i386) || defined(__i386__) || defined(_M_IX86) || \ @@ -261,6 +262,7 @@ unsigned char *SHA512(const unsigned char *d, size_t n, unsigned char *md) } #ifndef SHA512_ASM +__fips_constseg static const SHA_LONG64 K512[80] = { U64(0x428a2f98d728ae22),U64(0x7137449123ef65cd), U64(0xb5c0fbcfec4d3b2f),U64(0xe9b5dba58189dbbc), diff --git a/crypto/thr_id.c b/crypto/thr_id.c index 89979f8c17..71576dae29 100644 --- a/crypto/thr_id.c +++ b/crypto/thr_id.c @@ -130,6 +130,7 @@ void CRYPTO_THREADID_set_numeric(CRYPTO_THREADID *id, unsigned long val) id->val = val; } +__fips_constseg static const unsigned char hash_coeffs[] = { 3, 5, 7, 11, 13, 17, 19, 23 }; void CRYPTO_THREADID_set_pointer(CRYPTO_THREADID *id, void *ptr) { diff --git a/fips/aes/fips_aes_selftest.c b/fips/aes/fips_aes_selftest.c index 8fdda3b578..c31a266d42 100644 --- a/fips/aes/fips_aes_selftest.c +++ b/fips/aes/fips_aes_selftest.c @@ -56,7 +56,8 @@ #include "fips_locl.h" #ifdef OPENSSL_FIPS -static struct +__fips_constseg +static const struct { const unsigned char key[16]; const unsigned char plaintext[16]; @@ -99,26 +100,32 @@ int FIPS_selftest_aes() /* AES-CCM test data from NIST public test vectors */ +__fips_constseg static const unsigned char ccm_key[] = { 0xce,0xb0,0x09,0xae,0xa4,0x45,0x44,0x51,0xfe,0xad,0xf0,0xe6, 0xb3,0x6f,0x45,0x55,0x5d,0xd0,0x47,0x23,0xba,0xa4,0x48,0xe8 }; +__fips_constseg static const unsigned char ccm_nonce[] = { 0x76,0x40,0x43,0xc4,0x94,0x60,0xb7 }; +__fips_constseg static const unsigned char ccm_adata[] = { 0x6e,0x80,0xdd,0x7f,0x1b,0xad,0xf3,0xa1,0xc9,0xab,0x25,0xc7, 0x5f,0x10,0xbd,0xe7,0x8c,0x23,0xfa,0x0e,0xb8,0xf9,0xaa,0xa5, 0x3a,0xde,0xfb,0xf4,0xcb,0xf7,0x8f,0xe4 }; +__fips_constseg static const unsigned char ccm_pt[] = { 0xc8,0xd2,0x75,0xf9,0x19,0xe1,0x7d,0x7f,0xe6,0x9c,0x2a,0x1f, 0x58,0x93,0x9d,0xfe,0x4d,0x40,0x37,0x91,0xb5,0xdf,0x13,0x10 }; +__fips_constseg static const unsigned char ccm_ct[] = { 0x8a,0x0f,0x3d,0x82,0x29,0xe4,0x8e,0x74,0x87,0xfd,0x95,0xa2, 0x8a,0xd3,0x92,0xc8,0x0b,0x36,0x81,0xd4,0xfb,0xc7,0xbb,0xfd }; +__fips_constseg static const unsigned char ccm_tag[] = { 0x2d,0xd6,0xef,0x1c,0x45,0xd4,0xcc,0xb7,0x23,0xdc,0x07,0x44, 0x14,0xdb,0x50,0x6d @@ -201,26 +208,32 @@ int FIPS_selftest_aes_ccm(void) /* AES-GCM test data from NIST public test vectors */ +__fips_constseg static const unsigned char gcm_key[] = { 0xee,0xbc,0x1f,0x57,0x48,0x7f,0x51,0x92,0x1c,0x04,0x65,0x66, 0x5f,0x8a,0xe6,0xd1,0x65,0x8b,0xb2,0x6d,0xe6,0xf8,0xa0,0x69, 0xa3,0x52,0x02,0x93,0xa5,0x72,0x07,0x8f }; +__fips_constseg static const unsigned char gcm_iv[] = { 0x99,0xaa,0x3e,0x68,0xed,0x81,0x73,0xa0,0xee,0xd0,0x66,0x84 }; +__fips_constseg static const unsigned char gcm_pt[] = { 0xf5,0x6e,0x87,0x05,0x5b,0xc3,0x2d,0x0e,0xeb,0x31,0xb2,0xea, 0xcc,0x2b,0xf2,0xa5 }; +__fips_constseg static const unsigned char gcm_aad[] = { 0x4d,0x23,0xc3,0xce,0xc3,0x34,0xb4,0x9b,0xdb,0x37,0x0c,0x43, 0x7f,0xec,0x78,0xde }; +__fips_constseg static const unsigned char gcm_ct[] = { 0xf7,0x26,0x44,0x13,0xa8,0x4c,0x0e,0x7c,0xd5,0x36,0x86,0x7e, 0xb9,0xf2,0x17,0x36 }; +__fips_constseg static const unsigned char gcm_tag[] = { 0x67,0xba,0x05,0x10,0x26,0x2a,0xe4,0x87,0xd7,0x37,0xee,0x62, 0x98,0xf7,0x7e,0x0c @@ -300,24 +313,29 @@ int FIPS_selftest_aes_gcm(void) } +__fips_constseg static const unsigned char XTS_128_key[] = { 0xa1,0xb9,0x0c,0xba,0x3f,0x06,0xac,0x35,0x3b,0x2c,0x34,0x38, 0x76,0x08,0x17,0x62,0x09,0x09,0x23,0x02,0x6e,0x91,0x77,0x18, 0x15,0xf2,0x9d,0xab,0x01,0x93,0x2f,0x2f }; +__fips_constseg static const unsigned char XTS_128_i[] = { 0x4f,0xae,0xf7,0x11,0x7c,0xda,0x59,0xc6,0x6e,0x4b,0x92,0x01, 0x3e,0x76,0x8a,0xd5 }; +__fips_constseg static const unsigned char XTS_128_pt[] = { 0xeb,0xab,0xce,0x95,0xb1,0x4d,0x3c,0x8d,0x6f,0xb3,0x50,0x39, 0x07,0x90,0x31,0x1c }; +__fips_constseg static const unsigned char XTS_128_ct[] = { 0x77,0x8a,0xe8,0xb4,0x3c,0xb9,0x8d,0x5a,0x82,0x50,0x81,0xd5, 0xbe,0x47,0x1c,0x63 }; +__fips_constseg static const unsigned char XTS_256_key[] = { 0x1e,0xa6,0x61,0xc5,0x8d,0x94,0x3a,0x0e,0x48,0x01,0xe4,0x2f, 0x4b,0x09,0x47,0x14,0x9e,0x7f,0x9f,0x8e,0x3e,0x68,0xd0,0xc7, @@ -326,15 +344,18 @@ static const unsigned char XTS_256_key[] = { 0xd6,0x19,0xb7,0xe2,0xb9,0x14,0x1e,0x58,0x31,0x8e,0xea,0x39, 0x2c,0xf4,0x1b,0x08 }; +__fips_constseg static const unsigned char XTS_256_i[] = { 0xad,0xf8,0xd9,0x26,0x27,0x46,0x4a,0xd2,0xf0,0x42,0x8e,0x84, 0xa9,0xf8,0x75,0x64 }; +__fips_constseg static const unsigned char XTS_256_pt[] = { 0x2e,0xed,0xea,0x52,0xcd,0x82,0x15,0xe1,0xac,0xc6,0x47,0xe8, 0x10,0xbb,0xc3,0x64,0x2e,0x87,0x28,0x7f,0x8d,0x2e,0x57,0xe3, 0x6c,0x0a,0x24,0xfb,0xc1,0x2a,0x20,0x2e }; +__fips_constseg static const unsigned char XTS_256_ct[] = { 0xcb,0xaa,0xd0,0xe2,0xf6,0xce,0xa3,0xf5,0x0b,0x37,0xf9,0x34, 0xd4,0x6a,0x9b,0x13,0x0b,0x9d,0x54,0xf0,0x7e,0x34,0xf3,0x6a, diff --git a/fips/cmac/fips_cmac_selftest.c b/fips/cmac/fips_cmac_selftest.c index 89a491d78f..8833d97227 100644 --- a/fips/cmac/fips_cmac_selftest.c +++ b/fips/cmac/fips_cmac_selftest.c @@ -64,6 +64,7 @@ typedef struct { } CMAC_KAT; /* from http://csrc.nist.gov/publications/nistpubs/800-38B/SP_800-38B.pdf */ +__fips_constseg static const CMAC_KAT vector[] = { { NID_aes_128_cbc, /* Count = 32 from CMACGenAES128.txt */ { 0x77,0xa7,0x7f,0xaf, 0x29,0x0c,0x1f,0xa3, diff --git a/fips/des/fips_des_selftest.c b/fips/des/fips_des_selftest.c index 9d027c9195..a014f6f33f 100644 --- a/fips/des/fips_des_selftest.c +++ b/fips/des/fips_des_selftest.c @@ -57,7 +57,8 @@ #ifdef OPENSSL_FIPS -static struct +__fips_constseg +static const struct { const unsigned char key[24]; const unsigned char plaintext[8]; diff --git a/fips/dsa/fips_dsa_selftest.c b/fips/dsa/fips_dsa_selftest.c index 9617ab14bc..131f304025 100644 --- a/fips/dsa/fips_dsa_selftest.c +++ b/fips/dsa/fips_dsa_selftest.c @@ -60,6 +60,7 @@ #ifdef OPENSSL_FIPS +__fips_constseg static const unsigned char dsa_test_2048_p[] = { 0xa8,0x53,0x78,0xd8,0xfd,0x3f,0x8d,0x72,0xec,0x74,0x18,0x08, 0x0d,0xa2,0x13,0x17,0xe4,0x3e,0xc4,0xb6,0x2b,0xa8,0xc8,0x62, @@ -84,11 +85,13 @@ static const unsigned char dsa_test_2048_p[] = { 0x2c,0x8d,0x74,0x69,0xdb,0x02,0xe2,0x4d,0x59,0x23,0x94,0xa7, 0xdb,0xa0,0x69,0xe9 }; +__fips_constseg static const unsigned char dsa_test_2048_q[] = { 0xd2,0x77,0x04,0x4e,0x50,0xf5,0xa4,0xe3,0xf5,0x10,0xa5,0x0a, 0x0b,0x84,0xfd,0xff,0xbc,0xa0,0x47,0xed,0x27,0x60,0x20,0x56, 0x74,0x41,0xa0,0xa5 }; +__fips_constseg static const unsigned char dsa_test_2048_g[] = { 0x13,0xd7,0x54,0xe2,0x1f,0xd2,0x41,0x65,0x5d,0xa8,0x91,0xc5, 0x22,0xa6,0x5a,0x72,0xa8,0x9b,0xdc,0x64,0xec,0x9b,0x54,0xa8, @@ -114,6 +117,7 @@ static const unsigned char dsa_test_2048_g[] = { 0xb3,0xc2,0xa9,0x66 }; +__fips_constseg static const unsigned char dsa_test_2048_pub_key[] = { 0x24,0x52,0xf3,0xcc,0xbe,0x9e,0xd5,0xca,0x7d,0xc7,0x4c,0x60, 0x2b,0x99,0x22,0x6e,0x8f,0x2f,0xab,0x38,0xe7,0xd7,0xdd,0xfb, @@ -138,6 +142,7 @@ static const unsigned char dsa_test_2048_pub_key[] = { 0x0a,0xcb,0x67,0x37,0x17,0xa0,0xd2,0xfb,0x3b,0x50,0xc8,0x93, 0xf7,0xda,0xb1,0x4f }; +__fips_constseg static const unsigned char dsa_test_2048_priv_key[] = { 0x0c,0x4b,0x30,0x89,0xd1,0xb8,0x62,0xcb,0x3c,0x43,0x64,0x91, 0xf0,0x91,0x54,0x70,0xc5,0x27,0x96,0xe3,0xac,0xbe,0xe8,0x00, diff --git a/fips/dsa/fips_dsatest.c b/fips/dsa/fips_dsatest.c index c5dd088fe5..64d52258eb 100644 --- a/fips/dsa/fips_dsatest.c +++ b/fips/dsa/fips_dsatest.c @@ -140,8 +140,10 @@ static unsigned char out_g[] = { }; +__fips_constseg static const unsigned char str1[]="12345678901234567890"; +__fips_constseg static const char rnd_seed[] = "string to make the random number generator think it has entropy"; int main(int argc, char **argv) diff --git a/fips/ecdsa/fips_ecdsa_selftest.c b/fips/ecdsa/fips_ecdsa_selftest.c index 03eadda3d7..7d1007e19d 100644 --- a/fips/ecdsa/fips_ecdsa_selftest.c +++ b/fips/ecdsa/fips_ecdsa_selftest.c @@ -65,18 +65,22 @@ #ifdef OPENSSL_FIPS +__fips_constseg static const char P_224_name[] = "ECDSA P-224"; +__fips_constseg static const unsigned char P_224_d[] = { 0x98,0x1f,0xb5,0xf1,0xfc,0x87,0x1d,0x7d,0xde,0x1e,0x01,0x64, 0x09,0x9b,0xe7,0x1b,0x9f,0xad,0x63,0xdd,0x33,0x01,0xd1,0x50, 0x80,0x93,0x50,0x30 }; +__fips_constseg static const unsigned char P_224_qx[] = { 0x95,0x47,0x99,0x44,0x29,0x8f,0x51,0x39,0xe2,0x53,0xec,0x79, 0xb0,0x4d,0xde,0x87,0x1a,0x76,0x54,0xd5,0x96,0xb8,0x7a,0x6d, 0xf4,0x1c,0x2c,0x87 }; +__fips_constseg static const unsigned char P_224_qy[] = { 0x91,0x5f,0xd5,0x31,0xdd,0x24,0xe5,0x78,0xd9,0x08,0x24,0x8a, 0x49,0x99,0xec,0x55,0xf2,0x82,0xb3,0xc4,0xb7,0x33,0x68,0xe4, @@ -85,18 +89,22 @@ static const unsigned char P_224_qy[] = { #ifndef OPENSSL_NO_EC2M +__fips_constseg static const char K_233_name[] = "ECDSA K-233"; +__fips_constseg static const unsigned char K_233_d[] = { 0x10,0x0a,0xe0,0xae,0xcf,0x1b,0xa4,0x55,0x1a,0xd4,0xc8,0x3f, 0xc3,0x7e,0xdc,0x97,0x40,0x2c,0x6a,0xc8,0xe2,0x50,0x09,0xf8, 0x1c,0x70,0x23,0xcb,0xde }; +__fips_constseg static const unsigned char K_233_qx[] = { 0x01,0xa6,0xbf,0x38,0x32,0xe2,0xd7,0x15,0x4a,0xc8,0xaa,0x1f, 0x9d,0xdb,0xb8,0x8f,0x9a,0x9b,0xc0,0xb4,0xc1,0xb6,0xa5,0x5c, 0x93,0xb9,0x8a,0x83,0x65,0xe9 }; +__fips_constseg static const unsigned char K_233_qy[] = { 0x01,0x81,0x3d,0xfe,0x38,0x56,0x8f,0x3c,0x23,0x29,0xc6,0x59, 0xcb,0xa5,0x90,0x86,0xd1,0x8c,0xd8,0xb0,0xf2,0xd4,0x35,0x2b, diff --git a/fips/fips.c b/fips/fips.c index 823a042f50..a8f0f0374d 100644 --- a/fips/fips.c +++ b/fips/fips.c @@ -145,6 +145,7 @@ void fips_set_selftest_fail(void) extern const void *FIPS_text_start(), *FIPS_text_end(); extern const unsigned char FIPS_rodata_start[], FIPS_rodata_end[]; unsigned char FIPS_signature [20] = { 0 }; +__fips_constseg static const char FIPS_hmac_key[]="etaonrishdlcupfm"; unsigned int FIPS_incore_fingerprint(unsigned char *sig,unsigned int len) diff --git a/fips/fips_canister.c b/fips/fips_canister.c index a1f8400479..a209172f43 100644 --- a/fips/fips_canister.c +++ b/fips/fips_canister.c @@ -56,6 +56,10 @@ static void *instruction_pointer_xlc(void); * reference points accordingly. In case you wonder, the values are * big-endian encoded variable names, just to prevent these arrays * from being merged by linker. */ +# if defined(_MSC_VER) && defined(_WIN64) +# pragma section("fipsro$a",read) + __declspec(allocate("fipsro$a")) +# endif const unsigned int FIPS_rodata_start[]= { 0x46495053, 0x5f726f64, 0x6174615f, 0x73746172 }; #else @@ -63,6 +67,10 @@ const unsigned int FIPS_rodata_start[]= # ifdef FIPS_REF_POINT_IS_CROSS_COMPILER_AWARE # define instruction_pointer FIPS_text_endX # endif +# if defined(_MSC_VER) && defined(_WIN64) +# pragma section("fipsro$c",read) + __declspec(allocate("fipsro$c")) +# endif const unsigned int FIPS_rodata_end[]= { 0x46495053, 0x5f726f64, 0x6174615f, 0x656e645b }; #endif diff --git a/fips/fips_post.c b/fips/fips_post.c index 286edfe64f..392bd5543b 100644 --- a/fips/fips_post.c +++ b/fips/fips_post.c @@ -209,6 +209,7 @@ int fips_pkey_signature_test(int id, EVP_PKEY *pkey, int ret = 0; unsigned char *sig = NULL; unsigned int siglen; + __fips_constseg static const unsigned char str1[]="12345678901234567890"; DSA_SIG *dsig = NULL; ECDSA_SIG *esig = NULL; diff --git a/fips/fipssyms.h b/fips/fipssyms.h index 09bda6b4ed..67753d8033 100644 --- a/fips/fipssyms.h +++ b/fips/fipssyms.h @@ -666,3 +666,10 @@ #define _sparcv9_vis1_instrument _fips_sparcv9_vis1_instrument #define bn_mul_mont_gather5 fips_bn_mul_mont_gather5 #define bn_scatter5 fips_bn_scatter5 + +#if defined(_MSC_VER) && defined(_WIN64) +# pragma section("fipsro$b",read) +# define __fips_constseg __declspec(allocate("fipsro$b")) +#else +# define __fips_constseg +#endif diff --git a/fips/hmac/fips_hmac_selftest.c b/fips/hmac/fips_hmac_selftest.c index bdccf96f94..e82bacf20f 100644 --- a/fips/hmac/fips_hmac_selftest.c +++ b/fips/hmac/fips_hmac_selftest.c @@ -63,15 +63,18 @@ typedef struct { /* from http://csrc.nist.gov/publications/fips/fips198/fips-198a.pdf */ /* "0123456789:;<=>?@ABC" */ +__fips_constseg const unsigned char hmac_kat_key[] = { 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, 0x40, 0x41, 0x42, 0x43 }; /* "Sample #2" */ +__fips_constseg const unsigned char hmac_kat_data[] = { 0x53, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x20, 0x23, 0x32 }; +__fips_constseg static const HMAC_KAT vector[] = { { NID_sha1, { 0x09,0x22,0xd3,0x40,0x5f,0xaa,0x3d,0x19, diff --git a/fips/rand/fips_drbg_ec.c b/fips/rand/fips_drbg_ec.c index ee6fe074ec..0b674199bb 100644 --- a/fips/rand/fips_drbg_ec.c +++ b/fips/rand/fips_drbg_ec.c @@ -392,23 +392,27 @@ static int drbg_ec_uninstantiate(DRBG_CTX *dctx) /* Q points from SP 800-90 A.1, P is generator */ +__fips_constseg static const unsigned char p_256_qx[] = { 0xc9,0x74,0x45,0xf4,0x5c,0xde,0xf9,0xf0,0xd3,0xe0,0x5e,0x1e, 0x58,0x5f,0xc2,0x97,0x23,0x5b,0x82,0xb5,0xbe,0x8f,0xf3,0xef, 0xca,0x67,0xc5,0x98,0x52,0x01,0x81,0x92 }; +__fips_constseg static const unsigned char p_256_qy[] = { 0xb2,0x8e,0xf5,0x57,0xba,0x31,0xdf,0xcb,0xdd,0x21,0xac,0x46, 0xe2,0xa9,0x1e,0x3c,0x30,0x4f,0x44,0xcb,0x87,0x05,0x8a,0xda, 0x2c,0xb8,0x15,0x15,0x1e,0x61,0x00,0x46 }; +__fips_constseg static const unsigned char p_384_qx[] = { 0x8e,0x72,0x2d,0xe3,0x12,0x5b,0xdd,0xb0,0x55,0x80,0x16,0x4b, 0xfe,0x20,0xb8,0xb4,0x32,0x21,0x6a,0x62,0x92,0x6c,0x57,0x50, 0x2c,0xee,0xde,0x31,0xc4,0x78,0x16,0xed,0xd1,0xe8,0x97,0x69, 0x12,0x41,0x79,0xd0,0xb6,0x95,0x10,0x64,0x28,0x81,0x50,0x65 }; +__fips_constseg static const unsigned char p_384_qy[] = { 0x02,0x3b,0x16,0x60,0xdd,0x70,0x1d,0x08,0x39,0xfd,0x45,0xee, 0xc3,0x6f,0x9e,0xe7,0xb3,0x2e,0x13,0xb3,0x15,0xdc,0x02,0x61, @@ -416,6 +420,7 @@ static const unsigned char p_384_qy[] = { 0xc5,0xe0,0x9b,0x05,0x67,0x4d,0xbb,0x7e,0x45,0xc8,0x03,0xdd }; +__fips_constseg static const unsigned char p_521_qx[] = { 0x01,0xb9,0xfa,0x3e,0x51,0x8d,0x68,0x3c,0x6b,0x65,0x76,0x36, 0x94,0xac,0x8e,0xfb,0xae,0xc6,0xfa,0xb4,0x4f,0x22,0x76,0x17, @@ -424,6 +429,7 @@ static const unsigned char p_521_qx[] = { 0x3b,0x24,0xc3,0xed,0xfa,0x0f,0x85,0xfe,0x24,0xd0,0xc8,0xc0, 0x15,0x91,0xf0,0xbe,0x6f,0x63 }; +__fips_constseg static const unsigned char p_521_qy[] = { 0x01,0xf3,0xbd,0xba,0x58,0x52,0x95,0xd9,0xa1,0x11,0x0d,0x1d, 0xf1,0xf9,0x43,0x0e,0xf8,0x44,0x2c,0x50,0x18,0x97,0x6f,0xf3, diff --git a/fips/rand/fips_drbg_selftest.h b/fips/rand/fips_drbg_selftest.h index 572f047ece..31e1961553 100644 --- a/fips/rand/fips_drbg_selftest.h +++ b/fips/rand/fips_drbg_selftest.h @@ -51,53 +51,62 @@ /* AES-128 use df PR */ +__fips_constseg static const unsigned char aes_128_use_df_pr_entropyinput[] = { 0x61,0x52,0x7c,0xe3,0x23,0x7d,0x0a,0x07,0x10,0x0c,0x50,0x33, 0xc8,0xdb,0xff,0x12 }; +__fips_constseg static const unsigned char aes_128_use_df_pr_nonce[] = { 0x51,0x0d,0x85,0x77,0xed,0x22,0x97,0x28 }; +__fips_constseg static const unsigned char aes_128_use_df_pr_personalizationstring[] = { 0x59,0x9f,0xbb,0xcd,0xd5,0x25,0x69,0xb5,0xcb,0xb5,0x03,0xfe, 0xd7,0xd7,0x01,0x67 }; +__fips_constseg static const unsigned char aes_128_use_df_pr_additionalinput[] = { 0xef,0x88,0x76,0x01,0xaf,0x3c,0xfe,0x8b,0xaf,0x26,0x06,0x9e, 0x9a,0x47,0x08,0x76 }; +__fips_constseg static const unsigned char aes_128_use_df_pr_entropyinputpr[] = { 0xe2,0x76,0xf9,0xf6,0x3a,0xba,0x10,0x9f,0xbf,0x47,0x0e,0x51, 0x09,0xfb,0xa3,0xb6 }; +__fips_constseg static const unsigned char aes_128_use_df_pr_int_returnedbits[] = { 0xd4,0x98,0x8a,0x46,0x80,0x4c,0xdb,0xa3,0x59,0x02,0x57,0x52, 0x66,0x1c,0xea,0x5b }; +__fips_constseg static const unsigned char aes_128_use_df_pr_additionalinput2[] = { 0x88,0x8c,0x91,0xd6,0xbe,0x56,0x6e,0x08,0x9a,0x62,0x2b,0x11, 0x3f,0x5e,0x31,0x06 }; +__fips_constseg static const unsigned char aes_128_use_df_pr_entropyinputpr2[] = { 0xc0,0x5c,0x6b,0x98,0x01,0x0d,0x58,0x18,0x51,0x18,0x96,0xae, 0xa7,0xe3,0xa8,0x67 }; +__fips_constseg static const unsigned char aes_128_use_df_pr_returnedbits[] = { 0xcf,0x01,0xac,0x22,0x31,0x06,0x8e,0xfc,0xce,0x56,0xea,0x24, @@ -106,53 +115,62 @@ static const unsigned char aes_128_use_df_pr_returnedbits[] = /* AES-128 use df No PR */ +__fips_constseg static const unsigned char aes_128_use_df_entropyinput[] = { 0x1f,0x8e,0x34,0x82,0x0c,0xb7,0xbe,0xc5,0x01,0x3e,0xd0,0xa3, 0x9d,0x7d,0x1c,0x9b }; +__fips_constseg static const unsigned char aes_128_use_df_nonce[] = { 0xd5,0x4d,0xbd,0x4a,0x93,0x7f,0xb8,0x96 }; +__fips_constseg static const unsigned char aes_128_use_df_personalizationstring[] = { 0xab,0xd6,0x3f,0x04,0xfe,0x27,0x6b,0x2d,0xd7,0xc3,0x1c,0xf3, 0x38,0x66,0xba,0x1b }; +__fips_constseg static const unsigned char aes_128_use_df_additionalinput[] = { 0xfe,0xf4,0x09,0xa8,0xb7,0x73,0x27,0x9c,0x5f,0xa7,0xea,0x46, 0xb5,0xe2,0xb2,0x41 }; +__fips_constseg static const unsigned char aes_128_use_df_int_returnedbits[] = { 0x42,0xe4,0x4e,0x7b,0x27,0xdd,0xcb,0xbc,0x0a,0xcf,0xa6,0x67, 0xe7,0x57,0x11,0xb4 }; +__fips_constseg static const unsigned char aes_128_use_df_entropyinputreseed[] = { 0x14,0x26,0x69,0xd9,0xf3,0x65,0x03,0xd6,0x6b,0xb9,0x44,0x0b, 0xc7,0xc4,0x9e,0x39 }; +__fips_constseg static const unsigned char aes_128_use_df_additionalinputreseed[] = { 0x55,0x2e,0x60,0x9a,0x05,0x72,0x8a,0xa8,0xef,0x22,0x81,0x5a, 0xc8,0x93,0xfa,0x84 }; +__fips_constseg static const unsigned char aes_128_use_df_additionalinput2[] = { 0x3c,0x40,0xc8,0xc4,0x16,0x0c,0x21,0xa4,0x37,0x2c,0x8f,0xa5, 0x06,0x0c,0x15,0x2c }; +__fips_constseg static const unsigned char aes_128_use_df_returnedbits[] = { 0xe1,0x3e,0x99,0x98,0x86,0x67,0x0b,0x63,0x7b,0xbe,0x3f,0x88, @@ -161,18 +179,21 @@ static const unsigned char aes_128_use_df_returnedbits[] = /* AES-192 use df PR */ +__fips_constseg static const unsigned char aes_192_use_df_pr_entropyinput[] = { 0x2b,0x4e,0x8b,0xe1,0xf1,0x34,0x80,0x56,0x81,0xf9,0x74,0xec, 0x17,0x44,0x2a,0xf1,0x14,0xb0,0xbf,0x97,0x39,0xb7,0x04,0x7d }; +__fips_constseg static const unsigned char aes_192_use_df_pr_nonce[] = { 0xd6,0x9d,0xeb,0x14,0x4e,0x6c,0x30,0x1e,0x39,0x55,0x73,0xd0, 0xd1,0x80,0x78,0xfa }; +__fips_constseg static const unsigned char aes_192_use_df_pr_personalizationstring[] = { 0xfc,0x43,0x4a,0xf8,0x9a,0x55,0xb3,0x53,0x83,0xe2,0x18,0x16, @@ -180,6 +201,7 @@ static const unsigned char aes_192_use_df_pr_personalizationstring[] = 0x7d,0x49,0xf0,0x41,0x9e,0x3d,0x99,0x04 }; +__fips_constseg static const unsigned char aes_192_use_df_pr_additionalinput[] = { 0x5e,0x9f,0x49,0x6f,0x21,0x8b,0x1d,0x32,0xd5,0x84,0x5c,0xac, @@ -187,18 +209,21 @@ static const unsigned char aes_192_use_df_pr_additionalinput[] = 0x69,0x10,0x0a,0x7e,0x81,0x57,0xb5,0x36 }; +__fips_constseg static const unsigned char aes_192_use_df_pr_entropyinputpr[] = { 0xd4,0x81,0x0c,0xd7,0x66,0x39,0xec,0x42,0x53,0x87,0x41,0xa5, 0x1e,0x7d,0x80,0x91,0x8e,0xbb,0xed,0xac,0x14,0x02,0x1a,0xd5 }; +__fips_constseg static const unsigned char aes_192_use_df_pr_int_returnedbits[] = { 0xdf,0x1d,0x39,0x45,0x7c,0x9b,0xc6,0x2b,0x7d,0x8c,0x93,0xe9, 0x19,0x30,0x6b,0x67 }; +__fips_constseg static const unsigned char aes_192_use_df_pr_additionalinput2[] = { 0x00,0x71,0x27,0x4e,0xd3,0x14,0xf1,0x20,0x7f,0x4a,0x41,0x32, @@ -206,12 +231,14 @@ static const unsigned char aes_192_use_df_pr_additionalinput2[] = 0x49,0x3d,0xde,0xe8,0xbc,0x93,0x91,0x99 }; +__fips_constseg static const unsigned char aes_192_use_df_pr_entropyinputpr2[] = { 0x90,0xee,0x76,0xa1,0x45,0x8d,0xb7,0x40,0xb0,0x11,0xbf,0xd0, 0x65,0xd7,0x3c,0x7c,0x4f,0x20,0x3f,0x4e,0x11,0x9d,0xb3,0x5e }; +__fips_constseg static const unsigned char aes_192_use_df_pr_returnedbits[] = { 0x24,0x3b,0x20,0xa4,0x37,0x66,0xba,0x72,0x39,0x3f,0xcf,0x3c, @@ -220,18 +247,21 @@ static const unsigned char aes_192_use_df_pr_returnedbits[] = /* AES-192 use df No PR */ +__fips_constseg static const unsigned char aes_192_use_df_entropyinput[] = { 0x8d,0x74,0xa4,0x50,0x1a,0x02,0x68,0x0c,0x2a,0x69,0xc4,0x82, 0x3b,0xbb,0xda,0x0e,0x7f,0x77,0xa3,0x17,0x78,0x57,0xb2,0x7b }; +__fips_constseg static const unsigned char aes_192_use_df_nonce[] = { 0x75,0xd5,0x1f,0xac,0xa4,0x8d,0x42,0x78,0xd7,0x69,0x86,0x9d, 0x77,0xd7,0x41,0x0e }; +__fips_constseg static const unsigned char aes_192_use_df_personalizationstring[] = { 0x4e,0x33,0x41,0x3c,0x9c,0xc2,0xd2,0x53,0xaf,0x90,0xea,0xcf, @@ -239,6 +269,7 @@ static const unsigned char aes_192_use_df_personalizationstring[] = 0x9c,0xd3,0xf8,0x30,0x9e,0xed,0x35,0x70 }; +__fips_constseg static const unsigned char aes_192_use_df_additionalinput[] = { 0x5d,0x8b,0x8c,0xc1,0xdf,0x0e,0x02,0x78,0xfb,0x19,0xb8,0x69, @@ -246,18 +277,21 @@ static const unsigned char aes_192_use_df_additionalinput[] = 0x28,0x3d,0x0c,0x9e,0x68,0xa8,0x45,0xd7 }; +__fips_constseg static const unsigned char aes_192_use_df_int_returnedbits[] = { 0xd5,0xe7,0x08,0xc5,0x19,0x99,0xd5,0x31,0x03,0x0a,0x74,0xb6, 0xb7,0xed,0xe9,0xea }; +__fips_constseg static const unsigned char aes_192_use_df_entropyinputreseed[] = { 0x9c,0x26,0xda,0xf1,0xac,0xd9,0x5a,0xd6,0xa8,0x65,0xf5,0x02, 0x8f,0xdc,0xa2,0x09,0x54,0xa6,0xe2,0xa4,0xde,0x32,0xe0,0x01 }; +__fips_constseg static const unsigned char aes_192_use_df_additionalinputreseed[] = { 0x9b,0x90,0xb0,0x3a,0x0e,0x3a,0x80,0x07,0x4a,0xf4,0xda,0x76, @@ -265,6 +299,7 @@ static const unsigned char aes_192_use_df_additionalinputreseed[] = 0xaf,0x88,0xdd,0x63,0x89,0x47,0x06,0x65 }; +__fips_constseg static const unsigned char aes_192_use_df_additionalinput2[] = { 0x3c,0x11,0x64,0x7a,0x96,0xf5,0xd8,0xb8,0xae,0xd6,0x70,0x4e, @@ -272,6 +307,7 @@ static const unsigned char aes_192_use_df_additionalinput2[] = 0x56,0xef,0xa3,0xf1,0x6b,0xa1,0xb1,0x77 }; +__fips_constseg static const unsigned char aes_192_use_df_returnedbits[] = { 0x0b,0xe2,0x56,0x03,0x1e,0xdb,0x2c,0x6d,0x7f,0x1b,0x15,0x58, @@ -280,6 +316,7 @@ static const unsigned char aes_192_use_df_returnedbits[] = /* AES-256 use df PR */ +__fips_constseg static const unsigned char aes_256_use_df_pr_entropyinput[] = { 0x61,0x68,0xfc,0x1a,0xf0,0xb5,0x95,0x6b,0x85,0x09,0x9b,0x74, @@ -287,12 +324,14 @@ static const unsigned char aes_256_use_df_pr_entropyinput[] = 0x96,0xab,0x2c,0xe4,0xc8,0x8f,0xdd,0x6a }; +__fips_constseg static const unsigned char aes_256_use_df_pr_nonce[] = { 0xad,0xd2,0xbb,0xba,0xb7,0x65,0x89,0xc3,0x21,0x6c,0x55,0x33, 0x2b,0x36,0xff,0xa4 }; +__fips_constseg static const unsigned char aes_256_use_df_pr_personalizationstring[] = { 0x6e,0xca,0xe7,0x20,0x72,0xd3,0x84,0x5a,0x32,0xd3,0x4b,0x24, @@ -300,6 +339,7 @@ static const unsigned char aes_256_use_df_pr_personalizationstring[] = 0x16,0x37,0x0b,0xd1,0x06,0x4f,0x68,0x6d }; +__fips_constseg static const unsigned char aes_256_use_df_pr_additionalinput[] = { 0x7e,0x08,0x4a,0xbb,0xe3,0x21,0x7c,0xc9,0x23,0xd2,0xf8,0xb0, @@ -307,6 +347,7 @@ static const unsigned char aes_256_use_df_pr_additionalinput[] = 0x7b,0xce,0x9b,0xd2,0x4a,0x76,0xb8,0xde }; +__fips_constseg static const unsigned char aes_256_use_df_pr_entropyinputpr[] = { 0x0b,0x23,0xaf,0xdf,0xf1,0x62,0xd7,0xd3,0x43,0x97,0xf8,0x77, @@ -314,12 +355,14 @@ static const unsigned char aes_256_use_df_pr_entropyinputpr[] = 0xbb,0x56,0x17,0x86,0x68,0x0e,0xba,0xa9 }; +__fips_constseg static const unsigned char aes_256_use_df_pr_int_returnedbits[] = { 0x31,0x8e,0xad,0xaf,0x40,0xeb,0x6b,0x74,0x31,0x46,0x80,0xc7, 0x17,0xab,0x3c,0x7a }; +__fips_constseg static const unsigned char aes_256_use_df_pr_additionalinput2[] = { 0x94,0x6b,0xc9,0x9f,0xab,0x8d,0xc5,0xec,0x71,0x88,0x1d,0x00, @@ -327,6 +370,7 @@ static const unsigned char aes_256_use_df_pr_additionalinput2[] = 0xc7,0x06,0x4e,0x99,0x04,0x28,0x29,0xc3 }; +__fips_constseg static const unsigned char aes_256_use_df_pr_entropyinputpr2[] = { 0xbf,0x6c,0x59,0x2a,0x0d,0x44,0x0f,0xae,0x9a,0x5e,0x03,0x73, @@ -334,6 +378,7 @@ static const unsigned char aes_256_use_df_pr_entropyinputpr2[] = 0xa4,0xdf,0x56,0xf4,0x06,0x07,0x9c,0x0f }; +__fips_constseg static const unsigned char aes_256_use_df_pr_returnedbits[] = { 0x22,0x4a,0xb4,0xb8,0xb6,0xee,0x7d,0xb1,0x9e,0xc9,0xf9,0xa0, @@ -342,6 +387,7 @@ static const unsigned char aes_256_use_df_pr_returnedbits[] = /* AES-256 use df No PR */ +__fips_constseg static const unsigned char aes_256_use_df_entropyinput[] = { 0xa5,0x3e,0x37,0x10,0x17,0x43,0x91,0x93,0x59,0x1e,0x47,0x50, @@ -349,12 +395,14 @@ static const unsigned char aes_256_use_df_entropyinput[] = 0xe0,0x02,0xd8,0x0f,0xdc,0x40,0x1a,0x47 }; +__fips_constseg static const unsigned char aes_256_use_df_nonce[] = { 0xa9,0x4d,0xa5,0x5a,0xfd,0xc5,0x0c,0xe5,0x1c,0x9a,0x3b,0x8a, 0x4c,0x44,0x84,0x40 }; +__fips_constseg static const unsigned char aes_256_use_df_personalizationstring[] = { 0x8b,0x52,0xa2,0x4a,0x93,0xc3,0x4e,0xa7,0x1e,0x1c,0xa7,0x05, @@ -362,6 +410,7 @@ static const unsigned char aes_256_use_df_personalizationstring[] = 0x37,0x84,0x5f,0xf1,0xc7,0xd5,0xf6,0xd2 }; +__fips_constseg static const unsigned char aes_256_use_df_additionalinput[] = { 0x20,0xf4,0x22,0xed,0xf8,0x5c,0xa1,0x6a,0x01,0xcf,0xbe,0x5f, @@ -369,12 +418,14 @@ static const unsigned char aes_256_use_df_additionalinput[] = 0xc7,0xb3,0x65,0x81,0x80,0x8d,0x0d,0x46 }; +__fips_constseg static const unsigned char aes_256_use_df_int_returnedbits[] = { 0x4e,0x44,0xfd,0xf3,0x9e,0x29,0xa2,0xb8,0x0f,0x5d,0x6c,0xe1, 0x28,0x0c,0x3b,0xc1 }; +__fips_constseg static const unsigned char aes_256_use_df_entropyinputreseed[] = { 0xdd,0x40,0xe5,0x98,0x7b,0x27,0x16,0x73,0x15,0x68,0xd2,0x76, @@ -382,6 +433,7 @@ static const unsigned char aes_256_use_df_entropyinputreseed[] = 0x42,0xdd,0xd4,0x67,0xc8,0x79,0xc8,0x1e }; +__fips_constseg static const unsigned char aes_256_use_df_additionalinputreseed[] = { 0x7f,0xd8,0x1f,0xbd,0x2a,0xb5,0x1c,0x11,0x5d,0x83,0x4e,0x99, @@ -389,6 +441,7 @@ static const unsigned char aes_256_use_df_additionalinputreseed[] = 0x93,0xfe,0x12,0x5e,0x5d,0x73,0xfb,0x75 }; +__fips_constseg static const unsigned char aes_256_use_df_additionalinput2[] = { 0xcd,0x2c,0xff,0x14,0x69,0x3e,0x4c,0x9e,0xfd,0xfe,0x26,0x0d, @@ -396,6 +449,7 @@ static const unsigned char aes_256_use_df_additionalinput2[] = 0x62,0x39,0x2c,0x3b,0x74,0xeb,0xc9,0x0d }; +__fips_constseg static const unsigned char aes_256_use_df_returnedbits[] = { 0x4f,0x78,0xbe,0xb9,0x4d,0x97,0x8c,0xe9,0xd0,0x97,0xfe,0xad, @@ -404,6 +458,7 @@ static const unsigned char aes_256_use_df_returnedbits[] = /* AES-128 no df PR */ +__fips_constseg static const unsigned char aes_128_no_df_pr_entropyinput[] = { 0x9a,0x25,0x65,0x10,0x67,0xd5,0xb6,0x6b,0x70,0xa1,0xb3,0xa4, @@ -411,11 +466,13 @@ static const unsigned char aes_128_no_df_pr_entropyinput[] = 0x31,0x6c,0x33,0x38,0x0b,0x00,0xb2,0x5a }; +__fips_constseg static const unsigned char aes_128_no_df_pr_nonce[] = { 0x78,0x47,0x6b,0xf7,0x90,0x8e,0x87,0xf1 }; +__fips_constseg static const unsigned char aes_128_no_df_pr_personalizationstring[] = { 0xf7,0x22,0x1d,0x3a,0xbe,0x1d,0xca,0x32,0x1b,0xbd,0x87,0x0c, @@ -423,6 +480,7 @@ static const unsigned char aes_128_no_df_pr_personalizationstring[] = 0x1c,0xfa,0x42,0x89,0xcc,0x6f,0xa0,0xa8 }; +__fips_constseg static const unsigned char aes_128_no_df_pr_additionalinput[] = { 0xc9,0xe0,0x80,0xbf,0x8c,0x45,0x58,0x39,0xff,0x00,0xab,0x02, @@ -430,6 +488,7 @@ static const unsigned char aes_128_no_df_pr_additionalinput[] = 0xb1,0xd9,0xcf,0x28,0xf6,0x8f,0x9b,0x12 }; +__fips_constseg static const unsigned char aes_128_no_df_pr_entropyinputpr[] = { 0x4c,0xa8,0xc5,0xf0,0x59,0x9e,0xa6,0x8d,0x26,0x53,0xd7,0x8a, @@ -437,12 +496,14 @@ static const unsigned char aes_128_no_df_pr_entropyinputpr[] = 0xe7,0x1d,0x74,0x99,0x00,0x9d,0x31,0x3e }; +__fips_constseg static const unsigned char aes_128_no_df_pr_int_returnedbits[] = { 0xe2,0xac,0x20,0xf0,0x80,0xe7,0xbc,0x7e,0x9c,0x7b,0x65,0x71, 0xaf,0x19,0x32,0x16 }; +__fips_constseg static const unsigned char aes_128_no_df_pr_additionalinput2[] = { 0x32,0x7f,0x38,0x8b,0x73,0x0a,0x78,0x83,0xdc,0x30,0xbe,0x9f, @@ -450,6 +511,7 @@ static const unsigned char aes_128_no_df_pr_additionalinput2[] = 0x51,0x54,0x7d,0x38,0x23,0x3a,0x52,0x50 }; +__fips_constseg static const unsigned char aes_128_no_df_pr_entropyinputpr2[] = { 0x18,0x61,0x53,0x56,0xed,0xed,0xd7,0x20,0xfb,0x71,0x04,0x7a, @@ -457,6 +519,7 @@ static const unsigned char aes_128_no_df_pr_entropyinputpr2[] = 0xe9,0x46,0x95,0x02,0x48,0x01,0x78,0xf9 }; +__fips_constseg static const unsigned char aes_128_no_df_pr_returnedbits[] = { 0x29,0xc8,0x1b,0x15,0xb1,0xd1,0xc2,0xf6,0x71,0x86,0x68,0x33, @@ -465,6 +528,7 @@ static const unsigned char aes_128_no_df_pr_returnedbits[] = /* AES-128 no df No PR */ +__fips_constseg static const unsigned char aes_128_no_df_entropyinput[] = { 0xc9,0xc5,0x79,0xbc,0xe8,0xc5,0x19,0xd8,0xbc,0x66,0x73,0x67, @@ -472,11 +536,13 @@ static const unsigned char aes_128_no_df_entropyinput[] = 0xab,0xf4,0x16,0xb2,0x96,0xd2,0xb6,0x60 }; +__fips_constseg static const unsigned char aes_128_no_df_nonce[] = { 0x5f,0xbf,0x97,0x0c,0x4b,0xa4,0x87,0x13 }; +__fips_constseg static const unsigned char aes_128_no_df_personalizationstring[] = { 0xce,0xfb,0x7b,0x3f,0xd4,0x6b,0x29,0x0d,0x69,0x06,0xff,0xbb, @@ -484,6 +550,7 @@ static const unsigned char aes_128_no_df_personalizationstring[] = 0x3c,0x16,0x88,0xed,0x50,0x13,0x81,0xce }; +__fips_constseg static const unsigned char aes_128_no_df_additionalinput[] = { 0x4b,0x22,0x46,0x18,0x02,0x7b,0xd2,0x1b,0x22,0x42,0x7c,0x37, @@ -491,12 +558,14 @@ static const unsigned char aes_128_no_df_additionalinput[] = 0x4f,0x06,0x66,0xdb,0x19,0x2b,0x13,0x95 }; +__fips_constseg static const unsigned char aes_128_no_df_int_returnedbits[] = { 0x2e,0x96,0x70,0x64,0xfa,0xdf,0xdf,0x57,0xb5,0x82,0xee,0xd6, 0xed,0x3e,0x65,0xc2 }; +__fips_constseg static const unsigned char aes_128_no_df_entropyinputreseed[] = { 0x26,0xc0,0x72,0x16,0x3a,0x4b,0xb7,0x99,0xd4,0x07,0xaf,0x66, @@ -504,6 +573,7 @@ static const unsigned char aes_128_no_df_entropyinputreseed[] = 0x2f,0x3c,0x10,0xe7,0x90,0xd0,0x46,0x00 }; +__fips_constseg static const unsigned char aes_128_no_df_additionalinputreseed[] = { 0x83,0x39,0x37,0x7b,0x02,0x06,0xd2,0x12,0x13,0x8d,0x8b,0xf2, @@ -511,6 +581,7 @@ static const unsigned char aes_128_no_df_additionalinputreseed[] = 0x3b,0x77,0x5d,0x4d,0x47,0xb2,0x2d,0xb4 }; +__fips_constseg static const unsigned char aes_128_no_df_additionalinput2[] = { 0x0b,0xb9,0x67,0x37,0xdb,0x83,0xdf,0xca,0x81,0x8b,0xf9,0x3f, @@ -518,6 +589,7 @@ static const unsigned char aes_128_no_df_additionalinput2[] = 0xd3,0xe6,0x09,0xb8,0x2c,0x6a,0x67,0xd6 }; +__fips_constseg static const unsigned char aes_128_no_df_returnedbits[] = { 0x1e,0xa7,0xa4,0xe4,0xe1,0xa6,0x7c,0x69,0x9a,0x44,0x6c,0x36, @@ -526,6 +598,7 @@ static const unsigned char aes_128_no_df_returnedbits[] = /* AES-192 no df PR */ +__fips_constseg static const unsigned char aes_192_no_df_pr_entropyinput[] = { 0x9d,0x2c,0xd2,0x55,0x66,0xea,0xe0,0xbe,0x18,0xb7,0x76,0xe7, @@ -534,12 +607,14 @@ static const unsigned char aes_192_no_df_pr_entropyinput[] = 0x17,0x1f,0x8d,0x9a }; +__fips_constseg static const unsigned char aes_192_no_df_pr_nonce[] = { 0x44,0x82,0xed,0xe8,0x4c,0x28,0x5a,0x14,0xff,0x88,0x8d,0x19, 0x61,0x5c,0xee,0x0f }; +__fips_constseg static const unsigned char aes_192_no_df_pr_personalizationstring[] = { 0x47,0xd7,0x9b,0x99,0xaa,0xcb,0xe7,0xd2,0x57,0x66,0x2c,0xe1, @@ -548,6 +623,7 @@ static const unsigned char aes_192_no_df_pr_personalizationstring[] = 0x57,0x2e,0xe7,0x55 }; +__fips_constseg static const unsigned char aes_192_no_df_pr_additionalinput[] = { 0x4b,0x74,0x0b,0x40,0xce,0x6b,0xc2,0x6a,0x24,0xb4,0xf3,0xad, @@ -556,6 +632,7 @@ static const unsigned char aes_192_no_df_pr_additionalinput[] = 0xe2,0xd0,0x0c,0x2f }; +__fips_constseg static const unsigned char aes_192_no_df_pr_entropyinputpr[] = { 0x0c,0x9c,0xad,0x05,0xee,0xae,0x48,0x23,0x89,0x59,0xa1,0x94, @@ -564,12 +641,14 @@ static const unsigned char aes_192_no_df_pr_entropyinputpr[] = 0x1d,0x30,0xb3,0x78 }; +__fips_constseg static const unsigned char aes_192_no_df_pr_int_returnedbits[] = { 0xf7,0x93,0xb0,0x6d,0x77,0x83,0xd5,0x38,0x01,0xe1,0x52,0x40, 0x7e,0x3e,0x0c,0x26 }; +__fips_constseg static const unsigned char aes_192_no_df_pr_additionalinput2[] = { 0xbc,0x4b,0x37,0x44,0x1c,0xc5,0x45,0x5f,0x8f,0x51,0x62,0x8a, @@ -578,6 +657,7 @@ static const unsigned char aes_192_no_df_pr_additionalinput2[] = 0x0c,0x4b,0xee,0x6e }; +__fips_constseg static const unsigned char aes_192_no_df_pr_entropyinputpr2[] = { 0xec,0xaf,0xf6,0x4f,0xb1,0xa0,0x54,0xb5,0x5b,0xe3,0x46,0xb0, @@ -586,6 +666,7 @@ static const unsigned char aes_192_no_df_pr_entropyinputpr2[] = 0x8e,0x0a,0x83,0xdf }; +__fips_constseg static const unsigned char aes_192_no_df_pr_returnedbits[] = { 0x74,0x45,0xfb,0x53,0x84,0x96,0xbe,0xff,0x15,0xcc,0x41,0x91, @@ -594,6 +675,7 @@ static const unsigned char aes_192_no_df_pr_returnedbits[] = /* AES-192 no df No PR */ +__fips_constseg static const unsigned char aes_192_no_df_entropyinput[] = { 0x3c,0x7d,0xb5,0xe0,0x54,0xd9,0x6e,0x8c,0xa9,0x86,0xce,0x4e, @@ -602,12 +684,14 @@ static const unsigned char aes_192_no_df_entropyinput[] = 0x94,0xc3,0x59,0x63 }; +__fips_constseg static const unsigned char aes_192_no_df_nonce[] = { 0x43,0xf1,0x7d,0xb8,0xc3,0xfe,0xd0,0x23,0x6b,0xb4,0x92,0xdb, 0x29,0xfd,0x45,0x71 }; +__fips_constseg static const unsigned char aes_192_no_df_personalizationstring[] = { 0x9f,0x24,0x29,0x99,0x9e,0x01,0xab,0xe9,0x19,0xd8,0x23,0x08, @@ -616,6 +700,7 @@ static const unsigned char aes_192_no_df_personalizationstring[] = 0x3b,0x88,0xce,0x35 }; +__fips_constseg static const unsigned char aes_192_no_df_additionalinput[] = { 0x94,0xe9,0x7c,0x3d,0xa7,0xdb,0x60,0x83,0x1f,0x98,0x3f,0x0b, @@ -624,12 +709,14 @@ static const unsigned char aes_192_no_df_additionalinput[] = 0x3e,0xbe,0xd4,0x8e }; +__fips_constseg static const unsigned char aes_192_no_df_int_returnedbits[] = { 0xf9,0xd7,0xad,0x69,0xab,0x8f,0x23,0x56,0x70,0x17,0x4f,0x2a, 0x45,0xe7,0x4a,0xc5 }; +__fips_constseg static const unsigned char aes_192_no_df_entropyinputreseed[] = { 0xa6,0x71,0x6a,0x3d,0xba,0xd1,0xe8,0x66,0xa6,0xef,0xb2,0x0e, @@ -638,6 +725,7 @@ static const unsigned char aes_192_no_df_entropyinputreseed[] = 0x9b,0xcb,0x7e,0x75 }; +__fips_constseg static const unsigned char aes_192_no_df_additionalinputreseed[] = { 0x27,0x21,0xfc,0xc2,0xbd,0xf3,0x3c,0xce,0xc3,0xca,0xc1,0x01, @@ -646,6 +734,7 @@ static const unsigned char aes_192_no_df_additionalinputreseed[] = 0x5d,0x7a,0x25,0x79 }; +__fips_constseg static const unsigned char aes_192_no_df_additionalinput2[] = { 0x2d,0x8e,0x16,0x5d,0x0b,0x9f,0xeb,0xaa,0xd6,0xec,0x28,0x71, @@ -654,6 +743,7 @@ static const unsigned char aes_192_no_df_additionalinput2[] = 0x91,0x6a,0xe3,0x5f }; +__fips_constseg static const unsigned char aes_192_no_df_returnedbits[] = { 0xe5,0xda,0xb8,0xe0,0x63,0x59,0x5a,0xcc,0x3d,0xdc,0x9f,0xe8, @@ -662,6 +752,7 @@ static const unsigned char aes_192_no_df_returnedbits[] = /* AES-256 no df PR */ +__fips_constseg static const unsigned char aes_256_no_df_pr_entropyinput[] = { 0x15,0xc7,0x5d,0xcb,0x41,0x4b,0x16,0x01,0x3a,0xd1,0x44,0xe8, @@ -670,12 +761,14 @@ static const unsigned char aes_256_no_df_pr_entropyinput[] = 0x96,0x7e,0x78,0x81,0x2f,0x91,0x1b,0x44,0xb0,0x02,0xba,0x1c }; +__fips_constseg static const unsigned char aes_256_no_df_pr_nonce[] = { 0xdc,0xe4,0xd4,0x27,0x7a,0x90,0xd7,0x99,0x43,0xa1,0x3c,0x30, 0xcc,0x4b,0xee,0x2e }; +__fips_constseg static const unsigned char aes_256_no_df_pr_personalizationstring[] = { 0xe3,0xe6,0xb9,0x11,0xe4,0x7a,0xa4,0x40,0x6b,0xf8,0x73,0xf7, @@ -684,6 +777,7 @@ static const unsigned char aes_256_no_df_pr_personalizationstring[] = 0x31,0xa8,0x0b,0xf7,0xe6,0x59,0x42,0xb8,0x03,0x0c,0xf8,0x06 }; +__fips_constseg static const unsigned char aes_256_no_df_pr_additionalinput[] = { 0x6a,0x9f,0x00,0x91,0xae,0xfe,0xcf,0x84,0x99,0xce,0xb1,0x40, @@ -692,6 +786,7 @@ static const unsigned char aes_256_no_df_pr_additionalinput[] = 0x9d,0x9d,0xbc,0x7e,0x49,0xae,0xec,0x39,0x6b,0xd1,0x1f,0x7e }; +__fips_constseg static const unsigned char aes_256_no_df_pr_entropyinputpr[] = { 0xf3,0xb9,0x75,0x9c,0xbd,0x88,0xea,0xa2,0x50,0xad,0xd6,0x16, @@ -700,12 +795,14 @@ static const unsigned char aes_256_no_df_pr_entropyinputpr[] = 0x48,0x45,0x40,0xe2,0xc7,0xc9,0x9a,0x74,0xff,0x8c,0x99,0x1f }; +__fips_constseg static const unsigned char aes_256_no_df_pr_int_returnedbits[] = { 0x2e,0xf2,0x45,0x4c,0x62,0x2e,0x0a,0xb9,0x6b,0xa2,0xfd,0x56, 0x79,0x60,0x93,0xcf }; +__fips_constseg static const unsigned char aes_256_no_df_pr_additionalinput2[] = { 0xaf,0x69,0x20,0xe9,0x3b,0x37,0x9d,0x3f,0xb4,0x80,0x02,0x7a, @@ -714,6 +811,7 @@ static const unsigned char aes_256_no_df_pr_additionalinput2[] = 0xc7,0x5f,0x56,0x14,0x4a,0xe8,0x73,0x95,0x5b,0x1c,0xb9,0xcb }; +__fips_constseg static const unsigned char aes_256_no_df_pr_entropyinputpr2[] = { 0xe5,0xb0,0x2e,0x7e,0x52,0x30,0xe3,0x63,0x82,0xb6,0x44,0xd3, @@ -722,6 +820,7 @@ static const unsigned char aes_256_no_df_pr_entropyinputpr2[] = 0x0c,0x25,0x0e,0x63,0x0b,0xe9,0x12,0x60,0xcd,0xef,0x80,0x0f }; +__fips_constseg static const unsigned char aes_256_no_df_pr_returnedbits[] = { 0x5e,0xf2,0x26,0xef,0x9f,0x58,0x5d,0xd5,0x4a,0x10,0xfe,0xa7, @@ -730,6 +829,7 @@ static const unsigned char aes_256_no_df_pr_returnedbits[] = /* AES-256 no df No PR */ +__fips_constseg static const unsigned char aes_256_no_df_entropyinput[] = { 0xfb,0xcf,0x1b,0x61,0x16,0x89,0x78,0x23,0xf5,0xd8,0x96,0xe3, @@ -738,12 +838,14 @@ static const unsigned char aes_256_no_df_entropyinput[] = 0xcf,0xb3,0xd6,0xfc,0xaf,0x99,0x39,0x28,0x9c,0x61,0xe8,0xb3 }; +__fips_constseg static const unsigned char aes_256_no_df_nonce[] = { 0x12,0x96,0xf0,0x52,0xf3,0x8d,0x81,0xcf,0xde,0x86,0xf2,0x99, 0x43,0x96,0xb9,0xf0 }; +__fips_constseg static const unsigned char aes_256_no_df_personalizationstring[] = { 0x63,0x0d,0x78,0xf5,0x90,0x8e,0x32,0x47,0xb0,0x4d,0x37,0x60, @@ -752,6 +854,7 @@ static const unsigned char aes_256_no_df_personalizationstring[] = 0x66,0x4d,0x62,0xd9,0x10,0xe0,0xad,0xc8,0x9a,0xf0,0xa8,0x6d }; +__fips_constseg static const unsigned char aes_256_no_df_additionalinput[] = { 0x36,0xc6,0x13,0x60,0xbb,0x14,0xad,0x22,0xb0,0x38,0xac,0xa6, @@ -760,12 +863,14 @@ static const unsigned char aes_256_no_df_additionalinput[] = 0x6f,0x8d,0x49,0x74,0x2f,0xda,0xdc,0x1f,0x17,0xd0,0xde,0x17 }; +__fips_constseg static const unsigned char aes_256_no_df_int_returnedbits[] = { 0x16,0x2f,0x8e,0x3f,0x21,0x7a,0x1c,0x20,0x56,0xd1,0x92,0xf6, 0xd2,0x25,0x75,0x0e }; +__fips_constseg static const unsigned char aes_256_no_df_entropyinputreseed[] = { 0x91,0x79,0x76,0xee,0xe0,0xcf,0x9e,0xc2,0xd5,0xd4,0x23,0x9b, @@ -774,6 +879,7 @@ static const unsigned char aes_256_no_df_entropyinputreseed[] = 0x4d,0x6a,0x0e,0xd8,0x9d,0xbe,0x1b,0x31,0x93,0x7b,0xec,0xfb }; +__fips_constseg static const unsigned char aes_256_no_df_additionalinputreseed[] = { 0xd2,0x46,0x50,0x22,0x10,0x14,0x63,0xf7,0xea,0x0f,0xb9,0x7e, @@ -782,6 +888,7 @@ static const unsigned char aes_256_no_df_additionalinputreseed[] = 0x62,0x86,0x64,0xea,0x2c,0x73,0x8c,0xae,0x9d,0x98,0x98,0x29 }; +__fips_constseg static const unsigned char aes_256_no_df_additionalinput2[] = { 0x8c,0xab,0x18,0xf8,0xc3,0xec,0x18,0x5c,0xb3,0x1e,0x9d,0xbe, @@ -790,6 +897,7 @@ static const unsigned char aes_256_no_df_additionalinput2[] = 0xf6,0xd1,0xec,0x27,0x86,0x7b,0xd6,0x55,0x9b,0x60,0xa5,0xc6 }; +__fips_constseg static const unsigned char aes_256_no_df_returnedbits[] = { 0xef,0xd2,0xd8,0x5c,0xdc,0x62,0x25,0x9f,0xaa,0x1e,0x2c,0x67, @@ -798,53 +906,62 @@ static const unsigned char aes_256_no_df_returnedbits[] = /* SHA-1 PR */ +__fips_constseg static const unsigned char sha1_pr_entropyinput[] = { 0xd2,0x36,0xa5,0x27,0x31,0x73,0xdd,0x11,0x4f,0x93,0xbd,0xe2, 0x31,0xa5,0x91,0x13 }; +__fips_constseg static const unsigned char sha1_pr_nonce[] = { 0xb5,0xb3,0x60,0xef,0xf7,0x63,0x31,0xf3 }; +__fips_constseg static const unsigned char sha1_pr_personalizationstring[] = { 0xd4,0xbb,0x02,0x10,0xb2,0x71,0xdb,0x81,0xd6,0xf0,0x42,0x60, 0xda,0xea,0x77,0x52 }; +__fips_constseg static const unsigned char sha1_pr_additionalinput[] = { 0x4d,0xd2,0x6c,0x87,0xfb,0x2c,0x4f,0xa6,0x8d,0x16,0x63,0x22, 0x6a,0x51,0xe3,0xf8 }; +__fips_constseg static const unsigned char sha1_pr_entropyinputpr[] = { 0xc9,0x83,0x9e,0x16,0xf6,0x1c,0x0f,0xb2,0xec,0x60,0x31,0xa9, 0xcb,0xa9,0x36,0x7a }; +__fips_constseg static const unsigned char sha1_pr_int_returnedbits[] = { 0xa8,0x13,0x4f,0xf4,0x31,0x02,0x44,0xe3,0xd3,0x3d,0x61,0x9e, 0xe5,0xc6,0x3e,0x89,0xb5,0x9b,0x0f,0x35 }; +__fips_constseg static const unsigned char sha1_pr_additionalinput2[] = { 0xf9,0xe8,0xd2,0x72,0x13,0x34,0x95,0x6f,0x15,0x49,0x47,0x99, 0x16,0x03,0x19,0x47 }; +__fips_constseg static const unsigned char sha1_pr_entropyinputpr2[] = { 0x4e,0x8c,0x49,0x9b,0x4a,0x5c,0x9b,0x9c,0x3a,0xee,0xfb,0xd2, 0xae,0xcd,0x8c,0xc4 }; +__fips_constseg static const unsigned char sha1_pr_returnedbits[] = { 0x50,0xb4,0xb4,0xcd,0x68,0x57,0xfc,0x2e,0xc1,0x52,0xcc,0xf6, @@ -853,53 +970,62 @@ static const unsigned char sha1_pr_returnedbits[] = /* SHA-1 No PR */ +__fips_constseg static const unsigned char sha1_entropyinput[] = { 0xa9,0x47,0x1b,0x29,0x2d,0x1c,0x05,0xdf,0x76,0xd0,0x62,0xf9, 0xe2,0x7f,0x4c,0x7b }; +__fips_constseg static const unsigned char sha1_nonce[] = { 0x53,0x23,0x24,0xe3,0xec,0x0c,0x54,0x14 }; +__fips_constseg static const unsigned char sha1_personalizationstring[] = { 0x7a,0x87,0xa1,0xac,0x1c,0xfd,0xab,0xae,0xf7,0xd6,0xfb,0x76, 0x28,0xec,0x6d,0xca }; +__fips_constseg static const unsigned char sha1_additionalinput[] = { 0xfc,0x92,0x35,0xd6,0x7e,0xb7,0x24,0x65,0xfd,0x12,0x27,0x35, 0xc0,0x72,0xca,0x28 }; +__fips_constseg static const unsigned char sha1_int_returnedbits[] = { 0x57,0x88,0x82,0xe5,0x25,0xa5,0x2c,0x4a,0x06,0x20,0x6c,0x72, 0x55,0x61,0xdd,0x90,0x71,0x9f,0x95,0xea }; +__fips_constseg static const unsigned char sha1_entropyinputreseed[] = { 0x69,0xa5,0x40,0x62,0x98,0x47,0x56,0x73,0x4a,0x8f,0x60,0x96, 0xd6,0x99,0x27,0xed }; +__fips_constseg static const unsigned char sha1_additionalinputreseed[] = { 0xe5,0x40,0x4e,0xbd,0x50,0x00,0xf5,0x15,0xa6,0xee,0x45,0xda, 0x84,0x3d,0xd4,0xc0 }; +__fips_constseg static const unsigned char sha1_additionalinput2[] = { 0x11,0x51,0x14,0xf0,0x09,0x1b,0x4e,0x56,0x0d,0xe9,0xf6,0x1e, 0x52,0x65,0xcd,0x96 }; +__fips_constseg static const unsigned char sha1_returnedbits[] = { 0xa1,0x9c,0x94,0x6e,0x29,0xe1,0x33,0x0d,0x32,0xd6,0xaa,0xce, @@ -908,35 +1034,41 @@ static const unsigned char sha1_returnedbits[] = /* SHA-224 PR */ +__fips_constseg static const unsigned char sha224_pr_entropyinput[] = { 0x12,0x69,0x32,0x4f,0x83,0xa6,0xf5,0x14,0xe3,0x49,0x3e,0x75, 0x3e,0xde,0xad,0xa1,0x29,0xc3,0xf3,0x19,0x20,0xb5,0x4c,0xd9 }; +__fips_constseg static const unsigned char sha224_pr_nonce[] = { 0x6a,0x78,0xd0,0xeb,0xbb,0x5a,0xf0,0xee,0xe8,0xc3,0xba,0x71 }; +__fips_constseg static const unsigned char sha224_pr_personalizationstring[] = { 0xd5,0xb8,0xb6,0xbc,0xc1,0x5b,0x60,0x31,0x3c,0xf5,0xe5,0xc0, 0x8e,0x52,0x7a,0xbd,0xea,0x47,0xa9,0x5f,0x8f,0xf9,0x8b,0xae }; +__fips_constseg static const unsigned char sha224_pr_additionalinput[] = { 0x1f,0x55,0xec,0xae,0x16,0x12,0x84,0xba,0x84,0x16,0x19,0x88, 0x8e,0xb8,0x33,0x25,0x54,0xff,0xca,0x79,0xaf,0x07,0x25,0x50 }; +__fips_constseg static const unsigned char sha224_pr_entropyinputpr[] = { 0x92,0xa3,0x32,0xa8,0x9a,0x0a,0x58,0x7c,0x1d,0x5a,0x7e,0xe1, 0xb2,0x73,0xab,0x0e,0x16,0x79,0x23,0xd3,0x29,0x89,0x81,0xe1 }; +__fips_constseg static const unsigned char sha224_pr_int_returnedbits[] = { 0xf3,0x38,0x91,0x40,0x37,0x7a,0x51,0x72,0x42,0x74,0x78,0x0a, @@ -944,18 +1076,21 @@ static const unsigned char sha224_pr_int_returnedbits[] = 0x54,0x60,0xee,0x6a }; +__fips_constseg static const unsigned char sha224_pr_additionalinput2[] = { 0x75,0xf3,0x04,0x25,0xdd,0x36,0xa8,0x37,0x46,0xae,0x0c,0x52, 0x05,0x79,0x4c,0x26,0xdb,0xe9,0x71,0x16,0x4c,0x0a,0xf2,0x60 }; +__fips_constseg static const unsigned char sha224_pr_entropyinputpr2[] = { 0xea,0xc5,0x03,0x0a,0x4f,0xb0,0x38,0x8d,0x23,0xd4,0xc8,0x77, 0xe2,0x6d,0x9c,0x0b,0x44,0xf7,0x2d,0x5b,0xbf,0x5d,0x2a,0x11 }; +__fips_constseg static const unsigned char sha224_pr_returnedbits[] = { 0x60,0x50,0x2b,0xe7,0x86,0xd8,0x26,0x73,0xe3,0x1d,0x95,0x20, @@ -965,29 +1100,34 @@ static const unsigned char sha224_pr_returnedbits[] = /* SHA-224 No PR */ +__fips_constseg static const unsigned char sha224_entropyinput[] = { 0xb2,0x1c,0x77,0x4d,0xf6,0xd3,0xb6,0x40,0xb7,0x30,0x3e,0x29, 0xb0,0x85,0x1c,0xbe,0x4a,0xea,0x6b,0x5a,0xb5,0x8a,0x97,0xeb }; +__fips_constseg static const unsigned char sha224_nonce[] = { 0x42,0x02,0x0a,0x1c,0x98,0x9a,0x77,0x9e,0x9f,0x80,0xba,0xe0 }; +__fips_constseg static const unsigned char sha224_personalizationstring[] = { 0x98,0xb8,0x04,0x41,0xfc,0xc1,0x5d,0xc5,0xe9,0xb9,0x08,0xda, 0xf9,0xfa,0x0d,0x90,0xce,0xdf,0x1d,0x10,0xa9,0x8d,0x50,0x0c }; +__fips_constseg static const unsigned char sha224_additionalinput[] = { 0x9a,0x8d,0x39,0x49,0x42,0xd5,0x0b,0xae,0xe1,0xaf,0xb7,0x00, 0x02,0xfa,0x96,0xb1,0xa5,0x1d,0x2d,0x25,0x78,0xee,0x83,0x3f }; +__fips_constseg static const unsigned char sha224_int_returnedbits[] = { 0xe4,0xf5,0x53,0x79,0x5a,0x97,0x58,0x06,0x08,0xba,0x7b,0xfa, @@ -995,24 +1135,28 @@ static const unsigned char sha224_int_returnedbits[] = 0x55,0x22,0x9a,0xad }; +__fips_constseg static const unsigned char sha224_entropyinputreseed[] = { 0x67,0x09,0x48,0xaa,0x07,0x16,0x99,0x89,0x7f,0x6d,0xa0,0xe5, 0x8f,0xdf,0xbc,0xdb,0xfe,0xe5,0x6c,0x7a,0x95,0x4a,0x66,0x17 }; +__fips_constseg static const unsigned char sha224_additionalinputreseed[] = { 0x0f,0x4b,0x1c,0x6f,0xb7,0xe3,0x47,0xe5,0x5d,0x7d,0x38,0xd6, 0x28,0x9b,0xeb,0x55,0x63,0x09,0x3e,0x7c,0x56,0xea,0xf8,0x19 }; +__fips_constseg static const unsigned char sha224_additionalinput2[] = { 0x2d,0x26,0x7c,0x37,0xe4,0x7a,0x28,0x5e,0x5a,0x3c,0xaf,0x3d, 0x5a,0x8e,0x55,0xa2,0x1a,0x6e,0xc0,0xe5,0xf6,0x21,0xd3,0xf6 }; +__fips_constseg static const unsigned char sha224_returnedbits[] = { 0x4d,0x83,0x35,0xdf,0x67,0xa9,0xfc,0x17,0xda,0x70,0xcc,0x8b, @@ -1022,6 +1166,7 @@ static const unsigned char sha224_returnedbits[] = /* SHA-256 PR */ +__fips_constseg static const unsigned char sha256_pr_entropyinput[] = { 0xce,0x49,0x00,0x7a,0x56,0xe3,0x67,0x8f,0xe1,0xb6,0xa7,0xd4, @@ -1029,12 +1174,14 @@ static const unsigned char sha256_pr_entropyinput[] = 0x07,0x3d,0x11,0x0d,0xc8,0xea,0x2b,0xfe }; +__fips_constseg static const unsigned char sha256_pr_nonce[] = { 0x73,0x41,0xc8,0x92,0x94,0xe2,0xc5,0x5f,0x93,0xfd,0x39,0x5d, 0x2b,0x91,0x4d,0x38 }; +__fips_constseg static const unsigned char sha256_pr_personalizationstring[] = { 0x50,0x6d,0x01,0x01,0x07,0x5a,0x80,0x35,0x7a,0x56,0x1a,0x56, @@ -1042,6 +1189,7 @@ static const unsigned char sha256_pr_personalizationstring[] = 0xff,0xfb,0x0f,0xd9,0x4b,0x79,0x1d,0xba }; +__fips_constseg static const unsigned char sha256_pr_additionalinput[] = { 0x20,0xb8,0xdf,0x44,0x77,0x5a,0xb8,0xd3,0xbf,0xf6,0xcf,0xac, @@ -1049,6 +1197,7 @@ static const unsigned char sha256_pr_additionalinput[] = 0x7b,0x0d,0xe4,0x0d,0xc6,0xe4,0x9a,0x1f }; +__fips_constseg static const unsigned char sha256_pr_entropyinputpr[] = { 0x04,0xc4,0x65,0xf4,0xd3,0xbf,0x83,0x4b,0xab,0xc8,0x41,0xa8, @@ -1056,6 +1205,7 @@ static const unsigned char sha256_pr_entropyinputpr[] = 0x17,0xea,0xe6,0x1a,0x9d,0x5e,0x66,0x78 }; +__fips_constseg static const unsigned char sha256_pr_int_returnedbits[] = { 0x07,0x4d,0xac,0x9b,0x86,0xca,0x4a,0xaa,0x6e,0x7a,0x03,0xa2, @@ -1063,6 +1213,7 @@ static const unsigned char sha256_pr_int_returnedbits[] = 0x06,0x34,0x60,0x6f,0x83,0x94,0x99,0x76 }; +__fips_constseg static const unsigned char sha256_pr_additionalinput2[] = { 0x89,0x4e,0x45,0x8c,0x11,0xf9,0xbc,0x5b,0xac,0x74,0x8b,0x4b, @@ -1070,6 +1221,7 @@ static const unsigned char sha256_pr_additionalinput2[] = 0x12,0xa4,0x5f,0xd4,0xec,0xfc,0xcd,0x09 }; +__fips_constseg static const unsigned char sha256_pr_entropyinputpr2[] = { 0x0e,0xeb,0x1f,0xd7,0xfc,0xd1,0x9d,0xd4,0x05,0x36,0x8b,0xb2, @@ -1077,6 +1229,7 @@ static const unsigned char sha256_pr_entropyinputpr2[] = 0x44,0xfe,0x1a,0x03,0x43,0x56,0xbd,0x86 }; +__fips_constseg static const unsigned char sha256_pr_returnedbits[] = { 0x02,0xaa,0xb6,0x1d,0x7e,0x2a,0x40,0x03,0x69,0x2d,0x49,0xa3, @@ -1086,6 +1239,7 @@ static const unsigned char sha256_pr_returnedbits[] = /* SHA-256 No PR */ +__fips_constseg static const unsigned char sha256_entropyinput[] = { 0x5b,0x1b,0xec,0x4d,0xa9,0x38,0x74,0x5a,0x34,0x0b,0x7b,0xc5, @@ -1093,12 +1247,14 @@ static const unsigned char sha256_entropyinput[] = 0xc1,0xbc,0x67,0x69,0xec,0x6b,0x03,0x3c }; +__fips_constseg static const unsigned char sha256_nonce[] = { 0xa4,0x0c,0xd8,0x9c,0x61,0xd8,0xc3,0x54,0xfe,0x53,0xc9,0xe5, 0x5d,0x6f,0x6d,0x35 }; +__fips_constseg static const unsigned char sha256_personalizationstring[] = { 0x22,0x5e,0x62,0x93,0x42,0x83,0x78,0x24,0xd8,0x40,0x8c,0xde, @@ -1106,6 +1262,7 @@ static const unsigned char sha256_personalizationstring[] = 0xfd,0x61,0x56,0xc6,0x4c,0x13,0x41,0x9c }; +__fips_constseg static const unsigned char sha256_additionalinput[] = { 0xbf,0x74,0x5b,0xf6,0xc5,0x64,0x5e,0x99,0x34,0x8f,0xbc,0xa4, @@ -1113,6 +1270,7 @@ static const unsigned char sha256_additionalinput[] = 0x66,0xfc,0xdf,0x63,0x26,0x26,0x19,0x87 }; +__fips_constseg static const unsigned char sha256_int_returnedbits[] = { 0xb3,0xc6,0x07,0x07,0xd6,0x75,0xf6,0x2b,0xd6,0x21,0x96,0xf1, @@ -1120,6 +1278,7 @@ static const unsigned char sha256_int_returnedbits[] = 0xbf,0xd3,0x64,0xbc,0x59,0xf9,0xc0,0x76 }; +__fips_constseg static const unsigned char sha256_entropyinputreseed[] = { 0xbf,0x20,0x33,0x56,0x29,0xa8,0x37,0x04,0x1f,0x78,0x34,0x3d, @@ -1127,6 +1286,7 @@ static const unsigned char sha256_entropyinputreseed[] = 0x46,0x20,0xa4,0x35,0xeb,0xc7,0xe2,0x9d }; +__fips_constseg static const unsigned char sha256_additionalinputreseed[] = { 0x9b,0xae,0x2d,0x2d,0x61,0xa4,0x89,0xeb,0x43,0x46,0xa7,0xda, @@ -1134,6 +1294,7 @@ static const unsigned char sha256_additionalinputreseed[] = 0xd4,0xd0,0xe6,0xbd,0xfb,0x03,0x9c,0xa8 }; +__fips_constseg static const unsigned char sha256_additionalinput2[] = { 0x23,0xaa,0x0c,0xbd,0x28,0x33,0xe2,0x51,0xfc,0x71,0xd2,0x15, @@ -1141,6 +1302,7 @@ static const unsigned char sha256_additionalinput2[] = 0x5c,0xca,0xc5,0x30,0xf2,0x75,0x1f,0xda }; +__fips_constseg static const unsigned char sha256_returnedbits[] = { 0x90,0x3c,0xc1,0x10,0x8c,0x12,0x01,0xc6,0xa6,0x3a,0x0f,0x4d, @@ -1150,6 +1312,7 @@ static const unsigned char sha256_returnedbits[] = /* SHA-384 PR */ +__fips_constseg static const unsigned char sha384_pr_entropyinput[] = { 0x71,0x9d,0xb2,0x5a,0x71,0x6d,0x04,0xe9,0x1e,0xc7,0x92,0x24, @@ -1157,12 +1320,14 @@ static const unsigned char sha384_pr_entropyinput[] = 0x28,0x97,0x06,0x6a,0xc0,0x0c,0xa0,0x7e }; +__fips_constseg static const unsigned char sha384_pr_nonce[] = { 0xf5,0x0d,0xfa,0xb0,0xec,0x6a,0x7c,0xd6,0xbd,0x9b,0x05,0xfd, 0x38,0x3e,0x2e,0x56 }; +__fips_constseg static const unsigned char sha384_pr_personalizationstring[] = { 0x74,0xac,0x7e,0x6d,0xb1,0xa4,0xe7,0x21,0xd1,0x1e,0x6e,0x96, @@ -1170,6 +1335,7 @@ static const unsigned char sha384_pr_personalizationstring[] = 0x9e,0xe1,0x0f,0x15,0xea,0x41,0xbf,0xe3 }; +__fips_constseg static const unsigned char sha384_pr_additionalinput[] = { 0xda,0x95,0xd4,0xd0,0xb8,0x11,0xd3,0x49,0x27,0x5d,0xa9,0x39, @@ -1177,6 +1343,7 @@ static const unsigned char sha384_pr_additionalinput[] = 0x7c,0x9e,0x03,0xa1,0x8b,0x26,0x2d,0x6e }; +__fips_constseg static const unsigned char sha384_pr_entropyinputpr[] = { 0x49,0xdf,0x44,0x00,0xe4,0x1c,0x75,0x0b,0x26,0x5a,0x59,0x64, @@ -1184,6 +1351,7 @@ static const unsigned char sha384_pr_entropyinputpr[] = 0xa0,0x48,0xe6,0xcf,0x1d,0xd1,0x92,0x0d }; +__fips_constseg static const unsigned char sha384_pr_int_returnedbits[] = { 0xc8,0x52,0xae,0xbf,0x04,0x3c,0x27,0xb7,0x78,0x18,0xaa,0x8f, @@ -1192,6 +1360,7 @@ static const unsigned char sha384_pr_int_returnedbits[] = 0xfa,0x61,0x2d,0x9d,0x9e,0xcf,0x98,0xac,0x52,0x40,0xce,0xaf }; +__fips_constseg static const unsigned char sha384_pr_additionalinput2[] = { 0x61,0x7c,0x03,0x9a,0x3e,0x50,0x57,0x60,0xc5,0x83,0xc9,0xb2, @@ -1199,6 +1368,7 @@ static const unsigned char sha384_pr_additionalinput2[] = 0x72,0xfd,0xba,0xae,0x9c,0x8f,0xf8,0x18 }; +__fips_constseg static const unsigned char sha384_pr_entropyinputpr2[] = { 0xf8,0xeb,0x89,0xb1,0x8d,0x78,0xbe,0x21,0xe0,0xbb,0x9d,0xb7, @@ -1206,6 +1376,7 @@ static const unsigned char sha384_pr_entropyinputpr2[] = 0xbd,0xc7,0x0b,0xa5,0xce,0xb2,0x65,0x81 }; +__fips_constseg static const unsigned char sha384_pr_returnedbits[] = { 0xe6,0x9f,0xfe,0x68,0xd6,0xb5,0x79,0xf1,0x06,0x5f,0xa3,0xbb, @@ -1216,6 +1387,7 @@ static const unsigned char sha384_pr_returnedbits[] = /* SHA-384 No PR */ +__fips_constseg static const unsigned char sha384_entropyinput[] = { 0x07,0x15,0x27,0x2a,0xaf,0x74,0x24,0x37,0xbc,0xd5,0x14,0x69, @@ -1223,12 +1395,14 @@ static const unsigned char sha384_entropyinput[] = 0x6a,0xcc,0xcd,0x60,0xa3,0x68,0xca,0xf4 }; +__fips_constseg static const unsigned char sha384_nonce[] = { 0x70,0x17,0xc2,0x5b,0x5d,0x22,0x0b,0x06,0x15,0x54,0x78,0x77, 0x44,0xaf,0x2f,0x09 }; +__fips_constseg static const unsigned char sha384_personalizationstring[] = { 0x89,0x39,0x28,0xb0,0x60,0xeb,0x3d,0xdc,0x55,0x75,0x86,0xeb, @@ -1236,6 +1410,7 @@ static const unsigned char sha384_personalizationstring[] = 0x62,0x8b,0xcb,0x2c,0x26,0xf6,0xbc,0xb1 }; +__fips_constseg static const unsigned char sha384_additionalinput[] = { 0x30,0x2b,0x42,0x35,0xef,0xda,0x40,0x55,0x28,0xc6,0x95,0xfb, @@ -1243,6 +1418,7 @@ static const unsigned char sha384_additionalinput[] = 0x54,0x40,0x22,0xc8,0x66,0xa5,0x48,0x48 }; +__fips_constseg static const unsigned char sha384_int_returnedbits[] = { 0x82,0xc4,0xa1,0x9c,0x21,0xd2,0xe7,0xa5,0xa6,0xf6,0x5f,0x04, @@ -1251,6 +1427,7 @@ static const unsigned char sha384_int_returnedbits[] = 0x2c,0x56,0xf6,0x88,0x3a,0x92,0x93,0xa1,0xfb,0x79,0xc1,0x7a }; +__fips_constseg static const unsigned char sha384_entropyinputreseed[] = { 0x39,0xa6,0xe8,0x5c,0x82,0x17,0x71,0x26,0x57,0x4f,0x9f,0xc2, @@ -1258,6 +1435,7 @@ static const unsigned char sha384_entropyinputreseed[] = 0x2d,0x32,0xf0,0xe4,0x52,0x8c,0xc5,0x0c }; +__fips_constseg static const unsigned char sha384_additionalinputreseed[] = { 0x8d,0xcb,0x8d,0xce,0x08,0xea,0x80,0xe8,0x9b,0x61,0xa8,0x0f, @@ -1265,6 +1443,7 @@ static const unsigned char sha384_additionalinputreseed[] = 0x30,0x2a,0x67,0x08,0xf4,0xe3,0x40,0x22 }; +__fips_constseg static const unsigned char sha384_additionalinput2[] = { 0x7c,0x8f,0xc2,0xae,0x22,0x4a,0xd6,0xf6,0x05,0xa4,0x7a,0xea, @@ -1272,6 +1451,7 @@ static const unsigned char sha384_additionalinput2[] = 0x4e,0xb4,0xbd,0xf4,0xe5,0x40,0x80,0x94 }; +__fips_constseg static const unsigned char sha384_returnedbits[] = { 0x9e,0x7e,0xfb,0x59,0xbb,0xaa,0x3c,0xf7,0xe1,0xf8,0x76,0xdd, @@ -1282,6 +1462,7 @@ static const unsigned char sha384_returnedbits[] = /* SHA-512 PR */ +__fips_constseg static const unsigned char sha512_pr_entropyinput[] = { 0x13,0xf7,0x61,0x75,0x65,0x28,0xa2,0x59,0x13,0x5a,0x4a,0x4f, @@ -1289,12 +1470,14 @@ static const unsigned char sha512_pr_entropyinput[] = 0xa2,0xb5,0xfd,0x5b,0x3a,0xab,0xec,0x28 }; +__fips_constseg static const unsigned char sha512_pr_nonce[] = { 0xbe,0xa3,0x91,0x93,0x1d,0xc3,0x31,0x3a,0x23,0x33,0x50,0x67, 0x88,0xc7,0xa2,0xc4 }; +__fips_constseg static const unsigned char sha512_pr_personalizationstring[] = { 0x1f,0x59,0x4d,0x7b,0xe6,0x46,0x91,0x48,0xc1,0x25,0xfa,0xff, @@ -1302,6 +1485,7 @@ static const unsigned char sha512_pr_personalizationstring[] = 0x22,0x41,0xdd,0x48,0x78,0x6b,0x77,0x2b }; +__fips_constseg static const unsigned char sha512_pr_additionalinput[] = { 0x30,0xff,0x63,0x6f,0xac,0xd9,0x84,0x39,0x6f,0xe4,0x99,0xce, @@ -1309,6 +1493,7 @@ static const unsigned char sha512_pr_additionalinput[] = 0x04,0xa0,0xd2,0x21,0xfe,0xf2,0x95,0x1d }; +__fips_constseg static const unsigned char sha512_pr_entropyinputpr[] = { 0x64,0x54,0x13,0xec,0x4f,0x77,0xda,0xb2,0x92,0x2e,0x52,0x80, @@ -1316,6 +1501,7 @@ static const unsigned char sha512_pr_entropyinputpr[] = 0xeb,0xbb,0xb1,0xbf,0x15,0x5c,0x73,0x08 }; +__fips_constseg static const unsigned char sha512_pr_int_returnedbits[] = { 0xef,0x1e,0xdc,0x0a,0xa4,0x36,0x91,0x9c,0x3d,0x27,0x97,0x50, @@ -1326,6 +1512,7 @@ static const unsigned char sha512_pr_int_returnedbits[] = 0xe2,0xc6,0x8b,0xc3 }; +__fips_constseg static const unsigned char sha512_pr_additionalinput2[] = { 0xe6,0x9b,0xc4,0x88,0x34,0xca,0xea,0x29,0x2f,0x98,0x05,0xa4, @@ -1333,6 +1520,7 @@ static const unsigned char sha512_pr_additionalinput2[] = 0x25,0x7f,0xc1,0xb7,0xb1,0xf1,0x25,0x61 }; +__fips_constseg static const unsigned char sha512_pr_entropyinputpr2[] = { 0x23,0x6d,0xff,0xde,0xfb,0xd1,0xba,0x33,0x18,0xe6,0xbe,0xb5, @@ -1340,6 +1528,7 @@ static const unsigned char sha512_pr_entropyinputpr2[] = 0x1a,0xc8,0x60,0xdb,0x8f,0x99,0x15,0x99 }; +__fips_constseg static const unsigned char sha512_pr_returnedbits[] = { 0x70,0x27,0x31,0xdb,0x92,0x70,0x21,0xfe,0x16,0xb6,0xc8,0x51, @@ -1352,6 +1541,7 @@ static const unsigned char sha512_pr_returnedbits[] = /* SHA-512 No PR */ +__fips_constseg static const unsigned char sha512_entropyinput[] = { 0xb6,0x0b,0xb7,0xbc,0x84,0x56,0xf6,0x12,0xaf,0x45,0x67,0x17, @@ -1359,12 +1549,14 @@ static const unsigned char sha512_entropyinput[] = 0xc6,0xbc,0x4d,0xe1,0xf7,0xbe,0xce,0xbd }; +__fips_constseg static const unsigned char sha512_nonce[] = { 0x9d,0xed,0xc0,0xe5,0x5a,0x98,0x6a,0xcb,0x51,0x7d,0x76,0x31, 0x5a,0x64,0xf0,0xf7 }; +__fips_constseg static const unsigned char sha512_personalizationstring[] = { 0xc2,0x6d,0xa3,0xc3,0x06,0x74,0xe5,0x01,0x5c,0x10,0x17,0xc7, @@ -1372,6 +1564,7 @@ static const unsigned char sha512_personalizationstring[] = 0x46,0x48,0x2d,0xcf,0x36,0x7d,0x59,0xc0 }; +__fips_constseg static const unsigned char sha512_additionalinput[] = { 0xec,0x8c,0xd4,0xf7,0x61,0x6e,0x0d,0x95,0x79,0xb7,0x28,0xad, @@ -1379,6 +1572,7 @@ static const unsigned char sha512_additionalinput[] = 0xc4,0xa1,0x12,0x85,0x0a,0xdf,0x4b,0x34 }; +__fips_constseg static const unsigned char sha512_int_returnedbits[] = { 0x84,0x2f,0x1f,0x68,0x6a,0xa3,0xad,0x1e,0xfb,0xf4,0x15,0xbd, @@ -1389,6 +1583,7 @@ static const unsigned char sha512_int_returnedbits[] = 0x28,0xd4,0x39,0x9a }; +__fips_constseg static const unsigned char sha512_entropyinputreseed[] = { 0xfa,0x7f,0x46,0x51,0x83,0x62,0x98,0x16,0x9a,0x19,0xa2,0x49, @@ -1396,6 +1591,7 @@ static const unsigned char sha512_entropyinputreseed[] = 0xbf,0x11,0xf9,0x9e,0xbc,0xd0,0x01,0xee }; +__fips_constseg static const unsigned char sha512_additionalinputreseed[] = { 0xb9,0x12,0xe0,0x4f,0xf7,0xa7,0xc4,0xd8,0xd0,0x8e,0x99,0x29, @@ -1403,6 +1599,7 @@ static const unsigned char sha512_additionalinputreseed[] = 0x2e,0xfa,0xb8,0x5e,0x8e,0x6b,0x78,0x20 }; +__fips_constseg static const unsigned char sha512_additionalinput2[] = { 0xd7,0x07,0x52,0xb9,0x83,0x2c,0x03,0x71,0xee,0xc9,0xc0,0x85, @@ -1410,6 +1607,7 @@ static const unsigned char sha512_additionalinput2[] = 0x99,0xb2,0x84,0xe9,0x17,0xd2,0x76,0x92 }; +__fips_constseg static const unsigned char sha512_returnedbits[] = { 0x36,0x17,0x5d,0x98,0x2b,0x65,0x25,0x8e,0xc8,0x29,0xdf,0x27, @@ -1422,53 +1620,62 @@ static const unsigned char sha512_returnedbits[] = /* HMAC SHA-1 PR */ +__fips_constseg static const unsigned char hmac_sha1_pr_entropyinput[] = { 0x26,0x5f,0x36,0x14,0xff,0x3d,0x83,0xfa,0x73,0x5e,0x75,0xdc, 0x2c,0x18,0x17,0x1b }; +__fips_constseg static const unsigned char hmac_sha1_pr_nonce[] = { 0xc8,0xe3,0x57,0xa5,0x7b,0x74,0x86,0x6e }; +__fips_constseg static const unsigned char hmac_sha1_pr_personalizationstring[] = { 0x6e,0xdb,0x0d,0xfe,0x7d,0xac,0x79,0xd0,0xa5,0x3a,0x48,0x85, 0x80,0xe2,0x7f,0x2a }; +__fips_constseg static const unsigned char hmac_sha1_pr_additionalinput[] = { 0x31,0xcd,0x5e,0x43,0xdc,0xfb,0x7a,0x79,0xca,0x88,0xde,0x1f, 0xd7,0xbb,0x42,0x09 }; +__fips_constseg static const unsigned char hmac_sha1_pr_entropyinputpr[] = { 0x7c,0x23,0x95,0x38,0x00,0x95,0xc1,0x78,0x1f,0x8f,0xd7,0x63, 0x23,0x87,0x2a,0xed }; +__fips_constseg static const unsigned char hmac_sha1_pr_int_returnedbits[] = { 0xbb,0x34,0xe7,0x93,0xa3,0x02,0x2c,0x4a,0xd0,0x89,0xda,0x7f, 0xed,0xf4,0x4c,0xde,0x17,0xec,0xe5,0x6c }; +__fips_constseg static const unsigned char hmac_sha1_pr_additionalinput2[] = { 0x49,0xbc,0x2d,0x2c,0xb7,0x32,0xcb,0x20,0xdf,0xf5,0x77,0x58, 0xa0,0x4b,0x93,0x6e }; +__fips_constseg static const unsigned char hmac_sha1_pr_entropyinputpr2[] = { 0x3c,0xaa,0xb0,0x21,0x42,0xb0,0xdd,0x34,0xf0,0x16,0x7f,0x0c, 0x0f,0xff,0x2e,0xaf }; +__fips_constseg static const unsigned char hmac_sha1_pr_returnedbits[] = { 0x8e,0xcb,0xa3,0x64,0xb2,0xb8,0x33,0x6c,0x64,0x3b,0x78,0x16, @@ -1477,53 +1684,62 @@ static const unsigned char hmac_sha1_pr_returnedbits[] = /* HMAC SHA-1 No PR */ +__fips_constseg static const unsigned char hmac_sha1_entropyinput[] = { 0x32,0x9a,0x2a,0x87,0x7b,0x89,0x7c,0xf6,0xcb,0x95,0xd5,0x40, 0x17,0xfe,0x47,0x70 }; +__fips_constseg static const unsigned char hmac_sha1_nonce[] = { 0x16,0xd8,0xe0,0xc7,0x52,0xcf,0x4a,0x25 }; +__fips_constseg static const unsigned char hmac_sha1_personalizationstring[] = { 0x35,0x35,0xa9,0xa5,0x40,0xbe,0x9b,0xd1,0x56,0xdd,0x44,0x00, 0x72,0xf7,0xd3,0x5e }; +__fips_constseg static const unsigned char hmac_sha1_additionalinput[] = { 0x1b,0x2c,0x84,0x2d,0x4a,0x89,0x8f,0x69,0x19,0xf1,0xf3,0xdb, 0xbb,0xe3,0xaa,0xea }; +__fips_constseg static const unsigned char hmac_sha1_int_returnedbits[] = { 0xcf,0xfa,0x7d,0x72,0x0f,0xe6,0xc7,0x96,0xa0,0x69,0x31,0x11, 0x9b,0x0b,0x1a,0x20,0x1f,0x3f,0xaa,0xd1 }; +__fips_constseg static const unsigned char hmac_sha1_entropyinputreseed[] = { 0x90,0x75,0x15,0x04,0x95,0xf1,0xba,0x81,0x0c,0x37,0x94,0x6f, 0x86,0x52,0x6d,0x9c }; +__fips_constseg static const unsigned char hmac_sha1_additionalinputreseed[] = { 0x5b,0x40,0xba,0x5f,0x17,0x70,0xf0,0x4b,0xdf,0xc9,0x97,0x92, 0x79,0xc5,0x82,0x28 }; +__fips_constseg static const unsigned char hmac_sha1_additionalinput2[] = { 0x97,0xc8,0x80,0x90,0xb3,0xaa,0x6e,0x60,0xea,0x83,0x7a,0xe3, 0x8a,0xca,0xa4,0x7f }; +__fips_constseg static const unsigned char hmac_sha1_returnedbits[] = { 0x90,0xbd,0x05,0x56,0x6d,0xb5,0x22,0xd5,0xb9,0x5a,0x29,0x2d, @@ -1532,35 +1748,41 @@ static const unsigned char hmac_sha1_returnedbits[] = /* HMAC SHA-224 PR */ +__fips_constseg static const unsigned char hmac_sha224_pr_entropyinput[] = { 0x17,0x32,0x2b,0x2e,0x6f,0x1b,0x9c,0x6d,0x31,0xe0,0x34,0x07, 0xcf,0xed,0xf6,0xb6,0x5a,0x76,0x4c,0xbc,0x62,0x85,0x01,0x90 }; +__fips_constseg static const unsigned char hmac_sha224_pr_nonce[] = { 0x38,0xbf,0x5f,0x20,0xb3,0x68,0x2f,0x43,0x61,0x05,0x8f,0x23 }; +__fips_constseg static const unsigned char hmac_sha224_pr_personalizationstring[] = { 0xc0,0xc9,0x45,0xac,0x8d,0x27,0x77,0x08,0x0b,0x17,0x6d,0xed, 0xc1,0x7d,0xd5,0x07,0x9d,0x6e,0xf8,0x23,0x2a,0x22,0x13,0xbd }; +__fips_constseg static const unsigned char hmac_sha224_pr_additionalinput[] = { 0xa4,0x3c,0xe7,0x3b,0xea,0x19,0x45,0x32,0xc2,0x83,0x6d,0x21, 0x8a,0xc0,0xee,0x67,0x45,0xde,0x13,0x7d,0x9d,0x61,0x00,0x3b }; +__fips_constseg static const unsigned char hmac_sha224_pr_entropyinputpr[] = { 0x15,0x05,0x74,0x4a,0x7f,0x8d,0x5c,0x60,0x16,0xe5,0x7b,0xad, 0xf5,0x41,0x8f,0x55,0x60,0xc4,0x09,0xee,0x1e,0x11,0x81,0xab }; +__fips_constseg static const unsigned char hmac_sha224_pr_int_returnedbits[] = { 0x6f,0xf5,0x9a,0xe2,0x54,0x53,0x30,0x3d,0x5a,0x27,0x29,0x38, @@ -1568,18 +1790,21 @@ static const unsigned char hmac_sha224_pr_int_returnedbits[] = 0x41,0xfe,0x99,0xf2 }; +__fips_constseg static const unsigned char hmac_sha224_pr_additionalinput2[] = { 0x73,0x81,0x88,0x84,0x8f,0xed,0x6f,0x10,0x9f,0x93,0xbf,0x17, 0x35,0x7c,0xef,0xd5,0x8d,0x26,0xa6,0x7a,0xe8,0x09,0x36,0x4f }; +__fips_constseg static const unsigned char hmac_sha224_pr_entropyinputpr2[] = { 0xe6,0xcf,0xcf,0x7e,0x12,0xe5,0x43,0xd2,0x38,0xd8,0x24,0x6f, 0x5a,0x37,0x68,0xbf,0x4f,0xa0,0xff,0xd5,0x61,0x8a,0x93,0xe0 }; +__fips_constseg static const unsigned char hmac_sha224_pr_returnedbits[] = { 0xaf,0xf9,0xd8,0x19,0x91,0x30,0x82,0x6f,0xa9,0x1e,0x9d,0xd7, @@ -1589,29 +1814,34 @@ static const unsigned char hmac_sha224_pr_returnedbits[] = /* HMAC SHA-224 No PR */ +__fips_constseg static const unsigned char hmac_sha224_entropyinput[] = { 0x11,0x82,0xfd,0xd9,0x42,0xf4,0xfa,0xc8,0xf2,0x41,0xe6,0x54, 0x01,0xae,0x22,0x6e,0xc6,0xaf,0xaf,0xd0,0xa6,0xb2,0xe2,0x6d }; +__fips_constseg static const unsigned char hmac_sha224_nonce[] = { 0xa9,0x48,0xd7,0x92,0x39,0x7e,0x2a,0xdc,0x30,0x1f,0x0e,0x2b }; +__fips_constseg static const unsigned char hmac_sha224_personalizationstring[] = { 0x11,0xd5,0xf4,0xbd,0x67,0x8c,0x31,0xcf,0xa3,0x3f,0x1e,0x6b, 0xa8,0x07,0x02,0x0b,0xc8,0x2e,0x6c,0x64,0x41,0x5b,0xc8,0x37 }; +__fips_constseg static const unsigned char hmac_sha224_additionalinput[] = { 0x68,0x18,0xc2,0x06,0xeb,0x3e,0x04,0x95,0x44,0x5e,0xfb,0xe6, 0x41,0xc1,0x5c,0xcc,0x40,0x2f,0xb7,0xd2,0x0f,0xf3,0x6b,0xe7 }; +__fips_constseg static const unsigned char hmac_sha224_int_returnedbits[] = { 0x7f,0x45,0xc7,0x5d,0x32,0xe6,0x17,0x60,0xba,0xdc,0xb8,0x42, @@ -1619,24 +1849,28 @@ static const unsigned char hmac_sha224_int_returnedbits[] = 0xcd,0xd6,0xa9,0xcc }; +__fips_constseg static const unsigned char hmac_sha224_entropyinputreseed[] = { 0xc4,0x8e,0x37,0x95,0x69,0x53,0x28,0xd7,0x37,0xbb,0x70,0x95, 0x1c,0x07,0x1d,0xd9,0xb7,0xe6,0x1b,0xbb,0xfe,0x41,0xeb,0xc9 }; +__fips_constseg static const unsigned char hmac_sha224_additionalinputreseed[] = { 0x53,0x17,0xa1,0x6a,0xfa,0x77,0x47,0xb0,0x95,0x56,0x9a,0x20, 0x57,0xde,0x5c,0x89,0x9f,0x7f,0xe2,0xde,0x17,0x3a,0x50,0x23 }; +__fips_constseg static const unsigned char hmac_sha224_additionalinput2[] = { 0x3a,0x32,0xf9,0x85,0x0c,0xc1,0xed,0x76,0x2d,0xdf,0x40,0xc3, 0x06,0x22,0x66,0xd4,0x9a,0x9a,0xff,0x5a,0x7e,0x7a,0xf3,0x96 }; +__fips_constseg static const unsigned char hmac_sha224_returnedbits[] = { 0x43,0xb4,0x57,0x5c,0x38,0x25,0x9d,0xae,0xec,0x96,0xd1,0x85, @@ -1646,6 +1880,7 @@ static const unsigned char hmac_sha224_returnedbits[] = /* HMAC SHA-256 PR */ +__fips_constseg static const unsigned char hmac_sha256_pr_entropyinput[] = { 0x4d,0xb0,0x43,0xd8,0x34,0x4b,0x10,0x70,0xb1,0x8b,0xed,0xea, @@ -1653,12 +1888,14 @@ static const unsigned char hmac_sha256_pr_entropyinput[] = 0x32,0x48,0x28,0xe7,0x02,0x5d,0xa6,0xa6 }; +__fips_constseg static const unsigned char hmac_sha256_pr_nonce[] = { 0x3a,0xae,0x15,0xa9,0x99,0xdc,0xe4,0x67,0x34,0x3b,0x70,0x15, 0xaa,0xd3,0x30,0x9a }; +__fips_constseg static const unsigned char hmac_sha256_pr_personalizationstring[] = { 0x13,0x1d,0x24,0x04,0xb0,0x18,0x81,0x15,0x21,0x51,0x2a,0x24, @@ -1666,6 +1903,7 @@ static const unsigned char hmac_sha256_pr_personalizationstring[] = 0x71,0xd8,0x01,0x86,0x15,0xb7,0x8b,0xb5 }; +__fips_constseg static const unsigned char hmac_sha256_pr_additionalinput[] = { 0x8f,0xa6,0x54,0x5f,0xb1,0xd0,0xd8,0xc3,0xe7,0x0c,0x15,0xa9, @@ -1673,6 +1911,7 @@ static const unsigned char hmac_sha256_pr_additionalinput[] = 0x8e,0xe9,0x1a,0xa9,0x78,0xfc,0x79,0x0b }; +__fips_constseg static const unsigned char hmac_sha256_pr_entropyinputpr[] = { 0xcf,0x24,0xb9,0xeb,0xb3,0xd4,0xcd,0x17,0x37,0x38,0x75,0x79, @@ -1680,6 +1919,7 @@ static const unsigned char hmac_sha256_pr_entropyinputpr[] = 0x7c,0x5c,0xe4,0x47,0xf1,0x3e,0x1d,0xe5 }; +__fips_constseg static const unsigned char hmac_sha256_pr_int_returnedbits[] = { 0x52,0x42,0xfa,0xeb,0x85,0xe0,0x30,0x22,0x79,0x00,0x16,0xb2, @@ -1687,6 +1927,7 @@ static const unsigned char hmac_sha256_pr_int_returnedbits[] = 0x54,0xd6,0x33,0xe9,0x20,0xd6,0xfd,0x56 }; +__fips_constseg static const unsigned char hmac_sha256_pr_additionalinput2[] = { 0xf4,0xf6,0x49,0xa1,0x2d,0x64,0x2b,0x30,0x58,0xf8,0xbd,0xb8, @@ -1694,6 +1935,7 @@ static const unsigned char hmac_sha256_pr_additionalinput2[] = 0xd0,0xda,0x18,0xb7,0x88,0xfb,0x59,0xf3 }; +__fips_constseg static const unsigned char hmac_sha256_pr_entropyinputpr2[] = { 0x21,0xcd,0x6e,0x46,0xad,0x99,0x07,0x17,0xb4,0x3d,0x76,0x0a, @@ -1701,6 +1943,7 @@ static const unsigned char hmac_sha256_pr_entropyinputpr2[] = 0xa9,0xc9,0x37,0xcf,0xd8,0x26,0x25,0x91 }; +__fips_constseg static const unsigned char hmac_sha256_pr_returnedbits[] = { 0xa7,0xaf,0x2f,0x29,0xe0,0x3a,0x72,0x95,0x96,0x1c,0xa9,0xf0, @@ -1710,6 +1953,7 @@ static const unsigned char hmac_sha256_pr_returnedbits[] = /* HMAC SHA-256 No PR */ +__fips_constseg static const unsigned char hmac_sha256_entropyinput[] = { 0x96,0xb7,0x53,0x22,0x1e,0x52,0x2a,0x96,0xb1,0x15,0x3c,0x35, @@ -1717,12 +1961,14 @@ static const unsigned char hmac_sha256_entropyinput[] = 0x43,0xa1,0x07,0x2c,0x2d,0xe3,0x81,0xcc }; +__fips_constseg static const unsigned char hmac_sha256_nonce[] = { 0xf1,0xac,0x97,0xcb,0x5e,0x06,0x48,0xd2,0x94,0xbe,0x15,0x2e, 0xc7,0xfc,0xc2,0x01 }; +__fips_constseg static const unsigned char hmac_sha256_personalizationstring[] = { 0x98,0xc5,0x1e,0x35,0x5e,0x89,0x0d,0xce,0x64,0x6d,0x18,0xa7, @@ -1730,6 +1976,7 @@ static const unsigned char hmac_sha256_personalizationstring[] = 0xb8,0xeb,0x10,0xd7,0x57,0x18,0xa0,0x32 }; +__fips_constseg static const unsigned char hmac_sha256_additionalinput[] = { 0x1b,0x10,0xaf,0xac,0xd0,0x65,0x95,0xad,0x04,0xad,0x03,0x1c, @@ -1737,6 +1984,7 @@ static const unsigned char hmac_sha256_additionalinput[] = 0x8c,0xa2,0x33,0xa7,0x9a,0x26,0xd3,0x27 }; +__fips_constseg static const unsigned char hmac_sha256_int_returnedbits[] = { 0xba,0x61,0x0e,0x55,0xfe,0x11,0x8a,0x9e,0x0f,0x80,0xdf,0x1d, @@ -1744,6 +1992,7 @@ static const unsigned char hmac_sha256_int_returnedbits[] = 0x88,0xe5,0x4e,0xfb,0xaf,0xce,0x69,0x90 }; +__fips_constseg static const unsigned char hmac_sha256_entropyinputreseed[] = { 0x62,0x7f,0x1e,0x6b,0xe8,0x8e,0xe1,0x35,0x7d,0x9b,0x4f,0xc7, @@ -1751,6 +2000,7 @@ static const unsigned char hmac_sha256_entropyinputreseed[] = 0x2f,0x0f,0x27,0x9c,0xd4,0x15,0xed,0x2d }; +__fips_constseg static const unsigned char hmac_sha256_additionalinputreseed[] = { 0xc7,0x76,0x6e,0xa9,0xd2,0xb2,0x76,0x40,0x82,0x25,0x2c,0xb3, @@ -1758,6 +2008,7 @@ static const unsigned char hmac_sha256_additionalinputreseed[] = 0x49,0x77,0x34,0x88,0x52,0x36,0xe6,0x2e }; +__fips_constseg static const unsigned char hmac_sha256_additionalinput2[] = { 0x8d,0xb8,0x0c,0xd1,0xbf,0x70,0xf6,0x19,0xc3,0x41,0x80,0x9f, @@ -1765,6 +2016,7 @@ static const unsigned char hmac_sha256_additionalinput2[] = 0xdf,0x88,0x6a,0x89,0xd6,0x05,0xd8,0x9d }; +__fips_constseg static const unsigned char hmac_sha256_returnedbits[] = { 0x43,0x12,0x2a,0x2c,0x40,0x53,0x2e,0x7c,0x66,0x34,0xac,0xc3, @@ -1774,6 +2026,7 @@ static const unsigned char hmac_sha256_returnedbits[] = /* HMAC SHA-384 PR */ +__fips_constseg static const unsigned char hmac_sha384_pr_entropyinput[] = { 0x69,0x81,0x98,0x88,0x44,0xf5,0xd6,0x2e,0x00,0x08,0x3b,0xc5, @@ -1781,12 +2034,14 @@ static const unsigned char hmac_sha384_pr_entropyinput[] = 0xf8,0x6d,0xa4,0x58,0x54,0xfd,0x88,0xa9 }; +__fips_constseg static const unsigned char hmac_sha384_pr_nonce[] = { 0x6e,0x38,0x81,0xca,0xb7,0xe8,0x6e,0x66,0x49,0x8a,0xb2,0x59, 0xee,0x16,0xc9,0xde }; +__fips_constseg static const unsigned char hmac_sha384_pr_personalizationstring[] = { 0xfe,0x4c,0xd9,0xf4,0x78,0x3b,0x08,0x41,0x8d,0x8f,0x55,0xc4, @@ -1794,6 +2049,7 @@ static const unsigned char hmac_sha384_pr_personalizationstring[] = 0x04,0xb1,0x4e,0xa9,0x00,0xa1,0x52,0xa1 }; +__fips_constseg static const unsigned char hmac_sha384_pr_additionalinput[] = { 0x89,0xe9,0xcc,0x8f,0x27,0x3c,0x26,0xd1,0x95,0xc8,0x7d,0x0f, @@ -1801,6 +2057,7 @@ static const unsigned char hmac_sha384_pr_additionalinput[] = 0x7c,0x66,0x33,0xa0,0x90,0xc9,0x92,0x88 }; +__fips_constseg static const unsigned char hmac_sha384_pr_entropyinputpr[] = { 0xbe,0x3d,0x7c,0x0d,0xca,0xda,0x7c,0x49,0xb8,0x12,0x36,0xc0, @@ -1808,6 +2065,7 @@ static const unsigned char hmac_sha384_pr_entropyinputpr[] = 0x63,0x82,0x11,0x3e,0xa7,0x33,0x70,0x72 }; +__fips_constseg static const unsigned char hmac_sha384_pr_int_returnedbits[] = { 0x82,0x3d,0xe6,0x54,0x80,0x42,0xf8,0xba,0x90,0x4f,0x06,0xa6, @@ -1816,6 +2074,7 @@ static const unsigned char hmac_sha384_pr_int_returnedbits[] = 0x8e,0x87,0xd1,0x5a,0x48,0x26,0x72,0x2a,0x8e,0xcf,0xee,0xba }; +__fips_constseg static const unsigned char hmac_sha384_pr_additionalinput2[] = { 0x8f,0xff,0xd9,0x84,0xbb,0x85,0x3a,0x66,0xa1,0x21,0xce,0xb2, @@ -1823,6 +2082,7 @@ static const unsigned char hmac_sha384_pr_additionalinput2[] = 0x0d,0xc8,0xe1,0xaf,0x57,0xd2,0xcb,0x60 }; +__fips_constseg static const unsigned char hmac_sha384_pr_entropyinputpr2[] = { 0xd7,0xfb,0xc9,0xe8,0xe2,0xf2,0xaa,0x4c,0xb8,0x51,0x2f,0xe1, @@ -1830,6 +2090,7 @@ static const unsigned char hmac_sha384_pr_entropyinputpr2[] = 0x09,0x69,0x6c,0xd3,0x97,0x51,0x81,0x87 }; +__fips_constseg static const unsigned char hmac_sha384_pr_returnedbits[] = { 0xe6,0x19,0x28,0xa8,0x21,0xce,0x5e,0xdb,0x24,0x79,0x8c,0x76, @@ -1840,6 +2101,7 @@ static const unsigned char hmac_sha384_pr_returnedbits[] = /* HMAC SHA-384 No PR */ +__fips_constseg static const unsigned char hmac_sha384_entropyinput[] = { 0xc3,0x56,0x2b,0x1d,0xc2,0xbb,0xa8,0xf0,0xae,0x1b,0x0d,0xd3, @@ -1847,12 +2109,14 @@ static const unsigned char hmac_sha384_entropyinput[] = 0x04,0x3e,0xb4,0x99,0x35,0xc4,0xc0,0x5f }; +__fips_constseg static const unsigned char hmac_sha384_nonce[] = { 0xc5,0x49,0x1e,0x66,0x27,0x92,0xbe,0xec,0xb5,0x1e,0x4b,0xb1, 0x38,0xe3,0xeb,0x62 }; +__fips_constseg static const unsigned char hmac_sha384_personalizationstring[] = { 0xbe,0xe7,0x6b,0x57,0xde,0x88,0x11,0x96,0x9b,0x6e,0xea,0xe5, @@ -1860,6 +2124,7 @@ static const unsigned char hmac_sha384_personalizationstring[] = 0x6d,0x5a,0xfc,0xbf,0x97,0xba,0xcd,0x77 }; +__fips_constseg static const unsigned char hmac_sha384_additionalinput[] = { 0xe5,0x28,0x5f,0x43,0xf5,0x83,0x6e,0x0a,0x83,0x5c,0xe3,0x81, @@ -1867,6 +2132,7 @@ static const unsigned char hmac_sha384_additionalinput[] = 0x33,0x6c,0x53,0x35,0x0d,0x66,0xe3,0xce }; +__fips_constseg static const unsigned char hmac_sha384_int_returnedbits[] = { 0xe2,0x1f,0xf3,0xda,0x0d,0x19,0x99,0x87,0xc4,0x90,0xa2,0x31, @@ -1875,6 +2141,7 @@ static const unsigned char hmac_sha384_int_returnedbits[] = 0x64,0x95,0x4d,0x48,0x96,0x35,0xe6,0xbd,0x3c,0x34,0xdb,0x1b }; +__fips_constseg static const unsigned char hmac_sha384_entropyinputreseed[] = { 0x77,0x61,0xba,0xbc,0xf2,0xc1,0xf3,0x4b,0x86,0x65,0xfd,0x48, @@ -1882,6 +2149,7 @@ static const unsigned char hmac_sha384_entropyinputreseed[] = 0xcd,0xcd,0x77,0x07,0x2b,0xbe,0xc5,0x5c }; +__fips_constseg static const unsigned char hmac_sha384_additionalinputreseed[] = { 0x18,0x24,0x5f,0xc6,0x84,0xd1,0x67,0xc3,0x9a,0x11,0xa5,0x8c, @@ -1889,6 +2157,7 @@ static const unsigned char hmac_sha384_additionalinputreseed[] = 0x21,0xd9,0x9e,0x41,0x72,0x6c,0x9e,0x63 }; +__fips_constseg static const unsigned char hmac_sha384_additionalinput2[] = { 0x96,0x67,0x41,0x28,0x9b,0xb7,0x92,0x8d,0x64,0x3b,0xe4,0xcf, @@ -1896,6 +2165,7 @@ static const unsigned char hmac_sha384_additionalinput2[] = 0x3b,0xe8,0x91,0x9d,0xe1,0x8a,0xb7,0x32 }; +__fips_constseg static const unsigned char hmac_sha384_returnedbits[] = { 0xe3,0x59,0x61,0x38,0x92,0xec,0xe2,0x3c,0xff,0xb7,0xdb,0x19, @@ -1906,6 +2176,7 @@ static const unsigned char hmac_sha384_returnedbits[] = /* HMAC SHA-512 PR */ +__fips_constseg static const unsigned char hmac_sha512_pr_entropyinput[] = { 0xaa,0x9e,0x45,0x67,0x0e,0x00,0x2a,0x67,0x98,0xd6,0xda,0x0b, @@ -1913,12 +2184,14 @@ static const unsigned char hmac_sha512_pr_entropyinput[] = 0x85,0xd9,0xbe,0x8f,0xf3,0xff,0x91,0x4d }; +__fips_constseg static const unsigned char hmac_sha512_pr_nonce[] = { 0x8c,0x49,0x2f,0x58,0x1e,0x7a,0xda,0x4b,0x7e,0x8a,0x30,0x7b, 0x86,0xea,0xaf,0xa2 }; +__fips_constseg static const unsigned char hmac_sha512_pr_personalizationstring[] = { 0x71,0xe1,0xbb,0xad,0xa7,0x4b,0x2e,0x31,0x3b,0x0b,0xec,0x24, @@ -1926,6 +2199,7 @@ static const unsigned char hmac_sha512_pr_personalizationstring[] = 0xc1,0x7e,0xad,0xec,0x54,0xa6,0xd0,0xad }; +__fips_constseg static const unsigned char hmac_sha512_pr_additionalinput[] = { 0x3d,0x6e,0xa6,0xa8,0x29,0x2a,0xb2,0xf5,0x98,0x42,0xe4,0x92, @@ -1933,6 +2207,7 @@ static const unsigned char hmac_sha512_pr_additionalinput[] = 0xe7,0x05,0x20,0xa9,0x29,0xc6,0x75,0x71 }; +__fips_constseg static const unsigned char hmac_sha512_pr_entropyinputpr[] = { 0xab,0xb9,0x16,0xd8,0x55,0x35,0x54,0xb7,0x97,0x3f,0x94,0xbc, @@ -1940,6 +2215,7 @@ static const unsigned char hmac_sha512_pr_entropyinputpr[] = 0x0c,0xb0,0x03,0xd8,0xbb,0x71,0xd9,0x10 }; +__fips_constseg static const unsigned char hmac_sha512_pr_int_returnedbits[] = { 0x8e,0xd3,0xfd,0x52,0x9e,0x83,0x08,0x49,0x18,0x6e,0x23,0x56, @@ -1950,6 +2226,7 @@ static const unsigned char hmac_sha512_pr_int_returnedbits[] = 0x05,0x17,0xbe,0x0d }; +__fips_constseg static const unsigned char hmac_sha512_pr_additionalinput2[] = { 0xc3,0xfc,0x95,0xaa,0x69,0x06,0xae,0x59,0x41,0xce,0x26,0x08, @@ -1957,6 +2234,7 @@ static const unsigned char hmac_sha512_pr_additionalinput2[] = 0x10,0xba,0x38,0x8c,0xcf,0x29,0x99,0xaa }; +__fips_constseg static const unsigned char hmac_sha512_pr_entropyinputpr2[] = { 0x3b,0x9a,0x25,0xce,0xd7,0xf9,0x5c,0xd1,0x3a,0x3e,0xaa,0x71, @@ -1964,6 +2242,7 @@ static const unsigned char hmac_sha512_pr_entropyinputpr2[] = 0x3f,0xa7,0xf2,0xfd,0x76,0x5f,0x6a,0xe7 }; +__fips_constseg static const unsigned char hmac_sha512_pr_returnedbits[] = { 0xb7,0x82,0xa9,0x57,0x81,0x67,0x53,0xb5,0xa1,0xe9,0x3d,0x35, @@ -1976,6 +2255,7 @@ static const unsigned char hmac_sha512_pr_returnedbits[] = /* HMAC SHA-512 No PR */ +__fips_constseg static const unsigned char hmac_sha512_entropyinput[] = { 0x6e,0x85,0xe6,0x25,0x96,0x29,0xa7,0x52,0x5b,0x60,0xba,0xaa, @@ -1983,12 +2263,14 @@ static const unsigned char hmac_sha512_entropyinput[] = 0x39,0xb9,0x4a,0x96,0xf8,0x77,0xcb,0x95 }; +__fips_constseg static const unsigned char hmac_sha512_nonce[] = { 0xe0,0xa6,0x5d,0x08,0xc3,0x7c,0xae,0x25,0x2e,0x80,0xd1,0x3e, 0xd9,0xaf,0x43,0x3c }; +__fips_constseg static const unsigned char hmac_sha512_personalizationstring[] = { 0x53,0x99,0x52,0x5f,0x11,0xa9,0x64,0x66,0x20,0x5e,0x1b,0x5f, @@ -1996,6 +2278,7 @@ static const unsigned char hmac_sha512_personalizationstring[] = 0x90,0x3b,0xd0,0x78,0xe4,0x0b,0xa7,0x20 }; +__fips_constseg static const unsigned char hmac_sha512_additionalinput[] = { 0x85,0x90,0x80,0xd3,0x98,0xf1,0x53,0x6d,0x68,0x15,0x8f,0xe5, @@ -2003,6 +2286,7 @@ static const unsigned char hmac_sha512_additionalinput[] = 0x50,0x21,0x89,0xae,0xf6,0xfd,0x32,0x73 }; +__fips_constseg static const unsigned char hmac_sha512_int_returnedbits[] = { 0x28,0x56,0x30,0x6f,0xf4,0xa1,0x48,0xe0,0xc9,0xf5,0x75,0x90, @@ -2013,6 +2297,7 @@ static const unsigned char hmac_sha512_int_returnedbits[] = 0xb1,0x57,0x69,0xe8 }; +__fips_constseg static const unsigned char hmac_sha512_entropyinputreseed[] = { 0x8c,0x52,0x7e,0x77,0x72,0x3f,0xa3,0x04,0x97,0x10,0x9b,0x41, @@ -2020,6 +2305,7 @@ static const unsigned char hmac_sha512_entropyinputreseed[] = 0x75,0x82,0x36,0x77,0x88,0xcd,0xa6,0x73 }; +__fips_constseg static const unsigned char hmac_sha512_additionalinputreseed[] = { 0x7e,0x32,0xe3,0x69,0x69,0x07,0x34,0xa2,0x16,0xa2,0x5d,0x1a, @@ -2027,6 +2313,7 @@ static const unsigned char hmac_sha512_additionalinputreseed[] = 0x11,0xe1,0x50,0xff,0x5c,0xb7,0xeb,0x5c }; +__fips_constseg static const unsigned char hmac_sha512_additionalinput2[] = { 0x7f,0x78,0x66,0xd8,0xfb,0x67,0xcf,0x8d,0x8c,0x08,0x30,0xa5, @@ -2034,6 +2321,7 @@ static const unsigned char hmac_sha512_additionalinput2[] = 0xa8,0x60,0xb9,0x07,0xc4,0xb1,0x95,0x48 }; +__fips_constseg static const unsigned char hmac_sha512_returnedbits[] = { 0xdf,0xa7,0x36,0xd4,0xdc,0x5d,0x4d,0x31,0xad,0x69,0x46,0x9f, @@ -2046,35 +2334,41 @@ static const unsigned char hmac_sha512_returnedbits[] = /* P-256 SHA-1 PR */ +__fips_constseg static const unsigned char p_256_sha1_pr_entropyinput[] = { 0xb7,0xd4,0x38,0x90,0x9a,0xa8,0xfc,0xb6,0xd6,0x3c,0xc5,0x35, 0x2b,0x0b,0x0e,0x1f }; +__fips_constseg static const unsigned char p_256_sha1_pr_nonce[] = { 0xd9,0xae,0xf5,0xe8,0xd5,0x10,0x1f,0x82 }; +__fips_constseg static const unsigned char p_256_sha1_pr_personalizationstring[] = { 0x88,0xe8,0x77,0xab,0x01,0x19,0x5e,0xaf,0x50,0x6c,0x89,0x2d, 0x0c,0x12,0xe2,0x11 }; +__fips_constseg static const unsigned char p_256_sha1_pr_additionalinput[] = { 0xd1,0x46,0xa6,0xb0,0x6e,0xc5,0xaa,0x7b,0x6d,0x1a,0xf9,0x36, 0x8c,0x95,0x9c,0xed }; +__fips_constseg static const unsigned char p_256_sha1_pr_entropyinputpr[] = { 0xb0,0x97,0xa8,0x3e,0xd3,0x28,0x3d,0x36,0xdd,0xfe,0x89,0x00, 0x63,0x4f,0x21,0xfc }; +__fips_constseg static const unsigned char p_256_sha1_pr_int_returnedbits[] = { 0x9f,0x66,0x6a,0x38,0x57,0x49,0x15,0xcd,0x5a,0x85,0x03,0x97, @@ -2082,18 +2376,21 @@ static const unsigned char p_256_sha1_pr_int_returnedbits[] = 0x67,0xf4,0x19,0x68,0x92,0x63 }; +__fips_constseg static const unsigned char p_256_sha1_pr_additionalinput2[] = { 0x0c,0xb6,0x1c,0xc7,0x52,0x47,0xe4,0xf1,0xa7,0x75,0x60,0x3d, 0x60,0x07,0x72,0x6f }; +__fips_constseg static const unsigned char p_256_sha1_pr_entropyinputpr2[] = { 0x39,0x37,0xb6,0x55,0x82,0x71,0x0e,0xd4,0x8f,0x8c,0x10,0xe5, 0x7c,0x8f,0x5e,0x37 }; +__fips_constseg static const unsigned char p_256_sha1_pr_returnedbits[] = { 0x37,0x6c,0x94,0x02,0xbe,0x28,0x42,0xd5,0xe7,0x4d,0x1a,0x6e, @@ -2103,29 +2400,34 @@ static const unsigned char p_256_sha1_pr_returnedbits[] = /* P-256 SHA-1 No PR */ +__fips_constseg static const unsigned char p_256_sha1_entropyinput[] = { 0xac,0x08,0x45,0x86,0x79,0xfc,0x4b,0xb4,0x8b,0xe4,0xfd,0x1d, 0x0e,0xeb,0x1b,0x8f }; +__fips_constseg static const unsigned char p_256_sha1_nonce[] = { 0x5e,0xf4,0xe9,0xc5,0x04,0xee,0xb7,0x8a }; +__fips_constseg static const unsigned char p_256_sha1_personalizationstring[] = { 0x55,0x0f,0xca,0x3b,0x1c,0xa6,0xf3,0xce,0xcb,0x6f,0xa7,0xc7, 0x26,0x65,0x0f,0x7c }; +__fips_constseg static const unsigned char p_256_sha1_additionalinput[] = { 0x74,0x51,0x73,0xa9,0xee,0x2e,0x21,0xf9,0xba,0x07,0xe4,0xad, 0x97,0xae,0x1c,0x8b }; +__fips_constseg static const unsigned char p_256_sha1_int_returnedbits[] = { 0x8d,0x45,0x11,0xa9,0x74,0x14,0x05,0x94,0x97,0x66,0x71,0xe2, @@ -2133,24 +2435,28 @@ static const unsigned char p_256_sha1_int_returnedbits[] = 0x3a,0x6e,0x69,0xd3,0xc8,0xc4 }; +__fips_constseg static const unsigned char p_256_sha1_entropyinputreseed[] = { 0x34,0xd9,0x8b,0x67,0x82,0xaf,0x97,0x95,0xe9,0x25,0xa7,0x93, 0x37,0x06,0x73,0x5c }; +__fips_constseg static const unsigned char p_256_sha1_additionalinputreseed[] = { 0x39,0x21,0x24,0x27,0x67,0xa1,0xc3,0xc4,0x90,0xc2,0x68,0x68, 0x26,0x9b,0x32,0xc2 }; +__fips_constseg static const unsigned char p_256_sha1_additionalinput2[] = { 0x84,0xa8,0x10,0xe5,0x71,0x0c,0x1e,0x74,0x42,0x6a,0xa5,0x09, 0x90,0x74,0x39,0xd7 }; +__fips_constseg static const unsigned char p_256_sha1_returnedbits[] = { 0x1e,0x0b,0x5c,0x41,0xcd,0xab,0x07,0xbd,0xdc,0x53,0xa7,0x62, @@ -2160,35 +2466,41 @@ static const unsigned char p_256_sha1_returnedbits[] = /* P-256 SHA-224 PR */ +__fips_constseg static const unsigned char p_256_sha224_pr_entropyinput[] = { 0x92,0x05,0xf0,0x1e,0xc4,0xc4,0x9e,0xab,0x85,0x10,0x16,0xda, 0xa6,0xb4,0xba,0x6f }; +__fips_constseg static const unsigned char p_256_sha224_pr_nonce[] = { 0xa3,0x5e,0xde,0x12,0xdc,0xa7,0x67,0xfd }; +__fips_constseg static const unsigned char p_256_sha224_pr_personalizationstring[] = { 0x76,0xa0,0x8d,0x6c,0x0d,0x19,0x5d,0x94,0x9b,0x92,0x67,0x78, 0x6c,0x02,0xfe,0xe4 }; +__fips_constseg static const unsigned char p_256_sha224_pr_additionalinput[] = { 0xe2,0x05,0xcf,0x63,0x0f,0xf1,0xd0,0x41,0xc9,0xe3,0xf6,0xb0, 0x57,0xaa,0xcd,0x92 }; +__fips_constseg static const unsigned char p_256_sha224_pr_entropyinputpr[] = { 0x1a,0xd5,0xa9,0x25,0x52,0xa8,0xba,0x51,0x81,0x99,0x62,0x4d, 0xbf,0x30,0x44,0xf3 }; +__fips_constseg static const unsigned char p_256_sha224_pr_int_returnedbits[] = { 0xbf,0x9e,0x45,0x73,0x67,0x4b,0x25,0xa5,0x58,0x23,0x31,0xd8, @@ -2196,18 +2508,21 @@ static const unsigned char p_256_sha224_pr_int_returnedbits[] = 0x6a,0xc5,0x70,0x4e,0x5e,0x58 }; +__fips_constseg static const unsigned char p_256_sha224_pr_additionalinput2[] = { 0x4a,0x85,0x19,0xb2,0x61,0x5d,0xd5,0xc0,0x1f,0x47,0x72,0x8b, 0x62,0x35,0x19,0xc1 }; +__fips_constseg static const unsigned char p_256_sha224_pr_entropyinputpr2[] = { 0xda,0xa7,0x84,0x3f,0xfa,0xf9,0xd1,0x51,0x17,0xf8,0xe3,0x77, 0xf5,0x20,0x37,0x17 }; +__fips_constseg static const unsigned char p_256_sha224_pr_returnedbits[] = { 0x15,0xa4,0xa1,0x53,0x4f,0x63,0x06,0xfe,0x28,0xfd,0x58,0xa9, @@ -2217,29 +2532,34 @@ static const unsigned char p_256_sha224_pr_returnedbits[] = /* P-256 SHA-224 No PR */ +__fips_constseg static const unsigned char p_256_sha224_entropyinput[] = { 0xec,0x5b,0x46,0x4a,0xe1,0xe1,0xcb,0x31,0x86,0xa7,0x11,0x3a, 0xff,0x87,0x4a,0x66 }; +__fips_constseg static const unsigned char p_256_sha224_nonce[] = { 0xd1,0x6c,0x33,0x3c,0x37,0xc9,0xc6,0xac }; +__fips_constseg static const unsigned char p_256_sha224_personalizationstring[] = { 0x8b,0xfe,0x68,0x96,0x2d,0xc5,0x91,0xb3,0xf2,0xaa,0x15,0xad, 0x1a,0x50,0x0c,0x0a }; +__fips_constseg static const unsigned char p_256_sha224_additionalinput[] = { 0xd4,0x48,0xfd,0x16,0x41,0xea,0xef,0x06,0x7f,0x4a,0xa2,0x60, 0x60,0x31,0x20,0x5d }; +__fips_constseg static const unsigned char p_256_sha224_int_returnedbits[] = { 0x68,0x64,0x67,0x0c,0x73,0x08,0x00,0x60,0x5a,0xa6,0x9a,0x27, @@ -2247,24 +2567,28 @@ static const unsigned char p_256_sha224_int_returnedbits[] = 0x42,0xbe,0x46,0x73,0x40,0x1c }; +__fips_constseg static const unsigned char p_256_sha224_entropyinputreseed[] = { 0x9c,0xde,0x86,0x11,0x55,0x9a,0xb4,0x2b,0x70,0xf0,0xc6,0x9d, 0x8d,0x3a,0xc3,0x1e }; +__fips_constseg static const unsigned char p_256_sha224_additionalinputreseed[] = { 0x5d,0x5b,0xeb,0x38,0xc5,0x8b,0x2b,0xc8,0x73,0xe3,0x0e,0xca, 0x35,0xb0,0x4d,0x11 }; +__fips_constseg static const unsigned char p_256_sha224_additionalinput2[] = { 0xf7,0xa3,0x79,0x4b,0xb0,0x2c,0x1e,0xc6,0x61,0x69,0x14,0x6a, 0xed,0xf1,0xa2,0xd8 }; +__fips_constseg static const unsigned char p_256_sha224_returnedbits[] = { 0x89,0x75,0x1b,0x89,0x20,0xcc,0xe2,0xaf,0xae,0x5e,0xc1,0xa9, @@ -2274,35 +2598,41 @@ static const unsigned char p_256_sha224_returnedbits[] = /* P-256 SHA-256 PR */ +__fips_constseg static const unsigned char p_256_sha256_pr_entropyinput[] = { 0x22,0xe4,0x4c,0x01,0x94,0x59,0xce,0x08,0xb3,0x92,0x48,0xe2, 0x0d,0x1a,0x32,0x4d }; +__fips_constseg static const unsigned char p_256_sha256_pr_nonce[] = { 0x8d,0xf9,0x20,0x8a,0x65,0xf4,0x93,0x37 }; +__fips_constseg static const unsigned char p_256_sha256_pr_personalizationstring[] = { 0x06,0x7e,0xe8,0x4f,0xdd,0xae,0x8d,0xf1,0xc9,0x13,0x9a,0x81, 0xd3,0x68,0x76,0xc1 }; +__fips_constseg static const unsigned char p_256_sha256_pr_additionalinput[] = { 0xfa,0x8e,0xea,0xf3,0xcf,0xda,0x7c,0x11,0x88,0xaa,0xb9,0x02, 0x84,0xc4,0x30,0x54 }; +__fips_constseg static const unsigned char p_256_sha256_pr_entropyinputpr[] = { 0xbb,0x21,0x72,0x4f,0x83,0x03,0x14,0x18,0x8e,0x88,0xec,0x73, 0xde,0xed,0x60,0xf7 }; +__fips_constseg static const unsigned char p_256_sha256_pr_int_returnedbits[] = { 0xdc,0x40,0x73,0x5e,0x1d,0x21,0x35,0x8c,0xcf,0xa4,0x50,0x05, @@ -2310,18 +2640,21 @@ static const unsigned char p_256_sha256_pr_int_returnedbits[] = 0x48,0x9d,0x84,0x77,0xc2,0x8e }; +__fips_constseg static const unsigned char p_256_sha256_pr_additionalinput2[] = { 0x0e,0xa7,0x4d,0x4f,0x19,0x94,0x34,0x05,0x46,0x3e,0x0c,0x05, 0x27,0x85,0xd9,0xdf }; +__fips_constseg static const unsigned char p_256_sha256_pr_entropyinputpr2[] = { 0x4f,0xae,0x44,0x10,0x2b,0xa1,0xbc,0xd7,0xcb,0xa7,0x49,0x55, 0x27,0x54,0x36,0x2b }; +__fips_constseg static const unsigned char p_256_sha256_pr_returnedbits[] = { 0x1c,0x16,0xf7,0x2b,0xd0,0xb7,0x54,0x5a,0xa5,0x85,0x14,0x63, @@ -2331,29 +2664,34 @@ static const unsigned char p_256_sha256_pr_returnedbits[] = /* P-256 SHA-256 No PR */ +__fips_constseg static const unsigned char p_256_sha256_entropyinput[] = { 0xa7,0x0b,0x6b,0xf7,0xfb,0x40,0x1a,0xca,0xa9,0x1f,0x16,0xc9, 0x6a,0xd0,0x4a,0x8c }; +__fips_constseg static const unsigned char p_256_sha256_nonce[] = { 0x97,0x8e,0xb1,0x72,0xe8,0x30,0xfc,0x43 }; +__fips_constseg static const unsigned char p_256_sha256_personalizationstring[] = { 0x6c,0x90,0x00,0x41,0x84,0x7c,0x58,0x56,0x48,0xf0,0x60,0x04, 0xe9,0xc0,0xa0,0xd8 }; +__fips_constseg static const unsigned char p_256_sha256_additionalinput[] = { 0x69,0xad,0xd7,0x7c,0xbd,0x90,0xa1,0x63,0xcd,0x64,0x7c,0xb3, 0xce,0xff,0xf2,0xf7 }; +__fips_constseg static const unsigned char p_256_sha256_int_returnedbits[] = { 0xe8,0x5a,0x4f,0x5d,0xab,0xc7,0xd2,0x94,0x4d,0xbf,0x02,0x57, @@ -2361,24 +2699,28 @@ static const unsigned char p_256_sha256_int_returnedbits[] = 0x32,0x45,0xd7,0x8a,0x8a,0x38 }; +__fips_constseg static const unsigned char p_256_sha256_entropyinputreseed[] = { 0x5c,0xb4,0x82,0x38,0xa2,0x2d,0x78,0x63,0x2a,0x38,0x77,0x5b, 0x9a,0x59,0x4d,0x17 }; +__fips_constseg static const unsigned char p_256_sha256_additionalinputreseed[] = { 0x43,0x28,0x7f,0x91,0x92,0xad,0x88,0x75,0x64,0xe5,0xef,0x95, 0x59,0xa9,0x11,0x61 }; +__fips_constseg static const unsigned char p_256_sha256_additionalinput2[] = { 0x77,0xee,0xfc,0x84,0x5b,0x69,0xdf,0x9f,0x7e,0xf2,0xb1,0x35, 0x34,0x28,0x8f,0xcd }; +__fips_constseg static const unsigned char p_256_sha256_returnedbits[] = { 0x2d,0x45,0x00,0x60,0x87,0x6c,0xfa,0x69,0x06,0x9e,0x99,0xf9, @@ -2388,35 +2730,41 @@ static const unsigned char p_256_sha256_returnedbits[] = /* P-256 SHA-384 PR */ +__fips_constseg static const unsigned char p_256_sha384_pr_entropyinput[] = { 0xb3,0x6a,0x1b,0x68,0xe3,0x8a,0xa4,0xad,0x2d,0xa0,0x6a,0xae, 0x10,0xe5,0x55,0x58 }; +__fips_constseg static const unsigned char p_256_sha384_pr_nonce[] = { 0xe2,0xe8,0xd4,0x8d,0xc8,0x47,0xad,0x79 }; +__fips_constseg static const unsigned char p_256_sha384_pr_personalizationstring[] = { 0xf9,0xbb,0xac,0xe9,0xd9,0x8a,0x58,0xae,0x58,0xa6,0x68,0xd2, 0xff,0x49,0x71,0x08 }; +__fips_constseg static const unsigned char p_256_sha384_pr_additionalinput[] = { 0xa7,0xa3,0xcc,0xc1,0xbf,0xa7,0x32,0xe8,0xcb,0x21,0xf4,0x35, 0x42,0xa6,0xdd,0x4b }; +__fips_constseg static const unsigned char p_256_sha384_pr_entropyinputpr[] = { 0x37,0xdb,0x5a,0x83,0x9c,0x7a,0x50,0xe3,0xc7,0xbd,0x50,0x63, 0x88,0x44,0xa1,0x50 }; +__fips_constseg static const unsigned char p_256_sha384_pr_int_returnedbits[] = { 0x65,0x3a,0xdd,0x95,0x3a,0x52,0xd7,0x7f,0x8d,0x81,0x1b,0x53, @@ -2424,18 +2772,21 @@ static const unsigned char p_256_sha384_pr_int_returnedbits[] = 0xbc,0x1c,0x02,0xd2,0xe9,0x1e }; +__fips_constseg static const unsigned char p_256_sha384_pr_additionalinput2[] = { 0xb3,0xff,0xbc,0x54,0x38,0x49,0x1f,0xad,0x3f,0x33,0x5f,0x45, 0x21,0x2f,0xcf,0xba }; +__fips_constseg static const unsigned char p_256_sha384_pr_entropyinputpr2[] = { 0x43,0x37,0x4a,0x16,0x15,0x1d,0x3d,0xa9,0x3b,0xcf,0xbb,0x73, 0x67,0xce,0x93,0xbf }; +__fips_constseg static const unsigned char p_256_sha384_pr_returnedbits[] = { 0x1e,0x1b,0x69,0x67,0xb8,0xd7,0xb4,0x18,0xb8,0xa0,0x11,0xc7, @@ -2445,29 +2796,34 @@ static const unsigned char p_256_sha384_pr_returnedbits[] = /* P-256 SHA-384 No PR */ +__fips_constseg static const unsigned char p_256_sha384_entropyinput[] = { 0x1c,0x0d,0xa7,0x27,0x1f,0xb4,0xa2,0x4a,0xe5,0x25,0x00,0xbe, 0xbe,0x80,0x88,0xa8 }; +__fips_constseg static const unsigned char p_256_sha384_nonce[] = { 0x2c,0x7e,0x21,0x02,0x46,0x9e,0xe5,0xae }; +__fips_constseg static const unsigned char p_256_sha384_personalizationstring[] = { 0x0a,0xf6,0x83,0xa9,0x7b,0x97,0x20,0x60,0xcc,0x46,0x0e,0x52, 0xd0,0xcb,0x57,0xb5 }; +__fips_constseg static const unsigned char p_256_sha384_additionalinput[] = { 0xac,0xd8,0x25,0xef,0x85,0xa8,0x5e,0x55,0x89,0x5b,0x6e,0xf6, 0x4d,0x4d,0x05,0x53 }; +__fips_constseg static const unsigned char p_256_sha384_int_returnedbits[] = { 0x5c,0x71,0x32,0x2f,0x34,0x09,0x99,0x6a,0x4e,0x55,0xaf,0x4b, @@ -2475,24 +2831,28 @@ static const unsigned char p_256_sha384_int_returnedbits[] = 0xe5,0xe4,0x6f,0x61,0xab,0x8c }; +__fips_constseg static const unsigned char p_256_sha384_entropyinputreseed[] = { 0x4b,0x0d,0xa9,0x66,0xc3,0x64,0xe9,0xd5,0x87,0xb1,0x98,0xc2, 0xeb,0x14,0xd2,0x8a }; +__fips_constseg static const unsigned char p_256_sha384_additionalinputreseed[] = { 0x1f,0x11,0x6b,0xc0,0x15,0x38,0xbd,0x62,0x27,0xf7,0x6d,0x97, 0x77,0xd1,0xcc,0x00 }; +__fips_constseg static const unsigned char p_256_sha384_additionalinput2[] = { 0x1d,0x9a,0xe5,0xfc,0xed,0x93,0x3d,0xbb,0x08,0xf3,0xba,0x01, 0x6f,0x9f,0xdf,0xb1 }; +__fips_constseg static const unsigned char p_256_sha384_returnedbits[] = { 0x4a,0xd5,0xd3,0x62,0xbb,0x6e,0x6c,0xb2,0x1c,0x0e,0xf6,0x97, @@ -2502,35 +2862,41 @@ static const unsigned char p_256_sha384_returnedbits[] = /* P-256 SHA-512 PR */ +__fips_constseg static const unsigned char p_256_sha512_pr_entropyinput[] = { 0x73,0x83,0x07,0x93,0x85,0x39,0x2f,0x96,0xcd,0x74,0x32,0x4d, 0x68,0x0e,0x97,0x9d }; +__fips_constseg static const unsigned char p_256_sha512_pr_nonce[] = { 0xab,0xc6,0xf4,0x38,0x72,0x9b,0x9f,0x36 }; +__fips_constseg static const unsigned char p_256_sha512_pr_personalizationstring[] = { 0x88,0x8e,0xc1,0xaf,0xe9,0x1b,0x8a,0xf5,0xf2,0x23,0x44,0x71, 0xf5,0x9a,0xed,0x5e }; +__fips_constseg static const unsigned char p_256_sha512_pr_additionalinput[] = { 0x38,0xf7,0x2b,0x11,0x7b,0xd6,0xfa,0xbd,0x07,0x42,0x46,0x77, 0xed,0x1b,0x3f,0x95 }; +__fips_constseg static const unsigned char p_256_sha512_pr_entropyinputpr[] = { 0x52,0xf2,0x68,0x6d,0xc9,0x1b,0xc7,0xb0,0x52,0x07,0x69,0x79, 0x25,0x5d,0xbb,0xdb }; +__fips_constseg static const unsigned char p_256_sha512_pr_int_returnedbits[] = { 0x23,0xa6,0x84,0x48,0x4f,0xd3,0x1f,0x56,0x57,0xae,0x50,0xea, @@ -2538,18 +2904,21 @@ static const unsigned char p_256_sha512_pr_int_returnedbits[] = 0x45,0xbb,0x1d,0x90,0x2c,0xce }; +__fips_constseg static const unsigned char p_256_sha512_pr_additionalinput2[] = { 0x9c,0x46,0x61,0x85,0x2c,0x9e,0x2c,0xd0,0x4d,0xcd,0x73,0x78, 0x08,0x8d,0x49,0x5b }; +__fips_constseg static const unsigned char p_256_sha512_pr_entropyinputpr2[] = { 0x71,0x60,0x46,0x14,0xc1,0xaa,0x21,0xc8,0xf1,0xfe,0x32,0x90, 0x46,0xfd,0xe9,0x80 }; +__fips_constseg static const unsigned char p_256_sha512_pr_returnedbits[] = { 0x7a,0x30,0x7d,0x6e,0xb1,0x22,0xb9,0x68,0x7d,0x00,0x14,0x63, @@ -2559,29 +2928,34 @@ static const unsigned char p_256_sha512_pr_returnedbits[] = /* P-256 SHA-512 No PR */ +__fips_constseg static const unsigned char p_256_sha512_entropyinput[] = { 0x55,0xd0,0x7f,0xb7,0x23,0x81,0x95,0x38,0xa7,0xbf,0x01,0x8d, 0x06,0x8b,0xbc,0x47 }; +__fips_constseg static const unsigned char p_256_sha512_nonce[] = { 0x96,0xab,0x85,0xba,0x88,0x7b,0xf5,0x6e }; +__fips_constseg static const unsigned char p_256_sha512_personalizationstring[] = { 0xea,0x25,0x60,0xd0,0x5d,0xd8,0x9c,0x8d,0x43,0x23,0x49,0x0a, 0xd5,0x57,0xf3,0x54 }; +__fips_constseg static const unsigned char p_256_sha512_additionalinput[] = { 0x8e,0xe8,0xfd,0x2e,0xcd,0x27,0xc6,0x7e,0x7a,0xf8,0xe7,0x11, 0xb8,0x0d,0x20,0x36 }; +__fips_constseg static const unsigned char p_256_sha512_int_returnedbits[] = { 0x57,0x18,0x20,0x51,0xd7,0x57,0x13,0xb0,0xa0,0x8f,0x92,0xd2, @@ -2589,24 +2963,28 @@ static const unsigned char p_256_sha512_int_returnedbits[] = 0x0a,0x04,0x11,0xdf,0x52,0x27 }; +__fips_constseg static const unsigned char p_256_sha512_entropyinputreseed[] = { 0x89,0x1d,0x17,0x0c,0xe4,0x82,0x34,0xe7,0x81,0x6c,0x47,0x47, 0xc6,0x49,0x50,0x3e }; +__fips_constseg static const unsigned char p_256_sha512_additionalinputreseed[] = { 0xe7,0xe4,0x88,0x00,0xa7,0xc9,0xb7,0x6b,0x70,0xda,0xe3,0xf0, 0x44,0xa9,0x02,0xf6 }; +__fips_constseg static const unsigned char p_256_sha512_additionalinput2[] = { 0x09,0x9f,0xd2,0xe8,0xb2,0x0e,0x6e,0x89,0xf5,0x73,0x1c,0x1f, 0x93,0xf2,0x76,0xb2 }; +__fips_constseg static const unsigned char p_256_sha512_returnedbits[] = { 0xdd,0x42,0x2a,0x7b,0x4f,0x84,0x07,0xfa,0x4d,0x17,0x9a,0x2e, @@ -2616,35 +2994,41 @@ static const unsigned char p_256_sha512_returnedbits[] = /* P-384 SHA-224 PR */ +__fips_constseg static const unsigned char p_384_sha224_pr_entropyinput[] = { 0x34,0xf0,0x89,0xac,0x46,0x33,0xe2,0x7f,0x8c,0x02,0x65,0x09, 0xe1,0xcf,0x93,0x5b,0x10,0xbc,0xb0,0x43,0x4f,0xc7,0x62,0x19 }; +__fips_constseg static const unsigned char p_384_sha224_pr_nonce[] = { 0x55,0x30,0xdf,0xa9,0xfb,0xbe,0x4a,0x2e,0x1d,0x03,0xf5,0x91 }; +__fips_constseg static const unsigned char p_384_sha224_pr_personalizationstring[] = { 0x35,0xc7,0x3a,0x7b,0x5a,0x4e,0xd4,0x1a,0x82,0xe2,0xf5,0xed, 0x40,0x61,0x4b,0xf4,0xb9,0xcf,0xd0,0xc1,0xe2,0x41,0x23,0x04 }; +__fips_constseg static const unsigned char p_384_sha224_pr_additionalinput[] = { 0xec,0xef,0x64,0xfb,0x92,0xbb,0xdf,0x8b,0xc8,0xf2,0xad,0xd8, 0x93,0x21,0x6f,0x11,0xde,0x37,0x52,0xe3,0x16,0x49,0xc7,0xe1 }; +__fips_constseg static const unsigned char p_384_sha224_pr_entropyinputpr[] = { 0x59,0xb0,0x7e,0x34,0x49,0x29,0x7e,0x91,0x92,0x91,0x0c,0xca, 0x8e,0x31,0x62,0x06,0xab,0xf4,0x81,0x80,0xa4,0x55,0x8f,0x0f }; +__fips_constseg static const unsigned char p_384_sha224_pr_int_returnedbits[] = { 0x29,0xd9,0x3a,0x95,0xb1,0x34,0xff,0x73,0x06,0x1e,0x08,0x43, @@ -2653,18 +3037,21 @@ static const unsigned char p_384_sha224_pr_int_returnedbits[] = 0xf0,0xc7,0x57,0x35,0x5d,0x32,0x78,0x9e,0x1d,0x2a }; +__fips_constseg static const unsigned char p_384_sha224_pr_additionalinput2[] = { 0x56,0x8c,0x6f,0x29,0xd6,0x25,0x9f,0xb8,0x6a,0x1d,0x70,0x5f, 0x6a,0xe7,0xe2,0x2e,0xcc,0x6b,0x78,0x0a,0x3f,0x54,0x73,0x97 }; +__fips_constseg static const unsigned char p_384_sha224_pr_entropyinputpr2[] = { 0xe3,0x91,0x20,0x13,0x78,0xc6,0x01,0xfd,0x82,0xd7,0x43,0x1e, 0xed,0x85,0x4a,0xe2,0x0c,0x6f,0xdc,0x43,0x5f,0x7c,0xfd,0xd0 }; +__fips_constseg static const unsigned char p_384_sha224_pr_returnedbits[] = { 0x89,0xa9,0x17,0xd8,0xcb,0x73,0x17,0x69,0x78,0x69,0x50,0x58, @@ -2675,29 +3062,34 @@ static const unsigned char p_384_sha224_pr_returnedbits[] = /* P-384 SHA-224 No PR */ +__fips_constseg static const unsigned char p_384_sha224_entropyinput[] = { 0x44,0x2c,0xc3,0xc6,0x20,0xe6,0x61,0xec,0xd1,0x2b,0xdf,0x18, 0x2e,0xc5,0x4a,0xd4,0x80,0x55,0xbd,0x54,0x89,0x01,0x7b,0xbb }; +__fips_constseg static const unsigned char p_384_sha224_nonce[] = { 0x16,0x27,0x4b,0xb3,0x0f,0x01,0xd0,0xe6,0x9f,0x5c,0x44,0xa4 }; +__fips_constseg static const unsigned char p_384_sha224_personalizationstring[] = { 0x55,0x26,0x3e,0xee,0xaa,0x1b,0x35,0x27,0xef,0x18,0x28,0x62, 0x51,0x1e,0xbc,0x4c,0x64,0x0d,0xf8,0x20,0xe6,0x0a,0x1d,0xaa }; +__fips_constseg static const unsigned char p_384_sha224_additionalinput[] = { 0x27,0x08,0x22,0x32,0x4a,0xd6,0xc6,0x51,0xff,0xc5,0xb7,0x8f, 0xb4,0x3e,0xa0,0x6e,0xe2,0x55,0xa1,0xf1,0x2e,0x0d,0x89,0x91 }; +__fips_constseg static const unsigned char p_384_sha224_int_returnedbits[] = { 0x85,0x0e,0xe3,0xde,0xed,0x40,0xdc,0xec,0x9a,0x2d,0x65,0x24, @@ -2706,24 +3098,28 @@ static const unsigned char p_384_sha224_int_returnedbits[] = 0xa7,0xb1,0x91,0xba,0x0d,0x81,0x8f,0x04,0xaf,0x91 }; +__fips_constseg static const unsigned char p_384_sha224_entropyinputreseed[] = { 0x27,0x57,0xc2,0x22,0xa6,0x70,0xb9,0x74,0x86,0x59,0x8c,0xff, 0x7d,0x10,0x0c,0xe3,0x24,0xf1,0x95,0xbd,0x99,0x84,0xca,0x11 }; +__fips_constseg static const unsigned char p_384_sha224_additionalinputreseed[] = { 0x5a,0xc3,0x47,0x2c,0x9c,0x1d,0xe0,0x43,0x3b,0x1b,0x01,0xed, 0x86,0x5d,0x1b,0x3f,0x45,0xb1,0x8e,0xa9,0x79,0x7b,0x88,0x01 }; +__fips_constseg static const unsigned char p_384_sha224_additionalinput2[] = { 0x7d,0x48,0x91,0xda,0x00,0x60,0x33,0x2c,0x22,0xe4,0x42,0x61, 0xbc,0x70,0x05,0x73,0x22,0x23,0x42,0xda,0x7a,0x2b,0xba,0xbb }; +__fips_constseg static const unsigned char p_384_sha224_returnedbits[] = { 0xfa,0x7d,0x7b,0x35,0x32,0xbe,0x44,0x91,0x90,0xd2,0x69,0x9a, @@ -2734,35 +3130,41 @@ static const unsigned char p_384_sha224_returnedbits[] = /* P-384 SHA-256 PR */ +__fips_constseg static const unsigned char p_384_sha256_pr_entropyinput[] = { 0xc6,0xd0,0xc7,0xa3,0x7e,0x2b,0x8c,0xd6,0x23,0xe9,0x9e,0x1f, 0x77,0x30,0xed,0x6a,0xfc,0xe4,0x7b,0xf0,0x6f,0xd6,0xfe,0x05 }; +__fips_constseg static const unsigned char p_384_sha256_pr_nonce[] = { 0x67,0x91,0xca,0x93,0xc8,0x1e,0x93,0x13,0x00,0x72,0x4e,0xa2 }; +__fips_constseg static const unsigned char p_384_sha256_pr_personalizationstring[] = { 0xa5,0x5b,0x6e,0xeb,0xc9,0x0d,0x42,0x0b,0x41,0xec,0x0b,0x9e, 0xde,0xc1,0x80,0x4d,0xe3,0x86,0xa0,0xfe,0x7e,0x92,0x47,0xa3 }; +__fips_constseg static const unsigned char p_384_sha256_pr_additionalinput[] = { 0x9a,0x04,0xa9,0x78,0x48,0xa8,0x77,0x0f,0x38,0x2a,0x54,0x66, 0x34,0xaa,0x31,0xbd,0xf6,0xfb,0xc1,0x14,0xa5,0xcb,0x1c,0xf2 }; +__fips_constseg static const unsigned char p_384_sha256_pr_entropyinputpr[] = { 0x19,0x6c,0x48,0xf5,0x64,0xb3,0xb4,0x49,0x6e,0xb8,0xc4,0x8b, 0xab,0xba,0xb5,0x8e,0xa3,0xf1,0x6e,0xe9,0xf6,0x37,0xa1,0x46 }; +__fips_constseg static const unsigned char p_384_sha256_pr_int_returnedbits[] = { 0xfd,0x04,0x26,0x4f,0xbd,0x84,0xe3,0x54,0xb2,0x9b,0xb1,0x84, @@ -2771,18 +3173,21 @@ static const unsigned char p_384_sha256_pr_int_returnedbits[] = 0xae,0x71,0xe9,0x60,0x94,0x90,0xce,0x6d,0xba,0xab }; +__fips_constseg static const unsigned char p_384_sha256_pr_additionalinput2[] = { 0x4d,0x27,0x90,0x17,0x81,0x74,0x4f,0xa4,0x40,0xdf,0x42,0x29, 0xc5,0x37,0xf1,0x31,0x89,0x90,0x27,0x8a,0x96,0xcc,0x68,0x6e }; +__fips_constseg static const unsigned char p_384_sha256_pr_entropyinputpr2[] = { 0x1d,0xbe,0xdf,0x39,0xd8,0x82,0xb2,0x8f,0x7f,0x90,0xac,0x19, 0xc8,0x65,0xf2,0x5a,0xff,0x4e,0xbb,0xcf,0xcd,0xce,0x2c,0xfd }; +__fips_constseg static const unsigned char p_384_sha256_pr_returnedbits[] = { 0x45,0x63,0xac,0xb5,0x1e,0x49,0x99,0x67,0x89,0xd4,0x9c,0xa9, @@ -2793,29 +3198,34 @@ static const unsigned char p_384_sha256_pr_returnedbits[] = /* P-384 SHA-256 No PR */ +__fips_constseg static const unsigned char p_384_sha256_entropyinput[] = { 0x52,0x92,0xc4,0xac,0xce,0xf5,0x35,0xa4,0x15,0xdb,0xa9,0xe1, 0xbc,0x7b,0x08,0xa5,0x27,0x16,0xe3,0x50,0x08,0x2d,0x09,0x2d }; +__fips_constseg static const unsigned char p_384_sha256_nonce[] = { 0xe8,0x14,0x2b,0xee,0xba,0xac,0xe0,0x25,0xd0,0x3b,0x78,0xc5 }; +__fips_constseg static const unsigned char p_384_sha256_personalizationstring[] = { 0x28,0x0c,0x86,0x48,0x5e,0xca,0xfa,0x89,0x1f,0x58,0xb8,0x2c, 0x41,0x28,0x3f,0x98,0x71,0x66,0x7b,0xb7,0x32,0xa2,0xe1,0x49 }; +__fips_constseg static const unsigned char p_384_sha256_additionalinput[] = { 0xdc,0x59,0xb1,0x23,0x39,0x75,0x1b,0x27,0x24,0x5f,0x7a,0x55, 0x82,0xdc,0xdc,0xe2,0x12,0x65,0xbf,0x8a,0x65,0xdb,0x27,0xdb }; +__fips_constseg static const unsigned char p_384_sha256_int_returnedbits[] = { 0xc0,0x86,0xd8,0x67,0xdd,0xe4,0xce,0x15,0x60,0xad,0x45,0x60, @@ -2824,24 +3234,28 @@ static const unsigned char p_384_sha256_int_returnedbits[] = 0xa8,0x0f,0x45,0xd6,0x2e,0xd1,0xe6,0x29,0xb5,0x1c }; +__fips_constseg static const unsigned char p_384_sha256_entropyinputreseed[] = { 0x9f,0x19,0x9f,0xc8,0x18,0x43,0xfc,0x9a,0x97,0xed,0x20,0x13, 0xad,0xc9,0xa0,0x65,0xef,0x38,0xd6,0x2e,0xce,0x4d,0xe1,0x1d }; +__fips_constseg static const unsigned char p_384_sha256_additionalinputreseed[] = { 0xa6,0x27,0x35,0x9f,0x8a,0xaa,0xf5,0xb3,0x60,0x4b,0x16,0x68, 0xdd,0x32,0x2e,0x1b,0xb1,0x34,0x47,0x03,0x45,0x3f,0xb6,0x3e }; +__fips_constseg static const unsigned char p_384_sha256_additionalinput2[] = { 0x76,0x4e,0x5c,0x75,0x33,0xa5,0x94,0x95,0xf4,0x36,0xa5,0x39, 0x28,0xc1,0x74,0xd1,0xfa,0x1d,0x8a,0x40,0x6e,0x84,0x4e,0xc7 }; +__fips_constseg static const unsigned char p_384_sha256_returnedbits[] = { 0x50,0x15,0xc9,0x98,0x73,0x71,0x55,0xb7,0x7a,0xf4,0xa5,0xe7, @@ -2852,35 +3266,41 @@ static const unsigned char p_384_sha256_returnedbits[] = /* P-384 SHA-384 PR */ +__fips_constseg static const unsigned char p_384_sha384_pr_entropyinput[] = { 0x3b,0x40,0x57,0x65,0x46,0x14,0xa5,0xf6,0x63,0x21,0xe7,0x33, 0xd7,0x38,0xa7,0x54,0x33,0x62,0x08,0x08,0x37,0xef,0xbf,0x22 }; +__fips_constseg static const unsigned char p_384_sha384_pr_nonce[] = { 0xf4,0xd4,0x11,0x0a,0x4a,0xdb,0xfc,0xbb,0x08,0x7a,0x20,0x51 }; +__fips_constseg static const unsigned char p_384_sha384_pr_personalizationstring[] = { 0x5d,0x5b,0x9d,0xe5,0x45,0x62,0x5b,0xd0,0xa8,0x1b,0xea,0xe3, 0xbd,0x59,0xd4,0xab,0x50,0xbe,0x5d,0x21,0x5d,0x85,0x42,0x16 }; +__fips_constseg static const unsigned char p_384_sha384_pr_additionalinput[] = { 0xd9,0xac,0x4b,0x76,0x18,0x46,0xba,0x30,0x88,0xdf,0x41,0xdb, 0x72,0x9b,0x4d,0xb7,0xbb,0x12,0xd2,0xd8,0x00,0xa0,0x81,0x14 }; +__fips_constseg static const unsigned char p_384_sha384_pr_entropyinputpr[] = { 0x46,0x6d,0x66,0xaf,0xcf,0xb3,0x59,0x37,0x52,0x7e,0xa0,0xce, 0x6d,0xaa,0x40,0xac,0x87,0xce,0x01,0x76,0x8f,0xac,0x49,0x42 }; +__fips_constseg static const unsigned char p_384_sha384_pr_int_returnedbits[] = { 0xe1,0xea,0x43,0x73,0x35,0xf8,0x1f,0x2d,0xab,0x82,0x82,0x7f, @@ -2889,18 +3309,21 @@ static const unsigned char p_384_sha384_pr_int_returnedbits[] = 0x0c,0x36,0xe1,0xaf,0xd3,0xbd,0x43,0x08,0xb8,0x65 }; +__fips_constseg static const unsigned char p_384_sha384_pr_additionalinput2[] = { 0x6f,0xe5,0x27,0xa8,0x0c,0x4b,0xad,0x03,0xba,0xaa,0x70,0xc5, 0xc6,0x4c,0xa6,0x6b,0xd9,0xb4,0x74,0x7a,0xea,0x4b,0x07,0xc8 }; +__fips_constseg static const unsigned char p_384_sha384_pr_entropyinputpr2[] = { 0xec,0xc8,0x0c,0x3a,0x39,0xd3,0x2e,0xa9,0xab,0x57,0x89,0x1d, 0x85,0x23,0x54,0x40,0xdf,0x15,0xbd,0x65,0x41,0xe5,0xaf,0xfb }; +__fips_constseg static const unsigned char p_384_sha384_pr_returnedbits[] = { 0x3f,0xe0,0xa9,0x90,0x8e,0x27,0x2c,0xbe,0xfe,0xdd,0x35,0x67, @@ -2911,29 +3334,34 @@ static const unsigned char p_384_sha384_pr_returnedbits[] = /* P-384 SHA-384 No PR */ +__fips_constseg static const unsigned char p_384_sha384_entropyinput[] = { 0x52,0x51,0xd7,0x2a,0x26,0xda,0xeb,0x5c,0xfb,0x23,0x47,0x49, 0xf7,0x04,0xc6,0x62,0xed,0x72,0x3e,0x70,0x41,0x87,0x75,0x42 }; +__fips_constseg static const unsigned char p_384_sha384_nonce[] = { 0x63,0x66,0x35,0x65,0x9b,0xe5,0xd3,0xcb,0x94,0x82,0x81,0x05 }; +__fips_constseg static const unsigned char p_384_sha384_personalizationstring[] = { 0x52,0xa4,0xce,0x0e,0x4b,0x72,0x21,0x63,0xad,0x21,0x7f,0x60, 0x9e,0x5d,0xa7,0xff,0xef,0xf1,0xfb,0x04,0xdb,0x30,0x5a,0x0c }; +__fips_constseg static const unsigned char p_384_sha384_additionalinput[] = { 0xd7,0xde,0x8e,0xc4,0xeb,0x69,0xd2,0x2b,0xed,0x00,0x4a,0x6e, 0x3a,0x13,0xf5,0x48,0xe4,0x83,0xad,0x81,0x4d,0x68,0xe5,0x57 }; +__fips_constseg static const unsigned char p_384_sha384_int_returnedbits[] = { 0xbc,0x2d,0x9b,0x3b,0xbb,0x75,0xf4,0xdf,0xda,0x0f,0x10,0x88, @@ -2942,24 +3370,28 @@ static const unsigned char p_384_sha384_int_returnedbits[] = 0xcc,0x39,0x83,0xab,0x3f,0x31,0xe7,0x6d,0x44,0x0f }; +__fips_constseg static const unsigned char p_384_sha384_entropyinputreseed[] = { 0xef,0x0f,0xa7,0x4e,0x90,0xe1,0x57,0x9e,0xce,0x52,0xe1,0xa0, 0xd3,0x0f,0x06,0xa4,0xfe,0x5d,0x55,0x60,0xe2,0xc5,0x45,0x3b }; +__fips_constseg static const unsigned char p_384_sha384_additionalinputreseed[] = { 0xec,0x87,0x9e,0x8e,0x58,0xb8,0xa3,0xd3,0x3e,0x49,0x22,0xf5, 0x68,0x5b,0x60,0x6e,0x7b,0x73,0xd5,0xa4,0x7c,0x9e,0xcd,0xba }; +__fips_constseg static const unsigned char p_384_sha384_additionalinput2[] = { 0x1c,0xd2,0xce,0x30,0x31,0x8b,0xbb,0xaf,0xbb,0xa8,0xae,0x20, 0xa3,0x6b,0xb5,0x37,0xfe,0x09,0x91,0x1a,0x63,0x33,0x29,0x8c }; +__fips_constseg static const unsigned char p_384_sha384_returnedbits[] = { 0xd7,0x36,0x7b,0x33,0x50,0x6a,0x59,0xb0,0x7c,0xb3,0xc4,0xe9, @@ -2970,35 +3402,41 @@ static const unsigned char p_384_sha384_returnedbits[] = /* P-384 SHA-512 PR */ +__fips_constseg static const unsigned char p_384_sha512_pr_entropyinput[] = { 0x14,0xdf,0x91,0xdb,0xad,0xe2,0x22,0xe5,0x56,0xa1,0x88,0xbd, 0x42,0x73,0xf7,0x8d,0xdc,0x99,0x54,0x99,0x8a,0xab,0x11,0x4b }; +__fips_constseg static const unsigned char p_384_sha512_pr_nonce[] = { 0x10,0x49,0x5d,0xf6,0x5d,0x17,0xa7,0xa6,0xd8,0xc7,0xc8,0xe7 }; +__fips_constseg static const unsigned char p_384_sha512_pr_personalizationstring[] = { 0x61,0x59,0xc5,0x8e,0x30,0x77,0x05,0x75,0x87,0xff,0x0b,0x06, 0x03,0x79,0xa5,0x8b,0x59,0xb8,0x32,0xc9,0x19,0x47,0x7d,0x0e }; +__fips_constseg static const unsigned char p_384_sha512_pr_additionalinput[] = { 0x41,0xd5,0x73,0x17,0x13,0x4c,0xe8,0x7c,0x83,0x45,0x84,0xf1, 0x72,0xae,0x1d,0xea,0x08,0x0a,0x56,0xec,0x16,0xf9,0x1f,0xb6 }; +__fips_constseg static const unsigned char p_384_sha512_pr_entropyinputpr[] = { 0xa6,0x85,0xa8,0xa4,0x0f,0xad,0x96,0x32,0x39,0x5e,0x86,0xb0, 0x8b,0xda,0xb2,0xf0,0x38,0x75,0xf8,0xe2,0xc0,0xbf,0x77,0x62 }; +__fips_constseg static const unsigned char p_384_sha512_pr_int_returnedbits[] = { 0xc8,0xf2,0x0c,0x8a,0xe7,0x72,0xe2,0xa3,0x5e,0x0a,0xaa,0x21, @@ -3007,18 +3445,21 @@ static const unsigned char p_384_sha512_pr_int_returnedbits[] = 0x92,0x08,0x71,0x16,0xce,0x3e,0x5b,0x6b,0x9a,0x52 }; +__fips_constseg static const unsigned char p_384_sha512_pr_additionalinput2[] = { 0x72,0x72,0xb3,0x26,0x05,0x49,0xf0,0x34,0xb6,0x04,0x75,0x6a, 0x0a,0x86,0x9c,0x8f,0xe5,0x3d,0x90,0x26,0x42,0x92,0x2a,0x77 }; +__fips_constseg static const unsigned char p_384_sha512_pr_entropyinputpr2[] = { 0xf1,0xda,0x51,0xa2,0x21,0x54,0x2d,0x6d,0xec,0x92,0xe5,0x8f, 0x81,0x96,0x21,0x60,0x93,0x33,0x3d,0xfb,0x92,0xfe,0xae,0xcb }; +__fips_constseg static const unsigned char p_384_sha512_pr_returnedbits[] = { 0x12,0x87,0x30,0xc4,0x87,0x61,0x58,0xab,0x79,0x05,0xb4,0xfd, @@ -3029,29 +3470,34 @@ static const unsigned char p_384_sha512_pr_returnedbits[] = /* P-384 SHA-512 No PR */ +__fips_constseg static const unsigned char p_384_sha512_entropyinput[] = { 0xc7,0x7b,0x0e,0xe1,0x06,0x66,0x63,0x87,0x15,0x09,0x0a,0xe2, 0xbe,0xdc,0xd5,0x3c,0x65,0xce,0xc5,0x25,0xfd,0xf2,0x23,0xbe }; +__fips_constseg static const unsigned char p_384_sha512_nonce[] = { 0x5c,0xe8,0xa7,0x7d,0x45,0x8d,0x89,0xcd,0xb7,0xa3,0x4a,0x98 }; +__fips_constseg static const unsigned char p_384_sha512_personalizationstring[] = { 0xa9,0x0e,0x29,0xff,0x2f,0x4e,0x92,0xe3,0xbd,0xcf,0x25,0xfa, 0x96,0xdf,0x18,0x16,0x9a,0x99,0xb0,0x07,0xfe,0x51,0x24,0x9e }; +__fips_constseg static const unsigned char p_384_sha512_additionalinput[] = { 0x1a,0x19,0xdf,0x08,0x35,0x94,0x83,0x30,0xab,0x01,0x98,0x2b, 0xa5,0xe2,0x6d,0x99,0xe7,0x30,0xd5,0xef,0xf1,0xa7,0x61,0x61 }; +__fips_constseg static const unsigned char p_384_sha512_int_returnedbits[] = { 0xa2,0x80,0xdb,0xa3,0x6c,0x7b,0x74,0x57,0x65,0x9d,0x32,0x53, @@ -3060,24 +3506,28 @@ static const unsigned char p_384_sha512_int_returnedbits[] = 0x90,0xcd,0x6e,0xc5,0x97,0x1e,0xa2,0x90,0x2b,0x7e }; +__fips_constseg static const unsigned char p_384_sha512_entropyinputreseed[] = { 0xf4,0x57,0x3d,0xc5,0x13,0x99,0xb2,0x4d,0xdd,0xdf,0xf3,0xa0, 0x7b,0x82,0x8a,0x22,0x9a,0x02,0x9c,0xac,0x6f,0xb4,0x07,0xd8 }; +__fips_constseg static const unsigned char p_384_sha512_additionalinputreseed[] = { 0x12,0x98,0x84,0xa1,0xb5,0x26,0x7e,0x55,0xe1,0xd1,0x00,0x8f, 0x50,0x96,0x30,0xa7,0x33,0xf5,0xb4,0x76,0x93,0x7a,0x2d,0x82 }; +__fips_constseg static const unsigned char p_384_sha512_additionalinput2[] = { 0xfd,0x4c,0x76,0x61,0x48,0x40,0xa7,0x1e,0xa1,0xe9,0x25,0xcc, 0xa6,0x21,0x4e,0x87,0xc9,0x27,0x06,0x3e,0x89,0x8b,0x18,0x3c }; +__fips_constseg static const unsigned char p_384_sha512_returnedbits[] = { 0x90,0xa9,0xd4,0x1a,0x7f,0xb5,0xdd,0x66,0x5f,0xa7,0xc9,0x53, @@ -3088,6 +3538,7 @@ static const unsigned char p_384_sha512_returnedbits[] = /* P-521 SHA-256 PR */ +__fips_constseg static const unsigned char p_521_sha256_pr_entropyinput[] = { 0x1a,0xb3,0x78,0x1e,0x14,0x19,0x83,0x05,0xac,0xb0,0x95,0xe1, @@ -3095,12 +3546,14 @@ static const unsigned char p_521_sha256_pr_entropyinput[] = 0x88,0xc4,0xc4,0x4e,0x6d,0x03,0x96,0x5e }; +__fips_constseg static const unsigned char p_521_sha256_pr_nonce[] = { 0xd8,0x3d,0x1c,0x7e,0x4a,0x8e,0x28,0x4a,0xd6,0xf7,0xe8,0x0c, 0x54,0x69,0x31,0xe4 }; +__fips_constseg static const unsigned char p_521_sha256_pr_personalizationstring[] = { 0xc7,0xa6,0xb8,0xc0,0x25,0xaa,0x88,0xf5,0xc7,0x6a,0xd2,0xfc, @@ -3108,6 +3561,7 @@ static const unsigned char p_521_sha256_pr_personalizationstring[] = 0x9e,0xcd,0x5c,0x5d,0x2b,0xa3,0x45,0x86 }; +__fips_constseg static const unsigned char p_521_sha256_pr_additionalinput[] = { 0xde,0xc5,0x1d,0x59,0x4d,0x25,0x3c,0x4f,0xbb,0x81,0xb3,0x61, @@ -3115,6 +3569,7 @@ static const unsigned char p_521_sha256_pr_additionalinput[] = 0x94,0xf2,0xde,0x54,0x49,0x37,0xea,0xe8 }; +__fips_constseg static const unsigned char p_521_sha256_pr_entropyinputpr[] = { 0x4e,0xe6,0x23,0xa4,0x97,0xaf,0x70,0x36,0xed,0xed,0x37,0x6b, @@ -3122,6 +3577,7 @@ static const unsigned char p_521_sha256_pr_entropyinputpr[] = 0xb5,0xb1,0xd7,0x40,0x29,0x2e,0xa8,0xd8 }; +__fips_constseg static const unsigned char p_521_sha256_pr_int_returnedbits[] = { 0x7d,0x64,0x63,0x00,0xa5,0x98,0x9b,0xf3,0xf4,0x09,0x44,0x64, @@ -3132,6 +3588,7 @@ static const unsigned char p_521_sha256_pr_int_returnedbits[] = 0xbb,0xe1,0x8e }; +__fips_constseg static const unsigned char p_521_sha256_pr_additionalinput2[] = { 0xda,0x8a,0xbb,0x5e,0x1f,0xc7,0x4b,0x7e,0x2b,0x09,0xdd,0x64, @@ -3139,6 +3596,7 @@ static const unsigned char p_521_sha256_pr_additionalinput2[] = 0x16,0xe9,0x4a,0x3b,0x6e,0xc1,0xc6,0x74 }; +__fips_constseg static const unsigned char p_521_sha256_pr_entropyinputpr2[] = { 0x7b,0x4d,0x60,0x68,0xb1,0xd7,0xbe,0xf7,0x40,0xb5,0x84,0xa8, @@ -3146,6 +3604,7 @@ static const unsigned char p_521_sha256_pr_entropyinputpr2[] = 0x6a,0xf5,0x72,0x74,0xb5,0x6f,0x9f,0x7a }; +__fips_constseg static const unsigned char p_521_sha256_pr_returnedbits[] = { 0xb2,0x4e,0x40,0x75,0xaf,0xcf,0x93,0x13,0xaf,0x97,0x49,0x49, @@ -3158,6 +3617,7 @@ static const unsigned char p_521_sha256_pr_returnedbits[] = /* P-521 SHA-256 No PR */ +__fips_constseg static const unsigned char p_521_sha256_entropyinput[] = { 0x69,0x5d,0x57,0x6d,0xe8,0xb1,0x0a,0x01,0xf8,0x1d,0xb9,0x5d, @@ -3165,12 +3625,14 @@ static const unsigned char p_521_sha256_entropyinput[] = 0x55,0xd6,0xde,0xa2,0xc4,0xd2,0x78,0xfb }; +__fips_constseg static const unsigned char p_521_sha256_nonce[] = { 0x12,0xd2,0x1a,0xac,0xaf,0x49,0xb2,0xa4,0x9c,0x33,0x2e,0xdb, 0x46,0xd1,0xc7,0x23 }; +__fips_constseg static const unsigned char p_521_sha256_personalizationstring[] = { 0xb7,0xe2,0xeb,0xa9,0x88,0xb5,0x24,0xf3,0x82,0xc6,0x83,0xe3, @@ -3178,6 +3640,7 @@ static const unsigned char p_521_sha256_personalizationstring[] = 0x02,0x5b,0x2e,0xd2,0x01,0x52,0x4a,0x48 }; +__fips_constseg static const unsigned char p_521_sha256_additionalinput[] = { 0xf4,0xa2,0xfa,0xae,0x18,0x94,0xdb,0x12,0x0b,0xa8,0x1e,0x4e, @@ -3185,6 +3648,7 @@ static const unsigned char p_521_sha256_additionalinput[] = 0xcc,0xdb,0xae,0x5a,0xbc,0xb0,0x53,0x3f }; +__fips_constseg static const unsigned char p_521_sha256_int_returnedbits[] = { 0xbd,0x16,0xe4,0x4d,0x62,0xa1,0xb4,0x4f,0x3f,0xba,0x27,0x58, @@ -3195,6 +3659,7 @@ static const unsigned char p_521_sha256_int_returnedbits[] = 0xe1,0xea,0xbd }; +__fips_constseg static const unsigned char p_521_sha256_entropyinputreseed[] = { 0xda,0x4e,0x7f,0xf0,0x7d,0x4d,0xd8,0x74,0xa2,0x74,0x08,0x82, @@ -3202,6 +3667,7 @@ static const unsigned char p_521_sha256_entropyinputreseed[] = 0x40,0xe0,0x5a,0x95,0x5b,0x99,0x7f,0x28 }; +__fips_constseg static const unsigned char p_521_sha256_additionalinputreseed[] = { 0xf3,0x7d,0x64,0xae,0x7a,0xb3,0x9c,0xee,0x0a,0xd3,0x1a,0x56, @@ -3209,6 +3675,7 @@ static const unsigned char p_521_sha256_additionalinputreseed[] = 0x05,0x49,0xcc,0x28,0x81,0xaf,0x73,0x8a }; +__fips_constseg static const unsigned char p_521_sha256_additionalinput2[] = { 0x80,0xf2,0xdc,0xd2,0x0e,0x77,0x89,0xd7,0x46,0x67,0x31,0x28, @@ -3216,6 +3683,7 @@ static const unsigned char p_521_sha256_additionalinput2[] = 0x46,0x0e,0x50,0xc8,0x32,0xe0,0x4d,0x8f }; +__fips_constseg static const unsigned char p_521_sha256_returnedbits[] = { 0x04,0xce,0x3f,0x47,0x4b,0x90,0x0e,0x0b,0x5d,0x61,0xd2,0xe4, @@ -3228,6 +3696,7 @@ static const unsigned char p_521_sha256_returnedbits[] = /* P-521 SHA-384 PR */ +__fips_constseg static const unsigned char p_521_sha384_pr_entropyinput[] = { 0xd7,0xc3,0x75,0xc9,0xdc,0xd6,0x28,0x49,0x6c,0x0c,0x26,0xe8, @@ -3235,12 +3704,14 @@ static const unsigned char p_521_sha384_pr_entropyinput[] = 0x42,0x12,0x5f,0x6c,0x80,0x65,0x37,0x77 }; +__fips_constseg static const unsigned char p_521_sha384_pr_nonce[] = { 0x07,0x8a,0xc4,0xbb,0x27,0x54,0x33,0xe2,0xfa,0x4a,0xe2,0x84, 0xe5,0x5b,0x27,0x69 }; +__fips_constseg static const unsigned char p_521_sha384_pr_personalizationstring[] = { 0x69,0x90,0xea,0xac,0x46,0x2f,0x9a,0x3a,0xcc,0xdb,0xbc,0x26, @@ -3248,6 +3719,7 @@ static const unsigned char p_521_sha384_pr_personalizationstring[] = 0x36,0x69,0x8a,0x70,0x4e,0xb0,0xfb,0x16 }; +__fips_constseg static const unsigned char p_521_sha384_pr_additionalinput[] = { 0xc7,0x82,0x8d,0xac,0x49,0xed,0x4d,0xe0,0x5f,0x26,0xe4,0xdf, @@ -3255,6 +3727,7 @@ static const unsigned char p_521_sha384_pr_additionalinput[] = 0x18,0x86,0x73,0xcb,0x0d,0x3c,0xf4,0x76 }; +__fips_constseg static const unsigned char p_521_sha384_pr_entropyinputpr[] = { 0x88,0xeb,0xbc,0xc4,0xdb,0xb0,0x0c,0xc7,0xc9,0x0a,0xae,0x9f, @@ -3262,6 +3735,7 @@ static const unsigned char p_521_sha384_pr_entropyinputpr[] = 0x84,0x84,0x48,0x47,0x2d,0x24,0xc4,0xf8 }; +__fips_constseg static const unsigned char p_521_sha384_pr_int_returnedbits[] = { 0xf1,0x8a,0x43,0xec,0x2b,0x3f,0x74,0x05,0xae,0x4f,0x96,0xbb, @@ -3272,6 +3746,7 @@ static const unsigned char p_521_sha384_pr_int_returnedbits[] = 0x1c,0x3a,0x5f }; +__fips_constseg static const unsigned char p_521_sha384_pr_additionalinput2[] = { 0x1e,0xbd,0x75,0x87,0x28,0x2e,0x05,0xbe,0xb3,0xa8,0x81,0x57, @@ -3279,6 +3754,7 @@ static const unsigned char p_521_sha384_pr_additionalinput2[] = 0xac,0xdd,0xec,0x5e,0xb6,0xc6,0x9e,0x72 }; +__fips_constseg static const unsigned char p_521_sha384_pr_entropyinputpr2[] = { 0xa4,0x30,0xe4,0xec,0x31,0x84,0x79,0x5c,0x40,0xd8,0x54,0x9d, @@ -3286,6 +3762,7 @@ static const unsigned char p_521_sha384_pr_entropyinputpr2[] = 0xdb,0x4c,0xbd,0x4a,0x5a,0x6c,0xe7,0x40 }; +__fips_constseg static const unsigned char p_521_sha384_pr_returnedbits[] = { 0x15,0x44,0x90,0x6e,0x56,0xc1,0x51,0x2a,0x0d,0x3a,0x2f,0x1a, @@ -3298,6 +3775,7 @@ static const unsigned char p_521_sha384_pr_returnedbits[] = /* P-521 SHA-384 No PR */ +__fips_constseg static const unsigned char p_521_sha384_entropyinput[] = { 0xd2,0x5e,0x8a,0xdf,0x9d,0x50,0x3e,0xb8,0x0e,0x01,0x7b,0x02, @@ -3305,12 +3783,14 @@ static const unsigned char p_521_sha384_entropyinput[] = 0x60,0x8d,0xf8,0x83,0xdc,0xaf,0xb0,0xe1 }; +__fips_constseg static const unsigned char p_521_sha384_nonce[] = { 0x03,0xb8,0xbe,0x6f,0x90,0x5a,0xca,0x32,0xcd,0x86,0x9f,0x0a, 0x01,0xb6,0x8f,0x41 }; +__fips_constseg static const unsigned char p_521_sha384_personalizationstring[] = { 0x39,0x5d,0xc0,0xa6,0xa7,0x8f,0xc4,0x5e,0xec,0xb7,0x45,0xa7, @@ -3318,6 +3798,7 @@ static const unsigned char p_521_sha384_personalizationstring[] = 0x35,0x9a,0x8a,0x44,0x6f,0xea,0xb8,0x15 }; +__fips_constseg static const unsigned char p_521_sha384_additionalinput[] = { 0xac,0x37,0xb4,0x53,0x39,0xd7,0xdd,0xad,0x63,0x8d,0xe6,0x1a, @@ -3325,6 +3806,7 @@ static const unsigned char p_521_sha384_additionalinput[] = 0xc7,0x56,0xff,0x64,0x50,0x29,0xb2,0xb2 }; +__fips_constseg static const unsigned char p_521_sha384_int_returnedbits[] = { 0x16,0xf7,0x2a,0xa2,0x12,0x41,0xb9,0x58,0xac,0x9c,0x99,0xaa, @@ -3335,6 +3817,7 @@ static const unsigned char p_521_sha384_int_returnedbits[] = 0xd4,0x2c,0xa1 }; +__fips_constseg static const unsigned char p_521_sha384_entropyinputreseed[] = { 0x38,0xae,0xd1,0xbd,0xde,0xcc,0x88,0xc7,0x2d,0x39,0x68,0x1e, @@ -3342,6 +3825,7 @@ static const unsigned char p_521_sha384_entropyinputreseed[] = 0xf6,0xa9,0xea,0xf4,0x8b,0x43,0x6b,0xf7 }; +__fips_constseg static const unsigned char p_521_sha384_additionalinputreseed[] = { 0x6f,0xd8,0x16,0x55,0x9f,0xe8,0x71,0x65,0x83,0xf2,0xf5,0xaf, @@ -3349,6 +3833,7 @@ static const unsigned char p_521_sha384_additionalinputreseed[] = 0xda,0xda,0xde,0x4f,0xf0,0xfa,0xa3,0x33 }; +__fips_constseg static const unsigned char p_521_sha384_additionalinput2[] = { 0xd9,0xe2,0x19,0x2e,0x78,0x71,0x2f,0xec,0x45,0xcc,0x63,0x0e, @@ -3356,6 +3841,7 @@ static const unsigned char p_521_sha384_additionalinput2[] = 0x3e,0x1a,0x4c,0x69,0xcb,0xec,0xc6,0x33 }; +__fips_constseg static const unsigned char p_521_sha384_returnedbits[] = { 0x88,0x53,0x0c,0xa7,0x5c,0x3f,0x56,0x6a,0x0a,0x10,0xa5,0xac, @@ -3368,6 +3854,7 @@ static const unsigned char p_521_sha384_returnedbits[] = /* P-521 SHA-512 PR */ +__fips_constseg static const unsigned char p_521_sha512_pr_entropyinput[] = { 0xb7,0x8e,0x4a,0x70,0x59,0xf4,0xb4,0xfa,0x94,0xef,0xc7,0xe7, @@ -3375,12 +3862,14 @@ static const unsigned char p_521_sha512_pr_entropyinput[] = 0xee,0x1e,0x64,0x24,0x25,0xf4,0x1d,0xa6 }; +__fips_constseg static const unsigned char p_521_sha512_pr_nonce[] = { 0x46,0x15,0x8e,0x0c,0x97,0x3c,0x81,0x7b,0x2b,0x38,0xde,0x1a, 0x93,0x68,0x00,0x30 }; +__fips_constseg static const unsigned char p_521_sha512_pr_personalizationstring[] = { 0x05,0x12,0xdf,0xac,0xf9,0xf8,0xce,0xec,0x1e,0x98,0x91,0x6d, @@ -3388,6 +3877,7 @@ static const unsigned char p_521_sha512_pr_personalizationstring[] = 0x9a,0xa3,0xb5,0x54,0x63,0x74,0xf0,0xf2 }; +__fips_constseg static const unsigned char p_521_sha512_pr_additionalinput[] = { 0x04,0x8d,0xfc,0x7a,0xa2,0x25,0x99,0x6a,0xb0,0x17,0x7e,0xe8, @@ -3395,6 +3885,7 @@ static const unsigned char p_521_sha512_pr_additionalinput[] = 0xf0,0x57,0x69,0x7e,0x85,0x2a,0xa8,0x8b }; +__fips_constseg static const unsigned char p_521_sha512_pr_entropyinputpr[] = { 0xbb,0xa2,0x0b,0x9f,0xf2,0x01,0x4c,0x9a,0x20,0x87,0x75,0x69, @@ -3402,6 +3893,7 @@ static const unsigned char p_521_sha512_pr_entropyinputpr[] = 0x52,0x12,0x68,0xb8,0x90,0x87,0x0c,0x6f }; +__fips_constseg static const unsigned char p_521_sha512_pr_int_returnedbits[] = { 0x81,0x79,0xde,0xe3,0xe0,0x72,0xd8,0x86,0x39,0x42,0x4b,0x86, @@ -3412,6 +3904,7 @@ static const unsigned char p_521_sha512_pr_int_returnedbits[] = 0xe4,0x7a,0x01 }; +__fips_constseg static const unsigned char p_521_sha512_pr_additionalinput2[] = { 0x9d,0x9c,0xbd,0x7e,0x2d,0x33,0x41,0x63,0xb7,0x44,0x91,0xd0, @@ -3419,6 +3912,7 @@ static const unsigned char p_521_sha512_pr_additionalinput2[] = 0x85,0x47,0x06,0x9e,0x73,0x2b,0x85,0xb7 }; +__fips_constseg static const unsigned char p_521_sha512_pr_entropyinputpr2[] = { 0xcd,0x1e,0x0c,0x58,0xe9,0x65,0x44,0x95,0x7a,0x68,0xf1,0xe1, @@ -3426,6 +3920,7 @@ static const unsigned char p_521_sha512_pr_entropyinputpr2[] = 0x57,0x60,0x50,0x31,0x5f,0xf0,0x05,0xf7 }; +__fips_constseg static const unsigned char p_521_sha512_pr_returnedbits[] = { 0x5b,0x24,0x8e,0xab,0x1b,0x1b,0x86,0xe0,0x65,0x11,0x84,0x75, @@ -3438,6 +3933,7 @@ static const unsigned char p_521_sha512_pr_returnedbits[] = /* P-521 SHA-512 No PR */ +__fips_constseg static const unsigned char p_521_sha512_entropyinput[] = { 0x3d,0x1f,0x10,0x75,0x3c,0x9f,0x09,0xf2,0xe2,0x38,0x50,0x8e, @@ -3445,12 +3941,14 @@ static const unsigned char p_521_sha512_entropyinput[] = 0x5f,0xb2,0x0e,0x3b,0xaa,0x6b,0x2e,0xee }; +__fips_constseg static const unsigned char p_521_sha512_nonce[] = { 0x9d,0x59,0xbf,0xcb,0xcf,0x3f,0xe0,0xb1,0x2b,0x6f,0x3d,0xd8, 0x38,0x77,0xf6,0x1c }; +__fips_constseg static const unsigned char p_521_sha512_personalizationstring[] = { 0xf2,0x91,0xdb,0xef,0x70,0x9a,0x87,0x74,0xc4,0xf6,0x8e,0x09, @@ -3458,6 +3956,7 @@ static const unsigned char p_521_sha512_personalizationstring[] = 0x83,0xe8,0x66,0xd0,0x2f,0x49,0xef,0x63 }; +__fips_constseg static const unsigned char p_521_sha512_additionalinput[] = { 0x38,0x7c,0xdd,0x33,0xcd,0x09,0x12,0xc0,0xb8,0x73,0x72,0xdf, @@ -3465,6 +3964,7 @@ static const unsigned char p_521_sha512_additionalinput[] = 0xd5,0x90,0xe9,0x8c,0x66,0x8c,0x63,0x35 }; +__fips_constseg static const unsigned char p_521_sha512_int_returnedbits[] = { 0x7c,0xd6,0xd8,0xbb,0x12,0x5d,0xaf,0x65,0x65,0xd2,0x20,0x58, @@ -3475,6 +3975,7 @@ static const unsigned char p_521_sha512_int_returnedbits[] = 0xb2,0x66,0xba }; +__fips_constseg static const unsigned char p_521_sha512_entropyinputreseed[] = { 0xd5,0x51,0xf0,0x88,0xb6,0xa5,0x26,0x8c,0x34,0x82,0xd3,0xa4, @@ -3482,6 +3983,7 @@ static const unsigned char p_521_sha512_entropyinputreseed[] = 0x9c,0xcf,0x3e,0xa9,0xc2,0x6e,0x3a,0x3e }; +__fips_constseg static const unsigned char p_521_sha512_additionalinputreseed[] = { 0x22,0xce,0x9f,0x3b,0x36,0x8d,0x4e,0xe2,0xe5,0xff,0xaf,0x72, @@ -3489,6 +3991,7 @@ static const unsigned char p_521_sha512_additionalinputreseed[] = 0x8e,0xb0,0x0a,0x05,0xeb,0xd4,0xfd,0x58 }; +__fips_constseg static const unsigned char p_521_sha512_additionalinput2[] = { 0x2f,0x55,0x03,0xe2,0x5f,0x58,0xf4,0xc8,0xf9,0x98,0x79,0x9a, @@ -3496,6 +3999,7 @@ static const unsigned char p_521_sha512_additionalinput2[] = 0xc3,0xcf,0x3e,0x66,0xf2,0x2f,0xd5,0xb6 }; +__fips_constseg static const unsigned char p_521_sha512_returnedbits[] = { 0x2e,0xbf,0x98,0xf9,0x85,0x27,0x8b,0xff,0x36,0xb9,0x40,0x0b, diff --git a/fips/rand/fips_randtest.c b/fips/rand/fips_randtest.c index 7701565838..e8b52dba2a 100644 --- a/fips/rand/fips_randtest.c +++ b/fips/rand/fips_randtest.c @@ -137,11 +137,13 @@ typedef struct unsigned char R[16]; } AES_PRNG_MCT; -static unsigned char aes_128_mct_key[16] = +__fips_constseg +static const unsigned char aes_128_mct_key[16] = {0x9f,0x5b,0x51,0x20,0x0b,0xf3,0x34,0xb5, 0xd8,0x2b,0xe8,0xc3,0x72,0x55,0xc8,0x48}; -static AES_PRNG_MCT aes_128_mct_tv = { +__fips_constseg +static const AES_PRNG_MCT aes_128_mct_tv = { /* DT */ {0x63,0x76,0xbb,0xe5,0x29,0x02,0xba,0x3b, 0x67,0xc9,0x25,0xfa,0x70,0x1f,0x11,0xac}, @@ -153,12 +155,14 @@ static AES_PRNG_MCT aes_128_mct_tv = { 0xe4,0x57,0x90,0xd5,0xc3,0xfc,0x9b,0x73} }; -static unsigned char aes_192_mct_key[24] = +__fips_constseg +static const unsigned char aes_192_mct_key[24] = {0xb7,0x6c,0x34,0xd1,0x09,0x67,0xab,0x73, 0x4d,0x5a,0xd5,0x34,0x98,0x16,0x0b,0x91, 0xbc,0x35,0x51,0x16,0x6b,0xae,0x93,0x8a}; -static AES_PRNG_MCT aes_192_mct_tv = { +__fips_constseg +static const AES_PRNG_MCT aes_192_mct_tv = { /* DT */ {0x84,0xce,0x22,0x7d,0x91,0x5a,0xa3,0xc9, 0x84,0x3c,0x0a,0xb3,0xa9,0x63,0x15,0x52}, @@ -170,13 +174,15 @@ static AES_PRNG_MCT aes_192_mct_tv = { 0xdd,0x86,0x20,0x32,0x8a,0x29,0x6f,0x47} }; -static unsigned char aes_256_mct_key[32] = +__fips_constseg +static const unsigned char aes_256_mct_key[32] = {0x9b,0x05,0xc8,0x68,0xff,0x47,0xf8,0x3a, 0xa6,0x3a,0xa8,0xcb,0x4e,0x71,0xb2,0xe0, 0xb8,0x7e,0xf1,0x37,0xb6,0xb4,0xf6,0x6d, 0x86,0x32,0xfc,0x1f,0x5e,0x1d,0x1e,0x50}; -static AES_PRNG_MCT aes_256_mct_tv = { +__fips_constseg +static const AES_PRNG_MCT aes_256_mct_tv = { /* DT */ {0x31,0x6e,0x35,0x9a,0xb1,0x44,0xf0,0xee, 0x62,0x6d,0x04,0x46,0xe0,0xa3,0x92,0x4c}, diff --git a/fips/rsa/fips_rsa_selftest.c b/fips/rsa/fips_rsa_selftest.c index df03b6ade8..045ec51d64 100644 --- a/fips/rsa/fips_rsa_selftest.c +++ b/fips/rsa/fips_rsa_selftest.c @@ -61,6 +61,7 @@ #ifdef OPENSSL_FIPS +__fips_constseg static const unsigned char rsa_test_2048_n[] = { 0xDB,0x10,0x1A,0xC2,0xA3,0xF1,0xDC,0xFF,0x13,0x6B,0xED,0x44, 0xDF,0xF0,0x02,0x6D,0x13,0xC7,0x88,0xDA,0x70,0x6B,0x54,0xF1, @@ -85,9 +86,11 @@ static const unsigned char rsa_test_2048_n[] = { 0xD6,0xB0,0xE2,0x62,0x8F,0x74,0x26,0xC2,0x0C,0xD3,0x9A,0x17, 0x47,0xE6,0x8E,0xAB }; +__fips_constseg static const unsigned char rsa_test_2048_e[] = { 0x01,0x00,0x01 }; +__fips_constseg static const unsigned char rsa_test_2048_d[] = { 0x52,0x41,0xF4,0xDA,0x7B,0xB7,0x59,0x55,0xCA,0xD4,0x2F,0x0F, 0x3A,0xCB,0xA4,0x0D,0x93,0x6C,0xCC,0x9D,0xC1,0xB2,0xFB,0xFD, @@ -112,6 +115,7 @@ static const unsigned char rsa_test_2048_d[] = { 0xA7,0x1D,0xD9,0x1E,0x06,0xCD,0xE8,0xBA,0x2C,0x8C,0x69,0x32, 0xEA,0xBE,0x60,0x71 }; +__fips_constseg static const unsigned char rsa_test_2048_p[] = { 0xFA,0xAC,0xE1,0x37,0x5E,0x32,0x11,0x34,0xC6,0x72,0x58,0x2D, 0x91,0x06,0x3E,0x77,0xE7,0x11,0x21,0xCD,0x4A,0xF8,0xA4,0x3F, @@ -125,6 +129,7 @@ static const unsigned char rsa_test_2048_p[] = { 0x0A,0x3B,0xB3,0xAF,0xE2,0x75,0x36,0x04,0xAC,0x56,0xA0,0xAB, 0x52,0xDE,0xCE,0xDD,0x2C,0x28,0x77,0x03 }; +__fips_constseg static const unsigned char rsa_test_2048_q[] = { 0xDF,0xB7,0x52,0xB6,0xD7,0xC0,0xE2,0x96,0xE7,0xC9,0xFE,0x5D, 0x71,0x5A,0xC4,0x40,0x96,0x2F,0xE5,0x87,0xEA,0xF3,0xA5,0x77, @@ -138,6 +143,7 @@ static const unsigned char rsa_test_2048_q[] = { 0x5B,0x74,0x69,0x73,0x87,0x95,0x05,0x07,0xBE,0x45,0x07,0x17, 0x7E,0x4A,0x69,0x22,0xF3,0xDB,0x05,0x39 }; +__fips_constseg static const unsigned char rsa_test_2048_dmp1[] = { 0x5E,0xD8,0xDC,0xDA,0x53,0x44,0xC4,0x67,0xE0,0x92,0x51,0x34, 0xE4,0x83,0xA5,0x4D,0x3E,0xDB,0xA7,0x9B,0x82,0xBB,0x73,0x81, @@ -151,6 +157,7 @@ static const unsigned char rsa_test_2048_dmp1[] = { 0xE7,0x42,0x51,0xA9,0xC2,0x18,0xB1,0x58,0xB1,0x50,0x91,0xB8, 0x61,0x41,0xB6,0xA9,0xCE,0xD4,0x7C,0xBB }; +__fips_constseg static const unsigned char rsa_test_2048_dmq1[] = { 0x54,0x09,0x1F,0x0F,0x03,0xD8,0xB6,0xC5,0x0C,0xE8,0xB9,0x9E, 0x0C,0x38,0x96,0x43,0xD4,0xA6,0xC5,0x47,0xDB,0x20,0x0E,0xE5, @@ -164,6 +171,7 @@ static const unsigned char rsa_test_2048_dmq1[] = { 0x1C,0x7B,0x8C,0x29,0x13,0xA3,0x0C,0xB2,0xAD,0xEC,0x6C,0x0F, 0x8D,0x27,0x12,0x7B,0x48,0xB2,0xDB,0x31 }; +__fips_constseg static const unsigned char rsa_test_2048_iqmp[] = { 0x8D,0x1B,0x05,0xCA,0x24,0x1F,0x0C,0x53,0x19,0x52,0x74,0x63, 0x21,0xFA,0x78,0x46,0x79,0xAF,0x5C,0xDE,0x30,0xA4,0x6C,0x20, @@ -197,8 +205,10 @@ static int setrsakey(RSA *k) * kat_tbs. */ +__fips_constseg static const unsigned char kat_tbs[] = "OpenSSL FIPS 140-2 Public Key RSA KAT"; +__fips_constseg static const unsigned char kat_RSA_PSS_SHA256[] = { 0x51,0x4F,0x0B,0x8A,0xE6,0x7F,0xF0,0x39,0x9B,0x5F,0x21,0x26, 0x99,0x71,0xDC,0x64,0x5A,0x60,0x9B,0xFB,0xB9,0x48,0xE3,0xD4, diff --git a/fips/rsa/fips_rsa_sign.c b/fips/rsa/fips_rsa_sign.c index 4e1f27d48d..013333e0b4 100644 --- a/fips/rsa/fips_rsa_sign.c +++ b/fips/rsa/fips_rsa_sign.c @@ -74,26 +74,31 @@ /* Standard encodings including NULL parameter */ +__fips_constseg static const unsigned char sha1_bin[] = { 0x30, 0x21, 0x30, 0x09, 0x06, 0x05, 0x2b, 0x0e, 0x03, 0x02, 0x1a, 0x05, 0x00, 0x04, 0x14 }; +__fips_constseg static const unsigned char sha224_bin[] = { 0x30, 0x2d, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x04, 0x05, 0x00, 0x04, 0x1c }; +__fips_constseg static const unsigned char sha256_bin[] = { 0x30, 0x31, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0x04, 0x20 }; +__fips_constseg static const unsigned char sha384_bin[] = { 0x30, 0x41, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, 0x05, 0x00, 0x04, 0x30 }; +__fips_constseg static const unsigned char sha512_bin[] = { 0x30, 0x51, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x03, 0x05, 0x00, 0x04, 0x40 @@ -103,27 +108,32 @@ static const unsigned char sha512_bin[] = { * using this format but do tolerate received signatures of this form. */ -static unsigned char sha1_nn_bin[] = { +__fips_constseg +static const unsigned char sha1_nn_bin[] = { 0x30, 0x1f, 0x30, 0x07, 0x06, 0x05, 0x2b, 0x0e, 0x03, 0x02, 0x1a, 0x04, 0x14 }; -static unsigned char sha224_nn_bin[] = { +__fips_constseg +static const unsigned char sha224_nn_bin[] = { 0x30, 0x2b, 0x30, 0x0b, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x04, 0x04, 0x1c }; -static unsigned char sha256_nn_bin[] = { +__fips_constseg +static const unsigned char sha256_nn_bin[] = { 0x30, 0x2f, 0x30, 0x0b, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x04, 0x20 }; -static unsigned char sha384_nn_bin[] = { +__fips_constseg +static const unsigned char sha384_nn_bin[] = { 0x30, 0x3f, 0x30, 0x0b, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, 0x04, 0x30 }; -static unsigned char sha512_nn_bin[] = { +__fips_constseg +static const unsigned char sha512_nn_bin[] = { 0x30, 0x4f, 0x30, 0x0b, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x03, 0x04, 0x40 }; diff --git a/fips/sha/fips_sha1_selftest.c b/fips/sha/fips_sha1_selftest.c index 3c8ca2be20..62680bfff8 100644 --- a/fips/sha/fips_sha1_selftest.c +++ b/fips/sha/fips_sha1_selftest.c @@ -63,6 +63,7 @@ static const unsigned char test[][60]= "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq" }; +__fips_constseg static const unsigned char ret[][SHA_DIGEST_LENGTH]= { { 0xda,0x39,0xa3,0xee,0x5e,0x6b,0x4b,0x0d,0x32,0x55, diff --git a/util/pl/VC-32.pl b/util/pl/VC-32.pl index a665b562e1..e98eb1e1b9 100644 --- a/util/pl/VC-32.pl +++ b/util/pl/VC-32.pl @@ -162,7 +162,7 @@ $app_cflag.=" /Zi /Fd\$(TMP_D)/app"; $lib_cflag.=" /Zi /Fd\$(TMP_D)/lib"; $lflags.=" /debug"; -$lflags.=" /fixed" if $fips; +$lflags.=" /fixed" if ($fips && $FLAVOR !~ /WIN64/); $obj='.obj'; $asm_suffix='.asm';