linux-kselftest.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning
@ 2022-07-21 19:40 Kristen Carlson Accardi
  2022-07-21 20:02 ` Dave Hansen
  2022-07-28  8:00 ` Jarkko Sakkinen
  0 siblings, 2 replies; 5+ messages in thread
From: Kristen Carlson Accardi @ 2022-07-21 19:40 UTC (permalink / raw)
  To: linux-kernel, Jarkko Sakkinen, Dave Hansen, Shuah Khan
  Cc: Kristen Carlson Accardi, linux-sgx, linux-kselftest

OpenSSL 3.0 deprecates some of the functions used in the SGX
selftests, causing build errors on new distros. For now ignore
the warnings until support for the functions is no longer
available.

Signed-off-by: Kristen Carlson Accardi <kristen@linux.intel.com>
---
 tools/testing/selftests/sgx/sigstruct.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tools/testing/selftests/sgx/sigstruct.c b/tools/testing/selftests/sgx/sigstruct.c
index 50c5ab1aa6fa..bb191b70141a 100644
--- a/tools/testing/selftests/sgx/sigstruct.c
+++ b/tools/testing/selftests/sgx/sigstruct.c
@@ -17,6 +17,9 @@
 #include "defines.h"
 #include "main.h"
 
+/* OpenSSL 3.0 has deprecated some functions. For now just ignore the warnings. */
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
 struct q1q2_ctx {
 	BN_CTX *bn_ctx;
 	BIGNUM *m;
-- 
2.36.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning
  2022-07-21 19:40 [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning Kristen Carlson Accardi
@ 2022-07-21 20:02 ` Dave Hansen
  2022-07-21 20:08   ` Kristen Carlson Accardi
  2022-07-28  8:00 ` Jarkko Sakkinen
  1 sibling, 1 reply; 5+ messages in thread
From: Dave Hansen @ 2022-07-21 20:02 UTC (permalink / raw)
  To: Kristen Carlson Accardi, linux-kernel, Jarkko Sakkinen,
	Dave Hansen, Shuah Khan
  Cc: linux-sgx, linux-kselftest

On 7/21/22 12:40, Kristen Carlson Accardi wrote:
> OpenSSL 3.0 deprecates some of the functions used in the SGX
> selftests, causing build errors on new distros. For now ignore
> the warnings until support for the functions is no longer
> available.

Are there some better functions we should be moving to?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning
  2022-07-21 20:02 ` Dave Hansen
@ 2022-07-21 20:08   ` Kristen Carlson Accardi
  2022-07-21 20:14     ` Dave Hansen
  0 siblings, 1 reply; 5+ messages in thread
From: Kristen Carlson Accardi @ 2022-07-21 20:08 UTC (permalink / raw)
  To: Dave Hansen, linux-kernel, Jarkko Sakkinen, Dave Hansen, Shuah Khan
  Cc: linux-sgx, linux-kselftest

On Thu, 2022-07-21 at 13:02 -0700, Dave Hansen wrote:
> On 7/21/22 12:40, Kristen Carlson Accardi wrote:
> > OpenSSL 3.0 deprecates some of the functions used in the SGX
> > selftests, causing build errors on new distros. For now ignore
> > the warnings until support for the functions is no longer
> > available.
> 
> Are there some better functions we should be moving to?

I looked into this actually as my first choice, but the problem I had
was that the recommended new functions weren't available on other
OpenSSL libraries, and we'd have to add compatibility macros and stuff,
so it seemed to me that the less complicated thing to do was wait till
OpenSSL 1 was just not widely deployed anymore. This strategy is also
being used in other scripts in the kernel.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning
  2022-07-21 20:08   ` Kristen Carlson Accardi
@ 2022-07-21 20:14     ` Dave Hansen
  0 siblings, 0 replies; 5+ messages in thread
From: Dave Hansen @ 2022-07-21 20:14 UTC (permalink / raw)
  To: Kristen Carlson Accardi, linux-kernel, Jarkko Sakkinen,
	Dave Hansen, Shuah Khan
  Cc: linux-sgx, linux-kselftest

On 7/21/22 13:08, Kristen Carlson Accardi wrote:
> On Thu, 2022-07-21 at 13:02 -0700, Dave Hansen wrote:
>> On 7/21/22 12:40, Kristen Carlson Accardi wrote:
>>> OpenSSL 3.0 deprecates some of the functions used in the SGX
>>> selftests, causing build errors on new distros. For now ignore
>>> the warnings until support for the functions is no longer
>>> available.
>> Are there some better functions we should be moving to?
> I looked into this actually as my first choice, but the problem I had
> was that the recommended new functions weren't available on other
> OpenSSL libraries, and we'd have to add compatibility macros and stuff,
> so it seemed to me that the less complicated thing to do was wait till
> OpenSSL 1 was just not widely deployed anymore. This strategy is also
> being used in other scripts in the kernel.

Sounds sane to me.  Thanks for the explanation.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning
  2022-07-21 19:40 [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning Kristen Carlson Accardi
  2022-07-21 20:02 ` Dave Hansen
@ 2022-07-28  8:00 ` Jarkko Sakkinen
  1 sibling, 0 replies; 5+ messages in thread
From: Jarkko Sakkinen @ 2022-07-28  8:00 UTC (permalink / raw)
  To: Kristen Carlson Accardi
  Cc: linux-kernel, Dave Hansen, Shuah Khan, linux-sgx, linux-kselftest

On Thu, Jul 21, 2022 at 12:40:40PM -0700, Kristen Carlson Accardi wrote:
> OpenSSL 3.0 deprecates some of the functions used in the SGX
> selftests, causing build errors on new distros. For now ignore
> the warnings until support for the functions is no longer
> available.
> 
> Signed-off-by: Kristen Carlson Accardi <kristen@linux.intel.com>
> ---
>  tools/testing/selftests/sgx/sigstruct.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/tools/testing/selftests/sgx/sigstruct.c b/tools/testing/selftests/sgx/sigstruct.c
> index 50c5ab1aa6fa..bb191b70141a 100644
> --- a/tools/testing/selftests/sgx/sigstruct.c
> +++ b/tools/testing/selftests/sgx/sigstruct.c
> @@ -17,6 +17,9 @@
>  #include "defines.h"
>  #include "main.h"
>  
> +/* OpenSSL 3.0 has deprecated some functions. For now just ignore the warnings. */

Perhaps, even prefix with "FIXME:" prefix?

> +#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
> +
>  struct q1q2_ctx {
>  	BN_CTX *bn_ctx;
>  	BIGNUM *m;
> -- 
> 2.36.1
> 

BR, Jarkko

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-07-28  8:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-21 19:40 [PATCH] selftests/sgx: Ignore OpenSSL 3.0 deprecated functions warning Kristen Carlson Accardi
2022-07-21 20:02 ` Dave Hansen
2022-07-21 20:08   ` Kristen Carlson Accardi
2022-07-21 20:14     ` Dave Hansen
2022-07-28  8:00 ` Jarkko Sakkinen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).