|
|
|
@ -22,6 +22,26 @@ jobs:
|
|
|
|
- name: Checkout repository
|
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@v6
|
|
|
|
uses: actions/checkout@v6
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# ── Build rdpwrap.dll for both x64 and Win32 ────────────────────────────
|
|
|
|
|
|
|
|
- name: Setup MSBuild
|
|
|
|
|
|
|
|
uses: microsoft/setup-msbuild@v3
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- name: Build rdpwrap.dll (x64 and Win32)
|
|
|
|
|
|
|
|
shell: pwsh
|
|
|
|
|
|
|
|
run: |
|
|
|
|
|
|
|
|
foreach ($platform in @('x64', 'Win32')) {
|
|
|
|
|
|
|
|
msbuild src-x86-x64-Fusix/RDPWrap.vcxproj `
|
|
|
|
|
|
|
|
/p:Configuration=Release `
|
|
|
|
|
|
|
|
/p:Platform="$platform" `
|
|
|
|
|
|
|
|
/p:PlatformToolset=v143 `
|
|
|
|
|
|
|
|
/p:WindowsTargetPlatformVersion=10.0 `
|
|
|
|
|
|
|
|
/v:minimal
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
Copy-Item src-x86-x64-Fusix/x64/Release/rdpwrap.dll .\rdpwrap_x64.dll
|
|
|
|
|
|
|
|
Copy-Item src-x86-x64-Fusix/Win32/Release/rdpwrap.dll .\rdpwrap_x86.dll
|
|
|
|
|
|
|
|
Write-Host "Built DLLs:"
|
|
|
|
|
|
|
|
Get-Item .\rdpwrap_x64.dll, .\rdpwrap_x86.dll | Format-Table Name, Length
|
|
|
|
|
|
|
|
|
|
|
|
# ── Extract the date string used for tagging and the updated field ──────
|
|
|
|
# ── Extract the date string used for tagging and the updated field ──────
|
|
|
|
- name: Get release metadata
|
|
|
|
- name: Get release metadata
|
|
|
|
id: meta
|
|
|
|
id: meta
|
|
|
|
@ -86,22 +106,30 @@ jobs:
|
|
|
|
Copy-Item $x64dll.FullName .\Zydis_x64.dll
|
|
|
|
Copy-Item $x64dll.FullName .\Zydis_x64.dll
|
|
|
|
Copy-Item $x86dll.FullName .\Zydis_x86.dll
|
|
|
|
Copy-Item $x86dll.FullName .\Zydis_x86.dll
|
|
|
|
|
|
|
|
|
|
|
|
# Build self-contained zip bundles so manual users can extract-and-run
|
|
|
|
echo "finder_ver=$($release.tag_name)" >> $env:GITHUB_OUTPUT
|
|
|
|
# without needing to rename the DLL or download a second file.
|
|
|
|
|
|
|
|
|
|
|
|
# ── Download the latest rdpWrapper GUI app from sergiye ─────────────────
|
|
|
|
|
|
|
|
- name: Download rdpWrapper (sergiye)
|
|
|
|
|
|
|
|
id: wrapper
|
|
|
|
|
|
|
|
shell: pwsh
|
|
|
|
|
|
|
|
run: |
|
|
|
|
|
|
|
|
$apiUrl = "https://api.github.com/repos/sergiye/rdpWrapper/releases/latest"
|
|
|
|
|
|
|
|
$release = Invoke-RestMethod -Uri $apiUrl -Headers @{ "User-Agent" = "rdpwrap-ci" }
|
|
|
|
|
|
|
|
|
|
|
|
foreach ($arch in @('x64', 'x86')) {
|
|
|
|
foreach ($arch in @('x64', 'x86')) {
|
|
|
|
$bundle = ".\bundle_$arch"
|
|
|
|
$asset = $release.assets |
|
|
|
|
New-Item -ItemType Directory -Path $bundle -Force | Out-Null
|
|
|
|
Where-Object { $_.name -eq "rdpWrapper_$arch.exe" } |
|
|
|
|
Copy-Item ".\RDPWrapOffsetFinder_$arch.exe" "$bundle\RDPWrapOffsetFinder.exe"
|
|
|
|
Select-Object -First 1
|
|
|
|
Copy-Item ".\Zydis_$arch.dll" "$bundle\Zydis.dll"
|
|
|
|
if (-not $asset) {
|
|
|
|
Compress-Archive -Path "$bundle\*" -DestinationPath ".\RDPWrapOffsetFinder_$arch.zip" -Force
|
|
|
|
throw "Could not find rdpWrapper_$arch.exe in sergiye release $($release.tag_name)"
|
|
|
|
Remove-Item $bundle -Recurse -Force
|
|
|
|
}
|
|
|
|
|
|
|
|
Write-Host "Downloading $($asset.browser_download_url)"
|
|
|
|
|
|
|
|
Invoke-WebRequest -Uri $asset.browser_download_url -OutFile ".\rdpWrapper_$arch.exe"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
Write-Host "Staged binaries:"
|
|
|
|
Write-Host "Wrapper exes:"
|
|
|
|
Get-ChildItem .\RDPWrapOffsetFinder_*.exe, .\Zydis_*.dll, .\RDPWrapOffsetFinder_*.zip |
|
|
|
|
Get-Item .\rdpWrapper_x64.exe, .\rdpWrapper_x86.exe | Format-Table Name, Length
|
|
|
|
Format-Table Name, Length
|
|
|
|
echo "wrapper_ver=$($release.tag_name)" >> $env:GITHUB_OUTPUT
|
|
|
|
|
|
|
|
|
|
|
|
echo "finder_ver=$($release.tag_name)" >> $env:GITHUB_OUTPUT
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# ── Validate the INI has required sections ───────────────────────────────
|
|
|
|
# ── Validate the INI has required sections ───────────────────────────────
|
|
|
|
- name: Validate INI
|
|
|
|
- name: Validate INI
|
|
|
|
@ -116,6 +144,40 @@ jobs:
|
|
|
|
$sectionCount = ([regex]::Matches($ini, '^\[[\d\.]+\]', 'Multiline')).Count
|
|
|
|
$sectionCount = ([regex]::Matches($ini, '^\[[\d\.]+\]', 'Multiline')).Count
|
|
|
|
Write-Host "INI is valid. Windows-version sections: $sectionCount"
|
|
|
|
Write-Host "INI is valid. Windows-version sections: $sectionCount"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# ── Assemble the two user-facing distribution bundles ────────────────────
|
|
|
|
|
|
|
|
- name: Create distribution bundles
|
|
|
|
|
|
|
|
shell: pwsh
|
|
|
|
|
|
|
|
run: |
|
|
|
|
|
|
|
|
# RDPWrapper.zip - complete install package.
|
|
|
|
|
|
|
|
# Contains both arch DLLs, both arch wrapper exes, latest INI, and scripts.
|
|
|
|
|
|
|
|
$d = ".\bundle_wrapper"
|
|
|
|
|
|
|
|
New-Item -ItemType Directory -Path $d -Force | Out-Null
|
|
|
|
|
|
|
|
Copy-Item .\rdpwrap_x64.dll "$d\rdpwrap_x64.dll"
|
|
|
|
|
|
|
|
Copy-Item .\rdpwrap_x86.dll "$d\rdpwrap_x86.dll"
|
|
|
|
|
|
|
|
Copy-Item .\rdpWrapper_x64.exe "$d\rdpWrapper_x64.exe"
|
|
|
|
|
|
|
|
Copy-Item .\rdpWrapper_x86.exe "$d\rdpWrapper_x86.exe"
|
|
|
|
|
|
|
|
Copy-Item res\rdpwrap.ini "$d\rdpwrap.ini"
|
|
|
|
|
|
|
|
Copy-Item bin\install.bat "$d\install.bat"
|
|
|
|
|
|
|
|
Copy-Item bin\uninstall.bat "$d\uninstall.bat"
|
|
|
|
|
|
|
|
Copy-Item bin\update.bat "$d\update.bat"
|
|
|
|
|
|
|
|
Compress-Archive -Path "$d\*" -DestinationPath ".\RDPWrapper.zip" -Force
|
|
|
|
|
|
|
|
Remove-Item $d -Recurse -Force
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# RDPWrapOffsetFinder.zip - offset finder with per-arch subfolders.
|
|
|
|
|
|
|
|
# Extract x64\ or x86\ folder and run RDPWrapOffsetFinder.exe directly.
|
|
|
|
|
|
|
|
$f = ".\bundle_finder"
|
|
|
|
|
|
|
|
foreach ($arch in @('x64', 'x86')) {
|
|
|
|
|
|
|
|
$dir = "$f\$arch"
|
|
|
|
|
|
|
|
New-Item -ItemType Directory -Path $dir -Force | Out-Null
|
|
|
|
|
|
|
|
Copy-Item ".\RDPWrapOffsetFinder_$arch.exe" "$dir\RDPWrapOffsetFinder.exe"
|
|
|
|
|
|
|
|
Copy-Item ".\Zydis_$arch.dll" "$dir\Zydis.dll"
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
Compress-Archive -Path "$f\*" -DestinationPath ".\RDPWrapOffsetFinder.zip" -Force
|
|
|
|
|
|
|
|
Remove-Item $f -Recurse -Force
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Write-Host "Distribution bundles:"
|
|
|
|
|
|
|
|
Get-Item .\RDPWrapper.zip, .\RDPWrapOffsetFinder.zip | Format-Table Name, Length
|
|
|
|
|
|
|
|
|
|
|
|
# ── Create/update a versioned GitHub Release with all assets ─────────────
|
|
|
|
# ── Create/update a versioned GitHub Release with all assets ─────────────
|
|
|
|
- name: Publish release
|
|
|
|
- name: Publish release
|
|
|
|
uses: softprops/action-gh-release@v2
|
|
|
|
uses: softprops/action-gh-release@v2
|
|
|
|
@ -125,30 +187,35 @@ jobs:
|
|
|
|
prerelease: false
|
|
|
|
prerelease: false
|
|
|
|
make_latest: true
|
|
|
|
make_latest: true
|
|
|
|
body: |
|
|
|
|
body: |
|
|
|
|
## RDP Wrapper — Automated INI Release
|
|
|
|
## RDP Wrapper - Automated Release
|
|
|
|
|
|
|
|
|
|
|
|
| Field | Value |
|
|
|
|
| Field | Value |
|
|
|
|
|---|---|
|
|
|
|
|---|---|
|
|
|
|
| INI `Updated` date | `${{ steps.meta.outputs.inidate }}` |
|
|
|
|
| INI `Updated` date | `${{ steps.meta.outputs.inidate }}` |
|
|
|
|
| Published | ${{ steps.meta.outputs.stamp }} |
|
|
|
|
| Published | ${{ steps.meta.outputs.stamp }} |
|
|
|
|
| RDPWrapOffsetFinder | ${{ steps.finder.outputs.finder_ver }} |
|
|
|
|
| rdpWrapper (sergiye) | ${{ steps.wrapper.outputs.wrapper_ver }} |
|
|
|
|
|
|
|
|
| RDPWrapOffsetFinder (llccd) | ${{ steps.finder.outputs.finder_ver }} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### Downloads
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| File | Contents | Use |
|
|
|
|
|
|
|
|
|---|---|---|
|
|
|
|
|
|
|
|
| `RDPWrapper.zip` | rdpwrap_x64.dll, rdpwrap_x86.dll, rdpWrapper_x64.exe, rdpWrapper_x86.exe, rdpwrap.ini, install/uninstall/update.bat | Main install package - extract and run `rdpWrapper_x64.exe` |
|
|
|
|
|
|
|
|
| `RDPWrapOffsetFinder.zip` | x64\RDPWrapOffsetFinder.exe + Zydis.dll, x86\RDPWrapOffsetFinder.exe + Zydis.dll | Generate offsets for an unknown termsrv.dll version manually |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
### Individual files (used by the automated installer)
|
|
|
|
|
|
|
|
|
|
|
|
### Assets
|
|
|
|
|
|
|
|
| File | Purpose |
|
|
|
|
| File | Purpose |
|
|
|
|
|---|---|
|
|
|
|
|---|---|
|
|
|
|
| `rdpwrap.ini` | Latest offset database for all known termsrv.dll versions |
|
|
|
|
| `rdpwrap.ini` | Offset database fetched automatically by the installer |
|
|
|
|
| `RDPWrapOffsetFinder_x64.zip` | x64 finder bundle — extract and run `RDPWrapOffsetFinder.exe` directly |
|
|
|
|
| `RDPWrapOffsetFinder_x64.exe` / `Zydis_x64.dll` | Loose x64 binaries downloaded by `TryAutoGenerateOffsets` |
|
|
|
|
| `RDPWrapOffsetFinder_x86.zip` | x86 finder bundle — extract and run `RDPWrapOffsetFinder.exe` directly |
|
|
|
|
| `RDPWrapOffsetFinder_x86.exe` / `Zydis_x86.dll` | Loose x86 binaries downloaded by `TryAutoGenerateOffsets` |
|
|
|
|
| `RDPWrapOffsetFinder_x64.exe` / `Zydis_x64.dll` | Loose x64 binaries (used by the installer) |
|
|
|
|
|
|
|
|
| `RDPWrapOffsetFinder_x86.exe` / `Zydis_x86.dll` | Loose x86 binaries (used by the installer) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The installer fetches `rdpwrap.ini` from this release automatically.
|
|
|
|
|
|
|
|
If your termsrv.dll version is not in the INI, the installer downloads the
|
|
|
|
|
|
|
|
offset finder tools and generates the missing section on-the-fly.
|
|
|
|
|
|
|
|
files: |
|
|
|
|
files: |
|
|
|
|
|
|
|
|
RDPWrapper.zip
|
|
|
|
|
|
|
|
RDPWrapOffsetFinder.zip
|
|
|
|
res/rdpwrap.ini
|
|
|
|
res/rdpwrap.ini
|
|
|
|
RDPWrapOffsetFinder_x64.zip
|
|
|
|
rdpwrap_x64.dll
|
|
|
|
RDPWrapOffsetFinder_x86.zip
|
|
|
|
rdpwrap_x86.dll
|
|
|
|
RDPWrapOffsetFinder_x64.exe
|
|
|
|
RDPWrapOffsetFinder_x64.exe
|
|
|
|
RDPWrapOffsetFinder_x86.exe
|
|
|
|
RDPWrapOffsetFinder_x86.exe
|
|
|
|
Zydis_x64.dll
|
|
|
|
Zydis_x64.dll
|
|
|
|
|