python 中有独立的 pgp 实现吗?
我所说的“独立”是指一个模块,它允许我的应用程序管理自己的密钥数据库,而不是将资源分配给与其运行的操作系统的用户帐户关联的数据库?
我红色 python-gnupg 的文档,如果我理解正确的话,它依赖于用户本地密钥数据库。
我很高兴能找到一个可以在 Linux 上运行的解决方案。目前对其他平台的支持的优先级较低。
By 'standalone' I mean a module that allows my application to manage its own database of keys rather than resourcing to the one associated to the user account of the operative system where it runs?
I red python-gnupg's docs, if I understood it correctly it relies on the user local keys database.
I'd be happy with a solution that would work on linux. Support for other platforms has low priority at the moment.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
当您使用 python-gnupg 时,您可以使用它的
GPG()带有
构造函数:keyring
参数的When you use python-gnupg you can use its
GPG()
constructor withkeyring
argument:使用 python-gnupg 两个参数都是可能的,keyring 和gnupghome。
主目录方法的好处是,不仅使用另一个(公共)密钥环,而且您将使用该专用目录中的所有文件。如果它不存在,它将在创建 gnupg.GPG 实例时创建并填充 - 很好而且理智。
Using python-gnupg both arguments are possible, keyring and gnupghome.
The bonus for the home dir approach is, that not only another (public) keyring is used, but you'll use all files in that dedicated directory. If it doesn't exist, it will be created and populated on creation of the gnupg.GPG instance - nice and sane.