走贵一为完成。

🔐 密钥

🔐 在 Capgo Cloud 中管理加密密钥,支持 RSA 和 AES combination 的端到端加密。

🔹 保存

标题:保存
终端窗口
npx @capgo/cli@latest key save

💾 将公钥保存在 Capacitor 配置中,适用于 CI 环境。 建议不要将密钥提交到版本控制中以保持安全。

示例:

终端窗口
npx @capgo/cli@latest key save --key ./path/to/key.pub

选项:

参数:类型描述
-f,string强制生成一个新的
—keystringKey path to save in Capacitor config
—key-数据stringKey data to save in Capacitor config
窗口程屏帮
npx @capgo/cli@latest key create

🔨 Create RSA key pair for end-to-end encryption. Creates .capgo_key_v2 (private) and .capgo_key_v2.pub (public) in project root. Public key is saved to capacitor.config for mobile app decryption. NEVER commit the private key - store it securely!

生成 .__CAPGO_KEEP_0___key_v2 (私钥) 和 .__CAPGO_KEEP_1___key_v2.pub (公钥) 在项目根目录。

公钥保存到 __CAPGO_KEEP_2__.config 中用于移动应用程序解密。
npx @capgo/cli@latest key create

示例:

终端窗口复制到剪贴板选项:
参数string类型
终端窗口
npx @capgo/cli@latest key delete_old

🧹 从 Capacitor 配置中删除旧的加密密钥,以确保只使用当前密钥。

示例:

终端窗口
npx @capgo/cli@latest key delete_old