Home
last modified time | relevance | path

Searched refs:bytes (Results 1 – 25 of 87) sorted by relevance

1234

/mbedtls-latest/tests/suites/
Dtest_suite_cipher.camellia.data9 CAMELLIA Encrypt and decrypt 0 bytes [#1]
17 CAMELLIA Encrypt and decrypt 2 bytes [#1]
21 CAMELLIA Encrypt and decrypt 7 bytes [#1]
25 CAMELLIA Encrypt and decrypt 8 bytes [#1]
29 CAMELLIA Encrypt and decrypt 9 bytes [#1]
33 CAMELLIA Encrypt and decrypt 15 bytes [#1]
37 CAMELLIA Encrypt and decrypt 16 bytes [#1]
41 CAMELLIA Encrypt and decrypt 17 bytes [#1]
45 CAMELLIA Encrypt and decrypt 31 bytes [#1]
49 CAMELLIA Encrypt and decrypt 32 bytes [#1]
[all …]
Dtest_suite_cipher.des.data13 DES Encrypt and decrypt 0 bytes [#1]
21 DES Encrypt and decrypt 2 bytes
25 DES Encrypt and decrypt 7 bytes
29 DES Encrypt and decrypt 8 bytes
33 DES Encrypt and decrypt 9 bytes
37 DES Encrypt and decrypt 15 bytes
41 DES Encrypt and decrypt 16 bytes
45 DES Encrypt and decrypt 17 bytes
49 DES Encrypt and decrypt 31 bytes
53 DES Encrypt and decrypt 32 bytes [#1]
[all …]
Dtest_suite_bignum_mod_raw.function130 size_t bytes = limbs * sizeof(mbedtls_mpi_uint);
142 TEST_CF_SECRET(X, bytes);
143 TEST_CF_SECRET(Y, bytes);
147 TEST_CF_PUBLIC(X, bytes);
148 TEST_CF_PUBLIC(Y, bytes);
150 TEST_ASSERT(memcmp(X, Y, bytes) != 0);
153 TEST_CF_SECRET(X, bytes);
154 TEST_CF_SECRET(Y, bytes);
158 TEST_CF_PUBLIC(X, bytes);
159 TEST_CF_PUBLIC(Y, bytes);
[all …]
Dtest_suite_cipher.aria.data5 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 0 bytes
13 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 2 bytes
17 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 7 bytes
21 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 8 bytes
25 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 9 bytes
29 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 15 bytes
33 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 16 bytes
37 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 17 bytes
41 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 31 bytes
45 ARIA-128 CCM*-NO-TAG - Encrypt and decrypt 32 bytes
[all …]
Dtest_suite_cipher.aes.data9 AES-128 CBC - Encrypt and decrypt 0 bytes with PKCS7 padding
17 AES-128 CBC - Encrypt and decrypt 2 bytes with PKCS7 padding
21 AES-128 CBC - Encrypt and decrypt 7 bytes with PKCS7 padding
25 AES-128 CBC - Encrypt and decrypt 8 bytes with PKCS7 padding
29 AES-128 CBC - Encrypt and decrypt 9 bytes with PKCS7 padding
33 AES-128 CBC - Encrypt and decrypt 15 bytes with PKCS7 padding
37 AES-128 CBC - Encrypt and decrypt 16 bytes with PKCS7 padding
41 AES-128 CBC - Encrypt and decrypt 17 bytes with PKCS7 padding
45 AES-128 CBC - Encrypt and decrypt 31 bytes with PKCS7 padding
49 AES-128 CBC - Encrypt and decrypt 32 bytes with PKCS7 padding
[all …]
Dtest_suite_cipher.null.data1 NULL Encrypt and decrypt 0 bytes
5 NULL Encrypt and decrypt 1 bytes
9 NULL Encrypt and decrypt 2 bytes
13 NULL Encrypt and decrypt 7 bytes
17 NULL Encrypt and decrypt 8 bytes
21 NULL Encrypt and decrypt 9 bytes
25 NULL Encrypt and decrypt 15 bytes
29 NULL Encrypt and decrypt 16 bytes
33 NULL Encrypt and decrypt 31 bytes
37 NULL Encrypt and decrypt 32 bytes
[all …]
Dtest_suite_cipher.chacha20.data9 ChaCha20 Encrypt and decrypt 0 bytes
13 ChaCha20 Encrypt and decrypt 1 bytes
17 ChaCha20 Encrypt and decrypt 2 bytes
21 ChaCha20 Encrypt and decrypt 7 bytes
25 ChaCha20 Encrypt and decrypt 8 bytes
29 ChaCha20 Encrypt and decrypt 9 bytes
33 ChaCha20 Encrypt and decrypt 15 bytes
37 ChaCha20 Encrypt and decrypt 16 bytes
41 ChaCha20 Encrypt and decrypt 17 bytes
45 ChaCha20 Encrypt and decrypt 31 bytes
[all …]
Dtest_suite_cipher.chachapoly.data5 ChaCha20+Poly1305 Encrypt and decrypt 0 bytes
9 ChaCha20+Poly1305 Encrypt and decrypt 1 bytes
13 ChaCha20+Poly1305 Encrypt and decrypt 2 bytes
17 ChaCha20+Poly1305 Encrypt and decrypt 7 bytes
21 ChaCha20+Poly1305 Encrypt and decrypt 8 bytes
25 ChaCha20+Poly1305 Encrypt and decrypt 9 bytes
29 ChaCha20+Poly1305 Encrypt and decrypt 15 bytes
33 ChaCha20+Poly1305 Encrypt and decrypt 16 bytes
37 ChaCha20+Poly1305 Encrypt and decrypt 17 bytes
41 ChaCha20+Poly1305 Encrypt and decrypt 31 bytes
[all …]
Dtest_suite_bignum_core.function28 size_t bytes = limbs * sizeof(*A);
37 TEST_MEMORY_COMPARE(X, bytes, S, bytes);
40 memcpy(X, A, bytes);
42 TEST_MEMORY_COMPARE(X, bytes, S, bytes);
45 memcpy(X, B, bytes);
47 TEST_MEMORY_COMPARE(X, bytes, S, bytes);
49 if (memcmp(A, B, bytes) == 0) {
54 TEST_MEMORY_COMPARE(X, bytes, S, bytes);
57 memcpy(X, A, bytes);
59 TEST_MEMORY_COMPARE(X, bytes, S, bytes);
[all …]
Dtest_suite_cipher.padding.data68 Check PKCS padding #6 (too few padding bytes)
72 Check PKCS padding #7 (non-uniform padding bytes #1)
76 Check PKCS padding #7 (non-uniform padding bytes #2)
80 Check PKCS padding #7 (non-uniform padding bytes #3)
84 Check PKCS padding #7 (non-uniform padding bytes #4)
88 Check PKCS padding #7 (non-uniform padding bytes #5)
92 Check PKCS padding #7 (non-uniform padding bytes #6)
96 Check PKCS padding #7 (non-uniform padding bytes #7)
100 Check PKCS padding #7 (non-uniform padding bytes #8)
104 Check PKCS padding #7 (non-uniform padding bytes #9)
[all …]
Dtest_suite_bignum_mod.function120 const size_t bytes = limbs * sizeof(mbedtls_mpi_uint);
131 TEST_MEMORY_COMPARE(rX.p, bytes, rR.p, bytes);
134 memcpy(rX.p, rA.p, bytes);
136 TEST_MEMORY_COMPARE(rX.p, bytes, rR.p, bytes);
139 memcpy(rX.p, rB.p, bytes);
141 TEST_MEMORY_COMPARE(rX.p, bytes, rR.p, bytes);
144 if (memcmp(rA.p, rB.p, bytes) == 0) {
146 TEST_MEMORY_COMPARE(rX.p, bytes, rR.p, bytes);
149 memcpy(rX.p, rA.p, bytes);
151 TEST_MEMORY_COMPARE(rX.p, bytes, rR.p, bytes);
[all …]
Dtest_suite_bignum_core.misc.data194 mbedtls_mpi_core_lt_ct: x>y (64 bit x, first bytes equal)
197 mbedtls_mpi_core_lt_ct: x<y (64 bit y, first bytes equal)
224 mbedtls_mpi_core_lt_ct: x>y (32 bit x, first bytes equal)
227 mbedtls_mpi_core_lt_ct: x<y (32 bit y, first bytes equal)
320 mbedtls_mpi_core_cond_assign: copy 256 bytes of limbs
341 mbedtls_mpi_core_cond_swap: copy 256 bytes of limbs
428 Fill random core: 0 bytes
449 Fill random core: 8 bytes, RNG stops before
452 Fill random core: 8 bytes, RNG just sufficient
455 Fill random core: 8 bytes, RNG not exhausted
[all …]
Dtest_suite_asn1parse.data10 Prefixes of OCTET STRING, length=0 (0 length bytes)
64 length=0 (2 length bytes)
73 length=1 (2 length bytes)
76 length=1 (3 length bytes)
79 length=1 (4 length bytes)
88 length=2 (2 length bytes)
91 length=2 (3 length bytes)
94 length=2 (4 length bytes)
103 length=128 (2 length bytes)
109 length=255 (2 length bytes)
[all …]
Dtest_suite_psa_crypto_driver_wrappers.data322 PSA symmetric encrypt validation: AES-CTR, 16 bytes, good
326 PSA symmetric encrypt validation: AES-CTR, 15 bytes, good
330 PSA symmetric encrypt validation: AES-CTR, 16 bytes, fallback
334 PSA symmetric encrypt validation: AES-CTR, 15 bytes, fallback
338 PSA symmetric encrypt multipart: AES-CTR, 16 bytes, good
342 PSA symmetric encrypt multipart: AES-CTR, 15 bytes, good
346 PSA symmetric encrypt multipart: AES-CTR, 16 bytes, fallback
350 PSA symmetric encrypt multipart: AES-CTR, 15 bytes, fallback
354 PSA symmetric encrypt multipart: AES-CTR, 16 bytes, fake
358 PSA symmetric encrypt multipart: AES-CTR, 15 bytes, fake
[all …]
Dtest_suite_psa_its.data1 Set/get/remove 0 bytes
4 Set/get/remove 42 bytes
7 Set/get/remove 1000 bytes
40 Get 0 bytes of 10 at 10
46 Get 0 bytes of 10 at 0
52 Get 2 bytes of 10 at 1
61 Get 0 bytes of 10 at 11: out of range
Dtest_suite_lms.data18 # word at the start of the key/sig. We strip these 4 bytes from the signature
22 # signature bytes will differ due to randomization):
32 # message1 = bytes.fromhex('60da1a17c88c59da8a730e6ca8effd37')
43 # signature bytes will differ due to randomization), after generating the
46 # message2 = bytes.fromhex('92d036bde8c45b8bb5dea2a072560b1e29fc4bb7dc4549ce90bccee8a6e962a1')
58 # "levels" word at the start of the key/sig. We strip these 4 bytes from the
62 # signature bytes will differ due to randomization):
90 # 4-byte "levels" word at the start of the key/sig. We strip these 4 bytes from
94 # signature bytes will differ due to randomization):
118 # 4-byte "levels" word at the start of the key/sig. We strip these 4 bytes from
[all …]
Dtest_suite_psa_crypto.data7 PSA import/export raw: 1 bytes
10 PSA import/export raw: 1 bytes, larger buffer
13 PSA import/export raw: 2 bytes, buffer too small
28 PSA import/export raw: 1 bytes, opaque
32 PSA import/export raw: 1 bytes, larger buffer, opaque
36 PSA import/export raw: 2 bytes, buffer too small, opaque
1766 PSA MAC setup: truncated MAC too large (33 bytes for SHA-256)
2010 PSA MAC sign: HMAC-SHA-224, truncated to 28 bytes (actual size)
2014 PSA MAC verify: HMAC-SHA-224, truncated to 28 bytes (actual size)
2018 PSA MAC sign multipart: HMAC-SHA-224, truncated to 28 bytes (actual size)
[all …]
Dtest_suite_cipher.gcm.data13 AES 128 GCM Encrypt and decrypt 0 bytes
21 AES 128 GCM Encrypt and decrypt 2 bytes
25 AES 128 GCM Encrypt and decrypt 7 bytes
29 AES 128 GCM Encrypt and decrypt 8 bytes
33 AES 128 GCM Encrypt and decrypt 9 bytes
37 AES 128 GCM Encrypt and decrypt 15 bytes
41 AES 128 GCM Encrypt and decrypt 16 bytes
45 AES 128 GCM Encrypt and decrypt 17 bytes
49 AES 128 GCM Encrypt and decrypt 31 bytes
53 AES 128 GCM Encrypt and decrypt 32 bytes [#1]
[all …]
Dtest_suite_bignum.misc.data1733 Fill random: 0 bytes
1739 Fill random: 2 bytes, good, no leading zero
1742 Fill random: 2 bytes, good, 1 leading zero
1751 Fill random: 0 bytes, previously small >0
1754 Fill random: 0 bytes, previously small <0
1757 Fill random: 0 bytes, previously large >0
1760 Fill random: 0 bytes, previously large <0
1775 Fill random: 9 bytes, previously small >0
1778 Fill random: 9 bytes, previously small <0
1784 Fill random: 2 bytes, RNG failure after 1 byte
[all …]
Dtest_suite_ecp.function1567 size_t bytes;
1578 bytes = limbs_N * sizeof(mbedtls_mpi_uint);
1666 TEST_MEMORY_COMPARE(X, bytes, res, bytes);
1685 size_t bytes;
1696 bytes = p_limbs * sizeof(mbedtls_mpi_uint);
1707 TEST_MEMORY_COMPARE(p, bytes, m.p, bytes);
1781 size_t bytes;
1800 bytes = p_A_limbs * ciL;
1814 TEST_MEMORY_COMPARE(rA.p, bytes, rS.p, bytes);
1831 size_t bytes;
[all …]
Dtest_suite_gcm.aes128_en.data673 AES-GCM NIST CAVS 14.0 - empty plaintext, AD length: 128 bytes, ciphertext updates: 0
677 AES-GCM NIST CAVS 14.0 - empty plaintext, AD length: 128 bytes, ciphertext updates: 1
681 AES-GCM NIST CAVS 14.0 - empty plaintext, AD length: 128 bytes, ciphertext updates: 2
685 AES-GCM NIST CAVS 14.0 - empty plaintext, AD length: 90 bytes, ciphertext updates: 0
689 AES-GCM NIST CAVS 14.0 - empty plaintext, AD length: 90 bytes, ciphertext updates: 1
693 AES-GCM NIST CAVS 14.0 - empty plaintext, AD length: 90 bytes, ciphertext updates: 2
697 AES-GCM NIST CAVS 14.0 - empty AD, plaintext length: 128 bytes, AD updates: 0
701 AES-GCM NIST CAVS 14.0 - empty AD, plaintext length: 128 bytes, AD updates: 1
705 AES-GCM NIST CAVS 14.0 - empty AD, plaintext length: 128 bytes, AD updates: 2
709 AES-GCM NIST CAVS 14.0 - empty AD, plaintext length: 51 bytes, AD updates: 0
[all …]
Dtest_suite_lmots.data25 # signature bytes will differ due to randomization):
36 # message = bytes.fromhex('60da1a17c88c59da8a730e6ca8effd37')
50 # signature bytes will differ due to randomization):
61 #message = bytes.fromhex('92d036bde8c45b8bb5dea2a072560b1e29fc4bb7dc4549ce90bccee8a6e962a1')
73 # signature bytes will differ due to randomization):
84 #message = bytes()
/mbedtls-latest/docs/architecture/
Dmbed-crypto-storage-specification.md51 All integers are encoded in little-endian order in 8-bit bytes.
55 * magic (8 bytes): `"PSA\0KEY\0"`
56 * version (4 bytes): 0
57 * type (4 bytes): `psa_key_type_t` value
58 * policy usage flags (4 bytes): `psa_key_usage_t` value
59 * policy usage algorithm (4 bytes): `psa_algorithm_t` value
60 * key material length (4 bytes)
189 * Magic header (8 bytes): `"PSA\0ITS\0"`
201 All integers are encoded in little-endian order in 8-bit bytes.
205 * magic (8 bytes): `"PSA\0KEY\0"`
[all …]
/mbedtls-latest/library/
Dpsa_crypto.c728 slot->key.bytes = buffer_length; in psa_allocate_buffer_to_slot()
1196 if (slot->key.bytes > 0) { in psa_remove_key_data_from_memory()
1201 mbedtls_zeroize_and_free(slot->key.data, slot->key.bytes); in psa_remove_key_data_from_memory()
1207 slot->key.bytes = 0; in psa_remove_key_data_from_memory()
1549 slot->key.data, slot->key.bytes, in psa_export_key()
1666 &slot->attr, slot->key.data, slot->key.bytes, in psa_export_public_key()
1964 slot->key.bytes);
2125 if (slot->key.bytes == 0) {
2143 slot->key.bytes,
2144 &slot->key.bytes, &bits);
[all …]
/mbedtls-latest/tests/scripts/
Daudit-validity-dates.py106 typing.Callable[[bytes], object]]]) \ argument
116 def wrapper(data: bytes): argument
143 def pem_data_type(data: bytes) -> typing.Optional[str]: argument
230 def parse_bytes(self, data: bytes): argument
363 audit_data = self.parse_bytes(bytes.fromhex(match.group('data')))

1234