Comment 17 for bug 1541559

Revision history for this message
Jeff Davis (jdavis-sitka) wrote :

Pushed a couple of commits -- (1) a signoff for Kathy's display tweaks, (2) defaulting to HTTPS for OverDrive requests:

http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/jeffdavis/lp1541559-ebook-api-master

Note that OverDrive's responses may contain non-HTTPS URIs; we don't use these embedded URIs, but they may show up in your logs. Also, HTTPS is hard-coded for some authentication-related OverDrive API endpoints which don't appear to support plain HTTP at all.

***

Mike, the trouble I had was with getting HTTPClient to validate certs properly. HTTPClient is a wrapper around LWP::UserAgent, which uses a few different options for certificate validation -- see the documentation for the $ua->ssl_opts attribute method here:

http://search.cpan.org/~oalders/libwww-perl-6.19/lib/LWP/UserAgent.pm

I ended up adding a section to opensrf.xml.example to let the user specify values for the various certificate-related variables. By default, certificate validation is enabled and CA certificates are presumed to be installed in a location where LWP::UserAgent can find them automatically. This works for me on Ubuntu 14.04, and it appears to work for Kathy as well. In other environments, it might be necessary to tweak the CA cert path/file variables for cert validation to work.