Token导航 LogoToken导航

Agent Skill · 研究检索

keychain-bridge(钥匙扣桥)

keychain-bridge 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

keychain-bridge 是研究检索类 Agent Skill,可用宿主为 OpenClaw,通过ClawHub获取,权限为接触敏感数据;许可证为 MIT-0,第三方扫描有提醒项,按安装量在研究检索类的 73,675 个 Skill 里排第 6,890。

总安装 20,592周安装 825GitHub Stars 公开资料未说明下载 6,666核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT-0
版本
1.1.0

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:keychain-bridge(钥匙扣桥)
来源仓库:https://github.com/euda1mon1a/keychain-bridge
安装命令:
openclaw skills install keychain-bridge
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install keychain-bridge

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

用于通过 macOS 钥匙串安全存储和管理机密信息,替代明文配置文件。适合在 OpenClaw 中迁移现有密钥、读写钥匙串条目或桥接 bash 工具脚本时使用。支持审核条目变更历史与权限控制,提升本地环境安全性。安装命令:openclaw skills install keychain-bridge。

仅限 macOS 系统使用,且需用户授予钥匙串访问权限。

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 OpenClaw;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 openclaw skills install keychain-bridge;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

keychain-bridge 怎么安装?

在终端执行 openclaw skills install keychain-bridge。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

keychain-bridge 支持哪些 AI 工具?

公开资料标注支持 OpenClaw。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

keychain-bridge 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

keychain-bridge 是免费的吗?

来源标注的许可证是 MIT-0。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

keychain-bridge 用的人多吗?

公开数据是累计安装 20,592 次,近一周安装 825 次,下载 6,666 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

keychain-bridge 安全吗?

第三方扫描有提醒项,说明存在需要人工确认的行为。安装前请打开源码看清它读了什么、联网到哪里。

值得选的地方和要先想清楚的地方

值得选的地方

  • 专注 OpenClaw 一种宿主,触发方式和使用习惯不用来回切换。
  • 许可证明确为 MIT-0,商用和分发边界好判断。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 OpenClaw,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
keychain-bridge

钥匙扣桥 · 本页

20,592—接触敏感数据MIT-0有提醒

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

name
keychain-bridge
description
Manage secrets via macOS Keychain instead of plaintext files. Migrate existing secrets, read/write keychain entries, bridge to files for bash tools, audit for leaks, diagnose access issues. Use when asked about secrets, keychain, credentials, API keys, or security hardening on macOS.
homepage
https://github.com/moltbot/keychain-bridge
metadata
openclaw
emoji
🔐
requires
bins
["bash", "python3"]
env
[]
files
["scripts/*"]
clawmart
price
99
currency
USD
category
security
tags
["keychain", "macos", "secrets", "credentials", "tahoe", "migration"]

Keychain Bridge

Trigger Phrases

  • "migrate secrets to keychain" / "move secrets"
  • "check keychain health" / "keychain status"
  • "audit secrets" / "check for leaks"
  • "read secret" / "get API key"
  • "store secret" / "write to keychain"
  • "keychain not working" / "security find-generic-password hangs"

Example Usage

User: "Migrate my secrets to the keychain"
Action: python3 SKILL_DIR/scripts/migrate_secrets.py --dir ~/.openclaw/secrets/ --account moltbot --dry-run

User: "Check if the keychain bridge is healthy"
Action: Run keychain health check (test write/read/delete cycle)

User: "Audit for plaintext secret leaks"
Action: python3 SKILL_DIR/scripts/audit_secrets.py --dir ~/.openclaw/secrets/ --account moltbot

Manage secrets via macOS Keychain instead of plaintext files. Eliminates plaintext credential storage while maintaining compatibility with bash-based tools through a file-bridge architecture.

Prerequisites

The keyring Python library must be installed for each Python version that will access secrets:

pip3 install keyring
# If multiple Python versions exist (common on macOS):
/usr/bin/python3 -m pip install keyring
/opt/homebrew/opt/python@3.14/bin/python3.14 -m pip install --break-system-packages keyring

Check Keychain Health

Verify the keychain bridge is working correctly:

python3 -c "
import keyring
# Test write
keyring.set_password('keychain-bridge-test', 'test', 'hello')
# Test read
val = keyring.get_password('keychain-bridge-test', 'test')
assert val == 'hello', f'Read back {val!r}, expected hello'
# Cleanup
keyring.delete_password('keychain-bridge-test', 'test')
print('Keychain health: OK')
"

If this fails, see Diagnose Issues below.

Migrate Secrets

Migrate plaintext secret files to macOS Keychain. The migration tool:

  • Auto-detects all Python versions on the system
  • Injects each secret from ALL detected Python binaries (required for ACL coverage)
  • Verifies the round-trip read
  • Optionally deletes the original file
python3 SKILL_DIR/scripts/migrate_secrets.py --dir ~/.openclaw/secrets/ --account moltbot --dry-run
# Remove --dry-run to actually migrate
python3 SKILL_DIR/scripts/migrate_secrets.py --dir ~/.openclaw/secrets/ --account moltbot

After migration, secrets fall into two groups:

Group A — Keychain Only

Python scripts read directly via keychain_helper.get_secret(service). No file on disk.

Group B — File Bridge

Bash scripts cannot reliably use Python keyring as a subprocess (see Known Issues). For these, a boot-time bridge script populates files from the keychain:

# Add to your LaunchAgent or startup script:
bash SKILL_DIR/scripts/populate_secrets.sh

This reads each Group B secret from keychain and writes it to a chmod 600 file that bash scripts can cat.

Read a Secret

From Python

import sys, os
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
from keychain_helper import get_secret

token = get_secret("my-service-name")

The helper tries keychain first, falls back to file read.

From Bash (via Group B file)

MY_SECRET=$(cat ~/.openclaw/secrets/my-service-name)

Ensure the service is listed in populate_secrets.sh so the file is populated at boot.

From Bash (via CLI helper — interactive only)

# Works from terminal, but HANGS from LaunchAgent bash scripts
MY_SECRET=$(python3 path/to/get_secret.py my-service-name)

Write a Secret

Critical: Inject from ALL Python versions on the system. Keychain ACLs are per-binary — an item created by Python 3.9 cannot be read by Python 3.14 unless both binaries are in the ACL.

# Detect Python versions
PYTHONS=()
[ -x /usr/bin/python3 ] && PYTHONS+=(/usr/bin/python3)
[ -x /opt/homebrew/opt/python@3.14/bin/python3.14 ] && PYTHONS+=(/opt/homebrew/opt/python@3.14/bin/python3.14)

# Inject from each
for py in "${PYTHONS[@]}"; do
    $py -c "import keyring; keyring.set_password('SERVICE', 'ACCOUNT', 'VALUE')"
done

Or use the migration tool for batch operations.

Audit for Leaks

Check for unexpected plaintext secret files and verify keychain health:

python3 SKILL_DIR/scripts/audit_secrets.py --dir ~/.openclaw/secrets/ --account moltbot

Reports:

  • Unexpected files in the secrets directory (potential leaks)
  • Keychain items that exist but can't be read (ACL issues)
  • Files that exist but aren't in keychain (unmigrated)
  • Keychain library installation status per Python version

Diagnose Issues

security find-generic-password -w hangs

macOS Tahoe 26.x regression. The security CLI hangs indefinitely (or returns exit code 36) when reading keychain items, even after security unlock-keychain. This affects ALL CLI-based keychain reads.

Fix: Use Python keyring library instead. It uses the Security framework C API via ctypes, bypassing the broken CLI entirely.

Python keyring returns None or raises errSecInteractionNotAllowed (-25308)

This happens when running from an SSH session. The keychain requires a GUI session (SecurityAgent) context.

Fix (recommended): Use the Group B file-bridge pattern. Write secrets from a GUI session (LaunchAgent or VNC Terminal), then read from chmod 600 files in SSH.

Fix (SSH write — ctypes unlock): The security unlock-keychain -p CLI command is also broken on Tahoe (returns "incorrect passphrase" with correct password). Use the Security framework C API via ctypes instead. The unlock + set + verify must happen in a single Python process — the unlock does not persist across invocations:

python3 << 'PYEOF'
import ctypes, ctypes.util, keyring

# Unlock via Security framework (bypasses broken security CLI)
Security = ctypes.cdll.LoadLibrary(ctypes.util.find_library("Security"))
keychain = ctypes.c_void_p()
path = b"/Users/USERNAME/Library/Keychains/login.keychain-db"
Security.SecKeychainOpen(path, ctypes.byref(keychain))
pw = b"YOUR_LOGIN_PASSWORD"
Security.SecKeychainUnlock(keychain, ctypes.c_uint32(len(pw)), pw, ctypes.c_bool(True))

# Now keyring works — but ONLY within this same process
keyring.set_password("SERVICE", "ACCOUNT", "VALUE")
print("OK" if keyring.get_password("SERVICE", "ACCOUNT") else "FAIL")
PYEOF

Caveats of ctypes unlock:

  • Unlock is process-scoped — a second python3 invocation starts locked again
  • Only /usr/bin/python3 (Apple system Python) can write after ctypes unlock; Homebrew Pythons (3.12, 3.14) still get -25308 even in the same process
  • For multi-Python ACL coverage, write from /usr/bin/python3 first, then inject from other Pythons in a VNC Terminal session (GUI context)
  • If you need SSH-only access to the secret after writing, create a Group B bridge file in the same process:
# After keyring.set_password() succeeds in the same process:
import os
val = keyring.get_password("SERVICE", "ACCOUNT")
os.makedirs(os.path.expanduser("~/.my-app/secrets"), exist_ok=True)
path = os.path.expanduser("~/.my-app/secrets/SERVICE")
with open(path, "w") as f:
    f.write(val)
os.chmod(path, 0o600)

Python keyring hangs when called from bash LaunchAgent

Novel finding (macOS Tahoe 26.x). When a bash script is the LaunchAgent program and spawns python3 get_secret.py as a subprocess, the Python process hangs indefinitely. The SecurityAgent session attachment is lost in the bash-to-python subprocess transition.

Fix: Use the Group B file-bridge pattern. Have a Python-native process populate files at boot, then bash scripts read from files.

Alternatively, make Python the direct LaunchAgent program (not a subprocess of bash).

Different Python versions can't read each other's items

Keychain ACLs are per-binary. An item created by /usr/bin/python3 (Python 3.9) has an ACL entry only for that binary. /opt/homebrew/bin/python3.14 is a different binary and gets access denied.

Fix: Inject from both Python versions:

# Read from working version, write via target version
import subprocess, keyring
value = keyring.get_password("service", "account")
subprocess.run(["/opt/homebrew/bin/python3.14", "-c",
    f"import keyring; keyring.set_password('service', 'account', '{value}')"])

Or use migrate_secrets.py which handles this automatically.

keyring not installed for a Python version

Each Python binary has its own site-packages. pip3 install keyring only installs for one.

# Check which Python pip3 targets
pip3 --version
# Install for system Python
/usr/bin/python3 -m pip install keyring
# Install for Homebrew Python
/opt/homebrew/opt/python@3.14/bin/python3.14 -m pip install --break-system-packages keyring

Architecture Reference

                    ┌─────────────────────┐
                    │   macOS Keychain     │
                    │  (login keychain)    │
                    └──────────┬──────────┘
                               │
              ┌────────────────┼────────────────┐
              │                │                │
    ┌─────────▼─────────┐     │     ┌──────────▼──────────┐
    │   Group A          │     │     │   Group B            │
    │   (keychain only)  │     │     │   (file bridge)      │
    │                    │     │     │                      │
    │ Python scripts     │     │     │ populate_secrets.sh  │
    │ import keychain_   │     │     │ runs at boot →       │
    │ helper.get_secret()│     │     │ writes chmod 600     │
    │                    │     │     │ files for bash       │
    └────────────────────┘     │     └──────────────────────┘
                               │
                    ┌──────────▼──────────┐
                    │   Fallback           │
                    │   get_secret() tries │
                    │   keychain first,    │
                    │   then file read     │
                    └─────────────────────┘

When to use Group A

  • The consumer is a Python script
  • The script runs as a LaunchAgent (or from terminal)
  • The script is NOT spawned as a subprocess from a bash LaunchAgent

When to use Group B

  • The consumer is a bash script
  • The bash script runs as a LaunchAgent
  • The secret is referenced by a config file that expects file:secrets/ paths

Known Issues (macOS Tahoe 26.x)

  1. security CLI broken across the board: find-generic-password -w hangs or exits 36. unlock-keychain -p returns "incorrect passphrase" with correct password. show-keychain-info exits 36. The entire security CLI is unreliable on Tahoe — use Python keyring (Group A) or ctypes Security framework for all keychain operations.
  2. Keychain ACL per-binary: Must inject from every Python version that will read the item.
  3. Bash subprocess loses SecurityAgent: bash LaunchAgent → python3 subprocess hangs. Use Group B file bridge.
  4. SSH sessions lack GUI context: Keychain reads/writes fail with -25308. Use ctypes SecKeychainUnlock in the same Python process (see Diagnose Issues), or use Group B file bridge. The ctypes unlock is process-scoped — it does not persist across separate command invocations.
  5. keyring must be installed per-Python: Each binary's site-packages is independent.
  6. Homebrew Python ignores ctypes unlock: After SecKeychainUnlock via ctypes, /usr/bin/python3 (Apple system Python 3.9) can read/write via keyring, but Homebrew Pythons (3.12, 3.14) still get -25308. Root cause unknown — may be entitlement or codesigning difference. Workaround: write from /usr/bin/python3, then inject from Homebrew Pythons in a GUI session (VNC Terminal or LaunchAgent).

These issues are specific to macOS Tahoe 26.x (macOS 26). Earlier versions (Sonoma 14, Sequoia 15) may not exhibit all of them, but the Group A/B architecture is safe on all versions.

External Endpoints

None. This skill makes zero network requests. All operations are local to the macOS Keychain and filesystem.

Security & Privacy

  • All operations execute locally against the macOS login keychain
  • No telemetry, analytics, or usage tracking
  • No data leaves the machine under any circumstances
  • Scripts request no network permissions
  • Secrets are only read from and written to the local keychain or chmod 600 files
  • Migration tool never logs or displays secret values

Trust Statement

All code is open for inspection — no obfuscation, no minification, no compiled binaries. The skill operates exclusively on the local macOS Keychain and filesystem. Built and tested on a production Mac Mini M4 Pro deployment running OpenClaw 24/7 with 12+ API keys and 25 automated scripts.

平台分布

OpenClaw

76.01%
按下载量换算5,067

安全审计

VirusTotal

可疑

ClawScan

可疑

Static analysis

未展示

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills