最好的Python加密方法是什么

发布于 2024-08-07 06:14:02 字数 114 浏览 2 评论 0原文

我从公钥服务器检索了 PGP 密钥,现在需要帮助获取可以接受此 PGP 公钥的 python 加密方法。

据我所知,PGP/Gnupg.py 模块不允许我在不生成密钥的情况下单独使用加密/解密功能。

I retrieved the PGP key from the public key server ,Now need help in getting a python method for encryption which can accept this PGP public key .

As i know PGP/Gnupg.py module do not allow me to use encryption/decryption function separately without generating the key.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

梦里的微风 2024-08-14 06:14:02

在我看来,最简单的方法是使用 GPGME,它基本上是 GnuPG 包裹在方便的库形式(因此得名,GPGME = GnuPG Made Easy)。 GPGME 有一个名为 Pyme 的 Python 包装器,它可以让您执行导入密钥、使用密钥加密消息等操作等,全部使用标准PGP格式。在线有一些基本的 Pyme 文档,以及更复杂示例的承诺包含在源代码分发中。

It seems to me that the easiest approach is use GPGME, which is basically GnuPG wrapped up in a convenient library form (thus the name, GPGME = GnuPG Made Easy). There is a Python wrapper for GPGME named Pyme which will let you do things like import keys, encrypt messages using them, etc, all using the standard PGP formats. There is some basic Pyme documentation online, along with the promise of more complicated examples being included in the source distribution.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文