ruffle-rs / ruffle

A Flash Player emulator written in Rust
https://ruffle.rs
Other
15.67k stars 815 forks source link

ruffle not works with cookiebot.com consent javascript #11551

Open vollcom opened 1 year ago

vollcom commented 1 year ago

Describe the bug

Hi, my users detect a bug with the cookiebot.com consent javascript.

First, we load googleAdsene Script (https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js) If load adsbygoogle.js successful, we load the cookiebot.com consent JavaScript (https://consent.cookiebot.com/uc.js). After we initialize the ruffle script (last update: nightly-2023-06-14) and no flash game runs. The error is different (CORS or SWF not found or JavaScript issue). If we refresh the page, sometimes the games works.

If you use an adblocker, and no (https://consent.cookiebot.com/uc.js) is loading, the swf Flash Games run very well.

Some Examples: https://www.spiele-kostenlos-online.de/puzzlespiele/suchbilder/krankenhaus-wimmelbild/ https://www.spiele-kostenlos-online.de/puzzlespiele/mahjong/mahjongcon-flash/ https://www.spiele-kostenlos-online.de/puzzlespiele/mahjong/osmose-mahjong/

It is possible to fix this issue?

Regards

Expected behavior

Pls, fix the issus.

Affected platform

Desktop app

Operating system

Win 11

Browser

Chrome Version 114.0.5735.110 (Offizieller Build) (64-Bit)

Additional information

No response

n0samu commented 1 year ago

Please see https://github.com/ruffle-rs/ruffle/issues/11504#issuecomment-1589749159

We submitted a fix to wasm-bindgen but they did not accept it. The only possibility now is to convince Cookiebot to fix it on their end.

vollcom commented 1 year ago

THX ... I have 2 questions: First: Is there an old nightly ruffle version that works with cookiebot consens script? Second: What is the exact issue to post it on the cookiebot help section to fix them?

Regards

n0samu commented 1 year ago

@danielhjacobs explained the problem with Cookiebot here: https://github.com/rustwasm/wasm-bindgen/pull/3478#issuecomment-1589347973. They override the Response object, and their Response object doesn't include the proper Response.headers.

I don't know whether old nightly versions of Ruffle may work. You can try them if you like

vollcom commented 1 year ago

THX ... we reported it to cookiebot support and still wait.

n0samu commented 1 year ago

Did Cookiebot get back to you?

vollcom commented 1 year ago

NO !!! Cookiebot support don't answer our question and don't fix the bug. So we decide to change to quantcast.com Now, all flash games run very well ... and quantcast.com is free ;)

THX all!!

n0samu commented 1 year ago

Okay, I'm glad to hear that the problem is resolved for you. Nevertheless, I'll reopen the issue because it is not "fixed" and may apply to anyone still using the cookiebot.com script.