Title: Hotlinking issue
Last modified: December 9, 2016

---

# Hotlinking issue

 *  Resolved [ShortPixel](https://wordpress.org/support/users/shortpixel/)
 * (@shortpixel)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/hotlinking-issue-2/)
 * Hi,
    I’m Alex from ShortPixel – an image optimization plugin: [https://wordpress.org/plugins/shortpixel-image-optimiser](https://wordpress.org/plugins/shortpixel-image-optimiser)
 * We’ve had a few users that use your plugin and also tried to optimize their website’s
   images using ShortPixel plugin.
    This lead sometimes to errors as the anti-hotlinking
   feature in your plugin prevented our optimization API from being able to access
   the images that needed optimization.
 * Is there any way you could whitelist our API in your plugin so our common users
   won’t run into this kind of problems anymore?
 * Thank you, I look forward to hearing from you,
    Alex
 * PS: if you prefer to discuss this over email you can contact me directly here
   [https://shortpixel.com/contact](https://shortpixel.com/contact)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Česlav Przywara](https://wordpress.org/support/users/chesio/)
 * (@chesio)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/hotlinking-issue-2/#post-8534575)
 * Hi Alex,
 * The anti-hotlinking firewall rule triggers when the HTTP(S) request comes with
   non-empty referrer that doesn’t match the domain of the website. We employ almost
   verbatim copy of the first example here: [https://httpd.apache.org/docs/2.4/rewrite/access.html#blocked-inline-images](https://httpd.apache.org/docs/2.4/rewrite/access.html#blocked-inline-images)
 * Perhaps the problem could be solved on your side by manipulating the referrer
   that your optimization API sends: either by removing it completely from request
   or setting it to root URL of the currently accessed website? I don’t know, if
   such solution has any “moral” implications for you, but I don’t see anything 
   wrong in it – after all you are acting on behalf of your users (owners of the
   website).
 * Cheers,
    Česlav
    -  This reply was modified 9 years, 5 months ago by [Česlav Przywara](https://wordpress.org/support/users/chesio/).
 *  Thread Starter [ShortPixel](https://wordpress.org/support/users/shortpixel/)
 * (@shortpixel)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/hotlinking-issue-2/#post-8543426)
 * Česlav,
    thanks for your reply, I believe we fixed the issue following your advice
   🙂 I’ll get back to you if I’ll discover I was wrong.
 * Kind regards,
    Alex
 *  [Česlav Przywara](https://wordpress.org/support/users/chesio/)
 * (@chesio)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/hotlinking-issue-2/#post-8544645)
 * Hi Alex,
 * I’m glad I could help. I’m going to mark this thread as resolved, but feel free
   to reopen it, if you experience any further problems because of the plugin.
 * Cheers,
    Česlav

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Hotlinking issue’ is closed to new replies.

 * ![](https://ps.w.org/all-in-one-wp-security-and-firewall/assets/icon-256x256.
   png?rev=2798307)
 * [All-In-One Security (AIOS) – Security and Firewall](https://wordpress.org/plugins/all-in-one-wp-security-and-firewall/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/all-in-one-wp-security-and-firewall/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/all-in-one-wp-security-and-firewall/)
 * [Active Topics](https://wordpress.org/support/plugin/all-in-one-wp-security-and-firewall/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/all-in-one-wp-security-and-firewall/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/all-in-one-wp-security-and-firewall/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Česlav Przywara](https://wordpress.org/support/users/chesio/)
 * Last activity: [9 years, 5 months ago](https://wordpress.org/support/topic/hotlinking-issue-2/#post-8544645)
 * Status: resolved