Home
last modified time | relevance | path

Searched refs:ciphertext (Results 1 – 25 of 94) sorted by relevance

1234

/third_party/node/test/fixtures/wpt/WebCryptoAPI/encrypt_decrypt/
Drsa_vectors.js31 var ciphertext = { variable
54 ciphertext: ciphertext["sha-1, no label"] property
67 ciphertext: ciphertext["sha-256, no label"] property
80 ciphertext: ciphertext["sha-384, no label"] property
93 ciphertext: ciphertext["sha-512, no label"] property
106 ciphertext: ciphertext["sha-1, no label"] property
119 ciphertext: ciphertext["sha-256, no label"] property
132 ciphertext: ciphertext["sha-384, no label"] property
145 ciphertext: ciphertext["sha-512, no label"] property
158 ciphertext: ciphertext["sha-1, with label"] property
[all …]
Drsa.js24 return subtle.decrypt(vector.algorithm, vector.privateKey, vector.ciphertext)
53 var ciphertext = copyBuffer(vector.ciphertext);
54 var operation = subtle.decrypt(vector.algorithm, vector.privateKey, ciphertext)
60 ciphertext[0] = 255 - ciphertext[0];
80 return subtle.decrypt(vector.algorithm, vector.publicKey, vector.ciphertext)
108 return subtle.decrypt(vector.algorithm, vector.publicKey, vector.ciphertext)
135 .then(function(ciphertext) { argument
136 …assert_equals(ciphertext.byteLength * 8, vector.privateKey.algorithm.modulusLength, "Ciphertext le…
138 return subtle.decrypt(vector.algorithm, vector.privateKey, ciphertext)
141 return ciphertext;
[all …]
Daes_gcm_vectors.js21 ciphertext,
33 var result = new Uint8Array(ciphertext[keyLength].byteLength + byteCount);
34 result.set(ciphertext[keyLength], 0);
35 result.set(tag[keyLength].slice(0, byteCount), ciphertext[keyLength].byteLength);
45 var noadresult = new Uint8Array(ciphertext[keyLength].byteLength + byteCount);
46 noadresult.set(ciphertext[keyLength], 0);
47 …noadresult.set(tag_with_empty_ad[keyLength].slice(0, byteCount), ciphertext[keyLength].byteLength);
70 result: ciphertext[keyLength]
Daes_cbc_vectors.js77 var ciphertext = { variable
211 result: ciphertext[keyLength]
225 result: ciphertext[keyLength]
237 result: ciphertext[keyLength]
245 var badCiphertext = new Uint8Array(ciphertext[keyLength].byteLength);
246 … badCiphertext.set(ciphertext[keyLength].slice(0, ciphertext[keyLength].byteLength - 16));
Daes_ctr_vectors.js77 var ciphertext = { variable
96 result: ciphertext[keyLength]
109 result: ciphertext[keyLength]
118 result: ciphertext[keyLength]
/third_party/node/test/fixtures/crypto/
Drsa.js77 const ciphertext = { variable
180 ciphertext: ciphertext['sha-1, no label'] property
193 ciphertext: ciphertext['sha-256, no label'] property
206 ciphertext: ciphertext['sha-384, no label'] property
219 ciphertext: ciphertext['sha-512, no label'] property
232 ciphertext: ciphertext['sha-1, no label'] property
245 ciphertext: ciphertext['sha-256, no label'] property
258 ciphertext: ciphertext['sha-384, no label'] property
271 ciphertext: ciphertext['sha-512, no label'] property
284 ciphertext: ciphertext['sha-1, with label'] property
[all …]
/third_party/openssl/test/
Digetest.c227 unsigned char ciphertext[BIG_TEST_SIZE]; in test_ige_enc_dec() local
232 AES_ige_encrypt(plaintext, ciphertext, TEST_SIZE, &key, iv, AES_ENCRYPT); in test_ige_enc_dec()
236 AES_ige_encrypt(ciphertext, checktext, TEST_SIZE, &key, iv, AES_DECRYPT); in test_ige_enc_dec()
245 unsigned char ciphertext[BIG_TEST_SIZE]; in test_ige_enc_chaining() local
250 AES_ige_encrypt(plaintext, ciphertext, TEST_SIZE / 2, &key, iv, in test_ige_enc_chaining()
253 ciphertext + TEST_SIZE / 2, TEST_SIZE / 2, in test_ige_enc_chaining()
258 AES_ige_encrypt(ciphertext, checktext, TEST_SIZE, &key, iv, AES_DECRYPT); in test_ige_enc_chaining()
267 unsigned char ciphertext[BIG_TEST_SIZE]; in test_ige_dec_chaining() local
272 AES_ige_encrypt(plaintext, ciphertext, TEST_SIZE / 2, &key, iv, in test_ige_dec_chaining()
275 ciphertext + TEST_SIZE / 2, TEST_SIZE / 2, in test_ige_dec_chaining()
[all …]
Dmodes_internal_test.c194 unsigned char cleartext[64], ciphertext[64], vector[64]; in execute_cts128() local
203 if (!TEST_size_t_eq(fixture->encrypt_block(test_input, ciphertext, len, in execute_cts128()
206 || !TEST_mem_eq(ciphertext, len, vector, len) in execute_cts128()
212 size = fixture->decrypt_block(ciphertext, cleartext, len, in execute_cts128()
222 if (!TEST_size_t_eq(fixture->encrypt_stream(test_input, ciphertext, len, in execute_cts128()
226 || !TEST_mem_eq(ciphertext, len, vector, len) in execute_cts128()
232 if (!TEST_size_t_eq(fixture->decrypt_stream(ciphertext, cleartext, len, in execute_cts128()
/third_party/node/test/parallel/
Dtest-webcrypto-encrypt-decrypt-rsa.js32 async function testDecryption({ ciphertext, property
38 if (ciphertext === undefined)
52 const result = await subtle.decrypt(algorithm, privateKey, ciphertext);
58 const ciphercopy = Buffer.from(ciphertext);
71 ciphertext, property
174 async function testDecryptionWrongKey({ ciphertext, property
179 if (ciphertext === undefined)
193 subtle.decrypt(algorithm, publicKey, ciphertext), {
198 async function testDecryptionBadUsage({ ciphertext, property
203 if (ciphertext === undefined)
[all …]
Dtest-webcrypto-encrypt-decrypt.js28 const ciphertext = await subtle.encrypt({
36 }, privateKey, ciphertext);
57 const ciphertext = await subtle.encrypt(
62 { name: 'AES-CTR', counter, length: 64 }, key, ciphertext,
84 const ciphertext = await subtle.encrypt(
89 { name: 'AES-CBC', iv }, key, ciphertext,
111 const ciphertext = await subtle.encrypt(
116 { name: 'AES-GCM', iv }, key, ciphertext,
Dtest-crypto-authenticated.js573 const ciphertext = Buffer.concat([cipher.update(plain), cipher.final()]); constant
583 const resultUpdate = decipher.update(ciphertext);
604 const ciphertext = Buffer.concat([cipher.update(plain), cipher.final()]); constant
614 decipher.update(ciphertext),
712 const ciphertext = Buffer.concat([cipher.update('foo'), cipher.final()]); constant
724 const plaintext = decipher.update(ciphertext);
771 const ciphertext = Buffer.concat([ constant
777 assert.strictEqual(ciphertext.toString('hex'), testCase.ct);
782 decipher.setAAD(aad).update(ciphertext),
804 const ciphertext = Buffer.concat([ constant
[all …]
/third_party/mbedtls/library/
Dpsa_crypto_aead.c140 uint8_t *ciphertext, size_t ciphertext_size, size_t *ciphertext_length) in mbedtls_psa_aead_encrypt() argument
159 tag = ciphertext + plaintext_length; in mbedtls_psa_aead_encrypt()
169 plaintext, ciphertext, in mbedtls_psa_aead_encrypt()
181 plaintext, ciphertext, in mbedtls_psa_aead_encrypt()
198 ciphertext, in mbedtls_psa_aead_encrypt()
228 const uint8_t *ciphertext, in psa_aead_unpadded_locate_tag() argument
241 *p_tag = ciphertext + payload_length; in psa_aead_unpadded_locate_tag()
251 const uint8_t *ciphertext, size_t ciphertext_length, in mbedtls_psa_aead_decrypt() argument
266 ciphertext, ciphertext_length, in mbedtls_psa_aead_decrypt()
280 ciphertext, plaintext, in mbedtls_psa_aead_decrypt()
[all …]
Dpsa_crypto_aead.h86 uint8_t *ciphertext, size_t ciphertext_size, size_t *ciphertext_length);
148 const uint8_t *ciphertext, size_t ciphertext_length,
477 uint8_t *ciphertext,
/third_party/mbedtls/tests/src/drivers/
Dtest_driver_aead.c42 uint8_t *ciphertext, size_t ciphertext_size, size_t *ciphertext_length) in mbedtls_test_transparent_aead_encrypt() argument
60 ciphertext, ciphertext_size, ciphertext_length); in mbedtls_test_transparent_aead_encrypt()
69 ciphertext, ciphertext_size, ciphertext_length); in mbedtls_test_transparent_aead_encrypt()
81 (void) ciphertext; in mbedtls_test_transparent_aead_encrypt()
97 const uint8_t *ciphertext, size_t ciphertext_length, in mbedtls_test_transparent_aead_decrypt() argument
115 ciphertext, ciphertext_length, in mbedtls_test_transparent_aead_decrypt()
124 ciphertext, ciphertext_length, in mbedtls_test_transparent_aead_decrypt()
135 (void) ciphertext; in mbedtls_test_transparent_aead_decrypt()
349 uint8_t *ciphertext, in mbedtls_test_transparent_aead_finish() argument
365 libtestdriver1_mbedtls_psa_aead_finish(operation, ciphertext, in mbedtls_test_transparent_aead_finish()
[all …]
/third_party/node/deps/openssl/openssl/crypto/camellia/
Dcamellia.c405 u8 ciphertext[]) in Camellia_EncryptBlock_Rounds() argument
443 PUTU32(ciphertext, s2); in Camellia_EncryptBlock_Rounds()
444 PUTU32(ciphertext + 4, s3); in Camellia_EncryptBlock_Rounds()
445 PUTU32(ciphertext + 8, s0); in Camellia_EncryptBlock_Rounds()
446 PUTU32(ciphertext + 12, s1); in Camellia_EncryptBlock_Rounds()
450 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]) in Camellia_EncryptBlock() argument
453 plaintext, keyTable, ciphertext); in Camellia_EncryptBlock()
456 void Camellia_DecryptBlock_Rounds(int grandRounds, const u8 ciphertext[], in Camellia_DecryptBlock_Rounds() argument
463 s0 = GETU32(ciphertext) ^ k[0]; in Camellia_DecryptBlock_Rounds()
464 s1 = GETU32(ciphertext + 4) ^ k[1]; in Camellia_DecryptBlock_Rounds()
[all …]
Dcmll_local.h35 u8 ciphertext[]);
36 void Camellia_DecryptBlock_Rounds(int grandRounds, const u8 ciphertext[],
40 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]);
41 void Camellia_DecryptBlock(int keyBitLength, const u8 ciphertext[],
/third_party/openssl/crypto/camellia/
Dcamellia.c405 u8 ciphertext[]) in Camellia_EncryptBlock_Rounds() argument
443 PUTU32(ciphertext, s2); in Camellia_EncryptBlock_Rounds()
444 PUTU32(ciphertext + 4, s3); in Camellia_EncryptBlock_Rounds()
445 PUTU32(ciphertext + 8, s0); in Camellia_EncryptBlock_Rounds()
446 PUTU32(ciphertext + 12, s1); in Camellia_EncryptBlock_Rounds()
450 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]) in Camellia_EncryptBlock() argument
453 plaintext, keyTable, ciphertext); in Camellia_EncryptBlock()
456 void Camellia_DecryptBlock_Rounds(int grandRounds, const u8 ciphertext[], in Camellia_DecryptBlock_Rounds() argument
463 s0 = GETU32(ciphertext) ^ k[0]; in Camellia_DecryptBlock_Rounds()
464 s1 = GETU32(ciphertext + 4) ^ k[1]; in Camellia_DecryptBlock_Rounds()
[all …]
Dcmll_local.h35 u8 ciphertext[]);
36 void Camellia_DecryptBlock_Rounds(int grandRounds, const u8 ciphertext[],
40 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]);
41 void Camellia_DecryptBlock(int keyBitLength, const u8 ciphertext[],
/third_party/mbedtls/tests/src/
Dpsa_exercise_key.c165 unsigned char ciphertext[32] = "(wabblewebblewibblewobblewubble)"; in exercise_cipher_key() local
166 size_t ciphertext_length = sizeof(ciphertext); in exercise_cipher_key()
167 unsigned char decrypted[sizeof(ciphertext)]; in exercise_cipher_key()
183 ciphertext, sizeof(ciphertext), in exercise_cipher_key()
186 ciphertext + ciphertext_length, in exercise_cipher_key()
187 sizeof(ciphertext) - ciphertext_length, in exercise_cipher_key()
204 ciphertext, ciphertext_length, in exercise_cipher_key()
239 unsigned char ciphertext[48] = "(wabblewebblewibblewobblewubble)"; in exercise_aead_key() local
240 size_t ciphertext_length = sizeof(ciphertext); in exercise_aead_key()
241 size_t plaintext_length = sizeof(ciphertext); in exercise_aead_key()
[all …]
/third_party/openssl/doc/man7/
Ddes_modes.pod31 The same plaintext block always produces the same ciphertext block
36 An error will only affect one ciphertext block.
54 The CBC mode produces the same ciphertext whenever the same
59 The chaining operation makes the ciphertext blocks dependent on the
66 enciphering to the same ciphertext.
70 An error will affect the current and the following ciphertext blocks.
86 The CFB mode produces the same ciphertext whenever the same
91 The chaining operation makes the ciphertext variables dependent on the
98 enciphering to the same ciphertext.
117 An error will affect the current and the following ciphertext variables.
[all …]
/third_party/mbedtls/tests/suites/
Dtest_suite_nist_kw.function151 unsigned char *ciphertext = NULL;
164 ciphertext = mbedtls_calloc(1, output_len);
165 TEST_ASSERT(ciphertext != NULL);
172 ciphertext, &output_len,
186 mbedtls_free(ciphertext);
198 unsigned char *ciphertext = NULL;
211 ciphertext = mbedtls_calloc(1, in_len);
212 TEST_ASSERT(ciphertext != NULL);
217 unwrap_ret = mbedtls_nist_kw_unwrap(&ctx, mode, ciphertext, in_len,
230 mbedtls_free(ciphertext);
Dtest_suite_gcm.aes128_de.data673 AES-GCM NIST CAVS 14.0 - empty ciphertext, AD length: 128 bytes, ciphertext updates: 0
677 AES-GCM NIST CAVS 14.0 - empty ciphertext, AD length: 128 bytes, ciphertext updates: 1
681 AES-GCM NIST CAVS 14.0 - empty ciphertext, AD length: 128 bytes, ciphertext updates: 2
685 AES-GCM NIST CAVS 14.0 - empty ciphertext, AD length: 90 bytes, ciphertext updates: 0
689 AES-GCM NIST CAVS 14.0 - empty ciphertext, AD length: 90 bytes, ciphertext updates: 1
693 AES-GCM NIST CAVS 14.0 - empty ciphertext, AD length: 90 bytes, ciphertext updates: 2
697 AES-GCM NIST CAVS 14.0 - empty AD, ciphertext length: 128 bytes, AD updates: 0
701 AES-GCM NIST CAVS 14.0 - empty AD, ciphertext length: 128 bytes, AD updates: 1
705 AES-GCM NIST CAVS 14.0 - empty AD, ciphertext length: 128 bytes, AD updates: 2
709 AES-GCM NIST CAVS 14.0 - empty AD, ciphertext length: 51 bytes, AD updates: 0
[all …]
/third_party/libcoap/src/oscore/
Doscore_cose.c287 ptr->ciphertext.s, in cose_encrypt0_encode()
288 ptr->ciphertext.length); in cose_encrypt0_encode()
310 ptr->ciphertext.s = buffer; in cose_encrypt0_set_ciphertext()
311 ptr->ciphertext.length = size; in cose_encrypt0_set_ciphertext()
466 size_t max_result_len = ptr->ciphertext.length - tag_len; in cose_encrypt0_decrypt()
478 if (ptr->ciphertext.s == NULL || in cose_encrypt0_decrypt()
479 ptr->ciphertext.length > (plaintext_len + tag_len)) { in cose_encrypt0_decrypt()
490 &ptr->ciphertext, in cose_encrypt0_decrypt()
/third_party/ffmpeg/libavutil/tests/
Dblowfish.c117 static const uint8_t ciphertext[8] = { variable
158 test_blowfish(ctx, tmp, plaintext, ciphertext, 1, NULL, 0, "encryption"); in main()
159 test_blowfish(ctx, tmp, ciphertext, plaintext, 1, NULL, 1, "decryption"); in main()
160 test_blowfish(ctx, tmp, tmp, ciphertext, 1, NULL, 0, "Inplace encryption"); in main()
/third_party/mbedtls/tests/include/test/drivers/
Daead.h66 uint8_t *ciphertext, size_t ciphertext_size, size_t *ciphertext_length);
74 const uint8_t *ciphertext, size_t ciphertext_length,
114 uint8_t *ciphertext,

1234