/mcuboot-3.5.0/ext/tinycrypt/tests/ |
D | test_ecc_dh.c | 75 unsigned int pub[2*NUM_ECC_WORDS]; in ecdh_vectors() 92 uint8_t pub_bytes[2*NUM_ECC_BYTES]; in ecdh_vectors() 93 uECC_vli_nativeToBytes(pub_bytes, 2*NUM_ECC_BYTES, pub); in ecdh_vectors() 133 "2beedb04b05c6988f6a67500bb813faf2cae0d580c9253b6339e4a3337bb6c08", in cavp_ecdh() 147 "2c4bde40214fcc3bfc47d4cf434b629acbe9157f8fd0282540331de7942cf09d", in cavp_ecdh() 163 "2db4540d50230756158abf61d9835712b6486c74312183ccefcaef2797b7674d", in cavp_ecdh() 168 "2c91c61f33adfe9311c942fdbff6ba47020feff416b7bb63cec13faf9b099954", in cavp_ecdh() 210 "2d457b78b4614132477618a5b077965ec90730a8c81a1c75d6d4ec68005d67ec", in cavp_ecdh() 230 "2adae4a138a239dcd93c243a3803c3e4cf96e37fe14e6a9b717be9599959b11c", in cavp_ecdh() 231 "2e277ec30f5ea07d6ce513149b9479b96e07f4b6913b1b5c11305c1444a1bc0b", in cavp_ecdh() [all …]
|
D | test_ecc_utils.c | 92 if (buflen < hexlen / 2 + hexlen % 2) in hex2bin() 98 if (hexlen % 2) in hex2bin() 109 for (size_t i = 0; i < hexlen / 2; i++) in hex2bin() 111 dec = hex2int(hex[2 * i]); in hex2bin() 118 dec = hex2int(hex[ 2 * i + 1]); in hex2bin() 125 return hexlen / 2 + hexlen % 2; in hex2bin() 140 if (0 > (padding = 2 * num_bytes - strlen(str))) in string2scalar() 142 printf("Error: 2 * num_bytes(%d) < strlen(hex) (%zu)\n", in string2scalar() 143 2 * num_bytes, strlen(str)); in string2scalar() 147 memset(tmp, 0, padding / 2); in string2scalar() [all …]
|
D | test_ecc_dsa.c | 84 unsigned int sig[2 * NUM_ECC_WORDS]; in sign_vectors() 85 uint8_t sig_bytes[2 * NUM_ECC_BYTES]; in sign_vectors() 191 "2e7625a48874d86c9e467f890aaa7cd6ebdf71c0102bfdcfa24565d6af3fdce9", in cavp_sign() 214 "2dd46436cc0415f280c562bebb83a23e639e476a02ec8cff7ea06cd12c86dcc3adefbf1a9e" in cavp_sign() 289 "2d365a1eef25ead579cc9a069b6abc1b16b81c35f18785ce26a10ba6d1381185", in cavp_sign() 308 "2f9e2b4e9f747c657f705bffd124ee178bbc5391c86d056717b140c153570fd9", in cavp_sign() 328 "2bf3a80bc04faa35ebecc0f4864ac02d349f6f126e0f988501b8d3075409a26c", in cavp_sign() 348 unsigned int pub[2 * NUM_ECC_WORDS]; in vrfy_vectors() 349 uint8_t pub_bytes[2 * NUM_ECC_BYTES]; in vrfy_vectors() 350 unsigned int sig[2 * NUM_ECC_WORDS]; in vrfy_vectors() [all …]
|
/mcuboot-3.5.0/ext/tinycrypt/lib/include/tinycrypt/ |
D | ccm_mode.h | 45 * 2) Non-empty payload and empty associated data (it encrypts and 51 * between 0 and (2^16 - 2^8) bytes. 69 * 2) call tc_ccm_mode_encrypt to encrypt data and generate tag. 84 /* max additional authenticated size in bytes: 2^16 - 2^8 = 65280 */ 87 /* max message size in bytes: 2^(8L) = 2^16 = 65536 */ 140 * counter is 2 bytes long 142 * 0-2 bits: used to represent the value of q-1 149 * length(mac length) is 2 bytes long 151 * 0-2 bits: used to represent the value of q-1 152 * 3-5 bits: mac length (encoded as: (mlen-2)/2) [all …]
|
/mcuboot-3.5.0/ci/fih_test_docker/ |
D | fi_tester_gdb.sh | 20 local SKIP_SIZE=$2 25 …B $AXF_FILE --batch -ex "info line *$SKIP_ADDRESS" | sed "s/Line \([0-9]*\).*\"\(.*\)\".*/\2:\1/g") 65 echo -n '.' 1>&2 101 echo "" 1>&2 102 echo "Boot success: address: $SKIP_ADDRESS skipped: $SKIP_SIZE" 1>&2 103 …-eabi-objdump -d $IMAGE_DIR/bl2.axf --start-address=$SKIP_ADDRESS -S | tail -n +7 | head -n 14 1>&2 104 echo "" 1>&2 105 echo "" 1>&2 144 SKIP=2 154 SKIP="$2" [all …]
|
D | run_fi_test.sh | 21 DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd ) 28 SKIP_SIZES=$2 47 echo "Failed to damage image $IMAGE with param $DAMAGE_TYPE" 1>&2 51 python3 $DIR/damage_image.py -i $IMAGEDIR/$BACKUP_IMAGE_NAME -o $IMAGE $DAMAGE_PARAM 1>&2 62 …REGIONS=$(sed "N;s/\(0x[[:xdigit:]]*\).*START\n\(0x[[:xdigit:]]*\).*END.*/\1,\2/g;P;D" $PWD/fih_ma… 64 REGIONS=$(echo "$REGIONS" | tail -n+2) 69 END=$(echo $REGION | cut -d"," -f 2) 85 echo "Run tests with skip size $size" 1>&2
|
/mcuboot-3.5.0/ext/mbedtls-asn1/include/mbedtls/ |
D | oid.h | 51 #define MBEDTLS_OID_X509_EXT_KEY_USAGE (1 << 2) 69 #define MBEDTLS_OID_ISO_MEMBER_BODIES "\x2a" /* {iso(1) member-body(2)} */ 71 #define MBEDTLS_OID_ISO_CCITT_DS "\x55" /* {joint-iso-ccitt(2) ds(5)} */ 72 #define MBEDTLS_OID_ISO_ITU_COUNTRY "\x60" /* {joint-iso-itu-t(2) country(16)}… 80 … MBEDTLS_OID_ORG_RSA_DATA_SECURITY /* {iso(1) member-body(2) us(840) rsadsi(113549)} */ 102 …COUNTRY MBEDTLS_OID_COUNTRY_US MBEDTLS_OID_ORGANIZATION /* {joint-iso-itu-t(2) country(16) us(840)… 105 … MBEDTLS_OID_ISO_ITU_US_ORG MBEDTLS_OID_ORG_GOV /* {joint-iso-itu-t(2) country(16) us(840)… 108 …ID_ISO_ITU_US_ORG MBEDTLS_OID_ORG_NETSCAPE /* Netscape OID {joint-iso-itu-t(2) country(16) us(840)… 111 …MBEDTLS_OID_ISO_CCITT_DS "\x1D" /**< id-ce OBJECT IDENTIFIER ::= {joint-iso-ccitt(2) ds(5) 29} */ 113 #define MBEDTLS_OID_NIST_ALG MBEDTLS_OID_GOV "\x03\x04" /** { joint-iso-itu-t(2)… [all …]
|
D | error.h | 57 * ERROR 2 0x006E 0x0001 63 * BASE64 2 0x002A-0x002C 66 * DES 2 0x0032-0x0032 0x0033-0x0033 83 * CHACHAPOLY 2 0x0054-0x0056 84 * PLATFORM 2 0x0070-0x0072 90 * X509 2 20 91 * PKCS5 2 4 (Started from top) 98 * SSL 5 2 (Started from 0x5F00)
|
/mcuboot-3.5.0/ext/tinycrypt/lib/source/ |
D | ecc.c | 84 return 2 * curve->num_bytes; in uECC_curve_public_key_size() 228 return (!equal - 2 * neg); in uECC_vli_cmp() 258 /* Computes result = left * right. Result must be 2 * num_words long. */ 281 for (k = num_words; k < num_words * 2 - 1; ++k) { in uECC_vli_mult() 291 result[num_words * 2 - 1] = r0; in uECC_vli_mult() 318 /* Computes result = product % mod, where product is 2N words long. */ 323 uECC_word_t mod_multiple[2 * NUM_ECC_WORDS]; in uECC_vli_mmod() 324 uECC_word_t tmp[2 * NUM_ECC_WORDS]; in uECC_vli_mmod() 325 uECC_word_t *v[2] = {tmp, product}; in uECC_vli_mmod() 329 bitcount_t shift = (num_words * 2 * uECC_WORD_BITS) - in uECC_vli_mmod() [all …]
|
D | cmac_mode.c | 38 /* max number of calls until change the key (2^48).*/ 42 * gf_wrap -- In our implementation, GF(2^128) is represented as a 16 byte 46 * X^128 + X^7 + X^2 + X + 1, 48 * which leads to the reduction formula X^128 = X^7 + X^2 + X + 1. Indeed, 49 * since 0 = (X^128 + X^7 + X^2 + 1) mod (X^128 + X^7 + X^2 + X + 1) and since 50 * addition of polynomials with coefficients in Z/Z(2) is just XOR, we can 53 * X^128 = (X^7 + X^2 + X + 1) mod (X^128 + X^7 + X^2 + X + 1) 58 * This gets used in the following way. Doubling in GF(2^128) is just a left 60 * case, the relation X^128 = X^7 + X^2 + X + 1 says that the high order bit 62 * X^7 + X^2 + X + 1 <--> 0x87 to the low order 128 bits. Since addition [all …]
|
D | aes_decrypt.c | 75 out[0] = multe(in[0]) ^ multb(in[1]) ^ multd(in[2]) ^ mult9(in[3]); in mult_row_column() 76 out[1] = mult9(in[0]) ^ multe(in[1]) ^ multb(in[2]) ^ multd(in[3]); in mult_row_column() 77 out[2] = multd(in[0]) ^ mult9(in[1]) ^ multe(in[2]) ^ multb(in[3]); in mult_row_column() 78 out[3] = multb(in[0]) ^ multd(in[1]) ^ mult9(in[2]) ^ multe(in[3]); in mult_row_column() 87 mult_row_column(&t[2*Nb], s+(2*Nb)); in inv_mix_columns() 95 s[2] ^= (uint8_t)(k[0] >> 8); s[3] ^= (uint8_t)(k[0]); in add_round_key() 98 s[8] ^= (uint8_t)(k[2] >> 24); s[9] ^= (uint8_t)(k[2] >> 16); in add_round_key() 99 s[10] ^= (uint8_t)(k[2] >> 8); s[11] ^= (uint8_t)(k[2]); in add_round_key() 122 t[0] = s[0]; t[1] = s[13]; t[2] = s[10]; t[3] = s[7]; in inv_shift_rows() 124 t[8] = s[8]; t[9] = s[5]; t[10] = s[2]; t[11] = s[15]; in inv_shift_rows()
|
D | aes_encrypt.c | 87 (k[Nb*i+2]<<8) | (k[Nb*i+3]); in tc_aes128_set_encrypt_key() 104 s[2] ^= (uint8_t)(k[0] >> 8); s[3] ^= (uint8_t)(k[0]); in add_round_key() 107 s[8] ^= (uint8_t)(k[2] >> 24); s[9] ^= (uint8_t)(k[2] >> 16); in add_round_key() 108 s[10] ^= (uint8_t)(k[2] >> 8); s[11] ^= (uint8_t)(k[2]); in add_round_key() 126 out[0] = _double_byte(in[0]) ^ triple(in[1]) ^ in[2] ^ in[3]; in mult_row_column() 127 out[1] = in[0] ^ _double_byte(in[1]) ^ triple(in[2]) ^ in[3]; in mult_row_column() 128 out[2] = in[0] ^ in[1] ^ _double_byte(in[2]) ^ triple(in[3]); in mult_row_column() 129 out[3] = triple(in[0]) ^ in[1] ^ in[2] ^ _double_byte(in[3]); in mult_row_column() 138 mult_row_column(&t[2 * Nb], s + (2 * Nb)); in mix_columns() 151 t[0] = s[0]; t[1] = s[5]; t[2] = s[10]; t[3] = s[15]; in shift_rows() [all …]
|
D | hmac_prng.c | 46 * SP800-90A specifies a maximum of 2^35 bits (i.e., 2^32 bytes). 52 * SP800-90A specifies a maximum of 2^35 bits (i.e., 2^32 bytes). 58 * SP800-90A specifies a maximum of 2^35 bits (i.e., 2^32 bytes). 64 * TinyCrypt accepts up to (2^32 - 1) which is the maximal value of 65 * a 32-bit unsigned int variable, while SP800-90A specifies a maximum of 2^48. 71 * SP800-90A specifies a maximum up to 2^19.
|
D | ccm_mode.c | 73 dlen += 2; i = 2; in ccm_cbc_mac() 91 * 2 bytes of the nonce. 116 /* select the last 2 bytes of the nonce to be incremented */ in ccm_ctr_mode() 161 b[0] = ((alen > 0) ? 0x40:0) | (((c->mlen - 2) / 2 << 3)) | (1); in tc_ccm_generation_encryption() 180 b[0] = 1; /* q - 1 = 2 - 1 = 1 */ in tc_ccm_generation_encryption() 222 b[0] = 1; /* q - 1 = 2 - 1 = 1 */ in tc_ccm_decryption_verification() 242 b[0] = ((alen > 0) ? 0x40:0)|(((c->mlen - 2) / 2 << 3)) | (1); in tc_ccm_decryption_verification()
|
/mcuboot-3.5.0/docs/ |
D | Gemfile.lock | 5 concurrent-ruby (~> 1.0, >= 1.0.2) 6 i18n (>= 1.6, < 2) 10 public_suffix (>= 2.0.2, < 6.0) 17 concurrent-ruby (1.2.2) 30 faraday-net_http (3.0.2) 46 jekyll-optional-front-matter (= 0.3.2) 52 jekyll-sass-converter (= 1.5.2) 71 kramdown (= 2.3.2) 86 activesupport (>= 2) 95 i18n (>= 0.7, < 2) [all …]
|
/mcuboot-3.5.0/boot/cypress/libs/watchdog/ |
D | watchdog.c | 46 // ((2^16 * 2) + (2^16 - 1)) * .030518 ms 60 // WDT Reset Period (timeout_ms) = .030518 ms * (2 * 2^(16 - ignore_bits) + match) 62 // match range: 0 - (2^(16 - ignore_bits) - 1) 66 {1001, 750}, // 2 bits: min period: 1001ms, max period: 1499ms, round up from 750+ms 75 {2, 2}, // 11 bits: min period: 2ms, max period: 2ms 99 // match = (timeout_ms / .030518 ms) - (2 * 2^(16 - ignore_bits)) in _cy_wdg_timeout_to_match()
|
/mcuboot-3.5.0/.github/workflows/ |
D | fih_tests.yaml | 21 - "RELEASE 2,4,6 SIGNATURE" 22 - "RELEASE 2,4,6 SIGNATURE LOW" 23 - "RELEASE 2,4,6 SIGNATURE MEDIUM" 27 - "MINSIZEREL 2,4,6 SIGNATURE" 28 - "MINSIZEREL 2,4,6 SIGNATURE LOW" 29 - "MINSIZEREL 2,4,6 SIGNATURE MEDIUM"
|
/mcuboot-3.5.0/ |
D | .travis.yml-disabled | 12 env: BUILD_TYPE=RELEASE SKIP_SIZE=2,4,6,8,10 TEST=fih-tests DAMAGE_TYPE=SIGNATURE 16 … env: BUILD_TYPE=RELEASE SKIP_SIZE=2,4,6,8,10 FIH_LEVEL=LOW TEST=fih-tests DAMAGE_TYPE=SIGNATURE 20 … env: BUILD_TYPE=RELEASE SKIP_SIZE=2,4,6,8,10 FIH_LEVEL=MEDIUM TEST=fih-tests DAMAGE_TYPE=SIGNATURE 24 env: BUILD_TYPE=MINSIZEREL SKIP_SIZE=2,4,6 TEST=fih-tests DAMAGE_TYPE=SIGNATURE 28 env: BUILD_TYPE=MINSIZEREL SKIP_SIZE=2,4,6 FIH_LEVEL=LOW TEST=fih-tests DAMAGE_TYPE=SIGNATURE 32 … env: BUILD_TYPE=MINSIZEREL SKIP_SIZE=2,4,6 FIH_LEVEL=MEDIUM TEST=fih-tests DAMAGE_TYPE=SIGNATURE 50 # env: BUILD_TYPE=MINSIZEREL SKIP_SIZE=2,4,6 TEST=fih-tests DAMAGE_TYPE=IMAGE_HASH
|
D | Cargo.toml | 6 # compiles in about half the time, but runs about 5-6 times slower. 2 8 # Use 2 in case that makes the code slightly more debuggable. 10 opt-level = 2 13 opt-level = 2
|
/mcuboot-3.5.0/ext/fiat/ |
D | README.md | 15 "unsaturated arithmetic modulo 2^255-19 using 10 limbs of radix 2^25.5 in 32-bit 20 The 64-bit implementation uses 5 limbs of radix 2^51 with instruction scheduling 32 2^256 - 2^224 + 2^192 + 2^96 - 1". Again, everything except for the prime is
|
/mcuboot-3.5.0/boot/cypress/MCUBootApp/ |
D | cy_serial_flash_prog.c | 61 * 2) Placing it at an absolute location via a the linker script 70 * This data is used to populate the table of contents part 2. When present, it is used by the boot 81 0x01211220, /* Offset=0x0004: Magic Number (TOC Part 2, ID) */ 86 …[126] = 0x000002C2, /* Offset=0x01F8: Bits[ 1: 0] CLOCK_CONFIG (0=8MHz, 1=25MHz, 2=50MHz, 3=10… 87 … Bits[ 4: 2] LISTEN_WINDOW (0=20ms, 1=10ms, 2=1ms, 3=0ms, 4=100ms) 88 … Bits[ 6: 5] SWJ_PINS_CTL (0/1/3=Disable SWJ, 2=Enable SWJ) 89 … Bits[ 8: 7] APP_AUTHENTICATION (0/2/3=Enable, 1=Disable) 91 … 0x3BB30000 /* Offset=0x01FC: CRC16-CCITT (the upper 2 bytes contain the CRC and the lower 2 b…
|
/mcuboot-3.5.0/ext/fiat/src/ |
D | curve25519.h | 5 /* s = 0x8000000000000000000000000000000000000000000000000000000000000000 (from "2^255") */ 21 // fe means field element. Here the field is \Z/(2^255-19). An element t, 22 // entries t[0]...t[9], represents the integer t[0]+2^26 t[1]+2^51 t[2]+2^77 23 // t[3]+2^102 t[4]+...+2^230 t[9]. 24 // fe limbs are bounded by 1.125*2^26,1.125*2^25,1.125*2^26,1.125*2^25,etc. 28 // fe_loose limbs are bounded by 3.375*2^26,3.375*2^25,3.375*2^26,3.375*2^25,etc. 35 // satisfying -x^2 + y^2 = 1 + d x^2y^2 42 // ge_precomp (Duif): (y+x,y-x,2dxy) 198 uint64_t x8 = ((uint64_t)(arg1[9]) * ((arg2[2]) * (uint32_t)UINT8_C(0x13))); in fiat_25519_carry_mul() 207 uint64_t x17 = ((uint64_t)(arg1[8]) * ((arg2[2]) * (uint32_t)UINT8_C(0x13))); in fiat_25519_carry_mul() [all …]
|
/mcuboot-3.5.0/testplan/mynewt/ |
D | key_rsa.pem | 4 pQt3Cl/2C500j8P0kferKBJS3LuykoCY4hMz58MqHCeY/P8H210W0lDBjhL6lZhR 8 2UVByZ52LyVAWnaW9yAaZkz5CDose7nvhNoYZbnb50Ckhi588327/XvDBQZkjsKM 15 2wxw1O24uE1qN4Eh0UrLDvN07nKRJ6V9az+zSW3EAxwwUDWBIFL0pM8xAoGBAOJi 16 2cbIfHXEpt46aDEN7BwBog+8KL5Mima13zN8Melu6WvhB69JGG8IlUstMPPAq6uL
|
/mcuboot-3.5.0/boot/bootutil/src/ |
D | image_rsa.c | 117 * v2.2, section 9.1.2, with many parameters required to have fixed 118 * values. RSASSA-PSS-VERIFY RFC8017 section 8.1.2 147 * PKCS #1 v2.2, 9.1.2 EMSA-PSS-Verify in bootutil_cmp_rsasig() 156 * 32-bit processor, which is far less than the 2^61-1 limit of in bootutil_cmp_rsasig() 160 /* Step 2. mHash is passed in as 'hash', with hLen the hlen in bootutil_cmp_rsasig() 163 /* Step 3. if emLen < hLen + sLen + 2, inconsistent and stop. in bootutil_cmp_rsasig() 205 /* Step 10. If the emLen - hLen - sLen - 2 leftmost octets of DB in bootutil_cmp_rsasig()
|
/mcuboot-3.5.0/scripts/imgtool/keys/ |
D | rsa.py | 119 len_N = (b[off + 2] << 8) + b[off + 3] + 4 123 len_E = b[off + 2] + 4 127 len_D = (b[off + 2] << 8) + b[off + 3] + 4 131 len_P = b[off + 2] + 3 135 len_Q = b[off + 2] + 3 138 b[2] = (off - 4) >> 8
|