Compare commits

...

2 Commits

Author SHA1 Message Date
Sucukdeluxe
77240ae18d Release v1.6.76 2026-03-06 11:29:44 +01:00
Sucukdeluxe
90c73c4091 🐛 fix(bestdebrid): set user agent on session and webContents level
Cloudflare Turnstile blocks Electron's default user agent. Set a
Chrome user agent on both the session and webContents level so the
login captcha passes correctly.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-06 11:29:15 +01:00
2 changed files with 6 additions and 1 deletions

View File

@ -1,6 +1,6 @@
{
"name": "real-debrid-downloader",
"version": "1.6.75",
"version": "1.6.76",
"description": "Desktop downloader",
"main": "build/main/main/main.js",
"author": "Sucukdeluxe",

View File

@ -173,6 +173,10 @@ export class BestDebridWebFallback {
existing.close();
}
// Set user agent on session level so Cloudflare Turnstile sees a real Chrome
const currentSession = session.fromPartition(partition);
currentSession.setUserAgent(BESTDEBRID_USER_AGENT);
const window = new BrowserWindow({
width: 1120,
height: 900,
@ -186,6 +190,7 @@ export class BestDebridWebFallback {
nodeIntegration: false
}
});
window.webContents.setUserAgent(BESTDEBRID_USER_AGENT);
window.setMenuBarVisibility(false);
window.on("closed", () => {
if (this.loginWindow === window) {