How do i get RemoteDomainWhiteList (and ImageBaseDir) to support https`?
Hi,
Can't seem to be able to figure out how to use RemoteDomainWhiteList or ImageBaseDir with https. That is, the domains i want to call is using the https protocol.
Here's how I do it (using ImageGen 2.9.0 Professional) using an image that is available from both http and https via flickr. Let's take it step by step...
A simple remote request with ImageGen for the regular http image
This will fail because ImageGen requires that you specifically allow remote domains (you don't want your site being used as a resizer for every image on the internet!).
I'll add an entry to the <RemoteDomainWhiteList> section of the imagegen.config file, like this:
I don't want to advertise where the images are coming from so I'll use a class in the imagegen.config file hide that with the <ImageBaseDir> setting. I'll also set the width in the class.
How do i get RemoteDomainWhiteList (and ImageBaseDir) to support https`?
Hi,
Can't seem to be able to figure out how to use RemoteDomainWhiteList or ImageBaseDir with https.
That is, the domains i want to call is using the https protocol.
Example:
What am i missing?
Hi, Anders,
Here's how I do it (using ImageGen 2.9.0 Professional) using an image that is available from both http and https via flickr. Let's take it step by step...
A simple remote request with ImageGen for the regular http image
This will fail because ImageGen requires that you specifically allow remote domains (you don't want your site being used as a resizer for every image on the internet!).
I'll add an entry to the
<RemoteDomainWhiteList>
section of the imagegen.config file, like this:Notice the * wildcard character. This is new in 2.9.0. In previous versions you have to specify the domain precisely, without any wildcards.
Now the request will work properly.
A simple remote request for the secure https image
A request for the secure image now also works:
Simplification and security with classes
I don't want to advertise where the images are coming from so I'll use a class in the imagegen.config file hide that with the
<ImageBaseDir>
setting. I'll also set the width in the class.I can now use this very simple yet secure ImageGen request:
cheers,
doug.
<= Feeling stupid.
For some reason i tried to fetch the image with ?file= instead if ?image=.
My bad.
More coffee, my friend, more coffee. :)
Glad it is sorted out.
cheers,
doug.
is working on a reply...