VlaamseKunstcollectie / Imagehub

A IIIF Presentation API compliant aggregator and web service
GNU General Public License v3.0
1 stars 2 forks source link

enable SSL in Cantaloupe so info.json metadata is served over https #25

Open Hobbesball opened 5 years ago

Hobbesball commented 5 years ago

Detailed description of the issue. We want to be able to use Cantaloupe images in the Storiiies editor by Cogapp: https://storiiies-editor.cogapp.com. The errors we get when trying to load in an info.json file from our Cantaloupe server are these:

(index):1 Access to image at 'http://imagehub.vlaamsekunstcollectie.be/iiif/2/100000150/full/529,/0/default.jpg' from origin 'https://storiiies-editor.cogapp.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

We feel that the issue here isn't CORS in itself, but that the Storiiies editor tries to get the images from a HTTP endpoint instead of HTTPS. We believe this is because the info.json file that cantaloupe creates creates a HTTP URL in the 'id' field. cfr. https://imagehub.vlaamsekunstcollectie.be/iiif/2/100000150/info.json. Change the cantaloupe configuration so it creates IDs with HTTPS instead of HTTP, which should fix the issues the storiiies editor shows.

Possible implementation the first step would be to enable HTTPS in the cantaloupe config and see if this solves the issue. If it doesn't, maybe changes to TomCat and/or Nginx are needed to correctly serve https.

#serve info.json over https
#cantaloupe_https_enabled : "true"
#cantaloupe_https_host : imagehub.vlaamsekunstcollectie.be
#cantaloupe_https_port : 443
nvanderperren commented 5 years ago

Still getting errors in the Storiiies-editor, even now when both info.json & imagehub are served over HTTP. Must be another problem.

nvanderperren commented 5 years ago

Ignore above comment. Images must be server over HTTPS. I contacted the developers.