/mbedtls-development/programs/psa/ |
A D | psa_constant_names.c | 62 *buffer += length; in append() 208 char buffer[200]; in process_signed() local 226 psa_snprint_status(buffer, sizeof(buffer), in process_signed() 230 puts(buffer); in process_signed() 247 char buffer[200]; in process_unsigned() local 261 psa_snprint_algorithm(buffer, sizeof(buffer), in process_unsigned() 265 psa_snprint_ecc_curve(buffer, sizeof(buffer), in process_unsigned() 269 psa_snprint_dh_group(buffer, sizeof(buffer), in process_unsigned() 273 psa_snprint_key_type(buffer, sizeof(buffer), in process_unsigned() 277 psa_snprint_key_usage(buffer, sizeof(buffer), in process_unsigned() [all …]
|
A D | key_ladder_demo.c | 369 unsigned char *buffer = NULL; in wrap_data() local 415 buffer, input_size, in wrap_data() 416 buffer, buffer_size, in wrap_data() 423 SYS_CHECK( fwrite( buffer, 1, ciphertext_size, in wrap_data() 433 if( buffer != NULL ) in wrap_data() 435 free( buffer ); in wrap_data() 448 unsigned char *buffer = NULL; in unwrap_data() local 485 SYS_CHECK( fread( buffer, 1, ciphertext_size, in unwrap_data() 512 SYS_CHECK( fwrite( buffer, 1, plaintext_size, in unwrap_data() 522 if( buffer != NULL ) in unwrap_data() [all …]
|
/mbedtls-development/tests/suites/ |
A D | test_suite_debug.function | 14 char *p = buffer->ptr; 41 buffer->ptr = p; 56 struct buffer_data buffer; 61 buffer.ptr = buffer.buf; 91 struct buffer_data buffer; 96 buffer.ptr = buffer.buf; 123 struct buffer_data buffer; 128 buffer.ptr = buffer.buf; 156 struct buffer_data buffer; 162 buffer.ptr = buffer.buf; [all …]
|
A D | test_suite_memory_buffer_alloc.data | 1 Memory buffer alloc self test 4 Memory buffer alloc - free in middle, alloc at end 7 Memory buffer alloc - free in middle, realloc 10 Memory buffer alloc - free in middle, merge, realloc 13 Memory buffer alloc - free at end, merge, realloc 16 Memory buffer alloc - Out of Memory test 19 Memory buffer: heap too small (header verification should fail) 22 Memory buffer: attempt to allocate SIZE_MAX
|
A D | test_suite_psa_its.function | 87 unsigned char *buffer = NULL; 90 ASSERT_ALLOC( buffer, data->len ); 103 mbedtls_free( buffer ); 117 unsigned char *buffer = NULL; 140 mbedtls_free( buffer ); 208 unsigned char *buffer = NULL; 215 ASSERT_ALLOC( buffer, length + 16 ); 216 trailer = buffer + length; 231 mbedtls_free( buffer ); 242 unsigned char *buffer = NULL; [all …]
|
A D | test_suite_base64.data | 31 Test case mbedtls_base64_encode #1 buffer just right 34 Test case mbedtls_base64_encode #2 buffer just right 37 Test case mbedtls_base64_encode #2 buffer too small 40 Test case mbedtls_base64_encode #3 buffer just right 43 Test case mbedtls_base64_encode #3 buffer too small 46 Test case mbedtls_base64_encode #4 buffer just right 49 Test case mbedtls_base64_encode #4 buffer too small 55 Test case mbedtls_base64_encode #5 buffer too small 175 Base64 encode hex #2 (buffer too small) 201 Base64 decode hex #2 (buffer too small) [all …]
|
A D | test_suite_hmac_drbg.misc.data | 61 HMAC_DRBG from buffer SHA-1 65 HMAC_DRBG from buffer SHA-224 69 HMAC_DRBG from buffer SHA-256 73 HMAC_DRBG from buffer SHA-384 77 HMAC_DRBG from buffer SHA-512
|
A D | test_suite_pkcs1_v15.data | 4 RSAES-V15 Decryption empty output with NULL buffer 43 RSAES-V15 decoding: good, payload=max, tight output buffer 46 RSAES-V15 decoding: good, payload=max, larger output buffer 49 RSAES-V15 decoding: good, payload=max-1, tight output buffer 52 RSAES-V15 decoding: good, payload=max-1, larger output buffer
|
A D | test_suite_psa_crypto_se_driver_hal.function | 676 buffer, sizeof( buffer ), &length ) ); 698 buffer, sizeof( buffer ), 700 buffer, sizeof( buffer), 701 buffer, sizeof( buffer), &length ) ); 703 buffer, sizeof( buffer ), 705 buffer, sizeof( buffer), 706 buffer, sizeof( buffer), &length ) ); 710 buffer, sizeof( buffer ), &length ) ); 713 buffer, sizeof( buffer ) ) ); 736 if( psa_export_public_key( key, buffer, sizeof( buffer ), &length ) == [all …]
|
A D | test_suite_psa_crypto.function | 38 * `mem_is_char(buffer, c, size)` is true after `memset(buffer, c, size)`. 40 * \param buffer Pointer to the beginning of the buffer. 233 TEST_EQUAL( psa_export_key( key, buffer, sizeof( buffer ), &length ), 2694 buffer, sizeof( buffer ), 2702 buffer, sizeof( buffer ), 2706 buffer, sizeof( buffer ), 2718 buffer, sizeof( buffer ), 2744 buffer, sizeof( buffer ), 2754 buffer, sizeof( buffer ), 2764 buffer, sizeof( buffer ), [all …]
|
A D | test_suite_ecp.data | 172 ECP write binary #1 (zero, uncompressed, buffer just fits) 176 ECP write binary #2 (zero, buffer too small) 188 ECP write binary #5 (zero, compressed, buffer just fits) 192 ECP write binary #6 (zero, buffer too small) 196 ECP write binary #7 (even, compressed, buffer just fits) 200 ECP write binary #8 (even, compressed, buffer too small) 204 ECP write binary #9 (odd, compressed, buffer just fits) 216 ECP write binary #12 (Montgomery curve448, buffer just fits) 220 ECP write binary #13 (Montgomery curve448, buffer too small) 321 ECP tls read group #4 (OK, buffer just fits) [all …]
|
A D | test_suite_ssl.function | 119 unsigned char *buffer; 139 if( NULL == buf->buffer ) 148 if( buf->buffer != NULL ) 149 mbedtls_free( buf->buffer ); 155 * Puts \p input_len bytes from the \p input buffer into the ring buffer \p buf. 216 * \p output buffer. The output buffer can be NULL, in this case a part of the 2604 * (to wrap around the buffer) */ 2888 * receiver's buffer. */ 3000 * (to wrap around the buffer) */ 3169 * within the record buffer. [all …]
|
A D | test_suite_pkwrite.function | 33 // check that the rest of the buffer remains clear 74 // check that the rest of the buffer remains clear
|
A D | test_suite_debug.data | 25 Debug print buffer #1 28 Debug print buffer #2 31 Debug print buffer #3 34 Debug print buffer #4 37 Debug print buffer #5
|
A D | test_suite_mps.function | 31 * - The 'producing' layer provides a buffer 74 * - The 'producing' layer provides a buffer 125 * - The 'producing' layer provides a buffer 299 * holding the buffer length. 441 /* In all cases, fetch the rest of the second buffer. */ 580 /* Fetch (but not commit) the entire buffer. */ 587 /* Fetch (but not commit) parts of the buffer. */ 594 /* Fetch and commit parts of the buffer, then 595 * fetch but not commit the rest of the buffer. */ 701 * then exceed bounds of new buffer; accumulator [all …]
|
A D | test_suite_asn1write.data | 229 ASN.1 Write / Read Length #2 (Len = 127, buffer too small) 238 ASN.1 Write / Read Length #5 (Len = 255, buffer too small) 247 ASN.1 Write / Read Length #8 (Len = 65535, buffer too small) 256 ASN.1 Write / Read Length #11 (Len = 16777215, buffer too small) 262 ASN.1 Write / Read Length #12 (Len = 16909060, buffer too small)
|
A D | test_suite_dhm.function | 25 const unsigned char *buffer, 37 n = ( buffer[*offset] << 8 ) | buffer[*offset + 1]; 43 TEST_EQUAL( 0, mbedtls_mpi_read_binary( &actual, buffer + *offset, n ) );
|
/mbedtls-development/ChangeLog.d/ |
A D | psa_gcm_buffer_limitation.txt | 2 * Remove PSA'a AEAD finish/verify output buffer limitation for GCM. 3 The requirement of minimum 15 bytes for output buffer in 6 * Move GCM's update output buffer length verification from PSA AEAD to 8 The requirement for output buffer size to be equal or greater then 9 input buffer size is valid only for the built-in implementation of GCM. 16 MBEDTLS_ERR_GCM_BUFFER_TOO_SMALL in case the buffer length is too small.
|
/mbedtls-development/programs/aes/ |
A D | crypt_and_hash.c | 93 unsigned char buffer[1024]; in main() local 276 buffer[i] = (unsigned char)( filesize >> ( i << 3 ) ); in main() 281 mbedtls_md_update( &md_ctx, buffer, 8 ); in main() 341 if( fread( buffer, 1, ilen, fin ) != ilen ) in main() 430 if( fread( buffer, 1, 16, fin ) != 16 ) in main() 436 memcpy( IV, buffer, 16 ); in main() 484 if( fread( buffer, 1, ilen, fin ) != ilen ) in main() 491 mbedtls_md_hmac_update( &md_ctx, buffer, ilen ); in main() 492 if( mbedtls_cipher_update( &cipher_ctx, buffer, ilen, output, in main() 520 diff |= digest[i] ^ buffer[i]; in main() [all …]
|
/mbedtls-development/library/ |
A D | base64.c | 303 unsigned char buffer[128]; in mbedtls_base64_self_test() local 310 if( mbedtls_base64_encode( buffer, sizeof( buffer ), &len, src, 64 ) != 0 || in mbedtls_base64_self_test() 311 memcmp( base64_test_enc, buffer, 88 ) != 0 ) in mbedtls_base64_self_test() 324 if( mbedtls_base64_decode( buffer, sizeof( buffer ), &len, src, 88 ) != 0 || in mbedtls_base64_self_test() 325 memcmp( base64_test_dec, buffer, 64 ) != 0 ) in mbedtls_base64_self_test()
|
A D | sha512.c | 323 memcpy( (void *) (ctx->buffer + left), input, fill ); in mbedtls_sha512_update() 325 if( ( ret = mbedtls_internal_sha512_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_sha512_update() 343 memcpy( (void *) (ctx->buffer + left), input, ilen ); in mbedtls_sha512_update() 366 ctx->buffer[used++] = 0x80; in mbedtls_sha512_finish() 371 memset( ctx->buffer + used, 0, 112 - used ); in mbedtls_sha512_finish() 376 memset( ctx->buffer + used, 0, 128 - used ); in mbedtls_sha512_finish() 378 if( ( ret = mbedtls_internal_sha512_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_sha512_finish() 381 memset( ctx->buffer, 0, 112 ); in mbedtls_sha512_finish() 391 sha512_put_uint64_be( high, ctx->buffer, 112 ); in mbedtls_sha512_finish() 392 sha512_put_uint64_be( low, ctx->buffer, 120 ); in mbedtls_sha512_finish() [all …]
|
A D | md5.c | 244 memcpy( (void *) (ctx->buffer + left), input, fill ); in mbedtls_md5_update() 245 if( ( ret = mbedtls_internal_md5_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_md5_update() 264 memcpy( (void *) (ctx->buffer + left), input, ilen ); in mbedtls_md5_update() 285 ctx->buffer[used++] = 0x80; in mbedtls_md5_finish() 290 memset( ctx->buffer + used, 0, 56 - used ); in mbedtls_md5_finish() 295 memset( ctx->buffer + used, 0, 64 - used ); in mbedtls_md5_finish() 297 if( ( ret = mbedtls_internal_md5_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_md5_finish() 300 memset( ctx->buffer, 0, 56 ); in mbedtls_md5_finish() 310 MBEDTLS_PUT_UINT32_LE( low, ctx->buffer, 56 ); in mbedtls_md5_finish() 311 MBEDTLS_PUT_UINT32_LE( high, ctx->buffer, 60 ); in mbedtls_md5_finish() [all …]
|
A D | sha256.c | 290 memcpy( (void *) (ctx->buffer + left), input, fill ); in mbedtls_sha256_update() 292 if( ( ret = mbedtls_internal_sha256_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_sha256_update() 310 memcpy( (void *) (ctx->buffer + left), input, ilen ); in mbedtls_sha256_update() 333 ctx->buffer[used++] = 0x80; in mbedtls_sha256_finish() 338 memset( ctx->buffer + used, 0, 56 - used ); in mbedtls_sha256_finish() 343 memset( ctx->buffer + used, 0, 64 - used ); in mbedtls_sha256_finish() 345 if( ( ret = mbedtls_internal_sha256_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_sha256_finish() 348 memset( ctx->buffer, 0, 56 ); in mbedtls_sha256_finish() 358 MBEDTLS_PUT_UINT32_BE( high, ctx->buffer, 56 ); in mbedtls_sha256_finish() 359 MBEDTLS_PUT_UINT32_BE( low, ctx->buffer, 60 ); in mbedtls_sha256_finish() [all …]
|
A D | sha1.c | 297 memcpy( (void *) (ctx->buffer + left), input, fill ); in mbedtls_sha1_update() 299 if( ( ret = mbedtls_internal_sha1_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_sha1_update() 317 memcpy( (void *) (ctx->buffer + left), input, ilen ); in mbedtls_sha1_update() 340 ctx->buffer[used++] = 0x80; in mbedtls_sha1_finish() 345 memset( ctx->buffer + used, 0, 56 - used ); in mbedtls_sha1_finish() 350 memset( ctx->buffer + used, 0, 64 - used ); in mbedtls_sha1_finish() 352 if( ( ret = mbedtls_internal_sha1_process( ctx, ctx->buffer ) ) != 0 ) in mbedtls_sha1_finish() 355 memset( ctx->buffer, 0, 56 ); in mbedtls_sha1_finish() 365 MBEDTLS_PUT_UINT32_BE( high, ctx->buffer, 56 ); in mbedtls_sha1_finish() 366 MBEDTLS_PUT_UINT32_BE( low, ctx->buffer, 60 ); in mbedtls_sha1_finish() [all …]
|
A D | mps_reader.c | 235 unsigned char **buffer, in mbedtls_mps_reader_get() argument 344 *buffer = acc; in mbedtls_mps_reader_get() 394 *buffer = frag; in mbedtls_mps_reader_get()
|