-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OSM tiles response error when loaded with Cesium #12402
Comments
…as default (#12403) (#12404) * Referre poicy strict-origin-when-cross-origin as default * adapt proxy tests to adapt to new referrer policy (cherry picked from commit 8bb5eda) Co-authored-by: Giovanni Allegri <[email protected]>
An evergreen of nerd history 🫖 .. Weird behavior, though. Perhaps, the tiles serving backend has HTCPCP enabled, or what? I see that python's request lib is implementing '418' response code and some SO posts indicate, that such status can be returned even when scheme is not 'coffee://'. In your tests, the user-agent was set? |
@ridoo I think OSM simply uses that nerdy return code when either the referrer is missing or that accept header is not fully specified. |
Hey @giohappy it seems that the missing Referer conflicts with OSM's technical usage-policy:
|
Yes @ridoo that's why I changed the settings. Now the Referrer is sent as requested. |
On the contrary of MapStore itself, the GeoNode client receives a response error (
418 I'm a teapot
) for OSM tiles loaded by the Cesium viewer.After investigating a few combinations of headers, it looks like the two problematic ones are:
accept: */*
-> apparently this is accepted if theReferrer
is also set (don't know why!)accept: image/avif,image/webp,image/apng,image/svg+xml,image/*,*/*;q=0.8'
is set3D viewer in GeoNode:
referrer
is not sent andaccept
is set to*/*
-> we get the error2D viewer in GeoNode:
referrer
is not sent BUTaccept
is set toimage/avif,image/webp,image/apng,image/svg+xml,image/*,*/*;q=0.8
-> we get the tiles2D and 3D in MapStore behave the same as GeoNode for the
accept
header but thereferrer
in MapStore is set for both cases.So the problem is the missing Referrer inside the requests from GeoNode + Cesium.
The reason the referrer is not sent is due to different values for the
Referrer Policy
header set by MapStore and GeoNode:The quick solutions is to add
SECURE_REFERRER_POLICY = 'strict-origin-when-cross-origin'
to GeoNode settings.The text was updated successfully, but these errors were encountered: