我想让选定数量的开发人员能够在系统上运行代码,并使用 OpenSSH 的-Y verify功能对其进行验证。
# Generate the certificates, and sign the dev cert with the root CA
ssh-keygen -t ed25519 -C "Example Root CA" -N "" -f ./rootca
ssh-keygen -t ed25519 -C "Some Developer Inc." -N "" -f ./developer
ssh-keygen -s ./rootca -I somedeveloper@example.com ./developer.pub # <- Creates ./developer-cert.pub
# Sign "example.bin"
echo "hello" > ./example.bin
ssh-keygen -Y sign -f ./developer -n "codesign@example.com" ./example.bin
Run Code Online (Sandbox Code Playgroud)
现在,给定“example.bin”、“example.bin.sig”、“rootca.pub”和“developer-cert.pub”,您将如何验证它?
该ssh-keygen -Y verify命令不带“developer-cert.pub”文件的参数,这对于完成 CA 和签名之间的信任链至关重要。
我可以使用ssh-keygen -L,但它似乎不安全(谁实际上检查证书中的根 …