AGENTS.md now holds only policy that no tool enforces and that an agent
would not find on its own path. The first pass dropped content
discoverable from the tree or covered by a skill or `STYLE.md`: the role
preamble, the generic workflow, file and directory listings, xtask
command lists, the copy of the style rules, and a stale list of crates
missing from `ARCHITECTURE.md`. A review pass then moved rules to where
they trigger. Comment wrapping and test-module placement went to
`rust-style`. The dependency policies went to `public-dependency`. The
`iron-remote-desktop` base-API rule went to nested `AGENTS.md` files
next to its TypeScript and Rust definitions. It dropped rules already
stated by `ARCHITECTURE.md`, `protocol-reviewer`, or root `Cargo.toml`
comments. It also added a pointer to the testsuite crates and a warning
that synced skills are overwritten from Devolutions Gateway. The file
goes from 155 to 35 lines.
`STYLE.md` now extends the sentence-per-line rule to code comments and
doc comments. Devolutions Gateway and picky-rs vendor this file and will
re-sync it.
New skills, mirrored from Devolutions Gateway and added to the weekly
sync list:
- `rust-style`: everyday Rust rules from `STYLE.md`.
- `rust-style-reviewer`: fresh-context style review of changed Rust
lines, now run by `code-review`.
- `test-oracle-reviewer`: checks that a test's expected value is
independent of the code under test.
- `test-pruner`: prunes and strengthens tests with oracle classification
and cargo-mutants evidence.
The sync list also gains the remaining generic Devolutions Gateway
skills. `tdd` and its closure (`grill-intent`, `intent-files`,
`variants`) are dependencies of the synced `test-writer`,
`test-reviewer`, and `test-pruner`. The `contribute` flow brings `lead`,
`orchestrate-effort`, `review-feedback-loop`, `blind-testsuite`,
`contract-review`, `dependency-pruner`, `dependency-reviewer`,
`intent-drift-audit`, and `intent-review`. Intent and skill authoring
brings `agents-md`, `agents-md-review`, `contract-authoring`, and
`skill-discipline`. `code-review` now runs `intent-drift-audit`,
`intent-review`, `contract-review`, `test-reviewer`, and
`dependency-reviewer` when their conditions apply.
Claude Code discovers project skills only under `.claude/skills` and
reads only `CLAUDE.md`, so `.claude/skills` links to `.agents/skills`
and `CLAUDE.md` links sit beside both nested `AGENTS.md` files, as the
root one already does.
`AGENTS.md` now tells agents to start a work session with `/contribute`,
which picks the delivery flow by scale and the skills each step needs.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
`<iron-remote-desktop>` dispatches `ready` at the end of `initcanvas()`,
but `onMount` only then runs `await clipboardService.initClipboard()`.
That awaits `navigator.permissions.query({ name: 'clipboard-read' })`
before installing the clipboard callbacks, and
`RemoteDesktopService.connect()` only registers
`remoteClipboardChangedCallback` / `forceClipboardUpdateCallback` on the
session builder when those callbacks are installed.
So a host that connects as soon as `ready` fires gets a session with no
CLIPRDR channel, and the clipboard silently doesn't work.
iron-svelte-client connects after the user clicks, which hides the race.
With this commit:
- `ready` is dispatched from `onMount` after `initClipboard()` settles.
If clipboard initialization throws, the error is logged and `ready`
still fires.
- Test setup: mounting a Svelte component under vitest needs Svelte's
browser build, so `vite.config.ts` sets `resolve.conditions:
['browser']` when `VITEST` is set. It also skips vite-plugin-svelte's
style preprocessing in that case: the plugin (5.x, for Vite 6) crashes
in `preprocessCSS` under vitest 2's bundled Vite 5. The component's
styles are plain CSS. Builds are unchanged.
Co-authored-by: meanaverage <18336095+meanaverage@users.noreply.github.com>
Extracted from cxxzhang's #1408.
Win7-class servers reject the web client's enhanced graphics path.
The JS `legacy_graphics` SessionBuilder extension, default false,
switches BitmapConfig to 32-bpp lossless bitmaps, empty codecs, and
no bulk compression. Empty codecs are the BitmapConfig option that
lets the connector skip SurfaceCommands once that gating lands.
This is one of three independent follow-ups from #1408. It pairs
with the connector surface-capability gating PR but does not depend
on that PR being merged first.
The default enhanced web path is unchanged: 16-bpp, lossy codecs,
and compression_type None.
Co-authored-by: zhangshuangjun <zhangshuangjun@leagsoft.com>
Co-authored-by: zhangshuangjun <zhangshuangjun@leagsoft.com>
Hyper-V over RDCleanPath needs PCB → TLS on the proxy, then CredSSP →
X.224 on the client. Ordinary RDCleanPath stays X.224-first.
Still VERSION_1 with the same DER fields. An explicit VMConnect request
carries a Unicode PCB payload in `preconnection_blob` with no X.224; the
proxy encodes the binary PCB. Generic PCB requests keep their existing
X.224-first behavior.
Gateway reference implementation:
[Devolutions/devolutions-gateway#1372](https://github.com/Devolutions/devolutions-gateway/pull/1372)
Checked locally: Rust builds, formatting, Svelte typecheck, and .NET
build. Real nested Hyper-V E2E through Gateway: Native rendered 18
frames, Avalonia connected and rendered its first frame, and Web
rendered a non-empty 1280×720 canvas.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Marc-André Moreau <mamoreau@devolutions.net>
Adds a pluggable download storage layer to `iron-remote-desktop-rdp` so large RDP file downloads can stream to persistent storage (OPFS) instead of buffering all chunks in RAM, while keeping a universal in-memory Blob fallback.
Updates the web `RdpFileTransferProvider` (in `iron-remote-desktop-rdp`) to make uploads more resilient: starting a new upload now supersedes any in-progress batch, and empty (0-byte) files can complete without ever receiving a RANGE request, preventing the provider’s `uploadState` from becoming stuck.
npm's sigstore provenance verification rejected publishing with:
E422 Unprocessable Entity - Error verifying sigstore provenance
bundle: "repository.url" is "", expected to match
"https://github.com/Devolutions/IronRDP" from provenance
Add `repository`, `homepage`, `bugs`, and `license` fields to the
`public/package.json` of both `iron-remote-desktop` and
`iron-remote-desktop-rdp` so the published tarballs satisfy npm's
provenance checks.
### Summary
Fixed a Firefox-specific issue where right-clicking inside the remote
desktop canvas could leave the server-side right mouse button state
stuck as pressed.
### Changes
**Input cleanup**
- `onmouseleave` now releases all active inputs through `mouseOut()`
- Added `focusLost()` handling for:
- window `blur`
- document `visibilitychange`
- This ensures inputs are released when the user leaves the canvas,
switches tabs, or the browser loses focus
**Mouse state reconciliation**
Updated `mouseIn()` to compare e`vent.buttons` against tracked
server-side button state.
If the browser no longer reports a button as held, the service releases
it server-side.
This covers:
1. left button
2. right button
3. middle button
Releases are batched into a single `applyInputs` call.
**Listener cleanup**
- Hoisted `captureKeys` so it can be properly removed
- `onDestroy` now removes:
- keydown
- keyup
- blur
- visibilitychange
**Tests**
Added `mouseInput.test.ts` covering:
- `mouseOut`
- `focusLost`
- `mouseIn` reconciliation
- missing-session guards
- release batching
- no-op behavior when no release is required
Adds RDPDR virtual printer redirection for web sessions, enabling the web client to announce a redirected printer, receive server print jobs over RDPDR, and deliver completed PostScript jobs to a browser callback.
The core rule is: a method belongs in the base API (UserInteraction /
Session / SessionBuilder) if the web component itself needs to call it
for transparent behaviour, or if the feature is universal across all
remote protocol backends. Protocol-specific concepts must go through the
extension mechanism instead.
Add RDCleanPathDetails struct to provide detailed error information for
RDCleanPath errors, including HTTP status codes, WSA error codes, and
TLS alert codes.
Allows the web client to distinguish between different types of network
errors (say, WSAEACCES/10013) instead of showing a generic RDCleanpath
error message.
```js
await this.remoteDesktopService.onClipboardChanged(...)
```
Consumes the clipboard data we pass, so we need to clone the data to
prevent `this.lastSentClipboardData` from being null.
Fix a bug where, when the clipboard is in automatic mode,
`iron-remote-desktop` could send the first clipboard PDU to
the server before the connection is established.
This packet was ignored, and the clipboard on the server
not synced with the current host's clipboard.
Improves the error handling in _iron-remote-desktop_ by
replacing the session events with throwing errors for terminated and
error events and callbacks for warnings and the clipboard remote update
event.
Firefox versions before v127 do not support the write() method - only
writeText(). Therefore, the Extended Clipboard checkbox must be
automatically disabled.
Adds:
- auto clipboard mode.
When it's enabled, the clipboard will be automatically monitored for
changes, and updates from the server will be automatically saved to the
local clipboard (this is the old logic; nothing has changed).
- manual clipboard mode.
One calls dedicated functions to interact with the clipboard.
This PR changes the session to not return an error on the connection
stage. The `iron-remote-desktop` raises `TERMINATED` instead of `ERROR`,
because `ERROR` is now handled as non-critical and does not close the
session.
This resolves an issue with Unicode input that happens under Chrome.
where entering `Alt` codes results in broken modifier state and broken
input in general.
This happens because of how _Chrome_ handles `KeyboardEvent` key and
code in this particular case. For example, holding `Alt`, pressing 1, 2,
3 on a numpad, then releasing `Alt` will result in events with the
following key/code values being passed to `sendKeyboard`:
`{ "key": "Alt", "code": "AltLeft" ,"type": "keydown" }`
`{ "key": "1", "code": "Numpad1" ,"type": "keydown" }`
`{ "key": "1", "code": "Numpad1" ,"type": "keyup" }`
`{ "key": "2", "code": "Numpad2" ,"type": "keydown" }`
`{ "key": "2", "code": "Numpad2" ,"type": "keyup" }`
`{ "key": "3", "code": "Numpad3" ,"type": "keydown" }`
`{ "key": "3", "code": "Numpad3" ,"type": "keyup" }`
`{ "key": "{", "code": "AltLeft" ,"type": "keyup" }`
Without this fix, this will send Unicode `{` instead of plain `Alt` to
the RDP server, messing up the `Alt` code sequence and leaving `Al` in
pressed state.
For comparison, in _Firefox_ last event looks like this: `{ "key":
"Alt", "code": "AltLeft","type": "keyup" }`
Adds a general NegotiationFailure to IronErrorKind so that web embedders
can handle failures that occur during protocol negotiation, before
authentication.
Changes:
- RDP errors during the negotiation phase become
IronErrorKind.NegotiationError
- User-friendly RDP negotiation error messages to ironrdp-connector
- Update TypeScript definitions
Add support for chunking outbound WebSocket messages when they exceed a
configurable size limit. This helps avoid browser- or proxy-specific
WebSocket message size restrictions while maintaining wire
compatibility.
Changes:
- Add outbound_message_size_limit field to SessionBuilderInner
- Implement extension handler with safe f64->u32 casting and validation
- Update writer_task to chunk large messages when limit is set
- Add outboundMessageSizeLimit() helper function to JavaScript API
---------
Co-authored-by: Benoît Cortier <3809077+CBenoit@users.noreply.github.com>
Allows users to disable CredSSP/NLA, which is otherwise enabled by default.
This is necessary to connect to target hosts bound to AzureAD/Entra domains.
In this case, user authentication is handled in the interactive session.
The root cause of the bug is the incorrect keycodes-to-scancodes
mappings. These mappings translated the browser's key codes (like
"KeyA") to OS-specific scancode (OS where the browser runs). However,
that's not exactly what we need to do. We need to map the browser's key
codes to _Windows_ scancodes - the only format that is accepted by _VNC_
and _RDP_) modules.
Let's look at an example for a better understanding. _Safari_ browser
used _Linux_'s _Gecko) mappings as a fallback (because there were no
MacOS-specific mappings). For a given key, _iron-remote-desktop_ was
providing a scancode that did not correspond to the _Windows_ scancode
for that same key. As a result, the `IronVNC` module incorrectly mapped
this scancode to a `KeySym`, which resulted in an incorrect `KeySym` or
`NO_SYMBOL`.
When we receive clipboard update from the server and the browser window
is not in focus (for example, when the user copies some text directly on
the machine, not via the browser's VNC viewer), we got an error that
`navigator.clipboard.write` is not allowed when window is not in focus.
This PR adds a window check that the window has focus, and now
`clipboard.write` runs only when the window is in focus.
When the server sends the clipboard update, we write it to our
clipboard. But this new clipboard data was then processed as a new one,
so we sent it back to the server. This commit fixes this behavior by
tracking the data that we received from the server.