Skip to main content

onlykey-agent

Use your OnlyKey as a hardware-based SSH and GPG agent.

onlykey-agent lets you perform SSH authentication and GPG operations (signing, encryption, and decryption) using keys that are generated and stored on an OnlyKey hardware security device. Your private keys are created on the device and never leave it — they are never written to disk or exposed to your computer, which protects them from malware and key-theft even on a compromised host.

It is part of the lib-agent family of hardware agents (alongside trezor-agent, ledger_agent, keepkey_agent, and jade_agent).

Features

  • SSH agent — authenticate to servers and Git hosts with a key held on your OnlyKey.
  • GPG agent — sign emails, Git commits, and software releases, and decrypt messages.
  • age support — encrypt and decrypt files with hardware-backed keys.
  • No keys on disk — keys are generated and stored on the device and never reach the host.

Installation

pip install onlykey-agent

This installs three console entry points:

  • onlykey-agent — SSH agent
  • onlykey-gpg — GPG tool
  • onlykey-gpg-agent — GPG agent

Usage

Use your OnlyKey to log in over SSH:

onlykey-agent user@example.com -c

Set up a GPG identity backed by your OnlyKey:

onlykey-gpg init "Your Name <you@example.com>"

Derived keys default to the original derivation, so existing SSH and GPG keys are unchanged. --skey derived-v2 / --dkey derived-v2 selects the newer HKDF-based derivation (firmware v3.1.0+), which gives different keys.

Full SSH and GPG instructions, including common use cases, are available in the project documentation.

Requirements

  • Python 3.10+
  • An OnlyKey device (composite PQC GPG keys and --skey/--dkey derived-v2 need firmware v3.1.0 or newer)
  • lib-agent and the onlykey Python package (installed automatically)

License

Released under the GNU Lesser General Public License v3 (LGPLv3).

Metadata

Release files for onlykey-agent 1.1.17

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

Source distribution (sdist)

Source distribution for onlykey-agent 1.1.17
File Size Uploaded Provenance Actions
onlykey_agent-1.1.17.tar.gz 3.2 kB Without provenance Details for onlykey_agent-1.1.17.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for onlykey-agent 1.1.17
File Interpreter ABI Platform Actions
onlykey_agent-1.1.17-py3-none-any.whl Python 3 none any Details for onlykey_agent-1.1.17-py3-none-any.whl

Total release size: 6.7 kB

Release files / onlykey_agent-1.1.17.tar.gz

Download URL onlykey_agent-1.1.17.tar.gz
Size 3.2 kB
Tags Source
SHA-256 checksum
How to use checksums
6aa688af259d7dde7a211d54cfcbcb795d9050adc280d5e31aa3cc0299f7f874
BLAKE2b-256 checksum
How to use checksums
d154eb310a54f8ab2fedef0447b80e3492fa8bc760fc48ad1a9e9c9591b300e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.2

Release files / onlykey_agent-1.1.17-py3-none-any.whl

Download URL onlykey_agent-1.1.17-py3-none-any.whl
Size 3.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
65d59627a84786671dbad1e87f8e3d6a7482ebcbbf66452aaacc1e7af1b90fc8
BLAKE2b-256 checksum
How to use checksums
f6de3191728d0e8d2a613e52a0d6aff2a0393211dc8c715432ebe0e7f866505b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.2

Security for onlykey-agent 1.1.17

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

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