You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I add the # protect web fonts from hotlinking part, the font is not displayed on the website (which is unintended) and via the address bar I can still download the font (which is what I want to prevent (but maybe the file is in the cache at this point)).
I think the problem is that my domain is not added to the valid_referers.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I need to prevent hotlinking for web fonts, but I am not able to make it work in the nginx config file.
Here is what I have tried:
App:
https://app.example.com
Location:
/etc/nginx/conf.d/main.conf
When I add the
# protect web fonts from hotlinking
part, the font is not displayed on the website (which is unintended) and via the address bar I can still download the font (which is what I want to prevent (but maybe the file is in the cache at this point)).I think the problem is that my domain is not added to the
valid_referers
.This is why I have tried variations of this line:
Nothing works …
How can I make it work? Any ideas?
Beta Was this translation helpful? Give feedback.
All reactions