| /mbedtls/library/ |
| A D | debug.c | 54 const char *file, int line, in mbedtls_debug_print_msg() argument 84 debug_send_line(ssl, level, file, line, str); in mbedtls_debug_print_msg() 88 const char *file, int line, in mbedtls_debug_print_ret() argument 112 debug_send_line(ssl, level, file, line, str); in mbedtls_debug_print_ret() 133 debug_send_line(ssl, level, file, line, str); in mbedtls_debug_print_buf() 166 debug_send_line(ssl, level, file, line, str); in mbedtls_debug_print_buf() 203 debug_send_line(ssl, level, file, line, str); in mbedtls_debug_print_ec_coord() 229 debug_send_line(ssl, level, file, line, str); in mbedtls_debug_print_ec_coord() 285 debug_send_line(ssl, level, file, line, str); in mbedtls_debug_print_mpi() 327 debug_send_line(ssl, level, file, line, in debug_print_pk() [all …]
|
| A D | platform.c | 295 FILE *file; in mbedtls_platform_std_nv_seed_read() local 303 mbedtls_setbuf(file, NULL); in mbedtls_platform_std_nv_seed_read() 305 if ((n = fread(buf, 1, buf_len, file)) != buf_len) { in mbedtls_platform_std_nv_seed_read() 306 fclose(file); in mbedtls_platform_std_nv_seed_read() 311 fclose(file); in mbedtls_platform_std_nv_seed_read() 317 FILE *file; in mbedtls_platform_std_nv_seed_write() local 320 if ((file = fopen(MBEDTLS_PLATFORM_STD_NV_SEED_FILE, "w")) == NULL) { in mbedtls_platform_std_nv_seed_write() 325 mbedtls_setbuf(file, NULL); in mbedtls_platform_std_nv_seed_write() 327 if ((n = fwrite(buf, 1, buf_len, file)) != buf_len) { in mbedtls_platform_std_nv_seed_write() 328 fclose(file); in mbedtls_platform_std_nv_seed_write() [all …]
|
| A D | debug_internal.h | 31 const char *file, int line, 50 const char *file, int line, 71 const char *file, int line, const char *text, 92 const char *file, int line, 114 const char *file, int line, 135 const char *file, int line, 166 const char *file, int line,
|
| A D | entropy_poll.c | 151 FILE *file; in mbedtls_platform_entropy_poll() local 170 ((void) file); in mbedtls_platform_entropy_poll() 181 file = fopen("/dev/urandom", "rb"); in mbedtls_platform_entropy_poll() 182 if (file == NULL) { in mbedtls_platform_entropy_poll() 187 mbedtls_setbuf(file, NULL); in mbedtls_platform_entropy_poll() 189 read_len = fread(output, 1, len, file); in mbedtls_platform_entropy_poll() 191 fclose(file); in mbedtls_platform_entropy_poll() 195 fclose(file); in mbedtls_platform_entropy_poll()
|
| /mbedtls/tests/suites/ |
| A D | test_suite_hmac_drbg.misc.data | 37 HMAC_DRBG write/update seed file SHA-1 [#1] 41 HMAC_DRBG write/update seed file SHA-1 [#2] 45 HMAC_DRBG write/update seed file SHA-224 [#1] 49 HMAC_DRBG write/update seed file SHA-224 [#2] 53 HMAC_DRBG write/update seed file SHA-256 [#1] 57 HMAC_DRBG write/update seed file SHA-256 [#2] 61 HMAC_DRBG write/update seed file SHA-384 [#1] 65 HMAC_DRBG write/update seed file SHA-384 [#2] 69 HMAC_DRBG write/update seed file SHA-512 [#1] 73 HMAC_DRBG write/update seed file SHA-512 [#2] [all …]
|
| A D | test_suite_debug.function | 18 memcpy(p, file, strlen(file)); 19 p += strlen(file); 55 void debug_print_msg_threshold(int threshold, int level, char *file, 81 mbedtls_debug_print_msg(&ssl, level, file, line, 94 void mbedtls_debug_print_ret(char *file, int line, char *text, int value, 118 mbedtls_debug_print_ret(&ssl, 0, file, line, text, value); 130 void mbedtls_debug_print_buf(char *file, int line, char *text, 166 void mbedtls_debug_print_crt(char *crt_file, char *file, int line, 193 mbedtls_debug_print_crt(&ssl, 0, file, line, prefix, &crt); 206 void mbedtls_debug_print_mpi(char *value, char *file, int line, [all …]
|
| A D | test_suite_net.function | 22 /** Open a file on the given file descriptor. 28 * On success, it refers to the opened file (\p wanted_fd). 29 * \param wanted_fd The desired file descriptor. 77 /* Test that mbedtls_net_poll does not misbehave when given a file 90 /* On many systems, by default, the maximum permitted file descriptor 94 * If the limit can't be raised, a file descriptor opened by the 97 * A file descriptor could still be higher than FD_SETSIZE if it was 116 * file descriptors greater or equal to FD_SETSIZE. So we expect to hit
|
| A D | main_test.function | 5 * This file has been machine generated using the script: 8 * Test file : __MBEDTLS_TEST_TEMPLATE__TEST_FILE 10 * The following files were used to create this file. 12 * Main code file : __MBEDTLS_TEST_TEMPLATE__TEST_MAIN_FILE 13 * Platform code file : __MBEDTLS_TEST_TEMPLATE__TEST_PLATFORM_FILE 14 * Helper file : __MBEDTLS_TEST_TEMPLATE__TEST_COMMON_HELPER_FILE 15 * Test suite file : __MBEDTLS_TEST_TEMPLATE__TEST_CASE_FILE 233 extern void (*mbedtls_test_hook_test_fail)(const char *test, int line, const char *file); 241 * using the default data file. This allows running the executable 243 * the .datax file as well as data files used by test cases [all …]
|
| A D | test_suite_entropy.data | 10 Entropy write/update seed file: good 13 Entropy write/update seed file: nonexistent 14 entropy_seed_file:"no_such_dir/file":MBEDTLS_ERR_ENTROPY_FILE_IO_ERROR 16 Entropy write/update seed file: base NV seed file
|
| A D | host_test.function | 65 " file is used:\n" \ 320 * \param outcome_file The file to write to. 367 * \param outcome_file The file to write to. 481 * supplied or default data file. 504 FILE *file; 593 file = fopen(test_filename, "r"); 594 if (file == NULL) { 603 while (!feof(file)) { 749 fclose(file); 753 fclose(file); [all …]
|
| A D | test_suite_md.data | 347 generic MD5 Hash file #1 351 generic MD5 Hash file #2 355 generic MD5 Hash file #3 359 generic MD5 Hash file #4 367 generic RIPEMD160 Hash file #1 371 generic RIPEMD160 Hash file #2 375 generic RIPEMD160 Hash file #3 1183 generic SHA1 Hash file #1 1187 generic SHA1 Hash file #2 1191 generic SHA1 Hash file #3 [all …]
|
| A D | test_suite_psa_crypto_entropy.function | 17 /* Check the entropy seed file. 20 * If 0, the file must not exist. 23 * the entropy seed file exists and has exactly this size, 24 * or \p expected_size is zero and the file does not exist. 26 * the entropy seed file does not exist or has a different size, 27 * or \p expected_size is zero but the file exists. 30 * \note We enforce that the seed is in a specific ITS file. 38 * file. If this test assertion fails, you've presumably broken backward 58 /* Remove the entropy seed file.
|
| A D | test_suite_psa_its.function | 3 /* This test file is specific to the ITS implementation in PSA Crypto 4 * on top of stdio. It expects to know what the stdio name of a file is 50 * We ignore the error if the file exists but remove() fails because 51 * it can't be checked portably (except by attempting to open the file 53 * remove() on an existing file is very unlikely anyway and would not 162 "Content of file 0x%08lx", (unsigned long) uid); 168 "Content of file 0x%08lx", (unsigned long) uid); 260 /* Overwrite the 1st byte of the file, the ITS magic number */ 266 /* Reopen file and truncate it to 0 byte by specifying the 'w' flag */ 278 /* Check if the file is really deleted. */
|
| /mbedtls/docs/architecture/ |
| A D | mbed-crypto-storage-specification.md | 49 ### Key file format for 0.1.0 53 The layout of a key file is: 119 ### Key file format for 1.0.0 179 * [Some changes in the key file format](#key-file-format-for-1.1.0). 192 ### Key file format for 1.1.0 203 The layout of a key file is: 258 ### Key file format for TBD 262 The layout of a key file is: 317 ### Key file format for TBD 321 The layout of a key file is: [all …]
|
| A D | psa-storage-resilience.md | 26 * `remove()` removes a file (returning a specific error code if the file does not exist). 171 3. Write the key file. 184 3. Remove the key file. 201 4. Write the key file. 207 2. Remove the key file. 225 3. Write the key file. 233 3. Remove the key file. 323 * If the file `id` exists: 339 * If the file `id` exists: 414 2. Add _A_ [to the transaction list file](#transaction-list-file-manipulation). [all …]
|
| /mbedtls/docs/architecture/testing/ |
| A D | test-framework.md | 13 … the test does. The first non-comment line of each paragraph in a `.data` file is the test descrip… 16 … that process test descriptions (`generate_test_code.py`, [outcome file](#outcome-file) tools) sim… 17 * Test descriptions must be unique within a `.data` file. If you can't think of a better descriptio… 18 …a failure log to the test data. Avoid confusion between cases in the [outcome file](#outcome-file). 45 ### Outcome file 47 #### Generating an outcome file argument 49 … outcome file**. This feature is enabled if the environment variable `MBEDTLS_TEST_OUTCOME_FILE` i… 51 If you run `all.sh --outcome-file test-outcome.csv`, this collects the outcome of all the test case… 53 #### Outcome file format argument 55 The outcome file is in a CSV format using `;` (semicolon) as the delimiter and no quoting. This mea… [all …]
|
| /mbedtls/scripts/ |
| A D | generate_driver_wrappers.py | 63 with open(file=os.path.join(output_dir, os.path.splitext(template_file_name)[0]), 86 " for driver " + driver_prefix, str(err), file=sys.stderr) 96 " ".format(driverjson_data, _schema, str(err)), file=sys.stderr) 102 with open(file=driver_file, mode='r', encoding='UTF-8') as f: 129 with open(file=file_path, mode='r', encoding='UTF-8') as file: 130 driver_schema[key] = json.load(file) 142 with open(file=os.path.join(json_directory, jsondriver_list), 152 def trace_exception(e: Exception, file=sys.stderr) -> None: argument 156 ), file)
|
| A D | generate_errors.pl | 54 foreach my $file (@files) { 55 open(FILE, '<:crlf', $file) or die("$0: $file: $!"); 77 die "Description neither before nor after $name in $file\n" 79 die "Description both before and after $name in $file\n" 89 my $include_name = $file;
|
| /mbedtls/docs/proposed/ |
| A D | psa-driver-wrappers-codegen-migration-guide.md | 1 Migrating to an auto generated psa_crypto_driver_wrappers.h file 4 This document describes how to migrate to the auto generated psa_crypto_driver_wrappers.h file. 24 …a2 ) to render templates based on drivers that are defined using a Driver description JSON file(s). 31 (2) The auto generation is based on the template file at **scripts/data_files/driver_templates/psa_… 32 (3) The driver JSONS to be used for generating the psa_crypto_driver_wrappers.h file can be found a… 33 …es a need to patch psa_crypto_driver_wrappers.h file, the user will need to patch into the templat… 40 The JSON file 'driverlist.json' is meant to be edited by the user to reflect the drivers one wants …
|
| A D | psa-driver-developer-guide.md | 26 …file**. The driver description file declares which functions the driver implements and what crypto… 28 The concrete syntax for a driver description file is JSON. The structure of this JSON file is speci… 32 * A driver description file (in JSON format). 33 …the driver description. The names of these header files is declared in the driver description file. 34 * An object file compiled for the target platform defining the functions required by the driver des…
|
| /mbedtls/tests/ |
| A D | CMakeLists.txt | 18 file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/suites) 57 # Derive generated file paths in the build directory. The generated data 66 foreach(file ${base_bignum_generated_data_files}) 69 foreach(file ${base_ecp_generated_data_files}) 70 list(APPEND ecp_generated_data_files ${CMAKE_CURRENT_BINARY_DIR}/suites/${file}) 72 foreach(file ${base_psa_generated_data_files}) 73 list(APPEND psa_generated_data_files ${CMAKE_CURRENT_BINARY_DIR}/suites/${file}) 135 foreach(file ${all_generated_data_files}) 136 link_to_source(${file}) 229 --helpers-file ${CMAKE_CURRENT_SOURCE_DIR}/suites/helpers.function [all …]
|
| /mbedtls/include/mbedtls/ |
| A D | error.h | 143 const char *file, int line) in mbedtls_error_add() argument 147 (*mbedtls_test_hook_error_add)(high, low, file, line); in mbedtls_error_add() 150 (void) file; in mbedtls_error_add()
|
| /mbedtls/tests/scripts/ |
| A D | gen_gcm_encrypt.pl | 11 my $file = shift; 13 open(TEST_DATA, "$file") or die "Opening test cases '$file': $!";
|
| A D | gen_pkcs1_v21_sign_verify.pl | 8 my $file = shift; 10 open(TEST_DATA, "$file") or die "Opening test cases '$file': $!";
|
| /mbedtls/programs/pkey/ |
| A D | gen_key.c | 45 FILE *file; in dev_random_entropy_poll() local 52 file = fopen("/dev/random", "rb"); in dev_random_entropy_poll() 53 if (file == NULL) { in dev_random_entropy_poll() 59 ret = fread(p, 1, left, file); in dev_random_entropy_poll() 60 if (ret == 0 && ferror(file)) { in dev_random_entropy_poll() 61 fclose(file); in dev_random_entropy_poll() 69 fclose(file); in dev_random_entropy_poll()
|