Skip to content

The agent that grows with you

feat(vault): opt-in OS-keychain storage for the vault key, with a verified migration

Teknium7abb9cc0fa97
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index 9a126213c8b..3f23f74b4e4 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -72,7 +72,7 @@ jobs:
- name: Set up locked Python and test dependencies
uses: ./.github/actions/setup-pm
with:
- extras: '["all", "anthropic", "bedrock", "mistral", "fal", "modal", "daytona", "parallel-web"]'
+ extras: '["all", "anthropic", "bedrock", "mistral", "fal", "modal", "daytona", "parallel-web", "keychain"]'
test-environment: 'true'
prune-python-cache: true
@@ -385,7 +385,7 @@ jobs:
# in the venv up front.
uses: ./.github/actions/retry
with:
- command: uv sync --locked --python 3.14 --extra all --group dev --extra anthropic --extra mistral --extra fal --extra modal --extra daytona --extra parallel-web
+ command: uv sync --locked --python 3.14 --extra all --group dev --extra anthropic --extra mistral --extra fal --extra modal --extra daytona --extra parallel-web --extra keychain
- name: Install bubblewrap
# Every spawned updater runs in bwrap (own PID namespace, no user
diff --git a/agent/vault_keychain.py b/agent/vault_keychain.py
new file mode 100644
index 00000000000..a893f3ce757
--- /dev/null
+++ b/agent/vault_keychain.py
@@ -0,0 +1,134 @@
+"""OS-keychain storage for the local vault key (opt-in: ``vault.key_storage: keychain``).
+
+The vault key normally sits in ``vault.key`` next to the ciphertext. In keychain mode it lives in
+the OS credential store instead (macOS Keychain, Windows Credential Manager, Secret Service /
+KWallet on Linux, via the ``keyring`` package from the ``keychain`` extra), and the vault directory
+keeps only a non-secret pointer, ``vault.keyref``, naming the entry. A backup, a synced folder or
+a copied home directory then holds ciphertext without its key.
+
+This does not isolate the key from code running as the same OS user: any such process (including
+an in-process plugin) can ask the keychain for it, or simply call the vault API.
+"""
+
+from __future__ import annotations
+
+import json
+import os
+import uuid
+from pathlib import Path
+from typing import Optional
+
+SERVICE = "Hermes Agent vault key"
+
+# keyring backends that are not an OS credential store: ``fail``/``null`` are what keyring picks on
+# a headless Linux box with no Secret Service, and keyrings.alt's plaintext/encrypted-file keyrings
+# would only move the key into another file under the same home.
+_NOT_A_KEYCHAIN = ("keyring.backends.fail", "keyring.backends.null", "keyrings.alt")
+
+
+class KeychainUnavailable(Exception):
+ """No OS keychain is reachable from this process (headless, no keyring extra, plaintext backend)."""
+
+
+def _is_os_keychain(backend) -> bool:
+ children = getattr(backend, "backends", None)
+ if children is not None: # keyring's ChainerBackend writes to its highest-priority child
+ return bool(children) and _is_os_keychain(children[0])
+ return not type(backend).__module__.startswith(_NOT_A_KEYCHAIN)
+
+
+def os_keyring():
+ """The OS credential store keyring resolves to, or raise :class:`KeychainUnavailable`."""
+ try:
+ import keyring
+ except ImportError as exc:
+ raise KeychainUnavailable(
+ "the keychain feature is not installed (`hermes pm install --extra keychain`)") from exc
+ try:
+ backend = keyring.get_keyring()
+ except Exception as exc: # health: allow BLE001 -- backend discovery runs third-party entry points
+ raise KeychainUnavailable(f"keyring could not pick a backend ({type(exc).__name__})") from exc
+ if not _is_os_keychain(backend):
+ raise KeychainUnavailable(
+ f"no OS keychain is reachable from this session (keyring backend: {type(backend).__module__}.{type(backend).__name__})")
+ return backend
+
+
+def backend_label() -> str:
+ """Human name of the keychain this process would use, for ``hermes vault key``."""
+ try:
+ backend = os_keyring()
+ except KeychainUnavailable as exc:
+ return f"unavailable: {exc}"
+ return str(getattr(backend, "name", "") or type(backend).__name__)
+
+
+def new_ref(vault_dir: Path) -> dict:
+ """Keychain coordinates for a new entry. The account is random, never derived from the path: a
+ renamed profile keeps its pointer, and a new profile reusing the old name must not land on (and
+ overwrite) the renamed vault's entry. ``vault_dir`` records which directory owns the entry."""
+ return {"storage": "keychain", "service": SERVICE, "account": f"vault-{uuid.uuid4().hex}",
+ "vault_dir": str(Path(vault_dir).resolve())}
+
+
+def owns(ref: dict, vault_dir: Path) -> bool:
+ """False for a pointer copied or moved from another directory (profile clone/rename): the entry
+ it names may still be another vault's only key, so this vault must not overwrite or delete it."""
+ return ref.get("vault_dir") == str(Path(vault_dir).resolve())
+
+
+def read_ref(path: Path) -> Optional[dict]:
+ try:
+ data = json.loads(path.read_text(encoding="utf-8-sig"))
+ except FileNotFoundError:
+ return None
+ except (OSError, ValueError) as exc:
+ from agent.vault_store import VaultError
+ raise VaultError(f"{path.name} is unreadable ({type(exc).__name__}); see `hermes vault key`") from exc
+ if not isinstance(data, dict) or data.get("storage") != "keychain" or not data.get("account"):
+ from agent.vault_store import VaultError
+ raise VaultError(f"{path.name} does not describe a keychain entry; see `hermes vault key`")
+ return data
+
+
+def write_ref(path: Path, ref: dict) -> None:
+ from utils import atomic_write_bytes
+ atomic_write_bytes(path, json.dumps(ref, indent=2).encode("utf-8"), mode=0o600, fsync_dir=True)
+
+
+def load_key(ref: dict) -> Optional[bytes]:
+ """The stored key, or None when the entry is gone. Raises KeychainUnavailable."""
+ backend = os_keyring()
+ try:
+ value = backend.get_password(str(ref.get("service") or SERVICE), str(ref["account"]))
+ except Exception as exc: # health: allow BLE001 -- a locked or dismissed keychain raises backend-specific types
+ raise KeychainUnavailable(f"the OS keychain did not answer ({type(exc).__name__})") from exc
+ return value.encode("ascii") if value else None
+
+
+def store_key(ref: dict, key: bytes) -> None:
+ """Write the key and read it back: a store that accepts a write it cannot return is unusable."""
+ backend = os_keyring()
+ service, account = str(ref.get("service") or SERVICE), str(ref["account"])
+ try:
+ backend.set_password(service, account, key.decode("ascii"))
+ readback = backend.get_password(service, account)
+ except Exception as exc: # health: allow BLE001 -- every keyring backend raises its own types
+ raise KeychainUnavailable(f"the OS keychain refused the key ({type(exc).__name__})") from exc
+ if readback != key.decode("ascii"):
+ raise KeychainUnavailable("the OS keychain did not return the key it was given")
+
+
+def delete_key(ref: dict) -> bool:
+ try:
+ os_keyring().delete_password(str(ref.get("service") or SERVICE), str(ref["account"]))
+ except Exception: # health: allow BLE001 -- best effort; an orphaned entry is harmless
+ return False
+ return True
+
+
+def remove_file(path: Path) -> None:
+ try:
+ os.remove(path)
+ except FileNotFoundError:
+ pass
diff --git a/agent/vault_store.py b/agent/vault_store.py
index 746fbf8a771..f8b8a6f6661 100644
--- a/agent/vault_store.py
+++ b/agent/vault_store.py
@@ -9,6 +9,8 @@ the browser fill path and never enter tool results, logs, or the session DB.
Design notes:
- Follows the repo's "default frictionless, 0600 files OK" policy: the key
file and vault file are created 0600 under ``<HERMES_HOME>/vault/``.
+ ``vault.key_storage: keychain`` (opt-in) keeps the key in the OS keychain
+ instead (agent/vault_keychain.py); ``hermes vault key migrate`` moves it.
- Ported design (opaque-handle vault fill) from Merit-Systems/OpenInstinct
(MIT): lib/manager/server/secret-store.ts + vault services.
- Three item kinds: ``login`` (password-only secret), ``payment`` (card fields) and
@@ -18,6 +20,7 @@ Design notes:
from __future__ import annotations
import json
+import logging
import os
import re
import threading
@@ -33,6 +36,8 @@ from hermes_dir_acl import make_user_dir
from hermes_constants import get_hermes_home
from utils import atomic_write_bytes
+logger = logging.getLogger(__name__)
+
VAULT_KINDS = ("login", "payment", "address")
LOGIN_IDENTIFIER_TYPES = ("email", "phone", "username")
@@ -65,6 +70,15 @@ except ImportError: # pragma: no cover - platform-specific fallback
import msvcrt
+def configured_key_storage() -> str:
+ """``vault.key_storage``: where a NEW vault's key goes (``file`` default, or ``keychain``)."""
+ from hermes_cli.config import load_config_readonly
+
+ section = load_config_readonly().get("vault") or {}
+ value = section.get("key_storage") if isinstance(section, dict) else None
+ return str(value or "file").strip().lower()
+
+
class VaultError(Exception):
"""Vault failure that is safe to surface (never contains secret values)."""
@@ -200,6 +214,9 @@ class VaultStore:
)
self._vault_path = self._base / "vault.json.enc"
self._key_path = self._base / "vault.key"
+ # Keychain mode (vault.key_storage: keychain) keeps only this non-secret pointer beside the
+ # ciphertext; agent/vault_keychain.py owns the entry it names.
+ self._keyref_path = self._base / "vault.keyref"
# -- key / crypto ------------------------------------------------------
@@ -248,23 +265,208 @@ class VaultStore:
def _fernet(self):
from cryptography.fernet import Fernet
+ return Fernet(self._key())
+
+ def _has_ciphertext(self) -> bool:
+ return self._vault_path.exists() and self._vault_path.stat().st_size > 0
+
+ def _key(self) -> bytes:
+ """``vault.key`` when present (the legacy layout wins), else the keychain entry ``vault.keyref``
+ names, else a new key for a vault that has no items yet. Never mints a key over ciphertext:
+ that would make the saved items unrecoverable for good."""
+ from agent import vault_keychain as kc
+
self._ensure_dir()
- if not self._key_path.exists():
- key = Fernet.generate_key()
- fd = os.open(
- self._key_path, os.O_WRONLY | os.O_CREAT | os.O_EXCL, 0o600
- )
+ if self._key_path.exists():
+ with suppress(OSError):
+ os.chmod(self._key_path, 0o600)
+ return self._key_path.read_bytes().strip()
+ ref = kc.read_ref(self._keyref_path)
+ if ref is not None:
try:
- os.write(fd, key)
- finally:
- os.close(fd)
+ ref = self._adopt(ref)
+ key = kc.load_key(ref)
+ except kc.KeychainUnavailable as exc:
+ key, why = None, f"the OS keychain is not reachable here: {exc}"
+ else:
+ why = f"the keychain entry {ref.get('service')!r} / {ref['account']!r} is gone"
+ if key:
+ return key
else:
- key = self._key_path.read_bytes().strip()
+ why = f"{self._key_path.name} is missing"
+ if self._has_ciphertext():
+ raise VaultError(self._missing_key_message(why))
+ return self._create_key()
+
+ def _missing_key_message(self, why: str) -> str:
+ return (f"The vault key could not be found ({why}). vault.json.enc in {self._base} was left untouched. "
+ "If this profile came from another machine, run `hermes vault key migrate --to file` there and "
+ "copy its vault.key next to vault.json.enc; if the keychain entry was deleted, restore it from a "
+ "keychain backup. `hermes vault key` shows where the key is expected. To start over instead, "
+ "delete vault.json.enc (its saved items are lost).")
+
+ def _conflicting_key_message(self) -> str:
+ # Never overwrite or delete the other copy here: it may be the only key that opens the vault.
+ return (f"{self._key_path} does not decrypt vault.json.enc, so the key was not moved and nothing "
+ "was deleted. If the vault's key is in the OS keychain, move this vault.key aside and run "
+ "`hermes vault key` again.")
+
+ def _create_key(self) -> bytes:
+ from cryptography.fernet import Fernet
+
+ from agent import vault_keychain as kc
+
+ key = Fernet.generate_key()
+ if configured_key_storage() == "keychain":
+ ref = kc.new_ref(self._base)
+ try:
+ kc.store_key(ref, key)
+ except kc.KeychainUnavailable as exc:
+ # Headless boxes (no Secret Service), and installs without the keychain extra, keep
+ # working: the key goes to the 0600 file exactly as it always has.
+ logger.warning("vault.key_storage is keychain, but %s; using %s instead", exc, self._key_path)
+ else:
+ kc.write_ref(self._keyref_path, ref)
+ return key
+ kc.remove_file(self._keyref_path)
+ self._write_key_file(key)
+ return key
+
+ def _write_key_file(self, key: bytes) -> None:
+ # Atomic + directory fsync: an interrupted write must never leave a partial vault.key, which
+ # reads would prefer over a working keychain entry. Callers hold the vault lock.
+ atomic_write_bytes(self._key_path, key, mode=0o600, fsync_dir=True)
+
+ def _adopt(self, ref: dict) -> dict:
+ """Give a copied/moved vault (profile clone or rename) its own keychain entry. Never deletes the
+ entry it came from: another copy may still depend on it. Raises KeychainUnavailable only when the
+ shared entry cannot be read; if the new entry cannot be written, the shared one keeps serving."""
+ from agent import vault_keychain as kc
+
+ if kc.owns(ref, self._base):
+ return ref
+ key = kc.load_key(ref)
+ if not self._decrypts(key):
+ return ref
+ mine = kc.new_ref(self._base)
+ try:
+ kc.store_key(mine, key)
+ except kc.KeychainUnavailable:
+ logger.warning("could not give the copied vault in %s its own keychain entry", self._base, exc_info=True)
+ return ref
+ kc.write_ref(self._keyref_path, mine)
+ return mine
+
+ def _decrypts(self, key: Optional[bytes]) -> bool:
+ from cryptography.fernet import Fernet, InvalidToken
+
+ if not key:
+ return False
+ if not self._has_ciphertext():
+ return True
+ try:
+ Fernet(key).decrypt(self._vault_path.read_bytes())
+ except (InvalidToken, ValueError):
+ return False
+ return True
+
+ # -- key storage ---------------------------------------------------------
+
+ def key_location(self) -> dict[str, Any]:
+ """Where this vault's key lives (never the key itself), for ``hermes vault key``."""
+ from agent import vault_keychain as kc
+
+ ref = kc.read_ref(self._keyref_path)
+ if self._key_path.exists():
+ where = {"storage": "file", "path": str(self._key_path)}
+ if ref is not None: # a keychain copy that could not be removed yet
+ where["keychain_entry_left"] = ref["account"]
+ return where
+ return dict(ref) if ref else {"storage": "none", "path": str(self._key_path)}
+
+ def migrate_key(self, target: str) -> str:
+ """Move the key between ``vault.key`` and the OS keychain. The destination is written and proven
+ to decrypt the vault before the source is removed, so an interrupted move leaves a working vault
+ and re-running it finishes the job."""
+ if target not in ("file", "keychain"):
+ raise VaultError("key storage must be 'file' or 'keychain'")
+ with self._locked():
+ self._ensure_dir()
+ return self._migrate_to_keychain() if target == "keychain" else self._migrate_to_file()
+
+ def _migrate_to_keychain(self) -> str:
+ from agent import vault_keychain as kc
+
+ existing = kc.read_ref(self._keyref_path)
+ if not self._key_path.exists():
+ if existing is not None: # already moved: prove the entry still opens the vault
+ try:
+ key = kc.load_key(self._adopt(existing))
+ except kc.KeychainUnavailable as exc:
+ raise VaultError(f"cannot read the vault key from the OS keychain: {exc}") from exc
+ if not self._decrypts(key):
+ raise VaultError(self._missing_key_message(f"the keychain entry {existing['account']!r} does not open the vault"))
+ return "keychain"
+ if self._has_ciphertext():
+ raise VaultError(self._missing_key_message(f"{self._key_path.name} is missing"))
+ try:
+ kc.os_keyring() # nothing to move yet, but the new vault's key must have somewhere to go
+ except kc.KeychainUnavailable as exc:
+ raise VaultError(f"cannot use the OS keychain: {exc}") from exc
+ return "keychain"
+ key = self._key_path.read_bytes().strip()
+ if not self._decrypts(key):
+ raise VaultError(self._conflicting_key_message())
+ # Resume into our own entry from an interrupted move; a copied pointer's entry is not ours to overwrite.
+ ref = existing if existing is not None and kc.owns(existing, self._base) else kc.new_ref(self._base)
+ try:
+ kc.store_key(ref, key)
+ if not self._decrypts(kc.load_key(ref)):
+ raise kc.KeychainUnavailable("the key read back from the keychain does not decrypt the vault")
+ except kc.KeychainUnavailable as exc:
+ if ref is not existing:
+ kc.delete_key(ref)
+ raise VaultError(f"could not move the vault key to the OS keychain ({exc}); "
+ f"it stays in {self._key_path}") from exc
+ kc.write_ref(self._keyref_path, ref)
+ kc.remove_file(self._key_path)
+ return "keychain"
+
+ def _migrate_to_file(self) -> str:
+ from agent import vault_keychain as kc
+
+ ref = kc.read_ref(self._keyref_path)
+ if self._key_path.exists():
+ if ref is not None: # a move stopped with both copies present; the file is the one in use
+ if not self._decrypts(self._key_path.read_bytes().strip()):
+ raise VaultError(self._conflicting_key_message())
+ self._release_ref(ref)
+ return "file"
+ if ref is None:
+ if self._has_ciphertext():
+ raise VaultError(self._missing_key_message(f"{self._key_path.name} is missing"))
+ return "file"
try:
- os.chmod(self._key_path, 0o600)
- except OSError:
- pass
- return Fernet(key)
+ key = kc.load_key(ref)
+ except kc.KeychainUnavailable as exc:
+ raise VaultError(f"cannot read the vault key from the OS keychain: {exc}") from exc
+ if not key or not self._decrypts(key):
+ raise VaultError(self._missing_key_message(f"the keychain entry {ref['account']!r} does not hold this vault's key"))
+ self._write_key_file(key)
+ if self._key_path.read_bytes().strip() != key:
+ kc.remove_file(self._key_path)
+ raise VaultError(f"could not write {self._key_path}; the key stays in the OS keychain")
+ self._release_ref(ref)
+ return "file"
+
+ def _release_ref(self, ref: dict) -> None:
+ """The file holds the key now: drop the keychain copy. An entry this vault does not own (copied
+ pointer) is left alone; if deleting ours fails, the pointer stays so a rerun can finish."""
+ from agent import vault_keychain as kc
+
+ if kc.owns(ref, self._base) and not kc.delete_key(ref):
+ return
+ kc.remove_file(self._keyref_path)
# -- persistence -------------------------------------------------------
diff --git a/hermes_cli/config_defaults.py b/hermes_cli/config_defaults.py
index a53c90cfd4a..0099dce1cdd 100644
--- a/hermes_cli/config_defaults.py
+++ b/hermes_cli/config_defaults.py
@@ -2445,8 +2445,8 @@ DEFAULT_CONFIG = {
# External password managers are unlocked per session with a masked master-password prompt;
# headless sessions (cron, webhook, API) never prompt and see them as locked.
"vault": {
- "onepassword": {
- # Detected managers are login sources unless the user opts out (vault.<name>.enabled: false).
+ "key_storage": "file", # NEW vault's key: file (0600 vault.key) | keychain (OS; file if none). See `hermes vault key`.
+ "onepassword": { # detected managers are login sources unless the user opts out (enabled: false)
"enabled": True, # `op` CLI: Login items with a website URL become fillable handles.
"account": "", # account shorthand for `op --account`; empty = default account.
"binary_path": "", # absolute path to op; empty = PATH.
diff --git a/hermes_cli/vault.py b/hermes_cli/vault.py
index 7bdbe0be5e9..8033556beaf 100644
--- a/hermes_cli/vault.py
+++ b/hermes_cli/vault.py
@@ -7,6 +7,7 @@ Subcommands:
- ``hermes vault list`` metadata — labels, kinds, identifiers, origins,
handles. Passwords are never shown.
- ``hermes vault rm`` remove an item by handle/id.
+- ``hermes vault key`` where the vault key lives; ``key migrate --to keychain|file`` moves it.
The vault backs the password-blind browser autofill tools
(``browser_vault`` list / fill): the agent sees handles
@@ -182,6 +183,66 @@ def _cmd_rm(args) -> None:
c.print(f"[red]No vault item with handle {args.handle!r}[/]")
+def _cmd_key(args) -> None:
+ """Show where the local vault's key lives, or move it between vault.key and the OS keychain."""
+ from agent import vault_keychain
+ from agent.vault_store import configured_key_storage, get_vault_store
+
+ c = _console()
+ store = get_vault_store()
+ target = getattr(args, "to", None)
+ if target:
+ if target == "keychain" and not _ensure_keychain_extra(c):
+ return
+ store.migrate_key(target)
+ _set_key_storage(target)
+ if target == "keychain":
+ c.print(f"[green]Vault key moved to the OS keychain[/] ({vault_keychain.backend_label()}); "
+ "vault.key was removed after the keychain copy decrypted the vault.")
+ c.print("[dim]Backups of this profile now hold the encrypted vault without its key; "
+ "`hermes vault key migrate --to file` before moving the profile to another machine.[/]")
+ else:
+ where = store.key_location()
+ c.print(f"[green]Vault key moved to[/] {where.get('path')} (0600).")
+ if where.get("keychain_entry_left"):
+ c.print(f"[yellow]The keychain copy ({where['keychain_entry_left']}) could not be removed yet;[/] "
+ "run this command again when the keychain is reachable.")
+ else:
+ c.print("Keychain entry removed.")
+ return
+ where = store.key_location()
+ if where["storage"] == "file":
+ c.print(f"Vault key: [bold]file[/] {where['path']} (0600, beside the encrypted vault)")
+ elif where["storage"] == "keychain":
+ c.print(f"Vault key: [bold]OS keychain[/] service {where.get('service')!r}, account {where['account']!r}")
+ else:
+ c.print("Vault key: [dim]none yet[/] (created with the first saved item)")
+ c.print(f"New vaults use: vault.key_storage = {configured_key_storage()}")
+ c.print(f"OS keychain here: {vault_keychain.backend_label()}")
+
+
+def _ensure_keychain_extra(c) -> bool:
+ from pm.extras import available, ensure_import
+ from pm.package import InstallError
+
+ if available("keychain"):
+ return True
+ try:
+ ensure_import("keychain")
+ except InstallError as exc:
+ c.print(f"[red]The keychain feature is not installed:[/] {exc}")
+ return False
+ return True
+
+
+def _set_key_storage(value: str) -> None:
+ from hermes_cli.config import _ensure_dict, load_config, save_config
+
+ cfg = load_config()
+ _ensure_dict(cfg, "vault")["key_storage"] = value
+ save_config(cfg)
+
+
def register_cli(subparser) -> None:
"""Build the ``hermes vault`` argparse tree (called from main.py)."""
subs = subparser.add_subparsers(dest="vault_action")
@@ -209,6 +270,14 @@ def register_cli(subparser) -> None:
group.add_argument("--enable", metavar="NAME", help="Undo --disable")
p_src.set_defaults(_vault_handler=_cmd_sources)
+ p_key = subs.add_parser("key", help="Show where the local vault key is stored (vault.key file or OS keychain)")
+ p_key.set_defaults(_vault_handler=_cmd_key, to=None)
+ key_subs = p_key.add_subparsers(dest="vault_key_action")
+ p_migrate = key_subs.add_parser(
+ "migrate", help="Move the vault key to the OS keychain or back to vault.key (verified before the old copy is removed)")
+ p_migrate.add_argument("--to", choices=["keychain", "file"], required=True, help="Destination for the key")
+ p_migrate.set_defaults(_vault_handler=_cmd_key)
+
def vault_command(args) -> None:
from agent.vault_store import VaultError
diff --git a/pm/extras.py b/pm/extras.py
index 69bc080411c..ece84451724 100644
--- a/pm/extras.py
+++ b/pm/extras.py
@@ -47,6 +47,7 @@ ANCHORS: dict[str, str | tuple[str, ...]] = {
"dingtalk": "dingtalk_stream",
"feishu": "lark_oapi",
"wecom": "defusedxml",
+ "keychain": "keyring",
"teams": "microsoft_teams.apps",
"modal": "modal",
"daytona": "daytona",
diff --git a/pyproject.toml b/pyproject.toml
index 361d16892f7..8793ed59e09 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -299,6 +299,9 @@ matrix = [
# and XXE. aiohttp/httpx are already in [messaging]; defusedxml lands
# here to keep the dependency local to wecom_callback's threat model.
wecom = ["defusedxml==0.7.1"]
+# Opt-in OS-keychain storage for the local credential vault key (vault.key_storage: keychain).
+# Lazy-installed by `hermes vault key migrate --to keychain`, so NOT in [all].
+keychain = ["keyring==25.7.0"]
tts-premium = ["elevenlabs==1.59.0"]
voice = [
# Local STT pulls in wheel-only transitive deps (ctranslate2, onnxruntime).
diff --git a/tests/agent/test_vault_key_storage.py b/tests/agent/test_vault_key_storage.py
new file mode 100644
index 00000000000..ae2b35cd43f
--- /dev/null
+++ b/tests/agent/test_vault_key_storage.py
@@ -0,0 +1,197 @@
+"""Where the local vault key lives: the 0600 ``vault.key`` file (default) or the OS keychain.
+
+Contracts (temp HERMES_HOME + an in-memory keyring backend; nothing touches a real keychain):
+- keychain mode stores a NEW vault's key in the keychain, one entry per profile, and leaves no key
+ file beside the ciphertext;
+- ``migrate_key`` writes the keychain first, proves it decrypts the vault, and only then removes the
+ file; a store that cannot return the key aborts with the file intact (and back again for ``file``);
+- a vault whose key is missing says how to recover instead of minting a new key over it;
+- no reachable OS keychain (headless Linux, no keyring extra) falls back to the key file.
+"""
+
+from __future__ import annotations
+
+import shutil
+import stat
+import sys
+
+import keyring
+from cryptography.fernet import Fernet
+import pytest
+from keyring.backend import KeyringBackend
+from keyring.backends import fail
+from keyring.errors import PasswordDeleteError
+
+from agent.vault_store import VaultError, VaultStore
+
+_LOGIN = {"identifier_type": "email", "identifier": "[email protected]", "password": "dummy-pw-not-real-42"}
+
+
+class MemoryKeyring(KeyringBackend):
+ priority = 1
+
+ def __init__(self):
+ super().__init__()
+ self.entries: dict[tuple[str, str], str] = {}
+
+ def get_password(self, service, username):
+ return self.entries.get((service, username))
+
+ def set_password(self, service, username, password):
+ self.entries[(service, username)] = password
+
+ def delete_password(self, service, username):
+ if self.entries.pop((service, username), None) is None:
+ raise PasswordDeleteError("no such entry")
+
+
+class ForgetfulKeyring(MemoryKeyring):
+ """Accepts the write but hands back something else (a broken or mis-scoped store)."""
+
+ def get_password(self, service, username):
+ return "bm90LXRoZS1rZXktbm90LXRoZS1rZXktbm90LXRoZS1rZXk="
+
+
+def home(tmp_path, monkeypatch):
+ def make(name: str = "default", key_storage: str | None = None):
+ path = tmp_path / name
+ path.mkdir()
+ if key_storage:
+ (path / "config.yaml").write_text(f"vault:\n key_storage: {key_storage}\n", encoding="utf-8")
+ monkeypatch.setenv("HERMES_HOME", str(path))
+ return path
+ yield make
+ keyring.set_keyring(fail.Keyring())
+
+
+def keychain():
+ backend = MemoryKeyring()
+ keyring.set_keyring(backend)
+ return backend
+
+
+def _add(store: VaultStore) -> str:
+ return store.add_item("login", "Example", dict(_LOGIN), origin="https://example.com").id
+
+
+def test_keychain_mode_puts_a_new_vault_key_in_the_keychain_per_profile(home, keychain):
+ a = home("a", key_storage="keychain")
+ item_a = _add(VaultStore())
+ assert not (a / "vault" / "vault.key").exists()
+ assert (a / "vault" / "vault.json.enc").stat().st_size > 0
+ assert len(keychain.entries) == 1
+ assert VaultStore().resolve_secret(item_a)["password"] == _LOGIN["password"]
+
+ b = home("b", key_storage="keychain")
+ item_b = _add(VaultStore())
+ assert not (b / "vault" / "vault.key").exists()
+ assert len(keychain.entries) == 2, "each profile gets its own keychain entry"
+ assert VaultStore().resolve_secret(item_b)["password"] == _LOGIN["password"]
+ assert VaultStore(a / "vault").resolve_secret(item_a)["password"] == _LOGIN["password"]
+
+
+def test_migration_writes_keychain_verifies_then_removes_the_file_and_back(home, keychain):
+ h = home()
+ store = VaultStore()
+ item = _add(store)
+ key_file = h / "vault" / "vault.key"
+ old_key = key_file.read_bytes().strip()
+
+ assert store.migrate_key("keychain") == "keychain"
+ assert not key_file.exists()
+ assert list(keychain.entries.values()) == [old_key.decode()]
+ assert VaultStore().resolve_secret(item)["password"] == _LOGIN["password"]
+
+ assert store.migrate_key("file") == "file"
+ assert key_file.read_bytes().strip() == old_key
+ assert stat.S_IMODE(key_file.stat().st_mode) == 0o600
+ assert keychain.entries == {}
+ assert VaultStore().resolve_secret(item)["password"] == _LOGIN["password"]
+
+
+def test_migration_keeps_the_key_file_when_the_keychain_cannot_return_the_key(home):
+ h = home()
+ keyring.set_keyring(ForgetfulKeyring())
+ store = VaultStore()
+ item = _add(store)
+ with pytest.raises(VaultError, match="keychain"):
+ store.migrate_key("keychain")
+ assert (h / "vault" / "vault.key").exists()
+ assert not (h / "vault" / "vault.keyref").exists()
+ assert VaultStore().resolve_secret(item)["password"] == _LOGIN["password"]
+
+
[email protected]("lose", ["keychain entry", "key file"])
+def test_missing_key_with_an_existing_vault_explains_recovery_and_mints_nothing(home, keychain, lose):
+ h = home(key_storage="keychain" if lose == "keychain entry" else None)
+ _add(VaultStore())
+ blob = (h / "vault" / "vault.json.enc").read_bytes()
+ if lose == "keychain entry":
+ keychain.entries.clear()
+ else:
+ (h / "vault" / "vault.key").unlink()
+
+ with pytest.raises(VaultError) as excinfo:
+ VaultStore().list_items()
+ message = str(excinfo.value)
+ assert "hermes vault key" in message and "vault.json.enc" in message
+ assert (h / "vault" / "vault.json.enc").read_bytes() == blob, "the ciphertext must be left alone"
+ assert not (h / "vault" / "vault.key").exists(), "no fresh key may be minted over an existing vault"
+ assert len(keychain.entries) == 0
+ if lose == "keychain entry": # and a rerun of the move must not report the lost entry as fine
+ with pytest.raises(VaultError, match="hermes vault key"):
+ VaultStore().migrate_key("keychain")
+
+
[email protected]("headless", ["no secret service", "no keyring extra"])
+def test_keychain_mode_without_a_reachable_keychain_falls_back_to_the_key_file(home, monkeypatch, headless):
+ h = home(key_storage="keychain")
+ if headless == "no secret service":
+ keyring.set_keyring(fail.Keyring()) # what keyring resolves to on a headless Linux box
+ else:
+ monkeypatch.setitem(sys.modules, "keyring", None) # extra not installed: import fails
+ item = _add(VaultStore())
+ key_file = h / "vault" / "vault.key"
+ assert key_file.exists() and stat.S_IMODE(key_file.stat().st_mode) == 0o600
+ assert not (h / "vault" / "vault.keyref").exists()
+ assert VaultStore().resolve_secret(item)["password"] == _LOGIN["password"]
+
+ with pytest.raises(VaultError, match="keychain"):
+ VaultStore().migrate_key("keychain")
+ assert key_file.exists()
+
+
+def test_a_stray_key_file_that_cannot_open_the_vault_never_costs_the_keychain_copy(home, keychain):
+ h = home(key_storage="keychain")
+ item = _add(VaultStore())
+ (h / "vault" / "vault.key").write_bytes(Fernet.generate_key()) # e.g. restored from an old backup
+ good = dict(keychain.entries)
+ for target in ("file", "keychain"):
+ with pytest.raises(VaultError, match="does not decrypt"):
+ VaultStore().migrate_key(target)
+ assert keychain.entries == good
+ (h / "vault" / "vault.key").unlink()
+ assert VaultStore().resolve_secret(item)["password"] == _LOGIN["password"]
+
+
+def test_cloned_and_renamed_keychain_vaults_never_share_or_overwrite_an_entry(home, keychain):
+ """A profile clone copies vault.keyref; a rename moves it. Neither copy may later overwrite or delete
+ the entry another copy still depends on, and a new vault at a reused name gets its own entry."""
+ work = home("work", key_storage="keychain")
+ item = _add(VaultStore())
+ a, b = home("clone-a", key_storage="keychain"), home("clone-b", key_storage="keychain")
+ for clone in (a, b):
+ shutil.copytree(work / "vault", clone / "vault")
+ assert VaultStore(a / "vault").migrate_key("file") == "file"
+ assert VaultStore(b / "vault").migrate_key("keychain") == "keychain"
+ assert VaultStore(work / "vault").migrate_key("file") == "file" # deletes only the original's own entry
+ for vault in (a, b, work):
+ assert VaultStore(vault / "vault").resolve_secret(item)["password"] == _LOGIN["password"]
+
+ assert VaultStore(work / "vault").migrate_key("keychain") == "keychain"
+ renamed = home("renamed", key_storage="keychain")
+ (work / "vault").rename(renamed / "vault")
+ _add(VaultStore(work / "vault")) # a new vault where the renamed one used to live
+ assert VaultStore(renamed / "vault").resolve_secret(item)["password"] == _LOGIN["password"]
diff --git a/tests/hermes_cli/test_vault_key_cli.py b/tests/hermes_cli/test_vault_key_cli.py
new file mode 100644
index 00000000000..7bfdb155037
--- /dev/null
+++ b/tests/hermes_cli/test_vault_key_cli.py
@@ -0,0 +1,66 @@
+"""`hermes vault key migrate --to keychain|file` through the real argparse tree: the key moves, the
+vault still opens, and ``vault.key_storage`` follows so a recreated vault lands in the same place."""
+
+from __future__ import annotations
+
+import argparse
+
+import keyring
+import pytest
+from keyring.backend import KeyringBackend
+from keyring.backends import fail
+
+from agent.vault_store import VaultStore
+
+
+class _MemoryKeyring(KeyringBackend):
+ priority = 1
+
+ def __init__(self):
+ super().__init__()
+ self.entries: dict[tuple[str, str], str] = {}
+
+ def get_password(self, service, username):
+ return self.entries.get((service, username))
+
+ def set_password(self, service, username, password):
+ self.entries[(service, username)] = password
+
+ def delete_password(self, service, username):
+ self.entries.pop((service, username))
+
+
+def hermes(tmp_path, monkeypatch):
+ monkeypatch.setenv("HERMES_HOME", str(tmp_path))
+ backend = _MemoryKeyring()
+ keyring.set_keyring(backend)
+ from hermes_cli.subcommands.vault import build_vault_parser
+
+ parser = argparse.ArgumentParser(prog="hermes")
+ build_vault_parser(parser.add_subparsers())
+
+ def run(*argv):
+ args = parser.parse_args(["vault", *argv])
+ args.func(args)
+
+ yield run, backend, tmp_path
+ keyring.set_keyring(fail.Keyring())
+
+
+def test_vault_key_migrate_moves_the_key_and_records_the_choice(hermes, capsys):
+ run, backend, home = hermes
+ item = VaultStore().add_item("login", "Example", {"identifier_type": "email", "identifier": "[email protected]",
+ "password": "dummy-pw-cli-9"}, origin="https://example.com").id
+ from hermes_cli.config import load_config
+
+ run("key", "migrate", "--to", "keychain")
+ assert not (home / "vault" / "vault.key").exists() and len(backend.entries) == 1
+ assert load_config()["vault"]["key_storage"] == "keychain"
+ run("key")
+ assert "OS keychain" in capsys.readouterr().out
+
+ run("key", "migrate", "--to", "file")
+ assert (home / "vault" / "vault.key").exists() and backend.entries == {}
+ assert load_config()["vault"]["key_storage"] == "file"
+ assert VaultStore().resolve_secret(item)["password"] == "dummy-pw-cli-9"
diff --git a/tests/test_project_metadata.py b/tests/test_project_metadata.py
index 470a17b81cb..a6ab45c385e 100644
--- a/tests/test_project_metadata.py
+++ b/tests/test_project_metadata.py
@@ -122,6 +122,7 @@ def test_lazy_installable_extras_excluded_from_all():
"telegram", "discord",
"wake", "wake-openwakeword", "wake-sherpa", "wake-porcupine",
"google-chat",
+ "keychain", # keyring — vault key in the OS keychain, installed by `hermes vault key migrate`
"mistral", # mistralai — Voxtral STT/TTS, lazy-installed (stt.mistral / tts.mistral)
}
all_extra_specs = optional_dependencies["all"]
diff --git a/uv.lock b/uv.lock
index 4408980c0a0..f6b6479fa41 100644
--- a/uv.lock
+++ b/uv.lock
@@ -2421,6 +2421,9 @@ google-meet = [
{ name = "playwright", marker = "sys_platform != 'android'" },
{ name = "websockets", marker = "sys_platform != 'android'" },
]
+keychain = [
+ { name = "keyring" },
+]
kittentts = [
{ name = "kittentts", marker = "(platform_machine != 'x86_64' and sys_platform == 'darwin') or (platform_machine != 'ARM64' and sys_platform == 'win32') or (sys_platform != 'android' and sys_platform != 'darwin' and sys_platform != 'win32')" },
{ name = "misaki", extra = ["en"], marker = "(platform_machine != 'x86_64' and sys_platform == 'darwin') or (platform_machine != 'ARM64' and sys_platform == 'win32') or (sys_platform != 'android' and sys_platform != 'darwin' and sys_platform != 'win32')" },
@@ -2649,6 +2652,7 @@ requires-dist = [
{ name = "httpx2", marker = "extra == 'mcp'", specifier = "==2.15.1" },
{ name = "huggingface-hub", marker = "extra == 'trace-upload'", specifier = "==1.33.0" },
{ name = "jinja2", marker = "python_full_version >= '3.14'", specifier = "==3.1.6" },
+ { name = "keyring", marker = "extra == 'keychain'", specifier = "==25.7.0" },
{ name = "kittentts", marker = "(platform_machine != 'x86_64' and sys_platform == 'darwin' and extra == 'kittentts') or (platform_machine != 'ARM64' and sys_platform == 'win32' and extra == 'kittentts') or (sys_platform != 'android' and sys_platform != 'darwin' and sys_platform != 'win32' and extra == 'kittentts')", url = "https://github.com/KittenML/KittenTTS/releases/download/0.8.1/kittentts-0.8.1-py3-none-any.whl" },
{ name = "lark-oapi", marker = "extra == 'feishu'", specifier = "==1.7.5" },
{ name = "markdown", marker = "python_full_version >= '3.14'", specifier = "==3.11.2" },
@@ -2740,7 +2744,7 @@ requires-dist = [
{ name = "winrt-windows-services-store", marker = "python_full_version >= '3.14' and sys_platform == 'win32'", specifier = ">=3.2.1,<4" },
{ name = "youtube-transcript-api", marker = "extra == 'youtube'", specifier = "==1.2.4" },
]
-provides-extras = ["uvloop", "anthropic", "exa", "firecrawl", "parallel-web", "ddgs", "fal", "edge-tts", "neutts", "kittentts", "piper", "modal", "daytona", "vercel", "google-meet", "messaging", "cron", "slack", "matrix", "wecom", "tts-premium", "voice", "wake", "telegram", "discord", "stt-whisper", "audio-io", "silk", "wake-openwakeword", "wake-sherpa", "wake-porcupine", "google-chat", "doc-extract", "trace-upload", "vision", "pty", "mcp", "nemo-relay", "sms", "teams", "computer-use", "acp", "mistral", "otlp", "bedrock", "vertex", "azure-identity", "termux", "termux-all", "dingtalk", "feishu", "google", "youtube", "web", "all"]
+provides-extras = ["uvloop", "anthropic", "exa", "firecrawl", "parallel-web", "ddgs", "fal", "edge-tts", "neutts", "kittentts", "piper", "modal", "daytona", "vercel", "google-meet", "messaging", "cron", "slack", "matrix", "wecom", "keychain", "tts-premium", "voice", "wake", "telegram", "discord", "stt-whisper", "audio-io", "silk", "wake-openwakeword", "wake-sherpa", "wake-porcupine", "google-chat", "doc-extract", "trace-upload", "vision", "pty", "mcp", "nemo-relay", "sms", "teams", "computer-use", "acp", "mistral", "otlp", "bedrock", "vertex", "azure-identity", "termux", "termux-all", "dingtalk", "feishu", "google", "youtube", "web", "all"]
[package.metadata.requires-dev]
dev = [
@@ -3006,6 +3010,48 @@ wheels = [
{ url = "https://files.pythonhosted.org/packages/15/aa/0aca39a37d3c7eb941ba736ede56d689e7be91cab5d9ca846bde3999eba6/isodate-0.7.2-py3-none-any.whl", hash = "sha256:28009937d8031054830160fce6d409ed342816b543597cece116d966c6d99e15", size = 22320, upload-time = "2024-10-08T23:04:09.501Z" },
]
+[[package]]
+name = "jaraco-classes"
+version = "3.4.0"
+source = { registry = "https://pypi.org/simple" }
+dependencies = [
+ { name = "more-itertools" },
+]
+sdist = { url = "https://files.pythonhosted.org/packages/06/c0/ed4a27bc5571b99e3cff68f8a9fa5b56ff7df1c2251cc715a652ddd26402/jaraco.classes-3.4.0.tar.gz", hash = "sha256:47a024b51d0239c0dd8c8540c6c7f484be3b8fcf0b2d85c13825780d3b3f3acd", size = 11780, upload-time = "2024-03-31T07:27:36.643Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/7f/66/b15ce62552d84bbfcec9a4873ab79d993a1dd4edb922cbfccae192bd5b5f/jaraco.classes-3.4.0-py3-none-any.whl", hash = "sha256:f662826b6bed8cace05e7ff873ce0f9283b5c924470fe664fff1c2f00f581790", size = 6777, upload-time = "2024-03-31T07:27:34.792Z" },
+]
+
+[[package]]
+name = "jaraco-context"
+version = "6.1.2"
+source = { registry = "https://pypi.org/simple" }
+sdist = { url = "https://files.pythonhosted.org/packages/af/50/4763cd07e722bb6285316d390a164bc7e479db9d90daa769f22578f698b4/jaraco_context-6.1.2.tar.gz", hash = "sha256:f1a6c9d391e661cc5b8d39861ff077a7dc24dc23833ccee564b234b81c82dfe3", size = 16801, upload-time = "2026-03-20T22:13:33.922Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/f2/58/bc8954bda5fcda97bd7c19be11b85f91973d67a706ed4a3aec33e7de22db/jaraco_context-6.1.2-py3-none-any.whl", hash = "sha256:bf8150b79a2d5d91ae48629d8b427a8f7ba0e1097dd6202a9059f29a36379535", size = 7871, upload-time = "2026-03-20T22:13:32.808Z" },
+]
+
+[[package]]
+name = "jaraco-functools"
+version = "4.6.0"
+source = { registry = "https://pypi.org/simple" }
+dependencies = [
+ { name = "more-itertools" },
+]
+sdist = { url = "https://files.pythonhosted.org/packages/6c/1f/c23395957d41ccf27c4e535c3d334c4051e5395b3752057ba4cbaec35c56/jaraco_functools-4.6.0.tar.gz", hash = "sha256:880c577ec9720b3a052d5bc611fb9f2269b3d87902ef42440df443b88e443280", size = 20837, upload-time = "2026-07-14T01:28:02.544Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/02/36/ecc85bc96c273dc8a11273ed4782272975e6338d4a3e9228621175edf0e3/jaraco_functools-4.6.0-py3-none-any.whl", hash = "sha256:99e3dc0060c5cbe8fcd1cdb36258e2a65ca40f1566b2033b12abb1bb44dd3c30", size = 11677, upload-time = "2026-07-14T01:28:01.59Z" },
+]
+
+[[package]]
+name = "jeepney"
+version = "0.9.0"
+source = { registry = "https://pypi.org/simple" }
+sdist = { url = "https://files.pythonhosted.org/packages/7b/6f/357efd7602486741aa73ffc0617fb310a29b588ed0fd69c2399acbb85b0c/jeepney-0.9.0.tar.gz", hash = "sha256:cf0e9e845622b81e4a28df94c40345400256ec608d0e55bb8a3feaa9163f5732", size = 106758, upload-time = "2025-02-27T18:51:01.684Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/b2/a3/e137168c9c44d18eff0376253da9f1e9234d0239e0ee230d2fee6cea8e55/jeepney-0.9.0-py3-none-any.whl", hash = "sha256:97e5714520c16fc0a45695e5365a2e11b81ea79bba796e26f9f1d178cb182683", size = 49010, upload-time = "2025-02-27T18:51:00.104Z" },
+]
+
[[package]]
name = "jinja2"
version = "3.1.6"
@@ -3161,6 +3207,23 @@ wheels = [
{ url = "https://files.pythonhosted.org/packages/41/45/1a4ed80516f02155c51f51e8cedb3c1902296743db0bbc66608a0db2814f/jsonschema_specifications-2025.9.1-py3-none-any.whl", hash = "sha256:98802fee3a11ee76ecaca44429fda8a41bff98b00a0f2838151b113f210cc6fe", size = 18437, upload-time = "2025-09-08T01:34:57.871Z" },
]
+[[package]]
+name = "keyring"
+version = "25.7.0"
+source = { registry = "https://pypi.org/simple" }
+dependencies = [
+ { name = "jaraco-classes" },
+ { name = "jaraco-context" },
+ { name = "jaraco-functools" },
+ { name = "jeepney", marker = "sys_platform == 'linux'" },
+ { name = "pywin32-ctypes", marker = "sys_platform == 'win32'" },
+ { name = "secretstorage", marker = "sys_platform == 'linux'" },
+]
+sdist = { url = "https://files.pythonhosted.org/packages/43/4b/674af6ef2f97d56f0ab5153bf0bfa28ccb6c3ed4d1babf4305449668807b/keyring-25.7.0.tar.gz", hash = "sha256:fe01bd85eb3f8fb3dd0405defdeac9a5b4f6f0439edbb3149577f244a2e8245b", size = 63516, upload-time = "2025-11-16T16:26:09.482Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/81/db/e655086b7f3a705df045bf0933bdd9c2f79bb3c97bfef1384598bb79a217/keyring-25.7.0-py3-none-any.whl", hash = "sha256:be4a0b195f149690c166e850609a477c532ddbfbaed96a404d4e43f8d5e2689f", size = 39160, upload-time = "2025-11-16T16:26:08.402Z" },
+]
+
[[package]]
name = "kittentts"
version = "0.8.1"
@@ -3624,6 +3687,15 @@ wheels = [
{ url = "https://files.pythonhosted.org/packages/59/2c/d7a1eadd29223208d9143b57fc027e39ad2da411c798e991e669fe7562a2/modal-1.6.2-py3-none-any.whl", hash = "sha256:1a6c8409e315785137615601cac940de3d72462c0059b9cd0faf5d17615bacf0", size = 1097851, upload-time = "2026-10-16T02:21:32.788Z" },
]
+[[package]]
+name = "more-itertools"
+version = "11.2.1"
+source = { registry = "https://pypi.org/simple" }
+sdist = { url = "https://files.pythonhosted.org/packages/52/b8/c63995bebbb9ac9c059350e0fb8c82c2420c85aeca7d34e40aecf3df9281/more_itertools-11.2.1.tar.gz", hash = "sha256:cbf08fd0af284dc69718b9b76a8e6203df624d70209ea511e4219d350c856f63", size = 154133, upload-time = "2026-10-14T18:50:30.407Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/5d/57/3c4b1c6f2e0cc29ba023802458ea3d2a996f87085559e4a5f2192d549532/more_itertools-11.2.1-py3-none-any.whl", hash = "sha256:35a7377edd1dd6608dcb2cdf534ded55ea32d49448875ad042cd3f879fb1ded0", size = 74405, upload-time = "2026-10-14T18:50:29.116Z" },
+]
+
[[package]]
name = "mpmath"
version = "1.3.0"
@@ -5421,6 +5493,15 @@ wheels = [
{ url = "https://files.pythonhosted.org/packages/c0/d2/21af5c535501a7233e734b8af901574572da66fcc254cb35d0609c9080dd/pywin32-311-cp314-cp314-win_arm64.whl", hash = "sha256:a508e2d9025764a8270f93111a970e1d0fbfc33f4153b388bb649b7eec4f9b42", size = 8932540, upload-time = "2025-07-14T20:13:36.379Z" },
]
+[[package]]
+name = "pywin32-ctypes"
+version = "0.2.3"
+source = { registry = "https://pypi.org/simple" }
+sdist = { url = "https://files.pythonhosted.org/packages/85/9f/01a1a99704853cb63f253eea009390c88e7131c67e66a0a02099a8c917cb/pywin32-ctypes-0.2.3.tar.gz", hash = "sha256:d162dc04946d704503b2edc4d55f3dba5c1d539ead017afa00142c38b9885755", size = 29471, upload-time = "2024-08-14T10:15:34.626Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/de/3d/8161f7711c017e01ac9f008dfddd9410dff3674334c233bde66e7ba65bbf/pywin32_ctypes-0.2.3-py3-none-any.whl", hash = "sha256:8a1513379d709975552d202d942d9837758905c8d01eb82b8bcc30918929e7b8", size = 30756, upload-time = "2024-08-14T10:15:33.187Z" },
+]
+
[[package]]
name = "pywinpty"
version = "3.1.0"
@@ -5972,6 +6053,19 @@ wheels = [
{ url = "https://files.pythonhosted.org/packages/8d/fc/7eedc3510d97878876e32774eebbeb61c43f148a96e915c84229a3e967aa/safetensors-0.8.0-cp310-abi3-win_arm64.whl", hash = "sha256:f7838e5135a406ad3e02efdcb8cf2e5397d368b0154537c4fec682dbc544d452", size = 340500, upload-time = "2026-06-09T07:52:26.745Z" },
]
+[[package]]
+name = "secretstorage"
+version = "3.5.0"
+source = { registry = "https://pypi.org/simple" }
+dependencies = [
+ { name = "cryptography" },
+ { name = "jeepney" },
+]
+sdist = { url = "https://files.pythonhosted.org/packages/1c/03/e834bcd866f2f8a49a85eaff47340affa3bfa391ee9912a952a1faa68c7b/secretstorage-3.5.0.tar.gz", hash = "sha256:f04b8e4689cbce351744d5537bf6b1329c6fc68f91fa666f60a380edddcd11be", size = 19884, upload-time = "2025-11-23T19:02:53.191Z" }
+wheels = [
+ { url = "https://files.pythonhosted.org/packages/b7/46/f5af3402b579fd5e11573ce652019a67074317e18c1935cc0b4ba9b35552/secretstorage-3.5.0-py3-none-any.whl", hash = "sha256:0ce65888c0725fcb2c5bc0fdb8e5438eece02c523557ea40ce0703c266248137", size = 15554, upload-time = "2025-11-23T19:02:51.545Z" },
+]
+
[[package]]
name = "segments"
version = "2.4.0"