Commit Graph
5242 Commits
Author SHA1 Message Date
rafi_ghanbari da85f7ae69 i18n(fa): overhaul Persian translations, fix RTL word ordering, and standardize terminology (#17101)
- Fix critical semantic mistranslations and untranslated strings
- Resolve RTL/LTR bidirectional word-order scrambling
- Standardize core UI terminology across the entire file
- Fix typos, broken escape sequences, and ZWNJ spacing
2026-11-20 16:09:39 +08:00
bovirus 326deef884 Update Italian language (#17126) 2026-11-20 16:09:10 +08:00
fufesou 304e60492d fix(windows): show an installation tip for a missing service (#16948)
* fix(windows): show an installation tip for a missing service

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): preserve service state during recovery

Restore the saved stop-service option after installation errors and initialize the Windows Flutter service state before its first render.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(sciter): prioritize Windows recovery over download prompts

Show one Windows card in this order: upgrade the installed copy, install its missing service, then download a new version.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(flutter): read service recovery state synchronously

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(flutter): prioritize service recovery over update prompts

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(flutter): prioritize local installation over online updates

Offer the running version before an online update when the installed copy is older, even if its Windows service is registered.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(flutter): keep service recovery visible with hidden help cards

Allow missing-service recovery when the installed-copy upgrade card is hidden, while preserving visible upgrade priority.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): simplify service recovery priority

Show the missing-service Install action before update or upgrade cards in Flutter and Sciter. Preserve the original card order when service recovery is not needed.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): suppress recovery prompts during service installation

Suppress the missing-service prompt while an installation is active. Close Flutter sub-windows before service recovery, remove the redundant Windows error check, and qualify the service error type.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): keep service recovery tied to registration

Remove the installation-in-progress shortcut from the service probe. Flutter does not rebuild when the flag clears, which could leave the recovery action hidden after a cancelled or failed attempt. Keep the native guard against overlapping installations.

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-20 12:22:59 +08:00
21pages c50ae97512 fix: omit preset address book password from sysinfo uploads (#17130) 2026-11-19 20:35:50 +08:00
fufesou 742e507ca6 Feat: Windows, and an option to skip firewall rules (#17107)
* feat(windows): make installer firewall rules optional

Support FIREWALLRULES=0/1 in MSI and EXE installers, preserve the saved choice across maintenance and upgrades, and retain unconditional uninstall cleanup.

Persist MSI maintenance overrides with rollback and test EXE option resolution and command generation.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): keep firewall setup failures non-fatal

Restore infallible EXE script generation, warn and use the enabled default when option resolution fails, and continue after persistence errors. Use the existing non-blocking return policy for MSI firewall persistence and rollback actions.

Add regression coverage for invalid input and a failed registry command without changing valid FIREWALLRULES=0/1 behavior.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): support Y/N firewall installer options

Accept Y/y and N/n alongside 1 and 0 for FIREWALLRULES in MSI and EXE installers. Normalize MSI values before action conditions and registry writes to preserve canonical settings across upgrades.

Extend regression coverage for alias normalization and explicit overrides while retaining non-blocking failure handling.

Signed-off-by: fufesou <linlong1266@gmail.com>

* refactor(windows): simplify installer firewall option

Signed-off-by: fufesou <linlong1266@gmail.com>

* refactor(windows): retain legacy firewall installer flow

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(msi): default unknown firewall values to enabled

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): accept case-insensitive firewall option names

Keep the MSI registry search consistent with existing options and document the direct machine-hive alternative.

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-19 18:03:34 +08:00
fufesou 0d1cc89828 Fix/privacy mode2 initialization (#17090)
* fix(windows): stabilize privacy mode 2 initialization

First-time Amyuni setup can reset the display layout after the monitor
appears. Prepare it on a worker outside the privacy mutex and connection
loop, keeping remote input and video responsive during initialization.

Poll DXGI for five seconds without capture loss, with a 20-second deadline.
Log and retain the full wait when DXGI cannot be observed. Cancel pending
activation on disable, disconnect or permission revocation.

Validate active outputs before reporting success and detect subsequent
privacy loss in the display loop. Notify the authenticated owner directly
without depending on the connection manager.

Validation: default test build and two privacy-mode regression tests;
Flutter cargo check --tests; formatting and whitespace checks; successful
first-install hardware test with 12.1-second activation and manual exit.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): preserve privacy monitor cleanup and allow retries

Carry the monitor created during Amyuni preparation into privacy mode's
existing cleanup list so exiting removes one monitor instead of all managed
virtual monitors.

Wait cancellably for ongoing preparation when activation is retried, keeping
the connection responsive. Add a regression test for waiting and cancellation.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): skip privacy restoration when cancelling preparation

A cancelled preparation worker already owns cleanup. Acknowledge cancellation without restoring an inactive privacy layout, which could otherwise remove all managed virtual monitors before the worker finishes.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): roll back inactive privacy monitor preparation

Attempt to undo an accepted Amyuni monitor request when privacy preparation fails or is cancelled, even if active-display enumeration cannot see the requested monitor. Preserve non-forced removal for active outputs and report cleanup failures.

Signed-off-by: fufesou <linlong1266@gmail.com>

* chore(windows): trim privacy diagnostics and adjust polling

Remove temporary activation logs and move the preparation-lock test module after the other Amyuni items. Use a 300 ms polling interval for display stabilization and preparation-lock cancellation checks.

Signed-off-by: fufesou <linlong1266@gmail.com>

* perf(windows): probe privacy readiness without pixel readback

Check DXGI duplication access without copying or mapping desktop pixels during first-install privacy preparation. Reuse frame cleanup and preserve the existing stability window and normal capture path.

Log probe creation and recreation timing, and clarify which display flags are excluded from privacy validation.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): probe the prepared display during privacy initialization

Observe the newly created Amyuni output so the readiness probe does not contend with video capture for the same DXGI duplication interface.

Retry temporary DXGI unavailability within the existing initialization deadline while retaining the stability interval and explicit full-wait fallback.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): report privacy preparation cleanup failures

Preserve the single-monitor safety checks when cleaning up a prepared Amyuni display and propagate driver errors directly.

Leave ordinary monitor removal and best-effort bulk cleanup unchanged.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): retain privacy initialization wait across retries

Remember unfinished first-install observation after monitor creation or stability failures. Recheck it when reusing an existing Amyuni output, and clear it only after the existing observation policy completes.

Keep the state local to privacy preparation and serialize access with the existing preparation lock.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): validate privacy preparation and avoid display stalls

Keep initialization pending when its output disappears, and wait for an active output count decrease before completing preparation cleanup.

Skip privacy checks while activation or restoration holds the mutex, report poisoned locks, and log preparation errors with throttling.

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-19 17:43:55 +08:00
21pages 669cb8ac62 feat: allow custom clients to hide username and password login (#17092)
* feat: add option to hide account password login

* fix: initialize OIDC-only login in loading state

* test: cover OIDC-only login loading and empty states
2026-11-18 22:38:27 +08:00
RustDeskandClaude Opus 5.5 b633360372 Initialize libsodium before anything uses it (#16974)
* Initialize libsodium before anything uses it

The client called sodium_init() only when the update signature check
or the trusted device token first ran. That call also chooses
libsodium's implementations: where a build has both, it moves Poly1305
from the default one to the SSE2 one, whose state is laid out
differently, so a secretbox or AEAD operation another thread was in
the middle of finished under the other implementation. In one thread,
a computation straddling the call gives a wrong tag. The call now runs
once at process start: first in global_init, which core_main begins
with, and at the top of the FFI initialize, which on mobile verifies a
signature before it reaches global_init.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PkpVy2ufxgEjKd3SjXPnJ8

* Log a failed libsodium initialization and start anyway

As hbbs does: a client that does not start is worse than one that
runs with libsodium as it was before this change, and sodium_init()
fails only when it cannot lock its own mutex.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PkpVy2ufxgEjKd3SjXPnJ8

* Initialize libsodium where Android starts the server

Started at boot, MainService calls startServer with no Flutter engine,
so initialize never ran: the server worked with libsodium uninitialized
until the UI opened, and that first sodium_init() could land while
sessions were running. startServer now makes the call first, before it
verifies the custom client's signature or spawns the server.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PkpVy2ufxgEjKd3SjXPnJ8

---------

Co-authored-by: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-17 11:01:31 +08:00
Gabe FletcherandGabe Fletcher d1d497ff3c fix(linux/uinput): round relative mouse moves symmetrically (#17087)
`move_relative_` halved each delta with `(v as f32 / 2.).ceil()`, which
maps -1 to 0 but +1 to 1. Single-unit moves left or up were dropped while
right or down were kept, so in relative-mouse mode the pointer drifted
toward the bottom-right.

Round half away from zero instead: positive deltas give the same values
as before and negative deltas now mirror them. The /2 scaling is kept.

Co-authored-by: Gabe Fletcher <gabe@detailinggrowth.com>
2026-11-17 10:52:16 +08:00
a98450a995 fix(linux): keep the cursor visible over blank X11 cursors (#17078)
* fix(linux): keep the cursor visible over blank X11 cursors

Signed-off-by: luoming <ming.luo@uwa4d.com>

* fix(linux): test sign-extended X11 cursor pixels

- Drop the `count != 0` guard. With non-null pixels, a 0x0 image
  gives an empty slice, which the predicate already reports as hidden.
- Assert the sign-extended opaque pixel that 64-bit Xlib actually
  returns (`_XRead32` copies through `int *`), so a later signed
  comparison such as `p >= 0x0100_0000` fails the test.
- Use the file's `c_long` import in the test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkkfvhEPKVg85ZHovfs

* fix(linux): restore the explicit empty cursor image check

Keep `count != 0` so an empty image is visibly treated as hidden,
without relying on the zero-length `from_raw_parts` rules.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkkfvhEPKVg85ZHovfs

---------

Signed-off-by: luoming <ming.luo@uwa4d.com>
Co-authored-by: luoming <ming.luo@uwa4d.com>
Co-authored-by: rustdesk <71636191+rustdesk@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-17 10:28:25 +08:00
fufesou 3e953e886a fix: win, reg update, check (#17040)
* fix(security): prevent privilege escalation via registry recovery (ZDI-CAN-34805)

Validate all registry recovery inputs before accessing HKEY_LOCAL_MACHINE:
  - Path must start with the graphics drivers connectivity prefix
  - Key name must be exactly "Recent"
  - Subkey cannot contain path separators, dots, or null bytes
  - Old and new values must match in type and length

Validation applies unconditionally to both force=false and force=true paths,
blocking arbitrary registry writes from low-privilege IPC clients.

Maintain existing recovery lifecycle and config persistence. Add three
regression tests covering the reported attack vector and data validation.

Reported-by: BoGeun Jang <TrendAI Zero Day Initiative>
Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): preserve registry recovery behavior

Restore historical type conversion and force behavior while retaining registry target validation. Replace format restrictions with a regression test for variable-length recovery records.

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-16 17:30:15 +08:00
RustDesk 7949eca16c fix(android): enforce keyboard permission for remote input (#17061) 2026-11-15 22:58:36 +08:00
RustDeskandClaude Opus 5.5 506e111460 fix(android): sync input service state to enable-keyboard without the UI (#17064)
* Sync the Android input service state to enable-keyboard from Kotlin

enable-keyboard mirrors whether InputService is running, but only the
Flutter UI updated it. When the service was turned on from system
settings while the UI was not running, the option stayed N and new
connections were denied keyboard permission until the app was opened.

InputService now reports its state directly, and MainService reports it
again once startServer has set the config directory.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* Stop the Android UI from resetting enable-keyboard on start

ServerModel set enable-keyboard to N on every mobile UI start and relied
on the input state message to set it back. Until that message arrived,
open connections lost keyboard permission. Android now keeps the option
in step with InputService natively, so keep the reset on iOS only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 22:58:13 +08:00
RustDeskandClaude Opus 5.5 fcb485bb90 Ignore keyboard and clipboard switches on non-remote connections (#17062)
Android's input control and clipboard toggles call switch_permission_all,
which reaches every CM client. On a file-transfer, view-camera or
port-forward connection, the keyboard switch set keyboard = true and both
switches re-subscribed the clipboard service, so the host's clipboard
changes were sent to a peer that was not granted a remote session.


Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 11:49:36 +08:00
RustDeskandClaude Opus 5.5 febee50a6e fix: subscribe clipboard services from permission switches only after authorization (#17065)
* Subscribe clipboard services from permission switches only after authorization

Permission toggles in the accept window reach the connection before the
peer is authorized. The keyboard, clipboard and file switches subscribed
the clipboard services at once, so anything the host copied while the
window was open was sent to a peer that had not been accepted.

Subscribe only once authorized, as the audio switch does; on
authorization try_sub_monitor_services subscribes from the recorded
values.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* Say "until authorized" in the permission switch comment

The switch arrives after the login request, so "before login" was
inaccurate.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-15 11:20:09 +08:00
Maison da Silva fc9713c1b8 Update Portuguese translations for address book and forever (#17038) 2026-11-14 13:05:31 +08:00
Ruslan ZaitsevandRuslan Zaitsev d4df77e2fd fix(lang): keep the ?key= and @public syntax in the ID field tooltips (#17016)
* fix(lang): keep the ?key= and @public syntax in the ID field tooltips

es and hr translated ?key=, da translated @public, and the Catalan
id_input_tip held the text of a different string. Restore the literal
tokens and clear the Catalan entry so the English tooltip is shown.

* fix(lang): clear the Catalan web ID tooltip and require <id>@public in the test

---------

Co-authored-by: Ruslan Zaitsev <293677063+Dofam1nch1k@users.noreply.github.com>
2026-11-14 09:03:41 +08:00
Ruslan ZaitsevandRuslan Zaitsev 6837cb96eb fix(lang): pick the Norwegian translation for no and nn locales (#17010)
The only Norwegian table is nb (Bokmal), but systems also report Norwegian as no (the macrolanguage, e.g. no_NO) or nn (Nynorsk). resolve_lang returned no/nn, which match no table, so the UI fell back to English.

Co-authored-by: Ruslan Zaitsev <293677063+Dofam1nch1k@users.noreply.github.com>
2026-11-13 17:10:24 +08:00
Ruslan ZaitsevandRuslan Zaitsev 53a1e8aea4 fix(lang): spell the app name as RustDesk in five translations (#17008)
da, el, es, nl and uk wrote the app name as Rustdesk or RusDesk in nine entries. translate() replaces the exact string RustDesk with a custom client's name, so these spellings showed up unchanged in custom clients (for example the uk About dialog title). Adds a test that fails on master and passes with this change.

Co-authored-by: Ruslan Zaitsev <293677063+Dofam1nch1k@users.noreply.github.com>
2026-11-13 15:28:50 +08:00
Ruslan ZaitsevandRuslan Zaitsev 225ff5721e fix(lang): keep the {} placeholder in three translations (#17000)
* fix(lang): keep the {} placeholder in three translations

fa and nl dropped the {} in shortcut-must-include-modifiers and shortcut-key-not-supported, so the recording dialog lost the modifier list and the rejected key name. sc had a {} and an unrelated meaning in printer-os-requirement-tip, which is shown as plain text.

* test(lang): check fa, nl and sc against the placeholders of their English text

The existing placeholder test only looks at keys that contain {}. These three tables had mismatches against the en.rs text instead (strings whose {} is filled by Dart replaceAll). The test fails on master and passes with the translation fixes.

---------

Co-authored-by: Ruslan Zaitsev <293677063+Dofam1nch1k@users.noreply.github.com>
2026-11-13 14:23:31 +08:00
spacemingandluoming b84058e076 fix(linux): forward horizontal wheel events through uinput (#16986)
Signed-off-by: luoming <ming.luo@uwa4d.com>
Co-authored-by: luoming <ming.luo@uwa4d.com>
2026-11-13 09:46:32 +08:00
RustDeskandClaude Opus 5.5 3ccb4c4b5b fix(android): move the log toggle native into ffi.FFI (#16993)
* fix(android): move the log toggle native into ffi.FFI

Custom clients move the Kotlin classes out of com.carriez.flutter_hbb.
DocumentLogs declared setEnabled as a native method, so its export
Java_com_carriez_flutter_1hbb_DocumentLogs_setEnabled did not link
there and the app crashed on start with UnsatisfiedLinkError. The
ffi package keeps its name, so declare the native in ffi.FFI like the
others and call it from DocumentLogs.

Fixes rustdesk/rustdesk-server-pro#1035

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* ci(android): fail when a JNI native is outside ffi.FFI

Only ffi.FFI survives the package rename custom clients do. Check in
the Android build that every Rust JNI export is Java_ffi_FFI_* and that
no Kotlin file but ffi.kt declares an external fun, and write the rule
down in AGENTS.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* ci(android): report every JNI rule violation and check class lookups

Run the checks independently so one CI round lists both the Rust and
the Kotlin offenders, and also fail on a Rust lookup of an app class by
name. Note in AGENTS.md that a Kotlin method Rust calls by name needs
@Keep to survive R8.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-12 21:02:45 +08:00
OlegandClaude Opus 5.5 95cca3f661 fix(macos): turn privacy mode off before locking at session end (#16729)
* fix(macos): turn privacy mode off before locking at session end

Most closes call on_close(.., true) from inside the connection loop,
which locks the screen before the loop turns privacy mode off. On macOS
the lock is a Ctrl+Cmd+Q queued on the main queue, and privacy mode's
event tap is torn down on that same queue right after it, so the screen
did not lock and the displays came back on unlocked.

On macOS a connection that owns privacy mode now turns it off before
locking. The macOS lock_screen() also checks that the screen locked
(CGSSessionScreenIsLocked) and presses the shortcut once more if not.

Fixes #15875

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(macos): check the lock once more after the last wait

The retry loop ended its last wait without checking, so a lock that
landed in the final 100 ms pressed the shortcut again or logged a false
"Failed to lock the screen". Wait in platform::wait_locked(), which also
checks at the deadline, and keep the first press as it is on master.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* refact(macos): keep on_close a one-line hook for the turn-off before locking

Move the ownership check and the turn-off into privacy_mode::macos, so
the shared Connection::on_close only calls it, and log a failed turn-off.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(macos): turn privacy mode off on the main queue

The blackout monitor, the display reconfiguration callback and the
deferred shutdown lock g_privacyModeMutex on the main thread, while the
turn-off held that mutex and waited for the main queue to tear the event
tap down, so the two could deadlock. The turn-off now runs before the
lock at session end, where a deadlock would also keep the lock from
being requested.

Called off the main thread with privacy mode on, MacSetPrivacyMode(false)
now runs the whole turn-off on the main queue. With privacy mode off it
returns as before, without touching the main queue.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(macos): leave lock_screen() as on master

Review asked to keep this PR to the ordering fix. Drop the second
press in lock_screen() and the wait_locked() helper it used, so
ordinary macOS lock requests behave as on master again. Privacy mode
is still turned off before the lock at session end.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-09 16:04:24 +08:00
ceedc314d7 fix: block sensitive config options in strategy updates (#16696)
* fix: block sensitive heartbeat strategy options

Filter 25 sensitive server, trust, authentication, access-control,
deployment and local service settings before merging heartbeat strategy
options. Preserve the existing HTTP protocol, all 27 current server
policy options, and other unblocked options for version compatibility.
Strategy responses remain unauthenticated.

Add regression coverage for blocked writes and clears, including registry
recovery data, and preservation of existing and future policy options.

Tests: cargo test --lib hbbs_http::sync::strategy_tests --locked (2 passed)

* fix: log rejected strategy options and strengthen regression tests

* fix: block trusted-device expiration in strategy updates

A strategy setting it to 0 would make trusted devices skip 2FA forever.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix: block websocket port in heartbeat strategies

* fix: preserve security policy controls in heartbeat strategies

Allow the connection-window and scope-violation policy controls.
Keep enable-trusted-devices blocked because disabling it clears existing
trusted-device grants, which re-enabling does not restore.

* fix: acknowledge heartbeat strategies after application errors

Skipping modified_at after an application error allows the server to
deliver the same strategy version repeatedly. Authentication options
(2FA, trusted-device enablement and expiration) are already blocked,
and the authentication-update path applies unrelated options first.

Keep reporting application errors, but continue processing modified_at
so the failed version is acknowledged. Log "strategy updated" only on
success. Acknowledgement does not guarantee full application; retrying
a failed strategy requires publishing a new version.

Validation: cargo test --lib hbbs_http::sync::strategy_tests --locked
(2 passed; filter coverage only, no live heartbeat verification).

* Revert "fix: acknowledge heartbeat strategies after application errors"

This reverts commit a03d235236.

* test: fix future strategy option spelling

---------

Co-authored-by: rustdesk <71636191+rustdesk@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-08 23:51:33 +08:00
fufesou 3c69194ac4 fix(windows): continue removal after configuration sync errors (#16865)
* fix(windows): continue removal after configuration sync errors

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): revoke local trust after removal sync errors

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-08 22:28:28 +08:00
RustDeskandClaude Opus 5.5 1ff458bdf3 fix(linux): serve a greetd Wayland login screen over DRM (#16894)
* fix(linux): serve a greetd Wayland login screen over DRM

greetd starts its greeter with no XDG_SESSION_TYPE, so pam_systemd records
the session as Type=tty and the display server reads as x11. is_gdm_user only
knows gdm and sddm, so the DRM login-screen path never engaged at
cosmic-greeter and the greeter's --server captured over X11: a black stream.

Recognize a seat0 session with Class=greeter and Type=tty whose user has a
Wayland socket in /run/user/<uid> as a Wayland login screen, in
is_login_screen_wayland and in Desktop::is_login_wayland, so it takes the path
built for GDM and SDDM greeters. The compositor creates its socket after logind
registers the session, so a greeter first seen without one is asked again on
each refresh. drm builds only; console greeters (tuigreet, agreety) have no
socket and keep their current behavior.

Fixes #16891.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* fix(linux): drop the previous session's compositor env at a greetd greeter

Going straight from a user session to a greetd greeter kept that session's
WAYLAND_DISPLAY and bus address in Desktop, and the greeter --server was
started with them: an endpoint it is handed is never searched past, so the
compositor layout lookup failed and the uinput range fell back to the DRM
union. Clear every compositor variable when a greetd greeter is adopted.

Leave a forced display server alone, as IS_X11 and is_x11_for_drm already
do, and log a failing loginctl instead of taking it for "not a greeter" in
silence.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* fix(linux): take a greetd greeter for Wayland only from its socket

Type=tty names no display server, and the protocol fallback reads the
service's own XDG_SESSION_TYPE, not the session's. A service that inherited
XDG_SESSION_TYPE=wayland therefore made is_login_wayland() answer yes for a
tty greeter that was never adopted, skipping the socket check and a forced
display server. Start a tty greeter from x11 so only
adopt_wayland_tty_greeter can make it Wayland.

Also log an unexpected error reading the runtime directory; a directory
that does not exist yet stays a silent "no socket".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* fix(linux): adopt a greetd greeter when Wayland is forced

adopt_wayland_tty_greeter skipped any forced display server, so with
RUSTDESK_FORCED_DISPLAY_SERVER=wayland the greeter stayed on the x11 path
it now starts from, while its --server was told Wayland. Only a server
forced to x11 is the operator overruling the socket; one forced to Wayland
agrees with it, so adopt the greeter and clear the previous session's
compositor variables as for an unforced one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* fix(linux): keep a greetd greeter off the Wayland login gate when x11 is forced

With RUSTDESK_FORCED_DISPLAY_SERVER=x11, adopt_wayland_tty_greeter leaves a
greetd greeter on the x11 path, but is_login_screen_wayland() still took it
for a Wayland login screen. The login gate in connection.rs then refused the
connection while the DRM verdict was not Available, where master accepted it.
The tty-greeter branch now checks the same override; the GDM/SDDM test is
unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-08 21:10:52 +08:00
Mariano Abad 734273b61c fix(drm): stop re-encoding a still screen (#16888)
* drm: stop repeating an unchanged frame after 3 beats

A still screen sent one identical frame per second for ever (REPEAT_EVERY).
Each of those counts as a real frame in video_service and restarts
static_refresh, so its budget never ran out and the encoder kept re-encoding
the cached frame, about 26 times a second with h264_vaapi. x11 and pipewire
drop a repeat for good.

Send at most MAX_REPEATS (3) repeats after the last new picture. A hardware
encoder switches after 3 failed encodes, so those cover the failed-encode
case the beat is for. A new picture starts the count over.

* drm: notice a new subscriber while the screen is still

Once a still screen has used up its repeats and the static refresh
budget, the WouldBlock arm no longer reaches handle_one_frame or a
static refresh encode, where a subscriber added without a refresh
(the mobile display switch) is noticed. That client got no picture
until the screen changed.

Run the same new-subscriber check at the top of the WouldBlock arm.

* drm: switch for any new subscriber on a still screen

In the WouldBlock arm nothing is sent after the check, so also switch
when the last active subscriber has left and a new one is pending:
the snapshot would promote it with no frame ever following. Log the
expected event at trace level.

* drm: switch for a new subscriber once the encoder has run

Nothing is sent in the WouldBlock arm, so the switch is needed only
when the encoder already produced frames, even if the subscribers
that got them are gone: otherwise the new one gets no keyframe until
the screen changes. A fresh encoder needs no switch. Log the expected
event at trace level.

* drm: leave the new subscriber check in video_service as it was

This reverts the video_service.rs changes of fd872773b, de139dc97 and
ea73ed51f. A subscriber added without a refresh to a still screen is not
specific to drm, so it does not belong in this change.
2026-11-08 18:45:12 +08:00
fufesou 2228db8a10 fix(windows): retry service IPC before terminating the GUI (#16913)
Give the Start service caller one second to arrange its replacement and exit before retrying main IPC startup. Keep this workaround in the server startup thread and preserve the existing termination path when the retry fails.

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-08 16:17:26 +08:00
fufesou 78450f4987 Fix/windows installer directory guard (#16908)
* fix(windows): guard staged installer directories during handoff

Create restrictive staging directories and retain non-delete-sharing handles while CMD consumes packages, scripts and shortcuts. Adapt output paths and cleanup, and add a directory-replacement regression.

Validated with 11 focused Windows tests. Directory protection remains tied to the lifetime of the creating process.

Signed-off-by: fufesou <linlong1266@gmail.com>

* test(windows): streamline installer directory guard tests

Keep installer-file tests in their original inline module and remove the duplicate CMD-copy check from the directory replacement regression. Preserve directory protection and existing handoff coverage.

Validation: Windows library test compilation, four focused tests, rustfmt and git diff --check.
Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): use plain rd for empty staging directories

Remove the inapplicable /q switch from non-recursive staging-directory cleanup. Keep recursive deletion confined to the runner directory.

Validated with Windows library test compilation, four focused tests and isolated CMD probes for owner termination, nonempty staging directories and exit-code preservation.

Signed-off-by: fufesou <linlong1266@gmail.com>

* test(windows): pin installer staging directory permissions

Check effective ordinary-owner directory rights independently of the sharing guard. Clarify guard lifetime and the Rust and CMD cleanup responsibilities.

Validation: Windows library test compilation, four focused tests, rustfmt and git diff --check.
Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-08 13:06:43 +08:00
xpehter 3513c9751d fix(audio): look up the named audio input among input devices only (#16906)
get_audio_input() searched HOST.devices(), which lists input and output
devices together, and took the first device whose name matched. CoreAudio
gives a USB microphone with a headphone jack two devices with the same
name, and the output one can come first. RustDesk then picked the output
device, default_input_config() failed with StreamTypeNotSupported, and the
voice call sent no audio from the macOS side ("Failed to get default input
format" every second).

Search HOST.input_devices() instead, so only devices that support input
can match the configured or default input name.

Signed-off-by: xpehter <32315536+xpehter@users.noreply.github.com>
2026-11-07 11:00:14 +08:00
f4c0b13df7 fix(windows): drop the named-pipe installer handoff that F-Secure blocks (#16889)
* fix(windows): drop the named-pipe handoff that F-Secure blocks

Since #16562 the elevated cmd.exe waited on
`set /p RUSTDESK_HANDOFF=<"\\.\pipe\rustdesk-install-<uuid>"` until the
unelevated parent released the staged files' DELETE handles. F-Secure's
behavior detection closes that cmd's end of the pipe, so installation and
Stop service fail with "The pipe is being closed. (0x800700E8)"
(ERROR_NO_DATA) and the BAT never runs (#16840, #16842).

The handles exist only to delete the staged files when UAC is cancelled.
Tampering is prevented by the DACL set at creation, which grants the
unelevated owner read/execute only, and that is unchanged. Release the
handles before launching cmd and run the BAT directly. A cancelled UAC
prompt now leaves the staged BAT and shortcut in the protected directory.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* docs(windows): correct the handoff comments after dropping the pipe

The cleanup handle is no longer held through the UAC prompt, and the files
stay protected by their DACLs together with the parent directory's
permissions, not by the DACL alone. Describe the F-Secure failure as what
was observed: cmd's end of the pipe closed before the release signal.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkiaGp2k8okvs4MpCUq

* fix(windows): stage installer inputs in guarded directories

Create private staging directories atomically with restrictive ACLs and retained handles that forbid delete sharing. Reuse the existing handle-based cleanup and cover BAT, shortcut and verified-update inputs with Windows regression tests.

Known limitation: terminating the RustDesk caller before CMD exits still releases the directory guards and can leave staging directories behind.

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): clean up staging directories after batch execution

Remove each batch's own empty staging directories after its files, including when uninstall has terminated the Rust owner. Preserve the installer exit code and cover standalone batch cleanup with a regression test.

Signed-off-by: fufesou <linlong1266@gmail.com>

* test(windows): create protected output directory in handoff test

Exercise the production directory constructor under the retained staging-directory guard while preserving the existing elevated and unelevated assertions.

Signed-off-by: fufesou <linlong1266@gmail.com>

* test(windows): avoid protected installer fixture leftovers

Retain the production directory ACL check with native fixture cleanup. Remove the replacement and handoff tests that leave protected files after unelevated runs.

Signed-off-by: fufesou <linlong1266@gmail.com>

* revert(windows): restore installer handoff to 8ea7251e3

Restore the tracked tree to 8ea7251e35.
Remove the later guarded staging directories and cleanup/test changes,
while retaining the original direct CMD launch without a named pipe.

Reverted changes:
- 6f71c7d3a0
- a188f7b8f1
- d7fb4aff5f
- 6ace789b13

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: fufesou <linlong1266@gmail.com>
2026-11-07 00:11:18 +08:00
bovirus cd2e41383b Update ialian language (#16896) 2026-11-06 17:13:32 +08:00
Minh Nguyen 8d74ff0e57 fix(windows): write the clipboard owner marker first (#16695)
The Windows clipboard setter empties the clipboard and writes each format
in order, stopping at the first one that fails. With the marker written
last, a failure after an earlier format succeeded could leave unmarked
content on the clipboard. RustDesk could then read it back as a fresh local
copy and return it, causing the controller to empty its clipboard again.
For applications such as Excel, that destroys the application's copy state.

Write the marker first on Windows so a partial write stays identifiable
as RustDesk-owned. Other platforms keep appending it, so their payload
order is unchanged.

This covers a format failure before the marker is written, not a marker
that is written but later missing or unreadable.

Refs #16291
2026-11-06 17:11:02 +08:00
LukasandRustDesk fdffc37bb0 fix(server): ignore spaces around IP whitelist entries (#16692)
* fix(server): ignore spaces around IP whitelist entries

* fix(server): parse the IP and ID whitelists the same way, and fail closed

Both checks now read their option through one parser that accepts the
separators the settings dialogs accept (commas, semicolons, whitespace) and
drops empty entries. The IP whitelist split only at commas, so an entry
with a space around it, or a list from custom client settings separated by
semicolons or newlines, matched no address and locked the listed ones out.

A list is off only when the option is empty or holds only commas, which is
how the dialogs store a cleared list. Any other value without entries, such
as a lone space, now blocks every peer for the ID whitelist too, where it
used to let everyone in.

* fix(flutter): skip empty entries in the IP whitelist dialog

A leading or trailing comma gave an empty entry that the dialog rejected
as an invalid IP. Drop empty entries before the check, as the ID whitelist
dialog already does.

* fix(flutter): reject whitelist input that holds only separators

Dropping empty entries made the IP dialog save `,` or `;` as a cleared
whitelist, which turned the restriction off; before, that input failed
the IP check, and the server reads the same text as a list that allows
no one. Both dialogs now split through whitelistInputEntries, which
returns null for separator-only input, and show "Invalid IP" or "Invalid
ID" for it. Empty input and the Clear button still clear the whitelist.

* fix(flutter): keep a whitelist that lets no one in when its dialog is saved unchanged

A stored whitelist such as " , " is on but names no entry, so the server
lets no one in. Its dialog shows it as blank lines, and OK pressed
without an edit trimmed those to an empty field and saved a cleared
whitelist, lifting the restriction.

Both dialogs now take the shown text from whitelistDialogText and, when
the field is unchanged and whitelistLetsNoOneIn says the stored value
lets no one in, close without saving. Clearing the field and the Clear
button still clear the whitelist. The tests cover the load, unchanged
OK and save path for both cleared values (',' and '').

* style(flutter): drop a doubled blank line in whitelist_input.dart

* fix(ui): keep a whitelist that lets no one in when the Sciter dialog is saved unchanged

The Sciter IP whitelist dialog shows " , " as blank lines, trimmed the
submitted text before comparing it with what it showed, and so saved an
unchanged deny-all whitelist as a cleared one. The submitted text is now
compared first, as the Flutter dialogs do.

* test(flutter): name the round-trip test after the helper it checks

* fix(server): narrow the change to ignoring spaces around IP whitelist entries

As the review suggests, only the original fix stays: IP whitelist
entries are trimmed, so "192.168.1.0/24, 10.0.0.1" admits 10.0.0.1.

The ID whitelist keeps master's parsing and its "empty means allow"
behavior. The Flutter dialogs and the Sciter UI are back to master,
and the shared parse_whitelist and the dialog helpers are gone. The
trim lives in ip_whitelist_entries so that one regression test can pin
it. A whitespace-only IP whitelist still blocks everyone, as on master.

* Refactor IP whitelist entries handling and comments

Updated comments for clarity and adjusted whitespace handling in IP whitelist entries.

---------

Co-authored-by: RustDesk <71636191+rustdesk@users.noreply.github.com>
2026-11-06 10:00:54 +08:00
Lukas f2c16e1e20 fix: report the CPU frequency in GHz with /1000, not /1024 (#16887)
sysinfo's Cpu::frequency() is in MHz: on Linux it is scaling_cur_freq
(kHz) divided by 1000, or the "cpu MHz" line of /proc/cpuinfo, and on
macOS its documentation says MHz. get_sysinfo divided it by 1024 before
printing GHz, so a CPU at 2885 MHz showed as 2.82GHz instead of 2.89GHz
in the device info sent to the server.
2026-11-06 09:34:00 +08:00
fufesou 91e43e24ea fix: clarify unlimited trusted-device duration (#16886)
Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-06 09:30:31 +08:00
fufesou cbde394666 fix(windows): address IPC review follow-ups (#16885)
Require a dedicated child success exit code so an unmatched test filter cannot pass the GUI startup regression. Replace the ACE type binding with a local constant and drop the unused SystemServices feature.

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-05 23:43:54 +08:00
RustDeskandClaude Opus 5.5 2c085f91db Only relay to addresses this peer offered, and bound relay uuids (#16858)
* Only relay to addresses this peer offered, and bound relay uuids

A RequestRelay forwarded by the rendezvous server carries the relay
address and uuid the requester filled in, and the controlled peer
dialed that address as given. A genuine controller only echoes the
relay this peer put in its own PunchHoleSent or LocalAddr, so remember
those (plus the relay this peer would pick by itself) and drop any
request that names something else, before resolving or connecting.

Relay uuids are opaque pairing keys that arrive from the network and
are sent on to the relay, so both the controlled side (RequestRelay)
and the controller (RelayResponse) now refuse ones that are empty,
longer than 128 bytes, or carry anything but ASCII alphanumerics, '-'
and '_'. This matches the check hbbs applies before forwarding.

Known limits: a WebRTC-failure fallback that follows a peer-initiated
relay whose address hbbs rewrote for the LAN is refused; a refused
request gets no reply, so the controller sees its relay attempts time
out.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkh9Gd5dwGW8vL9JNV8

* Expire reported relays after ten minutes

A relay dropped from the configuration or no longer offered by the
rendezvous server stops being an accepted RequestRelay destination once
its last report is ten minutes old. Reporting it again restarts the
clock. The list is shared by all mediators, so it is not cleared when
one starts.

The comment now says where the entries come from and that the list only
bounds where a request can send this peer; it does not authenticate the
request.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkh9Gd5dwGW8vL9JNV8

* Test relay expiry through the relay request check

The expiry tests only called the cache helpers, so a request check that
stopped honouring the expiry would still pass them. check_relay_request
now takes the time like the helpers do, and the request test asserts an
expired relay is refused and accepted again once re-reported. Passing a
later time instead of recording an earlier one avoids Instant underflow
on Windows hosts up for less than ten minutes.

Also formats this PR's own relay check and expiry tests with rustfmt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JAxkkh9Gd5dwGW8vL9JNV8

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-05 23:42:38 +08:00
Lukas 78742bcd31 fix(lang): pick Hebrew and Indonesian from legacy Android locale codes (#16882)
* fix(lang): pick Hebrew and Indonesian from legacy Android locale codes

The Android service translates its notifications and floating window
menu with Locale.getDefault().toString(). Android's Locale reports
Hebrew and Indonesian with their legacy ISO 639 codes, iw_IL and in_ID,
unless both the device and the app's target SDK are Android 15 or
later. resolve_lang took "iw" and "in" as language codes, found no
table, and fell back to English.

Map "iw" to "he" and "in" to "id", next to the Kazakh and Georgian
mappings.

* fix(lang): say which Android versions report the legacy codes
2026-11-05 22:55:53 +08:00
fufesou 83e508cfdf Fix/windows ipc server auth (#16755)
* fix(ipc): authenticate Windows named pipe servers

Restrict main and service pipe instance creation and authenticate the
connected server before exchanging IPC data. Open clients with data access
that excludes FILE_CREATE_PIPE_INSTANCE.

Require SYSTEM ownership for service channels. For main IPC, also accept a
same-user server with a restricted DACL, matching session and executable,
and sufficient elevation. This includes the UI hosting main IPC while the
service is unavailable, without relying on installation or service config.

Elevated clients reject non-elevated servers, and SYSTEM clients reject
user-owned pipes. New clients reject old permissive listeners until those
processes restart on the fixed version.

Add native Windows regression tests for instance-creation permissions,
DACL rejection before application data, and normal client communication.

Signed-off-by: fufesou <linlong1266@gmail.com>

* refactor(ipc): clarify Windows pipe security policy

Signed-off-by: fufesou <linlong1266@gmail.com>

* test(ipc): bound the Windows server rejection test

Signed-off-by: fufesou <linlong1266@gmail.com>

* test(ipc): bound the complete Windows client communication test

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): keep portable GUI alive on IPC startup failure

Only attempt GUI fallback hosting when the main IPC pipe is absent. Bind its listener before marking hosting active or starting rendezvous, and return on bind failure without terminating the GUI.

Preserve IPC authentication and explicit server-process behavior. Cover rejected listeners, bind collisions, and standalone IPC communication with Windows regression tests.

Signed-off-by: fufesou <linlong1266@gmail.com>

* refactor(windows): simplify portable IPC startup fallback

Rely on exclusive listener creation instead of a separate pipe-presence probe. Keep GUI bind failures recoverable and require a successful bind before starting host services.

Retain the subprocess regression for bind-failure process survival, removing redundant GUI tests and their helper parameters and delay.

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-05 22:35:07 +08:00
RustDeskandClaude Opus 5.5 7b5540bd61 fix(port-forward): keep the KCP handle alive and send a close reason (#16880)
* fix(port-forward): keep the KCP handle alive and send a close reason

A port forward whose connection was won by a UDP punch (KCP) died right
after login. `Client::start` returns, next to the stream, the KCP handle
that drives the stream's UDP I/O, and both login functions dropped it on
return, so the stream failed with "stream closed" on first use. The handle
now goes with the stream to whichever task owns it: the raw pipe's task,
`run_legacy`'s task, or `tunnel_loop`.

Closing such a stream needs care as well. KCP's FIN is sent by the
handle's own tasks and dies with the handle, so the peer would hold the
connection until its own timeout. A KCP tunnel closed from this side now
sends a close reason first, as the remote session does. The port-forward
window's io_loop passes Close on to every mapping and waits 100ms before
its runtime is dropped, so the tunnels get to send it; a login that
receives the Close now ends instead of swallowing it.

Known limits: the raw pipe (a peer without mux) cannot carry a close
reason after `set_raw`, and exits during login send none.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* docs(port-forward): say what the close-reason send bound covers

The bound on sending the close reason keeps that step inside the window's
wait, but a data send already in flight in another arm of `tunnel_loop` is
not bounded by it and holds the close until it returns. The comment said
the whole close fit; say which part does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-05 21:39:53 +08:00
RustDeskandClaude Opus 5.5 1d828eee7a fix(macos): launch the service daemon directly instead of through sh (#16879)
The LaunchDaemon ran `/bin/sh -c .../Contents/MacOS/service`, so macOS
attributes the background item to /bin/sh: Login Items shows "sh", and
AssociatedBundleIdentifiers cannot link it to the app because the
launched executable is not signed by the app's team. Start the signed
service binary itself.

sh exec'd the single command anyway, so the running process is the
same. App names are limited to letters, digits, '-' and '_', so the
path never needed shell parsing.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-05 16:44:21 +08:00
fufesou 13cccb2f7b Fix/windows installer temp junction (#16871)
* fix(windows): support secure installer temp junctions

Preserve Windows Temp when persistent ACLs are available, validate resolved junction targets, and fall back to ProgramData only when the target volume lacks ACL support. Guard parent directories while creating protected installer files and cover the Windows sharing behavior with regression tests.

Refs rustdesk/rustdesk#16841

Signed-off-by: fufesou <linlong1266@gmail.com>

* fix(windows): simplify installer temp junction fallback

Signed-off-by: fufesou <linlong1266@gmail.com>

* test(windows): cover installer staging path selection

Signed-off-by: fufesou <linlong1266@gmail.com>

---------

Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-05 15:52:35 +08:00
deagusandClaude Opus 5.5 6ef56d779f fix(lang): correct typos in the Indonesian translation (#16875)
* fix(lang): correct typos in the Indonesian translation

Fix misspellings such as "kd", "halam", "ketik", "kostum" and
"kadaluwarsa", and the capitalization of "Anda" and "kamu" in the
middle of a sentence. Keys and placeholders are unchanged.

Signed-off-by: deagus <dedeaskyt121@gmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(lang): translate the Indonesian elevation username hint

The value was "panduan_elevasi_nama_pengguna", a translated copy of the
key rather than a sentence, and it showed as the hint of the username
field in the elevation dialog. Translate the English text instead. The
double backslash is a literal one, as in en.rs.

Signed-off-by: deagus <dedeaskyt121@gmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Signed-off-by: deagus <dedeaskyt121@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-05 14:37:47 +08:00
rustdeskandClaude Opus 5.5 beeeef14f0 fix(wayland): pass on an unclassified capture error instead of "x11 expected"
Every portal handshake failure is tagged and gets its own message, so the
untagged errors that still reach this fallback at login are internal ones
(GStreamer init, a poisoned lock). Reporting them as "x11 expected" sent
users off to switch to X11 for faults X11 does not fix, and hid the real
error. Send the error itself, as the Ubuntu 21+ branch already does.

No regression test: CI runs on Ubuntu 24.04, where map_err_scrap takes the
Ubuntu branch and returns the raw error both before and after this change.

Refs #16829

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 08:26:06 +08:00
21pages a85ad89ffc feat: request approval (#16784)
* feat: add connections without sending passwords

Add Without password actions and pass the selection through desktop,
mobile and Web sessions. Omit the password when constructing LoginRequest,
preserve saved credentials, and reuse the existing approval and OS login
dialogs. Keep protocol and controlled-side authentication changes separate.

* fix: preserve login method across session windows

* fix: skip password persistence for consent connections

* refactor: unify request approval menus and naming

* chore: move request approval translation key to the end

* i18n: translate request approval menu label

* fix: align request approval menu layout and icons

* fix: avoid duplicate focus stops in request approval menus

* fix: distinguish request approval submenus on mobile

* fix: open overflowing submenus to the left

* Revert "fix: distinguish request approval submenus on mobile"

This reverts commit 7f0e50d4e4.
2026-11-02 23:48:27 +08:00
mblbr 037b8787fe Clarify that "Forget Password" clears the saved password (#16826)
Update the text for "Forget Password" to "Clear saved password" to avoid confusion with password recovery. Both Flutter and legacy Sciter UIs use this key and share the updated translations.

Keep the existing translation key, UI calls, and password-clearing behavior unchanged. Leave Italian translations untouched.

Signed-off-by: mblbr <150243082+mblbr@users.noreply.github.com>
2026-11-02 23:47:00 +08:00
RustDeskandClaude Opus 5.5 4ec4ec3d14 fix(ci): build macOS arm64 with Flutter 3.44 (#16821)
* fix(ci): build macOS arm64 with Flutter 3.44

Flutter 3.24.5's macOS engine can crash in attributedSubstringForProposedRange
with an out-of-bounds range on an empty string (#16817). The fix
(flutter/flutter#153157) landed after 3.24 and was never cherry-picked, and
3.44 has the bounds check. So macOS arm64 now builds with Flutter 3.44.9, the
same way Windows arm64 does: the 3.44 bridge artifact and the shared source
patch script. The script uses GNU `sed -i`, which BSD sed on macOS rejects,
so the step puts GNU sed first on PATH. The 3.24 dropdown patch is skipped,
because 3.44 already has that fix.

macOS x86_64 stays on 3.24.5: 3.44's FlutterMacOS needs macOS 10.15 there,
and the build targets 10.14. The Dart tests move to the x86_64 job, so CI
still runs them against the 3.24.5 sources that most platforms ship.

Refs #16817

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(ci): keep CocoaPods on macOS arm64 and run Dart tests on both arches

Flutter 3.44 turns on Swift Package Manager by default. On the first
`flutter build macos` it would migrate Runner.xcodeproj and Runner.xcscheme,
and build file_selector_macos, path_provider_foundation, url_launcher_macos
and video_player_avfoundation through SwiftPM while the other 12 plugins stay
on CocoaPods. If the migration fails, the build fails. All 16 macOS plugins
still ship a podspec, so turning SwiftPM off keeps arm64 on the CocoaPods-only
path the 3.24.5 build uses, and this change only swaps the engine.

The Dart tests now run on both macOS jobs: x86_64 covers the 3.24.5 sources
most platforms ship, and arm64 covers the patched 3.44 sources it ships.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* ci: update comments that still call Windows arm64 the only Flutter 3.44 build

The FLUTTER_WINDOWS_ARM_VERSION note, the Windows source-patch step and the
header of apply_flutter_3.44_source_patches.sh still said Windows arm64 is
the only Flutter 3.44 target. They now mention macOS arm64 too, and the
script header records that macOS needs GNU sed for its `sed -i` calls.
Comments only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test: make test_RustDesk_interval_sleep deterministic

The test recorded tick times as wall-clock seconds, rounded to the nearest
second, and asserted all 5 were unique. If the runner stalled for close to a
second, two correct ticks rounded to the same value and the test failed
(macOS arm64 CI on #16821: left 5, right 4).

It now runs on tokio's paused clock and checks what ThrottledInterval
guarantees: ticks are at least 0.9 * period apart. A plain tokio interval
bursts its missed ticks with no gap, so a lost throttle still fails. This
needs tokio's test-util feature for the existing dev-dependency. It adds no
crates, so Cargo.lock is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 22:15:54 +08:00
fufesou 29d1ab26a1 fix(sciter): avoid double DPI scaling of main window minimum size (#16824)
Signed-off-by: fufesou <linlong1266@gmail.com>
2026-11-02 22:15:10 +08:00
rustdeskandClaude Opus 5.5 23e5bb471a finish translations
Fill install-directory-not-empty-tip (added in #16783) for every
language, including it.rs at the maintainer's request.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-01 13:50:20 +08:00