/mbedtls-3.5.0/programs/pkey/ |
D | rsa_sign.c | 45 FILE *f; in main() local 74 if ((f = fopen("rsa_priv.txt", "rb")) == NULL) { in main() 80 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 81 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0 || in main() 82 (ret = mbedtls_mpi_read_file(&D, 16, f)) != 0 || in main() 83 (ret = mbedtls_mpi_read_file(&P, 16, f)) != 0 || in main() 84 (ret = mbedtls_mpi_read_file(&Q, 16, f)) != 0 || in main() 85 (ret = mbedtls_mpi_read_file(&DP, 16, f)) != 0 || in main() 86 (ret = mbedtls_mpi_read_file(&DQ, 16, f)) != 0 || in main() 87 (ret = mbedtls_mpi_read_file(&QP, 16, f)) != 0) { in main() [all …]
|
D | rsa_decrypt.c | 50 FILE *f; in main() local 98 if ((f = fopen("rsa_priv.txt", "rb")) == NULL) { in main() 104 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 105 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0 || in main() 106 (ret = mbedtls_mpi_read_file(&D, 16, f)) != 0 || in main() 107 (ret = mbedtls_mpi_read_file(&P, 16, f)) != 0 || in main() 108 (ret = mbedtls_mpi_read_file(&Q, 16, f)) != 0 || in main() 109 (ret = mbedtls_mpi_read_file(&DP, 16, f)) != 0 || in main() 110 (ret = mbedtls_mpi_read_file(&DQ, 16, f)) != 0 || in main() 111 (ret = mbedtls_mpi_read_file(&QP, 16, f)) != 0) { in main() [all …]
|
D | rsa_verify.c | 45 FILE *f; in main() local 70 if ((f = fopen("rsa_pub.txt", "rb")) == NULL) { in main() 76 if ((ret = mbedtls_mpi_read_file(&rsa.MBEDTLS_PRIVATE(N), 16, f)) != 0 || in main() 77 (ret = mbedtls_mpi_read_file(&rsa.MBEDTLS_PRIVATE(E), 16, f)) != 0) { in main() 79 fclose(f); in main() 85 fclose(f); in main() 92 if ((f = fopen(filename, "rb")) == NULL) { in main() 98 while (fscanf(f, "%02X", (unsigned int *) &c) > 0 && in main() 103 fclose(f); in main()
|
D | dh_server.c | 62 FILE *f; in main() local 111 if ((f = fopen("rsa_priv.txt", "rb")) == NULL) { in main() 119 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 120 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0 || in main() 121 (ret = mbedtls_mpi_read_file(&D, 16, f)) != 0 || in main() 122 (ret = mbedtls_mpi_read_file(&P, 16, f)) != 0 || in main() 123 (ret = mbedtls_mpi_read_file(&Q, 16, f)) != 0) { in main() 126 fclose(f); in main() 129 fclose(f); in main() 149 if ((f = fopen("dh_prime.txt", "rb")) == NULL) { in main() [all …]
|
D | rsa_encrypt.c | 49 FILE *f; in main() local 91 if ((f = fopen("rsa_pub.txt", "rb")) == NULL) { in main() 97 if ((ret = mbedtls_mpi_read_file(&N, 16, f)) != 0 || in main() 98 (ret = mbedtls_mpi_read_file(&E, 16, f)) != 0) { in main() 101 fclose(f); in main() 104 fclose(f); in main() 136 if ((f = fopen("result-enc.txt", "wb+")) == NULL) { in main() 142 mbedtls_fprintf(f, "%02X%s", buf[i], in main() 146 fclose(f); in main()
|
D | key_app_writer.c | 110 FILE *f; in write_public_key() local 135 if ((f = fopen(output_file, "w")) == NULL) { in write_public_key() 139 if (fwrite(c, 1, len, f) != len) { in write_public_key() 140 fclose(f); in write_public_key() 144 fclose(f); in write_public_key() 152 FILE *f; in write_private_key() local 177 if ((f = fopen(output_file, "w")) == NULL) { in write_private_key() 181 if (fwrite(c, 1, len, f) != len) { in write_private_key() 182 fclose(f); in write_private_key() 186 fclose(f); in write_private_key()
|
D | pk_sign.c | 49 FILE *f; in main() local 121 if ((f = fopen(filename, "wb+")) == NULL) { in main() 126 if (fwrite(buf, 1, olen, f) != olen) { in main() 128 fclose(f); in main() 132 fclose(f); in main()
|
D | rsa_sign_pss.c | 50 FILE *f; in main() local 134 if ((f = fopen(filename, "wb+")) == NULL) { in main() 139 if (fwrite(buf, 1, olen, f) != olen) { in main() 141 fclose(f); in main() 145 fclose(f); in main()
|
/mbedtls-3.5.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: 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: 51 2a:ce:2c:0d:08:59:05:09:05:a6:39:9f:b3:67:1b:e2:83:e5: 52 e1:8f:53:f6:67:93:c7:f9:6f:76:44:58:12:e8:3a:d4:97:e7: [all …]
|
/mbedtls-3.5.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: 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: 51 2a:ce:2c:0d:08:59:05:09:05:a6:39:9f:b3:67:1b:e2:83:e5: 52 e1:8f:53:f6:67:93:c7:f9:6f:76:44:58:12:e8:3a:d4:97:e7: [all …]
|
/mbedtls-3.5.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: 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: 51 2a:ce:2c:0d:08:59:05:09:05:a6:39:9f:b3:67:1b:e2:83:e5: 52 e1:8f:53:f6:67:93:c7:f9:6f:76:44:58:12:e8:3a:d4:97:e7: [all …]
|
/mbedtls-3.5.0/tests/data_files/ |
D | server9-with-ca.crt | 34 00:c0:df:37:fc:17:bb:e0:96:9d:3f:86:de:96:32: 41 71:f1:bd:83:d9:3f:d6:a5:e2:3c:2a:8f:ef:27:60: 42 c3:c6:9f:cb:ba:ec:60:7d:b7:e6:84:32:be:4f:fb: 46 79:a4:b2:b5:2e:12:f9:84:17:f0:62:6f:27:3e:13: 47 58:b1:54:0d:21:9a:73:37:a1:30:cf:6f:92:dc:f6: 50 ab:e9:c3:f2:cf:87:96:8f:80:02:32:9e:99:58:6f: 66 32:89:be:63:47:53:ff:b6:be:f1:2e:8c:54:c0:99:3f:a0:b9: 67 37:23:72:5f:0d:46:59:8f:d8:47:cd:97:4c:9f:07:0c:12:62: 70 2a:ce:2c:0d:08:59:05:09:05:a6:39:9f:b3:67:1b:e2:83:e5: 71 e1:8f:53:f6:67:93:c7:f9:6f:76:44:58:12:e8:3a:d4:97:e7: [all …]
|
D | server10_int3_int-ca2_ca.crt | 55 00:c0:df:37:fc:17:bb:e0:96:9d:3f:86:de:96:32: 62 71:f1:bd:83:d9:3f:d6:a5:e2:3c:2a:8f:ef:27:60: 63 c3:c6:9f:cb:ba:ec:60:7d:b7:e6:84:32:be:4f:fb: 67 79:a4:b2:b5:2e:12:f9:84:17:f0:62:6f:27:3e:13: 68 58:b1:54:0d:21:9a:73:37:a1:30:cf:6f:92:dc:f6: 71 ab:e9:c3:f2:cf:87:96:8f:80:02:32:9e:99:58:6f: 87 32:89:be:63:47:53:ff:b6:be:f1:2e:8c:54:c0:99:3f:a0:b9: 88 37:23:72:5f:0d:46:59:8f:d8:47:cd:97:4c:9f:07:0c:12:62: 91 2a:ce:2c:0d:08:59:05:09:05:a6:39:9f:b3:67:1b:e2:83:e5: 92 e1:8f:53:f6:67:93:c7:f9:6f:76:44:58:12:e8:3a:d4:97:e7: [all …]
|
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:
|
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:
|
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:
|
/mbedtls-3.5.0/programs/util/ |
D | pem2der.c | 119 FILE *f; in load_file() local 122 if ((f = fopen(path, "rb")) == NULL) { in load_file() 126 fseek(f, 0, SEEK_END); in load_file() 127 if ((size = ftell(f)) == -1) { in load_file() 128 fclose(f); in load_file() 131 fseek(f, 0, SEEK_SET); in load_file() 137 fclose(f); in load_file() 141 if (fread(*buf, 1, *n, f) != *n) { in load_file() 142 fclose(f); in load_file() 148 fclose(f); in load_file() [all …]
|
/mbedtls-3.5.0/scripts/ |
D | generate_query_config.pl | 48 -f $mbedtls_config_file or die "No such file: $mbedtls_config_file"; 49 -f $query_config_format_file or die "No such file: $query_config_format_file"; 51 -f $psa_crypto_config_file or die "No such file: $psa_crypto_config_file"; 53 …$psa_crypto_config_file = (-f $default_psa_crypto_config_file) ? $default_psa_crypto_config_file :… 61 unless(-f $mbedtls_config_file && -f $query_config_format_file && -f $psa_crypto_config_file) { 63 -f $mbedtls_config_file && -f $query_config_format_file && -f $psa_crypto_config_file
|
/mbedtls-3.5.0/tests/suites/ |
D | test_suite_debug.data | 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 .....… 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… 63 …f 3d 40 6a d5 55 53 8b fd 36 ee 82 65 2e\nMyFile(0999)\: 15 61 5e 89 bf b8 e8 45 90 db ee 88 16 5… 67 …f 87 56 fe fc 89 ba 29 43\nMyFile(0999)\: 4b 4e e0 6e c3 0e 57 53 33 39 58 d4 52 b4 91 95\nMyFile…
|
D | test_suite_pkwrite.function | 19 FILE *f; 38 f = fopen(key_file, "r"); 39 TEST_ASSERT(f != NULL); 40 ilen = fread(check_buf, 1, sizeof(check_buf), f); 41 fclose(f); 58 FILE *f; 78 f = fopen(key_file, "r"); 79 TEST_ASSERT(f != NULL); 80 ilen = fread(check_buf, 1, sizeof(check_buf), f); 81 fclose(f);
|
/mbedtls-3.5.0/library/ |
D | hmac_drbg.c | 441 FILE *f; in mbedtls_hmac_drbg_write_seed_file() local 444 if ((f = fopen(path, "wb")) == NULL) { in mbedtls_hmac_drbg_write_seed_file() 449 mbedtls_setbuf(f, NULL); in mbedtls_hmac_drbg_write_seed_file() 455 if (fwrite(buf, 1, sizeof(buf), f) != sizeof(buf)) { in mbedtls_hmac_drbg_write_seed_file() 463 fclose(f); in mbedtls_hmac_drbg_write_seed_file() 472 FILE *f = NULL; in mbedtls_hmac_drbg_update_seed_file() local 477 if ((f = fopen(path, "rb")) == NULL) { in mbedtls_hmac_drbg_update_seed_file() 482 mbedtls_setbuf(f, NULL); in mbedtls_hmac_drbg_update_seed_file() 484 n = fread(buf, 1, sizeof(buf), f); in mbedtls_hmac_drbg_update_seed_file() 485 if (fread(&c, 1, 1, f) != 0) { in mbedtls_hmac_drbg_update_seed_file() [all …]
|
D | ctr_drbg.c | 601 FILE *f; in mbedtls_ctr_drbg_write_seed_file() local 604 if ((f = fopen(path, "wb")) == NULL) { in mbedtls_ctr_drbg_write_seed_file() 609 mbedtls_setbuf(f, NULL); in mbedtls_ctr_drbg_write_seed_file() 616 if (fwrite(buf, 1, MBEDTLS_CTR_DRBG_MAX_INPUT, f) != in mbedtls_ctr_drbg_write_seed_file() 626 fclose(f); in mbedtls_ctr_drbg_write_seed_file() 634 FILE *f = NULL; in mbedtls_ctr_drbg_update_seed_file() local 639 if ((f = fopen(path, "rb")) == NULL) { in mbedtls_ctr_drbg_update_seed_file() 644 mbedtls_setbuf(f, NULL); in mbedtls_ctr_drbg_update_seed_file() 646 n = fread(buf, 1, sizeof(buf), f); in mbedtls_ctr_drbg_update_seed_file() 647 if (fread(&c, 1, 1, f) != 0) { in mbedtls_ctr_drbg_update_seed_file() [all …]
|
D | entropy.c | 461 FILE *f = NULL; in mbedtls_entropy_write_seed_file() local 469 if ((f = fopen(path, "wb")) == NULL) { in mbedtls_entropy_write_seed_file() 475 mbedtls_setbuf(f, NULL); in mbedtls_entropy_write_seed_file() 477 if (fwrite(buf, 1, MBEDTLS_ENTROPY_BLOCK_SIZE, f) != MBEDTLS_ENTROPY_BLOCK_SIZE) { in mbedtls_entropy_write_seed_file() 487 if (f != NULL) { in mbedtls_entropy_write_seed_file() 488 fclose(f); in mbedtls_entropy_write_seed_file() 497 FILE *f; in mbedtls_entropy_update_seed_file() local 501 if ((f = fopen(path, "rb")) == NULL) { in mbedtls_entropy_update_seed_file() 506 mbedtls_setbuf(f, NULL); in mbedtls_entropy_update_seed_file() 508 fseek(f, 0, SEEK_END); in mbedtls_entropy_update_seed_file() [all …]
|
/mbedtls-3.5.0/tests/scripts/ |
D | generate-afl-tests.sh | 73 for f in *; 76 sed '/^\s*$/d' $f >testcase_$f 77 rm $f
|
/mbedtls-3.5.0/programs/random/ |
D | gen_entropy.c | 41 FILE *f; in main() local 52 if ((f = fopen(argv[1], "wb+")) == NULL) { in main() 67 fwrite(buf, 1, sizeof(buf), f); in main() 82 fclose(f); in main()
|