Hi everyone,
I’m having trouble downloading SRA data using fasterq-dump from the SRA Toolkit. Here is the error message I get:
err: /home/username/.ncbi/user-settings.mkfg:1:20: error: token='false', msg='syntax error' sys: connection failed while opening file within cryptographic module - mbedtls_ssl_handshake returned -9984 ( X509 - Certificate verification failed ) sys: mbedtls_ssl_get_verify_result returned 0x4008 ( The certificate is not correctly signed by the trusted CA ) sys: connection failed - Failed to create TLS stream for 'trace.ncbi.nlm.nih.gov'
I suspect the main problem is with my configuration file ~/.ncbi/user-settings.mkfg where I tried to disable SSL verification by adding:
/http/ssl/verify = false
However, the SRA Toolkit complains that the value false causes a syntax error. After checking the docs, I learned that boolean values in the config file must be numeric.
So I changed the file to:
/http/ssl/verify = 0
But I still get SSL/TLS handshake errors and connection failures.
What I have tried:
- Deleting and recreating user-settings.mkfg with /http/ssl/verify = 0
- Using prefetch with --ngc /dev/null option
- Checking my internet connection and firewall settings (which seem fine)
- Ensuring I’m running the latest toolkit version (2.9.6)
My thoughts and questions: Could this be caused by the NCBI server’s certificate using a hash algorithm unsupported by mbedtls on my system?
Is there a way to bypass SSL verification or an alternative method to download SRA data?
Has anyone found a solution for the mbedtls_ssl_handshake returned -9984 error?
Any help or advice from those who have encountered similar issues or know how to configure SSL/TLS in SRA Toolkit would be greatly appreciated.
Thanks in advance!
Use https://sra-explorer.info/ to get direct URL's to download the data. How to use the tool shown here: sra-explorer : find SRA and FastQ download URLs in a couple of clicks
Latest version is 3.2.1. Perhaps that is your main issue since this error appears to show up on their GitHub often and the advice always appears to be to get the latest. Prebuilt-binaries here: https://github.com/ncbi/sra-tools/wiki/01.-Downloading-SRA-Toolkit