Skip to content

Commit da8682a

Browse files
Remove OpenSSL 1.1.0 Support.
Only OpenSSL 1.1.1 and 3.0(via engine) is supported. All other versions are not supported. Signed-off-by: Yogaraj Alamenda <yogarajx.alamenda@intel.com>
1 parent bfe97aa commit da8682a

File tree

15 files changed

+189
-396
lines changed

15 files changed

+189
-396
lines changed

Makefile.am

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,11 @@ if QAT_HW
4242
qat_hw_dsa.c \
4343
qat_hw_ec.c \
4444
qat_hw_prf.c \
45-
qat_hw_gcm.c
46-
47-
if !QAT_OPENSSL_110
48-
QAT_HW_111_SRC = qat_hw_hkdf.c \
49-
qat_hw_ecx.c \
50-
qat_hw_sha3.c \
51-
qat_hw_chachapoly.c
52-
endif
45+
qat_hw_gcm.c \
46+
qat_hw_hkdf.c \
47+
qat_hw_ecx.c \
48+
qat_hw_sha3.c \
49+
qat_hw_chachapoly.c
5350
endif
5451

5552
if QAT_SW
@@ -70,7 +67,6 @@ endif
7067
qatengine_la_SOURCES = ${QAT_COMMON_SRC} \
7168
${QAT_ERR_SRC} \
7269
${QAT_HW_SRC} \
73-
${QAT_HW_111_SRC} \
7470
${QAT_HW_MEM_SRC} \
7571
${QAT_SW_SRC} \
7672
${QAT_SW_IPSEC_SRC}
@@ -111,19 +107,12 @@ MAKE = make err-files && make
111107
endif
112108

113109
err-files:
114-
if QAT_OPENSSL_110
115-
rm -rf e_qat_err* && perl -I$(with_openssl_dir) \
116-
$(with_openssl_dir)/util/mkerr.pl -conf e_qat.ec \
117-
-rebuild -reindex -nostatic -write *.c
118-
else
119110
if QAT_OPENSSL_3
120111
perl -I$(with_openssl_dir) $(with_openssl_dir)/util/mkerr.pl -conf qat_prov.ec \
121112
-rebuild -reindex *.c
122113
else
123-
rm -f e_qat_err.c e_qat.txt && perl -I$(with_openssl_dir) \
124-
$(with_openssl_dir)/util/mkerr.pl -conf e_qat.ec \
114+
perl -I$(with_openssl_dir) $(with_openssl_dir)/util/mkerr.pl -conf e_qat.ec \
125115
-rebuild -reindex *.c
126116
endif
127-
endif
128117

129118
include test.am

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -143,9 +143,9 @@ Clone OpenSSL\* from Github\* at the following location:
143143

144144
git clone https://github.com/openssl/openssl.git
145145

146-
It is recommended to checkout and build against the OpenSSL\* 1.1.1 git tag
147-
specified in the release notes.
148-
Versions of OpenSSL\* before OpenSSL\* 1.1.0 are not supported.
146+
It is recommended to checkout and build against the OpenSSL\* git tag
147+
specified in the Software Requirements section. OpenSSL\* Version 1.1.1
148+
and 3.0 are only supported.
149149

150150
Due to the nature of the Intel&reg; QAT OpenSSL\* Engine being a dynamic engine
151151
it can only be used with shared library builds of OpenSSL\*.
@@ -305,8 +305,8 @@ the engines dir of the system which can be checked using
305305
If OpenSSL\* version in the system can not be updated to 1.1.1 series, then
306306
the engine needs to be built from source using the option
307307
`--with-openssl_install_dir`. An additional option `--with-openssl_dir` pointing
308-
to the top directory of the OpenSSL\* source needs to be provided for building
309-
against OpenSSL\* 1.1.0 as the engine err files need to be regenerated for 1.1.0.
308+
to the top directory of the OpenSSL\* source needs to be provided for regenerating
309+
err files if there are any new error messages added/deleted in the source code.
310310

311311
<br>
312312
</details>

configure.ac

Lines changed: 2 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -268,17 +268,9 @@ then
268268
AC_SUBST([OPENSSL_LIB], ["-Wl,-rpath,\$(with_openssl_install_dir)/lib -L\$(with_openssl_install_dir)/lib -lcrypto"])
269269
fi
270270
else
271-
AC_MSG_NOTICE([Build QAT engine against OpenSSL 1.1.x])
271+
AC_MSG_NOTICE([Build QAT engine against OpenSSL 1.1.1])
272272
libdir="\$(with_openssl_install_dir)/lib/engines-1.1"
273273
AC_SUBST([OPENSSL_LIB], ["-Wl,-rpath,\$(with_openssl_install_dir)/lib -L\$(with_openssl_install_dir)/lib -lcrypto"])
274-
if test "`grep "define OPENSSL_VERSION_NUMBER 0x101000" $with_openssl_install_dir/include/openssl/opensslv.h | wc -l`" = "1"
275-
then
276-
if test "x$with_openssl_dir" = "x"
277-
then
278-
AC_MSG_ERROR([OpenSSL version 1.1.0! Additional flag "--with-openssl_dir" pointing to the OpenSSL source dir needs to be configured for OpenSSL 1.1.0 to regenerate err files])
279-
fi
280-
AC_SUBST([cflags_openssl_110], ["-DQAT_OPENSSL_110"])
281-
fi
282274
fi
283275
AC_SUBST([includes_openssl], ["-I\$(with_openssl_install_dir)/include"])
284276
else
@@ -290,18 +282,12 @@ else
290282
then
291283
AC_MSG_NOTICE([Build QAT engine against OpenSSL 3.0])
292284
AC_SUBST([cflags_openssl_3], ["-DQAT_OPENSSL_3 -DOPENSSL_SUPPRESS_DEPRECATED"])
293-
else
294-
if test "`grep "define OPENSSL_VERSION_NUMBER 0x10100" $includes_openssl/openssl/opensslv.h | wc -l`" = "1"
295-
then
296-
AC_MSG_ERROR([OpenSSL version in the system is less than 1.1.1. Either update system OpenSSL to 1.1.1 or Use "--with-openssl_install_dir" pointing to the path where OpenSSL downloaded from source is installed. Additional flag "--with-openssl_dir" pointing to the OpenSSL source dir needs to be configured for OpenSSL 1.1.0])
297-
fi
298285
fi
299286
AC_MSG_NOTICE([Install engine in the system OpenSSL enginesdir Path])
300287
AC_SUBST([includes_openssl], ["-I`pkg-config --variable=includedir libcrypto`"])
301288
AC_SUBST([OPENSSL_LIB], ["-lcrypto"])
302289
AC_SUBST([libdir])
303290
fi
304-
AM_CONDITIONAL([QAT_OPENSSL_110], [test "x$cflags_openssl_110" != "x"])
305291
AM_CONDITIONAL([QAT_OPENSSL_3], [test "x$cflags_openssl_3" != "x"])
306292

307293
# If both QAT HW and QAT SW configured, then check the libraries from standard location and use accordingly.
@@ -370,14 +356,10 @@ fi
370356
AM_CONDITIONAL([QAT_SW], [test "x$cflags_qat_sw" != "x"])
371357
AM_CONDITIONAL([QAT_SW_IPSEC], [test "x$cflags_qat_sw_ipsec" != "x"])
372358

373-
# OpenSSL source dir to regenerate err file for OpenSSL 1.1.0
359+
# OpenSSL source dir to regenerate err files if any changes in err messages
374360
if test "x$with_openssl_dir" = "x"
375361
then
376362
AC_MSG_NOTICE([Build with existing error files without regenerating from OpenSSL source])
377-
else if test "x$with_openssl_dir" = "xno"
378-
then
379-
AC_MSG_ERROR([--without-openssl_dir is invalid, set using --with-openssl_dir to the path to the OpenSSL source code. e.g: --with-openssl_dir=/path/to/openssl])
380-
fi
381363
fi
382364
AM_CONDITIONAL([QAT_ERR_FILES_BUILD], [test "x$with_openssl_dir" != "x"])
383365

docs/config_options.md

Lines changed: 13 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -35,24 +35,6 @@ The following is a list of the options that can be used with the
3535
(eg: /usr/lib64/engine-1.1).
3636
3737
```
38-
### OpenSSL 1.1.0 option
39-
```
40-
--with-openssl_dir=/path/to/openssl
41-
Specify the path to the top level of the OpenSSL* source code. This path
42-
is only needed to regenerate engine specific error source files using the
43-
mkerr.pl script from the OpenSSL source files. This option needs to be used
44-
if there is any new error message added in the QAT Engine source files
45-
and the error files will get updated using the mkerr.pl script. The default
46-
if not provided will build QAT Engine from the existing error files
47-
e_qat_err.c, e_qat_err.h & e_qat.txt in the QAT Engine dir which is
48-
generated from OpenSSL release mentioned in the github release page.
49-
This option is mandatory when building against OpenSSL* 1.1.0 as existing
50-
err files is generated for 1.1.1 which is not compatible for 1.1.0 and
51-
`--with-openssl_install_dir` needs to be provided to regenerate it.
52-
For example if you cloned the OpenSSL* Github* repository from within `/`
53-
then you would use the following setting:
54-
--with-openssl_dir=/openssl
55-
```
5638
### qat_sw options
5739
```
5840
--enable-qat_sw/--disable-qat_sw
@@ -79,6 +61,19 @@ The following is a list of the options that can be used with the
7961

8062
### Optional
8163
```
64+
--with-openssl_dir=/path/to/openssl
65+
Specify the path to the top level of the OpenSSL* source code. This path
66+
is only needed to regenerate engine specific error source files using the
67+
mkerr.pl script from the OpenSSL source. This option needs to be used
68+
if there is any new error message added in the QAT Engine source files
69+
and the error files will get updated using the mkerr.pl script. The default
70+
if not provided will build QAT Engine from the existing error files
71+
e_qat_err.c, e_qat_err.h & e_qat.txt in the QAT Engine dir which is
72+
generated from OpenSSL release mentioned in the github release page.
73+
For example if you cloned the OpenSSL* Github* repository from within `/`
74+
then you would use the following setting:
75+
--with-openssl_dir=/openssl
76+
8277
--with-qat_hw_install_dir=/path/to/qat_driver/build
8378
Specify the path to the location of the built Intel(R) QAT Hardware Driver
8479
library files. This path is needed in order to link to the userspace

docs/limitations.md

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,6 @@
66
* Only one level of forking is permitted, if a child process forks again then
77
the Intel&reg; QAT OpenSSL\* Engine will not be available in that forked
88
process.
9-
* The function `ASYNC_WAIT_CTX_get_changed_fds` contained in OpenSSL\* 1.1.0
10-
might return incorrect values in the case of failures during the submission of
11-
operations to the hardware accelerator. This could result in errors at the
12-
application level. The fix has been delivered in OpenSSL\* 1.1.0e and OpenSSL\*
13-
1.1.1. All previous versions of the library are affected.
14-
For more information, please refer to the following pull request on Github:
15-
[Fix waitctx fds removing the fd from the list #2581][1]
169
* Event driven mode of polling operation is not supported in the FreeBSD
1710
Operating system or in the qatlib RPM.
1811
* qat_contig_mem memory driver is not supported when running under FreeBSD
@@ -38,5 +31,3 @@
3831
sshd looks to be closing the file descriptors associated with QAT engine and driver
3932
after initialising openssl. Work around in sshd which comments out the closefrom()
4033
calls is needed to unblock the issue.
41-
42-
[1]:https://github.com/openssl/openssl/pull/2581

docs/software_requirements.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## qat_hw Requirements
44
Successful operation of QAT Hardware acceleration requires a software tool chain
5-
that supports OpenSSL\* 1.1.1 or OpenSSL\* 1.1.0 and Intel&reg; QuickAssist
5+
that supports OpenSSL\* 1.1.1 or OpenSSL\* 3.0 and Intel&reg; QuickAssist
66
Technology Driver for Linux or Intel&reg; QuickAssist Technology
77
Driver for FreeBSD. This release was validated on the following:
88

@@ -14,8 +14,8 @@ Driver for FreeBSD. This release was validated on the following:
1414

1515
## qat_sw Requirements
1616
Successful operation of the Intel&reg; QAT Software acceleration requires a
17-
software tool chain that supports OpenSSL\* 1.1.1 and Intel&reg; Crypto
18-
Multi-buffer library(for Asymmetric PKE) cloned from the [ipp-crypto][1] repo.
17+
software tool chain that supports OpenSSL\* 1.1.1 or OpenSSL\* 3.0 and Intel&reg;
18+
Crypto Multi-buffer library(for Asymmetric PKE) cloned from the [ipp-crypto][1] repo.
1919
The crypto_mb library needs to be installed using the instructions from the
2020
[Crypto Multi-buffer Library][2] Readme.
2121

e_qat.txt

Lines changed: 17 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -91,24 +91,23 @@ QAT_F_QAT_RSA_PRIV_ENC:181:qat_rsa_priv_enc
9191
QAT_F_QAT_RSA_PUB_DEC:182:qat_rsa_pub_dec
9292
QAT_F_QAT_RSA_PUB_ENC:183:qat_rsa_pub_enc
9393
QAT_F_QAT_SESSION_DATA_INIT:184:qat_session_data_init
94-
QAT_F_QAT_SET_AFFINE_COORDINATES:185:qat_set_affine_coordinates
95-
QAT_F_QAT_SET_INSTANCE_FOR_THREAD:186:qat_set_instance_for_thread
96-
QAT_F_QAT_SHA3_CLEANUP:187:qat_sha3_cleanup
97-
QAT_F_QAT_SHA3_CTRL:188:qat_sha3_ctrl
98-
QAT_F_QAT_SHA3_FINAL:189:qat_sha3_final
99-
QAT_F_QAT_SHA3_SESSION_DATA_INIT:190:qat_sha3_session_data_init
100-
QAT_F_QAT_SHA3_SETUP_PARAM:191:qat_sha3_setup_param
101-
QAT_F_QAT_SHA3_UPDATE:192:qat_sha3_update
102-
QAT_F_QAT_SYM_PERFORM_OP:193:qat_sym_perform_op
103-
QAT_F_QAT_VALIDATE_ECX_DERIVE:194:qat_validate_ecx_derive
104-
QAT_F_QAT_X25519_PMETH:195:qat_x25519_pmeth
105-
QAT_F_QAT_X448_PMETH:196:qat_x448_pmeth
106-
QAT_F_VAESGCM_CIPHERS_CTRL:197:vaesgcm_ciphers_ctrl
107-
QAT_F_VAESGCM_CIPHERS_DO_CIPHER:198:vaesgcm_ciphers_do_cipher
108-
QAT_F_VAESGCM_CIPHERS_INIT:199:vaesgcm_ciphers_init
109-
QAT_F_VAESGCM_INIT_GCM:200:vaesgcm_init_gcm
110-
QAT_F_VAESGCM_INIT_IPSEC_MB_MGR:201:vaesgcm_init_ipsec_mb_mgr
111-
QAT_F_VAESGCM_INIT_KEY:202:vaesgcm_init_key
94+
QAT_F_QAT_SET_INSTANCE_FOR_THREAD:185:qat_set_instance_for_thread
95+
QAT_F_QAT_SHA3_CLEANUP:186:qat_sha3_cleanup
96+
QAT_F_QAT_SHA3_CTRL:187:qat_sha3_ctrl
97+
QAT_F_QAT_SHA3_FINAL:188:qat_sha3_final
98+
QAT_F_QAT_SHA3_SESSION_DATA_INIT:189:qat_sha3_session_data_init
99+
QAT_F_QAT_SHA3_SETUP_PARAM:190:qat_sha3_setup_param
100+
QAT_F_QAT_SHA3_UPDATE:191:qat_sha3_update
101+
QAT_F_QAT_SYM_PERFORM_OP:192:qat_sym_perform_op
102+
QAT_F_QAT_VALIDATE_ECX_DERIVE:193:qat_validate_ecx_derive
103+
QAT_F_QAT_X25519_PMETH:194:qat_x25519_pmeth
104+
QAT_F_QAT_X448_PMETH:195:qat_x448_pmeth
105+
QAT_F_VAESGCM_CIPHERS_CTRL:196:vaesgcm_ciphers_ctrl
106+
QAT_F_VAESGCM_CIPHERS_DO_CIPHER:197:vaesgcm_ciphers_do_cipher
107+
QAT_F_VAESGCM_CIPHERS_INIT:198:vaesgcm_ciphers_init
108+
QAT_F_VAESGCM_INIT_GCM:199:vaesgcm_init_gcm
109+
QAT_F_VAESGCM_INIT_IPSEC_MB_MGR:200:vaesgcm_init_ipsec_mb_mgr
110+
QAT_F_VAESGCM_INIT_KEY:201:vaesgcm_init_key
112111

113112
#Reason codes
114113
QAT_R_AAD_INVALID_PTR:100:aad invalid ptr

e_qat_err.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,8 +119,6 @@ static ERR_STRING_DATA QAT_str_functs[] = {
119119
{ERR_PACK(0, QAT_F_QAT_RSA_PUB_DEC, 0), "qat_rsa_pub_dec"},
120120
{ERR_PACK(0, QAT_F_QAT_RSA_PUB_ENC, 0), "qat_rsa_pub_enc"},
121121
{ERR_PACK(0, QAT_F_QAT_SESSION_DATA_INIT, 0), "qat_session_data_init"},
122-
{ERR_PACK(0, QAT_F_QAT_SET_AFFINE_COORDINATES, 0),
123-
"qat_set_affine_coordinates"},
124122
{ERR_PACK(0, QAT_F_QAT_SET_INSTANCE_FOR_THREAD, 0),
125123
"qat_set_instance_for_thread"},
126124
{ERR_PACK(0, QAT_F_QAT_SHA3_CLEANUP, 0), "qat_sha3_cleanup"},

e_qat_err.h

Lines changed: 17 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -114,24 +114,23 @@ void ERR_QAT_error(int function, int reason, char *file, int line);
114114
# define QAT_F_QAT_RSA_PUB_DEC 182
115115
# define QAT_F_QAT_RSA_PUB_ENC 183
116116
# define QAT_F_QAT_SESSION_DATA_INIT 184
117-
# define QAT_F_QAT_SET_AFFINE_COORDINATES 185
118-
# define QAT_F_QAT_SET_INSTANCE_FOR_THREAD 186
119-
# define QAT_F_QAT_SHA3_CLEANUP 187
120-
# define QAT_F_QAT_SHA3_CTRL 188
121-
# define QAT_F_QAT_SHA3_FINAL 189
122-
# define QAT_F_QAT_SHA3_SESSION_DATA_INIT 190
123-
# define QAT_F_QAT_SHA3_SETUP_PARAM 191
124-
# define QAT_F_QAT_SHA3_UPDATE 192
125-
# define QAT_F_QAT_SYM_PERFORM_OP 193
126-
# define QAT_F_QAT_VALIDATE_ECX_DERIVE 194
127-
# define QAT_F_QAT_X25519_PMETH 195
128-
# define QAT_F_QAT_X448_PMETH 196
129-
# define QAT_F_VAESGCM_CIPHERS_CTRL 197
130-
# define QAT_F_VAESGCM_CIPHERS_DO_CIPHER 198
131-
# define QAT_F_VAESGCM_CIPHERS_INIT 199
132-
# define QAT_F_VAESGCM_INIT_GCM 200
133-
# define QAT_F_VAESGCM_INIT_IPSEC_MB_MGR 201
134-
# define QAT_F_VAESGCM_INIT_KEY 202
117+
# define QAT_F_QAT_SET_INSTANCE_FOR_THREAD 185
118+
# define QAT_F_QAT_SHA3_CLEANUP 186
119+
# define QAT_F_QAT_SHA3_CTRL 187
120+
# define QAT_F_QAT_SHA3_FINAL 188
121+
# define QAT_F_QAT_SHA3_SESSION_DATA_INIT 189
122+
# define QAT_F_QAT_SHA3_SETUP_PARAM 190
123+
# define QAT_F_QAT_SHA3_UPDATE 191
124+
# define QAT_F_QAT_SYM_PERFORM_OP 192
125+
# define QAT_F_QAT_VALIDATE_ECX_DERIVE 193
126+
# define QAT_F_QAT_X25519_PMETH 194
127+
# define QAT_F_QAT_X448_PMETH 195
128+
# define QAT_F_VAESGCM_CIPHERS_CTRL 196
129+
# define QAT_F_VAESGCM_CIPHERS_DO_CIPHER 197
130+
# define QAT_F_VAESGCM_CIPHERS_INIT 198
131+
# define QAT_F_VAESGCM_INIT_GCM 199
132+
# define QAT_F_VAESGCM_INIT_IPSEC_MB_MGR 200
133+
# define QAT_F_VAESGCM_INIT_KEY 201
135134

136135
/*
137136
* QAT reason codes.

0 commit comments

Comments
 (0)