diff options
Diffstat (limited to 'upstream/debian-unstable/man3/EVP_EncryptInit.3ssl')
-rw-r--r-- | upstream/debian-unstable/man3/EVP_EncryptInit.3ssl | 39 |
1 files changed, 36 insertions, 3 deletions
diff --git a/upstream/debian-unstable/man3/EVP_EncryptInit.3ssl b/upstream/debian-unstable/man3/EVP_EncryptInit.3ssl index 5d82fd79..4c42d8cc 100644 --- a/upstream/debian-unstable/man3/EVP_EncryptInit.3ssl +++ b/upstream/debian-unstable/man3/EVP_EncryptInit.3ssl @@ -55,7 +55,7 @@ .\" ======================================================================== .\" .IX Title "EVP_ENCRYPTINIT 3SSL" -.TH EVP_ENCRYPTINIT 3SSL 2024-02-03 3.1.5 OpenSSL +.TH EVP_ENCRYPTINIT 3SSL 2024-04-04 3.2.2-dev OpenSSL .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l @@ -937,6 +937,37 @@ Byte 9\-10: The protocol version Byte 11\-12: Input length (Always 0) .Sp "tls1multi_interleave" must also be set for this operation. +.IP """xts_standard"" (\fBOSSL_CIPHER_PARAM_XTS_STANDARD\fR) <UTF8 string>" 4 +.IX Item """xts_standard"" (OSSL_CIPHER_PARAM_XTS_STANDARD) <UTF8 string>" +Sets the XTS standard to use with SM4\-XTS algorithm. XTS mode has two +implementations, one is standardized in IEEE Std. 1619\-2007 and has +been widely used (e.g., XTS AES), the other is proposed recently +(GB/T 17964\-2021 implemented in May 2022) and is currently only used +in SM4. +.Sp +The main difference between them is the multiplication by the +primitive element α to calculate the tweak values. The IEEE +Std 1619\-2007 noted that the multiplication "is a left shift of each +byte by one bit with carry propagating from one byte to the next +one", which means that in each byte, the leftmost bit is the most +significant bit. But in GB/T 17964\-2021, the rightmost bit is the +most significant bit, thus the multiplication becomes a right shift +of each byte by one bit with carry propagating from one byte to the +next one. +.Sp +Valid values for the mode are: +.RS 4 +.IP """GB""" 4 +.IX Item """GB""" +The GB/T 17964\-2021 variant of SM4\-XTS algorithm. +.IP """IEEE""" 4 +.IX Item """IEEE""" +The IEEE Std. 1619\-2007 variant of SM4\-XTS algorithm. +.RE +.RS 4 +.Sp +The default value is "GB". +.RE .SH CONTROLS .IX Header "CONTROLS" The Mappings from \fBEVP_CIPHER_CTX_ctrl()\fR identifiers to PARAMETERS are listed @@ -1135,7 +1166,7 @@ length. \&\fBEVP_CIPHER_CTX_set_padding()\fR always returns 1. .PP \&\fBEVP_CIPHER_get_iv_length()\fR and \fBEVP_CIPHER_CTX_get_iv_length()\fR return the IV -length or zero if the cipher does not use an IV. +length, zero if the cipher does not use an IV and a negative value on error. .PP \&\fBEVP_CIPHER_CTX_get_tag_length()\fR return the tag length or zero if the cipher does not use a tag. @@ -1254,6 +1285,8 @@ nonce value. The nonce length is given by \fB15 \- L\fR so it is 7 by default fo AES. .SS "SIV Mode" .IX Subsection "SIV Mode" +Both the AES-SIV and AES-GCM-SIV ciphers fall under this mode. +.PP For SIV mode ciphers the behaviour of the EVP interface is subtly altered and several additional ctrl operations are supported. .PP @@ -1613,7 +1646,7 @@ non-deprecated alias macro. .PP The \fBEVP_CIPHER_CTX_flags()\fR macro was deprecated in OpenSSL 1.1.0. .PP -\&\fBEVP_CIPHER_CTX_dup()\fR was added in OpenSSL 3.1. +\&\fBEVP_CIPHER_CTX_dup()\fR was added in OpenSSL 3.2. .SH COPYRIGHT .IX Header "COPYRIGHT" Copyright 2000\-2023 The OpenSSL Project Authors. All Rights Reserved. |