/mbedtls-3.6.0/tests/data_files/dir1/ |
D | test-ca.crt | 15 00:c0:df:37:fc:17:bb:e0:96:9d:3f:86:de:96:32: 22 71:f1:bd:83:d9:3f:d6:a5:e2:3c:2a:8f:ef:27:60: 23 c3:c6:9f:cb:ba:ec:60:7d:b7:e6:84:32:be:4f:fb: 27 79:a4:b2:b5:2e:12:f9:84:17:f0:62:6f:27:3e:13: 28 58:b1:54:0d:21:9a:73:37:a1:30:cf:6f:92:dc:f6: 31 ab:e9:c3:f2:cf:87:96:8f:80:02:32:9e:99:58:6f: 38 B4:5A:E4:A5:B3:DE:D2:52:F6:B9:D5:A6:95:0F:EB:3E:BC:C7:FD:FF 40 keyid:B4:5A:E4:A5:B3:DE:D2:52:F6:B9:D5:A6:95:0F:EB:3E:BC:C7:FD:FF 47 32:89:be:63:47:53:ff:b6:be:f1:2e:8c:54:c0:99:3f:a0:b9: 48 37:23:72:5f:0d:46:59:8f:d8:47:cd:97:4c:9f:07:0c:12:62: [all …]
|
/mbedtls-3.6.0/tests/data_files/dir2/ |
D | test-ca.crt | 15 00:c0:df:37:fc:17:bb:e0:96:9d:3f:86:de:96:32: 22 71:f1:bd:83:d9:3f:d6:a5:e2:3c:2a:8f:ef:27:60: 23 c3:c6:9f:cb:ba:ec:60:7d:b7:e6:84:32:be:4f:fb: 27 79:a4:b2:b5:2e:12:f9:84:17:f0:62:6f:27:3e:13: 28 58:b1:54:0d:21:9a:73:37:a1:30:cf:6f:92:dc:f6: 31 ab:e9:c3:f2:cf:87:96:8f:80:02:32:9e:99:58:6f: 38 B4:5A:E4:A5:B3:DE:D2:52:F6:B9:D5:A6:95:0F:EB:3E:BC:C7:FD:FF 40 keyid:B4:5A:E4:A5:B3:DE:D2:52:F6:B9:D5:A6:95:0F:EB:3E:BC:C7:FD:FF 47 32:89:be:63:47:53:ff:b6:be:f1:2e:8c:54:c0:99:3f:a0:b9: 48 37:23:72:5f:0d:46:59:8f:d8:47:cd:97:4c:9f:07:0c:12:62: [all …]
|
/mbedtls-3.6.0/tests/data_files/dir3/ |
D | test-ca.crt | 15 00:c0:df:37:fc:17:bb:e0:96:9d:3f:86:de:96:32: 22 71:f1:bd:83:d9:3f:d6:a5:e2:3c:2a:8f:ef:27:60: 23 c3:c6:9f:cb:ba:ec:60:7d:b7:e6:84:32:be:4f:fb: 27 79:a4:b2:b5:2e:12:f9:84:17:f0:62:6f:27:3e:13: 28 58:b1:54:0d:21:9a:73:37:a1:30:cf:6f:92:dc:f6: 31 ab:e9:c3:f2:cf:87:96:8f:80:02:32:9e:99:58:6f: 38 B4:5A:E4:A5:B3:DE:D2:52:F6:B9:D5:A6:95:0F:EB:3E:BC:C7:FD:FF 40 keyid:B4:5A:E4:A5:B3:DE:D2:52:F6:B9:D5:A6:95:0F:EB:3E:BC:C7:FD:FF 47 32:89:be:63:47:53:ff:b6:be:f1:2e:8c:54:c0:99:3f:a0:b9: 48 37:23:72:5f:0d:46:59:8f:d8:47:cd:97:4c:9f:07:0c:12:62: [all …]
|
/mbedtls-3.6.0/tests/suites/ |
D | test_suite_debug.data | 17 …_ret:"MyFile":999:"Test return value":0:"MyFile(0999)\: Test return value() returned 0 (-0x0000)\n" 20 …ug_print_ret:"MyFile":999:"Test return value":-0x1000:"MyFile(0999)\: Test return value() returned… 23 …g_print_ret:"MyFile":999:"Test return value":-0xFFFF:"MyFile(0999)\: Test return value() returned … 32 …bytes)\nMyFile(0999)\: 0000\: 00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f ................\n" 35 …ytes)\nMyFile(0999)\: 0000\: 00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f ................\nM… 38 …f ................\nMyFile(0999)\: 0010\: 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f .....… 43 Debug print mbedtls_mpi: 0 (non-empty representation) 53 …f e1 5d f2 84 df de 4a 14\nMyFile(0999)\: 2f 68 aa 8d 41 20 23 19 5c ee 66 88 3e 62 90 ff\nMyFile… 56 …f e1 5d f2 84 df de 4a\nMyFile(0999)\: 14 2f 68 aa 8d 41 20 23 19 5c ee 66 88 3e 62 90\nMyFile(09… 59 …f e1 5d f2 84 df de 4a\nMyFile(0999)\: 14 2f 68 aa 8d 41 20 23 19 5c ee 66 88 3e 62 90\nMyFile(09… [all …]
|
D | test_suite_aes.ofb.data | 1 # NIST Special Publication 800-38A 3 # Test Vectors - Appendix F, Section F.4 4 OFB-AES128.Encrypt - Single block 8 OFB-AES128.Encrypt - Partial blocks - 7 bytes 12 OFB-AES128.Encrypt - Test NIST SP800-38A - F.4.1 16 OFB-AES128.Decrypt - Test NIST SP800-38A - F.4.2 20 OFB-AES192.Encrypt - Test NIST SP800-38A - F.4.3 24 OFB-AES192.Decrypt - Test NIST SP800-38A - F.4.4 28 OFB-AES256.Encrypt - Test NIST SP800-38A - F.4.5 32 OFB-AES256.Decrypt - Test NIST SP800-38A - F.4.6
|
D | test_suite_constant_time.function | 8 * under MSan or Valgrind will detect a non-constant-time implementation. 118 void mbedtls_ct_error_if(int cond, int t, int f) 122 int expected = c ? t : f; 127 TEST_CF_SECRET(&f, sizeof(f)); 129 TEST_EQUAL(mbedtls_ct_error_if(c, t, f), expected); 134 TEST_CF_PUBLIC(&f, sizeof(f)); 143 mbedtls_ct_uint_t f = (mbedtls_ct_uint_t) strtoull(f_str, NULL, 16); 145 mbedtls_ct_uint_t expected = c ? t : f; 150 TEST_CF_SECRET(&f, sizeof(f)); 152 TEST_EQUAL(mbedtls_ct_if(c, t, f), expected); [all …]
|
D | test_suite_bignum_core.generated.data | 27 mpi_core_add_and_add_if #7 0 + f 29 mpi_core_add_and_add_if:"00000000":"0000000f":"0000000f":0 31 mpi_core_add_and_add_if #8 0 + f 33 mpi_core_add_and_add_if:"0000000000000000":"000000000000000f":"000000000000000f":0 299 mpi_core_add_and_add_if #75 1 + f 301 mpi_core_add_and_add_if:"00000001":"0000000f":"00000010":0 303 mpi_core_add_and_add_if #76 1 + f 305 mpi_core_add_and_add_if:"0000000000000001":"000000000000000f":"0000000000000010":0 571 mpi_core_add_and_add_if #143 3 + f 573 mpi_core_add_and_add_if:"00000003":"0000000f":"00000012":0 [all …]
|
/mbedtls-3.6.0/programs/pkey/ |
D | rsa_sign.c | 2 * RSA/SHA-256 signature creation program 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 34 FILE *f; in main() local 63 if ((f = fopen("rsa_priv.txt", "rb")) == NULL) { in main() 69 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 70 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0 || in main() 71 (ret = mbedtls_mpi_read_file(&D, 16, f)) != 0 || in main() 72 (ret = mbedtls_mpi_read_file(&P, 16, f)) != 0 || in main() 73 (ret = mbedtls_mpi_read_file(&Q, 16, f)) != 0 || in main() 74 (ret = mbedtls_mpi_read_file(&DP, 16, f)) != 0 || in main() [all …]
|
D | rsa_decrypt.c | 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 38 FILE *f; in main() local 86 if ((f = fopen("rsa_priv.txt", "rb")) == NULL) { in main() 92 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 93 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0 || in main() 94 (ret = mbedtls_mpi_read_file(&D, 16, f)) != 0 || in main() 95 (ret = mbedtls_mpi_read_file(&P, 16, f)) != 0 || in main() 96 (ret = mbedtls_mpi_read_file(&Q, 16, f)) != 0 || in main() 97 (ret = mbedtls_mpi_read_file(&DP, 16, f)) != 0 || in main() 98 (ret = mbedtls_mpi_read_file(&DQ, 16, f)) != 0 || in main() [all …]
|
D | rsa_verify.c | 2 * RSA/SHA-256 signature verification program 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 34 FILE *f; in main() local 59 if ((f = fopen("rsa_pub.txt", "rb")) == NULL) { in main() 65 if ((ret = mbedtls_mpi_read_file(&rsa.MBEDTLS_PRIVATE(N), 16, f)) != 0 || in main() 66 (ret = mbedtls_mpi_read_file(&rsa.MBEDTLS_PRIVATE(E), 16, f)) != 0) { in main() 68 fclose(f); in main() 74 fclose(f); in main() 81 if ((f = fopen(filename, "rb")) == NULL) { in main() 87 while (fscanf(f, "%02X", (unsigned int *) &c) > 0 && in main() [all …]
|
D | rsa_encrypt.c | 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 37 FILE *f; in main() local 79 if ((f = fopen("rsa_pub.txt", "rb")) == NULL) { in main() 85 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 86 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0) { in main() 89 fclose(f); in main() 92 fclose(f); in main() 122 * Write the signature into result-enc.txt in main() 124 if ((f = fopen("result-enc.txt", "wb+")) == NULL) { in main() 125 mbedtls_printf(" failed\n ! Could not create %s\n\n", "result-enc.txt"); in main() [all …]
|
D | dh_server.c | 2 * Diffie-Hellman-Merkle key exchange (server side) 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 52 FILE *f; in main() local 101 if ((f = fopen("rsa_priv.txt", "rb")) == NULL) { in main() 109 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 110 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0 || in main() 111 (ret = mbedtls_mpi_read_file(&D, 16, f)) != 0 || in main() 112 (ret = mbedtls_mpi_read_file(&P, 16, f)) != 0 || in main() 113 (ret = mbedtls_mpi_read_file(&Q, 16, f)) != 0) { in main() 116 fclose(f); in main() [all …]
|
/mbedtls-3.6.0/programs/util/ |
D | pem2der.c | 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 55 s1 = (unsigned char *) strstr((const char *) input, "-----BEGIN"); in convert_pem_to_der() 57 return -1; in convert_pem_to_der() 60 s2 = (unsigned char *) strstr((const char *) input, "-----END"); in convert_pem_to_der() 62 return -1; in convert_pem_to_der() 66 while (s1 < end && *s1 != '-') { in convert_pem_to_der() 69 while (s1 < end && *s1 == '-') { in convert_pem_to_der() 80 return -1; in convert_pem_to_der() 83 ret = mbedtls_base64_decode(NULL, 0, &len, (const unsigned char *) s1, s2 - s1); in convert_pem_to_der() 89 return -1; in convert_pem_to_der() [all …]
|
/mbedtls-3.6.0/tests/data_files/ |
D | dh.optlen.pem | 7 93:8e:a1:1b:48:dc:51:5d:ab:7a:bc:bb:1e:0c:7f: 9 43:57:e1:c4:ea:07:a7:ce:1e:38:1a:2f:ca:fd:ff: 10 5f:5b:f0:0d:f8:28:80:60:20:e8:75:c0:09:26:e4: 17 ec:b0:55:6f:b7:13:12:a8:d7:c9:3b:b2:89:8e:a0: 18 8e:e5:4e:eb:59:45:48:28:5f:06:a9:73:cb:be:2a: 25 b3:12:6a:ea:f4:71:53:c7:d6:7f:40:30:30:b2:92: 30 e4:94:05:e5:90:2f:a0:59:6a:1c:ba:a8:95:cc:40: 31 2d:52:13:ed:4a:5f:1f:5b:a8:b5:e1:ed:3d:a9:51: 34 d7:23:32:2a:cf:32:7f:9e:41:3c:da:64:00:c1:5c: 35 5b:2e:a1:fa:34:40:5d:83:98:2f:ba:40:e6:d8:52: [all …]
|
D | dh.1000.pem | 16 9e:a4:a8:c4:29:fe:76:18:02:4f:76:c9:29:0e:f2: 21 4a:1a:dc:b2:d4:29:23:ab:2e:8f:7f:6a:84:1d:82: 22 23:6e:42:8c:1e:70:3d:21:bb:b9:b9:8f:f9:fd:9c: 23 53:08:e4:e8:5a:04:ca:5f:8f:73:55:ac:e1:41:20: 24 c7:43:fa:8f:99: 27 -----BEGIN DH PARAMETERS----- 34 -----END DH PARAMETERS-----
|
D | dh.998.pem | 3 39:5f:30:c0:7b:06:b7:6a:49:c6:c0:81:1f:39:77: 10 8f:93:78:96:8f:2c:25:8d:7d:1f:eb:5c:3c:bf:51: 13 -----BEGIN DH PARAMETERS----- 17 -----END DH PARAMETERS-----
|
/mbedtls-3.6.0/scripts/ |
D | generate_query_config.pl | 22 # SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 34 …die "Invalid number of arguments - usage: $0 [MBED_TLS_CONFIG_FILE PSA_CRYPTO_CONFIG_FILE TEMPLATE… 37 -f $mbedtls_config_file or die "No such file: $mbedtls_config_file"; 38 -f $psa_crypto_config_file or die "No such file: $psa_crypto_config_file"; 39 -f $query_config_format_file or die "No such file: $query_config_format_file"; 46 unless(-f $mbedtls_config_file && -f $query_config_format_file && -f $psa_crypto_config_file) { 48 -f $mbedtls_config_file && -f $query_config_format_file && -f $psa_crypto_config_file 49 … or die "No arguments supplied, must be run from project root or a first-level subdirectory\n"; 54 # have commas or function-like macros cannot be transformed into strings easily
|
/mbedtls-3.6.0/tests/ |
D | Makefile | 2 # To compile on SunOS: add "-lsocket -lnsl" to LDFLAGS 4 CFLAGS ?= -O2 5 WARNING_CFLAGS ?= -Wall -Wextra -Wformat=2 -Wno-format-nonliteral 8 # Set this to -v to see the details of failing test cases 9 TEST_FLAGS ?= $(if $(filter-out 0 OFF Off off NO No no FALSE False false N n,$(CTEST_OUTPUT_ON_FAIL… 13 # Include public header files from ../include, test-specific header files 16 LOCAL_CFLAGS = $(WARNING_CFLAGS) -I./include -I../include -I../library -D_FILE_OFFSET_BITS=64 17 LOCAL_LDFLAGS = -L../library \ 18 -lmbedtls$(SHARED_SUFFIX) \ 19 -lmbedx509$(SHARED_SUFFIX) \ [all …]
|
/mbedtls-3.6.0/ |
D | Makefile | 15 $(MAKE) -C programs 18 $(MAKE) -C library 21 $(MAKE) -C tests 24 $(MAKE) -C tests mbedtls_test 27 $(MAKE) -C library $* 29 $(MAKE) -C programs $* 31 $(MAKE) -C tests $* 45 # that lacks some of the necessary tools to re-generate the files. 46 # If $(GEN_FILES) is non-empty, the generated source files' dependencies 50 # In dependencies where the target is a configuration-independent generated [all …]
|
/mbedtls-3.6.0/tests/scripts/ |
D | all.sh | 6 # SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 15 # ------- 20 # --------------- 32 # * Basic Unix tools (Windows users note: a Unix-style find must be before 39 # * arm-gcc and mingw-gcc 40 # * ArmCC 5 and ArmCC 6, unless invoked with --no-armcc 50 # The behavior on an error depends on whether --keep-going (alias -k) 52 # * Without --keep-going: the script stops on the first error without 55 # * With --keep-going: the script runs all requested components and 60 # script -c tests/scripts/all.sh [all …]
|
D | generate_test_cert_macros.py | 9 # SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 18 #pylint: disable=signature-differs, too-few-public-methods 39 parser.add_argument('--string', type=macro_define_type, action=MacroDefineAction, 41 parser.add_argument('--binary', type=macro_define_type, action=MacroDefineAction, 44 parser.add_argument('--password', type=macro_define_type, action=MacroDefineAction, 46 parser.add_argument('--output', type=str, required=True) 55 #pylint: disable=dangerous-default-value, unused-argument 66 with open(filename, 'rb') as f: 67 data = f.read(12) 70 data = f.read(12) [all …]
|
/mbedtls-3.6.0/programs/random/ |
D | gen_entropy.c | 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 29 FILE *f; in main() local 40 if ((f = fopen(argv[1], "wb+")) == NULL) { in main() 50 mbedtls_printf(" failed\n ! mbedtls_entropy_func returned -%04X\n", in main() 55 fwrite(buf, 1, sizeof(buf), f); in main() 57 mbedtls_printf("Generating %ldkb of data in file '%s'... %04.1f" \ in main() 70 fclose(f); in main()
|
/mbedtls-3.6.0/library/ |
D | aes.c | 2 * FIPS-197 compliant AES implementation 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 10 …src.nist.gov/csrc/media/projects/cryptographic-standards-and-guidelines/documents/aes-development/… 11 * http://csrc.nist.gov/publications/fips/fips197/fips-197.pdf 68 static int aes_padlock_ace = -1; 73 * Forward S-box 121 V(0D, F2, F2, FF), V(BD, 6B, 6B, D6), V(B1, 6F, 6F, DE), V(54, C5, C5, 91), \ 124 V(45, CA, CA, 8F), V(9D, 82, 82, 1F), V(40, C9, C9, 89), V(87, 7D, 7D, FA), \ 126 V(EC, AD, AD, 41), V(67, D4, D4, B3), V(FD, A2, A2, 5F), V(EA, AF, AF, 45), \ 129 V(5A, 36, 36, 6C), V(41, 3F, 3F, 7E), V(02, F7, F7, F5), V(4F, CC, CC, 83), \ [all …]
|
D | Makefile | 4 CFLAGS ?= -O2 5 WARNING_CFLAGS ?= -Wall -Wextra -Wformat=2 -Wno-format-nonliteral 12 LOCAL_CFLAGS = $(WARNING_CFLAGS) -I. -I../include -D_FILE_OFFSET_BITS=64 16 LOCAL_CFLAGS += -g3 20 # CFLAGS += -mno-xl-soft-mul -mxl-barrel-shift 23 # CFLAGS += -D_BSD_EXTENSION 36 else ifeq ($(shell uname -s),Darwin) 43 LOCAL_LDFLAGS += -lbcrypt 48 # all code is position-indep with mingw, avoid warning about useless flag 50 LOCAL_CFLAGS += -fPIC -fpic [all …]
|
D | entropy.c | 5 * SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later 29 ctx->source_count = 0; in mbedtls_entropy_init() 30 memset(ctx->source, 0, sizeof(ctx->source)); in mbedtls_entropy_init() 33 mbedtls_mutex_init(&ctx->mutex); in mbedtls_entropy_init() 36 ctx->accumulator_started = 0; in mbedtls_entropy_init() 37 mbedtls_md_init(&ctx->accumulator); in mbedtls_entropy_init() 57 ctx->initial_entropy_run = 0; in mbedtls_entropy_init() 65 * This is important for mutexes which don't allow double-free. */ in mbedtls_entropy_free() 66 if (ctx->accumulator_started == -1) { in mbedtls_entropy_free() 71 mbedtls_mutex_free(&ctx->mutex); in mbedtls_entropy_free() [all …]
|