Limit file downloads to logged in users (WP + Nginx)
I am looking for a way to restrict access to mp3 files on my site to logged in users only.
The approach listed here sounds pretty much like what I need:
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} ^.*(mp3|m4a)$
RewriteCond %{HTTP_COOKIE} !^.*wordpress_logged_in.*$ [NC]
RewriteRule . - [R=403,L]
except how would I convert these .htaccess rules to nginx?
Topic content-restriction nginx Wordpress
Category Web