Deleted Added
full compact
EVP_EncryptInit.pod (1.1.1.9) EVP_EncryptInit.pod (1.1.1.10)
1=pod
2
3=head1 NAME
4
5EVP_CIPHER_fetch,
6EVP_CIPHER_up_ref,
7EVP_CIPHER_free,
8EVP_CIPHER_CTX_new,

--- 651 unchanged lines hidden (view full) ---

660=item "blocksize" (B<OSSL_CIPHER_PARAM_BLOCK_SIZE>) <unsigned integer>
661
662Gets the block size for the associated cipher algorithm I<cipher>.
663The block size should be 1 for stream ciphers.
664Note that the block size for a cipher may be different to the block size for
665the underlying encryption/decryption primitive.
666For example AES in CTR mode has a block size of 1 (because it operates like a
667stream cipher), even though AES has a block size of 16.
1=pod
2
3=head1 NAME
4
5EVP_CIPHER_fetch,
6EVP_CIPHER_up_ref,
7EVP_CIPHER_free,
8EVP_CIPHER_CTX_new,

--- 651 unchanged lines hidden (view full) ---

660=item "blocksize" (B<OSSL_CIPHER_PARAM_BLOCK_SIZE>) <unsigned integer>
661
662Gets the block size for the associated cipher algorithm I<cipher>.
663The block size should be 1 for stream ciphers.
664Note that the block size for a cipher may be different to the block size for
665the underlying encryption/decryption primitive.
666For example AES in CTR mode has a block size of 1 (because it operates like a
667stream cipher), even though AES has a block size of 16.
668Use EVP_CIPHER_get_block_size() to retreive the cached value.
668Use EVP_CIPHER_get_block_size() to retrieve the cached value.
669
670=item "aead" (B<OSSL_CIPHER_PARAM_AEAD>) <integer>
671
672Gets 1 if this is an AEAD cipher algorithm, otherwise it gets 0.
673Use (EVP_CIPHER_get_flags(cipher) & EVP_CIPH_FLAG_AEAD_CIPHER) to retrieve the
674cached value.
675
676=item "custom-iv" (B<OSSL_CIPHER_PARAM_CUSTOM_IV>) <integer>

--- 510 unchanged lines hidden (view full) ---

1187return 1 for success and 0 for failure.
1188
1189EVP_DecryptInit_ex2() and EVP_DecryptUpdate() return 1 for success and 0 for failure.
1190EVP_DecryptFinal_ex() returns 0 if the decrypt failed or 1 for success.
1191
1192EVP_CipherInit_ex2() and EVP_CipherUpdate() return 1 for success and 0 for failure.
1193EVP_CipherFinal_ex() returns 0 for a decryption failure or 1 for success.
1194
669
670=item "aead" (B<OSSL_CIPHER_PARAM_AEAD>) <integer>
671
672Gets 1 if this is an AEAD cipher algorithm, otherwise it gets 0.
673Use (EVP_CIPHER_get_flags(cipher) & EVP_CIPH_FLAG_AEAD_CIPHER) to retrieve the
674cached value.
675
676=item "custom-iv" (B<OSSL_CIPHER_PARAM_CUSTOM_IV>) <integer>

--- 510 unchanged lines hidden (view full) ---

1187return 1 for success and 0 for failure.
1188
1189EVP_DecryptInit_ex2() and EVP_DecryptUpdate() return 1 for success and 0 for failure.
1190EVP_DecryptFinal_ex() returns 0 if the decrypt failed or 1 for success.
1191
1192EVP_CipherInit_ex2() and EVP_CipherUpdate() return 1 for success and 0 for failure.
1193EVP_CipherFinal_ex() returns 0 for a decryption failure or 1 for success.
1194
1195EVP_Cipher() returns the amount of encrypted / decrypted bytes, or -1
1196on failure if the flag B<EVP_CIPH_FLAG_CUSTOM_CIPHER> is set for the
1197cipher. EVP_Cipher() returns 1 on success or 0 on failure, if the flag
1195EVP_Cipher() returns 1 on success or 0 on failure, if the flag
1198B<EVP_CIPH_FLAG_CUSTOM_CIPHER> is not set for the cipher.
1196B<EVP_CIPH_FLAG_CUSTOM_CIPHER> is not set for the cipher.
1197EVP_Cipher() returns the number of bytes written to I<out> for encryption / decryption, or
1198the number of bytes authenticated in a call specifying AAD for an AEAD cipher, if the flag
1199B<EVP_CIPH_FLAG_CUSTOM_CIPHER> is set for the cipher.
1199
1200EVP_CIPHER_CTX_reset() returns 1 for success and 0 for failure.
1201
1202EVP_get_cipherbyname(), EVP_get_cipherbynid() and EVP_get_cipherbyobj()
1203return an B<EVP_CIPHER> structure or NULL on error.
1204
1205EVP_CIPHER_get_nid() and EVP_CIPHER_CTX_get_nid() return a NID.
1206

--- 54 unchanged lines hidden (view full) ---

1261=head1 AEAD INTERFACE
1262
1263The EVP interface for Authenticated Encryption with Associated Data (AEAD)
1264modes are subtly altered and several additional I<ctrl> operations are supported
1265depending on the mode specified.
1266
1267To specify additional authenticated data (AAD), a call to EVP_CipherUpdate(),
1268EVP_EncryptUpdate() or EVP_DecryptUpdate() should be made with the output
1200
1201EVP_CIPHER_CTX_reset() returns 1 for success and 0 for failure.
1202
1203EVP_get_cipherbyname(), EVP_get_cipherbynid() and EVP_get_cipherbyobj()
1204return an B<EVP_CIPHER> structure or NULL on error.
1205
1206EVP_CIPHER_get_nid() and EVP_CIPHER_CTX_get_nid() return a NID.
1207

--- 54 unchanged lines hidden (view full) ---

1262=head1 AEAD INTERFACE
1263
1264The EVP interface for Authenticated Encryption with Associated Data (AEAD)
1265modes are subtly altered and several additional I<ctrl> operations are supported
1266depending on the mode specified.
1267
1268To specify additional authenticated data (AAD), a call to EVP_CipherUpdate(),
1269EVP_EncryptUpdate() or EVP_DecryptUpdate() should be made with the output
1269parameter I set to B.
1270parameter I<out> set to B<NULL>. In this case, on success, the parameter
1271I<outl> is set to the number of bytes authenticated.
1270
1271When decrypting, the return value of EVP_DecryptFinal() or EVP_CipherFinal()
1272indicates whether the operation was successful. If it does not indicate success,
1273the authentication operation has failed and any output data B<MUST NOT> be used
1274as it is corrupted.
1275
1276=head2 GCM and OCB Modes
1277

--- 460 unchanged lines hidden ---
1272
1273When decrypting, the return value of EVP_DecryptFinal() or EVP_CipherFinal()
1274indicates whether the operation was successful. If it does not indicate success,
1275the authentication operation has failed and any output data B<MUST NOT> be used
1276as it is corrupted.
1277
1278=head2 GCM and OCB Modes
1279

--- 460 unchanged lines hidden ---