| /openbsd-src/regress/lib/libcrypto/ige/ |
| H A D | igetest.c | 183 unsigned char ciphertext[BIG_TEST_SIZE]; in main() local 202 AES_ige_encrypt(plaintext, ciphertext, TEST_SIZE, &key, iv, in main() 207 AES_ige_encrypt(ciphertext, checktext, TEST_SIZE, &key, iv, in main() 221 AES_ige_encrypt(plaintext, ciphertext, TEST_SIZE/2, &key, iv, in main() 224 ciphertext+TEST_SIZE/2, TEST_SIZE/2, in main() 229 AES_ige_encrypt(ciphertext, checktext, TEST_SIZE, &key, iv, in main() 243 AES_ige_encrypt(plaintext, ciphertext, TEST_SIZE/2, &key, iv, in main() 246 ciphertext+TEST_SIZE/2, TEST_SIZE/2, in main() 251 AES_ige_encrypt(ciphertext, checktext, TEST_SIZE/2, &key, iv, in main() 253 AES_ige_encrypt(ciphertext+TEST_SIZE/2, in main() [all …]
|
| /openbsd-src/regress/lib/libcrypto/evp/ |
| H A D | evptest.c | 136 const unsigned char *ciphertext, int cn, int encdec) in test1() argument 150 hexdump(stdout, "Ciphertext",ciphertext,cn); in test1() 192 if (memcmp(out, ciphertext, cn)) { in test1() 195 hexdump(stderr, "Expected",ciphertext,cn); in test1() 211 if (!EVP_DecryptUpdate(ctx, out, &outl, ciphertext, cn)) { in test1() 245 const unsigned char *ciphertext, int cn, int encdec) in test_cipher() argument 253 test1(c, key, kn, iv, in, plaintext, pn, ciphertext, cn, encdec); in test_cipher() 260 const unsigned char *ciphertext, unsigned int cn) in test_digest() argument 274 hexdump(stdout, "Digest",ciphertext,cn); in test_digest() 305 if (memcmp(md, ciphertext, cn)) { in test_digest() [all …]
|
| H A D | evptests.txt | 2 #cipher:key:iv:plaintext:ciphertext:0/1(decrypt/encrypt) 76 # AES-bits-ECB:key::plaintext:ciphertext:encdec 93 # AES-bits-CBC:key:IV/ciphertext':plaintext:ciphertext:encdec 111 # AES-bits-CFB:key:IV/ciphertext':plaintext:ciphertext:encdec 143 # AES-bits-CFB:key:IV/output':plaintext:ciphertext:encdec 222 # CAMELLIA-bits-ECB:key::plaintext:ciphertext:encdec 251 # CAMELLIA-bits-CBC:key:IV/ciphertext':plaintext:ciphertext:encdec 272 # CAMELLIA-bits-CFB:key:IV/ciphertext':plaintext:ciphertext:encdec 310 # CAMELLIA-bits-OFB:key:IV/output':plaintext:ciphertext:encdec
|
| /openbsd-src/usr.bin/ssh/ |
| H A D | kexsntrup761x25519.c | 80 u_char *kem_key, *ciphertext, *server_pub; in kex_kem_sntrup761x25519_enc() 118 if ((r = sshbuf_reserve(server_blob, need, &ciphertext)) != 0) in kex_kem_sntrup761x25519_enc() 121 crypto_kem_sntrup761_enc(ciphertext, kem_key, client_pub); in kex_kem_sntrup761x25519_enc() 122 /* generate ECDH key pair, store server pubkey after ciphertext */ in kex_kem_sntrup761x25519_enc() 123 server_pub = ciphertext + crypto_kem_sntrup761_CIPHERTEXTBYTES; in kex_kem_sntrup761x25519_enc() 133 dump_digest("server cipher text:", ciphertext, in kex_kem_sntrup761x25519_enc() 165 const u_char *ciphertext, *server_pub; in kex_kem_sntrup761x25519_dec() 177 ciphertext = sshbuf_ptr(server_blob); in kex_kem_sntrup761x25519_dec() 178 server_pub = ciphertext + crypto_kem_sntrup761_CIPHERTEXTBYTES; in kex_kem_sntrup761x25519_dec() 180 dump_digest("server cipher text:", ciphertext, in kex_kem_sntrup761x25519_dec() 76 u_char *kem_key, *ciphertext, *server_pub; kex_kem_sntrup761x25519_enc() local 161 const u_char *ciphertext, *server_pub; kex_kem_sntrup761x25519_dec() local [all...] |
| H A D | PROTOCOL.chacha20poly1305 | 66 bytes of ciphertext length have been received, they may be decrypted 74 ciphertext of the packet length and the payload together. The calculated
|
| H A D | PROTOCOL | 59 calculating the MAC over the packet ciphertext rather than the 61 protocol, where decryption of unauthenticated ciphertext provided a 66 to calculate the MAC over the packet ciphertext and to send the packet
|
| /openbsd-src/regress/sys/crypto/aes/ |
| H A D | aestest.c | 142 u_char *plaintext, u_char *ciphertext, u_int textlen) in do_tests() argument 151 } else if (!match(result, ciphertext, textlen)) { in do_tests() 157 if (docrypt(key, keylen, ciphertext, result, textlen, 0) < 0) { in do_tests() 175 u_char *key, *plaintext, *ciphertext; in run_file() local 183 key = ciphertext = plaintext = NULL; in run_file() 226 if (ciphertext != NULL) in run_file() 227 free(ciphertext); in run_file() 228 parsehex(cp, &ciphertext, &tmp); in run_file() 247 if (plaintext == NULL || ciphertext == NULL || in run_file() 256 plaintext, ciphertext, textlen); in run_file()
|
| /openbsd-src/lib/libc/crypt/ |
| H A D | bcrypt.c | 100 u_int8_t ciphertext[4 * BCRYPT_WORDS] = "OrpheanBeholderScryDoubt"; in bcrypt_hashpass() local 171 cdata[i] = Blowfish_stream2word(ciphertext, 4 * BCRYPT_WORDS, &j); in bcrypt_hashpass() 178 ciphertext[4 * i + 3] = cdata[i] & 0xff; in bcrypt_hashpass() 180 ciphertext[4 * i + 2] = cdata[i] & 0xff; in bcrypt_hashpass() 182 ciphertext[4 * i + 1] = cdata[i] & 0xff; in bcrypt_hashpass() 184 ciphertext[4 * i + 0] = cdata[i] & 0xff; in bcrypt_hashpass() 190 encode_base64(encrypted + 7 + 22, ciphertext, 4 * BCRYPT_WORDS - 1); in bcrypt_hashpass() 192 explicit_bzero(ciphertext, sizeof(ciphertext)); in bcrypt_hashpass()
|
| /openbsd-src/lib/libcrypto/camellia/ |
| H A D | camellia.c | 99 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]); 100 void Camellia_DecryptBlock_Rounds(int grandRounds, const u8 ciphertext[], 103 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]); 104 void Camellia_DecryptBlock(int keyBitLength, const u8 ciphertext[], 481 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]) in Camellia_EncryptBlock_Rounds() argument 517 PUTU32(ciphertext, s2); in Camellia_EncryptBlock_Rounds() 518 PUTU32(ciphertext + 4, s3); in Camellia_EncryptBlock_Rounds() 519 PUTU32(ciphertext + 8, s0); in Camellia_EncryptBlock_Rounds() 520 PUTU32(ciphertext + 12, s1); in Camellia_EncryptBlock_Rounds() 525 const KEY_TABLE_TYPE keyTable, u8 ciphertext[]) in Camellia_EncryptBlock() argument [all …]
|
| /openbsd-src/sys/lib/libsa/ |
| H A D | bcrypt_pbkdf.c | 58 uint8_t ciphertext[BCRYPT_HASHSIZE] = in bcrypt_hash() local 76 cdata[i] = Blowfish_stream2word(ciphertext, sizeof(ciphertext), in bcrypt_hash() 90 explicit_bzero(ciphertext, sizeof(ciphertext)); in bcrypt_hash()
|
| /openbsd-src/lib/libutil/ |
| H A D | bcrypt_pbkdf.c | 60 uint8_t ciphertext[BCRYPT_HASHSIZE] = in bcrypt_hash() local 78 cdata[i] = Blowfish_stream2word(ciphertext, sizeof(ciphertext), in bcrypt_hash() 92 explicit_bzero(ciphertext, sizeof(ciphertext)); in bcrypt_hash()
|
| /openbsd-src/regress/lib/libcrypto/sm2/ |
| H A D | sm2evptest.c | 120 uint8_t ciphertext[128]; in test_EVP_SM2() local 121 size_t ctext_len = sizeof(ciphertext); in test_EVP_SM2() 214 CHECK_GOTO(EVP_PKEY_encrypt(cctx, ciphertext, &ctext_len, kMsg, sizeof(kMsg))); in test_EVP_SM2() 218 CHECK_GOTO(EVP_PKEY_decrypt(cctx, plaintext, &ptext_len, ciphertext, ctext_len)); in test_EVP_SM2()
|
| /openbsd-src/regress/sys/crypto/aesxts/ |
| H A D | aes_xts.c | 56 u_int8_t ciphertext[512]; member 1793 if (!match(result, tv->ciphertext, tv->text_len)) { in main() 1800 if (do_aes_xts(tv->key, tv->key_len, tv->seqno, tv->ciphertext, in main()
|
| /openbsd-src/lib/libfido2/src/ |
| H A D | largeblob.c | 18 fido_blob_t ciphertext; member 31 fido_blob_reset(&blob->ciphertext); in largeblob_reset() 78 if (aes256_gcm_dec(key, &blob->nonce, aad, &blob->ciphertext, in largeblob_decrypt() 141 &blob->ciphertext) < 0) { in largeblob_seal() 278 if (fido_blob_decode(val, &blob->ciphertext) < 0 || in largeblob_do_decode() 279 blob->ciphertext.len < LARGEBLOB_TAG_LENGTH) in largeblob_do_decode() 310 if (fido_blob_is_empty(&blob->ciphertext) || in largeblob_decode() 331 if ((argv[0] = fido_blob_encode(&blob->ciphertext)) == NULL || in largeblob_encode()
|
| /openbsd-src/lib/libcrypto/sm2/ |
| H A D | sm2.h | 54 const uint8_t *ciphertext, size_t ciphertext_len, uint8_t *ptext_buf,
|
| H A D | sm2_crypt.c | 464 SM2_decrypt(const EC_KEY *key, const EVP_MD *digest, const uint8_t *ciphertext, in SM2_decrypt() argument 496 if ((sm2_ctext = d2i_SM2_Ciphertext(NULL, &ciphertext, in SM2_decrypt()
|
| /openbsd-src/regress/sys/crypto/chachapoly/ |
| H A D | chachapoly_test.c | 379 u_char *ciphertext; in run() local
|
| /openbsd-src/lib/libcrypto/rc2/ |
| H A D | rrc2.doc | 58 RRC.2 uses a single 256-byte S-box derived from the ciphertext contents of
|