无初始化载体的密码算法

发布于 2025-02-09 09:45:00 字数 606 浏览 1 评论 0原文

我正在寻找不需要初始化向量的密码算法。我使用nodejs函数 /a>至少记录了没有初始化向量的选项。

如果密码不需要初始化向量,则IV可能为null。

const encryptionAlgoritm = 'aes-192-cbc';
const encryptionKey = '...';
const cipher = createCipheriv(encryptionAlgoritm, encryptionKey, null);
// Error: Missing IV for cipher aes-192-cbc

没有iv参数,可以使用哪种OpenSSL算法?

背景:我不需要解密加密的值。我想将加密值传递给数据库,并使用加密值查询数据库。因此,加密算法需要是徒。

I'm looking for a cipher algorithm which doesn't require an initialization vector. I use the NodeJS function crypto.createCipheriv which documents at least the option to pass no initialization vector.

If the cipher does not need an initialization vector, iv may be null.

const encryptionAlgoritm = 'aes-192-cbc';
const encryptionKey = '...';
const cipher = createCipheriv(encryptionAlgoritm, encryptionKey, null);
// Error: Missing IV for cipher aes-192-cbc

Which OpenSSL algorithm can be used without the iv parameter?

Background: I don't need to decrypt the encrypted value. I want to pass the encrypted value to the database and also query the database with the encrypted value. Therefore the encryption algorithm needs to be bijective.

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文