khlam / discord-sandboxed

Alternative electron-based Discord client with custom telemetry blocker and privacy-focused push-to-talk.
GNU General Public License v3.0
126 stars 20 forks source link

Cannot use client with activated 2FA #24

Open Gimleux opened 3 years ago

Gimleux commented 3 years ago

When I tried to log into my account secured by 2FA (through TOTP) and entered the correct one time code the message "A network error has occurred" was shown and the client remained in the login screen. Network connection was ensured and login worked without problems in the normal Discord-WebApp and using the Lightcord client.

Zaptosis commented 2 years ago

I'm having this same issue right now as well

darkarrow commented 2 years ago

I just downloaded and this is currently happening to me as well.

Giotto88 commented 1 year ago

Hi, analyzing the code in the .\views\js folder you can find a file named mainRender.js. Inside the file you can find a list of urls that are not blocked by the sandbox. Because the path to multifactor authentication (2fa / mfa) is not listed among those allowed, the sandbox, blocks the request. Note that to solve this problem you need to download the source code from GitHub, modify where necessary, (install node, npm, install packages npm i && npm i -d) and finally run the code using the npm start command.

How to solve

To solve this problem you simply need to add the following url to the array declared in line 73 in the file .\views\js\mainRender.js: https://discord.com/api/v9/auth/mfa/totp