Skip to content

LoveDoLove/RemoteRun

Repository files navigation

Contributors Forks Stargazers Issues Apache-2.0 License


Windows

RemoteRun

Lightweight .NET 8 Windows utility to run programs as NT AUTHORITY\\SYSTEM locally or remotely.
Explore the docs »

View Project · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Contributing
  5. License
  6. Contact
  7. Acknowledgments

About The Project

RemoteRun is a Windows command-line tool that executes processes as NT AUTHORITY\SYSTEM:

  • Locally: uses SYSTEM token duplication (CreateProcessWithTokenW) as the fast path.
  • Remotely: copies the executable over \\computer\admin$, installs a temporary service, runs the command, captures output, and cleans up.

It is designed as a lightweight, dependency-free utility in .NET 8 and follows a dual-mode architecture where the same executable acts as both CLI client and service worker (--service).

(back to top)

Built With

  • .NET 8
  • C#
  • Windows
  • Inno Setup

(back to top)

Getting Started

Follow these steps to build and run the project locally.

Prerequisites

  • Windows machine
  • .NET SDK 8.0+
  • Administrator privileges (required at runtime; UAC elevation is automatic)
  • Optional: Inno Setup for building installer binaries

Installation

  1. Clone the repository
    git clone https://github.com/LoveDoLove/RemoteRun.git
  2. Build the project
    dotnet build RemoteRun/RemoteRun.csproj -c Release
  3. (Optional) Publish self-contained binaries
    dotnet publish RemoteRun/RemoteRun.csproj -c Release -r win-x64 --self-contained true -o ./publish/windows-latest-x64/RemoteRun
    dotnet publish RemoteRun/RemoteRun.csproj -c Release -r win-x86 --self-contained true -o ./publish/windows-latest-x86/RemoteRun
  4. (Optional) Build installer packages
    ISCC.exe /DMyAppArch=x64 setup.iss
    ISCC.exe /DMyAppArch=x86 setup.iss

(back to top)

Usage

RemoteRun.exe [options] program [arguments]
RemoteRun.exe [options] \\computer program [arguments]

Options:

  • -w <directory>: Working directory for launched process
  • -d: Don't wait for process completion
  • -t <seconds>: Timeout in seconds (default: 60, 0 = unlimited)
  • -h, --help, /?: Show help

Examples:

RemoteRun.exe
RemoteRun.exe cmd.exe
RemoteRun.exe cmd.exe "/c whoami /all"
RemoteRun.exe -w "C:\Windows\System32" cmd.exe "/c dir"
RemoteRun.exe \\192.168.1.100 cmd.exe "/c ipconfig /all"
RemoteRun.exe \\MYSERVER -t 120 powershell.exe "-Command Get-Process"

Additional notes:

  • Running with no arguments opens an interactive cmd.exe as SYSTEM.
  • If not elevated, the tool relaunches with UAC (runas) automatically.
  • Interactive vs captured-output mode is selected automatically based on console redirection.

See the module README for deeper technical behavior.

(back to top)

See the open issues for a full list of proposed features (and known issues).

(back to top)

Contributing

Contributions are welcome and appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

Top contributors:

contrib.rocks image

License

Distributed under the Apache License 2.0. See LICENSE for more information.

(back to top)

Contact

LoveDoLove

Project Link: https://github.com/LoveDoLove/RemoteRun

(back to top)

Acknowledgments

(back to top)

Sponsor this project

 

Packages

 
 
 

Contributors