c - Error "Invalid X509 ASN.1 file" in libCurl with axTLS -
i using libcurl axtls (http://sourceforge.net/projects/axtls/files/1.5.3/ ) in embedded project.
when compiling axtls used following configuration ssl:
# # ssl library # # config_ssl_server_only not set # config_ssl_cert_verification not set # config_ssl_enable_client not set config_ssl_full_mode=y # config_ssl_skeleton_mode not set # config_ssl_prot_low not set config_ssl_prot_medium=y # config_ssl_prot_high not set config_ssl_use_default_key=y config_ssl_private_key_location="" config_ssl_private_key_password="" config_ssl_x509_cert_location="" # config_ssl_generate_x509_cert not set config_ssl_x509_common_name="" config_ssl_x509_organization_name="" config_ssl_x509_organization_unit_name="" config_ssl_enable_v23_handshake=y config_ssl_has_pem=y config_ssl_use_pkcs12=y config_ssl_expiry_time="" config_x509_max_ca_certs="" config_ssl_max_certs=3 config_ssl_ctx_mutexing=y config_use_dev_urandom=y # config_win32_use_crypto_lib not set config_openssl_compatible=y # config_performance_testing not set # config_ssl_test not set config_axtlswrap=y config_axhttpd=y
and when tried download files using https received following errors:
invalid digest: 2a 86 48 ce 3d 04 03 03 error: invalid x509 asn.1 file (unsupported digest) invalid digest: 2a 86 48 ce 3d 04 03 03 error: invalid x509 asn.1 file (unsupported digest) invalid digest: 2a 86 48 ce 3d 04 03 03 error: invalid x509 asn.1 file (unsupported digest) invalid digest: 2a 86 48 ce 3d 04 03 03 error: invalid x509 asn.1 file (unsupported digest) invalid digest: 2a 86 48 ce 3d 04 03 03 error: invalid x509 asn.1 file (unsupported digest) invalid digest: 2a 86 48 ce 3d 04 03 03 error: invalid x509 asn.1 file (unsupported digest) invalid digest: 2a 86 48 ce 3d 04 03 03 error: invalid x509 asn.1 file (unsupported digest) error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required error: maximum number of ca certs added (150) - change of compile-time configuration required
and initialize curl's options used following code:
curl_easy_setopt(curl_handle, curlopt_url, myurl); curl_easy_setopt(curl_handle, curlopt_ssl_verifypeer, 0l); curl_easy_setopt(curl_handle, curlopt_ssl_verifyhost, 0l); curl_easy_setopt(curl_handle, curlopt_writedata, mylocalfile); curl_easy_setopt(curl_handle, curlopt_useragent, "myagent"); curl_easy_perform(curl_handle);
it's non-blocking error, soft take long time begin downloading. when make config_ssl_generate_x509_cert=y error become blocking.
how can fix error?
best regards,
have tried changing config_x509_max_ca_certs="" in code larger 150? seems error indicating. if know how many ca certs have, can set higher number that.
Comments
Post a Comment