I am using R to read and download data from ODK Central. I have done this previously using the same server ( in which ODK Central is installed ), project and form without problems. But now, I got an error that the security certificate has expired and I can not access the data anymore using ruODK. I can still go to the website and use the GUI to download but not within R.
2. What app or server are you using and on what device and operating system? Include version numbers.
Droplet with ODK Central V1.1. R version 4.0.3 (2020-10-10) on windows computer.
Extra information: R console message:
Default ODK Central Project ID: 3
Default ODK Central Form ID: infra_v1
Default ODK Central URL: https://odkBBBBBB.com
Default ODK Central Username: ......CCCC
Default ODK Central Password: run ruODK::get_default_pw() to show
Default Time Zone: CET
Default ODK Central Version: 0.8
Default HTTP GET retries: 3
Verbose messages: TRUE
Test ODK Central Project ID:
Test ODK Central Form ID:
Test ODK Central Form ID (ZIP tests):
Test ODK Central Form ID (Attachment tests):
Test ODK Central Form ID (Parsing tests):
Test ODK Central Form ID (WKT tests):
Test ODK Central URL:
Test ODK Central Username:
Test ODK Central Password: run ruODK::get_test_pw() to show
Test ODK Central Passphrase: run ruODK::get_test_pp() to show
Test ODK Central Version: 0.8
Error in curl::curl_fetch_memory(url, handle = handle): schannel: next InitializeSecurityContext failed: SEC_E_CERT_EXPIRED (0x80090328) - The received certificate has expired.
Request failed [ERROR]. Retrying in 1.6 seconds...
Error in curl::curl_fetch_memory(url, handle = handle): schannel: next InitializeSecurityContext failed: SEC_E_CERT_EXPIRED (0x80090328) - The received certificate has expired.
Request failed [ERROR]. Retrying in 2.6 seconds...
Error in curl::curl_fetch_memory(url, handle = handle) :
schannel: next InitializeSecurityContext failed: SEC_E_CERT_EXPIRED (0x80090328) - The received certificate has expired.
I do not know how to fix the problem with the SSL so I was wondering if there is a way to omit the verification and continue with accessing the information?
Looks unlikely to be an ruODK issue, I think Yaw is on the money with checking your server's SSL certificate.
I noticed that your ODKC_VERSION is 0.8, while you run ODK Central v 1.1.
The only breaking change so far is form_schema between 0.7 and 0.8, so you should be fine for now. Ideally you'd set ruODK's ODKC_VERSION to the same version as your targeted Central instance.
Thank you Yaw and Florian,
I checked the ssl checker and it reports 2 problems:
The certificate has expired (5 days ago).
The common names in the certificate do not match the name of the domain.
I guess that problem #1 is because #2.
What happened is that I was using a free DNS (ABC.mooo.com) at around 2 months ago one day It stopped working (I went to the same domain but I could not see ODK, while entering the IP address looks all normal) so I got a second domain name (2ABC.com) and linked to the IP address. With this change I could go to a domain and access ODK central. But I did not know anything regarding the SSL ( I am learning on the way...). So Now I have this issue.
My question would be how to install a new ssl with the new domain using let's Encrypt which is free so there is no conflict about it? Thanks for any guidance
If it is too complicate for this specific project (droplet) I can reinstall ODK Central and generate the default SSL in a new droplet but for other projects (with different droplets in which I used free dns as well) in which there is already people collecting data that will be difficult. I am just afraid that this could happen again with the projects (droplets) that matter so I want to learn how to to solve it.
As far as getting a new cert, make sure the domain in the ~/central/.env file is correct. It should be 2ABC.com. Then follow the upgrade directions at https://docs.getodk.org/central-upgrade to rebuild and you should get the new cert for 2ABC.com
I haven't tried this myself, so please make sure you have a backup of the machine and your data (or try it on a machine you don't care about).
Thank you Yaw. I managed to upgrade ODK Central following the instruction in the link and now the SSL is fine. Also, I did the backup of the data and the data was still there after the upgrade so it worked great.
Now also ruODK worked fine and I could access the data using R. Thanks Florian for the guidance too.