Skip to content
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

Trezor Connect does not load in Brave when cookies are blocked #6129

Closed
john-light opened this issue Aug 26, 2022 · 6 comments
Closed

Trezor Connect does not load in Brave when cookies are blocked #6129

john-light opened this issue Aug 26, 2022 · 6 comments
Labels
connect-popup Connect popup used by 3rd parties connect-webextension

Comments

@john-light
Copy link

john-light commented Aug 26, 2022

I was having an issue connecting Trezor wallet to https://live.sovryn.app, https://live.sovryn.app/zero, and https://safe.gnosis.io

The URL would open but just show a loading spinner forever:

Screenshot 2022-08-11 111455

Since each app uses different wallet connection modules, I figured the issue must be Trezor Connect and worked with a colleague to investigate further.

After some troublshooting we narrowed it down. There is a setting in Brave browser called "Block cookies".

When the issue was happening, I had this set to "Only cross-site":

Screenshot 2022-08-26 073519

After changing this setting to "Disabled", the issue stopped happening:

Edit: For some apps, "Block fingerprinting" must also be disabled.

Screenshot 2022-08-26 073506

Screenshot 2022-08-26 074331

I am opening this issue because it'd be great if there was a way to use Brave while keeping this "Block cookies" setting enabled, for privacy reasons. It would be annoying to want to use this feature and have to disable it every time I wanted to use Trezor in the browser.

@hynek-jina hynek-jina added the connect Connect API related (ie. fee calculation) label Aug 26, 2022
@sime
Copy link
Member

sime commented Aug 26, 2022

Thanks for your report.

Tricky thing is that by definition, connect.trezor.io is cross site.

@john-light
Copy link
Author

john-light commented Aug 26, 2022

Tricky thing is that by definition, connect.trezor.io is cross site.

This may be out of scope for this issue, but it has always been a bit weird to me that Trezor has to phone home every time I want to use it on the web. Ledger doesn't do that (as far as I can tell). Maybe Trezor can somehow get rid of this requirement and work the same way as Ledger where it doesn't need to phone home to trezor.io just to connect to a web app?

Edit: I checked, and in Brave and Firefox cross-site cookies are blocked by default, and confirmed connect.trezor.io does not load with the default settings. So by default Trezor users are going to have problems with Trezor in these web browsers. Could the website they're trying to connect their Trezor to run Connect or is there something else web apps can do to make direct Trezor connections work smoothly with these default browser settings? Wondering because with the power of defaults we can expect it to be an issue, and also it is an unfortunate decision to have to make as a user between convenient privacy protection or having to manually turn this setting on and off whenever using Trezor on a site.

Brave default:
Screenshot 2022-08-27 012041

Firefox default:
Screenshot 2022-08-27 021556

@sime sime changed the title https://connect.trezor.io does not load in Brave when cookies are blocked Trezor Connect does not load in Brave when cookies are blocked Nov 11, 2022
@Hannsek Hannsek added connect-popup Connect popup used by 3rd parties connect-webextension and removed connect Connect API related (ie. fee calculation) labels Mar 10, 2023
@matejcik
Copy link

this also applies in Chrome when I disable 3rd party cookies.

error seen in the mother page console:

Uncaught (in promise) DOMException: Failed to read the 'localStorage' property from 'Window': Access is denied for this document.
    at s (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:1:88359)
    at t.load (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:1:88599)
    at No (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:65:346651)
    at bo.Ro (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:65:345908)
    at u.emit (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:61:10434)
    at eo (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:65:333828)
    at jt.<anonymous> (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:65:341444)
    at u.emit (https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:61:10434)
    at https://connect.trezor.io/9/js/iframe.43c34566e2d5515592c5.js:65:153015
    at Array.forEach (<anonymous>)

curiously enough, when I enable cookies, use Connect, then disable again, it works from then on.

@resetko-zeal
Copy link
Contributor

resetko-zeal commented Nov 29, 2023

This may be out of scope for this issue, but it has always been a bit weird to me that Trezor has to phone home every time I want to use it on the web. Ledger doesn't do that (as far as I can tell). Maybe Trezor can somehow get rid of this requirement and work the same way as Ledger where it doesn't need to phone home to trezor.io just to connect to a web app?

Considering that, can we really treat Trezor as self custody wallet? If trezor.io is down I will never get access to my assets, right?

When ledger has direct access to device, so let's say if leder's site is suddenly going down, it won't affect me, because I can even use old version of the app locally to have access to my devices, but same is not possible with Trezor

@mroz22
Copy link
Contributor

mroz22 commented Nov 30, 2023

Considering that, can we really treat Trezor as self custody wallet?

you can always run TrezorConnect locally. and it is totally stateless, you aren't locked-in in anyway.

@Hannsek
Copy link
Contributor

Hannsek commented Mar 15, 2024

I think this is solved by now. We can reopen this if the issue reappears.

@Hannsek Hannsek closed this as completed Mar 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
connect-popup Connect popup used by 3rd parties connect-webextension
Projects
Archived in project
Development

No branches or pull requests

7 participants