-
Notifications
You must be signed in to change notification settings - Fork 262
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix handling of CURLOPT_CAINFO and CURLOPT_CAPATH #2690
Conversation
re: Issue Unidata/netcdf4-python#1246 This provides a **partial** solution to the above PR. The underlying problem is with libcurl, but at least a workaround should be possible by creating a "~/.ncrc" file containing the line "HTTP.SSL_CAINFO=\<path to the cert (.crt) file\>". This was not working for obscure reasons. This PR should fix it. ## Misc. Other Changes * Update/fix configure.ac to properly test for libcurl version >= 7.66.0 * Update include/netcdf_json.h * Remove use of strlcat from plugins. * Fix applicability of .rc file entries
Thanks @DennisHeimbigner for fixing this! Would it be possible to add a netcdf API function for setting the cert path programatically? That way the python package could use certifi to determine the location of the cert files and set the path on import, without requiring any action by the user. This is what was done in the PROJ C lib (OSGeo/PROJ#2320) when a similar problem was encountered in the python interface. |
I think you can already do this. The netcdf.h API includes the following function:
You should be able to call "nc_rc_set("HTTP.SSL.CAINFO",<path to .crt file>) |
it would be nice to get this merged soon so I can build new netcdf4-python wheels that work with https URLs |
re: Issue Unidata/netcdf4-python#1246
This provides a partial solution to the above PR.
The underlying problem is with libcurl, but at least a
workaround should be possible by creating a "~/.ncrc" file
containing the line "HTTP.SSL_CAINFO=<path to the cert (.crt) file>".
This was not working for obscure reasons. This PR should fix it.
Misc. Other Changes