We recently upgraded a web application to Django 4 which now, by default, adds a
Cross-Origin-Opener-Policy: same-origin
header to http responses, which can cause window.opener to be null in the child window. This broke one of our pages where we had a child window (for SSO auth) sending a postMessage() back to the parent window when it was done doing its thing.
I know I can work around that by manually setting that header to unsafe-none, or structuring those pages differently, etc., but I'm curious what is potentially unsafe about the child window having access to window.opener?
Browsers keep window.opener pretty locked down, and there's not much that child windows can do with it other than calling postMessage() and a couple of other minor things.
Given that it is so locked down, what about it is unsafe? Can someone give an example of something damaging that a child window can do with window.opener that the browser will allow?