From 066a503a7a23beee7078e0962f2479836d836796 Mon Sep 17 00:00:00 2001 From: ZacharyZcR Date: Wed, 13 May 2026 15:44:06 +0800 Subject: [PATCH 1/2] fix: default ignore-cert to true for rdp connections --- src/backend/guacamole/routes.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/backend/guacamole/routes.ts b/src/backend/guacamole/routes.ts index 84f8c2a6..afbd5d2c 100644 --- a/src/backend/guacamole/routes.ts +++ b/src/backend/guacamole/routes.ts @@ -205,7 +205,8 @@ router.post( port: port || 3389, domain, security: (host.security as string) || undefined, - "ignore-cert": (host.ignoreCert as boolean) || false, + "ignore-cert": + host.ignoreCert !== undefined ? !!host.ignoreCert : true, ...guacConfig, }); break; From cf27af00ac4d9a727cbe70c87965cddc7fdd9a8a Mon Sep 17 00:00:00 2001 From: ZacharyZcR Date: Wed, 13 May 2026 16:25:18 +0800 Subject: [PATCH 2/2] fix: sanitize dpi value before passing to guacd --- src/backend/guacamole/routes.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/backend/guacamole/routes.ts b/src/backend/guacamole/routes.ts index afbd5d2c..714d088b 100644 --- a/src/backend/guacamole/routes.ts +++ b/src/backend/guacamole/routes.ts @@ -192,6 +192,11 @@ router.post( } } + if (guacConfig.dpi != null) { + const parsed = parseInt(String(guacConfig.dpi), 10); + guacConfig.dpi = Number.isFinite(parsed) && parsed > 0 ? parsed : undefined; + } + let token: string; const hostname = host.ip as string; const port = host.port as number;