summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortb <>2023-10-01 18:23:50 +0000
committertb <>2023-10-01 18:23:50 +0000
commit14325811a46be3e6d6d9a2f3e7431ed8789a08ed (patch)
tree52305c137c2c1710b768dfa034eace9be8b1217c /src
parent2877b0c96c385a58189dc0d110887eadd2730d0e (diff)
downloadopenbsd-14325811a46be3e6d6d9a2f3e7431ed8789a08ed.tar.gz
openbsd-14325811a46be3e6d6d9a2f3e7431ed8789a08ed.tar.bz2
openbsd-14325811a46be3e6d6d9a2f3e7431ed8789a08ed.zip
Document EVP_CIPHER_CTX_iv_length() return values
We aligned with upstream behavior. Let's document it properly. Surprisingly, OpenSSL 1.1 half-assed the docs: two parts of the manual contradict each other. The part getting EVP_CIPHER_CTX_iv_length() right, incorrectly documents possible -1 return value to EVP_CIPHER_iv_length(). OpenSSL 3 documentation improvement efforts seem to have tried to address this issue with the result that the manual is now entirely wrong when it comes to the EVP_CIPHER_CTX_iv_length() replacement. Par for the course.
Diffstat (limited to 'src')
-rw-r--r--src/lib/libcrypto/man/EVP_CIPHER_CTX_ctrl.310
1 files changed, 7 insertions, 3 deletions
diff --git a/src/lib/libcrypto/man/EVP_CIPHER_CTX_ctrl.3 b/src/lib/libcrypto/man/EVP_CIPHER_CTX_ctrl.3
index 40ed524ffa..ba0e4b074d 100644
--- a/src/lib/libcrypto/man/EVP_CIPHER_CTX_ctrl.3
+++ b/src/lib/libcrypto/man/EVP_CIPHER_CTX_ctrl.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: EVP_CIPHER_CTX_ctrl.3,v 1.1 2023/08/31 17:27:41 schwarze Exp $ 1.\" $OpenBSD: EVP_CIPHER_CTX_ctrl.3,v 1.2 2023/10/01 18:23:50 tb Exp $
2.\" full merge up to: OpenSSL 5211e094 Nov 11 14:39:11 2014 -0800 2.\" full merge up to: OpenSSL 5211e094 Nov 11 14:39:11 2014 -0800
3.\" 3.\"
4.\" This file is a derived work. 4.\" This file is a derived work.
@@ -67,7 +67,7 @@
67.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 67.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
68.\" OF THE POSSIBILITY OF SUCH DAMAGE. 68.\" OF THE POSSIBILITY OF SUCH DAMAGE.
69.\" 69.\"
70.Dd $Mdocdate: August 31 2023 $ 70.Dd $Mdocdate: October 1 2023 $
71.Dt EVP_CIPHER_CTX_CTRL 3 71.Dt EVP_CIPHER_CTX_CTRL 3
72.Os 72.Os
73.Sh NAME 73.Sh NAME
@@ -178,7 +178,9 @@ return the IV length of a cipher when passed an
178.Vt EVP_CIPHER_CTX 178.Vt EVP_CIPHER_CTX
179or 179or
180.Vt EVP_CIPHER . 180.Vt EVP_CIPHER .
181It will return zero if the cipher does not use an IV. 181They will return zero if the cipher does not use an IV.
182.Fn EVP_CIPHER_CTX_iv_length
183can fail and return \-1.
182The constant 184The constant
183.Dv EVP_MAX_IV_LENGTH 185.Dv EVP_MAX_IV_LENGTH
184is the maximum IV length for all ciphers. 186is the maximum IV length for all ciphers.
@@ -220,6 +222,8 @@ return the key length.
220and 222and
221.Fn EVP_CIPHER_iv_length 223.Fn EVP_CIPHER_iv_length
222return the IV length or zero if the cipher does not use an IV. 224return the IV length or zero if the cipher does not use an IV.
225.Fn EVP_CIPHER_CTX_iv_length
226can fail and return \-1.
223.Sh SEE ALSO 227.Sh SEE ALSO
224.Xr evp 3 , 228.Xr evp 3 ,
225.Xr EVP_CIPHER_nid 3 , 229.Xr EVP_CIPHER_nid 3 ,