惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Martin Fowler
Martin Fowler
V
Visual Studio Blog
有赞技术团队
有赞技术团队
T
Tailwind CSS Blog
B
Blog
I
InfoQ
博客园 - 三生石上(FineUI控件)
阮一峰的网络日志
阮一峰的网络日志
F
Fortinet All Blogs
H
Help Net Security
博客园 - Franky
宝玉的分享
宝玉的分享
博客园 - 司徒正美
C
Check Point Blog
G
Google Developers Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
Jina AI
Jina AI
T
The Blog of Author Tim Ferriss
MongoDB | Blog
MongoDB | Blog
云风的 BLOG
云风的 BLOG
A
About on SuperTechFans
罗磊的独立博客
大猫的无限游戏
大猫的无限游戏
IT之家
IT之家

Hacker News: Show HN

PurrrrrFocus: Pomodoro Timer App - App Store Workflow Engine — Multi-Step Orchestration for Bun RapidPhoto: Pro Photo Editor App - App Store GitHub - DheerG/swarms: Achieve extraordinary results with claude code across a variety of tasks SPICE simulation → oscilloscope → verification with Claude Code — Lucas Gerads Show HN: VCoding – A 5 MB native Windows IDE with no dynamic dependencies Show HN: LLMs don't hallucinate because they're bad at math, it's the format GitHub - Agent-FM/agentfm-core: AgentFM is a peer-to-peer network that turns everyday computers into a decentralized AI supercomputer. AgentFM lets you run massive AI workloads directly across a global mesh of idle CPUs and GPUs. Show HN: Tracking Top US Science Olympiad Alumni over Last 25 Years GitHub - Potarix/agent-hub: One place to talk to all your agents Show HN: Runtime security for AI agents(injection,tool abuse, data exfiltration) GitHub - dubeyKartikay/lazyspotify: Terminal Spotify client for macOS and Linux GitHub - the-banana-tool/king-louie: Easy to use GUI Personal AI Assistant. Win/Linux/Mac. Show HN I made my vacation rental bookable by AI agents–no Airbnb, 0% commission GitHub - basteez/jsf-autoreload: maven plugin to enable hot reload on jsf projects uvm32/hosts/host-gdbstub at main · ringtailsoftware/uvm32 GitHub - labsai/EDDI: Config-driven engine that turns JSON into production-grade AI agents. Multi-agent orchestration, 12+ LLM providers, MCP/A2A protocols, RAG, persistent memory, and enterprise compliance (EU AI Act, GDPR, HIPAA). Built on Quarkus. GitHub - glitchnsec/fortyone-oss: AI Executive Assistant Platform Quickstart | Alien GitHub - muxshed/shed: One stream in, or many. Every destination, simultaneously. No cloud middleman, no per-channel fees, no limits. GitHub - ocrbase-hq/ocrbase: 📄 PDF/IMG ->.MD/JSON Document OCR API for PaddleOCR and GLMOCR. Self-hostable. GitHub - impactjo/home-memory: MCP server that lets your AI assistant remember everything about your home. GitHub - Sets88/dbcls: DbCls is a powerful terminal database client that supports various databases GitHub - neptun2000/heor-agent-mcp GitHub - SeanFDZ/macmind: Single-layer transformer in HyperTalk for the classic Macintosh RollQuation: Math Puzzles - Apps on Google Play GitHub - dropbox/witchcraft Show HN: Agent-cache – Multi-tier LLM/tool/session caching for Valkey and Redis GitHub - opentalon/opentalon: OpenTalon is an open-source platform built from the ground up in Go as a robust alternative to OpenClaw LinkedIn™ 职位抓取工具 - Chrome 应用商店
GitHub - kernalix7/rdprrap: RDP Wrapper rewritten in Rust.
kernalix7 · 2026-05-06 · via Hacker News: Show HN

RDP Wrapper rewritten in Rust.

English | 한국어

Key Features

Component Description
termwrap-dll Core RDP patching — multi-session support, policy bypass for Home/non-Server editions. 7 patch types: DefPolicy, SingleUser, LocalOnly, NonRDP, PropertyDevice, SLPolicy, CSLQuery::Initialize
umwrap-dll USB/camera PnP device redirection for all SKUs (legacy + modern Windows)
endpwrap-dll Audio recording redirection (TSAudioCaptureAllowed)
patcher Shared library — PE parsing, x86/x64 disassembly, runtime pattern matching, 14 verified bytecode patches
offset-finder Standalone CLI tool for offset detection (pelite-based, no PDB required)
rdprrap-installer Rust CLI installer/uninstaller — service registration, registry setup, firewall rules, cohort service restart, install-dir ACL hardening (replaces Delphi RDPWInst.exe)
rdprrap-check RDP connection tester — loopback 127.0.0.2 via mstsc.exe, NLA guard RAII, 44 disconnect-reason codes (replaces RDPCheck.exe)
rdprrap-conf Configuration GUI — native-windows-gui panel for diagnostics + runtime RDP settings (Enable/Port/SingleSession/HideUsers/AllowCustom/AuthMode/Shadow), replaces RDPConf.exe

Tech Stack

Layer Technology
Language Rust (stable, MSVC toolchain)
Disassembler iced-x86 (pure Rust)
PE Parsing pelite
Windows API windows-rs
Target x86_64-pc-windows-msvc, i686-pc-windows-msvc
CI GitHub Actions (Linux check + Windows x64/x86 build)

Quick Start

Prerequisites

  • Rust toolchain (stable, MSVC)
  • Windows SDK

Installation

git clone https://github.com/kernalix7/rdprrap.git
cd rdprrap

rustup target add x86_64-pc-windows-msvc
rustup target add i686-pc-windows-msvc

cargo build --release

Usage

From an elevated (Administrator) command prompt on the target Windows host:

# Install — copies DLLs, writes registry, opens firewall (TCP+UDP 3389),
# grants install-dir ACL (SYSTEM + LocalService), restarts TermService cohort
rdprrap-installer.exe install --source <dir-containing-built-DLLs>

# Check current state (ServiceDll, registry, firewall, termsrv.dll version)
rdprrap-installer.exe status

# Print the install contract (paths, DLL names, registry keys+values,
# firewall rules) — pure documentation, no I/O, no elevation required
rdprrap-installer.exe plan

# Uninstall — restores original ServiceDll, AllowMultipleTSSessions,
# fDenyTSConnections, AddIns, and removes firewall rules
rdprrap-installer.exe uninstall

Additional flags:

Flag Effect
--source DIR Directory to copy DLLs from (defaults to the installer's own directory)
--force Reinstall even if ServiceDll already points to the wrapper
--skip-firewall Do not add/remove firewall rules
--skip-restart Do not restart TermService (apply changes manually or on reboot)
--disable-nla Set UserAuthentication=0 (opt-in, required for legacy clients)
-i / -u Legacy aliases for install / uninstall (RDPWInst compatibility)

After install, the two GUIs are launched from %ProgramFiles%\RDP Wrapper\:

# Configuration panel — live state + runtime settings toggles
rdprrap-conf.exe

# Loopback RDP test — spawns mstsc /v:127.0.0.2 with NLA-guard RAII
rdprrap-check.exe

Manual install (without rdprrap-installer.exe) remains possible — copy the DLLs into %ProgramFiles%\RDP Wrapper\ and merge the appropriate registry file. See the original TermWrap for the DLL interface reference.

Project Structure

rdprrap/
├── crates/
│   ├── patcher/            # Shared: PE parsing, disassembly, pattern matching, memory patching
│   │   └── src/
│   │       ├── pe.rs       # PE header/section/import/exception table parsing
│   │       ├── pattern.rs  # 4-byte aligned string pattern matching in .rdata
│   │       ├── disasm.rs   # iced-x86 decoder wrapper, xref search, branch helpers
│   │       └── patch.rs    # WriteProcessMemory wrapper, NOP fill, 14 bytecode constants
│   ├── termwrap-dll/       # cdylib: termsrv.dll proxy (core RDP)
│   │   └── src/patches/    # DefPolicy, SingleUser, LocalOnly, NonRDP, PropertyDevice, SLPolicy
│   ├── umwrap-dll/         # cdylib: umrdp.dll proxy (USB/camera redirection)
│   ├── endpwrap-dll/       # cdylib: rdpendp.dll proxy (audio recording)
│   ├── offset-finder/      # Binary: standalone offset detection CLI
│   ├── rdprrap-installer/  # Binary: install/uninstall CLI (registry, service, firewall, ACL)
│   ├── rdprrap-check/      # Binary: RDP loopback tester (mstsc + NLA guard)
│   └── rdprrap-conf/       # Binary: configuration GUI (native-windows-gui)
├── .github/
│   └── workflows/ci.yml   # Linux check + Windows x64/x86 build matrix
└── docs/                   # Korean documentation

How It Works

  1. Wrapper DLLs proxy original system DLLs (termsrv.dll, umrdp.dll, rdpendp.dll)
  2. On DLL_PROCESS_ATTACH, the original DLL is loaded and exports are forwarded
  3. All threads are suspended, in-memory patches applied via WriteProcessMemory, then resumed
  4. Patch offsets found at runtime:
    • x64: Scan .rdata for known strings → search exception table for LEA xrefs → backtrace unwind chains to function start
    • x86: Scan .text for function prologues (8B FF 55 8B EC) → follow branches → match PUSH/MOV immediates to string RVAs

Patch Types (termsrv.dll)

Patch Purpose Mechanism
DefPolicyPatch Allow multiple RDP sessions Replace CMP at offset 0x63c/0x320 with mov reg, 0x100
SingleUserPatch Disable per-user session limit NOP out VerifyVersionInfoW call or CMP instruction
LocalOnlyPatch Remove local-only license restriction Convert JZ to unconditional JMP
NonRDPPatch Allow non-RDP stack Replace CALL with inc [ecx]; xor eax,eax
PropertyDevicePatch Enable PnP device redirection Replace SHR+AND with mov reg, 0
SLPolicyPatch Set SL policy variables to 1 Direct memory write to bRemoteConnAllowed, bFUSEnabled, etc.

Testing

cargo test                                          # Unit tests
cargo clippy --all-targets -- -D warnings           # Lint
cargo fmt --check                                   # Format check

CI runs automatically on push/PR: Linux check + Windows x64/x86 full build.

Contributing

See CONTRIBUTING.md for development setup and workflow.

Security

For security issues, follow the process in SECURITY.md.

References

License

MIT License — see LICENSE for details.

Portions of rdprrap are ports or reimplementations of upstream projects (rdpwrap under Apache-2.0; TermWrap and RDPWrapOffsetFinder under MIT). See NOTICE for attribution, the full texts of those upstream licenses under vendor/licenses/, and THIRD_PARTY_LICENSES.txt (generated at release time; bundled inside each release ZIP) for the compiled Rust-dependency attributions.