p5-net-ssleay icon indicating copy to clipboard operation
p5-net-ssleay copied to clipboard

Net-SSLeay: Won't build with openssl-3.0.8

Open dharanlinux opened this issue 1 year ago • 1 comments

Hi Team,

Facing the below build issue because of openssl-3.0.8. I am using gcc-6.5.0 and linux platform.

Error log:

SSLeay.c: In function 'XS_Net__SSLeay_DH_free':
SSLeay.c:15394:2: warning: 'DH_free' is deprecated: Since OpenSSL 3.0 [-Wdeprecated-declarations]
  DH_free(dh);
  ^~~~~~~

SSLeay.c: In function 'XS_Net__SSLeay_EVP_MD_CTX_md':
SSLeay.c:16087:2: warning: 'EVP_MD_CTX_md' is deprecated: Since OpenSSL 3.0 [-Wdeprecated-declarations]
  RETVAL = EVP_MD_CTX_md(ctx);
  ^~~~~~

SSLeay.xs: In function 'XS_Net__SSLeay_X509_get_X509_PUBKEY':
SSLeay.xs:7241:14: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
    if (pi-pc != len) croak("invalid encoded length");
              ^~
SSLeay.xs: In function 'XS_Net__SSLeay_OCSP_response_verify':
SSLeay.xs:7584:15: warning: passing argument 2 of 'TRACE' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
       TRACE(2,"SSL_OCSP_response_verify: no nonce in response");
               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SSLeay.xs:233:13: note: expected 'char *' but argument is of type 'const char *'
 static void TRACE(int level,char *msg,...) {
             ^~~~~
SSLeay.xs:7601:14: warning: passing argument 2 of 'TRACE' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
      TRACE(1,"run basic verify");
              ^~~~~~~~~~~~~~~~~~
SSLeay.xs:233:13: note: expected 'char *' but argument is of type 'const char *'
 static void TRACE(int level,char *msg,...) {
             ^~~~~
SSLeay.xs:7614:15: warning: passing argument 2 of 'TRACE' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
       TRACE(1,"run OCSP_basic_verify with issuer for last chain element");
               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SSLeay.xs:233:13: note: expected 'char *' but argument is of type 'const char *'
 static void TRACE(int level,char *msg,...) {
             ^~~~~
SSLeay.xs: In function 'XS_Net__SSLeay_OSSL_PROVIDER_do_all':
SSLeay.xs:7931:9: error: ISO C90 forbids mixed declarations and code [-Werror=declaration-after-statement]
         OSSL_LIB_CTX *ctx = NULL;
         ^~~~~~~~~~~~
cc1: some warnings being treated as errors

And


SSLeay.c:14879:38: warning: request for implicit conversion from 'void *' to 'DH ** {aka struct dh_st **}' not permitted in C++ [-Wc++-compat]
  RETVAL = PEM_read_bio_DHparams(bio, x, cb, u);
                                      ^
SSLeay.c: In function 'XS_Net__SSLeay_PEM_read_bio_X509_CRL':
SSLeay.c:14922:38: warning: request for implicit conversion from 'void *' to 'X509_CRL ** {aka struct X509_crl_st **}' not permitted in C++ [-Wc++-compat]
  RETVAL = PEM_read_bio_X509_CRL(bio, x, cb, u);
                                      ^
SSLeay.c: In function 'XS_Net__SSLeay_PEM_read_bio_X509':
SSLeay.c:14965:34: warning: request for implicit conversion from 'void *' to 'X509 ** {aka struct x509_st **}' not permitted in C++ [-Wc++-compat]
  RETVAL = PEM_read_bio_X509(bio, x, cb, u);
                                  ^
SSLeay.c:14965:37: warning: request for implicit conversion from 'void *' to 'int (*)(char *, int,  int,  void *)' not permitted in C++ [-Wc++-compat]
  RETVAL = PEM_read_bio_X509(bio, x, cb, u);
                                     ^~
SSLeay.c: In function 'XS_Net__SSLeay_PEM_read_bio_X509_REQ':
SSLeay.c:15324:38: warning: request for implicit conversion from 'void *' to 'X509_REQ ** {aka struct X509_req_st **}' not permitted in C++ [-Wc++-compat]
  RETVAL = PEM_read_bio_X509_REQ(bio, x, cb, u);
                                      ^

dharanlinux avatar Aug 08 '23 08:08 dharanlinux