Make it clear in the documentation that the OpenStreetMap tile usage policy requires sending the referrer header - #405
Conversation
|
This is a real issue, please consider it with some priority. |
|
This really needs to be merged. Anyone looking for a temp fix add this to LEAFLET_CONFIG in settings.py :- |
|
@Gagaro Anything preventing merging this from your point of view? I was affected, too. |
|
Checked this code change, i dont see any issue, for holding it back. it does the required stuff mentiond by OSM: For websites/web applications, this can be fixed by setting your Referrer-Policy header to any of no-referrer-when-downgrade, origin, origin-when-cross-origin, strict-origin, or strict-origin-when-cross-origin. For more information, see the Referer article._ |
|
@webkrab Looks good to me, especially since I wrote the section you quoted 😛 Though @maxfenv I'd suggest you implement forced attribution just like Leaflet did in Leaflet/Leaflet#9897, because there has been a nonzero amount of sites intentionally setting the |
|
@ElementW it seems unnecessary to implement forcing of the |
|
In fact, given that Leaflet now directly sets referrerPolicy sensibly by default, is there still any point in this PR? Presumably yes, since there won't be a 1.x release (of leaflet) with that change. |
|
Sorry for the delay, I've been busy these last few months! I'll merge and make a new release ASAP. |
This PR changes the default tile layer configured by django-leaflet to include a sensible
referrerPolicy, a requirement (which is now actually enforced) of the OSM tile usage policy.It also updates the documentation to urge users to set this when configuring their own tiles.
For context, you may find the PR in leaflet helpful/interesting: Leaflet/Leaflet#9883.