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
{{ message }}
Repository navigation
[Bug]: Request to insecure websocket endpoint is blocked by browser #25040
When running matplotlib using the webagg backend behind a reverse proxy that adds HTTPS with secure headers like HSTS, the request to the insecure websocket is blocked by the browser with the following error:
Mixed Content: The page at 'https:/<some_website>/' was loaded over HTTPS, but attempted to connect to the insecure
WebSocket endpoint 'ws://<some_website>/1/ws'. This request has been blocked; this endpoint must be available over WSS.
Fails to connect to the websocket with the following message:
Mixed Content: The page at 'https:/<some_website>/' was loaded over HTTPS, but attempted to connect to the insecure
WebSocket endpoint 'ws://<some_website>/1/ws'. This request has been blocked; this endpoint must be available over WSS.
Expected outcome
The JavaScript code on the page should check whether the page is being served over HTTPS and if it is, the websocket uri should use wss: instead of ws:.
Activity
whyvra commentedon Jan 20, 2023
I submitted PR #25039 to address this issue