<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jun 26, 2023 at 12:04 PM Thomas Monjalon <<a href="mailto:thomas@monjalon.net">thomas@monjalon.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">26/06/2023 11:13, Didier Pallard:<br>
> HI,<br>
> not sure to understand how it is possible.<br>
> If build  OPENSSL_VERSION_NUMBER <  0x10100000L, linker should link binary<br>
> with libcrypto.so.1.0.0.<br>
> libcrypto.so.1.1 if build for 0x10100000L and libcrypto.so.3 for<br>
> 0x30000000L<br>
> loader should not allow to link with a library different from the one used<br>
> at build time, no?<br>
<br>
You are probably right.<br>
libcrypto.so.1.1 and libcrypto.so.1.0 are incompatible versions?<br></blockquote><div>I think so. Can someone else confirm?</div><div> <br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
If we are linking against libcrypto.so.1.1 and you did exactly<br>
a check for lower than libcrypto.so.1.1, then it should be OK.<br>
<br>
<br>
> On Sun, Jun 25, 2023 at 9:22 PM Thomas Monjalon <<a href="mailto:thomas@monjalon.net" target="_blank">thomas@monjalon.net</a>> wrote:<br>
> <br>
> > 18/04/2023 16:56, Didier Pallard:<br>
> > > This workaround was needed before version 1.0.1f. Do not build it for<br>
> > > versions >= 1.1.<br>
> > ><br>
> > > Fixes: d61f70b4c918 ("crypto/libcrypto: add driver for OpenSSL library")<br>
> > > Signed-off-by: Didier Pallard <<a href="mailto:didier.pallard@6wind.com" target="_blank">didier.pallard@6wind.com</a>><br>
> > > Cc: <a href="mailto:stable@dpdk.org" target="_blank">stable@dpdk.org</a><br>
> > [...]<br>
> > > +#if OPENSSL_VERSION_NUMBER < 0x10100000L<br>
> > >       /* Workaround open ssl bug in version less then 1.0.1f */<br>
> > >       if (EVP_EncryptUpdate(ctx, empty, &unused, empty, 0) <= 0)<br>
> > >               goto process_auth_encryption_gcm_err;<br>
> > > +#endif<br>
> ><br>
> > What happens if we build with OpenSSL 1.1 and run with OpenSSL 1.0?<br>
> > Can we have a runtime check?<br>
> > Or is it better doing the workaround always as before?<br>
<br>
<br>
<br>
</blockquote></div></div>