SoftU2F icon indicating copy to clipboard operation
SoftU2F copied to clipboard

Doesn't build with OpenSSL 1.1

Open zofrex opened this issue 5 years ago • 0 comments

I got the project building fine on my machine with OpenSSL 1.0.2t, but get a compilation error with 1.1.1g:

/Users/zofrex/SoftU2F/SelfSignedCertificate/SelfSignedCertificate.m:113:14: error: variable has incomplete type 'EVP_MD_CTX' (aka 'struct evp_md_ctx_st')
  EVP_MD_CTX ctx;
             ^
In file included from /Users/zofrex/SoftU2F/SelfSignedCertificate/SelfSignedCertificate.m:8:
In file included from /Users/zofrex/SoftU2F/SelfSignedCertificate/private.h:13:
In file included from /usr/local/opt/openssl/include/openssl/asn1.h:16:
In file included from /usr/local/opt/openssl/include/openssl/bio.h:20:
In file included from /usr/local/opt/openssl/include/openssl/crypto.h:25:
/usr/local/opt/openssl/include/openssl/ossl_typ.h:92:16: note: forward declaration of 'struct evp_md_ctx_st'
typedef struct evp_md_ctx_st EVP_MD_CTX;
               ^
1 error generated.

From a quick Google it seems like this is due to changes between 1.0->1.1, and there'll probably be other things to fix too.

Given that OpenSSL 1.0 is no longer supported, I think support for 1.1 should be added.

I'm happy to have a go at that but thought I would ask about it before starting / making a PR!

If upgrading to 1.1 is desirable does backward compatibility need to be kept to work with 1.0 as well, or can 1.0 support be completely dropped?

zofrex avatar Apr 23 '20 14:04 zofrex