References

Source: Setting up pass on git with a gpg key · GitHub

Pass for iOS

private repos 需要用 SSH Key 来访问。参考 Generating a new SSH key and adding it to the ssh-agent - GitHub Docs 生成后使用 pbcopy < ~/.ssh/id_ed25519.pub 命令复制公钥配置到 GitHub。刚刚同时生成的 id_ed25519 导入到 Pass for iOS 中拉取 repo。

gpg --export-secret-keys -a <pub_key> > gpg_key
gpg --export -a <pub_key> > gpg_key.pub

根据上述命令导出公私钥,导入到 Pass for iOS。

新电脑设置

导入密钥 –> gpg --import gpg_key​,当导入新的密钥后出现以下提示

It is NOT certain that the key belongs to the person named in the user ID. If you really know what you are doing, you may answer the next question with yes.

可以通过以下步骤验证信任

gpg --edit-key YOUR@KEY.ID
gpg> trust
Please decide how far you trust this user to correctly verify other users' keys
(by looking at passports, checking fingerprints from different sources, etc.)

  1 = I don't know or won't say
  2 = I do NOT trust
  3 = I trust marginally
  4 = I trust fully
  5 = I trust ultimately
  m = back to the main menu

Your decision? 5
Do you really want to set this key to ultimate trust? (y/N) y

Remarks

当提示 gpg: waiting for lock (held by 5175) 可以用 $ ls -l ~/.gnupg/*.lock 查看相关的锁文件,删除即可。


No notes link to this note