Protecting Private Videos on Nginx

By default, Presto Player will protect media files inside of the wp-content/uploads/presto-player-private/ folder with a .htaccess (and also allow to access), but this will only work if your site is running on Apache. If your site is running on NGINX, these videos will not be protected and will be able to be viewed by anyone.

To properly protect the videos on NGINX, we recommend using Cloudflare since this makes it free and has loads of other benefits to your website.

Blocking With Cloudflare

1. From your Cloudflare account page, navigate to the “Firewall” tab, then click “Firewall Rules”:

2. Click “Create a Firewall rule”:

3. Give the rule a name, and click “Edit Expression”:

4. Paste this into the expression box and click “Deploy”

This give access to the directory from Bunny’s CDN network IP addresses.

(http.request.uri contains "presto-player-private")

About the Author

Sharing is Caring!

Leave a Comment

Your email address will not be published. Required fields are marked *

Try Presto Player Risk-Free for 14 Days!

You are protected by our no-questions-asked refund policy.