Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions .github/workflows/desktop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ env:
TETHER_PUB_KEY: ${{ secrets.TETHER_PUB_KEY }}
TETHER_ADMIN_PUB_KEY: ${{ secrets.TETHER_ADMIN_PUB_KEY }}
TETHER_UPDATER_PUB_KEY: ${{ secrets.TETHER_UPDATER_PUB_KEY }}
SIGNPATH_API_TOKEN: ${{ secrets.SIGNPATH_API_TOKEN }}
WINDOWS_SIGNING_P12: ${{ secrets.WINDOWS_SIGNING_P12 }}

jobs:
build:
Expand Down Expand Up @@ -50,10 +52,47 @@ jobs:
working-directory: apps/desktop
shell: bash
run: npx tauri build --target ${{ matrix.target }} --bundles nsis
# Free self-signed Authenticode (scripts/make-windows-cert.ps1), mirroring the macOS cert.
# Gives a stable publisher identity and full trust on fleets that deploy the .cer (GPO/Intune);
# inert without the secret. Superseded by the SignPath step below once that is approved.
- name: Sign (self-signed)
if: env.WINDOWS_SIGNING_P12 != '' && github.event_name != 'pull_request'
shell: pwsh
env:
P12: ${{ secrets.WINDOWS_SIGNING_P12 }}
P12_PASSWORD: ${{ secrets.WINDOWS_SIGNING_PASSWORD }}
run: |
$dir = "apps/desktop/src-tauri/target/${{ matrix.target }}/release/bundle/nsis"
[IO.File]::WriteAllBytes("$env:RUNNER_TEMP\cs.pfx", [Convert]::FromBase64String($env:P12))
$c = [System.Security.Cryptography.X509Certificates.X509Certificate2]::new("$env:RUNNER_TEMP\cs.pfx", $env:P12_PASSWORD)
Get-ChildItem "$dir/*.exe" | ForEach-Object {
$r = Set-AuthenticodeSignature -FilePath $_.FullName -Certificate $c -HashAlgorithm SHA256 -TimestampServer 'http://timestamp.digicert.com'
if ($r.Status -ne 'Valid') { throw "signing $($_.Name): $($r.Status) $($r.StatusMessage)" }
"signed $($_.Name)"
}
Remove-Item "$env:RUNNER_TEMP\cs.pfx" -Force
- uses: actions/upload-artifact@v4
id: upload
with:
name: tether-${{ matrix.target }}
path: apps/desktop/src-tauri/target/${{ matrix.target }}/release/bundle/nsis/*.exe
# Free Authenticode signing by SignPath Foundation (docs/code-signing.md). Inert until the
# project is accepted and the secret SIGNPATH_API_TOKEN and the repo variables exist.
- name: Sign (SignPath)
if: env.SIGNPATH_API_TOKEN != '' && github.event_name != 'pull_request'
uses: signpath/github-action-submit-signing-request@v3
with:
api-token: ${{ secrets.SIGNPATH_API_TOKEN }}
organization-id: ${{ vars.SIGNPATH_ORGANIZATION_ID }}
project-slug: tether
signing-policy-slug: release-signing
github-artifact-id: ${{ steps.upload.outputs.artifact-id }}
output-artifact-directory: signed
- if: hashFiles('signed/**') != ''
uses: actions/upload-artifact@v4
with:
name: tether-${{ matrix.target }}-signed
path: signed/

# Unsigned universal build (Apple silicon + Intel), the same script as on a developer Mac.
macos:
Expand Down
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,8 @@ __pycache__/
# Tether Manage key backups (encrypted, but never commit them)
backup-keys/
*.tmkeys

# signing private keys never go in git (public .cer/.cmd/.mobileconfig are fine)
*.pfx
*.p12
/secret/
36 changes: 36 additions & 0 deletions CODE_SIGNING_POLICY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Code signing policy

Free code signing provided by [SignPath.io](https://about.signpath.io), certificate by
[SignPath Foundation](https://signpath.org).

Status: application pending; until it is accepted, Windows releases are unsigned.

Only Windows files built by this repository's GitHub Actions workflow (`.github/workflows/desktop.yml`)
from the tagged source are signed. Every signing request is approved by hand.

## Team roles

| Role | Members |
| --- | --- |
| Committers and reviewers | [fnpanic](https://github.com/fnpanic) |
| Approvers | [fnpanic](https://github.com/fnpanic) |

All members use multi-factor authentication on GitHub and SignPath.

## Privacy

This program will not transfer any information to other networked systems unless specifically
requested by the user or the person installing or operating it. It talks only to the relay servers
of the organization that provides it; see [PRIVACY.md](PRIVACY.md).

## System changes

The Windows installer adds two inbound firewall rules named "Tether" (TCP 21118 and UDP 21119, local
subnet only, for direct connections) and, if unattended access is chosen, the Windows service
"Tether". The uninstaller removes both.

## Third-party components

Tether is AGPL-3.0 ([LICENSE](LICENSE)) and builds on RustDesk (AGPL-3.0) and other open-source
libraries; their sources are fetched by `scripts/bootstrap.sh` with the patches in `patches/`.
Third-party binaries that are not built here (Microsoft WebView2) are not signed by this project.
Loading
Loading