AFAICS this has been around for years :/
See for instance
https://forum.unity.com/threads/how-to-check-playerprefs-has-actually-written-data.389376/
I really don't understand the logic of attempting to use the caller's / top-level IDBFS context instead of the iframe one?
One work-around is unblocking "third-party cookies" in
chrome://settings/content/cookies
Hi,
With some more testing:
- Chromium, Debian version, blocks third-party cookies by default:
https://sources.debian.org/patches/chromium/73.0.3683.75-1/disable/third-party-cookies.patch/
- Chrome and default Chromium builds do not
- Firefox, including Debian version, doesn't; with blocking even
the 3rd-party WASM can't load (SecurityException)
So this is not a browser issue but a default settings issue.
AFAIU the reason why the iframe cannot use IndexDB is because otherwise the top-level page could control the frame and have it set a cookie, bypassing the "no 3rd-party cookie" setting.
There doesn't seem to be a way around this but I can be mistaken.
Cheers!
Beuc
To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/9057fc5d-80fe-9b11-bf56-4ff506cf9759%40beuc.net.