Skip to main content

touchop icon

touchop

Touch ID-gated 1Password CLI (op) bridge for remote VMs, containers, AI coding agents, and secondary machines.

Release MIT License Python 3.9+ Zero Dependencies

touchop remote terminal triggering Mac Touch ID prompt


Why touchop?

On a local Mac or Linux desktop, op read and op run talk to the 1Password Desktop app and prompt for Touch ID (or PolKit biometrics). On a remote Linux VM (Fly.io Sprites, EC2, Hetzner, Docker, WSL) or a headless secondary Mac running AI coding agents (Claude Code, Codex, Cursor, OpenClaw), there is no local biometric sensor.

Usually you have to put a long-lived 1Password Service Account token on the remote disk. touchop gives you another option:

  • Your 1Password credentials never touch the remote machine.
  • The remote machine installs a drop-in op shim on $PATH that works seamlessly across any runtime (Node.js, Python, Go, Rust, Ruby, Bash, Docker, Claude Code, Codex, OpenClaw).
  • When a remote process runs op read, op inject, or op run --env-file=.env.tpl -- npm run dev, touchop forwards only the read request over Tailscale (or an SSH reverse tunnel) to your Mac's Aqua GUI LaunchAgent.
  • 1Password Desktop prompts for Touch ID on your Mac (showing the custom touchop icon and app name via a lightweight headless touchop.app bundle), and only the requested secret returns to the remote process in memory.

Unofficial community project. Not affiliated with or endorsed by 1Password or Tailscale.


Comparison

Approach Mac Touch ID Gate 1Password Creds on Remote Disk Works for op read / op run Works When Laptop Asleep Best Fit
touchop Yes None Yes (with log masking) No (unless fallback SA set) Personal dev VMs, Fly Sprites, remote AI coding agents
1Password Service Account No Long-lived token Yes Yes CI/CD, unattended servers, scoped team dev vaults
1Password Connect Server No Connect token + self-hosted server Yes Yes Production services, Kubernetes, team infra
1Password SSH Agent (ForwardAgent) Yes None SSH & Git signing only No git push, commit signing, remote SSH hops
Plaintext .env files No Plaintext secrets on disk N/A Yes Never recommended for real credentials

You can also combine approaches: touchop automatically delegates to the native op binary whenever OP_SERVICE_ACCOUNT_TOKEN or OP_CONNECT_TOKEN is set in the environment.


Architecture

touchop architecture diagram


Key Features

  • Zero external dependencies: Pure Python 3.9+ standard library (brew, uv, pipx, pip, or single-command scripts/install.sh).
  • Works across runtimes & platforms: Drop-in op shim works anywhere a process calls op (Node, Python, Go, Rust, Makefiles, Fly.io Sprites, EC2, Docker containers, WSL, secondary Macs).
  • Native macOS Touch ID branding: init-host builds a headless ~/Applications/touchop.app bundle (LSUIElement=true) with AppIcon.icns, so 1Password's biometric prompt shows "Allow touchop to get CLI access" with the touchop icon instead of a generic bare executable icon.
  • op run with secret masking: Resolves op:// references via your Mac, injects them strictly into child process memory on the remote machine, and redacts secret values from child stdout/stderr (<concealed by touchop>) unless --no-masking is passed.
  • Read-only by default: Hard allowlist of read/query op subcommands (read, item get/list, vault list/get, document get/list, inject, whoami, account list/get, --version). Mutations (item delete, item create, item edit, vault delete, run on host, etc.) are rejected with HTTP 403.
  • Vault allowlists (--allow-vault): Restrict remote machines to specific vaults (for example Engineering-Dev or Sandbox-Secrets) so remote agents can never even request items from Personal or Prod Admin.
  • Optional per-request macOS dialog (--require-confirm): Because 1Password Desktop caches CLI biometric unlocks for ~10 minutes by default, --require-confirm adds an explicit native macOS dialog showing the requesting host and exact op command before every call.
  • Multi-host failover: Pass multiple --url values on a client to automatically fail over if your primary Mac is asleep.
  • Seamless native fallback: Setting OP_SERVICE_ACCOUNT_TOKEN, OP_CONNECT_TOKEN, OP_SESSION_*, or TOUCHOP_DISABLE=1 automatically delegates straight to the machine's native op binary.

Quickstart

1. Install touchop (on both host and client)

Homebrew (macOS / Linux):

brew install saran-007/tap/touchop

Python (uv / pipx / pip):

uv tool install git+https://github.com/saran-007/touchop.git
# or: pip install git+https://github.com/saran-007/touchop.git

Zero-dependency install (no Homebrew, pip, or venv needed):

git clone https://github.com/saran-007/touchop.git
cd touchop && ./scripts/install.sh

2. Initialize your biometric host (Mac or Linux Desktop)

Make sure 1Password Desktop has Settings > Developer > Integrate with 1Password CLI enabled.

touchop init-host \
  --allow-ip 100.64.0.42 \
  --allow-vault "Engineering-Dev" \
  --allow-vault "Sandbox-Secrets" \
  --account acme.1password.com

This will:

  • Auto-detect your Tailscale IPv4 address (or fall back to 127.0.0.1 for SSH tunnel mode).
  • Generate a 256-bit bearer token at ~/.config/touchop/token (chmod 600).
  • Write ~/.config/touchop/host.json (chmod 600).
  • Install and start a macOS Aqua LaunchAgent (dev.touchop.bridge, wrapped in a headless ~/Applications/touchop.app bundle with AppIcon.icns so Touch ID prompts show the touchop name and icon) or a Linux systemd --user service so the bridge runs inside your GUI session and can trigger biometrics.

Want an explicit click confirmation on your Mac for every remote secret read? Add --require-confirm.

3. Initialize a remote client (Fly.io Sprite, Linux VM, Docker, or secondary Mac)

Copy ~/.config/touchop/token securely from your host to the remote machine (for example via scp or stdin pipe), then run:

touchop init-client \
  --url http://<HOST_TAILSCALE_IP>:18765 \
  --token-file /path/to/copied/token

Add more clients anytime from your host:

touchop allow-ip 100.64.0.30
touchop doctor

Usage on Remote Machines

# Read a single secret (triggers Touch ID on your Mac)
op read "op://Engineering-Dev/Postgres/password"

# Run a Node or Python app with secrets injected in memory only (masked in logs)
op run --env-file=.env.tpl -- npm run dev
op run --env-file=.env.tpl -- uv run python app.py

# Inject secrets into a local config file on the remote machine
op inject -i config.tpl.yml -o config.yml

# Bypass the bridge when using a headless Service Account in CI or unattended runs
OP_SERVICE_ACCOUNT_TOKEN=ops_... op read "op://Engineering-Dev/Postgres/password"

Transport Options

touchop init-host automatically binds strictly to your Tailscale IP (100.x.y.z:18765). Traffic is WireGuard-encrypted end-to-end by Tailscale, never exposed to LAN or public Wi-Fi. You can additionally pin allowed Tailscale node names via --allow-node <node-name> (checked with tailscale whois).

SSH Reverse Tunnel (No Tailscale required)

Bind the host strictly to localhost:

touchop init-host --bind 127.0.0.1 --allow-ip 127.0.0.1

Forward port 18765 when connecting via SSH:

ssh -R 127.0.0.1:18765:127.0.0.1:18765 user@remote-host

Initialize the client with --url http://127.0.0.1:18765.

Multi-Host Failover

Pass --url multiple times during init-client (or list one URL per line in ~/.config/touchop/urls):

touchop init-client \
  --url http://100.64.0.10:18765 \
  --url http://100.64.0.11:18765 \
  --token-file /path/to/token

If the primary host is asleep or unreachable, touchop fails over automatically to the next URL. Explicit policy/auth errors (401/403) do not fail over.


Security & Threat Model

See SECURITY.md for the full threat model, hardening controls, audit log format, and what touchop does and does not protect against.


Contributing & Development

See CONTRIBUTING.md. Run the zero-dependency test suite locally with:

python3 -W error::ResourceWarning -m unittest discover -s tests -v

License

MIT

Metadata

Release files for touchop 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for touchop 0.1.0
File Size Uploaded Provenance Actions
touchop-0.1.0.tar.gz 536.2 kB With provenance Details for touchop-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for touchop 0.1.0
File Interpreter ABI Platform Actions
touchop-0.1.0-py3-none-any.whl Python 3 none any Details for touchop-0.1.0-py3-none-any.whl

Total release size: 1.1 MB

Release files / touchop-0.1.0.tar.gz

Download URL touchop-0.1.0.tar.gz
Size 536.2 kB
Tags Source
SHA-256 checksum
How to use checksums
899cb3412d5834782b8652b7de574ed3b81bdfd4edafe8ee04c2b369ab6663d7
BLAKE2b-256 checksum
How to use checksums
31c61ddaecad0c059cc5bbdfaf35209ea90727207accfa48c826506eb4255356
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.

Transparency log

Release files / touchop-0.1.0-py3-none-any.whl

Download URL touchop-0.1.0-py3-none-any.whl
Size 530.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
85ce6f175f5ee9f9e9918523fd2418522ad9fe6fb5707a5ac087acf372bd28ac
BLAKE2b-256 checksum
How to use checksums
ebf73250a6bdaf66a701facb35a64735ece44e5797a0f093ce9cdc19d813428f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.

Transparency log

Security for touchop 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for touchop-0.1.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page